Material particle size measurement method, device, equipment and storage medium

By segmenting the material image into multiple sub-maps and performing fusion processing, the problem of high hardware requirements for material particle size measurement in the prior art and poor recognition effect is solved, and a particle size measurement with higher accuracy and efficiency is achieved.

CN119515956BActive Publication Date: 2025-05-27CONTEMPORARY AMPEREX TECHNOLOGY CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510026452.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-01-08
Publication Date
2025-05-27
Estimated Expiration
2045-01-08

AI Technical Summary

Technical Problem

Existing material particle size measurement methods have high hardware requirements and poor recognition effects, making it difficult to accurately measure the particle size distribution of materials.

Method used

By dividing the material image into multiple sub-maps for processing, and fusing the recognition results of each sub-maps, the recognition results of the entire image are obtained, and the material particle size measurement is performed. Specific steps include acquiring material images, image segmentation, image recognition, particle fusion and particle size measurement.

Benefits of technology

It improves the accuracy and efficiency of material particle size measurement, reduces the hardware requirements, and is suitable for particle size analysis of various materials.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119515956B_ABST
    Figure CN119515956B_ABST
Patent Text Reader

Abstract

This application belongs to the technical field of image processing, and discloses a method, device, equipment and storage medium for measuring the particle size of materials. The method includes: obtaining a current material image; performing image segmentation on the current material image to obtain a plurality of segmented material images; performing image recognition on the plurality of segmented material images to obtain the regional features of the segmented material images; performing particle fusion processing on the plurality of segmented material images based on the regional features of the segmented material images to obtain a fused image; and measuring the particle size of the material according to the fused image. By segmenting the image into multiple sub-images for processing, and then fusing the recognition results of each sub-image to obtain the recognition result of the entire image, the particle size of the material is measured according to the fused image, thereby improving the measurement accuracy and efficiency, being applicable to the particle size analysis of various materials, and effectively reducing the requirements for hardware.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of image processing technology, and particularly to a method, device, equipment, and storage medium for measuring the particle size of materials. Background Art

[0002] The detection of material particle size is a very important analysis technology in the fields of materials science and engineering, which involves measuring the size distribution of various materials (such as powders, particles, fibers, etc.). The results of particle size detection are of great significance for understanding the physical properties, chemical reactivity, flow characteristics, and final application performance of materials.

[0003] Traditional particle size measurement methods such as sieving method, laser scattering method, etc. have problems such as complex operation, long time consumption, and limited accuracy. In recent years, the particle size measurement method based on image recognition has received attention due to its advantages such as fast speed, non-contact, and rich information. However, the processing of high-resolution images requires high hardware requirements, and the recognition effect of small particles is not good. Summary of the Invention

[0004] The main purpose of this application is to provide a method, device, equipment, and storage medium for measuring the particle size of materials, aiming to solve the technical problems of high hardware requirements and poor recognition effect in current material particle size measurement.

[0005] In the first aspect, this application provides a method for measuring the particle size of materials, and the method for measuring the particle size of materials includes:

[0006] Obtain the current material image;

[0007] Perform image segmentation on the current material image to obtain multiple segmented material images;

[0008] Perform image recognition on the multiple segmented material images to obtain the region features of the segmented material images;

[0009] Based on the region features of the segmented material images, perform particle fusion processing on the multiple segmented material images to obtain a fused image;

[0010] Measure the particle size of the material according to the fused image.

[0011] In this solution, by segmenting the image into multiple sub-images for processing, and then fusing the recognition results of each sub-image to obtain the recognition result of the entire image, thereby measuring the particle size of the material according to the fused image, the measurement accuracy and efficiency are improved, it is applicable to the particle size analysis of various materials, and the hardware requirements are effectively reduced.

[0012] In some embodiments, performing particle fusion processing on the multiple segmented material images based on the region features of the segmented material images to obtain a fused image includes:

[0013] Perform boundary detection on multiple segmented material images based on the regional features of the segmented material images to obtain the boundary features of each segmented material image;

[0014] Perform boundary matching based on the boundary features to obtain a matching result;

[0015] When the matching result indicates that the boundary features match exactly, perform particle fusion based on the boundary features to obtain a fused image.

[0016] In this solution, accurate particle fusion is achieved through boundary detection and matching, ensuring that key information is not lost during the fusion process of the segmented material images and that the true structure of the original material can be accurately reflected, improving the accuracy of particle size measurement.

[0017] In some embodiments, performing boundary detection on multiple segmented material images based on the regional features of the segmented material images to obtain the boundary features of each segmented material image includes:

[0018] Obtain the segmentation mask of each segmented material image based on the regional features of the segmented material image;

[0019] Perform boundary detection on each segmented material image according to the segmentation mask to obtain a boundary segmentation mask;

[0020] Obtain the boundary features of each segmented material image according to the boundary segmentation mask.

[0021] In this solution, using the segmentation mask for boundary detection makes the extraction of boundary features more accurate and automated, reducing the need for manual intervention while improving the speed and quality of image processing.

[0022] In some embodiments, performing boundary detection on each segmented material image according to the segmentation mask to obtain a boundary segmentation mask includes:

[0023] Obtain the sub - image index of each segmented material image;

[0024] Obtain the index number of the segmentation mask in the corresponding segmented material image;

[0025] Obtain the segmentation mask index in each segmented material image according to the sub - image index and the index number;

[0026] Determine the boundary segmentation mask according to the segmentation mask index.

[0027] In this solution, the process of determining the boundary segmentation mask based on the sub - image index and the segmentation mask index enhances the flexibility and adaptability of boundary detection and can better adapt to different types of material images.

[0028] In some embodiments, performing boundary matching based on the boundary features to obtain a matching result includes:

[0029] Determine a boundary segmentation mask based on boundary features;

[0030] Obtain the boundary segmentation mask index of the boundary segmentation mask;

[0031] Perform boundary matching through the boundary segmentation mask index to obtain a matching result.

[0032] In this solution, a method of performing matching based on the boundary segmentation mask index is proposed, which simplifies the matching logic, improves the success rate and speed of boundary matching, and thus speeds up the entire particle fusion processing speed.

[0033] In some embodiments, performing boundary matching through the boundary segmentation mask index to obtain a matching result includes:

[0034] Match the target segmentation mask of each boundary segmentation mask through the boundary segmentation mask index;

[0035] When the target segmentation mask is matched, determine that the matching result is that the boundary features match;

[0036] When the target segmentation mask is not matched, determine that the matching result is that the boundary features do not match.

[0037] In this solution, it specifically illustrates how to match the target segmentation mask through the boundary segmentation mask index, further clarifies the operation details of boundary matching, and ensures the reliability and accuracy of the matching result.

[0038] In some embodiments, in the case where the matching result is that the boundary features match, performing particle fusion based on the boundary features to obtain a fused image includes:

[0039] In the case where the matching result is that the boundary features match, obtain the target segmentation mask based on the boundary features;

[0040] Obtain the target segmentation mask index;

[0041] Pair the target segmentation mask indexes to obtain target index pairs, and summarize the target index pairs to obtain a target index pair list;

[0042] Fuse the target index pair list to obtain a fused index pair list;

[0043] Obtain the segmentation mask indexes that do not match;

[0044] Obtain the fused image according to the segmentation mask indexes that do not match and the fused index pair list.

[0045] In this solution, particle fusion is performed on the boundary features with consistent matching, including generating a list of target index pairs and fusion index pairs, ensuring the transparency and controllability of the fusion process and improving the quality of the final fused image.

[0046] In some embodiments, image segmentation is performed on the current material image to obtain multiple segmented material images, including:

[0047] Obtain material properties;

[0048] Perform image segmentation on the current material image according to the material properties to obtain multiple segmented material images.

[0049] In this solution, image segmentation is performed according to the material properties, making the segmentation process more targeted and scientific, and being able to more accurately reflect the actual structure of the material, providing a better basis for subsequent image recognition and particle size measurement.

[0050] In some embodiments, image segmentation is performed on the current material image according to the material properties to obtain multiple segmented material images, including:

[0051] Obtain the particle size and particle distribution density according to the material properties;

[0052] Perform image segmentation on the current material image through the particle size and particle distribution density to obtain multiple segmented material images.

[0053] In this solution, incorporating the particle size and distribution density into the segmentation consideration makes the segmentation strategy closer to the actual situation of the material, improves the effect of image segmentation, and further improves the accuracy of particle size measurement.

[0054] In some embodiments, image recognition is performed on multiple segmented material images to obtain the region features of the segmented material images, including:

[0055] Input multiple segmented material images into the target image recognition model, and perform image feature extraction through the backbone network in the target image recognition model to obtain the first feature map;

[0056] Process the first feature map through the region generation network in the target image recognition model to generate candidate regions;

[0057] Perform feature extraction on the candidate regions through the region of interest extraction network in the target image recognition model to obtain candidate features;

[0058] Perform object detection and instance segmentation on the candidate features through the head network in the target image recognition model to obtain the category, bounding box, and segmentation mask of each segmented material image;

[0059] Obtain the region features of the segmented material images through the category, bounding box, and segmentation mask.

[0060] In this solution, a trained target image recognition model is used to recognize the segmented material images, which not only improves the recognition speed but also enhances the recognition accuracy. The functions of each network layer inside the target image recognition model are deeply analyzed. From image feature extraction to object detection and instance segmentation, this process ensures the high quality of the recognition results and provides a reliable basis for subsequent particle size measurement.

[0061] In some embodiments, obtaining the segmented material image region features through category, bounding box, and segmentation mask includes:

[0062] Obtaining the object confidence according to the bounding box;

[0063] Filtering the segmented material image based on the object confidence to obtain a filtered segmented material image;

[0064] Obtaining the segmented material image region features according to the type, bounding box, and segmentation mask of the filtered segmented material image.

[0065] In this solution, by evaluating the object confidence to filter the segmented material image, low-quality or irrelevant information is removed, the most representative part of the image is retained, and the effectiveness and practicality of the segmented material image region features are improved.

[0066] In some embodiments, the target image recognition model is trained in the following manner, including:

[0067] Obtaining a first training sample and a first validation sample, where the first training sample and the first validation sample include the original material images with segmentation masks labeled with particles;

[0068] Initializing the deep learning model and determining the training parameters;

[0069] Training the initialized deep learning model with the first training sample and the training parameters to obtain a training result;

[0070] Calculating the loss value according to the training result and the first validation sample;

[0071] Adjusting the training parameters of the initialized deep learning model through the loss value to obtain the target image recognition model.

[0072] In this solution, by using the training sample and the validation sample to train the model, the target image recognition model is obtained. Through the target image recognition model, the segmentation mask in the image can be recognized more quickly and accurately, improving the recognition accuracy and efficiency.

[0073] In some embodiments, the method further includes:

[0074] Perform image magnification on multiple segmented material images to obtain multiple magnified segmented material images;

[0075] Correspondingly, perform image recognition on multiple segmented material images to obtain segmented material image region features including:

[0076] Perform image recognition on multiple magnified segmented material images to obtain segmented material image region features.

[0077] In this solution, by magnifying the segmented material images, the problem of difficult recognition caused by insufficient image resolution is solved, and the accuracy of image recognition is improved.

[0078] In some embodiments, performing image magnification on multiple segmented material images to obtain multiple magnified segmented material images includes:

[0079] Input multiple segmented material images into the target generator in the image magnification model, and perform image magnification on the multiple segmented material images through the target generator to obtain target resolution segmented images;

[0080] Input the target resolution segmented images into the target discriminator in the image magnification model, and perform discrimination on the target resolution segmented images through the target discriminator to obtain probability values;

[0081] In the case where the probability value is greater than or equal to the preset threshold, use the target resolution segmented images as the magnified segmented material images.

[0082] In this solution, use the trained image magnification model to perform image magnification on the segmented material images, and use the image magnification model including the target generator and the target discriminator to achieve efficient image magnification, while ensuring the quality and authenticity of the magnification, which helps to improve the accuracy of subsequent image recognition and particle size measurement.

[0083] In some embodiments, inputting multiple segmented material images into the target generator in the image magnification model, and performing image magnification on the multiple segmented images through the target generator to obtain target resolution segmented images includes:

[0084] Input multiple segmented material images into the target generator in the image magnification model, and perform size magnification through the pre-upsampling layer in the target generator to obtain initial segmented material images;

[0085] Perform feature extraction and residual connection on the initial segmented material images through the residual blocks in the target generator to obtain reference segmented material images;

[0086] Perform convolution and size magnification on the reference segmented material images through the post-processing layer in the target generator to obtain target resolution segmented images.

[0087] In this solution, the functions of each layer inside the target generator are described in detail, such as the roles of the pre-upsampling layer, the residual block, and the post-processing layer, ensuring the efficiency and stability of image magnification and enhancing the visual effect and analysis value of the magnified image.

[0088] In some embodiments, the target resolution block image is input into the target discriminator in the image magnification model, and the target discriminator discriminates the target resolution block image to obtain probability values including:

[0089] The target resolution block image is input into the target discriminator in the image magnification model, and the target discriminator performs convolution, normalization, and activation on the target resolution block image through multiple convolutional layers, normalization layers, and activation functions in the target discriminator to obtain a non-linear activation map;

[0090] The non-linear activation map is pooled through the pooling layer in the target discriminator to obtain a second feature map;

[0091] The second feature map is transformed through the fully connected layer in the target discriminator to obtain probability values.

[0092] In this solution, it is elaborated on how the discriminator evaluates the magnified image through convolutional layers, normalization layers, activation functions, and pooling layers, etc., and finally outputs probability values, ensuring the scientificity and objectivity of the quality evaluation process of the magnified image.

[0093] In some embodiments, the image magnification model is trained in the following manner, including:

[0094] Obtain a second training sample and a third training sample, where the second training sample and the third training sample are material images of the initial resolution;

[0095] Input the second training sample into the initial generator to generate target sample data;

[0096] Input the third training sample and the target sample data into the initial discriminator for determination to obtain a determination result;

[0097] Adjust the parameters through the determination result to train the initial generator and the initial discriminator to obtain a target generator and a target discriminator;

[0098] Obtain the image magnification model through the target generator and the target discriminator.

[0099] In this solution, it is described that the image magnification model continuously optimizes the generator and the discriminator through training. This training method improves the robustness and adaptability of the model, enabling it to produce high-quality magnification results when processing various material images.

[0100] In some embodiments, the particle size measurement of the material based on the fused image includes:

[0101] Obtaining the number of pixels according to the fused image;

[0102] Calculating the equivalent diameter of the pixel unit according to the number of pixels;

[0103] Converting the equivalent diameter of the pixel unit to obtain the equivalent diameter of the material particles.

[0104] In this solution, the equivalent diameter of the material particles is calculated based on the fused image, converting the image information into specific physical quantities, completing a complete closed-loop from image analysis to particle size measurement, and providing important technical support for materials science research and industrial applications.

[0105] In a second aspect, to achieve the above object, the present application also proposes a material particle size measurement device, which includes:

[0106] An acquisition module, configured to acquire the current material image;

[0107] A segmentation module, configured to perform image segmentation on the current material image to obtain multiple segmented material images;

[0108] An identification module, configured to perform image identification on the multiple segmented material images to obtain the region features of the segmented material images;

[0109] A fusion module, configured to perform particle fusion processing on the multiple segmented material images based on the region features of the segmented material images to obtain a fused image;

[0110] A measurement module, configured to perform particle size measurement of the material according to the fused image.

[0111] In a third aspect, to achieve the above object, the present application also proposes a material particle size measurement device, which includes: a memory, a processor, and a computer program stored on the memory and executable on the processor, and the computer program is configured to implement the steps of the material particle size measurement method as described above.

[0112] In a fourth aspect, to achieve the above object, the present application also proposes a storage medium, which is a computer-readable storage medium, and a computer program is stored on the storage medium, and when the computer program is executed by a processor, it implements the steps of the material particle size measurement method as described above.

[0113] In a fifth aspect, to achieve the above object, the present application also provides a computer program product, which includes a computer program, and when the computer program is executed by a processor, it implements the steps of the material particle size measurement method as described above.

[0114] The above description is only an overview of the technical solution of this application. In order to be able to understand the technical means of this application more clearly, it can be implemented according to the content of the specification. And in order to make the above and other purposes, features and advantages of this application more obvious and understandable, the specific embodiments of this application are specifically exemplified below. Description of the Drawings

[0115] By reading the following detailed description of the preferred embodiments, various other advantages and benefits will become clear to those of ordinary skill in the art. The drawings are only for the purpose of showing the preferred embodiments and are not considered to be a limitation of this application. Moreover, in all the drawings, the same reference numerals are used to represent the same components. In the drawings:

[0116] Figure 1 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0117] Figure 2 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0118] Figure 3 It is a schematic diagram of the segmentation mask for the fusion of segmented materials in an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0119] Figure 4 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0120] Figure 5 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0121] Figure 6 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0122] Figure 7 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0123] Figure 8 It is a schematic flowchart of an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0124] Figure 9 It is a schematic diagram of the particle recognition effect of a certain material in an embodiment of the material particle size measurement method proposed in an embodiment of this application;

[0125] Figure 10 It is a schematic diagram of the module structure of the material particle size measurement device in an embodiment of this application;

[0126] Figure 11It is a schematic diagram of the device structure of the hardware operating environment involved in the material particle size measurement method in the embodiments of the present application.

[0127] The implementation, functional characteristics, and advantages of the present application will be further described with reference to the embodiments and the accompanying drawings. Specific Embodiments

[0128] Hereinafter, embodiments of the technical solution of the present application will be described in detail with reference to the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present application, and thus are only examples and should not be used to limit the protection scope of the present application.

[0129] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which this application belongs; the terms used herein are only for the purpose of describing specific embodiments and are not intended to limit this application; the terms "including" and "having" and any variations thereof in the specification and claims of this application and the above drawings are intended to cover non-exclusive inclusion.

[0130] In the description of the embodiments of the present application, technical terms such as "first" and "second" are only used to distinguish different objects and cannot be understood as indicating or implying relative importance or implicitly indicating the quantity, specific order, or primary-secondary relationship of the indicated technical features. In the description of the embodiments of the present application, "a plurality of" means two or more, unless otherwise specifically defined.

[0131] Referring to "embodiments" herein means that the specific features, structures, or characteristics described in connection with the embodiments may be included in at least one embodiment of this application. The phrase appears in various places in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment mutually exclusive with other embodiments. Those skilled in the art will explicitly and implicitly understand that the embodiments described herein can be combined with other embodiments.

[0132] In the description of the embodiments of the present application, the term "and / or" is merely a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in this article generally represents an "or" relationship between the associated objects before and after.

[0133] In the description of the embodiments of the present application, the term "a plurality of" refers to two or more (including two). Similarly, "a plurality of groups" refers to two or more groups (including two groups), and "a plurality of pieces" refers to two or more pieces (including two pieces).

[0134] Material particle size detection is a very important analytical technique in the field of materials science and engineering, which involves measuring the size distribution of various materials (such as powders, particles, fibers, etc.).

[0135] In the field of materials science, accurately measuring the particle size distribution of materials is crucial for evaluating their properties. Traditional particle size measurement methods such as sieving method, laser scattering method, etc. have problems such as complex operation, long time consumption, and limited accuracy. In recent years, the particle size measurement method based on image recognition has received attention due to its advantages such as fast speed, non-contact, and rich information. However, the processing of high-resolution images requires high hardware requirements, and the recognition effect of small particles is not good.

[0136] Moreover, in the current material particle size measurement, when the image is divided into blocks, some particles will be cut into multiple particles. Since the mis-segmented particles are not finally merged, the calculated particle size characteristics are inaccurate, such as the calculated number of particles is too large and the particle size is too small.

[0137] Therefore, in order to improve the accuracy of particle size measurement of materials such as electrodes and electrolytes in the battery field, the inventive concept of this application is as follows:

[0138] The image is divided into multiple sub-images for processing, and then the recognition results of each sub-image are fused to obtain the regional characteristics of the entire image. Finally, the material particle size characteristics are calculated based on the recognized particles. By dividing the image into multiple sub-images for processing, the hardware requirements are effectively reduced, and the segmented sub-images are fused to improve the accuracy of material particle size measurement.

[0139] Specifically, this solution obtains the captured material image, and performs preprocessing, image segmentation, image recognition, and image fusion on the material image, etc., so as to obtain a fused image, and calculates the material particle size characteristics based on the recognized particles to improve the accuracy of particle size measurement.

[0140] In practical applications, the embodiments described in this application are applied to the scenario of evaluating the particle size distribution and shape characteristics of materials, and can also be applied to the scenario of measuring the particle size distribution of electrode materials, catalysts, etc. in the field of energy materials such as batteries and fuel cells. This embodiment does not limit this.

[0141] This application proposes a material particle size measurement method for the technical problem of low accuracy of material particle size measurement. Referring to Figure 1 , in this example, the material particle size measurement method includes:

[0142] Step S10: Obtain the current material image.

[0143] It should be noted that the current material image is an image of related materials such as electrodes and catalysts taken by a camera, and can also be an image of other new energy materials. This embodiment does not limit this.

[0144] In a specific implementation, the current material image can be an image after preprocessing after shooting. The preprocessing process can include denoising processing, contrast enhancement processing, etc. Obtaining the current material image can specifically include: using a high-resolution camera (the resolution can be 20 million pixels, 30 million pixels, etc.) to shoot the target material to ensure image clarity and rich details. After shooting the image of the material, image processing software (such as OpenCV) can be used for preprocessing, which can specifically include denoising processing, contrast enhancement processing, correction processing, etc. The denoising processing can use a median filter to denoise the shot material image, and the specific parameters can be set to a window size of 3×3 to filter out the random noise of the shot material image, and use histogram equalization technology to perform contrast enhancement processing on the material image after noise filtering, so as to improve the distinguishability between particles and the background, obtain an enhanced material image, and use a camera correction algorithm to correct the enhanced material image to correct lens distortion and ensure accurate image geometry, obtaining the current material image to improve the accuracy of subsequent recognition.

[0145] Step S20: Perform image segmentation on the current material image to obtain multiple segmented material images.

[0146] In a specific implementation, to reduce the processing requirements for hardware, the current material image can be segmented into multiple sub-images for processing. Therefore, a certain material segmentation strategy can be used to perform image segmentation on the current material image, segment the current material image into multiple sub-blocks, and thus obtain multiple segmented material images.

[0147] Step S30: Perform image recognition on multiple segmented material images to obtain the regional features of the segmented material images.

[0148] It can be understood that image recognition mainly recognizes the feature information in each segmented material image. The regional features of the segmented material images can include the feature information of each segmented material image, and the feature information can include the category of particles, bounding boxes, segmentation masks, etc.

[0149] In a specific implementation, a certain feature extraction method or feature extraction model, etc. can be used to perform feature recognition on each segmented material image, so as to obtain the feature information of each segmented material image.

[0150] Step S40: Perform particle fusion processing on multiple segmented material images based on the regional features of the segmented material images to obtain a fused image.

[0151] It should be noted that the particle fusion processing of the material image can be performed according to the feature information of each segmented material image, and the particle boundaries that may be cut can be recognized, so that the mis-segmented particles can be merged, and the cut particles can be merged into a complete particle.

[0152] In a specific implementation, it is possible to determine whether to fuse particles by judging whether the particles in adjacent small blocks in each segmented material image are adjacent, and finally obtain the fused image.

[0153] Step S50: Measure the particle size of the material based on the fused image.

[0154] It should be understood that after obtaining the fused image, the particle size of the material can be measured based on the fused image. For example, data such as the equivalent diameter of the particle size and the area of the particle size are calculated, and finally the measurement result is obtained.

[0155] In a specific implementation, based on the measurement result of the particle size, the particle size and distribution of the material can be detected, so as to realize applications such as material analysis and material development.

[0156] In this embodiment, the current material image is obtained; the current material image is segmented to obtain multiple segmented material images; the multiple segmented material images are recognized to obtain the region features of the segmented material images; based on the region features of the segmented material images, the multiple segmented material images are subjected to particle fusion processing to obtain a fused image; the particle size of the material is measured based on the fused image. By dividing the image into multiple sub-images for processing, and then fusing the recognition results of each sub-image to obtain the recognition result of the entire image, the particle size of the material is measured based on the fused image, which improves the measurement accuracy and efficiency, is applicable to the particle size analysis of various materials, and effectively reduces the requirements for hardware.

[0157] In some embodiments, the particle fusion of each segmented material image is specifically to fuse the mis-segmented particles. Referring to Figure 2 , step S40 may include:

[0158] Step S401: Perform boundary detection on the multiple segmented material images based on the region features of the segmented material images to obtain the boundary features of each segmented material image.

[0159] It should be noted that boundary detection can be performed on each segmented material image through the feature information in the region features of the segmented material images, so as to obtain the boundary features of each segmented material image. The boundary features can be the feature information at the boundary of each segmented material image. For example, if the boundary feature is a segmentation mask, the segmentation mask of each segmented material image can be obtained through the region features of the segmented material images, so as to perform boundary detection, and thus obtain the boundary mask located in each segmented material image.

[0160] In a feasible implementation manner, step S401 may include:

[0161] Step A10: Obtain the segmentation mask of each segmented material image based on the region features of the segmented material images.

[0162] It should be noted that the features of the segmented material image regions may include the segmentation masks of each segmented material image. The segmentation mask is a concept in the field of image segmentation. It is an image used to represent the pixel attribution of different regions or objects in another image. The segmentation mask can be a binary mask, a multi-class mask, an instance mask, etc.

[0163] In this embodiment, the segmentation mask can be a binary mask. The binary mask is a binary image in a visual form. The segmentation mask is the particles in each segmented material image. Characterizing the particles as the segmentation mask facilitates subsequent processing of the particles.

[0164] In a feasible implementation manner, each segmented material image has a corresponding index. Therefore, the specific index can be determined, and then boundary detection can be quickly performed. Then step A10 includes: obtaining the sub-image index of each segmented material image; obtaining the index number of the segmentation mask in the corresponding segmented material image; obtaining the segmentation mask index in each segmented material image according to the sub-image index and the index number; and determining the boundary segmentation mask according to the segmentation mask index.

[0165] It should be noted that as Figure 3 shown, for example, the number of segmented material images is 4, that is, the current material image is segmented into 4 sub-images. There are multiple segmentation masks in each sub-image. The number of segmentation masks in each sub-image can be equal or unequal, which is specifically related to the distribution of the particles.

[0166] Each sub-image corresponds to a sub-image index, denoted as (i, j), that is, the index of the sub-image where it is located. For example, among the 4 sub-images, the sub-image indexes are M1(0,0), M2(0,1), M3(1,0), and M4(1,1) respectively. In each sub-image (segmented material image), the segmentation masks are in different positions and correspond to different index numbers. Let k represent the index number of the segmentation mask in the corresponding sub-image in each sub-image. For example, in sub-image M1(0,0), the index numbers of the segmentation masks include 0 and 1; in sub-image M2(0,1), the index numbers of the segmentation masks include 1 and 0; in sub-image M3(1,0), the index numbers of the segmentation masks include 0, 1, and 2; in sub-image M4(1,1), the index numbers of the segmentation masks include 0 and 1.

[0167] In a specific implementation, the segmentation mask indices in each block material image can be obtained according to the obtained sub - figure index and index number. Using (i, j, k) to represent the segmentation mask index, thus, the segmentation mask indices in sub - figure M1(0, 0) are (0, 0, 0) and (0, 0, 1); the segmentation mask indices in sub - figure M2(0, 1) are (0, 1, 0) and (0, 1, 1); the segmentation mask indices in sub - figure M3(1, 0) are (1, 0, 0), (1, 0, 1), and (1, 0, 2); the segmentation mask indices in sub - figure M4(1, 1) are (1, 1, 0) and (1, 1, 1).

[0168] It can be understood that the segmentation mask indices located at the boundary in the segmentation mask indices of each sub - figure can be obtained to get the boundary segmentation mask indices. For example, the boundary segmentation mask indices in sub - figure M3(1, 0) are (1, 0, 0) and (1, 0, 1). By filtering the segmentation mask indices of each sub - figure, the boundary segmentation mask indices in each sub - figure are obtained, and then the boundary segmentation mask and the specific position of the boundary segmentation mask are determined. The process of determining the boundary segmentation mask based on the sub - figure index and the segmentation mask index enhances the flexibility and adaptability of boundary detection and can better adapt to different types of material images.

[0169] Step A11: Perform boundary detection on each block material image according to the segmentation mask to obtain the boundary segmentation mask.

[0170] It should be understood that the positions of all segmentation masks in each block material image can be determined, so as to perform boundary detection on each block material image to obtain the boundary segmentation masks among all segmentation masks. The boundary segmentation mask is the segmentation mask located at the boundary position of the block material image.

[0171] Step A12: Obtain the boundary features of each block material image according to the boundary segmentation mask.

[0172] In a specific implementation, the boundary features of each block material image can be the boundary segmentation masks of each block material image. Therefore, the boundary features of each block material image can be determined according to the boundary segmentation mask. Using the segmentation mask for boundary detection makes the extraction of boundary features more accurate and automated, reduces the need for manual intervention, and improves the speed and quality of image processing at the same time.

[0173] Step S402: Perform boundary matching based on the boundary features to obtain the matching result.

[0174] It should be noted that since the boundary features include the boundary segmentation mask, boundary matching can be performed according to the boundary segmentation mask to obtain the matching result.

[0175] The matching result can be that the boundary feature matches or does not match. When the boundary feature matches, it indicates that the boundary segmentation masks (particles) in adjacent sub-block particle images are adjacent. For example, there are adjacent segmentation masks in the boundary segmentation masks of sub-graph M1 and sub-graph M2. When the boundary feature does not match, it means that the boundary segmentation masks (particles) in adjacent sub-block particle images are not adjacent, that is, there are no adjacent segmentation masks in the boundary segmentation masks of sub-graph M1 and sub-graph M2.

