Tibetan sheep individual and body size information identification method and device

By performing image analysis and point cloud processing on Tibetan sheep, the problems of low efficiency and poor safety of traditional measurement methods are solved, and accurate measurement and safe measurement of Tibetan sheep body ruler information are achieved.

CN119919472AActive Publication Date: 2025-05-02INTELLIGENT EQUIPMENT RESEARCH CENTER BEIJING ACADEMY OF AGRICULTURE AND FORESTRY SCIENCES
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN202411790085.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-06
Publication Date
2025-05-02
Estimated Expiration
2044-12-06

AI Technical Summary

Technical Problem

The traditional Tibetan sheep body ruler and weight measurement methods have problems such as inefficiency, subjective results, stress response to Tibetan sheep, and increased risk of disease transmission.

Method used

By performing hair shadow area analysis and local brightness analysis on the images of Tibetan sheep, combined with the PointNet network, the point cloud data is processed, and the carcass point cloud data is divided to calculate the body rule information.

Benefits of technology

Accurate measurement of Tibetan sheep body ruler information is achieved, measurement efficiency is improved, stress response to Tibetan sheep is reduced, and the risk of disease transmission is reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119919472A_ABST
    Figure CN119919472A_ABST
Patent Text Reader

Abstract

The invention provides a Tibetan sheep individual and body size information identification method and device, and relates to the technical field of data processing, and the method comprises the following steps: carrying out the hair shadow area analysis of a first image of a to-be-detected Tibetan sheep, and determining the first hair density of the to-be-detected Tibetan sheep; estimating a second hair density of the Tibetan sheep to be measured according to the brightness value of each pixel region in the first image; according to the first hair density and the second hair density, determining the hair thickness of the Tibetan sheep to be detected and the individual information of the Tibetan sheep to be detected; segmenting the overall point cloud data of the Tibetan sheep to be detected according to the hair thickness of the Tibetan sheep to be detected, and determining carcass point cloud data of the Tibetan sheep to be detected; and according to the carcass point cloud data of the to-be-detected Tibetan sheep, determining carcass body size information of the to-be-detected Tibetan sheep.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of data processing, and in particular to a method and a device for identifying individual Tibetan sheep and their body size information. Background Art

[0002] Traditional Tibetan sheep breeding and management methods have many problems, such as low breeding efficiency and inaccurate body condition evaluation. They are difficult to meet the comprehensive monitoring and evaluation needs of Tibetan sheep in large-scale farms and are easily affected by subjective factors.

[0003] In the related art, the measurement of body size and weight of Tibetan sheep mainly relies on manual measurement, which has the following problems: due to the large size and strong wildness of Tibetan sheep, measuring weight and body size requires the cooperation of multiple adults, which consumes time and energy, has low measurement efficiency and subjective results; during the measurement process, long-term direct contact with humans can easily induce stress response in Tibetan sheep, affecting their growth and development, and in severe cases may even lead to serious illness or even death; contact measurement increases the risk of disease and parasite transmission between humans and animals.

[0004] Therefore, how to measure the body size of Tibetan sheep more effectively has become an urgent problem to be solved in the industry. Summary of the invention

[0005] The invention provides a method and a device for identifying individual Tibetan sheep and body size information, so as to solve the problem of how to more effectively measure the body size of Tibetan sheep in the prior art.

[0006] The present invention provides a method for identifying Tibetan sheep individuals and body size information, comprising the following steps: Performing hair shadow area analysis on the first image of the Tibetan sheep to be tested to determine a first hair density of the Tibetan sheep to be tested; estimating a second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; Determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; According to the hair thickness of the Tibetan sheep to be tested, the overall point cloud data of the Tibetan sheep to be tested is segmented to determine the carcass point cloud data of the Tibetan sheep to be tested; According to the carcass point cloud data of the Tibetan sheep to be tested, the body size information of the carcass of the Tibetan sheep to be tested is determined.

[0007] According to a method for identifying individual Tibetan sheep and body size information provided by the present invention, the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested are determined according to the first hair density and the second hair density, including: Determine the third hair density information of the Tibetan sheep to be tested according to the product of the first hair density and the first preset weight coefficient and the sum of the product of the second hair density and the second preset weight coefficient; Determining the hair thickness of the Tibetan sheep to be tested according to the hair-bearing body size information of the Tibetan sheep to be tested and the third hair density information; The individual information of the Tibetan sheep to be tested is determined according to the body size information with hair and the hair thickness of the Tibetan sheep to be tested.

