Installation

WindKit is distributed as both pypi and conda packages. However, due to dependencies on several GIS utilities (GeoPandas, Rasterio), which depend on large C based libraries (GEOS, GDAL, PROJ), we recommend installing using the conda packages whenever possible.

Legacy Conda Installation

If you prefer to use the classic conda client, you can follow these steps. Note that dependency resolution may be significantly slower.

  1. Install a conda distribution. If you don’t have one, we recommend Miniforge.

  2. Configure channels. Open a conda-enabled terminal (e.g., “Anaconda Prompt” on Windows) and add the necessary channels.

conda config --add channels https://conda.windenergy.dtu.dk/channel/open/
conda config --add channels conda-forge
  1. Create an environment.

conda create -n <env_name> windkit
  1. Activate the environment.

conda activate <env_name>

Alternative: PyPI Installation

Warning

Installing WindKit from PyPI using pip, uv, or other package managers can be significantly more complex than using conda. This is because PyPI installers do not manage the non-Python, C-based libraries that WindKit’s dependencies (like GeoPandas and Rasterio) rely on (e.g., GDAL, GEOS, PROJ).

You are responsible for installing these system-level dependencies yourself before installing WindKit. For this reason, we strongly recommend the conda-based installation methods for a much smoother experience.

If you are an experienced user and have the necessary system libraries installed, you can use a PyPI-based installer. It is essential to always work within a virtual environment.

Using pip

This is the standard approach using pip.

  1. Install WindKit. To install the base package:

    pip install windkit
    

    To include optional dependencies:

    pip install windkit[plots,data_apis,performance]
    

Note

We recommend using a virtual environment to avoid conflicts with other Python packages. You can create one using venv or virtualenv.

Using uv

uv is an extremely fast Python package installer and resolver, designed as a drop-in replacement for pip and venv.

  1. Install uv. Follow the official installation guide.

  2. Create and activate a virtual environment. uv can create and manage virtual environments.

    # Create the virtual environment
    uv venv
    
    # Activate the environment (same as with venv)
    # On macOS/Linux
    source .venv/bin/activate
    # On Windows
    .venv\Scripts\activate
    
  3. Install WindKit. Use uv pip to install packages into the activated environment.

    To install the base package:

    uv pip install windkit
    

    To include optional dependencies:

    uv pip install windkit[plots,data_apis,performance]
    

Note

If you encounter installation errors, they are almost certainly related to the missing C library dependencies. Please consult the detailed installation guides for GeoPandas and Rasterio for platform-specific instructions.

Dependencies

Required dependencies:

Plotting dependencies (optional: plotting):
Data API dependencies (optional: data_api):
  • earthengine-api (Google Earth Engine: provides access to geospatial data from google. Non-commercial uses only.)

  • planetary-computer (Microsoft Planetary Computer: provides access to geospatial and atmospheric data from Microsoft. Terms of use apply.)

  • pystac-client (Used to access SpatioTemporal Asset Catalogs (STAC) data on Microsofts Planetary Computer)

  • fsspec (Used for accessing ERA5 data from the Planetary Computer)

  • adlfs (Used for accessing ERA5 data from the Planetary Computer)

Performance dependecies (optionaL: performance):
  • numba (Used to speed up some functions)