Performance and Parallelization
The runtime is dominated by repeated trapezoidal integrations over multipole and radial grids. Production settings should be chosen deliberately and recorded with the run outputs.
Integration Controls
ellminandellmaxBound the multipole integration. Increasing
ellmaxincreases the number of integration samples.pppPoints per Bessel period. Larger values sample oscillatory Bessel factors more densely and increase runtime. Use convergence tests before adopting a production value.
rand angular scalesThe
F-type integrals derive their step size from the largest relevant angular scale. Very small angular scales can increase the number of samples required over a fixedellrange.Nr,rmin, andrmaxControl the final radial integral. Larger
Nrvalues improve radial sampling but multiply the number of calls to the expensive inner multipole integrations.
OpenMP
OpenMP is controlled at compile time:
make clean
make PYTHON=python3 OPENMPMACHINE=1 all
At runtime:
export OMP_NUM_THREADS=8
./wlcov numberThreads=8 clsfile=tests/input/Cls_ep2.txt \
ellmax=2000 ppp=20 Nr=50
When OpenMP is disabled, numberThreads is accepted but has no effect.
Embarrassingly Parallel Workflows
Covariance-matrix workflows often require many independent wlcov calls.
Even without OpenMP, these calls can be distributed over a job scheduler or a
Python process pool. Keep each task self-contained:
write outputs to unique directories;
log the exact command and parameter values;
avoid sharing temporary files such as
Cls_temp.txtbetween concurrent jobs unless the filename is made unique per process.
Convergence Checks
For a production analysis, run a small convergence grid:
hold geometry fixed and vary
ppp;hold
pppfixed and varyNr;hold
pppfixed and varyellmax;compare final
integral=...values against an acceptance tolerance;record the selected settings in the analysis notes or paper repository.
The compact examples in this documentation use small ellmax and ppp
values so they run quickly; they are smoke tests, not science settings.