Configuration#
gb-dispatch-model has several additional configuration options above and beyond those set by PyPSA-Eur, which are documented in this section. For base PyPSA-Eur configuration, see references below.
Configuration Files#
Any gb-dispatch-model configuration can be set in a .yaml file.
The default configuration config/config.default.gb.yaml is maintained in the repository and covers all the options that are used / can be set.
The configuration config/config.gb.2024.yaml is an opinionated configuration we maintain that uses FES2024 data and is always applied on top of config/config.default.gb.yaml.
To pass your own configuration, you can create a new file, e.g. my_config.yaml, and specify the options you want to change.
They will override the default settings and options which are not set, will be inherited from the defaults above.
Another way is to use the config/config.yaml file, which does not exist in the repository and is also not tracked by git.
But snakemake will always use this file if it exists.
This way you can run snakemake with a custom config without having to specify the config file each time.
Configuration order of precedence is as follows:
1. Command line options specified with --config (optional)
2. Custom configuration file specified with --configfile (optional)
3. The config/config.yaml file (optional)
4. The default configuration files config/config.default.yaml and config/plotting.default.yaml
To use your custom configuration file, you need to pass it to the snakemake command using the --configfile option:
$ snakemake -call --configfile my_config.yaml
fes_costs#
GB-specific cost configuration. |
|||
properties |
|||
|
FES costing workbook sheet configurations. Any pandas read_excel kwargs can be included for each sheet. |
||
type |
object |
||
|
GBP to EUR exchange rate |
||
type |
number |
||
exclusiveMinimum |
0 |
||
default |
1 |
||
|
GBP to USD exchange rate |
||
type |
number |
||
exclusiveMinimum |
0 |
||
default |
1 |
||
|
Additional cost columns configuration |
||
type |
object |
||
|
Mapping from carrier names to fossil fuel types |
||
type |
object |
||
|
List of columns from PyPSA-Eur technology data to pass onto GB dispatch model tech data |
||
type |
array |
||
items |
type |
string |
|
minItems |
0 |
||
|
Default values for columns in PyPSA-Eur technology data |
||
type |
object |
||
|
Mapping from <carrier>(-<set>) to PyPSA-Eur technology data index names, for filling missing technology data. set names will be added for non-default sets (PP for generators, Store for stores) |
||
type |
object |
||
|
Mapping from <carrier>(-<set>) to FES costing table <Type>-<Sub Type> column name concatenations, for selecting variable O&M (VOM) data. |
||
type |
object |
||
|
Mapping from <carrier>(-<set>) to FES costing table <Type>-<Sub Type> column name concatenations, for selecting fuel cost data. |
||
type |
object |
||
|
Value of lost load in £/MWh |
||
type |
number |
||
minimum |
0 |
||
default |
0 |
||
YAML Syntax
fes_costs:
"sheet-config": {}
GBP_to_EUR: 1
GBP_to_USD: 1
add_cols: {}
carrier_fossil_fuel_type: {}
pypsa_eur_tech_data_columns: []
pypsa_eur_tech_data_defaults: {}
pypsa_eur_tech_data_carrier_set_mapping: {}
fes_VOM_carrier_set_mapping: {}
fes_fuel_carrier_set_mapping: {}
voll: 0
low_carbon_register#
Low carbon register configuration. |
||
properties |
||
|
Mapping from low carbon register carriers to model carriers |
|
type |
object |
|
YAML Syntax
low_carbon_register:
carrier_mapping: {}
chp#
Simplified CHP configuration for GB model. |
||
properties |
||
|
Enable simplified CHP constraints |
|
type |
boolean |
|
default |
True |
|
|
Heat-to-power ratio (c_b coefficient) |
|
type |
number |
|
exclusiveMinimum |
0 |
|
default |
1 |
|
|
Minimum operation level when running |
|
type |
number |
|
maximum |
1 |
|
minimum |
0 |
|
default |
0 |
|
|
Heat demand threshold below which CHPs can shut down completely |
|
type |
number |
|
maximum |
1 |
|
minimum |
0 |
|
default |
0 |
|
YAML Syntax
chp:
enable: true
heat_to_power_ratio: 1
min_operation_level: 0
shutdown_threshold: 0
urls#
URLs for GB data sources. |
|||
properties |
|||
|
URL for ETYS boundary GIS data |
||
type |
string |
||
default |
|||
|
default |
null |
|
anyOf |
type |
string |
|
type |
null |
||
|
default |
null |
|
anyOf |
type |
string |
|
type |
null |
||
|
default |
null |
|
anyOf |
type |
string |
|
type |
null |
||
|
default |
null |
|
anyOf |
type |
string |
|
type |
null |
||
|
default |
null |
|
anyOf |
type |
string |
|
type |
null |
||
|
default |
null |
|
anyOf |
type |
string |
|
type |
null |
||
|
URL for FES workbook for the given FES year |
||
type |
string |
||
default |
|||
|
URL for FES costing workbook |
||
type |
string |
||
default |
|||
|
URL for DUKES 5.11 data |
||
type |
string |
||
default |
|||
|
URL for GSP coordinates |
||
type |
string |
||
default |
|||
|
URL for GSP shapes |
||
type |
string |
||
default |
|||
|
URL for ETYS report |
||
type |
string |
||
default |
|||
|
URL for future boundary capabilities (from ETYS chart data). Only used if ‘etys.use_future_capacities’ is True |
||
type |
string |
||
default |
|||
|
URL for low carbon contracts actual CfD Generation data |
||
type |
string |
||
default |
|||
|
URL for European hydrogen demand data from the Clean Hydrogen Observatory |
||
type |
string |
||
default |
|||
|
URL for historical gas prices in the UK from Dukes |
||
type |
string |
||
default |
|||
YAML Syntax
urls:
"gb-etys-boundaries": ""
"transmission-availability-2020":
"transmission-availability-2021":
"transmission-availability-2022":
"transmission-availability-2023":
"transmission-availability-2024":
"transmission-availability-2025":
"fes-workbook": ""
"fes-costing-workbook": ""
"dukes-5.11": ""
"gsp-coordinates": ""
"gsp-shapes": ""
etys: ""
"etys-chart-data": ""
"low-carbon-contracts": ""
eur_H2_demand_today: ""
dukes_fuel_prices: ""
target_crs#
Target coordinate reference system (e.g., EPSG:27700) |
|
type |
string |
default |
EPSG:27700 |
YAML Syntax
target_crs: "EPSG:27700"
region_operations#
Manual region merging and splitting configuration. |
||||||
properties |
||||||
|
Percentage of area loss tolerated when splitting |
|||||
type |
number |
|||||
maximum |
100 |
|||||
minimum |
0 |
|||||
default |
0.01 |
|||||
|
Minimum area of a region in square meters |
|||||
type |
number |
|||||
minimum |
0 |
|||||
default |
100000.0 |
|||||
|
Filter boundaries using capabilities |
|||||
type |
boolean |
|||||
default |
False |
|||||
|
Region split configurations |
|||||
type |
array |
|||||
items |
Configuration for splitting regions. |
|||||
properties |
||||||
|
Region ID to split |
|||||
type |
integer |
|||||
|
Type of split |
|||||
type |
string |
|||||
enum |
vertical, horizontal |
|||||
|
Coordinate for the split |
|||||
type |
number |
|||||
|
Region merge group configurations |
|||||
type |
array |
|||||
items |
Configuration for merging region groups. |
|||||
properties |
||||||
|
Merged region ID |
|||||
anyOf |
type |
integer |
||||
type |
string |
|||||
|
List of regions to merge |
|||||
type |
array |
|||||
items |
anyOf |
type |
integer |
|||
type |
string |
|||||
minItems |
1 |
|||||
|
Transmission owner |
|||||
type |
string |
|||||
enum |
NGET, SPTL, SHETL, N-IRL |
|||||
minItems |
1 |
|||||
|
Map regions to neighbouring countries |
|||||
type |
object |
|||||
YAML Syntax
region_operations:
area_loss_tolerance_percent: 0.01
min_region_area: 100000.0
filter_boundaries_using_capabilities: false
splits: []
merge_groups: []
add_group_to_neighbour: {}
etys#
Configuration for ETYS boundaries. |
||
properties |
||
|
Name of the sheet to use in the downloaded ETYS future capacities workbook |
|
type |
string |
|
default |
ETYS 2022 Chart Data |
|
|
Whether to use future boundary capacities (a.k.a. capabilities) from ETYS chart data, instead of today’s capacities. |
|
type |
boolean |
|
default |
True |
|
|
Manual future boundary capacities, to fill gaps in the ETYS chart data, if necessary. Top-level key is the boundary name, then key-value pairs of year and capacity in MW. |
|
type |
object |
|
YAML Syntax
etys:
future_capacities_sheet_name: ETYS 2022 Chart Data
use_future_capacities: true
manual_future_capacities: {}
transmission_availability#
Transmission availability configuration. |
||||
properties |
||||
|
Years to process |
|||
type |
array |
|||
items |
type |
integer |
||
minItems |
1 |
|||
|
Transmission availability zone configuration. |
|||
properties |
||||
|
List of zones |
|||
type |
array |
|||
items |
type |
string |
||
minItems |
1 |
|||
|
Whether to construct an hourly availability profile using random sampling |
|||
type |
boolean |
|||
default |
True |
|||
|
Transmission availability zone configuration. |
|||
properties |
||||
|
List of zones |
|||
type |
array |
|||
items |
type |
string |
||
minItems |
1 |
|||
|
Whether to construct an hourly availability profile using random sampling |
|||
type |
boolean |
|||
default |
True |
|||
|
Random seeds for each zone |
|||
type |
object |
|||
YAML Syntax
transmission_availability:
years: []
intra_gb:
zones: []
sample_hourly: true
inter_gb:
zones: []
sample_hourly: true
random_seeds: {}
dukes-5.11#
DUKES configuration. |
||||
properties |
||||
|
DUKES sheet configuration. |
|||
properties |
||||
|
Name of the Excel sheet |
|||
type |
string |
|||
default |
||||
|
Columns to use |
|||
type |
string |
|||
default |
||||
|
Number of rows to skip |
|||
type |
integer |
|||
minimum |
0 |
|||
default |
0 |
|||
|
Index columns |
|||
type |
array |
|||
items |
type |
integer |
||
|
Header row |
|||
type |
integer |
|||
minimum |
0 |
|||
default |
0 |
|||
|
Carrier mapping configuration. Top level keys are column names, second level maps from column values to carrier names. |
|||
type |
object |
|||
|
Set mapping configuration. Top level keys are column names, second level maps from column values to set names. |
|||
type |
object |
|||
YAML Syntax
"dukes-5.11":
"sheet-config":
sheet_name: ""
usecols: ""
skiprows: 0
index_col: []
header: 0
carrier_mapping: {}
set_mapping: {}
grid_supply_points#
Grid supply points configuration. |
||
properties |
||
|
Manual GSP name mappings, from FES workbook names to GSP GIS file names. |
|
type |
object |
|
|
Manual GSP coordinate assignments, to add latitudes and longitudes for GSPs missing from the GIS data. Keys are FES workbook GSP names. |
|
type |
object |
|
|
Groups of GSPs to combine. Key is the name of the resulting combined GSP, value is a list of FES workbook GSP names to combine . This is used to combine GSPs which are split in the FES workbook but represented as a single GSP in the GIS data. |
|
type |
object |
|
YAML Syntax
grid_supply_points:
manual_mapping: {}
"fill-lat-lons": {}
combine_gsps: {}
fes#
Future Energy Scenarios (FES) configuration. |
|||||
properties |
|||||
|
FES data year |
||||
type |
integer |
||||
default |
2024 |
||||
|
FES scenarios to process |
||||
type |
array |
||||
items |
type |
string |
|||
|
Mapping from FES scenario shorthand (key) to FES scenario long name (value). The shorthand will be used in the output data directories and may be referred to when shorthand is used in data files (e.g. ETYS chart data). |
||||
type |
object |
||||
|
Default PyPSA network set identifier |
||||
type |
string |
||||
enum |
PP, CHP, Store |
||||
default |
PP |
||||
|
FES workbook sheet configurations. Any pandas read_excel kwargs can be included for each sheet. |
||||
type |
object |
||||
|
FES GB-specific configuration. |
||||
properties |
|||||
|
FES generator and storage configuration |
||||
properties |
|||||
|
Carrier mappings based on values in SubType column. Maps from FES European data SubType column values to PyPSA carrier names. |
||||
type |
object |
||||
|
Set mapping configuration. Top level keys are column names, second level maps from column values to set names. A regular expression can be used. |
||||
type |
object |
||||
|
Mapping FES building block IDs (see sheet BB2 ‘Building Block ID’ column) to FES technology names (see sheet ES1 SubType). Where multiple building block IDs map to the same technology, the total capacity of the technology will be split proportionally across the building blocks. Where multiple technology names map to the same building block ID, the regional capacity of the building block will be split proportionally across those technologies. |
||||
type |
object |
||||
|
Allowed mismatch between regional building block capacity (sheet BB1) and total national technology capacity (sheet ES1). Value given as a fraction and is reciprocal, so sum(technologies) * (1 - tolerance) <= sum(building blocks) <= sum(technologies) * (1 + tolerance) and`sum(building blocks) * (1 - tolerance) <= sum(technology) <= sum(building blocks) * (1 + tolerance)` |
||||
type |
number |
||||
maximum |
1 |
||||
minimum |
0 |
||||
|
FES demand configuration. |
||||
properties |
|||||
|
Grouping from FES workbook BB2 Technology Detail column to model carriers |
||||
type |
object |
||||
|
Mapping from FES workbook heating technologies to intermediate model carriers. |
||||
type |
object |
||||
|
Bus suffixes to apply in the PyPSA network for different demand types |
||||
type |
object |
||||
|
FES ED1 worksheet data item name(s) to use for total demand |
||||
type |
array |
||||
items |
type |
string |
|||
|
FES ED1 worksheet data item name(s) to use for transmisison & distribution losses |
||||
type |
array |
||||
items |
type |
string |
|||
|
FES flexibility configuration. |
||||
properties |
|||||
|
Carrier mapping for flexibility. Top level keys are GB model DSR carriers, second level maps from column names to column value(s). |
||||
type |
object |
||||
|
Demand side response hours for each carrier |
||||
type |
object |
||||
|
Carrier suffix mappings |
||||
type |
object |
||||
|
V2G storage to capacity ratio |
||||
type |
number |
||||
exclusiveMinimum |
0 |
||||
default |
1 |
||||
|
Regional distribution reference configuration |
||||
type |
object |
||||
|
FES European configuration. |
||||
properties |
|||||
|
FES carrier mapping configuration. |
||||
properties |
|||||
|
Carrier mappings based on values in SubType column. Maps from FES European data SubType column values to PyPSA carrier names. |
||||
type |
object |
||||
|
Set mapping configuration. Top level keys are column names, second level maps from column values to set names. A regular expression can be used. |
||||
type |
object |
||||
|
Keys are gb-model demand carriers, values are energy total column names. |
||||
type |
object |
||||
|
Reference data to use to synthesise datasets for which we have no European data. |
||||
type |
object |
||||
|
Marginal cost to apply to European load shedding above the marginal cost of the most expensive European generation technology. This is used to ensure that load shedding only occurs after all generation technologies have been fully utilised, but to stop the resulting marginal prices from being excessively high. |
||||
default |
null |
||||
anyOf |
type |
number |
|||
type |
null |
||||
|
FES hydrogen configuration. |
||||
properties |
|||||
|
FES hydrogen data selection filter. |
||||
properties |
|||||
|
Filter to get all relevant sources of hydrogen supply data from the FES workbook. Keys are column names, values are column value(s) to select. |
||||
type |
object |
||||
|
Filter to get all input electricity required to generate the hydrogen defined by networked_h2_supply . Keys are column names, values are column value(s) to select. |
||||
type |
object |
||||
|
Filter to get all input electricity required for non-networked hydrogen supply. Keys are column names, values are column value(s) to select. |
||||
type |
object |
||||
|
Filter to get all hydrogen storage data. Keys are column names, values are column value(s) to select. |
||||
type |
object |
||||
|
Whether to enable the H2 bus (incl. electrolysis to generate H2, H2 demand, and storage) for European countries. This is optional as the necessary data is not available in the FES and it is unclear whether modelled generation capacity is designed to meet electrolysis demands or not. |
||||
type |
boolean |
||||
default |
False |
||||
YAML Syntax
fes_costs:
"sheet-config": {}
GBP_to_EUR: 1
GBP_to_USD: 1
add_cols: {}
carrier_fossil_fuel_type: {}
pypsa_eur_tech_data_columns: []
pypsa_eur_tech_data_defaults: {}
pypsa_eur_tech_data_carrier_set_mapping: {}
fes_VOM_carrier_set_mapping: {}
fes_fuel_carrier_set_mapping: {}
voll: 0
ev#
Electric vehicle configuration. |
|||
properties |
|||
|
Hours after traffic peak when EVs are assumed to plug in |
||
type |
integer |
||
minimum |
0 |
||
default |
0 |
||
|
Charging duration in hours |
||
type |
integer |
||
exclusiveMinimum |
0 |
||
default |
1 |
||
|
EV demand profile transformation parameters. |
||
properties |
|||
|
Lower bound for gamma optimization |
||
type |
number |
||
exclusiveMinimum |
0 |
||
default |
0 |
||
|
Upper bound for gamma optimization |
||
type |
number |
||
exclusiveMinimum |
0 |
||
default |
null |
||
|
Relative peak tolerance (fraction) |
||
type |
number |
||
maximum |
1 |
||
minimum |
0 |
||
default |
0.0 |
||
|
Relative energy tolerance (fraction) |
||
type |
number |
||
maximum |
1 |
||
minimum |
0 |
||
default |
0.0 |
||
YAML Syntax
ev:
plug_in_offset: 0
charging_duration: 1
ev_demand_profile_transformation:
lower_optimization_bound: 0
upper_optimization_bound: .inf
relative_peak_tolerance: 0.0
relative_energy_tolerance: 0.0
interconnectors#
Interconnectors configuration. |
||||||
properties |
||||||
|
List of interconnector configurations |
|||||
type |
array |
|||||
items |
Individual interconnector configuration. |
|||||
properties |
||||||
|
Interconnector name |
|||||
type |
string |
|||||
|
Neighbouring country to which the interconnector connects |
|||||
type |
string |
|||||
|
Capacity in MW |
|||||
type |
number |
|||||
exclusiveMinimum |
0 |
|||||
|
TYNDP project information. |
|||||
properties |
||||||
|
TYNDP ID, if known |
|||||
default |
null |
|||||
anyOf |
type |
integer |
||||
type |
null |
|||||
|
TYNDP years in which the option appears |
|||||
type |
array |
|||||
items |
type |
integer |
||||
|
Latitude of GB substation where the interconnector onshores |
|||||
type |
number |
|||||
maximum |
90 |
|||||
minimum |
-90 |
|||||
|
Longitude of GB substation where the interconnector onshores |
|||||
type |
number |
|||||
maximum |
180 |
|||||
minimum |
-180 |
|||||
|
Interconnector deployment plan by FES scenario/pathway and year |
|||||
type |
object |
|||||
YAML Syntax
interconnectors:
options: []
plan: {}
redispatch#
Redispatch config. |
||||
properties |
||||
|
Inclusive year range [start, end] |
|||
type |
array |
|||
items |
type |
integer |
||
maxItems |
2 |
|||
minItems |
2 |
|||
|
number of years to extend the constraint cost calculation beyond the final year (using the data from the final year) |
|||
type |
integer |
|||
exclusiveMinimum |
0 |
|||
default |
20 |
|||
|
Whether to unconstrain lines and links in the redispatch model. This will Set s_nom (p_nom) to infinity for lines (links) between GB regions to ensure only boundary capabilities are bounding, not physical line limits. |
|||
type |
boolean |
|||
default |
True |
|||
|
Monthly scaling factors for boundary capabilities, by month number (1-12). This allows us to capture the impact of thermal constraints on boundary capabilities. |
|||
type |
object |
|||
|
penalty (per MWh) applied to redispatch actions in order to mitigate against unrealistic levels of redispatch profit that can occur due to favourable differences in bid/offer costs of different technologies. |
|||
type |
number |
|||
minimum |
0 |
|||
default |
0 |
|||
|
Elexon API configuration. |
|||
properties |
||||
|
Mapping from Elexon BMU technology names to model carrier names |
|||
type |
object |
|||
|
Years to retrieve data for |
|||
type |
array |
|||
items |
type |
integer |
||
|
Boolean to decide source of Elexon BMU unit -> fuel mapping. If True, data is fetched using API; otherwise, it uses data/gb-model/BMUFuelType.xlsx. |
|||
type |
boolean |
|||
default |
False |
|||
|
Maximum number of concurrent requests to Elexon API. May require adjustment if API rate limits are hit. |
|||
type |
integer |
|||
default |
4 |
|||
|
List of carriers to exclude from being redispatched. |
|||
type |
array |
|||
items |
type |
string |
||
|
Buffer distance in meters to apply to mainland GB when identifying flow directions for boundary crossings. This ensures we correctly identify flows on island boundaries (e.g. Anglesey). |
|||
type |
number |
|||
minimum |
0 |
|||
default |
1000 |
|||
|
Mapping from carriers that have received a bid/offer multipliers from processing the Elexon API to other carriers in the model. Keys are other carriers, values are carriers with Elexon bid/offer multipliers. |
|||
type |
object |
|||
YAML Syntax
redispatch:
year_range_incl: []
constraint_cost_extra_years: 20
unconstrain_lines_and_links: true
monthly_boundary_capability_scaling:
1: 1.0
2: 1.0
3: 1.0
4: 1.0
5: 1.0
6: 1.0
7: 1.0
8: 1.0
9: 1.0
10: 1.0
11: 1.0
12: 1.0
redispatch_profit_mitigation_penalty: 0
elexon:
technology_mapping: {}
years: []
api_bmu_fuel_map: false
max_concurrent_requests: 4
no_redispatch_carriers: []
boundary_flow_mainland_buffer_m: 1000
bid_offer_multiplier_mapping: {}
time_aggregation#
List of time aggregation configurations to apply sequentially. If multiple configurations are provided, they will be applied in the order they appear in the list. See PyPSA documentation for details on the available time aggregation methods and their parameters. |
|||
type |
array |
||
items |
Time aggregation configuration. |
||
properties |
|||
|
Time aggregation method to use, of those available in PyPSA. |
||
type |
string |
||
enum |
segment, downsample, resample |
||
|
Parameters for given PyPSA time aggregation method. |
||
type |
object |
||
YAML Syntax
Base PyPSA-Eur config#
Follow the links below to get more information about the base PyPSA-Eur configuration.