Skip to content

Commit 449eea7

Browse files
authored
Merge branch 'master' into EnhanceTest
2 parents b8c3ccf + 658f188 commit 449eea7

File tree

111 files changed

+10482
-855
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

111 files changed

+10482
-855
lines changed

.github/workflows/frontier/submit-bench.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ sbatch <<EOT
3232
#SBATCH -A CFD154 # charge account
3333
#SBATCH -N 1 # Number of nodes required
3434
$sbatch_device_opts
35-
#SBATCH -t 01:59:00 # Duration of the job (Ex: 15 mins)
35+
#SBATCH -t 02:59:00 # Duration of the job (Ex: 15 mins)
3636
#SBATCH -o$job_slug.out # Combined output and error messages file
3737
#SBATCH -p extended # Extended partition for shorter queues
3838
#SBATCH -W # Do not exit until the submitted job terminates.

.github/workflows/frontier/submit.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ sbatch <<EOT
3333
#SBATCH -A CFD154 # charge account
3434
#SBATCH -N 1 # Number of nodes required
3535
$sbatch_device_opts
36-
#SBATCH -t 01:59:00 # Duration of the job (Ex: 15 mins)
36+
#SBATCH -t 02:59:00 # Duration of the job (Ex: 15 mins)
3737
#SBATCH -o$job_slug.out # Combined output and error messages file
3838
#SBATCH -p extended # Extended partition for shorter queues
3939
#SBATCH -W # Do not exit until the submitted job terminates.

.github/workflows/phoenix/submit-bench.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ JOBID=$(sbatch <<-EOT | awk '{print $4}'
6969
EOT
7070
)
7171

72-
echo "🚀 Submitted SLURM job $JOBID"
72+
echo "Submitted: SLURM job $JOBID"
7373

7474
# if this wrapper is killed/canceled, make sure SLURM job is cleaned up
7575
trap '[[ -n "${JOBID:-}" ]] && scancel "$JOBID" >/dev/null 2>&1 || :' EXIT
@@ -86,22 +86,22 @@ while :; do
8686

8787
# If it’s one of SLURM’s terminal states, break immediately
8888
case "$STATE" in
89-
COMPLETED|FAILED|CANCELLED|TIMEOUT)
90-
echo " SLURM job $JOBID reached terminal state: $STATE"
89+
COMPLETED|FAILED|CANCELLED|TIMEOUT|PREEMPTED)
90+
echo "Completed: SLURM job $JOBID reached terminal state: $STATE"
9191
break
9292
;;
9393
"")
94-
echo " SLURM job $JOBID no longer in queue; assuming finished"
94+
echo "Completed: SLURM job $JOBID no longer in queue; assuming finished"
9595
break
9696
;;
9797
*)
98-
echo " SLURM job $JOBID state: $STATE"
98+
echo "Waiting: SLURM job $JOBID state: $STATE"
9999
sleep 10
100100
;;
101101
esac
102102
done
103103

104104
# Now retrieve the exit code and exit with it
105105
EXIT_CODE=$(sacct -j "$JOBID" --noheader --format=ExitCode | head -1 | cut -d: -f1)
106-
echo "🔚 SLURM job $JOBID exit code: $EXIT_CODE"
106+
echo "Completed: SLURM job $JOBID exit code: $EXIT_CODE"
107107
exit "$EXIT_CODE"

.github/workflows/phoenix/submit.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ JOBID=$(sbatch <<-EOT | awk '{print $4}'
6262
EOT
6363
)
6464

65-
echo "🚀 Submitted SLURM job $JOBID"
65+
echo "Submitted: SLURM job $JOBID"
6666

6767
# if this wrapper is killed/canceled, make sure SLURM job is cleaned up
6868
trap '[[ -n "${JOBID:-}" ]] && scancel "$JOBID" >/dev/null 2>&1 || :' EXIT
@@ -79,22 +79,22 @@ while :; do
7979

8080
# If it’s one of SLURM’s terminal states, break immediately
8181
case "$STATE" in
82-
COMPLETED|FAILED|CANCELLED|TIMEOUT)
83-
echo " SLURM job $JOBID reached terminal state: $STATE"
82+
COMPLETED|FAILED|CANCELLED|TIMEOUT|PREEMPTED)
83+
echo "Completed: SLURM job $JOBID reached terminal state: $STATE"
8484
break
8585
;;
8686
"")
87-
echo " SLURM job $JOBID no longer in queue; assuming finished"
87+
echo "Completed: SLURM job $JOBID no longer in queue; assuming finished"
8888
break
8989
;;
9090
*)
91-
echo " SLURM job $JOBID state: $STATE"
91+
echo "Waiting: SLURM job $JOBID state: $STATE"
9292
sleep 10
9393
;;
9494
esac
9595
done
9696

9797
# Now retrieve the exit code and exit with it
9898
EXIT_CODE=$(sacct -j "$JOBID" --noheader --format=ExitCode | head -1 | cut -d: -f1)
99-
echo "🔚 SLURM job $JOBID exit code: $EXIT_CODE"
99+
echo "Completed: SLURM job $JOBID exit code: $EXIT_CODE"
100100
exit "$EXIT_CODE"

CMakeLists.txt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -135,17 +135,17 @@ if (CMAKE_Fortran_COMPILER_ID STREQUAL "GNU")
135135
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
136136
add_compile_options(
137137
-Wall
138-
-Wextra
138+
-Wextra
139139
-fcheck=all,no-array-temps
140140
-fbacktrace
141141
-fimplicit-none
142142
-fsignaling-nans
143143
-finit-real=snan
144144
-finit-integer=-99999999
145-
-Wintrinsic-shadow
146-
-Wunderflow
147-
-Wrealloc-lhs
148-
-Wsurprising
145+
-Wintrinsic-shadow
146+
-Wunderflow
147+
-Wrealloc-lhs
148+
-Wsurprising
149149
)
150150
endif()
151151

@@ -163,6 +163,7 @@ elseif (CMAKE_Fortran_COMPILER_ID STREQUAL "Cray")
163163
"SHELL:-h acc_model=auto_async_none"
164164
"SHELL: -h acc_model=no_fast_addr"
165165
"SHELL: -h list=adm"
166+
"SHELL: -munsafe-fp-atomics" # Not unsafe for operations we do
166167
)
167168

168169
add_link_options("SHELL:-hkeepfiles")
@@ -172,7 +173,6 @@ elseif (CMAKE_Fortran_COMPILER_ID STREQUAL "Cray")
172173
"SHELL:-h acc_model=auto_async_none"
173174
"SHELL: -h acc_model=no_fast_addr"
174175
"SHELL: -K trap=fp" "SHELL: -G2"
175-
176176
)
177177
add_link_options("SHELL: -K trap=fp" "SHELL: -G2")
178178
endif()
@@ -200,10 +200,10 @@ elseif ((CMAKE_Fortran_COMPILER_ID STREQUAL "NVHPC") OR (CMAKE_Fortran_COMPILER_
200200
if (CMAKE_BUILD_TYPE STREQUAL "Debug")
201201
add_compile_options(
202202
$<$<COMPILE_LANGUAGE:Fortran>:-O0>
203-
$<$<COMPILE_LANGUAGE:Fortran>:-C>
203+
$<$<COMPILE_LANGUAGE:Fortran>:-C>
204204
$<$<COMPILE_LANGUAGE:Fortran>:-g>
205-
$<$<COMPILE_LANGUAGE:Fortran>:-traceback>
206-
$<$<COMPILE_LANGUAGE:Fortran>:-Minform=inform>
205+
$<$<COMPILE_LANGUAGE:Fortran>:-traceback>
206+
$<$<COMPILE_LANGUAGE:Fortran>:-Minform=inform>
207207
$<$<COMPILE_LANGUAGE:Fortran>:-Mbounds>
208208
)
209209
endif()

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,8 @@ They are organized below.
155155
* Runge-Kutta orders 1-3 (SSP TVD), adaptive time stepping
156156
* RK4-5 operator splitting for Euler-Lagrange modeling
157157
* Interface sharpening (THINC-like)
158+
* Information geometric regularization (IGR)
159+
* Shock capturing without WENO and Riemann solvers
158160

159161
### Large-scale and accelerated simulation
160162

benchmarks/5eq_rk3_weno3_hllc/case.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -188,8 +188,8 @@
188188
"cyl_coord": "F",
189189
"dt": dt,
190190
"t_step_start": 0,
191-
"t_step_stop": int(30 * (95 * size + 5)),
192-
"t_step_save": int(30 * (95 * size + 5)),
191+
"t_step_stop": int(20 * (5 * size + 5)),
192+
"t_step_save": int(20 * (5 * size + 5)),
193193
# Simulation Algorithm Parameters
194194
"num_patches": 3,
195195
"model_eqns": 2,

benchmarks/hypo_hll/case.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@
4141
"p": Nz,
4242
"dt": 1e-8,
4343
"t_step_start": 0,
44-
"t_step_stop": int(30 * (95 * size + 5)),
45-
"t_step_save": int(30 * (95 * size + 5)),
44+
"t_step_stop": int(20 * (5 * size + 5)),
45+
"t_step_save": int(20 * (5 * size + 5)),
4646
# Simulation Algorithm Parameters
4747
"num_patches": 2,
4848
"model_eqns": 2,

benchmarks/ibm/case.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@
4545
"p": Nz,
4646
"dt": mydt,
4747
"t_step_start": 0,
48-
"t_step_stop": int(20 * (95 * size + 5)),
49-
"t_step_save": int(20 * (95 * size + 5)),
48+
"t_step_stop": int(20 * (5 * size + 5)),
49+
"t_step_save": int(20 * (5 * size + 5)),
5050
# Simulation Algorithm Parameters
5151
"num_patches": 1,
5252
"model_eqns": 2,

benchmarks/igr/case.py

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
#!/usr/bin/env python3
2+
# Benchmark igr_T_viscous_T
3+
# Additional Benchmarked Features
4+
# - igr : T
5+
# - viscous : T
6+
# - igr_order : 5
7+
8+
import json, math, argparse
9+
10+
parser = argparse.ArgumentParser(prog="Benchmarking Case 5", description="This MFC case was created for the purposes of benchmarking MFC.", formatter_class=argparse.ArgumentDefaultsHelpFormatter)
11+
12+
parser.add_argument("--mfc", type=json.loads, default="{}", metavar="DICT", help="MFC's toolchain's internal state.")
13+
parser.add_argument("--gbpp", type=int, metavar="MEM", default=16, help="Adjusts the problem size per rank to fit into [MEM] GB of GPU memory per GPU.")
14+
15+
ARGS = vars(parser.parse_args())
16+
DICT = ARGS["mfc"]
17+
18+
size = 1 if DICT["gpu"] else 0
19+
20+
ppg = 8000000 / 16.0
21+
procs = DICT["nodes"] * DICT["tasks_per_node"]
22+
ncells = math.floor(ppg * procs * ARGS["gbpp"])
23+
s = math.floor((ncells) ** (1 / 3))
24+
Nx, Ny, Nz = s, s, s
25+
26+
Re = 1600
27+
L = 1
28+
P0 = 101325
29+
rho0 = 1
30+
C0 = math.sqrt(1.4 * P0)
31+
V0 = 0.1 * C0
32+
mu = V0 * L / Re
33+
34+
cfl = 0.5
35+
dx = 2 * math.pi * L / (Nx + 1)
36+
37+
dt = cfl * dx / (C0)
38+
39+
tC = L / V0
40+
tEnd = 20 * tC
41+
42+
Nt = int(tEnd / dt)
43+
44+
# Configuring case dictionary
45+
print(
46+
json.dumps(
47+
{
48+
# Logistics
49+
"run_time_info": "T",
50+
# Computational Domain Parameters
51+
"x_domain%beg": -math.pi * L,
52+
"x_domain%end": math.pi * L,
53+
"y_domain%beg": -math.pi * L,
54+
"y_domain%end": math.pi * L,
55+
"z_domain%beg": -math.pi * L,
56+
"z_domain%end": math.pi * L,
57+
"m": Nx,
58+
"n": Ny,
59+
"p": Nz,
60+
"cyl_coord": "F",
61+
"dt": dt,
62+
"t_step_start": 0,
63+
"t_step_stop": int(20 * (5 * size + 5)),
64+
"t_step_save": int(20 * (5 * size + 5)),
65+
# Simulation Algorithm Parameters
66+
"num_patches": 1,
67+
"model_eqns": 2,
68+
"num_fluids": 1,
69+
"time_stepper": 3,
70+
"bc_x%beg": -1,
71+
"bc_x%end": -1,
72+
"bc_y%beg": -1,
73+
"bc_y%end": -1,
74+
"bc_z%beg": -1,
75+
"bc_z%end": -1,
76+
"igr": "T",
77+
"igr_order": 5,
78+
"igr_iter_solver": 1,
79+
"num_igr_iters": 3,
80+
"num_igr_warm_start_iters": 3,
81+
"alf_factor": 10,
82+
"viscous": "T",
83+
# Formatted Database Files Structure Parameters
84+
"format": 1,
85+
"precision": 2,
86+
"prim_vars_wrt": "T",
87+
"omega_wrt(1)": "T",
88+
"omega_wrt(2)": "T",
89+
"omega_wrt(3)": "T",
90+
"qm_wrt": "T",
91+
"fd_order": 4,
92+
"parallel_io": "T",
93+
# Patch 1: Background (AIR - 2)
94+
"patch_icpp(1)%geometry": 9,
95+
"patch_icpp(1)%x_centroid": 0,
96+
"patch_icpp(1)%y_centroid": 0,
97+
"patch_icpp(1)%z_centroid": 0,
98+
"patch_icpp(1)%length_x": 2 * math.pi * L,
99+
"patch_icpp(1)%length_y": 2 * math.pi * L,
100+
"patch_icpp(1)%length_z": 2 * math.pi * L,
101+
"patch_icpp(1)%vel(1)": f"{V0}*sin(x/{L})*cos(y/{L})*sin(z/{L})",
102+
"patch_icpp(1)%vel(2)": f"-{V0}*cos(x/{L})*sin(y/{L})*sin(z/{L})",
103+
"patch_icpp(1)%vel(3)": 0,
104+
"patch_icpp(1)%pres": f"{P0} + ({rho0}*{V0}**2/16)*(cos(2*x/{L}) + cos(2*y/{L}))*(cos(2*z/{L}) + 2)",
105+
"patch_icpp(1)%alpha_rho(1)": 1,
106+
"patch_icpp(1)%alpha(1)": 1,
107+
# Fluids Physical Parameters
108+
"fluid_pp(1)%gamma": 1.0e00 / (1.4 - 1),
109+
"fluid_pp(1)%pi_inf": 0,
110+
"fluid_pp(1)%Re(1)": 1 / mu,
111+
}
112+
)
113+
)

0 commit comments

Comments
 (0)