fhi_aims_step package#

Submodules#

fhi_aims_step.energy module#

Non-graphical part of the Energy step in a FHI-aims flowchart

class fhi_aims_step.energy.Energy(flowchart=None, title='Energy', extension=None, module='fhi_aims_step.energy', logger=<Logger fhi_aims_step.energy (WARNING)>)[source]#

Bases: Substep

The non-graphical part of a Energy step in a flowchart.

parser#

The parser object.

Type:

configargparse.ArgParser

options#

It contains a two item tuple containing the populated namespace and the list of remaining argument strings.

Type:

tuple

subflowchart#

A SEAMM Flowchart object that represents a subflowchart, if needed.

Type:

seamm.Flowchart

parameters#

The control parameters for Energy.

Type:

EnergyParameters

See also

TkEnergy, Energy, EnergyParameters

analyze(P=None, indent='', configuration=None, data={}, **kwargs)[source]#

Do any analysis of the output from this step.

Also print important results to the local step.out file using “printer”.

Parameters:

indent (str) – An extra indentation for the output

description_text(P=None, configuration=None)[source]#

Create the text description of what this step will do. The dictionary of control values is passed in as P so that the code can test values, etc.

Parameters:

P (dict) – An optional dictionary of the current values of the control parameters.

Returns:

A description of the current step.

Return type:

str

property git_revision#

The git version of this module.

property header#

A printable header for this section of output

plot_control(P, configuration)[source]#

Create the density and orbital plots if requested

Parameters:

data (dict()) – Dictionary of results from the calculation (results.tag file)

run(printer=<seamm_util.printing.Printer object>, lines=None)[source]#

Get the input for an energy step.

Parameters:

None

Returns:

The input for FHI-aims

Return type:

str

property version#

The semantic version of this module.

fhi_aims_step.energy_parameters module#

Control parameters for the Energy step in a SEAMM flowchart

class fhi_aims_step.energy_parameters.EnergyParameters(defaults={}, data=None)[source]#

Bases: Parameters

The control parameters for Energy.

You need to replace the “time” entry in dictionary below these comments with the definitions of parameters to control this step. The keys are parameters for the current plugin,the values are dictionaries as outlined below.

Examples

parameters = {
    "time": {
        "default": 100.0,
        "kind": "float",
        "default_units": "ps",
        "enumeration": tuple(),
        "format_string": ".1f",
        "description": "Simulation time:",
        "help_text": ("The time to simulate in the dynamics run.")
    },
}
parameters{str: {str: str}}

A dictionary containing the parameters for the current step. Each key of the dictionary is a dictionary that contains the the following keys:

parameters[“default”] :

The default value of the parameter, used to reset it.

parameters[“kind”]enum()

Specifies the kind of a variable. One of “integer”, “float”, “string”, “boolean”, or “enum”

While the “kind” of a variable might be a numeric value, it may still have enumerated custom values meaningful to the user. For instance, if the parameter is a convergence criterion for an optimizer, custom values like “normal”, “precise”, etc, might be adequate. In addition, any parameter can be set to a variable of expression, indicated by having “$” as the first character in the field. For example, $OPTIMIZER_CONV.

parameters[“default_units”]str

The default units, used for resetting the value.

parameters[“enumeration”]: tuple

A tuple of enumerated values.

parameters[“format_string”]: str

A format string for “pretty” output.

parameters[“description”]: str

A short string used as a prompt in the GUI.

parameters[“help_text”]: str

A longer string to display as help for the user.

See also

Energy, TkEnergy, Energy, EnergyStep

