--- title: PlanetaryPy keywords: fastai sidebar: home_sidebar summary: "Beta release: This will become (part of) the core package of the PlanetaryPy organisation." description: "Beta release: This will become (part of) the core package of the PlanetaryPy organisation." nb_path: "notebooks/index.ipynb" ---
Potential logo:
First and foremost this package should provide support in working with planetary science data.
With working
we mean:
of data.
This library manages, via its PDS tools
, multiple PDS3 index files per instrument that can be used for identifying data of interest.
These index files are automatically downloaded and converted to the very performant (and cloud-ready) parquet file format.
Parquet is able to store advanced datatypes like nan-capable integer and full datetime objects, as opposed to HDF5.
The interface to getting data is via a path-retrieving function based on a PDS product-id. If that product-id is available locally, the path will be returned. If it is not, it will previously be downloaded, stored in a systematic fashion organized by mission and instrument, and then the local path will be returned.
For now, the library only returns the path to the object and the user needs to sort out the reading process.
A recently funded NASA project Planetary Data Reader
will be integrated here, so that basic reading into memory can be provided.
As such, we anticipate two classes of reading support:1. basic reading into numpy and/or xarray1. added reader functionality like basic plots and basic geospatial processing, as supported by interested parties
There will exist larger other packages that focus on working with a given instrument's data, in which case that package could become an affiliated package with the planetarypy
GitHub organization, if so desired.
In the future, additional frequently used procedures will be added to this library, e.g.
Look at the Apps
docs to see what pds.apps
exist for easily getting PDS indexes.
The find_index
app is specifically useful when you don't know what index files exist.
So far, the following indexes are supported (but not necessarily all tested within PLPY):
More indexes of other instruments can be easily added by following the existing structure of what has been copied into your config at ~/.planetarypy_config.toml
.
Please consider submitting a pull request for adding further PDS index files into the config file at its source: https://github.com/michaelaye/nbplanetary/blob/master/planetarypy/data/planetarypy_config.toml
Find something in Utils
for working with NASA timestamps and a well working URL download function url_retrieve
, among other stuff.
So far, planetarypy
supports CTX EDR and HiRISE RGB.NOMAP data.
Look at the CTX
and HiRISE
pages for descriptions of classes for working with these data.
Please submit bug reports at https://github.com/michaelaye/nbplanetary/issues
from planetarypy.pds.apps import get_index
ctrindex = get_index("mro.ctx", "edr")
ctrindex.sample(5, random_state=42) # setting random_state to always get same files for docs
hirise_rdr = get_index("mro.hirise", "rdr")
hirise_rdr.sample(5, random_state=42)
from planetarypy.ctx import CTXEDR
pid = ctrindex.sample().squeeze().PRODUCT_ID
pid
ctxedr = CTXEDR(pid)
ctxedr.local_path
ctxedr
ctxedr.download()
ctxedr