httk.atomistic.integrations.vasp.structure

Lazy VASP POSCAR structures backed by neutral httk payloads.

Classes

VASPStructure

Load a VASP POSCAR structure lazily.

Module Contents

class httk.atomistic.integrations.vasp.structure.VASPStructure(obj, **hints)[source]

Bases: httk.atomistic.models.structure.backend.StructureBackend

Load a VASP POSCAR structure lazily.

This backend is explicitly constructed because a generic structure source should not silently claim every POSCAR path.

It is not registered in backend_classes. Constructing it from a view whose unwrapped value is already a VASPStructure returns that backend by identity. The payload’s raw channel preserves the source representation for byte-exact saving.

Parameters:
  • obj (Any) – A POSCAR path, neutral payload, or serializer-supported source.

  • **hints (Any) – Backend-selection hints.

kind: ClassVar[str] = 'vasp'[source]
property payload: collections.abc.Mapping[str, Any][source]

Return the original, loaded, or synthesized neutral POSCAR payload.

property comment: Any[source]

Return the POSCAR comment, if present.

property selective_dynamics: Any[source]

Return selective-dynamics flags, if present.

resolve()[source]

Build and memoize the canonical structure from the POSCAR payload.

Returns:

The resolved unit-cell structure.

Return type:

httk.atomistic.models.structure.unitcell.UnitcellStructure

property cell: httk.atomistic.models.cell.cell.Cell[source]

Return the resolved cell.

property sites: httk.atomistic.models.sites.sites.Sites[source]

Return the resolved reduced coordinates.

property species: tuple[httk.atomistic.models.species.species.Species, Ellipsis][source]

Return the resolved distinct species.

property species_at_sites: tuple[str, Ellipsis][source]

Return the resolved species name at each site.

property site_moments: httk.atomistic.models.moments.backend.SiteMomentsBackend | None[source]

Return resolved site moments, or None.

property charge: Any[source]

Return the resolved structure charge, if present.

unwrap()[source]

Return the original POSCAR source.