Aquatic disease diagnosis method and device
By collecting images of water-generated objects and extracting edge and texture features, combined with convolutional neural network matching disease cases, the problem that breeders cannot accurately judge aquatic diseases is solved, and a highly accurate disease diagnosis is achieved.
Patent Information
- Application Number
- CN202411485799.8
- 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
The breeding personnel use their own experience to judge aquatic disease and are unable to accurately determine the type of disease of the breeding products, resulting in frequent misdiagnosis and increasing the cost and losses of aquaculture.
Aquatic disease diagnosis method is adopted to collect water-generated objects, extract edge features by combining direction gradient histograms, extract texture features using preset filters, match target disease case sets, and determine the disease type through convolutional neural network, and finally output Diagnostic results.
Accurate judgment of aquatic diseases is achieved, the accuracy of diagnosis is improved, and the misdiagnosis is reduced, thereby reducing the cost and losses of aquaculture.
Smart Images

Figure CN119445350A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of aquatic disease diagnosis, and in particular to an aquatic disease diagnosis method and device. Background Art
[0002] Aquatic diseases are an inevitable problem in the process of aquaculture. When a disease occurs, the safe and reliable method is to transport the diseased body to an expert for diagnosis, or ask an expert to perform on-site diagnosis. Due to the endless emergence of aquatic diseases in the breeding process, the disease analysis according to the above operation takes a long time, and the disease cannot be treated in time, resulting in high breeding costs. In order to solve this problem, breeders often judge aquatic diseases based on their own experience. Although this shortens the disease diagnosis time, due to the limitations of their own experience, they cannot accurately judge the type of disease of the farmed product, which can easily lead to misdiagnosis and bring greater losses to aquaculture.
[0003] However, the problem with the current method is that farmers rely on their own experience to judge aquatic diseases and are unable to accurately determine the type of disease in farmed products, which can easily lead to misdiagnosis and cause greater losses to aquaculture.
[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 diagnosing aquatic diseases, which aims to solve the technical problem that aquaculture personnel currently rely on their own experience to judge aquatic diseases, cannot accurately judge the disease type of the aquaculture products, easily lead to misdiagnosis, and bring greater losses to aquaculture.
[0006] To achieve the above object, the present invention provides a method for diagnosing aquatic diseases, which comprises the following steps:
[0007] Collect original aquatic biological images;
[0008] Extracting edge features of the original aquatic organism image by combining a directional gradient histogram of a partial area in the original aquatic organism image;
[0009] Extracting texture features in the aquatic organism image using a preset filter;
[0010] Matching a corresponding target disease case set based on the edge features and the texture features;
[0011] Determining the type of disease based on the edge feature and the texture feature;
[0012] A disease diagnosis result is output based on the disease case set and the disease type.
[0013] In some embodiments, extracting edge features of the original aquatic organism image by combining a directional gradient histogram of a partial area in the original aquatic organism image includes:
[0014] Compressing the original aquatic biological image based on a preset coefficient to obtain a grayscale image;
[0015] Calculating the gradient value of each pixel in the grayscale image;
[0016] Dividing the grayscale image into a plurality of cells of the same size, and constructing a corresponding gradient histogram for the pixels in each cell;
[0017] Merge multiple cells of the same size and normalize the gradient histogram within the cell to connect the features in each cell in series.
[0018] The overlapping parts of all unit features are combined to obtain the edge features of the original aquatic biological image.
[0019] In some embodiments, calculating the gradient value of each pixel in the grayscale image includes:
[0020] Obtain pixel values of two adjacent pixel points in the horizontal direction and pixel values of two adjacent pixel points in the vertical direction for each pixel point;
[0021] Determine the horizontal gradient of each pixel point according to the pixel values of two adjacent pixel points in the horizontal direction of each pixel point, and determine the vertical gradient of each pixel point according to the pixel values of two adjacent pixel points in the vertical direction of each pixel point;
[0022] A gradient value is determined based on the transverse gradient and the longitudinal gradient.
[0023] In some embodiments, the calculation formula of the lateral gradient is G x (x, y) = H(x+1, y) - H(x-1, y), where H(x+1, y) and H(x-1, y) are the pixel values of two adjacent pixels in the horizontal direction. The calculation formula of the longitudinal gradient is G y (x,y)=H(x,y+1)-H(x,y-1), where H(x,y+1) and H(x,y-1) are the pixel values of two adjacent pixels in the vertical direction. The gradient value is calculated as follows:
[0024]
[0025] In some embodiments, matching the corresponding target disease case set based on the edge feature and the texture feature includes:
[0026] Determining the similarity between the edge feature and the texture feature and each sample disease case, respectively, wherein each disease case includes the edge feature and texture feature corresponding to the disease;
[0027] Screening out sample disease cases whose similarities corresponding to the edge features and the texture features respectively exceed a preset similarity, so as to obtain a first disease case set;
[0028] Screening out a second disease case set from the first disease case set based on similarity order, wherein the second disease case set has a greater similarity to the edge feature and the texture feature than other disease cases;
[0029] The second disease case set is screened a second time to obtain a target disease case set.
[0030] In some embodiments, the second disease case set is screened again to obtain a target disease case set, including:
[0031] identifying a plurality of sub-disease case sets having the same disease type in the second disease case;
[0032] Determine, in each sub-disease case set, a sub-disease case having the greatest similarity with the edge feature and the texture feature;
[0033] The sub-disease cases with the greatest similarity are selected from each sub-disease case set to construct a target disease case set.
[0034] In some embodiments, determining the disease type based on the edge feature and the texture feature includes:
[0035] Inputting the edge features and the texture features into a preset convolutional neural network model;
[0036] Obtaining a plurality of classification probabilities corresponding to the output of the preset convolutional neural network model, wherein each classification probability corresponds to a disease type;
[0037] The disease type corresponding to the maximum classification probability is used as the disease type of the edge feature and the texture feature.
[0038] In addition, to achieve the above-mentioned purpose, the present invention also provides a device for diagnosing aquatic diseases, the device comprising:
[0039] An acquisition module, used for acquiring original aquatic biological images;
[0040] An extraction module, used for extracting edge features of the original aquatic organism image in combination with a directional gradient histogram of a partial area in the original aquatic organism image;
[0041] The extraction module is used to extract texture features in the aquatic organism image using a preset filter;
[0042] A matching module, used for matching a corresponding target disease case set based on the edge feature and the texture feature;
[0043] The matching module is used to determine the disease type based on the edge feature and the texture feature;
[0044] The diagnosis module is used to output a disease diagnosis result based on the disease case set and the disease type.
[0045] In some embodiments, the extraction module is used to compress the original aquatic biological image based on a preset coefficient to obtain a grayscale image;
[0046] Calculating the gradient value of each pixel in the grayscale image;
[0047] Dividing the grayscale image into a plurality of cells of the same size, and constructing a corresponding gradient histogram for the pixels in each cell;
[0048] Merge multiple cells of the same size and normalize the gradient histogram within the cell to connect the features in each cell in series.
[0049] The overlapping parts of all unit features are combined to obtain the edge features of the original aquatic biological image.
[0050] In some embodiments, the extraction module is used to obtain the pixel values of two adjacent pixel points of each pixel point in the horizontal direction, and the pixel values of two adjacent pixel points of each pixel point in the vertical direction;
[0051] Determine the horizontal gradient of each pixel point according to the pixel values of two adjacent pixel points in the horizontal direction of each pixel point, and determine the vertical gradient of each pixel point according to the pixel values of two adjacent pixel points in the vertical direction of each pixel point;
[0052] A gradient value is determined based on the transverse gradient and the longitudinal gradient.
[0053] The present invention collects original aquatic organism images; extracts edge features of the original aquatic organism images in combination with directional gradient histograms of partial areas in the original aquatic organism images; uses a preset filter to extract texture features in the aquatic organism images; matches corresponding target disease case sets based on the edge features and the texture features; determines disease types based on the edge features and the texture features; and outputs disease diagnosis results based on the disease case set and the disease type. The present invention uses image recognition technology to output diagnosis results based on edge features and texture features in the image in combination with the target disease case set and the disease type, thereby accurately determining the disease types of aquaculture products and improving the accuracy of diagnosis. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 It is a schematic diagram of the flow chart of the first embodiment of the aquatic disease diagnosis method of the present invention;
[0055] Figure 2 This is a structural block diagram of the first embodiment of the aquatic disease diagnosis device 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 present invention provides a method for diagnosing aquatic diseases. Figure 1 , Figure 1 This is a flow chart of a first embodiment of a method for diagnosing aquatic diseases according to the present invention.
[0059] In this embodiment, the aquatic disease diagnosis method comprises the following steps:
[0060] Step S10: Collecting original aquatic biological images.
[0061] In this embodiment, the executor of this embodiment is an aquatic disease diagnosis device, wherein the aquatic disease diagnosis device has functions such as data processing, data communication and program running. The aquatic disease diagnosis device 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 the problem with the current method is that farmers use their own experience to judge aquatic diseases and are unable to accurately determine the type of disease in the farmed products, which can easily lead to misdiagnosis and cause greater losses to aquaculture.
[0063] In order to solve the above technical problems, in this embodiment, original aquatic organism images are collected; edge features of the original aquatic organism images are extracted in combination with directional gradient histograms of partial areas in the original aquatic organism images; texture features in the aquatic organism images are extracted using preset filters; corresponding target disease case sets are matched based on the edge features and the texture features; disease types are determined based on the edge features and the texture features; disease diagnosis results are output based on the disease case set and the disease type. Image recognition technology is used to output diagnosis results based on edge features and texture features in the image in combination with the target disease case set and the disease type. The disease type of the aquaculture product can be accurately determined, thereby improving the accuracy of diagnosis. This can be specifically achieved in the following manner.
[0064] In a specific implementation, in this embodiment, it is necessary to first obtain the original aquatic organism image, which can be obtained by means of an underwater camera or the like.
[0065] Step S20: extracting edge features of the original aquatic organism image in combination with the directional gradient histogram of a partial area in the original aquatic organism image.
[0066] In the specific implementation, in order to reduce the impact of exposure on the image, the original aquatic biological image collected is compressed in this embodiment to obtain a grayscale image. The specific compression formula is: I'(x,y)=I(x,y) α , where α is the preset coefficient, which can be set to 0.5 and can be adjusted according to actual needs. I(x, y) represents the original aquatic image, and I'(x, y) is the grayscale image obtained after compression.
[0067] Next, the gradient value of each pixel in the grayscale image is calculated. The specific process is to obtain the pixel values of the two adjacent pixel points of each pixel in the horizontal direction and the pixel values of the two adjacent pixel points of each pixel in the vertical direction, determine the horizontal gradient of each pixel according to the pixel values of the two adjacent pixel points of each pixel in the horizontal direction, and determine the vertical gradient of each pixel according to the pixel values of the two adjacent pixel points of each pixel in the vertical direction, and determine the gradient value according to the horizontal gradient and the vertical gradient. The calculation formula of the horizontal gradient is G x (x,y)=H(x+1,y)-H(x-1,y), where H(x+1,y) and H(x-1,y) are the pixel values of two adjacent pixels in the horizontal direction, and the calculation formula of the vertical gradient is G y (x,y)=H(x,y+1)-H(x,y-1), where H(x,y+1) and H(x,y-1) are the pixel values of two adjacent pixels in the vertical direction. The gradient value is calculated as follows:
[0068] After calculating the gradient value, the grayscale image is divided into multiple cells of the same size, and the corresponding gradient histogram is constructed for the pixels in each cell. For example, the image is cut into m×n cells of the same size, and the number of pixels contained in each cell is m×m. The directional gradient histogram is made for the pixels in the grid. Assuming that m is 6, each cell is evenly divided into 9 histogram blocks to count the information of these 6*6 pixels. The bars of the histogram can use different colors to represent gradient values of different sizes, and then multiple cells of the same size are merged, and the gradient histogram in the cell is normalized to connect the features in each cell in series. It should be noted that this can reduce the impact of illumination on the image, and the gradient value is processed by the normalization method to avoid too large a difference in the gradient value. All cells are combined to obtain a spatially interconnected interval, so that the feature vectors of each cell inside it can be connected in series. Finally, all the overlapping parts of the unit features are combined to obtain a large feature vector. The features contained in the feature vector are also the edge features of the original aquatic organism image. The unit features are also the most basic and indivisible data representation of a feature space, and the partial area in the original aquatic organism image is also the area corresponding to the above-mentioned overlapping combination.
[0069] Step S30: extracting texture features in the aquatic organism image using a preset filter.
[0070] After the edge features are extracted, the present embodiment also needs to extract the texture features of the original aquatic biological image. Specifically, the present embodiment can use a preset filter to extract the texture features. The preset filter can be a Gabor filter. In practical applications, the direction of the filter can be adjusted to selectively respond to the texture in a specific direction in the image, or the frequency domain resolution of the filter can be adjusted to selectively respond to the texture of a specific frequency.
[0071] Step S40: matching a corresponding target disease case set based on the edge features and the texture features.
[0072] In the specific implementation, since each disease case contains the edge features and texture features corresponding to the disease, the similarity between the edge features and texture features and each sample disease case is first determined in this embodiment. For example, for disease case S, the extracted edge features and texture features are respectively compared with the edge features and texture features contained in disease case S in this embodiment, and the specific similarity is determined by Euclidean distance. Then, sample disease cases whose corresponding similarities of edge features and texture features exceed the preset similarity are screened out to obtain the first disease case set, wherein the preset similarity can be set to 80% or 90%, and can be specifically set according to the actual monitoring accuracy requirements, which is not limited in this embodiment.
[0073] After obtaining the first disease case set, in this embodiment, the second disease case set is further screened out from the first disease case set. The standard for screening the second disease case set is to sort the first disease case set according to the similarity, and determine several disease case sets with large similarity, that is, the second disease case set. The similarity between the second disease case set and the edge features and texture features is greater than that of the remaining disease cases. In practical applications, the first 10 disease case sets with large similarity, or the first 20% disease case sets with large similarity can be taken. The specific number can be selected according to actual needs, and this is not limited in this embodiment.
[0074] Finally, in this embodiment, the second disease case set needs to be screened again, that is, secondary screening, and finally the target disease case set can be obtained. The process of re-screening the second disease case set is specifically to identify several sub-disease case sets with the same disease type in the second disease case, and determine the sub-disease case with the greatest similarity between the edge feature and the texture feature in each sub-disease case set. Since the second disease case set has disease cases of the same disease type, in view of this situation, the method adopted in this embodiment is to retain the sub-disease case with the greatest similarity between the edge feature and the texture feature in the sub-disease case of the same disease type, and then eliminate other sub-disease cases of the same disease type to obtain the final target disease case set.
[0075] Step S50: determining the disease type based on the edge feature and the texture feature.
[0076] By extracting edge features and texture features from the original aquatic images, the disease type can be further determined in this embodiment. Specifically, the edge features and the texture features can be input into a preset convolutional neural network model, and then the preset convolutional neural network model outputs corresponding multiple classification probabilities, wherein each classification probability corresponds to a disease type, and finally the disease type corresponding to the maximum classification probability is used as the disease type of the edge features and the texture features.
[0077] It should be noted that, different from the existing convolutional neural network, the preset convolutional neural network in this embodiment uses small convolution kernels instead of traditional convolution kernels, specifically, uses 1*1 small convolution kernels to replace some traditional convolution kernels, but not all of them. The small convolution kernel and the traditional convolution kernel are combined, which not only reduces the impact on the accuracy of the recognition rate, but also greatly reduces the parameters in the model. The convolution layer that was originally one is divided into two parts, which are processed with a 1*1 convolution filter and then packaged into one part. In order to make the model lightweight and reduce the calculation time, while also ensuring the learning effect of deep learning, the preset convolutional neural network in this embodiment reduces some unimportant pooling layers.
[0078] Step S60: outputting a disease diagnosis result based on the disease case set and the disease type.
[0079] After determining the target disease case set and the disease type, since the target disease case set contains disease cases of various disease types, in this embodiment, matching disease cases can be found from the target disease case set according to the determined disease type. The output disease diagnosis results include not only the disease type but also the corresponding disease cases, which can not only accurately determine the disease type of the aquaculture product, but also enable users to understand the disease more clearly through actual disease cases to reduce losses.
[0080] This embodiment collects original aquatic organism images; extracts edge features of the original aquatic organism images in combination with directional gradient histograms of partial areas in the original aquatic organism images; uses a preset filter to extract texture features in the aquatic organism images; matches corresponding target disease case sets based on the edge features and the texture features; determines disease types based on the edge features and the texture features; and outputs disease diagnosis results based on the disease case set and the disease type. Image recognition technology is used to output diagnosis results based on edge features and texture features in the image in combination with the target disease case set and the disease type, so as to accurately determine the disease type of aquaculture products.
[0081] Reference Figure 2 , Figure 2 This is a structural block diagram of the first embodiment of the aquatic disease diagnosis device of the present invention.
[0082] like Figure 2 As shown, the aquatic disease diagnosis device proposed in the embodiment of the present invention includes:
[0083] The acquisition module 10 is used to acquire original aquatic biological images.
[0084] The extraction module 20 is used to extract edge features of the original aquatic organism image in combination with the directional gradient histogram of a partial area in the original aquatic organism image.
[0085] The extraction module 20 is used to extract texture features in the aquatic organism image using a preset filter.
[0086] The matching module 30 is used to match the corresponding target disease case set based on the edge feature and the texture feature.
[0087] The matching module 30 is used to determine the disease type based on the edge feature and the texture feature.
[0088] The diagnosis module 40 is used to output a disease diagnosis result based on the disease case set and the disease type.
[0089] This embodiment collects original aquatic organism images; extracts edge features of the original aquatic organism images in combination with oriented gradient histograms of partial areas in the original aquatic organism images; uses a preset filter to extract texture features in the aquatic organism images; matches corresponding target disease case sets based on the edge features and the texture features; determines disease types based on the edge features and the texture features; and outputs disease diagnosis results based on the disease case set and the disease type. Image recognition technology is used to output diagnosis results based on edge features and texture features in images in combination with the target disease case set and the disease type, so that the disease types of aquaculture products can be accurately determined, thereby improving the accuracy of diagnosis.
[0090] In some embodiments, the extraction module 20 is used to compress the original aquatic biological image based on a preset coefficient to obtain a grayscale image;
[0091] Calculating the gradient value of each pixel in the grayscale image;
[0092] Dividing the grayscale image into a plurality of cells of the same size, and constructing a corresponding gradient histogram for the pixels in each cell;
[0093] Merge multiple cells of the same size and normalize the gradient histogram within the cell to connect the features in each cell in series.
[0094] The overlapping parts of all unit features are combined to obtain the edge features of the original aquatic biological image.
[0095] In some embodiments, the extraction module 20 is used to obtain the pixel values of two adjacent pixel points of each pixel point in the horizontal direction, and the pixel values of two adjacent pixel points of each pixel point in the vertical direction;
[0096] Determine the horizontal gradient of each pixel point according to the pixel values of two adjacent pixel points in the horizontal direction of each pixel point, and determine the vertical gradient of each pixel point according to the pixel values of two adjacent pixel points in the vertical direction of each pixel point;
[0097] A gradient value is determined based on the transverse gradient and the longitudinal gradient.
[0098] In some embodiments, the calculation formula of the lateral gradient is G x (x, y) = H(x+1, y) - H(x-1, y), where H(x+1, y) and H(x-1, y) are the pixel values of two adjacent pixels in the horizontal direction. The calculation formula of the longitudinal gradient is G y (x,y)=H(x,y+1)-H(x,y-1), where H(x,y+1) and H(x,y-1) are the pixel values of two adjacent pixels in the vertical direction. The gradient value is calculated as follows:
[0099]
[0100] In some embodiments, the matching module 30 is used to determine the similarity between the edge feature and the texture feature and each sample disease case, wherein each disease case includes the edge feature and the texture feature corresponding to the disease;
[0101] Screening out sample disease cases whose similarities corresponding to the edge features and the texture features respectively exceed a preset similarity, so as to obtain a first disease case set;
[0102] Screening out a second disease case set from the first disease case set based on similarity order, wherein the second disease case set has a greater similarity to the edge feature and the texture feature than other disease cases;
[0103] The second disease case set is screened a second time to obtain a target disease case set.
[0104] In some embodiments, the matching module 30 is used to perform a secondary screening on the second disease case set to obtain a target disease case set, including:
[0105] identifying a plurality of sub-disease case sets having the same disease type in the second disease case;
[0106] Determine, in each sub-disease case set, a sub-disease case having the greatest similarity with the edge feature and the texture feature;
[0107] The sub-disease cases with the greatest similarity are selected from each sub-disease case set to construct a target disease case set.
[0108] In some embodiments, the matching module 30, for determining the disease type based on the edge feature and the texture feature, includes:
[0109] Inputting the edge features and the texture features into a preset convolutional neural network model;
[0110] Obtaining a plurality of classification probabilities corresponding to the output of the preset convolutional neural network model, wherein each classification probability corresponds to a disease type;
[0111] The disease type corresponding to the maximum classification probability is used as the disease type of the edge feature and the texture feature.
[0112] An embodiment of the present application also provides an aquatic disease diagnosis device, including a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus, and the memory is used to store an aquatic disease diagnosis program; the processor is used to implement the above-mentioned aquatic disease diagnosis method when executing the program stored in the memory.
[0113] The communication bus mentioned in the above-mentioned aquatic disease diagnosis equipment 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.
[0114] The communication interface is used for communication between the above-mentioned aquatic disease diagnosis equipment and other equipment.
[0115] 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.
[0116] 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.
[0117] 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.
[0118] 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.
[0119] 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.
[0120] 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.
[0121] 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.
[0122] 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.
[0123] In addition, for technical details not fully described in this embodiment, reference can be made to the aquatic disease diagnosis method provided in any embodiment of the present invention, and will not be repeated here.
[0124] 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.
[0125] 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.
[0126] 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.
[0127] 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.
[0128] 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 diagnosing aquatic diseases, characterized in that: The aquatic disease diagnosis method comprises: Collect original aquatic biological images; Extracting edge features of the original aquatic organism image by combining a directional gradient histogram of a partial area in the original aquatic organism image; Extracting texture features in the aquatic organism image using a preset filter; Matching a corresponding target disease case set based on the edge features and the texture features; Determining the type of disease based on the edge feature and the texture feature; A disease diagnosis result is output based on the disease case set and the disease type.
2. The method for diagnosing aquatic diseases according to claim 1, characterized in that: The step of extracting edge features of the original aquatic organism image by combining a directional gradient histogram of a partial area in the original aquatic organism image comprises: Compressing the original aquatic biological image based on a preset coefficient to obtain a grayscale image; Calculating the gradient value of each pixel in the grayscale image; Dividing the grayscale image into a plurality of cells of the same size, and constructing a corresponding gradient histogram for the pixels in each cell; Merge multiple cells of the same size and normalize the gradient histogram within the cell to connect the features in each cell in series. The overlapping parts of all unit features are combined to obtain the edge features of the original aquatic biological image.
3. The method for diagnosing aquatic diseases according to claim 2, characterized in that: The step of calculating the gradient value of each pixel in the grayscale image comprises: Obtain pixel values of two adjacent pixel points in the horizontal direction and pixel values of two adjacent pixel points in the vertical direction for each pixel point; Determine the lateral gradient of each pixel point according to the pixel values of two adjacent pixel points in the lateral direction of each pixel point, and determine the longitudinal gradient of each pixel point according to the pixel values of two adjacent pixel points in the longitudinal direction of each pixel point; A gradient value is determined based on the transverse gradient and the longitudinal gradient.
4. The method for diagnosing aquatic diseases according to claim 3, characterized in that: The calculation formula of the transverse gradient is G x (x, y) = H(x+1, y) - H(x-1, y), where H(x+1, y) and H(x-1, y) are the pixel values of two adjacent pixels in the horizontal direction. The calculation formula of the longitudinal gradient is G y (x,y)=H(x,y+1)-H(x,y-1), where H(x,y+1) and H(x,y-1) are the pixel values of two adjacent pixels in the vertical direction. The gradient value is calculated as follows:
5. The method for diagnosing aquatic diseases according to claim 1, characterized in that: The matching of the corresponding target disease case set based on the edge feature and the texture feature includes: Determining the similarity between the edge feature and the texture feature and each sample disease case, respectively, wherein each disease case includes the edge feature and texture feature corresponding to the disease; Screening out sample disease cases whose similarities corresponding to the edge features and the texture features respectively exceed a preset similarity, so as to obtain a first disease case set; Screening out a second disease case set from the first disease case set based on similarity order, wherein the second disease case set has a greater similarity to the edge feature and the texture feature than other disease cases; The second disease case set is screened a second time to obtain a target disease case set.
6. The method for diagnosing aquatic diseases according to claim 5, characterized in that: The second disease case set is screened again to obtain a target disease case set, including: identifying a plurality of sub-disease case sets having the same disease type in the second disease case; Determine, in each sub-disease case set, a sub-disease case having the greatest similarity with the edge feature and the texture feature; The sub-disease cases with the greatest similarity are selected from each sub-disease case set to construct a target disease case set.
7. The method for diagnosing aquatic diseases according to any one of claims 1 to 6, characterized in that: The determining of the disease type based on the edge feature and the texture feature comprises: Inputting the edge features and the texture features into a preset convolutional neural network model; Obtaining a plurality of classification probabilities corresponding to the output of the preset convolutional neural network model, wherein each classification probability corresponds to a disease type; The disease type corresponding to the maximum classification probability is used as the disease type of the edge feature and the texture feature.
8. A device for diagnosing aquatic diseases, characterized in that: The aquatic disease diagnosis device comprises: An acquisition module, used for acquiring original aquatic biological images; An extraction module, used for extracting edge features of the original aquatic organism image in combination with a directional gradient histogram of a partial area in the original aquatic organism image; The extraction module is used to extract texture features in the aquatic organism image using a preset filter; A matching module, used for matching a corresponding target disease case set based on the edge feature and the texture feature; The matching module is used to determine the disease type based on the edge feature and the texture feature; The diagnosis module is used to output a disease diagnosis result based on the disease case set and the disease type.
9. The aquatic disease diagnosis device according to claim 8, characterized in that: The extraction module is used to compress the original aquatic biological image based on a preset coefficient to obtain a grayscale image; Calculating the gradient value of each pixel in the grayscale image; Dividing the grayscale image into a plurality of cells of the same size, and constructing a corresponding gradient histogram for the pixels in each cell; Merge multiple cells of the same size and normalize the gradient histogram within the cell to connect the features in each cell in series. The overlapping parts of all unit features are combined to obtain the edge features of the original aquatic biological image.
10. The aquatic disease diagnosis device according to claim 9, characterized in that: The extraction module is used to obtain the pixel values of two adjacent pixel points in the horizontal direction of each pixel point, and the pixel values of two adjacent pixel points in the vertical direction of each pixel point; Determine the lateral gradient of each pixel point according to the pixel values of two adjacent pixel points in the lateral direction of each pixel point, and determine the longitudinal gradient of each pixel point according to the pixel values of two adjacent pixel points in the longitudinal direction of each pixel point; A gradient value is determined based on the transverse gradient and the longitudinal gradient.