energy_parameters = {'NAO-J-n_level': {'default': 'NAO-J-2', 'default_units': '', 'description': 'Basis set level:', 'enumeration': ('NAO-J-2', 'NAO-J-3', 'NAO-J-4', 'NAO-J-5'), 'format_string': '', 'help_text': 'The level of NAO-j (spin-coupling) basis sets used.', 'kind': 'enumeration'}, 'NAO-VCC-nZ_level': {'default': 'NAO-VCC-2Z', 'default_units': '', 'description': 'Basis set level:', 'enumeration': ('NAO-VCC-2Z', 'NAO-VCC-3Z', 'NAO-VCC-4Z', 'NAO-VCC-5Z'), 'format_string': '', 'help_text': 'The level of NAO-VCC (valence correlation) basis sets used.', 'kind': 'enumeration'}, 'basis_version': {'default': 'defaults_2020', 'default_units': '', 'description': 'Basis set version:', 'enumeration': ('defaults_2010', 'defaults_2020', 'NAO-VCC-nZ', 'NAO-J-n', 'non-standard/gaussian_tight_770', 'non-standard/Tier2_aug2', 'custom'), 'format_string': '', 'help_text': 'The version of basis sets used.', 'kind': 'enumeration'}, 'defaults_2010_level': {'default': 'light', 'default_units': '', 'description': 'Basis set level:', 'enumeration': ('light', 'intermediate', 'tight', 'really_tight'), 'format_string': '', 'help_text': 'The level of 2010 basis sets used.', 'kind': 'enumeration'}, 'defaults_2020_level': {'default': 'light', 'default_units': '', 'description': 'Basis set level:', 'enumeration': ('light_spd/light', 'light', 'intermediate', 'tight', 'really_tight'), 'format_string': '', 'help_text': 'The level of 2010 basis sets used.', 'kind': 'enumeration'}, 'dispersion': {'default': 'nonlocal many-body dispersion (MBD-NL)', 'default_units': '', 'description': 'Long-range vdW term:', 'enumeration': ('none', 'nonlocal many-body dispersion (MBD-NL)', 'range-separated self-consistently screened (MBD@rsSCS)'), 'format_string': '', 'help_text': 'Whether and how to calculate the many-body dispersions effects.', 'kind': 'enumeration'}, 'fixed_spin_moment': {'default': 'no', 'default_units': '', 'description': 'Fix the spin moment:', 'enumeration': ('no', 'yes'), 'format_string': '', 'help_text': "Whether to fix the spin moment, by default to the configuration's multiplicity. You may also specifiy and integer multiplicity here.", 'kind': 'integer'}, 'model': {'default': 'Generalized-gradient approximations (GGA)', 'default_units': '', 'description': 'Computational model:', 'enumeration': ('Local-density approximation (LDA)', 'Generalized-gradient approximations (GGA)', 'Meta-generalized gradient approximations (meta-GGA)', 'Hartree-Fock and hybrid functionals', 'Hybrid meta generalized gradient approximation (Hybrid meta-GGA)'), 'format_string': '', 'help_text': 'The high-level computational model employed.', 'kind': 'enumeration'}, 'primitive cell': {'default': 'yes', 'default_units': '', 'description': 'If possible, use primitive cell:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to use the primitive cell for the calculation.', 'kind': 'boolean'}, 'relativity': {'default': 'atomic ZORA approximation', 'default_units': '', 'description': 'Relativity:', 'enumeration': ('none', 'atomic ZORA approximation'), 'format_string': '', 'help_text': 'Whether and how to calculate relatavistic effects.', 'kind': 'enumeration'}, 'spin_polarization': {'default': 'default', 'default_units': '', 'description': 'Spin polarized?:', 'enumeration': ('default', 'none'), 'format_string': '', 'help_text': 'Whether to do a spin polarized calculation. The default is to do so if there are spins on any atoms. You can also turn this off, but cannot force a spin-polarized calculation without setting spins on one or more atoms in the structure.', 'kind': 'enumeration'}, 'submodel': {'default': 'pbe : Perdew, Burke and Ernzerhof', 'default_units': '', 'description': 'Model version:', 'enumeration': ('pbe : Perdew, Burke and Ernzerhof', 'am05 : Armiento and Mattsson', 'blyp : Becke and Lee-Yang-Parr', 'pbeint', 'pbesol : modified PBE GGA', 'rpbe : the RPBE modified PBE functional', 'revpbe : the revPBE modified PBE GGA', 'r48pbe : 0.52*pbe and 0.48*rpbe', 'pw91_gga : Perdew-Wang 1991 GGA', 'b86bbpe : Becke’s B86b + PBE'), 'format_string': '', 'help_text': 'The version of the model employed.', 'kind': 'enumeration'}}#
kspace_parameters = {'centering': {'default': '𝚪-centered', 'default_units': '', 'description': 'Centering of grid:', 'enumeration': ('𝚪-centered', 'off-center', 'Monkhorst-Pack'), 'format_string': '', 'help_text': 'How to center the grid in reciprocal space.', 'kind': 'enumeration'}, 'k-grid method': {'default': 'grid spacing', 'default_units': '', 'description': 'Specify k-space grid using:', 'enumeration': ('grid spacing', 'explicit grid dimensions'), 'format_string': '', 'help_text': 'How to specify the k-space integration grid.', 'kind': 'string'}, 'k-spacing': {'default': 0.2, 'default_units': '1/Å', 'description': 'K-spacing:', 'enumeration': None, 'format_string': '', 'help_text': 'The spacing of the grid in reciprocal space.', 'kind': 'float'}, 'na': {'default': 4, 'default_units': '', 'description': 'NPoints in a:', 'enumeration': None, 'format_string': '', 'help_text': 'Number of points in the first direction of the Brillouin zone.', 'kind': 'integer'}, 'nb': {'default': 4, 'default_units': '', 'description': 'b:', 'enumeration': None, 'format_string': '', 'help_text': 'Number of points in the second direction of the Brillouin zone.', 'kind': 'integer'}, 'nc': {'default': 4, 'default_units': '', 'description': 'c:', 'enumeration': None, 'format_string': '', 'help_text': 'Number of points in the third direction of the Brillouin zone.', 'kind': 'integer'}, 'occupation type': {'default': 'Gaussian', 'default_units': '', 'description': 'Smearing:', 'enumeration': ('Gaussian', 'Methfessel-Paxton', 'Fermi', 'integer', 'cubic', 'cold'), 'format_string': '', 'help_text': 'How occupy the orbitals, typically smearing the electrons as they would be at finite temperature.', 'kind': 'enumeration'}, 'odd grid': {'default': 'yes', 'default_units': '', 'description': 'Force to odd numbers:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to force the grid sizes to odd numbers.', 'kind': 'boolean'}, 'smearing width': {'default': 0.01, 'default_units': 'eV', 'description': 'Width:', 'enumeration': None, 'format_string': '.3f', 'help_text': 'The smearing or broadening width.', 'kind': 'float'}}#
output_parameters = {'difference density': {'default': 'no', 'default_units': '', 'description': 'Plot difference density:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to plot the difference density.', 'kind': 'boolean'}, 'nx': {'default': 50, 'default_units': '', 'description': 'Grid:', 'enumeration': None, 'format_string': '', 'help_text': 'Number of grid points in first direction', 'kind': 'integer'}, 'ny': {'default': 50, 'default_units': '', 'description': 'x', 'enumeration': None, 'format_string': '', 'help_text': 'Number of grid points in second direction', 'kind': 'integer'}, 'nz': {'default': 50, 'default_units': '', 'description': 'x', 'enumeration': None, 'format_string': '', 'help_text': 'Number of grid points in first direction', 'kind': 'integer'}, 'orbitals': {'default': 'no', 'default_units': '', 'description': 'Plot orbitals:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to plot orbitals.', 'kind': 'boolean'}, 'region': {'default': 'default', 'default_units': '', 'description': 'Region:', 'enumeration': ('default', 'explicit'), 'format_string': '', 'help_text': 'The region for the plots', 'kind': 'string'}, 'selected k-points': {'default': 'none', 'default_units': '', 'description': 'For crystals, k-points:', 'enumeration': ('none', 'all'), 'format_string': '', 'help_text': 'Plots the orbitals at these k-points.', 'kind': 'string'}, 'selected orbitals': {'default': '-1, HOMO, LUMO, +1', 'default_units': '', 'description': 'Selected orbitals:', 'enumeration': ('all', '-1, HOMO, LUMO, +1'), 'format_string': '', 'help_text': 'Which orbitals to plot.', 'kind': 'string'}, 'total density': {'default': 'no', 'default_units': '', 'description': 'Plot total density:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to plot the total charge density.', 'kind': 'boolean'}, 'total spin density': {'default': 'no', 'default_units': '', 'description': 'Plot total spin density:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to plot the total spin density.', 'kind': 'boolean'}}#
parameters = {'calculate_gradients': {'default': 'yes', 'default_units': '', 'description': 'Calculate gradients:', 'enumeration': ('yes', 'no'), 'format_string': '', 'help_text': 'Whether to calculate the gradients in a single-point calculation.', 'kind': 'boolean'}, 'gui': {'default': 'with recommended features for energy or structure of molecules or nonmetallic solids', 'default_units': '', 'description': 'Configure GUI', 'enumeration': ('with recommended features for energy or structure involving metallic solids', 'with recommended features for energy or structure of molecules or nonmetallic solids', 'with recommended features for band structures of metallic solids', 'with recommended features for orbital energies of molecules or band structures for nonmetallic solids', 'with all standard features', 'including experimental features'), 'format_string': '', 'help_text': 'How to configure the GUI', 'kind': 'enumeration'}, 'input only': {'default': 'no', 'default_units': '', 'description': 'Write the input files and stop:', 'enumeration': ('yes', 'no'), 'format_string': 's', 'help_text': "Don't run MOPAC. Just write the input files.", 'kind': 'boolean'}, 'results': {'default': {}, 'default_units': '', 'description': 'results', 'enumeration': (), 'format_string': '', 'help_text': 'The results to save to variables or in tables.', 'kind': 'dictionary'}}#