[0008] According to a method for identifying individual Tibetan sheep and body size information provided by the present invention, the hair shadow area analysis of a first image of the Tibetan sheep to be tested is performed to determine a first hair density of the Tibetan sheep to be tested, including: After performing image language preprocessing on the first image, an edge detection algorithm is used to identify a Tibetan sheep image region in the first image; Determine the Tibetan sheep wool shadow area in the Tibetan sheep image area according to the gray value change information of each pixel point in the Tibetan sheep image area; The first hair density of the Tibetan sheep to be tested is determined according to the ratio between the area of ​​each Tibetan sheep hair shadow area and the area of ​​the Tibetan sheep image area.

[0009] According to a method for identifying individual Tibetan sheep and body size information provided by the present invention, estimating the second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image includes: Analyze the first image by a local brightness analysis method to determine the brightness value of each pixel area in the first image; The pixel area whose brightness value is greater than a first preset threshold is regarded as a high-density hair area, and the pixel area whose brightness value is lower than a second preset threshold is regarded as a low-density hair area; The second hair density of the Tibetan sheep to be tested is determined according to the ratio of the brightness value of the low-density hair area to the brightness value of the high-density hair area.

[0010] According to a method for identifying individual Tibetan sheep and body size information provided by the present invention, the body size information of the carcass of the Tibetan sheep to be tested is determined according to the carcass point cloud data of the Tibetan sheep to be tested, comprising: Input the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network, and output the key points of the Tibetan sheep carcass to be tested; the key points include at least one of the following: head key points, chest key points and limb key points; Based on the Euclidean distance between the key points of the Tibetan sheep carcass to be tested, the body size information of the Tibetan sheep carcass to be tested is calculated.

[0011] According to a method for identifying Tibetan sheep individuals and body size information provided by the present invention, before the step of inputting the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network and outputting the key point information of the carcass of the Tibetan sheep to be tested, the method further includes: Obtain multiple point cloud sample information with key point labels; Sending each of the point cloud sample information to a preset PointNet network, and outputting the predicted key points corresponding to the point cloud sample information; Based on the predicted key points and the key point labels, a loss value is calculated, and when the loss value is lower than a third preset threshold, training is stopped to obtain a PointNet network.

[0012] The present invention also provides a device for identifying individual Tibetan sheep and body size information, comprising the following modules: An analysis module is used to perform hair shadow area analysis on the first image of the Tibetan sheep to be tested, and determine a first hair density of the Tibetan sheep to be tested; An estimation module, used for estimating the second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; A determination module, used to determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; A segmentation module is used to segment the overall point cloud data of the Tibetan sheep to be tested according to the hair thickness of the Tibetan sheep to be tested, and determine the carcass point cloud data of the Tibetan sheep to be tested; The identification module is used to determine the carcass size information of the Tibetan sheep to be tested based on the carcass point cloud data of the Tibetan sheep to be tested.

[0013] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Determine the third hair density information of the Tibetan sheep to be tested according to the product of the first hair density and the first preset weight coefficient and the sum of the product of the second hair density and the second preset weight coefficient; Determining the hair thickness of the Tibetan sheep to be tested according to the hair-bearing body size information of the Tibetan sheep to be tested and the third hair density information; The individual information of the Tibetan sheep to be tested is determined according to the body size information with hair and the hair thickness of the Tibetan sheep to be tested.

[0014] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: After performing image language preprocessing on the first image, an edge detection algorithm is used to identify a Tibetan sheep image region in the first image; Determine the Tibetan sheep wool shadow area in the Tibetan sheep image area according to the gray value change information of each pixel point in the Tibetan sheep image area; The first hair density of the Tibetan sheep to be tested is determined according to the ratio between the area of ​​each Tibetan sheep hair shadow area and the area of ​​the Tibetan sheep image area.

[0015] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Analyze the first image by a local brightness analysis method to determine the brightness value of each pixel area in the first image; The pixel area whose brightness value is greater than a first preset threshold is regarded as a high-density hair area, and the pixel area whose brightness value is lower than a second preset threshold is regarded as a low-density hair area; The second hair density of the Tibetan sheep to be tested is determined according to the ratio of the brightness value of the low-density hair area to the brightness value of the high-density hair area.

[0016] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Input the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network, and output the key points of the Tibetan sheep carcass to be tested; the key points include at least one of the following: head key points, chest key points and limb key points; Based on the Euclidean distance between the key points of the Tibetan sheep carcass to be tested, the body size information of the Tibetan sheep carcass to be tested is calculated.

