CV Stereo Calibrate (Circle Grid)
Estimates the relative pose (R, T) between two cameras - and both sets of intrinsics unless they are pinned - from matched asymmetric circle-grid views (cv2.stereoCalibrate). Feed an IMAGE BATCH of stereo pairs (left and right views of the SAME board poses, same order); each pair is circle-grid detected independently and skipped unless BOTH views find the full grid. The 'asymmetric (staggered)' layout is the default and the point of this node: a symmetric grid looks identical when rotated 180 degrees, so a tilted board seen by two cameras cannot be matched unambiguously - the staggered rows break that ambiguity, which is why asymmetric circle grids are the standard target for stereo rigs. Pre-calibrate each camera with 'Calibrate Camera (Circle Grid)' and feed BOTH K matrices here to PIN the intrinsics (CALIB_FIX_INTRINSIC - only R and T are then estimated, which is the recommended two-stage workflow); with one or neither K connected the intrinsics are estimated/refined here and any K you did pass is only an initial guess. Failure-tolerant: with fewer than 3 usable pairs returns found=false with identity R and zero T. Feed R, T, K, dist into 'cv2.stereoRectify' for rectification.
- images_left
- images_right
- K_left
- dist_left
- K_right
- dist_right
- K_left
- dist_left
- K_right
- dist_right
- R
- T
- rms_error
- found
Inputs (10)
| Name | Type | Default | Description |
|---|---|---|---|
| images_left | IMAGE | Batch of LEFT circle-grid views (>= 3 usable pairs; ~10-20 gives a good fit). Same order as images_right. | |
| images_right | IMAGE | Batch of RIGHT circle-grid views, same order/length as images_left. | |
| pattern_cols | INT | 42–40 | Circle centers per row (width of the grid). |
| pattern_rows | INT | 112–40 | Circle centers per column (height of the grid). |
| grid_layout | COMBO | asymmetric (staggered) | Grid geometry. Asymmetric staggers each row by half a spacing, which removes the 180-degree rotational ambiguity of symmetric targets - essential for matching a tilted board across two views. |
| square_sizeopt | FLOAT | 1.000.0001–1000000 | Physical center-to-center spacing (e.g. mm); sets the world scale. Leave 1.0 for relative calibration. |
| K_leftopt | NPARRAY | 3x3 intrinsics for the left camera from 'Calibrate Camera (Circle Grid)'. Connect BOTH K_left and K_right to hold the intrinsics FIXED and solve only for R/T; on its own it is just an initial guess and still gets refined. Leave unconnected for a fresh estimate. | |
| dist_leftopt | NPARRAY | Left distortion coefficients from 'Calibrate Camera (Circle Grid)'. Also held fixed when both K matrices are connected. | |
| K_rightopt | NPARRAY | 3x3 intrinsics for the right camera. See K_left: both connected = intrinsics pinned, one alone = initial guess only. | |
| dist_rightopt | NPARRAY | Right distortion coefficients. |
Outputs (8)
| Name | Type | Description |
|---|---|---|
| K_left | NPARRAY | Refined 3x3 intrinsic matrix for the left camera. |
| dist_left | NPARRAY | Refined distortion coefficients for the left camera. |
| K_right | NPARRAY | Refined 3x3 intrinsic matrix for the right camera. |
| dist_right | NPARRAY | Refined distortion coefficients for the right camera. |
| R | NPARRAY | 3x3 rotation matrix from left to right camera. |
| T | NPARRAY | 3x1 translation vector from left to right camera. |
| rms_error | FLOAT | Mean reprojection error in pixels; lower is better. |
| found | BOOLEAN | — |