Method and system for analyzing impurity content in washed coal based on deep learning

Through deep learning-based image processing technology, impurity content analysis is performed on coal samples, which solves the problem of time-consuming and labor-consuming manual operations in the existing technology, and improves the degree of intelligence and efficiency of analysis.

CN119850620BActive Publication Date: 2025-05-16QINSHUI COUNTY CHENYANG IND & TRADE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510329726.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-20
Publication Date
2025-05-16
Estimated Expiration
2045-03-20

AI Technical Summary

Technical Problem

The existing coal impurity content analysis methods rely on manual operations, consume a lot of human resources and time, and have a low degree of intelligence.

Method used

The impurity content analysis of coal samples was performed through image processing technology using deep learning-based methods. Specific steps include obtaining target coal samples, image shooting and grayscale conversion, image segmentation and uniform difference calculation, judging the uniform grayscale difference, identifying the impurity content of pure or mixed sample images, and extracting feature values ​​for analysis using deep learning models.

Benefits of technology

It improves the intelligence of coal impurity content analysis, reduces time and human resources consumption, and achieves more efficient impurity content analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119850620B_ABST
    Figure CN119850620B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of coal image processing, and is a method and system for analyzing impurity content of washed coal based on deep learning. The method comprises: photographing a target coal sample to obtain a grayscale sample image, segmenting the grayscale sample image to obtain a segmented sample image set, calculating the image grayscale mean difference of the segmented sample image, judging whether the image grayscale mean difference is within the coal mean difference range, if so, identifying the pure impurity content, if not, constructing a grayscale matrix to obtain a grayscale co-occurrence matrix, extracting uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​of the grayscale co-occurrence matrix to obtain a mixed impurity content, and calculating the total impurity content of the sample according to the pure impurity content and the mixed impurity content to obtain the target coal impurity content. The present invention can improve the intelligence level of impurity content analysis of washed coal and reduce excessive consumption of time and human resources.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of coal image processing, and in particular to a method and system for analyzing impurity content in washed coal based on deep learning. Background Art

[0002] The original collected coal often contains a large amount of impurities, such as sulfur, nitrogen compounds, heavy metals, etc. These impurity-containing coals will release harmful gases and particulate matter during combustion, causing environmental pollution. Therefore, these coals containing a large amount of impurities need to be washed. In order to ensure the safety of the coal washing process and improve the efficiency of coal washing, it is necessary to analyze the impurity content in the coal in advance so that the appropriate method and raw materials can be selected to complete the coal washing.

[0003] The current method for analyzing coal impurity content is mainly achieved through manual analysis. Although this method can analyze the impurity content of coal, it requires a lot of human resources and time costs, and its intelligence needs to be improved. Summary of the invention

[0004] The present invention provides a method and system for analyzing the impurity content of washed coal based on deep learning, the main purpose of which is to improve the intelligence level of the impurity content analysis of washed coal and reduce the excessive consumption of time and human resources.

[0005] To achieve the above-mentioned purpose, the present invention provides a method for analyzing the impurity content of washed coal based on deep learning, comprising: obtaining a target coal sample, photographing the target coal sample to obtain an original sample image, performing grayscale conversion on the original sample image to obtain a grayscale sample image; performing image segmentation on the grayscale sample image to obtain a segmented sample image set, extracting segmented sample images in the segmented sample image set in sequence, performing mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; judging whether the image grayscale mean difference is within a preset coal mean difference range; if the image grayscale mean difference is within the coal mean difference range, recording the segmented sample image as a pure sample image, and identifying the pure impurity content of the pure sample image; if the image grayscale mean difference is not within the coal mean difference range, recording the segmented sample image as a mixed sample image, construct a grayscale matrix for the mixed sample image to obtain a grayscale co-occurrence matrix, wherein the grayscale co-occurrence matrix contains the grayscale value information of each pixel in the mixed sample image; use the grayscale co-occurrence matrix to extract image eigenvalues ​​to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues; input the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​into a pre-constructed data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model; summarize the pure impurity content and the mixed impurity content respectively to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of segmented sample images; calculate the total impurity content of the sample according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

[0006] Optionally, performing grayscale conversion on the original sample image to obtain a grayscale sample image includes: extracting original image pixels from the original sample image, and identifying RGB channel values ​​of the original image pixels in an RGB color space, wherein the RGB channel values ​​are expressed as:

[0007] ,in, Represents the RGB channel value, Represents the red channel value, Represents the green channel value, represents the blue channel value; sets the red sensitivity coefficient, the green sensitivity coefficient and the blue sensitivity coefficient, and converts the RGB channel value into a gray channel value based on the red sensitivity coefficient, the green sensitivity coefficient and the blue sensitivity coefficient, wherein the gray channel value is represented as:

[0008] ,in, Represents the grayscale channel value, represents the red sensitivity coefficient, represents the green sensitivity coefficient, represents the blue sensitivity coefficient; using the grayscale channel value to update the original image pixel points to obtain grayscale image pixel points, summarizing the grayscale image pixel points to obtain a grayscale image pixel point set; using the grayscale image pixel point set to update the original sample image to obtain a grayscale sample image.

[0009] Optionally, performing image segmentation on the grayscale sample image to obtain a segmented sample image set includes: performing preliminary artificial segmentation on the grayscale sample image to obtain a preliminary segmented image set; performing the following operations on each preliminary segmented image in the preliminary segmented image set: identifying the maximum grayscale channel value and the minimum grayscale channel value in the preliminary segmented image, and calculating the image grayscale difference between the maximum grayscale channel value and the minimum grayscale channel value, wherein the image grayscale difference is the difference between the maximum grayscale channel value and the minimum grayscale channel value; respectively identifying the maximum grayscale pixel point and the minimum grayscale pixel point corresponding to the maximum grayscale channel value and the minimum grayscale channel value; judging whether the image grayscale difference is greater than a preset standard grayscale difference; if the image grayscale difference is greater than a preset standard grayscale difference, the image grayscale difference is greater than a preset standard grayscale difference. If the grayscale difference is greater than the standard grayscale difference, an image segmentation line is constructed based on the maximum grayscale pixel point and the minimum grayscale pixel point; the preliminary segmented image is segmented using the image segmentation line to obtain a secondary segmentation image set, wherein the secondary segmentation image set includes two secondary segmentation images; if the image grayscale difference is not greater than the standard grayscale difference, the preliminary segmented image is recorded as a segmentation sample image; the secondary segmentation image set is summarized to obtain a precise segmentation image set, the preliminary segmentation image set is updated using the precise segmentation image set, and the step of performing the following operations on each preliminary segmentation image in the preliminary segmentation image set is returned; the segmentation sample images are summarized to obtain a segmentation sample image set.

[0010] Optionally, the performing mean difference calculation on the segmented sample image to obtain the image grayscale mean difference includes: extracting segmentation pixels in the segmented sample image in sequence, and performing the following operations on the segmentation pixels: based on a preset neighborhood window value, performing neighborhood pixel collection on the segmentation pixels to obtain a neighborhood pixel set, wherein the number of neighborhood pixels in the neighborhood pixel set is the same as the neighborhood window value; adding the segmentation pixels to the neighborhood pixel set to obtain a sequence pixel set, and identifying a sequence grayscale value set of the sequence pixel set; extracting a central grayscale value from the sequence grayscale value set, and using the central grayscale value to update the grayscale value of the segmentation pixels to obtain a smooth pixel; summarizing the smooth pixel points to obtain a smooth pixel set, using the smooth pixel set to update the segmented sample image to obtain a smoothed sample image, and identifying a smoothed grayscale value set of the smoothed sample image; performing mean difference calculation on the smoothed grayscale value set to obtain an image grayscale mean difference, wherein the image grayscale mean difference is expressed as:

[0011] ,in, Represents the grayscale mean difference of the image. Represents the number of smooth gray values ​​in the smooth gray value set, Represents the tth smoothed grayscale value, and t represents the arrangement sequence number of the smoothed grayscale value in the smoothed grayscale value set.

