ctdam.proc package¶
Subpackages¶
- ctdam.proc.modules package
- Submodules
- ctdam.proc.modules.air_pressure_correction module
- ctdam.proc.modules.available_modules module
- ctdam.proc.modules.bottle_file module
- ctdam.proc.modules.external_functions module
- ctdam.proc.modules.geomar_wildedit module
- ctdam.proc.modules.gsw_functions module
- ctdam.proc.modules.seabird_functions module
- Module contents
- Submodules
Submodules¶
Module contents¶
- ctdam.proc.process(input='', modules=['loop_removal', 'wildedit_geomar', 'wfilter', 'alignctd', 'celltm', 'binavg'], other_settings={}, use_multiprocessing=True, **kwargs)[source]¶
- Return type:
Dataset|List[Dataset]
- ctdam.proc.is_directly_measured_value(parameter)[source]¶
Returns whether a parameter has been measured via a sensor or is calculated.
- Return type:
bool
- ctdam.proc.fill_file_type_dir(file_type_dir, file, copy=True)[source]¶
Copies the target input and output files into individual type directories.
A ‘file type directory’ is a directory that is meant to collect all the file of the same file extension that accumulate over multiple processings. For typical Sea-Bird processings you usually end up with something like this:
- root-dir
hex
cnv
XMLCON
btl
bl
hdr
- Parameters:
file (
Path)copy (
bool) – (Default value = True)
- class ctdam.proc.Workflow(ds, configuration, auto_run=True)[source]¶
Bases:
objectRuns a couple of processing steps in sequence on one or more CTD data source files.
It can use seabird internal processing modules, as well as custom ones. These can be in the form of independent windows exes or just pure python code. The input data can be .hex, .cnv or python data representations, predominantly CTDData. The input and all module and extra information is stored in a dict that usually will be generated by the settings Configuration module that reads a toml config.
- Parameters:
configuration (
dict|Configuration) – The information necessary to run a processing procedure.auto_run (
bool) – Whether to autopilot the whole procedure.
- load_config()[source]¶
Thorough input/format check of the processing configuration, that either stems from a .toml config file, or is a self-build dictionary. Checks for the presence of certain keys, and then, depending on their importance, either fails or sets default values.
- new_file_path(file=PosixPath('.'))[source]¶
Creates the new output file path.
Takes the file type directory or the given output directory and joins them with the given output name.
- Parameters:
file (
Path) – The current path to the target file.- Return type:
Path
- run()[source]¶
Performs the processing on all target files.
This is the ‘main’ method of the procedure. All previous methods prepare data for this method to then finally transform the input files into the wanted format. The main purpose of this method is the coordination of the two different forms of processing modules: standalone executables with config files, mainly Sea-Bird processing modules, and python-internal classes that implement the Module interface. The caveats are mainly the switching from one form to the other. This for example results in a in or out parsing of a CnvFile object.
- Return type:
Dataset