A method for detecting the content of branched-chain and amylose in mixed sorghum

Through the combination of hyperspectral imaging technology and machine learning models, rapid, non-destructive and accurate detection of branched chains and amylose content in mixed sorghum is achieved, solving the problems of high detection difficulty and low accuracy in the prior art, and improving the quality and yield of liquor.

CN114693636BActive Publication Date: 2025-04-11SICHUAN UNIVERSITY OF SCIENCE AND ENGINEERING
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202210322694.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-30
Publication Date
2025-04-11
Estimated Expiration
2042-03-30

AI Technical Summary

Technical Problem

The prior art is difficult to quickly and without loss to accurately detect the content of branched chains and amylose in mixed sorghum, which makes it difficult to guarantee the quality and yield of liquor.

Method used

The detection method based on hyperspectral imaging technology is adopted to segment sorghum grains through the improved watershed algorithm after extended maximum value transformation, combining genetic algorithms and BP neural network models, and fusing visible light and near-infrared spectral data to achieve high-precision detection of starch content.

Benefits of technology

It realizes rapid, non-destructive and accurate detection of branched chain and amylose content in mixed sorghum, which can effectively support the adjustment of process parameters during liquor brewing and improve product quality and yield.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114693636B_ABST
    Figure CN114693636B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for detecting the content of amylopectin and amylose in mixed sorghum. The method comprises: using visible light and near-infrared hyperspectral imaging systems to respectively collect hyperspectral images of mixed sorghum samples, and using chemical analysis methods to determine the starch content in the samples; segmenting the sorghum grains in the hyperspectral images of the samples, extracting spectral data, and extracting characteristic wavelengths or spectral features; and establishing a model using feature fused data to predict the starch content of mixed sorghum. The present invention realizes rapid, non-destructive and accurate evaluation of the starch content of mixed sorghum, effectively detects the starch content of mixed sorghum samples with different ratios, and provides a method for online detection of the amylopectin and amylose content of mixed sorghum.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention discloses a method for detecting the content of amylopectin and amylose in mixed sorghum, belongs to the technical field of solid brewing raw material detection, and particularly relates to a method for detecting the content of amylopectin and amylose in mixed sorghum based on hyperspectral imaging technology. Background Art

[0002] Solid-state fermentation technology has a long history in my country and is also a unique brewing process in my country. In the liquor brewing industry, sorghum is often used as an ideal raw material for brewing because of its high starch content, which accounts for about 65-70% of the sorghum ingredients, and its appropriate content of protein, tannin, and fat. It is used as the sole raw material for sauce-flavor liquor and the main raw material for strong-flavor liquor.

[0003] The starch in sorghum is composed of amylose and amylopectin, which are not only the main components for the production of alcohol, but also the main source of energy for the growth and reproduction of brewing microorganisms. The higher the amylopectin content of a sorghum variety, the easier it is to gelatinize the sorghum, which is more conducive to the growth, reproduction and metabolism of brewing microorganisms. At the same time, it will also produce more aromatic substances, making the flavor of the liquor fuller. The higher the amylose content of a sorghum variety, the more difficult it is to gelatinize the sorghum, but it can increase the yield of liquor. Different varieties of sorghum have different contents of amylose and amylopectin, and wineries often use a variety of mixed varieties of sorghum as brewing raw materials. Since it is difficult to accurately estimate the content of amylose and amylopectin after mixing different sorghum varieties, in order to ensure the quality and yield of liquor, it is particularly important to detect the content of amylose and amylopectin in mixed sorghums with different proportions.

[0004] At present, the detection of sorghum starch content mainly adopts chemical analysis method and non-destructive testing method. In chemical method, iodine affinity titration and dual-wavelength spectrophotometry are often used to determine starch content, but such methods are time-consuming and destructive. In non-destructive testing, near-infrared spectroscopy technology is often used to non-destructively determine starch content, but it can only achieve single-point detection and the detection accuracy is not high. Therefore, a fast and non-destructive method is needed to obtain the content of amylopectin and amylose in mixed sorghum.

[0005] The existing patent CN110609011A, the invention name is single-grain corn seed starch content near-infrared hyperspectral detection method and system, the invention records: by obtaining the double-surface (embryo surface, non-embryo surface) spectral curve of the single-grain corn seed to be detected; the double-surface spectral curve of the single-grain corn seed to be detected is input into the pre-constructed single-grain corn seed starch content prediction model to obtain the physical and chemical value of the starch content of the single-grain corn seed to be detected. By combining the hyperspectral information of the embryo surface and the non-embryo surface, the rapid and non-destructive detection of the starch content of corn seeds is achieved at the single-grain level, providing a new technical means for the rapid grading and screening of the quality of single-grain corn seeds. However, the single-grain corn seed starch content detection method described in the patent is not efficient and accurate. If, in the actual rapid grading and sun-drying of the quality of single corn seeds, the near-infrared hyperspectral system is used to collect the spectral data of the embryo surface of the single corn seeds, and then the single corn seeds are turned to the non-embryo surface, and the spectral data of the non-embryo surface is collected, this process is time-consuming and not conducive to the rapid grading of the quality of single corn seeds; in addition, the spectral data of the embryo surface and the non-embryo surface of the same corn seed need to correspond accurately. If they do not correspond accurately, a high-precision single corn seed starch content prediction model cannot be established. In addition, the patent does not mention what kind of mathematical model is used to predict the starch content of single corn seeds, nor does it mention the accuracy of this method in detecting the starch content of single corn seeds.

