pycvcam.core.Intrinsic.scale#
- Intrinsic.scale(distorted_points, *, transpose=False, dx=False, dp=False, **kwargs)[source]#
Alias for the
transformmethod, which applies the intrinsic transformation to the points.See also
pycvcam.core.Transform.transform()for applying the transformation to points.
Note
The
distorted_pointsis converted to a numpy array ofdtype=numpy.float64.- Parameters:
distorted_points (ArrayLike) – The distorted points to be transformed. Shape (…, 2).
transpose (bool, optional) – If True, the input points are assumed to have shape (2, …) instead of (…, 2) and the output points will have shape (2, …). Default is False.
dx (bool, optional) – If True, the jacobian with respect to the distorted points is computed. Default is False
dp (bool, optional) – If True, the jacobian with respect to the intrinsic parameters is computed. Default is False
- Returns:
The result of the transformation, which includes the
image_pointsand the Jacobian matrices if available.- Return type:
Examples
intrinsic = ... # An instance of a subclass of Intrinsic import numpy distorted_points = numpy.array([[0.0, 0.0], [1.0, 1.0], [2.0, 2.0]]) # shape (n_points, 2) result = intrinsic.scale(distorted_points) image_points = result.image_points # shape (n_points, 2) # SAME AS: result = intrinsic.transform(distorted_points) image_points = result.transformed_points # shape (n_points, 2)