Skip to main content

A Python implementation of the COARE bulk air-sea flux algorithm.

Project description

Tests License Code coverage Docs PyPI version

pycoare

pycoare is a Python package for calculating various air-sea fluxes from bulk variables (e.g., wind speed, temperature, humidity), using the COARE algorithms developed through the TOGA-COARE project (Fairall et al., 1996a, Fairall et al., 1996b, Fairall et al., 1997).

Included in this package are implementations of the COARE v3.5 and v3.6 algorithms that builds on the original NOAA-PSL pycoare code. This package makes very minor updates to the algorithm itself, instead focusing on improved code structure, packaging, documentation, and distribution by implementing an object oriented approach and utilizing modern Python tooling. The goal of this new version is to improve usability and reproducibility, encourage collaboration, and ease maintenance.

See the changelog for all mathematically relevant changes made to the algorithm itself.

Find more details on the usage and api in the documentation.

Installation

The latest stable version (currently a beta) can be downloaded using pip:

pip install pycoare

The package can also be added to projects via uv:

uv add pycoare

You can install the most up-to-date version using:

pip install git+https://github.com/pycoare/coare

Versions

pycoare contains two versions of the COARE algorithm: COARE v3.5 and COARE v3.6.

Version 3.5 was released in 2013, which made adjustments to the wind speed dependence of the Charnock parameter based on a large database of direct covariance stress observations (principally from a buoy) (Edson et al., 2013). This led to an increase in stress for wind speeds greater than about 18 m/s. The roughness Reynolds number formulation of the scalar roughness length was tuned slightly to give the same values of Ch and Ce as Version 3.0. The diurnal warm layer model was structured as a separate routine instead of embedded in a driver program. COARE v3.5 was based on buoy data (Edson et al., 2013) and was compared to a large database (a total of 16,000 hours of observations) combining observations from NOAA, WHOI, and U. Miami (Fairall et al., 2011).

Version 3.6 is slightly restructured and built around improvements in the representation of the effects of waves on fluxes. This includes improved relationships of surface roughness and whitecap fraction on wave parameters (Fairall et al., 2022).

Contribution

I welcome any contributions - feel free to raise an issue or submit a pull request. Take a look at the contribution guide to get started!

Credits

This Python implementation of the COARE algorithm was initially translated from MATLAB by Byron Blomquist, Ludovic Bariteau, with support from the NOAA Physical Sciences Laboratory (Ludovic et al., 2021).

The development of the COARE algorithm builds upon decades of research, for which I am extremely appreciative. The history of the COARE algorithm and its development can be found here (Fairall et al., 2022).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pycoare-0.4.2.tar.gz (27.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pycoare-0.4.2-py3-none-any.whl (23.2 kB view details)

Uploaded Python 3

File details

Details for the file pycoare-0.4.2.tar.gz.

File metadata

  • Download URL: pycoare-0.4.2.tar.gz
  • Upload date:
  • Size: 27.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pycoare-0.4.2.tar.gz
Algorithm Hash digest
SHA256 ba5b21cb5aed13f35e2fe04a0d5e3805c7524bddc8f845cc0868268573590bae
MD5 ca278621baafda88354f1c8cc9bf0d28
BLAKE2b-256 5670f43b358069a61b38c3ce8279f03b7c66f524fc978bbca932035c11b9d117

See more details on using hashes here.

File details

Details for the file pycoare-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: pycoare-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 23.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pycoare-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 58949bfdb58e06e5c381c6ac303a7acf879d9c2ca7d634d6582201f7945f7d85
MD5 a5288375b986514f3b60cd3120ed59f1
BLAKE2b-256 e639039df9fb607a3bcde18520f1269dae5f5bdc86e4b6e4939368e2beb176e8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page