[0012] Optionally, the identifying of the pure impurity content of the pure sample image includes: identifying the lower left vertex of the pure sample image, recording the lower left vertex as the extension starting point, identifying the maximum pure pixel point in the pure sample image, wherein the maximum pure pixel point is the pixel point with the largest grayscale value in the pure sample image; recording the line connecting the extension starting point and the maximum pure pixel point as the positive extension direction, identifying the starting grayscale value of the extension starting point, and identifying the pure sample image edge of the pure sample image; performing line segment extension based on the extension starting point and the positive extension direction to obtain an extension relay point, identifying the relay grayscale value of the extension relay point, and calculating the extended grayscale difference between the relay grayscale value and the starting grayscale value, wherein the extended relay point is the first grayscale value extended from the extension starting point. pixel points encountered once; judging whether the extended grayscale difference is greater than a preset standard extension difference; if the extended grayscale difference is not greater than the standard extension difference, continuing to extend the line segment in the positive extension direction until the line segment extends to the edge of the pure sample image; if the extended grayscale difference is greater than the standard extension difference, recording the extended relay point as an extended breakpoint, recording the line connecting the extended breakpoint and the extended starting point as an extended line segment, updating the extended starting point using the extended breakpoint, and returning to the step of extending the line segment based on the extended starting point and the positive extension direction; summarizing the extended line segments to obtain an extended line segment set, identifying the number of line segments in the extended line segment set, and calculating the pure impurity content based on the number of line segments and a preset adjustment factor using the following formula:

[0013] ,in, Indicates the pure impurity content, represents a natural constant, represents the adjustment factor, Indicates the number of line segments.

[0014] Optionally, the grayscale matrix of the mixed sample image is constructed to obtain a grayscale co-occurrence matrix, including: performing grayscale value conversion on the mixed sample image according to a preset mixed grayscale level to obtain a mixed grayscale image, wherein the mixed grayscale level is less than the original grayscale level in the mixed sample image; setting an adjacent step length, sequentially extracting mixed pixels in the mixed grayscale image, and based on the adjacent step length, performing adjacent pixel point extraction on the mixed pixel point to obtain an adjacent pixel point set; matching the mixed pixel point with each adjacent pixel point in the adjacent pixel point set to obtain an adjacent pixel point group set, wherein each adjacent pixel point group in the adjacent pixel point group set is respectively expressed as:

[0015] , ,in, represents the first adjacent pixel group, Represents mixed pixels, Represents the coordinates of the mixed pixel points, represents the first adjacent pixel, represents the coordinates of the first adjacent pixel, d represents the adjacent step length, represents the second adjacent pixel group, represents the second adjacent pixel, Represents the coordinates of the second adjacent pixel, represents the third adjacent pixel group, represents the third adjacent pixel, Represents the coordinates of the third adjacent pixel, represents the 4th adjacent pixel group, represents the 4th adjacent pixel, represents the coordinates of the fourth adjacent pixel point; grayscale values ​​of the adjacent pixel point set are identified to obtain an adjacent grayscale value set, wherein each adjacent grayscale value set in the adjacent grayscale value set is represented as:

[0016] , ,in, represents the first adjacent gray value group, Represents the grayscale value of the mixed pixel, Represents the gray value of the first adjacent pixel, represents the second adjacent gray value group, Represents the gray value of the second adjacent pixel. represents the third adjacent gray value group, Represents the gray value of the third adjacent pixel, represents the 4th adjacent gray value group, represents the gray value of the 4th adjacent pixel; summarizing the adjacent gray value groups to obtain a matrix gray value group, and constructing a gray level co-occurrence matrix according to the matrix gray value group.

[0017] Optionally, constructing a grayscale co-occurrence matrix according to the matrix grayscale value group set includes: extracting matrix grayscale value groups in the matrix grayscale value group set in sequence, counting the grayscale frequencies of the matrix grayscale value groups in the matrix grayscale value group set to obtain a grayscale frequency set, wherein each matrix grayscale value group corresponds to a unique grayscale frequency, and each grayscale frequency corresponds to one or more matrix grayscale value groups; constructing a grayscale co-occurrence matrix based on the grayscale frequency set, wherein the grayscale co-occurrence matrix is ​​expressed as:

[0018] ,in, represents the gray-level co-occurrence matrix, Indicates that the adjacent gray value group is The grayscale frequency, Indicates that the adjacent gray value group is The grayscale frequency, M represents the maximum value of the mixed grayscale level, Indicates that the adjacent gray value group is The grayscale frequency, Represents the maximum ordinate in a set of adjacent pixel points, Indicates that the adjacent gray value group is The grayscale frequency.

[0019] Optionally, the extracting image eigenvalues ​​by using the gray level co-occurrence matrix to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​includes: calculating uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​by using the following formulas according to the gray level co-occurrence matrix:

[0020] , , ,in, represents the uniform eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency, represents a clear eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency, represents the logarithmic function, represents the smoothed eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency.

[0021] Optionally, the calculating of the total impurity content of the sample according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content includes: respectively setting the pure content weight of the pure sample image and the mixed content weight of the mixed sample image, and calculating the target coal impurity content based on the pure content weight, the mixed content weight, the pure impurity content set and the mixed impurity content set using the following formula:

[0022] ,in, Indicates the target coal impurity content, represents the purity content weight, Indicates the number of pure impurity contents in the pure impurity content concentration, Indicates Pure impurity content, Indicates the arrangement number of the pure impurity content in the pure impurity content concentration, represents the mixed content weight, Indicates the number of mixed impurity contents in the mixed impurity content concentration, Indicates Mixed impurities content, Indicates the arrangement sequence number of the mixed impurity content in the mixed impurity content concentration.

[0023] To achieve the above-mentioned purpose, the present invention also provides an impurity content analysis system for washed coal based on deep learning, including: an image mean difference acquisition module, used to acquire a target coal sample, capture an image of the target coal sample to obtain an original sample image, perform grayscale conversion on the original sample image to obtain a grayscale sample image, perform image segmentation on the grayscale sample image to obtain a segmented sample image set, extract segmented sample images in the segmented sample image set in sequence, perform mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; an image grayscale determination module, used to determine whether the image grayscale mean difference is within a preset coal mean difference range; if the image grayscale mean difference is within the coal mean difference range, the segmented sample image is recorded as a pure sample image, and the pure impurity content of the pure sample image is identified; if the image grayscale mean difference is not within the coal mean difference range, the segmented sample image is recorded as a mixed sample image. This image, constructs a grayscale matrix for the mixed sample image to obtain a grayscale co-occurrence matrix, wherein the grayscale co-occurrence matrix contains the grayscale values ​​of each pixel in the mixed sample image; a mixed feature processing module, used to use the grayscale co-occurrence matrix to extract image eigenvalues, obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues, input the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​into a pre-constructed data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model; an impurity content calculation module, used to summarize the pure impurity content and the mixed impurity content respectively to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of segmented sample images, and the total impurity content of the sample is calculated according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

[0024] In order to solve the above problems, the present invention also provides an electronic device, which includes: a memory storing at least one instruction; and a processor executing the instructions stored in the memory to implement the above-mentioned method for analyzing the impurity content of washed coal based on deep learning.

[0025] In order to solve the above problems, the present invention also provides a computer-readable storage medium, in which at least one instruction is stored. The at least one instruction is executed by a processor in an electronic device to implement the above-mentioned method for analyzing the impurity content of washed coal based on deep learning.

