diff --git a/changelog/670.trivial.md b/changelog/670.trivial.md new file mode 100644 index 000000000..621e8b570 --- /dev/null +++ b/changelog/670.trivial.md @@ -0,0 +1 @@ +Updated the timerange on which the climate drivers for fire ESMValTool recipe is run. diff --git a/packages/climate-ref-esmvaltool/src/climate_ref_esmvaltool/diagnostics/climate_drivers_for_fire.py b/packages/climate-ref-esmvaltool/src/climate_ref_esmvaltool/diagnostics/climate_drivers_for_fire.py index c8f295ad4..380cbae00 100644 --- a/packages/climate-ref-esmvaltool/src/climate_ref_esmvaltool/diagnostics/climate_drivers_for_fire.py +++ b/packages/climate-ref-esmvaltool/src/climate_ref_esmvaltool/diagnostics/climate_drivers_for_fire.py @@ -56,7 +56,7 @@ class ClimateDriversForFire(ESMValToolDiagnostic): constraints=( RequireTimerange( group_by=("instance_id",), - start=PartialDateTime(2013, 1), + start=PartialDateTime(1994, 1), end=PartialDateTime(2014, 12), ), AddSupplementaryDataset.from_defaults("sftlf", SourceDatasetType.CMIP6), @@ -110,8 +110,8 @@ class ClimateDriversForFire(ESMValToolDiagnostic): constraints=( RequireTimerange( group_by=("instance_id",), - start=PartialDateTime(2013, 1), - end=PartialDateTime(2014, 12), + start=PartialDateTime(2001, 1), + end=PartialDateTime(2021, 12), ), AddSupplementaryDataset.from_defaults("sftlf", SourceDatasetType.CMIP7), RequireFacets( @@ -233,8 +233,12 @@ def update_recipe( else: short_name = cmip6_short_name variable["short_name"] = short_name - variable["start_year"] = 2013 - variable["end_year"] = 2014 + if cmip_source == SourceDatasetType.CMIP7: + variable["start_year"] = 2001 + variable["end_year"] = 2021 + else: + variable["start_year"] = 1994 + variable["end_year"] = 2014 datasets = recipe_variables[short_name]["additional_datasets"] for dataset in datasets: dataset.pop("timerange", None) diff --git a/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip6.yml b/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip6.yml index 49b7e0636..9f21e2884 100644 --- a/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip6.yml +++ b/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip6.yml @@ -35,7 +35,7 @@ diagnostics: mip: Amon preprocessor: preproc short_name: pr - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 @@ -50,7 +50,7 @@ diagnostics: mip: Amon preprocessor: preproc short_name: tasmax - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 @@ -65,7 +65,7 @@ diagnostics: mip: Lmon preprocessor: preproc_fraction short_name: treeFrac - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 @@ -80,7 +80,7 @@ diagnostics: mip: Emon preprocessor: preproc_fraction short_name: vegFrac - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 @@ -95,7 +95,7 @@ diagnostics: mip: Lmon preprocessor: preproc short_name: cVeg - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 @@ -110,7 +110,7 @@ diagnostics: mip: Amon preprocessor: preproc short_name: tas - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 @@ -125,7 +125,7 @@ diagnostics: mip: Amon preprocessor: preproc short_name: hurs - start_year: 2013 + start_year: 1994 end_year: 2014 additional_datasets: - project: CMIP6 diff --git a/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip7.yml b/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip7.yml index f3b3dcb3f..9807a070c 100644 --- a/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip7.yml +++ b/packages/climate-ref-esmvaltool/tests/unit/diagnostics/recipes/recipe_climate_drivers_for_fire_cmip7.yml @@ -35,8 +35,8 @@ diagnostics: mip: atmos preprocessor: preproc short_name: pr - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP @@ -53,8 +53,8 @@ diagnostics: mip: atmos preprocessor: preproc short_name: tas - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP @@ -71,8 +71,8 @@ diagnostics: mip: land preprocessor: preproc_fraction short_name: treeFrac - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP @@ -89,8 +89,8 @@ diagnostics: mip: land preprocessor: preproc_fraction short_name: vegFrac - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP @@ -107,8 +107,8 @@ diagnostics: mip: land preprocessor: preproc short_name: cVeg - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP @@ -125,8 +125,8 @@ diagnostics: mip: atmos preprocessor: preproc short_name: tas - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP @@ -143,8 +143,8 @@ diagnostics: mip: atmos preprocessor: preproc short_name: hurs - start_year: 2013 - end_year: 2014 + start_year: 2001 + end_year: 2021 additional_datasets: - project: CMIP7 activity: CMIP