Changes between Version 16 and Version 17 of Processing/SRTMDEMs
- Timestamp:
- Oct 21, 2010, 2:57:58 PM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Processing/SRTMDEMs
v16 v17 25 25 For ASTER data: 26 26 {{{ 27 r.in.gdal input=<aster_tile>_dem.tif output= aster_data27 r.in.gdal input=<aster_tile>_dem.tif output=<MAP_NAME> 28 28 }}} 29 29 For SRTM data: 30 30 {{{ 31 r.in.gdal input=w001001.adf output= srtm_data31 r.in.gdal input=w001001.adf output=<MAP_NAME> 32 32 }}} 33 33 … … 36 36 If the data you have downloaded spans multiple tiles, then you will need to run the above but inside a for loop like so: 37 37 38 For ASTER data: 38 39 {{{ 39 40 for tile in `ls *_dem.tif`; 40 41 do r.in.gdal input=$tile output=$tile.tile; 42 done 43 }}} 44 For SRTM data: 45 {{{ 46 for tile in `ls *.adf`; 47 r.in.gdal input=$tile output=$tile.tile; 41 48 done 42 49 }}} … … 56 63 }}} 57 64 58 I will refer to the comma separated list after "rast=" as TILELISTfrom hereon - This is the bit you need.65 I will refer to the comma separated list after "rast=" as <TILELIST> from hereon - This is the bit you need. 59 66 60 67 Now run 61 68 {{{ 62 g.region rast= TILELIST69 g.region rast=<TILELIST> 63 70 }}} 64 71 … … 66 73 67 74 {{{ 68 r.patch input= TILELIST output=some_name75 r.patch input=<TILELIST> output=<MAP_NAME> 69 76 }}} 70 77 71 Write down some_namesomewhere - you will need it in a minute.78 Write down <MAP_NAME> somewhere - you will need it in a minute. 72 79 73 80 5. Quit Grass and then start it up again. Select a location using UTM projection for the target area or create one if none is available - make sure you've got the right UTM zone. Note you can also use whatever other projection you want, but this guide assumes you want UTM. … … 75 82 Check [http://www.gpsinformation.org/utm-zones.gif] For the UTM zone 76 83 77 6. Use a conversion utility (eg see the spreadsheet at [http://www.uwgb.edu/dutchs/UsefulData/UTMFormulas.HTM#Spreadsheet http://www.uwgb.edu/dutchs/UsefulData/UTMFormulas.HTM#Spreadsheet]) to determine the boundaries of the target flight in meters within the selected UTM zone. If the flight spans two or more UTM zones, you will have to calculate the offsets appropriate to work out the east and west boundaries of the area. eg. If western boundary is zone 32 and eastern boundary is zone 33, for eastern value use zone 32, add 750000 to value from spreadsheet 78 to find eastings relative to zone 32 bound. 84 6. Here we can use the manual method of calculating the eastings/northings or simply grab them from the tile(s) we have input. 79 85 80 6-alternative. Once all of the 86 '''Manual:''' 87 Use a conversion utility (eg see the spreadsheet at [http://www.uwgb.edu/dutchs/UsefulData/UTMFormulas.HTM#Spreadsheet http://www.uwgb.edu/dutchs/UsefulData/UTMFormulas.HTM#Spreadsheet]) to determine the boundaries of the target flight in meters within the selected UTM zone. If the flight spans two or more UTM zones, you will have to calculate the offsets appropriate to work out the east and west boundaries of the area. eg. If western boundary is zone 32 and eastern boundary is zone 33, for eastern value use zone 32, add 750000 to value from spreadsheet to find eastings relative to zone 32 bound. 81 88 82 7. Set active region to calculated eastings/northings using: 89 7. Set active region to calculated eastings/northings using 90 83 91 {{{ 84 92 g.region n=<north val> s=<south val> e=<east val> w=<west val> res=50 85 93 }}} 86 94 95 For ASTER please put res=30 96 87 97 8. Use r.proj to convert from lat/long to UTM: 88 98 {{{ 89 r.proj input=< input_map_name> location=<lat/long_location> mapset=<lat/long_mapset> output=<output_map_name>99 r.proj input=<MAP_NAME> location=<lat/long_location> mapset=<lat/long_mapset> output=<output_map_name> 90 100 }}} 101 102 Where <MAP_NAME> is what we created in step 4. 91 103 92 104 9. If r.proj gives an error saying that the input map is outside the bounds of the current region, go back to step 6 and check your numbers 93 105 106 107 '''Other method:''' 108 Set the northings/eastings to something very large e.g. 109 110 {{{ 111 g.region n=50000000 s=0 e=50000000 w=-50000000 res=50 112 }}} 113 114 For ASTER please put res=30 115 116 8. Use r.proj to convert from lat/long to UTM: 117 {{{ 118 r.proj input=<MAP_NAME> location=<lat/long_location> mapset=<lat/long_mapset> output=<output_map_name> 119 }}} 120 121 Where <MAP_NAME> is what we created in step 4. 122 123 9. 124 125 Set the new region 126 127 {{{ 128 g.region rast=<output_map_name> 129 }}} 130 131 You can run 132 133 {{{ 134 gis.m & 135 }}} 136 137 To run a GUI and check whether the DEM covers the correct area, or to make the area smaller. 138 94 139 10 Output ASCII DEM from converted map as normal (see [wiki:Processing/NextMapDEMs Creation of DEMs from NextMap data]) 95 140