Pear internal quality detection method based on characteristic wavelength and sample screening

By constructing a predictive model of characteristic wavelengths for internal quality detection of pears and sample fruits, and screening out absorption peak data at characteristic wavelengths, the problems of large data volume and low efficiency in existing spectral detection technologies are solved, and efficient internal quality detection of pears is achieved.

CN121740792APending Publication Date: 2026-03-27REEMOON TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-26
Publication Date
2026-03-27

AI Technical Summary

Technical Problem

Existing visible/near-infrared spectroscopy detection technologies generate massive and redundant data when detecting the internal quality of pears, making it difficult to effectively screen out characteristic wavelengths that contribute significantly to the detection, resulting in low detection efficiency.

Method used

By constructing a predictive model of characteristic wavelengths for internal quality detection of pears and sample fruits, absorption peak data at characteristic wavelengths are screened out. Combined with mathematical analysis methods, the amount of spectral data is reduced, and characteristic wavelengths are selected for detection.

Benefits of technology

This method reduces the amount of spectral data, improves detection efficiency and accuracy, and identifies characteristic wavelengths that contribute significantly to the detection process in the internal quality inspection of pears.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121740792A_ABST
    Figure CN121740792A_ABST
Patent Text Reader

Abstract

The invention discloses a pear internal quality detection method based on characteristic wavelength and sample screening, which can be applied to a visible / near infrared spectrum detection technology for detecting certain internal quality of pears. The difference value between the mean value of the normal fruit sample set and the mean value of the defective fruit sample set of the screened characteristic wavelength is as large as possible, and the variance of the normal fruit sample set and the defective fruit sample set is as small as possible; according to the method, the characteristic wavelength which contributes greatly to internal quality detection is selected, and samples which deviate greatly from the mean value of the normal fruit sample set and the mean value of the imperfect fruit sample set are screened and removed, so that the data volume of a spectrum is effectively reduced, and a reference thought is provided for related work of internal quality nondestructive detection in the pear sorting process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of fruit and vegetable sorting technology, and more specifically, to a method for detecting the internal quality of pears based on characteristic wavelengths and sample screening. Background Technology

[0002] Pears contain a complex chemical composition. The overtones and combination frequencies of the same functional group can exhibit absorption peaks in multiple bands of the visible / near-infrared spectrum, and a single absorption peak can contain information about various chemical components within the pear. Commonly used spectroscopic analysis systems utilize light sources covering the entire visible / near-infrared spectrum. Illuminating a sample with this light source yields complete visible / near-infrared spectral information. However, this system generates a massive amount of data, including not only data related to the analyte but also redundant data. Considering that redundant spectral information is ineffective for data analysis, absorption wavelength information of the analyte can be sought based on full-band modeling. This modeling analysis can significantly reduce the number of variables in the model or enhance the robustness of the model, but it still cannot avoid using a complex system. For a specific analyte, the most relevant characteristic wavelength is first obtained. The interaction between the substance and light at the absorption peak of this characteristic wavelength is analyzed to obtain spectral reflectance information. Then, combined with mathematical analysis methods, the analyte is modeled and analyzed, enabling non-destructive testing of the parameter. The aforementioned method based on characteristic wavelength detection can effectively reduce the amount of spectral data and can also provide a basis for building a detection system based on characteristic wavelength through effective spectral information related to the detection parameters. Summary of the Invention

[0003] The technical problem to be solved by this invention is to provide a method for detecting the internal quality of pears based on characteristic wavelengths and sample selection. When using visible / near-infrared spectroscopy to detect a certain internal quality of pears, the method considers maximizing the difference between the mean of the normal fruit sample set and the mean of the defective fruit sample set for the selected characteristic wavelengths, while minimizing the variance of the normal and defective fruit sample sets. This allows for the selection of characteristic wavelengths that contribute significantly to the detection of that internal quality of the pears, while pear samples that deviate significantly from the mean of the normal and defective fruit sample sets are removed. This reduces the number of characteristic wavelengths with low correlation and the corresponding amount of spectral data when using characteristic wavelength detection, thereby enabling the detection of the internal quality of pears.

[0004] The technical solution adopted to solve the above-mentioned technical problems includes the following steps:

[0005] (1) When testing a certain internal quality of pears, the absorption peak data of each sample fruit in the normal fruit sample set and the defective fruit sample set are sampled at different characteristic wavelengths. The characteristic wavelength of pear internal quality detection and the sample fruit prediction model and its equivalent model are constructed.

[0006] (2) When the characteristic wavelength of the internal quality detection of pears is consistent with the sample fruit prediction model, obtain the absorption peak data adjustment coefficient of different sample fruits in the normal fruit sample set and the defective fruit sample set about a certain characteristic wavelength, and the weighting of a certain characteristic wavelength when detecting the internal quality of the pear.

[0007] (3) Give the screening value of the data adjustment coefficient of the absorption peak of different samples in the normal fruit sample update set and the defective fruit sample update set for a certain characteristic wavelength, and give the weighted screening value of a certain characteristic wavelength when detecting the internal quality of this item in the characteristic wavelength screening set.

[0008] (4) By constructing the detection probability of normal fruit in this internal quality item by the weighted screening value of different characteristic wavelengths when detecting this internal quality item and the membership function of the absorption peak data of normal fruit at a certain characteristic wavelength, the internal quality of pear is determined to be normal after the internal quality of this item is tested.

[0009] As a preferred technical solution, step (1) is specifically performed according to the following method:

[0010] When testing a certain internal quality of a pear, statistical reflectance data can be used to determine the reflectance in the visible / near-infrared spectrum. There is an absorption peak at each characteristic wavelength. This internal quality is considered normal. For each type of pear that is considered defective due to this internal quality issue, a normal fruit sample set is established. and defective fruit sample set Sampling Medium sample results At characteristic wavelength Absorption peak data at [location] and the Medium sample results At characteristic wavelength Absorption peak data at [location] Among them, the label of the characteristic wavelength satisfy The The label of the middle sample fruit satisfy The The label of the middle sample fruit satisfy ;set up For the Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. For the Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. For normal fruit sample set Regarding characteristic wavelengths The average value of the absorption peak data at the specified location is [value]. , For the defective fruit sample set Regarding characteristic wavelengths The average value of the absorption peak data at the specified location is [value]. , The characteristic wavelength for detecting this internal quality The weighting, with , and Using the mean of the normal fruit sample set and the mean of the defective fruit sample set under different characteristic wavelengths as the independent variable, and aiming to maximize the weighted square of the difference between the mean of the normal fruit sample set and the mean of the defective fruit sample set under different characteristic wavelengths, a predictive model for the characteristic wavelengths of pear internal quality detection and sample fruit is constructed. for:

[0011] max { F ( w k , α i , k , β j , k ) = ∑ k = 1 K w k 2 [ ( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] }

[0012] The weighted sum of different characteristic wavelengths should satisfy the normalization condition. Under the same characteristic wavelength condition, the The adjustment coefficients for all fruits should meet the normalization conditions. And the set of residual results under the same characteristic wavelength conditions The adjustment coefficients for all fruits should meet the normalization conditions. ;set up , and All are Lagrange multipliers, which can be obtained through the aforementioned , and The corresponding normalization conditions are respectively , and An equivalent model of the pear internal quality detection characteristic wavelength and sample fruit prediction model is constructed by introducing the model. for:

[0013] max { G ( w k , α i , k , β j , k ) = ∑ k = 1 K w k 2 [ ( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] − p ( ∑ k = 1 K w k − 1 ) + s ( ∑ i = 1 I α i , k − 1 ) + t ( ∑ j = 1 J β j , k − 1 ) }

[0014] As a preferred technical solution, step (2) is specifically performed according to the following steps:

[0015] (2a) The steps described in step (1) For the steps described in (1) Taking the first and second derivatives respectively, we can obtain:

[0016] ∂ G ( w k , α i , k , β j , k ) ∂ w k = 2 w k [( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] − p ∂ 2 G ( w k , α i , k , β j , k ) ∂ w k 2 = 2 [( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ]

[0017] (2b) The above For the steps described in (1) Taking the first and second derivatives respectively, we can obtain:

[0018]

[0019]

[0020] (2c) The above For the steps described in (1) Taking the first and second derivatives respectively, we can obtain:

[0021]

[0022]

[0023] (2d) When for the above exist When taking values ​​within an interval, for the above exist and If the above satisfy Then it satisfies Less than 0 and Under the given conditions, at this point, a judgment is made. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true.

[0024] At this time The above can be given Regarding the Lagrange multiplier The expression with the independent variable:

[0025] w k = p 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ]

[0026] Then by constraints The steps described in step (1) can be given. The expression:

[0027] p = { ∑ k = 1 K 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] } − 1

[0028] Therefore, the first preset formula can be used to obtain the... The statement at the time of establishment The first preset formula is:

[0029] w k = 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] ∑ k = 1 K 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ]

