planetarypy / planetaryimage

Python PDS and Isis Cube file parser.
BSD 3-Clause "New" or "Revised" License
39 stars 20 forks source link

GDAL Support? #46

Open cmillion opened 8 years ago

cmillion commented 8 years ago

There was discussion at the Data Users Workshop Hackday of building parallel PDS image viewers: one in pure Python and one that uses GDAL + PVL. (See: https://github.com/planetarypy/planetaryimage/wiki/Requirements) It looks like maybe the first is underway but not the second. Is anybody working on the GDAL angle, and do you still think it's necessary?

godber commented 8 years ago

@cmillion yeah, I know there were people who were interested in this. I personally am not interested in doing it unless someone can show me how GDAL supports opening many different mission image types.

I am definitely not advocating against someone else doing this work. I'd fully support having and alternate GDAL based backend.

Having a rough idea as to how GDAL supports the products listed here, would be a first step:

http://planetaryimage.readthedocs.org/en/latest/supported_planetary_image_types.html

(Note: the green/red markers on that page are somewhat notional as far as I am concerned. Until someone with true knowledge about a specific mission data type evaluates and writes a test confirming that we support something doesn't. How to formalize our supported data products is still TBD.

If you or someone you know wants to start thinking about GDAL, I'd be happy to discuss strategies with you/whoever. I should also point out one large API change that I know we will have to make already ... we need to support multiple data objects (#19). So image.data will have to become image.data[] or some such. @cmillion you probably have more experience than I do here, since all of the cameras I've worked on have always had only one data object in the file. I was surprised in May to learn what sort of crazy stuff people will jam into a PDS product.

CC @wtolson so he's aware of this discussion.

cmillion commented 8 years ago

Thank you. I don't personally see a reason to fork out a GDAL solution right now.

The data object issue does interest me, and I'd be happy to try to help with it, but I don't recall ever trying to work with PDS data more complicated than image or table + header. I'm aware that the "crazy stuff people will jam into a PDS product" was a problem, though, and think that this was one of the big justifications for PDS4. Do you have an example? In a quick search of PDS documentation referenced by #19, I found references to TIFF, TEX, and QUBE formats.

thareUSGS commented 7 years ago

Just as a heads-up, GDAL now has support for reading and writing ISIS3 cubes. This update does give one some interesting JSON options from python. Only in truck and still beta. For some example access and creation options see: http://www.gdal.org/frmt_isis3.html

One major benefit that I think help GIS-users is the ability for GDAL to convert to a "raw" GeoTiff with a detached ISIS3 header. Reason: 100% compatible with GIS applications and ISIS3 and planetaryimage at the same time. But you will not get to use optimized Tiffs (e.g. compression) if you still want ISIS3 compatibility.