Classical Machine Vision vs AI: A Guide for Manufacturing
Classical machine vision measures and reads codes by rules. AI learns from examples and handles products that are never identical. This guide shows when to use which approach and why modern systems often combine both.

A camera above the line can decide about each part in two ways. Classical machine vision compares the image with rules that someone wrote in advance. AI, more precisely deep learning, learns from examples of good and defective parts what a correct product looks like. Both approaches have their place on the line. This guide explains how they work, where each one is strong and how to choose between them.
How classical machine vision works
Classical machine vision is deterministic. A technician sets the rules: this edge must lie at a defined position within a given tolerance, this area must contain a certain number of dark pixels, this code must be readable. The system then compares each image with the rules and returns an OK or NOK result.
Typical tools are edge detection, blob analysis, pattern matching, dimension measurement and reading of barcodes and DataMatrix codes. These tools are fast, their decisions can be explained, and they have run reliably in factories for decades.
The weak point is variability. Rules struggle where good products naturally differ, where lighting conditions change or where defects cannot be fully described in advance. A strict rule also rejects good parts. A loose rule lets defects through.
How AI works in machine vision
Deep learning reverses the process. Instead of writing rules, you show the model examples. You train the model on photos of OK and NOK parts, and it learns what a good product looks like, including its harmless natural variability.
Anomaly detection models go further. They need mainly images of OK parts and report everything that differs from them. For this reason, they also suit defects that you have not seen before.
The price for this ability is data. The model needs representative images from real production, and you must retrain it after a change of product, packaging or lighting. A model decision is also harder to explain than the violation of a specific rule.
Comparison in one table
Aspect | Classical machine vision | AI (deep learning) |
|---|---|---|
How the system decides | By rules that a technician writes | By patterns that the model learns from examples |
Strong tasks | Dimension measurement, code reading, part position and presence | Surface defects, natural and variable products, classification |
Typical products | Rigid parts with fixed geometry, automotive, electronics | Food, bakery products, meat, flexible packaging, labels |
What you need at the start | An exact description of the defect and tolerances | Images of OK and NOK parts from real production |
Product change | A technician adjusts the rules | Adding images and retraining the model |
Explainability | High, each decision has a specific rule | Lower, the model decides by learned patterns |
When classical machine vision is enough
- You measure dimensions with a fixed tolerance.
- You read barcodes, DataMatrix codes or printed text at a fixed position.
- You check the presence and position of a rigid part.
- The product has a stable shape and the lighting is under control.
When you need AI
- Good parts naturally differ, for example bakery products, cheese or sandwiches.
- Defects cannot be fully described in advance, for example scratches, stains or deformations.
- You often introduce new products or change packaging.
- The rule-based system rejects too many good parts.
Why modern systems combine both approaches
In practice, the two approaches complement each other. Rules handle measurement and code reading, and neural networks handle surface defects and classification. Computing units directly on the line (edge AI) run the evaluation without a cloud connection, so production images do not leave the plant.
The article What is a vision system describes step by step how this loop works, from the trigger to the rejection of a part.
How to choose
- List the defects and the line cycle time.
- Classify the product: stable in shape or naturally variable.
- Decide who will maintain the system after a product change.
- Test the solution on your own worst NOK parts.
Robopipe uses deep learning trained on your products. The subscription price includes an IP67 camera and an AI PLC control unit. The camera quality inspection page shows how it works on the line.