[0030] (2e) As described in step (2b) The value is 0. Normalization conditions Later can be obtained s = [ ∑ i = 1 I I 2 w k 2 ( x i , k − x k ¯ ) 2 ] − 1 ; due to the Clearly less than 0, when the stated When it is 0, then we judge. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true;

[0031] Therefore, the second preset formula can be used to obtain the... The statement at the time of establishment The second preset formula is:

[0032]

[0033] (2f) As described in step (2c) The value is 0. Normalization conditions Later can be obtained t = [ ∑ j = 1 J J 2 w k 2 ( y j , k − y k ¯ ) 2 ] − 1 The If it is significantly less than 0, then when the stated When it is 0, then we judge. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true;

[0034] Therefore, the third preset formula can be used to obtain the... The statement at the time of establishment The third preset formula is as follows:

[0035]

[0036] As a preferred technical solution, step (3) is specifically performed according to the following steps:

[0037] (3a) Let For the number of iterations, and They represent the number of iterations. The time mentioned Medium sample results and stated Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. Number of iterations When testing the internal quality of this item, the characteristic wavelength is... The weighting will affect the number of iterations. When it is 0, the characteristic wavelength Weighted The value is set to The obtained in step (1) and and the As Substitute into the second preset formula and output As The obtained in step (1) and and the As Substitute into the third preset formula and output As ;

[0038] (3b) will Add 1, and the value obtained in step (1) , , and And through and As respectively and Substitute into the first preset formula and output As Then the above As Substitute into the second and third preset formulas and output and As respectively and ;

[0039] (3c) Calculate the number of iterations Time-weighted change status d t = ∑ k = 1 K [ w k ( t ) − w k ( t − 1 ) ] 4 If the above Greater than or equal to the weighted change threshold Then proceed to step (3b); otherwise proceed to step (3d).

[0040] (3d) Weighted from the current different characteristic wavelengths Select several characteristic wavelengths from largest to smallest to form the filter set. Thus, the above can be made Weighted sum of different characteristic wavelengths in Greater than or equal to the characteristic wavelength weighting threshold , and then middle corresponding Updated to At the same time middle corresponding Updated to 0; the above updated version As Substitute into the second and third preset formulas and output and These are respectively used as the current iteration number. Updated and Then from the above Select one that is greater than or equal to the normal fruit adjustment coefficient threshold. To establish a set of normal fruit adjustment coefficients and from the above Select one of the threshold values ​​that is greater than or equal to the defective fruit adjustment coefficient. To establish a set of adjustment coefficients for defective fruits ;

[0041] (3e) middle corresponding If it belongs to step (3d) Then the above Still remain as described above In the middle, the said middle corresponding If it does not fall under the category described in step (3d) Then the above From the above Removed from the middle, among which After completing the above operations, the above As a normal fruit sample update set Similarly, the aforementioned middle corresponding If it belongs to step (3d) Then the above Still remain as described above In the middle, the said middle corresponding If it does not fall under the category described in step (3d) Then the above From the above Removed from the middle, among which After completing the above operations, the above Update the sample set of defective fruits ; Let the above Medium sample results Regarding characteristic wavelengths Screening value of the absorption peak data adjustment coefficient at the location for Similarly, let the above be... Medium sample results Regarding characteristic wavelengths Screening value of the absorption peak data adjustment coefficient at the location for ;

[0042] (3f) Set up the normal fruit sample update set Regarding wavelength Average value of absorption peak data at ... and the updated set of defective fruit samples Regarding wavelength Average value of absorption peak data at ... ,in To be a function that takes the number of elements in a set, the function described in (3e) is... and As and and the above and As and Substitute into the first preset formula and output As a characteristic wavelength when testing this internal quality. Weighted filter value ;

[0043] As a preferred technical solution, step (4) is specifically performed according to the following method:

[0044] For a certain pear that needs to be tested for its internal quality... It can detect information about characteristic wavelengths. Absorption peak data at [location] ,in When the characteristic wavelength The reflectance of defective fruit is higher than that of normal fruit. This can be addressed by using the fourth preset formula to construct the characteristic wavelength of normal fruit. The membership function of the absorption peak data at the specified location, wherein the fourth preset formula is:

[0045]

[0046] in, For the characteristic wavelength Membership change index of absorption peak data;

