-
Notifications
You must be signed in to change notification settings - Fork 119
/
FV3LAM_wflow.xml
2993 lines (2659 loc) · 141 KB
/
FV3LAM_wflow.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
{#
This is a Jinja-enabled Rocoto XML template. It is filled in using the
fill_template.py script, and is done automatically by the
generate_workflow.sh step of preparing a regional workflow configured
experiment.
See README.xml_templating.md for information on using the Templating mechanisms.
-#}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE workflow [
<!--
Parameters needed by the job scheduler.
-->
<!ENTITY ACCOUNT "{{ account }}">
<!ENTITY SCHED "{{ sched }}">
<!ENTITY QUEUE_DEFAULT "{{ queue_default }}">
<!ENTITY QUEUE_HPSS "{{ queue_hpss }}">
<!ENTITY QUEUE_FCST "{{ queue_fcst }}">
<!--
Workflow task names.
-->
{%- if sched_native_cmd %}
<!ENTITY SCHED_NATIVE_CMD "{{ sched_native_cmd }}">
{%- else %}
<!ENTITY SCHED_NATIVE_CMD "">
{%- endif %}
<!ENTITY TN_MAKE_GRID "{{ tn_make_grid }}">
<!ENTITY TN_MAKE_OROG "{{ tn_make_orog }}">
<!ENTITY TN_MAKE_SFC_CLIMO "{{ tn_make_sfc_climo }}">
<!ENTITY TN_GET_EXTRN_ICS "{{ tn_get_extrn_ics }}">
<!ENTITY TN_GET_EXTRN_LBCS "{{ tn_get_extrn_lbcs }}">
<!ENTITY TN_MAKE_ICS "{{ tn_make_ics }}">
<!ENTITY TN_MAKE_LBCS "{{ tn_make_lbcs }}">
<!ENTITY TN_RUN_FCST "{{ tn_run_fcst }}">
<!ENTITY TN_RUN_POST "{{ tn_run_post }}">
{%- if fcst_len_hrs == -1 %}
<!ENTITY TN_RUN_POST_CYC1 "{{ tn_run_post }}_c1">
<!ENTITY TN_RUN_POST_CYC2 "{{ tn_run_post }}_c2">
<!ENTITY TN_RUN_POST_CYC3 "{{ tn_run_post }}_c3">
<!ENTITY TN_RUN_POST_CYC4 "{{ tn_run_post }}_c4">
{%- endif%}
<!ENTITY TN_RUN_PRDGEN "{{ tn_run_prdgen }}">
<!ENTITY TN_PLOT_ALLVARS "{{ tn_plot_allvars }}">
<!ENTITY TN_GET_OBS_CCPA "{{ tn_get_obs_ccpa }}">
<!ENTITY TN_GET_OBS_NDAS "{{ tn_get_obs_ndas }}">
<!ENTITY TN_GET_OBS_MRMS "{{ tn_get_obs_mrms }}">
{%- if run_tasks_metvx_det or run_tasks_metvx_ens %}
<!ENTITY TN_RUN_MET_PB2NC_OBS "{{ tn_run_met_pb2nc_obs }}">
<!ENTITY TN_RUN_MET_PCPCOMBINE "{{ tn_run_met_pcpcombine }}">
{%- endif%}
{%- if run_tasks_metvx_det %}
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_APCP01H "{{ tn_run_met_gridstat_vx_apcp01h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_APCP03H "{{ tn_run_met_gridstat_vx_apcp03h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_APCP06H "{{ tn_run_met_gridstat_vx_apcp06h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_APCP24H "{{ tn_run_met_gridstat_vx_apcp24h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_REFC "{{ tn_run_met_gridstat_vx_refc }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_RETOP "{{ tn_run_met_gridstat_vx_retop }}">
<!ENTITY TN_RUN_MET_POINTSTAT_VX_SFC "{{ tn_run_met_pointstat_vx_sfc }}">
<!ENTITY TN_RUN_MET_POINTSTAT_VX_UPA "{{ tn_run_met_pointstat_vx_upa }}">
{%- endif%}
{%- if run_tasks_metvx_ens %}
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_APCP01H "{{ tn_run_met_ensemblestat_vx_apcp01h }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_APCP03H "{{ tn_run_met_ensemblestat_vx_apcp03h }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_APCP06H "{{ tn_run_met_ensemblestat_vx_apcp06h }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_APCP24H "{{ tn_run_met_ensemblestat_vx_apcp24h }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_REFC "{{ tn_run_met_ensemblestat_vx_refc }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_RETOP "{{ tn_run_met_ensemblestat_vx_retop }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_SFC "{{ tn_run_met_ensemblestat_vx_sfc }}">
<!ENTITY TN_RUN_MET_ENSEMBLESTAT_VX_UPA "{{ tn_run_met_ensemblestat_vx_upa }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSMEAN_APCP01H "{{ tn_run_met_gridstat_vx_ensmean_apcp01h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSMEAN_APCP03H "{{ tn_run_met_gridstat_vx_ensmean_apcp03h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSMEAN_APCP06H "{{ tn_run_met_gridstat_vx_ensmean_apcp06h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSMEAN_APCP24H "{{ tn_run_met_gridstat_vx_ensmean_apcp24h }}">
<!ENTITY TN_RUN_MET_POINTSTAT_VX_ENSMEAN_SFC "{{ tn_run_met_pointstat_vx_ensmean_sfc }}">
<!ENTITY TN_RUN_MET_POINTSTAT_VX_ENSMEAN_UPA "{{ tn_run_met_pointstat_vx_ensmean_upa }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSPROB_APCP01H "{{ tn_run_met_gridstat_vx_ensprob_apcp01h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSPROB_APCP03H "{{ tn_run_met_gridstat_vx_ensprob_apcp03h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSPROB_APCP06H "{{ tn_run_met_gridstat_vx_ensprob_apcp06h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSPROB_APCP24H "{{ tn_run_met_gridstat_vx_ensprob_apcp24h }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSPROB_REFC "{{ tn_run_met_gridstat_vx_ensprob_refc }}">
<!ENTITY TN_RUN_MET_GRIDSTAT_VX_ENSPROB_RETOP "{{ tn_run_met_gridstat_vx_ensprob_retop }}">
<!ENTITY TN_RUN_MET_POINTSTAT_VX_ENSPROB_SFC "{{ tn_run_met_pointstat_vx_ensprob_sfc }}">
<!ENTITY TN_RUN_MET_POINTSTAT_VX_ENSPROB_UPA "{{ tn_run_met_pointstat_vx_ensprob_upa }}">
{%- endif%}
<!ENTITY GET_OBS_LOCAL_MODULE_FN "{{get_obs_local_module_fn}}">
{%- if run_tasks_metvx_det or run_tasks_metvx_ens %}
<!ENTITY VX_LOCAL_MODULE_FN "{{vx_local_module_fn}}">
{%- endif %}
{%- if run_task_aqm_ics %}
<!ENTITY TN_AQM_EXTRN_ICS "{{ tn_aqm_ics }}_ext">
<!ENTITY TN_AQM_ICS "{{ tn_aqm_ics }}">
{%- endif %}
{%- if run_task_aqm_lbcs %}
<!ENTITY TN_AQM_LBCS "{{ tn_aqm_lbcs }}">
{%- endif %}
{%- if run_task_nexus_gfs_sfc %}
<!ENTITY TN_NEXUS_GFS_SFC "{{ tn_nexus_gfs_sfc }}">
{%- endif %}
{%- if run_task_nexus_emission %}
<!ENTITY TN_NEXUS_EMISSION "{{ tn_nexus_emission }}">
<!ENTITY TN_NEXUS_POST_SPLIT "{{ tn_nexus_post_split }}">
{%- endif %}
{%- if run_task_fire_emission %}
<!ENTITY TN_FIRE_EMISSION "{{ tn_fire_emission }}">
{%- endif %}
{%- if run_task_point_source %}
<!ENTITY TN_POINT_SOURCE "{{ tn_point_source }}">
{%- endif %}
{%- if run_task_pre_post_stat %}
<!ENTITY TN_PRE_POST_STAT "{{ tn_pre_post_stat }}">
{%- endif %}
{%- if run_task_post_stat_o3 %}
<!ENTITY TN_POST_STAT_O3 "{{ tn_post_stat_o3 }}">
{%- endif %}
{%- if run_task_post_stat_pm25 %}
<!ENTITY TN_POST_STAT_PM25 "{{ tn_post_stat_pm25 }}">
{%- endif %}
{%- if run_task_bias_correction_o3 %}
<!ENTITY TN_BIAS_CORRECTION_O3 "{{ tn_bias_correction_o3 }}">
{%- endif %}
{%- if run_task_bias_correction_pm25 %}
<!ENTITY TN_BIAS_CORRECTION_PM25 "{{ tn_bias_correction_pm25 }}">
{%- endif %}
<!--
Flags that specify whether to run the preprocessing and/or verification tasks.
-->
<!ENTITY RUN_TASK_MAKE_GRID "{{ run_task_make_grid | upper }}">
<!ENTITY RUN_TASK_MAKE_OROG "{{ run_task_make_orog | upper }}">
<!ENTITY RUN_TASK_MAKE_SFC_CLIMO "{{ run_task_make_sfc_climo | upper }}">
<!--
Number of physical cores per node for the current machine. This is used
below in the <nodesize> tag, but that tag is not clearly documented. This
parameter may be unnecessary since each task now has its own variable that
specifies the number of processes per node being used (the PPN_... entities).
-->
<!ENTITY NCORES_PER_NODE "{{ ncores_per_node }}">
<!--
Directories and files.
-->
<!ENTITY USHdir "{{ ushdir }}">
<!ENTITY JOBSdir "{{ jobsdir }}">
<!ENTITY SCRIPTSdir "{{ scriptsdir }}">
<!ENTITY COMIN_BASEDIR "{{ comin_basedir }}">
<!ENTITY COMOUT_BASEDIR "{{ comout_basedir }}">
<!ENTITY GLOBAL_VAR_DEFNS_FP "{{ global_var_defns_fp }}">
<!ENTITY LOAD_MODULES_RUN_TASK_FP "{{ load_modules_run_task_fp }}">
<!ENTITY EXPTDIR "{{ exptdir }}">
{%- if run_envir == "nco" %}
{%- if do_ensemble %}
<!ENTITY DYN_DIR "{{ dataroot }}/run_fcst_{{ ensmem_indx_name }}#{{ ensmem_indx_name }}#.{{ workflow_id }}_<cyclestr>@Y@m@d@H</cyclestr>/dyn">
<!ENTITY PHY_DIR "{{ dataroot }}/run_fcst_{{ ensmem_indx_name }}#{{ ensmem_indx_name }}#.{{ workflow_id }}_<cyclestr>@Y@m@d@H</cyclestr>/phy">
{%- else %}
<!ENTITY DYN_DIR "{{ dataroot }}/run_fcst.{{ workflow_id }}_<cyclestr>@Y@m@d@H</cyclestr>/dyn">
<!ENTITY PHY_DIR "{{ dataroot }}/run_fcst.{{ workflow_id }}_<cyclestr>@Y@m@d@H</cyclestr>/phy">
{%- endif %}
<!ENTITY COMIN_DIR "{{ comin_basedir }}/{{ run }}.@Y@m@d/@H">
{%- else %}
<!ENTITY DYN_DIR "{{ comout_basedir }}/<cyclestr>@Y@m@d@H</cyclestr>{{ slash_ensmem_subdir }}/dyn">
<!ENTITY PHY_DIR "{{ comout_basedir }}/<cyclestr>@Y@m@d@H</cyclestr>{{ slash_ensmem_subdir }}/phy">
<!ENTITY COMIN_DIR "{{ comin_basedir }}/@Y@m@d@H{{ slash_ensmem_subdir }}">
{%- endif %}
{%- if run_envir == "nco" %}
<!ENTITY LOGDIR "{{ logbasedir }}/<cyclestr>@Y@m@d</cyclestr>">
<!ENTITY LOGEXT ".{{ workflow_id }}.log" >
{%- else %}
<!ENTITY LOGDIR "{{ logbasedir }}">
<!ENTITY LOGEXT ".log" >
{%- endif %}
<!ENTITY CMPEXT "_task_complete.txt">
<!ENTITY MET_INSTALL_DIR "{{ met_install_dir }}">
<!ENTITY METPLUS_PATH "{{ metplus_path }}">
<!ENTITY METPLUS_CONF "{{ metplus_conf }}">
<!ENTITY MET_CONFIG "{{ met_config }}">
<!ENTITY CCPA_OBS_DIR "{{ ccpa_obs_dir }}">
<!ENTITY MRMS_OBS_DIR "{{ mrms_obs_dir }}">
<!ENTITY NDAS_OBS_DIR "{{ ndas_obs_dir }}">
<!ENTITY WARMSTART_CYCLE_DIR "{{ warmstart_cycle_dir }}">
{%- if do_real_time %}
<!ENTITY COMINgfs "{{ comingfs }}">
{%- endif %}
<!--
Reservation types. Reservations specify the queue/partition and account
to use for a given task. The "DEFAULT" reservation type is used for all
tasks other than TN_GET_EXTRN_ICS, TN_GET_EXTRN_LBCS, and TN_RUN_FCST;
the "HPSS" type is used for the TN_GET_EXTRN_ICS and TN_GET_EXTRN_LBCS
tasks; and the "FCST" type is used for the TN_RUN_FCST task.
-->
{%- if partition_default is not none %}
<!ENTITY RSRV_DEFAULT "<account>&ACCOUNT;</account><queue>&QUEUE_DEFAULT;</queue><partition>{{ partition_default }}</partition>">
{%- else %}
<!ENTITY RSRV_DEFAULT "<account>&ACCOUNT;</account><queue>&QUEUE_DEFAULT;</queue>">
{%- endif %}
{%- if partition_hpss is not none %}
<!ENTITY RSRV_HPSS "<account>&ACCOUNT;</account><queue>&QUEUE_HPSS;</queue><partition>{{ partition_hpss }}</partition>">
{%- else %}
<!ENTITY RSRV_HPSS "<account>&ACCOUNT;</account><queue>&QUEUE_HPSS;</queue>">
{%- endif %}
{%- if partition_fcst is not none %}
<!ENTITY RSRV_FCST "<account>&ACCOUNT;</account><queue>&QUEUE_FCST;</queue><partition>{{ partition_fcst }}</partition>">
{%- else %}
<!ENTITY RSRV_FCST "<account>&ACCOUNT;</account><queue>&QUEUE_FCST;</queue>">
{%- endif %}
]>
<workflow realtime="F" scheduler="&SCHED;" cyclethrottle="200" taskthrottle="{{ taskthrottle }}">
{# Double quotes are required inside the strftime! Expect an error from reading the template if using single quotes. #}
<cycledef group="at_start">{{ cdate_first_cycl.strftime("%M %H %d %m %Y *") }}</cycledef>
<cycledef group="forecast">
{{- date_first_cycl ~ " " ~ date_last_cycl ~ " " ~ cycl_freq -}}
</cycledef>
{%- if cycl_next != date_first_cycl %}
<cycledef group="cycled">
{{- cycl_next ~ " " ~ date_last_cycl ~ " " ~ cycl_freq -}}
</cycledef>
{%- endif %}
{%- if fcst_len_hrs == -1 %}
{%- if num_fcst_len_cycl >= 1 %}
<cycledef group="cyc_1st"> {{- date_first_cycl ~ " " ~ date_1st_last_cycl ~ " " ~ "24:00:00" -}} </cycledef>
{%- endif %}
{%- if num_fcst_len_cycl >= 2 %}
<cycledef group="cyc_2nd"> {{- date_2nd_cycl ~ " " ~ date_2nd_last_cycl ~ " " ~ "24:00:00" -}} </cycledef>
{%- endif %}
{%- if num_fcst_len_cycl >= 3 %}
<cycledef group="cyc_3rd"> {{- date_3rd_cycl ~ " " ~ date_3rd_last_cycl ~ " " ~ "24:00:00" -}} </cycledef>
{%- endif %}
{%- if num_fcst_len_cycl >= 4 %}
<cycledef group="cyc_4th"> {{- date_4th_cycl ~ " " ~ date_4th_last_cycl ~ " " ~ "24:00:00" -}} </cycledef>
{%- endif %}
{%- endif %}
<log>
{%- if run_envir == "nco" %}
&LOGDIR;/FV3LAM_wflow.{{ workflow_id }}.log
{%- else %}
&LOGDIR;/FV3LAM_wflow.log
{%- endif %}
</log>
<!--
The following command works to call the J-job for a given task (in this
case the TN_MAKE_GRID task) if in the script LOAD_MODULES_RUN_TASK_FP we
do NOT call exec to run the J-job. The command first sources the script
LOAD_MODULES_RUN_TASK_FP and then runs the J-job, so it is simpler than
calling exec and thus preferred if NCO accepts it. Note that the portion
of the command that sources LOAD_MODULES_RUN_TASK_FP also passes an
argument to it (the argument being the name of the task). This works in
bash but it probably won't work in sh.
If this method is acceptable to NCO, then for clarity maybe we can
source LOAD_MODULES_RUN_TASK_FP within the J-job instead of here since
we are already sourcing other files in the J-job anyway.
-->
<!--
<command>{ . &LOAD_MODULES_RUN_TASK_FP; "&TN_MAKE_GRID;";
&JOBSdir;/JREGIONAL_MAKE_GRID;
}</command>
-->
<!--
The following command works if we call exec in LOAD_MODULES_RUN_TASK_FP
to run the J-job. This passes the J-job script as the second argument
to LOAD_MODULES_RUN_TASK_FP (the first argument is the task name). The
J-job then uses exec to run the J-job (while also terminating the LOAD_-
MODULES_RUN_TASK_FP script.
-->
{%- if run_task_make_grid %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_MAKE_GRID;" cycledefs="at_start" maxtries="{{ maxtries_make_grid }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_MAKE_GRID;" "&JOBSdir;/JREGIONAL_MAKE_GRID"</command>
<nodes>{{ nnodes_make_grid }}:ppn={{ ppn_make_grid }}</nodes>
<walltime>{{ wtime_make_grid }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
<jobname>&TN_MAKE_GRID;</jobname>
<join>&LOGDIR;/&TN_MAKE_GRID;&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
</task>
{%- endif %}
{%- if run_task_make_orog %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_MAKE_OROG;" cycledefs="at_start" maxtries="{{ maxtries_make_orog }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_MAKE_OROG;" "&JOBSdir;/JREGIONAL_MAKE_OROG"</command>
<nodes>{{ nnodes_make_orog }}:ppn={{ ppn_make_orog }}</nodes>
<walltime>{{ wtime_make_orog }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
<jobname>&TN_MAKE_OROG;</jobname>
<join>&LOGDIR;/&TN_MAKE_OROG;&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<dependency>
<or>
<!-- <taskdep task="make_grid"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/grid/&TN_MAKE_GRID;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_GRID;</left><right>FALSE</right></streq>
</or>
</dependency>
</task>
{%- endif %}
{%- if run_task_make_sfc_climo %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_MAKE_SFC_CLIMO;" cycledefs="at_start" maxtries="{{ maxtries_make_sfc_climo }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_MAKE_SFC_CLIMO;" "&JOBSdir;/JREGIONAL_MAKE_SFC_CLIMO"</command>
<nodes>{{ nnodes_make_sfc_climo }}:ppn={{ ppn_make_sfc_climo }}</nodes>
<walltime>{{ wtime_make_sfc_climo }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
<jobname>&TN_MAKE_SFC_CLIMO;</jobname>
<join>&LOGDIR;/&TN_MAKE_SFC_CLIMO;&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<dependency>
<and>
<or>
<!-- <taskdep task="&TN_MAKE_GRID;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/grid/&TN_MAKE_GRID;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_GRID;</left><right>FALSE</right></streq>
</or>
<or>
<!-- <taskdep task="&TN_MAKE_OROG;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/orog/&TN_MAKE_OROG;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_OROG;</left><right>FALSE</right></streq>
</or>
</and>
</dependency>
</task>
{%- endif %}
{%- if run_task_nexus_gfs_sfc %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_NEXUS_GFS_SFC;" cycledefs="forecast" maxtries="{{ maxtries_nexus_gfs_sfc }}">
{%- if do_real_time %}
&RSRV_DEFAULT;
{%- else %}
&RSRV_HPSS;
{%- endif %}
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_NEXUS_GFS_SFC;" "&JOBSdir;/JREGIONAL_NEXUS_GFS_SFC"</command>
<nodes>{{ nnodes_nexus_gfs_sfc }}:ppn={{ ppn_nexus_gfs_sfc }}</nodes>
{%- if machine not in ["GAEA", "NOAACLOUD"] %}
{%- if not do_real_time %}
<memory>{{ mem_nexus_gfs_sfc }}</memory>
{%- endif %}
{%- endif %}
<walltime>{{ wtime_nexus_gfs_sfc }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
{%- if machine not in ["WCOSS2"] %}
<native>&SCHED_NATIVE_CMD;</native>
{%- endif %}
<jobname>&TN_NEXUS_GFS_SFC;</jobname>
<join>&LOGDIR;/&TN_NEXUS_GFS_SFC;<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
{%- if do_real_time %}
<dependency>
<datadep age="00:00:00:05"><cyclestr offset="-{{- cycl_freq -}}">&COMINgfs;/gfs.@Y@m@d/@H/atmos</cyclestr></datadep>
</dependency>
{%- endif %}
</task>
{%- endif %}
{%- if run_task_nexus_emission %}
<!--
************************************************************************
************************************************************************
-->
<metatask name="&TN_NEXUS_EMISSION;">
<var name="nspt">{% for h in range(0, num_split_nexus) %}{{ " %02d" % h }}{% endfor %}</var>
<task name="&TN_NEXUS_EMISSION;_#nspt#" cycledefs="forecast" maxtries="{{ maxtries_nexus_emission }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_NEXUS_EMISSION;" "&JOBSdir;/JREGIONAL_NEXUS_EMISSION"</command>
{%- if machine in ["HERA"] %}
<nodes>{{ nnodes_nexus_emission }}:ppn={{ ppn_nexus_emission }}</nodes>
<native>{{ native_nexus_emission }}</native>
{%- elif machine in ["WCOSS2"] %}
<nodes>{{ nnodes_nexus_emission }}:ppn={{ ppn_nexus_emission }}:tpp={{ omp_num_threads_nexus_emission }}</nodes>
<native>&SCHED_NATIVE_CMD;</native>
{%- else %}
<nodes>{{ nnodes_nexus_emission }}:ppn={{ ppn_nexus_emission }}</nodes>
{%- endif %}
<walltime>{{ wtime_nexus_emission }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<jobname>&TN_NEXUS_EMISSION;_#nspt#</jobname>
<join>&LOGDIR;/&TN_NEXUS_EMISSION;<cyclestr>_@Y@m@d@H_s#nspt#&LOGEXT;</cyclestr></join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>nspt</name><value>#nspt#</value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
{%- if run_task_nexus_gfs_sfc %}
<dependency>
<taskdep task="&TN_NEXUS_GFS_SFC;"/>
</dependency>
{%- endif %}
</task>
</metatask>
<task name="&TN_NEXUS_POST_SPLIT;" cycledefs="forecast" maxtries="{{ maxtries_nexus_post_split }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_NEXUS_POST_SPLIT;" "&JOBSdir;/JREGIONAL_NEXUS_POST_SPLIT"</command>
<nodes>{{ nnodes_nexus_post_split }}:ppn={{ ppn_nexus_post_split }}</nodes>
<walltime>{{ wtime_nexus_post_split }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<jobname>&TN_NEXUS_POST_SPLIT;</jobname>
<join>&LOGDIR;/&TN_NEXUS_POST_SPLIT;<cyclestr>_@Y@m@d@H&LOGEXT;</cyclestr></join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<dependency>
<metataskdep metatask="&TN_NEXUS_EMISSION;"/>
</dependency>
</task>
{%- endif %}
{%- if run_task_fire_emission %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_FIRE_EMISSION;" cycledefs="forecast" maxtries="{{ maxtries_fire_emission }}">
{%- if do_aqm_save_fire %}
&RSRV_HPSS;
{%- else %}
&RSRV_DEFAULT;
{%- endif %}
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_FIRE_EMISSION;" "&JOBSdir;/JREGIONAL_FIRE_EMISSION"</command>
<nodes>{{ nnodes_fire_emission }}:ppn={{ ppn_fire_emission }}</nodes>
{%- if machine not in ["GAEA", "NOAACLOUD"] %}
{%- if not do_real_time %}
<memory>{{ mem_fire_emission }}</memory>
{%- endif %}
{%- endif %}
<walltime>{{ wtime_fire_emission }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
{%- if machine not in ["WCOSS2"] %}
<native>&SCHED_NATIVE_CMD;</native>
{%- endif %}
<jobname>&TN_FIRE_EMISSION;</jobname>
<join>&LOGDIR;/&TN_FIRE_EMISSION;<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
</task>
{%- endif %}
{%- if run_task_point_source %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_POINT_SOURCE;" cycledefs="forecast" maxtries="{{ maxtries_point_source }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_POINT_SOURCE;" "&JOBSdir;/JREGIONAL_POINT_SOURCE"</command>
<nodes>{{ nnodes_point_source }}:ppn={{ ppn_point_source }}</nodes>
<walltime>{{ wtime_point_source }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<jobname>&TN_POINT_SOURCE;</jobname>
<join>&LOGDIR;/&TN_POINT_SOURCE;<cyclestr>_@Y@m@d@H&LOGEXT;</cyclestr></join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<dependency>
<!-- <taskdep task="&TN_MAKE_GRID;"/> -->
<or>
<datadep age="00:00:00:05">&EXPTDIR;/grid/&TN_MAKE_GRID;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_GRID;</left><right>FALSE</right></streq>
</or>
</dependency>
</task>
{%- endif %}
{%- if run_task_get_extrn_ics %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_GET_EXTRN_ICS;" cycledefs="forecast" maxtries="{{ maxtries_get_extrn_ics }}">
&RSRV_HPSS;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_GET_EXTRN_ICS;" "&JOBSdir;/JREGIONAL_GET_EXTRN_MDL_FILES"</command>
<nodes>{{ nnodes_get_extrn_ics }}:ppn={{ ppn_get_extrn_ics }}</nodes>
{%- if machine not in ["GAEA", "NOAACLOUD"] %}
<memory>{{ mem_get_extrn_ics }}</memory>
{%- endif %}
<walltime>{{ wtime_get_extrn_ics }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
{%- if machine not in ["WCOSS2"] %}
<native>&SCHED_NATIVE_CMD;</native>
{%- endif %}
<jobname>&TN_GET_EXTRN_ICS;</jobname>
<join>&LOGDIR;/&TN_GET_EXTRN_ICS;<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>ICS_OR_LBCS</name><value>ICS</value></envar>
{%- if do_real_time %}
<dependency>
<datadep age="00:00:00:05"><cyclestr offset="-{{- cycl_freq -}}">&COMINgfs;/gfs.@Y@m@d/@H/atmos</cyclestr></datadep>
</dependency>
{%- endif %}
</task>
{%- endif %}
{%- if run_task_get_extrn_lbcs %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_GET_EXTRN_LBCS;" cycledefs="forecast" maxtries="{{ maxtries_get_extrn_lbcs }}">
&RSRV_HPSS;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_GET_EXTRN_LBCS;" "&JOBSdir;/JREGIONAL_GET_EXTRN_MDL_FILES"</command>
<nodes>{{ nnodes_get_extrn_lbcs }}:ppn={{ ppn_get_extrn_lbcs }}</nodes>
{%- if machine not in ["GAEA", "NOAACLOUD"] %}
<memory>{{ mem_get_extrn_lbcs }}</memory>
{%- endif %}
<walltime>{{ wtime_get_extrn_lbcs }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
{%- if machine not in ["WCOSS2"] %}
<native>&SCHED_NATIVE_CMD;</native>
{%- endif %}
<jobname>&TN_GET_EXTRN_LBCS;</jobname>
<join>&LOGDIR;/&TN_GET_EXTRN_LBCS;<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>ICS_OR_LBCS</name><value>LBCS</value></envar>
{%- if do_real_time %}
<dependency>
<datadep age="00:00:00:05"><cyclestr offset="-{{- cycl_freq -}}">&COMINgfs;/gfs.@Y@m@d/@H/atmos</cyclestr></datadep>
</dependency>
{%- endif %}
</task>
{%- endif %}
<!--
************************************************************************
************************************************************************
-->
{%- if do_ensemble %}
<metatask name="run_ensemble">
<var name="{{ ensmem_indx_name }}">{% for m in range(1, num_ens_members+1) %}{{ "%03d " % m }}{% endfor %}</var>
{%- endif %}
{%- if run_task_make_ics %}
<task name="&TN_MAKE_ICS;{{ uscore_ensmem_name }}" cycledefs="forecast" maxtries="{{ maxtries_make_ics }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_MAKE_ICS;" "&JOBSdir;/JREGIONAL_MAKE_ICS"</command>
<nodes>{{ nnodes_make_ics }}:ppn={{ ppn_make_ics }}</nodes>
<walltime>{{ wtime_make_ics }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
<jobname>&TN_MAKE_ICS;{{ uscore_ensmem_name }}</jobname>
<join>&LOGDIR;/&TN_MAKE_ICS;{{ uscore_ensmem_name }}<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<envar><name>ENSMEM_INDX</name><value><cyclestr>#{{ ensmem_indx_name }}#</cyclestr></value></envar>
<dependency>
<and>
<taskdep task="&TN_GET_EXTRN_ICS;"/>
<or>
<!-- <taskdep task="&TN_MAKE_GRID;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/grid/&TN_MAKE_GRID;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_GRID;</left><right>FALSE</right></streq>
</or>
<or>
<!-- <taskdep task="&TN_MAKE_OROG;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/orog/&TN_MAKE_OROG;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_OROG;</left><right>FALSE</right></streq>
</or>
<or>
<!-- <taskdep task="&TN_MAKE_SFC_CLIMO;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/sfc_climo/&TN_MAKE_SFC_CLIMO;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_SFC_CLIMO;</left><right>FALSE</right></streq>
</or>
</and>
</dependency>
</task>
{%- endif %}
{%- if run_task_make_lbcs %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_MAKE_LBCS;{{ uscore_ensmem_name }}" cycledefs="forecast" maxtries="{{ maxtries_make_lbcs }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_MAKE_LBCS;" "&JOBSdir;/JREGIONAL_MAKE_LBCS"</command>
<nodes>{{ nnodes_make_lbcs }}:ppn={{ ppn_make_lbcs }}</nodes>
<walltime>{{ wtime_make_lbcs }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
<jobname>&TN_MAKE_LBCS;{{ uscore_ensmem_name }}</jobname>
<join>&LOGDIR;/&TN_MAKE_LBCS;{{ uscore_ensmem_name }}<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<envar><name>ENSMEM_INDX</name><value><cyclestr>#{{ ensmem_indx_name }}#</cyclestr></value></envar>
<dependency>
<and>
<taskdep task="&TN_GET_EXTRN_LBCS;"/>
<or>
<!-- <taskdep task="&TN_MAKE_GRID;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/grid/&TN_MAKE_GRID;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_GRID;</left><right>FALSE</right></streq>
</or>
<or>
<!-- <taskdep task="&TN_MAKE_OROG;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/orog/&TN_MAKE_OROG;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_OROG;</left><right>FALSE</right></streq>
</or>
<or>
<!-- <taskdep task="&TN_MAKE_SFC_CLIMO;"/> -->
<datadep age="00:00:00:05">&EXPTDIR;/sfc_climo/&TN_MAKE_SFC_CLIMO;&CMPEXT;</datadep>
<streq><left>&RUN_TASK_MAKE_SFC_CLIMO;</left><right>FALSE</right></streq>
</or>
</and>
</dependency>
</task>
{%- endif %}
{%- if run_task_aqm_ics %}
{%- if not coldstart %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_AQM_EXTRN_ICS;" cycledefs="at_start" maxtries="{{ maxtries_aqm_ics }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_AQM_ICS;" "&JOBSdir;/JREGIONAL_AQM_ICS"</command>
<nodes>{{ nnodes_aqm_ics }}:ppn={{ ppn_aqm_ics }}</nodes>
<walltime>{{ wtime_aqm_ics }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<jobname>&TN_AQM_EXTRN_ICS;</jobname>
<join>&LOGDIR;/&TN_AQM_EXTRN_ICS;<cyclestr>_@Y@m@d@H&LOGEXT;</cyclestr></join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>PREV_CYCLE_DIR</name><value>&WARMSTART_CYCLE_DIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<dependency>
<and>
<taskdep task="&TN_MAKE_ICS;"/>
<or>
<datadep age="00:00:00:05">&WARMSTART_CYCLE_DIR;/RESTART/<cyclestr>@Y@m@d.@H@[email protected]_tracer.res.tile1.nc</cyclestr></datadep>
<datadep age="00:00:00:05">&WARMSTART_CYCLE_DIR;/RESTART/fv_tracer.res.tile1.nc</datadep>
</or>
</and>
</dependency>
</task>
{%- endif %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_AQM_ICS;" cycledefs="cycled" maxtries="{{ maxtries_aqm_ics }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_AQM_ICS;" "&JOBSdir;/JREGIONAL_AQM_ICS"</command>
<nodes>{{ nnodes_aqm_ics }}:ppn={{ ppn_aqm_ics }}</nodes>
<walltime>{{ wtime_aqm_ics }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<jobname>&TN_AQM_ICS;</jobname>
<join>&LOGDIR;/&TN_AQM_ICS;<cyclestr>_@Y@m@d@H&LOGEXT;</cyclestr></join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>PREV_CYCLE_DIR</name><value><cyclestr offset="-{{- cycl_freq -}}">&COMIN_DIR;</cyclestr></value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<dependency>
<and>
<taskdep task="&TN_MAKE_ICS;"/>
<or>
<datadep age="00:00:00:05"><cyclestr offset="-{{- cycl_freq -}}">&COMIN_DIR;</cyclestr>/RESTART/<cyclestr>@Y@m@d.@H@[email protected]_tracer.res.tile1.nc</cyclestr></datadep>
<datadep age="00:00:00:05"><cyclestr offset="-{{- cycl_freq -}}">&COMIN_DIR;</cyclestr>/RESTART/fv_tracer.res.tile1.nc</datadep>
</or>
</and>
</dependency>
</task>
{%- endif %}
{%- if run_task_aqm_lbcs %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_AQM_LBCS;" cycledefs="forecast" maxtries="{{ maxtries_aqm_lbcs }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_AQM_LBCS;" "&JOBSdir;/JREGIONAL_AQM_LBCS"</command>
<nodes>{{ nnodes_aqm_lbcs }}:ppn={{ ppn_aqm_lbcs }}</nodes>
<walltime>{{ wtime_aqm_lbcs }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<jobname>&TN_AQM_LBCS;</jobname>
<join>&LOGDIR;/&TN_AQM_LBCS;<cyclestr>_@Y@m@d@H&LOGEXT;</cyclestr></join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<dependency>
<taskdep task="&TN_MAKE_LBCS;"/>
</dependency>
</task>
{%- endif %}
{%- if run_task_run_fcst %}
<!--
************************************************************************
************************************************************************
-->
<task name="&TN_RUN_FCST;{{ uscore_ensmem_name }}" cycledefs="forecast" maxtries="{{ maxtries_run_fcst }}">
&RSRV_FCST;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_RUN_FCST;" "&JOBSdir;/JREGIONAL_RUN_FCST"</command>
{%- if machine in ["JET", "HERA", "LINUX"] %}
<cores>{{ ncores_run_fcst }}</cores>
<native>{{ native_run_fcst }}</native>
{%- elif machine in ["WCOSS2"] %}
<nodes>{{ nnodes_run_fcst }}:ppn={{ ppn_run_fcst }}:tpp={{ omp_num_threads_run_fcst }}</nodes>
<nodesize>&NCORES_PER_NODE;</nodesize>
{%- else %}
<nodes>{{ nnodes_run_fcst }}:ppn={{ ppn_run_fcst }}</nodes>
<nodesize>&NCORES_PER_NODE;</nodesize>
{%- endif %}
<native>&SCHED_NATIVE_CMD;</native>
<walltime>{{ wtime_run_fcst }}</walltime>
<jobname>&TN_RUN_FCST;{{ uscore_ensmem_name }}</jobname>
<join>&LOGDIR;/&TN_RUN_FCST;{{ uscore_ensmem_name }}<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<envar><name>ENSMEM_INDX</name><value><cyclestr>#{{ ensmem_indx_name }}#</cyclestr></value></envar>
<dependency>
<and>
<taskdep task="&TN_MAKE_ICS;{{ uscore_ensmem_name }}"/>
<taskdep task="&TN_MAKE_LBCS;{{ uscore_ensmem_name }}"/>
{%- if run_task_nexus_emission %}
<taskdep task="&TN_NEXUS_POST_SPLIT;"/>
{%- endif %}
{%- if run_task_fire_emission %}
<taskdep task="&TN_FIRE_EMISSION;"/>
{%- endif %}
{%- if run_task_point_source %}
<taskdep task="&TN_POINT_SOURCE;"/>
{%- endif %}
{%- if run_task_aqm_ics %}
<or>
<taskdep task="&TN_AQM_ICS;"/>
{%- if not coldstart %}
<and>
<not><cycleexistdep cycle_offset="-{{- cycl_freq -}}"/></not>
<taskdep task="&TN_AQM_EXTRN_ICS;"/>
</and>
{%- else %}
<not><cycleexistdep cycle_offset="-{{- cycl_freq -}}"/></not>
{%- endif %}
</or>
{%- endif %}
{%- if run_task_aqm_lbcs %}
<taskdep task="&TN_AQM_LBCS;"/>
{%- endif %}
</and>
</dependency>
</task>
{%- endif %}
<!--
************************************************************************
************************************************************************
-->
{%- if run_task_run_post %}
{%- if fcst_len_hrs == -1 %}
{%- for icyc in range(num_fcst_len_cycl) %}
<metatask name="&TN_RUN_POST;{{ uscore_ensmem_name }}">
<var name="fhr">{% for h in range(0, fcst_len_cycl[icyc]+1) %}{{ " %03d" % h }}{% endfor %}</var>
{%- if icyc == 0 %}
<task name="&TN_RUN_POST_CYC1;{{ uscore_ensmem_name }}_f#fhr#" cycledefs="cyc_1st" maxtries="{{ maxtries_run_post }}">
{%- elif icyc == 1 %}
<task name="&TN_RUN_POST_CYC2;{{ uscore_ensmem_name }}_f#fhr#" cycledefs="cyc_2nd" maxtries="{{ maxtries_run_post }}">
{%- elif icyc == 2 %}
<task name="&TN_RUN_POST_CYC3;{{ uscore_ensmem_name }}_f#fhr#" cycledefs="cyc_3rd" maxtries="{{ maxtries_run_post }}">
{%- elif icyc == 3 %}
<task name="&TN_RUN_POST_CYC4;{{ uscore_ensmem_name }}_f#fhr#" cycledefs="cyc_4th" maxtries="{{ maxtries_run_post }}">
{%- endif %}
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_RUN_POST;" "&JOBSdir;/JREGIONAL_RUN_POST"</command>
<nodes>{{ nnodes_run_post }}:ppn={{ ppn_run_post }}</nodes>
<walltime>{{ wtime_run_post }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
{%- if icyc == 0 %}
<jobname>&TN_RUN_POST_CYC1;{{ uscore_ensmem_name }}_f#fhr#</jobname>
{%- elif icyc == 1 %}
<jobname>&TN_RUN_POST_CYC2;{{ uscore_ensmem_name }}_f#fhr#</jobname>
{%- elif icyc == 2 %}
<jobname>&TN_RUN_POST_CYC3;{{ uscore_ensmem_name }}_f#fhr#</jobname>
{%- elif icyc == 3 %}
<jobname>&TN_RUN_POST_CYC4;{{ uscore_ensmem_name }}_f#fhr#</jobname>
{%- endif %}
<join>&LOGDIR;/&TN_RUN_POST;{{ uscore_ensmem_name }}_f#fhr#<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>fhr</name><value>#fhr#</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<envar><name>ENSMEM_INDX</name><value><cyclestr>#{{ ensmem_indx_name }}#</cyclestr></value></envar>
<dependency>
<or>
<taskdep task="&TN_RUN_FCST;{{ uscore_ensmem_name }}"/>
<and>
<datadep age="05:00">&DYN_DIR;f#fhr#.nc</datadep>
<datadep age="05:00">&PHY_DIR;f#fhr#.nc</datadep>
</and>
</or>
</dependency>
</task>
</metatask>
{%- endfor %}
{%- else %}
{%- if sub_hourly_post %}
<!--
Define the post-processing task for first model output time. The forecast
hour corresponding to this output time is zero (formatted to the appropriate
number of digits), and the corresponding forecast minute is the first model
time step dt_atmos, i.e. it is not zero. This is because FV3 is designed
such that its first output file contains fields at the first time step.
It is for this reason that this task is not rolled into the metatask(s)
further below.
Note that we wrap this task in a metatask in order to be able to declare
and use the variables fhr and fmn. This allows the block of code inside
the <task> tag (except for the dependencies) to be identical to the ones
later below for other output times.
-->
<metatask>
<var name="fhr">000</var>
<var name="fmn">00</var>
<task name="&TN_RUN_POST;{{ uscore_ensmem_name }}_f#fhr##fmn#" cycledefs="forecast" maxtries="{{ maxtries_run_post }}">
&RSRV_DEFAULT;
<command>&LOAD_MODULES_RUN_TASK_FP; "&TN_RUN_POST;" "&JOBSdir;/JREGIONAL_RUN_POST"</command>
<nodes>{{ nnodes_run_post }}:ppn={{ ppn_run_post }}</nodes>
<walltime>{{ wtime_run_post }}</walltime>
<nodesize>&NCORES_PER_NODE;</nodesize>
<native>&SCHED_NATIVE_CMD;</native>
<jobname>&TN_RUN_POST;{{ uscore_ensmem_name }}_f#fhr##fmn#</jobname>
<join>&LOGDIR;/&TN_RUN_POST;{{ uscore_ensmem_name }}_f#fhr##fmn#<cyclestr>_@Y@m@d@H</cyclestr>&LOGEXT;</join>
<envar><name>GLOBAL_VAR_DEFNS_FP</name><value>&GLOBAL_VAR_DEFNS_FP;</value></envar>
<envar><name>USHdir</name><value>&USHdir;</value></envar>
<envar><name>PDY</name><value><cyclestr>@Y@m@d</cyclestr></value></envar>
<envar><name>cyc</name><value><cyclestr>@H</cyclestr></value></envar>
<envar><name>subcyc</name><value><cyclestr>@M</cyclestr></value></envar>
<envar><name>LOGDIR</name><value>&LOGDIR;</value></envar>
<envar><name>fhr</name><value>#fhr#</value></envar>
<envar><name>fmn</name><value>#fmn#</value></envar>
<envar><name>SLASH_ENSMEM_SUBDIR</name><value><cyclestr>{{ slash_ensmem_subdir }}</cyclestr></value></envar>
<envar><name>ENSMEM_INDX</name><value><cyclestr>#{{ ensmem_indx_name }}#</cyclestr></value></envar>
<!--
Note that because the forecast minutes and seconds corresponding to the
first model output time are not exactly zero, we use the jinja template
variable first_fv3_file_tstr instead of fhr and fmn to form the file
names in the dependencies.
-->