picometer.atom ============== .. py:module:: picometer.atom Attributes ---------- .. autoapisummary:: picometer.atom.logger picometer.atom.group_registry Classes ------- .. autoapisummary:: picometer.atom.Locator picometer.atom.AtomSet Module Contents --------------- .. py:data:: logger .. py:class:: Locator Bases: :py:obj:`NamedTuple` .. py:attribute:: label :type: str .. py:attribute:: symm :type: str :value: 'x,y,z' .. py:attribute:: at :type: Sequence[Locator] :value: None .. py:method:: from_dict(d: dict) -> Locator :classmethod: .. py:method:: __bool__() .. py:data:: group_registry :type: Dict[str, List[Locator]] .. py:class:: AtomSet(bf: hikari.dataframes.BaseFrame = None, table: pandas.DataFrame = None) Bases: :py:obj:`picometer.shapes.Shape` Container class w/ atoms stored in pd.Dataframe & convenience methods .. py:attribute:: kind .. py:attribute:: base :value: None .. py:attribute:: table :value: None .. py:method:: __len__() -> int .. py:method:: __add__(other) -> AtomSet .. py:method:: __getitem__(item) -> AtomSet .. py:method:: from_cif(cif_path: str, block_name: str = None) -> AtomSet :classmethod: Initialize from cif file using hikari's `BaseFrame` and `CifFrame` .. py:property:: fract_xyz :type: numpy.ndarray .. py:property:: cart_xyz :type: numpy.ndarray .. py:property:: fract_uij :type: numpy.ndarray Return a 3D array i.e. stack of 3x3 fract. displacement tensors. .. py:method:: fractionalise(cart_xyz: numpy.ndarray) -> numpy.ndarray Multiply 3xN vector by crystallographic matrix to get fract coord .. py:method:: orthogonalise(fract_xyz: numpy.ndarray) -> numpy.ndarray Multiply 3xN vector by crystallographic matrix to get Cart. coord .. py:method:: locate(locators: Sequence[Locator]) -> AtomSet Convenience method to select multiple fragments from locators while interpreting and extending groups if necessary .. py:method:: select_atom(label_regex: str) -> AtomSet .. py:method:: transform(symm_op_code: str) -> AtomSet .. py:property:: u_cartesian_eigenvalues .. py:property:: centroid :type: numpy.ndarray A 3-vector with average atom position. .. py:property:: direction :type: picometer.shapes.Vector3 .. py:property:: line :type: picometer.shapes.Line A 3-vector describing line that best fits the cartesian coordinates of atoms. Based on https://stackoverflow.com/q/2298390/ .. py:property:: plane :type: picometer.shapes.Plane A 3-vector normal to plane that best fits atoms' cartesian coords. Based on https://gist.github.com/amroamroamro/1db8d69b4b65e8bc66a6 .. py:property:: origin :type: picometer.shapes.Vector3 .. py:method:: _angle(*others: picometer.shapes.Shape) -> float .. py:method:: _distance(other: picometer.shapes.Shape) -> float .. py:method:: dihedral(*others: AtomSet) -> float