WO2021083381A1 - Animal identity recognition method, apparatus and system - Google Patents

Animal identity recognition method, apparatus and system Download PDF

Info

Publication number
WO2021083381A1
WO2021083381A1 PCT/CN2020/125884 CN2020125884W WO2021083381A1 WO 2021083381 A1 WO2021083381 A1 WO 2021083381A1 CN 2020125884 W CN2020125884 W CN 2020125884W WO 2021083381 A1 WO2021083381 A1 WO 2021083381A1
Authority
WO
WIPO (PCT)
Prior art keywords
feature value
value set
animal
tracked
temporary
Prior art date
Application number
PCT/CN2020/125884
Other languages
French (fr)
Chinese (zh)
Inventor
陆冬云
Original Assignee
北京观海科技发展有限责任公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京观海科技发展有限责任公司 filed Critical 北京观海科技发展有限责任公司
Publication of WO2021083381A1 publication Critical patent/WO2021083381A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/20Analysis of motion
    • G06T7/246Analysis of motion using feature-based methods, e.g. the tracking of corners or segments
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10016Video; Image sequence
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30181Earth observation
    • G06T2207/30188Vegetation; Agriculture

Definitions

  • This application relates to the technical field of machine vision and image recognition, and in particular to an animal identification method, device and system.
  • the lean management of livestock farms requires precise identification of each animal, and the uniqueness of each animal is determined by the assigned unique identifier (referred to as ID for short).
  • ID the assigned unique identifier
  • Traditional animal identification methods usually use physical equipment such as ear tags, collars, and foot rings on the animal to identify the animal’s identity.
  • the physical equipment stores the assigned unique number as the animal’s ID, which is read by a dedicated reading device . For example, in a cattle breeding farm, when specific activities such as feeding, milking, breeding, vaccination, etc. occur, it is necessary to obtain the ID, and use this to record the activity information of the individual cattle.
  • the embodiments of the present application provide an animal identification method, device, and system, which are used to solve the problems of high cost, limited use location, and susceptibility to environmental interference in animal identification in the prior art.
  • an embodiment of the present application provides an animal identification method, which includes the following steps:
  • the method further includes:
  • the unique identifier of the one formal feature value set is the tracked animal object ’S identity.
  • continuously acquiring images of the tracked animal object includes:
  • the calculation of the temporary feature value set of the tracked animal object based on the image includes:
  • the current characteristic value is added to the initial temporary characteristic value set.
  • that the temporary feature value set satisfies the first condition includes: the number of feature values in the temporary feature value set is greater than a first threshold.
  • the similarity between the temporary feature value set and one formal feature value set in all formal feature value sets satisfies the second condition includes: the similarity is greater than a second threshold.
  • the multi-target tracking model includes a first convolutional neural network model.
  • continuously calculating the current feature value of the tracked animal object from the multiple images of the tracked animal object includes: calculating the current feature value of the tracked animal object using a second convolutional neural network model value.
  • the current feature value satisfying the third condition includes: the minimum value of the distance between the current feature value and all feature values in the initial temporary feature value set is greater than a third threshold; wherein, the The distance includes the cosine distance.
  • the method further includes: if the one tracking session ends, destroying the temporary feature value set, and invalidating the identity of the tracked animal object determined in the one tracking session.
  • the image of the tracked animal object includes an image of fur patterns on the surface of the animal's body.
  • an animal identification device including:
  • the tracking module is configured to continuously obtain images of the animal being tracked in a tracking session
  • a feature calculation module configured to calculate a temporary feature value set of the tracked animal object based on the image
  • the first identification module is configured to convert the temporary feature value set into a formal feature value set when the temporary feature value set satisfies the first condition, assign a unique identifier to the formal feature value set, and determine the unique The identifier is the identity identifier of the tracked animal object.
  • the device further includes:
  • the matching module is configured to calculate the similarity between the temporary feature value set and all formal feature value sets, and at least one of all the formal feature value sets when the identity of the tracked animal object is not determined
  • the unique identifier of the formal feature value set is the probability of the identity identifier of the tracked animal object
  • the second identification module is configured to determine the uniqueness of the formal feature value set when the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies a second condition
  • the identifier is the identity identifier of the tracked animal object.
  • the tracking module includes:
  • the first tracking sub-module is configured to use a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images;
  • the second tracking sub-module is configured to obtain the tracking frame of the tracked animal object in the continuous frame image based on the position;
  • the image extraction sub-module is configured to extract multiple images of the tracked animal object from the tracking frame.
  • the feature calculation module includes:
  • the first calculation sub-module is configured to establish an initial temporary feature value set for the tracked animal object in the tracking session
  • the second calculation sub-module is configured to continuously calculate the current characteristic value of the tracked animal object from the multiple images of the tracked animal object;
  • the third calculation sub-module is configured to add the current characteristic value to the initial temporary characteristic value set if the current characteristic value satisfies a third condition.
  • that the temporary feature value set satisfies the first condition includes: the number of feature values in the temporary feature value set is greater than a first threshold.
  • the similarity between the temporary feature value set and one formal feature value set in all formal feature value sets satisfies the second condition includes: the similarity is greater than a second threshold.
  • the multi-target tracking model includes a first convolutional neural network model.
  • the second calculation sub-module is configured to use a second convolutional neural network model to calculate the current feature value of the tracked animal object.
  • the current feature value satisfying the third condition includes: the minimum value of the distance between the current feature value and all feature values in the initial temporary feature value set is greater than a third threshold; wherein, the The distance includes the cosine distance.
  • the device further includes: a clearing module configured to destroy the temporary feature value set at the end of the one tracking session, and make the tracked animal object determined in the one tracking session The identity of is invalid.
  • the image of the tracked animal object includes an image of fur patterns on the surface of the animal's body.
  • an animal identification system including:
  • An image acquisition unit including at least one image acquisition device
  • the processing unit is connected to the image acquisition unit via a network, and is configured to:
  • an embodiment of the present application further provides a computing device, including a memory and a processor; wherein the memory is used to store at least one computer program, wherein the program is executed by the processor to implement the foregoing implementation manners The steps of the method.
  • the embodiments of the present application also provide a computer-readable storage medium on which a computer program is stored, and the computer program is executed by a processor to implement the steps of the method described in the foregoing embodiments.
  • the embodiment of the present application can be used at any position where an animal moves, and there is no need to install an identification device on the animal's body, it is not subject to environmental electromagnetic interference, and the cost is low.
  • Figure 1 is a schematic diagram of the deployment of surveillance cameras in an embodiment of the present application
  • Fig. 2 is a schematic flowchart of an animal identification method according to an embodiment of the present application.
  • FIG. 3 is a schematic diagram of a partial flow of an animal identification method according to another embodiment of the present application.
  • FIG. 4 is a schematic diagram of a partial flow of an animal identification method according to another embodiment of the present application.
  • FIG. 5 is a schematic diagram of a partial flow of an animal identification method according to another embodiment of the present application.
  • Fig. 6 is a schematic structural diagram of a second convolutional neural network model in an embodiment of the present application.
  • FIG. 7 is a diagram of an application example of cattle tracking and identification in a cattle breeding farm according to an embodiment of the present application.
  • FIG. 8 is a schematic structural diagram of an animal identification device according to an embodiment of the present application.
  • FIG. 9 is a schematic diagram of a partial structure of an animal identification device according to another embodiment of the present application.
  • FIG. 10 is a partial structural diagram of an animal identification device according to another embodiment of the present application.
  • Fig. 11 is a schematic structural diagram of an animal identification system according to an embodiment of the present application.
  • an animal identity refers to a string of characters or numbers assigned to each individual animal and used to identify the uniqueness of the individual animal.
  • Fig. 1 is a schematic diagram of the deployment of a surveillance camera in an embodiment of the present application.
  • the embodiment of the application can deploy surveillance cameras in a distributed manner within the range of movement of the cattle in the cowshed, and the deployment density and angle must satisfy the range of movement of the cattle without visual blind spots. At the same time, try to avoid the cattle from blocking each other visually.
  • a surveillance camera that can monitor 4 directions at the same time can be deployed on the central axis of the cowshed, and the surveillance camera can achieve 360-degree coverage.
  • the distance between the surveillance cameras on the central axis can be about 6-8 meters, and the distance between the feeding area and the outside of the cow house is between 12-14 meters, which can achieve no visual blind spots in the space from the ground to the height of 2 meters.
  • the embodiment of the present application can collect video images of multiple surveillance cameras, and through the multi-target tracking technology, real-time tracking of any cow can be realized in any area covered by the camera.
  • the cattle or other animal individuals being tracked are also referred to as tracked animal objects.
  • Fig. 2 is a schematic flowchart of an animal identification method according to an embodiment of the present application. As shown in FIG. 2, the animal identification method of the embodiment of the present application includes the following steps:
  • Step S110 in a tracking session, continuously obtain images of the tracked animal object
  • Step S120 Calculate a temporary feature value set of the tracked animal object based on the image
  • Step S130 when the temporary feature value set meets the first condition, transform the temporary feature value set into a formal feature value set, assign a unique identifier to the formal feature value set, and determine that the unique identifier is the Track the identity of animal objects.
  • the embodiment of the application can continuously acquire images of the tracked animal object, and calculate the temporary feature value set of the tracked animal object based on the acquired image, and the temporary feature value set is calculated for the same tracked animal object
  • the characteristic value (RID) can be a vector calculated from the image of the tracked animal object as input, and is used to characterize the external characteristics of the tracked animal object.
  • the image of the tracked animal object includes an image of fur patterns on the surface of the animal's body. The image of the fur pattern on the surface of the animal body has significant individual differences.
  • the characteristic value (RID) calculated by collecting the image of the fur pattern of the individual animal under different illumination, viewing angle and distance has the following characteristics: the same individual under different conditions
  • the similarity of the calculated eigenvalues is high, and the similarity of the eigenvalues calculated by different individuals is low.
  • the image feature values formed by bovine flower pieces such as milk cow flower pieces can be used to distinguish the differences between individual cows.
  • the temporary feature value set of the tracked animal object meets predetermined conditions and has the ability to distinguish other animal objects, the temporary feature value set is converted into a formal feature value set, and a unique identifier is assigned to it, which can then be used Determine the identity of the animal subject to be tracked.
  • the method can be used at any position where the animal moves, and there is no need to install identification equipment on the animal body, it is not subject to environmental electromagnetic interference, and has low cost.
  • the temporary feature value set satisfying the first condition may include that the number of feature values in the temporary feature value set is greater than a predetermined threshold, that is, the temporary feature value set contains enough to characterize the animal object.
  • the eigenvalues of the external features satisfy the conditions for transforming into the formal eigenvalue set of the animal object.
  • the embodiment of the present application may further include the following steps after the above step 120:
  • Step S140 When the identity of the tracked animal object is not determined, calculate the similarity between the temporary feature value set and all formal feature value sets, and at least one formal feature value in all formal feature value sets
  • the unique identifier of the set is the probability of the identity of the tracked animal object
  • Step S150 When the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets meets the second condition, determine that the unique identifier of the formal feature value set is the being Track the identity of animal objects.
  • the temporary characteristic value set can be considered to be equivalent to a certain formal characteristic value set, so that the identity mark of the tracked animal object can be determined.
  • This embodiment can further improve the real-time performance of animal identification, and there is no need to sample a large amount of data on the animal object in advance.
  • the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition may include that the similarity is greater than a predetermined threshold.
  • the following method can be used to calculate the similarity between the temporary feature value set and the formal feature value set:
  • the distance D x between the two feature value sets can be calculated as:
  • the meaning of the operator min is to calculate the minimum value of the square of the difference between a temporary feature value TRID i in a temporary feature value set and all feature values in a certain formal feature value set.
  • m is theoretically smaller than n.
  • the similarity S x between the temporary feature value set and the formal feature value set is defined as:
  • the similarity is 1, that is, 100% similarity.
  • the probability that the unique identification of a certain formal feature value set in all the formal feature value sets is the identity of the tracked animal object can be calculated by the following method, specifically:
  • the value of N is the number of formal feature set;
  • S i represents the degree of similarity between a feature value N formal formal set of feature values and the temporary collection of feature values, the greater the degree of similarity, which represents a formal feature The greater the probability that the unique identification of the value set is the identification of the tracked animal object.
  • the temporary feature value set of the tracked animal object can be destroyed, and the identity of the tracked animal object determined in the one tracking session can be invalidated.
  • the identification also includes a probabilistic identification calculated for the animal being tracked. In the next tracking session, try to track again.
  • continuously acquiring images of the tracked animal object may include:
  • Step S210 using a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images
  • Step S220 Obtain a tracking frame of the tracked animal object in the continuous frame image based on the position;
  • Step S230 Extract multiple images of the tracked animal object from the tracking frame.
  • the multi-target tracking model may include a first convolutional neural network model.
  • the first convolutional neural network model may be a general convolutional neural network (CNN) model.
  • CNN general convolutional neural network
  • This embodiment first obtains the first frame image of the tracked animal object, and uses CNN-based detection technology to obtain the initial position of each tracked animal object in the picture; in subsequent frame images, Kalman filter can be used Calculate the position of the tracked animal object in the next frame of image; and in subsequent frame images, it can also be based on the feature extraction of CNN to enhance the prediction of the position of the tracked animal object. Further, the tracking frame that wraps the tracked animal object in each frame of image is obtained through CNN, for example, the smallest possible rectangular frame that wraps the tracked animal object.
  • the rectangular frame does not include other images that do not contain the tracked animal object, such as the background. Wait. Subsequently, based on the identified tracking frame, an image of the tracked animal object can be extracted. This method can improve the ability to retrieve the target after a brief loss, and can reduce tracking loss caused by occlusion between animals.
  • the calculation of the temporary feature value set of the tracked animal object based on the image may include:
  • Step S310 in the tracking session, establish an initial temporary feature value set for the tracked animal object
  • Step S320 continuously calculating the current feature value of the tracked animal object from the multiple images of the tracked animal object;
  • Step S330 If the current characteristic value satisfies the third condition, the current characteristic value is added to the initial temporary characteristic value set.
  • an initial temporary feature value set of the tracked animal object is established.
  • this embodiment continues to calculate the current feature value (RID) of the image, If the distance between the current eigenvalue and all eigenvalues in the temporary eigenvalue set satisfies a certain condition, that is, there is a certain degree of difference between the current eigenvalue and the existing eigenvalues in the temporary eigenvalue set, then the current eigenvalue is added to the initial Temporary feature value set, otherwise the current feature value is discarded, and the temporary feature value set of the tracked animal object is calculated.
  • the minimum value of the distance between the current feature value and all feature values in the temporary feature value set is greater than a predetermined threshold, the current feature value may be added to the initial temporary feature value set.
  • the distance between the current feature value and all feature values in the temporary feature value set can be calculated by using the cosine distance or the Euclidean distance between the feature values or a combination of the two. Taking the calculation of cosine distance as an example, it is to calculate the cosine value of the angle between the eigenvalue vectors to measure the distance difference between the eigenvalues.
  • the specific calculation formula is as follows:
  • x and y respectively represent two eigenvalue vectors, xi is an element in the eigenvalue vector x, and y i is an element in the eigenvalue vector y.
  • T(x,y) The value range of T(x,y) is [-1,1]. The larger the value, the larger the angle, the farther the eigenvalues are, and the smaller the similarity.
  • a specially trained second convolutional neural network model may be used to calculate the characteristic value RID of the tracked animal object.
  • the second convolutional neural network model cannot be used for image detection or classification, and is dedicated to calculating the RID of the image. In use, it does not require pre-training of animal objects.
  • Fig. 6 exemplarily shows a schematic structural diagram of the second convolutional neural network model.
  • the process of calculating the feature value RID by the second convolutional neural network model is mainly divided into three steps: inputting the original image, CNN convolution, and outputting RID.
  • the second convolutional neural network model structure is similar to the main structure of the standard CNN model. Any CNN model (including but not limited to SSD and YOLO models) that can be used for target detection (including but not limited to SSD and YOLO models) can be applied to the embodiments of this application.
  • the main change of the second convolutional neural network is to remove the last layer of the standard CNN model, namely the fully connected layer (FC), which is the classification layer of the CNN neural network.
  • the output RID of the second convolutional neural network is the input of the original FC layer, which is a one-dimensional vector, and the length of the vector can be arbitrary.
  • Fig. 7 is a diagram of an application example of cattle tracking and identification in a cattle breeding farm according to an embodiment of the present application.
  • cows can be tracked in any area covered by the camera.
  • images of each tracked object are periodically collected.
  • the collected images are partial screenshots in a rectangular frame as small as possible that contain the tracked object, and do not contain other images of the tracked object. Such as background images.
  • the collected partial images of the cattle (C1, C2, C3 in the figure) are input into the above-mentioned second convolutional neural network model to calculate the corresponding feature value RID (RID1, RID2, RID3 in the figure), when the calculation
  • RID feature value
  • it is stored in a temporary RID set corresponding to the tracked object until the temporary RID set confirms to match a formal RID set, or the temporary RID set meets the conditions for transforming into a formal RID set. Transformed into a formal RID, and was assigned a formal cattle ID. If the tracking of the currently tracked object is lost, the temporary RID set is destroyed.
  • Fig. 8 is a schematic structural diagram of an animal identification device according to an embodiment of the present application. As shown in FIG. 8, the animal identification device of the embodiment of the present application includes the following components:
  • the tracking module 410 is configured to continuously obtain images of the tracked animal object in a tracking session
  • the feature calculation module 420 is configured to calculate a temporary feature value set of the tracked animal object based on the image
  • the first identification module 430 is configured to convert the temporary feature value set into a formal feature value set when the temporary feature value set meets the first condition, assign a unique identifier to the formal feature value set, and determine the The unique identifier is the identity identifier of the tracked animal object.
  • the temporary feature value set satisfying the first condition may include that the number of feature values in the temporary feature value set is greater than a predetermined threshold.
  • the embodiment of the present application may further include the following components:
  • the matching module 440 is configured to calculate the similarity between the temporary feature value set and all the formal feature value sets when the identity of the tracked animal object is not determined, and at least among all the formal feature value sets
  • the unique identifier of a formal feature value set is the probability of the identity of the tracked animal object
  • the second recognition module 450 is configured to determine the degree of similarity between the temporary feature value set and a formal feature value set in all formal feature value sets when the second condition is satisfied.
  • the unique identifier is the identity identifier of the tracked animal object.
  • the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition may include that the similarity is greater than a predetermined threshold.
  • the calculation of the similarity between the temporary feature value set and the formal feature value set can be calculated using the method described in the foregoing embodiment, which will not be repeated here.
  • the probability that the unique identification of a certain formal feature value set in all formal feature value sets is the identity of the tracked animal object can be calculated by the method described in the foregoing embodiment, and will not be repeated here.
  • the embodiment of the present application may further include the following components (not shown in the figure): a clearing module configured to destroy the temporary feature value set of the tracked animal object at the end of a tracking session, and make The identity of the tracked animal object determined in the one tracking session becomes invalid.
  • the identification also includes a probabilistic identification calculated for the animal being tracked.
  • the tracking module 410 may include:
  • the first tracking sub-module 510 is configured to use a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images;
  • the second tracking sub-module 520 is configured to obtain the tracking frame of the tracked animal object in the continuous frame image based on the position;
  • the image extraction sub-module 530 is configured to extract multiple images of the tracked animal object from the tracking frame.
  • the multi-target tracking model may include a first convolutional neural network model.
  • the first convolutional neural network model may be a general convolutional neural network (CNN) model.
  • CNN general convolutional neural network
  • This embodiment first obtains the first frame image of the tracked animal object, and uses CNN-based detection technology to obtain the initial position of each tracked animal object in the picture; in subsequent frame images, Kalman filter can be used Calculate the position of the tracked animal object in the next frame of image; and in subsequent frame images, it can also be based on the feature extraction of CNN to enhance the prediction of the position of the tracked animal object. Further, the tracking frame that wraps the tracked animal object in each frame of the image is obtained through CNN, for example, the smallest possible rectangular frame that wraps the tracked animal object.
  • the rectangular frame does not include other images that do not contain the tracked animal object, such as the background. Wait. Subsequently, based on the identified tracking frame, an image of the tracked animal object can be extracted. This method can improve the ability to retrieve the target after a brief loss, and can reduce tracking loss caused by occlusion between animals.
  • the feature calculation module 420 may include:
  • the first calculation sub-module 610 is configured to establish an initial temporary feature value set for the tracked animal object in the tracking session
  • the second calculation sub-module 620 is configured to continuously calculate the current characteristic value of the tracked animal object from the multiple images of the tracked animal object;
  • the third calculation sub-module 630 is configured to add the current characteristic value to the initial temporary characteristic value set if the current characteristic value satisfies a third condition.
  • an initial temporary feature value set of the tracked animal object is established.
  • this embodiment continues to calculate the current feature value (RID) of the image, If the distance between the current eigenvalue and all eigenvalues in the temporary eigenvalue set satisfies a certain condition, that is, there is a certain degree of difference between the current eigenvalue and the existing eigenvalues in the temporary eigenvalue set, then the current eigenvalue is added to the initial Temporary feature value set, otherwise the current feature value is discarded, and the temporary feature value set of the tracked animal object is calculated.
  • the minimum value of the distance between the current feature value and all feature values in the temporary feature value set is greater than a predetermined threshold, the current feature value may be added to the initial temporary feature value set.
  • the distance between the current feature value and all feature values in the temporary feature value set can be calculated by using the cosine distance or the Euclidean distance between the feature values or a combination of the two. Taking the calculation of the cosine distance as an example, it is to calculate the cosine value of the angle between the eigenvalue vectors to measure the distance difference between the eigenvalues. The specific calculation formula is as described above and will not be repeated here.
  • a specially trained second convolutional neural network model may be used to calculate the characteristic value RID of the tracked animal object.
  • the second convolutional neural network model cannot be used for image detection or classification, and is dedicated to calculating the RID of the image. In use, it does not require pre-training of animal objects.
  • Fig. 11 is a schematic structural diagram of an animal identification system according to an embodiment of the present application. As shown in FIG. 11, the animal identification system of the embodiment of the present application may include the following units:
  • An image acquisition unit 710 including at least one image acquisition device
  • the processing unit 720 is connected to the image acquisition unit 710 via a network, and is configured to: continuously acquire images of the tracked animal object in a tracking session; and calculate the temporary characteristics of the tracked animal object based on the image Value set; when the temporary feature value set meets the first condition, the temporary feature value set is transformed into a formal feature value set, a unique identifier is assigned to the formal feature value set, and the unique identifier is determined to be the Track the identity of animal objects.
  • the image acquisition device may include a camera or a camera, which is distributed in the space of the animal activity place.
  • the processing unit 720 may be a server or other computing processing devices connected to the image capture device through a network.
  • the temporary feature value set satisfying the first condition may include that the number of feature values in the temporary feature value set is greater than a predetermined threshold.
  • processing unit 720 is further configured to:
  • the unique identifier of the one formal feature value set is the tracked animal object ’S identity.
  • the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition may include that the similarity is greater than a predetermined threshold.
  • the calculation of the similarity between the temporary feature value set and the formal feature value set can be calculated using the method described in the foregoing embodiment, which will not be repeated here.
  • the probability that the unique identification of a certain formal feature value set in all formal feature value sets is the identity of the tracked animal object can be calculated by the method described in the foregoing embodiment, and will not be repeated here.
  • the processing unit 720 is further configured to: at the end of a tracking session, destroy the temporary feature value set of the tracked animal object, and invalidate the identity of the tracked animal object determined in the one tracking session .
  • the identification also includes a probabilistic identification calculated for the animal being tracked.
  • the processing unit 720 is further configured to: use a multi-target tracking model to identify the position of the tracked animal object from the acquired continuous frame images; and obtain information about the tracked animal object in the continuous frame image based on the position. Tracking frame; extracting multiple images of the tracked animal object from the tracking frame.
  • the multi-target tracking model may include a first convolutional neural network model.
  • the first convolutional neural network model may be a general convolutional neural network (CNN) model.
  • the processing unit 720 is further configured to: in the tracking session, establish an initial temporary feature value set for the tracked animal object; and continuously calculate the tracked animal object from multiple images of the tracked animal object. The current feature value of the tracked animal object; if the current feature value satisfies the third condition, the current feature value is added to the initial temporary feature value set.
  • the current feature value satisfying the third condition includes that the minimum value of the distance between the current feature value and all feature values in the temporary feature value set is greater than a predetermined threshold.
  • the distance between the current feature value and all feature values in the temporary feature value set can be calculated by using the cosine distance or the Euclidean distance between the feature values or a combination of the two. Taking the calculation of the cosine distance as an example, the specific calculation formula is as described above, and will not be repeated here.
  • a specially trained second convolutional neural network model may be used to calculate the characteristic value RID of the tracked animal object.
  • the second convolutional neural network model cannot be used for image detection or classification, and is dedicated to calculating the RID of the image. In use, it does not require pre-training of animal objects.
  • the steps, units, or modules involved in the embodiments of the present application can be implemented by software, hardware, or a combination thereof.
  • the described steps, units, or modules may also be provided in the processor of the computing device, where the name of the unit or module does not constitute a limitation on the unit or module itself.
  • an embodiment of the present application may include a computer program product, which includes a readable storage medium storing one or more computer programs, and the computer program includes program code for executing the method described in the present application.
  • the embodiments of the present application may also include a computer-readable storage medium that stores one or more programs, and the one or more programs are executed by one or more processors. When executed, the method described in this application can be implemented.
  • the methods and devices described in this application can be implemented by computing devices such as personal computers and servers.
  • the computing devices usually include a processor for executing various programs and a memory for storing programs, where the programs are loaded into the processor and run.
  • the method described in this application can be implemented at this time.

