[GRASS-user] r.patch number of input limitation?

Glynn Clements glynn at gclements.plus.com
Wed Sep 24 15:44:22 PDT 2014


Markus Neteler wrote:

> >> > GRASS 6.4.3 (wgs84pure):~/grassdata/import > r.patch in=$MAPS out=mosaic
> >> > WARNING: Unable to open raster map <ASTGTM2N31E096 at seasdem2>
> >> > ERROR: One or more input raster maps not found
> ...
> > Would it be possible to provide some possible reasons/suggestions in the
> > error message? (the wording should be that it is "possible reason")
> 
> Probably not. I think that the messages comes from a generic libgis or
> librast function.

In 7.x, G__open() will generate a warning message which includes
strerror(errno) if the open() call fails.

OTOH, 7.x requires twice as many descriptors per map, as it keeps both
the cell (or fcell) and null files open, whereas 6.x closes the null
file after reading each chunk.

For modules which often open a large number of maps (e.g. r.patch,
r.series), we could check the estimated number of open files against
the result of sysconf(_SC_OPEN_MAX) (at least for Unix) and warn the
user if the limit is likely to be exceeded.

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


More information about the grass-user mailing list