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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix SOM cellpool #402

Merged
merged 1 commit into from
Jun 17, 2022
Merged

bugfix SOM cellpool #402

merged 1 commit into from
Jun 17, 2022

Conversation

flohump
Copy link
Contributor

@flohump flohump commented Jun 16, 2022

馃惁 Purpose of this PR 馃惁

  • the model was infeasible with cfg$gms$c56_emis_policy <- "sdp_soil" and cfg$gms$som <- "cellpool_aug16"
  • the reason for this was a missing equation in 59_som/cellpool_aug16 for the dimension actualNoAcEst in vm_carbon_stock. Therefore, this dimension was a free varialbe, causing the infeasiblity.
  • the missing equation has been added
  • the unused dimensions previousLandPattern and previousCarbonDensity in vm_carbon_stock have been removed in all parts of the model
  • No entry in changelog needed. Bugfix of unpublished code.

馃敡 Checklist for PR creator 馃敡

  • Low risk : Simple bugfixes (missing files, updated documentation, typos) or Start/output scripts
  • Medium risk : New realization / Changes to existing realization / Other changes which don't modify default.cfg
  • High risk : New input files (if cfg$input is changed in default.cfg) / Modification to core model (eg. changes in equations, calculations, introduction of new sets etc.) / Other changes in default.cfg
  • Providing additional information based on PR label
  • Low risk : No new model run needed.
  • Medium risk : Default run based on the current version of the fork from which PR is made
  • High risk
    • Default run from the current develop branch: PR402_curDev_SSP2-Ref
    • Default run based on the current version of the fork from which PR is made: PR402_thisPR_SSP2-Ref
  • 馃搲 Performance loss/gain from current default behavior 馃搱
    • Current develop branch default : 0.47 h
    • This PR's default : 0.39 h

newplot-10

Resources_Land_Cover_Cropland-71
Productivity_Landuse_Intensity_Indicator_Tau-60
Emissions_CO2_Land_Land_use_Change-52

Runs with CO2 price
Resources_Land_Cover_Cropland-72

  • Added changes to CHANGELOG.md
  • Compilation check (model starts without compilation errors - use gams main.gms action=c in model folder for testing).
  • No hard coded numbers and cluster/country/region names.
  • The new code doesn't contain declared but unused parameters or variables.
  • Where relevant, In-code comments added including documentation comments.
  • Made sure that documentation created with goxygen is okay (use goxygen::goxygen() for testing).
  • Changes to magpie4 R library for post processing of model output (ideally backward compatible).
  • Self-review of my own code.
  • For high risk runs: validation of major model indicators - Land-use, emissions, food prices, Tau. %Delete this line in case it is not a high risk run%

鈿狅笍 Additional notes or warnings 鈿狅笍

NA

馃毃 Checklist for RSE reviewer 馃毃

  • PR is labeled correctly.
  • CHANGELOG is updated correctly
  • No hard coded numbers and cluster/country/region names.
  • No unnecessary increase in module interfaces
  • All required updates in interfaces (if any) have been properly adressed in the module contracts
  • In-code comments and documentation comments are satisfactory.
  • model behavior/performance is satisfactory.
  • Requested changes (if any) were applied correctly

馃毃 Checklist for MAgPIE reviewer 馃毃

  • PR is labeled correctly.
  • CHANGELOG is updated correctly
  • No hard coded numbers and cluster/country/region names.
  • Changes to the model are scientifically sound
  • In-code comments and documentation comments are satisfactory.
  • model behavior/performance is satisfactory.
  • Requested changes (if any) were applied correctly

@flohump flohump added Minor Smaller modifications High risk Higher risk bugfix labels Jun 16, 2022
@flohump flohump marked this pull request as ready for review June 16, 2022 11:27
Copy link
Member

@FelicitasBeier FelicitasBeier left a comment

Choose a reason for hiding this comment

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

For as far as I can judge, it looks fine.
I would suggest Kristine as 59_som expert to also have a quick look, though, as well.
Just to make sure that previousLandPattern and previousCarbonDensity are indeed no longer required?

Copy link
Member

@k4rst3ns k4rst3ns left a comment

Choose a reason for hiding this comment

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

This makes all sense to me and resolve the problem with the unbound variable.

core/macros.gms Show resolved Hide resolved
@flohump flohump merged commit 75825f5 into magpiemodel:develop Jun 17, 2022
@flohump flohump deleted the f_402 branch January 28, 2023 15:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix High risk Higher risk Minor Smaller modifications
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants