Method, device, electronic device and storage medium for measuring fish phenotypic data

By identifying the key points of fish body and calculating projection data, the measurement inaccuracy problem caused by fish body movement or morphology differences is solved, the accuracy of fish phenotype data is improved, and more accurate for fish morphology research and breeding management is provided. data support.

CN118942122BActive Publication Date: 2024-12-31SANYA BORUIYUAN TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411139087.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-20
Publication Date
2024-12-31
Estimated Expiration
2044-08-20

AI Technical Summary

Technical Problem

The existing methods of measuring fish phenotype data rely on the overall shooting of the fish body's appearance, and cannot avoid the problem of low accuracy of measurement data caused by fish body movement or morphological differences.

Method used

By obtaining multiple target images of the target fish, the pre-trained fish body key point identification model recognizes the key points on the tail handle and the tail handle, calculates the projection data on the horizontal and vertical lines of the fish body, and accurately marks the fish body key points based on the pre-trained fish body key points. Points to calculate phenotypic data.

Benefits of technology

It improves the measurement accuracy of fish phenotype data, provides more accurate and reliable data support, and improves the efficiency of fish morphological research and aquaculture management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118942122B_ABST
    Figure CN118942122B_ABST
Patent Text Reader

Abstract

The embodiment of the present invention relates to a method, device, electronic device and storage medium for measuring fish phenotypic data, including: obtaining multiple target images of target fish; identifying multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model; determining the horizontal line of the fish body with the key points on the tail peduncle and the key points below the tail peduncle as mirror symmetry; connecting the key points on the tail peduncle and the key points below the tail peduncle to obtain a vertical line; calculating the projection data of the target key points on the horizontal line and the vertical line of the fish body respectively based on the horizontal line and the vertical line of the fish body; calculating the target phenotypic data corresponding to the target fish based on the projection data. Therefore, by accurately marking the key points on the tail peduncle and the key points below the tail peduncle to calculate the fish phenotypic data, it is possible to reduce the error in the fish body morphology measurement, improve the measurement accuracy of the fish phenotypic data, provide accurate and reliable data support for fish morphology research and aquaculture management, and improve scientific research and production efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present invention relate to the technical field of fish phenotypic data measurement, and in particular to a method, device, electronic device and storage medium for measuring fish phenotypic data. Background Art

[0002] In the process of artificial aquaculture, a series of "phenotypic data" of aquatic organisms is the main information for farmers to conduct related research such as feeding, breeding, and differential grading. It not only reflects the growth status of individual fish, but also plays an important role in related research such as genetic breeding. Based on the "phenotypic data" of individual fish, researchers can obtain the growth status and development status of individual fish, and then formulate breeding strategies to improve economic benefits.

[0003] Existing methods for measuring fish phenotypic data mostly rely on taking a picture of the overall shape of the fish and analyzing it through image processing technology. However, due to the possible movement of the fish during the shooting process or the differences in the morphology of different fish, the accuracy of the measured data is often low, which affects the effectiveness of scientific research and breeding strategy formulation. Therefore, how to accurately measure fish phenotypic data has become an urgent problem to be solved. Summary of the invention

[0004] In view of this, in order to solve the above technical problems or part of the technical problems, an embodiment of the present invention provides a method, device, electronic device and storage medium for measuring fish phenotypic data.

[0005] In a first aspect, an embodiment of the present invention provides a method for measuring fish phenotypic data, comprising:

[0006] Acquire multiple target images of target fish;

[0007] Based on the pre-trained fish body key point recognition model, a plurality of key points corresponding to the fish body in each target image are identified, wherein the plurality of key points include an upper caudal peduncle key point and a lower caudal peduncle key point;

[0008] Determine the horizontal line of the fish body by using the key point on the caudal peduncle and the key point below the caudal peduncle as mirror images;

[0009] Connect the key points on the caudal peduncle and the key points below the caudal peduncle to obtain a vertical line;

[0010] Based on the horizontal line and vertical line of the fish body, the projection data of the target key points on the horizontal line and vertical line of the fish body are calculated respectively, wherein the target key points are at least one of the tip of the snout, the rear edge of the operculum, the highest point of the head, the isthmus, the highest point of the dorsal edge, the lowest point of the ventral edge, the end of the caudal vertebra, the front edge of the eye, the rear edge of the eye, the starting point of the pectoral fin, the end of the base of the pectoral fin, the starting point of the pelvic fin, the end of the base of the pelvic fin, the starting point of the anal fin, the rear end of the base of the anal fin, the outer edge of the anal fin, the starting point of the dorsal fin, the rear end of the base of the dorsal fin, and the outer edge of the dorsal fin;

[0011] The target phenotypic data corresponding to the target fish is calculated based on the projection data, wherein the calculation of different target phenotypic data corresponds to different target key points.

[0012] In a possible implementation, the method further includes:

[0013] The target phenotypic data at least include total length, body length, body height, snout length, head length, head height, caudal peduncle length, caudal peduncle height, caudal fin length, head length behind the eye, eye diameter, front distance of dorsal fin, and back distance of dorsal fin. The target phenotypic data include first type phenotypic data, second type phenotypic data, and third type phenotypic data;

[0014] The calculating the target phenotypic data corresponding to the target fish based on the projection data comprises:

[0015] The first type of phenotypic data is calculated based on the first formula, and the first type of phenotypic data is any one of the total length, body length, snout length, head length, tail peduncle length, tail fin length, head length behind the eye, eye diameter, front distance of dorsal fin, and back distance of dorsal fin. The first formula is:

[0016] Among them, A is the first type of phenotypic data, and the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x 8 ,y 8 ), X is the horizontal coordinate difference of the target key point required for the target phenotypic data to be calculated, and Y is the vertical coordinate difference of the target key point required for the target phenotypic data to be calculated.

[0017] In a possible implementation, the method further includes:

[0018] The second type of phenotypic data is calculated based on the second formula, the second type of phenotypic data being any one of the body height and the head height, and the second formula is:

[0019] Among them, B is the second type of phenotypic data, and the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x8 ,y 8 ), X is the horizontal coordinate difference of the target key point required for the target phenotypic data to be calculated, and Y is the vertical coordinate difference of the target key point required for the target phenotypic data to be calculated.

