Particle distribution detection method and device based on particle density
By estimating particle density and adaptively adjusting cutting parameters through a deep learning image segmentation model, combined with global coordinate system transformation and deduplication algorithms, the problem of balancing particle detection accuracy and efficiency in existing technologies is solved, and efficient and accurate particle distribution detection is achieved.
Patent Information
- Application Number
- CN202510721987.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-30
- Publication Date
- 2025-09-12
AI Technical Summary
When processing large-size, high-density particle images, existing technologies have difficulty balancing detection accuracy and computational efficiency. The fixed overlapping cutting method leads to a high particle missed detection rate, serious waste of computing resources, and insufficient adaptability.
Particle density is estimated through a pre-trained deep learning image segmentation model, image segmentation parameters are adaptively adjusted, and the image segmentation method is optimized by combining global coordinate system transformation and deduplication algorithms to reduce missed particle detections and improve detection efficiency.
It realizes the dynamic adjustment of cutting parameters according to particle density, improves the accuracy and efficiency of particle distribution detection, and is suitable for real-time processing of high-resolution images.
Smart Images

Figure CN120635005A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical fields related to image processing and computer vision, and in particular to a particle distribution detection method and device based on particle density. Background Art
[0002] In industries such as mining and building materials, real-time monitoring of rock particle size distribution is crucial for optimizing crushing processes and ensuring product quality. Traditional manual screening or mechanical measurement methods are inefficient and difficult to monitor dynamically. Computer vision technology based on high-resolution images is becoming a mainstream solution. However, existing technologies still struggle to balance detection accuracy and computational efficiency when processing large, high-density particle images.
[0003] In existing technologies, particle detection mainly uses a fixed overlapping cutting method, which divides a large image into blocks with fixed overlapping areas and then detects them one by one to reduce the missed detection of boundary particles. However, because the existing method does not consider the impact of particle density distribution on cutting parameters, it has the following disadvantages:
[0004] On the one hand, the particle missed detection rate is high. In the fixed overlap cutting method, the size of the overlap area is independent of the particle density. When the particles are dense or large, the fixed overlap area cannot completely cover the particle boundaries, resulting in some particles being incorrectly segmented and missed.
[0005] On the other hand, computing resources are wasted seriously. When the particles are sparsely distributed, a large fixed overlapping area will generate a lot of redundant calculations, reducing detection efficiency.
[0006] On the other hand, the existing methods are not adaptable enough. They cannot dynamically adjust cutting parameters according to the particle distribution characteristics, resulting in large fluctuations in detection accuracy in different scenarios.
[0007] Therefore, in this context, how to provide a particle distribution detection method that can adaptively adjust image cutting parameters according to particle density while taking into account both detection accuracy and computational efficiency is a technical problem that needs to be solved. Summary of the Invention
[0008] In view of the above problems in the prior art, the present application provides a particle distribution detection method and device based on particle density, so as to provide a particle distribution detection method that can adaptively adjust image cutting parameters according to particle density while taking into account both detection accuracy and computational efficiency.
[0009] To achieve the above objectives, the present application provides, in a first aspect, a particle distribution detection method based on particle density, comprising:
[0010] acquiring a first image comprising a distribution of a plurality of macroscopic rock particles;
[0011] estimating the particle density of the macroscopic rock particles in the first image using a pre-trained deep learning image segmentation model;
[0012] Cutting the first image into a plurality of second images according to a cutting step length, wherein the cutting step length is determined by an overlap value and a size of the second image; wherein the overlap value is the width of an overlapping region of left and right adjacent second images or the height of an overlapping region of top and bottom adjacent second images, and is calculated based on the estimated particle density;
[0013] Performing target detection on the second image to obtain bounding box and mask information of the macro rock particles; and converting the bounding box and mask information into a global coordinate system;
[0014] Repeated detection results across multiple second images are removed using a deduplication algorithm to generate final particle distribution data.
[0015] As mentioned above, a preliminary estimate is made through deep learning images, which improves the efficiency of detection with a smaller time and resource cost. By adaptively adjusting the cutting parameters based on the particle density, the problem of missed particle detection existing in the traditional fixed overlapping cutting method is solved. The integrity and accuracy of the detection results are ensured through global coordinate system conversion and deduplication algorithm. The overall solution takes into account both detection accuracy and computational efficiency and can be used for real-time processing of high-resolution images.
[0016] As a possible implementation of the first aspect, the overlap value is calculated based on the estimated particle density, specifically:
[0017] The overlap value is calculated by the following correlation relationship, including:
[0018] The overlap value is linearly positively correlated with the particle density;
[0019] Alternatively, the overlap value is linearly positively correlated with the product of the particle density and the size of the second image.
[0020] As described above, by providing two linear positive correlations, it is ensured that when the area of the second image is larger and the particle density is greater, the overlap value is correspondingly larger, thereby reducing the cutting step size and providing a finer-grained image cutting result.
[0021] As a possible implementation of the first aspect, the overlap value has an upper limit and a lower limit. When the calculated overlap value exceeds the upper limit, the overlap value is set to the upper limit; when the calculated overlap value is lower than the lower limit, the overlap value is set to the lower limit.
[0022] From the above, by setting the upper and lower limits, the rationality and stability of the image cutting size are guaranteed.
[0023] As a possible implementation of the first aspect, the cutting step size is calculated according to the following formula:
[0024] Step y =PatchHeight-Overlap
[0025] Step x =PatchWeight-Overlap
[0026] Among them, Step x ,Step y are the cutting steps in the x and y directions respectively, PatchHeight and PatchWeight are the height and width of the second image respectively, and Overlap is the overlap value.
[0027] As described above, by introducing the overlap value obtained according to the particle density to limit the cutting step, it is ensured that the cutting result has an adaptive effect.
[0028] As a possible implementation of the first aspect, the particle distribution data includes at least one of the following: a bounding box, mask information, an equivalent diameter of each particle, and statistical data of the equivalent diameter; wherein the particle equivalent diameter is calculated based on the mask area of the particle.
[0029] From the above, it is ensured that the final particle distribution data can provide a comprehensive and quantitative description of the particle characteristics, providing data support for subsequent process adjustments and quality control.
[0030] A second aspect of the present application provides a particle distribution detection method based on particle density, which is applied to the detection of rock particle distribution transported on an industrial conveyor belt, comprising:
[0031] Acquiring a first image including the distribution of a plurality of macro rock particles by an industrial camera mounted above the conveyor belt;
[0032] estimating the particle density of the macroscopic rock particles in the first image using a pre-trained deep learning image segmentation model;
[0033] Cutting the first image into a plurality of second images according to a cutting step length, wherein the cutting step length is determined by an overlap value and a size of the second image; wherein the overlap value is the width of an overlapping region of left and right adjacent second images or the height of an overlapping region of top and bottom adjacent second images, and is calculated based on the estimated particle density;
[0034] Performing target detection on the second image to obtain bounding box and mask information of the macro rock particles; and converting the bounding box and mask information into a global coordinate system;
[0035] removing repeated detection results across a plurality of the second images by a deduplication algorithm to generate final particle distribution data;
[0036] The particle distribution data is returned to the programmable logic system host through the communication device, and the programmable logic system host adjusts the feeding device parameters according to the particle distribution data.
[0037] As described above, the above-mentioned image segmentation method based on particle density can realize on-site detection of rock particle distribution in industrial sites, thereby improving the automation level and quality control capability of the production process.
[0038] A third aspect of the present application provides a particle distribution detection device based on particle density, comprising:
[0039] a data acquisition module for acquiring a first image including a distribution of a plurality of macro rock particles;
[0040] an image segmentation module for estimating the particle density of the macroscopic rock particles in the first image using a pre-trained deep learning image segmentation model; cutting the first image into a plurality of second images according to a cutting step length, wherein the cutting step length is determined by an overlap value and the size of the second images; wherein the overlap value is the width of the overlapping area of the second images adjacent to the left and right, or the height of the overlapping area of the second images adjacent to the top and bottom, calculated based on the estimated particle density;
[0041] An image processing module is used to perform target detection on the second image to obtain the bounding box and mask information of the macro rock particles; and convert the bounding box and mask information into a global coordinate system; remove duplicate detection results across multiple second images through a deduplication algorithm to generate final particle distribution data.
[0042] The fourth aspect of the present application provides a computing device, comprising: a processor, and a memory on which program instructions are stored, and when the program instructions are executed by the processor, the processor executes the particle distribution detection method based on particle density described in any one of the first aspect, or the particle distribution detection method based on particle density described in the second aspect.
[0043] In a fifth aspect, the present application provides a computer-readable storage medium having program instructions stored thereon. When the program instructions are executed by a computer, the computer executes the particle distribution detection method based on particle density described in any one of the first aspect, or the particle distribution detection method based on particle density described in the second aspect. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1is a flow chart of a particle distribution detection method based on particle density provided in the first embodiment of the present application;
[0045] Figure 2a is a flow chart of a particle distribution detection method based on particle density provided in the second embodiment of the present application;
[0046] Figure 2b This is a schematic diagram of the on-site setup for particle distribution detection provided in the second embodiment of the present application;
[0047] Figure 3 is a schematic diagram of a particle distribution detection device based on particle density provided in an embodiment of the present application;
[0048] Figure 4 It is a structural schematic diagram of a computing device provided in an embodiment of the present application.
[0049] It should be understood that the sizes and shapes of the blocks in the above structural diagrams are for reference only and should not constitute an exclusive interpretation of the embodiments of the present invention. The relative positions and inclusion relationships between the blocks presented in the structural diagrams are merely schematic representations of the structural relationships between the blocks and do not limit the physical connection methods of the embodiments of the present invention. DETAILED DESCRIPTION
[0050] The technical solution provided by this application is further described below with reference to the accompanying drawings and examples. It should be understood that the system structure and business scenarios provided in the examples of this application are mainly for illustrating possible implementation methods of the technical solution of this application and should not be interpreted as the sole limitation of the technical solution of this application. It is known to those skilled in the art that with the evolution of the system structure and the emergence of new business scenarios, the technical solution provided by this application is also applicable to similar technical problems.
[0051] It should be understood that the particle density-based particle distribution detection solutions provided in the embodiments of this application include particle density-based particle distribution detection methods, apparatuses, computing devices, and readable storage media. Because these technical solutions solve the same or similar problems, some repetitions may not be repeated in the following descriptions of the specific embodiments. However, these specific embodiments should be considered as cross-references and can be combined with each other.
[0052] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. In the event of any inconsistency, the meanings described in this specification or the meanings derived from the contents recorded in this specification shall prevail. In addition, the terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application. In order to accurately describe the technical content in this application and to accurately understand the present invention, the following explanations or definitions are given for the terms used in this specification before describing the specific embodiments:
[0053] 1) Deep Learning-based Image Segmentation Models: These are computer vision technologies that use deep neural networks to achieve pixel-level image segmentation. Typical models include U-Net (commonly used for medical image segmentation), Mask R-CNN (an instance segmentation model), and YOLOv8-Seg (a segmentation version of YOLOv8). These models, using architectures such as convolutional neural networks (CNNs) or visual transformers (ViTs), can output precise object masks and boundary information, achieving higher accuracy and robustness than traditional methods.
[0054] 2) Non-Maximum Suppression (NMS): This is a post-processing algorithm for object detection, primarily used to eliminate redundant detection boxes. Its principle is to first sort all candidate boxes by confidence, retain the highest-scoring box, and calculate its intersection over union (IoU) with other boxes. If the IoU exceeds a set threshold, the low-scoring box is removed. This process is repeated until all candidate boxes have been processed. NMS effectively addresses the problem of multiple detections of the same object and is widely used in algorithms such as YOLO and Faster R-CNN.
[0055] The particle distribution detection solution based on particle density provided in the embodiment of the present application is achieved by obtaining a first image containing the distribution of multiple macro rock particles; using a pre-trained deep learning image segmentation model to estimate the particle density of the macro rock particles in the first image, and thereby obtain cutting compensation; cutting the first image into multiple smaller second images; performing target detection on the second image to obtain the bounding box and mask information of the macro rock particles; and converting the bounding box and mask information to a global coordinate system; finally, removing the repeated detection results across multiple second images through a deduplication algorithm to generate the final particle distribution data. The embodiment of the present application can be applied to the image segmentation and detection of rock particle distribution in various industrial and scientific research fields, and is also applicable to the image segmentation and detection of other similar particle distributions. The embodiments of the present application are described in detail below with reference to the accompanying drawings.
[0056] The first embodiment of the present application provides a particle distribution detection method based on particle density. Figure 1 , specifically describing the implementation of each step of the method, including steps S10-S50.
[0057] S10: Acquire a first image containing the distribution of multiple macro rock particles.
[0058] In some embodiments, a first image containing the distribution of multiple macro rock particles is obtained by an industrial camera mounted above the conveyor belt; the industrial camera can also be a high-resolution imaging device. The image is usually high-resolution and contains multiple particle targets. To ensure image quality, the camera focus and lighting conditions need to be calibrated during the acquisition process to avoid overexposure or shadows interfering with the extraction of particle features. The acquired image is denoted as I(x,y), where x and y are pixel coordinates, ranging from 0≤x <Width,0≤y<Height。
[0059] In some embodiments, the method described in the embodiments of the present application is used to perform real-time particle distribution detection on the macro rock particles continuously transported on the conveyor belt.
[0060] In some embodiments, the captured first image is pre-processed, including overexposure correction, underexposure compensation, deblurring, etc.
[0061] S20: Estimate the particle density of the macro rock particles in the first image using a pre-trained deep learning image segmentation model.
[0062] In some embodiments, the deep learning image segmentation model can use existing models such as YOLOv8s, Mask R-CNN, U-Net, or a self-trained deep learning image segmentation model. Taking YOLOv8s as an example, when estimating the first image, the confidence threshold can be set to 0.3 and the maximum number of detected targets can be set to 100,000; then the particle density can be calculated using the following formula:
[0063]
[0064] Wherein, N represents the number of detected particles, Width and Height represent the width and height of the first image.
[0065] S30: Cut the first image into multiple second images according to a cutting step, where the cutting step is determined by an overlap value and a size of the second image; wherein the overlap value is the width of an overlap area of the second images adjacent to the left and right or the height of an overlap area of the second images adjacent to the top and bottom, and is calculated based on the estimated particle density.
[0066] In some embodiments, the overlap value is calculated based on the estimated particle density, specifically:
[0067] The overlap value is calculated by the following correlation relationship, including:
[0068] The overlap value is linearly positively correlated with the particle density;
[0069] Alternatively, the overlap value is linearly positively correlated with the product of the particle density and the size of the second image.
[0070] In some embodiments, the overlap value may be non-linearly related to the particle density.
[0071] In some embodiments, the overlap value has an upper limit and a lower limit. When the calculated overlap value exceeds the upper limit, the overlap value is set to the upper limit; when the calculated overlap value is lower than the lower limit, the overlap value is set to the lower limit. The upper and lower limits ensure that the overlap value is within a reasonable range, avoiding missed detection due to a too small value or increased computational burden due to a too large value.
[0072] In some embodiments, the overlap value can be calculated using the following formula:
[0073] Overlap=max(MinOverlap,min(MaxOverlap,k×Density×S))
[0074] Where MinOverlap is the set lower limit of the overlap value, MaxOverlap is the set upper limit of the overlap value, k is the proportional coefficient used to adjust the increasing speed of the overlap value with the particle density and the second image area; Density is the particle density, and S is the second image area.
[0075] In some embodiments, the scaling factor k may be automatically set based on the particle density.
[0076] In some embodiments, the cutting step length is calculated according to the following formula:
[0077] Step y =PatchHeight-Overlap
[0078] Step x =PatchWeight-Overlap
[0079] Among them, Step x ,Step yare the cutting steps in the x and y directions respectively, PatchHeight and PatchWeight are the height and width of the second image respectively, and Overlap is the overlap value.
[0080] In some embodiments, the overlap value may be different in the width direction and the height direction, and both values may be dynamically calculated based on the particle density.
[0081] In some embodiments, the image segmentation step also includes an edge compensation mechanism. To avoid omissions, the last row, last column, and corner areas of the first image are supplementally segmented, dynamically adjusting the segmentation range to fit the image boundaries. When the image size is not evenly divisible by the segmentation size, the following compensation strategy is used to ensure 100% coverage of the first image content:
[0082] Horizontal compensation: If Width%PatchWidth≠0, then add the right block x start =Width-PatchWidth;
[0083] Vertical compensation: if Height%PatchHeight≠0, then add the bottom block y start =Height-PatchHeight;
[0084] Corner compensation: If both are not divisible, then add the lower right corner block (x start ,y start )=(Width-PatchWidth,Height-PatchHeight).
[0085] Among them, x start ,y start are the coordinates of the lower left corner of the second image located at the lower right corner in the first image.
[0086] S40: Performing target detection on the second image to obtain bounding box and mask information of the macro rock particles; and converting the bounding box and mask information into a global coordinate system.
[0087] In some embodiments, the second image can be processed before target detection, and the processing may include: image enhancement processing, local contrast enhancement, noise suppression, edge sharpening, etc., or generating an attention mask based on the particle density map to assign higher computational weights to high-density areas.
[0088] In some embodiments, the model used for target detection can be an existing model such as YOLOv8, Mask R-CNN, ResNet, or a self-trained deep learning target detection model.
[0089] In some embodiments, the bounding box and mask information may include: bounding box size, border point positions, mask area, feature vectors, etc.
[0090] In some embodiments, the bounding box and mask information may be converted to a global coordinate system using the following formula:
[0091] GlobalBox=[x1+x start ,y1+y start ,x2+x start ,y2+y start ]
[0092] GlobalMask=Mask+[x start ,y start ]
[0093] Among them, x1, y1, x2, y2 are the lower left corner coordinates and upper right corner coordinates of the particle bounding box identified in a second image, respectively. start ,y start are the lower left corner coordinates of the second image in the first image respectively. GlobalBox is the bounding box of the particle in the first image, including the lower left corner coordinates and the upper right corner coordinates. GlobalMask is the mask information of the first image, and Mask is the mask information of the second image.
[0094] S50: removing repeated detection results across multiple second images using a deduplication algorithm to generate final particle distribution data.
[0095] In some embodiments, the deduplication algorithm may use non-maximum suppression (NMS), feature deduplication and other methods to remove overlapping detection results. Taking non-maximum suppression as an example, the IoU threshold may be set to 0.5.
[0096] In some embodiments, the particle distribution data includes at least one of the following: a bounding box, mask information, an equivalent diameter of each particle, and statistical data of the equivalent diameters; wherein the particle equivalent diameter is calculated based on the mask area of the particle.
[0097] In some embodiments, the particle equivalent diameter D can be calculated using the following formula:
[0098]
[0099] Among them, Area is the mask area.
[0100] In some embodiments, the particle distribution data is returned to a programmable logic system host via a communication device, and the programmable logic system host adjusts the parameters of the feeding device according to the particle distribution data.
[0101] In some embodiments, the detection results, including the bounding box and the mask area, are drawn on the original image, and the particle positions and characteristic information are marked.
[0102] In some embodiments, detection statistics (eg, total number of targets, particle size distribution) and visualization images are generated for subsequent analysis or storage.
[0103] The second embodiment of the present application provides an x method based on particle density. Figure 2a The method provided by the second embodiment includes the following steps S200-S250.
[0104] S200: Acquire a real-time image including distribution of multiple rock particles.
[0105] like Figure 2b As shown, a mounting frame 1 for detection is installed above a conveyor belt in a factory or mine, a light shield 2 is provided above the mounting frame 1 facing the conveyor belt, a top lighting 3 and a side lighting 4 are provided directly above and on the side of the light shield 2, and a camera 5 for collecting real-time images and a purge cooling barrel are provided directly above the light shield 2.
[0106] As the rock particles are transported from one end to the other on the conveyor belt, a camera 5 located above the conveyor belt will capture high-resolution real-time images for analysis.
[0107] To ensure image quality, the camera focus and lighting conditions need to be calibrated during the acquisition process to avoid overexposure or shadows interfering with the extraction of particle features.
[0108] The acquired image is recorded as I(x,y), where x and y are pixel coordinates, ranging from 0≤x <Width,0≤y<Height。
[0109] S210: Estimate the particle density of rock particles in the acquired image using a pre-trained deep learning image segmentation model.
[0110] After preprocessing the image by correcting overexposure and underexposure, a pretrained deep learning image segmentation model is used to estimate the particle density of image I(x,y). Taking YOLOv8s as an example, the YOLOv8s model is a relatively lightweight detection model that achieves fast prediction by lowering the confidence threshold and limiting the maximum number of detected targets (i.e., extracting the number of detected particles N from the model output). For example, if the confidence threshold is set to 0.3 and the maximum number of detected targets is 100,000, the theoretical formula for calculating particle density based on image size is:
[0111]
[0112] Wherein, Width and Height are the width and height of the first image, and Density is the particle density per unit area, which reflects the density of particle distribution and provides a basis for subsequent overlap adjustment.
[0113] S220: Dynamically determine the overlap value based on the particle density to ensure that the cut blocks can effectively cover the particle boundaries.
[0114] The image I(x,y) is cut from left to right and from top to bottom into blocks of equal area (second image), thereby reducing the area of each target detection and improving the overall detection efficiency.
[0115] Each patch has an area S, a height PatchHeight, and a width PatchWidth. During segmentation, each patch has overlapping areas to prevent some particles from becoming unrecognizable due to segmentation. The segmentation step size is slightly smaller than the patch height and width to ensure that every two patches have overlapping areas during segmentation.
[0116] To this end, the size of the overlapping area is adjusted according to the particle density, and a larger overlapping area, that is, a smaller cutting step size, is used for images with higher density to avoid missed detection.
[0117] For the convenience of calculation, the overlapping value with the same width and height is used to calculate the cutting step. The designed mapping function is as follows:
[0118] Overlap=max(MinOverlap,min(MaxOverlap,k×Density×S))
[0119] Among them, MinOverlap is the set lower limit of the overlap value, MaxOverlap is the set upper limit of the overlap value, k is the proportional coefficient, which is used to adjust the increasing speed of the overlap value with the particle density and block area; Density is the particle density, and S is the block area.
[0120] S230: Calculate the cutting step length and cut the image.
[0121] According to the overlap value determined in the above steps, the cutting step size is calculated as:
[0122] Step y =PatchHeight-Overlap
[0123] Step x =PatchWeight-Overlap
[0124] Among them, Step x ,Step yare the cutting steps in the x and y directions respectively, PatchHeight and PatchWeight are the height and width of the blocks respectively, and Overlap is the overlap value.
[0125] In addition, since the height or width of the image I(x,y) may not be divisible by the height or width of the block, after cutting from left to right and from top to bottom, cut areas that do not conform to the block size will remain on the right, bottom, and lower right corners. In this case, to avoid omissions, an edge processing step is added to perform additional cutting on the last row, last column, and corner areas of the image, and dynamically adjust the block range to adapt to the image boundary to ensure 100% coverage of the object to be detected. Specifically, it includes:
[0126] Horizontal compensation: If Width%PatchWidth≠0, then add the right block x start =Width-PatchWidth;
[0127] Vertical compensation: if Height%PatchHeight≠0, then add the bottom block y start =Height-PatchHeight;
[0128] Corner compensation: If both are not divisible, then add the lower right corner block (x start ,y start )=(Width-PatchWidth,Height-PatchHeight).
[0129] Among them, x start ,y start are the coordinates of the lower left corner of the block located in the lower right corner in the image I(x,y).
[0130] Finally, the compensated blocks obtained above are combined with the normal blocks for further batch detection. The above edge processing can ensure the following through the three-level compensation mechanism:
[0131] a) All particles are fully tested at least once;
[0132] b) Compensate for dynamic adjustment of overlapping areas of blocks (using the same Overlap value as the blocks).
[0133] S240: performing batch detection on the cut blocks, obtaining the bounding box and mask of the particles, and converting the bounding box and mask information into a global coordinate system.
[0134] Use a target detection model, such as YOLOv8s, to perform batch target detection on small blocks to obtain the bounding box of the particle, including the coordinates of the lower left corner and the upper right corner of the bounding box; and the mask.
[0135] The detection results of the blocks are converted to the global coordinate system (i.e., the coordinate system of the image I(x,y)). Specifically:
[0136] GlobalBox=[x1+x start ,y1+y start ,x2+x start ,y2+y start ]
[0137] GlobalMask=Mask+[x start ,y start ]
[0138] Among them, x1, y1, x2, y2 are the lower left corner coordinates and upper right corner coordinates of the particle bounding box identified in a second image, respectively. start ,y start The coordinates of the lower left corner of the second image in the first image are respectively. GlobalBox is the bounding box of the particle in the first image, including the coordinates of the lower left corner and the upper right corner. GlobalMask is the mask information of the first image, and Mask is the mask information of the second image. The mask information is a marked detection image with attributes such as area and coordinates.
[0139] S250: Deduplication and particle characteristics analysis are performed on the detection results to generate the final output.
[0140] The non-maximum suppression algorithm is used to remove overlapping detections across blocks. Based on the global bounding box and confidence score, an IoU threshold is set, such as 0.5, to filter out duplicate objects. NMS retains the object with the highest confidence and removes redundant detections in overlapping areas.
[0141] Based on the final bounding box and mask after excluding overlapping detection, the equivalent diameter D of each particle is calculated. Specifically:
[0142]
[0143] Among them, Area is the mask area.
[0144] Finally, the bounding box and mask area are drawn on the original image obtained by the camera, and the position and characteristic information of each particle, such as the equivalent diameter, are marked.
[0145] Through the above steps, the present invention realizes a particle distribution detection method based on particle density, which can dynamically optimize cutting parameters according to image content, ensure the integrity and efficiency of particle detection, and is applicable to various particle distribution scenarios.
[0146] The third embodiment of the present application provides a particle distribution detection device based on particle density, which can be used to implement the particle distribution detection method based on particle density in the above embodiments, such as Figure 3 As shown, the particle distribution detection device based on particle density includes:
[0147] The data acquisition module is used to obtain a first image containing the distribution of multiple macro rock particles; specifically, the data acquisition module can be used to implement step S10 in the first embodiment and its optional embodiments.
[0148] An image segmentation module is used to estimate the particle density of the macro rock particles in the first image through a pre-trained deep learning image segmentation model; cut the first image into multiple second images according to a cutting step, and the cutting step is determined by an overlap value and a size of the second image; wherein the overlap value is the width of the overlapping area of the second images adjacent to the left and right or the height of the overlapping area of the second images adjacent to the top and bottom, which is calculated based on the estimated particle density; specifically, the image segmentation module can be used to implement steps S20-S30 in the first embodiment and its optional embodiments.
[0149] The image processing module is configured to perform target detection on the second image, obtain bounding box and mask information for the macroscopic rock particles, convert the bounding box and mask information to a global coordinate system, and remove duplicate detection results across multiple second images using a deduplication algorithm to generate final particle distribution data. Specifically, the image processing module can be used to implement steps S40-S50 of the first embodiment and its alternative embodiments.
[0150] Figure 4 900 is a schematic structural diagram of a computing device provided in an embodiment of the present application. The computing device can execute each optional embodiment of the above method. The computing device can be a terminal, or a chip or chip system inside the terminal. Figure 4 As shown, the computing device 900 includes: a processor 910 , a memory 920 , and a communication interface 930 .
[0151] It should be understood that Figure 4 The communication interface 930 in the computing device 900 shown may be used to communicate with other devices, and may specifically include one or more transceiver circuits or interface circuits.
[0152] The processor 910 may be connected to a memory 920. The memory 920 may be used to store the program code and data. Therefore, the memory 920 may be a storage unit within the processor 910, an external storage unit independent of the processor 910, or a component including both a storage unit within the processor 910 and an external storage unit independent of the processor 910.
[0153] Optionally, the computing device 900 may further include a bus. The memory 920 and the communication interface 930 may be connected to the processor 910 via a bus. The bus may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 4 A line without an arrow is used to represent the bus, but this does not mean that there is only one bus or one type of bus.
[0154] It should be understood that in the embodiment of the present application, the processor 910 can adopt a central processing unit (CPU). The processor can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. Alternatively, the processor 910 adopts one or more integrated circuits to execute relevant programs to implement the technical solutions provided in the embodiments of the present application.
[0155] The memory 920 may include a read-only memory and a random access memory, and provides instructions and data to the processor 910. A portion of the processor 910 may also include a non-volatile random access memory. For example, the processor 910 may also store information about the device type.
[0156] When the computing device 900 is running, the processor 910 executes the computer-executable instructions in the memory 920 to perform any operation step of the above method and any optional embodiment thereof.
[0157] It should be understood that the computing device 900 according to the embodiment of the present application can correspond to the corresponding subject in executing the method according to each embodiment of the present application, and the above-mentioned and other operations and / or functions of each module in the computing device 900 are respectively for implementing the corresponding processes of each method of the present embodiment. For the sake of brevity, they will not be repeated here.
[0158] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0159] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0160] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0161] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0162] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0163] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0164] An embodiment of the present application also provides a computer-readable storage medium having a computer program stored thereon. When the program is executed by a processor, the program is used to execute the above method, which includes at least one of the solutions described in the above embodiments.
[0165] The computer storage medium of the embodiment of the present application can adopt any combination of one or more computer-readable media.Computer-readable media can be computer-readable signal media or computer-readable storage media.Computer-readable storage media can be, for example, but not limited to, electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices or components, or any combination thereof.More specific examples (non-exhaustive list) of computer-readable storage media include: electrical connection with one or more wires, portable computer disks, hard disks, random access memories (RAM), read-only memories (ROM), erasable programmable read-only memories (EPROM or flash memory), optical fibers, portable compact disk read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination thereof.In this document, computer-readable storage media can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.
[0166] A computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries computer-readable program code. Such propagated data signals may take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0167] Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
[0168] The computer program code for performing the operations of the present application can be written in one or more programming languages, or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (e.g., through the Internet using an Internet service provider).
[0169] In addition, the words "first, second, third, etc." or module A, module B, module C and other similar terms in the specification and claims are only used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that the specific order or sequence can be interchanged where permitted so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0170] In the above description, the numbers representing the steps, such as S110, S120, etc., do not necessarily mean that the steps must be executed in this manner. If permitted, the order of the steps can be interchanged or they can be executed simultaneously.
[0171] The term "comprising" as used in the specification and claims should not be construed as limiting to what is listed thereafter; it does not exclude other elements or steps. Thus, it should be interpreted as specifying the presence of the features, integers, steps, or components mentioned, but not excluding the presence or addition of one or more other features, integers, steps, or components, or groups thereof. Thus, the expression "a device comprising means A and B" should not be limited to a device consisting solely of components A and B.
[0172] References in this specification to "one embodiment" or "an embodiment" mean that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment of the present application. Therefore, the phrases "in one embodiment" or "in an embodiment" appearing throughout this specification do not necessarily refer to the same embodiment, but may refer to the same embodiment. Furthermore, in one or more embodiments, the particular features, structures, or characteristics can be combined in any suitable manner, as would be apparent to one of ordinary skill in the art from this disclosure.
[0173] Note that the above are only preferred embodiments of the present application and the technical principles employed. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and that various obvious changes, readjustments, and substitutions can be made by those skilled in the art without departing from the scope of protection of the present application. Therefore, although the present application has been described in more detail through the above embodiments, the present application is not limited to the above embodiments and may include many other equivalent embodiments without departing from the scope of protection of the present application, all of which fall within the scope of protection of the present application.
Claims
1. A particle distribution detection method based on particle density, characterized in that: The following steps are involved: acquiring a first image comprising a distribution of a plurality of macroscopic rock particles; estimating the particle density of the macroscopic rock particles in the first image using a pre-trained deep learning image segmentation model; Cutting the first image into a plurality of second images according to a cutting step length, wherein the cutting step length is determined by an overlap value and a size of the second image; wherein the overlap value is the width of an overlapping region of left and right adjacent second images or the height of an overlapping region of top and bottom adjacent second images, and is calculated based on the estimated particle density; Performing target detection on the second image to obtain bounding box and mask information of the macro rock particles; and converting the bounding box and mask information into a global coordinate system; Repeated detection results across multiple second images are removed using a deduplication algorithm to generate final particle distribution data.
2. The method according to claim 1, characterized in that The overlap value is calculated from the estimated particle density, specifically: The overlap value is calculated by the following correlation relationship, including: The overlap value is linearly positively correlated with the particle density; Alternatively, the overlap value is linearly positively correlated with the product of the particle density and the size of the second image.
3. The method according to claim 2, characterized in that The overlap value has an upper limit and a lower limit, and when the calculated overlap value exceeds the upper limit, the overlap value is set to the upper limit; When the calculated overlap value is lower than the lower limit, the overlap value is set as the lower limit.
4. The method according to claim 1, wherein The cutting step length is calculated according to the following formula: Step y =PatchHeight-Overlap Step x =PatchWeight-Overlap Among them, Step x ,Step y are the cutting steps in the x and y directions respectively, PatchHeight and PatchWeight are the height and width of the second image respectively, and Overlap is the overlap value.
5. The method according to claim 1, characterized in that The particle distribution data includes at least one of the following: a bounding box, mask information, an equivalent diameter of each particle, and statistical data of the equivalent diameter; wherein the particle equivalent diameter is calculated based on the mask area of the particle.
6. A particle distribution detection method based on particle density, characterized in that: Applied to the detection of rock particle distribution on industrial conveyor belts, including: Acquiring a first image including the distribution of a plurality of macro rock particles by an industrial camera mounted above the conveyor belt; estimating the particle density of the macroscopic rock particles in the first image using a pre-trained deep learning image segmentation model; Cutting the first image into a plurality of second images according to a cutting step length, wherein the cutting step length is determined by an overlap value and a size of the second image; wherein the overlap value is the width of an overlapping region of left and right adjacent second images or the height of an overlapping region of top and bottom adjacent second images, and is calculated based on the estimated particle density; Performing target detection on the second image to obtain bounding box and mask information of the macro rock particles; and converting the bounding box and mask information into a global coordinate system; removing repeated detection results across a plurality of the second images by a deduplication algorithm to generate final particle distribution data; The particle distribution data is returned to the programmable logic system host through the communication device, and the programmable logic system host adjusts the feeding device parameters according to the particle distribution data.
7. A particle distribution detection device based on particle density, characterized in that: include: a data acquisition module for acquiring a first image including a distribution of a plurality of macro rock particles; an image segmentation module, configured to estimate the particle density of the macro rock particles in the first image using a pre-trained deep learning image segmentation model; Cutting the first image into a plurality of second images according to a cutting step length, wherein the cutting step length is determined by an overlap value and a size of the second image; wherein the overlap value is the width of an overlapping region of left and right adjacent second images or the height of an overlapping region of top and bottom adjacent second images, and is calculated based on the estimated particle density; An image processing module is used to perform target detection on the second image to obtain the bounding box and mask information of the macro rock particles; and convert the bounding box and mask information into a global coordinate system; remove duplicate detection results across multiple second images through a deduplication algorithm to generate final particle distribution data.
8. A computing device, characterized in that include: processor, and A memory having program instructions stored thereon, wherein when the program instructions are executed by the processor, the processor executes the particle distribution detection method based on particle density according to any one of claims 1 to 5, or the particle distribution detection method based on particle density according to claim 6.
9. A computer-readable storage medium, characterized in that Program instructions are stored thereon, and when the program instructions are executed by a computer, the computer executes the particle distribution detection method based on particle density according to any one of claims 1 to 5, or the particle distribution detection method based on particle density according to claim 6.
10. A computer program product, characterized in that It includes program instructions, which, when executed by a computer, enable the computer to execute the particle distribution detection method based on particle density according to any one of claims 1 to 5, or the particle distribution detection method based on particle density according to claim 6.
Citation Information
Patent Citations
Conveyor belt ore granularity detection method based on edge response fusion algorithm
CN113240663A
Transport flow ore coarse particle distribution detection method based on TRCU algorithm
CN117115118A
Density-adaptive dense target detection method, device and equipment and medium
CN117671242A
Rock segmentation and identification model training method, application method and equipment
CN118411525A
Ore granularity detection method
CN119715276A
Cited By
A method and system for separating foreground and background layers of a paint microscopic image
CN122473219A
A method and system for separating foreground and background layers of a paint microscopic image
CN122473219B