fhi_aims_step.energy_step module#

class fhi_aims_step.energy_step.EnergyStep(flowchart=None, gui=None)[source]#

Bases: object

Helper class needed for the stevedore integration.

This must provide a description() method that returns a dict containing a description of this node, and create_node() and create_tk_node() methods for creating the graphical and non-graphical nodes.

The dictionary for the description is the class variable just below these comments. The felds are as follows:

my_description{str, str}

A human-readable description of this step. It can be several lines long, and needs to be clear to non-expert users. It contains the following keys: description, group, name.

my_description[“description”]tuple

A description of the Energy step. It must be clear to non-experts.

my_description[“group”]str

Which group in the menus to put this step. If the group does not exist it will be created. Common groups are “Building”, “Control”, “Custom”, “Data”, and “Simulations”.

my_description[“name”]str

The name of this step, to be displayed in the menus.

create_node(flowchart=None, **kwargs)[source]#

Create and return the new node object.

Parameters:
  • flowchart (seamm.Node) – A non-graphical SEAMM node

  • **kwargs (keyword arguments) – Various keyword arguments such as title, namespace or extension representing the title displayed in the flowchart, the namespace for the plugins of a subflowchart and the extension, respectively.

Return type:

Energy

create_tk_node(canvas=None, **kwargs)[source]#

Create and return the graphical Tk node object.

Parameters:
  • canvas (tk.Canvas) – The Tk Canvas widget

  • **kwargs (keyword arguments) – Various keyword arguments such as tk_flowchart, node, x, y, w, h representing a graphical flowchart object, a non-graphical node for a step, and dimensions of the graphical node.

Return type:

TkEnergy

description()[source]#

Return a description of what this step does.

Returns:

description

Return type:

dict(str, str)

my_description = {'description': 'An interface for Energy', 'group': 'Calculations', 'name': 'Energy'}#

fhi_aims_step.fhi_aims module#

Non-graphical part of the FHI-aims step in a SEAMM flowchart

class fhi_aims_step.fhi_aims.FHIaims(flowchart=None, title='FHI-aims', namespace='org.molssi.seamm.fhi_aims', extension=None, logger=<Logger fhi_aims_step.fhi_aims (WARNING)>)[source]#

Bases: Node

The non-graphical part of a FHI-aims step in a flowchart.

parser#

The parser object.

Type:

configargparse.ArgParser

options#

It contains a two item tuple containing the populated namespace and the list of remaining argument strings.

Type:

tuple

subflowchart#

A SEAMM Flowchart object that represents a subflowchart, if needed.

Type:

seamm.Flowchart

parameters#

The control parameters for FHI-aims.

Type:

FHIaimsParameters

See also

TkFHIaims, FHIaims, FHIaimsParameters

analyze(indent='', **kwargs)[source]#

Do any analysis of the output from this step.

Also print important results to the local step.out file using “printer”.

Parameters:

indent (str) – An extra indentation for the output

create_parser()[source]#

Setup the command-line / config file parser

description_text(P=None)[source]#

Create the text description of what this step will do. The dictionary of control values is passed in as P so that the code can test values, etc.

Parameters:

P (dict) – An optional dictionary of the current values of the control parameters.

Returns:

A description of the current step.

Return type:

str

property git_revision#

The git version of this module.

run()[source]#

Run a FHI-aims step.

Parameters:

None

Returns:

The next node object in the flowchart.

Return type:

seamm.Node

set_id(node_id)[source]#

Set the id for node to a given tuple

property version#

The semantic version of this module.

fhi_aims_step.fhi_aims_parameters module#

Control parameters for the FHIaims step in a SEAMM flowchart

class fhi_aims_step.fhi_aims_parameters.FHIaimsParameters(defaults={}, data=None)[source]#

Bases: Parameters

The control parameters for FHIaims.