[0020] In a possible implementation, the method further includes:

[0021] The third type of phenotypic data is calculated based on the third formula, the third type of phenotypic data is the caudal peduncle height, and the third formula is:

[0022] Among them, C is the third type of phenotypic data, and the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x 8 ,y 8 ).

[0023] In a possible implementation, the method further includes:

[0024] Collect multiple images of different fish in different postures and angles to obtain multiple target images corresponding to each target fish;

[0025] Marking the key points of the fish body for the multiple target images corresponding to each target fish to obtain a sample image set with completed marking, wherein the key points of the fish body include the key points on the caudal peduncle and the key points below the caudal peduncle;

[0026] Dividing a plurality of target images corresponding to each target fish in the sample image set into a model training image and a model test image to obtain a model training image set and a model test image set;

[0027] Performing deep learning training on the CSPNext backbone network model based on the model training image set, and testing the CSPNext backbone network model after deep learning training based on the model test image set;

[0028] If the test results meet the preset conditions, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as the fish body key point recognition model.

[0029] In a possible implementation, the method further includes:

[0030] Compare the key point labeling results of the CSPNext backbone network model trained by deep learning on the model test image set with the results of manual key point labeling to obtain a comparison result;

[0031] When the comparison result shows that the accuracy of the model annotation reaches a preset threshold, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as a fish body key point recognition model.

[0032] In a possible implementation, the method further includes:

[0033] Based on the pre-trained fish recognition model, the target types of the target fish corresponding to the multiple target images are identified.

[0034] In a second aspect, an embodiment of the present invention provides a device for measuring fish phenotypic data, comprising:

[0035] An acquisition module, used for acquiring multiple target images of target fish;

[0036] A recognition module, used to recognize multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model, wherein the multiple key points include an upper caudal peduncle key point and a lower caudal peduncle key point;

[0037] A measurement module is used to determine the horizontal line of the fish body with the key points on the caudal peduncle and the key points under the caudal peduncle as mirror symmetry; connect the key points on the caudal peduncle and the key points under the caudal peduncle to obtain a vertical line; calculate the projection data of the target key points on the horizontal line and the vertical line of the fish body based on the horizontal line and the vertical line of the fish body, wherein the target key points are at least one of the tip of the snout, the rear edge of the operculum, the highest point of the head, the isthmus, the highest point of the dorsal margin, the lowest point of the ventral margin, the end of the caudal vertebra, the front edge of the eye, the rear edge of the eye, the starting point of the pectoral fin, the end of the base of the pectoral fin, the starting point of the pelvic fin, the end of the base of the pelvic fin, the starting point of the anal fin, the rear end of the base of the anal fin, the outer edge of the anal fin, the starting point of the dorsal fin, the rear end of the base of the dorsal fin, and the outer edge of the dorsal fin; calculate the target phenotypic data corresponding to the target fish based on the projection data, wherein the calculation of different target phenotypic data corresponds to different target key points.

[0038] In a third aspect, an embodiment of the present invention provides an electronic device, comprising: a processor and a memory, wherein the processor is used to execute a fish phenotypic data measurement program stored in the memory to implement the fish phenotypic data measurement method described in the first aspect above.

[0039] In a fourth aspect, an embodiment of the present invention provides a storage medium, comprising: the storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the method for measuring fish phenotypic data described in the first aspect above.

[0040] The fish phenotypic data measurement scheme provided by the embodiment of the present invention obtains multiple target images of the target fish; identifies multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model, wherein the multiple key points include a key point on the tail peduncle and a key point below the tail peduncle; determines the horizontal line of the fish body with the key point on the tail peduncle and the key point below the tail peduncle as mirror symmetry; connects the key point on the tail peduncle and the key point below the tail peduncle to obtain a vertical line; and calculates the target key point on the horizontal line of the fish body based on the horizontal line and the vertical line of the fish body. and projection data on a vertical line, wherein the target key points are at least one of the tip of the snout, the rear edge of the operculum, the highest point of the head, the isthmus, the highest point of the dorsal margin, the lowest point of the ventral margin, the end of the caudal vertebrae, the front edge of the eye, the rear edge of the eye, the starting point of the pectoral fin, the end of the pectoral fin base, the starting point of the pelvic fin, the end of the pelvic fin base, the starting point of the anal fin, the rear end of the anal fin base, the outer edge of the anal fin, the starting point of the dorsal fin, the rear end of the dorsal fin base, and the outer edge of the dorsal fin; based on the projection data, the target phenotypic data corresponding to the target fish is calculated, wherein the calculation of different target phenotypic data corresponds to different target key points. Compared with the existing fish phenotypic data measurement methods that rely more on the overall shooting of the fish body shape, it is impossible to avoid the movement of the fish body during the shooting process, or the difference in the morphology of different fish bodies, resulting in the problem of low accuracy of the measurement data. This scheme can reduce the error in fish morphological measurement and improve the measurement accuracy of fish phenotypic data by accurately marking the key points on and below the caudal peduncle, thus providing more accurate and reliable data support for fish morphological research and aquaculture management, and improving scientific research and production efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 A schematic diagram of a flow chart of a method for measuring fish phenotypic data provided by an embodiment of the present invention;

[0042] Figure 2 A schematic diagram of marking key points of a fish body provided by an embodiment of the present invention;

[0043] Figure 3 A schematic flow chart of a method for training a fish body key point recognition model provided by an embodiment of the present invention;

[0044] Figure 4 A schematic diagram of the structure of a device for measuring fish phenotypic data provided by an embodiment of the present invention;

[0045] Figure 5 A schematic structural diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0046] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0047] To facilitate understanding of the embodiments of the present invention, specific embodiments will be further explained below in conjunction with the accompanying drawings. The embodiments do not constitute a limitation on the embodiments of the present invention.

[0048] Figure 1 A flow chart of a method for measuring fish phenotypic data provided by an embodiment of the present invention is shown in FIG. Figure 1 As shown, the method specifically includes:

