[GRASS-user] batch processing for raster import

Jarosław Jasiewicz jarekj at amu.edu.pl
Tue Nov 13 02:52:28 EST 2007


Christoph Knoll pisze:
> Hello everybody,
>
>  I am working with airborne laser scanner data and I need to import more than
> 2000 raster-datasets into my GRASSDatabase. I started to import the data with
> r.in.gdal (it works perfect) but if I do everything myself, I will still be
> importing the data still in a week or so.
>
> Who can tell me how to write or who has a script for batch processing (importing
> the data with the r.in.gdal-command?
>
> I'd be thankful for any help.
>
> Thanks in advance
>  Chris
>
>
> --------------------------------
> University of Innsbruck
> Institute of Geography
> Climate and Cryospheric Research
> Innrain 52f; A - 6020 Innsbruck
> AUSTRIA
>
> KNOLL Christoph, Mag.
>
> Dorfstrasse 106a/3
> 6240 Radfeld/Tirol
> AUSTRIA
>
> Office: +43 (0)512 507 5416
> Mobile: +43 (0)650 6013230
>
> _______________________________________________
> grassuser mailing list
> grassuser at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grassuser
>   
something like this:
divide rasters into some directories (2000 may be to much for it) and:
------
#!bin/bash
list_of_raster= ls

for i in $list_of_raster
do
eval `r.in.gdal input=~/your_dir/$i output=so_$i `
done
------
r.in gdal may require some addational parameters

end script may not work propertly, (i not tested it I use very similar 
to import multiple files)

Jarek




More information about the grass-user mailing list