pyatoa.utils.form
Formatting functionality
Pyatoa relies on data structure being ordered and consistent throughout all the various bits of data required, as well as a few standardized string formatters to keep everything playing nice. Functions here will aid in reshaping data into the correct formats.
Module Contents
Functions
|
Specfem outputs seismograms with channel band codes set by IRIS. Instrument |
|
Format the iteration to be used in internal path naming and labelling. |
|
Same as for iteration but step count is formatted with a leading 's' |
|
Formalize the definition of Event ID in Pyatoa |
- pyatoa.utils.form.channel_code(dt)[source]
Specfem outputs seismograms with channel band codes set by IRIS. Instrument codes are always X for synthetics, but band code will vary with the sampling rate of the data, return the correct code given a sampling rate. Taken from Appenix B of the Specfem3D cartesian manual (June 15, 2018)
- pyatoa.utils.form.format_iter(iteration)[source]
Format the iteration to be used in internal path naming and labelling. Standard is to format with a leading ‘i’ character followed by two digits. Inputs can be strings or integers. Assumes iterations won’t go above 99.
- pyatoa.utils.form.format_step(count)[source]
Same as for iteration but step count is formatted with a leading ‘s’