r.buffer.lowmem.html 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <h2>DESCRIPTION</h2>
  2. <em>r.buffer.lowmem</em> creates a new raster map layer showing
  3. buffer (a.k.a. "distance" or "proximity") zones around all
  4. cells that contain non-NULL category values in an existing
  5. raster map layer. The distances of buffer zones from cells
  6. with non-zero category values are user-chosen.
  7. <p>
  8. This is the low-memory alternative to the classic <em>r.buffer</em>
  9. module. It is much slower than the classic version, but will
  10. run on massive raster maps without using a lot of RAM. If your
  11. raster map is larger than 32000x32000 cells on a system with
  12. 1 GB of RAM, or larger than 90000x90000 cells on a system with
  13. 8 GB of RAM, consider using this module.
  14. <p>
  15. Suppose,
  16. for example, that you want to place buffer zones around
  17. roads. This program could create the raster map layer
  18. shown below on the right based on road information
  19. contained in the raster map layer shown on the left.
  20. <div class="code"><pre>
  21. 000000000000000000000000 222233333333333333444444
  22. 111000000000000000000000 111222222222223333333333
  23. 000111111111100000000000 222111111111122223333333
  24. 000000001000011100000000 332222221222211122222222
  25. 000000001000000011111111 333333321233222211111111
  26. 000000001000000000000000 433333321233333222222222
  27. 000000001000000000000000 444443321233333333333333
  28. 000000001000000000000000 444443321233443333333333
  29. 000000001000000000000000 444443321233444444444444
  30. Category 0: No roads
  31. Category 1: Road location
  32. Category 2: Buffer Zone 1 around roads
  33. Category 3: Buffer Zone 2 around roads
  34. Category 4: Buffer Zone 3 around roads
  35. </pre></div>
  36. <br>
  37. <h2>NOTES</h2>
  38. The user has the option of identifying up to 250 continuous zones.
  39. The zones are identified by specifying the upper limit of each desired zone
  40. (<em>r.buffer</em> assumes that <tt>0</tt> is the starting point).
  41. ("Continuous" is used in the sense that each category
  42. zone's lower value is the previous zone's upper value. The
  43. first buffer zone always has distance <tt>0</tt> as its lower
  44. bound.) Buffer distances can be specified using one of five units with the <em>
  45. units</em> parameter: <em>meters, kilometers, feet, miles</em>, and <em>nautmiles</em>
  46. (nautical miles).
  47. <p>
  48. <!-- ??? is this the real method used or some ancient option ??? -->
  49. Distances from cells containing the user-specified category values
  50. are calculated using the "fromcell" method. This method locates each
  51. cell that contains a category value from which distances are to be
  52. calculated, and draws the requested distance rings around
  53. them. This method works very fast when there are few cells
  54. containing the category values of interest, but works
  55. slowly when there are numerous cells containing the
  56. category values of interest spread throughout the area.
  57. <p>
  58. <em>r.buffer</em> measures distances from center of cell to
  59. center of cell using Euclidean distance measure for
  60. planimetric locations (like UTM) and using ellipsoidal
  61. geodesic distance measure for latitude/longitude locations.
  62. <p>
  63. <em>r.buffer</em> calculates distance zones from all cells having non-NULL
  64. category values in the <em>input</em> map. If the user wishes to calculate
  65. distances from only selected <em>input</em> map layer
  66. category values, the user should run (for example)
  67. <em><a href="r.reclass.html">r.reclass</a></em> prior to
  68. <em>r.buffer</em>, to reclass all categories from which distance zones
  69. are not desired to be calculated into category NULL.
  70. <p>
  71. The <b>-z</b> flag can be used to ignore raster values of zero instead of NULL
  72. values in the input raster map.
  73. <p>
  74. <h2>EXAMPLE</h2>
  75. In the following example, the buffer zones would be (in the default units
  76. of meters): 0-100, 101-200, 201-300, 301-400 and 401-500.
  77. <br>
  78. <div class="code"><pre>
  79. <b>r.buffer input=</b>roads <b>output=</b>roads.buf <b>distances=</b>100,200,300,400,500
  80. </pre></div>
  81. Result:
  82. <div class="code"><pre>
  83. <b>r.category input=</b>roads.buf
  84. 1 distances calculated from these locations
  85. 2 0-100 meters
  86. 3 100-200 meters
  87. 4 200-300 meters
  88. 5 300-400 meters
  89. 6 400-500 meters
  90. </pre></div>
  91. <h2>SEE ALSO</h2>
  92. <em>
  93. <a href="g.region.html">g.region</a><br>
  94. <a href="r.buffer.html">r.buffer</a><br>
  95. <a href="r.cost.html">r.cost</a><br>
  96. <a href="r.grow.distance.html">r.grow.distance</a><br>
  97. <a href="r.mapcalc.html">r.mapcalc</a><br>
  98. <a href="r.reclass.html">r.reclass</a><br>
  99. <a href="v.buffer.html">v.buffer</a>
  100. </em>
  101. <h2>AUTHORS</h2>
  102. Michael Shapiro, U.S. Army Construction Engineering
  103. Research Laboratory
  104. <br>
  105. James Westervelt, U.S. Army Construction Engineering
  106. Research Laboratory
  107. <br>
  108. Low-memory Python version by Glynn Clements
  109. <p>
  110. <i>Last changed: $Date$</i>