Aquatic product freshness detection method and device based on data mining

Through the data mining method, combined with the fusion of spectral feature data and image feature data, the traditional aquatic product freshness detection method has solved the shortage of fast, accurate and non-destructive methods, and achieved efficient and accurate aquatic product freshness Test.

CN119445349APending Publication Date: 2025-02-14汉唐和元(武汉)科技有限公司 +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411485795.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-23
Publication Date
2025-02-14

AI Technical Summary

Technical Problem

Traditional aquatic product freshness detection methods have flaws in non-subjectivity, accuracy and efficiency, which cannot meet the needs of rapid detection, and physical detection may damage the detection object.

Method used

Using a data mining method, different types of images are collected, spectral feature data and image feature data are mined, and the freshness of aquatic products is fused.

Benefits of technology

It realizes rapid and accurate detection of freshness of aquatic products, meets the needs of rapid detection, and does not cause damage to aquatic products.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119445349A_ABST
    Figure CN119445349A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of aquatic product detection, and discloses an aquatic product freshness detection method and device based on data mining. A first image and a second image of an aquatic product to be detected are acquired, and the first image and the second image have different image types and acquisition modes; mining spectral feature data from the first image; preprocessing the second image, and mining image feature data from the preprocessed image; fusing the spectral feature data with the image feature data to obtain fused feature data; and performing freshness detection on the to-be-detected aquatic product based on the fused feature data, through the above mode, the freshness detection is performed by fusing the spectral feature data and the image feature data, the requirement of rapid detection of the freshness of the aquatic product can be met, the detection accuracy is improved, and the aquatic product is not damaged.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of aquatic product detection, and in particular to a method and device for detecting freshness of aquatic products based on data mining. Background Art

[0002] Freshness is one of the important indicators for judging the quality of aquatic products. By judging freshness, we can understand the basic safety status of the product. Therefore, freshness has become an important parameter for consumers to judge when purchasing aquatic products, and it is also the most important indicator for merchants and relevant institutions to evaluate the quality and safety of aquatic products. In addition to playing an important role in the production and sales places, freshness testing also plays a vital role in the transportation process.

[0003] Among the traditional freshness detection methods, the most traditional way is to judge and evaluate by observing the appearance of the fish, changes in the pupil of the fish eye and the color of the fish gills; the second is the chemical detection of protein changes, pH value, K value and volatile basic nitrogen (TVB-N); and the physical detection of bioresistance. However, this method has many shortcomings in terms of non-subjectivity, accuracy and efficiency, which cannot meet the needs of rapid detection of the freshness of aquatic products, and physical detection also has the disadvantage of destroying the detection object.

[0004] The above contents are only used to assist in understanding the technical solution of the present invention and do not constitute an admission that the above contents are prior art. Summary of the invention

[0005] The main purpose of the present invention is to provide a method and device for detecting the freshness of aquatic products based on data mining, aiming to solve the technical problems that traditional detection methods cannot meet the needs of rapid detection of the freshness of aquatic products, and physical detection also has the disadvantage of destroying the detection object.

[0006] To achieve the above object, the present invention provides a method for detecting the freshness of aquatic products based on data mining, and the method for detecting the freshness of aquatic products based on data mining comprises the following steps:

[0007] Acquire a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and acquisition methods;

[0008] mining spectral feature data from the first image;

[0009] Preprocessing the second image, and mining image feature data from the preprocessed image;

[0010] Fusing the spectral feature data with the image feature data to obtain fused feature data;

[0011] The freshness of the aquatic product to be detected is detected based on the fused feature data.

[0012] In some embodiments, mining spectral feature data from the first image includes:

[0013] Performing dimensionality reduction and deblurring processing on the first image to obtain a reference first image;

[0014] A preset proportion of training samples is selected from the hyperspectral data set, the data window size is set, and the sample categories are trained by an automatic encoder to establish a test sample set;

[0015] Performing training optimization based on the test sample set and determining model parameters to establish a feature learning model;

[0016] The original image depth feature is extracted from the first image through the feature learning model, and the original image depth feature is placed in the spatial information to obtain spectral feature data.

[0017] In some embodiments, the preprocessing of the second image includes:

[0018] Binarize the second image according to a preset threshold to obtain a binary image;

[0019] Performing an opening operation on the binary image to remove redundant features at the edge;

[0020] An image closing operation is performed on the redundant binary image to fill the hole area in the redundant binary image to obtain a preprocessed image.

[0021] In some embodiments, mining image feature data from the preprocessed image includes:

[0022] The central pixel point is set to have a radius of one pixel, and a number of surrounding adjacent pixels form a local block of a preset size;

[0023] Obtaining the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels from the preprocessed image;

[0024] Calculating a local binary value according to the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels;

[0025] The texture feature of the preprocessed image is extracted based on the local binary value to obtain image feature data.

[0026] In some embodiments, the fusing the spectral feature data with the image feature data to obtain fused feature data includes:

[0027] Performing weighted summation according to the weights corresponding to the spectral feature data and the image feature data to obtain fused feature data;

[0028] Or, converting the spectral feature data and the image feature data to the same dimension, and concatenating the spectral feature data and the image feature data in the same dimension to obtain fused feature data;

[0029] Or, a fusion weight is determined using a preset conditional function, and the spectral feature data and the image feature data are fused according to the fusion weight to obtain fused feature data.

[0030] In some embodiments, the freshness detection of the aquatic product to be detected based on the fused feature data includes:

[0031] Determining the aquatic species of the aquatic product to be detected;

[0032] Determine key detection areas based on the aquatic species in question;

[0033] Determine the key features corresponding to the key detection area according to the fused feature data;

[0034] Comparing the key features with preset features;

[0035] The freshness of the aquatic product to be detected is detected based on the feature comparison result.

[0036] In addition, to achieve the above-mentioned purpose, the present invention also proposes a device for detecting freshness of aquatic products based on data mining, and the device for detecting freshness of aquatic products based on data mining comprises:

[0037] An acquisition module, used for acquiring a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and acquisition methods;

[0038] A mining module, used for mining spectral feature data from the first image;

[0039] The mining module is used to preprocess the second image and mine image feature data from the preprocessed image;

[0040] A fusion module, used for fusing the spectral feature data with the image feature data to obtain fused feature data;

[0041] A detection module is used to perform freshness detection on the aquatic product to be detected based on the fused feature data.

[0042] In some embodiments, the mining module is used to perform dimensionality reduction and deblurring processing on the first image to obtain a reference first image;

[0043] A preset proportion of training samples is selected from the hyperspectral data set, the data window size is set, and the sample categories are trained by an automatic encoder to establish a test sample set;

[0044] Performing training optimization based on the test sample set and determining model parameters to establish a feature learning model;

[0045] The original image depth feature is extracted from the first image through the feature learning model, and the original image depth feature is placed in the spatial information to obtain spectral feature data.

[0046] In some embodiments, the mining module is used to perform binarization processing on the second image according to a preset threshold value to obtain a binary image;

[0047] Performing an opening operation on the binary image to remove redundant features at the edge;

[0048] An image closing operation is performed on the redundant binary image to fill the hole area in the redundant binary image to obtain a preprocessed image.

[0049] In some embodiments, the mining module is used to set the central pixel point to have a radius of one pixel and to form a local block of a preset size with a number of surrounding adjacent pixels;

[0050] Obtaining the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels from the preprocessed image;

[0051] Calculating a local binary value according to the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels;

[0052] The texture feature of the preprocessed image is extracted based on the local binary value to obtain image feature data.

[0053] The present invention collects a first image and a second image of aquatic products to be detected, wherein the first image and the second image have different image types and collection methods; mines spectral feature data from the first image; preprocesses the second image and mines image feature data from the preprocessed image; fuses the spectral feature data with the image feature data to obtain fused feature data; and performs freshness detection on the aquatic products to be detected based on the fused feature data. Through the above method, freshness detection is performed by fusing spectral feature data with image feature data, which can meet the needs of rapid freshness detection of aquatic products, improve detection accuracy, and will not cause damage to the aquatic products. BRIEF DESCRIPTION OF THE DRAWINGS

[0054] Figure 1It is a flow chart of the first embodiment of the method for detecting freshness of aquatic products based on data mining of the present invention;

[0055] Figure 2 This is a structural block diagram of the first embodiment of the aquatic product freshness detection device based on data mining of the present invention.

[0056] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0057] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0058] The embodiment of the present invention provides a method for detecting freshness of aquatic products based on data mining, referring to Figure 1 , Figure 1 The figure is a flow chart of a first embodiment of a method for detecting freshness of aquatic products based on data mining according to the present invention.

[0059] In this embodiment, the aquatic product freshness detection method based on data mining includes the following steps:

[0060] Step S10: Acquire a first image and a second image of the aquatic product to be detected.

