sprit.sprit_calibration module¶
This module will be used for calibration of the ambient HVSR data acquired near wells to derive a relation between the resonant frequency and the depth to bedrock beneath the subsurface.
- sprit.sprit_calibration.calculate_depth(freq_input, depth_model='ISGS_All', freq_col='Peak', calculate_depth_in_feet=False, calculate_elevation=True, show_depth_curve=True, surface_elevation_data='Elevation', bedrock_elevation_column='BedrockElevation', depth_column='BedrockDepth', verbose=False, export_path=None, swave_velocity=563.0, decimal_places=3, depth_model_in_latex=False, fig=None, ax=None, **kwargs)[source]¶
Calculate depth(s) based on a frequency input (usually HVSRData or HVSRBatch oject) and a frequency-depth depth_model (usually a power law relationship).
- Parameters:
- freq_inputHVSRData, HVSRBatch, float, int, or filepath, optional
Input with frequency information, by default {sprit_hvsr.HVSRData, sprit_hvsr.HVSRBatch, float, os.PathLike}
- depth_modelstr, tuple, list, or dict, optional
Model describing a relationship between frequency and depth, by default “ISGS_All”
- calculate_depth_in_feetbool, optional
Whether to calculate depth in feet (in addition to meters, which is done by default)
- freq_colstr, optional
Name of the column containing the frequency information of the peak, by default “Peak” (per HVSRData.Table_Report output)
- calculate_elevationbool, optional
Whether or not to calculate elevation, by default True
- surface_elevation_datastr or numeric, optional
The name of the column or a manually specified numeric value to use for the surface elevation value, by default “Elevation”
- bedrock_elevation_columnstr, optional
The name of the column in the TableReport for the bedrock elevation of the point. This can be either the name of a column in a table (i.e., Table_Report) or a numeric value, by default “BedrockElevation”
- depth_columnstr, optional
_description_, by default “BedrockDepth”
- verbosebool, optional
Whether or not to print information about the processing to the terminal, by default False
- export_path_type_, optional
_description_, by default None
- swave_velocityfloat, optional
Shear wave velocity to use for depth calculations in meters/second, if using the quarter wavelength shear wave velocity method, by default 563.0
- decimal_placesint, optional
Number of decimal places to round depth results, by default 3
- Returns:
- HVSRBatch or list if those are input; otherwise, HVSRData object
The returns are the same type as freq_input, except filepath which returns pandas.DataFrame
- sprit.sprit_calibration.calibrate(calib_filepath, calib_type='power', peak_freq_col='PeakFrequency', calib_depth_col='Bedrock_Depth', outlier_radius=None, xcoord_col='xcoord', ycoord_col='ycoord', bedrock_type=None, show_calibration_plot=True)[source]¶
The calibrate function allows input of table with f0 and known depths to generate a power-law regression relationship.
- Parameters:
- calib_filepathpathlike object
Path to file readable by pandas.read_csv() with a column for frequencies and a column for depths.
- calib_typestr, optional
Which calibration to use. Currently only power-law is supported, by default “power”
- outlier_radiusNone or float, optional
Radius (in CRS of coordinates) within which to use the points for calibration, by default None. Not currently supported.
- bedrock_typestr or None, optional
Bedrock type by which to select which points to use for calibration, by default None. Not currently supported.
- peak_freq_colstr, optional
Which column in calib_filepath to use for fundamental frequency values, by default “PeakFrequency”
- calib_depth_colstr, optional
Which column in calib_filepath to use for depth values, by default “Bedrock_Depth”
- show_calibration_plotbool, optional
Whether to show the calibration plot, by default True
- Returns:
- tuple
Tuple (a, b) containing the parameters used for calibration regression.