[0006] CN103163128A, the invention name is: a method for determining the content of amylopectin and amylose in sorghum. The invention records the method including three steps, first preparing the regression equation of amylopectin and the regression equation of amylose in sorghum, then calculating the absorption ratio α of amylopectin and the absorption ratio β of amylose, and finally the sample determination. In this step, the absorbance of amylopectin and amylose at the measurement wavelength is calculated by a given formula, and then the corresponding absorption ratio and absorbance are brought into the corresponding regression equation to obtain the concentration of amylopectin and amylose. However, the method for determining the content of amylopectin and amylose in sorghum described in the patent belongs to destructive detection, and the sample cannot be used after detection. If the sample size is large, it will cause a waste of resources. In addition, the detection method described in the patent has a long cycle, and it is impossible to achieve rapid detection of amylopectin and amylose in sorghum. In addition, the patented method can only obtain the concentration of amylopectin and amylose, and does not achieve the detection of their specific content. Summary of the invention

[0007] The purpose of the present invention is to provide a method for detecting the content of amylopectin and amylose in mixed sorghum in view of the technical problems existing in the prior art. The detection method can realize rapid, non-destructive and accurate evaluation of the starch content of mixed sorghum, can effectively detect the starch content of mixed sorghum samples with different proportions, and provides a method for online detection of the content of amylopectin and amylose in mixed sorghum.

[0008] In order to achieve the above invention object, the specific technical solution of the present invention is:

[0009] A method for detecting the content of branched-chain starch and straight-chain starch in mixed sorghum comprises the following steps:

[0010] (1) respectively collecting hyperspectral images of the mixed sorghum sample in the visible light and near infrared spectral ranges, obtaining original hyperspectral image data of the mixed sorghum, and then performing black-white correction on the original hyperspectral image data;

[0011] (2) Determine the amylopectin and amylose contents of mixed sorghum samples;

[0012] (3) for the original hyperspectral image of step (1), segmenting the sorghum adhesion grain region of the image based on the watershed algorithm improved by extended maximum transform, segmenting the sorghum grain part from the image, removing the background part, and obtaining the pixel coordinates of each sorghum grain;

[0013] (4) for the pixel coordinates in the single sorghum kernel in step (3), extract the spectral vector value at the pixel coordinates and perform black-white correction, then average the spectral values ​​of all the pixel points in the single sorghum kernel in the same band to obtain the average spectral vector value of the single sorghum kernel, i.e., spectral data 1;

[0014] (5) averaging the average spectral vector values ​​of all sorghum kernels in a single sample (spectral data 1) to obtain the average spectral vector value of the sorghum sample, i.e., spectral data 2;

[0015] (6) performing black-white correction on the spectral data 2 in step (5), and then performing multivariate scattering correction combined with SG smoothing filter preprocessing to obtain spectral data 3;

[0016] (7) extracting characteristic wavelengths from the spectral data 3 in step (6) using the Pearson correlation coefficient method to obtain spectral data 4; extracting the score matrix corresponding to the latent variables, i.e., spectral feature 1, from the spectral data 3 using partial least squares regression (PLSR);

[0017] (8) fusing the spectral data 4 in the visible light range and the spectral data 4 in the near infrared spectral range of step (7) to obtain spectral data 5; fusing the spectral feature 1 in the visible light range and the spectral feature 1 in the near infrared spectral range of step (7) to obtain spectral feature 2;

[0018] (9) using the spectral data 5 of step (8) and the amylose content data corresponding to step (2) as training sets, constructing a genetic algorithm combined with a BP neural network model, and obtaining a prediction model for amylose in mixed sorghum;

[0019] (10) Using the spectral feature 2 of step (8) and the amylopectin content data corresponding to step (2) as a training set, constructing a genetic algorithm combined with a BP neural network model to obtain a prediction model for the amylopectin content of mixed sorghum;

[0020] (11) Collecting a hyperspectral image of the mixed sorghum to be tested, and using the prediction model of steps (9) and (10) to detect the straight chain and amylopectin content of the mixed sorghum to obtain a predicted value of the starch content of the mixed sorghum.

[0021] Furthermore, in step (1), the visible light and near infrared spectral ranges are 397-1000nm and 940-1730nm respectively.

[0022] Furthermore, in step (1), the formula for black and white correction is as follows:

[0023]

[0024] Where: R is the corrected reflectance image of the mixed sorghum sample; I is the original hyperspectral image of the mixed sorghum sample; W is the standard white board image; D is the standard black board image.

[0025] Furthermore, in step (2), the amylose content of each mixed sorghum sample is determined using the national standard method GB7648-87.

[0026] Furthermore, in step (4), the formula of the spectral data 1 is as follows:

[0027]

[0028] in: is the average spectral value of all pixels in a sorghum kernel in a certain band; m is the number of pixels inside the sorghum kernel selected by the milling class; I i,j is the reflectance of the j-th pixel in the i-th band.

[0029] Furthermore, in step (5), the formula of the spectral data 2 is as follows:

[0030]

