Previously, the accumulator object returned the coordinates of the upper-left corner of a pixel in keeping with GDAL convention. However, it is more appropriate that when returning linestrings or points, the returned coordinates are for the centre of the cell. As a result, I have updated the script to shift the output coordinates by a value of dx/2 and dy/2 so that all outputs are at the centre of the raster cell.
Previously, the
accumulator
object returned the coordinates of the upper-left corner of a pixel in keeping with GDAL convention. However, it is more appropriate that when returning linestrings or points, the returned coordinates are for the centre of the cell. As a result, I have updated the script to shift the output coordinates by a value ofdx/2
anddy/2
so that all outputs are at the centre of the raster cell.