[0049] S11. Acquire multiple target images of target fish.

[0050] The purpose of the embodiment of the present invention is to obtain the horizontal line of the fish body and the vertical line obtained by connecting the key points on the caudal peduncle and the key points under the caudal peduncle by accurately marking the key points on the caudal peduncle and the key points under the caudal peduncle, so as to calculate multiple measurement data of the fish body, thereby significantly improving the calculation accuracy of the fish phenotypic data.

[0051] Specifically, firstly, a plurality of target images of the target fish whose fish phenotypic data is to be measured are obtained, wherein the target images may be side views and top views of the target fish in different postures and angles.

[0052] Furthermore, a fish recognition model can be pre-trained, and the fish recognition model can identify the type of fish corresponding to the image. One of the multiple target images is input into the fish recognition model, or, to ensure recognition accuracy, multiple target images can be input into the fish recognition model, and after model calculation, the target type of the target fish corresponding to the target image can be determined. After the fish phenotypic data is obtained later, it can be determined that the obtained fish phenotypic data are all phenotypic data corresponding to the target type of fish, which is helpful for accurate fish morphological research and breeding management.

[0053] S12. Identify multiple key points corresponding to the fish body in each target image based on the pre-trained fish body key point recognition model.

[0054] In the embodiment of the present invention, a fish body key point recognition model is pre-trained. The multiple target images of the target fish obtained above are input into the fish body key point recognition model, and the model outputs the fish body key point labeling result, wherein multiple key points can be labeled, including the upper tail peduncle key point and the lower tail peduncle key point. Figure 2 As shown, including 1 tip of snout, 2 posterior edge of operculum, 3 highest point of head, 4 isthmus, 5 highest point of dorsal edge, 6 lowest point of ventral edge, 7 upper caudal peduncle, 8 lower caudal peduncle, 9 end of caudal fin, 10 posterior edge of caudal vertebra, 11 anterior edge of eye, 12 posterior edge of eye, 13 starting point of pectoral fin, 14 end of pectoral fin base, 15 starting point of pelvic fin, 16 end of pelvic fin base, 17 starting point of anal fin, 18 posterior end of anal fin base, 19 outer edge of anal fin, 20 starting point of dorsal fin, 21 posterior end of dorsal fin base, 22 outer edge of dorsal fin.

[0055] Optionally, since the upper and lower caudal peduncle key points are the two most important key points for subsequent calculation of fish phenotypic data, a manual confirmation step can be added based on model recognition. Professionals manually and accurately mark the upper and lower caudal peduncle key points again. In order to ensure the consistency and accuracy of the marking, the two key points are defined as a mirror symmetric relationship.

[0056] S13, determining the horizontal line of the fish body by taking the key points on the tail peduncle and the key points under the tail peduncle as mirror images.

[0057] S14, connecting the key points on the caudal peduncle and the key points under the caudal peduncle to obtain a vertical line.

[0058] S15. Calculate projection data of the target key point on the horizontal line and the vertical line of the fish body respectively based on the horizontal line and the vertical line of the fish body.

[0059] S16. Calculate target phenotypic data corresponding to the target fish based on the projection data.

[0060] The following is a unified description of S13-S16:

[0061] The horizontal line of the fish body is determined by using the key points on the caudal peduncle and the key points under the caudal peduncle as mirror symmetry; the key points on the caudal peduncle and the key points under the caudal peduncle are connected to obtain a vertical line. Based on the horizontal line and vertical line of the fish body, the projection data of other target key points except the key points on the caudal peduncle and the key points under the caudal peduncle on the horizontal line and vertical line of the fish body are calculated respectively, and the target phenotypic data corresponding to the target fish is calculated based on the projection data.

[0062] Among them, the target key points are at least one of the tip of the snout, the rear edge of the operculum, the highest point of the head, the isthmus, the highest point of the dorsal edge, the lowest point of the ventral edge, the end of the caudal vertebrae, the front edge of the eye, the rear edge of the eye, the starting point of the pectoral fin, the end of the pectoral fin base, the starting point of the pelvic fin, the end of the pelvic fin base, the starting point of the anal fin, the rear end of the anal fin base, the outer edge of the anal fin, the starting point of the dorsal fin, the rear end of the dorsal fin base, and the outer edge of the dorsal fin. The target phenotypic data at least includes the total length, body length, body height, snout length, head length, head height, caudal peduncle length, caudal peduncle height, caudal fin length, head length behind the eye, eye diameter, dorsal fin front distance, and dorsal fin back distance. The calculation of different target phenotypic data requires different target key points to participate in the calculation.

[0063] Specifically, the target phenotypic data may be divided into first type phenotypic data, second type phenotypic data and third type phenotypic data.

[0064] The first type of phenotypic data is calculated based on the first formula, and the first type of phenotypic data is any one of the total length, body length, snout length, head length, tail peduncle length, tail fin length, head length behind the eye, eye diameter, dorsal fin front distance, and dorsal fin rear distance. The first formula is:

[0065] Among them, A is the first type of phenotypic data, and the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x 8 ,y 8 ), X is the horizontal coordinate difference of other key points required for the phenotypic data to be calculated, and Y is the vertical coordinate difference of other key points required for the phenotypic data to be calculated.

[0066] For example, the total length: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), snout tip C(x 1 ,y 1 ), tail fin end D(x 9 ,y 9 ), the total length is the horizontal distance between the snout tip and the tail fin tip, and the calculation formula is as follows:

[0067]

[0068] Body length: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), snout tip C(x 1 ,y 1 ), the posterior edge of the coccyx D(x 10 ,y 10 ), body length is the horizontal distance between the snout tip and the rear edge of the caudal vertebrae, and the calculation formula is as follows:

[0069]

[0070] Snout length: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), snout tip C(x 1 ,y 1 ), the anterior edge D(x 11 ,y11 ), the snout length is the horizontal distance between the tip of the snout and the front edge of the eye, and the calculation formula is as follows:

[0071]

[0072] Head length: Note the key point A(x 9 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), snout tip C(x 1 ,y 1 ), posterior edge of operculum D(x 2 ,y 2 ), head length is the horizontal distance between the tip of the snout and the posterior edge of the operculum, and the calculation formula is as follows:

