Skip to content

Commit

Permalink
Merge pull request #930 from openego/features/#929-H2-carrier-name
Browse files Browse the repository at this point in the history
Harmonize H2 carrier name - eGon100RE
  • Loading branch information
ClaraBuettner authored Jun 28, 2023
2 parents 5d805f5 + dcf742c commit 0cdf157
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -458,6 +458,8 @@ Changed
`#882 <https://github.com/openego/eGon-data/issues/882>`_
* Insert crossboarding gas pipeline with Germany in eGon100RE
`#881 <https://github.com/openego/eGon-data/issues/881>`_
* Harmonize H2 carrier names in eGon100RE
`#929 <https://github.com/openego/eGon-data/issues/929>`_
* Rename noflex to lowflex scenario for motorized individual travel
`#921 <https://github.com/openego/eGon-data/issues/921>`_
* Update creation of heat demand timeseries
Expand Down
2 changes: 1 addition & 1 deletion src/egon/data/datasets/gas_neighbours/eGon100RE.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ def define_DE_crossbording_pipes_geom_eGon100RE(scn_name="eGon100RE"):
f"""
SELECT * FROM grid.egon_etrago_bus
WHERE scn_name = 'eGon100RE'
AND carrier = '{carrier}'
AND carrier = '{carrier_bus_DE}'
AND country != 'DE'
""",
epsg=4326,
Expand Down
17 changes: 7 additions & 10 deletions src/egon/data/datasets/gas_neighbours/gas_abroad.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,7 @@ def insert_gas_grid_capacities(Neighbouring_pipe_capacities_list, scn_name):
"""
)

carriers = {
"CH4": {"bus_inDE": "CH4", "bus_abroad": "CH4"},
"H2_retrofit": {"bus_inDE": "H2_grid", "bus_abroad": "H2"},
}
carriers = {"CH4": "CH4", "H2_retrofit": "H2_grid"}

if scn_name == "eGon100RE":
for c in carriers:
Expand All @@ -78,27 +75,27 @@ def insert_gas_grid_capacities(Neighbouring_pipe_capacities_list, scn_name):
SELECT bus_id FROM
{sources['buses']['schema']}.{sources['buses']['table']}
WHERE country != 'DE'
AND carrier = '{carriers[c]["bus_abroad"]}'
AND carrier = '{carriers[c]}'
AND scn_name = '{scn_name}')
AND "bus1" IN (SELECT bus_id FROM
{sources['buses']['schema']}.{sources['buses']['table']}
WHERE country = 'DE'
AND carrier = '{carriers[c]["bus_inDE"]}'
AND carrier = '{carriers[c]}'
AND scn_name = '{scn_name}'))
OR ("bus0" IN (
SELECT bus_id FROM
{sources['buses']['schema']}.{sources['buses']['table']}
WHERE country = 'DE'
AND carrier = '{carriers[c]["bus_inDE"]}'
AND carrier = '{carriers[c]}'
AND scn_name = '{scn_name}')
AND "bus1" IN (
AND "bus1" IN (
SELECT bus_id FROM
{sources['buses']['schema']}.{sources['buses']['table']}
WHERE country != 'DE'
AND carrier = '{carriers[c]["bus_abroad"]}'
AND carrier = '{carriers[c]}'
AND scn_name = '{scn_name}'))
AND scn_name = '{scn_name}'
AND carrier = '{c.index}'
AND carrier = '{c}'
;
"""
)
Expand Down
1 change: 1 addition & 0 deletions src/egon/data/datasets/pypsaeursec/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -609,6 +609,7 @@ def neighbor_reduction():
{
"gas": "CH4",
"gas_for_industry": "CH4_for_industry",
"H2": "H2_grid",
},
inplace=True,
)
Expand Down

0 comments on commit 0cdf157

Please sign in to comment.