Method and System for Extracting Individual Identification Features of Giant Pandas Based on Image Processing

The eye orbit and shoulder strap features of giant pandas were extracted through infrared image processing and least squares ellipse fitting, which solved the problem of low recognition accuracy of giant pandas and achieved efficient individual recognition.

CN120220192BActive Publication Date: 2025-07-25CHENGDU RES BASE OF GIANT PANDA BREEDING
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510695478.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-05-28
Publication Date
2025-07-25
Estimated Expiration
2045-05-28

AI Technical Summary

Technical Problem

In the prior art, giant pandas have low accuracy in recognition, small differences in facial features, and are easily disturbed by noise, and sound recognition is easily affected by the environment.

Method used

Through infrared image processing, the least squares ellipse fitting method was used to extract the characteristic parameters of the eye orbit and shoulder strap of giant pandas, and the characteristics of the eye orbit and shoulder strap were identified.

Benefits of technology

It improves the accuracy and efficiency of giant panda identification, reduces the impact of environmental background on feature extraction, and achieves accurate identification of panda individuals.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120220192B_ABST
    Figure CN120220192B_ABST
Patent Text Reader

Abstract

The present application discloses a method and system for extracting individual identification features of giant pandas based on image processing, which relates to the field of biometric identification technology. First, an original infrared image file set of the giant panda to be identified is obtained, and the original image file set of the giant panda to be identified is extracted from it. Then, the original image file set is subjected to grayscale processing to respectively obtain the original orbital image set and the original scapular image set of the giant panda to be identified. Subsequently, the original orbital images are processed by the least squares ellipse fitting method to obtain the orbital feature parameters of the giant panda to be identified. Finally, the scapular feature parameters of the giant panda to be identified are obtained according to the original scapular image set. The present application improves the accuracy of the original image file by using the temperature difference between the body temperature of the giant panda and the environmental temperature, extracts the orbital parameters of the panda, and also extracts the scapular patterns with greater individual differences, so as to achieve precise identification of panda individuals through the combination of orbital features and scapular features, and improve the panda recognition accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of biometric devices, and particularly to a method and system for extracting individual identification features of giant pandas based on image processing. Background Art

[0002] In order to improve the protection of giant pandas, identification technologies based on physiological parameters such as panda facial features and sounds have been widely applied. In the technology of identifying by sound, the identification results are extremely vulnerable to interference from background noise. When identifying by facial features, the extracted feature parameters are few, and the facial differences of pandas are small, resulting in a low identification accuracy of pandas. Summary of the Invention

[0003] The main purpose of the present application is to provide a method and system for extracting individual identification features of giant pandas based on image processing, aiming to solve the defect of low identification accuracy in the prior art.

[0004] The present application achieves the above object through the following technical solutions:

[0005] A method for extracting individual identification features of giant pandas based on image processing, comprising the following steps:

[0006] Obtain the original infrared image file set of the giant panda to be identified;

[0007] Extract the original image file set of the giant panda to be identified from the original infrared image file set;

[0008] Perform grayscale processing on the original image file set to obtain the original image set of the eye sockets and the original image set of the scapular girdle of the giant panda to be identified respectively;

[0009] Process the original eye socket image by using the least squares ellipse fitting method to obtain the eye socket feature parameters of the giant panda to be identified;

[0010] Obtain the scapular girdle feature parameters of the giant panda to be identified according to the original scapular girdle image set.

[0011] Optionally, extracting the original image file set of the giant panda to be identified from the original infrared image file set includes the following steps:

[0012] Set the recognition temperature threshold of the original infrared image file set;

[0013] Obtain the original infrared image file set of the giant panda to be identified, and extract any one of the original infrared images therefrom;

[0014] Perform binarization processing on the original infrared image according to the recognition temperature threshold;

[0015] Extract the thermal distribution characteristics of the binarized original infrared image to obtain the original image of the giant panda to be recognized;

[0016] Repeat the steps of obtaining the original infrared image file set of the giant panda to be recognized and extracting any original infrared image from it until the original image file set of the giant panda to be recognized is obtained;

[0017] Optionally, perform grayscale processing on the original image file set to obtain the original orbital image set and the original scapular image set of the giant panda to be recognized, including the following steps:

[0018] Obtain the original image file set and select any original image from the original image file set;

[0019] Convert the original image to a grayscale image and perform noise reduction processing;

[0020] Set the screening grayscale value and obtain the feature image according to the screening grayscale value;

[0021] Repeat the steps of obtaining the original image file set and selecting any original image from the original image file set until all feature images are obtained;

[0022] Divide each of the feature images to obtain the original orbital image set and the original scapular image set of the giant panda to be recognized.

[0023] Optionally, setting the screening grayscale value and obtaining the feature image according to the screening grayscale value includes the following steps:

[0024] Set the screening grayscale value G0;

[0025] Obtain the original image after noise reduction processing and divide it into several cells;

[0026] Respectively obtain the actual grayscale value G of each of the cells n , where n represents the cell number;

[0027] If G n ≥G0, then eliminate the cell, otherwise retain it;

[0028] Repeat the comparison of the pixel values of each cell, and splice the retained cells according to the numbers of each cell to obtain the feature image.