[0017] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Obtain multiple point cloud sample information with key point labels; Sending each of the point cloud sample information to a preset PointNet network, and outputting the predicted key points corresponding to the point cloud sample information; Based on the predicted key points and the key point labels, a loss value is calculated, and when the loss value is lower than a third preset threshold, training is stopped to obtain a PointNet network.

[0018] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, any of the above-mentioned methods for identifying individual Tibetan sheep and body size information is implemented.

[0019] The present invention also provides a non-transitory computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the method for identifying individual Tibetan sheep and body size information as described in any one of the above is implemented.

[0020] The present invention also provides a computer program product, including a computer program, wherein when the computer program is executed by a processor, the method for identifying individual Tibetan sheep and body size information as described above is implemented.

[0021] The method and device for identifying individual Tibetan sheep and body size information provided by the present invention can estimate the hair density by statistically analyzing the area and depth information of the shadow area, and determine the first hair density, because the area with higher hair density usually blocks more light and forms a darker shadow; through the analysis of the shadow area, the light intensity of each area can be calculated, so as to infer that the area with weaker light may be a place with dense hair, and determine the second hair density; in combination with the first hair density and the second hair density, the hair thickness and individual information of the Tibetan sheep can be determined, and according to the hair thickness of the Tibetan sheep to be measured, the point cloud of the carcass without hair is obtained by subtracting the point cloud of the hair area, so as to accurately calculate the volume of the Tibetan sheep, and on this basis, the weight of the Tibetan sheep is inferred, and the measurement of the body size information of the carcass of the Tibetan sheep to be measured is completed, and the accuracy and safety of the measurement are effectively guaranteed. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0023] Figure 1 It is a flow chart of the method for identifying Tibetan sheep individuals and body size information provided by the present invention.

[0024] Figure 2 This is a schematic diagram of the structure of the device for identifying Tibetan sheep individuals and body size information provided by the present invention.

[0025] Figure 3 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0026] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings 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.

[0027] Figure 1 FIG. 1 is a flow chart of a method for identifying Tibetan sheep individuals and body size information provided by the present invention. Figure 1 As shown, the method includes the following: Step 110, performing hair shadow area analysis on the first image of the Tibetan sheep to be tested to determine a first hair density of the Tibetan sheep to be tested; In the present invention, first, the image is denoised to remove background noise and other irrelevant interference. This can be achieved by Gaussian blur or median filtering to smooth the image and reduce noise.

[0028] By analyzing the grayscale value changes of the image, the possible shadow areas are detected. The shadow areas are usually caused by the obstruction of hair or uneven reflection, and the shadow areas can be extracted by threshold segmentation.

[0029] Analyze the distribution of the detected shadow area. If the shadow is darker and more concentrated, it may mean that the hair in this area is dense. The density of the hair can be estimated by counting the area, depth and other information of the shadow area.

[0030] Using the shadow analysis method, it can be done through the following steps: image preprocessing, edge detection, shadow detection and shadow area analysis. These steps help determine areas with higher hair density, which usually block more light and form darker shadows.

[0031] Finally, the primary hair density of Tibetan sheep is determined through hair shadow area analysis.

[0032] Step 120, estimating a second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; In the present invention, first, it is necessary to perform brightness analysis on the first image of the Tibetan sheep to be tested. This can be achieved by calculating the brightness value of each pixel area in the image. The brightness value reflects the reflection of light by the hair. The area with higher hair density usually has lower brightness because more light is absorbed by the hair.

[0033] Use local brightness analysis methods, such as local weighted average or filtering, to calculate the light intensity of each area. These intensity values ​​can help infer which areas may be densely covered with hair, because densely covered areas usually have lower brightness values.

[0034] The comprehensive analysis of the brightness values ​​of each pixel area in the image is carried out, and the relationship between these brightness values ​​and hair density is modeled and calculated to predict the second hair density of Tibetan sheep.

[0035] Step 130, determining the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; In the present invention, the determination of individual information may include characteristics of the Tibetan sheep such as breed, age, gender, etc. This information can be inferred by analyzing specific characteristics of the hair, such as hair color, texture, and distribution pattern. For example, different breeds of Tibetan sheep may have different hair characteristics, which can be identified by image analysis technology.

[0036] In the present invention, a relationship model can be established to determine the hair thickness based on the first hair density (obtained through shadow area analysis) and the second hair density (obtained through brightness value analysis).

