The Vision System That Took a Picture and Never Finished
A customer installed a vision inspection station on a high-speed line. The camera triggered on a photoeye. The inspection (a pass/fail on a label) was supposed to take 100 ms. On the line, it took 500 ms — the line had to pause for the camera every cycle. The customer blamed the camera. We looked at the program. The vision job was running 12 tools: locate, read barcode, check label, measure gap, inspect print, verify color, and so on. Every part went through all 12 tools, even though most parts only needed 3 of them. The camera was fast; the program was bloated. We split the job: 3 tools for the common case, and a separate 12-tool job only when the sensor flagged a suspect part. The cycle dropped to 120 ms. The line no longer paused. The camera was not slow — the program was.
Vision cycle time is set by the number of tools, not the camera. Here is how to keep the inspection fast without losing coverage.
What Consumes Vision Time
A vision system’s cycle time is the sum of three steps:
- Image acquisition: The exposure time (how long the sensor gathers light). A 5 ms exposure is fast; a 50 ms exposure (dim lighting) is slow.
- Image transfer: Moving the image from the camera to the processor. GigE cameras add latency; CameraLink is faster.
- Processing: Running the vision tools (locate, measure, read). Each tool adds time. 12 tools at 30 ms each is 360 ms.
The customer’s 500 ms was 12 tools × 30 ms. The camera was fine; the program was doing too much. The fix was not a faster camera — it was fewer tools per part.
The Split-Job Trick: Fast Path, Slow Path
Most parts are good. Run a fast job (3 tools: locate, check label, verify present). If the fast job passes, the part goes through in 100 ms. Only when the fast job flags a suspect (a label angle out, a missing print) does the system call the full job (12 tools, 500 ms). The suspect parts are maybe 2% of the total. The other 98% run at the fast speed. The average cycle drops to 108 ms — even though the full job still takes 500 ms when it runs.
The vision rule: Do not run every tool on every part. Use a fast “gate” job (3 tools) for the common case, and a full “deep” job only when the gate flags something. The 500 ms inspection dropped to 120 ms because 98% of parts never needed the deep job.
Image Resolution: More Pixels, More Time
A high-resolution image (5 MP) takes longer to acquire, transfer, and process than a low-resolution one (0.5 MP). If the inspection only needs to check a label’s presence (a 100×100 pixel region), use a low-resolution camera and crop the image to the region of interest. Processing 10,000 pixels is 10× faster than processing 1,000,000. The camera’s full resolution is wasted on a label-presence check.
Lighting: Faster Exposure
A dim image requires a long exposure (50 ms) — during which the part must be stationary (the line pauses). Bright lighting (a strobe, an LED bar) allows a 1 ms exposure — the line does not need to stop. The customer’s 500 ms included a 30 ms exposure because the lighting was weak. Adding a strobe dropped the exposure to 2 ms, and the line no longer paused. Good lighting is a cycle-time upgrade, not just an image-quality upgrade.
A Vision Cycle Checklist
- Time each step: exposure, transfer, processing.
- Count the number of vision tools running per part.
- Split into a fast gate job and a deep suspect job.
- Crop the image to the region of interest (not the whole frame).
- Use the lowest resolution that meets the measurement requirement.
- Add bright lighting (strobe) to shorten exposure.
- Verify the line does not need to pause for the image.
- Track the average cycle, not the worst case.
- Test the suspect path (the deep job) on real rejects.
- Re-time after adding a new inspection tool.
A Typical Time Breakdown
| Step | Before | After Optimization |
|---|---|---|
| Exposure | 30 ms (dim) | 2 ms (strobe) |
| Transfer | 20 ms | 10 ms (ROI crop) |
| Tools (fast gate) | — | 3 tools × 20 ms = 60 ms |
| Tools (deep, on suspects) | 12 tools × 30 ms = 360 ms | 12 tools × 30 ms = 360 ms (only 2%) |
| Average cycle | 410 ms | 72 ms |
The Bottom Line
The vision system that took a picture and never finished was a bloated program running 12 tools on every part. Split the job into a fast gate and a deep suspect path, crop the image, add strobe lighting, and the cycle drops. The camera was not slow — it was doing work that 98% of parts did not need.