System designHow-to

Checkerboard calibration target size: how many squares and how big

Size a checkerboard target from your working distance: the half-field rule, pixels per square, even-odd square counts, print accuracy and image poses.

LumaSpec Vision11 min read Share on LinkedIn

On this page 9 sections
  1. 01How big should a checkerboard calibration target be?
  2. 02How do you compute the field of view at your working distance?
  3. 03How many squares should the board have?
  4. 04Why must one side be even and the other odd?
  5. 05What steps take you from working distance to a finished board?
  6. 06How accurate does the printed pitch have to be?
  7. 07Which images make the calibration accurate?
  8. 08When is a plain checkerboard the wrong target?
  9. 09Questions

A calibration target of the wrong size wastes an afternoon: too small, and its corners never reach the frame edges where lens distortion lives; too dense, and the corner detector starts dropping views. Three numbers size the board — field of view at the working distance, pixels per square, and square-count parity — and every one of them comes from numbers you already know: sensor width, focal length, working distance and image resolution. The steps below take you from a working distance to a printed, measured and mounted target, with worked arithmetic for a bench machine-vision camera at 500 mm and a large-format camera standing 2 m from the scene.

How big should a checkerboard calibration target be?

Aim for a board that spans half of the field-of-view width at your working distance, and up to two-thirds where you can still handle it; with a 25 mm lens on a 1" sensor at a 500 mm working distance, that is a board around 150 × 105 mm, not a pocket target.

The distortion solve is least constrained at the edges and corners of the frame, because that is where the image is stretched most. A board covering at least half the width, moved through a handful of positions and tilts, puts corners into every region of the frame within 15 to 20 exposures. Published practice spans anywhere from 10% to 100% of the field across the pose set; the larger board simply arrives there in fewer, easier shots. Past about two-thirds of the width the returns flatten and the board becomes hard to hold square, so stop there. A smaller board can still calibrate if you carry it through more positions; the margins to leave around a known field are worked through in the calibration target field of view and coverage margins guide.

How do you compute the field of view at your working distance?

Estimate the field width from the thin-lens relation, sensor width times working distance divided by focal length: with a 13.2 mm wide sensor, a 25 mm lens and a 500 mm working distance, that gives 13.2 × 500 ÷ 25 = 264 mm of field width.

FOV_w = sensor_w × WD / f FOV_h = sensor_h × WD / f
How sensor width, working distance and field of view set the focal length Rays from the edges of the sensor pass through the lens and spread to the edges of the field of view. The ratio of sensor width to field of view is the magnification m.CameraField of view (FOV)Working distance (WD)≈ fsensor width slensm = s / FOVf = WD × m / (1 + m)
How sensor width, working distance and field of view set the focal length. Rays from the edges of the sensor pass through the lens and spread to the edges of the field of view. The ratio of sensor width to field of view is the magnification m.

Typical active sensor widths: about 7.2 mm for a 1/1.8" format, 8.8 mm for 2/3", 13.2 mm for a 1" format in 3:2 aspect, and 36 mm for the 36 × 24 mm full-frame format. A real lens shifts its effective focal length as it focuses closer, so treat the estimate as good to a few percent; one pass with a steel rule across the actual field pins it down exactly. The working distance and field of view formula guide runs the same relation for a production layout.

To run it the other way — from the field you need to the focal length that delivers it — open the field-of-view and focal length calculator:

Lens focal length, field of view and working distance
Units
Solve for
Focal length
– mm
Field of view
– mm
Working distance
– mm
Magnification
– x
Angle of view
– °
Pixel on the part
– mm

Thin-lens model: m = sensor width / field of view, f = WD × m / (1 + m). Accurate to a few percent above about 150 mm; check the lens's minimum object distance.

Find lenses with this focal length Open the full calculator

For the machine-vision worked examples below, take any 20 MP mono camera with a 1" sensor, C-mount and USB3 interface.

Area scan camerasHikrobot MV-CS200-10UM 20 MP Area Scan Camera, USB3.0, IMX183, 2nd Gen., MonoMV-CS200-10UM
Sensor format
1"
Lens mount
C-mount
Interface
USB3
Resolution
16-25 MP
$759.00View partBuild a system with it

How many squares should the board have?

Two floors decide it: every square should span at least 30 pixels in the image — about 50 for comfort — and each view should contribute at least 6 × 4 inner corners, with 9 × 6 the working default, which is a 10 × 7-square board.