You need to replace the “time” entry in dictionary below these comments with the definitions of parameters to control this step. The keys are parameters for the current plugin,the values are dictionaries as outlined below.

Examples

parameters = {
    "time": {
        "default": 100.0,
        "kind": "float",
        "default_units": "ps",
        "enumeration": tuple(),
        "format_string": ".1f",
        "description": "Simulation time:",
        "help_text": ("The time to simulate in the dynamics run.")
    },
}
parameters{str: {str: str}}

A dictionary containing the parameters for the current step. Each key of the dictionary is a dictionary that contains the the following keys:

parameters[“default”] :

The default value of the parameter, used to reset it.

parameters[“kind”]enum()

Specifies the kind of a variable. One of “integer”, “float”, “string”, “boolean”, or “enum”

While the “kind” of a variable might be a numeric value, it may still have enumerated custom values meaningful to the user. For instance, if the parameter is a convergence criterion for an optimizer, custom values like “normal”, “precise”, etc, might be adequate. In addition, any parameter can be set to a variable of expression, indicated by having “$” as the first character in the field. For example, $OPTIMIZER_CONV.

parameters[“default_units”]str

The default units, used for resetting the value.

parameters[“enumeration”]: tuple

A tuple of enumerated values.

parameters[“format_string”]: str

A format string for “pretty” output.

parameters[“description”]: str

A short string used as a prompt in the GUI.

parameters[“help_text”]: str

A longer string to display as help for the user.

See also

FHIaims, TkFHIaims, FHIaims, FHIaimsStep

parameters = {}#

fhi_aims_step.fhi_aims_step module#

class fhi_aims_step.fhi_aims_step.FHIaimsStep(flowchart=None, gui=None)[source]#

Bases: object

Helper class needed for the stevedore integration.

This must provide a description() method that returns a dict containing a description of this node, and create_node() and create_tk_node() methods for creating the graphical and non-graphical nodes.

The dictionary for the description is the class variable just below these comments. The felds are as follows:

my_description{str, str}

A human-readable description of this step. It can be several lines long, and needs to be clear to non-expert users. It contains the following keys: description, group, name.

my_description[“description”]tuple

A description of the FHI-aims step. It must be clear to non-experts.

my_description[“group”]str

Which group in the menus to put this step. If the group does not exist it will be created. Common groups are “Building”, “Control”, “Custom”, “Data”, and “Simulations”.

my_description[“name”]str

The name of this step, to be displayed in the menus.

create_node(flowchart=None, **kwargs)[source]#

Create and return the new node object.

Parameters:
  • flowchart (seamm.Node) – A non-graphical SEAMM node

  • **kwargs (keyword arguments) – Various keyword arguments such as title, namespace or extension representing the title displayed in the flowchart, the namespace for the plugins of a subflowchart and the extension, respectively.

Return type:

FHIaims

create_tk_node(canvas=None, **kwargs)[source]#

Create and return the graphical Tk node object.

Parameters:
  • canvas (tk.Canvas) – The Tk Canvas widget

  • **kwargs (keyword arguments) – Various keyword arguments such as tk_flowchart, node, x, y, w, h representing a graphical flowchart object, a non-graphical node for a step, and dimensions of the graphical node.

Return type:

TkFHIaims

description()[source]#

Return a description of what this step does.

Returns:

description

Return type:

dict(str, str)

my_description = {'description': 'An interface for FHI-aims', 'group': 'Simulations', 'name': 'FHI-aims'}#

fhi_aims_step.metadata module#

This file contains metadata describing the results from FHIaims

