|
flow 1.3.0
Kokkos cut-cell IBM incompressible Navier-Stokes solver + pnm pore extraction
|
Functions | |
| scene () | |
| compare () | |
| main () | |
Variables | |
| OUT = os.path.dirname(os.path.abspath(__file__)) | |
| N | |
| STEPS | |
| RHO | |
| MU | |
| F | |
| DT | |
| float | RF = 0.18 |
| float | R = RF * N |
| list | CEN |
| KN_R | |
| KI_I | |
| KI_R | |
Layer 2 (MPI scene demo) + Layer 4 rung 4 (replicated instances) gate.
An analytic scene is REPLICATED on every rank, so a rank derives its own block's geometry from it
with no communication at all -- that, and not any new exchange, is what lifts the single-rank
restriction the Python override path carried (set_exact_crossings / set_openness_override are
single-rank only). This script checks that claim end to end at np=1,2,4:
1. GEOMETRY. The scene-sampled SDF and the per-cell cut OWNER on each rank's block must equal the
single-rank global fields restricted to that block -- exactly, since every rank evaluates the
same replicated scene at global coordinates.
2. PHYSICS. The permeability k = mu<u>/f from a scene-driven solve must agree across np.
3. RESOLVED LOADS (L4-R4). The per-instance hydrodynamic force, which each rank integrates over
the wall cells inside its OWN block and which is summed across ranks, must agree across np.
Atomics over an unordered traversal make this tolerance-reproducible, not bitwise.
Run:
PYTHONPATH=<build_mpi> mpirun -np 1 python tests/study/sdf_campaign/mpi_scene_gate.py
PYTHONPATH=<build_mpi> mpirun -np 2 python tests/study/sdf_campaign/mpi_scene_gate.py
PYTHONPATH=<build_mpi> mpirun -np 4 python tests/study/sdf_campaign/mpi_scene_gate.py
Each run writes np<N>.npz; compare with `python mpi_scene_gate.py --compare`.
| mpi_scene_gate.scene | ( | ) |
Definition at line 36 of file mpi_scene_gate.py.
Referenced by main().
| mpi_scene_gate.compare | ( | ) |
Definition at line 46 of file mpi_scene_gate.py.
Referenced by main().
| mpi_scene_gate.main | ( | ) |
| mpi_scene_gate.OUT = os.path.dirname(os.path.abspath(__file__)) |
Definition at line 26 of file mpi_scene_gate.py.
| mpi_scene_gate.N |
Definition at line 27 of file mpi_scene_gate.py.
| mpi_scene_gate.STEPS |
Definition at line 27 of file mpi_scene_gate.py.
| mpi_scene_gate.RHO |
Definition at line 28 of file mpi_scene_gate.py.
| mpi_scene_gate.MU |
Definition at line 28 of file mpi_scene_gate.py.
| mpi_scene_gate.F |
Definition at line 28 of file mpi_scene_gate.py.
| mpi_scene_gate.DT |
Definition at line 28 of file mpi_scene_gate.py.
| float mpi_scene_gate.RF = 0.18 |
Definition at line 29 of file mpi_scene_gate.py.
Definition at line 30 of file mpi_scene_gate.py.
| list mpi_scene_gate.CEN |
Definition at line 31 of file mpi_scene_gate.py.
| mpi_scene_gate.KN_R |
Definition at line 33 of file mpi_scene_gate.py.
| mpi_scene_gate.KI_I |
Definition at line 33 of file mpi_scene_gate.py.
| mpi_scene_gate.KI_R |
Definition at line 33 of file mpi_scene_gate.py.