-
Notifications
You must be signed in to change notification settings - Fork 1
OnSSET
OnSSET (the Open-source Spatial Electrification Toolkit) is an energy access planning optimization tool written in Python that allows the user to estimate, analyse and visualize, cost-effective, electrification pathways in high spatial detail. As it is a spatially explicit model, when calculating the optimal pathway, OnSSET considers datasets that include information on population distribution, the availability of local energy resources such as solar, wind, and small hydropower, the distance of each population cluster to the current grid networks, landcover, and technology investment and operating costs, among others. The least-cost solution presented in the model compares the cost of supplying electricity to settlements either through a central grid connection, stand-alone “solar home systems” providing energy to a single dwelling or electrifying a community using mini-grid systems (here hybrid combinations of solar, battery, diesel, hydro and/or wind). The options are visualised in Figure 1.
Figure 1: Different energy technology options for electricity access and their typical end-users
The selection of the cheapest electrification solution for each populated area requires first the collection of a significant amount of location-specific data across the area of interest. This data relates to the population and demand in the settlement, the availability of energy resources, landcover, and protected areas, as well as the distance to existing infrastructure (such as roads and existing grid network). In the first step of the analysis, it is determined where the people with current access to electricity are: if a populated area is close to the existing electric network and there is light during the nighttime, it is considered as currently electrified via the electric network. Furthermore, locations of existing mini-grids and stable nightlights in isolated areas are used to identify additional settlements that are already electrified with mini-grids. A simplified example is illustrated below in Figure 2.
Figure 2: Data collection and calculation for each population settlement (Khavari, 2022).
In the next step shown in Figure 3, an electrification technology is selected for each populated area to meet the electricity demand (which is estimated as described in the previous section). This means that all households in each populated area are allocated the same electrification technology.
Figure 3: OnSSET least cost electrification technology option selection per settlement (Khavari, 2022).
The technology solution selected depends on the cost of providing electricity, or more precisely, the levelized cost of energy (LCOE). This is the cost that each unit of electricity would need to be sold for to cover all potential costs e.g., capital costs, interest on loans, insurance, installation and logistical costs, fuel, repairs and breakdowns, maintenance, and salaries, etc.) over the life of the project. The technology (grid extension, mini-grid, or solar home system) that can meet the demand at the lowest LCOE is selected in each area. The total costs in a populated area are the sum of the costs of all individual connections and generating technologies. For solar home systems, each customer will have their own system, operating in isolation from each other. One larger generation source is used for mini-grids instead of providing solar panels for every single household. A mini-grid could be powered by solar energy, hydro or wind. Additionally, a distribution network is required to connect the customers to the energy sources. Depending on the size and demand of the area, economies of scale may lead to lower generation costs than for Solar Home Systems, which can make up for the additional costs from the distribution network. Finally, the last option is the extension of the centralised grid network. This considers the cost of the distribution network needed in the settlement, the new lines needed to connect the area to the existing network, as well as the cost of generation of grid electricity (which comes from the NEST model in this study). This overall processing flow is demonstrated schematically in Figure 4 below.
Figure 4: Processing flow of the Open-Source Spatial Electrification Toolkit (OnSSET). Adapted from (OnSSET, 2022)
This calculation and optimal technology selection is made for an intermediate and a final year, 2030 and 2060 respectively, under certain assumptions for several parameters. These parameters include the electrification target at the end year, population growth, demand growth from households, heavy industries and other businesses, and solar panel costs. When this target is not 100%, a criterium must be chosen to select which populated areas are electrified first. The default of the model prioritises households whose per capita investment cost is the lowest. Other possible criteria could be to electrify first the poorest or richest households, or those which are closer to the electric grid, or a custom prioritisation implementation. OnSSET determines if settlements should be supplied from the grid or by off-grid technologies (and which ones), and NEST determines the cheapest technology mix to satisfy the demand for grid electricity and the estimated cost of that electricity.
The database to run the platform for the pilot country of Zambia is avaiable at the official Zenodo repository of the RE4AFAGRI platform).
- For OnSSET: include the OnSSET replication data folder unzipped in
onsset\onsset_replication
(more details below)
- Have Python (version 3+) and the conda package manager installed on your local computer:
- If you do not have this, then download and install Anaconda for your operating system from here: https://www.anaconda.com/ (Many useful Jupyter Notebook tutorials are also available there if you are unfamiliar with Jupyter)
- Then open "Anaconda Prompt" and navigate to this repository and into the
onsset
folder, and run the following commands: -
conda env create --name gep_onsset_env --file gep_onsset_env.yml
(This might take a while and download 100+MB of Python packages) - Then run the following commands:
conda activate gep_onsset_env
-
jupyter notebook
orjupyter lab
(if you are familiar with JupyterLab and know how to ensure your correct environment is activated)
- This will open up the Jupyter Notebook in a browser window.
- Include the "onsset_replication" data from the the official Zenodo repository of the RE4AFAGRI platform Unzip the database and then take the onsset data into
onsset\onsset_replication
(the folder will exist in the code but will be empty when downloading the code from github). After completing this correctly the folder should have 3 sub-foldersclusters
,mled
, andonsset_input_files
and no longer be as .zip file. If done incorrectly the code in the next steps will likely fail. - Go to the instructions below to run the different OnSSET parts of the model.
- Make sure the replication data is downloaded from the official Zenodo repository of the RE4AFAGRI platform as described above.
- In the root of the
onsset
folder first openMLED_extraction_to_OnSSET.ipynb
and run all of the cells. This will extract the MLED demands and create OnSSET compatible input files for use in the next step. The process may take a few minutes. You should find them as .CSV files in theonsset\mled_processed_input_files
folder with the names of the scenarios. If for any reason this step fails, then there are pre-processed input files available in theonsset_replication\mled_processed_input_files
database download which you could use instead or if you wish to double check your results. - Then, navigate into the
onsset/onsset
sub folder which also includes the .py Python files used by OnSSET. - Open the
OnSSET_Scenario_Running.ipynb
Notebook and run all of the cells. This will take a few minutes and will run the different scenarios and calculate the least-cost electrification options for the entire country. It will output it's results into several folders as .CSV files both as full results files for every population cluster in the country as well as summary files (also used later by NEST).
- The results files can be analysed using Python and Pandas in the "OnSSET_Scenario_Running.ipynb" notebook or with custom notebooks or other code.
- Otherwise the results can be visusalised in GIS software such as QGIS: https://download.qgis.org/. They can be linked back to the cluster .gpkg shape files by using a "join" (matching the clusters to the results) with the shared "id" variable to visualise the shapes in addition to the electrification optimization information of your choice. Typically the optimal technologies are shown but levelized costs and/or investment costs can also be interesting, or to visualize the estimated starting electrification status of each settlement as an example.
- Simplified results summary files for the national level are also available in .csv files in
onsset/results/onsset_summary_results
that can be opened and plotted with typical spreadsheet software. - A .csv file is available that summarizes the estimated allocations of energy values between the different technologies, scenarios, and years modelled for the different NEST "BCA" regions (a combination of water catchment areas and sub-national boundaries) results. This can be found in
onsset/results/nest_summaries/energy_allocation_results_for_nest.csv
Some users may have issues installing GDAL or libraries dependent on it on Windows.
Usually installing with conda from conda-forge works around this issue but if you still have problems try following this guide for your system:
https://towardsdatascience.com/spatial-data-science-installing-gdal-on-windows-and-macos-6fb5c958dc26
(Coming soon!)
(Coming soon!)
Parameter or Dataset | Unit | Type or Value | Description | Source | Validation or model linkage |
---|---|---|---|---|---|
Administrative boundaries (National and sub-national borders) | - | vector geometry | Delineates the boundaries of the analysis. | GADM | Consistent with other RE4AFAGRI models. |
BCU (river Basin Catchment Units) | - | vector geometry | Obtained by intersecting Hydrosheds water basin polygons and administrative boundaries polygons | HydroSheds (2021) and GADM (2022) | Derived from NEST delineations. Matched between M-LED, NEST, and OnSSET for consistency. |
Elevation | meters above sea level | raster | Elevation maps are used in several processes in the analysis (Energy potentials, restriction zones, grid extension suitability map etc.). | NASA Shuttle Radar Topography Mission | 90x90m resolution elevation maps used. Assumed to be adequate. Further improvements considered minimal. |
Hydropower | various | vector points | Points showing potential mini/small hydropower potential. Provides power availability in each identified point. | Korkovelos, et. al. 2018 “A Geospatial Assessment of Small-Scale Hydropower Potential in Sub-Saharan Africa” https://www.mdpi.com/1996-1073/11/11/3100 | Korkovelos, et. al. 2018 (default of OnSSET) used without further adjustments |
Land Cover | category | raster | Land cover maps are use in a number of processes in the analysis (Energy potentials, restriction zones, grid extension suitability map etc.). | https://lpdaac.usgs.gov/products/mcd12q1v006/ or https://developers.google.com/earth-engine/datasets/catalog/MODIS_006_MCD12Q1 | Dataset updated to use USGS “mcd12q1v006” categorical landcover maps. Updated from previously discontinued data. |
Night-time Lights | - | raster | Dataset used to, identify and spatially calibrate the currently electrified/non-electrified population. | Payne Institute - Earth Observation Group https://eogdata.mines.edu/products/vnl/#annual_v2 (Processed from VIIRS satellite) | Updated from previous 2016 maps to use composite of 2015-2020 data from eogdata.mines.edu |
Population | various | vector geometries and raster surfaces | Spatial identification and quantification of the current (base year) population. | GRID3 Settlement Extents: https://data.grid3.org/datasets/GRID3::grid3-zambia-settlement-extents-version-01-01-/about & WorldPop Population Counts: https://wopr.worldpop.org/?ZMB/ | Extensive recreation and revalidation of population clusters using GRID3 and WorldPop and updated future projections to match SSPs. More details in the text. Updates benchmarked against existing GEPv2 Data. |
Roads | - | vector lines | Current road infrastructure is used to specify grid extension suitability. | GRIP global roads database https://www.globio.info/download-grip-dataset | Updated to match inputs with M-LED and OnSSET |
Solar irradiation | kWh/m2/year | raster | Provide information about the Global Horizontal Irradiation over an area. This is later used to identify the availability/suitability of Photovoltaic systems. | https://globalsolaratlas.info/download | Updated to use latest data from globalsolaratlas.info (improved resolution from 1km x1km to 250m x 250m) |
Wind speed | m/s (at 100m) annual average | raster | Provide information about the wind velocity over an area. This is later used to identify the availability/suitability of wind power (using Capacity factors). | https://globalwindatlas.info/en/download/gis-files | Updated to use latest data from globalwindatlas.info (improved resolution from 1km x1km to 250m x 250m) |
Total electricity demand of settlements | kWh/ year | Settlement boundary geometries | Provides the total electricity consumption estimate for the settlement per sector | M-LED model output | M-LED values are used instead of previous methodology. |
Travel-time | minutes | raster | Minutes of travel time via the fastest travel mode to reach the nearest city of at least 50 thousand inhabitants. | World Cities database; friction layer raster: Weiss et al. (2020) | Default from Weiss et. al. used – same dataset as in M-LED |
Electricity Substations | kVa | vector points | Current substation infrastructure is used to specify grid extension suitability | - | Not used in analysis for Zambia. Validated lines data supersede this. |
Electricity grid (existing) | kV | vector lines (Separate for HV and MV lines) | Current grid network. High voltage and medium voltage lines. Low voltage lines not mapped. | Gridfinder: https://gridfinder.org/ Open Street Map Export: https://overpass-turbo.eu/ Nighttime lights: https://eogdata.mines.edu/products/vnl/#annual_v2 | Extensive cross validation and improvement with multiple data sources. Benchmarked against GEPv2 OSM+gridfinder data. |
Electricity grid (planned) | kV | vector lines (Separate for HV and MV lines) | Planned/committed grid network extensions | - | Not currently used in analysis. |
Parameter or Dataset | Unit | Type or Value | Description |
Source |
Validation or model linkage |
---|---|---|---|---|---|
National Electrification Rate |
% | National: 44% | National share of the population classified as “with access to electricity” in baseline year (2020). | World Bank Data https://data.worldbank.org/indicator/EG.ELC.ACCS.ZS |
Updated to match values used in M-LED with latest available data. |
Average rural household size |
people | Different per zone based on national survey data | Gives the total estimated average persons per household in the rural and urban areas. | Global Data Lab (DHS surveys) https://globaldatalab.org/ |
Updated to match values used in M-LED with latest available data. |
Average urban household size |
people | ||||
Expected Hydro mini‐grid cost: |
$/kWp | 3000 $/kWp | These costs are used to calculate the total system costs of minigrids of various technologies and combinations | -International Renewable Energy Agency, “Renewable Power Generation Costs in 2017,” -IRENA, Innovation Outlook: Renewable Mini‐Grids. 2016. -IRENA, “Solar PV in Africa: Costs and Markets,” 2016. -A. Korkovelos et al., “The Role of Open Access Data in Geospatial Electrification Planning and the Achievement of SDG7. An OnSSET‐Based Case Study for Malawi Apr. 2019, |
Unchanged from previous benchmarked values. Same values as in GEPv2. |
Expected Hybrid mini‐grid cost: |
various | -PV panels: 503 $/kWp -Batteries: 139 $/kWh -Inverter: 80 $/kW -Charge controller: 142 $/kWp -Diesel generator: 261 $/kWp -Wind turbine: 2800 $/kWp |
Unchanged from previous benchmarked values. Same values as in GEPv2. |
||
Expected PV stand‐alone (or SHS) costs: |
$/kWp | -9620 $/kWp if kW < 0.02 -8780 $/kWp if 0.02 < kW < 0.05 -6380 $/kWp if 0.05 < kW < 0.1 -4470 $/kWp if 0.1 < kW < 1 -6950 $/kWp if kW > 1 |
These costs are used to calculate the cost of SHS of different sizes (economies of scale) |
Unchanged from previous benchmarked values. Same values as in GEPv2. |
|
Grid electricity wholesale generation cost |
$/kWh | Taken from each corresponding scenario run of the NEST model | The grid electricity generation cost is the wholesale total cost of electricity generation levelized over the operating lifetime of the energy system. | NEST model outputs |
Updated to use values from NEST modelling. Previous GEPv2 values no longer used. |
Transmission and Distribution (T&D) costs |
various | -HV line (69‐132 kV): 53000 $/km -MV line (11‐33 kV): 7000 $/km -LV line (0.2 – 0.4 kV): 4250 $/km -HV to MV substation (1000 kVA): 25000 $/unit -MV to LV substation (400 kVA): 1000 $/unit -Service transformer (50 kVA): 4250 $/unit |
T&D costs of each appropriate type, size, and distance are calculated to determine the total electric transmission and distribution cost from the nearest suitable existing infrastructure to each settlement in the area of study. | Energy Sector Management Assistance Program (ESMAP), “Model for Electricity Technology Assessment (META).” 2014. R. Karhammer et al., “Sub‐Saharan Africa: Introducing Low-Cost Methods in Electricity Distribution Networks,” ESMAP October 2006. |
Unchanged from previous benchmarked values. Same values as in GEPv2. |
Financial support from the European Commission H2020 funded project LEAP-RE (Long-Term Joint EU-AU Research and Innovation Partnership on Renewable Energy), grant number 963530 is gratefully acknowledged.