Typedef for an STL vector of Eigen vector objects. Use a specialized allocator in the case that types divisible by 16 bytes are used, specifically Eigen::Vector2d.
template<Eigen::Index DIM>
using
industrial_calibration::TargetFeatures = std::map< unsigned, VectorEigenVector< DIM > >
Typedef for a container of target features from a calibration target. This definition allows for multiple features to be associated with a single unique identifier (such as the corners of an ArUco tag)
A set of data representing a single observation of a calibration target. This consists of the feature correspondences as well as the transforms to the "mount" frames of the camera and target. For a moving camera or target, the "mount" pose would likely be the transform from the robot base to the robot tool flange. For a stationary camera or target, this "mount" pose would simply be identity. More...
A set of data representing a single measurement of the state of a system where a kinematic device holding a "camera" directly observes the position and orientation of a target mounted on a separate kinematic device. More...
Functions
template<typename T >
void
industrial_calibration::projectPoint (const CameraIntrinsics &intr, const T point[3], T xy_image[2])
Projects a 3D point (relative to the camera frame) into image coordinates.
There is a 3x3 homography matrix, H, that can transform a point from one plane onto a different plane
In our case we have 2 sets of known corresponding planar points: points on the planar target, and points in the image plane. Therefore, there is some matrix, H, which can transform target points into the image plane. If the target points and camera points actually match, we should be able to:
Calculate H for a subset of corresponding points
Transform the remaining target points by H to obtain estimates of their locations in the image plane
Compare the calculated estimations to the actual image points to make sure they are very close. If they are not close, we know that the correspondences are not valid
The matrix H has 8 unique values. These 8 values of the homography matrix can be solved for, given a set of (at least) 8 corresponding planar vectors, by rearranging the above equations:
, where
A is matrix (size 2*n x 8), where n is the number of corresponding vectors
H is a vector (size 8 x 1) of the unknown elements of the homography matrix
B is a vector (size 2*n x 1) representing the elements of one set of planar vectors
Note
At least 4 correspondences are required (2 equations per correspondence x 4 correspondences = 8 unknowns)