[0037] Step 140, segmenting the overall point cloud data of the Tibetan sheep to be tested according to the hair thickness of the Tibetan sheep to be tested, and determining the carcass point cloud data of the Tibetan sheep to be tested; In the present invention, in order to accurately calculate the carcass point cloud, the hair area must be separated from the point cloud data. Usually, three-dimensional reconstruction technology is used to generate point cloud data without hair in combination with the hair thickness of the Tibetan sheep to be tested; this process is completed by distance-based point cloud segmentation technology, mainly by subtracting the hair thickness from the normal vector position of the Tibetan sheep with hair, and then the carcass point cloud can be identified, and the carcass point cloud data of the Tibetan sheep to be tested can be obtained.

[0038] Step 150: determining the body size information of the carcass of the Tibetan sheep to be tested according to the carcass point cloud data of the Tibetan sheep to be tested.

[0039] Optionally, the carcass point cloud data of the Tibetan sheep to be tested is input into the PointNet network, and the key points of the Tibetan sheep carcass to be tested are output; the key points include at least one of the following: head key points, chest key points and limb key points; Based on the Euclidean distance between the key points of the Tibetan sheep carcass to be tested, the body size information of the Tibetan sheep carcass to be tested is calculated.

[0040] In the present invention, the carcass point cloud data of the Tibetan sheep to be tested is input into the PointNet network. PointNet is a deep learning network that can directly process point cloud data, extract global features from disordered point clouds, and output key point information.

[0041] The PointNet network outputs the key points of the Tibetan sheep carcass, including the head key points, chest key points and limb key points. These key points are obtained by feature extraction and learning of point cloud data, and can represent the main characteristic parts of the Tibetan sheep carcass.

[0042] Based on the above key points, calculate the Euclidean distance between them. Euclidean distance is the most commonly used distance measurement method, which calculates the straight-line distance between two points.

[0043] The Euclidean distance between key points is used to calculate the carcass size information of the Tibetan sheep to be tested, such as body length, body height, body width, etc. For example, the body length can be estimated by calculating the distance between the key points of the head and the key points of the chest; the body width and body height can be estimated by the distance between the key points of the limbs, and finally the carcass size information of the Tibetan sheep to be tested can be obtained.

[0044] More specifically, the volume of the Tibetan sheep to be measured can be calculated by voxelizing the point cloud or applying a volume estimation formula. The weight is estimated using the volume and density of the sheep (assuming the density of the sheep is known). The commonly used formula is: in, is the volume of Tibetan sheep to be measured, is the preset Tibetan sheep density.

[0045] In the present invention, the hair density can be estimated by analyzing the shadow area by counting the area and depth information of the shadow area. This is because areas with higher hair density usually block more light and form deeper shadows, thereby determining the first hair density. The illumination intensity of each area can be calculated by a local brightness analysis method, such as local weighted average or filtering, thereby inferring that areas with weaker illumination may be places with dense hair, thereby determining the second hair density. Combining the first hair density and the second hair density, the hair thickness and individual information of the Tibetan sheep can be determined. According to the hair thickness of the Tibetan sheep to be measured, the point cloud of the carcass without hair is obtained by subtracting the point cloud of the hair area, thereby accurately calculating the volume of the Tibetan sheep, and on this basis, calculating its weight, completing the measurement of the carcass size information of the Tibetan sheep to be measured, and effectively ensuring the accuracy and safety of the measurement.

[0046] Optionally, determining the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density includes: Determine the third hair density information of the Tibetan sheep to be tested according to the product of the first hair density and the first preset weight coefficient and the sum of the product of the second hair density and the second preset weight coefficient; Determining the hair thickness of the Tibetan sheep to be tested according to the hair-bearing body size information of the Tibetan sheep to be tested and the third hair density information; The individual information of the Tibetan sheep to be tested is determined according to the body size information with hair and the hair thickness of the Tibetan sheep to be tested.

[0047] In the present invention, the third hair density information of the Tibetan sheep to be tested is determined according to the product of the first hair density and the first preset weight coefficient and the sum of the product of the second hair density and the second preset weight coefficient.

[0048] Specifically, the joint analysis formula of the third hair density information is: ; in, and are respectively a first preset weight coefficient and a second preset weight coefficient, is the first hair density, The second hair density.

[0049] More specifically, in the embodiments of the present application, in order to improve the accuracy of hair density estimation, the illumination change and shadow analysis can be combined. By considering both the intensity of illumination and the depth of shadows, the distribution and density of hair can be more comprehensively inferred. Through the analysis of illumination and shadows, the distribution of hair can be estimated in the image. Shadow areas usually represent areas where hair is denser, while areas with stronger illumination may represent areas where hair is sparser. Combining this information, the density of hair can be effectively inferred, and valuable data can be provided for subsequent body shape and weight estimation.

