Whatever procedure you use to get the energy from psi4.optimize will work with psi4.energy. Probably, you’re setting return_wfn=True and reading the orbital energies from the wavefunction object.
Bug seems not to be critical, and it is just a printing issue,
So, I run the code to get energy, but, I met the error below
Is it actully possible to get a wavefunction from Ar moleclue?
Sorry for my beginner question.
if len(mol.GetAtoms())>1:
psi4.optimize(level, molecule=molecule)
energy, wf = psi4.energy(level, molecule=molecule, return_wfn=True)
23968
RDKit 2D
1 0 0 0 0 0 0 0 0 0999 V2000
2.0000 0.0000 0.0000 Ar 0 0 0 0 0 15 0 0 0 0 0 0
M END
mol_input = 0 1
Ar 0.0 0.0 0.0
>>>>>
[16:55:49] UFFTYPER: Unrecognized atom type: Ar3+4 (0)
[16:55:49] SMILES Parse Error: syntax error while parsing: Ar
[16:55:49] SMILES Parse Error: Failed parsing SMILES 'Ar' for input: 'Ar'
---------------------------------------------------------------------------
ArgumentError Traceback (most recent call last)
File <timed exec>:91
ArgumentError: Python argument types in
rdkit.Chem.rdmolops.AddHs(NoneType)
did not match C++ signature:
AddHs(RDKit::ROMol mol, bool explicitOnly=False, bool addCoords=False, boost::python::api::object onlyOnAtoms=None, bool addResidueInfo=False)