Conversation
There was a problem hiding this comment.
this file should not exist in the repo - it should only exist in the experiment. A way to avoid this file being in the repo is to have swell create this file based on the initial date/time of the experiment. From there on, the experiment (GCM) will create this file on its own; the file can then be recycled from one cycle to the next.
There was a problem hiding this comment.
removing cap_restart. Note that prep_forecast.py handles writing the correct initial date/time for the experiment.
| geoscf_jedi.format: 'CFIO', | ||
| geoscf_jedi.mode: 'instantaneous' , | ||
| #geoscf_jedi.frequency: 010000, | ||
| geoscf_jedi.frequency: >>SWELL_FC_OUTPUT_FREQ<<, |
There was a problem hiding this comment.
We should talk about the naming conventions for these templated frequencies and such.
| bkg_steps = [] | ||
|
|
||
| # Parse config | ||
| background_experiment = self.config.background_experiment() |
There was a problem hiding this comment.
I am trying to understand the reason for the changes here. Is this because the backgrounds for various cycles for the swell experiment can be located outside of r2d2?
There was a problem hiding this comment.
Please see the comment in the code. For the first cycle the backgrounds are fetched from R2D2 using the experiment_id specified by the user. For the cycles after that swell ('get_background.py') fetches the backgrounds files from the 12h forecast done in the previous cycles. Those forecast files from the previous cycle get updloaded to R2D2 with the current experiment id. In the following cycle this experiment id is used to fetch those forecast files and will be used as backgrounds for the current cycle.
| @@ -0,0 +1,19 @@ | |||
| SpeciesName: CO | |||
There was a problem hiding this comment.
I puzzled as to why this RC and other RCs and GEOS yaml need to be here. These files should be in the tag of GEOS that supports CF, no? What am I missing?
There was a problem hiding this comment.
For each cycle, FileTemplate is replaced to point to the JEDI increment file. I'm keeping all the RC files that are modified for each cycle in SWELL. The rest of RC files are copied from a tagged version of GEOS specified in suite_config.py: geos_cf_run_dir('/discover/nobackup/mabdiosk/rundir/GCv14.0_GCMv1.17_c90_Skylab')
I think this way we can easily keep track of what goes into the swell experiment.
| @@ -0,0 +1,20 @@ | |||
| SpeciesName: NO2 | |||
There was a problem hiding this comment.
Same comment as above for RC files ...
| @@ -0,0 +1,2769 @@ | |||
| Samplings: | |||
There was a problem hiding this comment.
Same comment as for the RC files - this should be in the GEOS tag and in the settings of your experiment.
|
Should this be moved out of the draft status at this point? Ideally we want this ready for merge ASAP even if this is isn't perfect this is IMO good enough and replicates what has been done in slylab. Over time a few improvements on top of my head:
|
There was a problem hiding this comment.
Since this script and the RunForecast task are relatively simple, would it be possible to run the executable directly from the task runtime like how Doruk uses gcm_run.j?
[[RunForecast-{{model_component}}]]
script = "{{experiment_path}}/run/$datetime/{{model_component}}/gcm_run_geoscf.j"
platform = {{platform}}
execution time limit = {{scheduling["RunForecast"]["execution_time_limit"]}}
[[[directives]]]
--output="{{experiment_path}}/run/$datetime/{{model_component}}/gcm_run.log"
{%- for key, value in scheduling["RunForecast"]["directives"][model_component].items() %}
--{{key}} = {{value}}
{%- endfor %}
| echo "Submitting GCM job: ${GCM_SCRIPT}" | ||
|
|
||
| set +e | ||
| sbatch --wait --output=${LOG_FILE} ${GCM_SCRIPT} |
There was a problem hiding this comment.
If I'm not mistaken the RunForecast task will be queued into slurm, then this will allocate its own job on top of that. This command also failed for me when I tried it
| # For experiments with cycle in the suite name: | ||
| # for the first cycle, use background_experiment in config | ||
| # as the experiment id for fetching from r2d2 for cycles after | ||
| # the first, use the current experiment id for fetching from r2d2 | ||
| if self.cycle_time_dto() != self.start_cycle_point_dto() and 'cycle' in self.suite_name(): | ||
| background_experiment = self.config.r2d2_experiment_id() | ||
| else: | ||
| background_experiment = self.config.background_experiment() | ||
|
|
||
| self.logger.info(f'Fetching background from experiment {background_experiment}') | ||
|
|
There was a problem hiding this comment.
Will this affect 3dvar_marine_cycle and 3dfgat_marine_cycle?
Description
This PR adds a new cycling 3DVar suite for GEOS-CF. The experiment is designed to run a 12h forecast starting from the beginning of the assimilation window and apply the increment from the middle of the window using IAU. The forecast length and frequency can be set using
forecast_lengthandforecast_output_frequencybut I didn't test changing the forecast length.Summary of changes:
RC files that get templated with SWELL are in
src/swell/configuration/jedi/interfaces/geos_cf/namelists. The remaining RC files (static) are copied into the scratch directory from geos_cf_run_dir.get_backgroundtask fetches backgrounds from R2D2 usingbackground_experimentin the config as the experiment ID. In cycling experiments (those with "cycle" in their name), the experiment ID is set tobackground_experimentfor the first cycle. For subsequent cycles, it is set to ther2d2_experiment_idof the current experiment, so that backgrounds from the previous cycle are fetched for the variational task in the current one.save_forecasttask stores forecasts in R2D2 using r2d2_experiment_idas the experiment ID. These files are then fetched from R2D2 during theget_backgroundtask.Restarts are saved (
save_restart) and fetched (get_restart) from R2D2. To save space, restart files are not stored on R2D2 at every cycle. Therst_store_intervalkey controls how many cycles pass before restart files are stored as real files rather than symlinks. In intermediate cycles, restarts are saved as symlinks.prep_forecast prepares the scratch directory within the current cycle's run directory:
geos_cf_run_dirand copies/edits RC files fromsrc/swell/configuration/jedi/interfaces/geos_cf/namelists.inc_template.run_forecastsubmits gcm_run_geoscf.j (a lighter version ofgcm_run.jused for running GEOS-CF) to the queue and waits until the job finishes. One limitation: the Cylc interface shows this job as "running" whether it is waiting in the queue or actually executing. There may be better approaches for handlinggcm_run.jexecution.clean_cycle.pynow cleans the scratch directory of the previous cycle after the current cycle completes. This way, the restart files from the previous cycle that are saved as symlinks are kept until the current cycle uses them.