[0176] In a feasible implementation manner, step S402 may include:

[0177] Step A20: Determine the boundary segmentation mask based on the boundary feature.

[0178] It should be noted that the boundary feature contains the boundary segmentation mask, so the boundary segmentation mask can be obtained according to the boundary feature. Specifically, the boundary segmentation masks of each sub-graph can be obtained according to the boundary features in each sub-graph.

[0179] Step A21: Obtain the boundary segmentation mask index of the boundary segmentation mask.

[0180] It should be understood that each boundary segmentation mask corresponds to a boundary segmentation mask index, so the boundary segmentation mask indexes of all sub-graphs of the sub-blocks can be obtained. For example, as Figure 3 shown above, there are a total of 9 segmentation masks, among which there are 5 boundary segmentation masks, and the corresponding boundary segmentation mask indexes are (0, 0, 1), (0, 1, 1), (1, 0, 0), (1, 0, 1), (1, 1, 0).

[0181] Step A22: Perform boundary matching through the boundary segmentation mask index to obtain the matching result.

[0182] It should be noted that boundary matching can be performed through the boundary segmentation mask index. Specifically, it can be determined whether the boundary segmentation masks are adjacent, so as to determine whether the match is consistent and obtain the matching result of whether they are adjacent. The method of performing matching based on the boundary segmentation mask index simplifies the matching logic, improves the success rate and speed of boundary matching, and thus speeds up the entire particle fusion processing speed.

[0183] In a feasible implementation manner, performing boundary matching through the boundary segmentation mask index is specifically to query whether there is a target segmentation mask. Therefore, step A22 includes: matching the target segmentation mask of each boundary segmentation mask through the boundary segmentation mask index; when the target segmentation mask is matched, determining that the matching result is that the boundary feature matches; when the target segmentation mask is not matched, determining that the matching result is that the boundary feature does not match.

[0184] It should be noted that matching can be performed through the boundary segmentation mask index to determine whether each boundary segmentation mask has a target segmentation mask. The target segmentation mask can include the right adjacent segmentation mask and the bottom adjacent segmentation mask of the boundary segmentation mask. The target segmentation mask is the boundary segmentation mask corresponding to the index that has common elements in the index of the boundary segmentation mask currently being matched. For example, if the boundary segmentation mask index is (0, 0, 1), then it is matched whether there is a bottom right adjacent segmentation mask, that is, whether there is a right adjacent segmentation mask or a bottom adjacent segmentation mask. The target segmentation mask can include the right adjacent segmentation mask and the bottom adjacent segmentation mask.

[0185] If the target segmentation mask is matched, the matching result is that the boundary features match. For example, if the boundary segmentation mask index is (0, 0, 1) and the matched target segmentation mask is (1, 0, 0), that is, the right adjacent segmentation mask. For example, if the boundary segmentation mask index is (0, 1, 1) and the matched target segmentation mask is (1, 1, 0), that is, the right adjacent segmentation mask. For example, if the boundary segmentation mask index is (1, 0, 1) and the matched target segmentation mask is (1, 1, 0), that is, the bottom adjacent segmentation mask.

[0186] In a specific implementation, there are also segmentation masks that do not match. For example, (1, 0, 0) has no right or bottom adjacent segmentation mask, so the boundary feature matching is inconsistent. By describing how to match the target segmentation mask through the boundary segmentation mask index, the operation details of the boundary matching are further clarified, ensuring the reliability and accuracy of the matching result.

[0187] Step S403: In the case where the matching result is that the boundary features match, perform particle fusion based on the boundary features to obtain a fused image.

[0188] It should be noted that in the case where the matching result is that the boundary features match, it indicates that there are adjacent particles in the adjacent small blocks, which may be caused by mis-segmentation during segmentation. To improve the accuracy of subsequent particle size measurement, the adjacent particles can be fused to obtain a fused image.

[0189] In a specific implementation, the logic of fusion is to merge the indexes containing common elements.

[0190] In a feasible implementation manner, step S403 may include:

[0191] Step A30: In the case where the matching result is that the boundary features match, obtain the target segmentation mask based on the boundary features.

[0192] Step A31: Obtain the target segmentation mask index.

[0193] It should be noted that if the matching result is that the boundary features match, it means that particle fusion is required. Therefore, the target segmentation mask can be screened and determined according to each boundary segmentation mask in the boundary features.

[0194] In a specific implementation, after obtaining the target segmentation mask, the target segmentation mask index can be obtained.

[0195] Step A32: Pair the target segmentation mask indices to obtain target index pairs, and summarize the target index pairs to obtain an adjacent index pair list.

[0196] In a specific implementation, the target segmentation mask indices can be paired to obtain target index pairs, that is, adjacent index pairs. For example, for the (0,0) sub-graph, it can be detected which segmentation masks in the (0,1) sub-graph and the (1,0) sub-graph are adjacent to the segmentation mask of the M1(0,0) sub-graph, and the indices of the adjacent segmentation masks are paired to obtain several mask pairs, that is, adjacent index pairs. The mask pair is represented as [mask A, mask B].

[0197] When pairing, specifically, if the ordinate of the rightmost pixel of the boundary segmentation mask in the left sub-graph intersects with the ordinate of the leftmost adjacent pixel of the boundary segmentation mask in the right sub-graph, it is determined to be adjacent, that is, the pairing is successful. When calculating the lower adjacent index pair, if the abscissa of the lowermost pixel of the boundary segmentation mask in the upper sub-graph intersects with the uppermost abscissa of the boundary segmentation mask in the lower sub-graph, it is determined to be adjacent, that is, the pairing is successful. The rightmost (lower) pixel refers to the list of pixel points with a width of 1 pixel at the rightmost (lower) side.

[0198] By pairing all the target segmentation mask indices, multiple target index pairs are obtained, and an adjacent index pair list is summarized. As shown in Table 1 below, Table 1 is the lower-right adjacent index pair list for each sub-graph.

[0199] Table 1

[0200]

[0201] By summarizing the lower-right adjacent index pair lists of all the block material images, a target index pair list is obtained: {[(0,0,1),(1,0,0)],[(0,1,1),(1,1,0)],[(1,0,1),(1,1,0)]}.

[0202] Step A33: Fuse the target index pair list to obtain a fused index pair list.

[0203] It should be noted that by fusing the target index pair lists, the specific fusion logic is to merge the lists containing common elements to obtain the fused index pair list, which is represented as follows: {[(0,0,1),(1,0,0)],[(0,1,1),(1,0,1),(1,1,0)]}.

[0204] Step A34: Obtain the un-matched segmentation mask indexes.

[0205] In a specific implementation, continuing as above Figure 3 shown, for example, the subgraphs include M1(0,0), M2(0,1), M3(1,0), and M4(1,1), and the un-matched segmentation mask indexes are [0,0,0], [1,0,2], [0,1,0], [1,1,1].

[0206] Step A35: Obtain the fused image according to the un-matched segmentation mask indexes and the fused index pair list.

[0207] It should be noted that the un-matched segmentation mask indexes and the fused index pair list can be fused to construct the fused image.

[0208] For each fused segmentation mask, set the background to 0, and then traverse each segmentation mask index, and mark the mask area corresponding to the segmentation mask index as 1, so as to obtain 6 binary images, that is, the fused image. Granular fusion is performed on the successfully matched boundary features, including generating the target index pair list and the fused index pair, ensuring the transparency and controllability of the fusion process and improving the quality of the final fused image.

[0209] In this solution, accurate granular fusion is achieved through boundary detection and matching, ensuring that key information will not be lost during the fusion process of the segmented material images and being able to accurately reflect the true structure of the original material, improving the accuracy of particle size measurement.

[0210] In some embodiments, the current material image can be segmented according to the characteristics of the material. Referring to Figure 4 , step S20 may include:

[0211] Step S201: Obtain the material properties.

[0212] It should be noted that the material properties may include the characteristics of the material, such as the average particle size, particle distribution density, mechanical properties, physical properties, etc.

[0213] Step S202: Perform image segmentation on the current material image according to the material properties to obtain multiple segmented material images.

[0214] In a specific implementation, the current material image may be segmented according to the material properties, and the material properties may be used as a condition or reference for segmentation to obtain a segmented material image, that is, a plurality of segmented material images.

[0215] In this scheme, image segmentation is performed according to material properties, making the segmentation process more targeted and scientific, and being able to more accurately reflect the actual structure of the material, providing a better basis for subsequent image recognition and particle size measurement.

[0216] In a feasible implementation, the current material image may be segmented according to the particle size and distribution density in the material properties to obtain a block material image. Then step S202 may include:

[0217] Step B10: Obtaining particle size and particle distribution density according to material properties.

[0218] It is understood that the material properties include the particle size of different materials, and the particle size may be an average particle size, for example, an average particle size of 50 microns. The particle distribution density may be obtained by measuring and counting the physical size of the particles.

[0219] Step B20: Segment the current material image by particle size and particle distribution density to obtain a plurality of segmented material images.

[0220] In a specific implementation, an image segmentation algorithm, such as an improved watershed algorithm or a U-Net model based on deep learning, can be applied to segment the material image. During the segmentation process, the edge of the particle can be detected according to its local features to separate each particle or material region. Finally, multiple block material images are obtained through image segmentation, and each block represents a different material region or particle set. For example, for an image with a resolution of 1024×1024 pixels, it can be segmented into small blocks of 64×64 pixels.

[0221] In this scheme, the particle size and distribution density are taken into consideration for segmentation, which makes the segmentation strategy closer to the actual situation of the material, improves the effect of image segmentation, and thus improves the accuracy of particle size measurement.

[0222] In a feasible implementation, in order to improve the efficiency of image recognition, the trained model can be used to directly perform image recognition and output the recognition result. Figure 5 , step S30 comprises:

[0223] Step S301: input a plurality of block material images into a target image recognition model, extract image features through a backbone network in the target image recognition model, and obtain a first feature map.

