Cobaya multiple cpus per chain

Use of Healpix, camb, CLASS, cosmomc, compilers, etc.
Post Reply
Omar Darwish
Posts: 1
Joined: October 01 2019
Affiliation: damtp

Cobaya multiple cpus per chain

Post by Omar Darwish » October 02 2019


I was trying to set up my python script based on Cobaya to perform a parallel mcmc sampling for multiple chains. I would like to have several cores per chain.

As I am not sure if I did things correctly, to speed up sampling, I am posting here: (or maybe I could simply use the flag time for a simple script, but I put the command here as it can be useful for someone else if correct).

On Nersc-Cori, I use

srun -n-tasks=8 --cpus-per-task=8 python

-n-tasks will specify the number of chains
--cpus-per-task cpus per chain

Does this make sense?


Jesus Torrado
Posts: 2
Joined: April 15 2013
Affiliation: TU Munich

Re: Cobaya multiple cpus per chain

Post by Jesus Torrado » October 10 2019

Hi Omar,

Looks OK at first sight. Does it work as intended? I.e. do lines printed by Cobaya start with "[#]" where "#" is the rank of the process? (if all #=0, then MPI is not configured correctly.

Post Reply