httk.atomistic.cell_numeric_view¶
A view presenting any cell backend as a NumericCell (the plain-numpy presentation).
Classes¶
A view presenting an underlying cell backend as a |
Module Contents¶
- class httk.atomistic.cell_numeric_view.CellNumericView(obj: httk.atomistic.cell_like.CellLike, **hints: Any)[source]¶
Bases:
httk.atomistic.cell_view.CellView,httk.atomistic.numeric_cell.NumericCellA view presenting an underlying cell backend as a
NumericCell.This view is a genuine
NumericCell, so it can be passed anywhere one is accepted. Its exactCellis built eagerly from the backend on construction, preserving the scale/unscaled split. Like aNumericCellit requires numpy (raisingImportErrorotherwise).- 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.