Nodes/comfyui_cv/CV Calibrate Camera (ChArUco)
ComfyUI Node

CV Calibrate Camera (ChArUco)

Camera intrinsics + lens distortion from a batch of ChArUco board photos - the robust alternative to 'CV Calibrate Camera (Chessboard)'. A plain chessboard view is thrown away unless EVERY inner corner is visible; a ChArUco view contributes whatever corners it can identify, so photos where the board runs off the frame or is partly occluded still count. That means fewer, easier shots for the same coverage - and coverage of the image CORNERS, which is exactly where distortion is estimated, is what a full-board requirement makes hardest. Views with too few corners are skipped. Failure-tolerant: fewer than 3 usable views returns found=false with an identity matrix and zero distortion.

By bmad4ever·Created 3 months ago·Updated 2 days ago· 0
CV Calibrate Camera (ChArUco)
  • images
  • camera_matrix
  • dist_coeffs
  • rms_error
  • views_used
  • corners_used
  • found
dictionaryDICT_6X6_250
cols5
rows7
cell_size0.040
marker_ratio0.70
min_corners6
legacy_patternfalse
Categoryimage/CV/features

Inputs (8)

NameTypeDefaultDescription
imagesIMAGEBatch of board photos from DIFFERENT angles and distances (>= 3 usable; ~15 gives a good fit). Tilt the board - views that are all fronto-parallel cannot separate focal length from distance.
dictionaryCOMBODICT_6X6_250Dictionary the board's markers were drawn from.
colsINT52–50Chessboard squares across (as given to the board image node).
rowsINT72–50Chessboard squares down.
cell_sizeFLOAT0.0400.0001–1000000Physical square size of the PRINTED board; it sets the world unit of the translation vectors.
marker_ratioFLOAT0.700.05–0.95Marker edge as a fraction of the square - the value used to generate the board.
min_cornersoptINT64–1000Skip a view that identifies fewer corners than this. Four is the theoretical minimum for a planar view; 6-10 keeps the fit stable.
legacy_patternoptBOOLEANfalseSet for boards generated by OpenCV before 4.6 (white top-left cell).

Outputs (6)

NameTypeDescription
camera_matrixNPARRAY3x3 intrinsic matrix K (fx, fy, cx, cy).
dist_coeffsNPARRAYDistortion coefficients (k1, k2, p1, p2, k3).
rms_errorFLOATMean reprojection error in pixels; lower is better (under ~1 is good).
views_usedINTHow many input views contributed corners - compare it with the batch size to see how many were skipped.
corners_usedINTTotal identified corners across all used views; this is the number that really drives the fit.
foundBOOLEAN