[0031] in: is the average reflectance of all sorghum kernels in the mixed sorghum sample in a certain band; k is the number of all sorghum kernels in the mixed sorghum sample; is the average reflectance of the kth sorghum in the i-th band.

[0032] Furthermore, in step (7), the specific steps of extracting characteristic wavelengths using the Pearson correlation coefficient method are as follows:

[0033] (A) The correlation statistics between the spectral data 3 and the amylose content data were calculated according to the Pearson correlation coefficient method. The formula is as follows:

[0034]

[0035] Where: r represents the Pearson correlation coefficient; x i is the reflectance of a certain band in the i-th sample spectrum data 3, is the average reflectance of a certain band in spectral data 3; i is the amylose content of the ith sample; is the average amylose content of all samples;

[0036] (B) The wavelengths with an absolute value of the Pearson correlation coefficient ≥ 0.9 (extremely strong correlation) and an absolute value of the significance level coefficient ≤ 0.01 were selected as characteristic wavelengths.

[0037] Furthermore, in step (7), the spectral data 3 is subjected to PLSR to extract the score matrix corresponding to the latent variables, and the specific steps are as follows:

[0038] (i) Standardize the data of spectral data 3, that is, centralize the data by performing the following operation on each sample of spectral data 3: subtract the mean of a dimension (column) variable and divide it by the standard deviation of the dimension (column);

[0039] (ii) Calculate the correlation coefficient matrix between (i) the independent variable group (standardized data) and the dependent variable group (amylose content);

[0040] (ii) The components of the independent variable group and the dependent variable group are proposed respectively. When the ratio of the first k components to explain the independent variables reaches 90%, the matrix of the first k components is taken as the score matrix.

[0041] Furthermore, in step (8), the data fusion refers to serially splicing the data blocks, as follows:

[0042] Data block 1: Data block 2:

[0043] After splicing:

[0044] Furthermore, in steps (9) and (10), the population size of the genetic algorithm is set to 100, the number of genetic iterations is 50, the crossover probability is 0.6, and the mutation probability is 0.05.

[0045] Furthermore, in steps (9) and (10), the BP neural network model consists of an input layer, a hidden layer and an output layer.

[0046] Furthermore, in steps (9) and (10), the parameters of the BP neural network model are designed as follows: trainlm is determined as the training function of the neural network, the hidden layer is set to 1 layer with 15 point neurons, tansig is determined as the transfer function of the hidden layer nodes, purelin is the transfer function of the output layer nodes, the network learning function is the BP learning rule learngdm, the learning rate is 0.001, the number of iterations is 1000, and the training target is 4.43e-7.

[0047] Furthermore, in steps (9) and (10), the input of the BP neural network model is spectral data 5 or spectral feature 2.

[0048] Furthermore, in steps (9) and (10), the output of the BP neural network model is the content of straight-chain or amylopectin corresponding to each mixed sorghum sample.

[0049] In this detection method, a hyperspectral sample of mixed sorghum is collected by a visible light and near-infrared hyperspectral imaging system, and the starch content of the hyperspectral sample is measured. The invention is different from other existing hyperspectral detection methods for starch content. The invention expands the spectral range of the acquisition equipment and obtains sample hyperspectral data with a wide spectral range. The rapid and non-destructive acquisition of mixed sorghum is achieved through hyperspectral imaging technology.

[0050] By fusing the visible light and near-infrared spectral data of mixed sorghum samples and establishing a mathematical model for the starch content of mixed sorghum, in order to improve the accuracy of starch content prediction of mixed sorghum, the present invention proposes a new data fusion method to fuse visible light and near-infrared spectral data, and realizes high-precision detection of mixed sorghum.

[0051] Compared with the prior art, the present invention has the following beneficial effects:

[0052] (1) Accurate segmentation of sorghum grains. The hyperspectral image of the mixed sorghum sample contains a large amount of irrelevant background information and information about the sorghum grains, and there is adhesion between the sorghum grains. In order to remove irrelevant background information and segment the sorghum grains with adhesion, as well as to solve the over-segmentation and under-segmentation of sorghum grains. This patent proposes an improved watershed algorithm based on extended maximum transform to achieve the segmentation of sorghum grains in the RGB image of mixed sorghum. Before using the watershed algorithm, the RGB image of sorghum was subjected to an extended maximum transform to obtain an image with clear outlines of the sorghum grains. The image was used in the watershed algorithm to obtain an accurately segmented image of the sorghum grains, and the spectral data of a single sorghum grain was accurately extracted, which is conducive to the subsequent establishment of a high-precision starch content prediction model.

[0053] (ii) The feature fusion method was used to perform feature fusion on the hyperspectral data of mixed sorghum in two spectral ranges (Vis and NIR). The present application uses two methods to extract the spectral features or characteristic wavelengths of the spectral data of Vis and NIR, respectively.

[0054] 1) A partial least squares regression (PLSR) model was established using the independent variables (Vis and NIR spectral data) and the dependent variable (starch content of mixed sorghum); the established PLSR model then selected the score matrix corresponding to the latent variable as the spectral feature according to the cumulative contribution rate. The spectral features extracted from the Vis and NIR spectral data by the above method were serially spliced ​​together for the subsequent modeling of the prediction model of the amylopectin content of mixed sorghum.

[0055] 2) The Pearson correlation coefficient was used to extract characteristic wavelengths with high correlation with sorghum starch content. The characteristic wavelengths under Vis and NIR were selected based on the absolute value of the Pearson correlation coefficient and the significance level coefficient. The characteristic wavelengths extracted from the spectral data of Vis and NIR by the above method were serially spliced ​​together for the subsequent modeling of the amylose content prediction model of mixed sorghum.

[0056] (III) A starch content prediction model of a genetic algorithm optimized BP neural network (GA-BPNN) was developed. This patent combines the GA algorithm and the BP neural network to optimize the initial weights and thresholds of the neural network as a whole. After testing, it was found that the model effect was best when the network structure and parameters of the GA-BPNN were set as follows: the population size of the GA algorithm was set to 100, the number of genetic iterations was 50, the crossover probability was 0.6, and the mutation probability was 0.05; the hidden layer of the BPNN was set to 1 layer with 15 neurons, and the activation functions of the hidden layer and the output layer were selected as tansig function and purelin function respectively, and the network learning rate and number of iterations were set to 0.001 and 1000 respectively.

[0057] (IV) Currently, there is no method for measuring the starch content of mixed sorghum. This application proposes a rapid and accurate method for detecting the starch content of mixed sorghum, which has guiding significance for the timely adjustment of process parameters in the liquor brewing process, and also provides a method for the component detection of other grains. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] Figure 1 is a flow chart of the method of the present invention;

[0059] Figure 2 This is a diagram of the image segmentation process in the fourth step of Example 1 of the present invention;

[0060] Figure 3 is a graph of the spectrum data 3 of step 5 in Example 1 of the present invention;

[0061] Figure 4 It is the characteristic wavelength position extracted by the Pearson correlation coefficient in the sixth step of Example 1 of the present invention. DETAILED DESCRIPTION

[0062] The following is an explanation of the embodiments of the present invention by specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the following embodiments and features in the embodiments can be combined with each other without conflict.

[0063] It should be noted that in order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention are clearly and completely described below. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all of the embodiments.

[0064] Therefore, the following detailed description of the embodiments of the present invention is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0065] Unless otherwise specified, the raw materials, equipment and methods used in the present invention are commonly used in the art.

[0066] Embodiment 1:

[0067] A method for detecting the content of amylopectin and amylose in mixed sorghum, the specific steps are as follows:

[0068] Step 1: Mixed sorghum sample preparation

[0069] In this embodiment, Hongyingzi (HYZ) from a sorghum breeding center in Guizhou was selected as the mixed sorghum variety, and American sorghum (MG) and Tiegan (TG) from a sorghum breeding center in Sichuan and Shandong were selected as the mixed sorghum varieties. The three sorghum varieties were combined in pairs to obtain three groups of mixed samples (MG+HYZ, TG+HYZ, TG+MG). Table 1 shows the specific information of sorghum samples with different mixing ratios.

[0070] Table 1 Preparation of sorghum samples with different mixing ratios

[0071]

[0072]

[0073] Note: The combination of TG+HYZ and TG+MG is consistent with the above table.

[0074] Step 2: Hyperspectral image acquisition and correction of mixed sorghum samples

[0075] 1) Equipment configuration: The hyperspectral imaging system consists of a hyperspectral camera (Finland FX17 / FX10 series), a halogen lamp (OSRAM, German), an electronically controlled mobile platform, data acquisition software (LUMO-scanner), a computer, and a calibration whiteboard. The hyperspectral camera uses a near-infrared camera (NIR: 940-1730nm) and a visible light camera (Vis: 397-1000nm). The band interval of the NIR camera is 3.5nm, which divides the spectrum into 224 bands. The band interval of the Vis camera is 2.1nm, which divides the spectrum into 448 bands;

[0076] 2) Equipment parameter setting: When using the NIR camera, adjust the white plate calibration peak to 3616, set the exposure frequency and exposure time to 50Hz and 4.02ms respectively, and set the mobile platform scanning speed to 16.57mm / s. When using the Vis camera to collect data, the white plate calibration peak and the camera exposure frequency are consistent with the NIR parameters, the exposure time is set to 8.0ms, and the mobile platform scanning speed is set to 10.84mm / s. After the acquisition parameters are set, the sorghum sample is spread in a culture dish with a diameter of 150mm, and then placed on an electronically controlled mobile platform for data collection; if the above parameters are not set, the collected hyperspectral image of the mixed sorghum will not be clear, which is not conducive to the subsequent sorghum grain segmentation and the establishment of an accurate sorghum starch content prediction model.

[0077] 3) Black and white correction: The original hyperspectral image data is corrected using the hyperspectral image data of the black correction plate and the hyperspectral image data of the white correction plate to obtain the spectral reflectance of the sample.

[0078] The formula for the black and white correction is as follows:

[0079]

[0080] Where: R is the corrected reflectance image of the mixed sorghum sample; I is the original hyperspectral image of the mixed sorghum sample; W is the standard white board image; D is the standard black board image.

[0081] In the third step, the amylose and straight-chain starch contents of each mixed sorghum sample were determined using the national standard method GB7648-87.

[0082] Step 4: Sorghum grain image segmentation

