abics.applications.latgas_abinitio_interface.vasp module

To deal with VASP

class abics.applications.latgas_abinitio_interface.vasp.VASPSolver(path_to_solver)[source]

Bases: abics.applications.latgas_abinitio_interface.base_solver.SolverBase

VASP solver

path_to_solver

Path to the solver

Type

str

input

Input manager

Type

VASPSolver.Input

output

Output manager

Type

VASPSolver.Output

Initialize the solver.

Parameters

path_to_solver (str) – Path to the solver.

class Input[source]

Bases: object

Input manager for VASP

base_info

Common parameters

Type

dict

pos_info

Atom positions

Type

pymatgen.Structure

cl_args(nprocs, nthreads, workdir)[source]

Generate command line argument of the solver program.

Parameters
  • nprocs (int) – The number of processes.

  • nthreads (int) – The number of threads.

  • workdir (str) – Path to the working directory.

Returns

args – Arguments of command

Return type

list[str]

from_directory(base_input_dir)[source]
Parameters

base_input_dir (str) – Path to the directory including base input files.

Returns

base_vasp_input – vasp input object

Return type

VaspInput (defined in pymatgen)

update_info_by_structure(structure)[source]

Update information by structure file

Parameters

structure (pymatgen.Structure) – Atomic structure

update_info_from_files(workdir, rerun)[source]

Update information from output files.

Parameters
  • workdir (str) – Path to working directory.

  • rerun (int) – Mode for rerunning (0: not rerun, 1: rerun (base file is replaced by new one))

write_input(output_dir)[source]

Generate input files of the solver program.

Parameters

workdir (str) – Path to working directory.

class Output[source]

Bases: object

Output manager.

get_results(workdir)[source]

Get energy and structure obtained by the solver program.

Parameters

workdir (str) – Path to the working directory.

Returns

phys – Total energy and atomic structure. The energy is measured in the units of eV and coodinates is measured in the units of Angstrom.

Return type

named_tuple(“energy”, “structure”)

__init__(path_to_solver)[source]

Initialize the solver.

Parameters

path_to_solver (str) – Path to the solver.

name()[source]
Returns

name – Name of solver.

Return type

str

solver_run_schemes()[source]
Returns

schemes – Implemented runner schemes.

Return type

tuple[str]