Powder hollowness rate grading and particle size distribution statistical method and system
The powder image is preprocessed and enhanced through the hybrid supervision classification model, which solves the problem of real-time monitoring of hollow powder hollow rate and particle size distribution, and realizes efficient non-destructive detection and automated grading, improving detection accuracy and efficiency.
Patent Information
- Application Number
- CN202510458284.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-14
- Publication Date
- 2025-07-11
AI Technical Summary
It is difficult for the prior art to realize real-time quality monitoring of the hollow rate and particle size distribution of hollow powders, and deep learning-based detection algorithms are poor in complex industrial scenarios, traditional methods have low manual recognition efficiency and high algorithm identification and labeling cost.
A hybrid supervision classification model is adopted, combined with full supervision and semi-supervised training branches, by pre-processing and enhancing the powder images, the strong characterization ability of the pre-trained visual model is used to design a cross-enhanced consistency loss function, optimize the labeled data and unlabeled data, and realize the hollow rate level identification and particle size distribution statistics of powder particles.
The non-destructive detection of powder particles and fully automated hollow rate quantitative grading are realized, which reduces the artificial dependence of image annotation, improves detection efficiency and accuracy, and provides industrial-grade quality inspection and analysis capabilities.
Smart Images

Figure CN120293791A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of non-destructive testing of materials, and particularly to a method and system for powder hollowness grading and particle size distribution statistics. Background Art
[0002] In the high-end powder industry, accurate analysis of the hollowness and particle size distribution of hollow powders directly affects material properties, such as the catalytic efficiency and heat insulation of materials.
[0003] Currently, there are two mainstream analysis methods for the hollowness and particle size distribution of hollow powders. One is the traditional analysis method that relies on destructive electron microscopy or inefficient manual statistics. However, the traditional analysis method is difficult to meet the requirement of real-time quality monitoring of the hollowness and particle size of powders in industrial production lines. The other is the detection algorithm based on deep learning. Although the detection algorithm based on deep learning can realize full automation of hollowness quantification grading and particle size statistics and improve the detection efficiency, the detection algorithm based on deep learning currently faces two major core contradictions: fully supervised learning relies on a large number of refined and high-cost pixel annotations, and the cost of manual single-icon annotation > 30 minutes; while the weak supervision method (such as rectangular box annotation) has an increased error rate of particle size grade misjudgment due to the lack of specific edges of powders. Although unlabeled data can be utilized, due to the particularity of powder particles - including fine-grained morphological differences (such as unclear edges and fuzzy hollowness grades) and the sparsity of weak supervision signals, it leads to the amplification of pseudo-label noise. The generated coarse-grained labels (such as graffiti annotation, point annotation) are prone to introduce boundary blur errors in the particle adhesion area, and the traditional pre-trained model cannot distinguish overlapping powders, resulting in poor recognition effect of the hollowness grade and poor generalization in complex industrial scenarios.
[0004] Despite the powerful zero-shot generalization ability of recently emerging general segmentation large models (such as the SAM general image segmentation large model) in natural images, its underlying architecture is designed for semantic objects in natural scenes and has a large difference from the microscopic features of powder particles. Natural objects usually have regular topological structures (such as vehicles, animals), while the fragmentation, porosity, and irregular contours of particles cause the segmentation mechanism of the SAM general image segmentation large model to fail.
[0005] Therefore, the existing technology needs to be further developed. Summary of the Invention
[0006] Aiming at the deficiencies of the existing technology, the present invention provides a method and system for powder hollowness grading and particle size distribution statistics to solve the technical problem that the recognition effect of the hollowness grade of hollow powders in related technologies is not ideal.
[0007] To achieve the above technical objectives, the present invention adopts the following technical solutions: A method for powder hollow rate grading and particle size distribution statistics is provided, including: obtaining a powder image containing powder particles; preprocessing the powder image to obtain a standardized file; inputting the standardized file into a preset hybrid supervised classification model to obtain hollow rate level prediction data of the powder particles; and obtaining the hollow rate grading and particle size distribution statistics results of the powder particles based on the hollow rate level prediction data.
[0008] Further, the powder particles include standard powder particles and non-standard powder particles. Among them, the standard powder particles include powder particles with clear, closed edge contours that do not cross or overlap with the edge contours of other powder particles; the non-standard powder particles include powder particles with unclear edge contours, powder particles with unclosed edge contours, and powder particles whose edge contours cross or overlap with the edge contours of other powder particles.
[0009] Further, the method for preprocessing the powder image includes: annotating the powder particles according to the types of the powder particles in the powder image; masking the annotated powder image based on a preset masking method; performing enhancement processing on the masked powder image using a preset enhancement module, where the preset enhancement module includes a strong enhancement module and a weak enhancement module, the strong enhancement module includes random occlusion and random fusion, and the weak enhancement module includes rotation, translation, and brightness adjustment; and adjusting the resolution of the powder image obtained by the enhancement processing to obtain a standardized file.
[0010] Further, the preset masking method includes: extracting features from the annotation area of the standard powder particles to obtain the particle level of the standard powder particles, and generating a masking file based on the particle level; and performing vector conversion on the standard contour of the annotation area of the non-standard powder particles to generate a masking file.
[0011] Further, the preset hybrid supervised model includes a fully supervised training branch and a semi-supervised training branch. The fully supervised training branch is trained with manually annotated powder images, and the semi-supervised training branch is trained with unannotated powder images. The network structures of the fully supervised training branch and the semi-supervised training branch are the same.
[0012] Further, the network structures of both the fully supervised training branch and the semi-supervised training branch use a vision-based model as the feature extraction backbone, and a low-rank adaptation layer is inserted into each Transformer module of the fully supervised training branch and the semi-supervised training branch.
[0013] Further, the method for obtaining the prediction data of the hollowness rate level of powder particles includes: obtaining the supervised loss based on the fully supervised training branch; obtaining the semi-supervised loss based on the semi-supervised training branch; obtaining the total loss data of the semi-supervised training branch based on the supervised loss, the semi-supervised loss, and a preset weight; and if the total loss data meets the preset standard, completing the training of the semi-supervised training branch.
[0014] Further, the method for obtaining the statistical result of the particle size distribution of powder particles includes: obtaining the hollowness rate level of powder particles and the number of powder particles corresponding to each hollowness rate level based on the prediction data of the hollowness rate level; obtaining the particle size of powder particles and the number of powder particles corresponding to each particle size based on the prediction data of the hollowness rate level; and inputting the hollowness rate level of powder particles, the number of powder particles corresponding to each hollowness rate level, the particle size of powder particles, and the number of powder particles corresponding to each particle size into a preset statistical model to obtain the statistical result of the particle size distribution of powder particles.
[0015] A powder hollowness rate grading and particle size distribution statistical system, the powder hollowness rate grading and particle size distribution statistical system includes: a data acquisition module for acquiring a powder image containing powder particles; a preprocessing module for preprocessing the powder image to obtain a standardized file; a classification prediction module for inputting the standardized file into a preset mixed supervised classification model to obtain the prediction data of the hollowness rate level of powder particles; and a data output module for obtaining the hollowness rate grading and particle size distribution statistical result of powder particles based on the prediction data of the hollowness rate level.
[0016] A computer-readable storage medium, on which computer-readable instructions are stored, characterized in that when the computer-readable instructions are executed by a processor, each step of the above-mentioned powder hollowness rate grading and particle size distribution statistical method is implemented.
[0017] The beneficial effects of the present invention are as follows:
[0018] 1. The powder hollowness rate grading and particle size distribution statistical method of the present invention trains a mixed supervised classification model through a small number of labeled images and a large number of unlabeled images. Based on the strong representation ability of the pre-trained vision large model, domain knowledge of powder images is introduced through low-rank fine-tuning. At the same time, a cross-enhanced consistency loss is designed to jointly optimize the labeled data (strong supervision) and unlabeled data (pseudo-supervision). After the trained model processes the powder image, it can jointly output particle mask segmentation and hollowness rate level, and then output the classification and particle size distribution map through statistical analysis. While reducing the dependence on manual labor for image annotation, it ensures industrial-level accuracy and provides one-stop analysis for industrial quality inspection.
[0019] 2. The powder hollowness grading and particle size distribution statistical method of the present invention outputs the results of powder particle segmentation and attribute classification through a trained model, and automatically generates an industrial-level quantitative inspection report according to the output results. The output results can be adjusted according to production needs and have guiding significance for production.
[0020] 3. The powder hollowness grading and particle size distribution statistical method of the present invention realizes the full automation of non-destructive testing, hollowness quantization grading, and particle size statistics under optical microscopy for the first time through an innovative image algorithm, improves the detection efficiency, and fills the technical gap of the optical solution in the field of physical property analysis. Brief Description of the Drawings
[0021] Figure 1 It is a flow chart of the powder hollowness grading and particle size distribution statistical method adopted in this embodiment;
[0022] Figure 2 It is a schematic structural diagram of the powder hollowness grading and particle size distribution statistical system adopted in this embodiment;
[0023] Figure 3 It is a schematic diagram of the powder particle hollowness level adopted in this embodiment;
[0024] Figure 4 It is a schematic diagram of rectangular annotation and polygon annotation of powder particles adopted in this embodiment;
[0025] Figure 5 It is a schematic diagram of the masked powder image adopted in this embodiment;
[0026] Figure 6 It is a schematic diagram of the effects of different enhancement strategies on the powder image adopted in this embodiment;
[0027] Figure 7 It is a schematic diagram of the training process of the preset hybrid supervised classification model adopted in this embodiment;
[0028] Figure 8 It is a network structure diagram of the preset hybrid supervised classification model adopted in this embodiment;
[0029] Figure 9 It is a hollowness level and histogram adopted in the second embodiment;
[0030] Figure 10 It is a particle size-volume fraction distribution diagram adopted in the second embodiment;
[0031] Figure 11 It is a schematic diagram of structured data output adopted in this embodiment. Detailed Embodiments
[0032] To enable those skilled in the art to better understand the solution of this application, the technical solution in the embodiments of this application will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are only a part of the embodiments of this application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the scope of protection of this application.
[0033] According to an embodiment of the present invention, a method for grading the powder hollow ratio and statistically analyzing the particle size distribution is provided. Please refer to Figures 1 to 11 , including:
[0034] S100 Obtain a powder image containing powder particles;
[0035] It should be noted that the powder particles include standard powder particles and non-standard powder particles. Among them, the standard powder particles include powder particles with clear, closed edge contours that do not cross or overlap with the edge contours of other powder particles; the non-standard powder particles include powder particles with unclear edge contours, powder particles with unclosed edge contours, and powder particles whose edge contours cross or overlap with the edge contours of other powder particles.
[0036] In specific practice, the quality of the edge contour of the powder particles will have a certain impact on the grading of the powder hollow ratio and the statistical results of the particle size distribution. Among them, incomplete edges or irregular shapes will directly affect the accuracy of the automatic detection algorithm. For example, blurred or broken edges may cause the particles to be misjudged as multiple small particles, or the measured particle size value to be too small; the hollow area of the hollow powder particles may produce low-contrast edges in the microscope image. If the outer edge of the powder particles is incomplete, it may be impossible to accurately distinguish the inner and outer boundaries of the particles, increasing the difficulty of edge detection, making the traditional method face the problems of low manual recognition efficiency, high algorithm recognition and annotation costs, and poor generalization in the field of non-destructive testing of materials for a long time.
[0037] S200 Preprocess the powder image to obtain a standardized file;
[0038] Specifically, the method for preprocessing the powder image includes: labeling the powder particles according to the type of the powder particles in the powder image; masking the labeled powder image based on a preset masking method; performing enhancement processing on the masked powder image using a preset enhancement module, where the preset enhancement module includes a strong enhancement module and a weak enhancement module, the strong enhancement module includes random occlusion and random fusion, and the weak enhancement module includes rotation, translation, and brightness adjustment; adjusting the resolution of the powder image obtained by the enhancement processing to obtain a standardized file.
[0039] The preset masking method includes:
[0040] Feature extraction is performed on the labeled areas of standard powder particles to obtain the particle grades of the standard powder particles, and a mask file is generated based on the particle grades; vector conversion is performed on the standard contours of the labeled areas of non-standard powder particles to generate a mask file.
[0041] With the above settings, through systematic integration of the mixed annotation strategy, the double improvement of the powder grade and particle size analysis efficiency and accuracy is achieved.
[0042] In specific practice, the data input into the preset mixed supervised classification model includes the labeled data set and the unlabeled data set. The labeled data set is manually classified and labeled. Among them, as Figure 3 shown, the manual classification standard consists of a labeling team composed of multiple technicians with more than five years of powder material quality inspection experience. The powder particles in the optical microscopic images are classified and labeled according to the following rules:
[0043] Classification standard rule (1): The hollowness feature of the powder particles is manifested as the transparency on the image. The particles are divided into levels 1-4. Specifically, level 4 is solid, that is, the transparency ≤ 20%; level 3 is low hollowness, that is, the transparency is 20% - 50%; level 2 is medium hollowness, that is, the transparency is 50% - 80%; level 1 is high hollowness, that is, the transparency ≥ 80%.
[0044] Classification standard rule (2): Determine the annotation form according to the clarity of the particle boundary: If the boundary is clear (such as the particles isolated and non-adhesive in the image), use a rectangular box for annotation; if the boundary is blurred or partially overlapped (the overlapping area of the particles > 15%), switch to a polygon box to accurately annotate the contour pixel by pixel.
[0045] In this embodiment, the specific steps of the manual standard are as follows:
[0046] 1. Manual annotation and review. Among them, manual annotation mainly uses the open-source tool labelme (a graphic image annotation tool, which can be replaced by CVAT software or VGG Image Annotator software, and there is no special requirement in this embodiment). At the same time, the automatic edge detection function of the annotation tool is disabled to ensure the accuracy of manual work. The annotation label set is set to "1, 2, 3, 4" corresponding to the four grades of powder particles. In some embodiments, the grades of powder particles can also be divided into n grades according to specific production requirements.
[0047] 2. As Figure 4 shown, for the particles with clear boundaries, use a rectangular box to mark the area. The rectangular box should ensure that it contains as much as possible or is slightly larger than the entire range of the particles; for the particles with blurred boundaries or overlapping areas, switch to the polygon annotation mode, manually click on the anchor points to close the contour. After marking the area, select a grade for each particle according to its transparency feature.
[0048] 3. All the annotation results need to be independently reviewed by three experts. The review criteria are as follows: For the particles marked with rectangular boxes, the actual boundaries of the particles should be completely contained within the boxes, and there should be no obvious overlap of other particles within the boxes; for the particles marked with polygons, the contour lines of the particles should accurately fit the true edges of the particles.
[0049] If there are disagreements among the three experts in the review results (such as inconsistent judgment of the grade of a certain particle), additional experts will be added for review, and the principle of the minority obeying the majority will be used for determination.
[0050] In specific practice, after manual annotation, the powder particles also need to generate masks.
[0051] Specifically, in this embodiment, the preset mask method includes:
[0052] For the rectangular box area, the following process is used to generate a color mask corresponding to the hollow grade:
[0053] 1. Crop the ROI area according to the area of the rectangular box and convert it into a grayscale image;
[0054] 2. Use the erosion and dilation algorithm to eliminate the impurities within the box, that is, morphological closing operation, and its parameters are: the radius of the structural element r = 2, and the number of iterations = 1;
[0055] 3. Dynamically adapt to the brightness and darkness changes on the particle surface through the Gaussian adaptive threshold method based on local contrast to extract the main body area of the particle, and color the mask area according to the particle grade.
[0056] Specifically, the code interface: cv2.adaptiveThreshold(), the mode is set to
[0057] ADAPTIVE_THRESH_GAUSSIAN_C, the Gaussian weight σ = 5.0, and the empirical constant C = 7. With this configuration, images with severe uneven illumination can be effectively processed, and the requirements for noise suppression and target retention can be balanced.
[0058] In some embodiments, the constant can be selected empirically, or the parameters can be adjusted according to different contrast intensities.
[0059] The corresponding rule between the hollow rate grade and the color coding in this embodiment is shown in Table 1:
[0060] Table 1
[0061] Hollow ratio level Color coding (RGB) Ratio of cavity area Level 1 Red (RGB: 255, 0, 0) ≥80% Level 2 Blue (RGB: 0, 0, 255) 50%~80% Level 3 Green (RGB: 0, 255, 0) 20%~50% Level 4 Yellow (RGB: 255, 255, 0) ≤20%
[0062] In specific practice, the masked powder image is finally saved as a mask file in the png (or tiff, jpeg, etc.) format, with a bit depth of 8 bits and the four-channel transparency retained. See Figure 5, the powder image after masking can accurately reproduce the particle morphology and physical property labels (i.e., the proportion of cavity area).
[0063] For polygonal regions, the vector contour is directly converted into a mask.
[0064] S300 inputs the standardized file into a preset hybrid supervised classification model to obtain the prediction data of the hollowness level of powder particles;
[0065] Such as Figure 6 shown, in this embodiment, the standardized file includes a first standardized file and a second standardized file. Among them, the first standardized file is obtained by weakly enhancing the powder image; the second standardized file is obtained by strongly enhancing the powder image.
[0066] Specifically, a structured dataset (i.e., a standardized file) is constructed based on the manually labeled powder image dataset after masking. Among them, the first standardized file includes:
[0067] Image source: High-resolution optical microscopic image;
[0068] Annotation file: Mask in PNG (or tiff / JPEG) format;
[0069] Data augmentation: Apply weak augmentation to the labeled data while preserving the geometric accuracy of the original labels.
[0070] In some embodiments, the high-resolution optical microscopic image is 2024*2048 pixels and has three channels; the weak augmentation method is rotation of ±10°, translation of ±5%, and brightness adjustment of ±15%.
[0071] The second standardized file is specifically: Based on the unlabeled powder image in the same scene as the image source in the first standardized file, different intensity enhancement strategies are applied to it.
[0072] In some embodiments, the weak augmentation method is rotation of ±10°, translation of ±5%, and brightness adjustment of ±15%; the strong augmentation methods are random occlusion (CutOut), random fusion (CutMix), etc.
[0073] Example 1:
[0074] The particles are divided into two categories: standard type (clear boundaries, no overlap) and non-standard type (overlap, blurred edges). The former is labeled with a fast rectangular box (0.3 seconds / particle), and the latter is marked point by point with a polygon (3 seconds / particle). The comprehensive annotation efficiency is greatly improved compared with the traditional full-mask annotation. During the annotation process, the grade of the particles (levels 1-4) is marked synchronously. Through the transmittance-color correlation model, the optical features (such as saturation, brightness difference) in the microscopic image are mapped into physical property labels to generate a standardized JSON file.
[0075] For the rectangular annotation area, based on the local contrast optimization algorithm and morphological opening and closing operations, sub-pixel edge segmentation is achieved (positioning error < 2μm); for the polygon area, the vector contour is directly converted into a mask. All output masks are attached with color-coded physical property labels (e.g., dark red corresponds to a hollow rate > 80%), forming a standardized file.
[0076] Specifically, the above weak data augmentation process constructs a multi-modal augmentation process based on the torchvision.transforms module of the PyTorch framework, and designs augmentation strategies for manually annotated images and unannotated data respectively.
[0077] In this embodiment, the strong augmentation process is manually designed. Among them, random occlusion (Cutout) is specifically to randomly select a 10×10 pixel area (about 0.2% of the image area) in the image spatial domain, and force the RGB values of the masked area to zero, simulating the scenario of a dirty microscope lens or particulate adhesion contaminants; random fusion (CutMix) is specifically to adopt an improved mixing strategy, constrain the mixing area to be rectangular (minimum size 20×20), and the mixing ratio is based on the Beta distribution (α = β = 1.0) to ensure that the enhanced image retains the main structure information.
[0078] It should be noted that after the first standardized file and the second standardized file are enhanced, it is necessary to uniformly reduce the input resolution to 224×224 to reduce the computational amount and make the size compatible with the basic model (the 14×14 Patch partitioning mechanism of the DINOv2 vision self-supervised learning framework), to avoid the inability to align the network position encoding due to size mismatch and the inability to reuse pre-trained parameters, thus significantly degrading the model performance.
[0079] Specifically, after the resolution is reduced, compared with the original 2048×2048, the computational amount is reduced by 98.8%.
[0080] In this embodiment, the preset hybrid supervised classification model includes a fully supervised training branch and a semi-supervised training branch. Among them, the fully supervised training branch is trained with manually annotated powder images, and the semi-supervised training branch is trained with unannotated powder images. The network structures of the fully supervised training branch and the semi-supervised training branch are the same.
[0081] It should be noted that the network structures of both the fully supervised training branch and the semi-supervised training branch use a vision base model as the feature extraction backbone, and a low-rank adaptation layer is inserted into each Transformer module of the fully supervised training branch and the semi-supervised training branch.
[0082] Specifically, as Figure 7As shown, the preset hybrid addition model design of this embodiment has a dual-branch stacked architecture. The teacher model and the student model share a unified network framework. The network consists of an encoder and a decoder. The student model and the teacher model have the same network structure. As Figure 8 shown, the specific network structure includes:
[0083] (1) Encoder module
[0084] Backbone network: Select the ViT-B model (or S, L model) pre-trained by the DINOv2 vision self-supervised learning framework as the basic encoder. During the above image preprocessing process, adjust the resolution of the input standardized file to 224*224, and output multi-scale feature maps (stage-1 to stage-4, with sizes of 1 / 28, 1 / 14, 1 / 7, 1 / 2 of the original).
[0085] Adaptive layer design: Insert a low-rank adaptation (LoRA) layer into each Transformer module of the ViT model to achieve qualitative adaptation of the feature space.
[0086] LoRA low-rank adaptation layer: Implicitly represent the change in weights ΔW through the low-rank matrix product B·A. Specifically:
[0087]
[0088] where W new is the weight matrix recalculated after adding the low-rank adaptation layer, ΔW is the change in weights, B·A is the low-rank matrix product, and W origin is the original weight matrix. is the matrix space of d rows and r columns over the real number field. The rank r is usually set to 1 to 32, and d, k are the number of rows and columns of the weight matrix W origin .
[0089] Specifically, if the input dimension of a fully connected layer is d and the output dimension is k, then the size of the weight matrix is d×k.
[0090] In this embodiment, during training, freeze the weight matrix W origin , and only update the low-rank matrix.
[0091] (2) Decoder module
[0092] Based on the improvement of the DPT (i.e., dense prediction transformer) architecture, upsample the hierarchical features of the ViT model to the original image resolution through transposed convolution, introduce skip connections, pass through a multi-layer multi-scale fusion module (including 4 layers of 3x3 convolution + upsampling), and finally pass through the output convolution module to output the pixel-level segmentation probability map P m ∈[0,1]H×W and the probability distribution of the hollow rate level
[0093] In this embodiment, the method for obtaining the prediction data of the hollow rate level of powder particles includes: obtaining a supervised loss based on the fully supervised training branch; obtaining a semi-supervised loss based on the semi-supervised training branch; obtaining the total loss data of the semi-supervised training branch based on the supervised loss, the semi-supervised loss, and a preset weight; and if the total loss data meets the preset standard, completing the training of the semi-supervised training branch.
[0094] Specifically, the training process of the preset hybrid supervised classification model synchronously utilizes the strong supervision of labeled data and the consistency constraint of unlabeled data. The loss function is designed as follows:
[0095] (1) The fully supervised loss of manually labeled data:
[0096] For labeled images, after weak augmentation, all are input into the teacher model for fully supervised training. Specifically, the fully supervised loss includes:
[0097] Mask segmentation loss: The weighted sum of Focal Loss and Dice Loss is used to alleviate the class imbalance problem. Specifically: λ1 = 0.8, λ2 = 0.2;
[0098] Among them, is the prediction result after the labeled data passes through the teacher model, and G is the manually labeled data.
[0099] Hollow rate level classification loss: Based on the KL divergence loss with label smoothing, the consistency between attribute prediction and manual annotation is constrained:
[0100]
[0101] Among them, is the true classification, and P c (i) is the predicted category.
[0102] Therefore, the fully supervised loss of manually labeled data is:
[0103]
[0104] (2) The semi-supervised loss of unlabeled data
[0105] The unlabeled images are respectively subjected to 1 time of weak augmentation (input into the teacher model) and 2 times of strong augmentation (input into the student model). The teacher model generates pseudo-labels as the supervision signal, and the student model generates two predictions Calculate the mean squared error between the two predictions of the student model and the pseudo-labels generated by the teacher model:
[0106] Among them, in order to suppress noise propagation, the loss is only calculated for the pixels with a confidence threshold τ > 0.7 in the pseudo-labels.
[0107] Finally, the total loss is a mixed weighted sum:
[0108] Among them, γ(t) is a variable weight coefficient that increases from 0.1 to 0.5 with the round t.
[0109] Among them, the variable weight coefficient is set empirically during the training process. The weight is smaller in the early stage because in the early stage, the teacher model is mainly trained with labeled data. After the teacher model is trained to a good level with labeled data, the training weight of the student model is gradually increased.
[0110] With the above settings, using the vision foundation model DINOv2 as the feature extraction backbone, a low-rank adaptation layer (LoRA, rank r = 8) is inserted into each layer of the Transformer, enabling the model parameter increment to be only 0.15% of the original structure while retaining the ability to recognize the optical characteristics of the powder. The decoder is designed as a multi-scale fusion structure (DPT) to improve the sub-pixel level positioning accuracy of the particle edges. A teacher-student collaborative training framework is constructed. Among them, the teacher model processes the pre-labeled data to generate benchmark predictions, and the student model learns robust features through noise perturbation enhanced data (Cutout, CutMix). For unlabeled data, a cross-channel consistency loss function is designed to force the prediction results of the model to remain stable under multiple perturbation conditions. While reducing the artificial dependence on image annotation, it ensures industrial-level accuracy and provides one-stop analysis for industrial quality inspection.
[0111] S400 obtains the hollowness classification and particle size distribution statistical results of the powder particles based on the hollowness level prediction data.
[0112] In this embodiment, the method for obtaining the particle size distribution statistical results of the powder particles includes: obtaining the hollowness level of the powder particles and the number of powder particles corresponding to each hollowness level based on the hollowness level prediction data; obtaining the particle size of the powder particles and the number of powder particles corresponding to each particle size based on the hollowness level prediction data; inputting the hollowness level of the powder particles, the number of powder particles corresponding to each hollowness level, the particle size of the powder particles, and the number of powder particles corresponding to each particle size into a preset statistical model to obtain the particle size distribution statistical results of the powder particles.
[0113] In specific practice, after the classification and segmentation of the powder particles are completed, a quantitative report required for industrial inspection is automatically given through statistical analysis. The process is as follows:
[0114] 1. Category Quantity Statistics: Count the void ratio classification, based on mask color coding (e.g., red = void ratio level 1, yellow = void ratio level 4), count the number of particles of each level in each image, and the results are presented in the form of a classification histogram.
[0115] 2. Calculation of Particle Size - Volume Fraction Ratio: Based on the mask area A i , combined with the input scale (or recognized by the OCR algorithm) α = 0.1 μm / px, calculate the equivalent volume (assuming the particles are spherical):
[0116] Among them, the abscissa is the particle size, and the ordinate is the volume fraction of the particle size (n = total number of particles in a single image).
[0117] 3. Structured Data Output: Generate an Excel / CSV file containing indicators such as the total number of particles, particle sizes D10 / D50 / D90, and the main void ratio level, which supports direct import into the SPC (Statistical Process Control) system.
[0118] In some embodiments, the trained model outputs the results of powder particle segmentation and attribute classification, and automatically generates an industrial - level quantitative inspection report according to the output results. The output industrial - level quantitative inspection report can be adjusted according to production needs.
[0119] Example Two:
[0120] In this example, select to output the void ratio classification and histogram, and the particle size - volume fraction distribution map.
[0121] Specifically, the output method of the void ratio classification and histogram is as follows: Preset the hybrid - supervised model to output an instance segmentation mask with void ratio color coding. Based on the findContours function of OpenCV, identify the closed boundaries of each color region in the mask, extract the number of particles of the corresponding void ratio level with color coding, and generate a histogram, as Figure 9 shown, where the abscissa is the void ratio level and the ordinate is the number of particles.
[0122] The output method of the particle size - volume fraction distribution map is:
[0123] According to the mask area A i and the scale α, calculate the particle size (μm):
[0124] Calculate the volume according to the particle size:
[0125] For obtaining the scale, the length and unit represented by the scale can be automatically recognized by OCR to obtain α (μm / pix), or the scale can be input manually.
[0126] Calculate D i and V i After that, plot the particle size - volume distribution function curve, with the particle size D i on the abscissa and the volume fraction on the ordinate. The volume density is calculated as follows:
[0127] According to the calculated volume fraction, plot the curve with double ordinates. The left side is the volume density corresponding to the particle size, and the right side is the cumulative volume density. The calculation method for the cumulative volume density is: As Figure 10 shown.
[0128] In some embodiments, as Figure 11 shown, a structured data output method can also be selected. Specifically, an Excel / CSV file containing indicators such as the total number of particles, particle size, and main hollowness level can be generated and supported for direct import into the SPC (Statistical Process Control) system. The indicator definitions and calculation methods are shown in Table 2.
[0129] Table 2 Indicator Definitions and Calculation Methods
[0130]
[0131]
[0132] This embodiment provides a powder hollowness grading and particle size distribution statistics system. Refer to Figure 2 , the powder hollowness grading and particle size distribution statistics system includes: a data acquisition module for acquiring powder images containing powder particles; a preprocessing module for preprocessing the powder images to obtain a standardized file; a classification and prediction module for inputting the standardized file into a preset hybrid supervised classification model to obtain hollowness level prediction data of the powder particles; and a data output module for obtaining the hollowness grading and particle size distribution statistics results of the powder particles based on the hollowness level prediction data.
[0133] In this way, the hybrid supervised classification model is trained with a small number of labeled images and a large number of unlabeled images. Based on the strong representation ability of the pre - trained vision large model (such as the DINOv2 model), domain knowledge of the powder images is introduced through low - rank fine - tuning (LORA). At the same time, a cross - enhanced consistency loss is designed to jointly optimize the labeled data (strong supervision) and unlabeled data (pseudo - supervision). The trained model processes the powder images, can jointly output particle mask segmentation and hollowness level, and then outputs the classification and particle size distribution diagram through statistical analysis, reducing the manual dependence on image annotation while ensuring industrial - level accuracy and providing one - stop analysis for industrial quality inspection.
[0134] This embodiment provides a computer-readable storage medium, on which computer-readable instructions are stored. It is characterized in that when the computer-readable instructions are executed by a processor, each step of any of the above powder hollow rate grading and particle size distribution statistical methods is implemented.
[0135] Embodiments of the present invention may be implemented in the form of a computer program product implemented on one or more storage media (including but not limited to disk memories, CD-ROMs, optical memories, etc.) containing program codes. The computer-readable storage medium includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. The information may be computer-readable instructions, data structures, program modules, or other data. Examples of computer-readable storage media include but are not limited to: new types of memories such as phase change memory / resistive random access memory / magnetic random access memory / ferroelectric random access memory (PRAM / RRAM / MRAM / FeRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassette tapes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information accessible by a computing device.
[0136] It should be noted that the terms "first", "second", etc. in the description, claims, and the above drawings of this application are used to distinguish similar objects and do not necessarily need to describe a specific order or sequence. It should be understood that such used data can be interchanged under appropriate circumstances so that the embodiments of the present application described here can be implemented in an order other than those illustrated or described here. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units does not necessarily need to be limited to those clearly listed steps or units, but may include other steps or units not clearly listed or inherent to these processes, methods, products, or devices.
[0137] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments, and will not be elaborated here.
[0138] The serial numbers of the above embodiments of the present application are only for description and do not represent the advantages or disadvantages of the embodiments.
[0139] In the above-mentioned embodiments of the present application, the descriptions of the respective embodiments have their own focuses. For the parts not detailed in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.
[0140] The above are only the preferred embodiments of the present application. It should be noted that for those of ordinary skill in the art, without departing from the principle of the present application, several improvements and refinements can be made, and these improvements and refinements should also be regarded as the protection scope of the present application.
Claims
1. A method for grading the powder hollow ratio and statistically analyzing the particle size distribution, characterized in that Including: Obtain a powder image containing powder particles; Preprocess the powder image to obtain a standardized file; Input the standardized file into a preset hybrid supervised classification model to obtain hollow rate level prediction data of the powder particles; Based on the hollow rate level prediction data, obtain the hollow rate classification and particle size distribution statistical results of the powder particles.
2. The powder hollow ratio grading and particle size distribution statistical method according to claim 1, wherein The powder particles include standard powder particles and non-standard powder particles. Among them, the standard powder particles include those with clear, closed edge contours that do not cross or overlap with the edge contours of other powder particles; the non-standard powder particles include powder particles with unclear edge contours, powder particles with unclosed edge contours, and powder particles whose edge contours cross or overlap with the edge contours of other powder particles.
3. The powder hollow ratio grading and particle size distribution statistical method according to claim 2, characterized in that The method for preprocessing the powder image includes: Label the powder particles according to the types of the powder particles in the powder image; Mask the labeled powder image based on a preset masking method; Use a preset enhancement module to perform enhancement processing on the masked powder image. Among them, the preset enhancement module includes a strong enhancement module and a weak enhancement module. The strong enhancement module includes random occlusion and random fusion, and the weak enhancement module includes rotation, translation, and brightness adjustment; Adjust the resolution of the powder image obtained by the enhancement processing to obtain the standardized file.
4. The method for grading the powder hollow rate and statistically analyzing the particle size distribution according to claim 3, characterized in that, The preset masking method includes: Extract features from the labeled area of the standard powder particles to obtain the particle level of the standard powder particles, and generate a mask file based on the particle level; and / or Perform vector conversion based on the standard contour of the labeled area of the non-standard powder particles to generate a mask file.
5. The method for grading the hollow ratio and statistically analyzing the particle size distribution of the powder according to claim 1, characterized in that, The preset hybrid supervised model includes a fully supervised training branch and a semi-supervised training branch. The fully supervised training branch is trained with the manually labeled powder images, and the semi-supervised training branch is trained with the unlabeled powder images. The network structures of the fully supervised training branch and the semi-supervised training branch are the same.
6. The method for powder hollow ratio grading and particle size distribution statistics according to claim 5, characterized in that, The network structures of both the fully supervised training branch and the semi-supervised training branch use a vision-based model as the feature extraction backbone, and a low-rank adaptation layer is inserted into each Transformer module of the fully supervised training branch and the semi-supervised training branch.
7. The method for powder hollow ratio grading and particle size distribution statistics according to claim 6, characterized in that, The method for obtaining the hollow rate level prediction data of the powder particles includes: Obtain a supervised loss based on the fully supervised training branch; Obtain a semi-supervised loss based on the semi-supervised training branch; Based on the supervised loss, the semi-supervised loss, and a preset weight, obtain the total loss data of the semi-supervised training branch; If the total loss data meets the preset standard, complete the training of the semi-supervised training branch.
8. The method for grading the powder hollow ratio and statistically analyzing the particle size distribution according to claim 1, wherein, The method for obtaining the particle size distribution statistical results of the powder particles includes: Based on the hollow rate level prediction data, obtain the hollow rate level of the powder particles and the number of the powder particles corresponding to each hollow rate level; Based on the hollow rate level prediction data, obtain the particle size of the powder particles and the number of the powder particles corresponding to each particle size; Input the hollowness rate level of the powder particles, the quantity of the powder particles corresponding to each hollowness rate level, the particle size of the powder particles, and the quantity of the powder particles corresponding to each particle size into a preset statistical model to obtain the statistical result of the particle size distribution of the powder particles.
9. A powder hollow rate grading and particle size distribution statistical system, characterized in that, The powder hollowness rate classification and particle size distribution statistical system includes: A data acquisition module, which is used to acquire a powder image containing powder particles; A preprocessing module, which is used to preprocess the powder image to obtain a standardized file; A classification and prediction module, which is used to input the standardized file into a preset hybrid supervised classification model to obtain the hollowness rate level prediction data of the powder particles; A data output module, which is used to obtain the hollowness rate classification and particle size distribution statistical result of the powder particles based on the hollowness rate level prediction data.
10. A computer-readable storage medium, on which computer-readable instructions are stored, characterized in that, When the computer-readable instructions are executed by a processor, each step of the powder hollowness rate classification and particle size distribution statistical method according to any one of claims 1-8 is implemented.