[0050] Relationship between hair thickness and body shape: in, is the hair thickness, is the body size information of the Tibetan sheep to be tested with hair. Used to calculate the relationship between hair thickness and body shape.

[0051] In the present invention, hair thickness is an important factor in determining individual information of Tibetan sheep. Physical properties of hair, such as thickness, color, and texture, are related to individual information of Tibetan sheep, such as breed, age, and gender. For example, different breeds of Tibetan sheep may have different hair characteristics, which can be identified by analyzing the physical properties of hair.

[0052] Combining the body size information with hair and the thickness of hair can more accurately determine the individual information of Tibetan sheep. For example, by analyzing the thickness and growth cycle of hair, the age and breed of Tibetan sheep can be inferred.

[0053] In the present invention, the hair thickness and individual information of the Tibetan sheep to be tested can be effectively determined by combining the measurement of hair density and body size information, providing a scientific basis for the breeding, health monitoring and management of Tibetan sheep.

[0054] Optionally, performing hair shadow area analysis on the first image of the Tibetan sheep to be tested to determine the first hair density of the Tibetan sheep to be tested includes: After performing image language preprocessing on the first image, an edge detection algorithm is used to identify a Tibetan sheep image region in the first image; Determine the Tibetan sheep wool shadow area in the Tibetan sheep image area according to the gray value change information of each pixel point in the Tibetan sheep image area; The first hair density of the Tibetan sheep to be tested is determined according to the ratio between the area of ​​each Tibetan sheep hair shadow area and the area of ​​the Tibetan sheep image area.

[0055] In the present invention, first, the first image of the Tibetan sheep to be tested is subjected to image preprocessing to enhance the contrast of the image so that the distinction between the hair and non-hair areas is more obvious. This can be achieved by methods such as histogram equalization, the purpose of which is to improve the distinction between hair and background in the image.

[0056] Edge detection algorithms, such as Sobel operator, Robert operator or Canny operator, are used to identify the edges in the Tibetan sheep image area. These algorithms can highlight the boundaries of the hair in the image and provide a basis for the subsequent identification of the hair shadow area.

[0057] By analyzing the gray value change information of each pixel in the Tibetan sheep image area, the hair shadow area is determined. The shadow area is usually manifested as an area with a higher gray value, which can be achieved through the threshold segmentation method, identifying the area with a gray value higher than a certain threshold as a shadow area.

[0058] Calculate the area of ​​each hair shadow region. This can be done by image segmentation and region marking, marking all shadow regions and calculating their total area.

[0059] The first hair density of the Tibetan sheep to be tested is determined based on the ratio between the area of ​​the hair shadow area and the area of ​​the Tibetan sheep image area. This ratio can reflect the density of the hair. The larger the area ratio, the higher the hair density. Finally, the number of hair roots is divided by the area of ​​the hair region to be tested to calculate the first hair density of the Tibetan sheep to be tested.

[0060] In the present invention, the area with high hair density usually blocks the light, resulting in insufficient illumination in the local area, thereby forming a shadow. The shadow area usually has a darker grayscale value in the image, so by detecting the shadow in the image, the area with denser hair can be inferred, thereby effectively realizing the measurement of the first hair density of the Tibetan sheep to be tested.

[0061] Optionally, estimating the second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image includes: Analyze the first image by a local brightness analysis method to determine the brightness value of each pixel area in the first image; The pixel area whose brightness value is greater than a first preset threshold is regarded as a high-density hair area, and the pixel area whose brightness value is lower than a second preset threshold is regarded as a low-density hair area; The second hair density of the Tibetan sheep to be tested is determined according to the ratio of the brightness value of the low-density hair area to the brightness value of the high-density hair area.

[0062] In the present invention, hair with a higher density may result in a lower reflectivity, and thus a lower brightness value of the image; while hair with a lower density may reflect more light and have a higher brightness, so the first image may be analyzed by a local brightness analysis method to determine the brightness value of each pixel region in the first image. This method may involve local weighted averaging or filtering to calculate the light intensity of each region.

[0063] Pixel areas with brightness values ​​greater than the first preset threshold are identified as high-density hair areas, which usually have high hair density because they reflect less light, resulting in lower brightness values. Correspondingly, pixel areas with brightness values ​​lower than the second preset threshold are identified as low-density hair areas, which have low hair density because they reflect more light and have higher brightness values.

[0064] The second hair density of the Tibetan sheep to be tested is determined based on the ratio of the brightness value of the low-density hair area to the brightness value of the high-density hair area. This ratio can reflect the density of the hair and provide a quantitative hair density estimate. Specifically, if the brightness value of the high-density hair area is low and the brightness value of the low-density hair area is high, this ratio will be used to determine the second hair density of the Tibetan sheep to be tested.

