Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def _create_pinhole_pair(self, batch_size):
# prepare data
fx, fy = 1., 1.
height, width = 3, 5
cx, cy = width / 2, height / 2
tx, ty, tz = 0, 0, 0
# create pinhole cameras
pinhole_src = kornia.PinholeCamera.from_parameters(
fx, fy, cx, cy, height, width, tx, ty, tz, batch_size)
pinhole_dst = kornia.PinholeCamera.from_parameters(
fx, fy, cx, cy, height, width, tx, ty, tz, batch_size)
return pinhole_src, pinhole_dst
def _create_pinhole_pair(self, batch_size):
# prepare data
fx, fy = 1., 1.
height, width = 3, 5
cx, cy = width / 2, height / 2
tx, ty, tz = 0, 0, 0
# create pinhole cameras
pinhole_src = kornia.PinholeCamera.from_parameters(
fx, fy, cx, cy, height, width, tx, ty, tz, batch_size)
pinhole_dst = kornia.PinholeCamera.from_parameters(
fx, fy, cx, cy, height, width, tx, ty, tz, batch_size)
return pinhole_src, pinhole_dst