[gdal-dev] Help with python gdal.RasterizeLayer

Chaitanya kumar CH chaitanya.ch at gmail.com
Sat Aug 7 10:23:01 EDT 2010


GDALRasterBand::ComputeStatistics() recalculates them.

On Sat, Aug 7, 2010 at 7:06 PM, Rudi von Staden <rudivs at gmail.com> wrote:

> On 07/08/2010 13:29, Rudi von Staden wrote:
>
>> Below I've included the output I'm getting (followed by my python script).
>> The RasterizeLayer command should be burning the polygon onto the single
>> band raster (initialized to have all cells = 255) using a value of 0.
>> However, the stats show that nothing has happened, and if I check the
>> resulting GTif, all cells are still 255.
>>
>
> Apologies. It seems I was a little hasty in checking my own output, and I
> had some issues with the extents being different. It is working now, but the
> statistics are not reported correctly ([255.0, 255.0, 255.0, 0.0] before and
> after). Do I have to set them manually, or is there some way to recalculate
> them?
>
> Rudi
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>



-- 
Best regards,
Chaitanya kumar CH.
/tʃaɪθənjə/ /kʊmɑr/
+91-9494447584
17.2416N 80.1426E
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20100807/0387ebc4/attachment.html


More information about the gdal-dev mailing list