[0083] The image data of mixed sorghum contains sorghum kernel information as well as irrelevant background information, and there is a phenomenon of adhesion between sorghum kernels. In order to remove irrelevant background information and segment the sorghum kernels with adhesion, it is necessary to use image processing and segmentation algorithms suitable for the image. The specific steps are as follows:

[0084] 1) graying the RGB image of the sorghum sample to obtain a grayscale image of the sorghum sample;

[0085] 2) Binarize the RGB image of the sorghum sample and use the Otsu threshold segmentation method to binarize the image to obtain a black and white image of the sorghum sample;

[0086] 3) Performing an extended maximum transformation on the grayscale image of the sorghum sample to obtain a grayscale image after the extended maximum transformation;

[0087] 4) Distance transformation of grayscale image, performing Euclidean distance transformation on the transformed black-and-white image to obtain the transformed image;

[0088] 5) Segment the image, using the watershed algorithm to segment the distance transformed image to obtain a watershed ridge image;

[0089] 6) Subtract the watershed ridge image from the black and white image in 2) to obtain a binary image after segmenting the sorghum grains.

[0090] Step 5: Spectral data extraction and preprocessing

[0091] 1) Obtain the pixel coordinates of each sorghum grain from the binary image segmented in the fourth step;

[0092] 2) According to the coordinates of the pixel points in a single sorghum kernel, the spectral vector value at the pixel coordinates is extracted, and then the spectral values ​​of all the pixel points in the single sorghum kernel in the same band are averaged to obtain the average spectral vector value of the single sorghum kernel, i.e., spectral data 1;

[0093] The formula for spectral data 1 is as follows:

[0094]

[0095] in: is the average spectral value of all pixels in a sorghum kernel in a certain band; m is the number of pixels inside the sorghum kernel selected by the milling class; I i,j is the reflectance of the j-th pixel in the i-th band.

[0096] 3) averaging the average spectral vector values ​​of all sorghum kernels in each sample to obtain the average spectral vector value of the sorghum sample, i.e., spectral data 2;

[0097] The formula for spectral data 2 is as follows:

[0098]

[0099] in: is the average reflectance of all sorghum kernels in the mixed sorghum sample in a certain band; k is the number of all sorghum kernels in the mixed sorghum sample; is the average reflectance of the kth sorghum in the i-th band.

[0100] 4) Preprocessing the spectral data 2 using multivariate scatter correction combined with SG smoothing filter (MSC-SG) to obtain spectral data 3;

[0101] The correlation statistics of spectral data 3 and amylose content data are as follows:

[0102]

[0103] Where: r represents the Pearson correlation coefficient; x i is the reflectance of a certain band in the i-th sample spectrum data 3, is the average reflectance of a certain band in spectral data 3; i is the amylose content of the ith sample; is the average amylose content of all samples.

[0104] The spectral data 3 in the visible range is a 300×448 matrix, and the spectral data 3 in the near infrared range is a 300×224 matrix, where 300 represents the number of mixed sorghum samples, and 224 and 448 represent the number of bands.

[0105] Step 6: Feature extraction

[0106] 1) According to the absolute value of the Pearson correlation coefficient ≥ 0.9 (extremely strong correlation) and the absolute value of the significance level coefficient ≤ 0.01, the characteristic wavelengths of spectral data 3 were extracted, and 47 wavelengths (300×47) were selected in the visible light range. 32 wavelengths (300×32) were selected in the near-infrared range, namely spectral data 4. If the characteristic wavelengths of spectral data 3 are not extracted according to the absolute value of the Pearson correlation coefficient ≥ 0.9 (extremely strong correlation) and the absolute value of the significance level coefficient ≤ 0.01, the performance of the starch content prediction model established later will be poor.

[0107] 2) According to the PLSR algorithm, the spectral features of spectral data 3 are extracted. The cumulative contribution rates of the first five latent variables in the visible light range and near-infrared range are 89.23% and 85.95%, respectively. Therefore, the score matrix (300×5) corresponding to the first five latent variables in the visible light range and near-infrared range is selected as the spectral feature, that is, spectral feature 1.

[0108] Step 7: Feature data fusion

[0109] The characteristic wavelengths extracted by Pearson in the visible and near-infrared range (spectral data 4) and the spectral feature 1 extracted by PLSR were serially spliced ​​to obtain spectral data 5 (300×79) and spectral feature 2 (300×10), respectively.

[0110] Data fusion refers to serial splicing of data blocks, as follows:

[0111] Data block 1: Data block 2:

[0112] After splicing:

[0113] Step 8: GA-BPNN model training

[0114] 1) Using the spectral data 5 of the seventh step and the amylose content data corresponding to the fourth step as a training set (260 samples) and a test set (40), constructing a genetic algorithm combined with a BP neural network model to obtain a prediction model for amylose in mixed sorghum;

[0115] 2) Using the spectral feature 1 of the seventh step and the amylopectin content data corresponding to the fourth step as a training set (260 samples) and a test set (40), a genetic algorithm combined with a BP neural network model was constructed to obtain a prediction model for the amylopectin content of mixed sorghum;

[0116] 3) Model evaluation to determine the coefficient R 2 , Root Mean Square Error (RMSE) is used as the evaluation index to determine the effect of the model. The results are shown in Table 2.

[0117] Table 2 Model results

[0118]

