Single-grain product anomaly detection and rejection method and device
By combining visual inspection algorithms and rejection devices, efficient and accurate anomaly detection and rejection of single products are achieved, solving the problems of false rejection and missed detection caused by improper equipment sensitivity adjustment, and improving the quality stability and efficiency of the production line.
Patent Information
- Application Number
- CN202511778859.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-28
- Publication Date
- 2026-03-03
AI Technical Summary
Existing single-particle product testing equipment is prone to mistakenly rejecting normal particles or missing defective products when the sensitivity is not properly adjusted, resulting in low production efficiency and unstable product quality. Furthermore, it lacks intuitive observation of the testing status and parameter management.
By combining edge detection algorithm, contour extraction algorithm and grayscale gradient technology, along with template matching and defect classifier, images are acquired in real time and anomalies are verified based on features, and the rejector is controlled to remove defective products at appropriate times.
It improves the efficiency and accuracy of anomaly detection and rejection of single-piece products, provides precise data support, provides a basis for production process optimization and equipment performance improvement, and reduces the rate of false rejection and missed rejection.
Smart Images

Figure CN121589053A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present invention relate to the field of visual inspection technology, and in particular to a method and apparatus for detecting and rejecting anomalies in single-piece products. Background Technology
[0002] In the single-piece production process, single-piece machines are prone to various quality defects, including abnormal particle counts such as missing, half-piece, or extra pieces, as well as appearance contamination issues such as black spots and oil stains. If these defective products are not intercepted in time at the front end, they will continue to flow to subsequent production lines, not only increasing the operating costs of subsequent sorting and screening, but also significantly negatively impacting the overall quality stability of the final product and reducing the finished product qualification rate.
[0003] In the current single-grain machine production operation scenario, the equipment body is pre-installed with a set of dedicated detection photoelectric devices, which have a relatively simple function and can only identify defective products such as missing grains that occur in the production process.
[0004] In practical application, the operational stability of this photoelectric sensor is highly dependent on the adjustment of its sensitivity parameters. Under varying production environments (such as changes in ambient light and dust accumulation) and material characteristics (such as color variations and particle size differences), frequent and precise sensitivity calibration is necessary; otherwise, detection deviations are highly likely. Furthermore, the system lacks an intuitive visual management module, preventing operators from observing the sensor's detection status, sensitivity parameter values, and defective product identification trajectories in real time, making it difficult to quickly assess the equipment's operational condition.
[0005] The above factors directly lead to two core problems that frequently occur in actual production: On the one hand, when the sensitivity is adjusted too high, normal particles are easily misjudged as defective products, causing unnecessary false rejections, resulting in material waste and reduced production efficiency; on the other hand, when the sensitivity is adjusted too low or the parameters drift due to environmental interference, defective products with missing particles may not be identified, causing unqualified products to flow into subsequent processes, affecting the quality stability of the final product and posing a significant risk to production quality control. Summary of the Invention
[0006] This invention provides a method for detecting and rejecting anomalies in single-piece products, thereby improving the efficiency and accuracy of anomaly detection and rejection, and providing precise data support for quality improvement work such as production process optimization and equipment performance improvement. The method includes: Images of individual products at preset points on the production line are collected in real time at a preset frequency; the preset frequency is synchronized with the production frequency of the production equipment used to produce individual products. The image is used to extract features by employing one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques; the features include one or any combination of the size, shape, and spatial location of individual products. A template matching algorithm is used to verify the extracted features against the standard parameters of standard single-grain products, and the verification results are output. The verification results are used to identify abnormal single-grain products. Abnormal single-piece products are classified by using one or any combination of defect classifiers, dimensional measurement tools, and surface defect detection tools to determine the abnormality type of the abnormal single-piece products; The rejection time is determined based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality; the rejector corresponds to the type of abnormality; the rejection parameters of the rejector are determined by the type of abnormality and / or the characteristics of the abnormal single product. The rejector is controlled to remove abnormal single-piece products from the production line at the rejection time according to the rejection parameters.
[0007] Another aspect of the present invention provides a device for detecting and rejecting anomalies in single-piece products, which improves the efficiency and accuracy of detecting and rejecting anomalies in single-piece products, and provides accurate data support for quality improvement work such as production process optimization and equipment performance improvement. The device includes: The image acquisition module is used to acquire images of individual products at preset points in the production line in real time at a preset frequency; the preset frequency is synchronized with the production frequency of the production equipment used to produce individual products. The feature extraction module is used to extract features from an image using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques; the features include one or any combination of the size, shape, and spatial location of a single product. The verification module is used to verify the extracted features against the standard parameters of the standard single-grain product using a template matching algorithm, and outputs the verification results; the verification results are used to identify abnormal single-grain products. The classification module is used to classify abnormal single-piece products by employing one or any combination of defect classifiers, dimensional measurement tools, and surface defect detection tools, and to determine the abnormality type of the abnormal single-piece products. The rejection time determination module is used to determine the rejection time based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality; the rejector corresponds to the type of abnormality; the rejection parameters of the rejector are determined by the type of abnormality and / or the characteristics of the abnormal single product. The rejection module controls the rejector to remove abnormal single-piece products from the production line at the rejection time according to the rejection parameters.
[0008] This invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the above-described method for detecting and rejecting abnormal single-piece products.
[0009] This invention also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the above-described method for detecting and rejecting anomalies in single-piece products.
[0010] This invention also provides a computer program product, which includes a computer program that, when executed by a processor, implements the above-described method for detecting and rejecting anomalies in single-piece products.
[0011] Compared with existing technologies, this invention's embodiments involve real-time acquisition of images of individual products at preset locations on a production line at a preset frequency; the preset frequency is synchronized with the production frequency of the equipment used to produce individual products; feature extraction is performed on the images using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques; features include one or any combination of the size, shape, and spatial position of the individual product; a template matching algorithm is used to verify the extracted features against the standard parameters of a standard individual product, and the verification result is output; the verification result is used to identify abnormal individual products; and a defect classifier and a size measurement tool are used. Using one or any combination of surface defect detection tools, abnormal single-piece products are classified to determine their abnormality type. The rejection time is determined based on the image acquisition time, the distance between preset points and the rejection device, and the abnormality type. The rejection device corresponds to the abnormality type. The rejection parameters of the rejection device are determined by the abnormality type and / or the characteristics of the abnormal single-piece product. By controlling the rejection device to remove abnormal single-piece products from the production line at the rejection time according to the rejection parameters, the efficiency and accuracy of single-piece abnormality detection and rejection can be improved, providing precise data support for quality improvement work such as production process optimization and equipment performance improvement. Attached Figure Description
[0012] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort. In the drawings: Figure 1 This is a flowchart of the single-piece product anomaly detection and rejection method in an embodiment of the present invention; Figure 2This is a schematic diagram of the installation position of the highly uniform coaxial light source in an embodiment of the present invention; Figure 3 This is a schematic diagram of the single-piece product anomaly detection and rejection device in an embodiment of the present invention; Figure 4 This is a schematic diagram of a specific example of the single-piece product anomaly detection and rejection device in this invention. Figure 5 This is a schematic diagram of a computer device in an embodiment of the present invention. Detailed Implementation
[0013] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the embodiments of the present invention will be further described in detail below with reference to the accompanying drawings. Here, the illustrative embodiments of the present invention and their descriptions are used to explain the present invention, but are not intended to limit the present invention.
[0014] This invention provides a multi-dimensional detection system for common quality problems in the production of single-piece products. It accurately identifies particle morphology defects such as missing, half-piece, and multiple-piece defects, while also effectively capturing surface contamination defects such as black spots and oil stains. Based on the detection results, the equipment uses a customized rejection mechanism to classify and process abnormal single-piece products (defective products). Different types of non-conforming products are imported into dedicated storage containers, achieving zoned collection and standardized storage of defective products for convenient subsequent centralized disposal.
[0015] At the data management level, the equipment integrates a visual inspection data recording module, which can automatically classify and archive image information of various defective products according to defect type, and simultaneously statistically analyze core data such as the frequency and percentage of different defect states. This data traceability function provides intuitive evidence for tracing the source of faults and locating quality problems in the production process, while also providing precise data support for quality improvement work such as production process optimization and equipment performance improvement, helping to achieve closed-loop control of production quality.
[0016] In this embodiment of the invention, milk tablets are used as an example of single-piece products. Other than milk tablets, single-piece products can be other foods, medicines, decorative items, etc., which will not be elaborated upon here.
[0017] Figure 1 This is a flowchart of the single-piece product anomaly detection and rejection method in an embodiment of the present invention, as shown below. Figure 1 As shown, the method includes: Step 101: Collect images of individual products at preset points in the production line in real time at a preset frequency; the preset frequency is synchronized with the production frequency of the production equipment used to produce individual products. Step 102: Use one or any combination of edge detection algorithm, contour extraction algorithm and grayscale gradient technology to extract features from the image; the features include one or any combination of the size, shape and spatial position of the individual product. Step 103: Using a template matching algorithm, the extracted features are verified against the standard parameters of the standard single-grain product, and the verification results are output; the verification results are used to identify abnormal single-grain products. Step 104: Use one or any combination of a defect classifier, a dimensional measurement tool, and a surface defect detection tool to classify abnormal single-piece products and determine the abnormal type of the abnormal single-piece products. Step 105: Determine the rejection time based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality; the rejector corresponds to the type of abnormality; the rejection parameters of the rejector are determined by the type of abnormality and / or the characteristics of the abnormal single product. Step 106: Control the rejector to remove abnormal single-piece products from the production line at the rejection time according to the rejection parameters.
[0018] Compared with the technical solutions of the prior art, the embodiments of the present invention can improve the efficiency and accuracy of abnormal detection and rejection of single-piece products through the above steps, and provide accurate data support for quality improvement work such as production process optimization and equipment performance improvement.
[0019] In one embodiment, the present invention provides a single-piece product anomaly detection and rejection system for implementing the above-described method. The single-piece product anomaly detection and rejection system includes: an industrial vision inspection camera, a highly uniform coaxial light source, a main control system (including a human-machine interface), and a graded rejection collection slot, etc.
[0020] Among them, the industrial vision inspection camera is responsible for image acquisition and preliminary analysis, and uses a megapixel-level industrial lens to ensure inspection accuracy; the highly uniform coaxial light source can eliminate the interference of surface reflection of the tested object and ensure the stability of image grayscale values; the main control industrial control is used for parameter setting, data storage and equipment status monitoring; the graded rejection and collection slots are divided according to the defect type, which facilitates subsequent traceability and statistical analysis of defective products.
[0021] Industrial vision inspection camera mounting structure: A three-dimensional adjustable aluminum alloy bracket (profile specifications 57×76mm, load capacity ≥5kg) is used. The bracket base is fixed to the load-bearing crossbeam above the single-particle conveyor mechanism using two M8 expansion bolts and a custom base. The vertical distance between the mounting reference plane and the conveyor belt surface is 250mm±5mm (adjustable within a ±100mm range via the bracket's vertical adjustment slider). The industrial vision inspection camera body is fixed to the bracket crossbeam using quick-release sliders and corner brackets (gap ≤0.2mm). The lens optical axis is perpendicular to the conveyor belt's running direction at 90°. The horizontal deviation between the optical axis center and the center point of the inspection station is ≤0.5mm, ensuring the imaging area completely covers the maximum projection range of the material.
[0022] Figure 2 This is a schematic diagram of the installation position of the highly uniform coaxial light source in an embodiment of the present invention, as shown below. Figure 2 As shown, the high-uniformity coaxial light source is installed in a ring-shaped bracket (integrated with the camera bracket, with an adjustable spacing of 50-100mm), with the light source ring surface parallel to the lens end face. The light source cable is routed through the bracket's built-in cable tray, and its end connects to the controller's power interface via an aviation plug, preventing cable movement from interfering with the detection field of view.
[0023] Main control and industrial control system integration and installation: (1) Layout inside the electrical cabinet: The main control controller is fixed to the lower part of the electrical cabinet via a guide rail mounting bracket (≥100mm from the bottom of the cabinet and ≥200mm from the cabinet door). The distance between the controller and the inner wall of the electrical cabinet is ≥50mm to ensure heat dissipation and ventilation.
[0024] (2) Communication Link Connection: The communication between the industrial vision inspection camera and the PLC (Programmable Logic Controller) uses twisted-pair shielded cable, which is laid through the cable tray in the electrical cabinet. The two ends are respectively connected to the Ethernet interface (with anti-loosening clip) of the industrial vision inspection camera and the communication module of the PLC. The redundant length of the cable is ≤300mm to avoid signal transmission attenuation. The controller power cable and the communication cable are laid in separate trays to reduce electromagnetic interference.
[0025] Graded rejection and collection trough fixing method: The rejector is fixed to the mounting base on the side of the single-piece machine outlet. The connecting bolt hole adopts a waist-shaped groove design (adjustment range ±3mm) to facilitate fine adjustment of the rejection action direction. The graded rejection and collection trough corresponds to the rejector. The graded rejection and collection trough is divided into independent collection cavities according to the type of abnormality and is placed at the landing point after the rejector rejects the abnormal single-piece products.
[0026] In one embodiment, step 101, which involves acquiring images of individual products at preset points on the production line in real time at a preset frequency, may include: using a camera and a coaxial light source to acquire images of individual products at preset points on the production line in real time at a preset frequency; the camera's exposure parameters are adjusted according to a preset adaptive exposure algorithm based on the surface reflectivity of the individual products; and the uniformity of the coaxial light source is higher than a first preset threshold.
[0027] Once the upstream single-particle processing equipment (referred to as "single-particle machine") completes the loading and positioning of the object to be inspected (single-particle product), the main control unit sends a hardware trigger signal (usually a 24V level signal) to the industrial vision inspection camera. After the trigger signal is triggered, the industrial vision inspection camera starts a single image acquisition according to the preset exposure parameters (shutter speed, gain value). The acquisition process is strictly synchronized with the operating cycle of the single-particle machine to ensure that each object to be inspected can be accurately captured without any missed or incorrect shots.
[0028] The vision inspection unit is equipped with a monocular industrial vision inspection camera. The monocular industrial vision inspection camera starts a single precise image acquisition based on preset initial exposure parameters. The camera's exposure parameters adopt a preset adaptive exposure algorithm, which is adjusted according to the surface reflectivity of a single product. It acquires high-definition single-frame visual images of the products to be inspected on the production line in real time, ensuring that the image edge sharpness is not less than 300dpi.
[0029] The built-in algorithm processing unit integrates at least three differentiated machine vision algorithms, including edge contour extraction algorithm, gray-scale gradient difference algorithm (with dynamic threshold adjustment mechanism), and standard template matching algorithm. The algorithm processing unit performs pixel-by-pixel fine scanning processing on the acquired single-frame visual image to accurately extract features such as the size tolerance parameters (measurement accuracy ±0.01mm), appearance features (including surface flatness and contour integrity), and spatial position offset (detection accuracy ±0.02mm) of the product to be inspected.
[0030] In one embodiment, feature extraction of an image using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques may include: using an edge detection algorithm to determine preliminary edge information of a single product based on the image; using the contour tracking function in the contour extraction algorithm to construct a complete closed contour of the single product based on the preliminary edge information; calculating one or any combination of the projected area, perimeter, length and width of the minimum bounding rectangle, roundness, rectangularity, and aspect ratio of the single product based on the complete closed contour; calculating the grayscale gradient information of the image in the X and Y directions using an edge detection operator; determining the gradient maxima and / or centroid of the single product based on the grayscale gradient information; determining the gradient maxima and / or centroid of the single product as the spatial location features of the single product; determining one or any combination of the projected area, perimeter, and length and width of the minimum bounding rectangle as the size features of the single product; and determining one or any combination of the roundness, rectangularity, and aspect ratio of the single product as the morphological features of the single product.
[0031] In this embodiment, the challenge of high-precision feature extraction in complex backgrounds or for irregular objects is solved through algorithm combination and process optimization. First, the Canny edge detection algorithm is used to obtain preliminary edge information of the single-piece product. Based on this preliminary edge information, the contour tracking function in the contour extraction algorithm is used to construct the complete closed contour of the single-piece product. Finally, based on the complete closed contour, the projected area, perimeter, and length and width of the minimum bounding rectangle of the single-piece product are calculated as its size features, and its roundness, rectangularity, or aspect ratio are calculated as its morphological features. The Sobel or Scharr operator is used to calculate the gray-level gradient information of the image in the X and Y directions, respectively. Based on the gray-level gradient information, the gradient maxima or centroid of the single-piece product is located, and its pixel coordinates in the image coordinate system are used as its spatial position. Further, based on the gradient ratio in the X and Y directions, the principal axis direction of the single-piece product is calculated as its spatial pose feature.
[0032] In this embodiment, edges obtained by a single algorithm (such as edge detection alone) may be discontinuous, contain burrs, or be noisy, leading to large errors in subsequent size and shape measurements. This invention creatively combines the Canny algorithm (strong noise resistance, capable of generating fine edges) with contour tracing (connecting discrete edge points into a closed contour usable for geometric analysis). This is a specific process from "coarse localization" to "fine shaping." Through this combined process, a complete and clean simply connected region contour can be obtained, providing a solid foundation for subsequent accurate geometric calculations (such as area, perimeter, and circumscribed rectangle), significantly improving the measurement accuracy and robustness of size and shape features. Traditional centroid localization may be affected by uneven lighting or internal textures and cannot determine the object's orientation (such as the orientation of a pill or the deflection angle of a part). This invention not only uses grayscale gradients for edge detection but also deeply mines the directional information of gradient vectors. Gradient localization is utilized (more resistant to internal texture interference than simple centroid localization), and the principal axis direction of the object is creatively calculated through gradient field analysis. This achieves simultaneous and high-precision extraction of the object's spatial position and spatial orientation (i.e., orientation). This is crucial for automated sorting or assembly scenarios that require determining whether objects are placed correctly or whether orientation correction is needed, providing richer spatial information.
[0033] In one embodiment, when an image includes multiple individual products, feature extraction of the image is performed using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques. This may include: using an edge detection algorithm based on grayscale gradient information to determine the overall edge map of the individual products; extracting contours from the overall edge map to determine the outer contour of each individual product; determining the area and convex hull area within each outer contour; identifying outer contours that meet the following conditions as adherent contours: the area is greater than the standard area in the standard parameters, and / or the ratio of the area to the convex hull area is less than a second preset threshold; determining the distance transformation map inside the adherent contours and locating local maxima points in the distance transformation map; determining the local maxima points as potential seed points for each individual product; using a watershed algorithm or a region growing algorithm, segmenting the adherent contours into multiple independent individual product contours based on the potential seed points; and extracting size features, morphological features, and spatial location features for each individual product based on the multiple independent individual product contours.
[0034] This embodiment addresses a classic challenge in automated visual inspection: object adhesion or overlap, which hinders accurate individual item statistics and feature analysis. It creatively combines contour analysis (for identifying problem areas) with grayscale gradient analysis (for providing segmentation criteria). Utilizing the physical characteristic of lower gradient values within adhered regions, segmentation points are located. This is a cross-algorithm collaborative solution for a specific technical problem. It achieves effective separation of adhered items, thus ensuring the accuracy of feature extraction and the reliability of individual item counting even in complex scenarios.
[0035] In one embodiment, the features further include: dirt features; the single-product anomaly detection and rejection method may further include: using an edge detection algorithm and / or a contour extraction algorithm to perform single-product contour recognition on the image; using local contrast enhancement technology to perform local contrast enhancement processing on the image after single-product contour recognition; using gray-level gradient technology to calculate the gradient amplitude map of the image after local contrast enhancement processing; using the spot detection algorithm in the contour extraction algorithm to determine the dirt area and surrounding area in the image after local contrast enhancement processing; the surrounding area is the area other than the dirt area within the identified single-product contour; based on the gradient amplitude map, the dirt area and the surrounding area, determine the gray-level mean of the dirt area, the gray-level difference between the dirt area and the surrounding area, the aspect ratio of the dirt area, the roundness of the dirt area and the gradient edge intensity of the dirt area; and determine the gray-level mean of the dirt area, the gray-level difference between the dirt area and the surrounding area, the aspect ratio of the dirt area, the roundness of the dirt area and the gradient edge intensity of the dirt area as dirt features.
[0036] This embodiment addresses the challenge of reliably detecting minute surface defects with low contrast to the background while minimizing noise interference, all with high efficiency. It goes beyond simply "finding dark spots," ensuring that "real defect points" are found, rather than noise or normal texture. The extraction of features for black spots or oil stains on the surface of individual products includes: processing the image within the located contour area of the individual product using a local contrast enhancement technique to highlight potential defect areas. For the processed image, a gradient magnitude map is calculated using grayscale gradient technology, and simultaneously, a spot detection method from the contour extraction algorithm is used to find dark closed connected components in the image. For candidate regions identified by both the gradient magnitude map and spot detection, multidimensional features are extracted and filtered. These multidimensional features include: the grayscale difference between the average grayscale value of the contaminated area and the surrounding background area, the aspect ratio and roundness of the contaminated area, and the gradient edge strength of the contaminated area. The multidimensional features are compared with a preset black spot or oil stain defect model. Only when the features of a candidate region satisfy the defect model are they ultimately determined to be surface defects, and their location, size, and quantity are recorded as extracted features.
[0037] Direct thresholding or simple edge detection can mistakenly identify noise, dust, or normal product textures as defects, leading to a high false detection rate. Simultaneously, faint black spots or translucent oil stains may be missed due to low contrast. Dual-path collaborative detection combines gradient detection (sensitive to subtle grayscale changes) and spot detection (sensitive to closed dark areas) to complement each other and improve defect recall. Multi-dimensional feature filtering creatively introduces a multi-dimensional feature screening mechanism based on shape, grayscale, and gradient intensity—a crucial "false positive" step. It's no longer simply a matter of "if it looks like it, it's fine," but rather precise judgment through multiple quantitative indicators. Local enhancement first performs local contrast enhancement, specifically improving the signal-to-noise ratio of defect areas. While maintaining a high detection rate, it significantly reduces the false detection rate. It can intelligently distinguish between real defects and image noise or inherent product textures, making surface defect detection results stable and reliable, and directly applicable to automated sorting on production lines.
[0038] In one embodiment, a template matching algorithm is used to verify the extracted features against the standard parameters of a standard single-piece product, and the verification result is output. The extracted features are then subjected to multi-dimensional conformity verification against preset standard threshold parameters, ultimately outputting a binary verification result of "OK" (compliant with standards) or "NG" (non-compliant with standards). If the verification result is "OK", a no-feedback signal output state is maintained, and the product to be inspected automatically flows to the next processing stage along the preset production line, ensuring the continuity of the production process. If the verification result is "NG", the built-in algorithm processing unit will further accurately determine the specific defect type and level using multi-dimensional composite detection tools such as a defect classifier, dimensional measurement tools, and surface defect identification tools.
[0039] In one embodiment, the anomaly type includes one or any combination of missing grains, half grains, multiple grains, black spots, oil stains, dimensional deviations, and contour deformation.
[0040] In one embodiment, two related collaborative operations are executed simultaneously: First, an NG signal data packet containing anomaly type code, detection timestamp, product serial number, and detection station number is sent to the field PLC to ensure the integrity and traceability of the information carried by the signal; Second, the corresponding NG images are classified and marked according to anomaly type and level, and then transmitted to the server via industrial Ethernet. They are automatically stored in a hierarchical storage directory under the specified main control industrial control path. The NG image files are named in a standardized format of "product category-detection date-detection time-defect type code-serial number". At the same time, the corresponding detection parameters, feature data, and judgment criteria are automatically associated and stored, providing complete data support for subsequent quality traceability, defect cause analysis, and algorithm model optimization.
[0041] In one embodiment, determining the rejection time based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the rejection device, and the type of abnormality may include: determining the corresponding rejection device based on the type of abnormality; setting rejection parameters for the rejection device based on the type of abnormality and / or the characteristics of the abnormal single product; rejection parameters including airflow pressure parameters; characteristics including weight characteristics and / or size characteristics; determining the time required for the abnormal single product to travel from the preset point to the rejection device based on the distance between the preset point and the rejection device and the production line speed; and determining the rejection time based on the acquisition time and duration of the image of the abnormal single product.
[0042] In this embodiment, the rapid separation execution unit responds to the NG verification result and abnormality type information output by the built-in algorithm processing unit, and initiates the collaborative control process: First, after receiving the NG signal data packet sent by the built-in algorithm processing unit, the field PLC immediately executes the signal integrity verification process. The integrity and accuracy of the data packet are verified by the CRC (Cyclic redundancy check) algorithm, effectively avoiding signal loss and bit errors caused by electromagnetic interference and line loss during signal transmission. After the verification is passed, the PLC parses the data packet, extracts the defect type code, detection timestamp, and product position association information, and calls the pre-stored dedicated airflow sorting logic program (preset corresponding rejection channels, directional airflow push parameters, and trigger timing for different defect types). Second, based on the parsed product position association information and the real-time conveyor speed of the production line, the PLC dynamically calculates and adjusts the trigger delay parameter (adjustment range 0-50ms) to ensure that the trigger delay parameter is accurately matched with the production line movement position of the product to be tested, ensuring that the rejection action is synchronized with the actual position of the product, and avoiding erroneous rejection or missed rejection due to position deviation.
[0043] Subsequently, according to the rejection logic, a precise control signal containing trigger delay parameters and airflow pressure level parameters is output to the electromagnetically driven airflow sorting device of the corresponding channel. Furthermore, after receiving the control signal, the airflow sorting device starts the single-pulse airflow drive mode within a preset response time, and matches the airflow pressure parameters according to the differences in weight and volume attributes of the non-conforming products. The pressure adjustment range is locked at 0.3-0.6MPa to achieve adaptability separation of non-conforming products of different specifications.
[0044] In one embodiment, controlling the rejector to remove abnormal single-piece products from the production line at a rejection time according to rejection parameters may include: controlling the rejector to remove abnormal single-piece products from the production line to a receiving cavity corresponding to the type of abnormality at a rejection time according to airflow pressure parameters; the receiving cavity includes an elastic buffer protection structure; the elastic buffer protection structure uses a honeycomb buffer matrix to buffer the falling abnormal single-piece products.
[0045] In this embodiment, the rapid separation execution unit is equipped with a graded sorting and storage component. This component is divided into independent storage chambers according to the type of defect. Each independent chamber is equipped with an elastic buffer protection structure (protective layer thickness 5-8mm, Shore hardness 30-40HA). It adopts a honeycomb buffer matrix design to absorb the impact force of the product falling and avoid secondary damage to the defective products due to collision during the collection process. The total response time of the entire NG product separation process from the PLC receiving the signal to the completion of storage is strictly controlled within 100ms. Ultimately, it achieves directional sorting, graded storage and non-destructive collection of defective products, while achieving the control targets of low false rejection rate (≤0.1%) and low missed rejection rate (≤0.05%), ensuring efficient collaboration between production line detection and separation.
[0046] The following table shows a comparison between this solution and existing technical solutions: Table 1
[0047] This invention also provides a device for detecting and rejecting anomalies in single-piece products, as described in the following embodiments. Since the principle by which this device solves the problem is similar to that of the method for detecting and rejecting anomalies in single-piece products, the implementation of this device can refer to the implementation of the method for detecting and rejecting anomalies in single-piece products; repeated details will not be elaborated further.
[0048] Figure 3 This is a schematic diagram of the single-piece product anomaly detection and rejection device in an embodiment of the present invention, as shown below. Figure 3 As shown, the device includes: Image acquisition module 301 is used to acquire images of single-piece products at preset points in the production line in real time at a preset frequency; the preset frequency is synchronized with the production frequency of the production equipment used to produce the single-piece products. The feature extraction module 302 is used to extract features from the image using one or any combination of edge detection algorithm, contour extraction algorithm, and grayscale gradient technology; the features include one or any combination of the size, shape, and spatial position of the single product. The verification module 303 is used to use a template matching algorithm to verify the extracted features against the standard parameters of the standard single-grain product and output the verification result; the verification result is used to determine the abnormal single-grain product. The classification module 304 is used to classify the abnormal single-piece products by using one or any combination of a defect classifier, a size measurement tool, and a surface defect detection tool, and to determine the abnormal type of the abnormal single-piece products. The rejection time determination module 305 is used to determine the rejection time based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality; the rejector corresponds to the type of abnormality; the rejection parameters of the rejector are determined by the type of abnormality and / or the characteristics of the abnormal single product. The rejection module 306 is used to control the rejector to remove the abnormal single product from the production line at the rejection time according to the rejection parameters.
[0049] In one embodiment, the image acquisition module 301 is specifically used for: Using a camera and a coaxial light source, images of individual products at preset points on the production line are acquired in real time at a preset frequency; the camera's exposure parameters adopt a preset adaptive exposure algorithm and are adjusted according to the surface reflectivity of the individual products; the uniformity of the coaxial light source is higher than a first preset threshold.
[0050] In one embodiment, the feature extraction module 302 is specifically used for: An edge detection algorithm is used to determine the preliminary edge information of a single product based on the image; Based on the preliminary edge information, the contour tracking function in the contour extraction algorithm is used to construct the complete closed contour of a single product; Based on the complete closed contour, calculate one or any combination of the projected area, perimeter, length and width of the smallest bounding rectangle, circularity, rectangularity, and aspect ratio of a single product. The gray-level gradient information of the image in the X and Y directions is calculated using edge detection operators; Based on the gray-scale gradient information, determine the gradient maxima and / or centroid of a single product; The gradient maxima and / or centroid of a single product are determined as the spatial location features of the single product. The dimensional characteristics of a single product are determined by one or any combination of its projected area, perimeter, and the length and width of its smallest bounding rectangle. The morphological characteristics of a single product are determined by one or any combination of its roundness, rectangularity, and aspect ratio.
[0051] In one embodiment, the feature extraction module 302 is specifically used for: An edge detection algorithm based on grayscale gradient information is used to determine the overall edge map of a single product; The overall edge map is extracted to determine the external contour of each individual product; Determine the area within each outer contour and the area of the convex hull; An external contour that meets the following conditions is identified as an adhered contour: the area is greater than the standard area in the standard parameters, and / or the ratio of the area to the convex hull area is less than the second preset threshold. Determine the distance transformation map inside the adhesion contour, and locate the local maxima points in the distance transformation map; Local maxima are identified as potential seed points for each single grain product; Using the watershed algorithm or region growing algorithm, the adhesive contour is divided into multiple independent single-piece product contours based on potential seed points; Based on multiple independent single-piece product outlines, size features, morphological features, and spatial location features are extracted for each single-piece product.
[0052] In one embodiment, the feature further includes: a soiling feature; Figure 4 This is a schematic diagram of a specific example of the single-piece product anomaly detection and rejection device in this invention, as shown below. Figure 4 As shown, the single-piece product anomaly detection and rejection device may further include: a dirt feature extraction module 401, used for: Edge detection algorithms and / or contour extraction algorithms are used to identify the contours of single-piece products in the image; Local contrast enhancement technology is used to perform local contrast enhancement processing on the image after contour recognition of a single product. Using grayscale gradient technology, calculate the gradient magnitude map of the image after local contrast enhancement processing; Using the spot detection algorithm in the contour extraction algorithm, the dirty area and the surrounding area are identified in the image after local contrast enhancement processing; the surrounding area is the area other than the dirty area within the identified single product contour. Based on the gradient amplitude map, the dirty area and the surrounding area, determine the gray mean of the dirty area, the gray difference between the dirty area and the surrounding area, the aspect ratio of the dirty area, the circularity of the dirty area, and the gradient edge intensity of the dirty area. The grayscale mean of the dirty area, the grayscale difference between the dirty area and the surrounding area, the aspect ratio of the dirty area, the circularity of the dirty area, and the gradient edge intensity of the dirty area are defined as the dirty features.
[0053] In one embodiment, the anomaly type includes one or any combination of missing grains, half grains, multiple grains, black spots, oil stains, dimensional deviations, and contour deformation.
[0054] In one embodiment, the elimination time determination module 305 is specifically used for: Determine the corresponding rejector based on the anomaly type; Based on the type of abnormality and / or the characteristics of the abnormal single product, the rejection parameters of the rejector are determined; the rejection parameters include airflow pressure parameters; the characteristics include weight characteristics and / or size characteristics. Based on the distance between the preset point and the location of the rejector, as well as the production line speed, determine the time required for an abnormal single product to travel from the preset point to the location of the rejector. The rejection time is determined based on the acquisition time and duration of the image of the abnormal single product.
[0055] In one embodiment, the rejection module 306 is specifically used for: The rejector controls the airflow pressure parameters to remove abnormal single-piece products from the production line at the rejection time and place them into the receiving cavity corresponding to the abnormality type. The receiving cavity includes an elastic buffer protection structure. The elastic buffer protection structure uses a honeycomb buffer matrix to buffer the falling abnormal single-piece products.
[0056] Figure 5 This is a schematic diagram of a computer device in an embodiment of the present invention. Based on the foregoing inventive concept, as follows... Figure 5 As shown, the present invention also proposes a computer device 500, including a memory 501, a processor 502, and a computer program 503 stored in the memory 501 and executable on the processor 502. When the processor 502 executes the computer program 503, it implements the aforementioned method for detecting and rejecting abnormal single-piece products.
[0057] Based on the aforementioned inventive concept, the present invention proposes a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the aforementioned method for detecting and rejecting anomalies in single-piece products.
[0058] Based on the aforementioned inventive concept, the present invention proposes a computer program product, which includes a computer program that, when executed by a processor, implements a method for detecting and rejecting anomalies in single-piece products.
[0059] Compared with existing technologies, this invention's embodiments involve real-time acquisition of images of individual products at preset locations on a production line at a preset frequency; the preset frequency is synchronized with the production frequency of the equipment used to produce individual products; feature extraction is performed on the images using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques; features include one or any combination of the size, shape, and spatial position of the individual product; a template matching algorithm is used to verify the extracted features against the standard parameters of a standard individual product, and the verification result is output; the verification result is used to identify abnormal individual products; and a defect classifier and a size measurement tool are used. Using one or any combination of surface defect detection tools, abnormal single-piece products are classified to determine their abnormality type. The rejection time is determined based on the image acquisition time, the distance between preset points and the rejection device, and the abnormality type. The rejection device corresponds to the abnormality type. The rejection parameters of the rejection device are determined by the abnormality type and / or the characteristics of the abnormal single-piece product. By controlling the rejection device to remove abnormal single-piece products from the production line at the rejection time according to the rejection parameters, the efficiency and accuracy of single-piece abnormality detection and rejection can be improved, providing precise data support for quality improvement work such as production process optimization and equipment performance improvement.
[0060] The embodiments of the present invention have excellent core performance in the defective product detection and rejection process. The defective product detection accuracy rate can reach 99.9%, and 100% accurate rejection of identified defective products can be achieved. A solid quality defense line is built from the core production process, effectively preventing the vast majority of defective products from flowing into subsequent processes and the market.
[0061] For the remaining 0.1% of potentially defective products not automatically detected by the equipment, a supplementary quality inspection system covering the entire process has been established, specifically achieving precise control through the following multi-level methods: Manual sampling and re-inspection mechanism: A scientific sampling cycle and sample size standard are set, and professional quality inspectors conduct regular sampling inspections of the finished products produced by the equipment. Visual observation combined with specialized testing tools (such as precision calipers, microscopes, etc.) is used to focus on checking for minor defects that may be missed by the equipment, ensuring the quality and compliance of the sampled products.
[0062] The final inspection stage serves as a supplement: a dedicated full inspection station is set up at the end of the single-granulator production line, where quality inspectors manually re-inspect all finished products one by one. This stage can specifically identify defective products that were missed due to special operating conditions (such as sudden abnormalities in the instantaneous shape of materials, sudden changes in ambient light, etc.), thus achieving the final control over product quality.
[0063] Data traceability and post-mortem optimization: Utilizing the production data recording system onboard the equipment, complete records are kept of production parameters, equipment operating status, and defective product detection data for each batch of products. When missed defective products are discovered during manual re-inspection, the root cause of the problem can be traced back based on the traceability data. Simultaneously, equipment detection parameters (such as photoelectric eye sensitivity and visual inspection algorithm thresholds) can be adjusted to continuously optimize the equipment's automatic detection capabilities and gradually reduce the probability of missed detections.
[0064] By combining "core equipment testing + multi-level manual supplementary inspection + data-driven optimization", a closed loop of quality control is formed throughout the entire process, achieving comprehensive and thorough control over defective products and maximizing product quality stability.
[0065] The hardware system of this invention consists of a megapixel global area array industrial camera (equipped with a 16mm fixed-focus lens), a high color rendering LED (light-emitting diode) ring light source, and a sorting and rejection collection slot. The components achieve real-time data interaction through industrial Ethernet (Profinet protocol).
[0066] 1. Triggering the synchronization and image acquisition process: When the single-particle machine completes material feeding and conveys the material to the inspection station via a servo-driven conveyor mechanism, its built-in encoder sends a differential signal trigger pulse (pulse width 50μs±10μs) to the vision camera. After receiving the trigger signal, the camera starts image acquisition based on a preset adaptive exposure algorithm (exposure time adjustable, dynamically corrected according to the reflectivity of the material surface). The acquisition time is strictly synchronized with the static dwell window of the material at the inspection station to ensure that the image is free of motion blur, the image resolution is stable at 1920×1080 pixels, and the grayscale deviation is ≤5%.
[0067] 2. Visual inspection and feedback logic: After the camera acquires images, the materials are detected using a multi-feature fusion algorithm (including feature matching, gray-level co-occurrence matrix analysis, etc.). The detection dimensions cover: Geometric parameters (diameter / length, measurement accuracy ±0.02mm), appearance defects, integrity (particle missing threshold: material projected area missing ≥N%, N value can be set).
[0068] The rules for determining test results are as follows: If all parameters are within the preset tolerance range (OK state), no feedback signal is output, and the material enters the next process with the conveyor mechanism; If the condition is determined to be NG, the algorithm automatically classifies the defect type (such as "missing grain", "half grain", "multiple grains", etc., with a classification accuracy of ≥99.5%) and sends a digital signal to the PLC. At the same time, the NG image storage mechanism is triggered. The image is named with "line number + defect type + detection time", and the storage path is archived according to the line number and defect type, supporting local query.
[0069] 3. PLC signal processing and rejection execution (including dynamic correction): After receiving the NG signal, the PLC first performs signal redundancy verification to avoid false triggering. Then, it calls the corresponding rejection timing parameters according to the defect type code (e.g., for the "missing grain" type, the rejection delay is set to the first rejection and collection hopper; for the "half grain" type, the delay is set to the second rejection and collection hopper. The specific rejection delay value can be corrected online through the HMI interface).
[0070] If the material position shifts due to vibration in the conveying mechanism, the algorithm corrects it through real-time position compensation; After rejection is completed, the photoelectric sensor built into the storage slot sends a position signal, and the PLC records the rejection result (success / failure) and uploads it to the main controller, forming a closed-loop data chain.
[0071] Through the above design, the entire process from triggering synchronization and high-precision detection to dynamic elimination is controllable. Furthermore, the uniqueness of the technical solution is effectively enhanced by the detailed differentiation of algorithm models, parameter thresholds, and execution mechanisms.
[0072] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0073] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1A device that provides the functions specified in one or more boxes.
[0074] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0075] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0076] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above descriptions are merely specific embodiments of the present invention and are not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for detecting and rejecting abnormalities in single-grain products, characterized in that, include: Images of individual products at preset points on the production line are collected in real time at a preset frequency. The preset frequency is synchronized with the production frequency of the production equipment used to produce the single-grain product. The image is used to extract features by employing one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques; the features include one or any combination of the size, shape, and spatial position of the single product. A template matching algorithm is used to verify the extracted features against the standard parameters of a standard single-grain product, and the verification result is output; the verification result is used to identify abnormal single-grain products. The abnormal single-piece products are classified by using one or any combination of defect classifiers, dimensional measuring tools, and surface defect detection tools to determine the abnormal type of the abnormal single-piece products; The rejection time is determined based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality; the rejector corresponds to the type of abnormality; the rejection parameters of the rejector are determined by the type of abnormality and / or the characteristics of the abnormal single product. The rejector is controlled to remove the abnormal single-piece product from the production line at the rejection time according to the rejection parameters.
2. The method as described in claim 1, characterized in that, Images of individual products at preset points on the production line are acquired in real time at a preset frequency, including: Using a camera and a coaxial light source, images of individual products at preset points on the production line are acquired in real time at a preset frequency; the exposure parameters of the camera adopt a preset adaptive exposure algorithm and are adjusted according to the surface reflectivity of the individual product; the uniformity of the coaxial light source is higher than a first preset threshold.
3. The method as described in claim 1, characterized in that, Feature extraction of the image is performed using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques, including: An edge detection algorithm is used to determine the preliminary edge information of the single product based on the image; Based on the preliminary edge information, the contour tracking function in the contour extraction algorithm is used to construct the complete closed contour of the single product; Based on the complete closed contour, calculate one or any combination of the projected area, perimeter, length and width of the minimum bounding rectangle, circularity, rectangularity, and aspect ratio of the single-piece product. The gray-level gradient information of the image in the X and Y directions is calculated using an edge detection operator; Based on the grayscale gradient information, determine the gradient maxima and / or centroid of the single-grain product; The gradient maxima and / or centroid of the single-grain product are determined as the spatial positional features of the single-grain product. The projected area, perimeter, and length and width of the minimum bounding rectangle of the single-grain product, or any combination thereof, are determined as the dimensional characteristics of the single-grain product. The morphological characteristics of the single-grain product are determined by one or any combination of the roundness, rectangularity, and aspect ratio.
4. The method as described in claim 1, characterized in that, When the image includes multiple single-piece products, feature extraction is performed on the image using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques, including: An edge detection algorithm based on grayscale gradient information is used to determine the overall edge map of the single product; The overall edge map is used to extract the contour, and the external contour of each individual product is determined. Determine the area within each outer contour and the area of the convex hull; An external contour that meets the following conditions is determined to be an adhesive contour: the area is greater than the standard area in the standard parameters, and / or the ratio of the area to the convex hull area is less than a second preset threshold. Determine the distance transformation map inside the adhesion contour, and locate the local maxima points in the distance transformation map; The local maxima are identified as potential seed points for each single-grain product; Using a watershed algorithm or a region growing algorithm, the adhesion contour is divided into multiple independent single-piece product contours based on the potential seed points; Based on the multiple independent single-piece product outlines, size features, morphological features, and spatial location features are extracted for each single-piece product.
5. The method as described in claim 1, characterized in that, The features also include: dirt and grime features; The method further includes: The image is used to perform single-piece product contour recognition by employing edge detection algorithms and / or contour extraction algorithms; Local contrast enhancement technology is used to perform local contrast enhancement processing on the image after contour recognition of a single product. Using grayscale gradient technology, calculate the gradient magnitude map of the image after local contrast enhancement processing; Using the spot detection algorithm in the contour extraction algorithm, the dirty area and the surrounding area are determined in the image after local contrast enhancement processing; the surrounding area is the area other than the dirty area within the contour of the identified single product. Based on the gradient amplitude map, the dirty area and the surrounding area, determine the gray average value of the dirty area, the gray difference between the dirty area and the surrounding area, the aspect ratio of the dirty area, the roundness of the dirty area and the gradient edge intensity of the dirty area. The grayscale mean of the dirty area, the grayscale difference between the dirty area and the surrounding area, the aspect ratio of the dirty area, the circularity of the dirty area, and the gradient edge intensity of the dirty area are defined as the dirty features.
6. The method as described in claim 1, characterized in that, The abnormality types include one or any combination of missing grains, half grains, multiple grains, black spots, oil stains, dimensional deviations, and contour deformation.
7. The method as described in claim 1, characterized in that, The rejection time is determined based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality, including: Based on the type of anomaly, determine the corresponding rejector; The rejection parameters of the rejector are determined based on the type of abnormality and / or the characteristics of the abnormal single product; the rejection parameters include airflow pressure parameters; the characteristics include weight characteristics and / or size characteristics. Based on the distance between the preset point and the location of the rejector and the production line speed, determine the time required for the abnormal single product to travel from the preset point to the location of the rejector. The rejection time is determined based on the acquisition time of the image of the abnormal single product and the duration thereof.
8. The method as described in claim 7, characterized in that, Controlling the rejector to remove the abnormal single-piece product from the production line at the rejection time according to the rejection parameters includes: The rejector is controlled to remove the abnormal single product from the production line and place it into the receiving cavity corresponding to the abnormality type at the rejection time according to the airflow pressure parameters; the receiving cavity includes an elastic buffer protection structure; the elastic buffer protection structure uses a honeycomb buffer matrix to buffer the falling abnormal single product.
9. A device for detecting and rejecting abnormal single-grain products, characterized in that, include: The image acquisition module is used to acquire images of individual products at preset points in the production line in real time at a preset frequency; The preset frequency is synchronized with the production frequency of the production equipment used to produce the single-grain product. The feature extraction module is used to extract features from the image using one or any combination of edge detection algorithms, contour extraction algorithms, and grayscale gradient techniques; the features include one or any combination of the size, shape, and spatial position of the single product. The verification module is used to use a template matching algorithm to verify the extracted features against the standard parameters of a standard single-grain product and output the verification result; the verification result is used to identify abnormal single-grain products. The classification module is used to classify the abnormal single-piece products by using one or any combination of a defect classifier, a dimensional measurement tool, and a surface defect detection tool, and to determine the abnormal type of the abnormal single-piece products. The rejection time determination module is used to determine the rejection time based on the acquisition time of the image of the abnormal single product, the distance between the preset point and the location of the rejector, and the type of abnormality; the rejector corresponds to the type of abnormality; the rejection parameters of the rejector are determined by the type of abnormality and / or the characteristics of the abnormal single product. The rejection module is used to control the rejector to remove the abnormal single product from the production line at the rejection time according to the rejection parameters.
10. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the method of any one of claims 1 to 8.
11. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method of any one of claims 1 to 8.
12. A computer program product, characterized in that, The computer program product includes a computer program that, when executed by a processor, implements the method of any one of claims 1 to 8.