[0047] When the characteristic wavelength The reflectance of normal fruit is higher than that of defective fruit. This can be achieved by using the fifth preset formula to construct the characteristic wavelength of normal fruit. The membership function of the absorption peak data at the specified location, wherein the fifth preset formula is:

[0048]

[0049] The The probability of being detected as a normal fruit in terms of this internal quality can be set as follows: If it is greater than or equal to the threshold for normal internal quality fruit If the internal quality of the pear is tested, it can be considered a normal fruit; otherwise, it is considered a defective fruit. Attached Figure Description

[0050] Figure 1 A schematic flowchart illustrating a method for detecting the internal quality of pears based on characteristic wavelengths and sample screening, provided in an embodiment of this disclosure;

[0051] Figure 2 Weighted average of different characteristic wavelengths in the embodiments of this disclosure Numerical value;

[0052] Figure 3 This is the membership function of the absorption peak data of normal fruit at different characteristic wavelengths in the embodiments of this disclosure. Numerical value. Detailed Implementation

[0053] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments, but the present invention is not limited to the specific embodiments described below.

[0054] like Figure 1 The diagram shown is a flowchart of a method for detecting the internal quality of pears based on characteristic wavelengths and sample screening in this embodiment. Taking the detection of whether there is an infectious disease in Fengshui pears as an example, the method consists of the following steps:

[0055] (1) When testing a certain internal quality of pears, the absorption peak data of each sample fruit in the normal fruit sample set and the defective fruit sample set are sampled at different characteristic wavelengths. The characteristic wavelength of pear internal quality detection and the prediction model of sample fruit and its equivalent model are constructed as follows:

[0056] When testing for the presence of infectious diseases in Fengshui pears, considering that the main characteristic wavelengths related to internal quality such as soluble solids content are concentrated in the wavelength ranges of 465-497nm, 513-547nm, 561-599nm, 608-647nm, 680-710nm, 743-780nm, 790-820nm, 840-889nm, 900-936nm, and 944-965nm, the absorbance peaks can be selected from the reflectance data obtained by preprocessing the original spectral signal. Characteristic wavelengths in the visible / near-infrared spectrum, This internal quality is considered normal. For each type of pear that is considered defective due to this internal quality issue, a normal fruit sample set is established. and defective fruit sample set Sampling Medium sample results At characteristic wavelength Absorption peak data at [location] and the Medium sample results At characteristic wavelength Absorption peak data at [location] Among them, the label of the characteristic wavelength satisfy The The label of the middle sample fruit satisfy The The label of the middle sample fruit satisfy ;set up For the Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. For the Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. For normal fruit sample set Regarding characteristic wavelengths The average value of the absorption peak data at the specified location is [value]. , For the defective fruit sample set Regarding characteristic wavelengths The average value of the absorption peak data at the specified location is [value]. , The characteristic wavelength for detecting this internal quality The weighting, with , and Using the mean of the normal fruit sample set and the mean of the defective fruit sample set under different characteristic wavelengths as the independent variable, and aiming to maximize the weighted square of the difference between the mean of the normal fruit sample set and the mean of the defective fruit sample set under different characteristic wavelengths, a predictive model for the characteristic wavelengths of pear internal quality detection and sample fruit is constructed. for:

