MCPcopy Create free account
hub / github.com/DeepLabCut/DeepLabCut / _undistort_points

Function _undistort_points

deeplabcut/pose_estimation_3d/triangulation.py:472–482  ·  view source on GitHub ↗
(points, mat, coeffs, p, r)

Source from the content-addressed store, hash-verified

470
471
472def _undistort_points(points, mat, coeffs, p, r):
473 pts = points.reshape((-1, 3))
474 pts_undist = cv2.undistortPoints(
475 src=pts[:, :2].astype(np.float32),
476 cameraMatrix=mat,
477 distCoeffs=coeffs,
478 P=p,
479 R=r,
480 )
481 pts[:, :2] = pts_undist.squeeze()
482 return pts.reshape((points.shape[0], -1))
483
484
485def _undistort_views(df_view_pairs, stereo_params):

Callers 1

_undistort_viewsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected