[gdal-dev] Read image from zip with python and GDAL
Anton Korosov
anton.korosov at nersc.no
Tue Jul 3 10:00:25 PDT 2012
Dear Even,
thank you very much for the info. I'm imressed by the gdal once again!
Though I have a problem with LANDSAT tar.gz:
fram:raw>tar -tf LT52280012006208KIS00.tar.gz
L5228001_00120060727_B10.TIF
L5228001_00120060727_B20.TIF
L5228001_00120060727_B30.TIF
fram:raw>gdalinfo /vsigzip/LT52280012006208KIS00.tar.gz/L5228001_00120060727_B10.TIF
ERROR 4: `/vsigzip/LT52280012006208KIS00.tar.gz/L5228001_00120060727_B10.TIF' does not exist in the file system, and is not recognised as a supported dataset name.
gdalinfo failed - unable to open '/vsigzip/LT52280012006208KIS00.tar.gz/L5228001_00120060727_B10.TIF'.
fram:~>gdalinfo --version
GDAL 1.9.0, released 2011/12/29
Why can that happen?
Thank you!
Anton
----- Original Message -----
From: Even Rouault
[mailto:even.rouault at mines-paris.org]
To: Marc Padilla Parellada
[mailto:padilla.marc at gmail.com]
Cc: gdal-dev at lists.osgeo.org
Sent: Tue, 03
Jul 2012 18:23:38 +0100
Subject: Re: [gdal-dev] Read image from zip with
python and GDAL
> Selon Marc Padilla Parellada <padilla.marc at gmail.com>:
>
> > Hello,
> >
> >
> > I would like to read raster files stored within a zip file with python and
> > GDAL. Something like this:
> >
> >
>
> Try this instead :
>
> data=gdal.Open("/vsizip/file.zip/image.tif")
>
> See http://trac.osgeo.org/gdal/wiki/UserDocs/ReadInZip
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>
More information about the gdal-dev
mailing list