fhi_aims_step.metadata.metadata = {'computational models': {'Density Functional Theory (DFT)': {'models': {'Generalized-gradient approximations (GGA)': {'parameterizations': {'am05 : Armiento and Mattsson': {'description': 'GGA functional designed to include surface effects in self-consistent density functional theory, according to Armiento and Mattsson [9]', 'gui': 'standard'}, 'b86bbpe : Becke’s B86b + PBE': {'description': 'Becke’s B86b exchange[19] plus PBE correlation[181].', 'gui': 'molecule/energy'}, 'blyp : Becke and Lee-Yang-Parr': {'description': 'The BLYP functional: Becke (1988) exchange [20] and Lee-Yang-Parr correlation [150].', 'gui': 'standard'}, 'pbe : Perdew, Burke and Ernzerhof': {'description': 'GGA of Perdew, Burke and Ernzerhof 1997 [181].', 'gui': 'metal/energy molecule/energy'}, 'pbeint': {'description': 'PBEint functional of Ref. [67]', 'gui': 'standard'}, 'pbesol : modified PBE GGA': {'description': 'Modified PBE GGA according to Ref. [187].', 'gui': 'metal/energy'}, 'pw91_gga : Perdew-Wang 1991 GGA': {'description': "GGA according to Perdew and Wang, usually referred to as 'Perdew-Wang 1991 GGA'. This GGA is most accessibly described in Reference 26 and 27 of Ref. [182]. Note that the often mis-quoted reference [183] does not(!) describe the Perdew-Wang GGA but instead only the correlation part of the local-density approximation described above.", 'gui': 'metal/energy'}, 'r48pbe : 0.52*pbe and 0.48*rpbe': {'description': 'The mixed functional containing 0.52*pbe and 0.48*rpbe according to Ref. [173]', 'gui': 'standard'}, 'revpbe : the revPBE modified PBE GGA': {'description': 'The revPBE modified PBE GGA suggested in Ref. [247].', 'gui': 'standard'}, 'rpbe : the RPBE modified PBE functional': {'description': 'The RPBE modified PBE functional according to Ref. [93].', 'gui': 'standard'}}}, 'Hybrid functionals and Hartree-Fock': {'parameterizations': {'b3lyp': {'description': "'B3LYP' hybrid functional as allegedly implemented in the Gaussian code (i.e., using the RPA version of the Vosko-Wilk-Nusair local-density approximation, see Refs. [233, 210] for details). Note that this is therefore not exactly the same B3LYP as originally described by Becke in 1993.", 'gui': 'molecule/energy'}, 'b86bpbe-25': {'description': 'B86bPBE hybrid functional [19, 181], mixing 75 % GGA exchange with 25 % Hartree-Fock exchange.', 'gui': 'molecule/energy'}, 'b86bpbe-50': {'description': 'B86bPBE hybrid functional [19, 181], mixing 75 % GGA exchange with 50 % Hartree-Fock exchange.', 'gui': 'standard'}, 'hf : Hartree-Fock': {'description': 'Hartree-Fock exchange, only', 'gui': 'standard'}, 'hse03 : Heyd, Scuseria and Ernzerhof': {'description': 'Hybrid functional as used in Heyd, Scuseria and Ernzerhof [105, 106]. In this functional, 25 % of the exchange energy is split into a short-ranged, screened Hartree-Fock part, and a PBE GGA-like functional for the longrange part of exchange. The remaining 75 % exchange and full correlation energy are treated as in PBE. As clarified in Refs. [141, 106], two different screening parameters were used in the short-range exchange part and longrange exchange part of the original HSE functional, respectively. The ’hse03’ functional in FHI-aims reproduces these original values exactly.', 'gui': 'standard'}, 'hse06 : Heyd, Scuseria and Ernzerhof': {'description': 'Hybrid functional according to Heyd, Scuseria and Ernzerhof [105], following the naming convention suggested in Ref. [141]. In this case, the additional option value is needed, representing the single real, positive screening parameter omega as clarified in Ref. [141]. In this functional, 25 % of the exchange energy is split into a short-ranged, screened Hartree-Fock part, and a PBE GGA-like functional for the long-range part of exchange. The remaining 75 % exchange and full correlation energy are treated as in PBE.', 'gui': 'molecule/energy'}, 'lc_wpbeh': {'description': 'Range separated hybrid functional LC-!PBEh using 100 % Hartree-Fock exchange in the long-range part and omegaPBE [179] in the shortrange part. The full correlation energy is treated as in PBE.', 'gui': 'standard'}, 'pbe0': {'description': 'PBE0 hybrid functional [1], mixing 75 % GGA exchange with 25 % Hartree-Fock exchange', 'gui': 'molecule/energy'}, 'pbesol0': {'description': 'Hybrid functional in analogy to PBE0 [1], except that the PBEsol [187] GGA functionals are used, mixing 75 % GGA exchange with 25 % Hartree-Fock exchange.', 'gui': 'recommended'}}}, 'Hybrid meta generalized gradient approximation (Hybrid meta-GGA)': {'parameterizations': {'m06': {'description': "Truhlar’s optimized hybrid meta-GGA of the 'M06' suite of functionals; with 27% exact exchange. [249]", 'gui': 'recommended'}, 'm06-2x': {'description': "Truhlar’s optimized hybrid meta-GGA of the 'M06' suite of functionals, with double contribution (54%) from the hartree-fock exact exchange. [249]", 'gui': 'standard'}, 'm06-hf': {'description': "Truhlar’s optimized hybrid meta-GGA of the 'M06' suite of functionals, with 100% exact exchage contribution. [248]", 'gui': 'standard'}, 'm08-hx': {'description': "Truhlar’s optimized hybrid meta-GGA of the 'M08' suite of functionals, with 52.23% contribution from the hartree-fock exact exchange. [251]", 'gui': 'recommended'}, 'm08-so': {'description': "Truhlar’s optimized hybrid meta-GGA of the 'M08' suite of functionals, with 56.79% contribution from the hartree-fock exact exchange. [251]", 'gui': 'standard'}, 'm11': {'description': "Truhlar’s optimized range-separated local meta-GGA of the 'M11' suite of functionals [190]. The range-separation variable is also hardcoded in this implementation with omega = 0.25 bohr−1", 'gui': 'recommended'}}}, 'Local-density approximation (LDA)': {'parameterizations': {'pw-lda : Perdew-Wang': {'description': 'Homogeneous electron gas based on Ceperley and Alder [42] as parameterized by Perdew and Wang 1992 [183]. Recommended LDA parameterization.', 'gui': 'metal/energy'}, 'pz-lda : Perdew-Zunger': {'description': 'Homogeneous electron gas based on Ceperley and Alder [42], as parameterized by Perdew and Zunger 1981 [184]', 'gui': 'metal/energy'}, 'vwn : Vosko-Wilk-Nusair': {'description': 'LDA of Vosko, Wilk, and Nusair 1980 [233].', 'gui': 'metal/energy'}, 'vwn-gauss : VWN based on random phase approx.': {'description': 'LDA of Vosko, Wilk, and Nusair 1980, but based on the random phase approximation [210]. Do not use this LDA unless for one specific reason: In the B3LYP implementation of the Gaussian code, this functional is allegedly used instead of the correct VWN functional. It is therefore now present in many reference results in the literature, and also available here for comparison.', 'gui': 'standard'}}}, 'Meta-generalized gradient approximations (meta-GGA)': {'parameterizations': {'m06-l : Truhlar’s optimized meta-GGA': {'description': "Truhlar’s optimized meta-GGA of the 'M06' suite of functionals. [250]", 'gui': 'recommended'}, 'm11-l : Truhlar’s optimized range-separated local meta-GGA': {'description': "Truhlar’s optimized range-separated local meta-GGA of the 'M11' suite of functionals. [191]", 'gui': 'recommended'}, 'revtpss': {'description': ('Meta-GGA revTPSS functional of Ref. [185, 186]',), 'gui': 'standard'}, 'scan or SCAN:': {'description': "'Strongly Constrained and Appropriately Normed Semilocal Density Functional,' i.e., the SCAN meta-GGA functional by Sun, Ruzsinszky, and Perdew.[219]", 'gui': 'recommended'}, 'tpss': {'description': 'Meta-GGA TPSS functional of Ref. [223]', 'gui': 'recommended'}, 'tpssloc': {'description': 'Meta-GGA TPSSloc functional, thanks to E. Fabiano and F. Della Sala. L.A. Constantin, E. Fabiano, F.Della Sala, Ref. [51].', 'gui': 'standard'}}}}}}, 'results': {'atoms_proj_charge': {'description': 'Mulliken charges on atoms', 'dimensionality': '[n_atoms]', 'json_section': 'mulliken', 'type': <class 'float'>}, 'atoms_proj_spin': {'description': 'Mulliken spins on atoms', 'dimensionality': '[n_atoms]', 'json_section': 'mulliken', 'type': <class 'float'>}, 'change_charge_density': {'description': 'SCF final delta charge density', 'dimensionality': '[n_iterations]', 'json_section': 'scf_iteration', 'type': <class 'float'>}, 'change_forces': {'description': 'SCF final delta forces', 'dimensionality': '[n_iterations]', 'json_section': 'scf_iteration', 'type': <class 'float'>}, 'change_spin_density': {'description': 'SCF final delta spin density', 'dimensionality': '[n_iterations]', 'json_section': 'scf_iteration', 'type': <class 'float'>}, 'change_sum_eigenvalues': {'description': 'SCF final delta eigenvalue sum', 'dimensionality': '[n_iterations]', 'json_section': 'scf_iteration', 'type': <class 'float'>}, 'clock_time_total': {'description': 'Total wallclock time', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'float'>}, 'dispersion_energy': {'calculation': ['energy', 'optimization'], 'description': 'vdW energy correction', 'dimensionality': 'scalar', 're': 'Libmbd: Evaluated energy: *([-+E.0-9]+)', 'type': <class 'float'>, 'units': 'eV'}, 'energy': {'description': 'energy', 'dimensionality': 'scalar', 'type': 'float', 'units': 'eV'}, 'gradients': {'description': 'gradients', 'dimensionality': [3, 'n_atoms'], 'type': 'float', 'units': 'eV/Å'}, 'maximum_force': {'calculation': ['optimization'], 'description': 'Maximum force', 'dimensionality': 'scalar', 're': 'Maximum force component is *([-+E.0-9]+) +eV/A', 'type': <class 'float'>, 'units': 'eV/Å'}, 'model': {'description': 'The model string', 'dimensionality': 'scalar', 'type': 'string'}, 'n_basis': {'description': 'Number of basis fnctns', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'int'>}, 'n_electrons': {'description': 'Number of electrons', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'float'>}, 'n_spin': {'description': 'Number of spins', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'int'>}, 'norm_force_atoms': {'calculation': ['optimization'], 'description': 'Norm of force on atoms', 'dimensionality': 'scalar', 're': '\\|\\| Forces on atoms   \\|\\| = *([-+E.0-9]+) +eV/A', 'type': <class 'float'>, 'units': 'eV/Å'}, 'relaxation_step_number': {'calculation': ['optimization'], 'description': 'Number of geometry steps', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'int'>}, 'time_total': {'description': 'Total cpu time', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'float'>}, 'total_energy': {'calculation': ['energy', 'optimization'], 'description': 'The total energy', 'dimensionality': 'scalar', 'json_section': 'final_output', 'property': 'total energy#FHIaims#{model}', 're': 'Total energy of the DFT / Hartree-Fock s.c.f. calculation      : *([-+.0-9]+) eV', 'type': <class 'float'>, 'units': 'eV'}, 'total_energy^': {'calculation': ['energy', 'optimization'], 'description': 'SCF iteration energy', 'dimensionality': '[n_iterations]', 'json_section': 'scf_iteration', 'type': <class 'float'>, 'units': 'eV'}, 'total_number_of_loops': {'calculation': ['energy', 'optimization'], 'description': 'Number of SCF iterations', 'dimensionality': 'scalar', 'json_section': 'final_output', 'type': <class 'int'>}, 'total_spin': {'description': 'Total spin', 'dimensionality': 'scalar', 'json_section': 'mulliken', 'type': <class 'float'>}}}#