[0065] In the present invention, the local brightness analysis method and the threshold segmentation technology are combined to effectively estimate the second hair density of the Tibetan sheep to be tested, providing accurate data support for further analysis and evaluation.

[0066] Optionally, before the step of inputting the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network and outputting the key point information of the Tibetan sheep carcass to be tested, the method further comprises: Obtain multiple point cloud sample information with key point labels; Sending each of the point cloud sample information to a preset PointNet network, and outputting the predicted key points corresponding to the point cloud sample information; Based on the predicted key points and the key point labels, a loss value is calculated, and when the loss value is lower than a third preset threshold, training is stopped to obtain a PointNet network.

[0067] In the present invention, the point cloud data of the Tibetan sheep to be tested is obtained by laser scanning, depth camera, etc. These devices can capture the three-dimensional coordinate information of the surface of the Tibetan sheep to form a point cloud data set. In the acquired point cloud data, the key point positions need to be marked, such as the head, chest, limbs, etc. These key points will be used as labels in the training data for subsequent model training and key point detection, and multiple point cloud sample information carrying key point labels will be obtained.

[0068] In the present invention, the PointNet model can directly process the point cloud, learn the corresponding spatial encoding for each point in the input point cloud, and then use the features of all points to obtain a global point cloud feature. This global feature can be used for classification tasks and can also be used for key point detection.

[0069] Using PointNet for training, the network architecture inputs unordered point cloud data, and extracts global and local features of the point cloud through multi-layer perceptron (MLP) and maximum pooling operations. PointNet uses the maximum pooling operation to capture the global features of unordered point sets, ensuring that the order of the input point cloud does not affect the output: ; in, It refers to the feature extraction of each point, and the pooling operation generates a global feature representation. During the training process, the mean square error loss function is used to regress the position of the key points: ; in, K is the number of key points, and They are the predicted key point positions and the true label positions. After training, the model can predict key points for new point cloud data and output the key positions of objects. Based on these predicted key points, the length, height, width and other dimensions of the Tibetan sheep can be calculated.

[0070] The advantage of PointNet is that it can directly process unordered point cloud data without converting the data into a grid or voxel format, and can effectively extract the geometric features of the object, so it has high efficiency and robustness in body measurement and key point detection. This method is widely used in animal body measurement tasks.

[0071] The following is a description of the device for identifying individual Tibetan sheep and body size information provided by the present invention. The device for identifying individual Tibetan sheep and body size information described below and the method for identifying individual Tibetan sheep and body size information described above can be referred to each other.

[0072] Figure 2 The schematic diagram of the structure of the device for identifying the individual and body size information of Tibetan sheep provided by the present invention is as follows: Figure 2As shown, including: The analysis module 210 is used to perform hair shadow area analysis on the first image of the Tibetan sheep to be tested, and determine the first hair density of the Tibetan sheep to be tested; The estimation module 220 is used to estimate the second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; The determination module 230 is used to determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; The segmentation module 240 is used to segment the overall point cloud data of the Tibetan sheep to be tested according to the hair thickness of the Tibetan sheep to be tested, and determine the carcass point cloud data of the Tibetan sheep to be tested; The identification module 250 is used to determine the carcass size information of the Tibetan sheep to be tested based on the carcass point cloud data of the Tibetan sheep to be tested.

[0073] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Determine the third hair density information of the Tibetan sheep to be tested according to the product of the first hair density and the first preset weight coefficient and the sum of the product of the second hair density and the second preset weight coefficient; Determining the hair thickness of the Tibetan sheep to be tested according to the hair-bearing body size information of the Tibetan sheep to be tested and the third hair density information; The individual information of the Tibetan sheep to be tested is determined according to the body size information with hair and the hair thickness of the Tibetan sheep to be tested.

[0074] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: After performing image language preprocessing on the first image, an edge detection algorithm is used to identify a Tibetan sheep image region in the first image; Determine the Tibetan sheep wool shadow area in the Tibetan sheep image area according to the gray value change information of each pixel point in the Tibetan sheep image area; The first hair density of the Tibetan sheep to be tested is determined according to the ratio between the area of ​​each Tibetan sheep hair shadow area and the area of ​​the Tibetan sheep image area.

[0075] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Analyze the first image by a local brightness analysis method to determine the brightness value of each pixel area in the first image; The pixel area whose brightness value is greater than a first preset threshold is regarded as a high-density hair area, and the pixel area whose brightness value is lower than a second preset threshold is regarded as a low-density hair area; The second hair density of the Tibetan sheep to be tested is determined according to the ratio of the brightness value of the low-density hair area to the brightness value of the high-density hair area.

