Running CONES

CONES is launched as a set of MPI processes: some run the coupled model (OpenFOAM or Meso-NH, one group of ranks per ensemble member) and the last ranks run one of the Python entry-point scripts below, which drives the Data Assimilation cycle.

For a complete, working example you can run end to end, see the cavity tutorial.

Entry points

Script

Data Assimilation method

src/main_EnKF.py

Classic Ensemble Kalman Filter (single-fidelity ensemble)

src/main_MGEnKF.py

Multi-Grid EnKF (one fine member + N coarse members)

src/main_MFEnKF.py

Multi-Fidelity EnKF (principal, control and ancillary ensembles)

All these scripts share the same command-line arguments, parsed by conesToolBox.conesMPI.argument_parser():

Argument

Default

Description

--casePath

case_orig/

Path to the reference (undecomposed) model case

--nens

-1

Number of ensemble members

--nmodelProcs

-1

Number of processors used by each model simulation

--model

OF

Coupled model: OF (OpenFOAM) or MNH (Meso-NH)

Example

The ranks are split between the ensemble members’ solver processes (grouped with :), and the CONES/Python processes, launched last:

mpirun -np 4 conesFoam -parallel -case en0 : \
       -np 4 conesFoam -parallel -case en1 : \
       -np 2 python3 src/main_EnKF.py --nens 2 --nmodelProcs 4

This is exactly the pattern the cavity tutorial’s Allrun script builds and runs for you (see CONES); reading it alongside this example is the fastest way to see how the pieces above fit together in practice.