httk.atomistic.models.structure.unitcell_view

A view presenting any structure backend as a UnitcellStructure (the Unitcell representation).

Classes

UnitcellStructureView

A view presenting an underlying structure backend as a UnitcellStructure.

Module Contents

class httk.atomistic.models.structure.unitcell_view.UnitcellStructureView(obj, **hints)[source]

Bases: httk.atomistic.models.structure.view.StructureView, httk.atomistic.models.structure.unitcell.UnitcellStructure

A view presenting an underlying structure backend as a UnitcellStructure.

This view is a genuine UnitcellStructure, so it can be passed anywhere a UnitcellStructure is accepted. Each component is normalized lazily on first access. For an ASU-backed view, accessing cell or species never triggers expansion.

An ASU backend is expanded when unit-cell sites, species-at-sites, moments, or assemblies are requested. Assembly correlations that cannot be mapped from the fundamental domain to the full cell raise an error.

Parameters:
Raises:

httk.core.optimade.entries.IncompleteOptimadeResourceError – If the source declares a coordinate span that cannot be projected as a native unit cell.

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

Expose the site’s magnetic moments.

property charge: fractions.Fraction | None[source]

Expose the explicitly assigned charge.

unwrap()[source]

Return the raw value wrapped by the backend.

Returns:

The original source value.

Return type:

Any

unview()[source]

Materialize this presentation as a standalone unit-cell structure.

Returns:

The exact unit-cell structure represented by this view.

Return type:

httk.atomistic.models.structure.unitcell.UnitcellStructure

property immutable_id: str | None[source]

Expose the immutable source identifier.

property last_modified: Any[source]

Expose the source modification timestamp.

property molecular: bool[source]

Expose whether the presented structure is molecular.

property site_coordinate_span: str[source]

Expose the unit-cell coordinate span.

property symmetry: Any[source]

Expose the optional symmetry metadata.

property assemblies: tuple[httk.atomistic.composition.Assembly, Ellipsis] | None[source]

Expose site correlations in the presented unit cell.

property chemical_composition: Any[source]

Expose the optional chemical composition metadata.

property chemical_formula_descriptive: str | None[source]

Expose the optional descriptive chemical formula.

property chemical_formula_hill: str | None[source]

Expose the optional Hill chemical formula.

property optimization_type: str | None[source]

Expose the optional optimization provenance.

property site_coordinate_span_description: str | None[source]

Expose the optional coordinate-span description.

property space_group_it_number: int | None[source]

Expose the optional space-group number.

property space_group_symbol_hall: str | None[source]

Expose the optional Hall symbol.

property space_group_symbol_hermann_mauguin: str | None[source]

Expose the optional Hermann–Mauguin symbol.

property space_group_symbol_hermann_mauguin_extended: str | None[source]

Expose the optional extended Hermann–Mauguin symbol.

property space_group_symmetry_operations_xyz: tuple[str, Ellipsis] | None[source]

Expose the optional symmetry operations in xyz notation.

property wyckoff_positions: tuple[str, Ellipsis] | None[source]

Expose the optional Wyckoff positions.