square_px = image_w_px × pitch / FOV_w pitch_min = 30 × FOV_w / image_w_px board_w = columns × pitch

Worked example, continuing the bench setup: a 20 MP 3:2 image is about 5472 × 3648 pixels, because 13.2 mm ÷ 5472 = 2.4 µm per pixel. At a 15 mm pitch the 10 × 7 board measures 150 × 105 mm, and each square spans 5472 × 15 ÷ 264 = 311 pixels. The reverse floor gives 30 × 264 ÷ 5472 = 1.4 mm, so detection has enormous margin at bench distances; spend the slack on corner count and handling instead of density. At a 2 m standoff the same 25 mm lens widens the field to 1056 mm and lifts the floor to 5.8 mm — still easy, but now the board size, not its density, becomes the problem, which is the territory of the checkerboard calibration fails at distance guide.

More corners average out noise and shrug off one or two bad detections; denser squares raise accuracy in theory but give the detector more chances to miss or misorder, and subpixel corner fitting needs those pixels. When views start failing, work through what to check when the chessboard is not detected; the same pixel-size floor explains why tiny fiducial markers fail.

Why must one side be even and the other odd?

With squares counted even along one axis and odd along the other, a 180-degree turn of the board is no longer indistinguishable from the original, so the detector cannot silently flip the corner ordering; a 14 × 10 board fails this test — print 13 × 10 or 14 × 9 instead.

Both-even and both-odd boards map onto themselves under a 180-degree rotation: every black square lands on another black square. The detector then has two equally valid orderings, and the solver either discards the view or, worse, folds it in with a mirrored interpretation; the usual symptom is a handful of views whose residuals sit far above the rest. Mixed parity breaks the symmetry, which is why the guidance across the common calibration tools reads one edge even, the other odd. The rule holds for corner counts too, because a board of c × r squares has (c − 1) × (r − 1) inner corners, one fewer per axis: most libraries ask for those inner corners, so a 10 × 7-square board is entered as 9 × 6. If a both-even board is already printed and mounted, do not start over: cut one row of squares away, remount it flat, and enter the new inner-corner count.

What steps take you from working distance to a finished board?

Fix the distance, compute the field, choose the coverage, divide into squares, check the pixels, set the parity, then print matte, measure the pitch and mount flat — seven steps, run here for a full-frame 18 MP camera standing 2 m from the scene.

  1. Set the working distance. Put the camera where the parts will actually sit: WD = 2000 mm. Focus once and fix it.
  2. Compute the field. With a 36 mm wide sensor and a 35 mm lens, FOV_w = 36 × 2000 ÷ 35 = 2057 mm and FOV_h = 24 × 2000 ÷ 35 = 1371 mm.
  3. Choose the coverage. Half to two-thirds of 2057 mm is about 1030 to 1370 mm. The board below covers 48% — just under target — and works because the poses spread well.
  4. Divide into squares. At a 70 mm pitch, 980 ÷ 70 = 14 columns and 700 ÷ 70 = 10 rows.
  5. Check pixels per square. An 18 MP full-frame image is about 5184 × 3456 pixels (36 mm ÷ 5184 = 6.9 µm), so each square spans 5184 × 70 ÷ 2057 = 176 pixels, well above the 30-pixel floor.
  6. Set the parity. 14 × 10 is both-even and ambiguous. Cut it to 14 × 9 (980 × 630 mm) or 13 × 10 (910 × 700 mm), giving 13 × 8 or 12 × 9 inner corners.
  7. Print, measure, mount. Print at 100% scale on matte stock, measure the pitch across the longest span, mount the board flat, and shoot the poses in the next section.

Hold the camera itself on a slide-table camera stand so the working distance cannot drift between poses; the LS-MNT-0040 below is the professional slide-table type with a 700 mm height and a 400 x 450 mm base.

Camera standsMachine vision camera stand, professional slide-table type, height 700 mm, 400 x 450 mm base (LS-MNT-0040)LS-MNT-0040
Type
Camera stands
$629.00View partBuild a system with it

How accurate does the printed pitch have to be?

Pitch error passes into the calibration scale one for one, so keep it under 1% of the square side for pose and guidance work and under 0.1% where you measure parts; on a 50 mm square that is 0.5 mm loose and 0.05 mm tight.

A square printed 1 mm short of a nominal 50 mm is a 2% scale error, and the solve inherits it: every distance reads 2% off, with the bias absorbed into the focal length. The common failure is not printer repeatability but print scaling — a 600 mm pattern sent through fit-to-page arrives near 594 mm, a clean 1% short. Print at 100% scale, then measure the pitch across the longest span with a steel rule or calipers: 0.5 mm out of 600 mm is 0.08%, which is measurement-grade once you enter the measured pitch as the square size. Measuring a single square lies about the average; across the full board the scale error shows where it matters. Flatness matters as much as length, because the model assumes the target is a plane: hold the board flat to about 0.5 mm across its width on bonded aluminium, glass or rigid composite, not foam board, which bows within days. The grid pitch and calibration error guide traces what each of these does to the result.

Which images make the calibration accurate?

Take 15 to 20 views: the board centred, then held near each corner of the frame and along the edges, tilted up to about 45 degrees, with focus and exposure locked so every corner lands sharp and unbloomed.

Focus first: calibrate at the same distance and focus setting as production, because a refocused lens is effectively a different focal length. Exposure second: keep the white squares below saturation, because bloom eats into the black squares and rounds the corners the detector fits. Tilt third: views up to about 45 degrees stabilise the focal-length estimate, while beyond that the oblique corners fit poorly on most sensors. A mono sensor buys crisper corners because there is no demosaicing step; colour works, just with slightly softer fits. Judge the result by its residuals rather than by how tidy the shots look — the average and maximum residual targets guide gives the numbers to hold it to. And re-shoot if the temperature moved far between calibration and production, because focus drifts with heat, which shows up as daytime blur.

When is a plain checkerboard the wrong target?

When the camera is fixed and the scene is far wider than any board you can hold — a camera over a 3 m conveyor, say — swap to a coded target whose squares carry individual identities, because partially visible views still solve.

A plain board only scores when the detector sees the whole pattern; hide 30% of it behind a part or a frame member and the view is lost, along with the corners you needed at that spot. Coded targets in the ArUco, ChArUco and AprilGrid families label every cell, so a partially visible board still contributes known points, at the cost of printing a marker layout and running a library that decodes it. The decision by case: bench or cell with fields up to about 1 m — a plain 10 × 7 board at half the field width, 9 × 6 corners. Fixed camera over a wide scene — a coded target, placed wherever the corner coverage is thinnest. Telephoto fields of several metres — accept a small target, sweep the whole frame with it, and expect more poses; where even a board is impractical, a single printed square can still calibrate the camera within known limits.

Size the camera and lens first, because they set the field the board has to fill. The area scan cameras page and the camera finder filter by sensor format and resolution, the machine vision lenses page pairs a focal length with the format, and the camera configurator walks the whole chain; the accessories finder covers the stands and mounting hardware. The rest of the maths around calibration lives on the systems topic page.

Questions

Can I calibrate with a board smaller than half the field of view?

Yes. Published practice runs from 10% to 100% of the field across the pose set, so a small board works if you carry it through 15-20 positions until the corners collectively cover the frame, edges included. The cost is time, and a steadier hand at the frame borders, where a small board is hardest to hold square.

How few calibration images can I get away with?

Two distinct poses solve the model mathematically, but nothing is then over-determined and one bad corner corrupts the result. Ten views is the practical floor and 15-20 gives margin. Each view contributes (cols − 1) × (rows − 1) corners, so a 10 × 7-square board adds 54 corners per shot.

Why does my board calibrate with low error but measure the wrong size?

Because the print scale, not the solver, is wrong. If fit-to-page shrank every square by 1%, or you typed a nominal 50 mm pitch that actually measures 49.5 mm, the calibration is self-consistent but every distance reads 1% off. Measure the real pitch across the full board and enter that number.

Should I laminate the printed board or leave the paper matte?

Leave it matte. Gloss lamination turns white squares into mirrors; under any directional light the highlights swallow the black squares and round the corners the detector fits. If the target must survive oil or washdown, mount the matte print behind glass or on a bonded-aluminium board instead of sealing its surface.

Does a colour sensor calibrate as well as mono?

Colour calibrates, but demosaicing interpolates half the green pixels and all of the red and blue ones, which softens corner estimates slightly, and coloured lighting adds a cast the corners inherit. A mono sensor gives the sharpest, most repeatable corner fits, which is why calibration benches usually run mono cameras.