@@ -30,6 +30,8 @@ def run_ssps(
3030 config ,
3131 USA ,
3232 AR ,
33+ masks = [None ],
34+ fair_dims_list = [["simulation" ]],
3335 global_cons = False ,
3436 factors = False ,
3537 marginal_damages = False ,
@@ -39,13 +41,23 @@ def run_ssps(
3941 with open (config , "r" ) as stream :
4042 conf = yaml .safe_load (stream )
4143
42- for sector , pulse_year , menu_disc , eta_rho in product (
43- sectors , pulse_years , menu_discs , eta_rhos .items ()
44+ for sector , pulse_year , menu_disc , eta_rho , mask , fair_dims in product (
45+ sectors , pulse_years , menu_discs , eta_rhos .items (), masks , fair_dims_list
4446 ):
4547
4648 menu_option , discount_type = menu_disc
4749 save_path = f"{ conf ['paths' ][f'AR{ AR } _ssp_results' ]} /{ sector } /{ pulse_year } /"
4850
51+ if mask is not None :
52+ save_path = save_path + "/" + mask
53+
54+ if fair_dims != ["simulation" ]:
55+ save_path = (
56+ save_path
57+ + "/"
58+ + f"fair_collapsed_{ '_' .join ([i for i in fair_dims if i != 'simulation' ])} "
59+ )
60+
4961 if USA == True :
5062 econ = EconVars (path_econ = conf ["econdata" ]["USA_ssp" ])
5163 else :
@@ -54,7 +66,9 @@ def run_ssps(
5466 add_kwargs = {
5567 "econ_vars" : econ ,
5668 "climate_vars" : Climate (
57- ** conf [f"AR{ AR } _ssp_climate" ], pulse_year = pulse_year
69+ ** conf [f"AR{ AR } _ssp_climate" ],
70+ pulse_year = pulse_year ,
71+ ecs_mask_name = mask ,
5872 ),
5973 "formula" : conf ["sectors" ][sector if USA == False else sector [:- 4 ]][
6074 "formula"
@@ -65,6 +79,7 @@ def run_ssps(
6579 "save_path" : save_path ,
6680 "eta" : eta_rho [0 ],
6781 "rho" : eta_rho [1 ],
82+ "fair_dims" : fair_dims ,
6883 }
6984
7085 kwargs = conf ["global_parameters" ].copy ()
0 commit comments