SlopeEXCL generates .tif
files to exclude areas unsuitable for wind and solar energy placements based on slope thresholds.
- Wind Turbines: Applies a uniform slope threshold across all aspects.
- Solar Panels: Allows distinct thresholds for south-facing and north-east-west-facing slopes.
The generated .tif files can be integrated as exclusion layers in renewable energy planning tools like GLAES. For example, in Glaes:
ec.excludeRasterType(os.path.join(data_path, 'exclude_slope_pv.tif'), value=1, prewarp=True)
Download of files is indicated by 📋.
Code execution is indicated by 👉.
Set up Python and install the required dependencies (rasterio
, numpy
, scipy
, os
, argparse
).
📋 This repository requires a 3-arc-second resolution Digital Elevation Model (DEM) from HydroSHEDS. Place the downloaded DEM in the data
folder and rename to "fulL_dem".
DEMs for entire continents are often too large to process efficiently. To avoid excessive file sizes, clip the DEM to your area of interest (e.g., a country).
📋 You can download country boundary GeoJson files from opendatasoft based on their ISO3 code. Place the .geojson file in the data
folder and rename to "country_boundary".
👉 Clip the DEM to your country using the provided script:
python clip_raster_to_boundary.py --raster data/full_dem.tif --boundary data/country_boundary.geojson --output data/dem.tif
👉 Execute the script from the terminal:
python exclude_slope.py --type [solar|wind|both] --solar-nea [value] --solar-s [value] --wind-thresh [value] --output [filename]
Example with custom values:
python exclude_slope.py --type both --solar-nea 6.28 --solar-s 33 --wind-thresh 8.53 --output exclusion.tif
To use the default values, omit the optional arguments:
python exclude_slope.py --type both
The script will then use:
--solar-nea
:6.28
(degrees)--solar-s
:33
(degrees)--wind-thresh
:8.53
(degrees)--sigma
:1
--output
:exclusion.tif
exclude_slope.py
: Python script for generating exclusion files.exclude_slope.ipynb
: Jupyter notebook for running the same code interactively.data
: Directory for raw input filedem.tif
.output
: Directory where generated.tif
files will be saved.