Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix in HalfEarth Scenario: Synchronization until 2020 with WDPA protection scenario #241

Merged
merged 9 commits into from
Jan 18, 2021

Conversation

FelicitasBeier
Copy link
Member

@FelicitasBeier FelicitasBeier commented Jan 13, 2021

Please fill following information
(Add additional info if you think its important and not covered by this Pull Request (PR)):

Purpose of this PR

  • bugfix: synchronize HalfEarth scenario with WDPA until 2020, so that scenarios only diverge after 2020

Performance loss/gain from current default behavior

newplot

  • performance gain = 0.623352/0.6361311 = 0.9799
  • like already noted when the HalfEarth Scenario was introduced the first time: runtime is even a bit faster compared to default (WDPA protection)

Type of change

  • Bug fix (Change which fixes an issue).
  • New feature (Change which adds functionality).
  • Minor change (Change which does not modify core model code i.e., in /modules).
  • Major change (fix or feature that would change current model behavior).

How Has This Been Tested?

  • Runs using starting script which tests current defaults (using test_runs.R).
  • Runs using starting script which successfully runs the same scenarios as in test_runs.R but with the changes from PR.
  • (If applicable) Runs using different scenarios/mappings which are not the default (12 regions/c200 clusters).

Additions or Changes to default configuration (default.cfg):

no additions required

Changes are deletion or updates to the existing model components in default config

  • Realizations:
  • Scenario switches:
  • Scalars/Constants:
  • Model interfaces:
  • Others: only change in presolve (synchronize data before 2020)

Checklist:

  • Self-review of my own code.
  • Compilation check (model starts without compilation errors).
  • Added changes to CHANGELOG.md (I think this is not required, since it was only a bugfix, right?)
  • No hard coded numbers and cluster/country/region names.
  • The code doesn't contain declared but unused parameters or variables.
  • In-code comments added including documentation comments.
  • Compiled and checked resulting documentation with goxygen::goxygen() for the new/updated parts.
  • [] Changes to magpie4 R library for post processing of model output (ideally backward compatible).

Special comments/warnings

  • Notes: It was only an adjustment when the HalfEarth protection kicks in

Copy link
Member

@abhimishr abhimishr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks fine to me. So WDPA is active till 2020 and then additional protection after 2020 with half-earth (WDPA+something). I'll approve it but would recommend waiting until @flohump also approves it.

@FelicitasBeier
Copy link
Member Author

UPDATE: The HalfEarth scenario now fades in until 2050.
Also: Code-cleanup of the interest fader (now read in as csv instead of hard-coded section in the code)

Copy link
Contributor

@flohump flohump left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One issue needs to be resolved in presolve line 76

modules/35_natveg/dynamic_may20/presolve.gms Outdated Show resolved Hide resolved
@flohump flohump merged commit f8b2777 into magpiemodel:develop Jan 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants