httk.atomistic.species_primitive_view¶
A view presenting any species backend as an OPTIMADE species dict.
Classes¶
A view presenting an underlying species backend as an OPTIMADE species dict. |
Module Contents¶
- class httk.atomistic.species_primitive_view.SpeciesPrimitiveView(obj: httk.atomistic.species_like.SpeciesLike, **hints: Any)[source]¶
Bases:
httk.atomistic.species_view.SpeciesView,dictA view presenting an underlying species backend as an OPTIMADE species dict.
This view is a genuine
dictcarrying the OPTIMADEspeciesfields (optional fields that areNoneare omitted; list-valued fields are plain lists). Unlike the immutable-subclass views, a dict is mutable, so this view is a detached copy: mutating it does not affect the underlying backend.- unwrap() Any[source]¶
Return the most raw representation possible of this view, i.e., if it uses a backend with an internal representaion - or if it can (possibly lossly) convert itself into a more raw representation that still would be recognized as a <Something>Like type, that representation will be returned. If this is not possible, the instance itself is returned.