[0029] Optionally, use the least squares ellipse fitting method to process the original orbital image to obtain the orbital feature parameters of the giant panda to be recognized, including the following steps:

[0030] Obtain the original orbital image set and select any original orbital image from it;

[0031] Extract the original orbital curve according to the gray value of the original orbital image;

[0032] Use the least squares ellipse fitting method to fit the original orbital curve to obtain the fitted orbital curve;

[0033] Calculate the orbital characteristic parameters according to the fitted orbital curve, and the orbital characteristic parameters include the major axis, minor axis and rotation angle.

[0034] Optionally, extracting the original orbital curve according to the gray value of the original orbital image includes the following steps:

[0035] Retrieve the first screening gray value G0;

[0036] Divide the original orbital image into several cells, and obtain the actual gray value G of each cell n ; where n represents the cell number;

[0037] Extract all the cells with the actual gray value equal to the first screening gray value G0, and number each cell in a clockwise or counterclockwise direction to obtain the first cell set {A1, A2,..., A m}; where m represents the cell number;

[0038] Generate the first fitting curve set according to the first cell set;

[0039] Randomly select several pixel units P i in the cell A x , and smoothly connect each pixel unit P i in sequence through the fitting curve L x ;

[0040] According to the numbers of the fitting curves, smoothly connect the fitting curves L i in sequence to obtain the original orbital curve.

[0041] Optionally, obtaining the scapular characteristic parameters of the giant panda to be recognized according to the original scapular image set includes the following steps:

[0042] Obtain the original scapular image set and select an original scapular image from it;

[0043] Calculate the scapular area S according to the gray value of the original scapular image 实 ;

[0044] Extract the original scapular curve according to the gray value of the original scapular image;

[0045] Judge the scapular type according to the original scapular curve and generate corresponding dimension parameters;

[0046] Output the shoulder strap area, shoulder strap type, and size parameters as shoulder strap characteristic parameters.

[0047] Optionally, calculate the shoulder strap area S according to the gray value of the original shoulder strap image 实 , including the following steps,

[0048] Retrieve the original shoulder strap image and set the second screening gray value G0';

[0049] Divide the original shoulder strap image into several cells, and respectively obtain the actual gray value G n ' of each cell; where n represents the cell number;

[0050] Extract all cells with actual gray value G n ' less than the second screening gray value G0' as the first cells, and calculate the first shoulder strap area. The expression of the first shoulder strap area is S1 = j * s0, where j represents the number of the first cells, and s0 represents the area of the cell;

[0051] Extract all cells with actual gray value G n ' equal to the second screening gray value G0' as the second cells, and obtain the second cell set {A1', A2',..., A t '}; where t represents the cell number;

[0052] Generate a fitting curve L i ' in each of the second cells A i ' according to the second screening gray value G0', and obtain the second fitting curve set {L1', L2',..., L t '};

