What machine vision does
Machine vision means using cameras and software to look at products or parts and make a decision, usually pass or fail, sometimes measure or sort. It is used on production lines to check that a label is present, a cap is seated, a weld looks continuous, a printed code is readable, a dimension is within tolerance or a surface is free of scratches.
The appeal of automated quality inspection is consistency and pace. A person inspecting items all day can tire or vary from hour to hour, while a camera applies the same check to each item at line speed. That does not make the system perfect, and many factories keep people in the loop for judgments the software cannot make well.
The basic pieces
A typical inspection station has a few parts working together:
- A trigger. A sensor detects that a part has arrived so the camera captures it at the right moment.
- Lighting. Controlled light, often shaped for the particular defect being sought.
- A camera and lens. Matched to the size of the area and the detail needed.
- A processor. Software that analyzes the image, often on a dedicated unit near the line.
- An output. A signal to a reject mechanism, a counter or a controller. The logic that acts on this signal is often handled by programmable logic controllers on the line.
Many of the same ideas apply to the image sensors used in other connected systems, but industrial setups lean much more heavily on controlled conditions.
Two broad approaches to analysis
Rule-based methods use fixed measurements: Is there a dark region here? Is this edge at the expected position? Is the object’s width between two limits? These are transparent and fast, and easy to explain when a part is rejected. They work well when the product is consistent and the defect is clearly defined.
Learned methods use machine learning, with a model trained on example images of good and bad items. They can cope better with natural variation, such as wood grain or textured surfaces, where defining a rule is hard. Their drawbacks are the need for enough representative examples, particularly of rare defects, and the difficulty of explaining exactly why an item was flagged. Some systems train only on good examples and flag anything unusual, which is a form of anomaly detection.
Neither approach is automatically better. Many lines use both: simple rules for measurements and a trained model for surface appearance.
Why setup is harder than it looks
Demonstrations on a bench can look impressive, and then performance drops on a real line. Common reasons include:
Lighting. This is frequently the biggest factor. Glare on shiny parts, shadows, changing daylight from a nearby window or a bulb that dims with age can all alter the image. Careful lighting often makes a defect stand out so clearly that the software has an easy job. Poor lighting can make the job nearly impossible, whatever the software.
Part position and presentation. If parts arrive rotated, tilted or at slightly different heights, the image changes. Fixtures, guides or software that finds and aligns the part help.
Speed. A fast line leaves little time per item. Cameras must expose briefly to avoid motion blur, and the analysis must finish before the next item arrives. This is one reason image processing is often done through local processing rather than sending every picture to a distant server.
Variation in the product. A new color, a changed supplier or a slightly different material can confuse a system tuned to the old version. Product changeovers need a plan.
Defining acceptable. A surprising amount of effort goes into deciding what counts as a defect. Two inspectors may disagree about a faint mark. A vision system needs a clear, agreed standard, ideally with sample images of borderline cases.
Dirt and vibration. Dust on a lens, a camera knocked out of position or vibration from nearby machines can quietly degrade results. Housings, cleaning schedules and secure mounting matter.
Measuring how well it works
Two kinds of mistake matter. A false reject flags a good item, wasting product and time. A missed defect lets a bad item through. Tightening a system to catch more defects often increases false rejects, so there is a trade-off, and the right balance depends on the cost of each error. For something safety-related, a team may accept many false rejects to avoid a single miss.
Sites typically test a system on a stored set of known good and bad samples before trusting it, then keep checking after launch. Performance can drift as lighting, materials and wear change, much like sensor calibration needs rechecking on any instrument.
Data and integration
Inspection results are valuable beyond the reject decision. Counting defect types and times can reveal that a particular machine or shift produces more faults, helping trace the cause upstream. Pass and fail counts also feed the quality portion of equipment effectiveness figures. Images take up considerable storage, so teams decide what to keep, often saving only failures or samples. Where images show people, privacy and retention rules may apply.
Practical advice
- Start with a narrow, well-defined defect rather than “inspect everything”.
- Spend time on lighting and mounting before tuning software.
- Collect real examples from the actual line, including borderline ones, and from different shifts.
- Run a small pilot alongside human inspectors and compare results before relying on the system.
- Plan for maintenance: cleaning, recalibration and retraining when products change.
Done carefully, machine vision can make quality checks more consistent. Treated as a plug-in camera, it often disappoints.