Metadata-Version: 2.4
Name: ctdcast
Version: 0.3.0
Summary: Processing and reporting for shipboard CTD and LADCP data: raw files to QC'd netCDF to self-contained HTML
Author: Angel Ruiz-Angulo
Author-email: Eleanor Frajka-Williams <eleanorfrajka@gmail.com>
License: MIT
Project-URL: Homepage, https://github.com/ocean-uhh/ctdcast
Project-URL: Source, https://github.com/ocean-uhh/ctdcast
Project-URL: Documentation, https://ocean-uhh.github.io/ctdcast
Project-URL: Bug Tracker, https://github.com/ocean-uhh/ctdcast/issues
Keywords: oceanography,CTD,LADCP,shipboard,seawater,report
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Visualization
Requires-Python: <3.14,>=3.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: gsw>=3.6
Requires-Dist: cmocean>=3.0
Requires-Dist: matplotlib>=3.7
Requires-Dist: pillow>=9.0
Requires-Dist: numpy>=1.24
Requires-Dist: xarray>=2023.1
Requires-Dist: netcdf4>=1.6
Requires-Dist: jinja2>=3.1
Requires-Dist: pyyaml>=6.0
Requires-Dist: ruamel.yaml>=0.18
Requires-Dist: scipy>=1.9
Provides-Extra: docs
Requires-Dist: sphinx>=7.2; extra == "docs"
Requires-Dist: sphinx-rtd-theme>=2.0; extra == "docs"
Requires-Dist: myst-parser>=2.0; extra == "docs"
Provides-Extra: test
Requires-Dist: pytest>=8; extra == "test"
Requires-Dist: pytest-cov>=5; extra == "test"
Requires-Dist: pytest-timeout>=2.3; extra == "test"
Provides-Extra: dev
Requires-Dist: ctdcast[docs,test]; extra == "dev"
Requires-Dist: ruff>=0.3; extra == "dev"
Dynamic: license-file

# ctdcast

[![PyPI](https://img.shields.io/pypi/v/ctdcast.svg)](https://pypi.org/project/ctdcast/)
[![Python versions](https://img.shields.io/pypi/pyversions/ctdcast.svg)](https://pypi.org/project/ctdcast/)
[![License: MIT](https://img.shields.io/pypi/l/ctdcast.svg)](https://github.com/ocean-uhh/ctdcast/blob/main/LICENSE)
[![Tests](https://github.com/ocean-uhh/ctdcast/actions/workflows/tests.yml/badge.svg)](https://github.com/ocean-uhh/ctdcast/actions/workflows/tests.yml)
[![Documentation](https://img.shields.io/badge/docs-ocean--uhh.github.io-blue.svg)](https://ocean-uhh.github.io/ctdcast/)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.22846130.svg)](https://doi.org/10.5281/zenodo.22846130)

Processing and reporting for shipboard CTD and LADCP data: raw Sea-Bird files → per-cast
netCDF at each stage (read, trim, process/QC) → a compiled `profiles.nc` aligned with CF and
CCHDO naming → self-contained HTML reports. Built for use at sea: every output works offline,
with no external requests.

**Documentation**: https://ocean-uhh.github.io/ctdcast/ · [example report](https://ocean-uhh.github.io/ctdcast/_static/demo/index.html)

## Installation

```bash
pip install ctdcast
```

Reading raw `.cnv` files needs `seasenselib` (`pip install seasenselib`). Python 3.10–3.13 is
supported. See the [installation notes](https://ocean-uhh.github.io/ctdcast/quickstart.html)
for isolated-environment and from-source options.

## Quick start

Raw CNV files fresh off the instrument — one command gives station pages, an index and a map:

```bash
ctdcast draft /path/to/cnv/ --cruise odb2026     # writes ./ctd_draft/index.html
```

For the full pipeline — sections, time series, LADCP, the sensor inventory — write a config
and process stage by stage:

```bash
ctdcast init --interactive        # guided config.yaml
ctdcast validate config.yaml      # check paths before the first run
ctdcast process config.yaml --stage 1 2 3 profiles
ctdcast run config.yaml           # the report; --force rebuilds, --only 42 one cast
```

`ctdcast clock config.yaml` diagnoses the acquisition-clock error and prints a paste-ready
`processing.clock` block. See the [quickstart](https://ocean-uhh.github.io/ctdcast/quickstart.html)
for the recommended first-cruise workflow, the [config reference](https://ocean-uhh.github.io/ctdcast/config_yaml.html)
and the [CLI reference](https://ocean-uhh.github.io/ctdcast/cli_reference.html).

To check an installation, run the bundled demo against the committed fixture casts:

```bash
ctdcast run config_demo.yaml      # writes demo_report/index.html
```

## Python API

```python
import ctdcast

ctdcast.report("ctd_nc", "report", profiles_path="profiles.nc",
               groupings_yaml="ctd_groupings.yaml")
```

See the [API reference](https://ocean-uhh.github.io/ctdcast/api.html) for `process`,
`stage1`, `profiles` and the full interface.

## Acknowledgements

Development of this package started during the Odón de Buen cruise of AEI-DFG DS-MIXSED.
DS-MIXSED is funded by the Agencia Estatal de Investigación (AEI) through the PCI 2024 call —
projects PCI2024-155022-2 and PCI2024-155084-2 — and the Deutsche Forschungsgemeinschaft
(DFG, German Research Foundation) — Projektnummer 541914507.

Development was assisted by Claude Code (Anthropic) and GitHub Copilot code review.

## License

MIT License
