code: def relative_camera_motion(
      R1: torch.Tensor,
      t1: torch.Tensor,
      R2: torch.Tensor,
      t2: torch.Tensor,
  ) -> Tuple[torch.Tensor, torch.Tensor]:
      r"""Compute the relative camera motion between two cameras.
  
      Given the motion parameters of two cameras, computes the motion parameters of the second
      one assuming the first one to be at the origin. If :math:`T1` and :math:`T2` are the camera motions,
      the computed relative motion is :math:`T = T_{2}T^{-1}_{1}`.
  
      Args:
          R1: The first camera rotation matrix with shape :math:`(*, 3, 3)`.
          t1: The first camera translation vector with shape :math:`(*, 3, 1)`.
          R2: The second camera rotation matrix with shape :math:`(*, 3, 3)`.
          t2: The second camera translation vector with shape :math:`(*, 3, 1)`.
  
      Returns:
          A tuple with the relative rotation matrix and
          translation vector with the shape of :math:`[(*, 3, 3), (*, 3, 1)]`.
      """
      if not (len(R1.shape) >= 2 and R1.shape[-2:] == (3, 3)):
          raise AssertionError(R1.shape)
      if not (len(t1.shape) >= 2 and t1.shape[-2:] == (3, 1)):
          raise AssertionError(t1.shape)
      if not (len(R2.shape) >= 2 and R2.shape[-2:] == (3, 3)):
          raise AssertionError(R2.shape)
      if not (len(t2.shape) >= 2 and t2.shape[-2:] == (3, 1)):
          raise AssertionError(t2.shape)
  
      # compute first the relative rotation
      R = R2 @ R1.transpose(-2, -1)
  
      # compute the relative translation vector
      t = t2 - R @ t1
  
      return R, t
  
file_path: kornia/kornia/geometry/epipolar/essential.py
imports: from typing import Optional, Tuple
  import torch
  import kornia.geometry.epipolar
  from kornia.core import eye, ones_like, stack, where, zeros
  from kornia.core.check import KORNIA_CHECK, KORNIA_CHECK_SAME_SHAPE, KORNIA_CHECK_SHAPE
  from kornia.geometry import solvers
  from kornia.utils import eye_like, vec_like
  from kornia.utils.helpers import _torch_svd_cast
  from .numeric import cross_product_matrix
  from .projection import depth_from_point, projection_from_KRt
  from .triangulation import triangulate_points
label_desc: Use image node_id 7 for calling a global function with example usage: relative_camera_motion(R1, t1, R2, t2) and returns: R,  t