Rosetta  2021.16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Functions
pyrosetta.toolbox.numpy_utils Namespace Reference

Functions

def rigid_transform_3D
 
def calc_dihedral
 

Function Documentation

def pyrosetta.toolbox.numpy_utils.calc_dihedral (   c)
Compute a dihedral angle from four points in space.

Args:
    c (np.ndarray): Coordinates of four points in space (atoms)

Returns:
    float: The dihedral angle

References numeric::conversions.degrees(), and measure_params.norm().

def pyrosetta.toolbox.numpy_utils.rigid_transform_3D (   A,
  B 
)
Compute the translation and rotation to optimally superpose two sets
of points using singular value decomposition.

Args:
    A (np.ndarray): A set of points
    B (np.ndarray): A set of points (must have a one-to-one correspondence
        to the points in A)

Returns:
    tuple: Rotation matrix (np.ndarray) and translation vector (np.array) to
        optimally superpose A onto B

References fmt.print().