[0057] max { F ( w k , α i , k , β j , k ) = ∑ k = 1 K w k 2 [ ( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] }

[0058] The weighted sum of different characteristic wavelengths should satisfy the normalization condition. Under the same characteristic wavelength condition, the The adjustment coefficients for all fruits should meet the normalization conditions. And the set of residual results under the same characteristic wavelength conditions The adjustment coefficients for all fruits should meet the normalization conditions. ;set up , and All are Lagrange multipliers, which can be obtained through the aforementioned , and The corresponding normalization conditions are respectively , and An equivalent model of the pear internal quality detection characteristic wavelength and sample fruit prediction model is constructed by introducing the model. for:

[0059] max { G ( w k , α i , k , β j , k ) = ∑ k = 1 K w k 2 [ ( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] − p ( ∑ k = 1 K w k − 1 ) + s ( ∑ i = 1 I α i , k − 1 ) + t ( ∑ j = 1 J β j , k − 1 ) }

[0060] (2) When the characteristic wavelength for internal quality detection of pears is consistent with the sample fruit prediction model, obtain the absorption peak data adjustment coefficients of different sample fruits in the normal fruit sample set and the defective fruit sample set regarding a certain characteristic wavelength, as well as the weighting of a certain characteristic wavelength when detecting the internal quality of the pear, as follows:

[0061] (2a) The steps described in step (1) For the steps described in (1) Taking the first and second derivatives respectively, we can obtain:

[0062] ∂ G ( w k , α i , k , β j , k ) ∂ w k = 2 w k [( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] − p ∂ 2 G ( w k , α i , k , β j , k ) ∂ w k 2 = 2 [( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ]

[0063] (2b) The above For the steps described in (1) Taking the first and second derivatives respectively, we can obtain:

[0064]

[0065]

[0066] (2c) The above For the steps described in (1) Taking the first and second derivatives respectively, we can obtain:

[0067]

[0068]

[0069] (2d) When for the above exist When taking values ​​within an interval, for the above exist and If the above satisfy Then it satisfies Less than 0 and Under the given conditions, at this point, a judgment is made. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true.

[0070] At this time The above can be given Regarding the Lagrange multiplier The expression with the independent variable:

[0071] w k = p 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ]

[0072] Then by constraints The steps described in step (1) can be given. The expression:

[0073] p = { ∑ k = 1 K 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] } − 1

[0074] Therefore, the first preset formula can be used to obtain the... The statement at the time of establishment The first preset formula is:

[0075] w k = 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] ∑ k = 1 K 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ]

[0076] (2e) As described in step (2b) The value is 0. Normalization conditions Later can be obtained s = [ ∑ i = 1 I I 2 w k 2 ( x i , k − x k ¯ ) 2 ] − 1 ; due to the Clearly less than 0, when the stated When it is 0, then we judge. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true;

[0077] Therefore, the second preset formula can be used to obtain the... The statement at the time of establishment The second preset formula is:

[0078]

[0079] (2f) As described in step (2c) The value is 0. Normalization conditions Later can be obtained t = [ ∑ j = 1 J J 2 w k 2 ( y j , k − y k ¯ ) 2 ] − 1 The If it is significantly less than 0, then when the stated When it is 0, then we judge. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true;

[0080] Therefore, the third preset formula can be used to obtain the... The statement at the time of establishment The third preset formula is as follows:

[0081]

[0082] (3) Provide the screening values ​​of the absorption peak data adjustment coefficients of different samples in the normal fruit sample update set and the defective fruit sample update set for a certain characteristic wavelength, and provide the weighted screening values ​​of a certain characteristic wavelength in the characteristic wavelength screening set when detecting the internal quality of this item, as follows:

[0083] (3a) Let For the number of iterations, and They represent the number of iterations. The time mentioned Medium sample results and stated Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. Number of iterations When testing the internal quality of this item, the characteristic wavelength is... The weighting will affect the number of iterations. When it is 0, the characteristic wavelength Weighted The value is set to The obtained in step (1) and and the As Substitute into the second preset formula and output As The obtained in step (1) and and the As Substitute into the third preset formula and output As ;

[0084] (3b) will Add 1, and the value obtained in step (1) , , and And through and As respectively and Substitute into the first preset formula and output As Then the above As Substitute into the second and third preset formulas and output and As respectively and ;

[0085] (3c) Calculate the number of iterations Time-weighted change status d t = ∑ k = 1 K [ w k ( t ) − w k ( t − 1 ) ] 4 Set weighted change threshold If the above Greater than or equal to Then proceed to step (3b); otherwise proceed to step (3d).

[0086] (3d) Let Figure 3 From left to right, the images show weighted averages of different characteristic wavelengths: 472nm, 630nm, 700nm, 760nm, 810nm, 860nm, 910nm, and 950nm. From largest to smallest, several characteristic wavelengths can be selected to form the selection set. Thus, the above can be made Weighted sum of different characteristic wavelengths in Greater than or equal to the characteristic wavelength weighting threshold , wherein Therefore, the above It can include five characteristic wavelengths: 472nm, 630nm, 760nm, 810nm, and 950nm, and then... middle corresponding Updated to At the same time middle corresponding Updated to 0; the above updated version As Substitute into the second and third preset formulas and output and These are respectively used as the current iteration number. Updated and Then from the above Select one that is greater than or equal to the normal fruit adjustment coefficient threshold. To establish a set of normal fruit adjustment coefficients and from the above Select one of the threshold values ​​that is greater than or equal to the defective fruit adjustment coefficient. To establish a set of adjustment coefficients for defective fruits , wherein and stated All set to ;

