aiida_vasp.assistant.parameters#
Parameter related utils
Contains utils and definitions that are used together with the parameters.
Module Contents#
Classes#
Encode values for the initial charge density. |
|
Encode values for the smearing used during integration in reciprocal space. |
|
Encode values for the projector information. |
|
Encode values for algorithm descriptively. |
|
Encode values for degrees of freedom mode of relaxation descriptively. |
|
A class that contains all relevant massaging of the input parameters for VASP. |
|
Container for the set functions that converts an AiiDA parameters to a default override specific one. |
Functions#
Check that the inputs are of some correct type and returned as AttributeDict. |
|
Goes trough the inputs namespaces and the namespaces in the inputs.parameters and merge them. |
Data#
API#
- aiida_vasp.assistant.parameters._BASE_NAMESPACES: list[str] = ['electronic', 'smearing', 'charge', 'dynamics', 'bands', 'relax', 'converge']#
- class aiida_vasp.assistant.parameters.ChargeEnum[source]#
Bases:
enum.IntEnumEncode values for the initial charge density.
See: https://www.vasp.at/wiki/index.php/ICHARG
Initialization
Initialize self. See help(type(self)) for accurate signature.
- WAVE = 0#
- CHARGE = 1#
- ATOMIC = 2#
- POTENTIAL = 4#
- CONSTANT_CHARGE = 11#
- CONSTANT_ATOMIC = 12#
- class aiida_vasp.assistant.parameters.IntSmearingEnum[source]#
Bases:
enum.IntEnumEncode values for the smearing used during integration in reciprocal space.
See: https://www.vasp.at/wiki/index.php/ISMEAR.
Initialization
Initialize self. See help(type(self)) for accurate signature.
- MP = 1#
- GAUSSIAN = 0#
- FERMI = None#
- PARTIAL = None#
- TETRA = None#
- class aiida_vasp.assistant.parameters.OrbitEnum[source]#
Bases:
enum.IntEnumEncode values for the projector information.
See: https://www.vasp.at/wiki/index.php/LORBIT
Initialization
Initialize self. See help(type(self)) for accurate signature.
- ATOM = 0#
- ATOM_LM = 1#
- ATOM_LM_PHASE = 2#
- NO_RWIGS_ATOM = 10#
- NO_RWIGS_ATOM_LM = 11#
- NO_RWIGS_ATOM_LM_PHASE = 12#
- NO_RWIGS_ATOM_LM_PHASE_AUTO = 14#
- ATOM_LM_WAVE = 5#
- classmethod get_lorbit_from_combination(**kwargs) aiida_vasp.assistant.parameters.OrbitEnum[source]#
Get the correct mode of the projectors/decomposition.
- class aiida_vasp.assistant.parameters.RelaxAlgoEnum[source]#
Bases:
enum.IntEnumEncode values for algorithm descriptively.
See: https://www.vasp.at/wiki/index.php/IBRION
Initialization
Initialize self. See help(type(self)) for accurate signature.
- NO_UPDATE = None#
- IONIC_RELAXATION_RMM_DIIS = 1#
- IONIC_RELAXATION_CG = 2#
- class aiida_vasp.assistant.parameters.RelaxModeEnum[source]#
Bases:
enum.IntEnumEncode values for degrees of freedom mode of relaxation descriptively.
See: https://cms.mpi.univie.ac.at/wiki/index.php/ISIF
Initialization
Initialize self. See help(type(self)) for accurate signature.
- POS_ONLY = 2#
- POS_SHAPE_VOL = 3#
- POS_SHAPE = 4#
- SHAPE_ONLY = 5#
- SHAPE_VOL = 6#
- VOL_ONLY = 7#
- classmethod get_isif_from_dof(**kwargs) aiida_vasp.assistant.parameters.RelaxModeEnum[source]#
Get the correct mode of relaxation for the given degrees of freedom.
- class aiida_vasp.assistant.parameters.ParametersMassage(parameters: Any, unsupported_parameters: Any = None, settings: Any = None, skip_parameters_validation: bool = False)[source]#
A class that contains all relevant massaging of the input parameters for VASP.
The idea is that this class accepts the set input parameters from AiiDA (non code specifics), checks if any code specific parameters supplied are valid VASP input parameters (only rudimentary at this point, should also cross check and check types) and convert the AiiDA input parameters to VASP specific parameters. A set function needs to be developed for each VASP INCAR parameter that we want to set based on supplied AiiDA/AiiDA-VASP specific parameters. These set functions takes these parameters and converts it to VASP INCAR compatible tags. The parameter property should return ready to go parameters containing the default override namespace, the namespaces set in the _set_extra_parameters function and any additional namespaces that might have been set using the additional_override_namespaces setting entry in settings that can be supplied to the VaspWorkChain.
The default override namespace (see _DEFAULT_OVERRIDE_NAMESPACE) should always be present when using this VASP plugin. If using additional plugins, one can for instance supply additional namespace override that can be used, depending on what is needed in those plugins and how you construct your workchains.
Initialization
- _check_valid_namespaces() None[source]#
Check that we do not have namespaces on the input parameters that is unsupported.
- _load_valid_params() None[source]#
Import a list of valid parameters for VASP. This is generated from the manual.
- _fetch_additional_override_namespaces() list[str][source]#
Check the settings for any additional supplied override namespace and return it.
- _set_vasp_parameters() None[source]#
Iterate over the valid parameters and call the set function associated with that parameter.
- _set_extra_vasp_parameters() None[source]#
Find if there are any extra parameters that are not part of the INCAR that needs to be set.
One example is the dynamic namespace which handles for instance flags for selective dynamics. These flags are more connected to a calculation than a StructureData and thus it was necessary to make sure it was valid input to the VASP workchain.
- _set_additional_override_parameters() None[source]#
Set any customized parameter namespace, including its content on the massaged container.
- _valid_vasp_parameter(key: str) bool[source]#
Make sure a key are recognized as a valid VASP input parameter.
- _validate_vasp_parameters() None[source]#
Make sure all the massaged values are recognized as valid VASP input parameters.
- property parameters: aiida.common.extendeddicts.AttributeDict#
Return the massaged parameter set ready to go in VASP format.
- class aiida_vasp.assistant.parameters.ParameterSetFunctions(parameters: aiida.common.extendeddicts.AttributeDict, incar: aiida.common.extendeddicts.AttributeDict)[source]#
Container for the set functions that converts an AiiDA parameters to a default override specific one.
Initialization
- set_ismear() None[source]#
Make sure we do not supply invalid integration methods when running explicit k-point grids.
- aiida_vasp.assistant.parameters.check_inputs(supplied_inputs: None | aiida.common.extendeddicts.AttributeDict | aiida.orm.Dict | dict) aiida.common.extendeddicts.AttributeDict[source]#
Check that the inputs are of some correct type and returned as AttributeDict.
- aiida_vasp.assistant.parameters.inherit_and_merge_parameters(inputs: dict[str, Any]) aiida.common.extendeddicts.AttributeDict[source]#
Goes trough the inputs namespaces and the namespaces in the inputs.parameters and merge them.
Note that parameters specified in the inputs.parameters will override what is supplied as workchain input, in case there is overlap.