[0076] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Input the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network, and output the key points of the Tibetan sheep carcass to be tested; the key points include at least one of the following: head key points, chest key points and limb key points; Based on the Euclidean distance between the key points of the Tibetan sheep carcass to be tested, the body size information of the Tibetan sheep carcass to be tested is calculated.

[0077] According to the device for identifying Tibetan sheep individuals and body size information provided by the present invention, the device is also used for: Obtain multiple point cloud sample information with key point labels; Sending each of the point cloud sample information to a preset PointNet network, and outputting the predicted key points corresponding to the point cloud sample information; Based on the predicted key points and the key point labels, a loss value is calculated, and when the loss value is lower than a third preset threshold, training is stopped to obtain a PointNet network.

[0078] In the present invention, because the area with higher hair density usually blocks more light and forms a darker shadow, the hair density can be estimated by analyzing the shadow area by counting the area and depth information of the shadow area, and the first hair density is determined; the illumination intensity of each area can be calculated by a local brightness analysis method, such as local weighted average or filtering, so as to infer that the area with weaker illumination may be a place with dense hair, and the second hair density is determined; the hair thickness and individual information of the Tibetan sheep can be determined by combining the first hair density and the second hair density, and the carcass point cloud without hair is obtained by subtracting the point cloud of the hair area according to the hair thickness of the Tibetan sheep to be measured, so as to accurately calculate the volume of the Tibetan sheep, and on this basis, infer its weight, and complete the measurement of the carcass size information of the Tibetan sheep to be measured, thereby effectively ensuring the accuracy and safety of the measurement.

[0079] Figure 3 is a schematic diagram of the structure of the electronic device provided by the present invention, such as Figure 3As shown, the electronic device may include: a processor 310, a communications interface 320, a memory 330 and a communication bus 340, wherein the processor 310, the communications interface 320 and the memory 330 communicate with each other through the communication bus 340. The processor 310 may call the logic instructions in the memory 330 to execute the method for identifying individual Tibetan sheep and body size information, the method comprising: performing hair shadow area analysis on a first image of a Tibetan sheep to be detected, and determining a first hair density of the Tibetan sheep to be detected; estimating a second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; Determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; According to the hair thickness of the Tibetan sheep to be tested, the overall point cloud data of the Tibetan sheep to be tested is segmented to determine the carcass point cloud data of the Tibetan sheep to be tested; According to the carcass point cloud data of the Tibetan sheep to be tested, the body size information of the carcass of the Tibetan sheep to be tested is determined.

[0080] In addition, the logic instructions in the above-mentioned memory 330 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.

[0081] On the other hand, the present invention further provides a computer program product, the computer program product includes a computer program, the computer program can be stored in a non-transitory computer-readable storage medium, when the computer program is executed by a processor, the computer can execute the Tibetan sheep individual and body size information identification method provided by the above methods, the method includes: performing hair shadow area analysis on a first image of a Tibetan sheep to be tested, and determining a first hair density of the Tibetan sheep to be tested; estimating a second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; Determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; According to the hair thickness of the Tibetan sheep to be tested, the overall point cloud data of the Tibetan sheep to be tested is segmented to determine the carcass point cloud data of the Tibetan sheep to be tested; According to the carcass point cloud data of the Tibetan sheep to be tested, the body size information of the carcass of the Tibetan sheep to be tested is determined.

[0082] In another aspect, the present invention further provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to perform the method for identifying individual Tibetan sheep and body size information provided by the above methods, the method comprising: performing hair shadow area analysis on a first image of a Tibetan sheep to be tested, and determining a first hair density of the Tibetan sheep to be tested; estimating a second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; Determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; According to the hair thickness of the Tibetan sheep to be tested, the overall point cloud data of the Tibetan sheep to be tested is segmented to determine the carcass point cloud data of the Tibetan sheep to be tested; According to the carcass point cloud data of the Tibetan sheep to be tested, the body size information of the carcass of the Tibetan sheep to be tested is determined.

[0083] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0084] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0085] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for identifying Tibetan sheep individuals and body size information, characterized in that: include: Performing hair shadow area analysis on the first image of the Tibetan sheep to be tested to determine a first hair density of the Tibetan sheep to be tested; estimating a second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; Determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; According to the hair thickness of the Tibetan sheep to be tested, the overall point cloud data of the Tibetan sheep to be tested is segmented to determine the carcass point cloud data of the Tibetan sheep to be tested; According to the carcass point cloud data of the Tibetan sheep to be tested, the body size information of the carcass of the Tibetan sheep to be tested is determined.