[0119] Step 9: Prediction of starch content of the sample to be tested

[0120] The hyperspectral image of the mixed sorghum sample to be tested is collected, and the predicted values ​​of the straight-chain and amylopectin contents of the sample to be tested can be obtained by traversing from the second step to the eighth step, as shown in Table 3.

[0121] Table 3 Comparison of starch measurement and predicted values

[0122]

[0123]

[0124] Embodiment 2:

[0125] A method for detecting the content of amylopectin and amylose in mixed sorghum, the specific steps are as follows:

[0126] Step 1: Mixed sorghum sample preparation

[0127] In this embodiment, Hongyingzi (HYZ) from a sorghum breeding center in Guizhou was selected as the mixed sorghum variety, and Hongmao sorghum (HM) and Ruinuo sorghum (RN) from a sorghum breeding center in Sichuan and Shandong were selected as the mixed sorghum varieties. The three sorghum varieties were combined in pairs to obtain three groups of mixed samples (HM+HYZ, RN+HYZ, HM+RN). Table 4 shows the specific information of sorghum samples with different mixing ratios.

[0128] Table 4 Preparation of sorghum samples with different mixing ratios

[0129]

[0130] Note: The combination of RN+HYZ and HM+RN is consistent with the above table.

[0131] Step 2: Hyperspectral image acquisition and correction of mixed sorghum samples

[0132] 1) Equipment configuration: The hyperspectral imaging system consists of a hyperspectral camera (Finland FX17 / FX10 series), a halogen lamp (OSRAM, German), an electronically controlled mobile platform, data acquisition software (LUMO-scanner), a computer, and a calibration whiteboard. The hyperspectral camera uses a near-infrared camera (NIR: 940-1730nm) and a visible light camera (Vis: 397-1000nm). The band interval of the NIR camera is 3.5nm, which divides the spectrum into 224 bands. The band interval of the Vis camera is 2.1nm, which divides the spectrum into 448 bands;

[0133] 2) Equipment parameter setting: When using the NIR camera, adjust the white board calibration peak to 3616, set the exposure frequency and exposure time to 50Hz and 4.02ms respectively, and set the mobile platform scanning speed to 16.57mm / s. When using the Vis camera to collect data, the white board calibration peak and the camera's exposure frequency are consistent with the NIR parameters, the exposure time is set to 8.0ms, and the mobile platform scanning speed is set to 10.84mm / s. After the acquisition parameters are set, spread the sorghum sample in a culture dish with a diameter of 150mm, and then place it on an electronically controlled mobile platform for data collection; if the above parameters are not set, the collected hyperspectral image of the mixed sorghum will not be clear, which is not conducive to the subsequent sorghum grain segmentation and the establishment of an accurate sorghum starch content prediction model;

[0134] 3) Black and white correction: The original hyperspectral image data is corrected using the hyperspectral image data of the black correction plate and the hyperspectral image data of the white correction plate to obtain the spectral reflectance of the sample.

[0135] The formula for the black and white correction is as follows:

[0136]

[0137] Where: R is the corrected reflectance image of the mixed sorghum sample; I is the original hyperspectral image of the mixed sorghum sample; W is the standard white board image; D is the standard black board image.

[0138] In the third step, the amylose and straight-chain starch contents of each mixed sorghum sample were determined using the national standard method GB7648-87.

[0139] Step 4: Sorghum grain image segmentation

[0140] The image data of mixed sorghum contains sorghum kernel information as well as irrelevant background information, and there is a phenomenon of adhesion between sorghum kernels. In order to remove irrelevant background information and segment the sorghum kernels with adhesion, it is necessary to use image processing and segmentation algorithms suitable for the image. The specific steps are as follows:

[0141] 1) graying the RGB image of the sorghum sample to obtain a grayscale image of the sorghum sample;

[0142] 2) Binarize the RGB image of the sorghum sample and use the Otsu threshold segmentation method to binarize the image to obtain a black and white image of the sorghum sample;

[0143] 3) Performing an extended maximum transformation on the grayscale image of the sorghum sample to obtain a grayscale image after the extended maximum transformation;

[0144] 4) Distance transformation of grayscale image, performing Euclidean distance transformation on the transformed black-and-white image to obtain the transformed image;

[0145] 5) Segment the image, using the watershed algorithm to segment the distance transformed image to obtain a watershed ridge image;

[0146] 6) Subtract the watershed ridge image from the black and white image in 2) to obtain a binary image after segmenting the sorghum grains.

[0147] Step 5: Spectral data extraction and preprocessing

[0148] 1) Obtain the pixel coordinates of each sorghum grain from the binary image segmented in the fourth step;

[0149] 2) According to the coordinates of the pixel points in a single sorghum kernel, the spectral vector value at the pixel coordinates is extracted, and then the spectral values ​​of all the pixel points in the single sorghum kernel in the same band are averaged to obtain the average spectral vector value of the single sorghum kernel, i.e., spectral data 1;

[0150] The formula for spectral data 1 is as follows:

[0151]

[0152] in: is the average spectral value of all pixels in a sorghum kernel in a certain band; m is the number of pixels inside the sorghum kernel selected by the milling class; I i,j is the reflectance of the j-th pixel in the i-th band.

