diff --git a/examples/mean_values.config b/examples/mean_values.config index 5fcb0b7d34e8d57c42d4639dfe94372092c8f565..13dccea661c63ac7e9c652a73acce09409647cc6 100644 --- a/examples/mean_values.config +++ b/examples/mean_values.config @@ -3,7 +3,7 @@ # EXP_ID = mean_values -EXPNAME = amip-LR +EXP_TYPE = amip-LR QUEUE_TYPE = blizzard ACCOUNT = xy9999 diff --git a/examples/old_input_data.config b/examples/old_input_data.config index 2f53e01d6d6f7d0e05996e14f41d2543966a5435..16210bcb4ff0c287c1def5b8ee87d3137b915ec2 100644 --- a/examples/old_input_data.config +++ b/examples/old_input_data.config @@ -3,7 +3,7 @@ # EXP_ID = old_input_data -EXPNAME = amip-LR +EXP_TYPE = amip-LR QUEUE_TYPE = blizzard ACCOUNT = xy9999 diff --git a/examples/reference.config b/examples/reference.config index f0e1a9137b4c05746502a8f17a1e9aa136974dae..05421c587ca48b0502b44df2de8f26267a757a88 100644 --- a/examples/reference.config +++ b/examples/reference.config @@ -3,7 +3,7 @@ # EXP_ID = reference -EXPNAME = amip-LR +EXP_TYPE = amip-LR QUEUE_TYPE = blizzard ACCOUNT = xy9999 diff --git a/mkexp b/mkexp index 159bede73959453432f72e7c6468918f94e5ca31..57b1af134380ece79e1b01a24f286adf98c02e9a 100755 --- a/mkexp +++ b/mkexp @@ -54,11 +54,11 @@ def chmod_plus_x(file_name): # Templates -def get_template_name(experiment_type, job_id): +def get_template_name(experiment_kind, job_id): '''Determine script template, taking system default if type is unsupported.''' - run_template_name = os.path.join(exp_lib_dir, experiment_type+'.'+job_id+'.tmpl') + run_template_name = os.path.join(exp_lib_dir, experiment_kind+'.'+job_id+'.tmpl') if not os.path.exists(run_template_name): - logging.warning("no %s template for '%s', using default", job_id, experiment_type) + logging.warning("no %s template for '%s', using default", job_id, experiment_kind) run_template_name = os.path.join(exp_lib_dir, default_name+'.'+job_id+'.tmpl') return run_template_name @@ -153,8 +153,8 @@ experiment_config_name = sys.argv[1] pre_config = ConfigObj(experiment_config_name, interpolation=False) experiment_id = pre_config['EXP_ID'] -experiment_name = pre_config['EXPNAME'] -experiment_type = re.sub(r'-\wR$', '', experiment_name) +experiment_type = pre_config['EXP_TYPE'] +experiment_kind = re.sub(r'-\wR$', '', experiment_type) queue_type = pre_config['QUEUE_TYPE'] pre_config = None @@ -171,12 +171,12 @@ lib_config_name = os.path.join(exp_lib_dir, default_name+'.config') pre_config.merge(ConfigObj(lib_config_name, interpolation=False)) split_jobs(pre_config) -lib_config_name = os.path.join(exp_lib_dir, experiment_name+'.config') +lib_config_name = os.path.join(exp_lib_dir, experiment_type+'.config') if os.path.exists(lib_config_name): pre_config.merge(ConfigObj(lib_config_name, interpolation=False)) split_jobs(pre_config) else: - logging.warning("cannot find config for '%s', using default only", experiment_name) + logging.warning("cannot find config for '%s', using default only", experiment_type) # Re-read config to allow overriding default settings # TODO: probably nicer if default experiment is given as argument @@ -238,6 +238,6 @@ for subjob, subconfig in config['jobs'].iteritems(): if 'extends' in config['JOB']: template_job = config['JOB']['extends'] expand_template(config, - get_template_name(experiment_type, template_job), + get_template_name(experiment_kind, template_job), get_script_name(experiment_id, subjob)) diff --git a/standard_experiments/DEFAULT.run.tmpl b/standard_experiments/DEFAULT.run.tmpl index 66603a6f3b4f5a937a10109eb94a3b2da1ba4bcc..2d1a556860676eef3938c952518293024fccdb08 100644 --- a/standard_experiments/DEFAULT.run.tmpl +++ b/standard_experiments/DEFAULT.run.tmpl @@ -31,7 +31,7 @@ START=%{JOB.start} # followed by a number for the current experiment # EXP="%{EXP_ID}" # experiment identifier -expname="%{EXPNAME}" # experiments name +expname="%{EXP_TYPE}" # experiments name # RERUN=.true. # Rerun switch; .false. for initial run, .true. else # diff --git a/standard_experiments/amip.run.tmpl b/standard_experiments/amip.run.tmpl index bc362393cb6b8397cc43ad4322ab53361cd45ca5..1361d95d1ba41c0688cf42088a46ade1d9da5aef 100644 --- a/standard_experiments/amip.run.tmpl +++ b/standard_experiments/amip.run.tmpl @@ -31,7 +31,7 @@ START=%{JOB.start} # followed by a number for the current experiment # EXP="%{EXP_ID}" # experiment identifier -expname="%{EXPNAME}" # experiments name +expname="%{EXP_TYPE}" # experiments name # RERUN=.true. # Rerun switch; .false. for initial run, .true. else # diff --git a/standard_experiments/sstClim.run.tmpl b/standard_experiments/sstClim.run.tmpl index f9df526c68755d284b6bf5e5690d3b2fbf76de77..a3d254fa2661f35998936332759c122e65b4c849 100644 --- a/standard_experiments/sstClim.run.tmpl +++ b/standard_experiments/sstClim.run.tmpl @@ -31,7 +31,7 @@ START=%{JOB.start} # followed by a number for the current experiment # EXP="%{EXP_ID}" # experiment identifier -expname="%{EXPNAME}" # experiments name +expname="%{EXP_TYPE}" # experiments name # RERUN=.true. # Rerun switch; .false. for initial run, .true. else #