forked from mos3r3n/mos3r3n.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
2024 lines (1719 loc) · 76.3 KB
/
Copy pathindex.html
File metadata and controls
2024 lines (1719 loc) · 76.3 KB
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
<!doctype html>
<!-- Copyright (c) 2026, University Corporation for Atmospheric Research (UCAR). -->
<!-- Copyright (c) 2026, Centre for Climate Research Singapore (CCRS). -->
<html>
<head>
<style>
h1 {font-family:Verdana,Geneva,sans-serif;}
h2 {font-family:Verdana,Geneva,sans-serif;}
h3 {font-family:Verdana,Geneva,sans-serif;}
h4 {font-family:Verdana,Geneva,sans-serif;}
li {font-family:Verdana,Geneva,sans-serif;}
b {font-family:Verdana,Geneva,sans-serif;}
p.top {max-width:875px; font-family:Verdana,Geneva,sans-serif;}
p {max-width:98%; font-family:Verdana,Geneva,sans-serif;}
div.header {background-color:lightgray; max-width:900px; margin-top:30px; margin-bottom:10px; cursor:pointer;}
div.subheader {background-color:lightgray; max-width:870px; margin-top:30px; margin-bottom:10px; cursor:pointer;}
div.hintheader {background-color:lightblue; max-width:840px; margin-top:30px; margin-bottom:10px; cursor:pointer;}
div.section {max-width:900px; display:none; margin-left:30px;}
div.subsection {max-width:900px; display:none; margin-left:30px;}
div.hint {max-width:900px; display:none; margin-left:30px;}
div.outlined {max-width:870px; padding-left:15px; padding-right:15px; border-style:solid; border-width:thin; border-color:red;}
pre.terminal {font-family:"Courier New",Courier,monospace; font-weight:bold; margin-left:15px;}
em.terminal {font-family:"Courier New",Courier,monospace; font-weight:bold; font-style:normal;}
em.highlight {background-color: yellow; font-style:normal;}
em.prompt {user-select: none; -webkit-user-select: none; -moz-user-select: none; -ms-user-select: none; font-style:normal;}
b.red {font-family:"Courier New",Courier,monospace; font-weight:bold; color:#ff0000;}
</style>
<title>MPAS-JEDI Training for WSRP — Practice Session Guide</title>
<script type="text/javascript">
function show(id)
{
var e = document.getElementById(id);
if (e.style.display == "block") {
e.style.display = "none";
}
else {
e.style.display = "block";
}
}
function jump(sectionid='')
{
if (sectionid == '') {
var params = new URLSearchParams(window.location.search);
if (params.has('section')) {
sectionid = params.get('section');
}
}
if (sectionid == '') {
return;
}
var section = document.getElementById(sectionid);
while (section != null && section.id != '') {
show(section.id);
section = section.parentNode;
}
document.getElementById(sectionid+'-header').scrollIntoView({behavior: 'smooth'});
}
</script>
</head>
<body onLoad="jump()">
<img src="images/MPAS_logo.png" style="height:84px; width:250px">
<img src="images/mss-ccrs-logo.png" style="height:84px; width:400px">
<img src="images/Astar_logo.png" style="height:84px; width:250px">
<h1>Welcome to the MPAS-JEDI Training hands-on exercises</h1>
<p class="top">
This web page is intended to serve as a guide through the hands-on practice exercises of this MPAS-JEDI
training for the Weather Science Research Programme (WSRP) projects. Detailed information of WSRP
can be found at <a href="https://www.a-star.edu.sg/ihpc/cawret" target="_blank">CAWRET website</a>.
In the following, exercises are split into 5 main sections, each of them focusing on a specific aspect
of using the MPAS-JEDI data assimilation system.
</p>
<p class="top">
In case you would like to refer to any of the lecture slides from previous days,
you can open the <a href="agenda.html" target="_blank">Tutorial Agenda</a> in another window.
The test dataset is available under Aspire2a under the WSRP project folder
/home/project/13004327/training_service/2026-MPAS-JEDI.
</p>
<p class="top">
You can proceed through the sections of this practical guide at your own pace. It is highly recommended
to go through the exercises in order, since later exercises may require the output of earlier ones.
Clicking the grey headers will expand each section or subsection.
</p>
<!-- ============================================================================== -->
<!-- === 0. Prerequisites and environment setup =========== -->
<!-- ============================================================================== -->
<div class="header" onClick="show('prerequisites')">
<h2 id="prerequisites-header">0. Prerequisites and environment setup</h2>
</div>
<div id="prerequisites" class="section">
<p>
The practical exercises in this tutorial have been tailored to work on
the <a href="https://www.nscc.sg/aspire-2a/" target="_blank">NSCC Aspire2a</a> system.
Aspire2a is an HPC cluster that provides most of the libraries needed by MPAS-JEDI and its pre- and post-processing
tools through <i>modules</i>. In general, before compiling and running MPAS-JEDI on your own system,
you will need to install <a href="https://github.com/JCSDA/spack-stack" target="_blank">spack-stack</a>.
However, this tutorial does not cover the installation of spack-stack, which was pre-installed on Aspire2a.
MPAS-JEDI code build for this tutorial is based upon <a href="https://github.com/JCSDA/spack-stack/tree/release/1.8.0" target="_blank">spack-stack-1.8.0</a>.
</p>
<p>
Before logging onto Aspire2a, you need to set up your vpn to have the internet connection to NSCC HPC systems. Please follow the instructions from NSCC for
<a href="https://help.nscc.sg/wp-content/uploads/ASPIRE2A_VPN_MAC.pdf" target="_blank">Mac</a> and
<a href="https://help.nscc.sg/wp-content/uploads/ASPIRE2A_VPN_WINDOWS.pdf" target="_blank">Windows</a>users.
<p>
After setting up the VPN, log onto Aspire2a from your laptop or desktop by
</p>
<pre class="terminal">
<em class="prompt">$ </em>ssh aspire2a.nscc.sg
</pre>
<p>
You will be required to type your username and password to log onto Aspire2a. It is recommended to at least login onto Aspire2a
with multiple terminals for different tasks.
</p>
<p>
After logging, you will be in your home directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>pwd
</pre>
<p>
The command above will display the current working directory (your home directory after logging). However, the home directory
usually has very limited disk space, so it is recommended to perform all exercises under your scratch directory.
</p>
<p>
You can set an environment variable for your scratch directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>export SCRATCH=${HOME/home/scratch}
</pre>
<p>
You will run all of the practical exercises in your own <i>scratch</i> space, and you can check whether it is properly set by using
<em class="terminal">echo $SCRATCH</em>.
</p>
<p>
Navigate to your scratch directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd $SCRATCH
</pre>
<p>
Then, create a working directory for the training exercises and move into it:
</p>
<pre class="terminal">
<em class="prompt">$ </em>mkdir MPAS_JEDI_Training
<em class="prompt">$ </em>cd MPAS_JEDI_Training
</pre>
<p>
All the training dataset is located under /home/project/13004327/training_service/2026-MPAS-JEDI. Due to the IO limit,
we recommend you to linking them to your working directory
<pre class="terminal">
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/OBS_FILE .
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/MPAS_FILE .
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/BEC_FILE .
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/MPASJEDI_FILE .
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/Graphics .
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/SINGV-NG-1.0 .
<em class="prompt">$ </em>ln -fs /home/project/13004327/training_service/2026-MPAS-JEDI/OBS2IODA .
</pre>
</p>
<p>
Now, under your working directory, you will have those folders:
<ul>
<li><em class="terminal">OBS_FILE</em> - Observation-related files, such as observation data on bufr and IODA formats, CRTM coefficients, bias correction files.
<li><em class="terminal">MPAS_FILE</em> - MPAS model-related files, such as MPAS forecast (as background), ensemble forecasts, MPAS grid files, and MPAS namlist and stream files.
<li><em class="terminal">BEC_FILE</em> - Background error covariance (BEC) files, including ensemble-BEC localization matrix and static BEC files.
<li><em class="terminal">MPASJEDI_FILE</em> - yaml and job scirpt files for conducting MPAS-JEDI applications.
<li><em class="terminal">Graphics</em> - Python scripts for visualization.
<li><em class="terminal">SINGV-NG-1.0</em> - Source code and compled exctuables of MPAS-JEDI (CCRS version).
<li><em class="terminal">OBS2IODA</em> - Source code and compiled exctuable of obs2ioda for observation convector.
</ul>
</p>
<p>
On aspire2a, the default shell is bash.
</p>
<p>
Aspire2a uses the LMOD package to manage the software development.
Running <em class="terminal">module list</em> to see what modules are loaded by default
right after logging.
It should print something similar to the below:
</p>
<pre class="terminal">
<em class="prompt">$ </em>module list
Currently Loaded Modulefiles:
1) craype-x86-rome 3) craype-network-ofi 5) cce/13.0.2 7) cray-dsmml/0.2.2 9) cray-libsci/21.08.1.2 11) PrgEnv-cray/8.3.3
2) libfabric/1.11.0.4.125 4) perftools-base/22.04.0 6) craype/2.7.15 8) cray-mpich/8.1.15 10) cray-pals/1.1.6
</pre>
<p>
Post-processing and graphics exercises will need Python. A Conda environment with a plenty of Python libraries is available.
We can activate the conda environment with the following command:
<pre class="terminal">
<em class="prompt">$ </em>module load miniforge3/25.3.1
<em class="prompt">$ </em>conda activate /home/project/13004327/software_service/conda_envs/MPAS-JEDI-Training
</pre>
</p>
<p>
Running jobs on Aspire2a requires the submission of a job script to a batch queueing system,
which will allocate requested computing resources to your job when they become available.
In general, it's best to avoid running any compute-intensive jobs on the login nodes, and
the practical instructions to follow will guide you in the process of submitting jobs when
necessary.
</p>
<p>
As a first introduction to running jobs on Aspire2a, there are several key commands worth
noting:
<ul>
<li><em class="terminal">qsub job-script</em> - This command submits a PBS job script, which describes a job
to be run on one or more batch nodes.
<li><em class="terminal">qstat -u $USER</em> - This command tells you the status of your pending and running jobs.
<i>Note that you may need to wait about 30 seconds for a recently submitted job to show up.</i></li>
<li><em class="terminal">qdel JobID</em> - This command deletes a queued or running job</li>
</ul>
</p>
<p>
Throughout this training, you will submit your jobs to a special project number <em class="terminal">S6244386</em>.
After the training, do remember to use your own project number to submit jobs.
At various points in the practical exercises, we'll need to submit jobs to Aspire2a's queueing system
using the <em class="terminal">qsub</em> command, and after doing so, we may check on the status
of the job with the <em class="terminal">qstat</em> command, monitoring the log files produced by the job
once we see that the job has begun to run. Most exercises will run with 128 cores in one single node,
each Aspire2a's node having 128 cores (440GB available memory).
</p>
<p>
You're now ready to begin with the practical exercises of this training!
</p>
</div>
<!-- ============================================================================== -->
<!-- === 1. Compiling/Testing MPAS-JEDI =========== -->
<!-- ============================================================================== -->
<div class="header" onClick="show('compile')">
<h2 id="compile-header">1. Compiling/Testing MPAS-JEDI</h2>
</div>
<div id="compile" class="section">
<p>
In this section, the goal is to obtain, compile, and test the MPAS-JEDI code
through cmake/ctest mechanism. Due to I/O and network bandwidth limitations,
it is not recommended to download, compile, or test the MPAS-JEDI code on the login node
during this training.
</p>
<!-- === 1.1 Downloading the code ================================================ -->
<div class="subheader" onClick="show('downloading')">
<h3 id="downloading-header">1.1 Git-Clone the mpas-bundle repository</h3>
</div>
<div id="downloading" class="subsection">
<p>
In order to build MPAS-JEDI and its dependencies, it is recommended to access source code from <a href=https://github.com/mos3r3n/mpas-bundle>mpas-bundle</a>.
We will use the 'SINGV-NG-1.0' branch from <a href=https://github.com/mos3r3n/mpas-bundle/tree/SINGV-NG-1.0>SINGV-NG-1.0</a>:
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd ${SCRATCH}/MPAS-JEDI-Training
<em class="prompt">$ </em>mkdir MPAS-BUNDLE
<em class="prompt">$ </em>cd MPAS-BUNDLE
<em class="prompt">$ </em>git clone -b SINGV-NG-1.0 https://github.com/mos3r3n/mpas-bundle code
</pre>
<p>
The git command will clone the mpas-bundle repository from github to a local directory 'code'
, then make the 'SINGV-NG-1.0' branch as the active branch. The output to the terminal should look as following:
</p>
<pre class="terminal">
Cloning into 'code'...
remote: Enumerating objects: 436, done.
remote: Counting objects: 100% (73/73), done.
remote: Compressing objects: 100% (35/35), done.
remote: Total 436 (delta 55), reused 43 (delta 38), pack-reused 363 (from 1)
Receiving objects: 100% (436/436), 144.95 KiB | 3.54 MiB/s, done.
Resolving deltas: 100% (267/267), done.
</pre>
<p>
Note that the mpas-bundle repository does not contain actual source code.
Instead, the CMakeLists.txt file under code includes the github repositories's branch/tag
information needed to build MPAS-JEDI.
One important difference from previous mpas-bundle releases (1.0.0, 2.0.0, and 3.0.x) is
that SINGV-NG-1.0 bundle works together with the special version of MPAS-A model code from
<a href=https://github.com/mos3r3n/MPAS-Model-SINGVNG/tree/nssl>MPAS-SINGVNG</a>. Also, some
enhancements have been applied to the MPAS-JEDI DA system.
We now load the spack-stack environment pre-built using the GNU compiler:
</p>
<pre class="terminal">
<em class="prompt">$ </em>source code/env-setup/gnu-aspire2a.sh
<em class="prompt">$ </em>module list
</pre>
<p>
The output to the module list in the terminal should look like the following (45 modules!!!).
These packages are from pre-installed spack-stack-1.8.0.
</p>
<pre class="terminal">
Currently Loaded Modulefiles:
1) craype-x86-milan 10) zlib-ng/2.1.6 19) stack-python/3.11.7 28) snappy/1.1.10 37) parallelio/2.6.2
2) craype/2.7.15 11) pigz/2.8 20) boost/1.84.0 29) c-blosc/1.21.5 38) jedi-cmake/1.4.0
3) libfabric/1.11.0.4.125 12) zstd/1.5.2 21) eckit/1.25.2 30) nghttp2/1.57.0 39) cmake/3.31.3
4) cray-pals/1.1.6 13) tar/1.34 22) eigen/3.4.0 31) curl/8.7.1 40) ecbuild/3.7.2
5) gcc/11.2.0 14) gettext/0.22.5 23) fckit/0.11.0 32) hdf5/1.14.3 41) python-venv/1.0
6) cray-mpich/8.1.15 15) libxcrypt/4.4.35 24) fftw/3.3.10 33) netcdf-c/4.9.2 42) py-setuptools/63.4.3
7) stack-gcc/11.2.0 16) sqlite/3.43.2 25) ecmwf-atlas/0.36.0 34) netcdf-cxx4/4.3.1 43) py-pycodestyle/2.11.0
8) stack-cray-mpich/8.1.15 17) util-linux-uuid/2.38.1 26) gptl/8.1.1 35) netcdf-fortran/4.6.1 44) udunits/2.2.28
9) glibc/2.28 18) python/3.11.7 27) gsl-lite/0.37.0 36) parallel-netcdf/1.12.3 45) nccmp/1.9.0.1
</pre>
<p>
If the system throws an error "ModuleCmd_List.c(170):FATAL:997". Do not worry, the modules are still loaded, just not able to print out.
You can try to source the environment again, and list the modules again.
</p>
<p>
Now we are ready to 'fetch' actual source code from github repositories through cmake.
</p>
</div>
<!-- === 1.2 Compiling/Testing =================================================== -->
<div class="subheader" onClick="show('building')">
<h3 id="building-header">1.2 Compiling and testing MPAS-JEDI</h3>
</div>
<div id="building" class="subsection">
<div class="outlined">
<p>
<b class="red">WARNING:</b>Due to huge burden on I/O and network bandwidth, please don't configure, compile, and test MPAS-JEDI during the training.
Instead, you may try that after the training, when you have time.
</p>
</div>
<p>
MPAS-JEDI uses CMake to automatically fetch the code from various Github repositories,
listed in CMakeLists.txt under ~code. Now type the command below under the build directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>git lfs install
<em class="prompt">$ </em>mkdir build
<em class="prompt">$ </em>cd build
<em class="prompt">$ </em>cmake ../code
</pre>
<p>
After it completes (may take 15-20 min depending on network connection), you will see the actual source codes of various
repositories (e.g., oops, vader, saber, ufo, ioda, crtm, mpas-jedi, and MPAS) are now under the code directory.
Meanwhile, Makefile files to build executables are generated under the build directory.
Now it is ready to compile MPAS-JEDI under 'build' using the standard make. Commonly, we don't compile MPAS-JEDI on the login node.
Instead, we do it by submiting an interactive job as following
<pre class="terminal">
<em class="prompt">$ </em>qsub -I -l select=1:ncpus=4:mem=32gb -l walltime=01:00:00 -P ${PROJECT_NUMBER} -q normal
</pre>
Then, your job will queue, and you will login to the compute node you are assigned when it is get ready
<pre class="terminal">
qsub: waiting for job 13405681.pbs101 to start
qsub: job 13405681.pbs101 ready
</pre>
On the compute node, you need to re-activate the spack-stack environment first and then do "make".
<pre class="terminal">
<em class="prompt">$ </em>source ${SCRATCH}/MPAS-JEDI-Training/MPAS-BUNDLE/code/env-setup/gnu-aspire2a.sh
<em class="prompt">$ </em>make -j4
</pre>
</p>
<p>
This could take ~25 min. Using more cores for build could speed up a bit, but will not help too much from our experience.
Also note that the reason we do the cmake step (will clone various github repositories) on the login
node instead of a compute node is that aspire2a's compute nodes have a much slower internet connection.
</p>
<div class="outlined">
<p>
<b class="red">WARNING:</b>The compilation could take ~25 min to complete. You may continue to read instructions while waiting.
</p>
</div>
<p>
Once we reach 100% of the compilation, many executables will be generated under build/bin.
Related executables of MPAS model and MPAS-JEDI include:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ls bin/mpas*
bin/mpas_atmosphere bin/mpasjedi_enkf.x bin/mpasjedi_hofx3d.x bin/mpas_namelist_gen
bin/mpas_atmosphere_build_tables bin/mpasjedi_enshofx.x bin/mpasjedi_hofx.x bin/mpas_parse_atmosphere
bin/mpas_init_atmosphere bin/mpasjedi_ens_mean_variance.x bin/mpasjedi_process_perts.x bin/mpas_parse_init_atmosphere
bin/mpasjedi_convertstate.x bin/mpasjedi_error_covariance_toolbox.x bin/mpasjedi_rtpp.x bin/mpas_streams_gen
bin/mpasjedi_converttostructuredgrid.x bin/mpasjedi_forecast.x bin/mpasjedi_saca.x
bin/mpasjedi_eda.x bin/mpasjedi_gen_ens_pert_B.x bin/mpasjedi_variational.x
</pre>
<p>
The last step is to ensure that the code was compiled properly by running the MPAS-JEDI ctests,
with two lines of simple command:
</p>
<pre class="terminal">
<em class="prompt">$ </em>export LD_LIBRARY_PATH=${SCRATCH}/MPAS-JEDI-Training/MPAS-BUNDLE/build/lib:$LD_LIBRARY_PATH
<em class="prompt">$ </em>cd mpas-jedi
<em class="prompt">$ </em>ctest
</pre>
<p>
At the moment the tests are running (take ~5 min to finish), it indicates if it passes or fails.
At the end, a summary is provided with a percentage of the tests that passed, failed and the processing times.
</p>
<p>
The output to the terminal should look as following:
</p>
<pre class="terminal">
......
100% tests passed, 0 tests failed out of 59
Label Time Summary:
executable = 18.76 sec*proc (13 tests)
mpasjedi = 237.40 sec*proc (59 tests)
mpi = 235.68 sec*proc (56 tests)
script = 218.64 sec*proc (44 tests)
Total Test time (real) = 237.49 sec
</pre>
<div class="outlined">
<p>
<b class="red">WARNING:</b>You could run ctest just under the 'build' directory, but that will run a total of 2159 ctest cases for all
component packages (oops, vader, saber, ufo, ioda, crtm, mpas-jedi etc.) in mpas-bundle, which will take much longer time.
Maybe something you can play with after this tutorial.
You may use 'ctest -N, which will only list names of ctest cases, but not run them).
</p>
</div>
<p>
To determine if a test passes or fails, a comparison of the test log and reference file is done internally taking as reference a tolerance value. This tolerance is specified via YAML file. These files can be found under <em class="terminal">mpas-jedi/test/testoutput</em> in the build folder:
</p>
<pre class="terminal">
3denvar_2stream_bumploc.ref 4denvar_ID.run ens_mean_variance.run.ref
3denvar_2stream_bumploc.run 4denvar_ID.run.ref forecast.ref
3denvar_2stream_bumploc.run.ref 4denvar_VarBC_nonpar.run forecast.run
3denvar_amsua_allsky.ref 4denvar_VarBC_nonpar.run.ref forecast.run.ref
3denvar_amsua_allsky.run 4denvar_VarBC.ref gen_ens_pert_B.ref
3denvar_amsua_allsky.run.ref 4denvar_VarBC.run gen_ens_pert_B.run
3denvar_amsua_bc.ref 4denvar_VarBC.run.ref gen_ens_pert_B.run.ref
3denvar_amsua_bc.run 4dfgat.ref hofx3d_nbam.ref
3denvar_amsua_bc.run.ref 4dfgat.run hofx3d_nbam.run
3denvar_bumploc.ref 4dfgat.run.ref hofx3d_nbam.run.ref
3denvar_bumploc.run 4dhybrid_bumpcov_bumploc.ref hofx3d.ref
3denvar_bumploc.run.ref 4dhybrid_bumpcov_bumploc.run hofx3d_ropp.ref
3denvar_dual_resolution.ref 4dhybrid_bumpcov_bumploc.run.ref hofx3d_rttovcpp.ref
3denvar_dual_resolution.run convertstate_bumpinterp.ref hofx3d.run
3denvar_dual_resolution.run.ref convertstate_bumpinterp.run hofx3d.run.ref
3dfgat_pseudo.ref convertstate_bumpinterp.run.ref hofx4d_pseudo.ref
3dfgat_pseudo.run convertstate_unsinterp.ref hofx4d_pseudo.run
3dfgat_pseudo.run.ref convertstate_unsinterp.run hofx4d_pseudo.run.ref
3dfgat.ref convertstate_unsinterp.run.ref hofx4d.ref
3dfgat.run converttostructuredgrid_latlon.ref hofx4d.run
3dfgat.run.ref converttostructuredgrid_latlon.run hofx4d.run.ref
3dhybrid_bumpcov_bumploc.ref converttostructuredgrid_latlon.run.ref letkf_3dloc.ref
3dhybrid_bumpcov_bumploc.run dirac_bumpcov.ref letkf_3dloc.run
3dhybrid_bumpcov_bumploc.run.ref dirac_bumpcov.run letkf_3dloc.run.ref
3dvar_bumpcov_nbam.ref dirac_bumpcov.run.ref lgetkf_height_vloc.ref
3dvar_bumpcov_nbam.run dirac_bumploc.ref lgetkf_height_vloc.run
3dvar_bumpcov_nbam.run.ref dirac_bumploc.run lgetkf_height_vloc.run.ref
3dvar_bumpcov.ref dirac_bumploc.run.ref lgetkf.ref
3dvar_bumpcov_ropp.ref dirac_noloc.ref lgetkf.run
3dvar_bumpcov_rttovcpp.ref dirac_noloc.run lgetkf.run.ref
3dvar_bumpcov.run dirac_noloc.run.ref parameters_bumpcov.ref
3dvar_bumpcov.run.ref dirac_spectral_1.ref parameters_bumpcov.run
3dvar.ref dirac_spectral_1.run parameters_bumpcov.run.ref
3dvar.run dirac_spectral_1.run.ref parameters_bumploc.ref
3dvar.run.ref eda_3dhybrid.ref parameters_bumploc.run
4denvar_bumploc.ref eda_3dhybrid.run parameters_bumploc.run.ref
4denvar_bumploc.run eda_3dhybrid.run.ref rtpp.ref
4denvar_bumploc.run.ref ens_mean_variance.ref rtpp.run
4denvar_ID.ref ens_mean_variance.run rtpp.run.ref
</pre>
<p>
After running ctest, you can terminate your interactive job by simply typing 'exit' or by:
</p>
<pre class="terminal">
<em class="prompt">$ </em>qstat -u $USER
<em class="prompt">$ </em>qdel job-id-number
</pre>
<p>
The qstat command will return your job ID in a form of 'job-id-number.pbs101'.
The qdel command will kill your interactive job by only supplying 'job-id-number'.
</p>
<p>
Note that the tutorial test cases are designed with single-precision MPAS model test dataset.
Therefore, we pre-compiled mpas-bundle code with single-precision mode in
</p>
<pre class="terminal">
/home/project/17001770/weather_department/dae/taosun/MPAS-JEDI-Training/SINGV-NG-1.0
</pre>
<p>
Tutorial attendees should use this pre-build bundle for mpas-jedi practicals and should
set an environment variable 'bundle_dir' for convenience in the subsequent practices.
</p>
<pre class="terminal">
<em class="prompt">$ </em>export bundle_dir=/home/project/17001770/weather_department/dae/taosun/MPAS-JEDI-Training/SINGV-NG-1.0/build
</pre>
</div>
</div>
<!-- ============================================================================== -->
<!-- === 2. Converting NCEP BUFR obs into IODA-HDF5 format ====================== -->
<!-- ============================================================================== -->
<div class="header" onClick="show('convert')">
<h2 id="convert-header">2. Converting NCEP BUFR obs into IODA-HDF5 format</h2>
</div>
<div id="convert" class="section">
<p>
The goal of this session is to create the observation input files needed for running
MPAS-JEDI test cases.
</p>
<!-- === 2.1 Converter compilation ========================================= -->
<div class="subheader" onClick="show('obs2ioda')">
<h3 id="obs2ioda-header">2.1 Compiling the converter</h3>
</div>
<div id="obs2ioda" class="subsection">
<p>
Under the <em class="terminal">MPAS-JEDI-Training</em> directory,
create a directory for converting NCEP BUFR observation into IODA-HDF5 format.
Then, clone the obs2ioda repository and proceed for compiling the converter.
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd ${SCRATCH}/MPAS-JEDI-Training
<em class="prompt">$ </em>git clone https://github.com/NCAR/obs2ioda
<em class="prompt">$ </em>cd obs2ioda
</pre>
<p>
NCEP BUFR library (https://github.com/NOAA-EMC/NCEPLIBS-bufr) along with NETCDF-C and NETCDF-Fortran libraries.
are required to compile <em class="terminal">obs2ioda_v3</em>.
Here we have pre-built BUFR_LIB and
we put the pre-build BUFR_LIB path in <em class="terminal">Makefile</em>.
</p>
<p>
Load the proper intel compiler modules and then compile the converter by using <em class="terminal">make</em> command:
</p>
<pre class="terminal">
<em class="prompt">$ </em>source /home/project/17001770/weather_department/dae/taosun/MPAS-JEDI-Training/SINGV-NG-1.0/code/env-setup/gnu-aspire2a.sh
<em class="prompt">$ </em>mkdir build
<em class="prompt">$ </em>cd build
<em class="prompt">$ </em>cmake .. -DNCEP_BUFR_LIB=/data/projects/13004327/software_service/spack-stack/1.8-mos3r3n/envs/mpas-bundle/install/gcc/11.2.0/bufr-12.1.0-eemymeq/lib64/libbufr_4.so
<em class="prompt">$ </em>make
</pre>
<p>
If the compilation is successful, the executable file <em class="terminal">obs2ioda_v3</em> will be generated under build/bin.
</p>
</div>
<!-- === 2.2 Run obs2ioda-v2.x ================================================ -->
<div class="subheader" onClick="show('bufr')">
<h3 id="bufr-header">2.2 Convert prepbufr/bufr files to IODAv2-HDF5 format </h3>
</div>
<div id="bufr" class="subsection">
<p>
The NCEP bufr input files are under the existing OBS_FILE/BUFR folder. Now we need to convert
the bufr-format data into the iodav2-hdf5 format under the OBS_IODA folder.
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd ${SCRATCH}/MPAS-JEDI-Training
<em class="prompt">$ </em>mkidr OBS_IODA
<em class="prompt">$ </em>cd OBS_IODA
</pre>
<p>
Link the prepbufr/bufr files to the working directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/BUFR/prepbufr.gdas.20240917.t12z.nr.48h .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/BUFR/gdas.1bamua.t12z.20240917.bufr .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/BUFR/gdas.gpsro.t12z.20240917.bufr .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/BUFR/gdas.1bmhs.t12z.20240917.bufr .
</pre>
<p>
Link executables and files:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/obs2ioda/build/bin/obs2ioda_v3 .
</pre>
<p>
Now we can run <em class="terminal">obs2ioda_v3</em>.
The usage is:
</p>
<pre class="terminal">
<em class="prompt">$ </em>./obs2ioda_v3 [-i input_dir] [-o output_dir] [bufr_filename(s)_to_convert]
</pre>
<p>
If input_dir and output_dir are not specified, the default is the current working directory.
If bufr_filename(s)_to_convert is not specified, the code looks for file name, **prepbufr.bufr** (also **satwnd.bufr**, **gnssro.bufr**, **amsua.bufr**, **airs.bufr**, **mhs.bufr**, **iasi.bufr**, **cris.bufr**) in the input/working directory. If the file exists, do the conversion, otherwise skip it.
</p>
<pre class="terminal">
<em class="prompt">$ </em>source /home/project/17001770/weather_department/dae/taosun/MPAS-JEDI-Training/SINGV-NG-1.0/code/env-setup/gnu-aspire2a.sh
<em class="prompt">$ </em>./obs2ioda_v3 prepbufr.gdas.20240917.t12z.nr.48h
<em class="prompt">$ </em>./obs2ioda_v3 gdas.satwnd.t12z.20240917.bufr
<em class="prompt">$ </em>./obs2ioda_v3 gdas.gpsro.t12z.20240917.bufr
<em class="prompt">$ </em>./obs2ioda_v3 gdas.1bamua.t12z.20240917.bufr
<em class="prompt">$ </em>./obs2ioda_v3 gdas.1bmhs.t12z.20240917.bufr
</pre>
<p>
Now you have the proper format IODA files under OBS_IODA for mpas-jedi tests:
</p>
<pre class="terminal">
aircraft_obs_2024091712.h5 amsua_n19_obs_2024091712.h5 mhs_n19_obs_2024091712.h5
amsua_metop-b_obs_2024091712.h5 ascat_obs_2024091712.h5 satwind_obs_2024091712.h5
amsua_metop-c_obs_2024091712.h5 gnssro_obs_2024091712.h5 sfc_obs_2024091712.h5
amsua_n15_obs_2024091712.h5 mhs_metop-b_obs_2024091712.h5 sondes_obs_2024091712.h5
amsua_n18_obs_2024091712.h5 mhs_metop-c_obs_2024091712.h5
</pre>
</div>
<!-- === 2.3 Plot Obs locations ============================================== -->
<div class="subheader" onClick="show('plot_loc')">
<h3 id="plot_loc-header">2.3 Plotting observation coverage</h3>
</div>
<div id="plot_loc" class="subsection">
<p>
Setup python enviorment for plotting.
</p>
<p><i>
Note that we need to load the python environment before executing the python script.
If you have already loaded the spack-stack module, reset the module environment before loading python env.
</i></p>
<pre class="terminal">
<em class="prompt">$ </em>module load miniforge3/25.3.1
<em class="prompt">$ </em>conda activate /home/project/13004327/software_service/conda_envs/MPAS-JEDI-Training
</pre>
<p>
Copy graphics directory to current directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>cp -r ${SCRATCH}/MPAS-JEDI-Training/Graphics/plot_obs_singv.py .
<em class="prompt">$ </em>python plot_obs_singv.py
</pre>
<p>
Now, one of the figures shown here:
</p>
<img src="images/OBS_horizontal_distribution_satwind.png", width="800"/>
</div>
</div>
<!-- ============================================================================== -->
<!-- === 3. Running MPAS-JEDI's HofX application ======== -->
<!-- ============================================================================== -->
<div class="header" onClick="show('hofx')">
<h2 id="hofx-header">3. Running MPAS-JEDI's HofX application</h2>
</div>
<div id="hofx" class="section">
<p>
In this session, we will be running an application called 𝐻(𝐱), which maps the model states to the observation space.
</p>
<!-- === 3.1 Create working directory and link files =================== -->
<div class="subheader" onClick="show('grid_rotate')">
<h3 id="grid_rotate-header">3.1 Create working directory and link files</h3>
</div>
<div id="grid_rotate" class="subsection">
<p>
Creating HofX directory in MPAS-JEDI-Training
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd ${SCRATCH}/MPAS-JEDI-Training
<em class="prompt">$ </em>mkdir HofX
<em class="prompt">$ </em>cd HofX
</pre>
<p>
Set environment variable for the mpas-bundle directory
</p>
<pre class="terminal">
<em class="prompt">$ </em>export bundle_dir=/home/project/17001770/weather_department/dae/taosun/MPAS-JEDI-Training/SINGV-NG-1.0/build
</pre>
<p>
Now, we need to prepare input files to run hofx.
The following commands are for linking files, such as,
physics-related data and tables, MPAS graph, streams, and namelist files:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${bundle_dir}/MPAS/core_atmosphere/*TBL .
<em class="prompt">$ </em>ln -fs ${bundle_dir}/MPAS/core_atmosphere/*DBL .
<em class="prompt">$ </em>ln -fs ${bundle_dir}/MPAS/core_atmosphere/*DATA .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/grid/x1.522172.graph.info* .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/namelist.atmosphere .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/streams.atmosphere .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.analysis .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.background .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.control .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.ensemble .
</pre>
<p>
Link yamls:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/geovars.yaml .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/keptvars.yaml .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/obsop_name_map.yaml .
</pre>
<p>
The MPAS uses the 2-stream IO, in which invariant and variant states are stored in seperate files.
Link MPAS invariant file (invariant fields) and 6-h forecast background file (variant fields).
Also, link the 6-h forecast file as the template file:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/grid/invariant.522172.nc .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/background/mpasout.2024-09-17_12.00.00.nc ./bg.2024-09-17_12.00.00.nc
<em class="prompt">$ </em>ln -fs bg.2024-09-17_12.00.00.nc templateFields.522172.2024-09-17_12.00.00.nc
</pre>
<p>
Create dbIn and dbOut directories, and then link the observation input files under it:
<pre class="terminal">
<em class="prompt">$ </em>mkdir dbIn dbOut
<em class="prompt">$ </em>cd dbIn
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/IODA/aircraft_obs_2024091712.h5 .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/IODA/gnssro_obs_2024091712.h5 .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/IODA/satwind_obs_2024091712.h5 .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/IODA/sfc_obs_2024091712.h5 .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/OBS_FILE/IODA/sondes_obs_2024091712.h5 .
</pre>
</div>
<!-- === 3.2 Run HofX ========================================== -->
<div class="subheader" onClick="show('initialization-static-varres')">
<h3 id="initialization-static-varres-header">3.2 Run HofX</h3>
</div>
<div id="initialization-static-varres" class="subsection">
<p>
Copy hofx.yaml and run_hofx.ksh to the working directory:
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd ${SCRATCH}/MPAS-JEDI-Training/HofX
<em class="prompt">$ </em>cp ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/hofx.yaml .
<em class="prompt">$ </em>cp ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/run_hofx.ksh .
</pre>
<p>
Submit a PBS job to run hofx,
</p>
<pre class="terminal">
<em class="prompt">$ </em>qsub run_hofx.ksh
</pre>
<p>
According to the setting in hofx.yaml, the output files are obsout_hofx_*.h5 under dbOut.
You may check the output file content, e.g., using 'ncdump -h obsout_hofx_aircraft.h5'.
you can also check hofx by running plot_diag.py.
</p>
<p>
The following steps are for set up python environment, copy graphics directory, and run plot_diag.py:
</p>
<pre class="terminal">
<em class="prompt">$ </em>module load miniforge3/25.3.1
<em class="prompt">$ </em>conda activate /home/project/13004327/software_service/conda_envs/MPAS-JEDI-Training
<em class="prompt">$ </em>cp ${SCRATCH}/MPAS-JEDI-Training/Graphics/plot_obs_singv.py .
</pre>
Before plotting, you need to do several modifications as the following in plot_obs_singv.py:
<pre class="terminal">
obsout_dir = './dbOut'
plot_type = 'HofX'
hofx_da = 'hofx'
sensors = ['satwind','sondes','aircraft','sfc','gnssro']
</pre>
Then, you can run the Python script to plot the simulated observed variables.
<pre class="terminal"></pre>
<em class="prompt">$ </em>python plot_diag.py
</pre>
</p>
<p>
This will produce a number of figure files, display one of them
<p>
<pre class="terminal">
display HofX_horizontal_distribution_satwind.png
</pre>
<p>
which will look like the figure below
</p>
<img src="images/HofX_horizontal_distribution_satwind.png", width="800"/>
</div>
</div>
<!-- ============================================================================== -->
<!-- === 4. Generating localization files and running 3D/4DEnVar with "conventional" obs
<!-- ============================================================================== -->
<div class="header" onClick="show('envar')">
<h2 id="envar-header">4. Generating localization files and running 3DEnVar with "conventional" obs</h2>
</div>
<div id="envar" class="section">
<p>
</p>
<!-- === 4.1 Generating BUMP localization files ============== -->
<div class="subheader" onClick="show('generate_localization')">
<h3 id="generate_localization-header">4.1 Generating BUMP localization files</h3>
</div>
<div id="generate_localization" class="subsection">
<p>
In this practice, we will generate the BUMP localization files to be used for spatial localization
of ensemble background error covariance. These files will be used in the following 3DEnVar and hybrid-3DEnVar
data assimilation practice.
</p>
<p>
Create the working directory.
</p>
<pre class="terminal">
<em class="prompt">$ </em>cd ${SCRATCH}/MPAS-JEDI-Training
<em class="prompt">$ </em>mkdir Localization
<em class="prompt">$ </em>cd Localization
</pre>
<p>
set the bundle_dir environment
</p>
<pre class="terminal">
<em class="prompt">$ </em>export bundle_dir=/home/project/17001770/weather_department/dae/taosun/MPAS-JEDI-Training/SINGV-NG-1.0/build
</pre>
<p>
Now, we need to prepare input files to generate BUMP localization files.
Similar to what we have done for the HofX application, we need to link MPAS physics-related data and tables, MPAS graph, streams, and namelist files:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${bundle_dir}/MPAS/core_atmosphere/*TBL .
<em class="prompt">$ </em>ln -fs ${bundle_dir}/MPAS/core_atmosphere/*DBL .
<em class="prompt">$ </em>ln -fs ${bundle_dir}/MPAS/core_atmosphere/*DATA .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/grid/x1.522172.graph.info* .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/namelist.atmosphere .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/streams.atmosphere .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.analysis .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.background .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.control .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/streamNamelist/stream_list.atmosphere.ensemble .
</pre>
<p>
Then, link yamls:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/geovars.yaml .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/keptvars.yaml .
</pre>
<p>
Followed by the 2-stream IO files:
</p>
<pre class="terminal">
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/grid/invariant.522172.nc .
<em class="prompt">$ </em>ln -fs ${SCRATCH}/MPAS-JEDI-Training/MPAS_FILE/background/mpasout.2024-09-17_12.00.00.nc .
<em class="prompt">$ </em>ln -fs mpasout.2024-09-17_12.00.00.nc templateFields.522172.2024-09-17_12.00.00.nc
</pre>
<p>
copy the MPAS-JEDI yaml file and the pbs job script, and then submit the job script.
</p>
<pre class="terminal">
<em class="prompt">$ </em>cp ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/bumploc.yaml .
<em class="prompt">$ </em>cp ${SCRATCH}/MPAS-JEDI-Training/MPASJEDI_FILE/run_bumploc.ksh .
<em class="prompt">$ </em>qsub run_bumploc.ksh
</pre>
<p>
User may check the PBS job status by running <em class="terminal">qstat -u $USER</em>,
or monitoring the log file <em class="terminal">jedi.log</em>.
</p>
<p>
After finishing the PBS job, user can check the BUMP localization files generated. The "local" files are generated for each processor (256 processors in this practice).
</p>
<pre class="terminal">
<em class="prompt">$ </em>ls bumploc_nicas_local_*.nc <br>
</pre>
<p>
For a Dirac function multiplied by a given localization function, user can make a plot with <em class="terminal"> dirac_nicas.2024-09-17_12.00.00.nc</em> .
</p>
<p><i>