[0061] In this embodiment, the executor of this embodiment is a water product freshness detection device based on data mining, wherein the water product freshness detection device based on data mining has functions such as data processing, data communication and program running. The water product freshness detection device based on data mining can be a computer terminal device or other network device, and of course it can also be other devices with similar functions, and this embodiment does not limit this.

[0062] It should be noted that among the traditional freshness detection methods, the most traditional way is to judge and evaluate by observing the appearance of the fish, changes in the pupil of the fish eye and the color of the fish gills; followed by chemical detection of protein changes, pH value, K value and volatile basic nitrogen (TVB-N); and then physical detection of bioresistance. However, this method has many shortcomings in terms of non-subjectivity, accuracy and efficiency, which cannot meet the needs of rapid detection of the freshness of aquatic products, and physical detection also has the disadvantage of destroying the detection object.

[0063] In order to solve the above technical problems, this embodiment collects a first image and a second image of aquatic products to be detected, wherein the first image and the second image have different image types and acquisition methods; mines spectral feature data from the first image; preprocesses the second image, and mines image feature data from the preprocessed image; fuses the spectral feature data with the image feature data to obtain fused feature data; and performs freshness detection on the aquatic products to be detected based on the fused feature data. Through the above method, freshness detection is performed by fusing spectral feature data with image feature data, which can meet the needs of rapid freshness detection of aquatic products, improve detection accuracy, and will not cause damage to the aquatic products. Specifically, it can be implemented as follows.

[0064] In the specific implementation, in this embodiment, it is necessary to first collect the first image and the second image of the aquatic product to be inspected, wherein the first image and the second image belong to different types of images, and the corresponding image acquisition methods are also different. The first image can be a hyperspectral image, and the second image is an ordinary three-primary color image. The second image can be obtained by shooting with a traditional camera, while the first image needs to be obtained with the help of, for example, a hyperspectral imaging sensor.

[0065] Step S20: mining spectral feature data from the first image.

[0066] In a specific implementation, for the first image, that is, the hyperspectral image, it is necessary to mine spectral feature data therefrom in this embodiment, specifically including performing dimensionality reduction and deblurring processing on the first image to obtain a reference first image, selecting a preset proportion of training samples in the hyperspectral data set, setting the data window size, training sample categories through an automatic encoder to establish a test sample set, performing training optimization based on the test sample set, and determining model parameters to establish a feature learning model, extracting original image depth features from the first image through the feature learning model, putting the original image depth features into spatial information, and obtaining spectral feature data.

[0067] It should be noted that the image dimensionality reduction process is to determine the input data, set the hyperspectral image data set Y, the label set A, the dimension K of the data target dimensionality reduction, and the total number of data set categories q, establish a data category container, store data samples according to the data category, expand the sparse representation of the data, construct a data similarity matrix, and establish a data projection transformation matrix by solving the eigenvalues ​​of the data to obtain the image data dimensionality reduction result. The process is shown in the following formula: X = Q T Y∈R k×n , where the data dimension reduction result is expressed in the form of X, and the corresponding feature description of the kth data in the data set is R k×nIn the form of semi-supervised sample selection strategy, data semi-supervised samples are selected to establish a new data label set, and then the above process is repeated until the dimension reduction result is obtained. The defuzzification process is based on the dictionary initialization result, fixes the dictionary to be learned D, and calculates the dictionary sparse coefficient vector value β ij Based on the calculation results of the dictionary sparse coefficient vector value, the dictionary is updated and the new dictionary atoms and corresponding coefficients are calculated by the following formula. The process is shown in the following formula Among them, the updated dictionary atom is described as D ki The corresponding coefficients are marked The rank approximation function is expressed in T form, and the singular decomposition value of the dictionary is expressed as W ki The autoencoder is an unsupervised feature learning neural network model. The objective function of the model is The original image depth feature is extracted through the established feature learning model as Y i =s(W i +l pi ), W i is the model parameter of the feature learning model, l pi Determined by the output layer and hidden layer of the automatic encoder.

[0068] Step S30: preprocessing the second image, and mining image feature data from the preprocessed image.

[0069] In a specific implementation, the process of preprocessing the second image is to binarize the second image according to a preset threshold to obtain a binary image; perform an opening operation on the binary image to remove redundant features at the edge; perform an image closing operation on the de-redundant binary image to fill the hole areas in the redundant binary image to obtain a preprocessed image.

