River crab growth stage monitoring floating platform and method based on machine vision
By integrating pressure sensors and cameras on the river crab breeding platform, combined with the improved support vector machine classification algorithm, real-time non-destructive monitoring of the river crab growth stage is achieved, and the problem of difficulty in real-time monitoring of the river crab growth stage in the existing technology is solved, and the breeding quality and scientific nature are improved.
Patent Information
- Application Number
- CN202411899714.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-23
- Publication Date
- 2025-04-04
AI Technical Summary
The existing technology is difficult to monitor the growth stage of river crabs in real time and non-destructively, resulting in the reliance on experience in the river crab farming process and a low level of scientific breeding.
A floating platform for monitoring the growth stage of river crabs based on machine vision was designed. The sign data of river crabs were collected through pressure sensors and camera components, and combined with the improved support vector machine classification algorithm, real-time monitoring and analysis of river crabs' growth stage was achieved.
Real-time non-destructive monitoring of the growth status of river crabs is achieved, the quality of breeding is improved, and accurate judgment of growth stage is provided, providing a parameter basis for farmers to formulate scientific breeding strategies.
Smart Images

Figure CN119756471A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of non-destructive monitoring of river crab growth, and in particular relates to a floating platform and method for monitoring river crab growth stages based on machine vision. Background Art
[0002] Since 1993, the production of adult crabs in my country has grown rapidly and steadily. It is estimated that by 2024, there will be more than 7,600 crab farming-related enterprises in the country, with an output value of more than 100 billion yuan. my country's river crab production has always maintained a high level, and the huge number of enterprises and consumer groups make river crab intelligent production machinery have a broad sales market prospect.
[0003] Compared with economic aquaculture of fish and shrimp, the ecological farming of Chinese mitten crabs and the improvement of the level of intelligent farming of river crabs have problems such as complex water environment, which makes the water quality control process more complicated and it is difficult to feed the river crabs accurately and evenly according to their growth habits. The reason is that the current growth data collection method in river crab farming is difficult to be lossless, so it is difficult to obtain comprehensive growth data of river crabs in real time, resulting in the current river crab farming process still being mainly based on experience-based farming, and the level of scientific farming is low.
[0004] Prior art 1 (CN106305567A) discloses an image recognition method for river crab identification, which uses river crab image data to construct a river crab pattern diagram and calculate characteristic values, thereby determining the river crab population, which plays a role in river crab breeding and obtaining river crab production areas, but cannot be used for direct judgment of growth conditions in river crab farming; Prior art 2 (CN117011795B) discloses a river crab growth status non-destructive monitoring and evaluation platform and method based on Gaussian fuzzy support, which builds a monitoring platform based on the habits of river crabs, collects river crab images and weight information, and non-destructively monitors the growth status of river crabs based on Gaussian fuzzy support, but its judgment on the growth status of river crabs is relatively vague, and it can only judge whether the river crabs are mature or abnormal, and has low guidance for river crab farming.
[0005] Therefore, how to obtain the current growth stage of river crabs and make timely judgments on their growth status is a key step in improving the quality of river crab farming and accelerating the automation process of river crab farming equipment. It is also a technical problem that urgently needs to be solved. Summary of the invention
[0006] In view of the deficiencies in the prior art, the present invention provides a floating platform and method for monitoring the growth stages of river crabs based on machine vision, which can collect the vital signs data of river crabs to monitor their growth stages, and realize real-time data collection and analysis and evaluation of the growth status of river crabs under open-air river crab farming conditions.
[0007] The present invention achieves the above technical objectives through the following technical means.
[0008] A floating platform for monitoring the growth stages of river crabs based on machine vision comprises a box-type monitoring channel with an opening at one end formed by splicing a plurality of plates, the monitoring channel is placed on the floating platform, the opening of the monitoring channel is connected to an outlet at one end of a crab-attracting cage, the crab-attracting cage is arranged obliquely and the other end extends underwater and is provided with an entrance for river crabs to enter; a pressure sensor is installed at the bottom of the monitoring channel, and detection data of the pressure sensor is collected by a control terminal in a waterproof box on the side of the monitoring channel, and further sent to a workstation or a server for processing; a camera assembly is installed directly above the pressure sensor, and the control terminal controls the opening and closing of the camera assembly according to the opening and closing of the pressure sensor, and the data collected by the camera assembly is collected by the control terminal, and further sent to a workstation or a server for processing.
[0009] Furthermore, the floating platform includes a floating platform, a floating platform bracket, and a floating ball. The floating platform bracket is composed of several hollow circular tubes connected by a three-way connector, on which the floating platform is fixed. Multiple floating balls pass through the hollow circular tubes. The specific number of floating balls is manually adjusted according to different breeding conditions. A monitoring channel is placed and fixed on the floating platform, and the entire floating platform is restricted to move within a small range by means of ropes or rods.
[0010] A method for monitoring the growth stage of river crabs based on machine vision using the above-mentioned river crab growth stage monitoring floating platform based on machine vision includes the following process:
[0011] Step 1: Arrange the crab growth stage monitoring floating platform in the aquaculture pond area to be tested;
[0012] Step 2: The river crab crawls into the pressure sensor plane through the crab trap. When the pressure sensor detects a pressure signal, it sends an electrical signal to the control terminal. The control terminal controls the camera component to collect image data of the river crab.
[0013] Step 3: The control terminal transmits the image data collected by the camera component to a workstation or server for processing and analysis to obtain the growth sign data of the river crab;
[0014] Step 4: The control terminal transmits the data collected by the pressure sensor to the workstation or server for processing to obtain the weight data of the river crab;
[0015] Step 5: Based on the acquired crab growth sign data and crab weight data, the workstation or server uses an improved support vector machine classification algorithm model to classify and discriminate the growth stage of the crab;
[0016] Step 6: The workstation or server outputs the crab growth stage information and displays it visually for relevant personnel to view.
[0017] Furthermore, the specific process of step 3 is as follows:
[0018] Step 3.1: Extract the G channel value from the obtained image; because the color of river crabs is close to green, extracting the G channel makes it easier to distinguish it from the background;
[0019] Step 3.2: Binarize the obtained image to separate the crab from the background;
[0020] Step 3.3: Perform an opening operation on the obtained image, that is, first erode and then expand, to extract the main information in the image;
[0021] Step 3.4: Perform noise reduction processing on the obtained image to reduce the influence of noise points in the image on image processing;
[0022] Step 3.5: Perform edge extraction on the obtained image to extract edge information of the crab outline;
[0023] Step 3.6: Establish a rectangular coordinate system for the obtained contour, and obtain the maximum and minimum values of the horizontal and vertical coordinates of each point in the contour, which are x max 、x min and max ,y min , and then (x max ,y max )、(x min ,y min ) is a point-by-point scan in the diagonal rectangle, and the sum of the distances between each point and each point on the contour line is calculated:
[0024]
[0025] Among them, L is the sum of the distances required, Q is all the points on the contour line, a is the serial number of each point on the contour, l a Represents the distance between the point and a single point on the contour line, l a The calculation method is as follows:
[0026]
[0027] Among them, (x1, y1) and (x2, y2) are the coordinates of the desired point and a point on the contour line respectively;
[0028] Step 3.7: Compare the calculated L values. When the L value is the smallest, the corresponding point is the center of the inscribed circle of the river crab contour. The minimum distance between the center and the contour line is the radius of the inscribed circle, and the radius of the inscribed circle is the growth sign data of the river crab.
[0029] Furthermore, in step 4, since the crabs will crawl on the platform, the reading of the pressure sensor will fluctuate, so the data collected by the pressure sensor is processed. The specific working settings of the pressure sensor include the following items:
[0030] Set the pressure sensor to detect again every two seconds after detecting the pressure signal to avoid a large amount of repeated image data backlog due to continuous pressure sensor signals;
[0031] In a monitoring cycle, if the pressure sensor fails to read a signal for a preset number of times, the monitoring of a crab is considered to be completed. The next monitoring cycle is considered to start when the pressure sensor senses a pressure signal.
[0032] At the beginning of a monitoring cycle, a new array is created. After the end of a monitoring cycle, 20% of the values before and after the array are discarded and the average value is calculated. After the average value is obtained, the value in the array is subtracted from the average value, and then the absolute value of the difference is compared with the set threshold. If it is less than or equal to the set threshold, it is considered that the value has practical significance and the sampling value is retained. If it is greater than the set threshold, it is considered that the deviation of this value is large and the sampling value is discarded. The final retained value is re-averaged and regarded as the actual weight of the river crab.
[0033] Furthermore, the specific process of step 5 is as follows:
[0034] The obtained crab growth sign data and weight data were used as input values, and the classification was performed using the improved support vector machine classification algorithm. The classification results were "molting once", "molting twice", "molting three times", "molting four times" and "molting five times".
[0035] The improved support vector machine classification algorithm improves the traditional support vector machine classification algorithm, changing the "one-to-one" classification to a "one-to-many" form. First, for the i and j classes to be classified, the center point positions of the i and j classes are calculated:
[0036]
[0037] Among them, c i represents the coordinates of the center point of class i, n i represents the total number of samples of class i, X i represents all sample points of class i; x represents the coordinate value of the sample point of class i; c represents the coordinate value of the center point of class j j The calculation method is the same;
[0038] Then calculate the Euclidean distance d between class i and class j ij :
[0039] d ij =(d ji )=‖c i -c j ‖
[0040] The classification process is optimized by comparing the Euclidean distance between multiple categories. The specific classification steps are as follows:
[0041] Based on the above calculation principle, we first calculate the Euclidean distance d between class i and all other classes. ij , d ik , d il …,d im ;
[0043] Then take the minimum value of the Euclidean distance between class i and other classes as b i :
[0044]
[0045] Among them, d ip represents the Euclidean distance between category i and other categories, p represents the classification number, that is, the total number of categories other than category i; j, k, l, and m all represent categories;
[0046] Then select all b i The maximum value of the value, the selected category is the first classified category; if there are two categories b i If the values are both the largest, compare the second smallest Euclidean distance. If they are still equal, continue to compare the smaller Euclidean distance until the size is determined.
[0047] After classifying the first category, repeat the above steps for the remaining p-1 categories until all classifications are completed.
[0048] Furthermore, after completing the classification of the molting stage of river crabs, since the molting time of river crabs is not fixed, even if the breeding conditions are the same, the molting period will last for about a week. Therefore, only a single river crab is not enough to represent the overall growth status of the crab pond; therefore, the judgment of the growth stage must be voted on through the classification results of river crabs. The formula for determining the growth stage of the river crab group is as follows:
[0049]
[0050] Among them, ST represents the determination result of the growth status of river crabs in the crab pond at this time; ST i and ST i+1 Represents the two growth stages before and after molting, s i and i+1They represent the proportion of crabs in the previous and next growth stages in the past monitoring times. When the number of crabs in the previous growth stage in the crab population monitored in the past certain times exceeds 90%, it means that the crab pond has not yet completely started to molt and is still in the previous growth stage; on the contrary, if the number of crabs that have completed molting and entered the next growth stage in the crab population monitored in a certain number of times exceeds 90%, it means that the crab pond has completed molting and is now determined to be in the next growth stage; if the number of crabs in the previous and next growth stages does not account for 90%, it proves that the crab pond is in the molting period between the previous and next growth stages.
[0051] The present invention has the following beneficial effects:
[0052] The floating platform for monitoring the growth of river crabs designed by the present invention realizes non-destructive monitoring of river crabs. River crabs act spontaneously due to their own biological habits, reducing the interference of human actions; and the floating platform has improved flexibility compared to the fixed platform, and can be placed in the pond according to the needs of the breeding personnel, and can be transferred to the shore for operation when the platform needs to be replaced and adjusted. In addition, the present invention uses an improved SVM multi-classification algorithm suitable for the classification of multiple growth stages of river crabs, which can quickly obtain the growth status of river crabs in the current breeding pond, and provide a parameter basis for farmers to formulate breeding strategies and automated breeding equipment. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 This is a schematic diagram of the overall scheme of the floating platform for monitoring the growth stages of river crabs according to the present invention;
[0054] Figure 2 This is a schematic diagram of the structure of the floating platform of the present invention;
[0055] Figure 3 This is a schematic diagram of the internal structure of the floating platform of the present invention;
[0056] Figure 4 This is the overall flow chart of monitoring the growth stages of river crabs according to the present invention;
[0057] Figure 5 This is a flow chart of the crab vital sign data extraction process described in the present invention;
[0058] Figure 6 This is a logical diagram of the SVM improved algorithm of the present invention;
[0059] In the figure: 1- waterproof box; 2- monitoring channel; 21- camera assembly; 22- pressure sensor; 3- floating platform; 4- crab trap. DETAILED DESCRIPTION
[0060] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments, but the protection scope of the present invention is not limited thereto.
[0061] like Figures 1 to 3 As shown, the floating platform for monitoring the growth stage of river crabs based on machine vision of the present invention includes a waterproof box 1, a monitoring channel 2, a floating platform 3, a crab-attracting cage 4, a camera assembly 21, and a pressure sensor 22.
[0062] like Figures 1 to 3 As shown, the monitoring channel 2 is a box-type structure with one end open and composed of multiple plates spliced together. One end of the tilted crab trap 4 extends into the water and is provided with an inlet for river crabs to enter, and the other end is connected to the monitoring channel 2 and is provided with an outlet for river crabs to crawl out to the monitoring channel 2; a pressure sensor 22 is installed at the bottom of the monitoring channel 2, and the plane of the pressure sensor 22 is flush with the bottom of the monitoring channel 2. After the river crab enters the range of the pressure sensor 22, the pressure signal is collected, and the data is collected and processed by the control terminal in the waterproof box 1; the camera assembly 21 is located directly above the pressure sensor 22, and the control terminal controls the opening and closing of the camera assembly 21 according to the opening and closing of the pressure sensor 22, and the collected data is sent to the workstation or server through the wireless module through the local area network or the Internet. In addition, the outlet of the crab trap 4 should not be too wide, and it should be ensured that only one river crab passes through each time to prevent multiple river crabs from entering the monitoring range at the same time and affecting the monitoring results.
[0063] like Figure 1 , 2 As shown, the monitoring channel 2 is placed on the floating platform 3, and a waterproof box 1 is installed on the side of the monitoring channel 2. A wireless module and a control terminal are arranged inside the waterproof box 1; the floating platform 3 includes a floating platform, a floating platform bracket, and a floating ball. The floating platform bracket is composed of several hollow circular tubes connected by a three-way connector, and a floating platform is fixed thereon. Multiple floating balls pass through the hollow circular tubes. The specific number of floating balls can be manually adjusted according to different breeding conditions. The monitoring channel 2 is placed and fixed on the floating platform, and the entire floating platform 3 can be restricted to move in a small range by tying ropes or inserting poles.
[0064] Reference Figure 4 , 5 6. The method for monitoring the growth stage of river crabs based on machine vision using the above-mentioned river crab growth stage monitoring floating platform specifically includes the following process:
[0065] Step 1: Arrange the crab growth stage monitoring floating platform in the aquaculture pond area to be tested;
[0066] Step 2: The river crab crawls into the plane of the pressure sensor 22 through the crab trap 4, and the control terminal leads out a signal line connected to the pressure sensor 22 and the camera assembly 21. After the pressure sensor 22 senses that a river crab has passed, the pressure sensor 22 sends an electrical signal to the control terminal when detecting the pressure signal, and the control terminal controls the camera assembly 21 to start working and collect image data of the river crab;
[0067] Step 3: The control terminal transmits the image data collected by the camera assembly 21 to a workstation or server for processing and analysis to obtain the growth sign data of the river crab. The specific process is as follows:
[0068] Step 3.1: Extract the G channel value from the obtained image; because the color of river crabs is close to green, extracting the G channel makes it easier to distinguish it from the background;
[0069] Step 3.2: Binarize the obtained image to roughly distinguish the crab from the background;
[0070] Step 3.3: Perform an opening operation on the obtained image, that is, first erode and then expand, to extract the main information in the image;
[0071] Step 3.4: Perform noise reduction processing on the obtained image to reduce the influence of noise points in the image on image processing;
[0072] Step 3.5: Perform edge extraction on the obtained image to extract edge information of the crab outline;
[0073] Step 3.6: Establish a rectangular coordinate system for the obtained contour, and obtain the maximum and minimum values of the horizontal and vertical coordinates of each point in the contour, which are x max 、x min and max ,y min , and then in (x max ,y max )、(x min ,y min ) is a point-by-point scan in the diagonal rectangle, and the sum of the distances between each point and each point on the contour line is calculated:
[0074]
[0075] Among them, L is the sum of the distances required, Q is all the points on the contour line, a is the serial number of each point on the contour, l a Represents the distance between the point and a single point on the contour line, where l a The calculation method is as follows:
[0076]
[0077] Among them, (x1, y1) and (x2, y2) are the coordinates of the desired point and a point on the contour line respectively;
[0078] Step 3.7: Compare the calculated L values. When the L value is the smallest, the corresponding point is the center of the inscribed circle of the river crab outline. The minimum distance between the center and the outline is the radius of the inscribed circle. The radius of the inscribed circle is the growth sign data of the river crab.
[0079] It should be noted that the carapace of river crabs is not a regular circle. The radius of the inscribed circle of the contour is used here as a representation of the size of the crab's physical data. That is, the larger the size of the river crab, the larger the radius of the inscribed circle obtained, but the inscribed circle is not directly equal to the size of the crab's carapace.
[0080] Step 4: The control terminal transmits the data collected by the pressure sensor 22 to the workstation or server for processing to obtain the weight data of the river crab, as follows:
[0081] Since river crabs will crawl on the platform, the reading of the pressure sensor 22 will fluctuate, so the data collected by the pressure sensor 22 must be processed. The specific working settings of the pressure sensor 22 include the following items:
[0082] Since the start signal of the camera assembly 21 is controlled based on the pressure sensor 22, the continuous signal of the pressure sensor 22 will cause a large amount of repeated image data to be accumulated. Therefore, in this embodiment, the pressure sensor 22 is set to detect again every two seconds after detecting the pressure signal;
[0083] In a monitoring cycle, if the pressure sensor 22 fails to read a signal for a preset number of times, the monitoring of a crab is considered to be completed, and the next monitoring cycle is considered to be started after the pressure sensor 22 senses a pressure signal next time;
[0084] At the beginning of a monitoring cycle, a new array is created. After a monitoring cycle ends, 20% of the values before and after the array are discarded and the average value is calculated. After the average value is calculated, the value in the array is subtracted from the average value, and then the absolute value of the difference is compared with the set threshold. If it is less than or equal to the set threshold, it is considered that the value has practical significance and the sampling value is retained. If it is greater than the set threshold, it is considered that the deviation of this value is large and the sampling value is discarded. The final retained value is re-averaged and regarded as the actual weight of the crab.
[0085] In the above processing, 20% of the values before and after a monitoring cycle are discarded because when the river crab climbs onto or leaves the plane of the pressure sensor 22, the value will deviate greatly from the actual weight. Therefore, the data samples in the first and last time periods of the whole process are excluded; the values that deviate greatly from the average value are deleted in order to eliminate the influence of serious signal distortion caused by random interference on the experiment.
[0086] Step 5: Based on the acquired crab growth sign data and crab weight data, the workstation or server uses an improved support vector machine (SVM) classification algorithm model to classify and discriminate the growth stage of the crab. The specific process is as follows:
[0087] The obtained crab growth sign data and weight data were used as input values, and the improved SVM classification algorithm was used for classification. The classification results were "molted once", "molted twice", "molted three times", "molted four times" and "molted five times".
[0088] Since the traditional SVM algorithm can only perform binary classification, and here we need to perform classification of five growth stages, this embodiment improves the traditional SVM algorithm. The improved method of the SVM algorithm is changed from "one-to-one" classification to "one-to-many". First, for the i and j classes to be classified by the SVM, the center point positions of the i and j classes are calculated:
[0089]
[0090] Among them, c i represents the coordinates of the center point of class i, n i represents the total number of samples of class i, X i represents all sample points of class i; x represents the coordinate value of the sample point of class i; c represents the coordinate value of the center point of class j j The calculation method is the same;
[0091] Then calculate the Euclidean distance d between class i and class j ij :
[0092] d ij =(d ji )=‖c i -c j ‖
[0093] The classification process is optimized by comparing the Euclidean distance between multiple categories. The specific classification steps are as follows:
[0094] Based on the above calculation principle, we first calculate the Euclidean distance d between class i and all other classes. ij , d ik , d il …,d im ;
[0096] Then take the minimum value of the Euclidean distance between class i and other classes as b i :
[0097]
[0098] Among them, d ip represents the Euclidean distance between category i and other categories, p represents the classification number, that is, the total number of categories other than category i; j, k, l, and m all represent categories; similarly, the minimum Euclidean distance between the next category and all other categories is calculated until all b are calculated. i value;
[0099] Then, in order to avoid misclassification as much as possible, we need to ensure that the first classified category has the largest distance from other categories when selecting it. Selecting the maximum value in the minimum Euclidean distance means selecting a "category farthest from other categories" for classification, so that its decision boundary with other categories will be more obvious. Therefore, select all b i The maximum value of the value, the selected category is the first classified category; if there are two categories b i If the values are both the largest, compare the second smallest Euclidean distance. If they are still equal, continue to compare the smaller Euclidean distance until the size is determined.
[0100] After classifying the first category, repeat the above steps for the remaining p-1 categories until all classifications are completed.
[0101] After completing the classification of the molting stage of river crabs, since the molting time of river crabs is not fixed, even if the breeding conditions are the same, the molting period will last for about a week. Therefore, a single river crab is not enough to represent the overall growth status of the crab pond; therefore, the judgment of the growth stage must be voted on through the SVM algorithm classification results of the river crabs. The formula for determining the growth stage of the river crab group is as follows:
[0102]
[0103] Among them, ST represents the determination result of the growth status of river crabs in the crab pond at this time; ST i and ST i+1 Represents the two growth stages before and after molting, s i and i+1 They represent the proportion of crabs in the previous and next growth stages in the past monitoring times. When the number of crabs in the previous growth stage in the crab population monitored in the past certain times exceeds 90%, it means that the crab pond has not yet completely started to molt and is still in the previous growth stage; on the contrary, if the number of crabs that have completed molting and entered the next growth stage in the crab population monitored in a certain number of times exceeds 90%, it means that the crab pond has completed molting and is now determined to be in the next growth stage; if the number of crabs in the previous and next growth stages does not account for 90%, it proves that the crab pond is in the molting period between the previous and next growth stages.
[0104] Step 6: The workstation or server outputs the crab growth stage information according to the judgment criteria obtained in step 5 for relevant personnel to view.
[0105] The present invention aims to determine the growth stage of river crabs in current breeding ponds and provide accurate feeding guidance for farmers in view of the phenomenon that the feed requirements of river crabs vary greatly at different growth stages. After obtaining the carapace size data and weight data of river crabs, a method for distinguishing the growth stage of river crabs based on the SVM algorithm is designed. By constructing an SVM function to distinguish river crab samples collected by a growth monitoring platform, the growth stage of river crabs can be actively, quickly and more accurately determined. After the carapace size of river crabs increases, the weight of river crabs will also increase as the amount of food consumed increases. Therefore, the weight and carapace size of river crabs are selected as the main criteria for judging the growth stage, so that the judgment is more accurate.
[0106] The ground trap 4 of the present invention is obtained by modifying a conventional crab trap, opening the mouth to a width that is only wide enough for a river crab to crawl out, and raising the height to the surface of the water. The above embodiment is a preferred embodiment of the present invention, but the present invention is not limited to the above embodiment. Any obvious improvement, replacement or modification that can be made by a person skilled in the art without departing from the essence of the present invention belongs to the protection scope of the present invention.
Claims
1. A floating platform for monitoring the growth stage of river crabs based on machine vision, characterized in that: The invention comprises a box-type monitoring channel (2) which is formed by splicing a plurality of plates and has an opening at one end. The monitoring channel (2) is placed on a floating platform (3). The opening of the monitoring channel (2) is connected to an outlet at one end of a crab-attracting ground cage (4). The crab-attracting ground cage (4) is arranged obliquely and the other end extends underwater and is provided with an inlet for crabs to enter. A pressure sensor (22) is installed at the bottom of the monitoring channel (2). The detection data of the pressure sensor (22) is collected by a control terminal in a waterproof box (1) on the side of the monitoring channel (2) and further sent to a workstation or a server for processing. A camera assembly (21) is installed directly above the pressure sensor (22). The control terminal controls the opening and closing of the camera assembly (21) according to the opening and closing of the pressure sensor (22). The data collected by the camera assembly (21) is collected by the control terminal and further sent to a workstation or a server for processing.
2. The machine vision-based floating platform for monitoring the growth stage of river crabs according to claim 1 is characterized in that: The floating platform (3) includes a floating platform, a floating platform bracket, and a floating ball. The floating platform bracket is composed of several hollow circular tubes connected by a three-way connector, on which the floating platform is fixed. A plurality of floating balls pass through the hollow circular tubes. The specific number of floating balls is manually adjusted according to different breeding conditions. A monitoring channel (2) is placed on the floating platform and fixed. The entire floating platform (3) is restricted to move within a small range by means of a tether or a rod.
3. A method for monitoring the growth stage of river crabs based on machine vision using the river crab growth stage monitoring floating platform based on machine vision according to claim 1, characterized in that: The process includes the following: Step 1: Arrange the crab growth stage monitoring floating platform in the aquaculture pond area to be tested; Step 2: The river crab crawls into the plane of the pressure sensor (22) through the crab trap (4). When the pressure sensor (22) detects a pressure signal, it sends an electrical signal to the control terminal. The control terminal controls the camera assembly (21) to work and collect image data of the river crab. Step 3: The control terminal transmits the image data collected by the camera assembly (21) to a workstation or a server for processing and analysis to obtain the growth sign data of the river crab; Step 4: The control terminal transmits the data collected by the pressure sensor (22) to a workstation or a server for processing to obtain the weight data of the river crab; Step 5: Based on the acquired crab growth sign data and crab weight data, the workstation or server uses an improved support vector machine classification algorithm model to classify and discriminate the growth stage of the crab; Step 6: The workstation or server outputs the crab growth stage information and displays it visually for relevant personnel to view.
4. The method for monitoring the growth stage of river crabs based on machine vision according to claim 3 is characterized in that: The specific process of step 3 is as follows: Step 3.1: Extract the G channel value from the obtained image; because the color of river crabs is close to green, extracting the G channel makes it easier to distinguish it from the background; Step 3.2: Binarize the obtained image to separate the crab from the background; Step 3.3: Perform an opening operation on the obtained image, that is, first erode and then expand, to extract the main information in the image; Step 3.4: Perform noise reduction processing on the obtained image to reduce the influence of noise points in the image on image processing; Step 3.5: Perform edge extraction on the obtained image to extract edge information of the crab outline; Step 3.6: Establish a rectangular coordinate system for the obtained contour, and obtain the maximum and minimum values of the horizontal and vertical coordinates of each point in the contour, which are x max 、x min and max ,y min , and then (x max ,y max )、(x min ,y min ) is a point-by-point scan in the diagonal rectangle, and the sum of the distances between each point and each point on the contour line is calculated: Among them, L is the sum of the distances required, Q is all the points on the contour line, a is the serial number of each point on the contour, l a Represents the distance between the point and a single point on the contour line, l a The calculation method is as follows: Among them, (x1, y1) and (x2, y2) are the coordinates of the desired point and a point on the contour line respectively; Step 3.7: Compare the calculated L values. When the L value is the smallest, the corresponding point is the center of the inscribed circle of the river crab contour. The minimum distance between the center and the contour line is the radius of the inscribed circle, and the radius of the inscribed circle is the growth sign data of the river crab.
5. The method for monitoring the growth stage of river crabs based on machine vision according to claim 3 is characterized in that: In step 4, since the crabs will crawl on the platform, the reading of the pressure sensor (22) will fluctuate, so the data collected by the pressure sensor (22) is processed. The specific working settings of the pressure sensor (22) include the following items: The pressure sensor (22) is set to detect again every two seconds after detecting the pressure signal, so as to avoid a large amount of repeated image data being accumulated due to a continuous signal from the pressure sensor (22); In a monitoring cycle, if the pressure sensor (22) fails to read a signal for a preset number of times, it is considered that the monitoring of a crab is completed, and the next monitoring cycle is considered to be started after the pressure sensor (22) senses a pressure signal next time; At the beginning of a monitoring cycle, a new array is created. After the end of a monitoring cycle, 20% of the values before and after the array are discarded and the average value is calculated. After the average value is obtained, the value in the array is subtracted from the average value, and then the absolute value of the difference is compared with the set threshold. If it is less than or equal to the set threshold, it is considered that the value has practical significance and the sampling value is retained. If it is greater than the set threshold, it is considered that the deviation of this value is large and the sampling value is discarded. The final retained value is re-averaged and regarded as the actual weight of the river crab.
6. The method for monitoring the growth stage of river crabs based on machine vision according to claim 3 is characterized in that: The specific process of step 5 is as follows: The obtained crab growth sign data and weight data were used as input values, and the improved support vector machine classification algorithm was used for classification. The classification results were "molted once", "molted twice", "molted three times", "molted four times" and "molted five times". The improved support vector machine classification algorithm improves the traditional support vector machine classification algorithm, changing the "one-to-one" classification to a "one-to-many" form. First, for the i and j classes to be classified, the center point positions of the i and j classes are calculated: Among them, c i represents the coordinates of the center point of class i, n i represents the total number of samples of class i, X i represents all sample points of class i; x represents the coordinate value of sample points of class i; c represents the coordinate value of the center point of class j j The calculation method is the same; Then calculate the Euclidean distance d between class i and class j ij : d ij =(d ji )=‖c i -c j ‖ The classification process is optimized by comparing the Euclidean distance between multiple categories. The specific classification steps are as follows: Based on the above calculation principle, we first calculate the Euclidean distance d between class i and all other classes. ij , d ik , d il …,d im ; Then take the minimum value of the Euclidean distance between class i and other classes as b i : Among them, d ip represents the Euclidean distance between category i and other categories, p represents the classification number, that is, the total number of categories other than category i; j, k, l, and m all represent categories; similarly, the minimum Euclidean distance between the next category and all other categories is calculated until all the minimum Euclidean distances are calculated; Then select the maximum value among all the minimum values of the Euclidean distance, and the selected category is the first classified category; if the minimum values of the Euclidean distances of two categories are both the largest, compare the second smallest Euclidean distance. If they are still equal, continue to compare the smaller Euclidean distance until the size is compared; After classifying the first category, repeat the above steps for the remaining p-1 categories until all classifications are completed.
7. The method for monitoring the growth stage of river crabs based on machine vision according to claim 6 is characterized in that: After the classification of river crabs at the molting stage is completed, since the molting time of river crabs is not fixed, even if the breeding conditions are the same, the molting period will last for about a week. Therefore, a single river crab is not enough to represent the overall growth status of the crab pond; therefore, the judgment of the growth stage must be voted on through the classification results of river crabs. The formula for determining the growth stage of river crab groups is as follows: Among them, ST represents the determination result of the growth status of river crabs in the crab pond at this time; ST i and ST i+1 Represents the two growth stages before and after molting, s i and i+1 They represent the proportion of crabs in the previous and next growth stages in the past monitoring times. When the number of crabs in the previous growth stage in the crab population monitored in the past certain times exceeds 90%, it means that the crab pond has not yet completely started to molt and is still in the previous growth stage; on the contrary, if the number of crabs that have completed molting and entered the next growth stage in the crab population monitored in a certain number of times exceeds 90%, it means that the crab pond has completed molting and is now determined to be in the next growth stage; if the number of crabs in the previous and next growth stages does not account for 90%, it proves that the crab pond is in the molting period between the previous and next growth stages.
Citation Information
Patent Citations
Image identification method used for judging river crabs
CN106305567A
Nondestructive monitoring and evaluation platform and method for crab growth status based on Gaussian fuzzy support
CN117011795B