[0224] It should be noted that the target image recognition model is a pre-trained model for image recognition, which can be specifically used to recognize the image feature information in each segmented material image. The target image recognition model can be a deep learning model, such as the Mask R-CNN model (Mask Region Convolutional Neural Network model), or the BlendMask model (instance segmentation algorithm model), YOLO (You Only Look Once) series models, etc. This embodiment does not limit this.

[0225] For example, the target image recognition model is the Mask R-CNN model. Mask R-CNN is an image segmentation and object detection model based on deep learning. Its structure is mainly based on Faster R-CNN and adds a branch for instance segmentation. The basic structure of Mask R-CNN includes: Backbone (main network), Region Proposal Network (RPN), RoI Align (Region of Interest Alignment Network), and Head Networks (head network).

[0226] By inputting multiple segmented material images into the target image recognition model, the region features of the segmented material images can be directly output. Using the trained target image recognition model to recognize the segmented material images not only improves the recognition speed but also enhances the recognition accuracy.

[0227] It should be understood that multiple segmented material images can be input into the Mask R-CNN model in sequence. The first part of the Mask R-CNN model, the Backbone (main network), is used to extract image features. The Backbone (main network) is usually a pre-trained convolutional neural network, such as ResNet, VGG, or Xception. By extracting the features of the segmented material images through the main network, a first feature map is generated, and the first feature map contains the high-level features of the segmented material images.

[0228] Step 302: Process the first feature map through the region generation network in the target image recognition model to generate candidate regions.

[0229] In a specific implementation, the region generation network is the Region Proposal Network (RPN). The region generation network is a part of Faster R-CNN and is used to generate candidate regions (Region Proposals). Therefore, the first feature map can be input into the region generation network to generate candidate regions. RPN is a fully convolutional network that runs on the feature map generated by the Backbone and generates multiple candidate regions for each position. Each region has a prediction for object / background classification and bounding box regression.

[0230] Step 303: Extract features from the candidate regions through the region of interest extraction network in the target image recognition model to obtain candidate features.

[0231] After obtaining the candidate regions, the region of interest extraction network RoI Align can be used to extract features from the candidate regions. RoI Align is a key component of Mask R-CNN, which is used to extract the features of each candidate region from the feature map. RoIAlign uses bilinear interpolation to accurately align the feature map and the candidate regions, thus avoiding the quantization error introduced by RoI Pooling.

[0232] Extract features from the candidate regions through the region of interest extraction network, so as to obtain the features of the candidate regions, that is, candidate features.

[0233] Step S304: Perform object detection and instance segmentation on the candidate features through the head network in the target image recognition model to obtain the categories, bounding boxes, and segmentation masks of each piece of material image.

[0234] It should be understood that the head network is the last part of the target image recognition model, including two branches. One is for object detection (including classification and bounding box regression), and the other is for instance segmentation (generating segmentation masks). Therefore, after obtaining the candidate features, the object detection branch and the instance segmentation branch in the head network can be used to perform object detection and instance segmentation on the candidate features respectively. The object detection branch is a fully connected network, which generates an object category prediction and a bounding box regression prediction for each candidate feature, so as to obtain the categories and bounding boxes of each piece of material image.

[0235] The instance segmentation branch is a convolutional network, which generates a segmentation mask prediction for each candidate feature, so as to obtain the segmentation masks of each piece of material image.

[0236] Step S305: Obtain the region features of the piece of material image through the category, bounding box, and segmentation mask.

[0237] It should be noted that after obtaining the category, bounding box, and segmentation mask, the category, bounding box, and segmentation mask can be used as the region features of the piece of material image.

[0238] In specific implementation, when the target image recognition model performs image recognition, it can be loaded first. By converting the current material image into the size expected by the model, such as 128×128 pixels, the image converted into the size expected by the model is input into the target image recognition model, so as to output the category, bounding box, and segmentation mask of each detected object through the target image recognition model.

[0239] It should be noted that the results output by the model may have low confidence. Therefore, after obtaining the category, bounding box, and segmentation mask of each detected object, the image can be further filtered. Thus, step S305 may include: obtaining the object confidence based on the bounding box; filtering the segmented material image based on the object confidence to obtain a filtered segmented material image; obtaining the region features of the segmented material image according to the type, bounding box, and segmentation mask of the filtered segmented material image.

[0240] It should be noted that when the target image recognition model outputs the bounding box, it will also attach the confidence of each object. Therefore, the object confidence can be obtained based on the bounding box. A confidence threshold can be set in advance, such as 0.85, 0.9, etc. When the object confidence is less than the confidence threshold, the corresponding segmented material image will be removed, so as to filter each segmented material image, filter out the detection results with low confidence, thereby obtaining the retained filtered segmented material image, and using the type, bounding box, and segmentation mask of the filtered segmented material image as the final region features of the segmented material image.

[0241] In a specific implementation, the segmentation mask is a binary image. The white area of the binary image represents particles, and the black area represents the background. By evaluating the object confidence to filter the segmented material image, low-quality or irrelevant information is removed, and the most representative part of the image is retained, improving the effectiveness and practicality of the region features of the segmented material image.

[0242] In this solution, the functions of each network layer inside the target image recognition model are deeply analyzed. From image feature extraction to object detection and instance segmentation, this process ensures the high quality of the recognition results and provides a reliable basis for subsequent particle size measurement.

[0243] In a feasible implementation manner, the training process of the target image recognition model includes:

[0244] Obtaining a first training sample and a first validation sample, where the first training sample and the first validation sample include the original material image with a segmentation mask labeled with particles;

[0245] Initializing the deep learning model and determining the training parameters;

[0246] Training the initialized deep learning model with the first training sample and the training parameters to obtain a training result;

[0247] Calculating the loss value according to the training result and the first validation sample;

[0248] Adjusting the training parameters of the initialized deep learning model through the loss value to obtain the target image recognition model.

[0249] It should be noted that the first training sample and the first validation sample are labeled material images. The first training sample and the first validation sample contain the segmentation masks of each particle, and the object category and bounding box correspond to the segmentation masks.

[0250] To improve the generalization ability of the model, it is necessary to perform data augmentation on the first training sample and the first validation sample, such as rotation, flipping, scaling, etc. After data augmentation, the deep learning model can be initialized. The deep learning model is a Mask R-CNN model, using a pre-trained model trained on large datasets such as ImageNet as the basis, and then fine-tuned, which can provide good initialization weights.

[0251] The deep learning model can be initialized using the set initialization method, such as zero initialization method, random initialization method, normal distribution initialization method, etc., and it can also be other initialization methods. For example, if the zero initialization method is used, all the weights in the deep learning model are set to 0, so as to realize the initialization of the deep learning model.

[0252] After the model is initialized, appropriate training parameters can be set, including learning rate, batch size, number of iterations, etc.

[0253] In a specific implementation, the initialized deep learning model can be trained with the first training sample and training parameters. In each iteration, the model predicts the category, bounding box and segmentation mask of the object according to the input image, so as to obtain the training result.

[0254] The true label is determined through the first validation sample, and then the loss is calculated according to the true label and the training result, so as to obtain the loss value. The loss threshold can be set in advance. When the loss value is greater than the loss threshold, the optimizer is used to update the model weights and training parameters, so as to continue training until the loss value is less than or equal to the loss threshold, and the training is stopped to obtain the target image recognition model.

[0255] After the model training is completed, the weights and structure of the model can be saved for subsequent use.

[0256] In this solution, the target image recognition model is obtained by training the model using the training sample and the validation sample. Through the target image recognition model, the segmentation mask in the image can be recognized more quickly and accurately, improving the recognition accuracy and efficiency.

[0257] In a feasible implementation, to improve the image resolution and enhance the detailed information of small particles, after the image is processed in blocks, the block material image can be enlarged. Therefore, referring to Figure 6 , after step S20, it further includes:

[0258] Step S21: Enlarge the images of multiple segmented material images to obtain multiple enlarged segmented material images.

[0259] It should be noted that image enlargement of each segmented material image can be achieved using interpolation methods or image enlargement models. The interpolation methods can be nearest neighbor interpolation, bilinear interpolation, adaptive interpolation algorithms, etc. The image enlargement models can be obtained through pre-training.

[0260] By enlarging the images of multiple segmented material images, multiple enlarged segmented material images are obtained.

[0261] It can be understood that after image enlargement, the process of image recognition is to perform image recognition on the enlarged segmented material images. Therefore, performing image recognition on multiple segmented material images to obtain the regional features of the segmented material images includes: performing image recognition on multiple enlarged segmented material images to obtain the regional features of the segmented material images.

[0262] In a specific implementation, the target image recognition model can be used to perform image recognition on multiple enlarged segmented material images, thereby obtaining the regional features of the segmented material images.

[0263] In this solution, by enlarging the segmented material images, the problem of difficult recognition caused by insufficient image resolution is solved, and the accuracy of image recognition is improved.

[0264] In a feasible implementation manner, to improve the image enlargement efficiency, a pre-trained image enlargement model can be used to enlarge the segmented material images. Refer to Figure 7 , Step S21 includes:

[0265] Step C10: Input multiple segmented material images into the target generator in the image enlargement model, and use the target generator to enlarge the images of multiple segmented material images to obtain segmented images with the target resolution.

[0266] It should be noted that the image enlargement model can be an SRGAN model (Super-Resolution Generative Adversarial Network, a deep learning model for image super-resolution), or a DRRN (Deep Recursive Residual Network), LapSRN (Laplacian Pyramid Super-Resolution Network) model, or other models that can perform image enlargement. This embodiment does not limit this.

[0267] For example, by sequentially inputting multiple segmented material images into the SRGAN model, SRGAN (Super-Resolution Generative Adversarial Network) is a deep learning model for image super-resolution. By adopting a deep learning-based super-resolution reconstruction algorithm, the segmented material images can be magnified by 2 times, for example, the image resolution can be increased to 128×128 pixels.

[0268] The structure of the image magnification model includes: a target generator (Generator) and a target discriminator (Discriminator).

[0269] It should be noted that the target generator is used to convert low-resolution images into high-resolution images. Therefore, after each segmented material image is input into the target generator, the target generator can magnify the segmented material image to obtain a high-resolution segmented image, and the target resolution can be 128×128 pixels.

[0270] In a feasible implementation manner, the target generator is usually based on the ResNet (Residual Network) structure, and specifically may include a pre-upsampling layer, residual blocks, and a post-processing layer. Then step C10 includes: inputting multiple segmented material images into the target generator, magnifying the size through the pre-upsampling layer in the target generator to obtain an initial segmented material image; extracting features and performing residual connection on the initial segmented material image through the residual blocks in the target generator to obtain a reference segmented material image; performing convolution and size magnification on the reference segmented material image through the post-processing layer in the target generator to obtain a segmented image with the target resolution.

[0271] The pre-upsampling layer includes a preprocessing convolutional layer and an upsampling layer. Therefore, the segmented material image can be input into the pre-upsampling layer in the target generator. First, the input low-resolution segmented material image is preprocessed through one or more convolutional layers, and the preprocessed segmented material image is magnified in size through the upsampling layer (such as nearest neighbor interpolation or transposed convolution layer) by a certain resolution, for example, magnifying a small block of 64×64 pixels to a segmented image of 96×96 pixels, that is, magnifying 1.5 times.

[0272] After obtaining the initial segmented material image, the initial segmented material image can be processed through residual blocks. The residual blocks are the core part of the target generator. The number of residual blocks can be multiple. Each residual block contains two 3x3 convolutional layers, and each convolutional layer is followed by a batch normalization layer and an activation function (such as PReLU). The design of the residual blocks enables the network to learn more complex feature maps and avoids the problem of gradient vanishing. Therefore, feature extraction and residual connection can be performed on the initial segmented material image through the residual blocks. The initial segmented material image first undergoes feature extraction through the convolutional layer and then is added to the original input to form a residual connection, thereby obtaining the reference segmented material image.

[0273] The post-processing layer is a process of post-processing the reference segmented material image. The post-processing layer is located at the end of the target generator, and its purpose is to perform final optimization on the generated high-resolution image to improve the visual quality and realism of the image. Therefore, the reference segmented material image can be convolved through one or more convolutional layers in the post-processing layer, and the size of the convolved image can be enlarged again through the upsampling layer in the post-processing layer, thereby converting the feature map into a high-resolution image, that is, the target resolution segmented image. The target resolution can be a segmented image of 128×128 pixels. The functions of each layer inside the target generator are described in detail, such as the functions of the pre-upsampling layer, residual blocks, and post-processing layer, ensuring the efficiency and stability of image magnification and enhancing the visual effect and analysis value after image magnification.

[0274] Step C11: Input the target resolution segmented image into the target discriminator in the image magnification model, and the target discriminator discriminates the target resolution segmented image to obtain a probability value.

[0275] It should be noted that the target discriminator is used to distinguish between the generated high-resolution image and the real high-resolution image.

[0276] Therefore, after the target resolution segmented image is input into the target discriminator, the target discriminator can verify the segmented material image, thereby converting the feature map into a probability value. The probability value represents the probability that the input target resolution segmented image is a real image.

[0277] In a feasible implementation manner, the target discriminator is usually a convolutional neural network, including the following main components: convolutional layer, pooling layer, and fully connected layer. Therefore, step C11 specifically includes: inputting the target resolution segmented image into the target discriminator, performing convolution, normalization, and activation on the target resolution segmented image through multiple convolutional layers, normalization layers, and activation functions in the target discriminator to obtain a non-linear activation map; performing pooling on the non-linear activation map through the pooling layer in the target discriminator to obtain a second feature map; and converting the second feature map through the fully connected layer in the target discriminator to obtain a probability value.

[0278] It should be noted that the target discriminator processes the input target resolution block image through multiple convolutional layers, and a batch normalization layer and an activation function are provided after each convolutional layer. The activation function can be LeakyReLU, or it can also be ReLU activation function, Sigmoid activation function, Softmax activation function, etc. The convolutional layer, batch normalization layer, and activation function are used to perform convolution, normalization, and activation on the target resolution block image in sequence, so as to obtain a non-linear activation map. After each convolutional layer, there is usually a batch normalization layer (BatchNormalization), which helps to accelerate the training process, reduce internal covariate shift, and improve the generalization ability of the model. The activation function (such as LeakyReLU) is applied to the output after batch normalization to introduce non-linearity, enabling the network to learn more complex feature representations. LeakyReLU allows small gradients when the input is negative, which helps to avoid the problem of gradient vanishing.

[0279] After obtaining the non-linear activation map, the target discriminator reduces the spatial dimension of the feature map through a pooling layer while retaining the most important feature information. Specifically, pooling is performed through the pooling layer, such as max pooling or average pooling, so as to reduce the size of the non-linear activation map while retaining the density of the features, and obtain the second feature map.

[0280] Finally, the target discriminator converts the second feature map into a probability value through one or more fully connected layers, representing the probability that the input target resolution block image is a real image. For example, the output probability value is 0.8, 0.9, etc. The above content specifically elaborates on how the target discriminator evaluates the enlarged image through convolutional layers, normalization layers, activation functions, and pooling layers, and finally outputs a probability value, ensuring the scientificity and objectivity of the quality evaluation process of the enlarged image.

[0281] Step C12: When the probability value is greater than or equal to the preset threshold, use the target resolution block image as the enlarged block material image.

[0282] It should be noted that the preset threshold can be set to a relatively high value for evaluating whether the target resolution block image is retained. For example, the preset threshold is set to 0.9. If the probability value output by the target discriminator is less than 0.9, the corresponding target resolution block image is excluded. If the probability value output by the target discriminator is greater than or equal to 0.9, the target resolution block image is retained and used as the final enlarged block material image. By setting the preset threshold, the block images that meet the true resolution are screened out, improving the effect and authenticity of image enlargement.

[0283] In this solution, an image magnification model including a target generator and a target discriminator is used to achieve efficient image magnification while ensuring the quality and authenticity of the magnification, which helps improve the accuracy of subsequent image recognition and particle size measurement.

[0284] In a feasible implementation, the training process of the image magnification model includes:

[0285] Obtain a second training sample and a third training sample, where the second training sample and the third training sample are material images with an initial resolution;

[0286] Input the second training sample into the initial generator to generate target sample data;

[0287] Input the third training sample and the target sample data into the initial discriminator for determination to obtain a determination result;

[0288] Adjust the parameters through the determination result to train the initial generator and the initial discriminator to obtain a target generator and a target discriminator;

[0289] Obtain an image magnification model through the target generator and the target discriminator.

[0290] It should be noted that both the second training sample and the third training sample are low-resolution material images, and the initial resolution is low resolution.

[0291] In a specific implementation, the second training sample can be input into the initial generator through an adversarial generator to generate target sample data. The target sample data can be used as a training condition for whether the initial generator ends training. The target sample data is a high-resolution image output by the initial generator, and this image should be visually similar to a real high-resolution image.

[0292] The third training sample is used as real sample data. By inputting the target sample data and the third training sample representing the real sample into the initial discriminator to determine the authenticity of the input sample, a determination result can be obtained. The determination result can be that the sample is a real sample or the sample is a fake sample.

[0293] In a specific implementation, the parameters of the initial generator and the initial discriminator can be adjusted according to the determination result to train the initial generator and the initial discriminator until a target generator and a target discriminator are obtained.

[0294] The initial generator and the initial discriminator are trained alternately. First, the initial generator is fixed and the initial discriminator is trained; then the initial discriminator is fixed and the initial generator is trained. Iteration process: This process will be iterated multiple times until the quality of the images generated by the initial generator is high enough that the discriminator cannot distinguish between real and fake images, or until a predetermined number of iterations is reached. The target generator and the target discriminator are obtained, and an image magnification model is constructed. Model saving: During the training process, the weights of the model can be saved regularly for subsequent use or further fine-tuning. This adversarial training method can drive the generator to generate higher-quality images, while the discriminator is also continuously improving its discrimination ability, ultimately achieving the goal of generating high-resolution and realistic images.

[0295] In this solution, it is described that the image magnification model continuously optimizes the generator and the discriminator through training. This training method improves the robustness and adaptability of the model, enabling it to produce high-quality magnification results when processing various material images.

[0296] It should be noted that after obtaining the fused image, the material can be subjected to particle size measurement based on the fused image. Therefore, referring to Figure 8 , step S50 includes:

[0297] Step S501: Obtain the number of pixels according to the fused image.

[0298] It should be noted that since the fused image is a binary image, the area of the particles, that is, the number of pixels, can be obtained based on the binary image of the fused image, denoted as S.

[0299] Step S502: Calculate the equivalent diameter of the pixel unit according to the number of pixels.

[0300] In a specific implementation, the equivalent diameter is defined as the diameter of a circle equal to the area of the particle. According to the area formula of a circle: S = 1 / 4 × π × D 2 It can be known that D = (4S / π) 0.5 , thus obtaining the equivalent diameter D.

[0301] Step S503: Convert the equivalent diameter of the pixel unit to obtain the equivalent diameter of the material particles.

[0302] In a specific implementation, according to the scale of the current material image, the equivalent diameter of the pixel unit can be converted, thereby converting it into the equivalent diameter in microns of the material particles in the real world. Assuming that m pixels in the image represent n microns, then the equivalent diameter of the material particles = D / m × n microns.

[0303] As Figure 9 shown, Figure 9 is a schematic diagram of the particle recognition effect of a certain material. The left side is the particle image of a certain material before recognition, and the right side is the recognition result after recognition.

[0304] In this solution, the equivalent diameter of material particles is calculated based on the fused image, converting the image information into specific physical quantities, completing a complete closed-loop from image analysis to particle size measurement, and providing important technical support for materials science research and industrial applications.

[0305] It should be noted that the above examples are only for understanding this application and do not constitute a limitation on the material particle size measurement method of this application. Based on this technical concept, more forms of simple transformations are within the protection scope of this application.

[0306] This application also provides a material particle size measurement device. Please refer to Figure 10 , the material particle size measurement device includes:

[0307] An acquisition module 10, configured to acquire the current material image.

[0308] A segmentation module 20, configured to perform image segmentation on the current material image to obtain multiple segmented material images.

[0309] An identification module 30, configured to perform image identification on multiple segmented material images to obtain the region features of the segmented material images.