[0087] (3e) middle corresponding If it belongs to step (3d) Then the above Still remain as described above In the middle, the said middle corresponding If it does not fall under the category described in step (3d) Then the above From the above Removed from the middle, among which After completing the above operations, the above As a normal fruit sample update set Similarly, the aforementioned middle corresponding If it belongs to step (3d) Then the above Still remain as described above In the middle, the said middle corresponding If it does not fall under the category described in step (3d) Then the above From the above Removed from the middle, among which After completing the above operations, the above Update the sample set of defective fruits ; Let the above Medium sample results Regarding characteristic wavelengths Screening value of the absorption peak data adjustment coefficient at the location for Similarly, let the above be... Medium sample results Regarding characteristic wavelengths Screening value of the absorption peak data adjustment coefficient at the location for ;

[0088] (3f) Set up the normal fruit sample update set Regarding wavelength Average value of absorption peak data at ... and the updated set of defective fruit samples Regarding wavelength Average value of absorption peak data at ... ,in For the function that takes the number of elements in a set, we know that The (3e) mentioned and As and and the above and As and Substitute into the first preset formula and output As a characteristic wavelength when testing this internal quality. Weighted filter value This corresponds to five characteristic wavelengths: 472nm, 630nm, 760nm, 810nm, and 950nm.

[0089] (4) By constructing the membership function of the weighted screening value of different characteristic wavelengths when detecting this internal quality and the absorption peak data of normal fruit at a certain characteristic wavelength, the detection probability of normal fruit in this internal quality is constructed. Thus, after detecting the internal quality of pears in this internal quality, it is determined whether the fruit is normal, as follows:

[0090] For a certain Fengshui pear variety that requires testing for the presence of infectious diseases as an internal quality criterion. It can detect information about characteristic wavelengths. Absorption peak data at [location] ,in When the characteristic wavelength The reflectance of defective fruit is higher than that of normal fruit. This can be addressed by using the fourth preset formula to construct the characteristic wavelength of normal fruit. The membership function of the absorption peak data at the specified location, wherein the fourth preset formula is:

[0091]

[0092] in, For the characteristic wavelength Membership change index of absorption peak data;

[0093] When the characteristic wavelength The reflectance of normal fruit is higher than that of defective fruit. This can be achieved by using the fifth preset formula to construct the characteristic wavelength of normal fruit. The membership function of the absorption peak data at the specified location, wherein the fifth preset formula is:

[0094]

[0095] Suppose we detect absorption peak data at the above 5 characteristic wavelengths. The result can be calculated using the fourth or fifth preset formula. Figure 3 The result shown is a normal result with respect to wavelength. Membership function of absorption peak data at ... Numerical value; thus described The probability of being detected as a normal fruit in terms of this internal quality. The value can be calculated to be 0.9871; set the threshold for normal internal quality fruit. As can be seen from the above The probability of being detected as a normal fruit in terms of this internal quality is greater than or equal to the stated value. If the pear is found to have an internal quality test to determine whether it has any infectious diseases, it can be considered a normal fruit.

[0096] It should be understood that those skilled in the art can make improvements based on the above description, and all such improvements should fall within the protection scope of the appended claims.

Claims

1. A method for detecting the internal quality of pears based on characteristic wavelengths and sample screening, characterized in that, Specifically, the following steps should be followed: (1) When testing a certain internal quality of pears, the absorption peak data of each sample fruit in the normal fruit sample set and the defective fruit sample set are sampled at different characteristic wavelengths. The characteristic wavelength of pear internal quality detection and the sample fruit prediction model and its equivalent model are constructed. (2) When the characteristic wavelength of the internal quality detection of pears is consistent with the sample fruit prediction model, obtain the absorption peak data adjustment coefficient of different sample fruits in the normal fruit sample set and the defective fruit sample set about a certain characteristic wavelength, and the weighting of a certain characteristic wavelength when detecting the internal quality of the pear. (3) Give the screening value of the data adjustment coefficient of the absorption peak of different samples in the normal fruit sample update set and the defective fruit sample update set for a certain characteristic wavelength, and give the weighted screening value of a certain characteristic wavelength when detecting the internal quality of this item in the characteristic wavelength screening set. (4) By constructing the detection probability of normal fruit in this internal quality item by the weighted screening value of different characteristic wavelengths when detecting this internal quality item and the membership function of the absorption peak data of normal fruit at a certain characteristic wavelength, the internal quality of pear is determined to be normal fruit after the internal quality of this item is tested.

