# Manual Calibration

When it is not feasible to perform hand-eye or cross-station calibration, manual calibration can be used to establish the relationship between Raw2D and Home2D. The Raw2DFromHome2D transform is an affine transform. In the manual calibration mode, a suitable HMI allows the user to calibrate using various techniques. The users will have the option to either 1. Enter the affine parameters directly, 2. Identify features in the field of view whose position is known in Home2D, 3. A combination of the above two. Those inputs could be translation, rotation, scale, aspect, and skew of the transform or paired points in Raw2D and Home2D depending on which method user choose.

## Manual Calibration Modes

AlignPlus supports two major modes of manual calibration.

- Non-hybrid mode

  In this mode, the calibration process computes an affine transform that can be used to map features from uncalibrated space to calibrated space. This mode cannot be used to model any lens and perspective distortion

- Hybrid mode

  In this mode, the lens and perspective distortion are removed through checkerboard calibration. The HMI allows the user to compute a 2D rigid transform and flip in handedness, that maps uncalibrated features to calibrated features.

## Affine Transform Parameters

This method allows user directly input affine transform parameters include translation, rotation, scale, aspect, and skew. Those parameters can be obtained through mechanical measurement after cameras are installed on machine.

Parameters | Description | Example
Translation | Specifies an offset of a Camera’s center relative to Home2D space |
Rotation | Specifies rotation of camera relative to Home2D space |
Scaling | Specifies the x- and y-axis units of one Raw2D relative to Home2D. This is the Pixel Size. |
Aspect | Specifies the ratio of scaling along the y-axis over scaling along the x-axis in Raw2D. When x and y axes share the same scaling, aspect is 1. |
Skew | Specifies x/y axis angle compared with original angle in Raw2D, when x and y axes are perpendicular to each other, skew is 1. |

## Paired Points

The Manual Calibration HMI also allows computation of Raw2DFromHome2D by specifying feature locations in Raw2D and Home2D. AlignPlus also provides HMIs that allow the user to specify a subset of the affine parameters and compute the rest of the parameters using point correspondence.