[0153] 3) averaging the average spectral vector values ​​of all sorghum kernels in each sample to obtain the average spectral vector value of the sorghum sample, i.e., spectral data 2;

[0154] The formula for spectral data 2 is as follows:

[0155]

[0156] in: is the average reflectance of all sorghum kernels in the mixed sorghum sample in a certain band; k is the number of all sorghum kernels in the mixed sorghum sample; is the average reflectance of the kth sorghum in the i-th band.

[0157] 4) Preprocessing the spectral data 2 using multivariate scatter correction combined with SG smoothing filter (MSC-SG) to obtain spectral data 3;

[0158] The correlation statistics of spectral data 3 and amylose content data are as follows:

[0159]

[0160] Where: r represents the Pearson correlation coefficient; x i is the reflectance of a certain band in the i-th sample spectrum data 3, is the average reflectance of a certain band in spectral data 3; i is the amylose content of the ith sample; is the average amylose content of all samples.

[0161] The spectral data 3 in the visible range is a 300×448 matrix, and the spectral data 3 in the near infrared range is a 300×224 matrix, where 300 represents the number of mixed sorghum samples, and 224 and 448 represent the number of bands.

[0162] Step 6: Feature extraction

[0163] 1) According to the absolute value of the Pearson correlation coefficient ≥ 0.9 (extremely strong correlation) and the absolute value of the significance level coefficient ≤ 0.01, the characteristic wavelengths of spectral data 3 were extracted, and 42 wavelengths (300×42) were selected in the visible light range. 28 wavelengths (300×28) were selected in the near-infrared range, namely spectral data 4. If the characteristic wavelengths of spectral data 3 are not extracted according to the absolute value of the Pearson correlation coefficient ≥ 0.9 (extremely strong correlation) and the absolute value of the significance level coefficient ≤ 0.01, the performance of the starch content prediction model established later will be poor.

[0164] 2) According to the PLSR algorithm, the spectral features of spectral data 3 are extracted. The cumulative contribution rates of the first five latent variables in the visible light range and near-infrared range are 90.45% and 92.63%, respectively. Therefore, the score matrix (300×5) corresponding to the first five latent variables in the visible light range and near-infrared range is selected as the spectral feature, that is, spectral feature 1.

[0165] Step 7: Feature data fusion

[0166] The characteristic wavelengths extracted by Pearson in the visible and near-infrared range (spectral data 4) and the spectral feature 1 extracted by PLSR were serially spliced ​​to obtain spectral data 5 (300×70) and spectral feature 2 (300×10), respectively.

[0167] Data fusion refers to serial splicing of data blocks, as follows:

[0168] Data block 1: Data block 2:

[0169] After splicing:

[0170] Step 8: GA-BPNN model training

[0171] 1) Using the spectral data 5 of the seventh step and the amylose content data corresponding to the fourth step as a training set (260 samples) and a test set (40), constructing a genetic algorithm combined with a BP neural network model to obtain a prediction model for amylose in mixed sorghum;

[0172] 2) Using the spectral feature 1 of the seventh step and the amylopectin content data corresponding to the fourth step as a training set (260 samples) and a test set (40), a genetic algorithm combined with a BP neural network model was constructed to obtain a prediction model for the amylopectin content of mixed sorghum;

[0173] 3) Model evaluation to determine the coefficient R 2 , Root Mean Square Error (RMSE) is used as the evaluation index to determine the effect of the model. The results are shown in Table 5.

[0174] Table 5 Model results

[0175]

[0176] Step 9: Prediction of starch content of the sample to be tested

[0177] The hyperspectral image of the mixed sorghum sample to be tested is collected, and the predicted values ​​of the straight-chain and amylopectin contents of the sample to be tested can be obtained by traversing from the second step to the eighth step, as shown in Table 5.

[0178] Table 5 Comparison of starch measurement and detection results

[0179]

[0180] The embodiment of the present invention provides a method for detecting the content of amylopectin and amylose in mixed sorghum based on hyperspectral imaging technology, and realizes the segmentation of sorghum grains in an RGB image of mixed sorghum by using a watershed algorithm improved by extended maximum transform; a feature fusion method is used to fuse the spectral features or characteristic wavelengths of mixed sorghum in the visible light and near-infrared spectral ranges; the established optimal detection model can simultaneously detect the content of amylopectin and amylose in mixed sorghum quickly, non-destructively and accurately; and a new method is provided for online real-time detection of the content of amylopectin and amylose in brewing raw materials (mixed sorghum) in the process of liquor brewing.