2. The method for detecting the internal quality of pears based on characteristic wavelength and sample screening according to claim 1, characterized in that, The specific steps (1) are as follows: When testing a certain internal quality of a pear, statistical reflectance data can be used to determine the reflectance in the visible / near-infrared spectrum. There is an absorption peak at each characteristic wavelength. This internal quality is considered normal. For each type of pear that is considered defective due to this internal quality issue, a normal fruit sample set is established. and defective fruit sample set Sampling Medium sample results At characteristic wavelength Absorption peak data at [location] and the Medium sample results At characteristic wavelength Absorption peak data at [location] Among them, the label of the characteristic wavelength satisfy The The label of the middle sample fruit satisfy The The label of the middle sample fruit satisfy ;set up For the Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. For the Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. For normal fruit sample set Regarding characteristic wavelengths The average value of the absorption peak data at the specified location is [value]. , For the defective fruit sample set Regarding characteristic wavelengths The average value of the absorption peak data at the specified location is [value]. , The characteristic wavelength for detecting this internal quality The weighting, with , and Using the mean of the normal fruit sample set and the mean of the defective fruit sample set under different characteristic wavelengths as the independent variable, and aiming to maximize the weighted square of the difference between the mean of the normal fruit sample set and the mean of the defective fruit sample set under different characteristic wavelengths, a predictive model for the characteristic wavelengths of pear internal quality detection and sample fruit is constructed. for: max { F ( w k , α i , k , β j , k ) = ∑ k = 1 K w k 2 [ ( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] } The weighted sum of different characteristic wavelengths should satisfy the normalization condition. Under the same characteristic wavelength condition, the The adjustment coefficients for all fruits should meet the normalization conditions. And the set of residual results under the same characteristic wavelength conditions The adjustment coefficients for all fruits should meet the normalization conditions. ;set up , and All are Lagrange multipliers, which can be obtained through the aforementioned , and The corresponding normalization conditions are respectively , and An equivalent model of the pear internal quality detection characteristic wavelength and sample fruit prediction model is constructed by introducing the model. for: max { G ( w k , α i , k , β j , k ) = ∑ k = 1 K w k 2 [ ( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] − ρ ( ∑ k = 1 K w k − 1 ) + σ ( ∑ i = 1 I α i , k − 1 ) + τ ( ∑ j = 1 J β j , k − 1 ) } 3. The method for detecting the internal quality of pears based on characteristic wavelength and sample screening according to claim 1, characterized in that, Step (2) is as follows: (2a) The steps described in step (1) For the steps described in (1) Taking the first and second derivatives respectively, we can obtain: ∂ G ( w k , α i , k , β j , k ) ∂ w k = 2 w k [( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] − ρ ∂ 2 G ( w k , α i , k , β j , k ) ∂ w k 2 = 2 [( x k ¯ − y k ¯ ) 2 − 1 I ∑ i = 1 I α i , k 2 ( x i , k − x k ¯ ) 2 − 1 J ∑ j = 1 J β j , k 2 ( y j , k − y k ¯ ) 2 ] (2b) The above For the steps described in (1) Taking the first and second derivatives respectively, we can obtain: (2c) The above For the steps described in (1) Taking the first and second derivatives respectively, we can obtain: (2d) When for the above exist When taking values ​​within an interval, for the above exist and If the above satisfy Then it satisfies Less than 0 and Under the given conditions, at this point, a judgment is made. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true. At this time, by The above can be given Regarding the Lagrange multiplier The expression with the independent variable: w k = ρ 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] Then by constraints The steps described in step (1) can be given. The expression: ρ = { ∑ k = 1 K 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] } − 1 Therefore, the first preset formula can be used to obtain the... The statement at the time of establishment The first preset formula is: w k = 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] ∑ k = 1 K 1 2 [( x k ¯ − y k ¯ ) 2 − ∑ i = 1 I α i , k 2 I ( x i , k − x k ¯ ) 2 − ∑ j = 1 J β j , k 2 J ( y j , k − y k ¯ ) 2 ] (2e) As described in step (2b) The value is 0. Normalization conditions Later can be obtained σ = [ ∑ i = 1 I I 2 w k 2 ( x i , k − x k ¯ ) 2 ] − 1 ; due to the Clearly less than 0, when the stated When it is 0, then we judge. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true; Therefore, the second preset formula can be used to obtain the... The statement at the time of establishment The second preset formula is: (2f) As described in step (2c) The value is 0. Normalization conditions Later can be obtained τ = [ ∑ j = 1 J J 2 w k 2 ( y j , k − y k ¯ ) 2 ] − 1 The If it is significantly less than 0, then when the stated When it is 0, then we judge. This allows the steps described in (1) to be performed. This establishes the condition, thereby enabling the step (1) described above. It also holds true; Therefore, the third preset formula can be used to obtain the... The statement at the time of establishment The third preset formula is as follows:

