ctdam.proc.modules.seabird_functions module¶
- class ctdam.proc.modules.seabird_functions.LoopRemoval[source]¶
Bases:
ModuleFlags pressure loops caused by ship heave.
- transformation()[source]¶
Calls the loop removal function and handles the resulting flag values for array truncation.
- Return type:
bool
- time_dependent_loop_removal(pressure, delta)[source]¶
Flag samples where pressure does not increase strictly with time. Optionally leaves some room for minor fluctuations.
A sample is flagged when its pressure does not surpass the maximum pressure of every previous measurement (excluding possible minor fluctuations).
Note take time itself is not required as an arugment as each entry is taken at a discrete timestep i.e. relative time can be easily induced
Parameters
- delta: float
Value that take minor fluctuations into account
- Return type:
ndarray
- jens_loop_removal(pressure, sample_interval, precut_period=5, cut_period=10, mean_speed_percent=20, delay=2, filter_order=4)[source]¶
Flag loops in CTD data caused by ship heave. Credit: Dr. Jens Faber, IOW.
- Parameters:
pressure (
ndarray) – Array of vertical axis valuessample_interval (
float) – The interval the data has been sampled withprecut_period (
int) – Cutoff period for the pressure (Default value = 5)cut_period (
int) – Cutoff period for the main filter (Default value = 10)mean_speed_percent (
int) – Percentage of filtered velocity to use as a threshold (Default value = 20)delay (
int) – Delay (Default value = 2)filter_order (
int) – Order of the Butterworth filter (Default value = 4)
- class ctdam.proc.modules.seabird_functions.AlignCTD[source]¶
Bases:
ModuleAlign the given parameter columns.
- class ctdam.proc.modules.seabird_functions.WFilter[source]¶
Bases:
ModuleApply a signal processing filter to certain data columns.
- transformation()[source]¶
Calls window_filter method and handles argument display.
- Return type:
bool
- window_filter(data_in, window_type, window_width, sample_interval, half_width=1.0, offset=0.0, flag_value=-9.99e-29)[source]¶
Filters a dataset by convolving it with an array of weights.
The available window filter types are boxcar, cosine, triangle, gaussian, and median. Refer to the SeaSoft data processing manual version 7.26.8, page 108.
- Parameters:
data_in (
ndarray) – Data to be filtered.flags (np.ndarray) – Flagged data defined by loop edit.
window_type (
str) – The filter type (boxcar, cosine, triangle, gaussian, or median).window_width (
int) – Width of the window filter (must be odd).sample_interval (
float) – Sample interval of the dataset.half_width (
float) – Width of the Gaussian curve. (Default value = 1.0)offset (
float) – Shifts the center point of the Gaussian. (Default value = 0.0)exclude_flags (bool) – Exclude flagged values from the dataset. (Default value = False)
flag_value (
float) – The flag value in flags. (Default value = -9.99e-29)
- Return type:
ndarray