pyatoa.utils.asdf.clean
Convenience functions for removing data from Pyasdf ASDFDataSet objects. All functions work with the dataset as an input and act in-place on the dataset so no returns
Module Contents
Functions
|
Removes synthetic waveforms and auxiliary data so that only observation |
|
Remove "synthetic_{iter_tag}{step_tag}" tagged waveforms from an asdf |
|
Delete all items in auxiliary data for a given iter_tag, if iter_tag not |
- pyatoa.utils.asdf.clean.clean_dataset(ds, iteration=None, step_count=None, fix_windows=False)[source]
Removes synthetic waveforms and auxiliary data so that only observation data remains for new iterations. If no iteration is given, will wipe all non-observation data and all auxiliary data
- pyatoa.utils.asdf.clean.del_synthetic_waveforms(ds, iteration=None, step_count=None)[source]
Remove “synthetic_{iter_tag}{step_tag}” tagged waveforms from an asdf dataset. If no iter_tag number given, wipes all synthetic data from dataset.
- pyatoa.utils.asdf.clean.del_auxiliary_data(ds, iteration=None, step_count=None, retain=None, only=None)[source]
Delete all items in auxiliary data for a given iter_tag, if iter_tag not given, wipes all auxiliary data.
- Parameters:
ds (pyasdf.ASDFDataSet) – dataset to be cleaned
iteration – iteration number, e.g. “i01”. Will be formatted so int ok.
step_count (str or int) – step count e.g. “s00”. Will be formatted so int ok.
retain (list of str) – list of auxiliary data tags to retain, that is: delete all auxiliary data EXCEPT FOR the names given in this variable
only (list of str) – list of auxiliary data tags to remove, that is: ONLY delete auxiliary data that matches the names given in this variable. Lower in priority than ‘retain’