CN113470058A - Gravel particle size distribution measuring method and device - Google Patents

Gravel particle size distribution measuring method and device Download PDF

Info

Publication number
CN113470058A
CN113470058A CN202110784549.4A CN202110784549A CN113470058A CN 113470058 A CN113470058 A CN 113470058A CN 202110784549 A CN202110784549 A CN 202110784549A CN 113470058 A CN113470058 A CN 113470058A
Authority
CN
China
Prior art keywords
image
sample
gravel
threshold value
particle size
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
CN202110784549.4A
Other languages
Chinese (zh)
Inventor
王卫星
葛琼
陈方昪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
University of Shaoxing
Original Assignee
University of Shaoxing
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by University of Shaoxing filed Critical University of Shaoxing
Priority to CN202110784549.4A priority Critical patent/CN113470058A/en
Publication of CN113470058A publication Critical patent/CN113470058A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/136Segmentation; Edge detection involving thresholding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/194Segmentation; Edge detection involving foreground-background segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • General Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • Biomedical Technology (AREA)
  • Molecular Biology (AREA)
  • Biophysics (AREA)
  • General Engineering & Computer Science (AREA)
  • Artificial Intelligence (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Image Analysis (AREA)

Abstract

The invention discloses a method and a device for measuring the particle size distribution of gravel. The method comprises the following steps: inputting a first image to be detected into a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; removing background objects in the first image based on an automatic particle size distribution algorithm and a first threshold value to obtain a second image; filling each gravel in the second image by adopting an area filling technology to obtain a third image; taking the second threshold value as an H value in H-minima transformation, and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image; and measuring the short axis of each gravel in the fourth image by adopting a Hotelling transformation to classify each gravel in the fourth image, and drawing a particle size distribution diagram of each gravel type. The method and the device can improve the accuracy of gravel particle size distribution measurement.

Description

Gravel particle size distribution measuring method and device
Technical Field
The invention belongs to the field of complex particle image segmentation, and particularly relates to a method and a device for measuring the particle size distribution of gravel.
Background
The topography of the river bed is affected by various shapes and sizes of gravel, and particle size distribution measurements of gravel are an important task in hydraulics, topography, and ecology. The development of digital image technology and computer software has increased the possibility of automated image analysis, thus facilitating the development of particle size distribution measurements of gravel, enabling the measurement of gravel particle size distribution by an automated particle size distribution Algorithm (AGS).
The river bed image generally comprises a plurality of gravels and background objects, the background objects are sand grounds, and researches show that a proper binary threshold value is determined in the AGS, so that the gravels and the sand grounds can be distinguished from the grayed binary image, namely the gray image of the colorful river bed image (generally, the white part is the gravels, and the black part is the sand grounds), an image only containing the gravels is obtained, and a foundation is laid for the subsequent measurement of the gravel particle size distribution.
In the prior art, an expert can determine a proper binary threshold value by manually identifying a riverbed image, but the process is a long and tedious process, and human subjective judgment is easy to make mistakes, so that the accuracy of subsequent gravel particle size distribution measurement is low.
Disclosure of Invention
In view of the above drawbacks and needs of the prior art, the present invention provides a method and an apparatus for measuring the particle size distribution of gravel, which aims to improve the accuracy of measuring the particle size distribution of gravel, thereby solving the technical problem of inaccurate measurement of the particle size distribution of gravel.
To achieve the above object, according to one aspect of the present invention, there is provided a method for measuring a particle size distribution of gravel, comprising:
inputting a first image to be detected into a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects;
removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image;
filling each gravel in the second image by adopting an area filling technology to obtain a third image;
taking the second threshold value as an H value in H-minima transformation, and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image;
and measuring the short axis of each gravel in the fourth image by adopting a Hotelling transformation to classify each gravel in the fourth image, and drawing a particle size distribution diagram of each type of gravel.
Preferably, the neural network model is a back propagation based fuzzy neural network.
Preferably, the first image to be measured is input to a preset neural network model, and the method further includes:
acquiring an original color image to be detected; wherein the original color image comprises a plurality of gravel and background objects;
and performing downsampling on the original color image by adopting discrete wavelet transform to obtain a first image to be detected.
Preferably, the neural network model is obtained as follows:
obtaining a plurality of sample original color images; wherein the sample original color image comprises a plurality of gravel and background objects;
adopting discrete wavelet transform to carry out downsampling on each sample original image to obtain a first sample image corresponding to each sample original image;
acquiring a first sample threshold value and a second sample threshold value corresponding to each first sample image, and combining each sample original image and the corresponding first sample threshold value and second sample threshold value to form a sample;
combining a plurality of the samples to form a training set, training the neural network model based on the training set to adjust parameters of the neural network model.
Preferably, training the neural network model based on the training set to adjust parameters of the neural network model comprises:
for any one sample, inputting the first sample image in the sample into the neural network model, and outputting a first prediction threshold value and a second prediction threshold value corresponding to the first sample image;
calculating a loss value according to the first prediction threshold value and the first sample threshold value in the sample, and the second prediction threshold value and the second sample threshold value in the sample by adopting a preset loss function;
and if the loss value is smaller than a preset threshold value, finishing the training of the neural network model.
Preferably, acquiring a first sample threshold and a second sample threshold corresponding to each of the first sample images includes:
and acquiring a first sample threshold and a second sample threshold corresponding to each first sample image based on an automatic particle size distribution algorithm.
According to another aspect of the present invention, there is provided a gravel particle size distribution measuring apparatus comprising:
the device comprises an input module, a first image acquisition module and a second image acquisition module, wherein the input module is used for inputting a first image to be detected to a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects;
the background removing module is used for removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image;
the filling module is used for filling each gravel in the second image by adopting an area filling technology to obtain a third image;
the segmentation module is used for taking the second threshold value as an H value in H-minima transformation and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image;
and the drawing module is used for measuring the short axis of each gravel in the fourth image by adopting Hotelling transformation so as to classify each gravel in the fourth image and draw a particle size distribution diagram of each type of gravel.
Preferably, the apparatus further comprises:
the image acquisition module is used for acquiring a plurality of sample original color images; wherein the sample original color image comprises a plurality of gravel and background objects;
the down-sampling module is used for carrying out down-sampling on each sample original image by adopting discrete wavelet transform to obtain a first sample image corresponding to each sample original image;
a threshold obtaining module, configured to obtain a first sample threshold and a second sample threshold corresponding to each first sample image, and combine each sample original image and the corresponding first sample threshold and second sample threshold as a sample;
and the training module is used for combining a plurality of samples to form a training set, and training the neural network model based on the training set to adjust the parameters of the neural network model.
According to a further aspect of the invention, there is provided an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the steps of the method as provided in the first aspect when executing the program.
According to a further aspect of the present invention, there is provided a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method as provided by the first aspect.
Generally speaking, compared with the prior art, the technical scheme of the invention captures 2 key parameters (namely the first threshold and the second threshold) of each digital image (namely the first image to be measured) through the neural network model, can automatically and accurately measure the particle size distribution of the gravel, effectively overcomes the problem that the prior art cannot fully identify the 2 key parameters of each digital image, and improves the accuracy of the measurement of the particle size distribution of the gravel.
Drawings
FIG. 1 is a flow chart of a method for measuring the particle size distribution of gravel according to an embodiment of the present invention;
FIG. 2 is a schematic structural diagram of a gravel particle size distribution measuring apparatus according to an embodiment of the present invention;
fig. 3 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention. In addition, the technical features involved in the embodiments of the present invention described below may be combined with each other as long as they do not conflict with each other.
It should be noted that, in the first place, the embodiments of the present invention aim to overcome the disadvantages of the prior art and provide a method for measuring the particle size distribution of river bed gravels based on digital images, which facilitates the full-automatic accurate measurement of the particle size distribution of the gravels, has the ability to simultaneously reduce the quantification of the particle size distribution of the gravels, the labor-intensive and time-consuming laboratory, and automatically and accurately measures the particle size distribution of the gravels with less labor intensity for each digital image. The technical scheme of the invention is as follows:
fig. 1 is a flow chart of a method for measuring a particle size distribution of gravel according to an embodiment of the present invention, as shown in fig. 1, the method includes:
step S1, inputting a first image to be detected into a preset neural network model, and obtaining a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects; wherein the first threshold is used for identifying sand as background, and the second threshold is used for controlling WST over-segmentation by using the threshold of H-minima transformation.
It should be noted that Artificial Neural Networks (ANNs) are a branch of artificial intelligence and perform well in various fields. In the embodiment of the invention, the preset neural network model is based on a back propagation fuzzy neural network (CFNN) to learn and infer the relationship between the input (a first image) of the CFNN and the corresponding output (a first threshold and a second threshold), the images are similar due to gravel and sand background objects, and the gravel and sand background objects which are distinguished are a fuzzy problem without absolute standards, so that the neural fuzzy network which can better simulate a human fuzzy judgment process is adopted, and the accuracy of an output result is higher compared with a common neural network classification algorithm.
Wherein the first image is an image input to the neural network model, which includes a plurality of gravels and background objects, which are typically sand.
And step S2, removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image.
Specifically, an appropriate binary threshold is determined in the AGS, so that gravel and sand can be distinguished from each other (usually, the white part is gravel and the black part is sand) from the grayed binary image of the colored riverbed image, namely the grayscale image, thereby obtaining an image only containing gravel and laying a foundation for subsequent measurement of gravel particle size distribution. The first threshold in the embodiment of the present invention, i.e. the binary threshold mentioned above, is used to identify a background object, such as sand, in the first image.
And taking the first threshold as a binary threshold in the AGS to remove background scenes in the first image, and taking the image without the background scenes as a second image.
And step S3, filling each gravel in the second image by adopting an area filling technology to obtain a third image.
And step S4, taking the second threshold as an H value in H-minima transformation, and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image.
In particular, the watershed transform algorithm (WST) is one of the most commonly used image segmentation methods in image processing, however, over-segmentation often occurs in segmentation procedures. In order to avoid over-segmentation, a second threshold value is used as an H value in the H-minima transformation, each gravel in the third image is segmented based on a watershed algorithm of the H-minima transformation, and the segmented image is used as a fourth image.
And step S5, measuring the short axis of each gravel in the fourth image by adopting Hotelling transformation to classify each gravel in the fourth image, and drawing a particle size distribution diagram of each type of gravel.
According to the method provided by the embodiment of the invention, 2 key parameters (namely the first threshold and the second threshold) of each digital image (namely the first image to be measured) are captured through the neural network model, the particle size distribution of the gravel can be automatically and accurately measured, the problem that the prior art cannot fully identify the 2 key parameters of each digital image is effectively solved, and the accuracy of measuring the particle size distribution of the gravel is improved.
Based on the above embodiment, in the embodiment of the present invention, the neural network model is obtained according to the following method:
acquiring an original color image to be detected; wherein the original color image includes a plurality of gravel and background objects. And performing downsampling on the original color image by adopting discrete wavelet transform to obtain a first image to be detected.
In particular, the input metric is reduced using a Discrete Wavelet Transform (DWT). For example, an original color image is a 256-metric input signal, down-sampled by DWT to 2 128-metric signals, where the noise is filtered by a high-pass filter and an approximation is retained by a low-pass filter. Starting with 256 metrics, the DWT based down-sampling procedure is repeated five times and after the 5 th down-sampling an 8-metric signal is generated by the low-pass filter as the first image.
Based on the above embodiment, in the embodiment of the present invention, the inputting the first image to be measured to the preset neural network model further includes:
obtaining a plurality of sample original color images; wherein the sample original color image includes a plurality of gravel and background objects.
Specifically, the steps of obtaining a plurality of sample original color images are as follows: bed images of 20 river sections and 40-80 river beds per river section were taken in a square area of 1 square meter. The collected images are classified into 2 types according to the boundary density: class a (with no significant sand) and class B (with significant sand). For a few high boundary density but not sandy images, manual image analysis manually removes these poor quality images, taking each of the remaining images as a sample original color image.
And performing downsampling on each sample original image by adopting discrete wavelet transform to obtain a first sample image corresponding to each sample original image.
Specifically, for each sample original color image, the Discrete Wavelet Transform (DWT) is used to reduce the input metric. For example, an original color image is a 256-metric input signal, down-sampled by DWT to 2 128-metric signals, where the noise is filtered by a high-pass filter and an approximation is retained by a low-pass filter. Starting with 256 metrics, the DWT based down-sampling procedure is repeated five times and after the 5 th down-sampling, an 8-metric signal is generated by the low-pass filter as the first sample image corresponding to the original color image of the sample.
And acquiring a first sample threshold value and a second sample threshold value corresponding to each first sample image, and combining each sample original image and the corresponding first sample threshold value and second sample threshold value to form a sample.
Specifically, a first sample threshold T corresponding to each first sample image is used for identifying a background object in the first sample image, and a second sample threshold H corresponding to each first sample image is an H value in H-minima transformation performed on the first sample image. In the embodiment of the present invention, a method for calculating Accuracy (AR) based on AGS obtains a first sample threshold T and a second sample threshold H corresponding to each first sample image, and includes the following specific steps: see first the following formula, where tob,tesAnd n is the observed, measured and total grain size grade numbers (increased from 4 to 9psi in 0.5psi increments). In each first sample image, AGS measures grain size by trying different T and H. T is in [50, 250 ]]Is searched at 5 intervals, and H is in [1, 15 ]]Is searched at intervals of 1. Therefore, a total of 615(═ 15 × 41) ARs need to be calculated for each first sample image, and thus, for each first sample image, T and H are obtained in association with the maximum AR value.
Figure BDA0003158676130000081
A first portion of the samples are combined in a plurality of the samples to form a training set, and the neural network model is trained based on the training set to adjust parameters of the neural network model.
Based on the foregoing embodiments, in the embodiments of the present invention, training the neural network model based on the training set to adjust parameters of the neural network model includes:
and for any one sample, inputting the first sample image in the sample into the neural network model, and outputting a first prediction threshold value and a second prediction threshold value corresponding to the first sample image.
Calculating a loss value by adopting a preset loss function according to the first prediction threshold value and the first sample threshold value in the samples, and the second prediction threshold value and the second sample threshold value in the samples, wherein the loss value is a weighted sum of a first prediction threshold value accumulated error and a second prediction threshold value accumulated error, and the first prediction threshold value accumulated error is an absolute value of a difference between the first prediction threshold value and the first sample prediction threshold value of each sample; the second prediction threshold accumulated error is the second prediction threshold of each sample and the absolute value of the second sample prediction threshold difference.
And if the loss value is smaller than a preset threshold value, finishing the training of the neural network model.
Based on the above embodiment, in the embodiment of the present invention, a second part of the samples may be further combined to form a validation set in a plurality of the samples, and the optimal neural network model may be determined based on the validation set.
Based on the above embodiments, the embodiments of the present invention are described as a preferred embodiment of a CFNN:
in inputting the first image selected in the above embodiments into the CFNN, the CFNN analyzes the characteristics of the first image by calculating the probability of occurrence of each gray level, where n is the total number of pixels (e.g., n is 1000 × 1000), and n is the total number of pixels in the first imagekIs the gray scale gkP (g) is the number of pixelsk) Has 256 measurements (0-255 gray levels), and
Figure BDA0003158676130000091
according to the input first image, the CFNN calculates the characteristics of the first image, and then performs pattern matching (performed by a gaussian function) to output a first threshold and a second threshold corresponding to the first image.
Based on the above embodiment, an embodiment of the present invention further provides a device for measuring a particle size distribution of gravel, fig. 2 is a schematic structural diagram of the device for measuring a particle size distribution of gravel provided by an embodiment of the present invention, as shown in fig. 2, the device includes:
the input module 201 is configured to input a first image to be detected to a preset neural network model, so as to obtain a first threshold and a second threshold corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects. And the background removing module 202 is configured to remove a background scene in the first image based on an automatic particle size distribution algorithm and the first threshold to obtain a second image. And the filling module 203 is configured to fill each gravel in the second image by using a region filling technique, so as to obtain a third image. And a segmentation module 204, configured to use the second threshold as an H value in an H-minima transformation, and segment each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image. A drawing module 205, configured to measure a short axis of each gravel in the fourth image by using a Hotelling transform, to classify each gravel in the fourth image, and to draw a particle size distribution map of each type of gravel.
The apparatus provided in the embodiment of the present invention is used for executing the method in the above embodiment, and the method has been described in detail in the above embodiment, so the apparatus is not described herein again. The device provided by the embodiment of the invention can automatically and accurately measure the particle size distribution of the gravel by capturing 2 key parameters (namely the first threshold value and the second threshold value) of each digital image (namely the first image to be measured) through the neural network model, effectively overcomes the problem that the prior art cannot fully identify 2 key parameters of each digital image, and improves the accuracy of measuring the particle size distribution of the gravel.
Based on the above embodiment, the apparatus provided in the embodiment of the present invention further includes:
the image acquisition module is used for acquiring a plurality of sample original color images; wherein the sample original color image includes a plurality of gravel and background objects.
And the downsampling module is used for downsampling each sample original image by adopting discrete wavelet transform to obtain a first sample image corresponding to each sample original image.
And the threshold acquisition module is used for acquiring a first sample threshold and a second sample threshold corresponding to each first sample image, and combining each sample original image and the corresponding first sample threshold and second sample threshold as a sample.
And the training module is used for combining a plurality of samples to form a training set, and training the neural network model based on the training set to adjust the parameters of the neural network model.
In summary, the method and the apparatus provided in the embodiments of the present invention have the following advantages:
a fine automatic grain size sorting (R-AGS) method is provided, AGS and CFNN are fused, in order to ensure that the R-AGS has strong robustness and can be applied to complex images of natural river beds, the constructed CFNN is enough to provide a proper binary threshold value for each river bed image so as to distinguish gravel and sand from the river bed image, and the CFNN is allocated to H-minima to transform a proper threshold value so as to effectively control WST over-segmentation, so the R-AGS is superior to the prior AGS in terms of gravel particle size distribution measurement.
Furthermore, when the image sample under investigation is significantly different from the image of this study, it is easy to reconstruct the CFNN by updating and/or adding rule nodes, and therefore its applicability and utility can be expanded.
In summary, the R-AGS presented by the embodiments of the present invention not only can automatically and adaptively process various captured riverbed images to obtain corresponding gravel size distributions, thereby replacing complex and time-consuming manual sampling methods, but also has the ability to simultaneously reduce the quantification of gravel size distributions, the labor-intensive and time-consuming laboratory, and automatically and accurately measure the gravel size distributions with less labor intensity for each digital image.
Fig. 3 is a schematic physical structure diagram of an electronic device according to an embodiment of the present invention, and as shown in fig. 3, the electronic device may include: a processor (processor)301, a communication Interface (communication Interface)302, a memory (memory)303 and a communication bus 304, wherein the processor 301, the communication Interface 302 and the memory 303 complete communication with each other through the communication bus 304. The processor 301 may invoke a computer program stored on the memory 303 and executable on the processor 301 to perform the methods provided by the various embodiments described above, including, for example: inputting a first image to be detected into a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects; removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image; filling each gravel in the second image by adopting an area filling technology to obtain a third image; taking the second threshold value as an H value in H-minima transformation, and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image; and measuring the short axis of each gravel in the fourth image by adopting a Hotelling transformation to classify each gravel in the fourth image, and drawing a particle size distribution diagram of each type of gravel.
In addition, the logic instructions in the memory 303 may be implemented in the form of software functional units and stored in a computer readable storage medium when the logic instructions are sold or used as independent products. Based on such understanding, the technical solutions of the embodiments of the present invention may be essentially implemented or make a contribution to the prior art, or may be implemented in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the methods described in the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
Embodiments of the present invention further provide a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program is implemented to perform the transmission method provided in the foregoing embodiments when executed by a processor, and the method includes: inputting a first image to be detected into a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects; removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image; filling each gravel in the second image by adopting an area filling technology to obtain a third image; taking the second threshold value as an H value in H-minima transformation, and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image; and measuring the short axis of each gravel in the fourth image by adopting a Hotelling transformation to classify each gravel in the fourth image, and drawing a particle size distribution diagram of each type of gravel.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in the embodiments or some parts of the embodiments.
It will be understood by those skilled in the art that the foregoing is only a preferred embodiment of the present invention, and is not intended to limit the invention, and that any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the scope of the present invention.

Claims (10)

1. A method for measuring a particle size distribution of gravel, comprising:
inputting a first image to be detected into a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects;
removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image;
filling each gravel in the second image by adopting an area filling technology to obtain a third image;
taking the second threshold value as an H value in H-minima transformation, and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image;
and measuring the short axis of each gravel in the fourth image by adopting a Hotelling transformation to classify each gravel in the fourth image, and drawing a particle size distribution diagram of each type of gravel.
2. The method of measuring the particle size distribution of gravel of claim 1, wherein the neural network model is a back-propagation-based fuzzy neural network.
3. The method of measuring the particle size distribution of gravel of claim 1, wherein the first image to be measured is input to a preset neural network model, and previously comprising:
acquiring an original color image to be detected; wherein the original color image comprises a plurality of gravel and background objects;
and performing downsampling on the original color image by adopting discrete wavelet transform to obtain a first image to be detected.
4. The method for measuring the particle size distribution of gravel of claim 1, wherein the neural network model is obtained as follows:
obtaining a plurality of sample original color images; wherein the sample original color image comprises a plurality of gravel and background objects;
adopting discrete wavelet transform to carry out downsampling on each sample original image to obtain a first sample image corresponding to each sample original image;
acquiring a first sample threshold value and a second sample threshold value corresponding to each first sample image, and combining each sample original image and the corresponding first sample threshold value and second sample threshold value to form a sample;
combining a plurality of the samples to form a training set, training the neural network model based on the training set to adjust parameters of the neural network model.
5. The method of measuring particle size distribution of gravel of claim 4, wherein training the neural network model based on the training set to adjust parameters of the neural network model comprises:
for any one sample, inputting the first sample image in the sample into the neural network model, and outputting a first prediction threshold value and a second prediction threshold value corresponding to the first sample image;
calculating a loss value according to the first prediction threshold value and the first sample threshold value in the sample, and the second prediction threshold value and the second sample threshold value in the sample by adopting a preset loss function;
and if the loss value is smaller than a preset threshold value, finishing the training of the neural network model.
6. The method of measuring the particle size distribution of gravel of claim 4, wherein obtaining the first and second sample thresholds for each of the first sample images comprises:
and acquiring a first sample threshold and a second sample threshold corresponding to each first sample image based on an automatic particle size distribution algorithm.
7. A gravel particle size distribution measuring apparatus, comprising:
the device comprises an input module, a first image acquisition module and a second image acquisition module, wherein the input module is used for inputting a first image to be detected to a preset neural network model to obtain a first threshold value and a second threshold value corresponding to the first image output by the neural network model; wherein the first image comprises a plurality of gravel and background objects;
the background removing module is used for removing background objects in the first image based on an automatic particle size distribution algorithm and the first threshold value to obtain a second image;
the filling module is used for filling each gravel in the second image by adopting an area filling technology to obtain a third image;
the segmentation module is used for taking the second threshold value as an H value in H-minima transformation and segmenting each gravel in the third image based on a watershed algorithm of the H-minima transformation to obtain a fourth image;
and the drawing module is used for measuring the short axis of each gravel in the fourth image by adopting Hotelling transformation so as to classify each gravel in the fourth image and draw a particle size distribution diagram of each type of gravel.
8. The apparatus for measuring the particle size distribution of gravel of claim 7, further comprising:
the image acquisition module is used for acquiring a plurality of sample original color images; wherein the sample original color image comprises a plurality of gravel and background objects;
the down-sampling module is used for carrying out down-sampling on each sample original image by adopting discrete wavelet transform to obtain a first sample image corresponding to each sample original image;
a threshold obtaining module, configured to obtain a first sample threshold and a second sample threshold corresponding to each first sample image, and combine each sample original image and the corresponding first sample threshold and second sample threshold as a sample;
and the training module is used for combining a plurality of samples to form a training set, and training the neural network model based on the training set to adjust the parameters of the neural network model.
9. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the steps of the method according to any of claims 1 to 7 are implemented when the processor executes the program.
10. A non-transitory computer-readable storage medium, on which a computer program is stored, which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 7.
CN202110784549.4A 2021-07-12 2021-07-12 Gravel particle size distribution measuring method and device Withdrawn CN113470058A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110784549.4A CN113470058A (en) 2021-07-12 2021-07-12 Gravel particle size distribution measuring method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110784549.4A CN113470058A (en) 2021-07-12 2021-07-12 Gravel particle size distribution measuring method and device

Publications (1)

Publication Number Publication Date
CN113470058A true CN113470058A (en) 2021-10-01

Family

ID=77879819

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110784549.4A Withdrawn CN113470058A (en) 2021-07-12 2021-07-12 Gravel particle size distribution measuring method and device

Country Status (1)

Country Link
CN (1) CN113470058A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114612450A (en) * 2022-03-17 2022-06-10 无锡东如科技有限公司 Image detection segmentation method and system based on data augmentation machine vision and electronic equipment

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112733920A (en) * 2020-12-31 2021-04-30 中国地质调查局成都地质调查中心 Image identification method and system based on deep learning

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112733920A (en) * 2020-12-31 2021-04-30 中国地质调查局成都地质调查中心 Image identification method and system based on deep learning

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
CHANG-HAN CHUNG 等: "A refined automated grain sizing method for estimating river-bed grain size distribution of digital images", 《JOURNAL OF HYDROLOGY(WWW.ELSEVIER.COM/LOCATE/JHYDROL)》, pages 2 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114612450A (en) * 2022-03-17 2022-06-10 无锡东如科技有限公司 Image detection segmentation method and system based on data augmentation machine vision and electronic equipment
CN114612450B (en) * 2022-03-17 2023-09-05 无锡东如科技有限公司 Image detection segmentation method and system based on data augmentation machine vision and electronic equipment

Similar Documents

Publication Publication Date Title
CN114549522B (en) Textile quality detection method based on target detection
CN107507173B (en) No-reference definition evaluation method and system for full-slice image
CN109191459B (en) Automatic identification and rating method for continuous casting billet macrostructure center segregation defect
CN110569730B (en) Road surface crack automatic identification method based on U-net neural network model
CN111507426B (en) Non-reference image quality grading evaluation method and device based on visual fusion characteristics
CN109993797B (en) Door and window position detection method and device
CN110378893B (en) Image quality evaluation method and device and electronic equipment
CN109241867B (en) Method and device for recognizing digital rock core image by adopting artificial intelligence algorithm
CN111882561A (en) Cancer cell identification and diagnosis system
CN108122221A (en) The dividing method and device of diffusion-weighted imaging image midbrain ischemic area
CN111161224A (en) Casting internal defect grading evaluation system and method based on deep learning
CN115797473B (en) Concrete forming evaluation method for civil engineering
CN114782329A (en) Bearing defect damage degree evaluation method and system based on image processing
CN107016680B (en) A kind of pest image background minimizing technology based on conspicuousness detection
CN113012124B (en) Shoe print hole and embedded object feature detection and description method
Chung et al. A refined automated grain sizing method for estimating river-bed grain size distribution of digital images
CN109146888B (en) Soil crack fractal dimension calculation method based on difference quotient analysis
CN102306378A (en) Image enhancement method
CN111179196A (en) Multi-resolution depth network image highlight removing method based on divide-and-conquer
CN113435460A (en) Method for identifying brilliant particle limestone image
CN115908142A (en) Contact net tiny part damage testing method based on visual recognition
CN117094975A (en) Method and device for detecting surface defects of steel and electronic equipment
CN113470058A (en) Gravel particle size distribution measuring method and device
CN114332081A (en) Textile surface abnormity determination method based on image processing
CN117853722A (en) Steel metallographic structure segmentation method integrating superpixel information

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication

Application publication date: 20211001

WW01 Invention patent application withdrawn after publication