ASE vibrations example
ajjackson opened this issue · 1 comments
Hi,
from ASE version 3.22 there is a VibrationsData object that can be instantiated from Hessian data. It looks like this is very simple to use with TorchANI's analytic Hessian feature:
following the tutorial at
https://aiqm.github.io/torchani/examples/vibration_analysis.html
I can add
from ase.units import Hartree
from ase.vibrations.data import VibrationsData
vibdata = VibrationsData.from_2d(molecule, hessian[0] * Hartree)
print(vibdata.tabulate())
which returns
---------------------
# meV cm^-1
---------------------
0 0.0i 0.1i
1 0.0 0.0
2 0.0 0.0
3 0.0 0.0
4 0.0 0.0
5 0.0 0.1
6 237.2 1913.2
7 481.4 3882.4
8 484.9 3911.2
---------------------
Zero-point energy: 0.602 eV
in agreement with freq
. This object provides some other nice features, such as the .write_jmol()
and .iter_animated_mode()
methods for visualization. Of course, it also makes comparison with finite-displacement vibrations straightforward.
Would it be helpful to open a PR adding some of this to the documentation?
Thanks for sharing the information and the integration idea. We appreciate your suggestion. A PR is welcomed!