Description of the computational models for FHIaims.

Hamiltonians, approximations, and basis set or parameterizations, only if appropriate for this code. For example:

metadata["computational models"] = {
    "Hartree-Fock": {
        "models": {
            "PM7": {
                "parameterizations": {
                    "PM7": {
                        "elements": "1-60,62-83",
                        "periodic": True,
                        "reactions": True,
                        "optimization": True,
                        "code": "mopac",
                    },
                    "PM7-TS": {
                        "elements": "1-60,62-83",
                        "periodic": True,
                        "reactions": True,
                        "optimization": False,
                        "code": "mopac",
                    },
                },
            },
        },
    },
}

fhi_aims_step.optimization module#

Non-graphical part of the Optimization step in a FHI aims flowchart

class fhi_aims_step.optimization.Optimization(flowchart=None, title='Optimization', extension=None, module='fhi_aims_step.optimization', logger=<Logger fhi_aims_step.optimization (WARNING)>)[source]#

Bases: Energy

The non-graphical part of a Optimization step in a flowchart.

parser#

The parser object.

Type:

configargparse.ArgParser

options#

It contains a two item tuple containing the populated namespace and the list of remaining argument strings.

Type:

tuple

subflowchart#

A SEAMM Flowchart object that represents a subflowchart, if needed.

Type:

seamm.Flowchart

parameters#

The control parameters for Optimization.

Type:

OptimizationParameters

See also

TkOptimization, Optimization, OptimizationParameters

analyze(P=None, indent='', configuration=None, data={}, **kwargs)[source]#

Do any analysis of the output from this step.

Also print important results to the local step.out file using “printer”.

Parameters:

indent (str) – An extra indentation for the output

description_text(P=None, configuration=None)[source]#

