Metadata-Version: 2.4
Name: cedarkit-comp
Version: 2026.7.0
Summary: A meteorological computation tool for CEMC/CMA.
Author-email: Wang Dapeng <perillaroc@gmail.com>
License: Apache-2.0
Project-URL: Homepage, https://github.com/cemc-oper/cedarkit-comp
Project-URL: Repository, https://github.com/cemc-oper/cedarkit-comp.git
Keywords: computation,meteorological
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy
Requires-Dist: pandas
Requires-Dist: xarray
Requires-Dist: scipy
Requires-Dist: importlib-metadata; python_version < "3.8"
Dynamic: license-file

# cedarkit-comp

![Maturity-Sandbox](https://img.shields.io/badge/Maturity-Sandbox-F9D71C)
![GitHub Release](https://img.shields.io/github/v/release/cemc-oper/cedarkit-comp)
![PyPI - Version](https://img.shields.io/pypi/v/cedarkit-comp)
![GitHub License](https://img.shields.io/github/license/cemc-oper/cedarkit-comp)
![GitHub Action Workflow Status](https://github.com/cemc-oper/cedarkit-comp/actions/workflows/ci.yaml/badge.svg)

A calculation tool for meteorological data.

## Install

Install using pip:

```bash
pip install cedarkit-comp
```

Or download the latest source code from GitHub and install manually.

## Getting started

Load data from file:

```py
from reki.format.grib.eccode import load_field_from_file

file_path = "/some/path/to/grib2/file"
field_h_500 = load_field_from_file(
    file_path,
    parameter="gh",
    level_type="pl",
    level=500
) / 10.
```

Smooth using `smth9`:

```py
from cedarkit.comp.smooth import smth9
from cedarkit.comp.util import apply_to_xarray_values

field_h_500 = apply_to_xarray_values(
    field_h_500, 
    lambda x: smth9(x, 0.5, 0.25, False)
)
```

## LICENSE

Copyright &copy; 2024-2026, developers at CMA Earth System Modeling And Prediction Centre.

`cedarkit-comp` is licensed under [Apache License V2.0](./LICENSE)