[0026] In order to solve the problems described in the background technology, the present invention first obtains a target coal sample, and shoots an image of the target coal sample to obtain an original sample image, and performs grayscale conversion on the original sample image to obtain a grayscale sample image. In this step, the physical properties of the target coal sample are converted into a digital image through image shooting, providing basic data for subsequent image processing and analysis. At the same time, the grayscale conversion helps to reduce the complexity of image processing, while retaining the key information of the image, providing clearer image data for subsequent image segmentation and feature extraction. Next, the grayscale sample image is segmented to obtain a segmented sample image set, and the segmented sample images are sequentially extracted from the segmented sample image set. The sample image is subjected to mean difference calculation to obtain the image grayscale mean difference. Among them, the grayscale sample image can be segmented to separate different areas in the target coal sample, so as to facilitate the separate analysis of the impurity content in different areas. Then, it is judged whether the image grayscale mean difference is within the coal mean difference range. By comparing the image grayscale mean difference with the coal mean difference range, the distribution of impurities in the coal sample can be preliminarily judged, which provides a reference for the subsequent impurity content analysis. If the image grayscale mean difference is within the coal mean difference range, the grayscale sample image is recorded as a pure sample image, and the pure impurity content of the pure sample image is identified. For samples with low impurity content, this step can directly identify and calculate their impurity content, simplifying the process. The analysis process of impurity content is improved, and the intelligence level of coal washing is improved. If the grayscale mean difference of the image is not within the range of the coal mean difference, the grayscale sample image is recorded as a mixed sample image, and the grayscale matrix of the mixed sample image is constructed to obtain a grayscale co-occurrence matrix. The grayscale co-occurrence matrix constructed in this step is helpful for in-depth analysis of the texture characteristics of the coal sample, providing richer data for subsequent impurity content analysis, while also reducing excessive consumption of time and human resources. Then, the grayscale co-occurrence matrix is ​​used to extract image eigenvalues, and uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​are obtained. The uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​extracted in this step can reflect the texture and The structural features provide key input data for the subsequent deep learning model. At the same time, the deep learning model is used to replace manual analysis to a great extent, which improves the intelligence level of impurity content analysis of washed coal. Next, the uniform eigenvalue, clear eigenvalue and smooth eigenvalue are input to the data processing center to obtain the mixed impurity content. This step completes the impurity content analysis of mixed sample images with more impurities. Finally, the pure impurity content and the mixed impurity content are summarized respectively to obtain the pure impurity content set and the mixed impurity content set. According to the pure impurity content set and the mixed impurity content set, the total impurity content of the sample is calculated to obtain the target coal impurity content, and the impurity content analysis of washed coal is completed. Therefore, the present invention can improve the intelligence level of impurity content analysis of washed coal and reduce the excessive consumption of time and human resources. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] Figure 1A schematic diagram of a flow chart of a method for analyzing impurity content in washed coal based on deep learning provided in one embodiment of the present invention; Figure 2 A functional module diagram of a system for analyzing impurity content in washed coal based on deep learning provided in one embodiment of the present invention; Figure 3 A schematic diagram of the structure of an electronic device for implementing the method for analyzing impurity content in washed coal based on deep learning provided in one embodiment of the present invention.

[0028] Explanation of the reference numerals: 1. electronic device; 10. processor; 11. memory; 12. bus.

[0029] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0030] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0031] The embodiment of the present application provides a method for analyzing the impurity content of washed coal based on deep learning. The execution subject of the method for analyzing the impurity content of washed coal based on deep learning includes but is not limited to at least one of the electronic devices such as a server and a terminal that can be configured to execute the method provided in the embodiment of the present application. In other words, the method for analyzing the impurity content of washed coal based on deep learning can be executed by software or hardware installed on a terminal device or a server device, and the software can be a blockchain platform. The server includes but is not limited to: a single server, a server cluster, a cloud server or a cloud server cluster, etc.

[0032] Reference Figure 1 The figure is a flow chart of a method for analyzing impurity content of washed coal based on deep learning provided by an embodiment of the present invention. In this embodiment, the method for analyzing impurity content of washed coal based on deep learning includes: S1, obtaining a target coal sample, photographing the target coal sample to obtain an original sample image, and gray-converting the original sample image to obtain a gray-scale sample image.

[0033] It is clear that the target coal sample refers to a coal pile composed of coal and impurities, wherein the impurities are, for example, carbonate minerals, silicate minerals, etc. These impurities will affect the normal use of coal and need to be removed from the coal. Before removal, the content of impurities in the coal needs to be evaluated in order to select appropriate methods and raw materials for impurity removal. The original sample image refers to an image obtained after photographing the target coal sample, and the grayscale sample image refers to the original sample image after conversion from the RGB color space to the grayscale color space.

[0034] For example, Xiao Zhang is an employee of a coal processing plant. One day, Xiao Zhang picked up a piece of coal from the coal pile as a target coal sample. Then Xiao Zhang flattened the coal pile and photographed the coal pile with a high-definition camera to obtain the original sample image. Then, Xiao Zhang converted the original sample image into a grayscale sample image.

[0035] In detail, the grayscale conversion of the original sample image to obtain the grayscale sample image includes: extracting original image pixels from the original sample image, and identifying RGB channel values ​​of the original image pixels in the RGB color space, wherein the RGB channel values ​​are expressed as:

[0036] ,in, Represents the RGB channel value, Represents the red channel value, Represents the green channel value, represents the blue channel value; sets the red sensitivity coefficient, the green sensitivity coefficient and the blue sensitivity coefficient, and converts the RGB channel value into a gray channel value based on the red sensitivity coefficient, the green sensitivity coefficient and the blue sensitivity coefficient, wherein the gray channel value is represented as:

[0037] ,in, Represents the grayscale channel value, represents the red sensitivity coefficient, represents the green sensitivity coefficient, represents the blue sensitivity coefficient; using the grayscale channel value to update the original image pixel points to obtain grayscale image pixel points, summarizing the grayscale image pixel points to obtain a grayscale image pixel point set; using the grayscale image pixel point set to update the original sample image to obtain a grayscale sample image.

[0038] It can be understood that the original pixel refers to the pixel in the original sample image, which contains RGB color information, and the red sensitivity coefficient, green sensitivity coefficient and blue sensitivity coefficient respectively refer to constants used to represent the sensitivity to the clearness of coal color resolution, which can be obtained by consulting relevant literature or by preliminary experiments. The grayscale channel value refers to the grayscale value of the original image pixel.

[0039] S2. Perform image segmentation on the grayscale sample image to obtain a segmented sample image set, extract segmented sample images in the segmented sample image set in sequence, perform mean difference calculation on the segmented sample images, and obtain an image grayscale mean difference.

[0040] It can be understood that the segmented sample image set refers to a set of grayscale sample images after image segmentation, and the image grayscale mean difference refers to a parameter used to represent the grayscale color distribution difference in the segmented sample images. Due to the presence of coal impurities, the grayscale values ​​in the segmented sample images are not uniform, but there are large grayscale value differences. The segmented sample images can be distinguished by different grayscale value differences, so that different segmented sample images with different impurity contents can be processed differently in the subsequent process.

[0041] In detail, the image segmentation of the grayscale sample image to obtain a segmented sample image set includes: performing preliminary artificial segmentation on the grayscale sample image to obtain a preliminary segmented image set; performing the following operations on each preliminary segmented image in the preliminary segmented image set: identifying the maximum grayscale channel value and the minimum grayscale channel value in the preliminary segmented image, and calculating the image grayscale difference between the maximum grayscale channel value and the minimum grayscale channel value, wherein the image grayscale difference is the difference between the maximum grayscale channel value and the minimum grayscale channel value; respectively identifying the maximum grayscale pixel point and the minimum grayscale pixel point corresponding to the maximum grayscale channel value and the minimum grayscale channel value; judging whether the image grayscale difference is greater than a preset standard grayscale difference; if the image grayscale difference is greater than a preset standard grayscale difference, the image grayscale difference is greater than a preset standard grayscale difference. If the grayscale difference is greater than the standard grayscale difference, an image segmentation line is constructed based on the maximum grayscale pixel point and the minimum grayscale pixel point; the preliminary segmented image is segmented using the image segmentation line to obtain a secondary segmentation image set, wherein the secondary segmentation image set includes two secondary segmentation images; if the image grayscale difference is not greater than the standard grayscale difference, the preliminary segmented image is recorded as a segmentation sample image; the secondary segmentation image set is summarized to obtain a precise segmentation image set, the preliminary segmentation image set is updated using the precise segmentation image set, and the step of performing the following operations on each preliminary segmentation image in the preliminary segmentation image set is returned; the segmentation sample images are summarized to obtain a segmentation sample image set.

[0042] It is understandable that the preliminary segmented image set refers to the grayscale sample image after artificial preliminary division, and the artificial preliminary division can be to divide the grayscale sample image according to the grayscale color observed by the human eye, or it can be automatically divided according to a pre-set segmentation program, for example: the grayscale sample image is divided into 10 equal parts. The maximum grayscale channel value refers to the grayscale channel value with the largest value in the preliminary segmented image, the minimum grayscale channel value refers to the grayscale channel value with the smallest value in the preliminary segmented image, and the image grayscale difference refers to the difference between the maximum grayscale channel value and the minimum grayscale channel value, which is used to indicate the degree of color difference of the preliminary segmented image.

[0043] It can be understood that the maximum grayscale pixel point refers to the pixel point corresponding to the maximum grayscale channel value, the minimum grayscale pixel point refers to the pixel point corresponding to the minimum grayscale channel value, and the standard grayscale difference refers to the artificially set image grayscale difference, which is used to determine whether the preliminary segmented image needs to be segmented further. The image segmentation line refers to the line between the maximum grayscale pixel point and the minimum grayscale pixel point, and the image segmentation line is used to perform secondary segmentation on the preliminary segmented image.

[0044] In detail, the mean difference calculation of the segmented sample image to obtain the image grayscale mean difference includes: extracting segmentation pixels in the segmented sample image in sequence, and performing the following operations on the segmentation pixels: based on a preset neighborhood window value, collecting neighborhood pixels of the segmentation pixels to obtain a neighborhood pixel set, wherein the number of neighborhood pixels in the neighborhood pixel set is the same as the neighborhood window value; adding the segmentation pixels to the neighborhood pixel set to obtain a sequence pixel set, and identifying a sequence grayscale value set of the sequence pixel set; extracting the central grayscale value in the sequence grayscale value set, and using the central grayscale value to update the grayscale value of the segmentation pixel to obtain a smooth pixel; summarizing the smooth pixel points to obtain a smooth pixel set, using the smooth pixel set to update the segmentation sample image to obtain a smooth sample image, and identifying a smooth grayscale value set of the smooth sample image; calculating the mean difference of the smooth grayscale value set to obtain the image grayscale mean difference, wherein the image grayscale mean difference is expressed as:

[0045] ,in, Represents the grayscale mean difference of the image. Represents the number of smooth gray values ​​in the smooth gray value set, Represents the tth smoothed grayscale value, and t represents the arrangement sequence number of the smoothed grayscale value in the smoothed grayscale value set.

[0046] It can be understood that the segmentation pixel point refers to the pixel point in the segmentation sample image, the neighborhood window value refers to the artificially set constant representing the number of pixels around the segmentation pixel point, and the neighborhood pixel point set refers to the set of a pixels around the segmentation pixel point, where a represents the neighborhood window value. The sequence pixel point set refers to the neighborhood pixel point set after the segmentation pixel point is supplemented, and the sequence pixel points in the sequence pixel point set have been arranged according to the grayscale value of the sequence pixel points, and the sequence grayscale value set refers to the set of grayscale values ​​of the sequence pixel points.

[0047] It can be understood that the central grayscale value refers to the median of the sequence grayscale value set, and the smooth pixel point refers to the segmented pixel point after the central grayscale value is updated, and the grayscale value of the smooth pixel point will be replaced by the central grayscale value.

[0048] S3. Determine whether the image grayscale mean difference is within a preset coal mean difference range.

[0049] It should be explained that the coal mean difference range refers to an artificially set mean difference constant range, which is used to represent the range of the mean difference of the image grayscale of pure coal. Since different segmented sample images represent different coal purity levels, for segmented sample images with higher coal purity, the impurity content will be obtained by direct recognition, while for segmented sample images with lower coal purity, since the impurity situation displayed by the segmented sample images at this time is more complicated, the impurity content will be calculated by deep learning. The coal mean difference range is the constant range that distinguishes these two situations.

[0050] If the grayscale mean difference of the image is within the coal mean difference range, S4 is executed to record the segmented sample image as a pure sample image, and identify the pure impurity content of the pure sample image.

[0051] It can be understood that the pure impurity content refers to the impurity content of coal in the pure sample image, and the pure impurity content is expressed as a percentage.

[0052] In detail, the identification of the pure impurity content of the pure sample image includes: identifying the lower left vertex of the pure sample image, recording the lower left vertex as the extension starting point, identifying the maximum pure pixel point in the pure sample image, wherein the maximum pure pixel point is the pixel point with the largest grayscale value in the pure sample image; recording the line connecting the extension starting point and the maximum pure pixel point as the positive extension direction, identifying the starting grayscale value of the extension starting point, and identifying the pure sample image edge of the pure sample image; performing line segment extension based on the extension starting point and the positive extension direction to obtain an extension relay point, identifying the relay grayscale value of the extension relay point, and calculating the extended grayscale difference between the relay grayscale value and the starting grayscale value, wherein the extended relay point is the first line segment extending from the extension starting point. pixel points encountered once; judging whether the extended grayscale difference is greater than a preset standard extension difference; if the extended grayscale difference is not greater than the standard extension difference, continuing to extend the line segment in the positive extension direction until the line segment extends to the edge of the pure sample image; if the extended grayscale difference is greater than the standard extension difference, recording the extended relay point as an extended breakpoint, recording the line connecting the extended breakpoint and the extended starting point as an extended line segment, updating the extended starting point using the extended breakpoint, and returning to the step of extending the line segment based on the extended starting point and the positive extension direction; summarizing the extended line segments to obtain an extended line segment set, identifying the number of line segments in the extended line segment set, and calculating the pure impurity content based on the number of line segments and a preset adjustment factor using the following formula:

[0053] ,in, Indicates the pure impurity content, represents a natural constant, represents the adjustment factor, Indicates the number of line segments.

[0054] It can be understood that the starting point grayscale value refers to the grayscale value of the extension starting point, the extension relay point refers to the pixel point encountered for the first time after extending from the extension starting point, the relay grayscale value refers to the grayscale value corresponding to the extension relay point, the extension grayscale difference refers to the difference between the relay grayscale value and the starting point grayscale value, the standard extension difference refers to the artificially set extension grayscale difference, and the adjustment factor refers to an artificially set constant, which is used to adjust the pure impurity content calculation formula.

[0055] If the image grayscale mean difference is not within the coal mean difference range, execute S5, record the segmented sample image as a mixed sample image, construct a grayscale matrix for the mixed sample image, and obtain a grayscale co-occurrence matrix, wherein the grayscale co-occurrence matrix contains the grayscale value information of each pixel in the mixed sample image.

[0056] It can be understood that the gray level co-occurrence matrix refers to a matrix used to represent eigenvalues ​​in a mixed sample image, and the gray level co-occurrence matrix is ​​composed of the frequencies of the gray values ​​of each pixel in the mixed sample image.

[0057] In detail, the grayscale matrix of the mixed sample image is constructed to obtain a grayscale co-occurrence matrix, including: performing grayscale value conversion on the mixed sample image according to a preset mixed grayscale level to obtain a mixed grayscale image, wherein the mixed grayscale level is less than the original grayscale level in the mixed sample image; setting an adjacent step length, sequentially extracting mixed pixels in the mixed grayscale image, and extracting adjacent pixels of the mixed pixels based on the adjacent step length to obtain an adjacent pixel set; matching the mixed pixel with each adjacent pixel in the adjacent pixel set to obtain an adjacent pixel group set, wherein each adjacent pixel group in the adjacent pixel group set is represented as:

[0058] , ,in, represents the first adjacent pixel group, Represents mixed pixels, Represents the coordinates of the mixed pixel points, represents the first adjacent pixel, represents the coordinates of the first adjacent pixel, d represents the adjacent step length, represents the second adjacent pixel group, represents the second adjacent pixel, Represents the coordinates of the second adjacent pixel, represents the third adjacent pixel group, represents the third adjacent pixel, Represents the coordinates of the third adjacent pixel, represents the 4th adjacent pixel group, represents the 4th adjacent pixel, represents the coordinates of the fourth adjacent pixel point; grayscale values ​​of the adjacent pixel point set are identified to obtain an adjacent grayscale value set, wherein each adjacent grayscale value set in the adjacent grayscale value set is represented as:

[0059] , ,in, represents the first adjacent gray value group, Represents the grayscale value of the mixed pixel, Represents the gray value of the first adjacent pixel, represents the second adjacent gray value group, Represents the gray value of the second adjacent pixel. represents the third adjacent gray value group, Represents the gray value of the third adjacent pixel, represents the 4th adjacent gray value group, represents the gray value of the 4th adjacent pixel; summarizing the adjacent gray value groups to obtain a matrix gray value group, and constructing a gray level co-occurrence matrix according to the matrix gray value group.

[0060] It can be understood that the mixed grayscale level refers to the artificially set range of grayscale values. Since the grayscale level of the image is too high, the grayscale co-occurrence matrix constructed subsequently will be too complicated, so the original grayscale level needs to be converted into a mixed grayscale level. The mixed grayscale image refers to the mixed sample image after the mixed grayscale level conversion. The adjacent step size refers to an artificially set constant. The adjacent step size represents the range of adjacent pixel points of the mixed pixel point. The adjacent step size can be set to: 1, 2, etc. The mixed pixel point refers to the pixel point in the mixed grayscale image, and the adjacent pixel point set refers to the pixel point at a distance d from the mixed pixel point, where d represents the adjacent step size.

[0061] For example, the original grayscale level of a mixed sample image is 256. In order to simplify the subsequently constructed grayscale co-occurrence matrix, the mixed grayscale level is set to 16, and the grayscale level of the mixed sample image is updated according to the mixed grayscale level to obtain a mixed grayscale image, that is, the grayscale level of the mixed grayscale image is 16.

[0062] It should be explained that the adjacent gray value group refers to the set of gray values ​​of each pixel in the adjacent pixel group. For example, the adjacent pixel group is , where the gray value of pixel a is , the gray value of pixel b is , then the adjacent gray value group is .

[0063] In detail, constructing a grayscale co-occurrence matrix according to the matrix grayscale value group set includes: extracting matrix grayscale value groups in the matrix grayscale value group set in sequence, counting the grayscale frequencies of the matrix grayscale value groups in the matrix grayscale value group set, and obtaining a grayscale frequency set, wherein each matrix grayscale value group corresponds to a unique grayscale frequency, and each grayscale frequency corresponds to one or more matrix grayscale value groups; constructing a grayscale co-occurrence matrix based on the grayscale frequency set, wherein the grayscale co-occurrence matrix is ​​expressed as:

[0064] ,in, represents the gray-level co-occurrence matrix, Indicates that the adjacent gray value group is The grayscale frequency, Indicates that the adjacent gray value group is The grayscale frequency, M represents the maximum value of the mixed grayscale level, Indicates that the adjacent gray value group is The grayscale frequency, Represents the maximum ordinate in a set of adjacent pixel points, Indicates that the adjacent gray value group is The grayscale frequency.

[0065] It can be understood that the grayscale frequency refers to the frequency at which the matrix grayscale value group appears in the matrix grayscale value group set.

[0066] For example, a matrix grayscale value group set is expressed as: {[1,2], [1,1], [1,3], [1,2]}. Since the frequency of occurrence of the matrix grayscale value group [1,2] is 2, and the frequencies of occurrence of the matrix grayscale value groups [1,1] and [1,3] are both 1, the grayscale frequency set of the matrix grayscale value group set is expressed as: {2,1,1}.

[0067] S6. Using the gray level co-occurrence matrix to extract image eigenvalues, and obtaining uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues.

[0068] It can be understood that the uniform eigenvalue refers to a numerical value used to represent the uniformity of the grayscale distribution of the mixed sample image, the clear eigenvalue refers to a numerical value used to represent the clarity of the mixed sample image, and the smooth eigenvalue refers to a numerical value used to represent the complexity of the texture of the mixed sample image. By extracting uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​from the grayscale co-occurrence matrix and through subsequent deep learning calculations, the content of coal impurities in the mixed sample image can be reflected.

[0069] In detail, the method of extracting image eigenvalues ​​using the gray level co-occurrence matrix to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​includes: calculating uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​using the following formulas according to the gray level co-occurrence matrix:

[0070] , , ,in, represents the uniform eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency, represents a clear eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency, represents the logarithmic function, represents the smoothed eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency.

[0071] S7. Input the uniform eigenvalue, the clear eigenvalue and the smooth eigenvalue into a pre-built data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model.

[0072] It can be understood that the data processing center refers to a platform for data processing of the entire washed coal impurity content, which includes a deep learning model for coal impurity content analysis, such as: convolutional neural network, BP neural network, etc. The mixed impurity content refers to the coal impurity content in the mixed sample image, and the mixed impurity content is a percentage value.

[0073] It needs to be explained that the deep learning model needs to go through a large amount of data exercises in the early stage. For example, relevant personnel manually analyze the impurity content of the experimental coal block and record the results of the analysis. The manual analysis result is the impurity content of the coal pile. At the same time, the shooting module is used to perform image recognition on the experimental coal block to obtain image recognition feature values, which are uniform feature values, clear feature values ​​and smooth feature values. The above experiments are repeated to obtain a large amount of basic data for deep learning model training. The basic data is composed of manual analysis results and image recognition feature values. Finally, the selected convolutional neural network completes data training through a large amount of basic data.

[0074] S8. Summarize the pure impurity contents and the mixed impurity contents respectively to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity contents and the mixed impurity contents is the same as the number of segmented sample images.

[0075] It is understandable that each segmented sample image corresponds to only a unique pure impurity content or mixed impurity content, so the total number of pure impurity contents and mixed impurity contents should be the same as the number of segmented sample images.

[0076] S9. Calculate the total impurity content of the sample according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

[0077] In detail, the calculation of the total impurity content of the sample according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content includes: setting the pure content weight of the pure sample image and the mixed content weight of the mixed sample image respectively, and based on the pure content weight, the mixed content weight, the pure impurity content set and the mixed impurity content set, using the following formula to calculate the target coal impurity content:

[0078] ,in, Indicates the target coal impurity content, represents the purity content weight, Indicates the number of pure impurity contents in the pure impurity content concentration, Indicates Pure impurity content, Indicates the arrangement number of the pure impurity content in the pure impurity content concentration, represents the mixed content weight, Indicates the number of mixed impurity contents in the mixed impurity content concentration, Indicates Mixed impurities content, Indicates the arrangement sequence number of the mixed impurity content in the mixed impurity content concentration.

[0079] It can be understood that the pure content weight refers to a constant used to represent the proportion of pure impurity content when calculating the target coal impurity content, and the mixed content weight refers to a constant used to represent the proportion of mixed impurity content when calculating the target coal impurity content, wherein the pure content weight and the mixed content weight are both artificially set.

[0080] It should be explained that since there are more coal impurities in the mixed sample image, in order to ensure the stability of the subsequent coal washing steps, it is necessary to increase the proportion of the mixed impurity content when calculating the target coal impurity content, so as to increase the fault tolerance of the subsequent coal washing steps.

[0081] In order to solve the problems described in the background technology, the present invention first obtains a target coal sample, and shoots an image of the target coal sample to obtain an original sample image, and performs grayscale conversion on the original sample image to obtain a grayscale sample image. In this step, the physical properties of the target coal sample are converted into a digital image through image shooting, providing basic data for subsequent image processing and analysis. At the same time, the grayscale conversion helps to reduce the complexity of image processing, while retaining the key information of the image, providing clearer image data for subsequent image segmentation and feature extraction. Next, the grayscale sample image is segmented to obtain a segmented sample image set, and the segmented sample images are sequentially extracted from the segmented sample image set. The sample image is subjected to mean difference calculation to obtain the image grayscale mean difference. Among them, the grayscale sample image can be segmented to separate different areas in the target coal sample, so as to facilitate the separate analysis of the impurity content in different areas. Then, it is judged whether the image grayscale mean difference is within the coal mean difference range. By comparing the image grayscale mean difference with the coal mean difference range, the distribution of impurities in the coal sample can be preliminarily judged, which provides a reference for the subsequent impurity content analysis. If the image grayscale mean difference is within the coal mean difference range, the grayscale sample image is recorded as a pure sample image, and the pure impurity content of the pure sample image is identified. For samples with low impurity content, this step can directly identify and calculate their impurity content, simplifying the process. The analysis process of impurity content is improved, and the intelligence level of coal washing is improved. If the grayscale mean difference of the image is not within the range of the coal mean difference, the grayscale sample image is recorded as a mixed sample image, and the grayscale matrix of the mixed sample image is constructed to obtain a grayscale co-occurrence matrix. The grayscale co-occurrence matrix constructed in this step is helpful for in-depth analysis of the texture characteristics of the coal sample, providing richer data for subsequent impurity content analysis, while also reducing excessive consumption of time and human resources. Then, the grayscale co-occurrence matrix is ​​used to extract image eigenvalues, and uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​are obtained. The uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​extracted in this step can reflect the texture and The structural features provide key input data for the subsequent deep learning model. At the same time, the deep learning model is used to replace manual analysis to a great extent, which improves the intelligence level of impurity content analysis of washed coal. Next, the uniform eigenvalue, clear eigenvalue and smooth eigenvalue are input to the data processing center to obtain the mixed impurity content. This step completes the impurity content analysis of mixed sample images with more impurities. Finally, the pure impurity content and the mixed impurity content are summarized respectively to obtain the pure impurity content set and the mixed impurity content set. According to the pure impurity content set and the mixed impurity content set, the total impurity content of the sample is calculated to obtain the target coal impurity content, and the impurity content analysis of washed coal is completed. Therefore, the present invention can improve the intelligence level of impurity content analysis of washed coal and reduce the excessive consumption of time and human resources.

[0082] like Figure 2As shown, it is a functional module diagram of an impurity content analysis system for washed coal based on deep learning provided by one embodiment of the present invention.

[0083] The impurity content analysis system 100 for washing coal based on deep learning of the present invention can be installed in an electronic device. According to the functions implemented, the impurity content analysis system 100 for washing coal based on deep learning can include an image mean difference acquisition module 101, an image grayscale determination module 102, a mixed feature processing module 103 and an impurity content calculation module 104. The module of the present invention can also be called a unit, which refers to a series of computer program segments that can be executed by an electronic device processor and can complete fixed functions, which are stored in the memory of the electronic device.

[0084] The image mean difference acquisition module 101 is used to acquire a target coal sample, capture an image of the target coal sample to obtain an original sample image, perform grayscale conversion on the original sample image to obtain a grayscale sample image, perform image segmentation on the grayscale sample image to obtain a segmented sample image set, extract segmented sample images in the segmented sample image set in sequence, perform mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; the image grayscale determination module 102 is used to determine whether the image grayscale mean difference is within a preset coal mean difference range. If the image grayscale mean difference is within the coal mean difference range, the segmented sample image is recorded as a pure sample image, and the pure impurity content of the pure sample image is identified. If the image grayscale mean difference is not within the coal mean difference range, the segmented sample image is recorded as a mixed sample image, and a grayscale matrix is ​​constructed for the mixed sample image. The mixed feature processing module 103 is used to extract image eigenvalues ​​using the grayscale co-occurrence matrix to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues, and input the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​into a pre-constructed data processing center to obtain mixed impurity content, wherein the data processing center has a built-in deep learning model; the impurity content calculation module 104 is used to summarize the pure impurity content and the mixed impurity content respectively to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of segmented sample images, and the total impurity content of the sample is calculated according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

[0085] In detail, the modules in the impurity content analysis system 100 for coal washing based on deep learning in the embodiment of the present invention are used in the same manner as above. Figure 1The same technical means as the method for analyzing impurity content of washed coal based on deep learning described in the text can produce the same technical effects, so I will not go into details here.

[0086] like Figure 3 , is a schematic diagram of the structure of an electronic device for implementing a method for analyzing impurity content of washed coal based on deep learning provided by an embodiment of the present invention.

[0087] The electronic device 1 may include a processor 10, a memory 11 and a bus 12, and may also include a computer program stored in the memory 11 and executable on the processor 10, such as a method program for analyzing impurity content of washed coal based on deep learning.

[0088] Among them, the memory 11 includes at least one type of readable storage medium, and the readable storage medium includes flash memory, mobile hard disk, multimedia card, card-type memory (for example: SD or DX memory, etc.), magnetic memory, disk, optical disk, etc. In some embodiments, the memory 11 can be an internal storage unit of the electronic device 1, such as a mobile hard disk of the electronic device 1. In other embodiments, the memory 11 can also be an external storage device of the electronic device 1, such as a plug-in mobile hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (SecureDigital, SD) card, a flash card (Flash Card), etc. equipped on the electronic device 1. Further, the memory 11 also includes an internal storage unit of the electronic device 1 and an external storage device. The memory 11 can not only be used to store application software and various types of data installed in the electronic device 1, such as the code of the impurity content analysis method program for washing coal based on deep learning, but also can be used to temporarily store data that has been output or is to be output.

[0089] The processor 10 may be composed of an integrated circuit in some embodiments, for example, a single packaged integrated circuit, or a plurality of packaged integrated circuits with the same or different functions, including one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and a combination of various control chips, etc. The processor 10 is the control core (Control Unit) of the electronic device, and uses various interfaces and lines to connect various components of the entire electronic device, and executes or executes programs or modules stored in the memory 11 (for example, a program for analyzing impurity content of washed coal based on deep learning, etc.), and calls data stored in the memory 11 to execute various functions of the electronic device 1 and process data.

[0090] The bus 12 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus, etc. The bus 12 may be divided into an address bus, a data bus, a control bus, etc. The bus 12 is configured to realize connection and communication between the memory 11 and at least one processor 10, etc.

[0091] Figure 3 Only an electronic device with components is shown, and those skilled in the art will understand that Figure 3 The structure shown does not constitute a limitation on the electronic device 1, and may include fewer or more components than shown in the figure, or combine certain components, or arrange the components differently.

[0092] For example, although not shown, the electronic device 1 may also include a power source (such as a battery) for supplying power to various components. Preferably, the power source may be logically connected to the at least one processor 10 through a power management system, so that the power management system can realize functions such as charging management, discharging management, and power consumption management. The power source may also include any components such as one or more DC or AC power sources, recharging systems, power failure detection circuits, power converters or inverters, and power status indicators. The electronic device 1 may also include a variety of sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be repeated here.

[0093] Furthermore, the electronic device 1 may also include a network interface. Optionally, the network interface may include a wired interface and / or a wireless interface (such as a WI-FI interface, a Bluetooth interface, etc.), which is generally used to establish a communication connection between the electronic device 1 and other electronic devices.

[0094] Optionally, the electronic device 1 may further include a user interface, which may be a display, an input unit (such as a keyboard), or a standard wired interface or a wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, and an OLED (Organic Light-Emitting Diode) touch device. The display may also be appropriately referred to as a display screen or a display unit, which is used to display information processed in the electronic device 1 and to display a visual user interface.

[0095] The program of the impurity content analysis method for washed coal based on deep learning stored in the memory 11 in the electronic device 1 is a combination of multiple instructions. When running in the processor 10, it can achieve: obtaining a target coal sample, capturing an image of the target coal sample to obtain an original sample image, performing grayscale conversion on the original sample image to obtain a grayscale sample image; performing image segmentation on the grayscale sample image to obtain a segmented sample image set, extracting segmented sample images in sequence from the segmented sample image set, performing mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; judging whether the image grayscale mean difference is within a preset coal mean difference range; if the image grayscale mean difference is within the coal mean difference range, recording the segmented sample image as a pure sample image, and identifying the pure impurity content of the pure sample image; if the image grayscale mean difference is not within the coal mean difference range, The segmented sample image is recorded as a mixed sample image, and a grayscale matrix is ​​constructed for the mixed sample image to obtain a grayscale co-occurrence matrix, wherein the grayscale co-occurrence matrix contains the grayscale value information of each pixel in the mixed sample image; the grayscale co-occurrence matrix is ​​used to extract image eigenvalues ​​to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues; the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​are input into a pre-constructed data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model; the pure impurity content and the mixed impurity content are respectively summarized to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of segmented sample images; the total impurity content of the sample is calculated according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

[0096] Specifically, the specific implementation method of the processor 10 for the above instructions can refer to Figures 1 to 3 The description of the relevant steps in the corresponding embodiments will not be repeated here.

[0097] Furthermore, if the module / unit integrated in the electronic device 1 is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. The computer-readable storage medium can be volatile or non-volatile. For example, the computer-readable medium can include: any entity or system that can carry the computer program code, a recording medium, a USB flash drive, a mobile hard disk, a magnetic disk, an optical disk, a computer memory, and a read-only memory (ROM).

[0098] The present invention also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor of an electronic device, it can achieve the following: obtaining a target coal sample, photographing the target coal sample to obtain an original sample image, performing grayscale conversion on the original sample image to obtain a grayscale sample image; performing image segmentation on the grayscale sample image to obtain a segmented sample image set, sequentially extracting segmented sample images from the segmented sample image set, performing mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; judging whether the image grayscale mean difference is within a preset coal mean difference range; if the image grayscale mean difference is within the coal mean difference range, recording the segmented sample image as a pure sample image, and identifying the pure impurity content of the pure sample image; if the image grayscale mean difference is not within the coal mean difference range, recording the segmented sample image as a pure sample image, and identifying the pure impurity content of the pure sample image; The cut sample image is recorded as a mixed sample image, and a grayscale matrix is ​​constructed for the mixed sample image to obtain a grayscale co-occurrence matrix, wherein the grayscale co-occurrence matrix contains the grayscale value information of each pixel in the mixed sample image; the image eigenvalues ​​are extracted using the grayscale co-occurrence matrix to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues; the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​are input into a pre-constructed data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model; the pure impurity content and the mixed impurity content are respectively summarized to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of the cut sample images; the total impurity content of the sample is calculated according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

[0099] In the several embodiments provided by the present invention, it should be understood that the disclosed devices, systems and methods can be implemented in other ways. For example, the system embodiments described above are only illustrative, and actual implementation may have other division methods.

[0100] The modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0101] In addition, each functional module in each embodiment of the present invention may be integrated into one processing unit, each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional modules.

[0102] It is obvious to those skilled in the art that the present invention is not limited to the details of the above exemplary embodiments, and that the present invention can be implemented in other specific forms without departing from the spirit or essential characteristics of the present invention.

[0103] Finally, it should be noted that the above embodiments are only used to illustrate the technical solution of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solution of the present invention can be modified or replaced by equivalents without departing from the spirit and scope of the technical solution of the present invention.

Claims

1. A method for analyzing impurity content in washed coal based on deep learning, characterized in that: The method comprises: obtaining a target coal sample, photographing the target coal sample to obtain an original sample image, performing grayscale conversion on the original sample image to obtain a grayscale sample image; performing image segmentation on the grayscale sample image to obtain a segmented sample image set, sequentially extracting segmented sample images from the segmented sample image set, performing mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; judging whether the image grayscale mean difference is within a preset coal mean difference range; if the image grayscale mean difference is within the coal mean difference range, recording the segmented sample image as a pure sample image, and identifying the pure impurity content of the pure sample image; if the image grayscale mean difference is not within the coal mean difference range, recording the segmented sample image as a mixed sample image, and performing grayscale matrix calculation on the mixed sample image. A gray level co-occurrence matrix is ​​constructed to obtain a gray level co-occurrence matrix, wherein the gray level co-occurrence matrix contains the gray level value information of each pixel in the mixed sample image; the gray level co-occurrence matrix is ​​used to extract image eigenvalues ​​to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues; the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​are input into a pre-constructed data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model; the pure impurity content and the mixed impurity content are respectively summarized to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of segmented sample images; the total impurity content of the sample is calculated according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

2. The method for analyzing impurity content of washed coal based on deep learning according to claim 1, characterized in that: The grayscale conversion of the original sample image to obtain a grayscale sample image includes: extracting original image pixels from the original sample image, and identifying RGB channel values ​​of the original image pixels in the RGB color space, wherein the RGB channel values ​​are expressed as: ,in, Represents the RGB channel value, Represents the red channel value, Represents the green channel value, represents the blue channel value; sets the red sensitivity coefficient, the green sensitivity coefficient and the blue sensitivity coefficient, and converts the RGB channel value into a gray channel value based on the red sensitivity coefficient, the green sensitivity coefficient and the blue sensitivity coefficient, wherein the gray channel value is represented as: ,in, Represents the grayscale channel value, represents the red sensitivity coefficient, represents the green sensitivity coefficient, represents the blue sensitivity coefficient; using the grayscale channel value to update the original image pixel points to obtain grayscale image pixel points, summarizing the grayscale image pixel points to obtain a grayscale image pixel point set; using the grayscale image pixel point set to update the original sample image to obtain a grayscale sample image.

3. The method for analyzing impurity content of washed coal based on deep learning according to claim 2, characterized in that: The method of performing image segmentation on the grayscale sample image to obtain a segmented sample image set includes: performing preliminary artificial segmentation on the grayscale sample image to obtain a preliminary segmented image set; performing the following operations on each preliminary segmented image in the preliminary segmented image set: identifying the maximum grayscale channel value and the minimum grayscale channel value in the preliminary segmented image, and calculating the image grayscale difference between the maximum grayscale channel value and the minimum grayscale channel value, wherein the image grayscale difference is the difference between the maximum grayscale channel value and the minimum grayscale channel value; respectively identifying the maximum grayscale pixel point and the minimum grayscale pixel point corresponding to the maximum grayscale channel value and the minimum grayscale channel value; judging whether the image grayscale difference is greater than a preset standard grayscale difference; if the image grayscale difference is greater than a preset standard grayscale difference, the image grayscale difference is greater than a preset standard grayscale difference. If the value is greater than the standard grayscale difference, an image segmentation line is constructed based on the maximum grayscale pixel point and the minimum grayscale pixel point; the preliminary segmented image is segmented using the image segmentation line to obtain a secondary segmentation image set, wherein the secondary segmentation image set contains two secondary segmentation images; if the image grayscale difference is not greater than the standard grayscale difference, the preliminary segmented image is recorded as a segmentation sample image; the secondary segmentation image set is summarized to obtain a precise segmentation image set, the preliminary segmentation image set is updated using the precise segmentation image set, and the step of performing the following operations on each preliminary segmentation image in the preliminary segmentation image set is returned; the segmentation sample images are summarized to obtain a segmentation sample image set.

4. The method for analyzing impurity content of washed coal based on deep learning according to claim 3, characterized in that: The method of performing mean difference calculation on the segmented sample image to obtain the image grayscale mean difference comprises: extracting segmentation pixels in the segmented sample image in sequence, and performing the following operations on the segmentation pixels: based on a preset neighborhood window value, performing neighborhood pixel collection on the segmentation pixels to obtain a neighborhood pixel point set, wherein the number of neighborhood pixels in the neighborhood pixel point set is the same as the neighborhood window value; supplementing the segmentation pixels to the neighborhood pixel point set to obtain a sequence pixel point set, and identifying a sequence grayscale value set of the sequence pixel point set; extracting the central grayscale value of the sequence grayscale value set, and using the central grayscale value to update the grayscale value of the segmentation pixels to obtain smoothed pixels; summarizing the smoothed pixels to obtain a smoothed pixel point set, and using the smoothed pixel point set to update the segmented sample image to obtain a smoothed sample image, and identifying a smoothed grayscale value set of the smoothed sample image; performing mean difference calculation on the smoothed grayscale value set to obtain the image grayscale mean difference, wherein the image grayscale mean difference is expressed as: ,in, Represents the mean grayscale difference of the image. Represents the number of smooth gray values ​​in the smooth gray value set, Represents the tth smoothed grayscale value, and t represents the arrangement sequence number of the smoothed grayscale value in the smoothed grayscale value set.

5. The method for analyzing impurity content of washed coal based on deep learning according to claim 4, characterized in that: The method for identifying the pure impurity content of the pure sample image includes: identifying the lower left vertex of the pure sample image, recording the lower left vertex as the extension starting point, identifying the maximum pure pixel point in the pure sample image, wherein the maximum pure pixel point is the pixel point with the largest grayscale value in the pure sample image; recording the line connecting the extension starting point and the maximum pure pixel point as the positive extension direction, identifying the starting grayscale value of the extension starting point, and identifying the pure sample image edge of the pure sample image; performing line segment extension based on the extension starting point and the positive extension direction to obtain an extension relay point, identifying the relay grayscale value of the extension relay point, and calculating the extended grayscale difference between the relay grayscale value and the starting grayscale value, wherein the extension relay point is the first extension from the extension starting point. pixel points encountered; judging whether the extended grayscale difference is greater than a preset standard extended difference; if the extended grayscale difference is not greater than the standard extended difference, continuing to extend the line segment in the positive extension direction until the line segment extends to the edge of the pure sample image; if the extended grayscale difference is greater than the standard extended difference, recording the extended relay point as an extended breakpoint, recording the line connecting the extended breakpoint and the extended starting point as an extended line segment, updating the extended starting point using the extended breakpoint, and returning to the step of extending the line segment based on the extended starting point and the positive extension direction; summarizing the extended line segments to obtain an extended line segment set, identifying the number of line segments in the extended line segment set, and calculating the pure impurity content based on the number of line segments and a preset adjustment factor using the following formula: ,in, Indicates the pure impurity content, represents a natural constant, represents the adjustment factor, Indicates the number of line segments.

6. The method for analyzing impurity content of washed coal based on deep learning according to claim 5, characterized in that: The grayscale matrix of the mixed sample image is constructed to obtain a grayscale co-occurrence matrix, including: performing grayscale value conversion on the mixed sample image according to a preset mixed grayscale level to obtain a mixed grayscale image, wherein the mixed grayscale level is less than the original grayscale level in the mixed sample image; setting an adjacent step length, sequentially extracting mixed pixels in the mixed grayscale image, and extracting adjacent pixels of the mixed pixels based on the adjacent step length to obtain an adjacent pixel set; matching the mixed pixel with each adjacent pixel in the adjacent pixel set to obtain an adjacent pixel group set, wherein each adjacent pixel group in the adjacent pixel group set is respectively expressed as: , ,in, represents the first adjacent pixel group, Represents mixed pixels, Represents the coordinates of the mixed pixel points, represents the first adjacent pixel, represents the coordinates of the first adjacent pixel, d represents the adjacent step length, represents the second adjacent pixel group, represents the second adjacent pixel, Represents the coordinates of the second adjacent pixel, represents the third group of adjacent pixels, represents the third adjacent pixel, Represents the coordinates of the third adjacent pixel, represents the 4th adjacent pixel group, represents the 4th adjacent pixel, Indicates the coordinates of the 4th adjacent pixel; Grayscale values ​​of the adjacent pixel point groups are identified to obtain adjacent grayscale value groups, wherein each adjacent grayscale value group in the adjacent grayscale value group is represented as: , ,in, represents the first adjacent gray value group, Represents the grayscale value of the mixed pixel, Represents the gray value of the first adjacent pixel, represents the second adjacent gray value group, Represents the gray value of the second adjacent pixel. represents the third adjacent gray value group, Represents the gray value of the third adjacent pixel, represents the 4th adjacent gray value group, represents the gray value of the 4th adjacent pixel; summarizing the adjacent gray value groups to obtain a matrix gray value group, and constructing a gray level co-occurrence matrix according to the matrix gray value group.

7. The method for analyzing impurity content of washed coal based on deep learning according to claim 6, characterized in that: The step of constructing a grayscale co-occurrence matrix according to the matrix grayscale value group set includes: sequentially extracting matrix grayscale value groups from the matrix grayscale value group set, and counting the grayscale frequencies of the matrix grayscale value groups in the matrix grayscale value group set to obtain a grayscale frequency set, wherein each matrix grayscale value group corresponds to a unique grayscale frequency, and each grayscale frequency corresponds to one or more matrix grayscale value groups; and constructing a grayscale co-occurrence matrix based on the grayscale frequency set, wherein the grayscale co-occurrence matrix is ​​expressed as: ,in, represents the gray-level co-occurrence matrix, Indicates that the adjacent gray value group is The grayscale frequency, Indicates that the adjacent gray value group is The grayscale frequency, M represents the maximum value of the mixed grayscale level, Indicates that the adjacent gray value group is The grayscale frequency, Represents the maximum ordinate in a set of adjacent pixel points. Indicates that the adjacent gray value group is The grayscale frequency.

8. The method for analyzing impurity content of washed coal based on deep learning according to claim 7, characterized in that: The method of using the gray level co-occurrence matrix to extract image eigenvalues ​​to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​includes: according to the gray level co-occurrence matrix, using the following formulas to calculate uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​respectively: , in, represents the uniform eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency, represents a clear eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency, represents the logarithmic function, represents the smoothed eigenvalue, Indicates that the adjacent gray value group is The grayscale frequency.

9. The method for analyzing impurity content of washed coal based on deep learning according to claim 8, characterized in that: The method of calculating the total impurity content of the sample according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content includes: respectively setting the pure content weight of the pure sample image and the mixed content weight of the mixed sample image, and calculating the target coal impurity content based on the pure content weight, the mixed content weight, the pure impurity content set and the mixed impurity content set using the following formula: ,in, Indicates the target coal impurity content, represents the purity content weight, Indicates the number of pure impurity contents in the pure impurity content concentration, Indicates Pure impurity content, Indicates the arrangement number of the pure impurity content in the pure impurity content concentration, represents the mixed content weight, Indicates the number of mixed impurity contents in the mixed impurity content concentration, Indicates Mixed impurities content, Indicates the arrangement sequence number of the mixed impurity content in the mixed impurity content concentration.

10. A system for analyzing impurity content of washed coal based on deep learning, characterized in that: The system includes: an image mean difference acquisition module, which is used to acquire a target coal sample, capture an image of the target coal sample to obtain an original sample image, perform grayscale conversion on the original sample image to obtain a grayscale sample image, perform image segmentation on the grayscale sample image to obtain a segmented sample image set, extract segmented sample images in the segmented sample image set in sequence, perform mean difference calculation on the segmented sample images to obtain an image grayscale mean difference; an image grayscale determination module, which is used to determine whether the image grayscale mean difference is within a preset coal mean difference range; if the image grayscale mean difference is within the coal mean difference range, the segmented sample image is recorded as a pure sample image, and the pure impurity content of the pure sample image is identified; if the image grayscale mean difference is not within the coal mean difference range, the segmented sample image is recorded as a mixed sample image, and grayscale conversion is performed on the mixed sample image A matrix is ​​constructed to obtain a gray level co-occurrence matrix, wherein the gray level co-occurrence matrix includes the gray level value of each pixel in the mixed sample image; a mixed feature processing module is used to use the gray level co-occurrence matrix to extract image eigenvalues ​​to obtain uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues, and the uniform eigenvalues, clear eigenvalues ​​and smooth eigenvalues ​​are input into a pre-constructed data processing center to obtain a mixed impurity content, wherein the data processing center has a built-in deep learning model; an impurity content calculation module is used to summarize the pure impurity content and the mixed impurity content respectively to obtain a pure impurity content set and a mixed impurity content set, wherein the total number of the pure impurity content and the mixed impurity content is the same as the number of segmented sample images, and the total impurity content of the sample is calculated according to the pure impurity content set and the mixed impurity content set to obtain the target coal impurity content.

Citation Information

Patent Citations

  • Intelligent coal gangue sorting method and system based on image deep learning

    CN119251600A

  • Method and apparatus for determining particle parameter and processor performance in a coal and mineral processing system

    US20070095168A1