pelagos_py.steps.processing.derive_ctd#

class pelagos_py.steps.processing.derive_ctd.DeriveCTDVariables(name, parameters=None, diagnostics=False, context=None)[source]#

Bases: pelagos_py.steps.base_step.BaseStep, pelagos_py.utils.qc_handling.QCHandlingMixin

A processing step class for deriving oceanographic variables from CTD data.

TEOS-10 implementation provided through Gibbs SeaWater (GSW) Oceanographic Toolbox functions. This step requires that “TIME”, “LATITUDE”, “LONGITUDE”, “CNDC”, “PRES” and “TEMP” are present in the dataset variables. Each derived variable is written as <name>_ADJUSTED (e.g. PSAL_ADJUSTED), so raw versions from the input file are kept, and inputs are read from their _ADJUSTED version where one exists. A PSAL_ADJUSTED already made by Salinity Adjustment is not overwritten. See Derived CTD Variables.

DEPTH_ADJUSTED is the vertical coordinate, so it is the one derived variable filled on every row: rows without a usable pressure (none, or flagged 3/4/9) are interpolated in time from the depth either side, at most 5 minutes apart, and flagged 8. The other variables only exist on the CTD’s own rows.

Parameters:

to_derive (list) – Variables to derive, each written as <name>_ADJUSTED: DEPTH, PSAL (practical salinity), ASAL (absolute salinity), CONS_TEMP (conservative temperature) and DENSITY.

Examples

Example usage in a pipeline configuration:

steps:
  - name: "Derive CTD"
    parameters:
        to_derive: [
            DEPTH,
            PSAL,
            ASAL,
            CONS_TEMP,
            DENSITY
        ]
classmethod output_variables(parameters)[source]#

Variables this step writes for the given config parameters (read by the config validator).