Lighting, fixturing and conveyor conditions make or break a CV inspection because a camera records contrast, and those conditions decide whether a defect produces any contrast in the image before a model ever runs. In published weld inspection work, uncontrolled acquisition cost more accuracy than the differences between model architectures. In a 2026 weld-seam segmentation study, CNNs that reached up to 0.87 mean mask mAP50 under controlled acquisition dropped to 0.22–0.48 on shop-floor imagery. The practical answer is a pre-pilot site survey of the line’s inspection conditions: illumination and its stability across shifts, surface reflectivity, part presentation in the fixture, and conveyor speed and vibration against exposure time. The survey comes before anyone picks a model, so that controllable variance is engineered out in lighting and fixturing instead of being left for the model to learn.
In the vision inspection pipeline, lighting and fixturing engineering is where controllable variance becomes cheap and permanent to deal with.
Acquisition Outweighs Architecture: What the Weld-Seam Data Shows
The weld-seam study is worth reading closely, because it compares the same models under controlled and uncontrolled acquisition. Its controlled set was captured with an OAK-D RGB camera fixed 20 cm from the workpiece, two polariser-equipped spotlights and a neutral black background, which the authors treat as an upper bound on model performance. Its industrial set of 54 images came from the production facility with no background or illumination control, so it contains specular reflections, cluttered backgrounds, varying viewing angles and non-uniform lighting.
Across three training seeds, the CNNs scored 0.78–0.87 mask mAP50 in controlled conditions and 0.22–0.48 on shop-floor imagery, a gap far wider than any difference between architectures in either setting. The authors conclude that the acquisition setup (background, illumination and camera distance) deserves at least as much engineering attention as the choice of network. They also conclude that effort is better spent on data collection and acquisition control than on model size.
On a production line, the imaging setup is part of the inspection system, not a backdrop to it. That is our reading of the result. Polarimetric imaging shows the other route: it reached 0.89–0.93 on uncontrolled scenes against 0.25–0.62 for RGB models (seed-0 results), matching controlled-RGB accuracy without the lighting, background and distance control, at the cost of a dedicated camera and polarised illumination.
The same pattern explains why off-the-shelf detection that looks finished in a demo breaks under the lighting, edge cases and throughput of a real deployment. One study of welds with a small industrial test set does not set a general rate for every line, but the direction is hard to argue with. The model-side half of the story, including the study’s finding that transformers held accuracy under a viewpoint shift where every CNN collapsed, belongs with why detectors degrade in production.
Is This Defect Class Limited by the Model or by the Imaging?
Look at where the errors fall. We treat a class that fails on the bench, under controlled light with well-exposed images, as limited by the model or its training data. We treat a class that passes on the bench but fails on the floor, or whose error rate moves with the shift, the season or nearby equipment, as limited by the imaging conditions.
Environmental limits can build up without any event that triggers an alarm. In one documented case, a camera on a standard aluminium mount in an unheated part of a plant saw ambient temperature swing by more than fifteen degrees between summer and winter. The mount expanded and contracted enough to push borderline measurements across the pass-fail threshold on the coldest days, with no mechanical fault an operator would notice. Vibration from nearby presses, conveyors or motors can loosen mounts and shift the camera’s pose out of calibration while the camera itself shows no damage.
A short diagnostic sequence separates the two causes:
- Is the defect visible in the failing frame? If a person cannot see it in the image, no model will find it, because the camera never captured it.
- Does the part pass when re-imaged under bench lighting? We read a fail on the floor and a pass on the bench as pointing to the floor conditions, not the classifier.
- Do errors cluster by time? Plot false rejects and escapes against shift, overhead lighting schedule, season and the duty cycle of nearby machines; we treat a pattern there as environmental.
- Has anything moved since training? A model trained under one illumination and run under another is being asked a different question, which is why lighting should be locked mechanically once commissioned.
A learned model does tolerate more illumination variation than a rule-based threshold, but that tolerance is not a substitute for control. Every bit of variation the model absorbs is capacity spent on lighting instead of on the defect, and it shows up as more training images needed for the same accuracy. Consistency of illumination matters more than absolute brightness. The MVTec AD 2 dataset includes test scenarios with lighting changes specifically to assess how robust methods are.
A Pre-Pilot Imaging Site Survey, Step by Step
Daryl Martin’s practical guide for Advanced Illumination sets out a sequence of lighting analysis that works as a checklist and can be extended for a specific inspection. Its goal is lighting that meets three acceptance criteria consistently: maximum contrast on the features of interest, minimum contrast elsewhere, and a measure of robustness. We would run the survey in this order, because each step limits the options of the next:
- Physical environment. Record the working volume for camera, lens and lights, the minimum and maximum working distance and field of view, whether the part is stationary, moving or indexed, speeds and cycle time, any strobing pulse rate and duty cycle, continuous or shock vibration, how consistently the part is presented, and any risk of ambient light. Measure temperature at the actual mounting point across a seasonal cycle, not the plant’s HVAC specification, and quantify the vibration amplitude reaching the mount before selecting hardware.
- Sample–light interaction. Characterise reflectivity (diffuse, specular or mixed), overall geometry, texture, topography, composition, part colour against background, and transparency or IR transmission.
- Light contamination. Document daylight exposure, overhead fixture schedules and reflective surfaces near the inspection zone. Include light from other inspection stations, or from other stations in the same cell.
- Resolution and motion budget. Work out the effective pixels per millimetre on the smallest defect that must be caught, then the maximum exposure the line speed allows (the worked example below shows the arithmetic).
- Bench test, then floor test. Try two or three light types and techniques on the bench first, then in the real floor installation wherever possible. Include a representative section of the conveyor, because its colour, texture and reflectivity change contrast in ways an artificial background hides.
- Record per defect class. Write down what each class needs and what the line delivers, so the gap is a number, not an impression.
The guide also warns that the analysis often points in contradictory directions. Sample analysis might call for dark-field lighting while the environment forces the light to sit far from the part, and the compromise (for example, more intense bar lights in a dark-field configuration) costs extra image processing elsewhere. When the inspection and part handling are designed from scratch, the guide recommends putting the lighting solution in place first and building everything else around it.
Worked Example: Exposure Budget for Motion Blur at Line Speed
Motion blur in machine vision, often called pixel smear, happens because the product keeps moving while the sensor is exposed, so edges and fine detail spread across several pixels. The quantity to control is smear in pixels, and it follows directly from three numbers:
Pixel smear = (product speed × exposure time) ÷ object resolution (mm per pixel)
1stVision writes the same relationship as B = Vp × Te × Np / FOV, where Np is the number of pixels spanning the field of view in the direction of motion. Rearranged, it gives the longest exposure the line allows:
Maximum exposure = (permitted smear × object resolution) ÷ product speed
Machine Vision Shop’s QR-code example uses an object resolution of 0.225 mm per pixel, a conveyor speed of 7 m/min (116.7 mm/s) and a permitted smear of 0.8 pixel. The working is (0.8 × 0.225) ÷ 116.7 = 0.001543 s, so the maximum exposure is about 1.54 ms, and a 1.5 ms setting stays inside the limit while still letting in as much light as it can. A strobe shortens the effective exposure further: with a 1.0 ms light pulse inside that 1.5 ms window and ambient light suppressed, smear falls to (116.7 × 0.001) ÷ 0.225 = 0.52 pixel.
A faster, finer case shows how quickly the budget shrinks. Vision-Doctor’s example spreads a 120 mm field of view across 2,464 pixels (0.0487 mm per pixel) at 600 mm/s. One pixel of smear allows 0.0487 ÷ 600 = 0.0000812 s, or about 81 µs of exposure.
How much smear is tolerable depends on the task. 1stVision notes that blur usually becomes an issue past 1 pixel and that precision measurement may not tolerate even that. Vision-Doctor adds that 0.5–2 pixels of blur is usually invisible to the eye but still harms measurement accuracy. For a survey we would budget about 0.5–1 pixel on the smallest defect and treat anything looser as a measured exception.
The budget then sets the lighting. A short exposure needs more light, so the intensity the lighting can deliver caps the line speed that can be inspected without blur, and lighting and exposure have to be specified together against line speed. Raising exposure to compensate for weak light adds noise as well as blur. For sensor-side choices such as global against rolling shutter (a rolling shutter exposes rows in sequence and distorts moving parts), the machine vision camera page goes into the detail.
Part-Pose Spread, Depth of Field and Vibration
Pose spread in the fixture becomes a depth-of-field problem. A higher f-number widens depth of field, but beyond a point the diffraction limit raises the minimum resolvable feature size even at best focus, and shorter wavelengths recover some of that resolution. A higher f-number also gathers less light. So stopping down to cover a sloppy fixture pushes exposure up against the blur budget. That three-way trade (pose spread, depth of field, exposure) is why we would measure pose spread before anyone specifies a lens.
Do We Need Thermal or Polarised Imaging to Catch Delamination at Line Speed?
The answer comes from a feasibility study against known delamination and discoloration samples at line speed, not from a general rule. Delamination can sit below the surface, where lock-in thermography reads it from phase contrast rather than reflectance.
TechnoLynx runs this as a feasibility study against known delamination and discoloration samples. The engagement defines the detection goal (defect depth and size range, line speed, how cleanly delamination must be separated from discoloration), selects candidate modalities from the defect physics and material, then builds and tunes the rig on the line. The study measures detection accuracy, false-positive rate and throughput against known samples before anything is integrated into the coil line.
Lock-in thermography applies a periodic heat source and reads the phase shift of the thermal response with an infrared camera; adjusting the excitation frequency probes different depths, which suits delaminations in multilayer and composite structures. The same Materials (2025) paper notes that depth analysis needs measurements at several frequencies, which can be very time-consuming. That sits awkwardly with a moving line. Photometric stereo recovers surface orientation and albedo from images lit from different directions through one synchronised camera. An inline variant strobes four LEDs at high frequency so the part can keep moving, at the cost of much higher data volume and a fast processor. It is worth testing where delamination lifts or blisters the surface. Polarimetric imaging is a worthwhile upgrade on reflective surfaces mainly because it removes the burden of acquisition control.
If no single modality separates the classes, combine two (visible plus thermal, for example) and validate them jointly. Every addition raises cost, integration complexity and data bandwidth at line speed. A result on one coating or coil product may not transfer to the next, and a small sample set will miss some ambient reflections, dust and finish variation in production.
Lighting Geometry for Glossy, Matte and Textured Surfaces on One Station
Lighting geometry that stays robust across glossy and matte surfaces starts from the physical property that distinguishes a bad part from a good one, because that property dictates the geometry. For specular samples, geometry matters most; for colour and transparency problems, wavelength and filtering matter most.
Dark-field and bright-field illumination detect different defects. In dark-field illumination, light reflected specularly from a clean surface misses the lens, and only light scattered by a defect reaches the camera. A glass-inspection patent (US7551274B1) assigns dark-field to scratches, digs, surface blemishes and edge chips, and bright-field to shape, size, edge definition, coating defects and inclusions. The same patent reports that diffuse light gave a poor signal-to-noise ratio, and often an invisible defect, for many of the most common defect types.
Defect orientation matters too. In the patent’s tests, lights aligned with the conveyor showed scratches running in that direction best and cross-conveyor scratches poorly or not at all; only the combination of both light assemblies showed scratches in every orientation. We read a hairline weld or crack running in several directions across three panel shapes as the same orientation problem, which argues for multi-angle lighting over a single fixed LED bar.
Glossy labels raise the opposite problem: too much specular reflection rather than too little. A ring light sits close to the lens axis, so a flat glossy surface reflects it straight back into the lens as a hotspot over the text. Diffuse dome lighting, cross-polarisation (which suppresses specular reflection) or several off-axis lights are the usual alternatives. Diffuse light can leave many common defect types low-contrast or invisible. A station that must read text and find scratches may therefore need two lighting modes.
Test the chosen setup against the variation in part size, shape, orientation, placement and ambient light the plant actually sees, because contrast alone holds only when those stay consistent. We would treat a new or substituted packaging stock as outside the validated range. Re-checking after such changes is covered in how lighting drift on a production line breaks a CV inspection model.
One Lighting Setup Across Variants, or Per-Variant Presets?
Whether one optics and lighting setup can serve several variants depends on measurement: compare the variants’ geometry and reflectivity differences against the tolerance band within which the target defect keeps enough contrast. If the variation stays inside the band, one variant-tolerant setup works; if not, per-variant presets or reconfiguration triggers are needed.
TechnoLynx’s Computer Vision R&D work covers this trial. The trial characterises the variants’ geometry and reflectivity against the current optics and defines a test matrix of illumination angles and wavelengths. TechnoLynx then runs it on the physical inspection cell and measures defect contrast across variants to decide between a single setup and preset switching.
The geometry behind that band is interlocked. In the glass patent, baffle size, light angles, light-to-baffle distance and baffle width are all interrelated, and changing one angle moves the required distances. Higher-reflectivity panels make geometry more decisive still, since specular samples are where geometry matters most. The illumination wavelength should match the camera’s sensitivity, and shorter wavelengths help preserve resolution when the aperture is stopped down for depth of field. No general rule names the angle and wavelength that will show hairline cracks on a new panel; the trial does.
For fixture-to-fixture variation, the same depth-of-field limits apply: the band is as wide as the lens can hold focus and the light can hold contrast. Two caveats keep that band honest. We treat it as specific to the materials and defects tested, so a new material gets a new trial. Fixture wear over time can erode the margin the trial measured.
Is Programmable Multi-Angle Lighting Cheaper than Re-Aiming Lights per Variant?
Programmable multi-angle lighting pays off when avoided manual reconfiguration repays its upfront and maintenance cost within the payback period the business accepts. The comparison needs the plant’s own changeover data.
The recurring side has three terms: technician time per re-aim multiplied by changeovers per year, line downtime per changeover multiplied by the cost of a line hour, and the quality cost of a re-aim that lands slightly off. Lighting that stays adjustable after commissioning is a liability, because a model trained under one illumination and run under another is being asked a different question. A rig that recalls stored settings per variant keeps the lighting locked in software rather than depending on someone’s hands at changeover.
Payback is the upfront cost divided by the annual avoided cost, so it shortens as the number of variants per year grows. The estimate is only as good as the current changeover times it is built on; measure them before trusting the result. The weld-seam study offers a parallel piece of logic: polarimetric imaging was worth its dedicated camera and polarised lights mainly because it removed the acquisition-control burden, not because it raised an already competitive accuracy ceiling. Precedent from elsewhere in the supply chain is informative, but a peer’s solution on another cell is no guarantee for this one.
Change the Line’s Lighting or Retrain the Model Under It?
Measure first: run the current model on samples imaged under the facility’s overhead lighting and on samples from the pilot rig, and compare false-reject and false-accept rates directly. If the gap is small and closes after fine-tuning on facility-lit samples, we would adapt the model and leave the line alone. If the gap persists after retraining, or if facility light varies too much for any single model to stay stable, install dedicated lighting per inspection head.
Overhead factory lights and sunlight are the most common ambient contributors, and with a broad-spectrum source such as white light they can badly affect inspection quality and consistency. The Advanced Illumination guide lists three active controls: high-power strobing with short pulses, physical enclosures, and pass filters. A strobe also freezes motion: once ambient light is suppressed, the pulse rather than the exposure determines motion freeze.
| What the measurement shows | What it points to | Route |
|---|---|---|
| Small error gap that closes after fine-tuning on facility-lit samples | Model has not seen facility conditions | Retrain or fine-tune, keep existing lighting |
| Gap stays large after retraining | Lighting mismatch the model cannot absorb | Dedicated lighting and optics per head |
| Errors move with time of day, season or fixture schedule | Ambient light is not stable | Strobe, enclosure or pass filter |
| Defect not visible in facility-lit frames | No contrast to learn from | Lighting change; retraining cannot create contrast |
Retraining has its own cost: labelled defect data collected under facility conditions, which takes time and may need defect injection or simulation. A single retrained model can also fall behind if overhead lighting changes with the seasons. Dedicated lighting is a one-off capital cost per head that adds maintenance and line-design complexity. Variance the model has to absorb is paid for in training images, so where lighting can be controlled cheaply, we would control it.
Dim Light, Steam and Night Shifts: Visible, Near-Infrared or Thermal?
The imaging modality and the minimum illumination have to be derived from the defect or wear types being detected and their accuracy targets; neither can be set in general. Visible light with software enhancement is the cheapest option to test first, and infrared vision earns its cost only where enhancement cannot close the gap.
TechnoLynx starts this by fixing the accuracy target per wear or defect type and recording what the existing PoE cameras and lighting allow. TechnoLynx then compares visible-light enhancement pipelines against near-infrared and thermal options on that taxonomy and tests detection under the real steam and light levels before integrating anything with night-shift operations.
The physics separates the options. Thermal cameras in the long-wave (8–14 µm) and mid-wave (3–5 µm) bands detect emitted heat, so they work in complete darkness with no external light. LightPath notes that near-infrared, like visible light, is scattered by fog, smoke and precipitation, while long-wave thermal penetrates those obscurants much more effectively. Steam and condensation behave more like fog than clear air, which makes that distinction relevant, though the source does not measure steam itself. Stretching visible-light exposure in dim conditions adds noise and blur, which is why low-light enhancement methods such as Retinex-based or learned approaches are candidates to test rather than assumed fixes. We would not expect software to recover detail lost to heavy steam occlusion or severe sensor noise. A thermal or near-infrared upgrade may also need budget and installation that a “no added IR” constraint does not allow.
Who Can Survey Our Line’s Imaging Conditions Before We Fund a CV Pilot?
TechnoLynx runs the pre-pilot imaging survey: it measures illuminance and its stability across shifts, effective pixels per millimetre on the smallest defect, motion blur at line speed and part-pose spread in the fixture, and records them per defect class. When choosing a partner, ask whether they will measure the line before quoting a model accuracy. Where the open question is which edge device should run the model, LynxBenchAI’s published results show how each device runs the public PyTorch stack, which is broadly indicative for custom models but does not measure your workload.
On build versus bring in: a team with machine vision engineers inspecting one stable defect at one station can run the checklist above in-house. A manufacturing AI engineering specialist earns its place when several defect classes and a pilot budget depend on the answer. The survey suits less well where the product is standard PCB assembly and an off-the-shelf AOI machine with its own validated lighting already does the job; the machine’s supplier is the shorter route there. Where the line’s conditions are already known and stable and the question is purely model performance, a model-focused engagement fits better.
How the Survey Record Feeds the Per-Defect-Class Go/No-Go
The survey’s output is a record per defect class: measured illuminance and its stability across shifts, effective pixels per millimetre on the smallest defect, motion blur at rated line speed, and part-pose spread in the fixture. Those numbers set the achievable accuracy band before a pilot is funded. They also separate accuracy loss that a lighting retrofit can fix from loss that needs a redesign of the camera or conveyor geometry. That evidence of physical constraints is what lets CV inspection feasibility end in a go/no-go per class rather than a single verdict for the whole line.
The record sorts each class as feasible now, feasible after a lighting retrofit, or unresolvable at the current camera and conveyor geometry. Sorting which defect classes are feasible for CV inspection today this way, before the pilot, guards against bench accuracy the line cannot sustain because it was never characterised, the failure described in why most CV inspection pilots over-promise on accuracy. The same record then becomes a baseline artefact for the industrial CV reliability evidence required at hardening time.
The uncertainty that remains is real. A class that is unreachable today may become feasible with a change of lighting, or it may stay a no-go whatever the light does. The survey is what tells you which. What it does is replace a guess with a measured reason, before the money is spent.