[GRASS-dev] grass6 and python array
glynn at gclements.plus.com
Mon May 10 03:17:26 EDT 2010
Massimo Di Stefano wrote:
> do you know if the nice ability to import grass maps
> directly in a numpy array (as already in grass7)
> will be backported to grass6 too ?
The grass.script.array module in GRASS 7 relies upon some changes
which were made to r.in.bin and r.out.bin, so it can't be used as-is.
It could be modified to work with the 6.x versions, although it would
require some changes. The main issues with the 6.x versions are:
1. You can't choose the output format (other than forcing integer
output with -i). The output is in the same format as the map, so you
would need to use "r.info -t ..." to determine the format of the data.
2. Integers are truncated to 16 bits.
Glynn Clements <glynn at gclements.plus.com>
More information about the grass-dev