Mondaic

salvus.modules.waveform_db.waveform_db

salvus.modules.waveform_db.waveform_db salvus modules waveform_db waveform_db

Waveform databases for Salvus.

Classes

WaveformDB

class WaveformDB(builtins.object):
    def __init__(self, filename: pathlib.Path | str): ...

Initialize a waveform database object from a database on disk.

Parameters
  • filename pathlib.Path | str — Path of the database.
Attributes
database_sampling_rate float

The sampling rate in Hertz for all waveforms in the database.

database_start_time obspy.UTCDateTime

Time of the first sample for all waveforms in the database.

gll_points_per_element int

The number of GLL points per element.

meta_json dict

Return a copy of the meta.json dictionary of the Salvus run creating the original volume data.

ndim int

The dimensionality of the database.

polynomial_order int

The polynomial order of the wavefield.

receiver_fields set[str]

The receiver fields available in the database.

Methods
get_waveform_data()
def get_waveform_data(
    self,
    receiver: simple_config.receiver._Base,
    receiver_field: str | None = None,
    sampling_rate: float | None = None,
) -> obspy.Stream: ...

Get waveforms from the database.

Parameters
  • receiver simple_config.receiver._Base — Salvus receiver object.
  • receiver_field str | None — The receiver field to extract. If the receiver object only contains a single receiver field this does not have to be specified.
  • sampling_rate float | None — Optionally resample to a chosen sampling rate. Cannot downsample.
Returns obspy.Stream