Skip to content

Commit 9282c6d

Browse files
committed
Merge remote-tracking branch 'upstream/master' into CodeTidying
2 parents 7a287ce + 16d582f commit 9282c6d

Some content is hidden

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

41 files changed

+1376
-1688
lines changed

.github/workflows/frontier/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/bash
22

33
build_opts=""
4-
if [ "$1" == "gpu" ]; then
4+
if [ "$1" = "gpu" ]; then
55
build_opts="--gpu"
66
fi
77

.github/workflows/frontier/submit.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ else
1313
exit 1
1414
fi
1515

16-
if [ "$2" == "cpu" ]; then
16+
if [ "$2" = "cpu" ]; then
1717
sbatch_device_opts="\
1818
#SBATCH -n 32 # Number of cores required"
19-
elif [ "$2" == "gpu" ]; then
19+
elif [ "$2" = "gpu" ]; then
2020
sbatch_device_opts="\
2121
#SBATCH -n 8 # Number of cores required"
2222
else

.github/workflows/frontier/test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
gpus=`rocm-smi --showid | awk '{print $1}' | grep -Eo '[0-9]+' | uniq | tr '\n' ' '`
44
ngpus=`echo "$gpus" | tr -d '[:space:]' | wc -c`
55

6-
if [ "$job_device" == "gpu" ]; then
6+
if [ "$job_device" = "gpu" ]; then
77
./mfc.sh test --max-attempts 3 -j $ngpus -- -c frontier
88
else
99
./mfc.sh test --max-attempts 3 -j 32 -- -c frontier

.github/workflows/phoenix/bench.sh

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,26 @@
22

33
n_ranks=12
44

5-
if [ "$job_device" == "gpu" ]; then
5+
if [ "$job_device" = "gpu" ]; then
66
n_ranks=$(nvidia-smi -L | wc -l) # number of GPUs on node
77
gpu_ids=$(seq -s ' ' 0 $(($n_ranks-1))) # 0,1,2,...,gpu_count-1
88
device_opts="--gpu -g $gpu_ids"
99
fi
1010

11-
mkdir -p /storage/scratch1/6/sbryngelson3/mytmp_build
12-
export TMPDIR=/storage/scratch1/6/sbryngelson3/mytmp_build
11+
tmpbuild=/storage/scratch1/6/sbryngelson3/mytmp_build
12+
currentdir=$tmpbuild/run-$(( RANDOM % 900 ))
13+
mkdir -p $tmpbuild
14+
mkdir -p $currentdir
1315

14-
if ["$job_device" == "gpu"]; then
16+
export TMPDIR=$currentdir
17+
18+
if [ "$job_device" = "gpu" ]; then
1519
./mfc.sh bench --mem 12 -j $(nproc) -o "$job_slug.yaml" -- -c phoenix-bench $device_opts -n $n_ranks
1620
else
1721
./mfc.sh bench --mem 1 -j $(nproc) -o "$job_slug.yaml" -- -c phoenix-bench $device_opts -n $n_ranks
1822
fi
1923

24+
sleep 10
25+
rm -rf "$currentdir" || true
26+
2027
unset TMPDIR

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ sbatch_gpu_opts="\
2525
#SBATCH -G2\
2626
"
2727

28-
if [ "$2" == "cpu" ]; then
28+
if [ "$2" = "cpu" ]; then
2929
sbatch_device_opts="$sbatch_cpu_opts"
30-
elif [ "$2" == "gpu" ]; then
30+
elif [ "$2" = "gpu" ]; then
3131
sbatch_device_opts="$sbatch_gpu_opts"
3232
else
3333
usage

.github/workflows/phoenix/submit.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ sbatch_gpu_opts="\
2525
#SBATCH -G2\
2626
"
2727

28-
if [ "$2" == "cpu" ]; then
28+
if [ "$2" = "cpu" ]; then
2929
sbatch_device_opts="$sbatch_cpu_opts"
30-
elif [ "$2" == "gpu" ]; then
30+
elif [ "$2" = "gpu" ]; then
3131
sbatch_device_opts="$sbatch_gpu_opts"
3232
else
3333
usage

.github/workflows/phoenix/test.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
#!/bin/bash
22

33
build_opts=""
4-
if [ "$job_device" == "gpu" ]; then
4+
if [ "$job_device" = "gpu" ]; then
55
build_opts="--gpu"
66
fi
77

88
./mfc.sh test --dry-run -j 8 $build_opts
99

1010
n_test_threads=8
1111

12-
if [ "$job_device" == "gpu" ]; then
12+
if [ "$job_device" = "gpu" ]; then
1313
gpu_count=$(nvidia-smi -L | wc -l) # number of GPUs on node
1414
gpu_ids=$(seq -s ' ' 0 $(($gpu_count-1))) # 0,1,2,...,gpu_count-1
1515
device_opts="-g $gpu_ids"

.typos.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ gam = "gam"
1717
Gam = "Gam"
1818
strang = "strang"
1919
Strang = "Strang"
20+
TKE = "TKE"
2021