[0053] The second fitting curve set {L1', L2',..., L t '} is used to divide each of the second cells A i ' respectively, and fit and calculate the effective area s i ' of each of the second cells A i ';

[0054] Calculate the second shoulder strap area and the shoulder strap area. The expression of the second shoulder strap area is S2 = s1' + s2' +... + s i ' +... + s t '; S 实 == S1 + S2.

[0055] Optionally, determine the shoulder strap type according to the original shoulder strap curve and generate corresponding characteristic parameters, including the following steps:

[0056] Obtain the original shoulder strap curve and determine the number P of the closed regions enclosed by the original shoulder strap;

[0057] If the number P≥2, it is determined that the original shoulder strap is a fracture zone, and the maximum width value, minimum width value, and length value are generated for each fracture zone respectively;

[0058] If the number P = 1, generate the minimum circumscribed rectangle for the original shoulder strap curve and calculate the area S of the minimum circumscribed rectangle 外 ;

[0059] Set the discrimination ratio Q0 and calculate the actual ratio Q 实 , if Q 实 ≥Q0, it is determined that the original shoulder strap is a rectangular shoulder strap, and the shoulder strap width value and shoulder strap length value are generated for the original shoulder strap curve; where the value of Q0 is 0.8 - 1, and the Q 实 =S 实 / S 外 ;

[0060] If Q 实 <Q0, it is determined that the original shoulder strap is a U-shaped shoulder strap, and the minimum width value, first width value, second width value, and length value are generated for the original shoulder strap.

[0061] Correspondingly, the present application also discloses a system based on the above feature extraction method, including,

[0062] A data acquisition module for acquiring the original infrared image file set of the giant panda to be recognized;

[0063] A data extraction module for extracting the original image file set of the giant panda to be recognized from the original infrared image file set;

[0064] An image processing module for performing gray processing on the original image file set to respectively obtain the original orbital image and the original shoulder strap image of the giant panda to be recognized;

[0065] A first calculation module for processing the original orbital image by using the least squares ellipse fitting method to obtain the orbital characteristic parameters of the giant panda to be recognized;

[0066] A second calculation module for obtaining the shoulder strap characteristic parameters of the giant panda to be recognized according to the original shoulder strap image.

[0067] Compared with the prior art, the present application has the following beneficial effects:

[0068] This application includes first obtaining the original infrared image file set of the giant panda to be recognized, extracting the original image file set of the giant panda to be recognized from it, then performing grayscale processing on the original image file set to respectively obtain the original orbital image set and the original scapular image set of the giant panda to be recognized; subsequently, processing the original orbital image through the least squares ellipse fitting method to obtain the orbital feature parameters of the giant panda to be recognized; finally, obtaining the scapular feature parameters of the giant panda to be recognized according to the original scapular image set;

[0069] Compared with the prior art, first, this application extracts the original image file through the infrared image file. The reason is that as a homeothermic animal, the infrared temperature image of the giant panda is relatively stable, and the ambient temperature around the panda is also relatively stable. Therefore, a stable temperature difference will be formed between the giant panda and the ambient temperature. Through the above temperature difference, the original image file can be accurately extracted on the infrared image, thereby reducing the influence of the environmental background on feature extraction and improving the accuracy of features and recognition;

[0070] Secondly, in the specific parameter extraction process of this application, not only the orbital parameters of the panda are extracted, but also the scapular patterns with obvious individual differences are extracted, so as to achieve precise identification of panda individuals through the combination of orbital features and scapular features and improve the accuracy of panda recognition;

[0071] Finally, when extracting the feature parameters of the panda's orbit, this application adopts the least squares ellipse fitting method. Compared with the method of comparing the contours of the black patches in the panda's orbit in the prior art, the parameters obtained by this application are more concise, the comparison efficiency is higher, and the ellipse parameters can more comprehensively reflect the overall situation of the panda's orbit, which is beneficial to improving the accuracy of recognition. Description of the Drawings

[0072] Figure 1 It is a flowchart of the method for extracting the individual identification features of giant pandas based on image processing provided in Embodiment 1 of this application;

[0073] Figure 2 It is a schematic diagram of dividing cells on the original orbital image;

[0074] Figure 3 It is a schematic diagram of the generation of the first fitting curve;

[0075] Figure 4 It is a schematic diagram of a broken scapular;

[0076] Figure 5 It is a schematic diagram of a rectangular scapular;

[0077] Figure 6 It is a schematic diagram of dividing cells on the original U-shaped scapular image;

[0078] Figure 7 Schematic diagram for calculating the effective area in the second cell

[0079] Figure 8 Schematic diagram for generating the second fitting curve

[0080] Figure 9 Schematic structural diagram of the identification feature extraction system

[0081] The implementation of the purpose, functional features and advantages of this application will be further described with reference to the embodiments and the accompanying drawings. Specific implementation manners

[0082] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

[0083] It should be noted that all directional indications (such as up, down, left, right, front, back...) in the embodiments of the present invention are only used to explain the relative positional relationship and movement conditions between components in a specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indications will also change accordingly.

[0084] In the present invention, unless otherwise clearly defined and limited, the terms "connection", "fixation", etc. should be understood in a broad sense. For example, "fixation" can be a fixed connection, a detachable connection, or integrated; it can be a mechanical connection or an electrical connection; it can be directly connected or indirectly connected through an intermediate medium, and it can be the communication inside two components or the interaction relationship between two components, unless otherwise clearly limited. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific situations.

[0085] In addition, if the embodiments of the present invention involve descriptions such as "first" and "second", the descriptions of "first", "second", etc. are only for descriptive purposes and should not be construed as indicating or implying their relative importance or implicitly specifying the quantity of the indicated technical features. Thus, the features defined with "first" and "second" may explicitly or implicitly include at least one such feature. In addition, the meaning of "and / or" appearing throughout the text includes three parallel scenarios. Taking "robot coordinate system and / or m" as an example, it includes the robot coordinate system scenario, or the m scenario, or the scenario where both the robot coordinate system and m are satisfied simultaneously. In addition, the technical solutions between various embodiments can be combined with each other, but it must be based on the ability of those of ordinary skill in the art to implement. When the combination of technical solutions results in contradictions or cannot be implemented, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection required by the present invention.

[0086] Embodiment 1

[0087] Referring to Figures 1 to 8 , this embodiment discloses a method for extracting individual identification features of giant pandas based on image processing, including the following steps:

[0088] S1. Obtain the original infrared image file set of the giant panda to be recognized;

[0089] Take pictures of the giant panda to be recognized through an infrared camera. It should be noted that when taking pictures, not only the frontal view of the giant panda's face needs to be taken, but also its back picture needs to be taken, so as to obtain the original infrared image file set containing multiple infrared images;

[0090] It should be noted that the original infrared image file set can also be obtained by screening from a database;

[0091] S2. Extract the original image file set of the giant panda to be recognized from the original infrared image file set;

[0092] S21. Set the recognition temperature threshold of the original infrared image file set;

[0093] The daily body temperature of a giant panda is generally 36.5°C - 37.5°C. Therefore, according to the body temperature of the giant panda, the recognition temperature threshold is set at 36.5°C - 37.5°C;

[0094] S22. Obtain the original infrared image file set of the giant panda to be recognized, and extract any one of the original infrared images from it;

[0095] S23. Perform binarization processing on the original infrared image according to the recognition temperature threshold;

[0096] Divide the original infrared image into several cells, and classify each cell according to the recognition temperature threshold;

[0097] That is, the area with a temperature higher than or equal to the recognition temperature threshold is a class, which is marked as 1, and the area with a temperature lower than the recognition temperature threshold is a class, which is marked as 0. The above-mentioned measures can complete the binarization of the original infrared image;

[0098] S24, extracting thermal distribution features from the original infrared image after binarization to obtain the original image of the giant panda to be identified;

[0099] Obtain the original infrared image after binarization processing. Since it is necessary to extract the image of the individual panda, all the areas marked as 1 are extracted and all the areas marked as 0 are removed, thereby obtaining the original image of the giant panda to be identified;

[0100] S25, repeating the steps of obtaining the original infrared image file set of the giant panda to be identified, and extracting any original infrared image therefrom, until the original image file set of the giant panda to be identified is obtained;

[0101] Repeat the above steps to obtain all original images and group them into the original image file set of the giant panda to be identified.

[0102] S3, performing grayscale processing on the original image file set to obtain an original image set of eye sockets and an original image set of shoulder straps of the panda to be identified;

[0103] S31, obtaining an original image file set, and selecting an original image from the original image file set;

[0104] S32, converting the original image into a grayscale image and performing noise reduction processing;

[0105] It should be noted that the conversion into a grayscale image and the noise reduction processing of the image are both performed using existing technologies, such as using Gaussian filtering or median filtering for noise reduction.

[0106] The above-mentioned noise reduction processing can effectively improve the accuracy of data extraction;

[0107] S33, setting a screening grayscale value, and obtaining a feature image according to the screening grayscale value;

[0108] S331, setting the first screening gray value G0;

[0109] The first screening grayscale value can be set manually or randomly by a computer within a set range. However, it should be pointed out that the cleanliness of the body surface of each giant panda is different when the photos are obtained, and there are certain differences in the hair color of each giant panda. Therefore, manual setting is given priority when setting the screening grayscale value to improve the accuracy of parameter setting.

[0110] S332. Obtain the original image after noise reduction processing and divide it into several cells;

[0111] S333. Obtain the actual gray value G of each of the cells n , where n represents the cell number;

[0112] After dividing the original image into several cells, first number each cell. Preferably, the numbering is carried out in the order from left to right in daily life;

[0113] Subsequently, obtain the actual gray value G of each cell through the computer system n , where n represents the cell number;

[0114] S334. If G n ≥ G0, then eliminate this cell, otherwise retain it;

[0115] Extract the actual gray value G1, compare the actual gray value G1 with the first screening gray value G0. If G1≥G0 is satisfied, it indicates that the actual gray value G1 does not meet the requirements, and this cell is eliminated;

[0116] S335. Repeatedly compare the pixel values of each cell, and splice the retained cells according to the numbers of each cell to obtain a feature image.

[0117] Extract the actual gray value G2, and repeat the above comparison until all actual gray value comparisons are completed, and eliminate all cells that satisfy G n ≥ G0;

[0118] Subsequently, on the premise of retaining the original positions, splice the retained cells to obtain a feature image;

[0119] Secondly, it is also possible to use the image divided into multiple cells as a basis. When identifying the cells to be cleared, delete them from the image, while the cells to be retained are retained, so as to obtain the final feature image by continuously clearing the cells;

[0120] S34. Repeat the steps of obtaining the original image file set and selecting an original image from the original image file set until all feature images are obtained;

[0121] Repeating steps S31 - S33 can obtain all feature images;

[0122] S35. Divide each of the feature images to obtain the original image set of the eye sockets of the pandas to be identified and the original image set of the shoulder straps.

[0123] The panda's eye sockets generally include two completely separated black patches with a relatively large interval between them; the two patches have a certain symmetry and a relatively small area. Therefore, based on the above distinguishing features, the original eye socket images and the original scapula images can be quickly identified, and then the original eye socket image set and the original scapula image set of the panda to be identified can be obtained respectively.

[0124] S4. Process the original eye socket image by using the least squares ellipse fitting method to obtain the eye socket feature parameters of the giant panda to be identified;

[0125] S41. Obtain the original eye socket image set and randomly select an original eye socket image from it;

[0126] Obtain the original eye socket image set obtained in step S3 and randomly select an original eye socket image from it;

[0127] S42. Extract the original eye socket curve according to the gray value of the original eye socket image;

[0128] S421. Retrieve the first screening gray value G0;

[0129] S422. Divide the original eye socket image into several cells and respectively obtain the actual gray value G of each cell; n ; where n represents the cell number;

[0130] It should be noted that in this step, the coding parameters and cell division in step S333 can be directly called. Using the above method may result in discontinuous numbers;

[0131] It is also possible to re-divide the original eye socket image into several cells and finally number each cell separately. However, it should be noted that in order to improve the accuracy of the parameters, the number of cells can only be increased and not decreased.

[0132] S423. Extract all the cells with the actual gray value equal to the first screening gray value G0, and number each cell in clockwise or counterclockwise direction respectively to obtain the first cell set {A1, A2,..., A}; m ; where m represents the cell number;

[0133] Taking the center point of the giant panda's eye socket as the origin, the color change of its eye socket black patch has a certain regularity, that is, along the radial direction, in the direction pointing to the origin, the color component deepens; therefore, in the area within the eye socket contour line, its gray value will gradually decrease until it approaches 0; away from the origin, the gray value will gradually increase, and the boundary area is equal to the first screening gray value G0;

[0134] Based on the above principle, extract all cells with actual gray values equal to the first screening gray value G0. To ensure the orderliness of subsequent calculations and considering the characteristic that the panda eye socket is a closed circular structure, number each cell in a clockwise or counterclockwise direction respectively to obtain the first cell set {A1, A2,..., A m}; where m represents the cell number;

[0135] It should be noted that the above first cells can be connected in sequence to form a closed loop.

[0136] S424. Generate a first set of fitting curves according to the first cell set;

[0137] Obtain any cell Ai from the first cell set i . Decompose the first cell Ai into several pixel units, read the gray value of each pixel unit. Among the gray values of the above pixel units, some will be higher than the first screening gray value G0, some will be equal to the first screening gray value G0, and some will be lower than the first screening gray value G0. Select the pixel units equal to the first screening gray value G0, and mark each pixel unit P x in a certain order. Subsequently, connect the above pixel units P x with a smooth curve. This smooth curve is the first fitting curve L i ;

[0138] It should be noted that the above marking direction can be selected along the length direction of the cell to avoid confusion in the connected curve;

[0139] At the same time, for some messy points, they can also be deleted by manual exclusion;

[0140] Repeat the above steps to obtain the first fitting curves of all cells in the first cell set, and then obtain the first set of fitting curves {L1, L2,..., L m};

[0141] S426. Smoothly connect each of the first fitting curves L i in sequence according to the numbers of the fitting curves to obtain the original eye socket curve.

[0142] Retrieve the set of fitting curves {L1, L2,..., L m}. Since each cell A i is numbered in a clockwise or counterclockwise order, smoothly connect each of the fitting curves L i in sequence according to the number order to obtain the original eye socket curve;

[0143] Through the above method, the edge line of the panda's eye socket can be further refined in units of pixel cells in the edge region, thereby improving the accuracy of subsequent calculations.

[0144] S43. Use the least squares ellipse fitting method to fit the original eye socket curve to obtain the fitted eye socket curve;

[0145] Retrieve the original eye socket curve obtained in step S426, and fit the above curve by the least squares method to obtain the fitted eye socket curve;

[0146] S44. Calculate the eye socket feature parameters according to the fitted eye socket curve, and the eye socket feature parameters include the major axis, minor axis, center point coordinates, and rotation angle.

[0147] After obtaining the fitted eye socket curve by computer fitting, the eye socket feature parameters can be automatically calculated. Since the eye socket of the giant panda is an elliptical structure, the fitted eye socket curve obtained by fitting is an ellipse, and then the eye socket feature parameters are obtained, including the major axis, minor axis, and rotation angle;

[0148] Among them, the two eye sockets are distributed in a V-shaped structure, and the rotation angle can represent the included angle between the two eye sockets;

[0149] Repeat step S4 to obtain the eye socket feature parameters of all the original eye socket images;

[0150] S5. Obtain the scapular feature parameters of the giant panda to be recognized according to the original scapular image set.

[0151] S51. Obtain the original scapular image set, and randomly select an original scapular image from it;

[0152] S52. Calculate the scapular area S according to the gray value of the original scapular image 实 ;

[0153] S521. Retrieve the original scapular image and set the second screening gray value G0';

[0154] It should be noted that the second screening gray value G0' can be the same as or different from the first screening gray value G0, and the second screening gray value G0' can be set manually;

[0155] S522. Divide the original scapular image into several cells, and respectively obtain the actual gray value G of each cell n '; where n represents the cell number;

[0156] Divide the original scapular image obtained in step S51 into several cells, number each cell in a certain order, and obtain the actual gray value G of each cell by n'; where n represents the cell number;

[0157] S523. Extract all actual gray values G n 'The cells with gray value less than the second screening gray value G0' are used as the first cells, and the area of the first shoulder belt is calculated. The expression for the area of the first shoulder belt is S1 = j * s0, where j represents the number of the first cells and s0 represents the area of a cell;

[0158] Based on the second screening gray value G0', there are three cases for the actual gray values of each cell, namely greater than, equal to, and less than the second screening gray value G0'. Among them, the cells with gray value greater than the second screening gray value G0' need to be excluded, and the cells with gray value equal to the second screening gray value G0' belong to the boundary area, and the above areas need to further distinguish the boundary. The cells with gray value less than the second screening gray value G0' belong to the core area of the shoulder belt plate, and the above areas can all be used to calculate the area of the shoulder belt;

[0159] Therefore, extract all actual gray values G n 'The cells with gray value less than the second screening gray value G0' are used as the first cells. Since the area of each cell is the same, the expression for the area of the first shoulder belt is S1 = j * s0, where j represents the number of the first cells and s0 represents the area of a cell;

[0160] S524. Extract all actual gray values G n 'The cells with gray value equal to the second screening gray value G0' are used as the second cells, and the second cell set {A1', A2',..., A t '} is obtained; where t represents the cell number;

[0161] S525. Generate a fitting curve L i ' in each of the second cells A i ' according to the second screening gray value G0', and the second fitting curve set {L1', L2',..., L t '} is obtained;

[0162] Select any second cell A t ' from the second cell set {A1', A2',..., A i '}, decompose the second cell A i ' into several pixel units, read the gray value of each pixel unit. Among the gray values of the above pixel units, some will be higher than the second screening gray value G0', some will be equal to the second screening gray value G0', and some will be lower than the second screening gray value G0'. Select the pixel units equal to the second screening gray value G0', and mark each pixel unit P x ' in a certain order, and then connect the above pixel units P with a smooth curvex ', and this smooth curve is the second fitting curve L i ';

[0163] It should be noted that the above-mentioned marking direction can be the length direction of the cell to avoid confusion of the connected curves;

[0164] At the same time, some messy points can also be deleted by manual exclusion;

[0165] Repeating the above steps can obtain the fitting curves of all cells in the second cell set, and the second fitting curve set {L1', L2',..., L t '} can be obtained by tracing;

[0166] S526. Respectively divide each of the second cells A t ' by the second fitting curve set {L1', L2',..., L i '}, and fit and calculate the effective area s i ' of each of the second cells A i ';

[0167] First, retrieve the second fitting curve L1' from the second fitting curve set {L1', L2',..., L t '}, and then retrieve the corresponding second cell A1';

[0168] In the second cell A1', one side of the second fitting curve L1' is the area higher than the second screening gray value G0', and the other side is lower than the second screening gray value G0'. Take the area on the side lower than the second screening gray value G0' as the effective area region, and calculate the effective area s i ' of this region by fitting calculation;

[0169] Repeating the above steps can obtain the effective area s i ' of all the second cells A i ';

[0170] S527. Calculate the second shoulder area and the shoulder area, where the second shoulder area S2 = s1' + s2' +... + s i '+... + s t '; S 实 = S1 + S2.

[0171] The calculation formula for the second shoulder area is S2 = s1' + s2' +... + s i '+... + s t '. Extracting all the effective areas in step S526 can obtain the second shoulder area;

