[GRASS-user] Combining Rasters Help

Glynn Clements glynn at gclements.plus.com
Fri Jul 21 06:20:40 EDT 2006


Slover, Kevin wrote:

> Trying to find the best way to approach combining ~4400 raster images
> into one.  Description are 50 foot ESRI Ascii formatted DEMs imported
> using r.in.arc.  When attempting to use a bash script to combine these
> rasters using r.mapcalc, the error appears "ERROR: Too many open raster
> files"
> 
> Does anyone know the limit of number of rasters that can be opened at
> one time?  Or does anyone have a suggestion on how best to combine (do I
> use r.combine??) the 4400 rasters as painless as possible?

You need to recompile to change the upper limit; both libgis and
r.patch have their own limits. Even if you do that, 4400 open files
may exceed limits imposed by the OS.

For that many files, I would suggest a recursive approach, i.e. 
combine 440 batches of 100 rasters to give 440 files, combine batches
of those files together, etc.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-user mailing list