[0181] The above descriptions are only typical embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A method for detecting the content of branched and straight chain starch in mixed sorghum, characterized in that The following steps are involved: (1) respectively collecting hyperspectral images of the mixed sorghum sample in the visible light and near infrared spectral ranges, obtaining original hyperspectral image data of the mixed sorghum, and then performing black-white correction on the original hyperspectral image data; (2) Determine the amylopectin and amylose content in mixed sorghum samples; (3) for the original hyperspectral image of step (1), segmenting the sorghum adhesion grain region of the image based on the watershed algorithm improved by extended maximum transform, segmenting the sorghum grain part from the image, removing the background part, and obtaining the pixel coordinates of each sorghum grain; (4) for the pixel coordinates in the single sorghum kernel in step (3), extract the spectral vector value at the pixel coordinates and perform black-white correction, then average the spectral values ​​of all the pixel points in the single sorghum kernel in the same band to obtain the average spectral vector value of the single sorghum kernel, i.e., spectral data 1; (5) averaging the average spectral vector values ​​of all sorghum kernels in a single sample to obtain the average spectral vector value of the sorghum sample, i.e., spectral data 2; (6) performing black-white correction on the spectral data 2 in step (5), and then performing multivariate scattering correction combined with SG smoothing filter preprocessing to obtain spectral data 3; (7) extracting characteristic wavelengths from the spectral data 3 in step (6) using the Pearson correlation coefficient method to obtain spectral data 4; extracting the score matrix corresponding to the latent variables from the spectral data 3 using partial least squares regression (PLSR), i.e., spectral feature 1; (8) fusing the spectral data 4 in the visible light range and the spectral data 4 in the near infrared spectral range of step (7) to obtain spectral data 5; fusing the spectral feature 1 in the visible light range and the spectral feature 1 in the near infrared spectral range of step (7) to obtain spectral feature 2; (9) using the spectral data 5 of step (8) and the amylose content data corresponding to step (2) as training sets, constructing a genetic algorithm combined with a BP neural network model, and obtaining a prediction model for amylose in mixed sorghum; (10) Using the spectral feature 2 of step (8) and the amylopectin content data corresponding to step (2) as a training set, constructing a genetic algorithm combined with a BP neural network model to obtain a prediction model for the amylopectin content of mixed sorghum; (11) Collecting a hyperspectral image of the mixed sorghum to be tested, and using the prediction model of steps (9) and (10) to detect the straight chain and amylopectin content of the mixed sorghum to obtain a predicted value of the starch content of the mixed sorghum.

2. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In step (1), the visible light and near infrared spectral ranges are 397-1000nm and 940-1730nm respectively; Furthermore, in step (1), the formula for black and white correction is as follows: Where: R is the corrected reflectance image of the mixed sorghum sample; I is the original hyperspectral image of the mixed sorghum sample; W is the standard white board image; D is the standard black board image.

3. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In step (2), the amylose content of each mixed sorghum sample is determined using the national standard method GB7648-87.

4. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In step (4), the formula of the spectral data 1 is as follows: in: is the average spectral value of all pixels in a sorghum kernel in a certain band; m is the number of pixels inside the sorghum kernel selected by the milling class; I i,j is the reflectance of the j-th pixel in the i-th band.

5. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In step (5), the formula of the spectral data 2 is as follows: in: is the average reflectance of all sorghum kernels in the mixed sorghum sample in a certain band; k is the number of all sorghum kernels in the mixed sorghum sample; is the average reflectance of the kth sorghum in the i-th band.

6. The method for detecting the content of branched and amylose in mixed sorghum according to claim 1, characterized in that: In step (7), the specific steps of extracting characteristic wavelengths using the Pearson correlation coefficient method are as follows: (A) The correlation statistics between the spectral data 3 and the amylose content data were calculated according to the Pearson correlation coefficient method. The formula is as follows: Where: r represents the Pearson correlation coefficient; x i is the reflectance of a certain band in the i-th sample spectrum data 3, is the average reflectance of a certain band in spectral data 3; i is the amylose content of the ith sample; is the average amylose content of all samples; (B) Select the wavelength with the absolute value of Pearson correlation coefficient ≥ 0.9 and the absolute value of significance level coefficient ≤ 0.01 as the characteristic wavelength; Furthermore, in step (7), the spectral data 3 is subjected to PLSR to extract the score matrix corresponding to the latent variables, and the specific steps are as follows: (i) Standardize the data of spectral data 3, that is, centralize the data by performing the following operations on each sample of spectral data 3: subtract the mean of a column variable and divide it by the standard deviation of the column; (ii) Calculate the correlation coefficient matrix between the standardized data of (i) and the amylose content; (iii) The components of the independent variable group and the dependent variable group are proposed respectively. When the ratio of the first k components to explain the independent variables reaches 90%, the matrix of the first k components is taken as the score matrix.

7. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In step (8), the data fusion refers to serially splicing the data blocks, as follows: Data block 1: Data block 2: After splicing:

8. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In steps (9) and (10), the population size of the genetic algorithm is set to 100, the number of genetic iterations is 50, the crossover probability is 0.6, and the mutation probability is 0.

05.

9. The method for detecting the content of amylopectin and amylose in mixed sorghum according to claim 1, characterized in that: In steps (9) and (10), the BP neural network model consists of an input layer, a hidden layer and an output layer; the parameter design of the BP neural network model: trainlm is determined as the training function of the neural network, the hidden layer is set to 1 layer with 15 point neurons, tansig is determined as the transfer function of the hidden layer nodes, purelin is the transfer function of the output layer nodes, the network learning function is the BP learning rule learngdm, the learning rate is 0.001, the number of iterations is 1000, and the training target is 4.43e-7; the input of the BP neural network model is spectral data 5 or spectral feature 2; the output of the BP neural network model is the linear or amylopectin content corresponding to each mixed sorghum sample.

Citation Information

Patent Citations

  • Method for determining content of amylopectin and amylose in broomcorn

    CN103163128A

  • Single-grain corn seed starch content near-infrared hyperspectral detection method and system

    CN110609011A