Aquaculture environment monitoring method and device

By building a BP neural network and optimizing its parameters using PSO algorithm, a water environment monitoring model was established, which solved the problem of relying on subjective experience in the existing technology, and improved the accuracy and supervision efficiency of monitoring.

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

Patent Information

Application Number
CN202411485798.3
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

The existing aquaculture environmental monitoring methods rely on the subjective experience of aquaculture personnel and lack scientific data comparison and analysis, resulting in insufficient accuracy and reliability, affecting regulatory efficiency.

Method used

By obtaining the original water body data collected by the water quality sensor, conducting outlier value detection and processing, building a BP neural network and optimizing its connection weights and thresholds using the PSO algorithm, establishing a water body environment monitoring model, and then realizing automated monitoring.

Benefits of technology

It improves the accuracy and reliability of aquaculture environmental monitoring, reduces the dependence on the subjective experience of aquaculture personnel, and improves the efficiency of aquaculture supervision.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119441874A_ABST
    Figure CN119441874A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of environment monitoring, and discloses an aquaculture environment monitoring method and device. The method comprises the following steps: acquiring original water body data acquired by a water quality sensor; carrying out abnormal value detection on the original water body data; processing the original water body data based on the detection result to obtain processed water body data; constructing a BP neural network, and optimizing a connection weight and a threshold value of the BP neural network by using a PSO algorithm to train the sample water body data to obtain a water body environment monitoring model; and inputting the processed water body data into the water body environment monitoring model to obtain a monitoring result output by the water body environment monitoring model, combining the PSO algorithm with the BP neural network to construct the water body environment monitoring model in the above mode, and through scientific data comparison and analysis, the accuracy of monitoring is ensured without relying on subjective experience judgment of aquaculture personnel, and the accuracy of monitoring is improved. And meanwhile, the aquaculture supervision efficiency is also improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of environmental monitoring, and in particular to an aquaculture environment monitoring method and device. Background Art

[0002] High-density aquaculture has very high requirements for the aquaculture water environment. If the water quality is poor, it will affect the growth of aquatic products, be detrimental to their growth and reproduction, and even cause large-scale death of aquatic products, seriously affecting economic benefits. Therefore, the water environment is crucial to the growth and development of aquatic products.

[0003] At present, aquaculture environmental monitoring is mainly completed by supplementing water quality sensor detection and focusing on aquaculture experience. Farmers need to judge abnormal changes in the aquaculture water environment based on corresponding sensor detection data and real-time observations, and take corresponding countermeasures based on abnormal changes to avoid economic losses. However, this method is time-consuming and labor-intensive, relies more on the subjective experience of farmers, lacks scientific data comparison and analysis, is prone to misjudgment, lacks accuracy and reliability, and is not conducive to improving the efficiency of aquaculture supervision.

