IAMconsortium / concordia

Apache License 2.0
0 stars 3 forks source link

reorganizing and adding docs #35

Closed gidden closed 3 months ago

gidden commented 5 months ago

Hey @coroa this PR does a few things

  1. it updates the config.yaml and workflow.py to streamline data locations, specifically requiring paths for history, scenarios (I see now it has proxies and gridding, maybe we want to further reduce this..)
  2. removes config.yaml from git tracking
  3. moves regionmapping information into the config.yaml and start to think about how to support running the workflows for multiple models/scenarios

I did a poor man's version of your path expansion to support configured paths in the region mapping, feel free to rip that apart.

Here's the version of my config I have on disk.

# Setting `base_path` redirects everything else from there
out_path: "../results"
data_path: "../data/rescue"

history_path: "$data_path/historical"
scenario_path: "$data_path/scenarios"
gridding_path: "$data_path/gridding_process_files"
proxy_path: "$data_path/gridding_process_files/proxy_rasters"
postprocess_path: "$data_path/postprocessing"

encoding:
  zlib: true
  complevel: 2

region_mappings:
  REMIND-MAgPIE 3.2.0-4.7.0: 
    path: "$data_path/regionmapping_remindmagpie_h12.csv"
    country_column: "CountryCode"
    region_column: "RegionCode"
    sep: ";"

country_combinations:
  sdn_ssd: ["ssd", "sdn"]
  isr_pse: ["isr", "pse"]
  srb_ksv: ["srb", "srb (kosovo)"]

variable_template: "CEDS+|9+ Sectors|Emissions|{gas}|{sector}"
base_year: 2020

luc_sectors:
  - "Agricultural Waste Burning"
  - "Grassland Burning"
  - "Forest Burning"
  - "Peat Burning"
  - "Agriculture"
  - "Aggregate - Agriculture and LUC"

Everything now lives in a single directory (data_path), which I can host on sharepoint (it's just copied over from our previous folder): ...\RESCUE - Documents\WP 1\data_2024_03_14

A next step would be to set up the gridding proxy and masks to write into these locations.

Let me know what you think!

gidden commented 5 months ago

@coroa 44d0911 implements file skipping. I noticed by the way that we not longer use aneris.grid()?

coroa commented 5 months ago

I noticed by the way that we not longer use aneris.grid()?

Yes. See also: https://github.com/iiasa/aneris/pull/64#issuecomment-1959884424

gidden commented 5 months ago

Got it, thanks!

gidden commented 5 months ago

This is good to go now, noting existing conflicts..

coroa commented 5 months ago

I rebased this on the latest changes on main and then added to fixup commits to stuff i'd have done differently

(for the path resolution for regionmappings and how to check for a single model)