pynetdesign.modelling.utils.retrieve_min_amps#

pynetdesign.modelling.utils.retrieve_min_amps(geometry_df, SNR_p, SNR_s, f_p=None, f_s=None, sample_interval=None)[source]#

Retrieve minimum amplitudes for P and S waves from geometry data, scaled based on noise type.

This function takes geometry data frame with noise levels, then scales these noise levels based on the noise type to displacement using the provided frequencies for P and S waves (optional), and applies SNR scaling for P and S waves.

Parameters:
geometry_dfpandas.DataFrame

The path to the input CSV (ASCII) file containing the geometry data.

SNR_pfloat

Signal-to-Noise Ratio for P waves

SNR_sfloat

Signal-to-Noise Ratio for S waves

f_p: :obj:`float`, optional, default: ``None``

Frequency of the P-wave. If None, scaling is postponed to be later done with peak frequency

f_s: :obj:`float`, optional, default: ``None``

Frequency of the S-wave. If None, scaling is postponed to be later done with peak frequency

sample_intervalfloat

Interval along the cable at which strain measurements are made

Returns:
min_amps_pnumpy.ndarray

Minimum displacement amplitudes for P waves

min_amps_snumpy.ndarray

Minimum displacement amplitudes for S waves

Raises:
ValueError

If an unsupported noise type is encountered.

ValueError

If the ‘NoiseLevel’ column is missing in geometry_df.

ValueError

If the sample_interval is None for strain and strain rate noise types