[0310] A fusion module 40, configured to perform particle fusion processing on multiple segmented material images based on the region features of the segmented material images to obtain a fused image.

[0311] A measurement module 50, configured to measure the particle size of the material according to the fused image.

[0312] The material particle size measurement device provided by this application adopts the material particle size measurement method in the above embodiment, and can solve the technical problems that the current material particle size measurement has high requirements for hardware and poor recognition effect. Compared with the prior art, the beneficial effects of the material particle size measurement device provided by this application are the same as those of the material particle size measurement method provided by the above embodiment, and other technical features in the material particle size measurement device are the same as those disclosed in the above embodiment method, and will not be elaborated here.

[0313] In one embodiment, the fusion module 40 is further configured to perform boundary detection on multiple segmented material images based on the region features of the segmented material images to obtain the boundary features of each segmented material image; perform boundary matching based on the boundary features to obtain a matching result; and perform particle fusion based on the boundary features when the matching result shows that the boundary features match consistently to obtain a fused image.

[0314] In one embodiment, the fusion module 40 is further configured to obtain a segmentation mask for each segmented material image based on the regional features of the segmented material images; perform boundary detection on each segmented material image according to the segmentation mask to obtain a boundary segmentation mask; and obtain the boundary features of each segmented material image.

[0315] In one embodiment, the fusion module 40 is further configured to obtain a sub - image index for each segmented material image; obtain the index number of the segmentation mask in the corresponding segmented material image; obtain the segmentation mask index in each segmented material image according to the sub - image index and the index number; and determine the boundary segmentation mask according to the segmentation mask index.

[0316] In one embodiment, the fusion module 40 is further configured to determine the boundary segmentation mask based on the boundary features; obtain the boundary segmentation mask index of the boundary segmentation mask; and perform boundary matching through the boundary segmentation mask index to obtain a matching result.

[0317] In one embodiment, the fusion module 40 is further configured to match the target segmentation mask of each boundary segmentation mask through the boundary segmentation mask index; when the target segmentation mask is matched, determine that the matching result is that the boundary features match; and when the target segmentation mask is not matched, determine that the matching result is that the boundary features do not match.

[0318] In one embodiment, the fusion module 40 is further configured to, when the matching result is that the boundary features match, obtain the target segmentation mask based on the boundary features; obtain the target segmentation mask index; pair the target segmentation mask indexes to obtain a target index pair, and summarize the target index pairs to obtain a target index pair list; fuse the target index pair list to obtain a fused index pair list; obtain the segmentation mask indexes that are not matched; and obtain a fused image according to the unmatched segmentation mask indexes and the fused index pair list.

[0319] In one embodiment, the segmentation module 20 is further configured to obtain the material properties; perform image segmentation on the current material image according to the material properties to obtain a plurality of segmented material images.

[0320] In one embodiment, the segmentation module 20 is further configured to obtain the particle size and the particle distribution density according to the material properties; perform image segmentation on the current material image through the particle size and the particle distribution density to obtain a plurality of segmented material images.

[0321] In one embodiment, the recognition module 30 is further configured to input multiple segmented material images into a target image recognition model, extract image features through a backbone network in the target image recognition model to obtain a first feature map; process the first feature map through a region generation network in the target image recognition model to generate candidate regions; extract features from the candidate regions through an interested region extraction network in the target image recognition model to obtain candidate features; perform object detection and instance segmentation on the candidate features through a head network in the target image recognition model to obtain the category, bounding box, and segmentation mask of each segmented material image; and obtain the region features of the segmented material images based on the category, bounding box, and segmentation mask. In one embodiment, the recognition module 30 is further configured to obtain an object confidence based on the bounding box; filter the segmented material images based on the object confidence to obtain filtered segmented material images; and obtain the region features of the segmented material images based on the type, bounding box, and segmentation mask of the filtered segmented material images.

[0322] In one embodiment, the recognition module 30 is further configured to obtain a first training sample and a first validation sample, where the first training sample and the first validation sample include original material images with segmentation masks labeled with particles; initialize a deep learning model and determine training parameters; train the initialized deep learning model with the first training sample and the training parameters to obtain a training result; calculate a loss value based on the training result and the first validation sample; and adjust the training parameters of the initialized deep learning model through the loss value to obtain a target image recognition model.

[0323] In one embodiment, the material particle size measuring device further includes a magnification module, which is configured to magnify multiple segmented material images to obtain multiple magnified segmented material images; and the recognition module 30 is further configured to perform image recognition on the multiple magnified segmented material images to obtain the region features of the segmented material images.

[0324] In one embodiment, the magnification module is further configured to input multiple segmented material images into a target generator in an image magnification model, magnify the multiple segmented material images through the target generator to obtain target resolution segmented images; input the target resolution segmented images into a target discriminator in the image magnification model, and discriminate the target resolution segmented images through the target discriminator to obtain a probability value; and use the target resolution segmented images as magnified segmented material images when the probability value is greater than or equal to a preset threshold.

[0325] In one embodiment, the amplification module is further configured to input multiple segmented material images into a target generator in an image amplification model, perform size amplification through a pre-upsampling layer in the target generator to obtain an initial segmented material image; perform feature extraction and residual connection on the initial segmented material image through a residual block in the target generator to obtain a reference segmented material image; and perform convolution and size amplification on the reference segmented material image through a post-processing layer in the target generator to obtain a segmented image with a target resolution.

[0326] In one embodiment, the amplification module is further configured to input the segmented image with the target resolution into a target discriminator in the image amplification model, perform convolution, normalization, and activation on the segmented image with the target resolution through multiple convolutional layers, normalization layers, and activation functions in the target discriminator to obtain a non-linear activation map; perform pooling on the non-linear activation map through a pooling layer in the target discriminator to obtain a second feature map; and perform conversion on the second feature map through a fully-connected layer in the target discriminator to obtain a probability value.

[0327] In one embodiment, the amplification module is further configured to obtain a second training sample and a third training sample, where the second training sample and the third training sample are material images with an initial resolution; input the second training sample into an initial generator to generate target sample data; input the third training sample and the target sample data into an initial discriminator for determination to obtain a determination result; adjust parameters through the determination result to train the initial generator and the initial discriminator to obtain a target generator and a target discriminator; and obtain an image amplification model through the target generator and the target discriminator.

[0328] In one embodiment, the measurement module 50 is further configured to obtain the number of pixels according to the fused image; calculate the equivalent diameter of a pixel unit according to the number of pixels; and perform conversion on the equivalent diameter of the pixel unit to obtain the equivalent diameter of the material particles.

[0329] This application provides a material particle size measurement device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein, the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the material particle size measurement method in the first embodiment above.

[0330] Next, refer to Figure 11, which shows a schematic structural diagram of a material particle size measuring device suitable for implementing the embodiments of the present application. The material particle size measuring device in the embodiments of the present application may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistant), PADs (Portable Application Description: tablet computers), PMPs (Portable Media Player), in-vehicle terminals (such as in-vehicle navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Figure 11 The shown material particle size measuring device is merely an example and should not impose any limitations on the functions and usage scope of the embodiments of the present application.

[0331] As Figure 11 shown, the material particle size measuring device may include a processing device 1001 (such as a central processing unit, a graphics processing unit, etc.), which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM: Read Only Memory) 1002 or the program loaded from the storage device 1003 into the random access memory (RAM: Random Access Memory) 1004. In the RAM 1004, various programs and data required for the operation of the material particle size measuring device are also stored. The processing device 1001, the ROM 1002, and the RAM 1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems may be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touchpad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the material particle size measuring device to communicate with other devices wirelessly or wiredly to exchange data. Although the figure shows a material particle size measuring device with various systems, it should be understood that it is not required to implement or have all the shown systems. More or fewer systems may be alternatively implemented or had.

[0332] In particular, according to the embodiments disclosed in the present application, the processes described above with reference to the flowcharts can be implemented as computer software programs. For example, the embodiments disclosed in the present application include a computer program product that includes a computer program carried on a computer-readable medium, and the computer program contains program codes for executing the methods shown in the flowcharts. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by a processing device 1001, the above-mentioned functions defined in the methods of the embodiments disclosed in the present application are executed.

[0333] The material particle size measurement device provided by the present application adopts the material particle size measurement method in the above-mentioned embodiment, and can solve the technical problems that the current material particle size measurement has high hardware requirements and poor recognition effects. Compared with the prior art, the beneficial effects of the material particle size measurement device provided by the present application are the same as those of the material particle size measurement method provided by the above-mentioned embodiment, and other technical features in the material particle size measurement device are the same as the features disclosed in the method of the previous embodiment, which will not be elaborated here.

[0334] It should be understood that the various parts disclosed in the present application can be implemented by hardware, software, firmware, or a combination thereof. In the description of the above embodiments, specific features, structures, materials, or characteristics can be combined in a suitable manner in any one or more embodiments or examples.

[0335] The above is only the specific implementation manner of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed in the present application, and all of them should be covered by the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

[0336] The present application provides a computer-readable storage medium having computer-readable program instructions (i.e., computer programs) stored thereon, and the computer-readable program instructions are used to execute the material particle size measurement method in the above-mentioned embodiment.

[0337] The computer-readable storage medium provided by the present application can be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or components, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: electrical connections with one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM) or flash memory, optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the above. In this embodiment, the computer-readable storage medium can be any tangible medium that contains or stores a program, and this program can be used by or in combination with an instruction execution system, device, or component. The program code contained on the computer-readable storage medium can be transmitted by any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency), etc., or any suitable combination of the above.

[0338] The above computer-readable storage medium can be included in a material particle size measurement device; or it can exist separately without being assembled into the material particle size measurement device.

[0339] The above computer-readable storage medium carries one or more programs. When the above one or more programs are executed by a material particle size measurement device, the material particle size measurement device can acquire the current material image; perform image segmentation on the current material image to obtain multiple segmented material images; perform image recognition on the multiple segmented material images to obtain the regional features of the segmented material images; perform particle fusion processing on the multiple segmented material images based on the regional features of the segmented material images to obtain a fused image; and perform particle size measurement of the material according to the fused image.

