CAMELS-DE 🌊
A Python package for working with the CAMELS-DE dataset.
About 🐪
CAMELS-DE provides access to hydrometeorological time series data and catchment attributes for 1582 catchments in Germany. This package offers a simple interface for loading, analyzing, and visualizing data from the CAMELS-DE dataset.
Installation
pip install camelsde
Usage
[!IMPORTANT] The package requires the CAMELS-DE dataset to be downloaded and extracted.
CAMELS-DE can be downloaded from Zenodo: 10.5281/zenodo.13837553
- The package uses
polarsfor reading csv files efficiently, but the functions returnpandasDataFrames at the moment. - Gauging station point locations and catchment polygons are returned as
geopandasGeodataFrames. - Interactive time series plots are created using
plotly.
Setting the CAMELS-DE Dataset Path
The package will look for the dataset in the following order:
pathargument passed to theCAMELS_DEclass constructor.- User-configured permanent path (if set).
CAMELSDE_PATHenvironment variable (if set)
You can set a permanent path to your CAMELS-DE dataset in following ways:
from camelsde import CAMELS_DE, set_camels_path
# Option 1: Temporarily override the path for a specific instance
camelsde = CAMELS_DE(path="/path/to/your/CAMELS_DE_v1_0_0")
# Option 2: Set a permanent path that will be remembered across sessions
set_camels_path("/path/to/your/CAMELS_DE_v1_0_0")
camelsde = CAMELS_DE() # Now this will use the permanent path
The permanent path is stored in a configuration file in your user config directory, which makes it available across all future Python sessions.
Basic Usage Examples
from camelsde import CAMELS_DE
# Initialize (uses the configured path or default)
camelsde = CAMELS_DE()
# Load static attributes
attributes = camelsde.load_static_attributes()
# Load specific attributes
hydro_attrs = camelsde.load_static_attributes(static_attribute="hydrology")
# Load specific columns across all static attribute files
attributes2 = camelsde.load_static_attributes(columns=["gauge_name", "gauge_elev", "area", "NSE_lstm", "NSE_hbv"])
# Load specific columns and apply filtering
attributes3 = camelsde.load_static_attributes(columns=["gauge_name", "gauge_elev", "area", "NSE_lstm", "NSE_hbv"], filters={"NSE_lstm": (">=", 0.9), "area": [ (">=", 50), ("<=", 100)]})
# Load specific gauge ID
gauge_data = camelsde.load_static_attributes(gauge_id="DE110000")
# Load timeseries data
ts_data = camelsde.load_timeseries(gauge_id="DE110000")
# Plot timeseries with Plotly
camelsde.plot_timeseries(gauge_id="DE110000", columns=["precipitation", "discharge_spec_obs", "discharge_spec_sim_lstm"])
# Load geospatial data (returns a geopandas GeoDataFrame)
catchments = camelsde.load_geopackage(layer="catchments")
stations = camelsde.load_geopackage(layer="gauging_stations")
Dataset
This package works with the CAMELS-DE v1.0.0 dataset, which is publicly available at:
The dataset needs to be downloaded and extracted before using this package.
Citation
If you use this package or the CAMELS-DE dataset in your research, please cite both the data description paper and the dataset itself:
- Dataset: CAMELS-DE v1.0.0
- Data description paper: CAMELS-DE: hydrometeorological time series and attributes for 1582 catchments in Germany
License
This package is distributed under the CC0 1.0 Universal License. See the LICENSE file for more information.
Metadata
Release files for camelsde 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| camelsde-0.2.0.tar.gz | 10.0 kB | With provenance | Details for camelsde-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| camelsde-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for camelsde-0.2.0-py3-none-any.whl |
Total release size: 23.2 kB
Release files / camelsde-0.2.0.tar.gz
| Download URL | camelsde-0.2.0.tar.gz |
|---|---|
| Size | 10.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
70d0aa26137f01995918f91c9bbc8a047b431b76016d4c048808e79bb3db43bb
|
|
BLAKE2b-256 checksum How to use checksums |
afddb15a82dfed0c4ac1f394982b46b67c4c52b0f3cfb96bf5e6b1c185cd578e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Apr 17, 2025.
Transparency logRelease files / camelsde-0.2.0-py3-none-any.whl
| Download URL | camelsde-0.2.0-py3-none-any.whl |
|---|---|
| Size | 13.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e8d397669c8fff5c9e74327146e9f2e4d98aae027fdb0b6232bd4dfbf4f476c5
|
|
BLAKE2b-256 checksum How to use checksums |
6ec8d5a4094ac8ee05477827e2eb9d87c62dd6b48ac237796f1a2fef0cb905b4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Apr 17, 2025.
Transparency logSecurity for camelsde 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for camelsde-0.2.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Apr 17, 2025.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.