Abstract

An animal identity recognition method, apparatus and system. The method comprises: continuously obtain images of a tracked animal object in a tracking session (S110); calculating a temporary feature value set of the tracked animal object on the basis of the images (S120); and when the temporary feature value set meets a first condition, converting the temporary feature value set into a formal feature value set, assigning a unique identifier to the formal feature value set, and determining the unique identifier as the identity identifier of the tracked animal object (S130). This method can be used at any position in a movement area of an animal, does not need to install a recognition device on the body of the animal, is not subject to environmental electromagnetic interference, and has low cost.

Description

动物身份识别方法、装置和系统Animal identification method, device and system 技术领域Technical field
本申请涉及机器视觉和图像识别技术领域,具体涉及一种动物身份识别方法、装置和系统。This application relates to the technical field of machine vision and image recognition, and in particular to an animal identification method, device and system.
背景技术Background technique
畜类动物养殖场的精益管理要求精确识别每只动物,每只动物的唯一性通过所分配的唯一标识确定(简称为ID)。传统的动物身份识别方法通常采用在动物身上设置耳标、项圈、脚环等物理设备来对动物身份进行标识,该物理设备里保存分配的唯一编号作为动物的ID,通过专用读取设备读出。例如,在牛养殖场中,在特定活动如投料、挤奶、配种、注射疫苗等发生时,需要获取该ID,并以此记录牛个体的活动信息。The lean management of livestock farms requires precise identification of each animal, and the uniqueness of each animal is determined by the assigned unique identifier (referred to as ID for short). Traditional animal identification methods usually use physical equipment such as ear tags, collars, and foot rings on the animal to identify the animal’s identity. The physical equipment stores the assigned unique number as the animal’s ID, which is read by a dedicated reading device . For example, in a cattle breeding farm, when specific activities such as feeding, milking, breeding, vaccination, etc. occur, it is necessary to obtain the ID, and use this to record the activity information of the individual cattle.
但是,该传统的动物身份识别方法需要在动物身上安装专用设备,并在动物活动区域的特定位置部署专用读取设备,动物数量越大,所需部署的设备数量越多,对企业形成高昂的管理成本;此外,ID的存储设备与读取设备只能在短距离工作,无法在动物的整个活动空间提供ID,读取位置受限,且读取精度受环境干扰。However, this traditional method of animal identification requires the installation of special equipment on animals and the deployment of special reading equipment at specific locations in the animal activity area. The larger the number of animals, the more equipment needs to be deployed, which poses a high cost to the enterprise. Management cost; in addition, ID storage devices and reading devices can only work at short distances, and cannot provide IDs in the entire activity space of the animals. The reading position is limited, and the reading accuracy is interfered by the environment.
发明内容Summary of the invention
本申请实施例提供一种动物身份识别方法、装置和系统,用于解决现有技术中动物身份识别存在成本高、使用位置受限、易受环境干扰等问题。The embodiments of the present application provide an animal identification method, device, and system, which are used to solve the problems of high cost, limited use location, and susceptibility to environmental interference in animal identification in the prior art.
第一方面,本申请实施例提供一种动物身份识别方法,包括以下步骤:In the first aspect, an embodiment of the present application provides an animal identification method, which includes the following steps:
在一个追踪会话中,持续获取被追踪动物对象的图像;In a tracking session, continuously obtain images of the animal being tracked;
基于所述图像,计算所述被追踪动物对象的临时特征值集合;Based on the image, calculating a temporary feature value set of the tracked animal object;
在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。When the temporary feature value set meets the first condition, transform the temporary feature value set into a formal feature value set, assign a unique identifier to the formal feature value set, and determine that the unique identifier is the tracked animal object ’S identity.
在优选的实施方式中,所述方法还包括:In a preferred embodiment, the method further includes:
在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;When the identity of the tracked animal object is not determined, calculate the similarity between the temporary feature value set and all formal feature value sets, and the uniqueness of at least one formal feature value set in all formal feature value sets The probability of being identified as the identity of the tracked animal object;
当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相 似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。When the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition, it is determined that the unique identifier of the one formal feature value set is the tracked animal object ’S identity.
在优选的实施方式中,所述在一个追踪会话中,持续获取被追踪动物对象的图像包括:In a preferred embodiment, in a tracking session, continuously acquiring images of the tracked animal object includes:
采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;Using a multi-target tracking model to identify the location of the tracked animal object from the collected continuous frame images;
基于所述位置获取连续帧图像中被追踪动物对象的追踪框;Acquiring a tracking frame of the animal object being tracked in consecutive frames of images based on the position;
从所述追踪框提取所述被追踪动物对象的多个图像。Extracting multiple images of the tracked animal object from the tracking frame.
在优选的实施方式中,所述基于所述图像,计算所述被追踪动物对象的临时特征值集合包括:In a preferred embodiment, the calculation of the temporary feature value set of the tracked animal object based on the image includes:
在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;In the tracking session, establish an initial temporary feature value set for the tracked animal object;
从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;Continuously calculating the current feature value of the tracked animal object from the multiple images of the tracked animal object;
如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。If the current characteristic value satisfies the third condition, the current characteristic value is added to the initial temporary characteristic value set.
在优选的实施方式中,所述临时特征值集合满足第一条件包括:所述临时特征值集合中的特征值的数量大于第一阈值。In a preferred embodiment, that the temporary feature value set satisfies the first condition includes: the number of feature values in the temporary feature value set is greater than a first threshold.
在优选的实施方式中,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件包括:所述相似度大于第二阈值。In a preferred embodiment, the similarity between the temporary feature value set and one formal feature value set in all formal feature value sets satisfies the second condition includes: the similarity is greater than a second threshold.
在优选的实施方式中,所述多目标追踪模型包括第一卷积神经网络模型。In a preferred embodiment, the multi-target tracking model includes a first convolutional neural network model.
在优选的实施方式中,从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值包括:采用第二卷积神经网络模型计算所述被追踪动物对象的当前特征值。In a preferred embodiment, continuously calculating the current feature value of the tracked animal object from the multiple images of the tracked animal object includes: calculating the current feature value of the tracked animal object using a second convolutional neural network model value.
在优选的实施方式中,所述当前特征值满足第三条件包括:所述当前特征值与所述初始临时特征值集合中的所有特征值的距离的最小值大于第三阈值;其中,所述距离包括余弦距离。In a preferred embodiment, the current feature value satisfying the third condition includes: the minimum value of the distance between the current feature value and all feature values in the initial temporary feature value set is greater than a third threshold; wherein, the The distance includes the cosine distance.
在优选的实施方式中,所述方法还包括:如果所述一个追踪会话结束,则销毁所述临时特征值集合,且使所述一个追踪会话中确定的被追踪动物对象的身份标识失效。In a preferred embodiment, the method further includes: if the one tracking session ends, destroying the temporary feature value set, and invalidating the identity of the tracked animal object determined in the one tracking session.
在优选的实施方式中,所述被追踪动物对象的图像包括动物身体表面的皮毛花纹的图像。In a preferred embodiment, the image of the tracked animal object includes an image of fur patterns on the surface of the animal's body.
第二方面,本申请实施例提供一种动物身份识别装置,包括:In the second aspect, an embodiment of the present application provides an animal identification device, including:
追踪模块,被配置为在一个追踪会话中,持续获取被追踪动物对象的图像;The tracking module is configured to continuously obtain images of the animal being tracked in a tracking session;
特征计算模块,被配置为基于所述图像,计算所述被追踪动物对象的临时特征值集合;A feature calculation module configured to calculate a temporary feature value set of the tracked animal object based on the image;
第一识别模块,被配置为在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。The first identification module is configured to convert the temporary feature value set into a formal feature value set when the temporary feature value set satisfies the first condition, assign a unique identifier to the formal feature value set, and determine the unique The identifier is the identity identifier of the tracked animal object.
在优选的实施方式中,所述装置还包括:In a preferred embodiment, the device further includes:
匹配模块,被配置为在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;The matching module is configured to calculate the similarity between the temporary feature value set and all formal feature value sets, and at least one of all the formal feature value sets when the identity of the tracked animal object is not determined The unique identifier of the formal feature value set is the probability of the identity identifier of the tracked animal object;
第二识别模块,被配置为当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。The second identification module is configured to determine the uniqueness of the formal feature value set when the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies a second condition The identifier is the identity identifier of the tracked animal object.
在优选的实施方式中,所述追踪模块包括:In a preferred embodiment, the tracking module includes:
第一追踪子模块,被配置为采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;The first tracking sub-module is configured to use a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images;
第二追踪子模块,被配置为基于所述位置获取连续帧图像中被追踪动物对象的追踪框;The second tracking sub-module is configured to obtain the tracking frame of the tracked animal object in the continuous frame image based on the position;
图像提取子模块,被配置为从所述追踪框提取所述被追踪动物对象的多个图像。The image extraction sub-module is configured to extract multiple images of the tracked animal object from the tracking frame.
在优选的实施方式中,所述特征计算模块包括:In a preferred embodiment, the feature calculation module includes:
第一计算子模块,被配置为在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;The first calculation sub-module is configured to establish an initial temporary feature value set for the tracked animal object in the tracking session;
第二计算子模块,被配置为从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;The second calculation sub-module is configured to continuously calculate the current characteristic value of the tracked animal object from the multiple images of the tracked animal object;
第三计算子模块,被配置为如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。The third calculation sub-module is configured to add the current characteristic value to the initial temporary characteristic value set if the current characteristic value satisfies a third condition.
在优选的实施方式中,所述临时特征值集合满足第一条件包括:所述临时特征值集合中的特征值的数量大于第一阈值。In a preferred embodiment, that the temporary feature value set satisfies the first condition includes: the number of feature values in the temporary feature value set is greater than a first threshold.
在优选的实施方式中,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件包括:所述相似度大于第二阈值。In a preferred embodiment, the similarity between the temporary feature value set and one formal feature value set in all formal feature value sets satisfies the second condition includes: the similarity is greater than a second threshold.
在优选的实施方式中,所述多目标追踪模型包括第一卷积神经网络模型。In a preferred embodiment, the multi-target tracking model includes a first convolutional neural network model.
在优选的实施方式中,所述第二计算子模块被配置为采用第二卷积神经网络模型计算所述被追踪动物对象的当前特征值。In a preferred embodiment, the second calculation sub-module is configured to use a second convolutional neural network model to calculate the current feature value of the tracked animal object.
在优选的实施方式中,所述当前特征值满足第三条件包括:所述当前特征值与所述初始临时特征值集合中的所有特征值的距离的最小值大于第三阈值;其中,所述距离包括余弦距离。In a preferred embodiment, the current feature value satisfying the third condition includes: the minimum value of the distance between the current feature value and all feature values in the initial temporary feature value set is greater than a third threshold; wherein, the The distance includes the cosine distance.
在优选的实施方式中,所述装置还包括:清除模块,被配置为在所述一个追踪会话结束时,销毁所述临时特征值集合,且使所述一个追踪会话中确定的被追踪动物对象的身份标识失效。In a preferred embodiment, the device further includes: a clearing module configured to destroy the temporary feature value set at the end of the one tracking session, and make the tracked animal object determined in the one tracking session The identity of is invalid.
在优选的实施方式中,所述被追踪动物对象的图像包括动物身体表面的皮毛花纹的图像。In a preferred embodiment, the image of the tracked animal object includes an image of fur patterns on the surface of the animal's body.
第三方面,本申请实施例提供一种动物身份识别系统,包括:In the third aspect, an embodiment of the present application provides an animal identification system, including:
包括至少一个图像采集设备的图像采集单元;An image acquisition unit including at least one image acquisition device;
处理单元,通过网络连接至所述图像采集单元,其被配置为:The processing unit is connected to the image acquisition unit via a network, and is configured to:
在一个追踪会话中,持续获取被追踪动物对象的图像;In a tracking session, continuously obtain images of the animal being tracked;
基于所述图像,计算所述被追踪动物对象的临时特征值集合;Based on the image, calculating a temporary feature value set of the tracked animal object;
在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。When the temporary feature value set meets the first condition, transform the temporary feature value set into a formal feature value set, assign a unique identifier to the formal feature value set, and determine that the unique identifier is the tracked animal object ’S identity.
第四方面,本申请实施例还提供一种计算设备,包括存储器和处理器;其中,所述存储器用于存储至少一个计算机程序,其中,所述程序被所述处理器执行以实现前述实施方式所述方法的步骤。In a fourth aspect, an embodiment of the present application further provides a computing device, including a memory and a processor; wherein the memory is used to store at least one computer program, wherein the program is executed by the processor to implement the foregoing implementation manners The steps of the method.
第五方面,本申请实施例还提供一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行以实现前述实施方式所述方法的步骤。In a fifth aspect, the embodiments of the present application also provide a computer-readable storage medium on which a computer program is stored, and the computer program is executed by a processor to implement the steps of the method described in the foregoing embodiments.
相对于现有技术,本申请实施例可以在动物活动的任意位置使用,也无需在动物身体上安装识别设备,不受环境电磁干扰,且成本低廉。Compared with the prior art, the embodiment of the present application can be used at any position where an animal moves, and there is no need to install an identification device on the animal's body, it is not subject to environmental electromagnetic interference, and the cost is low.
附图说明Description of the drawings
通过以下详细的描述并结合附图将更充分地理解本发明,其中相似的元件以相似的方式编号,其中:The present invention will be more fully understood through the following detailed description in conjunction with the accompanying drawings, in which similar elements are numbered in a similar manner, in which:
图1是本申请实施例中监控摄像头的部署示意图;Figure 1 is a schematic diagram of the deployment of surveillance cameras in an embodiment of the present application;
图2是根据本申请一实施例的动物身份识别方法的流程示意图;Fig. 2 is a schematic flowchart of an animal identification method according to an embodiment of the present application;
图3是根据本申请另一实施例的动物身份识别方法的部分流程示意图;FIG. 3 is a schematic diagram of a partial flow of an animal identification method according to another embodiment of the present application;
图4是根据本申请又一实施例的动物身份识别方法的部分流程示意图;FIG. 4 is a schematic diagram of a partial flow of an animal identification method according to another embodiment of the present application;
图5是根据本申请又一实施例的动物身份识别方法的部分流程示意图;FIG. 5 is a schematic diagram of a partial flow of an animal identification method according to another embodiment of the present application;
图6是本申请实施例中第二卷积神经网络模型的结构示意图;Fig. 6 is a schematic structural diagram of a second convolutional neural network model in an embodiment of the present application;
图7是根据本申请实施例的牛养殖场中牛追踪识别的应用示例图;FIG. 7 is a diagram of an application example of cattle tracking and identification in a cattle breeding farm according to an embodiment of the present application;
图8是根据本申请一实施例的动物身份识别装置的结构示意图;FIG. 8 is a schematic structural diagram of an animal identification device according to an embodiment of the present application;
图9是根据本申请另一实施例的动物身份识别装置的部分结构示意图;FIG. 9 is a schematic diagram of a partial structure of an animal identification device according to another embodiment of the present application;
图10是根据本申请又一实施例的动物身份识别装置的部分结构示意图;FIG. 10 is a partial structural diagram of an animal identification device according to another embodiment of the present application;
图11是根据本申请一实施例的动物身份识别系统的结构示意图。Fig. 11 is a schematic structural diagram of an animal identification system according to an embodiment of the present application.
具体实施方式Detailed ways
下面通过实施例,并结合附图,对本申请的技术方案进行清楚、完整地说明,但是本申请不限于以下所描述的实施例。基于以下实施例,本领域普通技术人员在没有创造性劳动的前提下所获得的所有其它实施例,都属于本申请保护的范围。为了清楚起见,在附图中省略了与描述示例性实施方式无关的部分。The technical solutions of the present application will be clearly and completely described below through embodiments in conjunction with the drawings, but the present application is not limited to the embodiments described below. Based on the following embodiments, all other embodiments obtained by a person of ordinary skill in the art without creative work shall fall within the protection scope of this application. For the sake of clarity, parts that are not related to the description of the exemplary embodiments are omitted in the drawings.
应理解,本申请中诸如“包括”或“具有”等的术语旨在指示本说明书中所公开的特征、数字、步骤、行为、部件或其组合的存在,并不排除一个或多个其它特征、数字、步骤、行为、部件或其组合存在或被添加的可能性。It should be understood that terms such as "including" or "having" in this application are intended to indicate the existence of the features, numbers, steps, actions, components, or combinations thereof disclosed in this specification, and do not exclude one or more other features , Numbers, steps, behaviors, components or combinations thereof exist or are added possibilities.
如前所述,现有技术中通过对动物个体设置存储有标识ID的物理设备来对动物个体进行身份识别,这种方法存在成本高、使用位置受限、读取精度易受环境干扰等诸多问题。为了克服现有技术的问题,本申请提出一种基于多目标追踪的视觉识别技术获取动物身份ID的方法和系统,利用分布式部署的图像获取装置,如监控摄像头或相机,基于多目标追踪技术(MOT),可以获得在动物任意活动位置识别动物身份的能力。本申请中,动物身份(ID)是指分配给每只动物个体的,用于标识动物个体唯一性的一串字符或者数字。As mentioned above, in the prior art, the physical device storing the identification ID of the animal is used to identify the individual animal. This method has high cost, limited use location, easy reading accuracy and environmental interference, etc. problem. In order to overcome the problems of the prior art, this application proposes a method and system for obtaining animal IDs based on multi-target tracking visual recognition technology, using distributed image acquisition devices, such as surveillance cameras or cameras, based on multi-target tracking technology (MOT), you can get the ability to identify the animal's identity at any position of the animal's activity. In this application, an animal identity (ID) refers to a string of characters or numbers assigned to each individual animal and used to identify the uniqueness of the individual animal.
以下实施例中,为了便于清楚地理解本申请的技术方案,特以牛养殖场为应用场景对本申请的实施例进行描述。In the following embodiments, in order to facilitate a clear understanding of the technical solutions of the present application, a cattle breeding farm is used as an application scenario to describe the embodiments of the present application.
图1是本申请实施例中监控摄像头的部署示意图。以牛养殖场中监控摄像头的部署为例,本申请实施例可以在牛舍中牛的活动范围内分布式部署监控摄像头,部署的密度和角度需满足在牛的活动范围内,无视觉死角,同时尽量避免牛在视觉上的彼此遮挡。如图1的示例中,可以在牛舍中轴线上部署一种可以同时监看4个方向的监控摄像头, 该监控摄像头可以实现360度覆盖。监控摄像头在中轴线上的间距可以为6-8米左右,采食区和牛舍外侧的距离在12-14米之间,可以实现地面到2米高度内空间无视觉死角。本申请实施例可以采集多颗监控摄像头的视频画面,通过多目标追踪技术,在摄像头覆盖的任意区域内可以实现对任意一头牛的实时追踪。本申请实施例中,被追踪的牛或其它动物个体也称为被追踪动物对象。Fig. 1 is a schematic diagram of the deployment of a surveillance camera in an embodiment of the present application. Taking the deployment of surveillance cameras in a cattle breeding farm as an example, the embodiment of the application can deploy surveillance cameras in a distributed manner within the range of movement of the cattle in the cowshed, and the deployment density and angle must satisfy the range of movement of the cattle without visual blind spots. At the same time, try to avoid the cattle from blocking each other visually. In the example shown in Figure 1, a surveillance camera that can monitor 4 directions at the same time can be deployed on the central axis of the cowshed, and the surveillance camera can achieve 360-degree coverage. The distance between the surveillance cameras on the central axis can be about 6-8 meters, and the distance between the feeding area and the outside of the cow house is between 12-14 meters, which can achieve no visual blind spots in the space from the ground to the height of 2 meters. The embodiment of the present application can collect video images of multiple surveillance cameras, and through the multi-target tracking technology, real-time tracking of any cow can be realized in any area covered by the camera. In the embodiments of the present application, the cattle or other animal individuals being tracked are also referred to as tracked animal objects.
图2是根据本申请一实施例的动物身份识别方法的流程示意图。如图2所示,本申请实施例的动物身份识别方法,包括以下步骤:Fig. 2 is a schematic flowchart of an animal identification method according to an embodiment of the present application. As shown in FIG. 2, the animal identification method of the embodiment of the present application includes the following steps:
步骤S110,在一个追踪会话中,持续获取被追踪动物对象的图像;Step S110, in a tracking session, continuously obtain images of the tracked animal object;
步骤S120,基于所述图像,计算所述被追踪动物对象的临时特征值集合;Step S120: Calculate a temporary feature value set of the tracked animal object based on the image;
步骤S130,在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。Step S130, when the temporary feature value set meets the first condition, transform the temporary feature value set into a formal feature value set, assign a unique identifier to the formal feature value set, and determine that the unique identifier is the Track the identity of animal objects.
本申请实施例中,在基于监控摄像头实施动物的多目标追踪时,由于动物之间彼此遮挡或者被环境遮挡等原因,通常会破坏动物追踪的连续性,技术上存在丢失被追踪动物对象的情形。因而,对于每个被追踪动物对象,从一个追踪对象的产生到其丢失,构成了一个追踪会话。In the embodiments of the present application, when multi-target tracking of animals is implemented based on surveillance cameras, the continuity of animal tracking is usually destroyed due to the fact that animals are blocked by each other or by the environment, and technically, there are situations in which the tracked animal objects are lost. . Therefore, for each tracked animal object, from the creation of a tracked object to its loss, a tracking session is formed.
本申请实施例在一个追踪会话中,能够持续地获取被追踪动物对象的图像,并根据获取的图像计算被追踪动物对象的临时特征值集合,该临时特征值集合是对同一被追踪动物对象计算的特征值的集合,特征值(RID)可以是以被追踪动物对象的图像为输入而计算得到的向量,用于表征被追踪动物对象的外部特征。在一实施方式中,被追踪动物对象的图像包括动物身体表面上的皮毛花纹的图像。动物身体表面的皮毛花纹的图像具有显著的个体差异,通过采集不同光照、视角、远近下的动物个体的皮毛花纹的图像而计算得到的特征值(RID)具有以下特点:相同个体在不同条件下计算得到的特征值相似度高,不同个体计算得到的特征值相似度低。例如,对于牛个体来说,如奶牛花片等牛体花片所形成的图像特征值就可以用来区分各只牛个体之间的差异。当被追踪动物对象的临时特征值集合符合预定条件,其具有足以区别其他动物对象的能力时,将该临时特征值集合转化为正式特征值集合,并为其分配一唯一标识,就可以用来确定该被追踪动物对象的身份。该方法可以在动物活动的任意位置使用,也无需在动物身体上安装识别设备,不受环境电磁干扰,且成本低廉。In a tracking session, the embodiment of the application can continuously acquire images of the tracked animal object, and calculate the temporary feature value set of the tracked animal object based on the acquired image, and the temporary feature value set is calculated for the same tracked animal object The characteristic value (RID) can be a vector calculated from the image of the tracked animal object as input, and is used to characterize the external characteristics of the tracked animal object. In one embodiment, the image of the tracked animal object includes an image of fur patterns on the surface of the animal's body. The image of the fur pattern on the surface of the animal body has significant individual differences. The characteristic value (RID) calculated by collecting the image of the fur pattern of the individual animal under different illumination, viewing angle and distance has the following characteristics: the same individual under different conditions The similarity of the calculated eigenvalues is high, and the similarity of the eigenvalues calculated by different individuals is low. For example, for individual cows, the image feature values formed by bovine flower pieces such as milk cow flower pieces can be used to distinguish the differences between individual cows. When the temporary feature value set of the tracked animal object meets predetermined conditions and has the ability to distinguish other animal objects, the temporary feature value set is converted into a formal feature value set, and a unique identifier is assigned to it, which can then be used Determine the identity of the animal subject to be tracked. The method can be used at any position where the animal moves, and there is no need to install identification equipment on the animal body, it is not subject to environmental electromagnetic interference, and has low cost.
在一实施方式中,所述临时特征值集合满足第一条件可以包括临时特征值集合中的 特征值的数量大于一预定阈值,也就是说,临时特征值集合中包含了足够可以表征该动物对象的外部特征的特征值,满足了转变为该动物对象的正式特征值集合的条件。In an embodiment, the temporary feature value set satisfying the first condition may include that the number of feature values in the temporary feature value set is greater than a predetermined threshold, that is, the temporary feature value set contains enough to characterize the animal object. The eigenvalues of the external features satisfy the conditions for transforming into the formal eigenvalue set of the animal object.
在一实施方式中,如图3所示,本申请实施例在上述步骤120之后还可以进一步包括以下步骤:In an implementation manner, as shown in FIG. 3, the embodiment of the present application may further include the following steps after the above step 120:
步骤S140,在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;Step S140: When the identity of the tracked animal object is not determined, calculate the similarity between the temporary feature value set and all formal feature value sets, and at least one formal feature value in all formal feature value sets The unique identifier of the set is the probability of the identity of the tracked animal object;
步骤S150,当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。Step S150: When the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets meets the second condition, determine that the unique identifier of the formal feature value set is the being Track the identity of animal objects.
本实施例在已采集了动物对象的正式特征值集合的基础上,在一个追踪会话中,通过临时特征值集合与所有的正式特征值集合之间的相似度,获得某个被追踪动物对象属于某个身份标识的概率排名,当相似度满足一定条件,即可认为该临时特征值集合与某个正式特征值集合等价,从而可以确定被追踪动物对象的身份标识。该实施例进一步可以提高动物身份识别的实时性,并且无需事先对动物对象进行大量的数据采样。In this embodiment, on the basis that the formal feature value set of the animal object has been collected, in a tracking session, through the similarity between the temporary feature value set and all the formal feature value sets, it is obtained that a certain tracked animal object belongs to The probability ranking of a certain identity mark, when the similarity satisfies certain conditions, the temporary characteristic value set can be considered to be equivalent to a certain formal characteristic value set, so that the identity mark of the tracked animal object can be determined. This embodiment can further improve the real-time performance of animal identification, and there is no need to sample a large amount of data on the animal object in advance.
在一实施方式中,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件可以包括相似度大于一预定阈值。In an embodiment, the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition may include that the similarity is greater than a predetermined threshold.
在一实施方式中,临时特征值集合与正式特征值集合之间的相似度的计算可以采用以下方法:In an embodiment, the following method can be used to calculate the similarity between the temporary feature value set and the formal feature value set:
假设临时特征值集合的元素个数为m,正式特征值集合的元素个数为n,两个特征值集合之间的距离D x可以计算为: Assuming that the number of elements in the temporary feature value set is m and the number of elements in the formal feature value set is n, the distance D x between the two feature value sets can be calculated as:
Figure PCTCN2020125884-appb-000001
Figure PCTCN2020125884-appb-000001
其中,TRID i表示临时特征值集合中的某个特征值,i=1~m;FRID p表示一个正式特征值集合中的每一个特征值,p=1~n。运算符min的含义是计算临时特征值集合中一个临时特征值TRID i与某个正式特征值集合中的所有特征值的差平方的最小值。此处,m在理论上小于n。FRID j是上述等式右侧的第一个部分求min运算后,该正式特征值集合中剩余的每一个特征值,j=1~n-m。 Among them, TRID i represents a certain feature value in a temporary feature value set, i=1 to m; FRID p represents each feature value in a formal feature value set, p=1 to n. The meaning of the operator min is to calculate the minimum value of the square of the difference between a temporary feature value TRID i in a temporary feature value set and all feature values in a certain formal feature value set. Here, m is theoretically smaller than n. FRID j is each remaining feature value in the formal feature value set after the first part of the right side of the above equation is calculated for min, j = 1 ~ nm.
在计算得到临时特征值集合与正式特征值集合之间的距离之后,就可以求得相似度,临时特征值集合与正式特征值集合之间的相似度S x定义为: After calculating the distance between the temporary feature value set and the formal feature value set, the similarity can be obtained. The similarity S x between the temporary feature value set and the formal feature value set is defined as:
Figure PCTCN2020125884-appb-000002
Figure PCTCN2020125884-appb-000002
其中,如果D x=0,则相似度为1,即100%相似度。 Among them, if D x =0, the similarity is 1, that is, 100% similarity.
在一实施方式中,所有的正式特征值集合中某个正式特征值集合的唯一标识为被追踪动物对象的身份标识的概率可以采用如下方法计算,具体为:In one embodiment, the probability that the unique identification of a certain formal feature value set in all the formal feature value sets is the identity of the tracked animal object can be calculated by the following method, specifically:
Figure PCTCN2020125884-appb-000003
Figure PCTCN2020125884-appb-000003
其中,N为正式特征值集合的个数;S i表示N个正式特征值集合中某个正式特征值集合和临时特征值集合之间的相似度,相似度越大,表示该某个正式特征值集合的唯一标识为被追踪动物对象的身份标识的概率越大。 Wherein, the value of N is the number of formal feature set; S i represents the degree of similarity between a feature value N formal formal set of feature values and the temporary collection of feature values, the greater the degree of similarity, which represents a formal feature The greater the probability that the unique identification of the value set is the identification of the tracked animal object.
在一实施方式中,如果一个追踪会话结束,则可以销毁被追踪动物对象的临时特征值集合,并使得所述一个追踪会话中确定的被追踪动物对象的身份标识失效。该身份标识也包括为被追踪动物对象计算得到的概率性的身份标识。下一次追踪会话中,再重新进行追踪。In one embodiment, if a tracking session ends, the temporary feature value set of the tracked animal object can be destroyed, and the identity of the tracked animal object determined in the one tracking session can be invalidated. The identification also includes a probabilistic identification calculated for the animal being tracked. In the next tracking session, try to track again.
在一实施方式中,如图4所示,上述步骤110中,所述在一个追踪会话中,持续获取被追踪动物对象的图像可以包括:In one embodiment, as shown in FIG. 4, in the above step 110, in a tracking session, continuously acquiring images of the tracked animal object may include:
步骤S210,采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;Step S210, using a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images;
步骤S220,基于所述位置获取连续帧图像中被追踪动物对象的追踪框;Step S220: Obtain a tracking frame of the tracked animal object in the continuous frame image based on the position;
步骤S230,从所述追踪框提取所述被追踪动物对象的多个图像。Step S230: Extract multiple images of the tracked animal object from the tracking frame.
其中,在一实施方式中,所述多目标追踪模型可以包括第一卷积神经网络模型。第一卷积神经网络模型可以是通用的卷积神经网络(CNN)模型。本实施例首先取得被追踪动物对象的第一帧图像,采用基于CNN的检测技术获取画面中每个被追踪动物对象的初始位置;在后继帧图像中,则可以采用卡尔曼(Kalman)滤波器计算被追踪动物对象在下一帧图像中的位置;并且在后继帧图像中,还可以基于CNN的特征提取,增强对被追踪动物对象的位置的预测。进一步地,通过CNN获取每帧图像中包裹被追踪动物对象的追踪框,例如包裹被追踪动物对象的尽可能小的矩形框,该矩形框不包括不包含被追踪动物对象的其它图像,例如背景等。随后,基于识别到的追踪框,可以提取被追踪动物对象的图像。这种方法可以提升目标短暂丢失后重新找回的能力,能够减少由于动物之间遮挡造成的追踪丢失。Wherein, in an embodiment, the multi-target tracking model may include a first convolutional neural network model. The first convolutional neural network model may be a general convolutional neural network (CNN) model. This embodiment first obtains the first frame image of the tracked animal object, and uses CNN-based detection technology to obtain the initial position of each tracked animal object in the picture; in subsequent frame images, Kalman filter can be used Calculate the position of the tracked animal object in the next frame of image; and in subsequent frame images, it can also be based on the feature extraction of CNN to enhance the prediction of the position of the tracked animal object. Further, the tracking frame that wraps the tracked animal object in each frame of image is obtained through CNN, for example, the smallest possible rectangular frame that wraps the tracked animal object. The rectangular frame does not include other images that do not contain the tracked animal object, such as the background. Wait. Subsequently, based on the identified tracking frame, an image of the tracked animal object can be extracted. This method can improve the ability to retrieve the target after a brief loss, and can reduce tracking loss caused by occlusion between animals.
在一些实施方式中,如图5所示,上述步骤120中,所述基于所述图像,计算所述 被追踪动物对象的临时特征值集合可以包括:In some embodiments, as shown in FIG. 5, in the above step 120, the calculation of the temporary feature value set of the tracked animal object based on the image may include:
步骤S310,在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;Step S310, in the tracking session, establish an initial temporary feature value set for the tracked animal object;
步骤S320,从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;Step S320, continuously calculating the current feature value of the tracked animal object from the multiple images of the tracked animal object;
步骤S330,如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。Step S330: If the current characteristic value satisfies the third condition, the current characteristic value is added to the initial temporary characteristic value set.
其中,对每一个追踪会话,会建立被追踪动物对象的初始临时特征值集合,随着对目标的追踪不断获取被追踪动物对象的图像,本实施例持续计算图像的当前特征值(RID),如果当前特征值与临时特征值集合中的所有特征值的距离满足一定条件,即该当前特征值与临时特征值集合中的已有特征值之间具有一定差异度,则将当前特征值加入初始临时特征值集合,否则放弃当前特征值,从而计算得到被追踪动物对象的临时特征值集合。在一实施方式中,如果当前特征值与临时特征值集合中的所有特征值的距离的最小值大于预定阈值时,则可以将当前特征值加入初始临时特征值集合。Among them, for each tracking session, an initial temporary feature value set of the tracked animal object is established. As the tracking of the target continues to obtain the image of the tracked animal object, this embodiment continues to calculate the current feature value (RID) of the image, If the distance between the current eigenvalue and all eigenvalues in the temporary eigenvalue set satisfies a certain condition, that is, there is a certain degree of difference between the current eigenvalue and the existing eigenvalues in the temporary eigenvalue set, then the current eigenvalue is added to the initial Temporary feature value set, otherwise the current feature value is discarded, and the temporary feature value set of the tracked animal object is calculated. In an embodiment, if the minimum value of the distance between the current feature value and all feature values in the temporary feature value set is greater than a predetermined threshold, the current feature value may be added to the initial temporary feature value set.
在一实施方式中,当前特征值与临时特征值集合中的所有特征值的距离可以采用特征值之间的余弦距离或欧式距离或两者的结合来计算。以余弦距离的计算为例,就是计算特征值向量之间夹角的余弦值来衡量特征值之间的距离差异,具体计算公式如下:In an embodiment, the distance between the current feature value and all feature values in the temporary feature value set can be calculated by using the cosine distance or the Euclidean distance between the feature values or a combination of the two. Taking the calculation of cosine distance as an example, it is to calculate the cosine value of the angle between the eigenvalue vectors to measure the distance difference between the eigenvalues. The specific calculation formula is as follows:
Figure PCTCN2020125884-appb-000004
Figure PCTCN2020125884-appb-000004
其中,x,y分别表示两个特征值向量,x i为特征值向量x中的元素,y i为特征值向量y中的元素。 Among them, x and y respectively represent two eigenvalue vectors, xi is an element in the eigenvalue vector x, and y i is an element in the eigenvalue vector y.
T(x,y)的取值范围为[-1,1],值越大,说明夹角越大,特征值之间相距就越远,相似度就越小。The value range of T(x,y) is [-1,1]. The larger the value, the larger the angle, the farther the eigenvalues are, and the smaller the similarity.
在一实施方式中,本实施例可以采用专门训练的第二卷积神经网络模型来计算被追踪动物对象的特征值RID。第二卷积神经网络模型不能用于图像的检测或分类,专用于计算图像的RID,其在使用上,无需对动物对象进行事先的预先训练。In an implementation manner, in this embodiment, a specially trained second convolutional neural network model may be used to calculate the characteristic value RID of the tracked animal object. The second convolutional neural network model cannot be used for image detection or classification, and is dedicated to calculating the RID of the image. In use, it does not require pre-training of animal objects.
图6示例性地示出了第二卷积神经网络模型的结构示意图。如图6所示,第二卷积神经网络模型计算特征值RID的过程主要分为三个步骤:输入原图、CNN卷积、输出RID。第二卷积神经网络模型结构与标准CNN模型的主要结构类似,任何可以做目标 检测(Detection)的CNN模型(包括但不限于SSD、YOLO模型)均可以适用本申请实施例。相对于标准CNN模型,第二卷积神经网络主要的变化是去掉了标准CNN模型的最后一层,即全连接层(Fully Connected Layer,FC),全连接层是CNN神经网络的分类层。该第二卷积神经网络的输出RID即为原FC层的输入,它是一个一维矢量,矢量长度可以任意。Fig. 6 exemplarily shows a schematic structural diagram of the second convolutional neural network model. As shown in Figure 6, the process of calculating the feature value RID by the second convolutional neural network model is mainly divided into three steps: inputting the original image, CNN convolution, and outputting RID. The second convolutional neural network model structure is similar to the main structure of the standard CNN model. Any CNN model (including but not limited to SSD and YOLO models) that can be used for target detection (including but not limited to SSD and YOLO models) can be applied to the embodiments of this application. Compared with the standard CNN model, the main change of the second convolutional neural network is to remove the last layer of the standard CNN model, namely the fully connected layer (FC), which is the classification layer of the CNN neural network. The output RID of the second convolutional neural network is the input of the original FC layer, which is a one-dimensional vector, and the length of the vector can be arbitrary.
图7是根据本申请实施例的牛养殖场中牛追踪识别的应用示例图。如图7所示,牛在摄像头覆盖的任意区域内,均可以被追踪。在一个追踪会话期内,每个被追踪对象,被周期性采集图像,采集的图像为包含被追踪对象的、一个尽可能小的矩形框内的部分截图,不包含被追踪对象的其它图像,如背景图像等。被采集的牛的局部图像(如图中C1,C2,C3)被输入上述第二卷积神经网络模型,用于计算其对应的特征值RID(如图中RID1,RID2,RID3),当所计算的RID符合预定条件时,其被存储在该被追踪对象对应的一个临时RID集合中,直到该临时RID集合确认匹配一个正式RID集合,或者该临时RID集合符合转变为正式RID集合的条件,被转变为一个正式RID,且被分配一个正式的牛ID。如果丢失了对当前被追踪对象的追踪,则该临时RID集合被销毁。Fig. 7 is a diagram of an application example of cattle tracking and identification in a cattle breeding farm according to an embodiment of the present application. As shown in Figure 7, cows can be tracked in any area covered by the camera. During a tracking session, images of each tracked object are periodically collected. The collected images are partial screenshots in a rectangular frame as small as possible that contain the tracked object, and do not contain other images of the tracked object. Such as background images. The collected partial images of the cattle (C1, C2, C3 in the figure) are input into the above-mentioned second convolutional neural network model to calculate the corresponding feature value RID (RID1, RID2, RID3 in the figure), when the calculation When the RID meets the predetermined conditions, it is stored in a temporary RID set corresponding to the tracked object until the temporary RID set confirms to match a formal RID set, or the temporary RID set meets the conditions for transforming into a formal RID set. Transformed into a formal RID, and was assigned a formal cattle ID. If the tracking of the currently tracked object is lost, the temporary RID set is destroyed.
图8是本申请实施例的动物身份识别装置的结构示意图。如图8所示,本申请实施例的动物身份识别装置,包括以下组件:Fig. 8 is a schematic structural diagram of an animal identification device according to an embodiment of the present application. As shown in FIG. 8, the animal identification device of the embodiment of the present application includes the following components:
追踪模块410,被配置为在一个追踪会话中,持续获取被追踪动物对象的图像;The tracking module 410 is configured to continuously obtain images of the tracked animal object in a tracking session;
特征计算模块420,被配置为基于所述图像,计算所述被追踪动物对象的临时特征值集合;The feature calculation module 420 is configured to calculate a temporary feature value set of the tracked animal object based on the image;
第一识别模块430,被配置为在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。The first identification module 430 is configured to convert the temporary feature value set into a formal feature value set when the temporary feature value set meets the first condition, assign a unique identifier to the formal feature value set, and determine the The unique identifier is the identity identifier of the tracked animal object.
在一实施方式中,所述临时特征值集合满足第一条件可以包括临时特征值集合中的特征值的数量大于一预定阈值。In an embodiment, the temporary feature value set satisfying the first condition may include that the number of feature values in the temporary feature value set is greater than a predetermined threshold.
在一实施方式中,如图8所示,本申请实施例还可以进一步包括以下组件:In an implementation manner, as shown in FIG. 8, the embodiment of the present application may further include the following components:
匹配模块440,被配置为在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;The matching module 440 is configured to calculate the similarity between the temporary feature value set and all the formal feature value sets when the identity of the tracked animal object is not determined, and at least among all the formal feature value sets The unique identifier of a formal feature value set is the probability of the identity of the tracked animal object;
第二识别模块450,被配置为当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。The second recognition module 450 is configured to determine the degree of similarity between the temporary feature value set and a formal feature value set in all formal feature value sets when the second condition is satisfied. The unique identifier is the identity identifier of the tracked animal object.
在一实施方式中,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件可以包括相似度大于一预定阈值。In an embodiment, the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition may include that the similarity is greater than a predetermined threshold.
在一实施方式中,临时特征值集合与正式特征值集合之间的相似度的计算可以采用前述实施例中描述的方法计算,在此不再赘述。In an embodiment, the calculation of the similarity between the temporary feature value set and the formal feature value set can be calculated using the method described in the foregoing embodiment, which will not be repeated here.
在一实施方式中,所有的正式特征值集合中某个正式特征值集合的唯一标识为被追踪动物对象的身份标识的概率可以采用前述实施例中描述的方法计算,在此不再赘述。In an embodiment, the probability that the unique identification of a certain formal feature value set in all formal feature value sets is the identity of the tracked animal object can be calculated by the method described in the foregoing embodiment, and will not be repeated here.
在一实施方式中,本申请实施例还可以进一步包括以下组件(图中未示出):清除模块,被配置为在一个追踪会话结束时,销毁被追踪动物对象的临时特征值集合,并使得所述一个追踪会话中确定的被追踪动物对象的身份标识失效。该身份标识也包括为被追踪动物对象计算得到的概率性的身份标识。In an embodiment, the embodiment of the present application may further include the following components (not shown in the figure): a clearing module configured to destroy the temporary feature value set of the tracked animal object at the end of a tracking session, and make The identity of the tracked animal object determined in the one tracking session becomes invalid. The identification also includes a probabilistic identification calculated for the animal being tracked.
在一实施方式中,如图9所示,追踪模块410可以包括:In an embodiment, as shown in FIG. 9, the tracking module 410 may include:
第一追踪子模块510,被配置为采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;The first tracking sub-module 510 is configured to use a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images;
第二追踪子模块520,被配置为基于所述位置获取连续帧图像中被追踪动物对象的追踪框;The second tracking sub-module 520 is configured to obtain the tracking frame of the tracked animal object in the continuous frame image based on the position;
图像提取子模块530,被配置为从所述追踪框提取所述被追踪动物对象的多个图像。The image extraction sub-module 530 is configured to extract multiple images of the tracked animal object from the tracking frame.
其中,在一实施方式中,所述多目标追踪模型可以包括第一卷积神经网络模型。第一卷积神经网络模型可以是通用的卷积神经网络(CNN)模型。本实施例首先取得被追踪动物对象的第一帧图像,采用基于CNN的检测技术获取画面中每个被追踪动物对象的初始位置;在后继帧图像中,则可以采用卡尔曼(Kalman)滤波器计算被追踪动物对象在下一帧图像中的位置;并且在后继帧图像中,还可以基于CNN的特征提取,增强对被追踪动物对象的位置的预测。进一步地,通过CNN获取每帧图像中包裹被追踪动物对象的追踪框,例如包裹被追踪动物对象的尽可能小的矩形框,该矩形框不包括不包含被追踪动物对象的其它图像,例如背景等。随后,基于识别到的追踪框,可以提取被追踪动物对象的图像。这种方法可以提升目标短暂丢失后重新找回的能力,能够减少由于动物之间遮挡造成的追踪丢失。Wherein, in an embodiment, the multi-target tracking model may include a first convolutional neural network model. The first convolutional neural network model may be a general convolutional neural network (CNN) model. This embodiment first obtains the first frame image of the tracked animal object, and uses CNN-based detection technology to obtain the initial position of each tracked animal object in the picture; in subsequent frame images, Kalman filter can be used Calculate the position of the tracked animal object in the next frame of image; and in subsequent frame images, it can also be based on the feature extraction of CNN to enhance the prediction of the position of the tracked animal object. Further, the tracking frame that wraps the tracked animal object in each frame of the image is obtained through CNN, for example, the smallest possible rectangular frame that wraps the tracked animal object. The rectangular frame does not include other images that do not contain the tracked animal object, such as the background. Wait. Subsequently, based on the identified tracking frame, an image of the tracked animal object can be extracted. This method can improve the ability to retrieve the target after a brief loss, and can reduce tracking loss caused by occlusion between animals.
在一些实施方式中,如图10所示,特征计算模块420可以包括:In some embodiments, as shown in FIG. 10, the feature calculation module 420 may include:
第一计算子模块610,被配置为在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;The first calculation sub-module 610 is configured to establish an initial temporary feature value set for the tracked animal object in the tracking session;
第二计算子模块620,被配置为从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;The second calculation sub-module 620 is configured to continuously calculate the current characteristic value of the tracked animal object from the multiple images of the tracked animal object;
第三计算子模块630,被配置为如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。The third calculation sub-module 630 is configured to add the current characteristic value to the initial temporary characteristic value set if the current characteristic value satisfies a third condition.
其中,对每一个追踪会话,会建立被追踪动物对象的初始临时特征值集合,随着对目标的追踪不断获取被追踪动物对象的图像,本实施例持续计算图像的当前特征值(RID),如果当前特征值与临时特征值集合中的所有特征值的距离满足一定条件,即该当前特征值与临时特征值集合中的已有特征值之间具有一定差异度,则将当前特征值加入初始临时特征值集合,否则放弃当前特征值,从而计算得到被追踪动物对象的临时特征值集合。在一实施方式中,如果当前特征值与临时特征值集合中的所有特征值的距离的最小值大于预定阈值时,则可以将当前特征值加入初始临时特征值集合。Among them, for each tracking session, an initial temporary feature value set of the tracked animal object is established. As the tracking of the target continues to obtain the image of the tracked animal object, this embodiment continues to calculate the current feature value (RID) of the image, If the distance between the current eigenvalue and all eigenvalues in the temporary eigenvalue set satisfies a certain condition, that is, there is a certain degree of difference between the current eigenvalue and the existing eigenvalues in the temporary eigenvalue set, then the current eigenvalue is added to the initial Temporary feature value set, otherwise the current feature value is discarded, and the temporary feature value set of the tracked animal object is calculated. In an embodiment, if the minimum value of the distance between the current feature value and all feature values in the temporary feature value set is greater than a predetermined threshold, the current feature value may be added to the initial temporary feature value set.
在一实施方式中,当前特征值与临时特征值集合中的所有特征值的距离可以采用特征值之间的余弦距离或欧式距离或两者的结合来计算。以余弦距离的计算为例,就是计算特征值向量之间夹角的余弦值来衡量特征值之间的距离差异,具体计算公式如前所述,在此不再赘述。In an embodiment, the distance between the current feature value and all feature values in the temporary feature value set can be calculated by using the cosine distance or the Euclidean distance between the feature values or a combination of the two. Taking the calculation of the cosine distance as an example, it is to calculate the cosine value of the angle between the eigenvalue vectors to measure the distance difference between the eigenvalues. The specific calculation formula is as described above and will not be repeated here.
在一实施方式中,本实施例可以采用专门训练的第二卷积神经网络模型来计算被追踪动物对象的特征值RID。第二卷积神经网络模型不能用于图像的检测或分类,专用于计算图像的RID,其在使用上,无需对动物对象进行事先的预先训练。In an implementation manner, in this embodiment, a specially trained second convolutional neural network model may be used to calculate the characteristic value RID of the tracked animal object. The second convolutional neural network model cannot be used for image detection or classification, and is dedicated to calculating the RID of the image. In use, it does not require pre-training of animal objects.
图11是本申请实施例的动物身份识别系统的结构示意图。如图11所示,本申请实施例的动物身份识别系统,可以包括以下单元:Fig. 11 is a schematic structural diagram of an animal identification system according to an embodiment of the present application. As shown in FIG. 11, the animal identification system of the embodiment of the present application may include the following units:
包括至少一个图像采集设备的图像采集单元710;An image acquisition unit 710 including at least one image acquisition device;
处理单元720,通过网络连接至所述图像采集单元710,其被配置为:在一个追踪会话中,持续获取被追踪动物对象的图像;基于所述图像,计算所述被追踪动物对象的临时特征值集合;在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。The processing unit 720 is connected to the image acquisition unit 710 via a network, and is configured to: continuously acquire images of the tracked animal object in a tracking session; and calculate the temporary characteristics of the tracked animal object based on the image Value set; when the temporary feature value set meets the first condition, the temporary feature value set is transformed into a formal feature value set, a unique identifier is assigned to the formal feature value set, and the unique identifier is determined to be the Track the identity of animal objects.
其中,图像采集设备可以包括摄像头或相机,分布式部署在动物活动场所的空间范围内。处理单元720可以是通过网络连接至图像采集设备的服务器或其它计算处理设备。Among them, the image acquisition device may include a camera or a camera, which is distributed in the space of the animal activity place. The processing unit 720 may be a server or other computing processing devices connected to the image capture device through a network.
在一实施方式中,所述临时特征值集合满足第一条件可以包括临时特征值集合中的特征值的数量大于一预定阈值。In an embodiment, the temporary feature value set satisfying the first condition may include that the number of feature values in the temporary feature value set is greater than a predetermined threshold.
在一实施方式中,处理单元720还被配置为:In an embodiment, the processing unit 720 is further configured to:
在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;When the identity of the tracked animal object is not determined, calculate the similarity between the temporary feature value set and all formal feature value sets, and the uniqueness of at least one formal feature value set in all formal feature value sets The probability of being identified as the identity of the tracked animal object;
当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。When the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition, it is determined that the unique identifier of the one formal feature value set is the tracked animal object ’S identity.
在一实施方式中,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件可以包括相似度大于一预定阈值。In an embodiment, the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition may include that the similarity is greater than a predetermined threshold.
在一实施方式中,临时特征值集合与正式特征值集合之间的相似度的计算可以采用前述实施例中描述的方法计算,在此不再赘述。In an embodiment, the calculation of the similarity between the temporary feature value set and the formal feature value set can be calculated using the method described in the foregoing embodiment, which will not be repeated here.
在一实施方式中,所有的正式特征值集合中某个正式特征值集合的唯一标识为被追踪动物对象的身份标识的概率可以采用前述实施例中描述的方法计算,在此不再赘述。In an embodiment, the probability that the unique identification of a certain formal feature value set in all formal feature value sets is the identity of the tracked animal object can be calculated by the method described in the foregoing embodiment, and will not be repeated here.
在一实施方式中,处理单元720还被配置为:在一个追踪会话结束时,销毁被追踪动物对象的临时特征值集合,并使得所述一个追踪会话中确定的被追踪动物对象的身份标识失效。该身份标识也包括为被追踪动物对象计算得到的概率性的身份标识。In one embodiment, the processing unit 720 is further configured to: at the end of a tracking session, destroy the temporary feature value set of the tracked animal object, and invalidate the identity of the tracked animal object determined in the one tracking session . The identification also includes a probabilistic identification calculated for the animal being tracked.
在一实施方式中,处理单元720还被配置为:采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;基于所述位置获取连续帧图像中被追踪动物对象的追踪框;从所述追踪框提取所述被追踪动物对象的多个图像。In one embodiment, the processing unit 720 is further configured to: use a multi-target tracking model to identify the position of the tracked animal object from the acquired continuous frame images; and obtain information about the tracked animal object in the continuous frame image based on the position. Tracking frame; extracting multiple images of the tracked animal object from the tracking frame.
在一实施方式中,所述多目标追踪模型可以包括第一卷积神经网络模型。第一卷积神经网络模型可以是通用的卷积神经网络(CNN)模型。In an embodiment, the multi-target tracking model may include a first convolutional neural network model. The first convolutional neural network model may be a general convolutional neural network (CNN) model.
在一些实施方式中,处理单元720还被配置为:在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。In some embodiments, the processing unit 720 is further configured to: in the tracking session, establish an initial temporary feature value set for the tracked animal object; and continuously calculate the tracked animal object from multiple images of the tracked animal object. The current feature value of the tracked animal object; if the current feature value satisfies the third condition, the current feature value is added to the initial temporary feature value set.
在一实施方式中,所述当前特征值满足第三条件包括当前特征值与临时特征值集合中的所有特征值的距离的最小值大于预定阈值。In an embodiment, the current feature value satisfying the third condition includes that the minimum value of the distance between the current feature value and all feature values in the temporary feature value set is greater than a predetermined threshold.
在一实施方式中,当前特征值与临时特征值集合中的所有特征值的距离可以采用特征值之间的余弦距离或欧式距离或两者的结合来计算。以余弦距离的计算为例,具体计算公式如前所述,在此不再赘述。In an embodiment, the distance between the current feature value and all feature values in the temporary feature value set can be calculated by using the cosine distance or the Euclidean distance between the feature values or a combination of the two. Taking the calculation of the cosine distance as an example, the specific calculation formula is as described above, and will not be repeated here.
在一实施方式中,本实施例可以采用专门训练的第二卷积神经网络模型来计算被追踪动物对象的特征值RID。第二卷积神经网络模型不能用于图像的检测或分类,专用于计算图像的RID,其在使用上,无需对动物对象进行事先的预先训练。In an implementation manner, in this embodiment, a specially trained second convolutional neural network model may be used to calculate the characteristic value RID of the tracked animal object. The second convolutional neural network model cannot be used for image detection or classification, and is dedicated to calculating the RID of the image. In use, it does not require pre-training of animal objects.
本申请实施例中所涉及到的步骤、单元或模块可以通过软件、硬件或其结合的方式实现。所描述的步骤、单元或模块也可以设置在计算设备的处理器中,其中单元或模块的名称并不构成对该单元或模块本身的限定。The steps, units, or modules involved in the embodiments of the present application can be implemented by software, hardware, or a combination thereof. The described steps, units, or modules may also be provided in the processor of the computing device, where the name of the unit or module does not constitute a limitation on the unit or module itself.
本申请实施例描述的方法可以被实现为计算机软件程序。例如,本申请实施例可以包括一种计算机程序产品,其包括存储有一个或一个以上计算机程序的可读存储介质,所述计算机程序包含用于执行本申请所述描述的方法的程序代码。另一方面,本申请实施例也可以包括一种计算机可读存储介质,该计算机可读存储介质存储有一个或一个以上的程序,所述一个或一个以上的程序被一个或一个以上的处理器执行时,可以实现本申请所描述的方法。The method described in the embodiments of the present application can be implemented as a computer software program. For example, an embodiment of the present application may include a computer program product, which includes a readable storage medium storing one or more computer programs, and the computer program includes program code for executing the method described in the present application. On the other hand, the embodiments of the present application may also include a computer-readable storage medium that stores one or more programs, and the one or more programs are executed by one or more processors. When executed, the method described in this application can be implemented.
本申请所描述的方法、装置可以借助个人电脑、服务器等计算设备实现,该计算设备通常包括执行各种程序的处理器,以及用于存储程序的存储器,其中所述程序加载到处理器中运行时可以实现本申请所描述的方法。The methods and devices described in this application can be implemented by computing devices such as personal computers and servers. The computing devices usually include a processor for executing various programs and a memory for storing programs, where the programs are loaded into the processor and run. The method described in this application can be implemented at this time.
本申请的实施方式并不限于上述实施例所述,在不偏离本申请的精神和范围的情况下,本领域普通技术人员可以在形式和细节上对本申请做出各种改变和改进,这些均被认为落入了本申请的保护范围。The implementation of the application is not limited to the above-mentioned embodiments. Without departing from the spirit and scope of the application, a person of ordinary skill in the art can make various changes and improvements in the form and details of the application, all of which are It is considered to fall into the scope of protection of this application.

Claims (25)

  1. 一种动物身份识别方法,其特征在于,包括以下步骤:An animal identification method, characterized in that it comprises the following steps:
    在一个追踪会话中,持续获取被追踪动物对象的图像;In a tracking session, continuously obtain images of the animal being tracked;
    基于所述图像,计算所述被追踪动物对象的临时特征值集合;Based on the image, calculating a temporary feature value set of the tracked animal object;
    在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。When the temporary feature value set meets the first condition, transform the temporary feature value set into a formal feature value set, assign a unique identifier to the formal feature value set, and determine that the unique identifier is the tracked animal object ’S identity.
  2. 根据权利要求1所述的动物身份识别方法,其特征在于,还包括:The animal identification method according to claim 1, characterized in that it further comprises:
    在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;When the identity of the tracked animal object is not determined, calculate the similarity between the temporary feature value set and all formal feature value sets, and the uniqueness of at least one formal feature value set in all formal feature value sets The probability of being identified as the identity of the tracked animal object;
    当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。When the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies the second condition, it is determined that the unique identifier of the one formal feature value set is the tracked animal object ’S identity.
  3. 根据权利要求1所述的动物身份识别方法,其特征在于,所述在一个追踪会话中,持续获取被追踪动物对象的图像包括:The animal identification method according to claim 1, characterized in that, in a tracking session, continuously acquiring images of the tracked animal object comprises:
    采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;Using a multi-target tracking model to identify the location of the tracked animal object from the collected continuous frame images;
    基于所述位置获取连续帧图像中被追踪动物对象的追踪框;Acquiring a tracking frame of the animal object being tracked in consecutive frames of images based on the position;
    从所述追踪框提取所述被追踪动物对象的多个图像。Extracting multiple images of the tracked animal object from the tracking frame.
  4. 根据权利要求3所述的动物身份识别方法,其特征在于,所述基于所述图像,计算所述被追踪动物对象的临时特征值集合包括:The animal identification method according to claim 3, wherein the calculation of the temporary feature value set of the tracked animal object based on the image comprises:
    在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;In the tracking session, establish an initial temporary feature value set for the tracked animal object;
    从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;Continuously calculating the current feature value of the tracked animal object from the multiple images of the tracked animal object;
    如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。If the current characteristic value satisfies the third condition, the current characteristic value is added to the initial temporary characteristic value set.
  5. 根据权利要求1所述的动物身份识别方法,其特征在于,所述临时特征值集合满足第一条件包括:所述临时特征值集合中的特征值的数量大于第一阈值。The animal identification method according to claim 1, wherein the temporary feature value set satisfying the first condition comprises: the number of feature values in the temporary feature value set is greater than a first threshold.
  6. 根据权利要求2所述的动物身份识别方法,其特征在于,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件包括:所 述相似度大于第二阈值。The animal identification method according to claim 2, wherein the similarity between the temporary feature value set and one formal feature value set in all formal feature value sets satisfies the second condition comprises: the similarity The degree is greater than the second threshold.
  7. 根据权利要求3所述的动物身份识别方法,其特征在于,所述多目标追踪模型包括第一卷积神经网络模型。The animal identification method according to claim 3, wherein the multi-target tracking model comprises a first convolutional neural network model.
  8. 根据权利要求4所述的动物身份识别方法,其特征在于,从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值包括:采用第二卷积神经网络模型计算所述被追踪动物对象的当前特征值。The animal identification method according to claim 4, wherein continuously calculating the current characteristic value of the tracked animal object from the multiple images of the tracked animal object comprises: calculating by using a second convolutional neural network model The current feature value of the tracked animal object.
  9. 根据权利要求4所述的动物身份识别方法,其特征在于,所述当前特征值满足第三条件包括:所述当前特征值与所述初始临时特征值集合中的所有特征值的距离的最小值大于第三阈值;其中,所述距离包括余弦距离。The animal identification method according to claim 4, wherein the current feature value satisfying the third condition comprises: the minimum value of the distance between the current feature value and all feature values in the initial temporary feature value set Greater than the third threshold; wherein, the distance includes a cosine distance.
  10. 根据权利要求1所述的动物身份识别方法,其特征在于,还包括:在所述一个追踪会话结束时,销毁所述临时特征值集合,且使所述一个追踪会话中确定的被追踪动物对象的身份标识失效。The animal identification method according to claim 1, further comprising: at the end of the one tracking session, destroying the temporary feature value set, and making the tracked animal object determined in the one tracking session The identity of is invalid.
  11. 根据权利要求1所述的动物身份识别方法,其特征在于,所述被追踪动物对象的图像包括动物身体表面的皮毛花纹的图像。The animal identification method according to claim 1, wherein the image of the tracked animal object comprises an image of fur patterns on the surface of the animal's body.
  12. 一种动物身份识别装置,其特征在于,包括:An animal identification device, characterized in that it comprises:
    追踪模块,被配置为在一个追踪会话中,持续获取被追踪动物对象的图像;The tracking module is configured to continuously obtain images of the animal being tracked in a tracking session;
    特征计算模块,被配置为基于所述图像,计算所述被追踪动物对象的临时特征值集合;A feature calculation module configured to calculate a temporary feature value set of the tracked animal object based on the image;
    第一识别模块,被配置为在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。The first identification module is configured to convert the temporary feature value set into a formal feature value set when the temporary feature value set satisfies the first condition, assign a unique identifier to the formal feature value set, and determine the unique The identifier is the identity identifier of the tracked animal object.
  13. 根据权利要求12所述的动物身份识别装置,其特征在于,还包括:The animal identification device according to claim 12, further comprising:
    匹配模块,被配置为在所述被追踪动物对象的身份标识未确定时,计算所述临时特征值集合与所有的正式特征值集合之间的相似度,以及所有的正式特征值集合中至少一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识的概率;The matching module is configured to calculate the similarity between the temporary feature value set and all formal feature value sets, and at least one of all the formal feature value sets when the identity of the tracked animal object is not determined The unique identifier of the formal feature value set is the probability of the identity identifier of the tracked animal object;
    第二识别模块,被配置为当所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件时,确定所述一个正式特征值集合的唯一标识为所述被追踪动物对象的身份标识。The second identification module is configured to determine the uniqueness of the formal feature value set when the similarity between the temporary feature value set and a formal feature value set in all formal feature value sets satisfies a second condition The identifier is the identity identifier of the tracked animal object.
  14. 根据权利要求12所述的动物身份识别装置,其特征在于,所述追踪模块包括:The animal identification device according to claim 12, wherein the tracking module comprises:
    第一追踪子模块,被配置为采用多目标追踪模型从采集的连续帧图像中识别所述被追踪动物对象的位置;The first tracking sub-module is configured to use a multi-target tracking model to identify the position of the tracked animal object from the collected continuous frame images;
    第二追踪子模块,被配置为基于所述位置获取连续帧图像中被追踪动物对象的追踪框;The second tracking sub-module is configured to obtain the tracking frame of the tracked animal object in the continuous frame image based on the position;
    图像提取子模块,被配置为从所述追踪框提取所述被追踪动物对象的多个图像。The image extraction sub-module is configured to extract multiple images of the tracked animal object from the tracking frame.
  15. 根据权利要求14所述的动物身份识别装置,其特征在于,所述特征计算模块包括:The animal identification device according to claim 14, wherein the characteristic calculation module comprises:
    第一计算子模块,被配置为在所述追踪会话中,为所述被追踪动物对象建立初始临时特征值集合;The first calculation sub-module is configured to establish an initial temporary feature value set for the tracked animal object in the tracking session;
    第二计算子模块,被配置为从所述被追踪动物对象的多个图像持续计算所述被追踪动物对象的当前特征值;The second calculation sub-module is configured to continuously calculate the current characteristic value of the tracked animal object from the multiple images of the tracked animal object;
    第三计算子模块,被配置为如果所述当前特征值满足第三条件,则将所述当前特征值加入所述初始临时特征值集合。The third calculation sub-module is configured to add the current characteristic value to the initial temporary characteristic value set if the current characteristic value satisfies a third condition.
  16. 根据权利要求12所述的动物身份识别装置,其特征在于,所述临时特征值集合满足第一条件包括:所述临时特征值集合中的特征值的数量大于第一阈值。The animal identification device according to claim 12, wherein the temporary feature value set satisfying the first condition comprises: the number of feature values in the temporary feature value set is greater than a first threshold.
  17. 根据权利要求13所述的动物身份识别装置,其特征在于,所述临时特征值集合与所有的正式特征值集合中的一个正式特征值集合之间的相似度满足第二条件包括:所述相似度大于第二阈值。The animal identification device according to claim 13, wherein the similarity between the temporary feature value set and one formal feature value set in all formal feature value sets satisfies the second condition comprises: the similarity The degree is greater than the second threshold.
  18. 根据权利要求14所述的动物身份识别装置,其特征在于,所述多目标追踪模型包括第一卷积神经网络模型。The animal identification device according to claim 14, wherein the multi-target tracking model comprises a first convolutional neural network model.
  19. 根据权利要求15所述的动物身份识别装置,其特征在于,所述第二计算子模块被配置为采用第二卷积神经网络模型计算所述被追踪动物对象的当前特征值。The animal identification device according to claim 15, wherein the second calculation sub-module is configured to use a second convolutional neural network model to calculate the current feature value of the tracked animal object.
  20. 根据权利要求15所述的动物身份识别装置,其特征在于,所述当前特征值满足第三条件包括:所述当前特征值与所述初始临时特征值集合中的所有特征值的距离的最小值大于第三阈值;其中,所述距离包括余弦距离。The animal identification device according to claim 15, wherein the current feature value satisfying the third condition comprises: the minimum value of the distance between the current feature value and all feature values in the initial temporary feature value set Greater than the third threshold; wherein, the distance includes a cosine distance.
  21. 根据权利要求12所述的动物身份识别装置,其特征在于,还包括:清除模块,被配置为在所述一个追踪会话结束时,销毁所述临时特征值集合,且使所述一个追踪会话中确定的被追踪动物对象的身份标识失效。The animal identification device according to claim 12, further comprising: a clearing module configured to destroy the temporary feature value set when the one tracking session ends, and make the The identity of the identified animal subject to be tracked is invalid.
  22. 根据权利要求12所述的动物身份识别装置,其特征在于,所述被追踪动物对象的图像包括动物身体表面的皮毛花纹的图像。The animal identification device according to claim 12, wherein the image of the tracked animal object comprises an image of fur patterns on the surface of the animal's body.
  23. 一种动物身份识别系统,其特征在于,包括:An animal identification system, which is characterized in that it comprises:
    包括至少一个图像采集设备的图像采集单元;An image acquisition unit including at least one image acquisition device;
    处理单元,通过网络连接至所述图像采集单元,其被配置为:The processing unit is connected to the image acquisition unit via a network, and is configured to:
    在一个追踪会话中,持续获取被追踪动物对象的图像;In a tracking session, continuously obtain images of the animal being tracked;
    基于所述图像,计算所述被追踪动物对象的临时特征值集合;Based on the image, calculating a temporary feature value set of the tracked animal object;
    在所述临时特征值集合满足第一条件时,将所述临时特征值集合转变为正式特征值集合,为所述正式特征值集合分配唯一标识,确定所述唯一标识为所述被追踪动物对象的身份标识。When the temporary feature value set meets the first condition, transform the temporary feature value set into a formal feature value set, assign a unique identifier to the formal feature value set, and determine that the unique identifier is the tracked animal object ’S identity.
  24. 一种计算设备,其特征在于,包括存储器和处理器;其中,A computing device, which is characterized by comprising a memory and a processor; wherein,
    所述存储器用于存储至少一个计算机程序,其中,所述计算机程序被所述处理器执行以实现权利要求1-11任一项所述方法的步骤。The memory is used to store at least one computer program, wherein the computer program is executed by the processor to implement the steps of the method according to any one of claims 1-11.
  25. 一种计算机可读存储介质,其特征在于,其上存储有计算机程序,该计算机程序被处理器执行以实现权利要求1-11任一项所述方法的步骤。A computer-readable storage medium, characterized in that a computer program is stored thereon, and the computer program is executed by a processor to implement the steps of the method according to any one of claims 1-11.
PCT/CN2020/125884 2019-11-01 2020-11-02 Animal identity recognition method, apparatus and system WO2021083381A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201911060046.1 2019-11-01
CN201911060046.1A CN112785620A (en) 2019-11-01 2019-11-01 Animal identity identification method, device and system

Publications (1)

Publication Number Publication Date
WO2021083381A1 true WO2021083381A1 (en) 2021-05-06

Family

ID=75715892

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/125884 WO2021083381A1 (en) 2019-11-01 2020-11-02 Animal identity recognition method, apparatus and system

Country Status (2)

Country Link
CN (1) CN112785620A (en)
WO (1) WO2021083381A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023203459A1 (en) 2022-04-19 2023-10-26 Lely Patent N.V. Animal husbandry system

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103489199A (en) * 2012-06-13 2014-01-01 通号通信信息集团有限公司 Video image target tracking processing method and system
CN105809711A (en) * 2016-03-02 2016-07-27 华南农业大学 Video tracking based pig movement associated big data extracting method and system
CN106713862A (en) * 2016-12-23 2017-05-24 浙江宇视科技有限公司 Tracking monitoring method and apparatus
CN108363990A (en) * 2018-03-14 2018-08-03 广州影子控股股份有限公司 One boar face identifying system and method
WO2018174812A1 (en) * 2017-03-24 2018-09-27 Bmp Innovation Ab Systems and methods for identifying individual animals in a group of animals
US20190138801A1 (en) * 2017-08-28 2019-05-09 Nutech Ventures Systems for tracking individual animals in a group-housed environment
CN110298239A (en) * 2019-05-21 2019-10-01 平安科技(深圳)有限公司 Target monitoring method, apparatus, computer equipment and storage medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103489199A (en) * 2012-06-13 2014-01-01 通号通信信息集团有限公司 Video image target tracking processing method and system
CN105809711A (en) * 2016-03-02 2016-07-27 华南农业大学 Video tracking based pig movement associated big data extracting method and system
CN106713862A (en) * 2016-12-23 2017-05-24 浙江宇视科技有限公司 Tracking monitoring method and apparatus
WO2018174812A1 (en) * 2017-03-24 2018-09-27 Bmp Innovation Ab Systems and methods for identifying individual animals in a group of animals
US20190138801A1 (en) * 2017-08-28 2019-05-09 Nutech Ventures Systems for tracking individual animals in a group-housed environment
CN108363990A (en) * 2018-03-14 2018-08-03 广州影子控股股份有限公司 One boar face identifying system and method
CN110298239A (en) * 2019-05-21 2019-10-01 平安科技(深圳)有限公司 Target monitoring method, apparatus, computer equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023203459A1 (en) 2022-04-19 2023-10-26 Lely Patent N.V. Animal husbandry system
NL2031623B1 (en) 2022-04-19 2023-11-06 Lely Patent Nv Animal husbandry system

Also Published As

Publication number Publication date
CN112785620A (en) 2021-05-11

Similar Documents

Publication Publication Date Title
Achour et al. Image analysis for individual identification and feeding behaviour monitoring of dairy cows based on Convolutional Neural Networks (CNN)
US10058076B2 (en) Method of monitoring infectious disease, system using the same, and recording medium for performing the same
Xiao et al. Cow identification in free-stall barns based on an improved Mask R-CNN and an SVM
Zin et al. Image technology based cow identification system using deep learning
Kaixuan et al. Recognition of individual dairy cattle based on convolutional neural networks.
Guzhva et al. Now you see me: Convolutional neural network based tracker for dairy cows
TWI714057B (en) Analysis system and method for feeding milk-production livestock
KR102584357B1 (en) Apparatus for identifying a livestock using a pattern, and system for classifying livestock behavior pattern based on images using the apparatus and method thereof
Yujuan et al. Intelligent monitoring method of cow ruminant behavior based on video analysis technology
US20230260327A1 (en) Autonomous livestock monitoring
KR102522239B1 (en) Apparatus and method for analyzing feeding behavior of livestock based on image
Zheng et al. Cows' legs tracking and lameness detection in dairy cattle using video analysis and Siamese neural networks
WO2021083381A1 (en) Animal identity recognition method, apparatus and system
KR102304109B1 (en) Animal tracking monitoring server and operation method thereof
KR20220064712A (en) Apparatus and method for monitoring growing progress of livestock individual based on image
Chae et al. Identifying the mating posture of cattle using deep learning-based object detection with networks of various settings
Dao et al. Automatic cattle location tracking using image processing
Heo et al. Real-time cattle action recognition for estrus detection
CN112528772A (en) Cow lameness movement characteristic detection method and device based on thermal infrared
CN115176290A (en) Method, system and computer program for traceability of living specimens
JP2023553812A (en) Nose-based pet identification system and method
Sarwar et al. Survey of livestock counting and tracking methods
Bergman et al. Biometric identification of dairy cows via real-time facial recognition
CN110991235A (en) State monitoring method and device, electronic equipment and storage medium
Shu et al. Non-contact respiration rate measurement of multiple cows in a free-stall barn using computer vision methods

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20883340

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205N DATED 05.09.2022)

122 Ep: pct application non-entry in european phase

Ref document number: 20883340

Country of ref document: EP

Kind code of ref document: A1