I’m running a test RHF/STO-3G calculation on a H24C48S2 molecule, against a Conda-based Psi4 installation. (I’m using the openfermionpsi4 interface, but the question is kind of in between Psi4 and the interface) The calculation is proceeding fine, but I notice I’m only getting a single thread in spite of asking for 4.
Would this approach lead to observable CPU utilization around 400% via, e.g., htop? I’ve looked at the run_psi4 interface and it doesn’t have a thread count argument, but I’m hoping I can avoid customizing it to pass a thread count argument if there’s a trick. Thanks in advance.
I can’t give a definitive answer without looking into the guts of OpenFermion, but I’d expect that supplying set_num_threads should parallelize.
Are you trying that and not seeing parallelization, or are you asking before you’ve even tried? If you need additional support on this, please state your OS.
I should also state as a disclaimer: I don’t understand why you would study a system with this many orbitals if your interests are in quantum computing, and I don’t understand why you would use OpenFermion if your interests aren’t in quantum computing. If you are sure you know what you’re doing, carry on.
In this case you need to get set_num_threads(4) in the input file openfermion writes, or modify the system call with adding -n <nthreads> (maybe an alias like alias psi4=psi4 -n 4 would already work)
From the code the run_psi4 function will accept some sort of template file, maybe check out as well.
Hi Jonathon, thanks. I did actually try it, but before getting too much deeper wanted to make sure there wasn’t a well-known trick. I’ve wanted to use Psi4 for awhile, but this is the first time I had good reason to start.
Re: quantum computing, it will be an active space calculation. We’re just exploring bounds of NISQ for now, and the phenomenon we’re interested in is primarily contained in a smallish active space around the frontier orbitals. Still working out whether and how the QC frameworks represent the aufbau core of systems; if they don’t, then we have our next proposal. If they do, then we’ll see how far we can push the active space.