[0073]

[0074] Tail peduncle length: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), the posterior edge of the coccyx C(x 10 ,y 10 ), posterior end of anal fin base D(x 18 ,y 18 ), the caudal peduncle length is the horizontal distance between the rear edge of the caudal vertebrae and the rear end of the anal fin base, and the calculation formula is as follows:

[0075]

[0076] Tail fin length: Note the key point A (x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), tail fin end C(x 9 ,y 9 ), the posterior edge of the coccyx D(x 10 ,y 10 ), the tail fin length is the horizontal distance between the end of the tail fin and the rear edge of the caudal vertebrae, and the calculation formula is as follows:

[0077]

[0078] The length of the head behind the eye: remember the key point A (x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), posterior margin of operculum C(x 2 ,y 2 ), posterior margin of eye D(x 12 ,y 12), the length of the head behind the eye is the horizontal distance between the posterior edge of the operculum and the posterior edge of the eye, and the calculation formula is as follows:

[0079]

[0080] Eye diameter: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), the anterior edge C(x 11 ,y 11 ), posterior margin of eye D(x 12 ,y 12 ), the eye diameter is the horizontal distance between the anterior edge of the eye and the posterior edge of the eye, and the calculation formula is as follows:

[0081]

[0082] Dorsal fin front distance: note the key point A (x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), snout tip C(x 1 ,y 1 ), dorsal fin starting point D(x 20 ,y 20 ), the dorsal fin front distance is the horizontal distance between the snout tip and the dorsal fin starting point, and the calculation formula is as follows:

[0083]

[0084] Back distance of dorsal fin: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), dorsal fin starting point C(x 20 ,y 20 ), the posterior edge of the coccyx D(x 10 ,y 10 ), the dorsal fin back distance is the horizontal distance between the starting point of the dorsal fin and the rear edge of the caudal vertebrae, and the calculation formula is as follows:

[0085]

[0086] The second type of phenotypic data is calculated based on the second formula. The second type of phenotypic data is any one of body height and head height. The second formula is:

[0087] Among them, B is the second type of phenotypic data, and the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x 8 ,y8 ), X is the horizontal coordinate difference of other key points required for the phenotypic data to be calculated, and Y is the vertical coordinate difference of other key points required for the phenotypic data to be calculated.

[0088] For example, body height: Note the key point A(x 7 ,y 7 ), below the caudal peduncle B(x 8 ,y 8 ), the highest point of the back edge C(x 5 ,y 5 ), the lowest point of the ventral margin D(x 6 ,y 6 ), body height is the vertical distance between the highest point of the back edge and the lowest point of the belly edge, and the calculation formula is as follows:

[0089]

[0090] Head height: Note the key point A(x 1 ,y 1 ), below the caudal peduncle B(x 2 ,y 2 ), the highest point of the head C(x 3 ,y 3 ), isthmus D(x 4 ,y 4 ), head height is the vertical distance between the highest point of the head and the isthmus, and the calculation formula is as follows:

[0091]

[0092] The third type of phenotypic data is calculated based on the third formula. The third type of phenotypic data is the tail peduncle height. The third formula is:

[0093] Among them, C is the third type of phenotypic data, and the key point A(x 1 ,y 1 ), below the caudal peduncle B(x 2 ,y 2 ).

[0094] For example, the height of the tail peduncle: record the key point A(x 1 ,y 1 ), below the caudal peduncle B(x 2 ,y 2 ), the caudal peduncle height is the distance between the upper caudal peduncle and the lower caudal peduncle, and the calculation formula is as follows:

[0095]

[0096] The calculation method of other fish phenotypic data, for example, the base length of the dorsal fin: record the dorsal fin starting point A (x 20 ,y 20), posterior end of dorsal fin base B(x 21 ,y 21 ), the dorsal fin base length is the distance between the starting point of the dorsal fin and the rear end of the dorsal fin base, and the calculation formula is as follows:

[0097]

[0098] Dorsal fin length: Note the starting point of the dorsal fin A (x 20 ,y 20 ), dorsal fin outer edge B(x 22 ,y 22 ), the dorsal fin length is the distance between the starting point of the dorsal fin and the outer edge of the dorsal fin, and the calculation formula is as follows:

[0099]

[0100] Pectoral fin distance: note the pectoral fin starting point A (x 13 ,y 13 ), dorsal fin starting point B(x 20 ,y 20 ), the pectoral-dorsal fin distance is the distance between the starting point of the pectoral fin and the starting point of the dorsal fin, and the calculation formula is as follows:

[0101]

[0102] Pectoral fin distance: note the pectoral fin starting point A (x 13 ,y 13 ), pelvic fin starting point B(x 15 ,y 15 ), the pectoral fin distance is the distance between the starting point of the pectoral fin and the starting point of the pelvic fin, and the calculation formula is as follows:

[0103]

[0104] Pectoral fin length: note the pectoral fin starting point A (x 13 ,y 13 ), the end of the pectoral fin base B(x 14 ,y 14 ), the pectoral fin length is the distance between the starting point of the pectoral fin and the end of the pectoral fin base, and the calculation formula is as follows:

[0105]

[0106] Dorsal fin distance: record the starting point of the pelvic fin A (x 15 ,y 15 ), dorsal fin starting point B(x 20 ,y 20 ), the ventral-dorsal fin distance is the distance between the starting point of the ventral fin and the starting point of the dorsal fin, and the calculation formula is as follows:

[0107]

[0108] Distance between the base of the pelvic fin and the starting point of the pelvic fin: A(x 15 ,y 15 ), anal fin starting point B(x 17 ,y 17 ), the ventral anal fin base distance is the distance between the starting point of the ventral fin and the starting point of the anal fin, and the calculation formula is as follows:

[0109]

[0110] Pelvic fin length: record the starting point of the pelvic fin A (x 15 ,y 15 ), the end of the pelvic fin base B(x 16 ,y 16 ), the pelvic fin length is the distance between the starting point of the pelvic fin and the end of the pelvic fin base, and the calculation formula is as follows:

[0111]

[0112] Anal fin base length: note the starting point of the anal fin A (x 17 ,y 17 ), posterior end of anal fin base B(x 18 ,y 18 ), the anal fin base length is the distance between the starting point of the anal fin and the rear end of the anal fin base, and the calculation formula is as follows:

[0113]

[0114] Anal fin length: note the starting point of the anal fin A (x 17 ,y 17 ), anal fin outer edge B(x 19 ,y 19 ), the anal fin length is the distance between the starting point of the anal fin and the outer edge of the anal fin, and the calculation formula is as follows:

[0115]

[0116] Through the method of the embodiment of the present invention, by combining manual precise annotation and deep learning models, the calculation accuracy of fish phenotypic data can be significantly improved, which helps to conduct fish morphological research and breeding management more accurately and improve scientific research and production efficiency.

[0117] The method for measuring fish phenotypic data provided by the embodiment of the present invention obtains multiple target images of target fish; identifies multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model, wherein the multiple key points include key points on the caudal peduncle and key points below the caudal peduncle; calculates the phenotypic data of the target fish based on the key points on the caudal peduncle and key points below the caudal peduncle and other key points, and obtains multiple phenotypic data corresponding to the target fish. Compared with the existing fish phenotypic data measurement methods, which mostly rely on the overall shooting of the fish body shape, it is impossible to avoid the movement of the fish body during the shooting process, or the difference in the morphology of different fish bodies, resulting in the problem of low accuracy of the measurement data. According to the present method, by accurately marking the key points on the caudal peduncle and the key points below the caudal peduncle to calculate the fish phenotypic data, the error in the fish body morphology measurement can be reduced, the measurement accuracy of the fish phenotypic data can be improved, and more accurate and reliable data support can be provided for fish morphological research and aquaculture management, thereby improving scientific research and production efficiency.

[0118] Figure 3 A flow chart of a method for training a fish body key point recognition model provided by an embodiment of the present invention is shown in FIG. Figure 3 As shown, the method specifically includes:

[0119] S31, collecting multiple images of different fish in different postures and angles to obtain multiple target images corresponding to each target fish.

[0120] The purpose of an embodiment of the present invention is to train a fish body key point recognition model, which can accurately mark multiple key points in fish images and further calculate fish phenotypic data with multiple key points. Therefore, a large number of model training sample images are required to train the model to improve the generalization ability of the model.

[0121] First, multiple images of different fish in different postures and angles are collected to obtain multiple target images corresponding to each target fish.

[0122] S32, annotating the key points of the fish bodies of the multiple target images corresponding to each target fish species to obtain a set of annotated sample images.

[0123] Professionals annotate the key points of the fish body for the multiple target images corresponding to each target fish species collected above. The key points of the fish body must include the key points on the caudal peduncle and the key points below the caudal peduncle. Since the key points on the caudal peduncle and the key points below the caudal peduncle are the two most important key points for the subsequent calculation of fish phenotypic data, more accurate annotation is required. Figure 2As shown, including: 1 tip of snout, 2 posterior edge of operculum, 3 highest point of head, 4 isthmus, 5 highest point of dorsal edge, 6 lowest point of ventral edge, 7 upper caudal peduncle, 8 lower caudal peduncle, 9 end of caudal fin, 10 posterior edge of caudal vertebra, 11 anterior edge of eye, 12 posterior edge of eye, 13 starting point of pectoral fin, 14 end of pectoral fin base, 15 starting point of pelvic fin, 16 end of pelvic fin base, 17 starting point of anal fin, 18 posterior end of anal fin base, 19 outer edge of anal fin, 20 starting point of dorsal fin, 21 posterior end of dorsal fin base, 22 outer edge of dorsal fin.

[0124] S33, dividing the multiple target images corresponding to each target fish in the sample image set into a model training image and a model test image to obtain a model training image set and a model test image set.

[0125] The multiple target images corresponding to each target fish in the sample image set with key point annotations are randomly divided into model training images and model testing images according to a certain ratio, and all model training images are saved as a model training image set, and all model testing images are saved as a model testing image set.

[0126] S34. Perform deep learning training on the CSPNext backbone network model based on the model training image set, and test the CSPNext backbone network model after deep learning training based on the model test image set.

[0127] The CSPNext backbone network model is trained with the model training image set. During the training process, the labeled key point data is used to optimize the model. Furthermore, the CSPNext backbone network model after deep learning training is tested based on the model test image set to obtain the key point labeling results output by the CSPNext backbone network model for the model test image set.

[0128] S35. If the test result meets the preset conditions, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as a fish body key point recognition model.

[0129] The results of the key point annotation of the model test image set by the CSPNext backbone network model after the above deep learning training are compared with the results of the manual key point annotation to obtain a comparison result. When the comparison result shows that the accuracy of the model annotation reaches a preset threshold (for example, 99%), it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as the fish body key point recognition model.

[0130] Furthermore, the fish body key point recognition model can be used to annotate the fish body key points of multiple target images of target fish.

[0131] The training method of the fish key point recognition model provided by the embodiment of the present invention obtains multiple target images corresponding to each target fish by collecting multiple images of different postures and angles of different fish; the multiple target images corresponding to each target fish are annotated with fish key points to obtain a sample image set with annotated fish, wherein the fish key points include the upper key points of the tail peduncle and the lower key points of the tail peduncle; the multiple target images corresponding to each target fish in the sample image set are divided into model training images and model test images to obtain a model training image set and a model test image set; the CSPNext backbone network model is trained with deep learning based on the model training image set, and the CSPNext backbone network model after deep learning training is tested based on the model test image set; if the test result meets the preset conditions, it is determined that the CSPNext backbone network model training is completed, and the trained CSPNext backbone network model is used as the fish key point recognition model. Compared with the existing fish phenotypic data measurement method, which relies more on automated image processing technology, it is impossible to accurately identify the key points of the fish body, resulting in inaccurate measurement results. By using this method, a fish key point recognition model is trained through a large number of fish images with key points manually and accurately annotated, which can improve the accuracy of key point recognition and thus improve the calculation accuracy of fish phenotypic data.