2. The method for identifying Tibetan sheep individuals and body size information according to claim 1, characterized in that: Determining the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density includes: Determine the third hair density information of the Tibetan sheep to be tested according to the product of the first hair density and the first preset weight coefficient and the sum of the product of the second hair density and the second preset weight coefficient; Determining the hair thickness of the Tibetan sheep to be tested according to the hair-bearing body size information of the Tibetan sheep to be tested and the third hair density information; The individual information of the Tibetan sheep to be tested is determined according to the body size information with hair and the hair thickness of the Tibetan sheep to be tested.

3. The method for identifying Tibetan sheep individuals and body size information according to claim 1, characterized in that: The method of performing hair shadow area analysis on the first image of the Tibetan sheep to be tested to determine the first hair density of the Tibetan sheep to be tested includes: After performing image language preprocessing on the first image, an edge detection algorithm is used to identify a Tibetan sheep image region in the first image; Determine the Tibetan sheep wool shadow area in the Tibetan sheep image area according to the gray value change information of each pixel point in the Tibetan sheep image area; The first hair density of the Tibetan sheep to be tested is determined according to the ratio between the area of ​​each Tibetan sheep hair shadow area and the area of ​​the Tibetan sheep image area.

4. The method for identifying Tibetan sheep individuals and body size information according to claim 1, characterized in that: The estimating the second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image includes: Analyze the first image by a local brightness analysis method to determine the brightness value of each pixel area in the first image; The pixel area whose brightness value is greater than a first preset threshold is regarded as a high-density hair area, and the pixel area whose brightness value is lower than a second preset threshold is regarded as a low-density hair area; The second hair density of the Tibetan sheep to be tested is determined according to the ratio of the brightness value of the low-density hair area to the brightness value of the high-density hair area.

5. The method for identifying Tibetan sheep individuals and body size information according to claim 1, characterized in that: Determining the carcass size information of the Tibetan sheep to be tested according to the carcass point cloud data of the Tibetan sheep to be tested, including: Input the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network, and output the key points of the Tibetan sheep carcass to be tested; the key points include at least one of the following: head key points, chest key points and limb key points; Based on the Euclidean distance between the key points of the Tibetan sheep carcass to be tested, the body size information of the Tibetan sheep carcass to be tested is calculated.

6. The method for identifying Tibetan sheep individuals and body size information according to claim 5, characterized in that: Before the step of inputting the carcass point cloud data of the Tibetan sheep to be tested into the PointNet network and outputting the key point information of the carcass of the Tibetan sheep to be tested, the method further comprises: Obtain multiple point cloud sample information with key point labels; Sending each of the point cloud sample information to a preset PointNet network, and outputting the predicted key points corresponding to the point cloud sample information; Based on the predicted key points and the key point labels, a loss value is calculated, and when the loss value is lower than a third preset threshold, training is stopped to obtain a PointNet network.

7. A device for identifying individual Tibetan sheep and their body size information, characterized in that: include: An analysis module is used to perform hair shadow area analysis on the first image of the Tibetan sheep to be tested, and determine a first hair density of the Tibetan sheep to be tested; An estimation module, used for estimating the second hair density of the Tibetan sheep to be tested according to the brightness value of each pixel area in the first image; A determination module, used to determine the hair thickness of the Tibetan sheep to be tested and the individual information of the Tibetan sheep to be tested according to the first hair density and the second hair density; A segmentation module is used to segment the overall point cloud data of the Tibetan sheep to be tested according to the hair thickness of the Tibetan sheep to be tested, and determine the carcass point cloud data of the Tibetan sheep to be tested; The identification module is used to determine the carcass size information of the Tibetan sheep to be tested based on the carcass point cloud data of the Tibetan sheep to be tested.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the computer program, the method for identifying Tibetan sheep individuals and body size information as described in any one of claims 1 to 6 is implemented.

9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for identifying Tibetan sheep individuals and body size information as described in any one of claims 1 to 6 is implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method for identifying Tibetan sheep individuals and body size information as described in any one of claims 1 to 6 is implemented.

Citation Information

Patent Citations

  • Point cloud quality evaluation method and device

    CN107767375A

  • Pig weight estimation method and device based on depth image

    CN114170292A

  • Blocking method and system based on livestock carcass point cloud image

    CN114330490A

  • Sheep body size measuring method and device based on 3D point cloud

    CN118657824A

  • Tibetan sheep carcass yield grading method based on computer technology

    CN118735850A