Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions src/gcages/cmip7_scenariomip/pre_processing/pre_processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,9 +356,22 @@ def species_in_variable(variable: str, species: str, ls: str) -> bool:
# Can't use these yet
# TODO: implement support for baskets
global_workflow_emissions_not_from_gridding_emissions = global_workflow_emissions_not_from_gridding_emissions.loc[ # noqa: E501
~global_workflow_emissions_not_from_gridding_emissions.index.get_level_values(
unit_level
).str.contains("equiv")
(
# baskets, like Kyoto Gases (or F-Gases):
~global_workflow_emissions_not_from_gridding_emissions.index.get_level_values(
unit_level
).str.contains("equiv")
)
& (
# Carbon Removal|* may have been renamed to Carbon Removal|CO2|*,
# - that's why the variable may still be here (as it is not gridded)
# - but we still do not want it in the global workflow (that
# ... would be double-counting) so we drop it here
# TODO: drop this earlier already
~global_workflow_emissions_not_from_gridding_emissions.index.get_level_values(
variable_level
).str.contains("Carbon Removal")
)
]

global_workflow_emissions_raw_names = pd.concat(
Expand Down