[0132] Figure 4 A schematic diagram of a device for measuring fish phenotypic data provided by an embodiment of the present invention specifically includes:

[0133] The acquisition module 401 is used to acquire multiple target images of target fish. For detailed description, please refer to the relevant description corresponding to the above method embodiment, which will not be repeated here.

[0134] The recognition module 402 is used to recognize multiple key points corresponding to the fish body in each target image based on the pre-trained fish body key point recognition model, wherein the multiple key points include the upper key point of the tail peduncle and the lower key point of the tail peduncle. For detailed description, please refer to the relevant description corresponding to the above method embodiment, which will not be repeated here.

[0135] The measurement module 403 is used to calculate the phenotypic data of the target fish based on the key points on the caudal peduncle, the key points under the caudal peduncle and other key points to obtain multiple phenotypic data corresponding to the target fish. For detailed description, please refer to the relevant description corresponding to the above method embodiment, which will not be repeated here.

[0136] The device for measuring fish phenotypic data provided in this embodiment can be as follows Figure 4 The device for measuring fish phenotypic data shown in FIG. Figure 1 All steps of the fish phenotypic data measurement method are achieved Figure 1 The technical effects of the measurement methods for the fish phenotypic data shown are detailed in Figure 1 For the sake of brevity, the relevant description is not repeated here.

[0137] Figure 5 A schematic diagram of the structure of an electronic device provided by an embodiment of the present invention, Figure 5 The electronic device 500 shown includes: at least one processor 501, a memory 502, at least one network interface 504 and other user interfaces 503. The various components in the electronic device 500 are coupled together via a bus system 505. It is understood that the bus system 505 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 505 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, the bus system 505 is not shown in FIG. Figure 5 Various buses are labeled as bus system 505 .

[0138] The user interface 503 may include a display, a keyboard, or a pointing device (eg, a mouse, a trackball, a touch pad, or a touch screen).

[0139] It can be understood that the memory 502 in the embodiment of the present invention can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example but not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM) and direct RAM bus random access memory (DRRAM). The memory 502 described herein is intended to include, but is not limited to, these and any other suitable types of memory.

[0140] In some implementations, the memory 502 stores the following elements, executable units or data structures, or a subset thereof, or an extended set thereof: an operating system 5021 and an application program 5022 .

[0141] The operating system 5021 includes various system programs, such as a framework layer, a core library layer, a driver layer, etc., which are used to implement various basic services and process hardware-based tasks. The application 5022 includes various application programs, such as a media player (Media Player), a browser (Browser), etc., which are used to implement various application services. The program for implementing the method of the embodiment of the present invention can be included in the application 5022.

[0142] In the embodiment of the present invention, by calling the program or instruction stored in the memory 502, specifically, the program or instruction stored in the application 5022, the processor 501 is used to execute the method steps provided by each method embodiment, for example, including:

[0143] Acquire multiple target images of target fish; identify multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model, wherein the multiple key points include an upper caudal peduncle key point and a lower caudal peduncle key point; calculate the phenotypic data of the target fish based on the upper caudal peduncle key point, the lower caudal peduncle key point and other key points to obtain multiple phenotypic data corresponding to the target fish.

[0144] In one possible implementation, the horizontal line of the fish body is determined by taking the key points on the caudal peduncle and the key points below the caudal peduncle as mirror symmetry; the key points on the caudal peduncle and the key points below the caudal peduncle are connected to obtain a vertical line; the phenotypic data of the target fish is calculated based on the horizontal line and the vertical line of the fish body and other key points to obtain multiple phenotypic data corresponding to the target fish.

[0145] In one possible implementation, projection data of other key points on the horizontal line and vertical line of the fish body are calculated respectively based on the horizontal line and vertical line of the fish body; phenotypic data of the target fish are calculated based on the projection data to obtain multiple phenotypic data corresponding to the target fish.

[0146] In one possible embodiment, the multiple phenotypic data at least include total length, body length, body height, snout length, head length, head height, caudal peduncle length, caudal peduncle height, caudal fin length, head length behind the eye, eye diameter, dorsal fin front distance, dorsal fin back distance; the total length, body length, snout length, head length, caudal peduncle length, caudal fin length, head length behind the eye, eye diameter, dorsal fin front distance, dorsal fin back distance are calculated based on a first formula, and the first formula is: The body height and head height are calculated based on a second formula, wherein the second formula is: The caudal peduncle height is calculated based on a third formula, which is: Among them, the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x 8 ,y 8 ), X is the horizontal coordinate difference of other key points required for the phenotypic data to be calculated, and Y is the vertical coordinate difference of other key points required for the phenotypic data to be calculated.

[0147] Collect multiple images of different fishes in different postures and angles to obtain multiple target images corresponding to each target fish; annotate the multiple target images corresponding to each target fish to obtain a sample image set with annotated key points, wherein the fish key points include the upper caudal peduncle key point and the lower caudal peduncle key point; divide the multiple target images corresponding to each target fish in the sample image set into model training images and model test images to obtain a model training image set and a model test image set; perform deep learning training on the CSPNext backbone network model based on the model training image set, and test the CSPNext backbone network model after deep learning training based on the model test image set; if the test result meets the preset conditions, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as the fish key point recognition model.

[0148] In one possible implementation, the results of key point labeling of the model test image set by the CSPNext backbone network model after deep learning training are compared with the results of manual key point labeling to obtain a comparison result; when the comparison result shows that the accuracy of the model labeling reaches a preset threshold, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as a fish body key point recognition model.

[0149] The method disclosed in the above embodiment of the present invention can be applied to the processor 501, or implemented by the processor 501. The processor 501 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit in the processor 501 or the instruction in the form of software. The above processor 501 can be a general processor, a digital signal processor (Digital Signal Processor, DSP), an application specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present invention can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiment of the present invention can be directly embodied as a hardware decoding processor to execute, or the hardware and software units in the decoding processor can be executed. The software unit can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 502, and the processor 501 reads the information in the memory 502 and completes the steps of the above method in combination with its hardware.

