Ammonium sulfate particle defect detection method
By installing industrial-grade cameras and light sources on the ammonium sulfate production line, and combining image processing algorithms to automatically detect the size and color of ammonium sulfate particles, the problem of cumbersome and high cost of artificial quality inspection in the existing technology is solved, and efficient and automated detection results are achieved.
Patent Information
- Application Number
- CN202510503824.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-22
- Publication Date
- 2025-08-01
AI Technical Summary
In the existing ammonium sulfate production, the artificial quality inspection process is cumbersome and costly, making it difficult to efficiently detect ammonium sulfate particles with unqualified particle size and color.
An industrial-grade high-speed camera and high-precision rangefinder are used to combine light sources to collect and process images, and image segmentation is performed using U-Net model and watershed algorithm. Combined with intelligent threshold segmentation of light intensity compensation and dynamic light compensation, particle characteristics are calculated and unqualified particles are alarmed.
It realizes efficient and automated detection of ammonium sulfate particles, reduces manual intervention, reduces detection costs, and improves detection efficiency and accuracy.
Smart Images

Figure CN120411028A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of ammonium sulfate particles, and particularly relates to a method for detecting defects in ammonium sulfate particles. Background Art
[0002] Ammonium sulfate products include various physical appearances, including granules and powders. For ammonium sulfate granules, there are technical requirements for the shape and size of individual granules; being too large, too small, sticky, etc. all belong to defective products. If the proportion of defective ammonium sulfate granules within a unit weight is too high, it will affect the selling price of this batch of products.
[0003] The problems existing in the above technology are as follows: Currently, ammonium sulfate manufacturers mainly rely on manual quality inspection, with workers performing a series of processes such as sampling, sample delivery, screening, and weighing. Some manufacturers use machine vision to detect the size and color of granules; however, due to the dense stacking of granules on the production line, many granules are blocked and cannot be fully displayed. Therefore, it is necessary to sample the granules on the production line onto the detection platform, then take pictures for detection, and then use mechanical devices to discard the samples or send the samples back to the production line. After ensuring that the granules are sparse and unobstructed, visual detection is started. This process is rather cumbersome and will result in a large amount of costs being consumed on sampling equipment. Summary of the Invention
[0004] In view of the problems existing in the prior art, the present invention provides a method for detecting defects in ammonium sulfate particles that can overcome or at least partially solve the above problems.
[0005] The present invention is implemented as follows. A method for detecting defects in ammonium sulfate particles, the method comprising the following steps; S1. Image acquisition: Install an industrial-grade high-speed camera above the production line, and continuously capture clear pictures of the granules from a top-down perspective. Each time, m pictures are sampled, and the next set of sampling is carried out every n time intervals; to reduce the influence of shadows, 3 evenly distributed light sources are used, and recognition is performed by quickly taking 3 pictures under different light sources; at the same time, a high-precision rangefinder is used to measure the distance d between the granules and the camera, and the size of the granules in pixel units is converted into millimeters. S2. Send the sampled images to the message queue: Use the producer-consumer structure to organize sampling and detection. After each set of sampling, the images are sent to the message queue, and the detection service, as the consumer, detects each picture one by one; S3. Detect each picture of each set of samples: For each group of samples, perform detection on each image one by one. First, crop and retain the common area of 3 images; perform image sharpening and preliminary segmentation on the images to find the center coordinates of the particles, and discard the particles with incomplete edges; perform intelligent threshold segmentation with light intensity compensation and dynamic illumination compensation, calculate the shadow area of the particles, and discard the particles whose shadow area exceeds the threshold; calculate the characteristics of the particles such as size and color, discard the unqualified particles, and save the information to the database; S4. Calculate the detection results of each group of samplings: Calculate the average value of the detection results of each group of sampling images as the detection result of this group of samples; S5. Acoustic and optical alarm: When the unqualified rate of the size of a certain group of samples exceeds the threshold, the color is unqualified, and the uniformity is less than the threshold, an acoustic and optical alarm is given.
[0006] Preferably, in the present invention, the minimum diameter threshold is 2 mm and the maximum threshold is 4.7 mm. Particles exceeding the threshold are judged as unqualified particles.
[0007] Preferably, in the present invention, particles with a shadow area on the particle surface exceeding the threshold are discarded because such particles are occluded particles.
[0008] Compared with the prior art, the beneficial effects of the present invention are as follows: After image acquisition of ammonium sulfate particles, the present invention performs detection on each sample image one by one. By performing image sharpening and preliminary segmentation on the images, the center coordinates of the particles are found, the particles with incomplete edges are discarded, intelligent threshold segmentation with light intensity compensation and dynamic illumination compensation is performed, the shadow area of the particles is calculated, and the particles whose shadow area exceeds the threshold are discarded; the characteristics of the particles such as size and color are calculated, the unqualified particles are discarded, then the sampling results are calculated, and finally the unqualified materials are alarmed, solving the problems of cumbersome process and high cost in manual quality inspection in the prior art. Description of the Drawings
[0009] Figure 1 is a top view of the arrangement of the camera and the light source provided by an embodiment of the present invention; Figure 2 is a distribution histogram of the main axis and the sub-axis provided by an embodiment of the present invention; Figure 3 is a schematic diagram of marking the main axis and the sub-axis of ammonium sulfate particles after image recognition provided by an embodiment of the present invention; Figure 4 is a schematic diagram of comparing detection results provided by an embodiment of the present invention. Detailed Embodiments
[0010] To further understand the content, features and effects of the present invention, the following embodiments are exemplified and described in detail in conjunction with the drawings.
[0011] The structure of the present invention will be described in detail below with reference to the accompanying drawings.
[0012] As Figures 1 to 4 shown, a method for detecting defects in ammonium sulfate particles provided by an embodiment of the present invention includes the following steps; S1. Image acquisition: The industrial-grade high-speed camera is mounted on the production line at a top-down angle, and clear particle pictures are captured through a high-speed shutter. Each time, m consecutive samples are taken as a group of samples, and the next group of sampling starts after an interval of n time periods.
[0013] To accurately identify shadows, 3 light sources need to be deployed near the camera. The 3 light sources are evenly distributed with the camera as the center and an interval of 120°. During the identification process, the 3 light sources are lit successively, and the camera takes 3 consecutive pictures.
[0014] Since the particle size recognized by the model is in pixels, a high-precision rangefinder also needs to be installed near the camera to obtain the distance d between the particle and the camera at the moment of capture in real time. The number of millimeters per pixel in the image is calculated through the field of view angle of the lens and the distance d between the particle and the lens, so as to convert the pixel number of the particle size into millimeters; S2. Send the sampled images to the message queue: The producer-consumer structure is used to organize sampling and detection. After each group of sampling, the images are sent to the message queue, and the detection service, as the consumer, detects each image one by one; S3. Detect each image in each group of samples: 1. Since the conveyor belt continues to move during camera shooting, there will be differences in the 3 images. First, the 3 images are cropped, and the common area of the 3 images is extracted and retained. 2. Sharpen the image to make the particle edges clearer, preparing for instance segmentation later. 3. Use the U-Net model and the watershed algorithm to perform preliminary segmentation on the image and find the center coordinates of each particle.
[0015] 4. Discard the particles that are not fully displayed at the edge of the picture.
[0016] 5. Perform light intensity compensation in the HSV space and implement regionalized Gamma correction in the Value channel.
[0017] 6. Since the ambient light, particle batches, and light source brightness are inconsistent, an intelligent threshold segmentation method with dynamic light compensation is required. That is, for the 3 images, calculate the average brightness mean_value of each image, and calculate the threshold threshold for judging shadows according to the following formula threshold = max(^255 - mean_value / 10, 240^) 7. Determine the brightness value of each pixel in the image. If the value is less than the threshold, the pixel is considered to be in the shadow area.
[0018] 8. Calculate the shadow area of each particle, and then sum up the shadow areas of each particle in the three images as the surface shadow area of the particle.
[0019] 9. Discard the particles whose surface shadow area exceeds the threshold because such particles are occluded particles.
[0020] 10. Calculate the maximum diameter, minimum diameter, color mode, color mean, etc. of each segmented particle.
[0021] 11. The minimum diameter threshold is 2 mm and the maximum threshold is 4.7 mm. Particles exceeding the threshold are judged as unqualified particles.
[0022] 12. Record the unqualified rate of the size of each image.
[0023] 13. Compare the color information of the color card and the particle color information taken under the same light source. If the difference reaches the threshold, it is recorded as color unqualified.
[0024] 14. Save the above useful information of each image in the database; S4. Calculate the test results of each group of samples: Calculate the average value of the test results of each group of sampled images as the test result of this group of samples; S5. Acousto-optic alarm: When the unqualified rate of the size of a certain group of samples exceeds the threshold, the color is unqualified, and the uniformity is less than the threshold, an acousto-optic alarm is given.
[0025] Preferably, in the present invention, the minimum diameter threshold is 2 mm and the maximum threshold is 4.7 mm. Particles exceeding the threshold are judged as unqualified particles.
[0026] Preferably, in the present invention, discard the particles whose surface shadow area exceeds the threshold because such particles are occluded particles.
[0027] It should be noted that in this article, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the term "comprises", "comprising" or any other variation thereof is intended to cover a non-exclusive inclusion, such that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not expressly listed, or elements inherent to such process, method, article or device.
[0028] The above are only the preferred embodiments of the present invention, and do not impose any formal restrictions on the present invention. Although the present invention has been disclosed above with the preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art of this patent, within the scope of the technical solution of the present invention.
Claims
1. A method for detecting defects in ammonium sulfate particles, characterized in that: The method comprises the following steps; S1. Image acquisition: An industrial-grade high-speed camera is installed above the production line to continuously capture clear pictures of particles from a top-down perspective. Each sampling takes m pictures, and the next set of sampling is carried out every n time intervals. To reduce the influence of shadows, 3 evenly distributed light sources are used, and the images under 3 different light sources are recognized by taking 3 consecutive rapid shots. At the same time, a high-precision rangefinder is used to measure the distance d between the particle and the camera, and the particle size in pixel units is converted into millimeters; S2. Sending the sampled images to the message queue: The producer-consumer structure is used to organize sampling and detection. After each group of sampling, the images are sent to the message queue, and the detection service, as the consumer, detects each image one by one; S3. Detecting each image of each group of samples: Each image of each group of samples is detected. First, the common area of 3 images is cropped and retained; the image is sharpened and preliminarily segmented to find the center coordinates of the particles, and the particles with incomplete edges are discarded; intelligent threshold segmentation of light intensity compensation and dynamic light compensation is carried out to calculate the shadow area of the particles and discard the particles whose shadow area exceeds the threshold; the features such as the size and color of the particles are calculated, the unqualified particles are discarded, and the information is saved to the database; S4. Calculating the detection results of each group of sampling: The mean value of the detection results of each group of sampled images is calculated as the detection result of this group of samples; S5. Acousto-optic alarm: When the unqualified rate of the size of a certain group of samples exceeds the threshold, the color is unqualified, or the uniformity is less than the threshold, an acousto-optic alarm is given.
2. The ammonium sulfate particle defect detection method according to claim 1, characterized in that: The minimum diameter threshold is 2 mm, and the maximum threshold is 4.7 mm. The particles exceeding the threshold are judged as unqualified particles.
3. The ammonium sulfate particle defect detection method according to claim 1, characterized in that: The particles with the shadow area on the particle surface exceeding the threshold are discarded because such particles are occluded particles.
Citation Information
Patent Citations
Intelligent machine vision ore particle detection system
CN108062750A
Rapid detection method for ultralimit particles of irregular particle swarm based on machine vision
CN114863277A
Video frame synchronization method, terminal, server, electronic equipment and storage medium
CN115334322A
Particle detection method and system for sample image
CN117893478A
Data acquisition method, device and equipment and readable storage medium
CN118802644A