[GRASS-dev] G_put_raster_row and OpenMP
Yann
yann.chemin at gmail.com
Thu Nov 29 21:18:48 EST 2007
Hello,
I am trying to include OpenMP coding into raster processing so that each row
can be processed by a different process.
The problem faced is that while row number 1 and 2 are still processing, row
number 3 may already have an ouput for wirting in the output file. Therefore
we would need to specify the row number to write the ouput row to.
Right now,
int G_put_raster_row (int fd, const void * buf, RASTER_MAP_TYPE data_type)
does not include row number specification. So I tried to find other functions
in put_row.c:
int G_put_map_row_random (int fd, const CELL * buf, int row, int col, int n)
This function is giving control to the data (row,col) location. However it
writes only CELL type of data, which is limiting a lot what is possible to do
with it in remote sensing processing.
Ideally, what we would be looking for is a G_put_raster_random_row() function,
giving only the row input location would be fine actually, since distributed
row processing is faster than pixel-wise.
I dont know what are the plans or interests to produce raster code that goes
this way, but this is something simple I believe would help OpenMP coding.
If people dont want to do it, I could try doing it.
If I missed a major concept, please do not hesitate to correct me :-)
Yann
More information about the grass-dev
mailing list