pelagos_py.steps.input_output.prepare_og1#

class pelagos_py.steps.input_output.prepare_og1.PrepareOG1(name, parameters=None, diagnostics=False, context=None)[source]#

Bases: pelagos_py.steps.base_step.BaseStep

Normalise a loaded file into OG1 with the names and units the pipeline expects.

An optional and hopefully temporary step for data that doesn’t properly comply with the OG1 format. Should be run straight after Load OG1; applies only the fixes a file needs, logging each one (CNDC fixes also raise a warning):

  • Missing LATITUDE/LONGITUDE are renamed from LATITUDE_GPS or ALATPT01/ALONPT01 if found instead; DOXY -> MOLAR_DOXY, TEMPDOXY -> TEMP_DOXY. QC flag variables are renamed alongside.

  • CNDC labelled S/m but holding mS/cm values (median > 8) is scaled x0.1 to S/m and relabelled.

  • When BBP700 is found with no BETA_BACKSCATTERING700 alongside, it can be treated as raw beta and renamed (bbp700_is_beta).

Examples

steps:
  - name: Load OG1
    parameters:
      file_path: "/path/to/dataset.nc"
  - name: Prepare OG1
    parameters:
      bbp700_is_beta: true
      renames:
        DOWNWELLING_PAR: PAR