diff --git a/VERSION b/VERSION index fb62f4077b27f0b2fe8a57be9d9b9baa798a8914..b0e4bca8dc425eb9c69cadb49bf354eda61295fa 100644 --- a/VERSION +++ b/VERSION @@ -1,2 +1,2 @@ -3.0.0b41 +3.0.0b42 diff --git a/doc/source/codedoc/general.rst b/doc/source/codedoc/general.rst index d7b2f88b41fc2cd0b539687ea8ece99701ff4fcc..d4fc8ea0828502b7a6869ed4f71b02a66e0be836 100644 --- a/doc/source/codedoc/general.rst +++ b/doc/source/codedoc/general.rst @@ -7,6 +7,12 @@ earthdiagnostics.general.attribute :show-inheritance: :members: +earthdiagnostics.general.dailymean +---------------------------------- +.. automodule:: earthdiagnostics.general.dailymean + :show-inheritance: + :members: + earthdiagnostics.general.monthlymean ------------------------------------ .. automodule:: earthdiagnostics.general.monthlymean @@ -37,3 +43,9 @@ earthdiagnostics.general.scale .. automodule:: earthdiagnostics.general.scale :show-inheritance: :members: + +earthdiagnostics.general.yearlymean +----------------------------------- +.. automodule:: earthdiagnostics.general.yearlymean + :show-inheritance: + :members: diff --git a/doc/source/codedoc/ocean.rst b/doc/source/codedoc/ocean.rst index 2da23cabf3372ccd784b4fb0980f812d4663cd7c..5ca11d71e4e36774561732b93ade7f2b714069a7 100644 --- a/doc/source/codedoc/ocean.rst +++ b/doc/source/codedoc/ocean.rst @@ -85,6 +85,12 @@ earthdiagnostics.ocean.psi :show-inheritance: :members: +earthdiagnostics.ocean.rotation +------------------------------- +.. automodule:: earthdiagnostics.ocean.rotation + :show-inheritance: + :members: + earthdiagnostics.ocean.siasiesiv -------------------------------- .. automodule:: earthdiagnostics.ocean.siasiesiv diff --git a/doc/source/conf.py b/doc/source/conf.py index 89ede55ddaa466d150cd53612fd42177763eca53..0be2cea52029c2d488e6b7e1771e61bbcf96fb13 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -64,7 +64,7 @@ copyright = u'2016, BSC-CNS Earth Sciences Department' # The short X.Y version. version = '3.0b' # The full version, including alpha/beta/rc tags. -release = '3.0.0b41' +release = '3.0.0b42' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff --git a/doc/source/config_file.rst b/doc/source/config_file.rst index b4bd369813afe34a9155bd45422413ac5b959272..dde7685aa3d0f930fd55a310416f42075cca43bf 100644 --- a/doc/source/config_file.rst +++ b/doc/source/config_file.rst @@ -30,10 +30,21 @@ Mandatory configurations Default data frequency to be used by the diagnostics. Some diagnostics can override this configuration or even ignore it completely. +* DIAGS: + List of diagnostic to run, in the order you want them to run + Optional configurations ~~~~~~~~~~~~~~~~~~~~~~~ +* SCRATCH_MASKS + Common scratch folder for the ocean masks. This is useful to avoid replicating them for each run at the fat nodes. + By default is '/scratch/Earth/ocean_masks' + +* RESTORE_MESHES + By default, Earth Diagnostics only copies the mask files if they are not present in the scratch folder. If this + option is set to true, Earth Diagnostics will copy them regardless of existence. Default is False. + * DATA_ADAPTOR This is used to choose the mechanism for storing and retrieving data. Options are CMOR (for our own experiments) or THREDDS (for anything else). Default value is CMOR @@ -66,10 +77,10 @@ This sections contains options related to the experiment's definition or configu Model version. Used to get the correct mask and mesh files * ATMOS_TIMESTEP - Time between outputs from the atmosphere. This is not the model simulation timestep! + Time between outputs from the atmosphere. This is not the model simulation timestep! Default is 6. * OCEAN_TIMESTEP - Time between outputs from the ocean. This is not the model simulation timestep! + Time between outputs from the ocean. This is not the model simulation timestep! Default is 6. * ATMOS_GRID Atmospheric grid definition. Will be used as a default target for interpolation diagnostics. @@ -87,12 +98,19 @@ This sections contains options related to the experiment's definition or configu Startdates to run as a space separated list * MEMBER - Members to run as a space separated integer list + Members to run as a space separated list. You can just provide the number or also add the prefix * MEMBER_DIGITS Number of minimum digits to compose the member name. By default it is 1. For example, for member 1 member name will be fc1 if MEMBER_DIGITS is 1 or fc01 if MEMBER_DIGITS is 2 +* MEMBER_PREFIX + Prefix to use for the member names. By default is 'fc' + +* MEMBER_COUNT_START + Number corresponding to the first member. For example, if your first member is 'fc1', it should be 1. + If it is 'fc0', it should be 0. By default is 0 + * CHUNK_SIZE Length of the chunks in months diff --git a/doc/source/diagnostic_list.rst b/doc/source/diagnostic_list.rst index 74c5b46a99b9958f9d4f00038ec2d413cfb35007..e2393d709804f2e375ab7e9d0722a0696bab9643 100644 --- a/doc/source/diagnostic_list.rst +++ b/doc/source/diagnostic_list.rst @@ -43,6 +43,30 @@ Options: 5. Grid = '': Variable grid. Only required in case that you want to use interpolated data. +dailymean +~~~~~~~~~ +Calculates the daily mean for a given variable. See :class:`~earthdiagnostics.general.dailymean.DailyMean` + +.. warning:: + + This diagnostic does not use the frequency configuration from the config file. You must specify the original + frequency when calling it. + +Options: +******** + +1. Variable: + Variable name + +2. Domain: + Variable domain + +3. Original frequency: + Original frequency to use + +4. Grid = '': + Variable grid. Only required in case that you want to use interpolated data. + monmean ~~~~~~~ Calculates the monthly mean for a given variable. See :class:`~earthdiagnostics.general.monthlymean.MonthlyMean` @@ -151,6 +175,30 @@ Options: 7. Max limit = NaN: If there is any value above this threshold, scale will not be applied +yearlymean +~~~~~~~~~~ +Calculates the daily mean for a given variable. See :class:`~earthdiagnostics.general.yearlymean.YearlyMean` + +.. warning:: + + This diagnostic does not use the frequency configuration from the config file. You must specify the original + frequency when calling it. + +Options: +******** + +1. Variable: + Variable name + +2. Domain: + Variable domain + +3. Original frequency: + Original frequency to use + +4. Grid = '': + Variable grid. Only required in case that you want to use interpolated data. + Ocean ----- @@ -458,7 +506,31 @@ Options: 7. Max depth: Maximum depth to compute in levels. If -1, average to the bottom +rotate +~~~~~~ + +Rotates the given variables +See :class:`~earthdiagnostics.ocean.rotation.Rotation` + + +Options: +******** +1. Variable u: + Variable's u component + +2. Variable v: + Variable's u component + +3. Domain = ocean: + Variable domain: + +4. Executable = /home/Earth/jvegas/pyCharm/cfutools/interpolation/rotateUVorca: + Path to the executable that will compute the rotation + +.. warning:: + This default executable has been compiled for ORCA1 experiments. For other resolutions you must use other + executables compiled ad-hoc for them siasiesiv ~~~~~~~~~ diff --git a/earthdiagnostics/EarthDiagnostics.pdf b/earthdiagnostics/EarthDiagnostics.pdf index 302176c41181b9907265f0f07717fd58f9b89163..40d79dfe0e345bbf5501604881c82035f9ed89d4 100644 Binary files a/earthdiagnostics/EarthDiagnostics.pdf and b/earthdiagnostics/EarthDiagnostics.pdf differ diff --git a/earthdiagnostics/cmormanager.py b/earthdiagnostics/cmormanager.py index dcfed271f3e1607756959351bbc8d949d81fd21a..10c45421d1c8a360040da60b04aee4661e1d84b9 100644 --- a/earthdiagnostics/cmormanager.py +++ b/earthdiagnostics/cmormanager.py @@ -534,5 +534,5 @@ class CMORManager(DataManager): self.experiment.model, self.experiment.experiment_name, 'S' + startdate) def _get_member_str(self, member): - return 'r{0}i1p1'.format(member + 1) + return 'r{0}i1p1'.format(member + 1 - self.experiment.member_count_start) diff --git a/earthdiagnostics/config.py b/earthdiagnostics/config.py index 7ace02ea1c8532155cfd7cd730dd6772712d41ff..ba1efb7ad244a6f55248092570c2735d92b677fd 100644 --- a/earthdiagnostics/config.py +++ b/earthdiagnostics/config.py @@ -27,7 +27,7 @@ class Config(object): "Scratch folder path" self.scratch_dir = parser.get_path_option('DIAGNOSTICS', 'SCRATCH_DIR') "Scratch folder path" - self.scratch_masks = parser.get_path_option('DIAGNOSTICS', 'SCRATCH_MASKS', '') + self.scratch_masks = parser.get_path_option('DIAGNOSTICS', 'SCRATCH_MASKS', '/scratch/Earth/ocean_masks') "Common scratch folder for masks" self.data_dir = parser.get_path_option('DIAGNOSTICS', 'DATA_DIR') "Root data folder path" @@ -204,16 +204,17 @@ class ExperimentConfig(object): self.members = parser.get_list_option('EXPERIMENT', 'MEMBERS') self.member_digits = parser.get_int_option('EXPERIMENT', 'MEMBER_DIGITS', 1) self.member_prefix = parser.get_option('EXPERIMENT', 'MEMBER_PREFIX', 'fc') + self.member_count_start = parser.get_int_option('EXPERIMENT', 'MEMBER_COUNT_START', 0) self.members = [int(mem) if mem.startswith(self.member_prefix) else int(mem) for mem in self.members] self.startdates = parser.get_option('EXPERIMENT', 'STARTDATES').split() self.chunk_size = parser.get_int_option('EXPERIMENT', 'CHUNK_SIZE') self.num_chunks = parser.get_int_option('EXPERIMENT', 'CHUNKS') self.calendar = parser.get_option('EXPERIMENT', 'CALENDAR', 'standard') self.model = parser.get_option('EXPERIMENT', 'MODEL') - self.atmos_timestep = parser.get_int_option('EXPERIMENT', 'ATMOS_TIMESTEP', 6) - self.ocean_timestep = parser.get_int_option('EXPERIMENT', 'OCEAN_TIMESTEP', 6) self.model_version = parser.get_option('EXPERIMENT', 'MODEL_VERSION', '') self.atmos_grid = parser.get_option('EXPERIMENT', 'ATMOS_GRID', '') + self.atmos_timestep = parser.get_int_option('EXPERIMENT', 'ATMOS_TIMESTEP', 6) + self.ocean_timestep = parser.get_int_option('EXPERIMENT', 'OCEAN_TIMESTEP', 6) def get_chunk_list(self): """ diff --git a/earthdiagnostics/earthdiags.py b/earthdiagnostics/earthdiags.py index dff13e0720b562a9a9c8e8c84ac539f9e788bcd1..7f93881296a1f5962e0022ccfe2d684ab2b0391b 100755 --- a/earthdiagnostics/earthdiags.py +++ b/earthdiagnostics/earthdiags.py @@ -245,7 +245,9 @@ class EarthDiags(object): @staticmethod def _register_general_diagnostics(): + Diagnostic.register(DailyMean) Diagnostic.register(MonthlyMean) + Diagnostic.register(YearlyMean) Diagnostic.register(Rewrite) Diagnostic.register(Relink) Diagnostic.register(RelinkAll) diff --git a/earthdiagnostics/general/__init__.py b/earthdiagnostics/general/__init__.py index 1c321cb46d27751ec57e05fd65a68a0128890e2e..2696ef623ab57bca72ccd6ebbf86243973988d1d 100644 --- a/earthdiagnostics/general/__init__.py +++ b/earthdiagnostics/general/__init__.py @@ -1,5 +1,7 @@ # coding=utf-8 from earthdiagnostics.general.monthlymean import MonthlyMean +from earthdiagnostics.general.dailymean import DailyMean +from earthdiagnostics.general.yearlymean import YearlyMean from earthdiagnostics.general.rewrite import Rewrite from earthdiagnostics.general.relink import Relink from earthdiagnostics.general.scale import Scale diff --git a/earthdiagnostics/general/dailymean.py b/earthdiagnostics/general/dailymean.py new file mode 100644 index 0000000000000000000000000000000000000000..ba9be504e70934caf1b82dacca1fefa2556196d7 --- /dev/null +++ b/earthdiagnostics/general/dailymean.py @@ -0,0 +1,96 @@ +# coding=utf-8 + +import os +from earthdiagnostics.diagnostic import Diagnostic, DiagnosticOption, DiagnosticDomainOption, \ + DiagnosticFrequencyOption, DiagnosticVariableOption +from earthdiagnostics.frequency import Frequencies +from earthdiagnostics.utils import Utils, TempFile +from earthdiagnostics.modelingrealm import ModelingRealm + + +class DailyMean(Diagnostic): + """ + Calculates daily mean for a given variable + + :original author: Javier Vegas-Regidor + + :created: July 2016 + + :param data_manager: data management object + :type data_manager: DataManager + :param startdate: startdate + :type startdate: str + :param member: member number + :type member: int + :param chunk: chunk's number + :type chunk: int + :param variable: variable's name + :type variable: str + :param domain: variable's domain + :type domain: ModelingRealm + :param frequency: original frequency + :type frequency: str + :param grid: original data grid + :type grid: str + """ + + alias = 'daymean' + "Diagnostic alias for the configuration file" + + def __init__(self, data_manager, startdate, member, chunk, domain, variable, frequency, grid): + Diagnostic.__init__(self, data_manager) + self.startdate = startdate + self.member = member + self.chunk = chunk + self.variable = variable + self.domain = domain + self.frequency = frequency + self.grid = grid + + def __str__(self): + return 'Calculate daily mean Startdate: {0} Member: {1} Chunk: {2} ' \ + 'Variable: {3}:{4} Original frequency: {5} Grid: {6}'.format(self.startdate, self.member, self.chunk, + self.domain, self.variable, + self.frequency, self.grid) + + def __eq__(self, other): + return self.startdate == other.startdate and self.member == other.member and self.chunk == other.chunk and \ + self.domain == other.domain and self.variable == other.variable and self.frequency == other.frequency and \ + self.grid == other.grid + + @classmethod + def generate_jobs(cls, diags, options): + """ + Creates a job for each chunk to compute the diagnostic + + :param diags: Diagnostics manager class + :type diags: Diags + :param options: variable, domain, frequency=day, grid='' + :type options: list[str] + :return: + """ + + options_available = (DiagnosticVariableOption('variable'), + DiagnosticDomainOption('domain'), + DiagnosticFrequencyOption('frequency'), + DiagnosticOption('grid', '')) + options = cls.process_options(options, options_available) + job_list = list() + for startdate, member, chunk in diags.config.experiment.get_chunk_list(): + job_list.append(DailyMean(diags.data_manager, startdate, member, chunk, + options['domain'], options['variable'], options['frequency'], options['grid'])) + return job_list + + def compute(self): + """ + Runs the diagnostic + """ + temp = TempFile.get() + variable_file = self.data_manager.get_file(self.domain, self.variable, self.startdate, self.member, self.chunk, + frequency=self.frequency, grid=self.grid) + Utils.cdo.daymean(input=variable_file, output=temp, options='-O') + os.remove(variable_file) + + self.send_file(temp, self.domain, self.variable, self.startdate, self.member, self.chunk, + frequency=Frequencies.daily, grid=self.grid) + diff --git a/earthdiagnostics/general/yearlymean.py b/earthdiagnostics/general/yearlymean.py new file mode 100644 index 0000000000000000000000000000000000000000..9eef8c9c0c438076665c5b47dc9f2f8dcd4a8dfa --- /dev/null +++ b/earthdiagnostics/general/yearlymean.py @@ -0,0 +1,96 @@ +# coding=utf-8 + +import os +from earthdiagnostics.diagnostic import Diagnostic, DiagnosticOption, DiagnosticDomainOption, \ + DiagnosticFrequencyOption, DiagnosticVariableOption +from earthdiagnostics.frequency import Frequencies +from earthdiagnostics.utils import Utils, TempFile +from earthdiagnostics.modelingrealm import ModelingRealm + + +class YearlyMean(Diagnostic): + """ + Calculates yearly mean for a given variable + + :original author: Javier Vegas-Regidor + + :created: July 2016 + + :param data_manager: data management object + :type data_manager: DataManager + :param startdate: startdate + :type startdate: str + :param member: member number + :type member: int + :param chunk: chunk's number + :type chunk: int + :param variable: variable's name + :type variable: str + :param domain: variable's domain + :type domain: ModelingRealm + :param frequency: original frequency + :type frequency: str + :param grid: original data grid + :type grid: str + """ + + alias = 'yearmean' + "Diagnostic alias for the configuration file" + + def __init__(self, data_manager, startdate, member, chunk, domain, variable, frequency, grid): + Diagnostic.__init__(self, data_manager) + self.startdate = startdate + self.member = member + self.chunk = chunk + self.variable = variable + self.domain = domain + self.frequency = frequency + self.grid = grid + + def __str__(self): + return 'Calculate yearly mean Startdate: {0} Member: {1} Chunk: {2} ' \ + 'Variable: {3}:{4} Original frequency: {5} Grid: {6}'.format(self.startdate, self.member, self.chunk, + self.domain, self.variable, + self.frequency, self.grid) + + def __eq__(self, other): + return self.startdate == other.startdate and self.member == other.member and self.chunk == other.chunk and \ + self.domain == other.domain and self.variable == other.variable and self.frequency == other.frequency and \ + self.grid == other.grid + + @classmethod + def generate_jobs(cls, diags, options): + """ + Creates a job for each chunk to compute the diagnostic + + :param diags: Diagnostics manager class + :type diags: Diags + :param options: variable, domain, frequency=day, grid='' + :type options: list[str] + :return: + """ + + options_available = (DiagnosticVariableOption('variable'), + DiagnosticDomainOption('domain'), + DiagnosticFrequencyOption('frequency'), + DiagnosticOption('grid', '')) + options = cls.process_options(options, options_available) + job_list = list() + for startdate, member, chunk in diags.config.experiment.get_chunk_list(): + job_list.append(YearlyMean(diags.data_manager, startdate, member, chunk, + options['domain'], options['variable'], options['frequency'], options['grid'])) + return job_list + + def compute(self): + """ + Runs the diagnostic + """ + temp = TempFile.get() + variable_file = self.data_manager.get_file(self.domain, self.variable, self.startdate, self.member, self.chunk, + frequency=self.frequency, grid=self.grid) + Utils.cdo.yearmean(input=variable_file, output=temp, options='-O') + os.remove(variable_file) + + self.send_file(temp, self.domain, self.variable, self.startdate, self.member, self.chunk, + frequency=Frequencies.yearly, grid=self.grid) + diff --git a/earthdiagnostics/ocean/rotation.py b/earthdiagnostics/ocean/rotation.py index 70525d60c686db2c5676cc52b55329760df16c8f..08adf41cd1cb7241bc7ac197fb6c52dfd8554bb8 100644 --- a/earthdiagnostics/ocean/rotation.py +++ b/earthdiagnostics/ocean/rotation.py @@ -88,28 +88,43 @@ class Rotation(Diagnostic): urotated = TempFile.get() vrotated = TempFile.get() - namelist_file = TempFile.get(suffix='') - rotate_namelist = open(namelist_file, 'w') - rotate_namelist.write("&nam_rotUV\n") - rotate_namelist.write(" Ufilein = {0}\n".format(ufile)) - rotate_namelist.write(" Uvarin = {0}\n".format(self.variableu)) - rotate_namelist.write(" Vfilein = {0}\n".format(vfile)) - rotate_namelist.write(" Vvarin = {0}\n".format(self.variablev)) - rotate_namelist.write(" meshmask = mask.nc\n") - rotate_namelist.write(" Ufileout = {0}\n".format(urotated)) - rotate_namelist.write(" Vfileout = {0}\n".format(vrotated)) - - rotate_namelist.writelines("/\n") - rotate_namelist.close() + namelist_file = self._create_namelist(ufile, urotated, vfile, vrotated) Utils.execute_shell_command('{0} {1}'.format(self.executable, namelist_file), Log.INFO) + ufile_handler = Utils.openCdf(ufile) + self._add_metadata_vars(ufile_handler, urotated) + self._add_metadata_vars(ufile_handler, vrotated) + ufile_handler.close() + os.remove(ufile) os.remove(vfile) self.send_file(urotated, self.domain, self.variableu, self.startdate, self.member, self.chunk, grid='rotated') self.send_file(vrotated, self.domain, self.variablev, self.startdate, self.member, self.chunk, grid='rotated') + def _create_namelist(self, ufile, urotated, vfile, vrotated): + namelist_file = TempFile.get(suffix='') + rotate_namelist = open(namelist_file, 'w') + rotate_namelist.write('&nam_rotUV\n') + rotate_namelist.write(' Ufilein = "{0}"\n'.format(ufile)) + rotate_namelist.write(' Uvarin = "{0}"\n'.format(self.variableu)) + rotate_namelist.write(' Vfilein = "{0}"\n'.format(vfile)) + rotate_namelist.write(' Vvarin = "{0}"\n'.format(self.variablev)) + rotate_namelist.write(' meshmask = "mask.nc"\n') + rotate_namelist.write(' Ufileout = "{0}"\n'.format(urotated)) + rotate_namelist.write('Vfileout = "{0}"\n'.format(vrotated)) + rotate_namelist.writelines("/\n") + rotate_namelist.close() + return namelist_file + + def _add_metadata_vars(self, reference_file_handler, rotaded_file): + rotated_handler = Utils.openCdf(rotaded_file) + for var in reference_file_handler.variables.keys(): + if var not in rotated_handler.variables.keys() and var not in [self.variableu, self.variablev]: + Utils.copy_variable(reference_file_handler, rotated_handler, var, True, True) + rotated_handler.close() + diff --git a/model_diags.conf b/model_diags.conf index 72bf0d20ad2e367d6c472c85447578f4d75d4b0b..0ac9a54e9f8fe1b83ed0a85a7a24ca59f22a0953 100644 --- a/model_diags.conf +++ b/model_diags.conf @@ -1,10 +1,16 @@ [DIAGNOSTICS] -# The next few configurations are mandatory - # Temporary folder for the calculations. Final results will never be stored here. SCRATCH_DIR = /scratch/Earth/$USER +# Common scratch folder for the ocean masks. This is useful to avoid replicating them for each run at the fat nodes. +# By default is '/scratch/Earth/ocean_masks' +# SCRATCH_MASKS = + +# By default, Earth Diagnostics only copies the mask files if they are not present in the scratch folder. If this +# option is set to true, Earth Diagnostics will copy them regardless of existence. Default is False. +# RESTORE_MESHES = + # ':' separated list of folders to look for data in. It will look for file in the path $DATA_FOLDER/$EXPID and # $DATA_FOLDER/$DATA_TYPE/$MODEL/$EXPID DATA_DIR = /esnas:/esarchive @@ -16,57 +22,92 @@ CON_FILES = /esnas/autosubmit/con_files/ # ignore it completely. FREQUENCY = mon -# All the other configurations in this section are optional - # Type of the dataset to use. It can be exp, obs or recon. Default is exp. -DATA_TYPE = exp +# DATA_TYPE = exp # This is used to choose the mechanism for storing and retrieving data. Options are CMOR (for our own experiments) or # THREDDS (for anything else). Default value is CMOR -DATA_ADAPTOR = CMOR +# DATA_ADAPTOR = CMOR +# Convention to use for file paths and names and variable naming among other things. Can be SPECS, PRIMAVERA or CMIP6. +# Default is SPECS. +DATA_CONVENTION = CMIP6 +# Path to the folder containing CDFTOOLS executables. By default is empty, so CDFTOOLS binaries must be added to the +# system path. +# CDFTOOLS_PATH = -* DATA_CONVENTION - Convention to use for file paths and names and variable naming among other things. Can be SPECS, PRIMAVERA or CMIP6. - Default is SPECS. +# Maximum number of cores to use. By default the diagnostics will use all cores available to them. It is not +# necessary when launching through a scheduler, as Earthdiagnostics can detect how many cores the scheduler has +# allocated to it. +# MAX_CORES = 1 -* CDFTOOLS_PATH - Path to the folder containing CDFTOOLS executables. By default is empty, so CDFTOOLS binaries must be added to the - system path. +# Diagnostics to run, space separated. You must provide for each one the name and the parameters (comma separated) or +# an alias defined in the ALIAS section (see more below). If you are using the diagnostics just to CMORize, leave it +# empty +DIAGS = -* MAX_CORES - Maximum number of cores to use. By default the diagnostics will use all cores available to them. It is not - necessary when launching through a scheduler, as Earthdiagnostics can detect how many cores the scheduler has - allocated to it. +[EXPERIMENT] -# Data adaptor type: CMOR (for our experiments), THREDDS (for other experiments) +# Institute that made the experiment, observation or reconstruction +INSTITUTE = BSC +# Name of the model used for the experiment. +MODEL = EC-EARTH -# Root path for the cmorized data to use +# Model version. Used to get the correct mask and mesh files. +# Available versions: +# Ec2.3_O1L42 +# Ec3.0_O1L46 Ec3.0_O25L46 Ec3.0_O25L75 +# Ec3.1_O1L46 Ec3.1_O25L75 +# Ec3.2beta_O1L75 Ec3.2_O1L75 Ec3.2_O25L75 +# N3.2_O1L42 N3.3_O1L46 N3.6_O025L75 N3.6_O1L75 N3.6_O25L75 +# nemovar_O1L42 CNRM_O1L42.nc glorys2v1_O25L75 ucl_O2L31 +# ORCA12L75 +MODEL_VERSION =Ec3.2_O1L75 -# Specify if your data is from an experiment (exp), observation (obs) or reconstructions (recon) +# Time between outputs from the atmosphere. This is not the model simulation timestep! Default is 6 +ATMOS_TIMESTEP = 6 -# CMORization type to use. Important also for THREDDS as it affects variable name conventions. -# Options: SPECS (default), PRIMAVERA, CMIP6 +# Time between outputs from the ocean. This is not the model simulation timestep! Default is 6 +OCEAN_TIMESTEP = 6 -# Path to NEMO's mask and grid files needed for CDFTools +# Unique identifier for the experiment +EXPID = -# Diagnostics to run, space separated. You must provide for each one the name and the parameters (comma separated) or -# an alias defined in the ALIAS section (see more below). If you are using the diagnostics just to CMORize, leave it -# empty -DIAGS = -# DIAGS = OHC -# Frequency of the data you want to use by default. Some diagnostics do not use this value: i.e. monmean always stores -# its results at monthly frequency (obvious) and has a parameter to specify input's frequency. +# Startdates to run as a space separated list +STARTDATES = + +# Members to run as a space separated list. You can just provide the number or also add the prefix +MEMBERS = + +# Number of minimum digits to compose the member name. By default it is 1. For example, for member 1 member name +# will be fc1 if MEMBER_DIGITS is 1 or fc01 if MEMBER_DIGITS is 2 +MEMBER_DIGITS = + +# Prefix to use for the member names. By default is 'fc' +MEMBER_PREFIX = + +# Number corresponding to the first member. For example, if your first member is 'fc1', it should be 1. +# If it is 'fc0', it should be 0. By default is 0 +MEMBER_COUNT_START = + +# Length of the chunks in months +CHUNK_SIZE = + +# Number of chunks to run +CHUNKS = + +# Atmospheric grid definition. Will be used as a default target for interpolation diagnostics. +# ATMOS_GRID = + +# Experiment's name. By default it is the EXPID. +# NAME = + +# Calendar to use for date calculation. All calendars supported by Autosubmit are available. Default is 'standard' +# CALENDAR = -# Path to CDFTOOLS binaries -CDFTOOLS_PATH = ~jvegas/CDFTOOLS/bin -# If true, copies the mesh files regardless of presence in scratch dir -RESTORE_MESHES = False -# Limits the maximum amount of threads used. Default: 0 (no limitation, one per virtual core available) -MAX_CORES = 1 [CMOR] # If true, recreates CMOR files regardless of presence. Default = False @@ -107,34 +148,6 @@ ATMOS_MONTHLY_VARS = 167, 201, 202, 165, 166, 151, 144, 228, 205, 182, 164, 146, [THREDDS] SERVER_URL = https://earth.bsc.es/thredds -[EXPERIMENT] -# Experiments parameters as defined in CMOR standard -INSTITUTE = BSC -MODEL = EC-EARTH -# Model version: Available versions -MODEL_VERSION =Ec3.2_O1L75 -# Atmospheric output timestep in hours -ATMOS_TIMESTEP = 6 -# Ocean output timestep in hours -OCEAN_TIMESTEP = 6 - -# For those who use Autosubmit, this will be easy -# EXPID is the unique identifier of the experiment. -# STARTDATES is the list of start dates -# MEMBERS is the list of members of your experiment (only the numbers, the fc will be added by the tool) -# MEMBER_DIGITS is the minimum number of digits to use for the member name: if 1 the name for member 0 will be fc0, -# if 2, fc00 -# CHUNK_SIZE is the size of each data file, given in months -# CHUNKS is the number of chunks. You can specify less chunks than present on the experiment -EXPID = a0c2 -STARTDATES = 19900101 -MEMBERS = 0 -MEMBER_DIGITS = 1 -CHUNK_SIZE = 12 -CHUNKS = 2 -# CHUNKS = 1 - - # This ALIAS section is a bit different # Inside this, you can provide alias for frequent diagnostics calls. # By default, there are some of the diagnostics available at the previous version.