[0070] It should be noted that the threshold selected in this embodiment may be 0.5. The opening operation is to first erode the image and then perform an expansion operation. The mathematical expression can be written as: Where A is the input image, B is the structure element, represents the corrosion operation, Represents the dilation operation. The closing operation is to dilate the image first and then perform the erosion operation. The mathematical expression can be written as:

[0071] After obtaining the preprocessed image, image feature data is further mined therefrom. The specific process is to set a central pixel point with a radius of one pixel, and form a local block of a preset size with several surrounding adjacent pixels; obtain the grayscale value of the central pixel point and the grayscale values ​​of several surrounding adjacent pixels from the preprocessed image; calculate the local binary value according to the grayscale value of the central pixel point and the grayscale values ​​of several surrounding adjacent pixels; and perform texture feature extraction on the preprocessed image based on the local binary value to obtain image feature data.

[0072] It should be noted that the number of pixels may be 8, and the preset size may be 3×3. For example, given a central pixel point with 1 pixel as the radius, and 8 adjacent pixels around it form a 3×3 local block, the calculation formula is: is the local binary value at the center pixel, p represents the pth pixel in the neighborhood of the center pixel, P represents the number of neighborhood pixels, i c Represents the gray value of the center pixel, i p Represents the gray value of the pth pixel in the neighborhood. By using the above local binary value to perform LBP processing on the preprocessed image, the texture feature can be obtained.

[0073] Step S40: fusing the spectral feature data with the image feature data to obtain fused feature data.

[0074] After extracting the spectral feature data and the image feature data from the first image and the second image, respectively, the further method adopted in this embodiment is to fuse the two. Specifically, different methods can be used for fusion. The first method is to perform weighted summation according to the weights corresponding to the spectral feature data and the image feature data, and obtain fused feature data, for example, F=w1·f1+w2·f2, where w1 and w2 are the corresponding weights. The second method is to convert the spectral feature data and the image feature data to the same dimension, and splice the spectral feature data and the image feature data under the same dimension to obtain fused feature data, for example, F=[f1,f2], where F is a new feature formed by splicing multiple features fi in the dimension. The third method is to determine the fusion weight using a preset conditional function, and fuse the spectral feature data and the image feature data according to the fusion weight to obtain fused feature data, for example, F=g(f1,f2)·f1+(1-g(f1,f2))f2, where g is a conditional function.

[0075] Step S50: performing freshness detection on the aquatic product to be detected based on the fused feature data.

[0076] After obtaining the fused features, in this embodiment, freshness monitoring can be achieved based on the fused feature data. The specific process is to determine the type of aquatic products to be detected, determine the key detection area based on the type of aquatic products, determine the key features corresponding to the key detection areas based on the fused feature data, compare the key features with the preset features, and realize freshness detection of the aquatic products to be detected based on the feature comparison results.

[0077] It should be noted that the freshness of different aquatic products is different. In order to improve the accuracy of freshness detection, in this embodiment, it is necessary to first determine the type of aquatic product. For example, for fish aquatic products, the key detection area is the eye area of ​​the fish. For shrimp aquatic products, the key detection area is the subject area on the shrimp. The key features extracted from the fusion features are, for example, the above-mentioned shrimp shell color, spot distribution and other features. Feature comparison can be a similarity comparison, for example, the distance between the key feature and the preset feature is calculated by Euclidean distance, and the distance corresponds to the similarity. The preset feature includes multiple features, such as fresh aquatic product features, and multiple features in the process of aquatic products changing from fresh to spoiled. By comparing one by one, it can be determined whether the aquatic product is fresh.

[0078] This embodiment collects a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and collection methods; mines spectral feature data from the first image; preprocesses the second image, and mines image feature data from the preprocessed image; fuses the spectral feature data with the image feature data to obtain fused feature data; and performs freshness detection on the aquatic product to be detected based on the fused feature data. Through the above method, freshness detection is performed by fusing spectral feature data with image feature data, which can meet the needs of rapid freshness detection of aquatic products, improve detection accuracy, and will not cause damage to the aquatic products.

[0079] Reference Figure 2 , Figure 2 This is a structural block diagram of the first embodiment of the aquatic product freshness detection device based on data mining of the present invention.

[0080] like Figure 2 As shown, the aquatic product freshness detection device based on data mining proposed in an embodiment of the present invention includes:

[0081] The acquisition module 10 is used to acquire a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and acquisition methods.

[0082] The mining module 20 is used to mine spectral feature data from the first image.

[0083] The mining module 20 is used to preprocess the second image and mine image feature data from the preprocessed image.