Create the text description of what this step will do. The dictionary of control values is passed in as P so that the code can test values, etc.

Parameters:

P (dict) – An optional dictionary of the current values of the control parameters.

Returns:

A description of the current step.

Return type:

str

property git_revision#

The git version of this module.

property header#

A printable header for this section of output

run(lines=None)[source]#

Run an Optimization step.

Parameters:

None

Returns:

The next node object in the flowchart.

Return type:

seamm.Node

property version#

The semantic version of this module.

fhi_aims_step.optimization_parameters module#

Control parameters for the Optimization step in a SEAMM flowchart

class fhi_aims_step.optimization_parameters.OptimizationParameters(defaults={}, data=None)[source]#

Bases: EnergyParameters

The control parameters for Optimization.

You need to replace the “time” entry in dictionary below these comments with the definitions of parameters to control this step. The keys are parameters for the current plugin,the values are dictionaries as outlined below.

Examples

parameters = {
    "time": {
        "default": 100.0,
        "kind": "float",
        "default_units": "ps",
        "enumeration": tuple(),
        "format_string": ".1f",
        "description": "Simulation time:",
        "help_text": ("The time to simulate in the dynamics run.")
    },
}
parameters{str: {str: str}}

A dictionary containing the parameters for the current step. Each key of the dictionary is a dictionary that contains the the following keys:

parameters[“default”] :

The default value of the parameter, used to reset it.

parameters[“kind”]enum()

Specifies the kind of a variable. One of “integer”, “float”, “string”, “boolean”, or “enum”

While the “kind” of a variable might be a numeric value, it may still have enumerated custom values meaningful to the user. For instance, if the parameter is a convergence criterion for an optimizer, custom values like “normal”, “precise”, etc, might be adequate. In addition, any parameter can be set to a variable of expression, indicated by having “$” as the first character in the field. For example, $OPTIMIZER_CONV.

parameters[“default_units”]str

The default units, used for resetting the value.

parameters[“enumeration”]: tuple

A tuple of enumerated values.

parameters[“format_string”]: str

A format string for “pretty” output.

parameters[“description”]: str

A short string used as a prompt in the GUI.

parameters[“help_text”]: str

A longer string to display as help for the user.

See also

Optimization, TkOptimization, Optimization, OptimizationStep

parameters = {'force_convergence': {'default': 0.01, 'default_units': 'eV/Å', 'description': 'Force convergence:', 'enumeration': (), 'format_string': '.4f', 'help_text': 'The convergence criterion for the force in the optimization', 'kind': 'float'}, 'optimize_cell': {'default': 'yes', 'default_units': '', 'description': 'Optimize the cell (if periodic):', 'enumeration': ('yes', 'fixing the angles', 'no'), 'format_string': '', 'help_text': 'Allow the lattice vectors to change during optimization. ', 'kind': 'enumeration'}, 'pressure': {'default': 0.0, 'default_units': 'GPa', 'description': 'Pressure:', 'enumeration': (), 'format_string': '.1f', 'help_text': 'The applied pressure.', 'kind': 'float'}}#

fhi_aims_step.optimization_step module#

class fhi_aims_step.optimization_step.OptimizationStep(flowchart=None, gui=None)[source]#

Bases: object

Helper class needed for the stevedore integration.

This must provide a description() method that returns a dict containing a description of this node, and create_node() and create_tk_node() methods for creating the graphical and non-graphical nodes.

The dictionary for the description is the class variable just below these comments. The felds are as follows:

my_description{str, str}

A human-readable description of this step. It can be several lines long, and needs to be clear to non-expert users. It contains the following keys: description, group, name.

my_description[“description”]tuple

A description of the Optimization step. It must be clear to non-experts.

my_description[“group”]str

Which group in the menus to put this step. If the group does not exist it will be created. Common groups are “Building”, “Control”, “Custom”, “Data”, and “Simulations”.

my_description[“name”]str

The name of this step, to be displayed in the menus.

create_node(flowchart=None, **kwargs)[source]#

Create and return the new node object.

Parameters:
  • flowchart (seamm.Node) – A non-graphical SEAMM node

  • **kwargs (keyword arguments) – Various keyword arguments such as title, namespace or extension representing the title displayed in the flowchart, the namespace for the plugins of a subflowchart and the extension, respectively.

Return type:

Optimization

create_tk_node(canvas=None, **kwargs)[source]#

Create and return the graphical Tk node object.

Parameters:
  • canvas (tk.Canvas) – The Tk Canvas widget

  • **kwargs (keyword arguments) – Various keyword arguments such as tk_flowchart, node, x, y, w, h representing a graphical flowchart object, a non-graphical node for a step, and dimensions of the graphical node.

Return type:

TkOptimization

description()[source]#

Return a description of what this step does.

Returns:

description

Return type:

dict(str, str)

my_description = {'description': 'An interface for Optimization', 'group': 'Calculations', 'name': 'Optimization'}#

fhi_aims_step.substep module#

Base class for substeps in the FHI-aims step

class fhi_aims_step.substep.Substep(flowchart=None, title='no title', extension=None, logger=<Logger fhi_aims_step.substep (WARNING)>, module='fhi_aims_step.substep')[source]#

Bases: Node

A base class for substeps in the FHI-aims step.

property global_options#

Dictionary of global options

property input_only#

Whether to write the input only, not run MOPAC.

property is_runable#

Indicate whether this not runs or just adds input.

property is_spin_polarized#

If the calculation is set up a spin polarized.

property options#

Dictionary of options for this step

parse_data()[source]#

Get the data from the AIMS files

Parameters:

none

run_aims(files, return_files=[])[source]#

Run a FHI-aims calculation.

Parameters:
  • files ({}) – Dictionary of input and control files for FHI-aims

  • return_files ([str]) – List of files to bring backfrom the calculation

fhi_aims_step.tk_energy module#

The graphical part of a Energy step

