Dedicated Parametric Simulation Module Development

Hello users and OpenMC devs!

I’ve made heavy use of the Python API for OpenMC 0.13.3 for running parametric simulations. They involved materials and geometry sweeps. A function built the model which was exported to an XML and then run. I found that the constant loading and unloading of XS was bottlenecking my sweep. 4 seconds for XS IO for 1.5 seconds of actual simulation. The situation was similar on an HPC cluster. I noticed that the search_for_keff feature also does this. Given that users running parametric sweeps wouldn’t expect very high fidelity and thus, the number of particles run would be low, it seems that the XS IO bottleneck would be common for parametric simulations.

I believe that OpenMC is uniquely suited to parametric runs and I’m interested in writing a dedicated parametric modelling module for it. For now, I’m still planning it but I’ve got this:

  1. Use openmc.lib in a dedicated parametric sweep function to only load XS as required like the depletion module
  2. Minimise IO for parametric sweeps, store StatePoint data in memory until the end of the sweep
  3. Refactor the search_for_keff to use the parametric module
  4. Include a class to handle the results of parametric sweeps using StatePoint and Numpy arrays
  5. Parametric depletion??
  6. Parallel model runs??

I’d love for this topic to be thoroughly discussed here and users and devs provide suggestions and inputs. Examples include the method of implementation (Sweep should take in an array OpenMC models vs Sweep should accept an array of parameters for a callable function builder) and functionality to include or exclude from the module.

1 Like

@paulromano and @gridley thank you for your support with the BC albedo implementation. I wanted to draw some attention to another thing I was working on here. What do you guys think about having a dedicated parametric module in 0.14.0?