[0150] It is understood that the embodiments described herein may be implemented in hardware, software, firmware, middleware, microcode, or a combination thereof. For hardware implementation, the processing unit may be implemented in one or more application specific integrated circuits (ASIC), digital signal processors (DSP), digital signal processing devices (DSPDevice, DSPD), programmable logic devices (PLD), field programmable gate arrays (FPGA), general purpose processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in the present application, or a combination thereof.

[0151] For software implementation, the technology described herein can be implemented by a unit that performs the functions described herein. The software code can be stored in a memory and executed by a processor. The memory can be implemented in the processor or outside the processor.

[0152] The electronic device provided in this embodiment may be Figure 5 The electronic device shown in FIG. 1 may perform the following steps: Figure 1 Methods for measuring fish phenotypic data and Figure 3 All steps of the training method of the fish body key point recognition model are implemented Figure 1 Methods for measuring fish phenotypic data and Figure 3 For details, please refer to the technical effect of the training method of the fish body key point recognition model. Figure 1 and Figure 3 For the sake of brevity, the relevant description is not repeated here.

[0153] The embodiment of the present invention also provides a storage medium (computer-readable storage medium). The storage medium here stores one or more programs. The storage medium may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a read-only memory, a flash memory, a hard disk or a solid-state drive; the memory may also include a combination of the above-mentioned types of memory.

[0154] When one or more programs in the storage medium can be executed by one or more processors, the above-mentioned method for measuring fish phenotype data and the method for training a fish body key point recognition model executed on the electronic device side can be implemented.

[0155] The processor is used to execute the fish phenotype data measurement program and the fish body key point recognition model training program stored in the memory to implement the following steps of the fish phenotype data measurement method and the fish body key point recognition model training method performed on the electronic device side:

[0156] Acquire multiple target images of target fish; identify multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model, wherein the multiple key points include an upper caudal peduncle key point and a lower caudal peduncle key point; calculate the phenotypic data of the target fish based on the upper caudal peduncle key point, the lower caudal peduncle key point and other key points to obtain multiple phenotypic data corresponding to the target fish.

[0157] In one possible implementation, the horizontal line of the fish body is determined by taking the key points on the caudal peduncle and the key points below the caudal peduncle as mirror symmetry; the key points on the caudal peduncle and the key points below the caudal peduncle are connected to obtain a vertical line; the phenotypic data of the target fish is calculated based on the horizontal line and the vertical line of the fish body and other key points to obtain multiple phenotypic data corresponding to the target fish.

[0158] In one possible implementation, projection data of other key points on the horizontal line and vertical line of the fish body are calculated respectively based on the horizontal line and vertical line of the fish body; phenotypic data of the target fish are calculated based on the projection data to obtain multiple phenotypic data corresponding to the target fish.

[0159] In one possible embodiment, the multiple phenotypic data at least include total length, body length, body height, snout length, head length, head height, caudal peduncle length, caudal peduncle height, caudal fin length, head length behind the eye, eye diameter, dorsal fin front distance, dorsal fin back distance; the total length, body length, snout length, head length, caudal peduncle length, caudal fin length, head length behind the eye, eye diameter, dorsal fin front distance, dorsal fin back distance are calculated based on a first formula, and the first formula is: The body height and head height are calculated based on a second formula, wherein the second formula is: The caudal peduncle height is calculated based on a third formula, which is: Among them, the coordinates of the key points on the tail peduncle are A(x 7 ,y 7 ), the coordinates of the key point under the tail peduncle are B(x 8 ,y 8 ), X is the horizontal coordinate difference of other key points required for the phenotypic data to be calculated, and Y is the vertical coordinate difference of other key points required for the phenotypic data to be calculated.

[0160] Collect multiple images of different fishes in different postures and angles to obtain multiple target images corresponding to each target fish; annotate the multiple target images corresponding to each target fish to obtain a sample image set with annotated key points, wherein the fish key points include the upper caudal peduncle key point and the lower caudal peduncle key point; divide the multiple target images corresponding to each target fish in the sample image set into model training images and model test images to obtain a model training image set and a model test image set; perform deep learning training on the CSPNext backbone network model based on the model training image set, and test the CSPNext backbone network model after deep learning training based on the model test image set; if the test result meets the preset conditions, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as the fish key point recognition model.

[0161] In one possible implementation, the results of key point labeling of the model test image set by the CSPNext backbone network model after deep learning training are compared with the results of manual key point labeling to obtain a comparison result; when the comparison result shows that the accuracy of the model labeling reaches a preset threshold, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as a fish body key point recognition model.

[0162] The professionals should further realize that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in terms of function in the above description. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.

[0163] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.

[0164] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for measuring fish phenotypic data, characterized in that: include: Acquire multiple target images of target fish; Based on the pre-trained fish body key point recognition model, a plurality of key points corresponding to the fish body in each target image are identified, wherein the plurality of key points include an upper caudal peduncle key point and a lower caudal peduncle key point; Determine the horizontal line of the fish body by using the key point on the caudal peduncle and the key point below the caudal peduncle as mirror images; Connect the key points on the caudal peduncle and the key points below the caudal peduncle to obtain a vertical line; Based on the horizontal line and vertical line of the fish body, the projection data of the target key points on the horizontal line and vertical line of the fish body are calculated respectively, wherein the target key points are at least one of the tip of the snout, the rear edge of the operculum, the highest point of the head, the isthmus, the highest point of the dorsal edge, the lowest point of the ventral edge, the end of the caudal vertebra, the front edge of the eye, the rear edge of the eye, the starting point of the pectoral fin, the end of the base of the pectoral fin, the starting point of the pelvic fin, the end of the base of the pelvic fin, the starting point of the anal fin, the rear end of the base of the anal fin, the outer edge of the anal fin, the starting point of the dorsal fin, the rear end of the base of the dorsal fin, and the outer edge of the dorsal fin; Calculating target phenotypic data corresponding to the target fish based on the projection data, wherein calculation of different target phenotypic data corresponds to different target key points; The target phenotypic data at least include total length, body length, body height, snout length, head length, head height, caudal peduncle length, caudal peduncle height, caudal fin length, head length behind the eye, eye diameter, front distance of dorsal fin, and back distance of dorsal fin. The target phenotypic data include first type phenotypic data, second type phenotypic data, and third type phenotypic data; The calculating the target phenotypic data corresponding to the target fish based on the projection data comprises: The first type of phenotypic data is calculated based on the first formula, and the first type of phenotypic data is any one of the total length, body length, snout length, head length, caudal peduncle length, caudal fin length, head length behind the eye, eye diameter, front distance of dorsal fin, and back distance of dorsal fin. The first formula is: A= ; Among them, A is the first type of phenotypic data, and the coordinates of the key points on the caudal peduncle are A( , ), the coordinates of the key point under the tail peduncle are B( , ), X is the horizontal coordinate difference of the target key point required for the target phenotypic data to be calculated, and Y is the vertical coordinate difference of the target key point required for the target phenotypic data to be calculated.

