Skip to content

Please trigger GHA#31

Open
tonnrueter wants to merge 3 commits intodev/ca_rework_pt1from
dev/deleteme_gha_change
Open

Please trigger GHA#31
tonnrueter wants to merge 3 commits intodev/ca_rework_pt1from
dev/deleteme_gha_change

Conversation

@tonnrueter
Copy link
Copy Markdown
Owner

@tonnrueter tonnrueter commented Apr 10, 2025

Purpose of this PR

First part of the reworking the REMIND climate assessment integration. Affects climate reporting via MAGICC7_AR6.R

  • Script has been consolidated using the remindClimateAssessment and piamenv packages

  • Python environment handling is done by piamenv::condaInit and piamenv::condaRun

    • Move towards conda run-based Python integration. This alleviates interference between R and Python environments
    • Init commands allow fine grained control of conda env activation
    • Only drawback so far in the new implementation is that logs are not printed linewise but dumped all at once
    • TODO (in a later PR): Archive Python run environment
    • TODO (in a later PR): Adapt scripts/input/climate_assessment_*.R to piamenv/remindClimateAssessment usage
  • remindClimateAssessment handles all aspects of setting up runs of IIASA's climate-assessment library

    • Features a configuration concept that absorbs the previously tedious file name record keeping. List climateAssessmentConfig contains all directories and file names relevant to set up a climate assessment run
    • Run time reporting for various parts of the script was implemented by storing run times in a named vector. reportRunTimes generates a report and attaches it to the log file
    • Write climate assessment parameters to gdx via remindClimateAssessment::dumpToGdx
    • Relies on config files to associate climate assessment variables. gdx filenames and REMIND/GAMS variables names
    • remindClimateAssessment::archiveClimateAssessmentData stores climate assessment data of a particular run in a tar archive

Type of change

Indicate the items relevant for your PR by replacing ◻️ with ☑️.
Do not delete any lines. This makes it easier to understand which areas are affected by your changes and which are not.

Parts concerned

  • ◻️ GAMS Code
  • ☑️ R-scripts
  • ☑️ Documentation (GAMS incode documentation, comments, tutorials)
  • ◻️ Input data / CES parameters
  • ◻️ Tests, CI/CD (continuous integration/deployment)
  • ◻️ Other (please give a description)

Impact

  • ◻️ Bug fix
  • ☑️ Refactoring
  • ◻️ New feature
  • ◻️ Change of parameter values or input data (including CES parameters)
  • ◻️ Minor change (default scenarios show only small differences)
  • ◻️ Fundamental change of results of default scenarios

Checklist

Do not delete any line. Leave unfinished elements unchecked so others know how far along you are.
In the end all checkboxes must be ticked before you can merge
.

  • I executed the automated model tests (make test) after my final commit and all tests pass (FAIL 0)
  • I adjusted the reporting in remind2 if and where it was needed
  • My code follows the coding etiquette
  • I explained my changes within the PR, particularly in hard-to-understand areas
  • I checked that the in-code documentation is up-to-date
  • I adjusted forbiddenColumnNames in readCheckScenarioConfig.R in case the PR leads to deprecated switches
  • I updated the CHANGELOG.md correctly (added, changed, fixed, removed, input data/calibration)

Further information (optional)

  • Runs with these changes are here:
    • /p/tmp/tonnru/remind/output/SSP2-NPi2025_2025-04-04_19.32.43
  • Comparison of results (what changes by this PR?):

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.

1 participant