grimme-lab / CENSO

CENSO - Commandline ENergetic SOrting of Conformer Rotamer Ensembles
https://xtb-docs.readthedocs.io/en/latest/CENSO_docs/censo.html
GNU Lesser General Public License v3.0
22 stars 9 forks source link

CENSO fails on water molecule #17

Closed myshevchuk closed 2 years ago

myshevchuk commented 2 years ago

Hi,

first of all thank you for the great software, which brings quantum chemical calculations to the people.

I've been playing around with different configuration options to better understand the workings of the program, the structure of the generated files and so on. To save some time I decided to use the water molecule.

I'm using all the latest versions of xtb, CENSO and CRENSO, and ORCA v4.2.1 as the QM engine.

So, with the crest_combi.xyz ensemble generated by CRENSO as an input file for a CENSO run:

censo -inp crest_combi.xyz -P 1 -O 1 > output

an error message "removing CONF1 because optimization crashed" appears in the output file, despite the fact that the geometry was successfully optimized according to CONF1/part2-functional/opt-part2.out.

The error emerges on lines 679-684 of orca_job.py:

if not error_logical:
    try:
        self.job["energy"] = self.job["ecyc"][-1]
        self.job["success"] = True
    except Exception:
        error_logical = True

It appears that self.job["ecyc"] is empty and therefore an exception list index out of range is raised. self.job["ecyc"] is populated earlier by looking for a av. E: line in opt-part2.out, but this line is missing from the output.

My impression was that this happens because the ensemble file contained only one conformer (quite expectedly). So I went to reproduce it with NH3, and it happens for this molecule too. If I understand it correctly, xtb doesn't produce the av. E: ... line for some reason, although conceptually it should. If av. E. stands for averaged energy, then it should be just the energy of this conformer.

Output from opt-part2.out for H2O and NH3:

 * successful orca run, taking over control again...
========================================================================
 * total energy  :   -76.4332744 Eh     change       -0.6085779E-05 Eh
   gradient norm :     0.0007015 Eh/a0  converged?    E=T G=T D=F
   step length   :     0.0192780 a0

   *** GEOMETRY OPTIMIZATION CONVERGED AFTER 2 CYCLES ***

Output from opt-part2.out for a more complex molecule, which does not cause this error:

 * successful orca run, taking over control again...
========================================================================
av. E:  -1790.8093431 ->  -1790.8093431
av. G:      0.0047743 ->      0.0047743
 * total energy  : -1790.8093431 Eh     change       -0.5488868E-05 Eh
   gradient norm :     0.0018665 Eh/a0  converged?    E=T G=T D=F
   step length   :     0.0481497 a0

   *** GEOMETRY OPTIMIZATION CONVERGED AFTER 1 CYCLES ***

Attached in the ZIP archive are .censorc and crest_combi.xyz.

Thank you!

fabothch commented 2 years ago

Hi,

this should not have anything to do with the systems investigated, but whether xTB prints the av. E: ... line. Can you please tell me which version of xtb you are using and how you installed it?

Best,

Fabian

myshevchuk commented 2 years ago

Right, I was running xtb v6.3.3, although I was sure it was the latest v6.4.1. It probably got downgraded when I installed openmpi v3.1.4 for ORCA 4. On my production machine I solved this dependency conflict by installing openmpi into a separate conda environment but forgot to do the same here.

This does not happen with xtb v6.4.1.

Sorry for a false alarm and thank you once again!

Best, Michael