httk.atomistic.models.structuretype¶
The structuretype family: dummy-species structuretypes and fundamental domains.
Submodules¶
- httk.atomistic.models.structuretype.anonymize
- httk.atomistic.models.structuretype.anonymized
- httk.atomistic.models.structuretype.api
- httk.atomistic.models.structuretype.backend
- httk.atomistic.models.structuretype.fundamental
- httk.atomistic.models.structuretype.fundamental_view
- httk.atomistic.models.structuretype.like
- httk.atomistic.models.structuretype.structuretype
- httk.atomistic.models.structuretype.view
- httk.atomistic.models.structuretype.view_base
Attributes¶
Classes¶
The common interface for dummy-species structures and prototypes. |
|
Backend root for the dummy-species structuretype family. |
|
Assert that a fundamental-domain template is a true asymmetric unit. |
|
Store a standard-setting fundamental domain with dummy species labels. |
|
Store a unit cell whose site identities are consecutive dummy labels. |
|
Base class for views presenting structuretype backends. |
Functions¶
|
Map element-like keys to anonymous symbols by descending amount. |
|
Return the exact dummy species used by structuretypes. |
|
Return whether |
Package Contents¶
- httk.atomistic.models.structuretype.canonical_dummy_assignment(amounts)[source]¶
Map element-like keys to anonymous symbols by descending amount.
- Parameters:
amounts (collections.abc.Sequence[tuple[str, fractions.Fraction | int]]) – The keys and represented site counts.
- Returns:
The deterministic key-to-anonymous-symbol assignment.
- Return type:
- httk.atomistic.models.structuretype.dummy_species(label)[source]¶
Return the exact dummy species used by structuretypes.
- Parameters:
label (str) – The anonymous symbol to use as the species name.
- Returns:
The canonical dummy species.
- Return type:
- httk.atomistic.models.structuretype.is_dummy_species(species)[source]¶
Return whether
specieshas precisely the sanctioned dummy-species shape.- Parameters:
species (httk.atomistic.models.species.species.Species) – The species to inspect.
- Returns:
Whether the species is a canonical dummy species.
- Return type:
- class httk.atomistic.models.structuretype.StructuretypeAPI[source]¶
Bases:
abc.ABCThe common interface for dummy-species structures and prototypes.
- property cell: httk.atomistic.models.cell.cell.Cell¶
- Abstractmethod:
Return the structure cell.
- property sites: httk.atomistic.models.sites.sites.Sites¶
- Abstractmethod:
Return the reduced sites.
- property species: tuple[httk.atomistic.models.species.species.Species, ...]¶
- Abstractmethod:
Return the distinct dummy species.
- property species_at_sites: tuple[str, ...]¶
- Abstractmethod:
Return dummy species names in site order.
- property coordinate_precision: fractions.Fraction | None¶
Return the reduced-coordinate precision, if known.
- property basis_precision: fractions.Fraction | None¶
Return the cell-basis precision, if known.
- property anonymous_formula: httk.atomistic.models.formula.formulatype_view.FormulatypeView¶
Return the canonical anonymous formula at the represented site scale.
- class httk.atomistic.models.structuretype.StructuretypeBackend(backend, **hints)[source]¶
Bases:
httk.core.Backend[StructuretypeBackend],httk.atomistic.models.structuretype.api.StructuretypeAPIBackend root for the dummy-species structuretype family.
- backend_classes: ClassVar[list[type[httk.core.Backend[Any]]]]¶
- class httk.atomistic.models.structuretype.ASUTemplate(cell, spacegroup, wyckoff_sites, species=None, coordinate_precision=None)[source]¶
Bases:
FundamentalDomainTemplateAssert that a fundamental-domain template is a true asymmetric unit.
Mirror
ASUStructure: mark aFundamentalDomainTemplatewhose Wyckoff sites are known to span a real asymmetric unit rather than merely a fundamental domain. The family exposes nosite_coordinate_spanhook, so this marker adds no state and inherits the fundamental-domain equality and representation.
- class httk.atomistic.models.structuretype.FundamentalDomainTemplate(cell, spacegroup, wyckoff_sites, species=None, coordinate_precision=None)[source]¶
Bases:
httk.atomistic.models.structuretype.backend.StructuretypeBackendStore a standard-setting fundamental domain with dummy species labels.
FundamentalDomainTemplateis the fundamental-domain member of theStructuretypefamily, the anonymous-species, exact-geometry cell used as a representative forBarePrototype.- Parameters:
cell (httk.atomistic.models.cell.like.CellLike) – The standard-setting cell geometry.
spacegroup (httk.atomistic.symmetry.spacegroup.Spacegroup | int) – The standard-setting space group.
wyckoff_sites (collections.abc.Sequence[httk.atomistic.models.structure.asu.WyckoffSite]) – The symmetry-distinct site definitions.
species (collections.abc.Sequence[httk.atomistic.models.species.like.SpeciesLike] | None) – The distinct dummy species definitions.
coordinate_precision (Any) – The precision recorded for the reduced coordinates.
- property cell: httk.atomistic.models.cell.cell.Cell¶
Return the standard-setting cell.
- property spacegroup: httk.atomistic.symmetry.spacegroup.Spacegroup¶
Return the standard-setting space group.
- property wyckoff_sites: tuple[httk.atomistic.models.structure.asu.WyckoffSite, ...]¶
Return the symmetry-distinct site definitions.
- property species: tuple[httk.atomistic.models.species.species.Species, ...]¶
Return the distinct dummy species.
- property coordinate_precision¶
Return the reduced-coordinate precision.
- property basis_precision¶
Return the cell-basis precision.
- property sites: httk.atomistic.models.sites.sites.Sites¶
Return the expanded standard-setting sites.
- property bare_prototype: httk.atomistic.models.bareprototype.bareprototype.BarePrototype¶
Return the anonymous prototype this fundamental domain folds to.
The template keeps this domain’s occupied Wyckoff letters and their dummy-species class partition; the exact geometry is discarded. The template’s constructor re-canonicalizes the class labels by the pinned group-ordering rule.
- Returns:
The folded
BarePrototype.- Return type:
httk.atomistic.models.bareprototype.bareprototype.BarePrototype
- type httk.atomistic.models.structuretype.StructuretypeLike = httk.atomistic.models.structuretype.backend.StructuretypeBackend | httk.atomistic.models.structuretype.view_base.StructuretypeViewBase | httk.atomistic.models.structuretype.structuretype.Structuretype | httk.atomistic.models.structuretype.fundamental.FundamentalDomainTemplate¶
- class httk.atomistic.models.structuretype.Structuretype(cell, sites, species=None, species_at_sites=None)[source]¶
Bases:
httk.atomistic.models.structuretype.backend.StructuretypeBackendStore a unit cell whose site identities are consecutive dummy labels.
Structuretypeis the anonymous-species, exact-geometry cell of the material-information matrix:With no geometry the anonymous/assigned pair is
Formulatype/ChemicalFormula; with Wyckoff information and optional disambiguation it isPrototype/Protostructure; and with exact geometry it isStructuretype/Structure.- Parameters:
cell (httk.atomistic.models.cell.like.CellLike) – The unit-cell geometry.
sites (httk.atomistic.models.sites.like.SitesLike) – The reduced coordinates of the sites.
species (collections.abc.Sequence[httk.atomistic.models.species.like.SpeciesLike] | None) – The distinct dummy species definitions.
species_at_sites (collections.abc.Sequence[str] | None) – The dummy species name occupying each site.
- property cell: httk.atomistic.models.cell.cell.Cell¶
Return the unit cell.
- property sites: httk.atomistic.models.sites.sites.Sites¶
Return the reduced sites.
- property species: tuple[httk.atomistic.models.species.species.Species, ...]¶
Return the distinct dummy species.
- cartesian_sites()[source]¶
Return the exact Cartesian site positions.
- Returns:
The Cartesian positions in the cell’s exact vector representation.
- Return type:
Any
- property coordinate_precision¶
Return the reduced-coordinate precision.
- property basis_precision¶
Return the cell-basis precision.
- class httk.atomistic.models.structuretype.StructuretypeViewBase[source]¶
Bases:
httk.core.View[httk.atomistic.models.structuretype.backend.StructuretypeBackend]Base class for views presenting structuretype backends.