Re: [gdal-dev] Removing Nodata pixels from raster
you can surely identify the valid pixels with visualization software such as qgis, using the valuetool plugin, to identify the 4 corners of the valid region. Another option is to compress the gtiff with e.g. DEFLATE compression like this gdal_translate -co COMPRESS=DEFLATE in.tif out.tif Etienne On Thu, Oct 25, 2012 at 1:32 PM, katrin eggert katrineggert1...@gmail.com wrote: Hello No I don't know where my valid pixels are. Any alternative? 2012/10/25 Kyle Shannon k...@pobox.com Katrin, Do you know where you valid pixels are in the image? If so, gdal_translate with -srcwin would work: kyle@ubuntu:~$ gdal_translate -srcwin xoff yoff 60 100 in.tif out.tif where xoff, yoff are the number of pixels from the image origin that your valid region begins(pixels, lines). See http://gdal.org/gdal_translate.html for more info. On Thu, Oct 25, 2012 at 8:05 AM, katrin eggert katrineggert1...@gmail.com wrote: Greetings I have a Geotif with only one Layer with a size of 6000x5000 but from which I only have a square of 60x100 with bvalid pixels. the remaining are NOdata. The problem is that this Geotiff is a big file 90MB and without these NoData values I would have a much smaller raster. How can I generate a new Geotiff without these noValid values and with extent adjusted to the valid pixels? Thank you Regards, Katrin E. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev
Re: [gdal-dev] Removing Nodata pixels from raster
In SAGA GIS there is a Crop to Data module (in Grid Tools module library), which performs the task. But this would require you to import your Geotif with the GDAL import module, process it in SAGA, and finally export it as Geotif again with the GDAL export module. Best regards, Volker On 10/25/2012 05:32 PM, katrin eggert wrote: Hello No I don't know where my valid pixels are. Any alternative? 2012/10/25 Kyle Shannon k...@pobox.com Katrin, Do you know where you valid pixels are in the image? If so, gdal_translate with -srcwin would work: kyle@ubuntu:~$ gdal_translate -srcwin xoff yoff 60 100 in.tif out.tif where xoff, yoff are the number of pixels from the image origin that your valid region begins(pixels, lines). See http://gdal.org/gdal_translate.html for more info. On Thu, Oct 25, 2012 at 8:05 AM, katrin eggert katrineggert1...@gmail.com wrote: Greetings I have a Geotif with only one Layer with a size of 6000x5000 but from which I only have a square of 60x100 with bvalid pixels. the remaining are NOdata. The problem is that this Geotiff is a big file 90MB and without these NoData values I would have a much smaller raster. How can I generate a new Geotiff without these noValid values and with extent adjusted to the valid pixels? Thank you Regards, Katrin E. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev
[gdal-dev] Removing Nodata pixels from raster
Greetings I have a Geotif with only one Layer with a size of 6000x5000 but from which I only have a square of 60x100 with bvalid pixels. the remaining are NOdata. The problem is that this Geotiff is a big file 90MB and without these NoData values I would have a much smaller raster. How can I generate a new Geotiff without these noValid values and with extent adjusted to the valid pixels? Thank you Regards, Katrin E. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev
Re: [gdal-dev] Removing Nodata pixels from raster
Hello No I don't know where my valid pixels are. Any alternative? 2012/10/25 Kyle Shannon k...@pobox.com Katrin, Do you know where you valid pixels are in the image? If so, gdal_translate with -srcwin would work: kyle@ubuntu:~$ gdal_translate -srcwin xoff yoff 60 100 in.tif out.tif where xoff, yoff are the number of pixels from the image origin that your valid region begins(pixels, lines). See http://gdal.org/gdal_translate.html for more info. On Thu, Oct 25, 2012 at 8:05 AM, katrin eggert katrineggert1...@gmail.com wrote: Greetings I have a Geotif with only one Layer with a size of 6000x5000 but from which I only have a square of 60x100 with bvalid pixels. the remaining are NOdata. The problem is that this Geotiff is a big file 90MB and without these NoData values I would have a much smaller raster. How can I generate a new Geotiff without these noValid values and with extent adjusted to the valid pixels? Thank you Regards, Katrin E. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev
Re: [gdal-dev] Removing Nodata pixels from raster
Katrin, Do you know where you valid pixels are in the image? If so, gdal_translate with -srcwin would work: kyle@ubuntu:~$ gdal_translate -srcwin xoff yoff 60 100 in.tif out.tif where xoff, yoff are the number of pixels from the image origin that your valid region begins(pixels, lines). See http://gdal.org/gdal_translate.htmlfor more info. On Thu, Oct 25, 2012 at 8:05 AM, katrin eggert katrineggert1...@gmail.comwrote: Greetings I have a Geotif with only one Layer with a size of 6000x5000 but from which I only have a square of 60x100 with bvalid pixels. the remaining are NOdata. The problem is that this Geotiff is a big file 90MB and without these NoData values I would have a much smaller raster. How can I generate a new Geotiff without these noValid values and with extent adjusted to the valid pixels? Thank you Regards, Katrin E. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev ___ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev