Method and device for measuring calorific value of garbage

Through the combination of spectral cameras and convolutional neural networks, the complex and time-consuming problem of calorific value measurement in waste incineration is solved, and the rapid and accurate measurement of calorific value of waste is achieved, which improves the stability and efficiency of incineration.

CN118937240APending Publication Date: 2024-11-12BEIJING OPTICAL FUNCTION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310527866.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-05-11
Publication Date
2024-11-12

AI Technical Summary

Technical Problem

During the existing waste incineration process, the measurement method of the calorific value of the waste is complex and time-consuming. Due to manual sorting, it is difficult to measure quickly and accurately, which affects the stability of the incineration.

Method used

The spectral camera is used to obtain the spectral image of garbage. After denoising, the spectral information is input into the trained convolutional neural network to quickly obtain the heat value information of garbage and avoid manual sampling and subjective judgment.

Benefits of technology

It realizes rapid and accurate measurement of garbage calorific value, improves the stability and efficiency of the incineration process, reduces measurement time, and improves data accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118937240A_ABST
    Figure CN118937240A_ABST
Patent Text Reader

Abstract

The embodiment of the invention discloses a garbage calorific value measuring method and device. According to the scheme, the method comprises the following steps: acquiring an original spectral image of to-be-processed garbage by using a spectral camera, and carrying out denoising processing on the original spectral image to obtain a denoised spectral image; spectral information of the garbage to be processed is obtained based on the spectral image subjected to denoising processing; and inputting the spectral information into a trained convolutional neural network to obtain heat value information corresponding to the to-be-treated garbage. According to the method, the spectral image of the to-be-treated garbage is obtained through the spectral camera arranged near the to-be-treated garbage, and then the spectral information in the spectral image subjected to denoising processing is input into the trained convolutional neural network, so that the calorific value information corresponding to the to-be-treated garbage can be quickly and accurately obtained; and in the process, manual sampling of the to-be-treated garbage is not needed, so that the influence of subjective judgment of sorting personnel is avoided, and the accuracy of the obtained heat value information of the to-be-treated garbage is high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of garbage disposal, and in particular to a method and device for measuring the calorific value of garbage. Background Art

[0002] With the rapid development of the domestic economy, the output of domestic garbage is also increasing rapidly, and the degree of pollution caused by it is also increasing. Therefore, in order to ensure the sustainable development of the city, it is necessary to effectively treat domestic garbage. At present, in the process of using incineration to treat domestic garbage, the calorific value of garbage is a key parameter affecting the stability of garbage incineration. The change of the calorific value of the garbage entering the furnace has a relatively large impact on the stability of the combustion process. Therefore, before the garbage enters the furnace for incineration, it is necessary to measure the calorific value of the garbage to be incinerated more accurately. At present, oxygen bomb calorimeter and thermogravimetric analyzer are generally used to measure the calorific value of domestic garbage. However, since domestic garbage is a non-uniform fuel with complex components and uneven calorific value distribution, in order to measure the calorific value of garbage, it is generally necessary to use the correct sampling method, accurately sort and proportion the physical components of the garbage, and the calorific value obtained is representative. However, the sorting of the physical components of garbage is easily affected by the subjective judgment of the sorting personnel, and the sample pre-treatment work is numerous, the whole set of operation procedures is complicated, time-consuming and labor-intensive, and when long-term calorific value measurement and evaluation are required, the experimental method takes too long to obtain accurate data, which is not conducive to the rapid development of garbage incineration treatment. Summary of the invention

[0003] The embodiments of this specification provide a method and device for measuring the calorific value of garbage to solve the problem.

[0004] To solve the above technical problems, the embodiments of this specification are implemented as follows:

[0005] According to a first aspect of an embodiment of the present invention, a method for measuring the calorific value of garbage is provided, comprising:

[0006] S1. Using a spectral camera to obtain an original spectral image of the garbage to be processed, and performing denoising on the original spectral image to obtain a spectral image after denoising;

[0007] S2. Obtaining spectral information of the garbage to be processed based on the spectral image after denoising;

[0008] S3, inputting the spectral information into the trained convolutional neural network to obtain the calorific value information corresponding to the waste to be processed;

[0009] The training process of the trained convolutional neural network specifically includes:

[0010] S31, constructing a data set;

[0011] A spectral camera is used in advance to obtain a plurality of spectral images of garbage mixtures obtained by mixing different types of garbage, and the calorific value information of each garbage mixture is measured based on a calorific value measuring instrument to obtain a plurality of spectral images of the garbage mixtures with the calorific value information as a label;

[0012] S32, dividing the spectral images of the garbage mixture with calorific value information as labels into a training set and a verification set according to a predetermined ratio;

[0013] S33, training the convolutional neural network using the spectral image of the garbage mixture labeled with calorific value information in the training set as a training sample; during the training process, updating the weight parameters in the convolutional neural network according to the following optimizer algorithm, When training The convolutional neural network stops training when the accuracy of the convolutional neural network on the validation set meets a predetermined threshold; wherein the optimizer algorithm specifically includes:

[0014] S331, set the learning rate ε, decay rate ρ, momentum coefficient μ, set the initial value of the parameter to be learned θ, cumulative square gradient r, cumulative gradient v in the convolutional neural network, and set the value equal to 10 -5 The parameter δ,

[0015] S332, randomly selecting m samples from the training set, wherein each of the m samples carries corresponding calorific value information, and the samples contain m spectral images represented as: {x (1) ,...,x (m)}, and the calorific value information corresponding to each spectral image is expressed as: {y (1) ,...,y (m)};

[0016] S333, calculate the average gradient g of the m samples at the current time step t according to the following rules t : Among them, the function f(x (i) ; θ) represents the function of convolutional neural network mapping, function L(f(x (i) ;θ),y (i) ) represents the loss function; Represents the gradient symbol;

[0017] S334: Update the cumulative gradient v corresponding to the current time step t according to the following rules. t :v t ←μv t-1 +(1-μ)g t ,That Among them Symbol v t-1Represents the cumulative gradient corresponding to the previous time step of the current time step t;

[0018] S335: Update and accumulate the square gradient r corresponding to the current time step t according to the following rules. t :r t ←ρr t-1 +(1-ρ)g t *g t , where the symbol r t-1 represents the cumulative square gradient corresponding to the previous time step of the current time step t;

[0019] S336: Calculate the first correction deviation according to the following rules and the second corrected deviation in, S337: Update the parameters to be learned at the current time step t based on the following rules Among them, the symbol θ t-1 represents the parameter to be learned corresponding to the previous time step of the current time step t;

[0020] Update time step t=t+1;

[0021] S338, repeating steps S332 to S337 iteratively until the accuracy of the trained parameter θ to be learned on the validation set meets a predetermined threshold and then stopping the training.

[0022] Preferably, the spectral camera is rotatably arranged obliquely above the waste to be processed, and the focal length f of the spectral camera is set based on the following formula:

[0023]

[0024]

[0025] Among them, the symbol h represents the imaging height of the garbage to be processed on the spectral camera, the symbol H represents the height of the garbage to be processed, the symbol L represents the distance between the garbage being observed and processed and the lens of the spectral camera, the symbol h0 represents the height of the photosensitive element of the spectral camera, the symbol w represents the imaging width of the garbage to be processed on the spectral camera, the symbol W represents the width of the garbage to be processed, the symbol w0 represents the width of the photosensitive element of the spectral camera, and the symbol ε is a parameter with a predetermined numerical value.

[0026] Preferably, after obtaining the calorific value information corresponding to the waste to be processed, the method further comprises:

[0027] The spectral camera is rotated to obtain the calorific value information of the waste to be processed at different positions, and the calorific value information of the waste to be processed at different positions is displayed in a display interface.

[0028] Preferably, an LED light source is provided above the waste to be processed, and the LED light source is used to provide supplementary light to the waste to be processed.

[0029] Preferably, data enhancement operation is performed on the spectral images in the training set by a combination of one or more operations selected from the group consisting of flipping operation, translation operation, rotation operation, scaling operation, and noise addition operation to obtain spectral images processed by data enhancement operation, so as to improve the generalization ability of the trained convolutional neural network.

[0030] Preferably, for any layer of neurons in the convolutional neural network, from the open interval Uniformly randomly select values ​​for all parameters to be learned in any layer of neurons, where the symbol d represents the number of neurons in any layer of neurons.

[0031] Preferably, a batch normalization layer is provided between adjacent fully connected layers and nonlinear activation layers in the convolutional neural network, and the batch normalization layer is used to perform standardization processing on the batch data output by each neuron in the fully connected layer when a number of training samples are used as input data. The standardization processing process specifically includes:

[0032] For any neuron in the fully connected layer, calculate the mean μ of the batch data output by any neuron B ,in, Among them, x i , i=1,2,...,n represents the batch output data of any neuron when the number of training samples is used as input data;

[0033] Calculate the variance of the batch output data output by any one of the neurons in,

[0034] The normalized value of the output value of any one neuron is calculated based on the following formula in, The symbol ε2 represents a constant whose value is greater than zero and less than a predetermined positive value;

[0035] The normalized value is calculated based on the following formula: Perform translation and scaling operations to obtain the output data y after the translation and scaling operations i , where γ represents the scaling factor corresponding to any one of the neurons, and β represents the translation factor corresponding to any one of the neurons;

[0036]

[0037] Preferably, in the process of testing the convolutional neural network, for a specific test sample, when performing standardization processing on any one of the neurons, the mean of several historical means corresponding to any one of the neurons in the training process of the convolutional neural network is used as the mean. The mean of the variances corresponding to any one neuron in the convolutional neural network training process is used as the variance

[0038] According to a second aspect of an embodiment of the present invention, there is provided a device for measuring the calorific value of garbage, comprising:

[0039] The spectral image acquisition module is used to acquire the original spectral image of the garbage to be processed by using a spectral camera, and perform denoising on the original spectral image to obtain a spectral image after denoising;

[0040] A spectral information acquisition module, used for obtaining spectral information of the garbage to be processed based on the spectral image after the denoising process;

[0041] A garbage calorific value information acquisition module is used to input the spectral information into a trained convolutional neural network to obtain the calorific value information corresponding to the garbage to be processed;

[0042] The training process of the trained convolutional neural network specifically includes:

[0043] Build a dataset;

[0044] A spectral camera is used in advance to obtain a plurality of spectral images of garbage mixtures obtained by mixing different types of garbage, and the calorific value information of each garbage mixture is measured based on a calorific value measuring instrument to obtain a plurality of spectral images of the garbage mixtures with the calorific value information as a label;

[0045] Dividing the spectral images of the garbage mixture labeled with calorific value information into a training set and a validation set according to a predetermined ratio;

[0046] The convolutional neural network is trained using the spectral image of the garbage mixture labeled with calorific value information in the training set as a training sample; during the training process, the weight parameters in the convolutional neural network are updated according to the following optimizer algorithm, and the training is stopped when the accuracy of the trained convolutional neural network on the verification set meets a predetermined threshold; wherein the optimizer algorithm specifically includes:

[0047] Set the learning rate ε, decay rate ρ, momentum coefficient μ, set the initial values ​​of the parameters to be learned θ, cumulative square gradient r, cumulative gradient v in the convolutional neural network, and set the value of 10 -5 The parameter δ,

[0048] M samples are randomly selected from the training set, wherein each of the m samples carries corresponding calorific value information, and the m spectral images contained in the sample are expressed as: {x (1) ,...,x (m)}, and the calorific value information corresponding to each spectral image is expressed as: {y (1) ,...,y (m)};

[0049] Calculate the average gradient g of the m samples at the current time step t according to the following rules t : Among them, the function f(x (i) ; θ) represents the function of convolutional neural network mapping, function L(f(x (i) ;θ),y (i) ) represents the loss function; Represents the gradient symbol;

[0050] Update the cumulative gradient v corresponding to the current time step t according to the following rules t :v t ←μv t-1 +(1-μ)g t , where the symbol v t-1 Represents the cumulative gradient corresponding to the previous time step of the current time step t;

[0051] Update the accumulated square gradient r corresponding to the current time step t according to the following rules t :r t ←ρr t-1 +(1-ρ)g t *g t , where the symbol r t-1 represents the cumulative square gradient corresponding to the previous time step of the current time step t;

[0052] Calculate the first correction deviation according to the following rules and the second corrected deviation in,

[0053] Update the parameters to be learned at the current time step t based on the following rules Among them, the symbol θ t-1 represents the parameter to be learned corresponding to the previous time step of the current time step t;

[0054] Update time step t=t+1;

[0055] The training is stopped when the accuracy of the trained parameter θ on the validation set meets a predetermined threshold.

[0056] One embodiment of the present specification can achieve at least the following beneficial effects: by obtaining a spectral image of the garbage to be processed through a spectral camera arranged near the garbage to be processed, and then inputting the spectral information in the spectral image after denoising into a trained convolutional neural network, the calorific value information corresponding to the garbage to be processed can be obtained quickly and accurately, and the process does not require manual sampling of the garbage to be processed, so it is not affected by the subjective judgment of the sorting personnel, and the calorific value information of the garbage to be processed obtained has high accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0057] In order to more clearly illustrate the embodiments of this specification or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0058] Figure 1 It is a schematic diagram of an application scenario of a method for measuring the calorific value of garbage provided in an embodiment of this specification;

[0059] Figure 2 It is a flow chart of a method for measuring the calorific value of garbage provided in an embodiment of this specification;

[0060] Figure 3 It is a schematic diagram of the cooperative relationship of various components in a method for measuring the calorific value of garbage provided in an embodiment of this specification;

[0061] Figure 4 It is a structural schematic diagram of a garbage calorific value measuring device provided in an embodiment of this specification.

[0062] Among them, 1 represents the garbage dump, 2 represents the light source, and 3 represents the spectral camera. DETAILED DESCRIPTION

[0063] In order to make the purpose, technical solutions and advantages of one or more embodiments of this specification clearer, the technical solutions of one or more embodiments of this specification will be clearly and completely described below in combination with the specific embodiments of this specification and the corresponding drawings. Obviously, the described embodiments are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of one or more embodiments of this specification.

[0064] It should be understood that although the terms first, second, third, etc. may be used in this application document to describe various information, this information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other.

[0065] Figure 1 Schematic diagram of an application scenario of a method for measuring the calorific value of garbage in an embodiment of this specification. Figure 1 As shown, a light source 2 is arranged above the garbage to be processed 1 (when the garbage to be processed is in an environment such as at night, indoors or in a closed space, a light source can be selected to assist in collecting the reflection spectrum of the garbage to be processed), and a spectral camera collects the reflection spectrum of the garbage to be processed, and then the computer can automatically process the reflection spectrum to obtain the calorific value information of the garbage to be processed, thereby facilitating subsequent garbage processing. Among them, software capable of processing the reflection spectrum is installed on the computer, and the software can obtain the calorific value information of the garbage to be processed based on the reflection spectrum based on a trained convolutional neural network algorithm.

[0066] Next, a method for measuring the calorific value of garbage provided in the embodiment of the specification will be described in detail with reference to the accompanying drawings.

[0067] Figure 2 The flowchart of a method for measuring the calorific value of garbage provided in the embodiment of this specification is as follows. From the program perspective, the execution subject of the process can be a program set in a computer.

[0068] like Figure 2 As shown, the process may include the following steps.

[0069] Step S1: using a spectral camera to obtain an original spectral image of the garbage to be processed, and performing denoising processing on the original spectral image to obtain a spectral image after denoising processing.

[0070] Step S2: obtaining the spectral information of the garbage to be processed based on the spectral image after the denoising process.

[0071] The garbage to be processed can be a mixture of different types of garbage, and the garbage to be processed can come from domestic garbage of urban residents. At the same time, considering the presence of random noise in the spectral image data (such as light source noise, CCD noise, dark current, etc.), this will affect the subsequent data analysis results, so denoising operation is required. In this embodiment, a digital filtering algorithm can be used to filter out random noise to improve the signal-to-noise ratio. Commonly used filtering algorithms can include sliding median filtering, sliding mean filtering, sliding polynomial filtering, etc.

[0072] S3, inputting the spectral information into the trained convolutional neural network to obtain the calorific value information corresponding to the waste to be processed;

[0073] The training process of the trained convolutional neural network specifically includes:

[0074] S31, constructing a data set;

[0075] A spectral camera is used in advance to obtain a plurality of spectral images of garbage mixtures obtained by mixing different types of garbage, and the calorific value information of each garbage mixture is measured based on a calorific value measuring instrument to obtain a plurality of spectral images of the garbage mixtures with the calorific value information as a label;

[0076] S32, dividing the spectral images of the garbage mixture with calorific value information as labels into a training set and a verification set according to a predetermined ratio.

[0077] In this solution, the spectral image of the garbage mixture labeled with calorific value information can be divided into a training set and a test set in a ratio of 6:4. Other ratios, such as 8:2, can also be used. The specific ratio distribution is not specifically limited by the solution of the present invention.

[0078] S33, training the convolutional neural network using the spectral image of the garbage mixture labeled with calorific value information in the training set as a training sample; updating the weight parameters in the convolutional neural network according to the following optimizer algorithm during the training process, and stopping the training when the accuracy of the trained convolutional neural network on the verification set meets a predetermined threshold; wherein the optimizer algorithm specifically includes:

[0079] S331, set the learning rate ε, decay rate ρ, momentum coefficient μ, set the initial value of the parameter to be learned θ, cumulative square gradient r, cumulative gradient v in the convolutional neural network, and set the value equal to 10 -5 The parameter δ,

[0080] S332, randomly selecting m samples from the training set, wherein each of the m samples carries corresponding calorific value information, and the samples contain m spectral images represented as: {x (1) ,...,x (m)}, and the calorific value information corresponding to each spectral image is expressed as: {y (1) ,...,y (m)};

[0081] S333, calculate the average gradient g of the m samples at the current time step t according to the following rules t : Among them, the function f(x (i) ; θ) represents the function of convolutional neural network mapping, function L(x (i) ;θ),y (i) ) represents the loss function; Represents the gradient symbol;

[0082] S334: Update the cumulative gradient v corresponding to the current time step t according to the following rules. t :v t ←μv t-1 +(1-μ)g t , where the symbol v t-1 Represents the cumulative gradient corresponding to the previous time step of the current time step t;

[0083] S335: Update and accumulate the square gradient r corresponding to the current time step t according to the following rules. t :r t ←ρr t-1 +(1-ρ)g t *g t , where the symbol r t-1 represents the cumulative square gradient corresponding to the previous time step of the current time step t;

[0084] S336: Calculate the first correction deviation according to the following rules and the second corrected deviation in,

[0085] S337: Update the parameters to be learned at the current time step t based on the following rules Among them, the symbol θ t-1 represents the parameter to be learned corresponding to the previous time step of the current time step t;

[0086] Update time step t=t+1;

[0087] S338, repeating steps S332 to S337 iteratively until the accuracy of the trained parameter θ to be learned on the validation set meets a predetermined threshold and then stopping the training.

[0088] In this scheme, the goal of deep learning is to continuously change the network parameters so that the parameters can make various nonlinear transformations of the input and fit the output. In essence, it is a function to find the optimal solution. Therefore, how to update the parameters in the convolutional neural network to be trained is the focus of deep learning. The optimizer algorithm mentioned above can update the variables according to the oscillation of the historical gradient and the real historical gradient after filtering the oscillation when updating the weight parameters in the convolutional neural network, thereby speeding up the training process and enabling the convolutional neural network to be trained to complete the training quickly.

[0089] In this embodiment, a spectral image of the garbage to be processed is obtained by a spectral camera arranged near the garbage to be processed, and the spectral information in the spectral image after denoising is input into a trained convolutional neural network. The calorific value information corresponding to the garbage to be processed can be obtained quickly and accurately. This process does not require manual sampling of the garbage to be processed, and is therefore not affected by the subjective judgment of the sorting personnel. The calorific value information of the garbage to be processed obtained has high accuracy.

[0090] based on Figure 2 The method, the examples of this specification also provide some specific implementation plans of the method, which are described below.

[0091] During the training of the convolutional neural network, the weight parameters in the convolutional neural network can also be updated according to the optimizer algorithm as follows, and the training is stopped when the accuracy of the trained convolutional neural network on the test set meets the predetermined threshold. The optimizer algorithm includes step 1: setting the values ​​of the learning rate ε and the decay rate ρ, setting the initial value of the parameter θ to be learned in the convolutional neural network CNN, and setting the value equal to 10 -5 Parameter σ; Step 2: Randomly select m samples and the calorific value information corresponding to each sample from the training set, where the m samples are represented as: {x (1) ,…,x (m)}, the calorific value information corresponding to each sample is expressed as: {y (1) ,…,y (m)}; Step 3: Calculate the average gradient g of the m samples according to the following rules: Among them, the function f(x (i) ; θ) represents the activation function, the function L(f(x (i) ;θ),y (i) ) represents the loss function; represents the gradient symbol; i = 1,…,m; Step 4: Calculate the cumulative square gradient r according to the following rules: r←ρr+(1-ρ)g*g; Step 5: Set the weight update factor α according to the following rules, The value of the parameter θ to be learned is updated based on the weight update factor α according to the following rule, where the rule is expressed as: θ←θ-α; when the weight update factor α is greater than a preset threshold β, the weight w in the CNN network is updated according to the rule w←w-β, wherein the preset threshold β is used to avoid gradient explosion in the back propagation stage of the convolutional neural network training process, thereby controlling the step size change amplitude.

[0092] Since the spectral camera in the garbage room is sometimes far away from the garbage, the spectral information obtained is relatively fuzzy, so it is necessary to add a telescope system to improve the measurement accuracy of the spectrum. In order to select a suitable lens, it is necessary to analyze the parameters of the optical system. In an optional technical solution, the spectral camera can be rotatably set diagonally above the garbage to be processed, and the focal length f of the spectral camera can be reasonably set based on the constraints of the following formula:

[0093]

[0094]

[0095] Among them, the symbol h represents the imaging height of the garbage to be processed on the spectral camera, the symbol H represents the height of the garbage to be processed, the symbol L represents the distance between the garbage to be observed and processed and the lens of the spectral camera, the symbol h0 represents the height of the photosensitive element of the spectral camera, the symbol w represents the imaging width of the garbage to be processed on the spectral camera, the symbol W represents the width of the garbage to be processed, the symbol w0 represents the width of the photosensitive element of the spectral camera, and the symbol ε is a parameter with a predetermined numerical value. In actual application scenarios, the focal length of the spectral camera should satisfy the imaging size as close as possible to the sensor size, so as to avoid the problems of incomplete imaging and low sensor utilization. The size of the sensor should be larger than the size of the image, otherwise the imaging will be incomplete. The sensor should choose the smallest size that meets the imaging requirements to prevent the sensor utilization from being too low. In actual design, the telescope system can be designed in combination with parameters such as the distance between the spectral acquisition system and the garbage and the size of the spectral camera sensor to achieve effective collection of spectral information of garbage in a specific area. At the same time, the spectral camera can be rotatably set diagonally above the garbage to be processed. The synergistic relationship between the various components can be as follows. Figure 3 shown.

[0096] Among them, the spectral camera is an efficient spectral acquisition device that can obtain spectra at multiple points in space. The data it obtains contains three dimensions, in addition to the image dimensions x, y, there is also a spectral dimension λ. In order to accurately predict the calorific value of garbage in real time, we use a spectral camera with a wavelength range that can cover the visible light and near-infrared bands. At the same time, the spectral camera needs to continuously collect spectral images at a certain sampling rate and calculate in real time. In theory, the faster the sampling rate, the better, but too much data will affect the speed of calculation, resulting in the inability to achieve real-time calculation. Therefore, in actual research, a suitable sampling rate can be selected to meet the requirements of real-time calculation and reduce the impact on the calculation speed.

[0097] In an optional embodiment, after obtaining the calorific value information corresponding to the waste to be processed, the method may include:

[0098] The spectral camera is rotated to obtain the calorific value information of the waste to be processed at different positions, and the calorific value information of the waste to be processed at different positions is displayed in a display interface.

[0099] In an optional embodiment, an LED light source is arranged above the waste to be processed, and the LED light source is used to provide supplementary lighting for the waste to be processed.

[0100] In an optional embodiment, data enhancement operations are performed on the spectral images in the training set by combining one or more operations selected from the group consisting of flipping, translating, rotating, scaling, and adding noise to obtain spectral images after the data enhancement operations. The convolutional neural network model will not view exactly the same image twice during the training process, thereby enabling the model to observe more content of the data and thus having better generalization capabilities.

[0101] In an optional embodiment, for any layer of neurons in the convolutional neural network, the open interval Uniformly randomly select values ​​for all parameters to be learned in any layer of neurons, where the symbol d represents the number of neurons in any layer of neurons.

[0102] Considering that the distribution of the activation input value of the deep neural network before the nonlinear transformation gradually shifts or changes as the network depth deepens or during the training process, the reason why the training converges slowly is generally that the overall distribution gradually approaches the upper and lower limits of the value range of the nonlinear function, so this causes the gradient of the low-level neural network to disappear during back propagation. This is the essential reason why the training of deep neural networks converges more and more slowly. Through certain normalization means, the distribution of the input value of any neuron in each layer of the neural network can be forcibly pulled back to a standard normal distribution with a mean of 0 and a variance of 1. Therefore, in an optional embodiment, a batch normalization layer is provided between adjacent fully connected layers and nonlinear activation layers in the convolutional neural network. The batch normalization layer is used to standardize the batch data output by each neuron in the fully connected layer when a number of training samples are used as input data. The standardization process can specifically include:

[0103] For any neuron in the fully connected layer, calculate the mean μ of the batch data output by any neuron B ,in, Among them, x i , i=1,2,...,n represents the batch output data of any neuron when the number of training samples is used as input data;

[0104] Calculate the variance of the batch output data output by any one of the neurons in,

[0105] The normalized value of the output value of any one of the neurons is calculated based on the following formula: in, The symbol ε2 represents a constant whose value is greater than zero and less than a predetermined positive value;

[0106] The normalized value is calculated based on the following formula: Perform translation and scaling operations to obtain the output data y after the translation and scaling operations i , where γ represents the scaling factor corresponding to any one of the neurons, and β represents the translation factor corresponding to any one of the neurons. In this embodiment, the parameters γ and β are also parameters to be learned;

[0107]

[0108] In an optional embodiment, during the testing of the convolutional neural network, for a specific test sample, when performing standardization on any one of the neurons, the mean of several historical means corresponding to any one of the neurons during the training of the convolutional neural network is used as the mean. The mean of the variances corresponding to any one neuron in the convolutional neural network training process is used as the variance

[0109] In this scheme, in the test phase, for a specific test sample, each neuron in the convolutional neural network has only one output value. When the output of the neuron is normalized based on the batch normalization layer, the mean of several historical means corresponding to any neuron in the convolutional neural network training process can be used as the mean. That is, for the mean For example, suppose that during the training phase of the convolutional neural network These four means can be based on the formula Calculate the mean value required for normalizing the output of any neuron in the batch normalization layer Similarly, suppose that during the training phase of the convolutional neural network there is These four variances can be based on the formula / 4 Calculate the variance required for normalizing the output of any neuron in the batch normalization layer

[0110] Spectral camera imaging is currently divided into passive imaging and active imaging. Passive imaging uses sunlight as the basic light. Sunlight is a large wide-spectrum light source. Only a camera and corresponding accessories are needed to collect the spectral information of objects. Active imaging requires additional light sources for supplementary lighting. When the garbage is in environments such as night, indoors, and enclosed spaces, you can choose to add light sources to collect the reflected spectrum of the garbage and analyze the garbage. We use LED light sources that can produce a wider spectrum as compensation light sources in scenes without sunlight, so as to accurately obtain the spectral information of the garbage in different scenes.

[0111] Based on the same idea, the embodiments of this specification also provide a device corresponding to the above method. Figure 4 The embodiments of this specification provide corresponding to Figure 2 A schematic diagram of the structure of a device for measuring the calorific value of garbage. Figure 4 As shown, the device may include:

[0112] The spectral image acquisition module 402 is used to acquire the original spectral image of the garbage to be processed by using a spectral camera, and perform denoising on the original spectral image to obtain a spectral image after denoising.

[0113] The spectrum information acquisition module 404 is used to obtain the spectrum information of the garbage to be processed based on the denoised spectrum image.

[0114] The garbage calorific value information acquisition module 406 is used to input the spectral information into the trained convolutional neural network to obtain the calorific value information corresponding to the garbage to be processed;

[0115] The training process of the trained convolutional neural network specifically includes:

[0116] Build a dataset;

[0117] A spectral camera is used in advance to obtain a plurality of spectral images of garbage mixtures obtained by mixing different types of garbage, and the calorific value information of each garbage mixture is measured based on a calorific value measuring instrument to obtain a plurality of spectral images of the garbage mixtures with the calorific value information as a label;

[0118] Dividing the spectral images of the garbage mixture labeled with calorific value information into a training set and a validation set according to a predetermined ratio;

[0119] The convolutional neural network is trained using the spectral image of the garbage mixture labeled with calorific value information in the training set as a training sample; during the training process, the weight parameters in the convolutional neural network are updated according to the following optimizer algorithm, and the training is stopped when the accuracy of the trained convolutional neural network on the verification set meets a predetermined threshold; wherein the optimizer algorithm specifically includes:

[0120] Set the learning rate ε, decay rate ρ, momentum coefficient μ, set the initial values ​​of the parameters to be learned θ, cumulative square gradient r, cumulative gradient v in the convolutional neural network, and set the value of 10 -5 The parameter δ,

[0121] M samples are randomly selected from the training set, wherein each of the m samples carries corresponding calorific value information, and the m spectral images contained in the sample are expressed as: {x (1) ,...,x (m)}, and the calorific value information corresponding to each spectral image is expressed as: {y (1) ,...,y (m)};

[0122] Calculate the average gradient g of the m samples at the current time step t according to the following rules t : Among them, the function f(x (i) ; θ) represents the function of convolutional neural network mapping, function L(f(x (i) ;θ),y (i) ) represents the loss function; Represents the gradient symbol;

[0123] Update the cumulative gradient v corresponding to the current time step t according to the following rules t :v t ←μv t-1 +(1-μ)g t , where the symbol v t-1 Represents the cumulative gradient corresponding to the previous time step of the current time step t;

[0124] Update the accumulated square gradient r corresponding to the current time step t according to the following rules t :r t ←ρr t-1 +(1-ρ)g t *g t , where the symbol r t-1 represents the cumulative square gradient corresponding to the previous time step of the current time step t;

[0125] Calculate the first correction deviation according to the following rules and the second corrected deviation in,

[0126] Update the parameters to be learned at the current time step t based on the following rules Among them, the symbol θ t-1 represents the parameter to be learned corresponding to the previous time step of the current time step t;

[0127] Update time step t=t+1;

[0128] The training is stopped when the accuracy of the trained parameter θ on the validation set meets a predetermined threshold.

[0129] The above describes specific embodiments of the present specification. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0130] The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referenced to each other.

[0131] The devices, equipment and methods provided in the embodiments of this specification correspond to each other, and therefore, the devices and equipment also have similar beneficial technical effects as the corresponding methods. Since the beneficial technical effects of the methods have been described in detail above, the beneficial technical effects of the corresponding devices and equipment will not be repeated here.

Claims

1. A method for measuring the calorific value of garbage, characterized in that: include: S1. Using a spectral camera to obtain an original spectral image of the garbage to be processed, and performing denoising on the original spectral image to obtain a spectral image after denoising; S2. Obtaining spectral information of the garbage to be processed based on the spectral image after denoising; S3, inputting the spectral information into the trained convolutional neural network to obtain the calorific value information corresponding to the waste to be processed; The training process of the trained convolutional neural network specifically includes: S31, constructing a data set; A spectral camera is used in advance to obtain a plurality of spectral images of garbage mixtures obtained by mixing different types of garbage, and the calorific value information of each garbage mixture is measured based on a calorific value measuring instrument to obtain a plurality of spectral images of the garbage mixtures with the calorific value information as a label; S32, dividing the spectral images of the garbage mixture with calorific value information as labels into a training set and a verification set according to a predetermined ratio; S33, training the convolutional neural network using the spectral image of the garbage mixture labeled with calorific value information in the training set as a training sample; updating the weight parameters in the convolutional neural network according to the following optimizer algorithm during the training process, and stopping the training when the accuracy of the trained convolutional neural network on the verification set meets a predetermined threshold; wherein the optimizer algorithm specifically includes: S331, set the learning rate ε, decay rate ρ, momentum coefficient μ, set the initial value of the parameter to be learned θ, cumulative square gradient r, cumulative gradient v in the convolutional neural network, and set the value equal to 10 -5 The parameter δ, S332, randomly selecting m samples from the training set, wherein each of the m samples carries corresponding calorific value information, and the samples contain m spectral images represented as: {x (1) ,...,x (m) }, and the calorific value information corresponding to each spectral image is expressed as: {y (1) ,...,y (m) }; S333, calculate the average gradient g of the m samples at the current time step t according to the following rules t : Among them, the function f(x (i) ; θ) represents the function of convolutional neural network mapping, function L(f(x (i) ;θ),y (i) ) represents the loss function; Represents the gradient symbol; S334: Update the cumulative gradient v corresponding to the current time step t according to the following rules. t :v t ←μv t-1 +(1-μ)g t , where the symbol v t-1 Represents the cumulative gradient corresponding to the previous time step of the current time step t; S335: Update and accumulate the square gradient r corresponding to the current time step t according to the following rules. t :r t ←ρr t-1 +(1-ρ)g t *g t , where the symbol r t-1 represents the cumulative square gradient corresponding to the previous time step of the current time step t; S336: Calculate the first correction deviation according to the following rules and the second corrected deviation in, S337: Update the parameters to be learned at the current time step t based on the following rules Among them, the symbol θ t-1 represents the parameter to be learned corresponding to the previous time step of the current time step t; Update time step t=t+1; S338, repeating steps S332 to S337 iteratively until the accuracy of the trained parameter θ to be learned on the validation set meets a predetermined threshold and then stopping the training.

2. The method according to claim 1, characterized in that The spectral camera is rotatably arranged above the waste to be processed, and the focal length f of the spectral camera is set based on the following formula: Among them, the symbol h represents the imaging height of the garbage to be processed on the spectral camera, the symbol H represents the height of the garbage to be processed, the symbol L represents the distance between the garbage being observed and processed and the lens of the spectral camera, the symbol h0 represents the height of the photosensitive element of the spectral camera, the symbol w represents the imaging width of the garbage to be processed on the spectral camera, the symbol W represents the width of the garbage to be processed, the symbol w0 represents the width of the photosensitive element of the spectral camera, and the symbol ε is a parameter with a predetermined numerical value.

3. The method according to claim 2, characterized in that After obtaining the calorific value information corresponding to the waste to be processed, the method includes: The spectral camera is rotated to obtain the calorific value information of the waste to be processed at different positions, and the calorific value information of the waste to be processed at different positions is displayed in a display interface.

4. The method according to claim 1, characterized in that An LED light source is arranged above the waste to be processed, and the LED light source is used to provide supplementary light for the waste to be processed.

5. The method according to claim 1, characterized in that The spectral images in the training set are subjected to data enhancement operations by combining one or more operations selected from the group consisting of flipping, translating, rotating, scaling, and adding noise to obtain spectral images processed by the data enhancement operations, so as to improve the generalization ability of the trained convolutional neural network.

6. The method according to claim 1, characterized in that For any layer of neurons in the convolutional neural network, from the open interval Uniformly randomly select values ​​for all parameters to be learned in any layer of neurons, where the symbol d represents the number of neurons in any layer of neurons.

7. The method according to claim 1, characterized in that A batch normalization layer is provided between adjacent fully connected layers and nonlinear activation layers in the convolutional neural network. The batch normalization layer is used to perform standardization processing on batch data output by each neuron in the fully connected layer when a number of training samples are used as input data. The standardization processing process specifically includes: For any neuron in the fully connected layer, calculate the mean μ of the batch data output by any neuron B ,in, Among them, x i , i=1,2,...,n represents the batch output data of any neuron when the number of training samples is used as input data; Calculate the variance of the batch output data output by any one of the neurons in, The normalized value of the output value of any one neuron is calculated based on the following formula in, The symbol ε2 represents a constant whose value is greater than zero and less than a predetermined positive value; The normalized value is calculated based on the following formula: Perform translation and scaling operations to obtain the output data y after the translation and scaling operations i , where γ represents the scaling factor corresponding to any one of the neurons, and β represents the translation factor corresponding to any one of the neurons; 8. The method as claimed in claim 7, characterized in that In the process of testing the convolutional neural network, for a specific test sample, when performing standardization on any one of the neurons, the mean of several historical means corresponding to any one of the neurons during the training of the convolutional neural network is used as the mean. The mean of the variances corresponding to any one neuron in the convolutional neural network training process is used as the variance 9. A garbage calorific value measuring device based on a spectral camera, characterized in that: include: The spectral image acquisition module is used to acquire the original spectral image of the garbage to be processed by using a spectral camera, and perform denoising on the original spectral image to obtain a spectral image after denoising; A spectral information acquisition module, used for obtaining spectral information of the garbage to be processed based on the spectral image after the denoising process; A garbage calorific value information acquisition module is used to input the spectral information into a trained convolutional neural network to obtain the calorific value information corresponding to the garbage to be processed; The training process of the trained convolutional neural network specifically includes: Build a dataset; A spectral camera is used in advance to obtain a plurality of spectral images of garbage mixtures obtained by mixing different types of garbage, and the calorific value information of each garbage mixture is measured based on a calorific value measuring instrument to obtain a plurality of spectral images of the garbage mixtures with the calorific value information as a label; Dividing the spectral images of the garbage mixture labeled with calorific value information into a training set and a validation set according to a predetermined ratio; The convolutional neural network is trained using the spectral image of the garbage mixture labeled with calorific value information in the training set as a training sample; during the training process, the weight parameters in the convolutional neural network are updated according to the following optimizer algorithm, and the training is stopped when the accuracy of the trained convolutional neural network on the verification set meets a predetermined threshold; wherein the optimizer algorithm specifically includes: Set the learning rate ε, decay rate ρ, momentum coefficient v, set the initial value of the parameter to be learned θ, cumulative square gradient r, cumulative gradient v in the convolutional neural network, and set the value to 10 -5 The parameter δ, M samples are randomly selected from the training set, wherein each of the m samples carries corresponding calorific value information, and the m spectral images contained in the sample are expressed as: {x (1) ,...,x (m) }, and the calorific value information corresponding to each spectral image is expressed as: {y (1) ,...,y (m) }; Calculate the average gradient g of the m samples at the current time step t according to the following rules t : Among them, the function f(x (i) ; θ) represents the function of convolutional neural network mapping, function L(f(x (i) ;θ),y (i) ) represents the loss function; Represents the gradient symbol; Update the cumulative gradient v corresponding to the current time step t according to the following rules t :v t ←μv t-1 +(1-μ)g t , where the symbol v t-1 Represents the cumulative gradient corresponding to the previous time step of the current time step t; Update the accumulated square gradient r corresponding to the current time step t according to the following rules t :r t ←ρr t-1 +(1-ρ)g t *g t , where the symbol r t-1 represents the cumulative square gradient corresponding to the previous time step of the current time step t; Calculate the first correction deviation according to the following rules and the second corrected deviation in, Update the parameters to be learned at the current time step t based on the following rules Among them, the symbol θ t-1 represents the parameter to be learned corresponding to the previous time step of the current time step t; Update time step t=t+1; The training is stopped when the accuracy of the trained parameter θ on the validation set meets a predetermined threshold.