[0172] Subsequently, according to the formula S实 Calculate the area of the shoulder strap by S1 + S2.

[0173] S53. Extract the original shoulder strap curve according to the gray value of the original shoulder strap image;

[0174] It should be noted that the method of extracting the original shoulder strap curve through the gray value is exactly the same as the method of extracting the original orbital curve in step S42, that is, call the second fitting curve set {L1', L2',..., L t '} in step S525, and then smoothly connect each second fitting curve in turn to obtain the original shoulder strap curve;

[0175] S54. Judge the type of the shoulder strap according to the original shoulder strap curve, and generate corresponding size parameters;

[0176] S541. Obtain the original shoulder strap curve, and judge the number P of the closed areas enclosed by the original shoulder strap;

[0177] S542. If the number P ≥ 2, it is determined that the original shoulder strap is a broken belt, and generate the maximum width value, minimum width value and length value for each broken area respectively;

[0178] If the number P ≥ 2, it means that there are at least two separated areas in the shoulder strap of the giant panda, that is, there is a broken area in the shoulder strap. At this time, it is directly determined that the original shoulder strap is a broken belt;

[0179] Subsequently, generate the maximum width value, minimum width value and length value for each broken area according to the original shoulder strap curve respectively;

[0180] S543. If the number P = 1, generate the minimum circumscribed rectangle for the original shoulder strap curve, and calculate the area S of the minimum circumscribed rectangle 外 ;

[0181] If the number P = 1, it means that the original shoulder strap curve encloses a complete area. At this time, the minimum circumscribed rectangle of the original shoulder strap curve is extracted by computer fitting, and the area S of the minimum circumscribed rectangle is calculated 外 ;

[0182] Set the discrimination ratio Q0, and calculate the actual ratio Q 实 , if Q 实 ≥ Q0, it is determined that the original shoulder strap is a rectangular shoulder strap, and generate the shoulder strap width value and shoulder strap length value for the original shoulder strap curve; where the value of Q0 is 0.8 - 1, and the Q 实 = S 实 / S 外 ;

[0183] Set the discrimination ratio according to the actual situation, and the value of Q0 is 0.8 - 1; then according to the calculation formula Q实 =S 实 / S 外 Calculate the actual ratio Q 实 ;

[0184] Then compare the discrimination ratio Q0 and the actual ratio Q 实 , if Q 实 ≥Q0, it indicates that the original shoulder strap curve basically fills the minimum circumscribed rectangle. When Q 实 =1, it indicates that the original shoulder strap curve completely fills the minimum circumscribed rectangle; at this time, it is determined that the shoulder strap of the giant panda is a rectangular shoulder strap;

[0185] Subsequently, the shoulder strap width value and shoulder strap length value of the original shoulder strap curve are automatically generated by a computer.

[0186] If Q 实 <Q0, it is determined that the original shoulder strap is a U-shaped shoulder strap, and the minimum width value, the first width value, the second width value, and the length value are generated for the original shoulder strap.

[0187] If Q 实 <Q0, it indicates that there are a large number of unfilled areas in the minimum circumscribed rectangle. At this time, it is determined that the original shoulder strap is a U-shaped shoulder strap, and the minimum width value, the first width value, the second width value, and the length value are generated for the original shoulder strap.

[0188] Through the above steps, the present application can accurately distinguish the shapes of different shoulder straps, and at the same time accurately classify each shoulder strap through area, dimension parameters, etc., especially avoiding the misidentification caused by solely distinguishing by area, and improving the reliability and accuracy of feature extraction as much as possible.

[0189] S55. Output the shoulder strap area, shoulder strap type, and dimension parameters as shoulder strap feature parameters.

[0190] Furthermore, referring to Figure 9 , the present application also discloses an extraction system based on the above extraction method, including a data acquisition module and a data extraction module, wherein the data acquisition module is used to retrieve the original infrared image file set of the giant panda to be identified from the database, and can also be directly connected to the data interface of the infrared camera;

[0191] The data acquisition module is communicatively connected to the data extraction module, the output end of the data extraction module is connected to an image processing module, and the output end of the image processing module is connected in parallel with a first calculation module and the second calculation module. The first calculation module is used to receive the original image of the eye socket of the giant panda to be identified, and process the original image of the eye socket by using the least square ellipse fitting method to obtain the eye socket feature parameters of the giant panda to be identified;

[0192] The second calculation module receives the original scapular image set of the giant panda to be recognized, and obtains the scapular feature parameters of the giant panda to be recognized according to the original scapular image;

[0193] Compared with the prior art, first, the present application extracts the original image file from the infrared image file. The reason is that as a homeothermic animal, the infrared temperature image of the giant panda is relatively stable, and the ambient temperature around the panda is also relatively stable. Therefore, a stable temperature difference will be formed between the giant panda and the ambient temperature. Through the above temperature difference, the original image file can be accurately extracted from the infrared image, thereby reducing the influence of the environmental background on feature extraction and improving the accuracy of features and recognition;

[0194] Secondly, in the specific parameter extraction process of the present application, the present application not only extracts the orbital parameters of the panda, but also extracts the scapular patterns with obvious individual differences, so as to achieve the precise identification of the panda individual through the combination of orbital features and scapular features and improve the accuracy of panda recognition;

[0195] Finally, when extracting the feature parameters of the panda's orbit, the present application adopts the least square ellipse fitting method. Compared with the method of comparing the contours of the black patches in the panda's orbit in the prior art, the parameters obtained by the present application are more concise, the comparison efficiency is higher, and the ellipse parameters can more comprehensively reflect the overall situation of the panda's orbit, which is beneficial to improving the accuracy of recognition.

[0196] The above are only the preferred embodiments of the present application, and do not limit the patent scope of the present application. Any equivalent structure or equivalent process transformation made by using the content of the specification and drawings of the present application, or directly or indirectly applied in other related technical fields, shall be included in the patent protection scope of the present application by the same token.

Claims

1. A method for extracting individual identification features of giant pandas based on image processing, characterized in that Including the following steps: Obtain the original infrared image file set of the giant panda to be recognized; Extract the original image file set of the giant panda to be recognized from the original infrared image file set; Perform grayscale processing on the original image file set to respectively obtain the original orbital image set and the original scapular image set of the giant panda to be recognized; Process the original orbital image by using the least squares ellipse fitting method to obtain the orbital feature parameters of the giant panda to be recognized; wherein the orbital feature parameters include the major axis, the minor axis and the rotation angle; Obtain the scapular feature parameters of the giant panda to be recognized according to the original scapular image set, wherein the scapular feature parameters include the scapular area, the scapular type and the dimension parameters, and the scapular type includes the fracture zone, the rectangular scapula and the U-shaped scapula.

2. The method for extracting individual identification features of giant pandas based on image processing according to claim 1, wherein The step of extracting the original image file set of the giant panda to be recognized from the original infrared image file set includes the following steps: Set the recognition temperature threshold of the original infrared image file set; Obtain the original infrared image file set of the giant panda to be recognized, and extract any one original infrared image therefrom; Perform binaryzation processing on the original infrared image according to the recognition temperature threshold; Extract the thermal distribution characteristics of the binaryzation-processed original infrared image to obtain the original image of the giant panda to be recognized; Repeat the step of obtaining the original infrared image file set of the giant panda to be recognized and extracting any one original infrared image therefrom until the original image file set of the giant panda to be recognized is obtained.

3. The method for extracting individual identification features of giant pandas based on image processing according to claim 1, wherein The step of performing grayscale processing on the original image file set to respectively obtain the original orbital image set and the original scapular image set of the giant panda to be recognized includes the following steps: Obtain the original image file set, and select any one original image from the original image file set; Convert the original image into a grayscale image and perform noise reduction processing; Set the screening grayscale value, and obtain the feature image according to the screening grayscale value; Repeat the step of obtaining the original image file set and selecting any one original image from the original image file set until all feature images are obtained; Divide each of the feature images to obtain the original orbital image set and the original scapular image set of the giant panda to be recognized.

4. The method for extracting individual identification features of giant pandas based on image processing according to claim 3, characterized in that, The step of setting the screening grayscale value and obtaining the feature image according to the screening grayscale value includes the following steps: Set the screening grayscale value G0; Obtain the original image after noise reduction processing, and divide it into several cells; Obtain the actual gray value G of each of the cells respectively n , where n represents the cell number; If G n ≥ G0, then eliminate this cell, otherwise retain it; Repeat comparing the pixel values of each cell, and splice the remaining cells according to the numbers of each cell to obtain the feature image.

5. The method for extracting individual identification features of giant pandas based on image processing according to claim 1, characterized in that, The step of processing the original orbital image by using the least squares ellipse fitting method to obtain the orbital feature parameters of the giant panda to be recognized includes the following steps: Obtain the original orbital image set, and select any one original orbital image therefrom; Extract the original orbital curve according to the grayscale value of the original orbital image; Perform fitting on the original orbital curve by using the least squares ellipse fitting method to obtain the fitted orbital curve; Calculate the orbital feature parameters according to the fitted orbital curve, and the orbital feature parameters include the major axis, the minor axis and the rotation angle.

6. The method for extracting individual identification features of giant pandas based on image processing according to claim 5, wherein, The step of extracting the original orbital curve according to the grayscale value of the original orbital image includes the following steps: Retrieve the first screening grayscale value G0; Divide the original orbital image into a number of cells, and respectively obtain the actual gray value G of each of the cells n ; where n represents the cell number; Extract all cells whose actual gray value is equal to the first screening gray value G0, and number each cell in clockwise or counterclockwise order to obtain the first cell set {A1, A2,..., A m}; where m represents the cell number; Generate a first set of fitting curves based on the first cell set; In the cell A i a number of pixel units P are randomly selected in sequence x , and each of the pixel units P is smoothly connected in sequence through a fitting curve L i ; x ; Smoothly connect the fitting curves L in sequence according to the numbers of the fitting curves to obtain an original orbital curve. i ​ 7. The method for extracting individual identification features of giant pandas based on image processing according to claim 1, characterized in that The method for obtaining the shoulder strap characteristic parameters of the giant panda to be recognized according to the original shoulder strap image set includes the following steps: Obtain the original shoulder strap image set and randomly select an original shoulder strap image therefrom; Calculate the shoulder strap area S according to the gray value of the original shoulder strap image 实 ; Extract the original shoulder strap curve according to the gray value of the original shoulder strap image; Judge the shoulder strap type according to the original shoulder strap curve and generate corresponding size parameters; Output the shoulder strap area, shoulder strap type and size parameters as shoulder strap characteristic parameters.

8. The method for extracting individual identification features of giant pandas based on image processing according to claim 7, wherein Calculating the area S of the shoulder strap according to the gray value of the original image of the shoulder strap 实 , including the following steps, Retrieve the original shoulder strap image and set the second screening gray value G0'; Divide the original image of the shoulder strap into a number of cells, and respectively obtain the actual gray value G of each of the cells n '; Where n represents the cell number; Extract all actual gray values G n Cells that are '<less than the second screening gray value G0>' are used as the first cells, and the first shoulder area is calculated. The expression for the first shoulder area is S1 = j * s0, where j represents the number of the first cells and s0 represents the area of a cell; Extract all actual gray values G n The cell of 'equal to the second screening gray value G0' is used as the second cell, and the second cell set {A1', A2',..., A t}; where t represents the cell number; Obtain any second cell A i ', and randomly select several pixel units P i ' in sequence in the second cell A x ', and smoothly connect each of the pixel units P i ' in sequence through a fitting curve L x '; wherein the pixel unit P x ' is randomly generated in the region where the gray level is the second screening gray level value G0'. Through the fitting curve L i 'Divide the second cell A i ', and take the actual gray value G n 'The area where the actual gray value G is less than the second screening gray value G0' is used as the effective area, and the effective area s is calculated by fitting i '; Obtain the effective area s of all the second cells i ', calculate the second shoulder strap area and the shoulder strap area, where the second shoulder strap area S2 = s1' + s2' +... + s i '+... + s t '; S 实 = S1 + S2.

9. The method for extracting individual identification features of giant pandas based on image processing according to claim 7, characterized in that The method for judging the shoulder strap type according to the original shoulder strap curve and generating corresponding characteristic parameters includes the following steps: Obtain the original shoulder strap curve and judge the number P of closed regions enclosed by the original shoulder strap; If the number P≥2, it is determined that the original shoulder strap is a fracture zone, and the maximum width value, minimum width value and length value are generated for each fracture zone respectively; If the number P = 1, generate a minimum bounding rectangle for the original shoulder strap curve and calculate the area S of the minimum bounding rectangle 外 ; Set a discrimination ratio Q0 and calculate the actual ratio Q 实 , if Q 实 ≥Q0, it is determined that the original shoulder strap is a rectangular shoulder strap, and a shoulder strap width value and a shoulder strap length value are generated for the original shoulder strap; where the value of Q0 is 0.8 - 1, and the Q 实 =S 实 / S 外 ; If Q 实 < Q0, it is determined that the original shoulder strap is a U-shaped shoulder strap, and a minimum width value, a first width value, a second width value, and a length value are generated for the original shoulder strap.

10. A system based on the extraction method according to any one of claims 1-9, characterized in that, Including, A data acquisition module for acquiring the original infrared image file set of the giant panda to be recognized; A data extraction module for extracting the original image file set of the giant panda to be recognized from the original infrared image file set; An image processing module for performing gray processing on the original image file set to respectively obtain the original orbital image and the original shoulder strap image of the giant panda to be recognized; A first calculation module for processing the original orbital image by using the least square ellipse fitting method to obtain the orbital characteristic parameters of the giant panda to be recognized; A second calculation module for obtaining the shoulder strap characteristic parameters of the giant panda to be recognized according to the original shoulder strap image.

Citation Information

Patent Citations

  • Captive panda body temperature rapid measurement method

    CN111369560A

  • Panda house foreign matter identification system and method

    CN117152798A