Metadata-Version: 2.4
Name: c3s-event-attribution-tools
Version: 1.0.0
Summary: C3S 451 Event attribution tools library for Python
Author-email: Paul Weerheim <paul@maris.nl>, Tjerk Krijger <tjerk@maris.nl>, Robin Kooyman <robin@maris.nl>, Jasper van den Barg <jasper@maris.nl>, Daniel Arteaga <daniel@maris.nl>
License-Expression: Apache-2.0
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Requires-Python: >=3.7
Description-Content-Type: text/markdown
Requires-Dist: requests>=2.0.0
Requires-Dist: pandas>=2.0.0
Requires-Dist: pyarrow>=19.0.1
Requires-Dist: matplotlib>=3.0.0
Requires-Dist: xarray>=2025.1.0
Requires-Dist: netcdf4>=1.7.2
Requires-Dist: cdsapi>=0.7.6
Requires-Dist: geopandas
Requires-Dist: plotly
Requires-Dist: contextily
Requires-Dist: regionmask
Requires-Dist: cmocean
Requires-Dist: beacon-api>=1.1.3
Requires-Dist: cartopy
Requires-Dist: networkx
Requires-Dist: scitools-iris; sys_platform == "linux" or sys_platform == "darwin"
Requires-Dist: ecmwf-api-client>=1.6.1; sys_platform == "linux" or sys_platform == "darwin"
Requires-Dist: ipywidgets>=8.1.7
Requires-Dist: scipy>=1.16.0
Requires-Dist: rpy2<3.6.0,>=3.5.11
Requires-Dist: requests>=2.32.4
Requires-Dist: aiohttp>=3.13.0


# C3S Event Attribution Tools

Python library for the [C3S2-451: Operational Extreme Event Monitoring and Attribution Service](https://climate.copernicus.eu/operational-extreme-event-monitoring-and-attribution-service), implemented by MARIS B.V. as part of the [Copernicus Climate Change Service](https://climate.copernicus.eu/).

Tools for analysing and attributing extreme weather events to climate change. Covers statistical analyses for the Interactive Web Application, data processing for the Extreme Event Attribution Office, and counter-factual weather data generation.

## Installation

```bash
pip install c3s-event-attribution-tools
```

Or install directly from source:

```bash
pip install git+https://github.com/maris-development/c3s-451
```

## Modules

| Module | Description |
|---|---|
| `analogues` | Circulation analogue analysis: find historical weather patterns similar to a target event using ERA reanalysis, Euclidean distance metrics, and composite anomaly methods |
| `process` | Data processing functions for preparing and transforming climate datasets |
| `plot` | Plotting and visualisation functions for extreme event analysis |
| `utils` | General utility functions |
| `data.cds_client` | Client for the Copernicus Climate Data Store (CDS) |
| `data.mars_client` | Client for the ECMWF MARS archive |
| `data.beacon_client` | Client for the Beacon data service |
| `data.cordex_client` | Client for CORDEX regional climate model data |
| `data.variable` | Variable definitions and metadata |
| `data.conversions` | Unit and format conversions |

## Usage

Start with the [notebook templates](https://github.com/maris-development/c3s-451/tree/main/notebook_templates), which cover a full attribution workflow:

1. **Event definition** - define the extreme event of interest
2. **Trend analysis** - assess observed trends in the relevant climate variable
3. **Circulation analogues** - identify historical circulation analogues
4. **Model validation & Probabilistic attribution** - validate model data and compute attribution probabilities
5. **Synthesis** - summarise results and produce communication outputs

An interactive [Virtual Research Environment](https://event-attribution.copernicus-climate.eu/jupyterlab) with pre-configured notebooks is available on the project platform.

## Resources

| | |
|---|---|
| Documentation | <https://maris-development.github.io/c3s-451/latest/> |
| PyPI | <https://pypi.org/project/c3s-event-attribution-tools/> |
| Source code | <https://github.com/maris-development/c3s-451> |
| Service platform | <https://event-attribution.copernicus-climate.eu/> |
| C3S project page | <https://climate.copernicus.eu/operational-extreme-event-monitoring-and-attribution-service> |
| Hazard monitoring tool | <https://event-attribution.copernicus-climate.eu/pinto> |

## License

[Apache 2.0](LICENSE.md)

