def get_4x4_cam_to_world_mat(self):
        """Return the camera to world transformation matrix.

        This matrix can be used to convert homogeneous points given in camera
        coordinates to homogeneous points given in world coordinates.
        """
        # M = [R^T    c]
        #     [0      1]
        homogeneous_mat = np.identity(4, dtype=float)
        homogeneous_mat[0:3, 0:3] = (
            self.get_rotation_as_rotation_mat().transpose()
        )
        homogeneous_mat[0:3, 3] = self.get_camera_center()
        return homogeneous_mat
Return the camera to world transformation matrix.

        This matrix can be used to convert homogeneous points given in camera
        coordinates to homogeneous points given in world coordinates.
        
photogrammetry_importer/types/camera.py