Skip to content
ppqmPublic

About

Enable cheminformatics and quantum chemistry

Resources

Stars

82 stars

Watchers

5 watching

Forks

Repository files navigation

Psi Phi Quantum Mechanics (ppqm)

Simple bridge between RDKit and quantum chemistry (QC) packages.

Installation

pip install ppqm

Example

All examples assume an RDKit molecule object with hydrogens and a 3D conformer:

from rdkit import Chem
from rdkit.Chem import AllChem

molecule = Chem.MolFromSmiles("O")
molecule = Chem.AddHs(molecule)
AllChem.EmbedMolecule(molecule)
AllChem.UFFOptimizeMolecule(molecule)

Create a calculator instance. Here using xTB with 4 cores:

from ppqm import XtbCalculator

xtb = XtbCalculator(cmd="xtb", cores=4)

Calculation options are plain dicts, translated into the right input format. To run a GFN2 optimization in water:

optimize_options = {
    "gfn": 2,
    "alpb": "h2o",
    "opt": None,
}

results = xtb.calculate(molecule, optimize_options)

for i, properties in enumerate(results):
    print(f"Conformer {i} properties: {properties}")

More examples in the notebooks/ directory.

Supported calculators

  • GAMESS
  • Gaussian
  • MNDO
  • MOPAC
  • Orca
  • xTB

Related projects

The interface might be too niche, but there are other cool molecular interfaces to explore;

Future Work

  • Would really love to seperate the parsers out and use cclib instead.

Contributing

Fork, branch, and use pre-commit.

License

MIT — see LICENSE.

About

Enable cheminformatics and quantum chemistry

Resources

Stars

82 stars

Watchers

5 watching

Forks

Releases

Packages

Used by

Contributors

Languages