class fhi_aims_step.tk_energy.TkEnergy(tk_flowchart=None, node=None, canvas=None, x=None, y=None, w=200, h=50, my_logger=<Logger fhi_aims_step.tk_energy (WARNING)>)[source]#

Bases: TkNode

The graphical part of a Energy step in a flowchart.

tk_flowchart#

The flowchart that we belong to.

Type:

TkFlowchart = None

node#

The corresponding node of the non-graphical flowchart

Type:

Node = None

canvas#

The Tk Canvas to draw on

Type:

tkCanvas = None

dialog#

The Pmw dialog object

Type:

Dialog

x#

The x-coordinate of the center of the picture of the node

Type:

int = None

y#

The y-coordinate of the center of the picture of the node

Type:

int = None

w#

The width in pixels of the picture of the node

Type:

int = 200

h#

The height in pixels of the picture of the node

Type:

int = 50

self[widget]#

A dictionary of tk widgets built using the information contained in Energy_parameters.py

Type:

dict

See also

Energy, TkEnergy, EnergyParameters

create_dialog(title='Energy')[source]#

Create the dialog. A set of widgets will be chosen by default based on what is specified in the Energy_parameters module.

Parameters:

None

Return type:

None

edit()[source]#

Present a dialog for editing this step’s parameters.

Subclasses can override this.

reset_dialog(widget=None)[source]#

Layout the widgets in the dialog.

The widgets are chosen by default from the information in Energy_parameter.

This function simply lays them out row by row with aligned labels. You may wish a more complicated layout that is controlled by values of some of the control parameters. If so, edit or override this method

Parameters:

widget (Tk Widget = None)

Return type:

None

reset_energy_frame(widget=None)[source]#

Layout the widgets in the dialog.

The widgets are chosen by default from the information in Energy_parameter.

This function simply lays them out row by row with aligned labels. You may wish a more complicated layout that is controlled by values of some of the control parameters. If so, edit or override this method

Parameters:

widget (Tk Widget = None)

Return type:

None

reset_kspace_frame(widget=None)[source]#

Layout the widgets in the dialog.

The widgets are chosen by default from the information in Energy_parameter.

This function simply lays them out row by row with aligned labels. You may wish a more complicated layout that is controlled by values of some of the control parameters. If so, edit or override this method

Parameters:

widget (Tk Widget = None)

Return type:

None

reset_plotting(widget=None)[source]#
right_click(event)[source]#

Handles the right click event on the node.

Parameters:

event (Tk Event)

Return type:

None

See also

TkEnergy.edit

fhi_aims_step.tk_fhi_aims module#

The graphical part of a FHI-aims step

class fhi_aims_step.tk_fhi_aims.TkFHIaims(tk_flowchart=None, node=None, namespace='org.molssi.seamm.fhi_aims.tk', canvas=None, x=None, y=None, w=200, h=50)[source]#

Bases: TkNode

The graphical part of a FHI-aims step in a flowchart.

tk_flowchart#

The flowchart that we belong to.

Type:

TkFlowchart = None

node#

The corresponding node of the non-graphical flowchart

Type:

Node = None

canvas#

The Tk Canvas to draw on

Type:

tkCanvas = None

dialog#

The Pmw dialog object

Type:

Dialog

x#

The x-coordinate of the center of the picture of the node

Type:

int = None

y#

The y-coordinate of the center of the picture of the node

Type:

int = None

w#

The width in pixels of the picture of the node

Type:

int = 200

h#

The height in pixels of the picture of the node

Type:

int = 50

self[widget]#

A dictionary of tk widgets built using the information contained in FHI-aims_parameters.py

Type:

dict

See also

FHIaims, TkFHIaims, FHIaimsParameters

create_dialog()[source]#

Create the dialog. A set of widgets will be chosen by default based on what is specified in the FHI-aims_parameters module.

Parameters:

None

Return type:

None

See also

TkFHIaims.reset_dialog

right_click(event)[source]#

Handles the right click event on the node.

Parameters:

event (Tk Event)

Return type:

None

See also

TkFHIaims.edit

fhi_aims_step.tk_optimization module#

The graphical part of a Optimization step

class fhi_aims_step.tk_optimization.TkOptimization(tk_flowchart=None, node=None, canvas=None, x=None, y=None, w=200, h=50, my_logger=<Logger fhi_aims_step.tk_optimization (WARNING)>)[source]#

Bases: TkEnergy

The graphical part of a Optimization step in a flowchart.

tk_flowchart#

The flowchart that we belong to.

Type:

TkFlowchart = None

node#

The corresponding node of the non-graphical flowchart

Type:

Node = None

canvas#

The Tk Canvas to draw on

Type:

tkCanvas = None

dialog#

The Pmw dialog object

Type:

Dialog

x#

The x-coordinate of the center of the picture of the node

Type:

int = None

y#

The y-coordinate of the center of the picture of the node

Type:

int = None

w#

The width in pixels of the picture of the node

Type:

int = 200

h#

The height in pixels of the picture of the node

Type:

int = 50

self[widget]#

A dictionary of tk widgets built using the information contained in Optimization_parameters.py

Type:

dict

See also

Optimization, TkOptimization, OptimizationParameters

create_dialog(title='Optimization')[source]#

Create the dialog. A set of widgets will be chosen by default based on what is specified in the Optimization_parameters module.

Parameters:

None

Return type:

None

reset_dialog(widget=None)[source]#

Layout the widgets in the dialog.

The widgets are chosen by default from the information in Optimization_parameter.

This function simply lays them out row by row with aligned labels. You may wish a more complicated layout that is controlled by values of some of the control parameters. If so, edit or override this method

Parameters:

widget (Tk Widget = None)

Return type:

None

reset_optimization_frame()[source]#

Layout the optimization frame according to the current values.

Module contents#

fhi_aims_step A SEAMM plug-in for FHI-aims