planetarypy / planetaryimage

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

How do we handle mission specific extensions to planetaryimage? #38

Open godber opened 8 years ago

godber commented 8 years ago

There are probably a number of mission specific extensions that can be implemented for planetaryimage. Things like filename parsing (for faster metadata extraction than actually opening a file) and image orientation information (e.g. Mastcam images appear inverted by default and need to be flipped when viewing them). It seems there might be a whole variety of these sorts of things, some of which might be needed to properly access the image data. For instance the Mastcam PDS products are JPEG compressed and claim they need to be converted into a .IMG using DAT2IMG. I suspect that Mastcam PDS archived products can simply have the JPEG data decoded by planetaryimage skipping any redundant product generation.

There may be need to support internal/proprietary extensions. Subclassing would work but if we implemented a plugin architecture of some sort that allowed extending the behavior of planetaryimage without changing the syntax by simply importing and registering a handler of some sort. Or maybe this is a bad idea for some reason.

godber commented 8 years ago

The type of data this includes can be as simple as image_flipped = True to indicate that the image should be flipped when displayed, as is the case for many of the ground based imagers (pancam).