pycvcam.TransformMasked._transform#
- TransformMasked._transform(points, *, dx=False, dp=False, **kwargs)[source]#
Apply the masked transformation to a set of input points.
This method simply call the original transformation’s
_transformmethod, since the parameters of the original transformation are updated to reflect the masked coefficients.- Parameters:
points (numpy.ndarray) – The input points to be transformed. Shape (n_points, input_dim).
dx (bool, optional) – If True, compute the Jacobian of the transformed points with respect to the input points. Default is False.
dp (bool, optional) – If True, compute the Jacobian of the transformed points with respect to the parameters of the transformation. Default is False.
**kwargs – Additional keyword arguments to be passed to the original transformation’s
_transformmethod.
- Returns:
A tuple containing:
transformed_points: The transformed points of shape (n_points, output_dim).jacobian_dx: The Jacobian matrix with respect to the input points of shape (n_points, output_dim, input_dim) ifdxis True, otherwise None.jacobian_dp: The Jacobian matrix with respect to the masked coefficients of the transformation of shape (n_points, output_dim, n_params) ifdpis True, otherwise None.
- Return type:
Tuple[numpy.ndarray, Optional[numpy.ndarray], Optional[numpy.ndarray]]