[0340] Computer program code for performing the operations of this application can be written in one or more programming languages or combinations thereof. The above-mentioned programming languages include object-oriented programming languages such as Java, Smalltalk, C++, and also include conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, executed as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any kind of network, including a local area network (LAN: Local Area Network) or a wide area network (WAN: Wide Area Network), or it can be connected to an external computer (for example, by connecting through the Internet using an Internet service provider).

[0341] The flowcharts and block diagrams in the accompanying drawings illustrate the possible architectures, functions, and operations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in the flowchart or block diagram can represent a module, a program segment, or a part of the code, and this module, program segment, or part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the blocks can occur in a different order than marked in the accompanying drawings. For example, two consecutively represented blocks can actually be executed substantially in parallel, and they can sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and / or flowchart, and the combination of blocks in the block diagram and / or flowchart, can be implemented by a dedicated hardware-based system for performing the specified functions or operations, or can be implemented by a combination of dedicated hardware and computer instructions.

[0342] The modules described in the embodiments of this application can be implemented in software or in hardware. Among them, the name of the module does not constitute a limitation on the unit itself in some cases.

[0343] The readable storage medium provided in this application is a computer-readable storage medium. The computer-readable storage medium stores computer-readable program instructions (i.e., computer programs) for performing the above-mentioned material particle size measurement method, and can solve the technical problems of high hardware requirements and poor recognition effects in current material particle size measurement. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as those of the material particle size measurement method provided in the above embodiments, and will not be elaborated here.

[0344] The present application also provides a computer program product, including a computer program which, when executed by a processor, implements the steps of the material particle size measurement method as described above.

[0345] The computer program product provided by the present application can solve the technical problems that the current material particle size measurement has high hardware requirements and poor recognition effect. Compared with the prior art, the beneficial effects of the computer program product provided by the present application are the same as those of the material particle size measurement method provided by the above embodiments, and will not be elaborated herein.

[0346] The above are only partial embodiments of the present application, and do not limit the patent scope of the present application accordingly. Any equivalent structural transformation made by using the content of the specification and drawings of the present application under the technical concept of the present application, or any direct / indirect application in other related technical fields shall be included within the patent protection scope of the present application.

Claims

1. A material particle size measurement method, characterized in that: The material particle size measurement method comprises: Get the current material image; Performing image segmentation on the current material image to obtain a plurality of segmented material images; Performing image recognition on the plurality of images of the block materials to obtain regional features of the images of the block materials; Obtaining a segmentation mask for each block material image based on the block material image region features; Get the sub-image index of each block material image; Obtaining the index number of the segmentation mask in the corresponding block material image; Obtaining a segmentation mask index in each block material image according to the sub-image index and the index number; Determining a boundary segmentation mask according to the segmentation mask index; Obtaining boundary features of each block material image according to the boundary segmentation mask; Perform boundary matching based on the boundary features to obtain a matching result; When the matching result is that the boundary features match consistently, performing particle fusion based on the boundary features to obtain a fused image; The particle size of the material is measured based on the fused image.

2. The method according to claim 1, characterized in that The performing boundary matching based on the boundary feature to obtain a matching result includes: determining a boundary segmentation mask based on the boundary features; Obtaining a boundary segmentation mask index of the boundary segmentation mask; Boundary matching is performed using the boundary segmentation mask index to obtain a matching result.

3. The method according to claim 2, characterized in that The boundary matching is performed by using the boundary segmentation mask index to obtain a matching result including: Matching the target segmentation mask of each boundary segmentation mask by the boundary segmentation mask index; When matching the target segmentation mask, determining the matching result as a boundary feature match consistency; When the target segmentation mask is not matched, it is determined that the matching result is inconsistent with the boundary feature matching.

4. The method according to claim 1, characterized in that When the matching result is that the boundary features match consistently, performing particle fusion based on the boundary features to obtain a fused image includes: When the matching result is that the boundary features match consistently, obtaining a target segmentation mask based on the boundary features; Get the target segmentation mask index; Pairing the target segmentation mask indexes to obtain target index pairs, and summarizing the target index pairs to obtain a target index pair list; Merging the target index pair lists to obtain a fused index pair list; Get the segmentation mask index that does not match the consistency; A fused image is obtained according to the unmatched segmentation mask index and the fusion index pair list.

5. The method according to claim 1, characterized in that The performing image segmentation on the current material image to obtain a plurality of segmented material images comprises: Get material properties; The current material image is segmented according to the material properties to obtain a plurality of segmented material images.

6. The method according to claim 5, characterized in that The performing image segmentation on the current material image according to the material attribute to obtain a plurality of segmented material images comprises: Obtaining particle size and particle distribution density according to the material properties; The current material image is segmented according to the particle size and the particle distribution density to obtain a plurality of segmented material images.

7. The method according to claim 1, characterized in that The performing image recognition on the plurality of block material images to obtain the block material image region features comprises: Inputting a plurality of the block material images into a target image recognition model, extracting image features through a backbone network in the target image recognition model, and obtaining a first feature map; Processing the first feature map through a region generation network in the target image recognition model to generate a candidate region; Extracting features from the candidate region through an interest extraction network in the target image recognition model to obtain candidate features; Performing object detection and instance segmentation on the candidate features through the head network in the target image recognition model to obtain the category, bounding box and segmentation mask of each block material image; The block material image region features are obtained through the category, the bounding box and the segmentation mask.

8. The method according to claim 7, characterized in that The obtaining of the block material image region feature by the category, the bounding box and the segmentation mask comprises: Obtaining object confidence according to the bounding box; filtering the block material image based on the object confidence to obtain a filtered block material image; The block material image region features are obtained according to the type, the boundary box and the segmentation mask of the filtered block material image.

9. The method according to claim 7, characterized in that The target image recognition model is trained in the following manner, including: Acquire a first training sample and a first verification sample, wherein the first training sample and the first verification sample include original material images with segmentation masks marked with particles; Initialize the deep learning model and determine the training parameters; Training the initialized deep learning model using the first training sample and the training parameters to obtain a training result; Calculate a loss value according to the training result and the first verification sample; The training parameters of the initialized deep learning model are adjusted using the loss value to obtain the target image recognition model.

10. The method according to claim 1, characterized in that The method further comprises: Amplifying the plurality of the block material images to obtain a plurality of amplified block material images; Correspondingly, performing image recognition on the plurality of block material images to obtain the block material image region features includes: Image recognition is performed on the plurality of enlarged block material images to obtain the block material image region features.

11. The method according to claim 10, characterized in that The performing image recognition on the plurality of enlarged block material images to obtain the block material image area features comprises: Inputting the plurality of block material images into a target generator in an image magnification model, and performing image magnification on the plurality of block material images through the target generator to obtain a block image of a target resolution; Inputting the target resolution block image into a target discriminator in an image magnification model, and discriminating the target resolution block image through the target discriminator to obtain a probability value; When the probability value is greater than or equal to a preset threshold, the target resolution block image is used as the enlarged block material image.

12. The method according to claim 11, characterized in that Inputting the plurality of block material images into a target generator in an image magnification model, and performing image magnification on the plurality of block images by the target generator to obtain block images of target resolution comprises: Inputting a plurality of the block material images into a target generator in an image magnification model, and magnifying the size of the images through a pre-upsampling layer in the target generator to obtain an initial block material image; Perform feature extraction and residual connection on the initial block material image through the residual block in the target generator to obtain a reference block material image; The reference block material image is convolved and scaled up through a post-processing layer in the target generator to obtain a target resolution block image.

13. The method according to claim 11, characterized in that The step of inputting the target resolution block image into a target discriminator in the image magnification model and discriminating the target resolution block image by the target discriminator to obtain a probability value includes: Inputting the target resolution block image into a target discriminator in an image magnification model, convolving, normalizing and activating the target resolution block image through multiple convolution layers, normalization layers and activation functions in the target discriminator to obtain a nonlinear activation map; Pooling the nonlinear activation map through a pooling layer in the target discriminator to obtain a second feature map; The second feature map is transformed through a fully connected layer in the target discriminator to obtain a probability value.

14. The method according to claim 11, characterized in that The image magnification model is trained in the following manner, including: Acquire a second training sample and a third training sample, wherein the second training sample and the third training sample are material images with an initial resolution; Inputting the second training sample into the initial generator to generate target sample data; Inputting the third training sample and the target sample data into an initial discriminator for determination to obtain a determination result; Adjusting parameters according to the determination result to train the initial generator and the initial discriminator to obtain a target generator and a target discriminator; An image magnification model is obtained through the target generator and the target discriminator.

15. The method according to any one of claims 1 to 14, characterized in that The measuring the particle size of the material according to the fused image comprises: Acquire the number of pixels according to the fused image; Calculating an equivalent diameter of a pixel unit according to the number of pixels; The equivalent diameter of the pixel unit is converted to obtain the equivalent diameter of the material particles.

16. A material particle size measuring device, characterized in that: The device comprises: An acquisition module is used to acquire the current material image; A segmentation module, used for performing image segmentation on the current material image to obtain a plurality of segmented material images; A recognition module, used for performing image recognition on the plurality of block material images to obtain regional features of the block material images; A fusion module, used for obtaining a segmentation mask of each block material image based on the regional features of the block material image; Get the sub-image index of each block material image; Obtaining the index number of the segmentation mask in the corresponding block material image; Obtaining a segmentation mask index in each block material image according to the sub-image index and the index number; Determining a boundary segmentation mask according to the segmentation mask index; Obtaining boundary features of each block material image according to the boundary segmentation mask; Perform boundary matching based on the boundary features to obtain a matching result; When the matching result is that the boundary features match consistently, particles are fused based on the boundary features to obtain a fused image. The measuring module is used to measure the particle size of the material according to the fused image.

17. A material particle size measuring device, characterized in that: The device comprises: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of the material particle size measurement method according to any one of claims 1 to 15.

18. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of the material particle size measurement method according to any one of claims 1 to 15 are implemented.

Citation Information

Patent Citations

  • Image recognition method and device, equipment and storage medium

    CN115115872A

  • Granularity detection method, device, equipment, medium and program product

    CN119027928A