PSI4/Optking Timeout

Hi,

I’m currently working on a high-throughput method using psi4 for multiple concurrent optimisatons using mpi4py and the optking package with psi4. One issue I am occasionally running into is psi4 calculations not crashing but stopping or sometimes simply just taking too long to complete relative to others and therefore taking up resources that another calculation could use.

Essentially I’m wondering if there is a way within psi4 or optking to place a timer upon a optking.optimize_psi4("B3LYP") or a psi4.energy("B3LYP") function call and have it cancel a particular job if it reaches a set time limit?

Thank you,
Jay

There is no build-in way to time-limit a psi4 call, but I think there should be python solution arounds.
A quick search on stackexchange gave this: python - How to limit execution time of a function call? - Stack Overflow, which looks reasonable.

Thank you for the link.