Machine vision is the use of machines to replace human eyes for measurement and judgment. A machine vision system refers to the process of converting the captured target into an image signal through machine vision products (i.e., image acquisition devices, which are divided into CMOS and CCD types), transmitting it to a dedicated image processing system, and converting it into a digital signal based on pixel distribution, brightness, color, and other information; the image system performs various operations on these signals to extract the target's features, and then controls the on-site equipment based on the judgment results.
Overview
Machine vision
Machine vision systems are characterized by improved production flexibility and automation. In hazardous work environments unsuitable for manual labor or where human vision is insufficient, machine vision is often used to replace human vision. Furthermore, in large-scale industrial production, manual inspection of product quality is inefficient and lacks precision; machine vision inspection methods can significantly improve production efficiency and automation. Moreover, machine vision facilitates information integration, making it a fundamental technology for computer-integrated manufacturing. Because machine vision systems can rapidly acquire large amounts of information, are easily processed automatically, and are readily integrated with design and processing control information, they are widely used in modern automated production processes for areas such as condition monitoring, finished product inspection, and quality control.
Basic structure
A typical industrial machine vision system includes: a light source, a lens, a camera (including CCD cameras and CMOS cameras), an image processing unit (or image capture card), image processing software, a monitor, and a communication/input/output unit.
The system can be further divided into: host computer, frame grabber and image processor, video camera, CCT lens, microscope lens, lighting equipment, halogen light source, LED light source, high-frequency fluorescent light source, flash light source, other special light sources, image display, LC mechanism and control system, PLC, PC-Base controller, precision table, and servo motion machine.
Working principle
Machine vision inspection systems use CCD cameras to convert the targets to be inspected into image signals, which are then transmitted to a dedicated image processing system. Based on pixel distribution and information such as brightness and color, the signals are converted into digital signals. The image processing system performs various calculations on these signals to extract the features of the targets, such as area, quantity, position, and length. Based on preset tolerances and other conditions, the system outputs results, including size, angle, number, pass/fail, presence/absence, etc., to achieve automatic recognition.
Typical structure of machine vision system
illumination
Illumination is a crucial factor affecting the input of machine vision systems, directly influencing the quality of input data and application effectiveness. Since there is no universal machine vision lighting equipment, appropriate lighting devices must be selected for each specific application to achieve optimal results. Light sources can be divided into visible and invisible light. Commonly used visible light sources include incandescent lamps, fluorescent lamps, mercury lamps, and sodium lamps. A drawback of visible light is its instability. How to maintain light stability to a certain extent is a pressing issue to be addressed in practical applications. On the other hand, ambient light can affect image quality, so using a protective screen can reduce its impact. Illumination systems can be categorized by their illumination method: backlighting, front lighting, structured light, and strobe lighting. Backlighting places the object under test between the light source and the camera, offering the advantage of high-contrast images. Front lighting places the light source and camera on the same side of the object under test, facilitating installation. Structured light illumination projects gratings or line light sources onto the object under test, demodulating the object's three-dimensional information based on the resulting distortions. Strobe lighting involves shining high-frequency light pulses onto an object, and the camera must synchronize with the light source when shooting.
lens
FOV (Field of Vision) = Required resolution * Sub-pixel count * Camera size / PRTM (Part Measurement Tolerance Ratio). Lens selection should consider: ① Focal length ② Target height ③ Image height ④ Magnification ⑤ Distance from image to target ⑥ Center point/Nodal point ⑦ Distortion.
camera
Cameras can be categorized according to different standards, such as standard resolution digital cameras and analog cameras. Different cameras and high-resolution cameras should be selected based on the specific application: line scan CCDs and area scan CCDs; monochrome cameras and color cameras.
Image acquisition card
The image acquisition card is only one component of a complete machine vision system, but it plays a very important role. The image acquisition card directly determines the camera's interface: monochrome, color, analog, digital, etc.
Typical examples are PCI or AGP compatible capture cards, which can quickly transfer images to computer memory for processing. Some capture cards have built-in multiplexers. For example, they can connect up to eight different cameras and then tell the capture card which camera's footage to use. Some capture cards have built-in digital inputs to trigger capture; when the capture card takes an image, the digital output is activated, triggering a gate.
Visual processor
A vision processor integrates a capture card and a processor. In the past, when computers were slower, vision processors were used to speed up visual processing tasks. Now, because capture cards can quickly transfer images to memory, and computers are much faster, vision processors are used less frequently.
Application areas
The main applications of machine vision are in two areas: inspection and robot vision.
1. Inspection: can be further divided into high-precision quantitative inspection (such as cell classification in micrographs, measurement of the size and position of mechanical parts) and qualitative or semi-quantitative inspection without measuring instruments (such as product appearance inspection, component identification and positioning on assembly lines, defect detection and assembly completeness inspection).
2. Robot vision: Used to guide robot operations and actions over a large area, such as picking up workpieces from a jumbled pile of workpieces from a hopper and placing them in a specific orientation on a conveyor belt or other equipment (i.e., the hopper picking problem). For operations and actions within a small area, tactile sensing technology is still needed.
In addition, there are: (1) automated optical inspection (2) face detection (3) driverless cars
Features of machine vision
1. The camera's shooting speed is automatically matched with the speed of the object being measured to capture ideal images;
2. The dimensions of the parts range from 2.4mm to 12mm, and the thickness can vary;
3. The system selects workpieces of different sizes based on the operator's choice, calls the corresponding vision program to perform dimensional inspection, and outputs the results;
4. For parts of different sizes, the sorting and conveying devices can precisely adjust the width of the feed channel, allowing the parts to move along a fixed path and be visually inspected;
5. The machine vision system has a resolution of 1600×1200 and a dynamic detection accuracy of 0.02mm;
6. The rate of missed defective products is 0;
7. This system can monitor the detection process by displaying images, and can also dynamically view the detection results through the detection data displayed on the interface;
8. It has the function of issuing rejection control signals in a timely and accurate manner to reject defective workpieces and remove scrap products;
9. The system can self-check whether the status of its main equipment is normal, and is equipped with status indicator lights; it can also set different operation permissions for system maintenance personnel and users;
10. Real-time display of the inspection screen, Chinese interface, can browse images of the most recent defective products, and has the function of storing and viewing images of defective workpieces in real time;
11. It can generate error result information files, including corresponding error images, and print them out.
Application Examples
1. Machine Vision-Based Intelligent Integration Testing System for Instrument Panel Assemblies
The EQ140-II automotive instrument panel assembly is a product manufactured by a Chinese automotive company. The instrument panel includes a speedometer, odometer, coolant temperature gauge, fuel gauge, ammeter, and warning lights. Due to its large production volume, a final quality inspection is required before shipment. The inspection items include: checking the indicating error of five gauges (speedometer, etc.); and checking for damage or missing parts of 24 warning lights and several illumination lights. Traditionally, manual visual inspection is used, which is prone to errors and has poor reliability, failing to meet the needs of automated production. A machine vision-based intelligent integrated testing system has changed this situation, enabling intelligent, fully automated, high-precision, and rapid quality inspection of the instrument panel assembly. This overcomes the various errors caused by manual inspection and significantly improves inspection efficiency.
The entire system is divided into four parts: an integrated multi-channel standard signal source that provides analog signal sources for the instrument panel, a dual-coordinate CNC system with image information feedback positioning, a camera image acquisition system, and a master-slave parallel processing system.
2. Automatic surface flaw control system for metal plates
The surface quality of metal plates, such as the flat wires of large power transformer coils and radio casings, requires high precision. However, traditional methods of inspection using manual visual inspection or dial indicators with control styluses are not only susceptible to subjective factors but may also introduce new scratches into the surface. The automatic surface flaw detection system for metal plates utilizes machine vision technology to automatically inspect metal surface defects. It performs high-speed and accurate inspections during production, and because it uses non-angle measurement, it avoids the possibility of creating new scratches. Its working principle is shown in Figure 8-6. In this system, a laser is used as the light source. A pinhole filter removes stray light around the laser beam, and a beam expander and collimator make the laser beam parallel and uniformly illuminate the surface of the metal plate being inspected at a 45-degree incident angle. The metal plate is placed on an inspection table. The inspection table can move in the X, Y, and Z directions. The camera uses a TCD142D type 2048-line CCD, and the lens is a standard camera lens. The CCD interface circuit uses a microcontroller system. The host PC primarily performs image preprocessing and defect classification or scratch depth calculation, and can display the detected defect or scratch images on the monitor. The CCD interface circuit and the PC communicate bidirectionally via an RS-232 port, combined with asynchronous A/D conversion, forming an interactive data acquisition and processing system.
This system mainly utilizes the self-scanning characteristics of a linear CCD combined with the movement of the inspected steel plate in the X direction to obtain three-dimensional image information of the metal plate surface.
3. Vehicle body inspection system
The 100% online inspection of the body contour dimensions of the 800 series vehicles manufactured by ROVER in the UK is a typical example of machine vision systems used in industrial inspection. The system consists of 62 measurement units, each including a laser and a CCD camera, used to inspect 288 measurement points on the vehicle body shell. The car body is placed under the measurement frame, and its precise position is calibrated by software.
The calibration of the measurement units is crucial to the detection accuracy and is therefore given special attention. Each laser/camera unit is calibrated offline. Additionally, a calibration device calibrated offline using a coordinate measuring machine is available for online calibration of the camera top.
The inspection system checks one vehicle body every 40 seconds, covering three body types. The system compares the inspection results with acceptable dimensions drawn by a person from a CAD model, with a measurement accuracy of ±0.1mm. ROVER's quality control personnel use this system to determine the dimensional consistency of critical components, such as the overall body shape, doors, and windows. The system has proven successful and will be used for body inspection of other ROVER vehicles.
4. Banknote Printing Quality Inspection System: This system uses image processing technology to compare and analyze more than 20 features (numbers, Braille, color, patterns, etc.) of banknotes on the banknote production line to detect the quality of banknotes, replacing the traditional method of human visual identification.
5. Intelligent Traffic Management System: By placing cameras on major traffic arteries, when a vehicle violates traffic rules (such as running a red light), the camera captures the vehicle's license plate and transmits the image to the central management system. The system uses image processing technology to analyze the captured image, extract the license plate number, and store it in a database for management personnel to retrieve.
6. Metallographic Analysis: Metallographic image analysis systems can accurately and objectively analyze the matrix structure, impurity content, and composition of metals or other materials, providing a reliable basis for product quality.
7. Medical image analysis: automatic classification and counting of blood cells, chromosome analysis, cancer cell identification, etc.
8. Bottled beer production line inspection system: This system can detect whether the beer meets the standard volume and whether the beer label is intact.
9. Large Workpiece Parallelism and Perpendicularity Measuring Instrument: This instrument employs a laser scanning and CCD detection system to measure the parallelism and perpendicularity of large workpieces. It uses a stable collimated laser beam as the measurement baseline, coupled with a rotating axis system. A rotating pentagonal prism scans out mutually parallel or perpendicular reference planes, which are then compared with the surfaces of the large workpiece being measured. This instrument can be used to measure the parallelism and perpendicularity between surfaces during the machining or installation of large workpieces.
10. Detection device for the outline dimensions of rebar: A dynamic detection system that uses stroboscopic light as the illumination source and surface-mounted and line-mounted CCDs as detection devices for the outline dimensions of rebar, realizing online measurement of the geometric parameters of hot-rolled rebar.
11. Real-time bearing monitoring: Vision technology monitors bearing load and temperature changes in real time, eliminating the dangers of overload and overheating. This transforms the traditional passive measurement method of ensuring machining quality and safe operation by measuring the ball surface into active monitoring.
12. Measurement of cracks on metal surfaces: Using microwaves as a signal source, square waves with different wave frequencies are emitted by the microwave generator to measure cracks on the metal surface. The higher the frequency of the microwave wave, the narrower the crack that can be measured.