sksurgerysurfacematch.utils.projection_utils module

Various utilities, mainly to help testing.

sksurgerysurfacematch.utils.projection_utils.reproject_and_save(image, model_to_camera, point_cloud, camera_matrix, output_file)[source]

For testing purposes, projects points onto image, and writes to file.

Parameters:
  • image – BGR image, undistorted.
  • model_to_camera – [4x4] ndarray of model-to-camera transform
  • point_cloud – [Nx3] ndarray of cloud of points to project
  • camera_matrix – [3x3] OpenCV camera_matrix (intrinsics)
  • output_file – file name