Нефть и песок О стали Компрессор - подбор и ошибки Из истории стандартизации резьб Соперник ксерокса - гектограф Новые технологии производства стали Экспорт проволоки из России Прогрессивная технологическая оснастка Цитадель сварки с полувековой историей Упрочнение пружин Способы обогрева Назначение, структура, характеристики анализаторов Промышленные пылесосы Штампованные гайки из пружинной стали Консервация САУ Стандарты и качество Технология производства Водород Выбор материала для крепежных деталей Токарный резец в миниатюре Производство проволоки Адгезия резины к металлокорду Электролитическое фосфатирование проволоки Восстановление корпусных деталей двигателей Новая бескислотная технология производства проката Синие кристаллы Автоклав Нормирование шумов связи Газосварочный аппарат для тугоплавких припоев
Главная --> Промиздат -->  Map principle 

1 2 3 4 5 6 7 8 9 10 11 12 13 14 ( 15 ) 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127

After a successful import, it is useful to run the module r.support with -r flag on the recently imported data set. It will calculate statistical data, such as the range, which is required by other modules:

r.support -r d44103d7

The import of multispectral satellite data is explained in Section 9.2.1.

Generating a new LOCATION from an external raster map. The module r.in.gdal provides an additional, very useful functionality by automatically generating a LOCATION from an external raster data set. For this purpose, it has to be run within another LOCATION (this LOCATION can be completely unrelated to the imported data and its setting wont be affected by r.in.gdal execution). For example, you can import a new 10 m DEM for Spearfish area, provided as ArcGRID coverage 092335362 in geographic coordinate system (NAD83 datum), and at the same time create a new LOCATION spearfishllnad83 that is defined with the parameter location. The projection information is taken from the input data set, in our case stored in the file 09233536/PRJ.ADF. To import the DEM run the r.in.gdal command from the spearfish LOCATION that we have created in Section 3.2.1:

unzip 09233536.zip cd 09233536/

r.in.gdal 09233536 location=spearfishllnad83 output=nedlOm.11

To display the imported DEM, exit GRASS and start it with new spearfishllnad83 LOCATION. You should see your imported file ned10m.ll when you run g.list rast and check the coordinate system information using g.projinfo. Note that the datum is NAD83, therefore we could not directly import this map into the spearfishLL LOCATION used in Section 3.1.3 that uses datum NAD27.

Generally, if no projection information is present, the new LOCATION will not have the coordinate system definitions. The module g.setproj can then be used within the new LOCATION to generate the projection information. Be careful to use g.setproj only in a new LOCATION! The module does not perform any coordinate transformation of data (see Section 3.3 to learn how to do that).

Import of TIFF raster files. Data in the TIFF/TFW format usually consist of two files: your maptif and your map.tfw. Make sure to get both files when obtaining data. For GeoTIFF format it will be a single file which may also contain projection information and one or several maps. Using the module r.in.gdal it is quite easy to import such a data set:

r.in.gdal -e in=your map.tif out=your map



The flag -e allows you to automatically extend the LOCATION DEFAULT -WIND based on new data set, if the imported map is larger. If the imported TIFF image consists of several bands, they are extracted respectively into the current MAPSET. This will usually occur when importing aerial color images which are delivered in RGB (red, green, blue) channels. It may happen that the data set does not contain the projection information. The module will not import the file unless you use the -o flag (override). In this case you are using the projection information of the current LOCATION which makes sense when the map belongs to this LOCATION and it is in the identical coordinate system.

Import of ASCII raster files. Raster data in ASCII format can be in different GIS formats. Besides the GRASS ASCII raster format (supported by

r.in.ascii and r.out.ascii), the ARC/INFO ASCII GRID format is commonly used. It can be imported by r.in.gdal. Data in ARC/INFO ASCII GRID sometimes have an associated map.prj file which contains projection information. If not available, the -o flag in r.in.gdal allows us to use the current projection information from the LOCATION.

Another method to generate raster area or lines from given coordinates is supported by r.in.poly. The module accepts text files containing coordinate pairs with labels. Either raster area ( A ) or raster line ( L ) type can be specified. An example for a single area (store next code as text file rasterarea.txt, we use UTM coordinates for Spearfish region):

591316.80 4926455.50 591410.25 4926482.40 591434.60 4926393.60 591341.20 4926368.70 = 42 stadium

It is important to define the raster resolution before importing this vector file (e.g. 1 meter raster resolution). The import of this file with r.in.poly will generate a raster area with given corner points and labeled as 42 stadium :

g.region res=l

r.in.poly in=rasterarea.txt out=stadium r.info stadium

The resulting map contains the desired stadium area.

Import of ARC/INFO Binary GRID files. The ARC/INFO Binary GRID coverages can be imported directly using r.in.gdal, as shown above (see paragraph about generating a new LOCATION). As an input, you can either specify the grid coverage directory or the w001001.adf grid file inside the grid directory.



Import of USGS DOQ flies. It is also possible to import DOQ (Digital Or-thophoto (Quarter) Quadrangles) data from USGS using r.in.gdal. The included projection information is respected as well as other metadata. Be sure to avoid the DOQ data in MrSID format because it is proprietary and therefore not supported. Conversion with the proprietary converter is done as follows (but it will not transfer projection information):

%#but it will not transfer projection information: mrsiddecode -tif -input 144103d7 a.sid -output i4 4103d7 a.tif

#verification: gdalinfo i4 4103d7 a.tif

As explained in Section 3.3.3, the missing projection information can be reassigned with gdal translate.

Import of binary arrays: GTOPO30 DEM, Etopo-5 DEM, Globe DEM, BIL, AVHRR and GMT flies. The module r.in.bin reads numerous binary array grids such as GTOPO30 DEM (worldwide elevation data in 30 arc-seconds resolution, USGS), Etopo-5 DEM (worldwide elevation data in 5 minutes resolution), Globe DEM (worldwide elevation data in 30 arc-seconds resolution, NOAA), BIL, AVHRR (Advanced Very High Resolution Radiometer) and GMT (Generic Mapping Tool). Please refer to the related manual page (g.manual r.in.bin) for encoding details. Examples are:

import of GTOPO30 DEM data (you can add anull=-9999 if you want the sea level be set to NULL):

r.in.bin -s input=E020N90.DEM out=gtopo30 bytes=2\ north=90 south=40 east=60 west=20 r=6000 c=4800

import of a GMT type 1 (float) binary array (-b may be used to swap bytes if required):

r.in.bin -hf input=your map.grd out=gmtmap

import of a AVHRR image (here the raster map will be assigned a north=128, south=0, east=128, west=0 as rows and cols are defined):

r.in.bin in=p07 b6.dat out=avhrr c=128 r=128

Import of DTED files. The module r.in.gdal supports import of DTED (Military Terrain Elevation Data) at Levels 1 and 2. The DTED data include projection information which is respected.



1 2 3 4 5 6 7 8 9 10 11 12 13 14 ( 15 ) 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127