4. The method for detecting the internal quality of pears based on characteristic wavelength and sample screening according to claim 1, characterized in that, The specific steps (3) are as follows: (3a) Let For the number of iterations, and They represent the number of iterations. The time mentioned Medium sample results and stated Medium sample results Regarding characteristic wavelengths The adjustment coefficient for the absorption peak data at that location. Number of iterations When testing the internal quality of this item, the characteristic wavelength is... The weighting will affect the number of iterations. When it is 0, the characteristic wavelength Weighted The value is set to The obtained in step (1) and and the As Substitute into the second preset formula and output As The obtained in step (1) and and the As Substitute into the third preset formula and output As ; (3b) will Add 1, and the value obtained in step (1) , , and And through and As respectively and Substitute into the first preset formula and output As Then the above As Substitute into the second and third preset formulas and output and As respectively and ; (3c) Calculate the number of iterations Time-weighted change status δ t = ∑ k = 1 K [ w k ( t ) − w k ( t − 1 ) ] 4 If the above Greater than or equal to the weighted change threshold Then proceed to step (3b); otherwise proceed to step (3d). (3d) Weighted from the current different characteristic wavelengths Select several characteristic wavelengths from largest to smallest to form the filter set. Thus, the above can be made Weighted sum of different characteristic wavelengths in Greater than or equal to the characteristic wavelength weighting threshold , and then middle corresponding Updated to At the same time middle corresponding Updated to 0; the above updated version As Substitute into the second and third preset formulas and output and These are respectively used as the current iteration number. Updated and Then from the above Select one that is greater than or equal to the normal fruit adjustment coefficient threshold. To establish a set of normal fruit adjustment coefficients and from the above Select one of the threshold values ​​that is greater than or equal to the defective fruit adjustment coefficient. To establish a set of adjustment coefficients for defective fruits ; (3e) middle corresponding If it belongs to step (3d) Then the above Still remain as described above In the middle, the said middle corresponding If it does not fall under the category described in step (3d) Then the above From the above Removed from the middle, among which After completing the above operations, the above As a normal fruit sample update set Similarly, the aforementioned middle corresponding If it belongs to step (3d) Then the above Still remain as described above In the middle, the said middle corresponding If it does not fall under the category described in step (3d) Then the above From the above Removed from the middle, among which After completing the above operations, the above Update the sample set of defective fruits ; Let the above Medium sample results Regarding characteristic wavelengths Screening value of the absorption peak data adjustment coefficient at the location for Similarly, let the above be... Medium sample results Regarding characteristic wavelengths Screening value of the absorption peak data adjustment coefficient at the location for ; (3f) Set up the normal fruit sample update set Regarding wavelength Average value of absorption peak data at ... and the updated set of defective fruit samples Regarding wavelength Average value of absorption peak data at ... ,in To be a function that takes the number of elements in a set, the function described in (3e) is... and As and and the above and As and Substitute into the first preset formula and output As a characteristic wavelength when testing this internal quality. Weighted filter value .

5. The method for detecting the internal quality of pears based on characteristic wavelength and sample screening according to claim 1, characterized in that, The specific steps (4) are as follows: For a certain pear that needs to be tested for its internal quality... It can detect information about characteristic wavelengths. Absorption peak data at [location] ,in ; When the characteristic wavelength The reflectance of defective fruit is higher than that of normal fruit. This can be addressed by using the fourth preset formula to construct the characteristic wavelength of normal fruit. The membership function of the absorption peak data at the specified location, wherein the fourth preset formula is: in, For the characteristic wavelength Membership change index of absorption peak data; When the characteristic wavelength The reflectance of normal fruit is higher than that of defective fruit. This can be achieved by using the fifth preset formula to construct the characteristic wavelength of normal fruit. The membership function of the absorption peak data at the specified location, wherein the fifth preset formula is: The The probability of being detected as a normal fruit in terms of this internal quality can be set as follows: If it is greater than or equal to the threshold for normal internal quality fruit If the internal quality of the pear is tested, it can be considered a normal fruit; otherwise, it is considered a defective fruit.