diff --git a/CHANGELOG.md b/CHANGELOG.md index bb93209f9..880d6db24 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). - **inputs** update of landuse emissions and costs using MAgPIE 4.6.8, mrcommons 1.32.0, input data rev6.543 - **scripts** MAgPIE coupling interface: replace old MAgPIE cost variable - **scripts** MAgPIE coupling interface: remove filtering of negative LU emissions +- **scripts** `./start.R --gamscompile` now adjust sets and gets input data - **core** MAgPIE coupling: tolerate negative values for `n2ofertsom` and deactivate its MAC - **05_initialCap** fix overwriting of investment cost changes from cm_inco0Factor switch diff --git a/config/21_regions_EU11/scenario_config_21_EU11_ECEMF.csv b/config/21_regions_EU11/scenario_config_21_EU11_ECEMF.csv index 5fbf3d41c..715048b4d 100644 --- a/config/21_regions_EU11/scenario_config_21_EU11_ECEMF.csv +++ b/config/21_regions_EU11/scenario_config_21_EU11_ECEMF.csv @@ -1,83 +1,83 @@ title;start;cm_implicitQttyTarget;cm_loadFromGDX_implicitQttyTargetTax;cm_implicitPriceTarget;cm_implicitPePriceTarget;cm_VREminShare;cm_nucscen;c_regi_nucscen;cm_vehiclesSubsidies;cm_incolearn;cm_inco0Factor;cm_learnRate;cm_calibration_string;cm_calibration_FE;regipol;cm_emiMktTarget;cm_NucRegiPol;cm_CoalRegiPol;cm_altFeEmiFac;cm_regiExoPrice;optimization;c_testOneRegi_region;cm_nash_mode;c_keep_iteration_gdxes;cm_abortOnConsecFail;transport;cm_EDGEtr_scen;industry;CES_parameters;regionmapping;extramappings_historic;cm_rcp_scen;cm_iterative_target_adj;subsidizeLearning;c_budgetCO2from2020;carbonprice;cm_co2_tax_2020;cm_peakBudgYr;cm_emiscen;c_tech_earlyreti_rate;techpol;cm_multigasscen;water;cm_startyear;path_gdx;path_gdx_ref;path_gdx_bau;path_gdx_refpolicycost;description -_____Default_runs_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____Default_runs_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; SSP2EU-EU21-calibrate;0;;;;;;;;;;;;;;;;;;;;;;;;;;Mix1;;calibrate;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;;;;0;;;2100;;off;none;2;heat;2005;;;;;SSP2EU-calibration: This baseline scenario follows the Shared Socioeconomic Pathways 2 called Middle of the Road. SSP2EU-EU21-Base;0;;;;;;;;;;;;;;;;;;;;;;;;;;Mix1;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;;;;0;;;2100;;off;none;2;heat;2005;;;;;SSP2EU-Base: This baseline calibration scenario follows the Shared Socioeconomic Pathways 2 called Middle of the Road. SSP2EU-EU21-NDC;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450;on;on;EUR_regi, NEU_regi;;;;;;;;Mix2;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;globallyOptimal;0;NDC;1;2100;9;;NDC;3;heat;2015;;SSP2EU-Base;SSP2EU-Base;;SSP2EU-NDC: This Nationally Determined Contribution (NDC) scenario follows the Shared Socioeconomic Pathways 2 called Middle of the Road. The NDC includes all pledged policies even if not yet implemented. It assumes that the moderate and heterogeneous climate ambition reflected in the NDCs at the begining of 2021 continues over the 21st century. This scenario serves as reference for all other policy scenarios and The NPi scenario until 2020. SSP2EU-EU21-NPi;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 3.266;on;on;EUR_regi, NEU_regi;;;;;;;;Mix1;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;1;2100;9;;NPi2018;3;heat;2025;;SSP2EU-NDC;SSP2EU-Base;;SSP2EU-NPi: This National Policies Implemented (Npi) scenario follows the Shared Socioeconomic Pathways 2 called Middle of the Road. The NPi is identical to the NDC scenario until 2020 but assumes that policies fail to achieve NDC targets in 2030. Instead, carbon prices are assumed to grow and converge more slowly, leading to emissions trajectories in line with bottom-up studies on the effect of currently implemented policies. SSP2EU-EU21-PkBudg500;0;;;;;;;;;;;;;;;;;;;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;500;diffCurvPhaseIn2Lin;100;2080;9;;NDC;2;heat;2025;;SSP2EU-NDC;SSP2EU-Base;;SSP2EU-PkBudg500: This climate policy scenario follows the Shared Socioeconomic Pathways 2 called Middle of the Road. The stylized climate policy scenario assumes a peak budget of 500 Gt?CO2 on total CO2 emissions from 2015 to 2100. This is a 1.5??C scenario, peak warming is allowed to be at or slightly above 1.5??C, at median climate sensitivity but returns to values below 1.5??C in at least 67?% of scenarios by the end of the century. SSP2EU-EU21-PkBudg1150;0;;;;;;;;;;;;;;;;;;;;;;;;;;Mix3;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;9;globallyOptimal;1150;diffCurvPhaseIn2Lin;60;2100;9;;NDC;2;heat;2025;;SSP2EU-NDC;SSP2EU-Base;;SSP2EU-PkBudg1150: This climate policy scenario follows the Shared Socioeconomic Pathways 2 called Middle of the Road. The stylized climate policy scenario assumes a peak budget of 1150 Gt?CO2 on total CO2 emissions from 2015 to 2100. This is a weel below 2??C scenario, peak warming is allowed to be at or slightly above 2??C, at median climate sensitivity but returns to values below 2??C in at least 67?% of scenarios by the end of the century. -________REMIND_3p0p0________;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -_____Calibration_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# ________REMIND_3p0p0________;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____Calibration_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_Calib;0;;;;;;;;;;;;;;;;;;EUR_regi, NEU_regi;;;;;;;;Mix1;;calibrate;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;;;;0;;;;;;none;;heat;2005;;;;; -_____default_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____default_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_DIAG-Base;0;;;;;;;;;;;;;;;;;;EUR_regi, NEU_regi;;;;;;;;Mix1;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;;;;0;;;2100;;;none;;heat;2005;;;;; xx_DIAG-NPI;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 3.266;on;on;EUR_regi, NEU_regi;;;;;;;;Mix1;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;1;2100;9;;NPi2018;3;heat;2015;xx_DIAG-Base;xx_DIAG-Base;xx_DIAG-Base;; -_____pure_carbon_pricing_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____pure_carbon_pricing_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_DIAG-C80-gr5;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 34,2030 44,2035 56,2040 71,2045 91,2050 116,2055 148,2060 190,2070 309,2080 503,2090 819,2100 1334,2110 1334,2130 1334,2150 1334);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-NPI;xx_DIAG-NPI;xx_DIAG-Base;; xx_DIAG-C0to80-gr5;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 0.001,2030 0.001,2035 0.001,2040 71,2045 91,2050 116,2055 148,2060 190,2070 309,2080 503,2090 819,2100 1334,2110 1334,2130 1334,2150 1334);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-NPI;xx_DIAG-NPI;xx_DIAG-Base;; xx_DIAG-C400-lin;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-NPI;xx_DIAG-NPI;xx_DIAG-Base;; -_____NZero_DIAG_scenario_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____NZero_DIAG_scenario_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_DIAG-NZero;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2050.EU27_regi.all.year.netGHG_LULUCFGrassi 0.01, 2020.2050.UKI.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; -_____C400-lin_tech_constraint_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____C400-lin_tech_constraint_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_DIAG-C400-lin-LimBio;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.PE.biomass 3.17,2050.EUR_regi.tax.t.PE.biomass 0.22;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-LimCCS;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.CCS.all 2000, 2050.EUR_regi.tax.t.CCS.all 250;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-LimNuclear;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;5;ENC,EWN,ECS,ESC,ECE,FRA,DEU,UKI,ESW;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; -_____C400-lin_DIAG_paradigm_shift_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____C400-lin_DIAG_paradigm_shift_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_DIAG-C400-lin-HighVRE;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;2050.EUR_regi 0.7;;;;wind 2300, windoff 4700, spv 5060;;wind 0.9, windoff 0.9, spv 0.9;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-HighElectrification;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;elecPrice;;;;;;;;wind 0.820125, windoff 0.91125, spv 0.95;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-HighElec-Supply;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916, 2050.EUR_regi.sub.t.SE.electricity 0.913;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-HighH2;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;H2Price;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-ResidualFossil;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;highFossilPrice;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; xx_DIAG-C400-lin-HighEff;0;2050.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 0.698;on;;;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; -_____NZero_scenario_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____NZero_scenario_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_WP1_NDC;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450;on;on;EUR_regi, NEU_regi;;;;;;;;Mix2;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;globallyOptimal;0;NDC;1;2100;9;;NDC;3;heat;2015;xx_DIAG-Base;xx_DIAG-Base;xx_DIAG-Base;; xx_WP1_NPI;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 3.266;on;on;EUR_regi, NEU_regi;;;;;;;;Mix1;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;1;2100;9;;NPi2018;3;heat;2015;xx_DIAG-Base;xx_DIAG-Base;xx_DIAG-Base;; xx_WP1_Nzero;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_NPI;xx_WP1_NPI;xx_DIAG-Base;; xx_EMFECEMF_Nzero;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01, 2020.2050.USA.all.year.netCO2 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_NPI;xx_WP1_NPI;xx_DIAG-Base;; -_____NZero_tech_constraint_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____NZero_tech_constraint_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_WP1_NZero-LimBio;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.PE.biomass 3.17,2050.EUR_regi.tax.t.PE.biomass 0.22;on;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_NPI;xx_WP1_NPI;xx_DIAG-Base;; xx_WP1_NZero-LimCCS;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.CCS.all 2000, 2050.EUR_regi.tax.t.CCS.all 250;on;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_NPI;xx_WP1_NPI;xx_DIAG-Base;; xx_WP1_NZero-LimNuclear;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;5;ENC,EWN,ECS,ESC,ECE,FRA,DEU,UKI,ESW;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_NPI;xx_WP1_NPI;xx_DIAG-Base;; -_____other_NZero_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____other_NZero_scenarios_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_WP1_Nzero_noBunkers;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi_noBunkers 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi_noBunkers 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_Nzero;xx_WP1_Nzero;xx_DIAG-Base;; xx_WP1_Nzero_netGHG;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG 2.450, 2035.2050.EUR_regi.all.year.netGHG 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_Nzero;xx_WP1_Nzero;xx_DIAG-Base;; xx_WP1_Nzero_netGHG_2050;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2050.EUR_regi.all.year.netGHG 0.01;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_Nzero;xx_WP1_Nzero;xx_DIAG-Base;; -_____tests_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____tests_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_WP1_NDC_debug;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;;;;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450;on;on;EUR_regi, NEU_regi;;;;debug;1;1;;Mix2;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;globallyOptimal;0;NDC;1;2100;9;;NDC;3;heat;2015;xx_DIAG-Base;xx_DIAG-Base;xx_DIAG-Base;; EWN_DIAG-C400-lin-ResidualFossil_debug;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;highFossilPrice;;;;;;;;;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);testOneRegi;EWN;debug;1;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_DIAG-C400-lin;xx_DIAG-C400-lin;xx_DIAG-Base;; -________REMIND_3p0p0_cplx________;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -_____Calibration_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# ________REMIND_3p0p0_cplx________;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____Calibration_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_Calib_FE_med;0;;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;medium;;;;;EUR_regi, NEU_regi;;;;;;;complex;Mix1;fixed_shares;calibrate;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;;;;0;;;;;;none;;heat;2005;;;;; -_____default_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____default_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_DIAG-Base;0;;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;;;;;EUR_regi, NEU_regi;;;;;;;complex;Mix1;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;;;;0;;;2100;;;none;;heat;2005;;;;; xx_cplx_DIAG-NPI;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 3.266;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix1;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;1;2100;9;;NPi2018;3;heat;2015;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;; xx_cplx_DIAG-NPI_old;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.676;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;EUR_regi.(2015 4,2020 16,2025 41,2030 41,2035 41,2040 41,2045 41,2050 41,2055 41,2060 41,2070 41,2080 41,2090 41,2100 41,2110 41,2130 41,2150 41);;;;;;complex;Mix1;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;;2100;9;;NPi2018;3;heat;2015;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;; -_____pure_carbon_pricing_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____pure_carbon_pricing_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_DIAG-C80-gr5;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 34,2030 44,2035 56,2040 71,2045 91,2050 116,2055 148,2060 190,2070 309,2080 503,2090 819,2100 1334,2110 1334,2130 1334,2150 1334);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-NPI;xx_cplx_DIAG-NPI;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C0to80-gr5;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 0.001,2030 0.001,2035 0.001,2040 71,2045 91,2050 116,2055 148,2060 190,2070 309,2080 503,2090 819,2100 1334,2110 1334,2130 1334,2150 1334);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-NPI;xx_cplx_DIAG-NPI;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp26;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-NPI;xx_cplx_DIAG-NPI;xx_cplx_DIAG-Base;; -_____NZero_DIAG_scenario_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____NZero_DIAG_scenario_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_DIAG-NZero;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2050.EU27_regi.all.year.netGHG_LULUCFGrassi 0.01, 2020.2050.UKI.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; -_____C400-lin_tech_constraint_scenarios_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____C400-lin_tech_constraint_scenarios_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_DIAG-C400-lin-LimBio;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.PE.biomass 3.17,2050.EUR_regi.tax.t.PE.biomass 0.22;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-LimCCS;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.CCS.all 2000, 2050.EUR_regi.tax.t.CCS.all 250;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-LimNuclear;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;5;ENC,EWN,ECS,ESC,ECE,FRA,DEU,UKI,ESW;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; -_____C400-lin_DIAG_paradigm_shift_scenarios_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____C400-lin_DIAG_paradigm_shift_scenarios_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_DIAG-C400-lin-HighVRE;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;2050.EUR_regi 0.7;;;;wind 2300, windoff 4700, spv 5060;apcardiEfft 0.8, apcardiEffH2t 0.675;wind 0.9, windoff 0.9, spv 0.9;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-HighElectrification;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;elecPrice;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;wind 0.820125, windoff 0.91125, spv 0.95;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-HighElec-Supply;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916, 2050.EUR_regi.sub.t.SE.electricity 0.913;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-HighH2;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;H2Price;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-ResidualFossil;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;highFossilPrice;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; xx_cplx_DIAG-C400-lin-HighEff;0;2050.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 0.698;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;;on;on;EUR_regi, NEU_regi;GLO.(2025 116,2030 196,2035 277,2040 357,2045 438,2050 518,2055 598,2060 679,2070 839,2080 1000,2090 1161,2100 1321,2110 1321,2130 1321,2150 1321);;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;;globallyOptimal;0;;;;9;;NDC;;heat;2025;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-C400-lin;xx_cplx_DIAG-Base;; -_____NZero_scenario_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____NZero_scenario_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_WP1_NDC;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix2;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;globallyOptimal;0;NDC;1;2100;9;;NDC;3;heat;2015;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;; xx_cplx_WP1_NPI_default;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 3.266;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix1;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;1;2100;9;;NPi2018;3;heat;2015;xx_cplx_WP1_NDC;xx_cplx_WP1_NDC;xx_cplx_DIAG-Base;; xx_cplx_WP1_NPI;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.2809;;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 3.266;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix1;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp45;3;;0;NPi2018;1;2100;9;;NPi2018;3;heat;2015;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;xx_cplx_DIAG-Base;; xx_cplx_WP1_Nzero;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_cplx_WP1_NPI;xx_cplx_WP1_NPI;xx_cplx_DIAG-Base;; xx_cplx_EMFECEMF_Nzero;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01, 2020.2050.USA.all.year.netCO2 0.01;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_cplx_WP1_NPI;xx_cplx_WP1_NPI;xx_cplx_DIAG-Base;; -_____NZero_tech_constraint_scenarios_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# _____NZero_tech_constraint_scenarios_cplx_____;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; xx_cplx_WP1_NZero-LimBio;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.PE.biomass 3.17,2050.EUR_regi.tax.t.PE.biomass 0.22;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_cplx_WP1_NPI;xx_cplx_WP1_NPI;xx_cplx_DIAG-Base;; xx_cplx_WP1_NZero-LimCCS;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916,2050.GLO.tax.t.CCS.all 2000, 2050.EUR_regi.tax.t.CCS.all 250;on;;;;;;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_cplx_WP1_NPI;xx_cplx_WP1_NPI;xx_cplx_DIAG-Base;; xx_cplx_WP1_NZero-LimNuclear;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;5;ENC,EWN,ECS,ESC,ECE,FRA,DEU,UKI,ESW;;;apcardiEfft 0.8, apcardiEffH2t 0.675;;FE_med;;regiCarbonPrice;2020.2030.EUR_regi.all.year.netGHG_LULUCFGrassi 2.450, 2035.2050.EUR_regi.all.year.netGHG_LULUCFGrassi 0.01;on;on;EUR_regi, NEU_regi;;;;;;;complex;Mix4;fixed_shares;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_cplx_WP1_NPI;xx_cplx_WP1_NPI;xx_cplx_DIAG-Base;; -__NGFS_test;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +# __NGFS_test;0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; NGFS;0;2030.EUR_regi.tax.t.FE_wo_b_wo_n_e.all 1.1916;on;;;;;;;;;;;;regiCarbonPrice;2020.2050.(CAZ,EUR_regi,JPN,USA).all.year.netGHG 0.001, 2020.2060.(CHA,REF).all.year.netGHG 0.001, 2020.2070.IND.all.year.netCO2 0.001;on;on;EUR_regi, NEU_regi;;;;;;;;Mix4;;;./config/21_regions_EU11/regionmapping_21_EU11.csv;./config/21_regions_EU11/extramapping_EU27.csv;rcp20;9;globallyOptimal;650;diffCurvPhaseIn2Lin;100;2080;9;;NDC;;heat;2025;xx_WP1_Nzero;xx_WP1_Nzero;xx_DIAG-Base;; diff --git a/core/sets.gms b/core/sets.gms index 1cc44b79f..6e0d7cf63 100755 --- a/core/sets.gms +++ b/core/sets.gms @@ -741,7 +741,7 @@ teEs(all_teEs) "ES technologies which are actually used (to be filled ***######################## R SECTION START (SETS) ############################### *** THIS CODE IS CREATED AUTOMATICALLY, DO NOT MODIFY THESE LINES DIRECTLY *** ANY DIRECT MODIFICATION WILL BE LOST AFTER NEXT INPUT DOWNLOAD -*** CHANGES CAN BE DONE USING THE RESPECTIVE LINES IN scripts/start/prepare.R +*** CHANGES CAN BE DONE USING THE RESPECTIVE LINES IN scripts/start/updateSets.R sets diff --git a/main.gms b/main.gms index 234fcc629..e6b1e3f85 100755 --- a/main.gms +++ b/main.gms @@ -156,11 +156,12 @@ *' ; *' param_name = 0; !! def = 0 !! regexp = 0|1 *' -------- -*' * The value behind 'def' contains the default value and is added only for the user to remember if changed manually -*' * The value behind regexp is read by scripts/start/checkFixCfg.R to check the validity of the input. +*' * def shows the default value, which is added only for the user to remember if changed manually +*' * regexp is optional, the value is read by scripts/start/checkFixCfg.R to check the validity of the input. *' In this case, it checks whether the value fits this regular expression: ^(0|1)$ *' Use 'value1|value2' for specific values, use '[1-7]' for a row of integers. -*' Two shortcut are defined: use 'is.numeric' for numeric values and 'is.share' if the value must be >= 0 and <= 1 +*' Three shortcut are defined: use 'is.numeric' for numeric values, 'is.nonnegative' for >= 0, +*' and 'is.share' if the value must be >= 0 and <= 1 *' *' *' #### Other general rules: @@ -502,7 +503,7 @@ parameter parameter cm_co2_tax_2020 "level of co2 tax in year 2020 in $ per t CO2eq, makes sense only for emiscen eq 9 and 45_carbonprice exponential" ; - cm_co2_tax_2020 = -1; !! def = -1 !! regexp = is.numeric + cm_co2_tax_2020 = -1; !! def = -1 !! regexp = -1|is.nonnegative *' * (-1): default setting equivalent to no carbon tax *' * (any number >= 0): tax level in 2020, with 5% exponential increase over time *' @@ -1137,7 +1138,7 @@ parameter *' *' * (off): off = REMIND expects to be run standalone (emission factors are used, shiftfactors are set to zero) *' * (on): on = REMIND expects to be run based on a MAgPIE reporting file (emission factors are set to zero because emissions are retrieved from the MAgPIE reporting, shift factors for supply curves are calculated) -$setglobal cm_MAgPIE_coupling off !! def = "off" !! regexp = on|off +$setglobal cm_MAgPIE_coupling off !! def = "off" !! regexp = off|on *' cm_rcp_scen "chooses RCP scenario" *' *' * (none): no RCP scenario, standard setting @@ -1193,7 +1194,7 @@ $setglobal cm_tradbio_phaseout default !! def = default !! regexp = default|f *** (off): (default) no bound *** (100): (e.g.) set maximum to 100 EJ per year *** (any value ge 0): set maximum to that value -$setglobal cm_maxProdBiolc off !! def = off !! regexp = off|is.numeric +$setglobal cm_maxProdBiolc off !! def = off !! regexp = off|is.nonnegative *** cm_bioprod_regi_lim *** limit to total biomass production (including residues) by region to an upper value in EJ/yr from 2035 on *** example: "CHA 20, EUR_regi 7.5" limits total biomass production in China to 20 EJ/yr and @@ -1202,7 +1203,7 @@ $setglobal cm_maxProdBiolc off !! def = off !! regexp = off|is.numeric *** If you specify a value for a region within a region group (e.g. DEU in EU27_regi), *** then the values from the region group disaggregation will be overwritten by this region-specific value. *** For example: "EU27_regi 7.5, DEU 1.5". -$setGLobal cm_bioprod_regi_lim off !! def off +$setGLobal cm_bioprod_regi_lim off !! def off *** cm_POPscen "Population growth scenarios from UN data and IIASA projection used in SSP" *** pop_SSP1 "SSP1 population scenario" *** pop_SSP2 "SSP2 population scenario" diff --git a/scripts/start/checkFixCfg.R b/scripts/start/checkFixCfg.R index 5249a5d34..bd8742e76 100644 --- a/scripts/start/checkFixCfg.R +++ b/scripts/start/checkFixCfg.R @@ -22,11 +22,14 @@ checkFixCfg <- function(cfg, remindPath = ".", testmode = FALSE) { code <- system(paste0("grep regexp ", file.path(remindPath, "main.gms")), intern = TRUE) # this is used to replace all 'regexp = is.numeric' grepisnum <- "((\\+|-)?[0-9]*([0-9]\\.?|\\.?[0-9])[0-9]*)" + grepisnonnegative <- "(\\+?[0-9]*([0-9]\\.?|\\.?[0-9])[0-9]*)" grepisshare <- "(\\+?0?\\.[0-9]+|0|0\\.0*|1|1\\.0*)" # some simple tests if (testmode) { stopifnot(all( grepl(paste0("^", grepisnum, "$"), c("2", "2.2", "32.", "+32.", "+.05", "-0.5", "-.5", "-5", "-7.")))) stopifnot(all(! grepl(paste0("^", grepisnum, "$"), c("2.2.", "0a", "1e1", ".2.", "ab", "2.3a", "--a", "++2")))) + stopifnot(all( grepl(paste0("^", grepisnonnegative, "$"), c("2", "2.2", "32.", "+32.", "+.05")))) + stopifnot(all(! grepl(paste0("^", grepisnonnegative, "$"), c("2.2.", "0a", "1e1", ".2.", "ab", "2.3a", "--a", "++2", "-0.5", "-.5", "-5", "-7.")))) stopifnot(all( grepl(paste0("^", grepisshare, "$"), c("0", "0.0", ".000", "1.0", "1.", "1", "0.12341234")))) stopifnot(all(! grepl(paste0("^", grepisshare, "$"), c("1.1", "-0.3", "-0", ".")))) } @@ -42,6 +45,7 @@ checkFixCfg <- function(cfg, remindPath = ".", testmode = FALSE) { regexp <- paste0("^(", trimws(gsub("!!.*", "", gsub("^.*regexp[ ]*=", "", filtered))), ")$") # replace is.numeric by pattern defined above useregexp <- gsub("is.numeric", grepisnum, regexp, fixed = TRUE) + useregexp <- gsub("is.nonnegative", grepisnonnegative, useregexp, fixed = TRUE) useregexp <- gsub("is.share", grepisshare, useregexp, fixed = TRUE) # check whether parameter value fits regular expression if (! grepl(useregexp, cfg$gms[[n]])) { diff --git a/scripts/start/prepare.R b/scripts/start/prepare.R index a39320837..57d328000 100644 --- a/scripts/start/prepare.R +++ b/scripts/start/prepare.R @@ -120,15 +120,6 @@ prepare <- function() { create_input_for_45_carbonprice_exogenous(as.character(cfg$files2export$start["input_carbonprice.gdx"])) } - cfg$gms$cm_CES_configuration <- calculate_CES_configuration(cfg) - - # write name of corresponding CES file to datainput.gms - replace_in_file(file = "./modules/29_CES_parameters/load/datainput.gms", - content = paste0('$include "', - "./modules/29_CES_parameters/load/input/", - cfg$gms$cm_CES_configuration, ".inc\""), - subject = "CES INPUT") - # If a path to a MAgPIE report is supplied use it as REMIND input (used for REMIND-MAgPIE coupling) # ATTENTION: modifying gms files if (!is.null(cfg$pathToMagpieReport)) { @@ -169,99 +160,9 @@ prepare <- function() { replace_in_file(tmpModelFile, paste("*", content), subject) } - update_sets <- function(map) { - .tmp <- function(x,prefix="", suffix1="", suffix2=" /", collapse=",", n=10) { - content <- NULL - tmp <- lapply(split(x, ceiling(seq_along(x)/n)),paste,collapse=collapse) - end <- suffix1 - for(i in 1:length(tmp)) { - if(i==length(tmp)) end <- suffix2 - content <- c(content,paste0(' ',prefix,tmp[[i]],end)) - } - return(content) - } - modification_warning <- c( - '*** THIS CODE IS CREATED AUTOMATICALLY, DO NOT MODIFY THESE LINES DIRECTLY', - '*** ANY DIRECT MODIFICATION WILL BE LOST AFTER NEXT INPUT DOWNLOAD', - '*** CHANGES CAN BE DONE USING THE RESPECTIVE LINES IN scripts/start/prepare.R') - content <- c(modification_warning,'','sets') - # create iso set with nice formatting (10 countries per line) - tmp <- lapply(split(map$CountryCode, ceiling(seq_along(map$CountryCode)/10)),paste,collapse=",") - regions <- as.character(unique(map$RegionCode)) - # Creating sets for H12 subregions - subsets <- remind2::toolRegionSubsets(map=cfg$regionmapping,singleMatches=TRUE,removeDuplicates=FALSE) - if(grepl("regionmapping_21_EU11", cfg$regionmapping, fixed = TRUE)){ #add EU27 region group - subsets <- c(subsets,list( - "EU27"=c("ENC","EWN","ECS","ESC","ECE","FRA","DEU","ESW"), #EU27 (without Ireland) - "NEU_UKI"=c("NES", "NEN", "UKI") #EU27 (without Ireland) - ) ) - } - # declare ext_regi (needs to be declared before ext_regi to keep order of ext_regi) - content <- c(content, '') - content <- c(content, paste('*** Several parts of the REMIND code relies in the order that the regional set is defined.')) - content <- c(content, paste('*** Therefore, you must always abide with the below rules:')) - content <- c(content, paste('*** - The first regional set to be declared must be the ext_regi set, which includes the model native regions and all possible regional aggregations considered in REMIND.')) - content <- c(content, paste('*** - The ext_regi set needs to be declared in the order of more aggregated to less aggregated region order (e.g. World comes first and country regions goes last).')) - content <- c(content, paste('*** - IMPORTANT: You CANNOT use any of the ext_regi set elements in any set definition made prior to the ext_regi set declaration in the code.')) - content <- c(content, '') - content <- c(content, paste(' ext_regi "extended regions list (includes subsets of H12 regions)"')) - content <- c(content, ' /') - content <- c(content, ' GLO,') - content <- c(content, paste0(' ',paste(paste0(names(subsets),"_regi"),collapse=','),",")) - content <- c(content, paste0(' ',paste(regions,collapse=','))) - content <- c(content, ' /') - # declare all_regi - content <- c(content, '',paste(' all_regi "all regions" /',paste(regions,collapse=','),'/',sep=''),'') - # regi_group - content <- c(content, ' regi_group(ext_regi,all_regi) "region groups (regions that together corresponds to a H12 region)"') - content <- c(content, ' /') - content <- c(content, paste0(' ',paste('GLO.(',paste(regions,collapse=','),')'))) - for (i in 1:length(subsets)){ - content <- c(content, paste0(' ', paste(c(paste0(names(subsets)[i],"_regi"))), ' .(',paste(subsets[[i]],collapse=','), ')')) - } - content <- c(content, ' /') - content <- c(content, '') - # iso countries set - content <- c(content,' iso "list of iso countries" /') - content <- c(content, .tmp(map$CountryCode, suffix1=",", suffix2=" /"),'') - content <- c(content,' regi2iso(all_regi,iso) "mapping regions to iso countries"',' /') - for(i in as.character(unique(map$RegionCode))) { - content <- c(content, .tmp(map$CountryCode[map$RegionCode==i], prefix=paste0(i," . ("), suffix1=")", suffix2=")")) - } - content <- c(content,' /') - content <- c(content, 'iso_regi "all iso countries and EU and greater China region" / EUR,CHA,') - content <- c(content, .tmp(map$CountryCode, suffix1=",", suffix2=" /"),'') - content <- c(content,' map_iso_regi(iso_regi,all_regi) "mapping from iso countries to regions that represent country" ',' /') - for(i in regions[regions %in% c("EUR","CHA",as.character(unique(map$CountryCode)))]) { - content <- c(content, .tmp(i, prefix=paste0(i," . "), suffix1="", suffix2="")) - } - content <- c(content,' /',';') - replace_in_file('core/sets.gms',content,"SETS",comment="***") - } - ############ download and distribute input data ######## # check whether the regional resolution and input data revision are outdated and update data if needed - if(file.exists("input/source_files.log")) { - input_old <- readLines("input/source_files.log")[c(1,2,3)] - } else { - input_old <- "no_data" - } - input_new <- c(paste0("rev",cfg$inputRevision,"_", madrat::regionscode(cfg$regionmapping),"_", tolower(cfg$model_name),".tgz"), - paste0("rev",cfg$inputRevision,"_", madrat::regionscode(cfg$regionmapping),ifelse(cfg$extramappings_historic == "","",paste0("-", madrat::regionscode(cfg$extramappings_historic))),"_", tolower(cfg$validationmodel_name),".tgz"), - paste0("CESparametersAndGDX_",cfg$CESandGDXversion,".tgz")) - # download and distribute needed data - if (! setequal(input_new, input_old) || isTRUE(cfg$force_download)) { - message(if (isTRUE(cfg$force_download)) "You set 'cfg$force_download = TRUE'" - else "Your input data are outdated or in a different regional resolution", - ". New input data are downloaded and distributed.") - download_distribute(files = input_new, - repositories = cfg$repositories, # defined in your environment variables - modelfolder = ".", - debug = FALSE, - stopOnMissing = TRUE) - } else { - message("No input data downloaded and distributed. To enable that, delete input/source_files.log or set cfg$force_download to TRUE.") - } + cfg <- updateInputData(cfg, remindPath = ".") # extract BAU emissions for NDC runs to set up emission goals for region where only some countries have a target if (isTRUE(cfg$gms$carbonprice == "NDC") || isTRUE(cfg$gms$carbonpriceRegi == "NDC")) { @@ -273,10 +174,9 @@ prepare <- function() { ############ update information ######################## # update_info, which regional resolution and input data revision in tmpModelFile update_info(madrat::regionscode(cfg$regionmapping), cfg$inputRevision, cfg$model_version) - # update_sets, which is updating the region-depending sets in core/sets.gms + # updateSets, which is updating the region-depending sets in core/sets.gms #-- load new mapping information - map <- read.csv(cfg$regionmapping, sep=";") - update_sets(map) + updateSets(cfg) ######################################################## ### PROCESSING INPUT DATA ###################### END ### diff --git a/scripts/start/runGamsCompile.R b/scripts/start/runGamsCompile.R index 885d112b6..6964b6e99 100644 --- a/scripts/start/runGamsCompile.R +++ b/scripts/start/runGamsCompile.R @@ -9,9 +9,10 @@ #' @param modelFile filename of model file to be compiled #' @param cfg list with REMIND configuration #' @param interactive boolean, if TRUE, will ask user to compile again after fails +#' @param testmode boolean. In test mode, don't update sets and input data #' @author Oliver Richters #' @return boolean whether compilation was successful -runGamsCompile <- function(modelFile, cfg, interactive = TRUE) { +runGamsCompile <- function(modelFile, cfg, interactive = TRUE, testmode = FALSE) { # Define colors for output red <- "\033[0;31m" green <- "\033[0;32m" @@ -21,6 +22,11 @@ runGamsCompile <- function(modelFile, cfg, interactive = TRUE) { tmpModelFile <- file.path(gcdir, paste0("main_", cfg$title, ".gms")) tmpModelLst <- gsub("gms$", "lst", tmpModelFile) file.copy(modelFile, tmpModelFile, overwrite = TRUE) + if (! testmode) { + unlink(file.path("modules", c("45_carbonprice", "46_carbonpriceRegi"), "NDC", "input", "pm_BAU_reg_emi_wo_LU_bunkers.cs4r")) + updateSets(cfg) + updateInputData(cfg, verbose = FALSE) + } lucode2::manipulateConfig(tmpModelFile, cfg$gms) exitcode <- system2( command = cfg$gamsv, diff --git a/scripts/start/updateInputData.R b/scripts/start/updateInputData.R new file mode 100644 index 000000000..847dbdebd --- /dev/null +++ b/scripts/start/updateInputData.R @@ -0,0 +1,35 @@ +updateInputData <- function(cfg, remindPath = ".", verbose = TRUE) { + # write name of corresponding CES file to datainput.gms + + cfg$gms$cm_CES_configuration <- calculate_CES_configuration(cfg) + replace_in_file(file = file.path(remindPath, "modules/29_CES_parameters/load/datainput.gms"), + content = paste0('$include "', + "./modules/29_CES_parameters/load/input/", + cfg$gms$cm_CES_configuration, ".inc\""), + subject = "CES INPUT") + + + if(file.exists("input/source_files.log")) { + input_old <- readLines(file.path(remindPath, "input/source_files.log"))[c(1,2,3)] + } else { + input_old <- "no_data" + } + input_new <- c(paste0("rev",cfg$inputRevision,"_", madrat::regionscode(cfg$regionmapping),"_", tolower(cfg$model_name),".tgz"), + paste0("rev",cfg$inputRevision,"_", madrat::regionscode(cfg$regionmapping),ifelse(cfg$extramappings_historic == "","",paste0("-", madrat::regionscode(cfg$extramappings_historic))),"_", tolower(cfg$validationmodel_name),".tgz"), + paste0("CESparametersAndGDX_",cfg$CESandGDXversion,".tgz")) + # download and distribute needed data + if (! setequal(input_new, input_old) || isTRUE(cfg$force_download)) { + message(if (isTRUE(cfg$force_download)) "You set 'cfg$force_download = TRUE'" + else "Your input data are outdated or in a different regional resolution", + ". New input data are downloaded and distributed.") + download_distribute(files = input_new, + repositories = cfg$repositories, # defined in your environment variables + modelfolder = remindPath, + debug = FALSE, + stopOnMissing = TRUE) + } else if (verbose) { + message("No input data downloaded and distributed. To enable that, delete input/source_files.log or set cfg$force_download to TRUE.") + } + + return(cfg) +} diff --git a/scripts/start/updateSets.R b/scripts/start/updateSets.R new file mode 100644 index 000000000..f317533df --- /dev/null +++ b/scripts/start/updateSets.R @@ -0,0 +1,78 @@ +# | (C) 2006-2023 Potsdam Institute for Climate Impact Research (PIK) +# | authors, and contributors see CITATION.cff file. This file is part +# | of REMIND and licensed under AGPL-3.0-or-later. Under Section 7 of +# | AGPL-3.0, you are granted additional permissions described in the +# | REMIND License Exception, version 1.0 (see LICENSE file). +# | Contact: remind@pik-potsdam.de + +######## declare functions for updating information #### +updateSets <- function(cfg) { + map <- read.csv(cfg$regionmapping, sep=";") + .tmp <- function(x,prefix="", suffix1="", suffix2=" /", collapse=",", n=10) { + content <- NULL + tmp <- lapply(split(x, ceiling(seq_along(x)/n)),paste,collapse=collapse) + end <- suffix1 + for(i in 1:length(tmp)) { + if(i==length(tmp)) end <- suffix2 + content <- c(content,paste0(' ',prefix,tmp[[i]],end)) + } + return(content) + } + modification_warning <- c( + '*** THIS CODE IS CREATED AUTOMATICALLY, DO NOT MODIFY THESE LINES DIRECTLY', + '*** ANY DIRECT MODIFICATION WILL BE LOST AFTER NEXT INPUT DOWNLOAD', + '*** CHANGES CAN BE DONE USING THE RESPECTIVE LINES IN scripts/start/updateSets.R') + content <- c(modification_warning,'','sets') + # create iso set with nice formatting (10 countries per line) + tmp <- lapply(split(map$CountryCode, ceiling(seq_along(map$CountryCode)/10)),paste,collapse=",") + regions <- as.character(unique(map$RegionCode)) + # Creating sets for H12 subregions + subsets <- remind2::toolRegionSubsets(map=cfg$regionmapping,singleMatches=TRUE,removeDuplicates=FALSE) + if(grepl("regionmapping_21_EU11", cfg$regionmapping, fixed = TRUE)){ #add EU27 region group + subsets <- c(subsets,list( + "EU27"=c("ENC","EWN","ECS","ESC","ECE","FRA","DEU","ESW"), #EU27 (without Ireland) + "NEU_UKI"=c("NES", "NEN", "UKI") #EU27 (without Ireland) + ) ) + } + # declare ext_regi (needs to be declared before ext_regi to keep order of ext_regi) + content <- c(content, '') + content <- c(content, paste('*** Several parts of the REMIND code relies in the order that the regional set is defined.')) + content <- c(content, paste('*** Therefore, you must always abide with the below rules:')) + content <- c(content, paste('*** - The first regional set to be declared must be the ext_regi set, which includes the model native regions and all possible regional aggregations considered in REMIND.')) + content <- c(content, paste('*** - The ext_regi set needs to be declared in the order of more aggregated to less aggregated region order (e.g. World comes first and country regions goes last).')) + content <- c(content, paste('*** - IMPORTANT: You CANNOT use any of the ext_regi set elements in any set definition made prior to the ext_regi set declaration in the code.')) + content <- c(content, '') + content <- c(content, paste(' ext_regi "extended regions list (includes subsets of H12 regions)"')) + content <- c(content, ' /') + content <- c(content, ' GLO,') + content <- c(content, paste0(' ',paste(paste0(names(subsets),"_regi"),collapse=','),",")) + content <- c(content, paste0(' ',paste(regions,collapse=','))) + content <- c(content, ' /') + # declare all_regi + content <- c(content, '',paste(' all_regi "all regions" /',paste(regions,collapse=','),'/',sep=''),'') + # regi_group + content <- c(content, ' regi_group(ext_regi,all_regi) "region groups (regions that together corresponds to a H12 region)"') + content <- c(content, ' /') + content <- c(content, paste0(' ',paste('GLO.(',paste(regions,collapse=','),')'))) + for (i in 1:length(subsets)){ + content <- c(content, paste0(' ', paste(c(paste0(names(subsets)[i],"_regi"))), ' .(',paste(subsets[[i]],collapse=','), ')')) + } + content <- c(content, ' /') + content <- c(content, '') + # iso countries set + content <- c(content,' iso "list of iso countries" /') + content <- c(content, .tmp(map$CountryCode, suffix1=",", suffix2=" /"),'') + content <- c(content,' regi2iso(all_regi,iso) "mapping regions to iso countries"',' /') + for(i in as.character(unique(map$RegionCode))) { + content <- c(content, .tmp(map$CountryCode[map$RegionCode==i], prefix=paste0(i," . ("), suffix1=")", suffix2=")")) + } + content <- c(content,' /') + content <- c(content, 'iso_regi "all iso countries and EU and greater China region" / EUR,CHA,') + content <- c(content, .tmp(map$CountryCode, suffix1=",", suffix2=" /"),'') + content <- c(content,' map_iso_regi(iso_regi,all_regi) "mapping from iso countries to regions that represent country" ',' /') + for(i in regions[regions %in% c("EUR","CHA",as.character(unique(map$CountryCode)))]) { + content <- c(content, .tmp(i, prefix=paste0(i," . "), suffix1="", suffix2="")) + } + content <- c(content,' /',';') + replace_in_file('core/sets.gms',content,"SETS",comment="***") +} diff --git a/start.R b/start.R index 70812892b..7c7819178 100755 --- a/start.R +++ b/start.R @@ -244,10 +244,6 @@ if (any(c("--reprepare", "--restart") %in% flags)) { # ask for slurmConfig if not specified for every run if ("--gamscompile" %in% flags) { slurmConfig <- "direct" - if (! file.exists("input/source_files.log")) { - message("\n### Input data missing, need to compile REMIND first (2 min.)\n") - system("Rscript start.R config/tests/scenario_config_compile.csv") - } message("\nTrying to compile the selected runs...") lockID <- gms::model_lock() } diff --git a/tests/testthat/test_01-checkFixCfg.R b/tests/testthat/test_01-checkFixCfg.R index 01905584b..20a89a6ea 100644 --- a/tests/testthat/test_01-checkFixCfg.R +++ b/tests/testthat/test_01-checkFixCfg.R @@ -13,7 +13,7 @@ test_that("checkFixCfg works", { "cm_NDC_version" = "2004_cond", "cm_emiscen" = "123", "cm_nash_autoconverge" = "NA", - "cm_co2_tax_2020" = "2.2.2", + "cm_gs_ew" = "2.2.2", "cm_co2_tax_growth" = "333++", "c_macscen" = "-1", "cm_keep_presolve_gdxes" = "1.1", @@ -22,6 +22,7 @@ test_that("checkFixCfg works", { "cm_rcp_scen" = "apocalypse", "c_testOneRegi_region" = "LOONG", "c_shGreenH2" = "1.5", + "cm_co2_tax_2020" = "-2", NULL) cfg <- savecfg diff --git a/tests/testthat/test_01-runGamsCompile.R b/tests/testthat/test_01-runGamsCompile.R index e4d9f4a68..99b4dd7ea 100644 --- a/tests/testthat/test_01-runGamsCompile.R +++ b/tests/testthat/test_01-runGamsCompile.R @@ -8,7 +8,7 @@ test_that("runGamsCompile works", { source("../../config/default.cfg") gmsfile <- tempfile(fileext = ".gms") writeLines(c("Parameter test 'a great test value' / 4 /;"), gmsfile) - expect_true(runGamsCompile(gmsfile, cfg, interactive = FALSE)) + expect_true(runGamsCompile(gmsfile, cfg, interactive = FALSE, testmode = TRUE)) writeLines(c("meter test 'a great test value' / 4 /"), gmsfile) - expect_false(runGamsCompile(gmsfile, cfg, interactive = FALSE)) + expect_false(runGamsCompile(gmsfile, cfg, interactive = FALSE, testmode = TRUE)) }) diff --git a/tests/testthat/test_01-start.R b/tests/testthat/test_01-start.R index 741284fde..9ac8855c4 100644 --- a/tests/testthat/test_01-start.R +++ b/tests/testthat/test_01-start.R @@ -39,7 +39,9 @@ test_that("start.R --test succeeds on all configs", { file.path("../../config", "*", "scenario_config*.csv"))) } csvfiles <- normalizePath(grep("scenario_config_coupled", csvfiles, invert = TRUE, value = TRUE)) - skipfiles <- c("scenario_config_21_EU11_ECEMF", "scenario_config_EDGE-T_NDC_NPi_pkbudget", "scenario_config_NAVIGATE_300") + skipfiles <- c("scenario_config_21_EU11_ECEMF", + "scenario_config_EDGE-T_NDC_NPi_pkbudget", + "scenario_config_NAVIGATE_300") csvfiles <- grep(paste(skipfiles, collapse = "|"), csvfiles, invert = TRUE, value = TRUE) expect_true(length(csvfiles) > 0) with_mocked_bindings( diff --git a/tests/testthat/test_04-gamscompile.R b/tests/testthat/test_04-gamscompile.R index 817278fa3..e4ea4638e 100644 --- a/tests/testthat/test_04-gamscompile.R +++ b/tests/testthat/test_04-gamscompile.R @@ -30,8 +30,16 @@ test_that("start.R --gamscompile works on all configs and scenarios", { file.path("../../config", "*", "scenario_config*.csv"))) } csvfiles <- normalizePath(grep("^scenario_config_coupled.*", csvfiles, invert = TRUE, value = TRUE)) - skipfiles <- c("scenario_config_21_EU11_ECEMF", "scenario_config_EDGE-T_NDC_NPi_pkbudget", - "scenario_config_NAVIGATE_300", "21_regions_EU11", "scenario_config_tradeCap_standalone") + skipfiles <- c("scenario_config_21_EU11_ECEMF", + "scenario_config_21_EU11_ARIADNE", + "scenario_config_21_EU11_SSPSDP", + "scenario_config_21_EU11_Fit_for_55_sensitivity", + "scenario_config_EDGE-T_NDC_NPi_pkbudget", + "scenario_config_NAVIGATE_300", + "scenario_config_tradeCap_standalone", + "scenario_config_DeepEl", + "scenario_config_SHAPE", + "scenario_config_GCS") csvfiles <- grep(paste(skipfiles, collapse = "|"), csvfiles, invert = TRUE, value = TRUE) expect_true(length(csvfiles) > 0) with_mocked_bindings( diff --git a/tests/testthat/test_06-output.R b/tests/testthat/test_06-output.R index 3f75c9053..e1286b75e 100644 --- a/tests/testthat/test_06-output.R +++ b/tests/testthat/test_06-output.R @@ -30,6 +30,7 @@ test_that("output.R -> export -> xlsx_IIASA works", { }) test_that("cleanup output.R", { + skipIfPreviousFailed() exportfiles <- Sys.glob(file.path("..", "..", "output", "export", "*TESTTHAT*")) unlink(exportfiles) })