duartegroup / autodE

automated reaction profile generation
https://duartegroup.github.io/autodE/
MIT License
165 stars 51 forks source link

Customization of input blocks ORCA #269

Closed BernalFA closed 1 year ago

BernalFA commented 1 year ago

Hello,

While trying to use autode features to calculate redox potentials, I encountered a SCF convergence problem for some of the radical anions of the organic molecules (while using the diffuse basis set ma-def2-TZVP). It seems, the problem may be resolved by adding some blocks to the ORCA input, but I could not find a way to do that in autode (the print_default_params function in your wrappers is fixed, and only the opt_ts "allows" the inclusion of a block string when configuring keywords). Thus, I would love to see if you can add such a customization to autode. In my case, manual addition of soscfmaxit = 12 and directresetfreq = 1 to the %scf block of the input file proved successful for sp calculations of the radical anions I am dealing with. Of course, manual editing of intermediate files is not ideal (loose automation that initially autode conferred me).

Best,

Freddy

t-young31 commented 1 year ago

Hi!

Yes there is a (yet to be documented) solution. See below for a working example

import autode as ade
kwds = ade.Config.ORCA.keywords.sp
kwds.append(
    "\n"
    "%scf\n"
    "  soscfmaxit = 12\n"
    "  directresetfreq = 1\n"
    "end"
)

m = ade.Molecule(smiles="C")
m.single_point(method=ade.methods.ORCA())

which generates:

$ head -n 6 CH4_sp_orca.inp 
! SP PBE0 RIJCOSX D3BJ def2-TZVP def2/J 
%scf
  soscfmaxit = 12
  directresetfreq = 1
end
%output
BernalFA commented 1 year ago

Thanks @t-young31 !!

I will then use it like that.

Best,

Freddy

t-young31 commented 1 year ago

Great! Please feel free to ask any other questions in a new issue 😄

t-young31 commented 1 year ago

Great! Please feel free to ask any other questions in a new issue 😄