Merge pull request #289 from PyPSA/update-lng-ports
Replacing the IGGIELNG_LNG data with Europe-Gas-Tracker
This commit is contained in:
commit
8e74ee6c49
@ -146,10 +146,9 @@ if config["sector"]["gas_network"] or config["sector"]["H2_retrofit"]:
|
|||||||
|
|
||||||
rule build_gas_input_locations:
|
rule build_gas_input_locations:
|
||||||
input:
|
input:
|
||||||
lng="data/gas_network/scigrid-gas/data/IGGIELGN_LNGs.geojson",
|
lng=HTTP.remote("https://globalenergymonitor.org/wp-content/uploads/2022/09/Europe-Gas-Tracker-August-2022.xlsx", keep_local=True),
|
||||||
entry="data/gas_network/scigrid-gas/data/IGGIELGN_BorderPoints.geojson",
|
entry="data/gas_network/scigrid-gas/data/IGGIELGN_BorderPoints.geojson",
|
||||||
production="data/gas_network/scigrid-gas/data/IGGIELGN_Productions.geojson",
|
production="data/gas_network/scigrid-gas/data/IGGIELGN_Productions.geojson",
|
||||||
planned_lng="data/gas_network/planned_LNGs.csv",
|
|
||||||
regions_onshore=pypsaeur("resources/regions_onshore_elec_s{simpl}_{clusters}.geojson"),
|
regions_onshore=pypsaeur("resources/regions_onshore_elec_s{simpl}_{clusters}.geojson"),
|
||||||
regions_offshore=pypsaeur('resources/regions_offshore_elec_s{simpl}_{clusters}.geojson')
|
regions_offshore=pypsaeur('resources/regions_offshore_elec_s{simpl}_{clusters}.geojson')
|
||||||
output:
|
output:
|
||||||
|
@ -1,8 +0,0 @@
|
|||||||
name,geometry,max_cap_store2pipe_M_m3_per_d,source
|
|
||||||
Wilhelmshaven,"POINT(8.133 53.516)",27.4,https://www.gem.wiki/Wilhelmshaven_LNG_Terminal
|
|
||||||
Brunsbüttel,"POINT(8.976 53.914)",19.2,https://www.gem.wiki/Brunsb%C3%BCttel_LNG_Terminal
|
|
||||||
Stade,"POINT(9.510 53.652)",32.9,https://www.gem.wiki/Stade_LNG_Terminal
|
|
||||||
Alexandroupolis,"POINT(25.843 40.775)",16.7,https://www.gem.wiki/Alexandroupolis_LNG_Terminal
|
|
||||||
Shannon,"POINT(-9.442 52.581)",22.5,https://www.gem.wiki/Shannon_LNG_Terminal
|
|
||||||
Gothenburg,"POINT(11.948 57.702)",1.4,https://www.gem.wiki/Gothenburg_LNG_Terminal
|
|
||||||
Cork,"POINT(-8.323 51.831)",11.0,https://www.gem.wiki/Cork_LNG_Terminal
|
|
|
@ -19,14 +19,29 @@ def read_scigrid_gas(fn):
|
|||||||
return df
|
return df
|
||||||
|
|
||||||
|
|
||||||
def build_gas_input_locations(lng_fn, planned_lng_fn, entry_fn, prod_fn, countries):
|
def build_gem_lng_data(lng_fn):
|
||||||
|
df = pd.read_excel(lng_fn[0], sheet_name='LNG terminals - data')
|
||||||
|
df = df.set_index("ComboID")
|
||||||
|
|
||||||
|
remove_status = ['Cancelled']
|
||||||
|
remove_country = ['Cyprus','Turkey']
|
||||||
|
remove_terminal = ['Puerto de la Luz LNG Terminal', 'Gran Canaria LNG Terminal']
|
||||||
|
|
||||||
|
df = df.query("Status != 'Cancelled' \
|
||||||
|
& Country != @remove_country \
|
||||||
|
& TerminalName != @remove_terminal \
|
||||||
|
& CapacityInMtpa != '--'")
|
||||||
|
|
||||||
|
df.CapacityInMtpa = df.CapacityInMtpa.astype(float)
|
||||||
|
|
||||||
|
geometry = gpd.points_from_xy(df['Longitude'], df['Latitude'])
|
||||||
|
return gpd.GeoDataFrame(df, geometry=geometry, crs="EPSG:4326")
|
||||||
|
|
||||||
|
|
||||||
|
def build_gas_input_locations(lng_fn, entry_fn, prod_fn, countries):
|
||||||
|
|
||||||
# LNG terminals
|
# LNG terminals
|
||||||
lng = read_scigrid_gas(lng_fn)
|
lng = build_gem_lng_data(lng_fn)
|
||||||
planned_lng = pd.read_csv(planned_lng_fn)
|
|
||||||
planned_lng.geometry = planned_lng.geometry.apply(wkt.loads)
|
|
||||||
planned_lng = gpd.GeoDataFrame(planned_lng, crs=4326)
|
|
||||||
lng = pd.concat([lng, planned_lng], ignore_index=True)
|
|
||||||
|
|
||||||
# Entry points from outside the model scope
|
# Entry points from outside the model scope
|
||||||
entry = read_scigrid_gas(entry_fn)
|
entry = read_scigrid_gas(entry_fn)
|
||||||
@ -45,10 +60,11 @@ def build_gas_input_locations(lng_fn, planned_lng_fn, entry_fn, prod_fn, countri
|
|||||||
(prod.country_code != "DE")
|
(prod.country_code != "DE")
|
||||||
]
|
]
|
||||||
|
|
||||||
conversion_factor = 437.5 # MCM/day to MWh/h
|
mcm_per_day_to_mw = 437.5 # MCM/day to MWh/h
|
||||||
lng["p_nom"] = lng["max_cap_store2pipe_M_m3_per_d"] * conversion_factor
|
mtpa_to_mw = 1649.224 # mtpa to MWh/h
|
||||||
entry["p_nom"] = entry["max_cap_from_to_M_m3_per_d"] * conversion_factor
|
lng["p_nom"] = lng["CapacityInMtpa"] * mtpa_to_mw
|
||||||
prod["p_nom"] = prod["max_supply_M_m3_per_d"] * conversion_factor
|
entry["p_nom"] = entry["max_cap_from_to_M_m3_per_d"] * mcm_per_day_to_mw
|
||||||
|
prod["p_nom"] = prod["max_supply_M_m3_per_d"] * mcm_per_day_to_mw
|
||||||
|
|
||||||
lng["type"] = "lng"
|
lng["type"] = "lng"
|
||||||
entry["type"] = "pipeline"
|
entry["type"] = "pipeline"
|
||||||
@ -64,7 +80,7 @@ if __name__ == "__main__":
|
|||||||
if 'snakemake' not in globals():
|
if 'snakemake' not in globals():
|
||||||
from helper import mock_snakemake
|
from helper import mock_snakemake
|
||||||
snakemake = mock_snakemake(
|
snakemake = mock_snakemake(
|
||||||
'build_gas_import_locations',
|
'build_gas_input_locations',
|
||||||
simpl='',
|
simpl='',
|
||||||
clusters='37',
|
clusters='37',
|
||||||
)
|
)
|
||||||
@ -87,7 +103,6 @@ if __name__ == "__main__":
|
|||||||
|
|
||||||
gas_input_locations = build_gas_input_locations(
|
gas_input_locations = build_gas_input_locations(
|
||||||
snakemake.input.lng,
|
snakemake.input.lng,
|
||||||
snakemake.input.planned_lng,
|
|
||||||
snakemake.input.entry,
|
snakemake.input.entry,
|
||||||
snakemake.input.production,
|
snakemake.input.production,
|
||||||
countries
|
countries
|
||||||
|
Loading…
Reference in New Issue
Block a user