[0084] The fusion module 30 is used to fuse the spectral feature data with the image feature data to obtain fused feature data.

[0085] The detection module 40 is used to perform freshness detection on the aquatic product to be detected based on the fused feature data.

[0086] This embodiment collects a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and collection methods; mines spectral feature data from the first image; preprocesses the second image, and mines image feature data from the preprocessed image; fuses the spectral feature data with the image feature data to obtain fused feature data; and performs freshness detection on the aquatic product to be detected based on the fused feature data. Through the above method, freshness detection is performed by fusing spectral feature data with image feature data, which can meet the needs of rapid freshness detection of aquatic products, improve detection accuracy, and will not cause damage to the aquatic products.

[0087] In some embodiments, the mining module 20 is used to perform dimensionality reduction and deblurring processing on the first image to obtain a reference first image; select a preset proportion of training samples in the hyperspectral data set, set the data window size, and train the sample categories through an automatic encoder to establish a test sample set; perform training optimization based on the test sample set, and determine model parameters to establish a feature learning model; extract the original image depth features from the first image through the feature learning model, put the original image depth features into spatial information, and obtain spectral feature data.

[0088] In some embodiments, the mining module 20 is used to binarize the second image according to a preset threshold to obtain a binary image; perform an opening operation on the binary image to remove redundant features at the edge; perform an image closing operation on the de-redundant binary image to fill the empty areas in the redundant binary image to obtain a preprocessed image.

[0089] In some embodiments, the mining module 20 is used to set a central pixel point with a radius of one pixel, and to form a local block of a preset size with several surrounding adjacent pixels; obtain the grayscale value of the central pixel point and the grayscale values ​​of several surrounding adjacent pixels from the preprocessed image; calculate the local binary value according to the grayscale value of the central pixel point and the grayscale values ​​of several surrounding adjacent pixels; and perform texture feature extraction on the preprocessed image based on the local binary value to obtain image feature data.

[0090] In some embodiments, the fusion module 30 is used to perform weighted summation according to the weights corresponding to each of the spectral feature data and the image feature data to obtain fused feature data; or, convert the spectral feature data and the image feature data to the same dimension, and descend the spectral feature data and the image feature data in the same dimension for splicing to obtain fused feature data; or, determine the fusion weight using a preset conditional function, and fuse the spectral feature data and the image feature data according to the fusion weight to obtain fused feature data.

[0091] In some embodiments, the detection module 40 is used to determine the type of aquatic product to be detected; determine the key detection area according to the type of aquatic product; determine the key features corresponding to the key detection area according to the fused feature data; compare the key features with preset features; and implement freshness detection of the aquatic product to be detected based on the feature comparison results.

[0092] An embodiment of the present application also provides a device for detecting the freshness of aquatic products based on data mining, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus, and the memory is used to store a program for detecting the freshness of aquatic products based on data mining; the processor is used to implement the above-mentioned method for detecting the freshness of aquatic products based on data mining when executing the program stored in the memory.

[0093] The communication bus mentioned in the above-mentioned aquatic freshness detection device based on data mining can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc.

[0094] The communication interface is used for communication between the above-mentioned aquatic product freshness detection device based on data mining and other devices.

[0095] The memory may include a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.

[0096] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, and discrete hardware components.

[0097] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from a website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrated. The available medium may be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state drive Solid State Disk (SSD)), etc.

[0098] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0099] Each embodiment in this specification is described in a related manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0100] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

[0101] It should be understood that the above is only an example and does not constitute any limitation on the technical solution of the present invention. In specific applications, technicians in this field can make settings as needed, and the present invention does not limit this.

[0102] It should be noted that the workflow described above is merely illustrative and does not limit the scope of protection of the present invention. In practical applications, technicians in this field can select part or all of them according to actual needs to achieve the purpose of the present embodiment, and no limitation is made here.

[0103] In addition, for technical details not fully described in this embodiment, reference can be made to the aquatic product freshness detection method based on data mining provided in any embodiment of the present invention, which will not be described in detail here.

[0104] In addition, it should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.

[0105] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0106] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as a read-only memory (ROM) / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present invention.

[0107] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

[0108] It is understandable that the system provided by the embodiment of the present invention corresponds to the method provided by the embodiment of the present invention, and the explanation, examples and beneficial effects of the relevant contents can refer to the corresponding parts in the above method.

Claims

