Depletion acceleration and run depletion with slurm

Hi all,

I am running a pincell calculation to understand radial flux variation along with depletion. Thus, I prepared a case dividing a 2D PWR pincell into 10 depletion zone. To obtain more accurate results, I use the whole endf71 decay and fission yield library to generate the chain.xml file. However, although with 10,000 particles per batch, the simulation is pretty slow on a small cluster with 56 omps (I haven’t test if it could be faster if I ruduces the omp nums). I would like to know is there a way to accelerate the simulation?

One more thing, I plan to run the silulation on a better cluster using slurm, I am confusing when run a depletion calculation with slurm, how could I specific the .sh file so that number of omps is controlled? Is there any example bash file that I can refer to?

Thank you very much for your help!

Regards,
Tian

Below is an example of slurm script I used on our computer cluster. The “dep.py” python script specified below can be the sample pin cell depletion input. Just note that mpi4py is required in this case.


#!/bin/sh -l

#SBATCH --job-name=openmc_dep
#SBATCH --export=ALL
#SBATCH --account=xxx
#SBATCH --partition=standard
#SBATCH --mail-user=xxx@xxx
#SBATCH --mail-type=BEGIN,END,FAIL

#SBATCH --nodes=5
#SBATCH --ntasks-per-node=1
#SBATCH --cpus-per-task=36

#SBATCH --mem=30000m
#SBATCH --time=10:00:00
#SBATCH --output=%x-%j.out
#SBATCH --error=%x-%j.err

export OMP_NUM_THREADS=36

mpirun -n 5 python -m mpi4py dep.py

This is my script,

#!/bin/bash
#SBATCH --job-name=PythonTest
#SBATCH --ntasks=2
#SBATCH --nodes=2
#SBATCH --ntasks-per-node=1
#SBATCH --cpus-per-task=64
#SBATCH --output=%j.log
#SBATCH --partition=xxx
export OMP_NUM_THREADS=64
srun --mpi=pmix_v3 -n 2 python -m mpi4py run_depletion.py

then I got the errors

Writing summary.h5 file…
Reading plot XML file…
Writing summary.h5 file…
ERROR: Failed to open HDF5 file with mode ‘w’: summary.h5

how to solve this problem

You may need to build HDF5 with support for parallel I/O in order to get it working properly for depletion simulations run in parallel. See details here.

Excuse me , can I ask you how to distinguish depletion zone ,I didn’t find tutorial in the documents.
Thanks
xmTang

Briefly, each depletion zone has a assigned material, you can identify the zone according to the material name

I get it ! Thank you so much, Zhang !