Fruit quality detection and evaluation method, device, medium and equipment
By constructing radar maps and calculating the graph area, the problem of single-dimensionality in traditional fruit quality detection methods is solved, the accuracy and comprehensiveness of the detection results are improved, and the modern market needs for accurate grading and standardization of fruit quality are met.
Patent Information
- Application Number
- CN202510064449.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-15
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2045-01-15
AI Technical Summary
The traditional fruit quality testing method has a single dimension that cannot comprehensively and comprehensively reflect the true quality status of fruits, and it is difficult to meet the modern market's demand for precise grading and standardization of fruit quality.
A fruit quality detection and evaluation method is adopted to obtain initial detection data and preset detection dimensions, filter target detection data, perform preset processing, build a radar map and calculate the graph area to determine the mass score.
The accuracy of fruit quality detection results is improved, and through reasonable basic parameter setting and irrelevant data removal, the radar chart can accurately reflect the relationship between the quality dimensions of the fruit and the quality score.
Smart Images

Figure CN119991595A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of agricultural product quality safety standards, and in particular to a fruit quality detection and evaluation method, device, medium and equipment. Background Art
[0002] As consumers' requirements for fruit quality continue to increase and market competition becomes increasingly fierce, accurate testing of fruit quality is of vital importance in all aspects of fruit production, sales and consumption.
[0003] Traditional fruit quality testing methods often focus on a single dimension, such as only paying attention to whether there are obvious flaws in the appearance of the fruit, or simply testing whether there are some common safety issues, such as excessive pesticide residues. This single-dimensional testing method cannot fully and comprehensively reflect the true quality of the fruit, which can easily lead to some potential quality problems being ignored, and it is difficult to meet the modern market's demand for accurate grading and standardization of fruit quality.
[0004] Therefore, how to improve the accuracy of fruit quality inspection and evaluation results has become an urgent problem to be solved. Summary of the invention
[0005] In view of the above technical problems, the technical solution adopted by the present invention is a method for detecting and evaluating the quality of fruits, which comprises the following steps:
[0006] S1, obtain the initial detection data corresponding to the target fruit, N preset detection dimensions, and the preset arrangement angle and preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, M and N are integers greater than 0 and M≥N.
[0007] S2, according to the preset detection dimension, filter out the target detection data corresponding to the target fruit from the initial detection data, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data.
[0008] S3, performing preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data.
[0009] S4, obtaining safety detection results corresponding to the target fruit according to the reference safety detection data, wherein the safety detection results include safe and unsafe.
[0010] S5, if the safety detection result is unsafe, the preset score is determined as the target quality score corresponding to the target fruit.
[0011] S6. If the safety detection result is safe, a radar chart corresponding to the target fruit is obtained according to the preset sorting angle, preset arrangement order and reference detection data corresponding to each predicted detection dimension, wherein the dimensions corresponding to the N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data.
[0012] S7, calculating the target graphic area of the radar chart, and determining the target graphic area as the target quality score corresponding to the target fruit.
[0013] The present invention also provides a fruit quality detection and evaluation device, the fruit quality detection and evaluation device comprising:
[0014] The data acquisition module is used to obtain the initial detection data corresponding to the target fruit, N preset detection dimensions, and the preset arrangement angle and preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, M and N are integers greater than 0 and M≥N.
[0015] The data screening module is used to screen the target detection data corresponding to the target fruit from the initial detection data according to the preset detection dimension, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data.
[0016] The data processing module is used to perform preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data.
[0017] The safety detection module is used to obtain the safety detection results corresponding to the target fruit according to the reference safety detection data, wherein the safety detection results include safe and unsafe.
[0018] The first quality detection module is used to determine a preset score as a target quality score corresponding to the target fruit if the safety detection result is unsafe.
[0019] The radar chart construction module is used to obtain the radar chart corresponding to the target fruit according to the preset sorting angle, preset arrangement order and reference detection data corresponding to each predicted detection dimension if the safety detection result is safe, wherein the dimensions corresponding to the N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data.
[0020] The second quality detection module is used to calculate the target graphic area of the radar chart and determine the target graphic area as the target quality score corresponding to the target fruit.
[0021] The present invention also provides a non-transitory computer-readable storage medium, in which at least one instruction or at least one program is stored, and the at least one instruction or at least one program is loaded and executed by a processor to implement the above-mentioned fruit quality detection and evaluation method.
[0022] The present invention also provides an electronic device, comprising a processor and the above-mentioned non-transitory computer-readable storage medium.
[0023] The present invention has at least the following beneficial effects: by obtaining the preset arrangement order and preset arrangement angle of each preset detection dimension of the target fruit, a reasonable and well-founded basic parameter setting is provided for the subsequent construction of a radar chart and the quality detection of the target fruit; by removing information that is not highly correlated with the core evaluation of the quality of the target fruit, interference of irrelevant data on the quality detection result is avoided; by clarifying the dimensions corresponding to the coordinate axes, the angles between adjacent coordinate axes, and the data points on the coordinate axes, a radar chart that can accurately display the quality of the target fruit is constructed, ensuring that the radar chart meets the correlation and importance of the dimensions in terms of position distribution and angle layout, so that the shape, angle and value of the entire radar chart can reasonably reflect the relationship between the preset detection dimensions of the target fruit and the quality score, making the method of characterizing the quality according to the area of the graph more accurate and orderly, thereby improving the accuracy of the quality detection result. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0025] Figure 1 A flow chart of a method for detecting and evaluating fruit quality provided in Embodiment 1 of the present invention;
[0026] Figure 2 This is a structural schematic diagram of a fruit quality detection and evaluation device provided in Embodiment 2 of the present invention. DETAILED DESCRIPTION
[0027] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0028] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It is understood that, where appropriate, the above-mentioned terms used to distinguish similar objects can be interchanged so that the present invention can also implement other embodiments other than the above-mentioned illustrated embodiments or described embodiments. In addition, the terms "including" and "having" and any variations are intended to cover non-exclusive inclusions. For example, a process, method, system, product or server that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0029] Embodiment 1
[0030] This embodiment 1 provides a method for detecting and evaluating the quality of fruits, and the method for detecting and evaluating the quality of fruits includes the following steps: Figure 1 As shown:
[0031] S1, obtain the initial detection data corresponding to the target fruit, N preset detection dimensions, and the preset arrangement angle and preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, M and N are integers greater than 0 and M≥N.
[0032] Among them, the target fruit can be various categories of fruits. Improving the random sampling of a large number of fruits and taking each sampled fruit as a target fruit for quality inspection is of great significance in optimizing fruit planting technology, maintaining market order, and protecting consumer health.
[0033] The initial detection data includes data corresponding to M initial detection dimensions. The initial detection data is various original information about the target fruit collected at the beginning, which may come from various detection instruments, manual observation records, etc.
[0034] The preset safety testing dimensions mainly focus on the safety of fruit consumption, which may include pesticide residues, harmful microbial contamination content, mycotoxin content, heavy metal content and other dimensions. The test results of the preset safety testing dimensions are directly related to whether the fruit can enter the market safely. The preset quality testing dimensions mainly focus on the quality-related dimensions that affect the taste and nutritional value of the fruit, which may include sweetness, acidity, soluble solids content, titratable acid, vitamin C and other dimensions. The preset appearance testing dimensions mainly focus on the external form, color and other intuitive and visible features of the fruit, which may include whether the shape is regular, whether the skin is damaged, and whether the color is bright and uniform. The preset quality testing dimensions and preset appearance testing dimensions help to measure the quality of the fruit and meet the requirements of different consumers for the quality of the fruit.
[0035] Different types of fruits have their own unique biological characteristics, growth environment requirements, consumer market demands, and common quality problems. Therefore, different types of fruits need to focus on different dimensional data when conducting quality inspections. For example, berry fruits such as strawberries and blueberries have thin skins, high water content, and short shelf life. Microorganisms can easily grow on their surfaces and quickly affect the quality and safety of the fruit. Therefore, in the preset safety inspection dimension, in addition to conventional pesticide residue testing, more emphasis is placed on detecting microbial contamination such as mold. From the perspective of the preset quality inspection dimension, the sweetness, acidity, and hardness of berry fruits affect the taste and storage properties more, while the browning and stone cell content of stone fruits such as apples and pears affect the delicateness of the taste. From the perspective of appearance inspection, the color and smoothness of the peel of citrus fruits are related to the maturity and storage conditions of the fruit, while the black spots on banana peels are related to the maturity and storage conditions of the fruit.
[0036] Therefore, we first collect initial inspection data related to appearance, internal quality and safety in a unified manner. There is no need to customize different data acquisition starting points for each fruit, which greatly enhances the applicability of the data acquisition method in the entire fruit category. Subsequently, we extract the inspection data that is truly needed for the target fruit through screening, reducing repeated inspection actions, saving time and labor costs, and thus improving the efficiency of overall quality inspection.
[0037] The preset arrangement angle is used to determine the angular distribution of each preset detection dimension in the graph when the radar chart is subsequently constructed. The preset arrangement order is used to determine the positional distribution of each preset detection dimension in the graph when the radar chart is subsequently constructed, so that data of different dimensions have a reasonable and clear spatial layout in the radar chart.
[0038] As mentioned above, by using the data of similar reference fruits to conduct in-depth correlation analysis, the preset arrangement order and preset arrangement angle of the preset detection dimensions are scientifically determined, which provides a reasonable and well-founded basic parameter setting for the subsequent quality inspection process of target fruits, and helps to evaluate the quality of fruits more accurately, comprehensively and intuitively.
[0039] In a specific implementation, S1 includes the following steps:
[0040] S11, obtaining K reference fruits belonging to the same category as the target fruit, reference detection data corresponding to each reference fruit, and a target quality score, wherein K is an integer greater than 0.
[0041] S12, obtaining a quality score vector according to the target quality scores corresponding to K reference fruits, wherein the value of the t-th element in the quality score vector is the target quality score corresponding to the t-th reference fruit, t=1, 2, ..., K.
[0042] S13, for any preset detection dimension, according to the reference detection data corresponding to each reference fruit, obtain the detection data vector corresponding to the current preset detection dimension, wherein the value of the t-th element in the detection data vector corresponding to the current preset detection dimension is the data in the reference detection data corresponding to the t-th reference fruit relative to the current preset detection dimension.
[0043] S14, obtaining a first correlation degree between the current preset detection dimension and the target quality score according to the quality score vector and the detection data vector corresponding to the current preset detection dimension.
[0044] S15, obtaining a second correlation degree between the current preset detection dimension and any other preset detection dimension according to the detection data vectors corresponding to the current preset detection dimension and any other preset detection dimension.
[0045] S16, traversing N preset detection dimensions, obtaining a first correlation degree between each preset detection dimension and the target quality score, and a second correlation degree between any two preset detection dimensions.
[0046] S17, obtaining a preset arrangement order corresponding to each preset detection dimension according to a first priority corresponding to each preset detection dimension and a second correlation degree between each preset detection dimension and other preset detection dimensions.
[0047] S18, obtaining a preset arrangement angle corresponding to each preset detection dimension according to the preset arrangement order corresponding to each preset detection dimension, the first correlation degree corresponding to each preset detection dimension, and the second correlation degree between each preset detection dimension and other preset detection dimensions.
[0048] Among them, fruits of the same category have consistency and similarity in characteristics such as safety, quality and appearance. Taking the reference test data and target quality scores of reference fruits as the basis, the first correlation degree between each preset test dimension and the target quality score is analyzed to characterize the importance of each preset test dimension to the overall quality evaluation of the fruit. The second correlation degree between different preset test dimensions is analyzed to characterize the mutual influence, synergy and other correlation relationships between different preset test dimensions, and then the preset arrangement order and preset arrangement angle corresponding to each preset test dimension are obtained according to the correlation.
[0049] Specifically, the arrangement order is preset to avoid confusion in interpreting the quality meaning represented by the graphic area due to disordered arrangement of dimensions. Dimensions with high correlation are presented adjacent to each other on the radar chart, so that the area enclosed by adjacent dimensions can more accurately reflect the comprehensive situation that conforms to the actual quality correlation, thereby making the method of characterizing quality based on the graphic area more accurate and orderly.
[0050] The angles between adjacent dimensions in the radar chart determine the weight of each preset detection dimension in the entire graph. Correspondingly, the two preset detection dimensions with higher importance and stronger correlation to the overall quality evaluation of the fruit can be set at a relatively large angle on the radar chart, so that a larger effective area can be corresponded when the area is calculated, which is more in line with the synergistic relationship in the actual quality impact, so that the data of each dimension can participate in the comprehensive characterization of quality in a more accurate and fair manner, thereby improving the accuracy of judging quality based on area.
[0051] As described above, based on the first correlation degree between each preset detection dimension and the target quality score and the second correlation degree between different preset detection dimensions, the position order and angle corresponding to each dimension in the radar chart are obtained, and factors such as dimension importance, correlation and weight are fully considered to optimize the radar chart's representation of fruit quality, so that measuring the quality of the target fruit based on the area of the radar chart becomes more accurate, reliable, and more in line with the actual quality of the target fruit.
[0052] In a specific implementation, S17 includes the following steps:
[0053] S171, determining the preset detection dimension corresponding to the largest first priority as the first target detection dimension.
[0054] S172, initialize R=1.
[0055] S173, determining the Rth target detection dimension as the intermediate detection dimension, and determining other preset detection dimensions other than the 1st target detection dimension to the Rth target detection dimension as candidate detection dimensions.
[0056] S174, according to the second correlation degree between the intermediate detection dimension and each candidate detection dimension, determine the candidate detection dimension corresponding to the maximum second correlation degree corresponding to the intermediate detection dimension as the R+1th target detection dimension.
[0057] S175, update R=R+1, return to execute step S173, until R=N-1, and obtain N target detection dimensions.
[0058] S176, determining the order of the 1st target detection dimension to the Nth target detection dimension as the preset arrangement order corresponding to each predicted detection dimension when constructing the radar chart.
[0059] Among them, the first priority reflects the importance of the preset detection dimension in detecting the target quality score. Therefore, prioritizing the most important dimension to start sorting will help build a dimension sequence that is more logical and in order of importance.
[0060] Specifically, the current intermediate detection dimension and candidate detection dimension are clarified in each cycle, so that the candidate detection dimension with the strongest correlation with the intermediate detection dimension can be selected as the next target detection dimension based on the second correlation degree between the intermediate detection dimension and each candidate detection dimension. The order of the N target detection dimensions can be gradually determined through continuous cycles, so that adjacent target detection dimensions are more closely associated in logic and actual data.
[0061] The order of the 1st target detection dimension to the Nth target detection dimension is directly set as the preset arrangement order corresponding to each preset detection dimension when constructing the radar chart. When the quality of the target fruit is subsequently analyzed based on the radar chart, the area enclosed by adjacent dimensions can more accurately reflect the comprehensive situation that conforms to the actual quality correlation, thereby making the method of characterizing the quality based on the graphic area more accurate and orderly.
[0062] As described above, the candidate detection dimension with the strongest correlation with the intermediate detection dimension is selected according to the second correlation degree to be determined as the next target detection dimension, and the order of N target detection dimensions is gradually determined through multiple rounds of cycles, so that adjacent target detection dimensions are more closely associated in logic and actual data, and the area enclosed by adjacent dimensions can more accurately reflect the comprehensive situation that conforms to the actual quality association, thereby improving the accuracy of the quality detection results.
[0063] In a specific implementation, S18 includes the following steps:
[0064] S181, for any preset detection dimension, according to the preset arrangement order corresponding to each preset detection dimension, obtain the next preset detection dimension corresponding to the current preset detection dimension.
[0065] S182, obtain the first angle priority between the current preset detection dimension and the next preset detection dimension according to the first correlation degree corresponding to the current preset detection dimension, the first correlation degree corresponding to the next preset detection dimension corresponding to the current preset detection dimension, and the second correlation degree between the current preset detection dimension and the next preset detection dimension corresponding to the current preset detection dimension.
[0066] S183, traverse all preset detection dimensions, and obtain the first angle priority corresponding to each predicted detection dimension.
[0067] S184, normalize the first angle priorities corresponding to the N predicted detection dimensions to obtain the second angle priority corresponding to each predicted detection dimension.
[0068] S185, according to the preset total angle and the second angle priority corresponding to each predicted detection dimension, obtain the preset arrangement angle corresponding to each preset detection dimension, wherein the preset arrangement angle refers to the angle between each preset detection dimension in the radar chart and the corresponding next preset detection dimension.
[0069] The greater the first correlation degree, the more important the corresponding preset detection dimension is in characterizing the quality of the fruit, and the greater the second correlation degree, the more accurately the area enclosed by the corresponding two preset detection dimensions can reflect the quality of the fruit. Therefore, the first angle priority is positively correlated with both the first correlation degree and the second correlation degree.
[0070] Correspondingly, a first preset weight corresponding to the first correlation degree corresponding to the current preset detection dimension, a second preset weight corresponding to the first correlation degree corresponding to the next preset detection dimension corresponding to the current preset detection dimension, and a third preset weight corresponding to the second correlation degree between the current preset detection dimension and the next preset detection dimension corresponding to the current preset detection dimension can be obtained, and the first angle priority between the current preset detection dimension and the next preset detection dimension can be obtained through weighted summation.
[0071] The specific values of the preset total angle, the first preset weight, the second preset weight and the third preset weight can be set by the implementer according to the actual situation. For example, the preset total angle is set to 360 degrees.
[0072] The value range of the second angle priority is (0, 1), and the product of the preset total angle and each second angle priority is determined as the corresponding preset arrangement angle, so that the two preset detection dimensions with higher importance and stronger correlation for the overall quality evaluation of the fruit can be set at a relatively large angle on the radar chart, so that a larger effective area can be corresponding when the area is calculated, which is more in line with the synergistic relationship in the actual quality impact, so that the data of each dimension can participate in the comprehensive characterization of quality in a more accurate and fair manner, thereby improving the accuracy of judging quality based on area.
[0073] As mentioned above, by comprehensively allocating angles to each preset detection dimension in the radar chart based on various correlation factors, the relative weight of each preset detection dimension in the quality evaluation and the degree of correlation between the preset detection dimensions are reflected, ensuring that when analyzing the quality of fruit according to the radar chart, each preset detection dimension can participate in the overall quality characterization with an appropriate proportion, avoiding excessive or insufficient attention to certain preset detection dimensions due to unreasonable angles, thereby making the radar chart more accurately reflect the comprehensive situation of fruit quality and improving the accuracy of measuring fruit quality based on characteristics such as the area of the radar chart.
[0074] S2, according to the preset detection dimension, filter out the target detection data corresponding to the target fruit from the initial detection data, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data.
[0075] Among them, in order to accurately evaluate the quality of different types of fruits, the most relevant target detection data are screened out from the initial detection data according to the characteristics of the target fruit, that is, the detection data corresponding to each preset detection dimension, and the relevant data of irrelevant dimensions are deleted, avoiding excessive attention to irrelevant data and waste of resources during the detection process, while ensuring that the quality problems and advantages unique to each type of fruit can be accurately discovered.
[0076] As described above, by acquiring the target detection data corresponding to N preset detection dimensions that the target fruit is more concerned about, the information that is not closely related to the core quality assessment of the target fruit is removed, thereby improving the efficiency of subsequent data processing and analysis, while avoiding interference of irrelevant data on the quality inspection results, thereby improving the accuracy of the quality inspection results.
[0077] S3, performing preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data.
[0078] In a specific implementation, the preset processing includes normalization processing and quantization processing, and S3 includes the following steps:
[0079] S31, obtaining a data type and a preset model corresponding to each preset detection dimension, wherein the data type includes a numeric type and a text type.
[0080] S32, for any preset detection dimension, if the data type corresponding to the current preset detection dimension is a numeric type, normalize the detection data corresponding to the current preset detection dimension in the target detection data to obtain the intermediate detection data corresponding to the current preset detection dimension.
[0081] S33, if the data type corresponding to the current preset detection dimension is text type, then perform vector conversion processing on the detection data corresponding to the current preset detection dimension in the target detection data, obtain the detection vector corresponding to the current preset detection dimension, input the detection vector corresponding to the current preset detection dimension into the preset model, and obtain the intermediate detection data corresponding to the current preset detection dimension.
[0082] S34, traverse N preset detection dimensions to obtain intermediate detection data corresponding to each preset detection dimension.
[0083] S35, obtaining reference detection data corresponding to the target fruit according to the intermediate detection data corresponding to the N preset detection dimensions.
[0084] Among them, the data type corresponding to each preset detection dimension can be a numerical type or a text type. For example, the preset detection dimensions include sweetness and appearance color description. Sweetness corresponds to numerical 12°Bx (Degrees Brix), 15°Bx and other specific sweetness values, while the appearance color description corresponds to text expressions such as "bright color" and "dull color". The preset model can be a machine learning model that has been trained to convert color-related text descriptions into quantitative values.
[0085] The detection data corresponding to the current preset detection dimension in the target detection data is normalized to unify the data of different magnitudes and ranges into a standard scale, specifically including: if the detection data corresponding to the current preset detection dimension is positively correlated with the fruit quality, the ratio of the detection data corresponding to the current preset detection dimension to the maximum detection data corresponding to the current preset detection dimension is determined as the intermediate detection data corresponding to the current preset detection dimension. If the detection data corresponding to the current preset detection dimension is negatively correlated with the fruit quality, the ratio of the minimum detection data corresponding to the current preset detection dimension to the detection data corresponding to the current preset detection dimension is determined as the intermediate detection data corresponding to the current preset detection dimension.
[0086] Among them, those skilled in the art know that any vector conversion technology in the prior art falls within the protection scope of the present invention, and will not be described in detail here.
[0087] The intermediate detection data obtained from each preset detection dimension are integrated together to form the reference detection data corresponding to the target fruit.
[0088] As mentioned above, the reference test data contains uniformly processed information that can comprehensively and scientifically reflect the quality characteristics of fruits from different dimensions, providing an accurate data basis for further analysis of fruit quality.
[0089] S4, obtaining safety detection results corresponding to the target fruit according to the reference safety detection data, wherein the safety detection results include safe and unsafe.
[0090] In a specific implementation, the data type corresponding to the reference safety detection data is a numerical type, and S4 includes the following steps:
[0091] S41, obtaining a preset data threshold corresponding to each preset security detection dimension.
[0092] S42, for any preset safety detection dimension, if the detection data corresponding to the current preset safety detection dimension in the reference safety detection data is greater than the preset data threshold corresponding to the current preset safety detection dimension, then the safety detection result corresponding to the target fruit is determined to be unsafe.
[0093] Among them, the specific value of the preset data threshold corresponding to each preset security detection dimension can be set by the implementer according to actual conditions.
[0094] S5, if the safety detection result is unsafe, the preset score is determined as the target quality score corresponding to the target fruit.
[0095] Among them, if the test data corresponding to any preset safety detection dimension corresponding to the target fruit does not meet the safety requirements, it can be determined that the safety detection result corresponding to the target fruit is unsafe, which means that the target fruit belongs to the category of fruits that do not meet safety standards and have poor quality.
[0096] The specific value of the preset score can be set by the implementer according to the actual situation. For example, the preset score is 0, which is used to indicate that the safety quality of the target fruit is not up to standard.
[0097] As described above, each preset safety detection dimension is used as the only criterion for measuring whether the target fruit is safe. By directly assigning preset scores, the quality of unsafe fruits can be quickly characterized. The processing flow in the quality detection process is simplified, and the efficiency and rationality of obtaining quality detection results are ensured.
[0098] S6. If the safety detection result is safe, a radar chart corresponding to the target fruit is obtained according to the preset sorting angle, preset arrangement order and reference detection data corresponding to each predicted detection dimension, wherein the dimensions corresponding to the N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data.
[0099] In a specific implementation, the radar chart includes N coordinate axes, and S6 includes the following steps:
[0100] S61, according to the preset arrangement order corresponding to each predicted detection dimension, determine the u-th target detection dimension as the dimension corresponding to the u-th coordinate axis in the radar chart, where u=1, 2, ..., N.
[0101] S62, according to the preset arrangement angle corresponding to each predicted detection dimension, the preset arrangement angle corresponding to the u-th target detection dimension is determined as the angle between the u-th coordinate axis and the u+1-th coordinate axis in the radar chart, wherein, when u=N, the preset arrangement angle corresponding to the N-th target detection dimension is determined as the angle between the N-th coordinate axis and the 1st coordinate axis in the radar chart.
[0102] S63, determining the detection data corresponding to the u-th target detection dimension in the reference detection data as the corresponding data point on the u-th coordinate axis in the radar chart.
[0103] Among them, according to the preset arrangement order corresponding to each preset detection dimension, each preset detection dimension is assigned to each coordinate axis of the radar chart in turn, so as to establish a correspondence between the dimension of quality detection and the coordinate axis of the radar chart, so that each coordinate axis of the radar chart has a clear quality meaning, preparing for the subsequent accurate detection of fruit quality information.
[0104] The angle between adjacent coordinate axes is determined according to the preset arrangement angle set for each preset detection dimension, thereby ensuring that the angle layout of the radar chart conforms to factors such as the correlation and importance between the dimensions, so that the shape and angle distribution of the entire radar chart can reasonably reflect the relationship between the various quality dimensions of the target fruit, which is helpful to analyze the quality of the target fruit more scientifically and intuitively.
[0105] By converting the specific detection data corresponding to each preset detection dimension into data points on the coordinate axis of the radar chart, the reference detection data is accurately mapped to the coordinate axis of the radar data chart, so that the radar chart can be drawn based on the actual detection data, truly reflecting the specific situation of the target fruit in each quality dimension, and then displaying the abstract data in a visual graphical form, which is convenient for intuitive analysis of the quality characteristics of the target fruit.
[0106] As mentioned above, by clarifying the dimensions corresponding to the coordinate axes, the angles between adjacent coordinate axes, and the data points on the coordinate axes, a radar chart that can accurately display the quality of the target fruits is constructed, which provides an important basis for the subsequent target fruit quality analysis based on the graphic area in the radar chart.
[0107] S7, calculating the target graphic area of the radar chart, and determining the target graphic area as the target quality score corresponding to the target fruit.
[0108] Among them, by connecting the data points on adjacent coordinate axes through line segments, a closed target figure surrounded by N line segments is obtained. By dividing the closed target figure into multiple triangles, calculating the area of the triangles respectively and summing them up, the target figure area corresponding to the radar chart can be obtained. Correspondingly, the larger the area of the target figure, the better the performance of the target fruit in each preset detection dimension, and the better the quality of the target fruit.
[0109] Furthermore, the quality of the target fruit can be evaluated by the target quality score. For example, a batch of fruit corresponding to the target fruit can be evaluated as special grade, first grade, second grade, third grade, etc. according to the score, and the fruit quality evaluation results can be promptly fed back to the fruit supplier, grower or person in charge of the relevant production and sales links. For batches with excellent quality, summarize the high-quality experience; for batches with quality problems, clearly point out the problems and put forward improvement suggestions, such as optimizing planting management measures, adjusting picking time, improving packaging and transportation methods, etc., to promote the improvement of fruit quality.
[0110] As described above, by obtaining the preset arrangement order and preset arrangement angle of each preset detection dimension of the target fruit, a reasonable and well-founded basic parameter setting is provided for the subsequent construction of the radar chart and the quality detection of the target fruit; by removing the information that is not closely related to the core evaluation of the quality of the target fruit, the interference of irrelevant data on the quality detection result is avoided; by clarifying the dimensions corresponding to the coordinate axes, the angles between adjacent coordinate axes, and the data points on the coordinate axes, a radar chart that can accurately display the quality of the target fruit is constructed, ensuring that the radar chart conforms to the correlation and importance of the dimensions in terms of position distribution and angle layout, so that the shape, angle and value of the entire radar chart can reasonably reflect the relationship between the preset detection dimensions of the target fruit and the quality score, making the method of characterizing the quality according to the area of the graph more accurate and orderly, thereby improving the accuracy of the quality detection results.
[0111] Embodiment 2
[0112] The second embodiment provides a fruit quality detection and evaluation device, the fruit quality detection and evaluation device includes: Figure 2 As shown:
[0113] The data acquisition module 21 is used to obtain the initial detection data corresponding to the target fruit, N preset detection dimensions, and the preset arrangement angle and preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, M and N are integers greater than 0 and M≥N.
[0114] The data screening module 22 is used to screen the target detection data corresponding to the target fruit from the initial detection data according to the preset detection dimension, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data.
[0115] The data processing module 23 is used to perform preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data.
[0116] The safety detection module 24 is used to obtain the safety detection result corresponding to the target fruit according to the reference safety detection data, wherein the safety detection result includes safe and unsafe.
[0117] The first quality detection module 25 is used to determine the preset score as the target quality score corresponding to the target fruit if the safety detection result is unsafe.
[0118] The radar chart construction module 26 is used to obtain the radar chart corresponding to the target fruit according to the preset sorting angle, preset arrangement order and reference detection data corresponding to each predicted detection dimension if the safety detection result is safe, wherein the dimensions corresponding to the N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data.
[0119] The second quality detection module 27 is used to calculate the target graphic area of the radar chart and determine the target graphic area as the target quality score corresponding to the target fruit.
[0120] In a specific implementation, the data acquisition module 21 includes:
[0121] The first data acquisition submodule is used to acquire K reference fruits belonging to the same category as the target fruit, reference detection data corresponding to each reference fruit, and a target quality score, wherein K is an integer greater than 0.
[0122] The quality score vector acquisition submodule is used to obtain a quality score vector according to the target quality scores corresponding to K reference fruits, wherein the value of the tth element in the quality score vector is the target quality score corresponding to the tth reference fruit, t=1, 2, ..., K.
[0123] The detection data vector acquisition submodule is used to obtain, for any preset detection dimension, the detection data vector corresponding to the current preset detection dimension based on the reference detection data corresponding to each reference fruit, wherein the value of the t-th element in the detection data vector corresponding to the current preset detection dimension is the data in the reference detection data corresponding to the t-th reference fruit relative to the current preset detection dimension.
[0124] The first correlation degree acquisition submodule is used to acquire a first correlation degree between the current preset detection dimension and the target quality score according to the quality score vector and the detection data vector corresponding to the current preset detection dimension.
[0125] The second correlation degree acquisition submodule is used to acquire the second correlation degree between the current preset detection dimension and any other preset detection dimension according to the detection data vectors corresponding to the current preset detection dimension and any other preset detection dimension.
[0126] The dimension traversal submodule is used to traverse N preset detection dimensions to obtain a first correlation degree between each preset detection dimension and the target quality score, and a second correlation degree between any two preset detection dimensions.
[0127] The preset arrangement order acquisition submodule is used to acquire the preset arrangement order corresponding to each preset detection dimension according to the first priority corresponding to each preset detection dimension and the second correlation between each preset detection dimension and other preset detection dimensions.
[0128] The preset arrangement angle acquisition submodule is used to obtain the preset arrangement angle corresponding to each preset detection dimension according to the preset arrangement order corresponding to each preset detection dimension, the first correlation degree corresponding to each preset detection dimension, and the second correlation degree between each preset detection dimension and other preset detection dimensions.
[0129] In a specific implementation, the preset arrangement order acquisition submodule includes:
[0130] The first target detection dimension determination unit is used to determine the preset detection dimension corresponding to the maximum first priority as the first target detection dimension.
[0131] An initialization unit, used for initializing R=1.
[0132] The detection dimension classification unit is used to determine the Rth target detection dimension as an intermediate detection dimension, and determine other preset detection dimensions other than the 1st target detection dimension to the Rth target detection dimension as candidate detection dimensions.
[0133] The second target detection dimension determination unit is used to determine the candidate detection dimension corresponding to the maximum second correlation degree corresponding to the intermediate detection dimension as the R+1th target detection dimension according to the second correlation degree between the intermediate detection dimension and each candidate detection dimension.
[0134] The third target detection dimension determination unit is used to update R=R+1 and return to execute step S173 until R=N-1, thereby obtaining N target detection dimensions.
[0135] The preset arrangement order acquisition unit is used to determine the order from the 1st target detection dimension to the Nth target detection dimension as the preset arrangement order corresponding to each predicted detection dimension when constructing the radar chart.
[0136] In a specific implementation, the preset arrangement angle acquisition submodule includes:
[0137] The dimension analysis unit is used to obtain, for any preset detection dimension, the next preset detection dimension corresponding to the current preset detection dimension according to the preset arrangement order corresponding to each preset detection dimension.
[0138] A first priority acquisition unit is used to acquire a first angular priority between a current preset detection dimension and a next preset detection dimension based on a first correlation degree corresponding to the current preset detection dimension, a first correlation degree corresponding to a next preset detection dimension corresponding to the current preset detection dimension, and a second correlation degree between the current preset detection dimension and the next preset detection dimension corresponding to the current preset detection dimension.
[0139] The second priority acquisition unit is used to traverse all preset detection dimensions and acquire the first angle priority corresponding to each predicted detection dimension.
[0140] The third priority acquisition unit is used to normalize the first angle priorities corresponding to the N predicted detection dimensions to obtain the second angle priority corresponding to each predicted detection dimension.
[0141] The preset arrangement angle acquisition unit is used to obtain the preset arrangement angle corresponding to each preset detection dimension according to the preset total angle and the second angle priority corresponding to each predicted detection dimension, wherein the preset arrangement angle refers to the angle between each preset detection dimension in the radar chart and the corresponding next preset detection dimension.
[0142] In a specific implementation, the radar chart includes N coordinate axes, and the radar chart construction module 26 includes:
[0143] The coordinate axis dimension determination submodule is used to determine the u-th target detection dimension as the dimension corresponding to the u-th coordinate axis in the radar chart according to the preset arrangement order corresponding to each predicted detection dimension, where u = 1, 2, ..., N.
[0144] The coordinate axis angle determination submodule is used to determine the preset arrangement angle corresponding to the u-th target detection dimension as the angle between the u-th coordinate axis and the u+1-th coordinate axis in the radar chart according to the preset arrangement angle corresponding to each predicted detection dimension, wherein when u=N, the preset arrangement angle corresponding to the N-th target detection dimension is determined as the angle between the N-th coordinate axis and the 1st coordinate axis in the radar chart.
[0145] The coordinate axis data point determination submodule is used to determine the detection data corresponding to the u-th target detection dimension in the reference detection data as the corresponding data point on the u-th coordinate axis in the radar chart.
[0146] In a specific implementation, the preset processing includes normalization processing and quantization processing, and the data processing module 23 includes:
[0147] The second data acquisition submodule is used to obtain the data type and preset model corresponding to each preset detection dimension, wherein the data type includes a numeric type and a text type.
[0148] The first data processing submodule is used to normalize the detection data corresponding to the current preset detection dimension in the target detection data for any preset detection dimension, if the data type corresponding to the current preset detection dimension is a numerical type, to obtain the intermediate detection data corresponding to the current preset detection dimension.
[0149] The second data processing sub-module is used to perform vector conversion processing on the detection data corresponding to the current preset detection dimension in the target detection data if the data type corresponding to the current preset detection dimension is text type, obtain the detection vector corresponding to the current preset detection dimension, input the detection vector corresponding to the current preset detection dimension into the preset model, and obtain the intermediate detection data corresponding to the current preset detection dimension.
[0150] The third data processing submodule is used to traverse N preset detection dimensions and obtain the intermediate detection data corresponding to each preset detection dimension.
[0151] The reference detection data acquisition submodule is used to obtain the reference detection data corresponding to the target fruit based on the intermediate detection data corresponding to N preset detection dimensions.
[0152] In a specific implementation, the data type corresponding to the reference safety detection data is a numerical type, and the safety detection module 24 includes:
[0153] The third data acquisition submodule is used to obtain the preset data threshold corresponding to each preset security detection dimension.
[0154] The safety detection submodule is used to determine that the safety detection result corresponding to the target fruit is unsafe for any preset safety detection dimension if the detection data corresponding to the current preset safety detection dimension in the reference safety detection data is greater than the preset data threshold corresponding to the current preset safety detection dimension.
[0155] It should be noted that the information interaction, execution process and other contents between the above modules are based on the same concept as the embodiment of the method of the present invention. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.
[0156] Embodiment 3
[0157] Embodiment 3 of the present invention provides a non-transitory computer-readable storage medium, wherein at least one instruction or at least one program is stored in the non-transitory computer-readable storage medium, and the at least one instruction or at least one program is loaded and executed by a processor to implement the steps:
[0158] S1, obtain the initial detection data corresponding to the target fruit, N preset detection dimensions, and the preset arrangement angle and preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, M and N are integers greater than 0 and M≥N.
[0159] S2, according to the preset detection dimension, filter out the target detection data corresponding to the target fruit from the initial detection data, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data.
[0160] S3, performing preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data.
[0161] S4, obtaining safety detection results corresponding to the target fruit according to the reference safety detection data, wherein the safety detection results include safe and unsafe.
[0162] S5, if the safety detection result is unsafe, the preset score is determined as the target quality score corresponding to the target fruit.
[0163] S6. If the safety detection result is safe, a radar chart corresponding to the target fruit is obtained according to the preset sorting angle, preset arrangement order and reference detection data corresponding to each predicted detection dimension, wherein the dimensions corresponding to the N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data.
[0164] S7, calculating the target graphic area of the radar chart, and determining the target graphic area as the target quality score corresponding to the target fruit.
[0165] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronization link DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0166] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.
[0167] Embodiment 4
[0168] A fourth embodiment of the present invention provides an electronic device, which includes a processor and the non-transitory computer-readable storage medium in the third embodiment of the present invention.
[0169] The above are only preferred embodiments of the present invention, and are not intended to limit the present invention in any form. Although the present invention has been disclosed as a preferred embodiment as above, it is not intended to limit the present invention. Any technician familiar with the profession can make some changes or modifications to equivalent embodiments of equivalent changes using the technical contents disclosed above without departing from the scope of the technical solution of the present invention. However, any simple modifications, equivalent changes and modifications made to the above embodiments based on the technical essence of the present invention without departing from the content of the technical solution of the present invention are still within the scope of the technical solution of the present invention.
Claims
1. A method for detecting and evaluating the quality of fruit, characterized in that: The fruit quality detection and evaluation method comprises the following steps: S1, obtaining initial detection data corresponding to the target fruit, N preset detection dimensions, and a preset arrangement angle and a preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, and the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, and M and N are integers greater than 0 and M≥N; S2, according to the preset detection dimension, screening the target detection data corresponding to the target fruit from the initial detection data, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data; S3, performing preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data; S4, obtaining a safety detection result corresponding to the target fruit according to the reference safety detection data, wherein the safety detection result includes safe and unsafe; S5, if the safety detection result is unsafe, determining the preset score as the target quality score corresponding to the target fruit; S6, if the safety detection result is safe, then according to the preset sorting angle, preset arrangement order and the reference detection data corresponding to each predicted detection dimension, a radar chart corresponding to the target fruit is obtained, wherein the dimensions corresponding to the N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data; S7, calculating the target graphic area of the radar chart, and determining the target graphic area as the target quality score corresponding to the target fruit.
2. The method for detecting and evaluating the quality of fruits according to claim 1, characterized in that: S1 includes the following steps: S11, obtaining K reference fruits belonging to the same category as the target fruit, reference detection data corresponding to each reference fruit and a target quality score, wherein K is an integer greater than 0; S12, obtaining a quality score vector according to the target quality scores corresponding to the K reference fruits, wherein the value of the t-th element in the quality score vector is the target quality score corresponding to the t-th reference fruit, t=1, 2, ..., K; S13, for any preset detection dimension, according to the reference detection data corresponding to each reference fruit, obtain the detection data vector corresponding to the current preset detection dimension, wherein the value of the t-th element in the detection data vector corresponding to the current preset detection dimension is the data in the reference detection data corresponding to the t-th reference fruit relative to the current preset detection dimension; S14, obtaining a first correlation degree between the current preset detection dimension and the target quality score according to the quality score vector and the detection data vector corresponding to the current preset detection dimension; S15, obtaining a second correlation degree between the current preset detection dimension and any other preset detection dimension according to the detection data vectors corresponding to the current preset detection dimension and any other preset detection dimension; S16, traversing N preset detection dimensions, obtaining a first correlation degree between each preset detection dimension and the target quality score, and a second correlation degree between any two preset detection dimensions; S17, acquiring a preset arrangement order corresponding to each preset detection dimension according to a first priority corresponding to each preset detection dimension and a second correlation degree between each preset detection dimension and other preset detection dimensions; S18, obtaining a preset arrangement angle corresponding to each preset detection dimension according to the preset arrangement order corresponding to each preset detection dimension, the first correlation degree corresponding to each preset detection dimension, and the second correlation degree between each preset detection dimension and other preset detection dimensions.
3. The method for detecting and evaluating the quality of fruits according to claim 2, characterized in that: S17 includes the following steps: S171, determining the preset detection dimension corresponding to the largest first priority as the first target detection dimension; S172, initialize R=1; S173, determining the Rth target detection dimension as the intermediate detection dimension, and determining other preset detection dimensions other than the first target detection dimension to the Rth target detection dimension as candidate detection dimensions; S174, according to the second correlation degree between the intermediate detection dimension and each candidate detection dimension, determining the candidate detection dimension corresponding to the maximum second correlation degree corresponding to the intermediate detection dimension as the R+1th target detection dimension; S175, update R=R+1, return to execute step S173, until R=N-1, and obtain N target detection dimensions; S176, determining the order of the 1st target detection dimension to the Nth target detection dimension as the preset arrangement order corresponding to each predicted detection dimension when constructing the radar chart.
4. The method for detecting and evaluating the quality of fruits according to claim 3, characterized in that: S18 includes the following steps: S181, for any preset detection dimension, according to the preset arrangement order corresponding to each preset detection dimension, obtaining the next preset detection dimension corresponding to the current preset detection dimension; S182, obtaining a first angle priority between the current preset detection dimension and the next preset detection dimension according to a first correlation degree corresponding to the current preset detection dimension, a first correlation degree corresponding to the next preset detection dimension corresponding to the current preset detection dimension, and a second correlation degree between the current preset detection dimension and the next preset detection dimension corresponding to the current preset detection dimension; S183, traversing all preset detection dimensions, and obtaining a first angle priority corresponding to each predicted detection dimension; S184, normalizing the first angle priorities corresponding to the N prediction detection dimensions to obtain a second angle priority corresponding to each prediction detection dimension; S185, according to the preset total angle and the second angle priority corresponding to each predicted detection dimension, obtain the preset arrangement angle corresponding to each preset detection dimension, wherein the preset arrangement angle refers to the angle between each preset detection dimension in the radar chart and the corresponding next preset detection dimension.
5. The method for detecting and evaluating the quality of fruits according to claim 3, characterized in that: The radar chart includes N coordinate axes, and S6 includes the following steps: S61, according to the preset arrangement order corresponding to each predicted detection dimension, determine the u-th target detection dimension as the dimension corresponding to the u-th coordinate axis in the radar chart, where u=1, 2, ..., N; S62, according to the preset arrangement angle corresponding to each predicted detection dimension, determine the preset arrangement angle corresponding to the u-th target detection dimension as the angle between the u-th coordinate axis and the u+1-th coordinate axis in the radar map, wherein when u=N, determine the preset arrangement angle corresponding to the N-th target detection dimension as the angle between the N-th coordinate axis and the 1st coordinate axis in the radar map; S63, determining the detection data corresponding to the u-th target detection dimension in the reference detection data as the corresponding data point on the u-th coordinate axis in the radar chart.
6. The method for detecting and evaluating the quality of fruits according to claim 1, characterized in that: The preset processing includes normalization processing and quantization processing, and S3 includes the following steps: S31, obtaining a data type and a preset model corresponding to each preset detection dimension, wherein the data type includes a numeric type and a text type; S32, for any preset detection dimension, if the data type corresponding to the current preset detection dimension is a numerical type, normalize the detection data corresponding to the current preset detection dimension in the target detection data to obtain intermediate detection data corresponding to the current preset detection dimension; S33, if the data type corresponding to the current preset detection dimension is a text type, performing vector conversion processing on the detection data corresponding to the current preset detection dimension in the target detection data, obtaining a detection vector corresponding to the current preset detection dimension, inputting the detection vector corresponding to the current preset detection dimension into the preset model, and obtaining intermediate detection data corresponding to the current preset detection dimension; S34, traversing N preset detection dimensions to obtain intermediate detection data corresponding to each preset detection dimension; S35, obtaining reference detection data corresponding to the target fruit according to the intermediate detection data corresponding to N preset detection dimensions.
7. The method for detecting and evaluating the quality of fruits according to claim 6, characterized in that: The data type corresponding to the reference safety detection data is a numerical type, and S4 includes the following steps: S41, obtaining a preset data threshold corresponding to each preset security detection dimension; S42, for any preset safety detection dimension, if the detection data corresponding to the current preset safety detection dimension in the reference safety detection data is greater than the preset data threshold corresponding to the current preset safety detection dimension, then the safety detection result corresponding to the target fruit is determined to be unsafe.
8. A fruit quality detection and evaluation device, characterized in that: The fruit quality detection and evaluation device comprises: A data acquisition module is used to acquire initial detection data corresponding to the target fruit, N preset detection dimensions, and a preset arrangement angle and a preset arrangement order corresponding to each predicted detection dimension, wherein the initial detection data includes data corresponding to M initial detection dimensions, and the preset detection dimensions include a preset safety detection dimension, a preset quality detection dimension, and a preset appearance detection dimension, and M and N are integers greater than 0 and M≥N; A data screening module, used for screening the target detection data corresponding to the target fruit from the initial detection data according to the preset detection dimension, wherein the target detection data includes target safety detection data, target quality detection data and target appearance detection data; A data processing module, used to perform preset processing on the target detection data to obtain reference detection data corresponding to the target fruit, wherein the reference detection data includes reference safety detection data, reference quality detection data and reference appearance detection data; A safety detection module, used to obtain a safety detection result corresponding to the target fruit according to the reference safety detection data, wherein the safety detection result includes safe and unsafe; A first quality detection module, configured to determine a preset score as a target quality score corresponding to the target fruit if the safety detection result is unsafe; A radar chart construction module, for obtaining a radar chart corresponding to the target fruit according to a preset sorting angle, a preset arrangement order and the reference detection data corresponding to each predicted detection dimension if the safety detection result is safe, wherein the dimensions corresponding to N coordinate axes in the radar chart are determined by the preset arrangement order corresponding to the N preset detection dimensions, the angles between adjacent coordinate axes are determined by the preset arrangement angles corresponding to the N preset detection dimensions, and the data points on each coordinate axis are determined by the detection data corresponding to each preset detection dimension in the reference detection data; The second quality detection module is used to calculate the target graphic area of the radar chart, and determine the target graphic area as the target quality score corresponding to the target fruit.
9. A non-transitory computer-readable storage medium, wherein at least one instruction or at least one program is stored in the non-transitory computer-readable storage medium, characterized in that: The at least one instruction or the at least one program is loaded and executed by the processor to implement the fruit quality detection and evaluation method as described in any one of claims 1 to 7.
10. An electronic device, characterized in that: The invention comprises a processor and the non-transitory computer-readable storage medium as claimed in claim 9.
Citation Information
Patent Citations
Method for quantifying wine taste
CN108196016A
Multiple apple quality indexes-based visualized evaluation method
CN110320333A
Construction method and application of chicken quality comprehensive evaluation model
CN112668142A
Multi-index system evaluation method suitable for food detection
CN113762759A
Method for evaluating quality of tropical fruit solid-state processing raw materials based on three elements of appearance, texture and flavor
CN118033009A
Cited By
Liver function health state monitoring method and system based on big data
CN120336976A