6.5. DFTB+ Input/Output interfaces

Warning

DFTB+ must be installed separately from the pharmaforge package. The DFTB+ package is not included in the pharmaforge package and must be installed separately. You can find the installation instructions for DFTB+ on their official website: DFTB+, but the installation is relatively straightforward (mamba install dftbplus). You will also need to download the Slater-Koster files that describe the dftb3 parameters.

class pharmaforge.interfaces.dftbio.DFTBInterface(skf_loc='./', default=False, **options)[source]

Bases: AbstractIO

This class is used to interface with DFTB+ for quantum chemistry calculations, and will be used to calculate the energies and forces of the system.

self.dftb_options = {
        "Hamiltonian_SCC": "Yes",
        "Hamiltonian_SccTolerance": 1e-8,
        "Hamiltonian_MaxAngularMomentum_": "",
        "Hamiltonian_MaxAngularMomentum_H": "s",
        "Hamiltonian_MaxAngularMomentum_O": "p",
        "Hamiltonian_MaxAngularMomentum_C": "p",
        "Hamiltonian_MaxAngularMomentum_N": "p",
    }

Warning

Currently, this interface does not support parallelization because it runs by creating an input file, which is not thread safe.

Parameters:
  • skf_loc (str) – The location of the DFTB+ skf files. Default is “./”.

  • default (bool) – If True, use the default options for the DFTB+ calculator. Default is False.

  • options (dict) – A dictionary of options to pass to the DFTB+ calculator. Default is an empty dictionary.

calculator

The DFTB+ calculator object.

Type:

object

allow_parallel

Whether to allow parallelization. Default is False.

Type:

bool

level_of_theory

The level of theory used for the calculations. Default is “DFTB”.

Type:

str

options_dict

A dictionary of options for the DFTB+ calculator.

Type:

dict

See also

pharmaforge.interfaces.abstractio.AbstractIO

The abstract interface class for the Psi4Interface.

ase.calculators.dftb.DFTB

The DFTB calculator object.

Methods

ObtainDeepData(filename)

Obtain the system data from the DeepIO interface and converts each configuration to an ASE atoms object.

ObtainQueryData(queryresults)

Obtain the system data from a query

calculate([limit, verbose, num_workers])

Calculate the energies and forces of the system using the interface.

find_clusters(structure[, cutoff])

Identify clusters of atoms in a structure based on a distance cutoff.

set_environment()

Set the environment for the DFTB+ calculator.

process_structure

set_environment()[source]

Set the environment for the DFTB+ calculator.