pyrot.eye_modelling.common_methods ================================== .. py:module:: pyrot.eye_modelling.common_methods Attributes ---------- .. autoapisummary:: pyrot.eye_modelling.common_methods.logger Functions --------- .. autoapisummary:: pyrot.eye_modelling.common_methods.getTranslationMatrix pyrot.eye_modelling.common_methods.toRadians pyrot.eye_modelling.common_methods.toDegrees pyrot.eye_modelling.common_methods.getIdentityMatrix pyrot.eye_modelling.common_methods.getRotationMatrixX pyrot.eye_modelling.common_methods.getRotationMatrixY pyrot.eye_modelling.common_methods.getRotationMatrixZ pyrot.eye_modelling.common_methods.getEyeModelGeometry pyrot.eye_modelling.common_methods.getClipGeometries pyrot.eye_modelling.common_methods.getEyeModelToPatientRotationMatrix Module Contents --------------- .. py:data:: logger .. py:function:: getTranslationMatrix(x: float, y: float, z: float) -> numpy.ndarray Generate a translation matrix for 3D transformations. Parameters ---------- x : float Translation along the x-axis. y : float Translation along the y-axis. z : float Translation along the z-axis. Returns ------- numpy.ndarray A 4x4 translation matrix. .. py:function:: toRadians(angleDegrees: float) -> float Convert an angle from degrees to radians. Parameters ---------- angleDegrees : float Angle in degrees. Returns ------- float Angle in radians. .. py:function:: toDegrees(angleRadians: float) -> float Convert an angle from radians to degrees. Parameters ---------- angleRadians : float Angle in radians. Returns ------- float Angle in degrees. .. py:function:: getIdentityMatrix() -> numpy.ndarray Returns a 4x4 identity matrix. Returns ------- numpy.ndarray A 4x4 identity matrix. .. py:function:: getRotationMatrixX(angleDeg: float) -> numpy.ndarray Calculate the rotation matrix for a rotation around the X-axis. Parameters ---------- angleDeg : float The angle of rotation in degrees. Returns ------- numpy.ndarray A 4x4 rotation matrix representing the rotation around the X-axis. .. py:function:: getRotationMatrixY(angleDeg: float) -> numpy.ndarray Generate a rotation matrix for a rotation around the Y-axis. Parameters ---------- angleDeg : float The angle of rotation in degrees. Returns ------- numpy.ndarray A 4x4 rotation matrix representing the rotation around the Y-axis. .. py:function:: getRotationMatrixZ(angleDeg: float) -> numpy.ndarray Generate a rotation matrix for a rotation around the Z-axis. Parameters ---------- angleDeg : float The angle of rotation in degrees. Returns ------- numpy.ndarray A 4x4 rotation matrix representing the rotation around the Z-axis. .. py:function:: getEyeModelGeometry(eyeModel: object, structureType: str) -> object Retrieve the geometry for a specific structure type from the eye model. Parameters ---------- eyeModel : object The eye model containing the geometries. structureType : str The type of structure to retrieve the geometry for. Returns ------- object The geometry corresponding to the specified structure type. .. py:function:: getClipGeometries(eyeModel: object) -> list Retrieve all clip geometries from the eye model. Parameters ---------- eyeModel : object The eye model containing the clip geometries. Returns ------- list A list of clip geometries. .. py:function:: getEyeModelToPatientRotationMatrix(rotationXDeg: float, rotationYDeg: float, rotationZDeg: float) -> numpy.ndarray Calculate the rotation matrix to transform from eye model coordinates to patient coordinates. Parameters ---------- rotationXDeg : float Rotation angle around the X-axis in degrees. rotationYDeg : float Rotation angle around the Y-axis in degrees. rotationZDeg : float Rotation angle around the Z-axis in degrees. Returns ------- numpy.ndarray A 4x4 rotation matrix.