1. A method for detecting freshness of aquatic products based on data mining, characterized in that: The aquatic product freshness detection method based on data mining comprises: Acquire a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and acquisition methods; mining spectral feature data from the first image; Preprocessing the second image, and mining image feature data from the preprocessed image; Fusing the spectral feature data with the image feature data to obtain fused feature data; The freshness of the aquatic product to be detected is detected based on the fused feature data.

2. The method for detecting freshness of aquatic products based on data mining according to claim 1, characterized in that: The mining of spectral feature data from the first image includes: Performing dimensionality reduction and deblurring processing on the first image to obtain a reference first image; A preset proportion of training samples is selected from the hyperspectral data set, the data window size is set, and the sample categories are trained by an automatic encoder to establish a test sample set; Performing training optimization based on the test sample set and determining model parameters to establish a feature learning model; The original image depth feature is extracted from the first image through the feature learning model, and the original image depth feature is placed in the spatial information to obtain spectral feature data.

3. The method for detecting freshness of aquatic products based on data mining according to claim 1, characterized in that: The preprocessing of the second image comprises: Binarize the second image according to a preset threshold to obtain a binary image; Performing an opening operation on the binary image to remove redundant features at the edge; An image closing operation is performed on the redundant binary image to fill the hole area in the redundant binary image to obtain a preprocessed image.

4. The method for detecting freshness of aquatic products based on data mining according to claim 3, characterized in that: The mining of image feature data from the preprocessed image includes: The central pixel point is set to have a radius of one pixel, and a number of surrounding adjacent pixels form a local block of a preset size; Obtaining the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels from the preprocessed image; Calculating a local binary value according to the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels; The texture feature of the preprocessed image is extracted based on the local binary value to obtain image feature data.

5. The method for detecting freshness of aquatic products based on data mining according to claim 1, characterized in that: The step of fusing the spectral feature data with the image feature data to obtain fused feature data includes: Performing weighted summation according to the weights corresponding to the spectral feature data and the image feature data to obtain fused feature data; Or, converting the spectral feature data and the image feature data to the same dimension, and concatenating the spectral feature data and the image feature data in the same dimension to obtain fused feature data; Or, a fusion weight is determined using a preset conditional function, and the spectral feature data and the image feature data are fused according to the fusion weight to obtain fused feature data.

6. The method for detecting freshness of aquatic products based on data mining according to any one of claims 1 to 5, characterized in that: The freshness detection of the aquatic product to be detected based on the fused feature data includes: Determining the aquatic species of the aquatic product to be detected; Determine key detection areas based on the aquatic species in question; Determine the key features corresponding to the key detection area according to the fused feature data; Comparing the key features with preset features; The freshness of the aquatic product to be detected is detected based on the feature comparison result.

7. A device for detecting freshness of aquatic products based on data mining, characterized in that: The aquatic product freshness detection device based on data mining comprises: An acquisition module, used for acquiring a first image and a second image of the aquatic product to be detected, wherein the first image and the second image have different image types and acquisition methods; A mining module, used for mining spectral feature data from the first image; The mining module is used to preprocess the second image and mine image feature data from the preprocessed image; A fusion module, used for fusing the spectral feature data with the image feature data to obtain fused feature data; A detection module is used to perform freshness detection on the aquatic product to be detected based on the fused feature data.

8. The aquatic product freshness detection device based on data mining according to claim 7, characterized in that: The mining module is used to perform dimensionality reduction and deblurring processing on the first image to obtain a reference first image; A preset proportion of training samples is selected from the hyperspectral data set, the data window size is set, and the sample categories are trained by an automatic encoder to establish a test sample set; Performing training optimization based on the test sample set and determining model parameters to establish a feature learning model; The original image depth feature is extracted from the first image through the feature learning model, and the original image depth feature is placed in the spatial information to obtain spectral feature data.

9. The aquatic product freshness detection device based on data mining according to claim 7, characterized in that: The mining module is used to perform binarization processing on the second image according to a preset threshold value to obtain a binary image; Performing an opening operation on the binary image to remove redundant features at the edge; An image closing operation is performed on the redundant binary image to fill the hole area in the redundant binary image to obtain a preprocessed image.

10. The aquatic product freshness detection device based on data mining according to claim 9, characterized in that: The mining module is used to set the central pixel point to have a radius of one pixel and form a local block of a preset size with a number of surrounding adjacent pixels; Obtaining the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels from the preprocessed image; Calculating a local binary value according to the grayscale value of the central pixel and the grayscale values ​​of several surrounding adjacent pixels; The texture feature of the preprocessed image is extracted based on the local binary value to obtain image feature data.