From fd2bee7de8c9933ef4ed86cc162d87849847ff95 Mon Sep 17 00:00:00 2001 From: Lisa Bock Date: Mon, 14 Aug 2023 16:54:42 +0200 Subject: [PATCH] Cmorizer for NOAA-CIRES-20CR v3 reanalysis (clt, clwvi, hus, prw, rlut, rlutcs, rsut, rsutcs) (#3137) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rémi Kazeroni --- doc/sphinx/source/input.rst | 4 +- ...-CIRES-20CR.yml => NOAA-CIRES-20CR-V2.yml} | 4 +- .../data/cmor_config/NOAA-CIRES-20CR-V3.yml | 56 +++++++++++++++++++ esmvaltool/cmorizers/data/datasets.yml | 17 +++++- ...aa_cires_20cr.py => noaa_cires_20cr_v2.py} | 2 +- .../datasets/noaa_cires_20cr_v3.py | 53 ++++++++++++++++++ ...aa_cires_20cr.py => noaa_cires_20cr_v2.py} | 2 +- .../formatters/datasets/noaa_cires_20cr_v3.py | 32 +++++++++++ .../recipes/examples/recipe_check_obs.yml | 25 +++++++-- ...-20cr.bibtex => noaa-cires-20cr-v2.bibtex} | 10 ++-- .../references/noaa-cires-20cr-v3.bibtex | 11 ++++ 11 files changed, 202 insertions(+), 14 deletions(-) rename esmvaltool/cmorizers/data/cmor_config/{NOAA-CIRES-20CR.yml => NOAA-CIRES-20CR-V2.yml} (88%) create mode 100644 esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V3.yml rename esmvaltool/cmorizers/data/downloaders/datasets/{noaa_cires_20cr.py => noaa_cires_20cr_v2.py} (97%) create mode 100644 esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v3.py rename esmvaltool/cmorizers/data/formatters/datasets/{noaa_cires_20cr.py => noaa_cires_20cr_v2.py} (92%) create mode 100644 esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v3.py rename esmvaltool/references/{noaa-cires-20cr.bibtex => noaa-cires-20cr-v2.bibtex} (62%) create mode 100644 esmvaltool/references/noaa-cires-20cr-v3.bibtex diff --git a/doc/sphinx/source/input.rst b/doc/sphinx/source/input.rst index 8bd0d5afd0..c453a0569e 100644 --- a/doc/sphinx/source/input.rst +++ b/doc/sphinx/source/input.rst @@ -380,7 +380,9 @@ A list of the datasets for which a CMORizers is available is provided in the fol +------------------------------+------------------------------------------------------------------------------------------------------+------+-----------------+ | NIWA-BS | toz, tozStderr (Amon) | 3 | NCL | +------------------------------+------------------------------------------------------------------------------------------------------+------+-----------------+ -| NOAA-CIRES-20CR | clt, clwvi, hus, prw, rlut, rsut (Amon) | 2 | Python | +| NOAA-CIRES-20CR-V2 | clt, clwvi, hus, prw, rlut, rsut (Amon) | 2 | Python | ++------------------------------+------------------------------------------------------------------------------------------------------+------+-----------------+ +| NOAA-CIRES-20CR-V3 | clt, clwvi, hus, prw, rlut, rlutcs, rsut, rsutcs (Amon) | 2 | Python | +------------------------------+------------------------------------------------------------------------------------------------------+------+-----------------+ | NOAAGlobalTemp | tasa (Amon) | 2 | Python | +------------------------------+------------------------------------------------------------------------------------------------------+------+-----------------+ diff --git a/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR.yml b/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V2.yml similarity index 88% rename from esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR.yml rename to esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V2.yml index cb3ccb38a8..7591e99257 100644 --- a/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR.yml +++ b/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V2.yml @@ -1,13 +1,13 @@ --- # Global attributes of NetCDF file attributes: - dataset_id: NOAA-CIRES-20CR + dataset_id: NOAA-CIRES-20CR-V2 project_id: OBS6 tier: 2 version: 'v2' modeling_realm: reanaly source: 'https://psl.noaa.gov/data/gridded/data.20thC_ReanV2.html' - reference: 'noaa-cires-20cr' + reference: 'noaa-cires-20cr-v2' comment: | '' diff --git a/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V3.yml b/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V3.yml new file mode 100644 index 0000000000..d16d5265e0 --- /dev/null +++ b/esmvaltool/cmorizers/data/cmor_config/NOAA-CIRES-20CR-V3.yml @@ -0,0 +1,56 @@ +--- +# Global attributes of NetCDF file +attributes: + dataset_id: NOAA-CIRES-20CR-V3 + project_id: OBS6 + tier: 2 + version: 'v3' + modeling_realm: reanaly + source: 'https://psl.noaa.gov/data/gridded/data.20thC_ReanV3.html' + reference: 'noaa-cires-20cr-v3' + comment: | + '' + +# Variables to CMORize +variables: + # monthly frequency + clt_month: + short_name: clt + mip: Amon + raw: tcdc + file: 'tcdc.eatm.mon.mean.nc' + clwvi_month: + short_name: clwvi + mip: Amon + raw: cldwtr + file: 'cldwtr.eatm.mon.mean.nc' + prw_month: + short_name: prw + mip: Amon + raw: pr_wtr + file: 'pr_wtr.eatm.mon.mean.nc' + hus_month: + short_name: hus + mip: Amon + raw: shum + file: 'shum.mon.mean.nc' + rlut_month: + short_name: rlut + mip: Amon + raw: ulwrf + file: 'ulwrf.ntat.mon.mean.nc' + rsut_month: + short_name: rsut + mip: Amon + raw: uswrf + file: 'uswrf.ntat.mon.mean.nc' + rlutcs_month: + short_name: rlutcs + mip: Amon + raw: csulf + file: 'csulf.ntat.mon.mean.nc' + rsutcs_month: + short_name: rsutcs + mip: Amon + raw: csusf + file: 'csusf.ntat.mon.mean.nc' diff --git a/esmvaltool/cmorizers/data/datasets.yml b/esmvaltool/cmorizers/data/datasets.yml index 61b56e7f8f..d40de3988c 100644 --- a/esmvaltool/cmorizers/data/datasets.yml +++ b/esmvaltool/cmorizers/data/datasets.yml @@ -985,7 +985,7 @@ datasets: https://nsidc.org/data/NSIDC-0116 Login required for download, and also requires citation only to use - NOAA-CIRES-20CR: + NOAA-CIRES-20CR-V2: tier: 2 source: ftp.cdc.noaa.gov/Projects/20thC_ReanV2/Monthlies/ last_access: 2022-11-17 @@ -998,6 +998,21 @@ datasets: gaussian/monolevel/ulwrf.ntat.mon.mean.nc gaussian/monolevel/uswrf.ntat.mon.mean.nc + NOAA-CIRES-20CR-V3: + tier: 2 + source: ftp.cdc.noaa.gov/Projects/20thC_ReanV3/Monthlies/ + last_access: 2023-03-27 + info: | + Download the following files: + miscSI-MO/cldwtr.eatm.mon.mean.nc + miscSI-MO/pr_wtr.eatm.mon.mean.nc + prsSI-MO/shum.mon.mean.nc + miscMO/tcdc.eatm.mon.mean.nc + ntatFlxSI-MO/ulwrf.ntat.mon.mean.nc + ntatFlxSI-MO/uswrf.ntat.mon.mean.nc + ntatFlxSI-MO/csulf.ntat.mon.mean.nc + ntatFlxSI-MO/csusf.ntat.mon.mean.nc + NOAAGlobalTemp: tier: 2 source: https://www.ncei.noaa.gov/data/noaa-global-surface-temperature/v5/access/ diff --git a/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr.py b/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v2.py similarity index 97% rename from esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr.py rename to esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v2.py index 836cfe8391..fb2d733f06 100644 --- a/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr.py +++ b/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v2.py @@ -1,4 +1,4 @@ -"""Script to download NOAA-CIRES-20CR.""" +"""Script to download NOAA-CIRES-20CR-V2.""" import logging from esmvaltool.cmorizers.data.downloaders.ftp import FTPDownloader diff --git a/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v3.py b/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v3.py new file mode 100644 index 0000000000..67f1a38f33 --- /dev/null +++ b/esmvaltool/cmorizers/data/downloaders/datasets/noaa_cires_20cr_v3.py @@ -0,0 +1,53 @@ +"""Script to download NOAA-CIRES-20CR-V3.""" +import logging + +from esmvaltool.cmorizers.data.downloaders.ftp import FTPDownloader + +logger = logging.getLogger(__name__) + + +def download_dataset(config, dataset, dataset_info, start_date, end_date, + overwrite): + """Download dataset. + + Parameters + ---------- + config : dict + ESMValTool's user configuration + dataset : str + Name of the dataset + dataset_info : dict + Dataset information from the datasets.yml file + start_date : datetime + Start of the interval to download + end_date : datetime + End of the interval to download + overwrite : bool + Overwrite already downloaded files + """ + downloader = FTPDownloader( + config=config, + server='ftp.cdc.noaa.gov', + dataset=dataset, + dataset_info=dataset_info, + overwrite=overwrite, + ) + downloader.connect() + + downloader.set_cwd("Datasets/20thC_ReanV3/Monthlies/") + downloader.download_file("miscSI-MO/cldwtr.eatm.mon.mean.nc", + sub_folder='surface') + downloader.download_file("miscSI-MO/pr_wtr.eatm.mon.mean.nc", + sub_folder='surface') + downloader.download_file("prsSI-MO/shum.mon.mean.nc", + sub_folder='pressure') + downloader.download_file("miscMO/tcdc.eatm.mon.mean.nc", + sub_folder='surface') + downloader.download_file("ntatFlxSI-MO/ulwrf.ntat.mon.mean.nc", + sub_folder='surface') + downloader.download_file("ntatFlxSI-MO/uswrf.ntat.mon.mean.nc", + sub_folder='surface') + downloader.download_file("ntatFlxSI-MO/csulf.ntat.mon.mean.nc", + sub_folder='surface') + downloader.download_file("ntatFlxSI-MO/csusf.ntat.mon.mean.nc", + sub_folder='surface') diff --git a/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr.py b/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v2.py similarity index 92% rename from esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr.py rename to esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v2.py index cdc5efbd40..3744cdce67 100644 --- a/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr.py +++ b/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v2.py @@ -1,4 +1,4 @@ -"""ESMValTool CMORizer for NOAA-CIRES-20CR data. +"""ESMValTool CMORizer for NOAA-CIRES-20CR-V2 data. Tier Tier 2: other freely-available dataset. diff --git a/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v3.py b/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v3.py new file mode 100644 index 0000000000..9405473931 --- /dev/null +++ b/esmvaltool/cmorizers/data/formatters/datasets/noaa_cires_20cr_v3.py @@ -0,0 +1,32 @@ +"""ESMValTool CMORizer for NOAA-CIRES-20CR-V3 data. + +Tier + Tier 2: other freely-available dataset. + +Source + https://psl.noaa.gov/data/gridded/data.ncep.reanalysis2.html + +Last access + 20230327 + +Download and processing instructions + To facilitate the download, the links to the ftp server are provided. + + ftp://ftp.cdc.noaa.gov/Datasets/20thC_ReanV3/Monthlies/ + + pr_wtr.eatm.mon.mean.nc + cldwtr.eatm.mon.mean.nc + tcdc.eatm.mon.mean.nc + ulwrf.ntat.mon.mean.nc + uswrf.ntat.mon.mean.nc + csulf.ntat.mon.mean.nc + csusf.ntat.mon.mean.nc + shum.mon.mean.nc + +Caveats + +""" +from .ncep_ncar_r1 import cmorization + +# The following line makes it clear that the above import is not an error +cmorization diff --git a/esmvaltool/recipes/examples/recipe_check_obs.yml b/esmvaltool/recipes/examples/recipe_check_obs.yml index 1bccda03b1..83ccc55607 100644 --- a/esmvaltool/recipes/examples/recipe_check_obs.yml +++ b/esmvaltool/recipes/examples/recipe_check_obs.yml @@ -632,21 +632,38 @@ diagnostics: scripts: null - NOAA-CIRES-20CR: - description: NOAA-CIRES-20CR check + NOAA-CIRES-20CR-V2: + description: NOAA-CIRES-20CR-V2 check variables: clt: clwvi: hus: prw: - rsut: rlut: + rsut: additional_datasets: - - {dataset: NOAA-CIRES-20CR, project: OBS6, mip: Amon, tier: 2, + - {dataset: NOAA-CIRES-20CR-V2, project: OBS6, mip: Amon, tier: 2, type: reanaly, version: v2, start_year: 1871, end_year: 2012} scripts: null + NOAA-CIRES-20CR-V3: + description: NOAA-CIRES-20CR-V3 check + variables: + clt: + clwvi: + hus: + prw: + rlut: + rlutcs: + rsut: + rsutcs: + additional_datasets: + - {dataset: NOAA-CIRES-20CR-V3, project: OBS6, mip: Amon, tier: 2, + type: reanaly, version: v3, start_year: 1836, end_year: 2015} + scripts: null + + NOAAGlobalTemp: description: NOAAGlobalTemp check variables: diff --git a/esmvaltool/references/noaa-cires-20cr.bibtex b/esmvaltool/references/noaa-cires-20cr-v2.bibtex similarity index 62% rename from esmvaltool/references/noaa-cires-20cr.bibtex rename to esmvaltool/references/noaa-cires-20cr-v2.bibtex index 54d67ea7f3..79314b1d4b 100644 --- a/esmvaltool/references/noaa-cires-20cr.bibtex +++ b/esmvaltool/references/noaa-cires-20cr-v2.bibtex @@ -1,9 +1,11 @@ -@article{noaa-cire-20cr, +@article{noaa-cires-20cr-v2, doi = {10.1002/qj.776}, url = {https://doi.org/10.1002/qj.776}, - publisher = {Royal Meteorological Society}, - author = {Compo, G.P., Whitaker, J.S., Sardeshmukh, P.D., Matsui, N., Allan, R.J., Yin, X., Gleason, B.E., Vose, R.S., Rutledge, G., Bessemoulin, P., Brönnimann, S., Brunet, M., Crouthamel, R.I., Grant, A.N., Groisman, P.Y., Jones, P.D., Kruk, M.C., Kruger, A.C., Marshall, G.J., Maugeri, M., Mok, H.Y., Nordli, Ø., Ross, T.F., Trigo, R.M., Wang, X.L., Woodruff, S.D. and Worley, S.J.}, + author = {Compo, G.P., Whitaker, J.S., Sardeshmukh, P.D., Matsui, N., Allan, R.J., Yin, X., Gleason, B.E., Vose, R.S., Rutledge, G., Bessemoulin, P., Brönnimann, S., Brunet, M., Crouthamel, R.I., Grant, A.N., Groisman, P.Y., Jones, P.D., Kruk, M.C., Kruger, A.C., Marshall, G.J., Maugeri, M., Mok, H.Y., Nordli, O., Ross, T.F., Trigo, R.M., Wang, X.L., Woodruff, S.D. and Worley, S.J.}, title = {The Twentieth Century Reanalysis Project}, - year = {2011} + year = {2011}, journal = {Quarterly J. Roy. Meteorol. Soc.} + volume = {137}, + number = {654}, + pages = {1-28}, } diff --git a/esmvaltool/references/noaa-cires-20cr-v3.bibtex b/esmvaltool/references/noaa-cires-20cr-v3.bibtex new file mode 100644 index 0000000000..d1bf482e9d --- /dev/null +++ b/esmvaltool/references/noaa-cires-20cr-v3.bibtex @@ -0,0 +1,11 @@ +@article{noaa-cires-20cr-v3, + journal = {Quarterly J. Roy. Meteorol. Soc.} + author = {Slivinski, Laura C. and Compo, Gilbert P. and Whitaker, Jeffrey S. and Sardeshmukh, Prashant D. and Giese, Benjamin S. and McColl, Chesley and Allan, Rob and Yin, Xungang and Vose, Russell and Titchner, Holly and Kennedy, John and Spencer, Lawrence J. and Ashcroft, Linden and Brönnimann, Stefan and Brunet, Manola and Camuffo, Dario and Cornes, Richard and Cram, Thomas A. and Crouthamel, Richard and Domínguez-Castro, Fernando and Freeman, J. Eric and Gergis, Joëlle and Hawkins, Ed and Jones, Philip D. and Jourdain, Sylvie and Kaplan, Alexey and Kubota, Hisayuki and Blancq, Frank Le and Lee, Tsz-Cheung and Lorrey, Andrew and Luterbacher, Jürg and Maugeri, Maurizio and Mock, Cary J. and Moore, G.W. Kent and Przybylak, Rajmund and Pudmenzky, Christa and Reason, Chris and Slonosky, Victoria C. and Smith, Catherine A. and Tinz, Birger and Trewin, Blair and Valente, Maria Antónia and Wang, Xiaolan L. and Wilkinson, Clive and Wood, Kevin and Wyszynski, Przemysxslaw}, + title = {Towards a more reliable historical reanalysis: Improvements for version 3 of the Twentieth Century Reanalysis system}, + volume = {145}, + number = {724}, + pages = {2876-2908}, + doi = {https://doi.org/10.1002/qj.3598}, + url = {https://rmets.onlinelibrary.wiley.com/doi/abs/10.1002/qj.3598}, + year = {2019} +}