raw

py4vasp.raw Package

Extract the raw data from the HDF5 file and transform it into dataclasses.

In the HDF5 file, the raw data is stored with specific keys. To avoid propagating the name of these keys to the higher tier modules, we transform everything into dataclasses. This enables the introduction of new file formats by replacing the File class.

Notes

The data from the HDF5 file is lazily loaded except for scalars. This avoids memory issues when the HDF5 file contains a lot of data, because only what is needed is read. However, this has the consequence that you need to enforce the read operation before the file is closed.

Classes

DataDict(dict_, version)

Provides an extension to a dictionary storing also the version of the data.

File([filename])

Extract raw data from the HDF5 file.

RawBand(fermi_energy, kpoints, eigenvalues, ...)

Electronic band structure

RawBornEffectiveCharge(structure, charge_tensors)

The Born effective charges resulting form a linear response calculation.

RawCell(lattice_vectors[, scale])

Unit cell of the crystal or simulation cell for molecules.

RawDensity(structure, charge)

The electronic charge and magnetization density.

RawDielectricFunction(energies, ...)

The electronic or ionic dielectric function.

RawDielectricTensor(electron, ion, ...)

The dielectric tensor resulting from ionic and electronic contributions.

RawDos(fermi_energy, energies, dos[, ...])

Electronic density of states.

RawElasticModulus(clamped_ion, relaxed_ion)

The elastic module calculated in a linear response calculation.

RawEnergy(labels, values)

Various energies during ionic relaxation or MD simulation.

RawForce(structure, forces)

The forces acting on the atoms at all steps.

RawForceConstant(structure, force_constants)

The force constants of the material.

RawInternalStrain(structure, internal_strain)

The internal strain calculated in a linear response calculation.

RawKpoint(mode, number, coordinates, ...[, ...])

k points at which wave functions are calculated.

RawMagnetism(structure, moments)

Data about the magnetism in the system.

RawPiezoelectricTensor(electron, ion)

The piezoelectric tensor calculated in a linear response calculation.

RawPolarization(electron, ion)

The electronic and ionic dipole moments.

RawProjector(topology, orbital_types, ...)

Projectors used for orbital projections.

RawStress(structure, stress)

The stress acting on the unit cell at all steps.

RawStructure(topology, cell, positions)

Structural information of the system.

RawSystem(system)

The name of the system set in the input.

RawTopology(number_ion_types, ion_types)

The topology of the system used, i.e., which elements are contained.

RawVersion(major[, minor, patch])

The version number of Vasp.