In [ ]:
from pyciss import index
In [ ]:
p = index.get_index_dir()
In [ ]:
cumindex = index.read_cumulative_iss_index()
In [ ]:
index.download()
In [ ]:
lblpath = next(index.get_index_dir().glob('*.lbl'))
In [ ]:
lblpath
In [ ]:
from planetpy.pdstools import indices
In [ ]:
label = indices.IndexLabel(lblpath)
In [ ]:
df = label.read_index_data(convert_times=True)
In [ ]:
lblpath
In [ ]:
df.to_hdf(lblpath.with_suffix('.hdf'), 'df')
In [ ]:
for col in df.columns:
weird = (df[[col]].applymap(type) != df[[col]].iloc[0].apply(type)).any(axis=1)
if len(df[weird]) > 0:
print(col)
In [ ]:
for col in ['CALIBRATION_LAMP_STATE_FLAG', 'DESCRIPTION', 'METHOD_DESC', 'TARGET_LIST']:
df[col] = df[col].fillna('Unknown')
In [ ]:
df.info()
In [ ]: