salvus.project.configuration.processing.seismology
salvus.project.configuration.processing.seismology salvus project configuration processing seismology Seismological processing configurations.
Classes
BasicBandpassProcessingConfiguration
BasicBandpassProcessingConfigurationclass BasicBandpassProcessingConfiguration(
salvus.project.configuration.processing.seismology.SeismologyProcessingConfiguration
):
def __init__(
self,
name: str,
data_source_name: str,
bandpass_minimum_frequency: float,
bandpass_maximum_frequency: float,
bandpass_filter_corners: int = 0,
highpass_filter_corners: int = 4,
lowpass_filter_corners: int = 4,
taper_percentage: float = 0.05,
zerophase: bool = False,
): ...Keeps track of the initial arguments passed to an objects and can later on serialize them to JSON document.
It will only consider whatever is passed in the init.
Basic processing that detrends, tapers, and filters.
namestr — Processing configuration name.data_source_namestr — Name of the data source.bandpass_minimum_frequencyfloat — Minimum frequency of the bandpass filter.bandpass_maximum_frequencyfloat — Maximum frequency of the bandpass filter.bandpass_filter_cornersint — Corners of the bandpass filter.highpass_filter_cornersint — Corners of the highass filter.lowpass_filter_cornersint — Corners of the lowpass filter.taper_percentagefloat — Taper percentage.zerophasebool — Zerophase.
from_json()
from_json()def from_json(d: builtins.dict) -> Any: ...Recreate the object from a dictionary serialization of its initialization parameters.
dbuiltins.dict — Dictionary containing its init parameters and a few other things.
to_json()
to_json()def to_json(
self,
external_file_hash: str | None = None,
timer: Timer | None = None,
log_to_logger: bool = False,
comm: int | None = None,
) -> dict: ...Convert object to a JSON-serializable dictionary.
external_file_hashstr | None — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.timerTimer | None — Execution timer.log_to_loggerbool — Log timings to the logger.commint | None — MPI communicator, if any.
BasicBandpassRemoveResponseProcessingConfiguration
BasicBandpassRemoveResponseProcessingConfigurationclass BasicBandpassRemoveResponseProcessingConfiguration(
salvus.project.configuration.processing.seismology.SeismologyProcessingConfiguration
):
def __init__(
self,
name: str,
data_source_name: str,
bandpass_minimum_frequency: float,
bandpass_maximum_frequency: float,
units: str,
bandpass_filter_corners: int = 0,
highpass_filter_corners: int = 0,
lowpass_filter_corners: int = 0,
pre_filter: tuple[float, float, float, float],
water_level: int = 200,
taper_percentage: float = 0.05,
zerophase: bool = False,
): ...Keeps track of the initial arguments passed to an objects and can later on serialize them to JSON document.
It will only consider whatever is passed in the init.
Basic processing which removes the response and applies a Butterworth bandpass filter.
namestr — Processing configuration name.data_source_namestr — Name of the data source.bandpass_minimum_frequencyfloat — Minimum frequency of the bandpass filter.bandpass_maximum_frequencyfloat — Maximum frequency of the bandpass filter.unitsstr — Desired output units.bandpass_filter_cornersint — Corners of the bandpass filter.highpass_filter_cornersint — Corners of the highass filter.lowpass_filter_cornersint — Corners of the lowpass filter.pre_filtertuple[float, float, float, float] — Pre-filter settings.water_levelint — Water level in dB.taper_percentagefloat — Taper percentage.zerophasebool — Zerophase.
from_json()
from_json()def from_json(d: builtins.dict) -> Any: ...Recreate the object from a dictionary serialization of its initialization parameters.
dbuiltins.dict — Dictionary containing its init parameters and a few other things.
to_json()
to_json()def to_json(
self,
external_file_hash: str | None = None,
timer: Timer | None = None,
log_to_logger: bool = False,
comm: int | None = None,
) -> dict: ...Convert object to a JSON-serializable dictionary.
external_file_hashstr | None — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.timerTimer | None — Execution timer.log_to_loggerbool — Log timings to the logger.commint | None — MPI communicator, if any.
CustomSeismologyProcessingConfiguration
CustomSeismologyProcessingConfigurationclass CustomSeismologyProcessingConfiguration(
salvus.project.configuration.processing.seismology.SeismologyProcessingConfiguration
):
def __init__(
self,
name: str,
data_source_name: str,
processing_function: str | typing.Callable,
): ...Keeps track of the initial arguments passed to an objects and can later on serialize them to JSON document.
It will only consider whatever is passed in the init.
Custom processing function. Any function with a suitable signature is acceptable.
The function must take the following arguments:
st: Anobspy.Streamobject with the data.receiver: The receiver object for the receiver.sources: All sources for the event.
In the case of seismological data it can also optionally take:
inv: Anobspy.Inventoryobject for the station in case it is stored in an ASDF file. Might be None.
The function must return the processed obspy.Stream object which
must contain exactly the same number of traces.
namestr — Name of the processing configuration.data_source_namestr — Name of the original data source.processing_functionstr | typing.Callable — The actual function.
from_json()
from_json()def from_json(d: builtins.dict) -> Any: ...Recreate the object from a dictionary serialization of its initialization parameters.
dbuiltins.dict — Dictionary containing its init parameters and a few other things.
to_json()
to_json()def to_json(
self,
external_file_hash: str | None = None,
timer: Timer | None = None,
log_to_logger: bool = False,
comm: int | None = None,
) -> dict: ...Convert object to a JSON-serializable dictionary.
external_file_hashstr | None — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.timerTimer | None — Execution timer.log_to_loggerbool — Log timings to the logger.commint | None — MPI communicator, if any.
SeismologyProcessingConfiguration
SeismologyProcessingConfigurationclass SeismologyProcessingConfiguration(
salvus.project.configuration.processing.ProcessingConfiguration
):
def __init__(
self,
name: str,
data_source_name: str,
processing_function: str | typing.Callable,
): ...Keeps track of the initial arguments passed to an objects and can later on serialize them to JSON document.
It will only consider whatever is passed in the init.
Define processing within SalvusProject with a function. Any function with a suitable signature is acceptable.
For block processing, the function must take the following arguments:
data_array: Anxarray.DataArrayobject with the data.event: The corresponding event.
Or, if the processing should be applied per receiver:
st: Anobspy.Streamobject with the data.receiver: The receiver object for the receiver.sources: All sources for the event.
In the case of seismological data it can also optionally take:
inv: Anobspy.Inventoryobject for the station in case it is stored in an ASDF file. Might be None.
The function must return the processed xarray.DataArray or
obspy.Stream object which must contain exactly the same number
of traces.
namestr — Name of the processing configuration.data_source_namestr — Name of the original data source.processing_functionstr | typing.Callable — The actual function.
from_json()
from_json()def from_json(d: builtins.dict) -> Any: ...Recreate the object from a dictionary serialization of its initialization parameters.
dbuiltins.dict — Dictionary containing its init parameters and a few other things.
to_json()
to_json()def to_json(
self,
external_file_hash: str | None = None,
timer: Timer | None = None,
log_to_logger: bool = False,
comm: int | None = None,
) -> dict: ...Convert object to a JSON-serializable dictionary.
external_file_hashstr | None — Hash of any external files associated with this object. Can be passed here in which case it will be stored in a centralized location in the JSON file.timerTimer | None — Execution timer.log_to_loggerbool — Log timings to the logger.commint | None — MPI communicator, if any.