Skip to content
PyPSAPublic

About

atlite: A Lightweight Python Package for Calculating Renewable Power Potentials and Time Series

Topics

Resources

Contributing

Stars

413 stars

Watchers

12 watching

Forks

Repository files navigation

atlite

PyPI version Conda version Documentation Status Tests codecov License REUSE status Ruff pre-commit.ci status JOSS Discord

atlite converts weather data into energy system data. It turns wind speed, solar radiation, temperature and runoff into time series of wind and solar power, hydro inflow, heating demand and more. atlite is free software, built on xarray and dask. It processes large weather datasets in chunks and therefore needs little memory.

How atlite works: 1 weather data, 2 cutout, 3 conversion per grid cell, 4 aggregation to regions

A cutout can combine several datasets, for example ERA5 with the higher-resolution solar radiation of SARAH. Before aggregation, atlite can also exclude land that is not available, such as protected areas, to calculate potentials.

Example

This example downloads ERA5 data for Germany in January 2023. It then calculates hourly wind capacity factors for each region in a file of region shapes:

import atlite
import geopandas as gpd

cutout = atlite.Cutout(
    path="germany-2023-01.nc",
    module="era5-edh",
    x=slice(5.5, 15.5),
    y=slice(47, 55.5),
    time="2023-01",
)
cutout.prepare()

regions = gpd.read_file("regions.geojson").set_index("name")
wind = cutout.wind(
    turbine="Vestas_V112_3MW",
    shapes=regions,
    per_unit=True,
    aggregate_time=None,
)

The result is an xarray.DataArray with one time series per region. To download ERA5 data, you need a free account; see ERA5 credentials.

Installation

atlite requires Python 3.11 or newer. Install it with conda from conda-forge:

conda install -c conda-forge atlite

or with pip from PyPI:

pip install atlite

To install the latest development version from GitHub:

pip install git+https://github.com/PyPSA/atlite.git

Documentation

The documentation contains an introduction, examples as Jupyter notebooks and the API reference.

Support and contributing

For the next development goals, see the roadmap and the open enhancements.

Citing

If you use atlite in your research, please cite the paper in the Journal of Open Source Software. The citing page has the BibTeX entry.

Origin

atlite began as a lightweight version of the Aarhus University RE Atlas (Andresen et al., 2015). The Renewable Energy Group at FIAS developed it for the CoNDyNet project (archived), funded by the German Federal Ministry of Education and Research (BMBF) as part of the Stromnetze Research Initiative (archived). Today, volunteers from different institutions maintain atlite; see the contributors.

atlite connects meteorology and energy system modelling, two communities that have long worked apart. Models such as PyPSA-Eur use its time series.

License

Copyright (C) Contributors to atlite https://github.com/pypsa/atlite

  • The source code is licensed under MIT.
  • The documentation is licensed under CC-BY-4.0.
  • Configuration and data files are mostly licensed under CC0-1.0.

See the individual files for details.

About

atlite: A Lightweight Python Package for Calculating Renewable Power Potentials and Time Series

Topics

Resources

Contributing

Stars

413 stars

Watchers

12 watching

Forks

Releases

Packages

Used by

Contributors

Languages