2. The method according to claim 1, characterized in that The calculating the target phenotypic data corresponding to the target fish based on the projection data also includes: The second type of phenotypic data is calculated based on the second formula, the second type of phenotypic data is any one of the body height and head height, and the second formula is: B= ; Among them, B is the second type of phenotypic data, and the coordinates of the key points on the tail peduncle are A( , ), the coordinates of the key point under the tail peduncle are B( , ), X is the horizontal coordinate difference of the target key point required for the target phenotypic data to be calculated, and Y is the vertical coordinate difference of the target key point required for the target phenotypic data to be calculated.

3. The method according to claim 1, characterized in that The calculating the target phenotypic data corresponding to the target fish based on the projection data also includes: The third type of phenotypic data is calculated based on the third formula, the third type of phenotypic data is the caudal peduncle height, and the third formula is: ; Among them, C is the third type of phenotypic data, and the coordinates of the key points on the tail peduncle are A( , ), the coordinates of the key point under the tail peduncle are B( , ).

4. The method according to claim 1, characterized in that: Before the fish body key point recognition model based on the pre-training recognizes a plurality of key points corresponding to the fish body in each target image, the method includes: Collect multiple images of different fish in different postures and angles to obtain multiple target images corresponding to each target fish; Marking the key points of the fish body for the multiple target images corresponding to each target fish to obtain a sample image set with completed marking, wherein the key points of the fish body include the key points on the caudal peduncle and the key points below the caudal peduncle; Dividing a plurality of target images corresponding to each target fish in the sample image set into a model training image and a model test image to obtain a model training image set and a model test image set; Performing deep learning training on the CSPNext backbone network model based on the model training image set, and testing the CSPNext backbone network model after deep learning training based on the model test image set; If the test results meet the preset conditions, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as the fish body key point recognition model.

5. The method according to claim 4, characterized in that If the test result meets the preset conditions, it is determined that the CSPNext backbone network model training is completed, and the trained CSPNext backbone network model is used as the fish body key point recognition model, including: Compare the key point labeling results of the CSPNext backbone network model trained by deep learning on the model test image set with the results of manual key point labeling to obtain a first comparison result; When the first comparison result is that the accuracy of the model annotation reaches a preset threshold, it is determined that the training of the CSPNext backbone network model is completed, and the trained CSPNext backbone network model is used as a fish body key point recognition model.

6. The method according to claim 1, characterized in that After obtaining a plurality of target images of the target fish, the method includes: Based on the pre-trained fish recognition model, the target types of the target fish corresponding to the multiple target images are identified.

7. A device for measuring fish phenotypic data, characterized in that: include: An acquisition module, used for acquiring multiple target images of target fish; A recognition module, used to recognize multiple key points corresponding to the fish body in each target image based on a pre-trained fish body key point recognition model, wherein the multiple key points include an upper caudal peduncle key point and a lower caudal peduncle key point; A measurement module is used to determine the horizontal line of the fish body with the key points on the caudal peduncle and the key points under the caudal peduncle as mirror symmetry; connect the key points on the caudal peduncle and the key points under the caudal peduncle to obtain a vertical line; calculate the projection data of the target key points on the horizontal line and the vertical line of the fish body based on the horizontal line and the vertical line of the fish body, wherein the target key points are at least one of the tip of the snout, the rear edge of the operculum, the highest point of the head, the isthmus, the highest point of the dorsal margin, the lowest point of the ventral margin, the end of the caudal vertebra, the front edge of the eye, the rear edge of the eye, the starting point of the pectoral fin, the end of the base of the pectoral fin, the starting point of the pelvic fin, the end of the base of the pelvic fin, the starting point of the anal fin, the rear end of the base of the anal fin, the outer edge of the anal fin, the starting point of the dorsal fin, the rear end of the base of the dorsal fin, and the outer edge of the dorsal fin; calculate the target phenotypic data corresponding to the target fish based on the projection data, wherein the calculation of different target phenotypic data corresponds to different target key points; The target phenotypic data at least include total length, body length, body height, snout length, head length, head height, caudal peduncle length, caudal peduncle height, caudal fin length, head length behind the eye, eye diameter, front distance of dorsal fin, and back distance of dorsal fin. The target phenotypic data include first type phenotypic data, second type phenotypic data, and third type phenotypic data; The calculating the target phenotypic data corresponding to the target fish based on the projection data comprises: The first type of phenotypic data is calculated based on the first formula, and the first type of phenotypic data is any one of the total length, body length, snout length, head length, caudal peduncle length, caudal fin length, head length behind the eye, eye diameter, front distance of dorsal fin, and back distance of dorsal fin. The first formula is: A= ; Among them, A is the first type of phenotypic data, and the coordinates of the key points on the caudal peduncle are A( , ), the coordinates of the key point under the tail peduncle are B( , ), X is the horizontal coordinate difference of the target key point required for the target phenotypic data to be calculated, and Y is the vertical coordinate difference of the target key point required for the target phenotypic data to be calculated.

8. An electronic device, characterized in that: include: A processor and a memory, wherein the processor is used to execute a fish phenotypic data measurement program stored in the memory to implement the fish phenotypic data measurement method according to any one of claims 1 to 6.

9. A storage medium, characterized in that: The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the method for measuring fish phenotypic data according to any one of claims 1 to 6.