2122
[files]
2223
extend-exclude = ["docs/documentation/references*", "tests/", "toolchain/cce_simulation_workgroup_256.sh"]

docs/documentation/case.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -825,7 +825,6 @@ When ``polytropic = 'F'``, the gas compression is modeled as non-polytropic due
825825
| `mixlayer_vel_profile` | Logical | Set the mean streamwise velocity to hyperbolic tangent profile |
826826
| `mixlayer_vel_coef` | Real | Coefficient for the hyperbolic tangent profile of a mixing layer |
827827
| `mixlayer_perturb` | Logical | Perturb the initial velocity field by instability waves |
828-
| `mixlayer_domain` | Real | Domain size of a mixing layer for the linear stability analysis |
829828

830829
The table lists velocity field parameters.
831830
The parameters are optionally used to define initial velocity profiles and perturbations.
@@ -840,15 +839,13 @@ The parameters are optionally used to define initial velocity profiles and pertu
840839

841840
- `perturb_sph_fluid` specifies the fluid component whose partial density is to be perturbed.
842841

843-
- `mixlayer_vel_profile` activates setting the mean streamwise velocity to a hyperbolic tangent profile. This option works only for 2D and 3D cases.
842+
- `mixlayer_vel_profile` activates setting the mean streamwise velocity to a hyperbolic tangent profile. This option works only for `n > 0`.
844843

845844
- `mixlayer_vel_coef` is a parameter for the hyperbolic tangent profile of a mixing layer when `mixlayer_vel_profile = 'T'`. The mean streamwise velocity profile is given as:
846845

847-
$$ u = patch\_icpp(1)\%vel(1) * tanh(y\_cc * mixlayer\_vel\_profile) $$
846+
$$ u = \mbox{patch\_icpp(1)\%vel(1)} * \tanh( y_{cc} * \mbox{mixlayer\_vel\_coef}) $$
848847

849-
- `mixlayer_perturb` activates the perturbation of initial velocity by instability waves obtained from linear stability analysis for a mixing layer with hyperbolic tangent mean streamwise velocity profile. This option only works for `n > 0`, `bc_y%[beg,end] = -6`, `num_fluids = 1`, `model_eqns = 2` and `mixlayer_vel_profile = 'T'`.
850-
851-
- `mixlayer_domain` defines the domain size to compute spatial eigenvalues of the linear instability analysis when `mixlayer_perturb = 'T'`. For example, the spatial eigenvalue in `x` direction in 2D problem will be $2 \pi \alpha / (mixlayer\_domain*patch\_icpp(1)\%length\_y)$ for $\alpha = 1$, $2$ and $4$.
848+
- `mixlayer_perturb` activates the velocity perturbation for a temporal mixing layer with hyperbolic tangent mean streamwise velocity profile, using an inverter version of the spectrum-based synthetic turbulence generation method proposed by Guo et al. (2023, JFM). This option only works for `p > 0` and `mixlayer_vel_profile = 'T'`.
852849

853850
### 11. Phase Change Model
854851
| Parameter | Type | Description |

docs/documentation/references.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020

2121
- <a id="Gottlieb98">Gottlieb, S. and Shu, C.-W. (1998). Total variation diminishing runge-kutta schemes. Mathematics of computation of the American Mathematical Society, 67(221):73–85.</a>
2222

23+
- <a id="Guo23">Guo, H., Jiang, P., Ye, L., & Zhu, Y. (2023). An efficient and low-divergence method for generating inhomogeneous and anisotropic turbulence with arbitrary spectra. Journal of Fluid Mechanics, 970, A2.</a>
24+
2325
- <a id="Henrick05">Henrick, A. K., Aslam, T. D., and Powers, J. M. (2005). Mapped weighted essentially nonoscillatory schemes: achieving optimal order near critical points. Journal of Computational Physics, 207(2):542–567.</a>
2426

2527
- <a id="Borges08">Borges, R., Carmona, M., Costa, B., and Don, W. S. (2008). An improved weighted essentially non-oscillatory scheme for hyperbolic conservation laws. Journal of computational physics, 227(6):3191–3211.</a>
@@ -34,6 +36,8 @@
3436

3537
- <a id="Meng16">Meng, J. C. C. (2016). Numerical simulations of droplet aerobreakup. PhD thesis, California Institute of Technology.</a>
3638

39+
- <a id="Michalke64"> Michalke, A. (1964). On the inviscid instability of the hyperbolictangent velocity profile. Journal of Fluid Mechanics, 19(4), 543-556.</a>
40+
3741
- <a id="Pirozzoli13">Pirozzoli, S., and Colonius, T. (2013). Generalized characteristic relaxation boundary conditions for unsteady compressible flow simulations. Journal of Computational Physics, 248:109-126.</a>
3842

3943
- <a id="Preston07">Preston, A., Colonius, T., and Brennen, C. (2007). A reduced-order model of diffusive effects on the dynamics of bubbles. Physics of Fluids, 19(12):123302.</a>

0 commit comments

Comments
 (0)