picometer.atom

Attributes

logger

group_registry

Classes

Locator

AtomSet

Container class w/ atoms stored in pd.Dataframe & convenience methods

Module Contents

picometer.atom.logger
class picometer.atom.Locator[source]

Bases: NamedTuple

label: str
symm: str = 'x,y,z'
at: Sequence[Locator] = None
classmethod from_dict(d: dict) Locator[source]
__bool__()[source]
picometer.atom.group_registry: Dict[str, List[Locator]]
class picometer.atom.AtomSet(bf: hikari.dataframes.BaseFrame = None, table: pandas.DataFrame = None)[source]

Bases: picometer.shapes.Shape

Container class w/ atoms stored in pd.Dataframe & convenience methods

kind
base = None
table = None
__len__() int[source]
__add__(other) AtomSet[source]
__getitem__(item) AtomSet[source]
classmethod from_cif(cif_path: str, block_name: str = None) AtomSet[source]

Initialize from cif file using hikari’s BaseFrame and CifFrame

property fract_xyz: numpy.ndarray
property cart_xyz: numpy.ndarray
property fract_uij: numpy.ndarray

Return a 3D array i.e. stack of 3x3 fract. displacement tensors.

fractionalise(cart_xyz: numpy.ndarray) numpy.ndarray[source]

Multiply 3xN vector by crystallographic matrix to get fract coord

orthogonalise(fract_xyz: numpy.ndarray) numpy.ndarray[source]

Multiply 3xN vector by crystallographic matrix to get Cart. coord

locate(locators: Sequence[Locator]) AtomSet[source]

Convenience method to select multiple fragments from locators while interpreting and extending groups if necessary

select_atom(label_regex: str) AtomSet[source]
transform(symm_op_code: str) AtomSet[source]
property u_cartesian_eigenvalues
property centroid: numpy.ndarray

A 3-vector with average atom position.

property direction: picometer.shapes.Vector3
property line: picometer.shapes.Line

A 3-vector describing line that best fits the cartesian coordinates of atoms. Based on https://stackoverflow.com/q/2298390/

property plane: picometer.shapes.Plane

A 3-vector normal to plane that best fits atoms’ cartesian coords. Based on https://gist.github.com/amroamroamro/1db8d69b4b65e8bc66a6

property origin: picometer.shapes.Vector3
_angle(*others: picometer.shapes.Shape) float[source]
_distance(other: picometer.shapes.Shape) float[source]
dihedral(*others: AtomSet) float[source]