[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 an aquaculture environment monitoring method and device, aiming to solve the technical problems that the current method is time-consuming and labor-intensive, relies heavily on the subjective experience and judgment of farmers, lacks scientific data comparison and analysis, is prone to misjudgment, lacks accuracy and reliability, and is not conducive to improving the efficiency of aquaculture supervision.

[0006] To achieve the above object, the present invention provides an aquaculture environment monitoring method, which comprises the following steps:

[0007] Obtain the original water body data collected by the water quality sensor;

[0008] Performing outlier detection on the original water body data;

[0009] Processing the original water body data based on the detection result to obtain processed water body data;

[0010] Constructing a BP neural network, and using a PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train sample water body data to obtain a water body environment monitoring model;

[0011] The processed water body data is input into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model.

[0012] In some embodiments, the performing outlier detection on the raw water body data includes:

[0013] Sorting the original water body data in descending order;

[0014] Based on the sorting result, the original water body data is divided according to a preset ratio to obtain a first quartile, a median, and a second quartile;

[0015] determining an interquartile range based on the first quartile and the second quartile;

[0016] Determine a lower limit value of the original water body data according to the first quartile and the interquartile range, and determine an upper limit value of the original water body data according to the second quartile and the interquartile range;

[0017] Constructing a data distribution graph according to the first quartile, the median, the second quartile, the lower limit value, and the upper limit value;

[0018] The data distribution graph is used to perform outlier detection on the original water body data.

[0019] In some embodiments, the processing of the raw water body data based on the detection result to obtain processed water body data includes:

[0020] Based on the detection results, outliers contained in the original water body data are eliminated to obtain reference water body data;

[0021] Identifying water body data collected by water quality sensors of the same type as the reference water body data;

[0022] Calculate the mean square error corresponding to each of the water body data collected by the water quality sensors of the same type;

[0023] Taking the minimum weighting factor as a variable, constructing a functional relationship corresponding to the total mean square error based on the mean square error;

[0024] Solving the extreme value of the functional relationship to obtain the minimum weighting factor corresponding to each of the water quality sensors of the same type when the total mean square error is minimized;

[0025] The water body data collected by the water quality sensors of the same type are fused based on the minimum weighting factor to obtain processed water body data.

[0026] In some embodiments, the constructing of the BP neural network includes:

[0027] Initialize the number of neurons in the input layer, the number of neurons in the hidden layer, and the number of neurons in the output layer;

[0028] Determine the connection weights between each input layer neuron and each hidden layer neuron, and the connection weights between each hidden layer neuron and each output layer neuron;

[0029] Determine the threshold of each hidden layer neuron and the threshold of each output layer neuron;

[0030] A BP neural network is constructed according to the number of input layer neurons, the number of hidden layer neurons, the number of output layer neurons, the connection weights between each input layer neuron and each hidden layer neuron, the connection weights between each hidden layer neuron and each output layer neuron, the threshold of each hidden layer neuron and the threshold of each output layer neuron.

[0031] In some embodiments, the method of using the PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train the sample water body data to obtain a water body environment monitoring model includes:

[0032] Determine the particles of the PSO algorithm according to the connection weights and the initial value of the threshold in the BP neural network;

[0033] Determining the dimension of the particle according to the number of weights and thresholds;

[0034] Obtaining a root mean square error between an actual output and an expected output of the sample water body data in the BP neural network;

[0035] Determining a fitness function according to the particle, the dimension of the particle, and the root mean square error;

[0036] The connection weights and thresholds of the BP neural network are optimized according to the fitness function, and the sample water body data are trained using the optimized connection weights and thresholds to obtain a water body environment monitoring model.

[0037] In some embodiments, the optimizing the connection weights and thresholds of the BP neural network according to the fitness function includes:

[0038] Determine the fitness value of each particle according to the fitness function;

[0039] Determine the optimal position of each particle according to the fitness value;

[0040] Determining a global optimal position of the population based on the optimal positions of the individual particles;

[0041] Performing vector decoding on the global optimal position to obtain a target connection weight and a target threshold;

[0042] The connection weight and threshold of the BP neural network are optimized by using the target connection weight and the target threshold.

[0043] In some embodiments, the step of obtaining a root mean square error between an actual output and an expected output of the sample water body data in the BP neural network comprises:

[0044] Determining the sample quantity of the sample water body data;

[0045] Determine the actual output and expected output of obtaining the sample water body data based on the BP neural network;

[0046] The root mean square error is calculated according to the sample quantity, the actual output and the expected output, and the calculation formula is:

[0047]

[0048] Wherein, n is the number of samples, y1 is the expected output, and y2 is the actual output.

[0049] In addition, to achieve the above-mentioned purpose, the present invention also proposes an aquaculture environment monitoring device, the aquaculture environment monitoring device comprising:

[0050] The acquisition module is used to obtain the original water body data collected by the water quality sensor;

[0051] A detection module, used for performing outlier detection on the raw water body data;

[0052] A processing module, used for processing the raw water body data based on the detection result to obtain processed water body data;

[0053] A training module is used to construct a BP neural network, and use a PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train sample water body data to obtain a water body environment monitoring model;

[0054] The monitoring module is used to input the processed water body data into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model.

[0055] In some embodiments, the detection module is used to sort the raw water body data in order from large to small;

[0056] Based on the sorting result, the original water body data is divided according to a preset ratio to obtain a first quartile, a median, and a second quartile;

[0057] determining an interquartile range based on the first quartile and the second quartile;

[0058] Determine a lower limit value of the original water body data according to the first quartile and the interquartile range, and determine an upper limit value of the original water body data according to the second quartile and the interquartile range;

[0059] Constructing a data distribution graph according to the first quartile, the median, the second quartile, the lower limit value, and the upper limit value;

[0060] The data distribution graph is used to perform outlier detection on the original water body data.

[0061] In some embodiments, the processing module is used to remove abnormal values ​​contained in the original water body data based on the detection results to obtain reference water body data;

[0062] Identifying water body data collected by water quality sensors of the same type as the reference water body data;

[0063] Calculate the mean square error corresponding to each of the water body data collected by the water quality sensors of the same type;

[0064] Taking the minimum weighting factor as a variable, constructing a functional relationship corresponding to the total mean square error based on the mean square error;

[0065] Solving the extreme value of the functional relationship to obtain the minimum weighting factor corresponding to each of the water quality sensors of the same type when the total mean square error is minimized;

[0066] The water body data collected by the water quality sensors of the same type are fused based on the minimum weighting factor to obtain processed water body data.

[0067] The present invention obtains original water body data collected by a water quality sensor; performs outlier detection on the original water body data; processes the original water body data based on the detection result to obtain processed water body data; constructs a BP neural network, and uses a PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train sample water body data to obtain a water body environment monitoring model; inputs the processed water body data into the water body environment monitoring model to obtain monitoring results output by the water body environment monitoring model. The PSO algorithm is combined with the BP neural network in the above manner to construct a water body environment monitoring model. Through scientific data comparison and analysis, there is no need to rely on the subjective experience of aquaculture personnel, thereby ensuring the accuracy of monitoring and improving the efficiency of aquaculture supervision. BRIEF DESCRIPTION OF THE DRAWINGS

[0068] Figure 1 It is a schematic diagram of the process of the first embodiment of the aquaculture environment monitoring method of the present invention;

[0069] Figure 2This is a schematic diagram of data distribution in the aquaculture environment monitoring method of the present invention;

[0070] Figure 3 This is a structural block diagram of the first embodiment of the aquaculture environment monitoring device of the present invention.

[0071] 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

[0072] 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.

[0073] The embodiment of the present invention provides a method for monitoring an aquaculture environment. Figure 1 , Figure 1 It is a schematic flow chart of a first embodiment of an aquaculture environment monitoring method of the present invention.

[0074] In this embodiment, the aquaculture environment monitoring method comprises the following steps:

[0075] Step S10: Acquire the original water body data collected by the water quality sensor.

[0076] In this embodiment, the executor of this embodiment is an aquaculture environment monitoring device, wherein the aquaculture environment monitoring device has functions such as data processing, data communication and program running. The aquaculture environment monitoring 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.

[0077] It should be noted that the current aquaculture environmental monitoring is mainly completed by supplementing water quality sensor detection and relying mainly on aquaculture experience. Farmers need to judge abnormal changes in the aquaculture water environment based on corresponding sensor detection data and real-time observations, and take corresponding countermeasures based on abnormal changes to avoid economic losses. However, this method is time-consuming and labor-intensive, relies more on the subjective experience of farmers, lacks scientific data comparison and analysis, is prone to misjudgment, lacks accuracy and reliability, and is not conducive to improving the efficiency of aquaculture supervision.

[0078] In order to solve the above technical problems, in this embodiment, the original water body data collected by the water quality sensor is obtained; outlier detection is performed on the original water body data; the original water body data is processed based on the detection results to obtain processed water body data; a BP neural network is constructed, and the connection weights and thresholds of the BP neural network are optimized by the PSO algorithm to train the sample water body data to obtain a water body environment monitoring model; the processed water body data is input into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model. The PSO algorithm is combined with the BP neural network in the above manner to construct a water body environment monitoring model. Through scientific data comparison and analysis, there is no need to rely on the subjective experience and judgment of the breeding personnel, which ensures the accuracy of monitoring and improves the efficiency of aquaculture supervision. Specifically, it can be achieved as follows.

[0079] In a specific implementation, a plurality of water quality sensors are provided in an aquaculture area, each of which is provided at a different monitoring point, and several water quality sensors are of the same type. In this embodiment, before performing water environment monitoring, it is necessary to first obtain the original water data collected by the water quality sensor.

[0080] Step S20: performing outlier detection on the original water body data.

[0081] In the aquaculture environment monitoring system, the water quality sensors are generally placed in relatively complex waters, and are affected by the disturbance of fish in the water and large equipment such as water pumps and oxygen pumps. The data collected by the sensors may have some abnormal values, which will have an adverse effect on the subsequent data processing and analysis. Therefore, in this embodiment, after obtaining the original water body data, it is necessary to perform abnormality detection on the original water body data.

[0082] The specific process of outlier detection is to sort the original water body data in order from large to small; divide the original water body data according to a preset ratio based on the sorting result to obtain a first quartile, a median and a second quartile; determine the interquartile range according to the first quartile and the second quartile; determine the lower limit value of the original water body data according to the first quartile and the interquartile range, and determine the upper limit value of the original water body data according to the second quartile and the interquartile range; construct a data distribution map according to the first quartile, the median, the second quartile, the lower limit value and the upper limit value; and use the data distribution map to perform outlier detection on the original water body data.

[0083] It should be noted that after sorting the original water body data, the first 25%, 50%, and 75% of the sorted data can be determined in this embodiment, that is, the corresponding preset proportions, the first quartile, the median, and the second quartile are the first 25%, 50%, and 75% of the data, respectively. Assuming that the first quartile, the median, and the second quartile are Q1, Q2, and Q3, respectively, the interquartile range is IQR=Q3-Q1, the upper limit is Q4=Q3+1.5IQR, and the lower limit is Q5=Q1-1.5IQR. The constructed data distribution diagram is as follows: Figure 2 As shown, those outside Q4 and Q5 are outliers.

[0084] Step S30: Processing the original water body data based on the detection result to obtain processed water body data.

[0085] After completing the outlier detection, in this embodiment, it is necessary to eliminate the outliers contained in the original water body data based on the detection results to obtain reference water body data, and then further process the reference water body. The specific process is to identify the water body data collected by the same type of water quality sensors in the reference water body data; calculate the mean square error corresponding to each of the water body data collected by the same type of water quality sensors; construct a functional relationship corresponding to the total mean square error based on the mean square error with the minimum weighting factor as a variable; solve the extreme value of the functional relationship to obtain the minimum weighting factor corresponding to each of the water quality sensors of the same type when the total mean square error is minimized; and fuse the water body data collected by the same type of water quality sensors based on the minimum weighting factor to obtain processed water body data.

[0086] It should be noted that the constructed functional relationship is Among them, σ represents the total mean square error, ω i Represents the weighting factors corresponding to the same type of water quality sensors, σ i Represents the mean square error corresponding to each water body data collected by the same type of water quality sensor. By solving the minimum value of the above functional relationship, the minimum weighting factor corresponding to each water quality sensor of the same type can be obtained. The data fusion in this embodiment is for water body data collected by the same type of water quality sensor, that is, the water body data collected by the same type of water quality sensor is weighted according to the minimum weighting factor, and finally the processed water body data can be obtained.

[0087] Step S40: constructing a BP neural network, and using the PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train the sample water body data to obtain a water body environment monitoring model.

[0088] It should be noted that, in this embodiment, the BP neural network is optimized by the PSO algorithm to obtain the final water environment monitoring model. Specifically, the process of constructing the BP neural network is to initialize the number of input layer neurons, the number of hidden layer neurons and the number of output layer neurons; determine the connection weights between each input layer neuron and each hidden layer neuron, and the connection weights between each hidden layer neuron and each output layer neuron; determine the threshold of each hidden layer neuron and the threshold of each output layer neuron; construct the BP neural network according to the number of input layer neurons, the number of hidden layer neurons, the number of output layer neurons, the connection weights between each input layer neuron and each hidden layer neuron, the connection weights between each hidden layer neuron and each output layer neuron, the threshold of each hidden layer neuron and the threshold of each output layer neuron, the above connection weights and thresholds are initial values, which can be selected according to actual needs, and are not limited in this embodiment, and due to the optimization of the PSO algorithm, the selection of the initial value does not affect the accuracy of the subsequent water environment monitoring model.

[0089] The optimization process is specifically to determine the particles of the PSO algorithm according to the initial values ​​of the connection weights and thresholds in the BP neural network, determine the dimensions of the particles according to the number of weights and thresholds, and obtain the root mean square error between the actual output and the expected output of the sample water body data in the BP neural network. The root mean square error calculation process is to determine the number of samples of the sample water body data, determine the actual output and expected output of the sample water body data based on the BP neural network, the actual output is obtained after the sample data is input into the BP neural network, and the expected output is the output set based on actual needs. The root mean square error is calculated according to the number of samples, the actual output and the expected output. The calculation formula is:

[0090]

[0091] Wherein, n is the number of samples, y1 is the expected output, and y2 is the actual output.

[0092] Then, the fitness function is determined according to the particles, their dimensions, and the root mean square error. Specifically, assuming that there are N particles forming a population, the dimension of each particle is D, and the position of the i-th particle can be expressed as: X i =x i1 ,x i2 ,...,x iD , where i = 1, 2, ..., N, and the fitness function is The process of further optimizing the connection weights and thresholds of the BP neural network according to the fitness function is specifically to determine the fitness value of each particle according to the fitness function, and to determine the optimal position of each particle according to the fitness value. In the fitness function, X represents the position of the particle. The optimal position of each particle can be determined by the fitness function, and then the global optimal position of the population is determined based on the optimal position of each particle. Each particle knows the optimal position and uses it as a reference to guide its own search direction. Each particle iteratively updates its own position through the determined optimal position. After each particle determines the optimal position, the optimal position of the entire population can be determined. The corresponding vector of the global optimal position is composed of the connection weight and The threshold composition, for example, S = [w1, b1, w2, b2, w3, b3], wherein w1 represents the connection weight between the input layer and the first hidden layer, w2 represents the connection weight between the input layer and the second hidden layer, w3 represents the connection weight between the hidden layer and the output layer, b1 represents the threshold of the first hidden layer, b2 represents the threshold of the second hidden layer, and b3 represents the threshold of the output layer. Finally, the global optimal position is vector decoded to obtain the target connection weight and target threshold. The connection weight and threshold of the BP neural network are optimized by the target connection weight and target threshold, and the sample water body data are trained using the optimized connection weight and threshold to obtain a water body environment monitoring model.

[0093] Step S50: inputting the processed water body data into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model.

[0094] After completing the construction of the water environment monitoring model, the processed water data is input into the water environment monitoring model to obtain the water environment monitoring results. The water environment monitoring results include the oxygen content, pH value and temperature of the water body. Furthermore, after obtaining these results, the corresponding numerical range can be set. If it is not within the corresponding numerical range, the corresponding alarm prompt is output. The specific numerical range is set based on the requirements of the aquaculture environment, and this is not limited in this embodiment.

[0095] This embodiment obtains the original water body data collected by the water quality sensor; performs outlier detection on the original water body data; processes the original water body data based on the detection results to obtain processed water body data; constructs a BP neural network, and uses the PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train the sample water body data to obtain a water body environment monitoring model; inputs the processed water body data into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model. The PSO algorithm is combined with the BP neural network in the above manner to construct a water body environment monitoring model. Through scientific data comparison and analysis, there is no need to rely on the subjective experience of the aquaculture personnel, which ensures the accuracy of monitoring and also improves the efficiency of aquaculture supervision.

[0096] Reference Figure 3 , Figure 3 This is a structural block diagram of the first embodiment of the aquaculture environment monitoring device of the present invention.

[0097] like Figure 3 As shown, the aquaculture environment monitoring device proposed in the embodiment of the present invention includes:

[0098] The acquisition module 10 is used to obtain the original water body data collected by the water quality sensor.

[0099] The detection module 20 is used to perform outlier detection on the original water body data.

[0100] The processing module 30 is used to process the original water body data based on the detection result to obtain processed water body data.

[0101] The training module 40 is used to construct a BP neural network, and use the PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train the sample water body data to obtain a water body environment monitoring model.

[0102] The monitoring module 50 is used to input the processed water body data into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model.

[0103] This embodiment obtains the original water body data collected by the water quality sensor; performs outlier detection on the original water body data; processes the original water body data based on the detection results to obtain processed water body data; constructs a BP neural network, and uses the PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train the sample water body data to obtain a water body environment monitoring model; inputs the processed water body data into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model. The PSO algorithm is combined with the BP neural network in the above manner to construct a water body environment monitoring model. Through scientific data comparison and analysis, there is no need to rely on the subjective experience of the aquaculture personnel, which ensures the accuracy of monitoring and also improves the efficiency of aquaculture supervision.

[0104] In some embodiments, the detection module 20 is used to sort the raw water body data in order from large to small; divide the raw water body data according to a preset ratio based on the sorting result to obtain a first quartile, a median and a second quartile; determine the interquartile range according to the first quartile and the second quartile; determine the lower limit value of the raw water body data according to the first quartile and the interquartile range, and determine the upper limit value of the raw water body data according to the second quartile and the interquartile range; construct a data distribution map according to the first quartile, the median, the second quartile, the lower limit value and the upper limit value; and use the data distribution map to detect outliers on the raw water body data.

[0105] In some embodiments, the processing module 30 is used to eliminate the abnormal values ​​contained in the original water body data based on the detection results to obtain reference water body data; identify the water body data collected by the same type of water quality sensors in the reference water body data; calculate the mean square error corresponding to each of the water body data collected by the same type of water quality sensors; construct a functional relationship corresponding to the total mean square error based on the mean square error with the minimum weighting factor as a variable; solve the extreme value of the functional relationship to obtain the minimum weighting factor corresponding to each of the water quality sensors of the same type when the total mean square error is minimized; and fuse the water body data collected by the same type of water quality sensors based on the minimum weighting factor to obtain processed water body data.

[0106] In some embodiments, the training module 40 is used to initialize the number of input layer neurons, the number of hidden layer neurons and the number of output layer neurons; determine the connection weights between each input layer neuron and each hidden layer neuron, and the connection weights between each hidden layer neuron and each output layer neuron; determine the threshold of each hidden layer neuron and the threshold of each output layer neuron; and construct a BP neural network based on the number of input layer neurons, the number of hidden layer neurons, the number of output layer neurons, the connection weights between each input layer neuron and each hidden layer neuron, the connection weights between each hidden layer neuron and each output layer neuron, the threshold of each hidden layer neuron and the threshold of each output layer neuron.

[0107] In some embodiments, the training module 40 is used to determine the particles of the PSO algorithm according to the initial values ​​of the connection weights and thresholds in the BP neural network; determine the dimensions of the particles according to the number of weights and thresholds; obtain the root mean square error between the actual output and the expected output of the sample water body data in the BP neural network; determine the fitness function according to the particles, the dimensions of the particles and the root mean square error; optimize the connection weights and thresholds of the BP neural network according to the fitness function, and use the optimized connection weights and thresholds to train the sample water body data to obtain a water environment monitoring model.

[0108] In some embodiments, the training module 40 is used to determine the fitness value of each particle according to the fitness function; determine the optimal position of each particle according to the fitness value; determine the global optimal position of the population based on the optimal position of each particle; perform vector decoding on the global optimal position to obtain target connection weights and target thresholds; and optimize the connection weights and thresholds of the BP neural network through the target connection weights and the target thresholds.

[0109] In some embodiments, the training module 40 is used to determine the sample size of the sample water body data; determine the actual output and expected output of the sample water body data based on the BP neural network; calculate the root mean square error according to the sample size, the actual output and the expected output, and the calculation formula is:

[0110]

[0111] Wherein, n is the number of samples, y1 is the expected output, and y2 is the actual output.

[0112] An embodiment of the present application also provides an aquaculture environment monitoring 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 aquaculture environment monitoring program; the processor is used to implement the above-mentioned aquaculture environment monitoring method when executing the program stored in the memory.

[0113] The communication bus mentioned in the above-mentioned aquaculture environment monitoring 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 aquaculture environment monitoring 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 aquaculture environment monitoring 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 monitoring an aquaculture environment, characterized in that: The aquaculture environment monitoring method comprises: Obtain the original water body data collected by the water quality sensor; Performing outlier detection on the original water body data; Processing the original water body data based on the detection result to obtain processed water body data; Constructing a BP neural network, and using a PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train sample water body data to obtain a water body environment monitoring model; The processed water body data is input into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model.

2. The aquaculture environment monitoring method according to claim 1, characterized in that: The performing outlier detection on the original water body data comprises: Sorting the original water body data in descending order; Based on the sorting result, the original water body data is divided according to a preset ratio to obtain a first quartile, a median, and a second quartile; determining an interquartile range based on the first quartile and the second quartile; Determine a lower limit value of the original water body data according to the first quartile and the interquartile range, and determine an upper limit value of the original water body data according to the second quartile and the interquartile range; Constructing a data distribution graph according to the first quartile, the median, the second quartile, the lower limit value, and the upper limit value; The data distribution graph is used to perform outlier detection on the original water body data.

3. The aquaculture environment monitoring method according to claim 1, characterized in that: The processing of the original water body data based on the detection result to obtain processed water body data includes: Based on the detection results, outliers contained in the original water body data are eliminated to obtain reference water body data; Identifying water body data collected by water quality sensors of the same type as the reference water body data; Calculate the mean square error corresponding to each of the water body data collected by the water quality sensors of the same type; Taking the minimum weighting factor as a variable, constructing a functional relationship corresponding to the total mean square error based on the mean square error; Solving the extreme value of the functional relationship to obtain the minimum weighting factor corresponding to each of the water quality sensors of the same type when the total mean square error is minimized; The water body data collected by the water quality sensors of the same type are fused based on the minimum weighting factor to obtain processed water body data.

4. The aquaculture environment monitoring method according to claim 1, characterized in that: The BP neural network is constructed, comprising: Initialize the number of neurons in the input layer, the number of neurons in the hidden layer, and the number of neurons in the output layer; Determine the connection weights between each input layer neuron and each hidden layer neuron, and the connection weights between each hidden layer neuron and each output layer neuron; Determine the threshold of each hidden layer neuron and the threshold of each output layer neuron; A BP neural network is constructed according to the number of input layer neurons, the number of hidden layer neurons, the number of output layer neurons, the connection weights between each input layer neuron and each hidden layer neuron, the connection weights between each hidden layer neuron and each output layer neuron, the threshold of each hidden layer neuron and the threshold of each output layer neuron.

5. The aquaculture environment monitoring method according to claim 4, characterized in that: The method of using the PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train the sample water body data to obtain a water body environment monitoring model includes: Determine the particles of the PSO algorithm according to the connection weights and the initial value of the threshold in the BP neural network; Determining the dimension of the particle according to the number of weights and thresholds; Obtaining a root mean square error between an actual output and an expected output of the sample water body data in the BP neural network; Determining a fitness function according to the particle, the dimension of the particle, and the root mean square error; The connection weights and thresholds of the BP neural network are optimized according to the fitness function, and the sample water body data are trained using the optimized connection weights and thresholds to obtain a water body environment monitoring model.

6. The aquaculture environment monitoring method according to claim 5, characterized in that: The step of optimizing the connection weights and thresholds of the BP neural network according to the fitness function includes: Determine the fitness value of each particle according to the fitness function; Determine the optimal position of each particle according to the fitness value; Determining a global optimal position of the population based on the optimal positions of the individual particles; Performing vector decoding on the global optimal position to obtain a target connection weight and a target threshold; The connection weight and threshold of the BP neural network are optimized by using the target connection weight and the target threshold.

7. The aquaculture environment monitoring method according to claim 5, characterized in that: The step of obtaining a root mean square error between an actual output and an expected output of the sample water body data in the BP neural network comprises: Determining the sample quantity of the sample water body data; Determine the actual output and expected output of obtaining the sample water body data based on the BP neural network; The root mean square error is calculated according to the sample quantity, the actual output and the expected output, and the calculation formula is: Wherein, n is the number of samples, y1 is the expected output, and y2 is the actual output.

8. An aquaculture environment monitoring device, characterized in that: The aquaculture environment monitoring device comprises: The acquisition module is used to obtain the original water body data collected by the water quality sensor; A detection module, used for performing outlier detection on the raw water body data; A processing module, used for processing the raw water body data based on the detection result to obtain processed water body data; A training module is used to construct a BP neural network, and use a PSO algorithm to optimize the connection weights and thresholds of the BP neural network to train sample water body data to obtain a water body environment monitoring model; The monitoring module is used to input the processed water body data into the water body environment monitoring model to obtain the monitoring results output by the water body environment monitoring model.

9. The aquaculture environment monitoring device according to claim 8, characterized in that: The detection module is used to sort the raw water body data in descending order; Based on the sorting result, the original water body data is divided according to a preset ratio to obtain a first quartile, a median, and a second quartile; determining an interquartile range based on the first quartile and the second quartile; Determine a lower limit value of the original water body data according to the first quartile and the interquartile range, and determine an upper limit value of the original water body data according to the second quartile and the interquartile range; Constructing a data distribution graph according to the first quartile, the median, the second quartile, the lower limit value, and the upper limit value; The data distribution graph is used to perform outlier detection on the original water body data.

10. The aquaculture environment monitoring device according to claim 8, characterized in that: The processing module is used to remove abnormal values ​​contained in the original water body data based on the detection results to obtain reference water body data; Identifying water body data collected by water quality sensors of the same type as the reference water body data; Calculate the mean square error corresponding to each of the water body data collected by the water quality sensors of the same type; Taking the minimum weighting factor as a variable, constructing a functional relationship corresponding to the total mean square error based on the mean square error; Solving the extreme value of the functional relationship to obtain the minimum weighting factor corresponding to each of the water quality sensors of the same type when the total mean square error is minimized; The water body data collected by the water quality sensors of the same type are fused based on the minimum weighting factor to obtain processed water body data.