CN114743215A - Cattle face identification method, system, equipment and medium based on graph convolution network model - Google Patents

Cattle face identification method, system, equipment and medium based on graph convolution network model Download PDF

Info

Publication number
CN114743215A
CN114743215A CN202210292944.5A CN202210292944A CN114743215A CN 114743215 A CN114743215 A CN 114743215A CN 202210292944 A CN202210292944 A CN 202210292944A CN 114743215 A CN114743215 A CN 114743215A
Authority
CN
China
Prior art keywords
graph
layer
feature
matrix
convolution network
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
CN202210292944.5A
Other languages
Chinese (zh)
Inventor
田绪红
黎京晔
熊浩
高月芳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
South China Agricultural University
Original Assignee
South China Agricultural University
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 South China Agricultural University filed Critical South China Agricultural University
Priority to CN202210292944.5A priority Critical patent/CN114743215A/en
Publication of CN114743215A publication Critical patent/CN114743215A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/25Fusion techniques
    • G06F18/253Fusion techniques of extracted features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/045Combinations of networks
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A40/00Adaptation technologies in agriculture, forestry, livestock or agroalimentary production
    • Y02A40/70Adaptation technologies in agriculture, forestry, livestock or agroalimentary production in livestock or poultry

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • Evolutionary Computation (AREA)
  • Artificial Intelligence (AREA)
  • General Engineering & Computer Science (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Evolutionary Biology (AREA)
  • General Health & Medical Sciences (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Molecular Biology (AREA)
  • Computational Linguistics (AREA)
  • Biophysics (AREA)
  • Biomedical Technology (AREA)
  • Health & Medical Sciences (AREA)
  • Image Analysis (AREA)

Abstract

The invention discloses a cow face identification method, a cow face identification system, cow face identification equipment and a cow face identification medium based on a graph convolution network model, wherein the method comprises the following steps: acquiring a cow face image; performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map; based on the original feature map, performing multi-scale and multi-level feature division and initializing nodes of a graph convolution network, and performing multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction; and classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face. The invention carries out multilevel and multi-scale global-local information interaction on the extracted original features through the graph convolution network, effectively fuses the global-local information of the cattle face image, and thus obviously improves the accuracy of cattle face identification.

Description

Cattle face identification method, system, equipment and medium based on graph convolution network model
Technical Field
The invention relates to a cow face identification method, a cow face identification system, cow face identification equipment and a cow face identification medium based on a graph convolution network model, and belongs to the field of computer vision.
Background
At present, many methods for identification and verification by using image convolution exist, but most methods are used on human faces/human bodies. In farming and animal husbandry, corresponding requirements also exist, the identification and verification of animal individuals are an indispensable step in animal husbandry breeding, and compared with a traditional wearable marking mode, the identification and verification of the animal individuals by using video images have the advantages of convenience and intuition in data acquisition, non-contact, non-invasive, less artificial stress and the like.
Unlike human face/body recognition and verification, bovine faces have many different characteristics. In many cases, the similarity of the face of a cow is higher than that of a human face, and the facial features of animals of the same species and similar body sizes are not greatly different. Meanwhile, the animals have short growth cycle, and the faces and body shapes of the animals can change greatly in a short time. On the facial features, the face of the cow has hairs, and interference factors such as texture changes and the like, which all increase the difficulty of face recognition of the cow. Compared with human beings, the animal image acquisition is more uncontrollable, the face of an animal cannot be stabilized in front of a camera for a long time by the animal, especially in natural and field environments, the animal image acquisition is more difficult due to the change of illumination conditions, different visual angles and distances, complex backgrounds and other factors, and the undesirable face image can have negative effects on model training and recognition. For this reason, there is an urgent need for a recognition method that can cope with the above-mentioned difference and is different from that on a human face/body.
Disclosure of Invention
In view of this, the present invention provides a method, a system, a device, and a medium for recognizing a bovine face based on a convolutional network model, which perform multi-level and multi-scale global-local information interaction on extracted original features through a convolutional network, so as to effectively fuse global-local information of a bovine face image, thereby significantly improving the accuracy of bovine face recognition.
The invention aims to provide a cow face identification method based on a graph convolution network model.
The invention also aims to provide a cattle face recognition system based on the graph volume network model.
It is a third object of the invention to provide a computer apparatus.
It is a fourth object of the present invention to provide a storage medium.
The first purpose of the invention can be achieved by adopting the following technical scheme:
a cattle face identification method based on a graph convolution network model, the method comprises the following steps:
acquiring a cow face image;
performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map;
based on the original feature map, performing multi-scale and multi-level feature division and initializing nodes of a graph convolution network, and performing multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction;
and classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
Further, the performing multi-scale and multi-level feature division and initializing nodes of a graph convolution network based on the original feature map, and performing multi-scale and multi-level global-local information interaction by using the graph convolution network specifically include:
constructing a graph with a three-layer structure based on the original characteristic graph, wherein the graph is used as a graph structure in a graph volume network;
converting the original feature map into a three-layer feature matrix by using pooling operations of different sizes based on the map of the three-layer structure;
initializing graph nodes of a corresponding layer by using the three layers of feature matrices to obtain the size and the position of an information source area of each graph node of each layer;
constructing a three-layer three-dimensional structure according to the size and the position of the information source area of each layer of graph nodes;
reforming to obtain an adjacent matrix in the graph convolution network according to the three layers of characteristic matrices;
and performing information interaction fusion by using a layer of graph convolution layer in the graph convolution network based on the adjacent matrix in the graph convolution network.
Further, the graph based on the three-layer structure converts the original feature graph into a three-layer feature matrix using pooling operations of different sizes, as follows:
fmatrix-i=φi(fI)
wherein f ismatrix-iThe feature matrix of the ith layer is represented, the size is n multiplied by m, n represents the number of graph nodes of the ith layer, m represents the number of channels of the original feature graph, fIRepresents the original feature map, phiiIndicating that the ith layer was pooled from f using the corresponding layerIExtracting characteristic vectors and arranging the characteristic vectors into a characteristic matrix in sequence;
said ith layer from f using a respective pooling operationIThe operation of extracting feature vectors and arranging the feature vectors into a feature matrix in sequence specifically comprises the following steps:
extracting an i multiplied by C characteristic map from the original characteristic map by using a corresponding pooling kernel;
and (3) recombining the i multiplied by C characteristic diagrams into a characteristic matrix of i multiplied by i rows and C columns, wherein i represents the corresponding layer number, and C represents the channel number of the original characteristic diagram.
Furthermore, in the three-layer three-dimensional structure, a first layer is provided with one graph node, a second layer is provided with four graph nodes, and a third layer is provided with nine graph nodes;
the graph nodes in each layer are arranged according to the positions of the acquired information areas in the original characteristic graph; and the adjacent graph nodes on the same layer and the adjacent graph nodes on different layers all adopt an information extraction mode of edge overlapping, and establish connection according to the coverage relation.
Further, the adjacent matrix in the graph convolution network is obtained by reforming according to the three-layer characteristic matrix, which is as follows:
A=Ψ(fmatrix-1,fmatrix-2,fmatrix-3)
wherein A represents an adjacency matrix in a graph convolution network, Ψ represents a method of reforming a feature matrix, and fmatrix-1,fmatrix-2,fmatrix-3Respectively representing the feature matrixes extracted from the three levels.
Further, the information interaction fusion is performed by using a layer of graph convolution layer in the graph convolution network based on the adjacency matrix in the graph convolution network, as follows:
Figure BDA0003562194530000031
wherein the content of the first and second substances,
Figure BDA0003562194530000032
a represents an adjacency matrix in the graph convolution network, X represents a feature matrix composed of feature vectors of all graph nodes, and W represents the weight of the graph convolution network.
Further, the feature extraction network selects the top 41 layers of the ResNet 50;
the method comprises the following steps of performing initial feature extraction on a cattle face image by using a feature extraction network to obtain an original feature map, wherein the method specifically comprises the following steps:
inputting the cattle face image into a feature extraction network to obtain an original feature map with the size of W multiplied by H multiplied by C, wherein W represents the width, H represents the height, and C represents the number of channels.
The second purpose of the invention can be achieved by adopting the following technical scheme:
a cattle face identification system based on a graph convolution network model, the system comprising:
an acquisition unit configured to acquire a cow face image;
the first feature extraction unit is used for performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map;
the second feature extraction unit is used for carrying out multi-scale and multi-level feature division and initializing nodes of the graph convolution network based on the original feature graph, and carrying out multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction;
and the classification unit is used for classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
The third purpose of the invention can be achieved by adopting the following technical scheme:
a computer device comprises a processor and a memory for storing programs executable by the processor, wherein the processor executes the programs stored in the memory to realize the cattle face identification method.
The fourth purpose of the invention can be achieved by adopting the following technical scheme:
a storage medium stores a program that, when executed by a processor, implements the above-described cow face recognition method.
Compared with the prior art, the invention has the following beneficial effects:
(1) the invention carries out multilevel and multi-scale global-local information interaction on the extracted original features through the graph convolution network, effectively fuses the global-local information of the cattle face image, and thus obviously improves the accuracy of cattle face identification.
(2) The connection mode among the graph nodes in the embodiment of the invention can enable the information interaction among the graph nodes to be more traceable, and meanwhile, the information correlation among the graph nodes is stronger; in addition, the connection mode not only can learn information of multiple layers and scales in a stable structure in the information interaction process, but also can provide better characteristic information after information interaction and fusion.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the structures shown in the drawings without creative efforts.
Fig. 1 is a simple flowchart of a cow face identification method based on a graph convolution network model according to embodiment 1 of the present invention.
Fig. 2 is a specific flowchart of a cow face identification method based on a graph convolution network model according to embodiment 1 of the present invention.
Fig. 3 is a structural diagram of a graph convolution network according to embodiment 1 of the present invention.
Fig. 4 is a flowchart of a cow face recognition system based on a graph convolution network model according to embodiment 2 of the present invention.
Fig. 5 is a block diagram of a computer device according to embodiment 3 of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be described clearly and completely with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some embodiments of the present invention, but not all embodiments, and all other embodiments obtained by a person of ordinary skill in the art without creative efforts based on the embodiments of the present invention belong to the protection scope of the present invention.
Example 1:
as shown in fig. 1 and fig. 2, the present embodiment provides a cow face identification method based on a graph convolution network model, which includes the following steps:
s201, obtaining a cow face image.
This embodiment is mainly directed at the milk cow, through the camera equipment record the ox crowd activity video to carry out the ox face interception to the ox crowd activity video, thereby obtain the ox face image, milk cow face regional image promptly.
S202, performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map.
Inputting the cattle face image into a feature extraction network to obtain an original feature map with the size of W multiplied by H multiplied by C, wherein W, H and C respectively represent the width, height and channel number of the original feature map.
The input size of the cow face image in the embodiment is 448 × 448, and an original feature map of 28 × 28 × 1024 is obtained after feature extraction network processing; taking the original feature graph as an information source for initializing nodes of a subsequent graph; the original feature graph extracted after convolution is used, so that nodes of a subsequent graph can obtain more abstract initialization feature information.
The feature extraction network in this embodiment selects the first 41 layers of ResNet 50.
S203, based on the original feature map, performing multi-scale and multi-level feature division, initializing nodes of the graph convolution network, and performing multi-scale and multi-level global-local information interaction by using the graph convolution network to realize further feature extraction.
As shown in fig. 3, in this embodiment, a graph with a three-layer structure is constructed based on the initial extracted feature map, and is used as a graph structure in a graph convolution network, and feature vectors of different levels are obtained by using pooling operations of different sizes according to a principle of layer-by-layer refinement; the corresponding feature source areas gradually become smaller and have partial overlapping, and an extraction mode with edge overlapping is used for avoiding the loss of partial trans-area information when the areas are divided; in addition to obtaining a 3-layer structure graph, the embodiment also obtains 14 feature vectors from information source areas of different sizes, and then uses the feature vectors to initialize corresponding graph nodes in the graph convolution network.
In this embodiment, multi-scale and multi-level feature division is performed, nodes of a graph convolution network are initialized, and multi-scale and multi-level global-local information interaction is performed by using the graph convolution network, which includes the following specific steps:
s2031, constructing a graph with a three-layer structure based on the original characteristic graph, wherein the graph is used as a graph structure in a graph convolution network.
S2032, based on the graph with three-layer structure, the original feature graph is converted into a three-layer feature matrix by using pooling operation with different sizes.
At the ith layer, converting the original characteristic diagram into a characteristic matrix which can be used for initializing the nodes of the diagram, wherein the row number of the characteristic matrix corresponds to the number of the nodes of the ith layer, and the column number corresponds to the number of channels of the original characteristic diagram, so that the conversion from the original characteristic diagram to the characteristic matrix of the corresponding layer is obtained, and the specific formula is as follows:
fmatrix-i=φi(fI)
wherein, fmatrix-iFeature matrix representing the i-th layer, fIRepresents the original characteristic diagram phiiIndicating that the ith layer was pooled from f using the corresponding layerIAnd extracting feature vectors and arranging the feature vectors into a feature matrix in sequence.
The size of the characteristic matrix of the ith layer is n multiplied by m, wherein n represents the number of graph nodes of the ith layer, and m represents the number of channels of the original characteristic graph; the feature vector corresponding to each row in the feature matrix is the feature vector of the graph node corresponding to the row.
Layer i from f using a corresponding layer pooling operationIThe operation of extracting the feature vectors and arranging the feature vectors into a feature matrix in sequence specifically comprises the following steps: extracting an i multiplied by C feature map from the original feature map by using a corresponding pooling kernel (a pooling kernel with a proper size); and (3) recombining the i multiplied by C characteristic diagrams into a characteristic matrix of i multiplied by i rows and C columns, wherein i represents the corresponding layer number, and C represents the channel number of the original characteristic diagram.
S2033, initializing graph nodes of corresponding layers by using the three-layer feature matrix to obtain the size and position of the information source area of each graph node of each layer.
In this embodiment, based on step S202, an original feature map of 28 × 28 × 1024 is obtained, and according to step S2032, a three-layer feature matrix is obtained, which is specifically as follows:
(1) the pooling size used in the first layer is 28 × 28, resulting in 1 eigenvector; further, according to step S2032, a first-layer feature matrix is obtained.
(2) The pooling size used by the second layer is 21 × 21, the step length is 7, and 4 feature vectors are obtained in total and correspond to four areas, namely, the upper left area, the upper right area, the lower left area and the lower right area of the feature map; further, according to step S2032, a second layer feature matrix is obtained.
(3) The pooling size used by the third layer is 14 multiplied by 14, the step size is 7, 9 feature vectors are obtained in total, and the feature vectors correspond to 9 areas of the feature map; further, according to step S2032, a third-layer feature matrix is obtained.
In this embodiment, the graph nodes of the corresponding layer are initialized by using the three layers of feature matrices, and the size and the position of the information source area of each graph node of each layer are obtained.
The regular and spatial relationship graph node initialization method in this embodiment can extract feature information that is related to each other and derived from multiple layers and multiple scales, where the feature information is a source of global information and local information in a graph convolution network.
S2034, a three-layer three-dimensional structure is constructed according to the size and the position of the information source area of each layer of graph nodes.
As shown in fig. 3, after the initialization mode of each graph node in each layer is determined, a three-layer three-dimensional structure is constructed according to the size and the position of the information source area of each graph node in each layer.
Specifically, the first layer of the three-layer three-dimensional structure has only 1 graph node, the second layer has 4 graph nodes, and the third layer has 9 graph nodes, wherein the graph nodes in each layer are arranged according to the positions of the information acquisition regions in the original feature map, for example, in the second layer, the information is from the upper left, the upper right, the lower left, and the lower right 4 graph nodes are sequentially placed on the upper left, the upper right, the lower left, and the lower right of the second layer; further, according to the spatial relationship of the second-layer graph nodes, the connection between the graph nodes is divided into two parts: the first part is the connection between the nodes of the graph in the same layer (the connection between the nodes of the graph with the same size of the information source area), specifically adopts an edge overlapping information extraction mode, and establishes the connection according to the coverage relation, so the connection between the nodes of the graph in the same layer is the connection between two adjacent graph nodes in a spatial relation (including the connection between the upper, lower, left and right sides and the adjacent bevel edge); the second part is the connection between different layer graph nodes, and the connection between different layer graph nodes refers to the connection rule between the same layer graph nodes, which specifically comprises the following steps: in this embodiment, each graph node is shown to be connected to all graph nodes on the upper and lower layers.
S2035, according to the three-layer characteristic matrix, reforming to obtain an adjacent matrix in the graph convolution network.
After obtaining the initialization parameters of each layer of graph nodes, sequentially arranging the three layers of feature matrices, and obtaining the graph node initialization parameters of the whole Graph Convolution Network (GCN) in a mode of recombining the three layers of feature matrices into an adjacent matrix, wherein the specific formula is as follows:
A=Ψ(fmatrix-1,fmatrix-2,fmatrix-3)
wherein A represents an adjacency matrix in a graph convolution network, Ψ represents a method of reforming a feature matrix, and fmatrix-1,fmatrix-2,fmatrix-3Respectively representing the feature matrixes extracted from the three levels.
The initialization parameters of each graph node in this embodiment are the size and the position of the information source area of each graph node.
S2036, based on the adjacent matrix in the graph convolution network, using a layer of graph convolution layer in the graph convolution network to perform information interactive fusion.
Based on the adjacency matrix obtained in step S2035, only one layer of graph convolution layer in the graph convolution network is used to perform information interaction fusion on the adjacent graph nodes in the graph convolution network, and the specific formula is as follows:
Figure BDA0003562194530000071
wherein the content of the first and second substances,
Figure BDA0003562194530000072
a represents an adjacency matrix in the graph convolution network, X represents a feature matrix composed of feature vectors of all graph nodes, and W represents the weight of the graph convolution network.
The adjacent graph nodes in this embodiment include the adjacent graph nodes on the same layer and the graph nodes connected on different layers.
In the embodiment, in order to avoid adding excessive parameters, only one layer of graph convolution layer is used for information interaction fusion; the graph convolution network after information interaction fusion can identify more characteristic information.
S204, classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
After the cattle face image passes through the steps S201-S203, firstly, extracting a reconstruction characteristic vector from each map node correspondingly, extracting 1 reconstruction characteristic vector from the first layer, extracting 4 reconstruction characteristic vectors from the second layer, and extracting 9 reconstruction characteristic vectors from the third layer; secondly, in order to enable the total dimensionality of the feature vectors extracted from different layers to be close, the feature vectors extracted from each layer are mapped to another feature dimensionality through a full-connection layer, so that the feature vectors of the same layer are spliced to be close to 2048 dimensionality and used as a feature fusion mode; thirdly, classifying the fusion feature vectors obtained from each layer by using a full-connection layer to obtain classification scores of each layer, and adding the classification scores of each layer to obtain a final classification score; and finally, obtaining the identity corresponding to the current cow face according to the final classification score.
In this embodiment, the performance of the graph convolution network after information interaction fusion is performed is specifically as follows:
the performance test results are shown in table 1, the first column in the table represents the using method, and the second column in the table represents the accuracy of the cow face identification by the corresponding method. Baseline in the table represents a reference method, the accuracy rate is 94.256%, and layer1+ layer2+ layer3 in the table represents that the image convolution network after information interaction fusion is completed is used for recognizing the cow face image, and the accuracy rate is 97.342%. Therefore, the graph convolution network after information interaction and fusion is completed in the embodiment has excellent identification performance.
TABLE 1 Performance test results of graph convolution network after information interaction fusion
Figure BDA0003562194530000081
Those skilled in the art will appreciate that all or part of the steps in the method for implementing the above embodiments may be implemented by a program to instruct associated hardware, and the corresponding program may be stored in a computer-readable storage medium.
It should be noted that although the method operations of the above-described embodiments are depicted in the drawings in a particular order, this does not require or imply that these operations must be performed in this particular order, or that all of the illustrated operations must be performed, to achieve desirable results. Rather, the depicted steps may change the order of execution. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step execution, and/or one step broken down into multiple step executions.
Example 2:
as shown in fig. 4, the present embodiment provides a cow face recognition system based on a graph convolution network model, which includes an obtaining unit 401, a first feature extraction unit 402, a second feature extraction unit 403, and a classification unit 404, where the specific functions of each unit are as follows:
an acquisition unit 401 configured to acquire a cow face image;
a first feature extraction unit 402, configured to perform preliminary feature extraction on the cow face image by using a feature extraction network to obtain an original feature map;
a second feature extraction unit 403, configured to perform multi-scale and multi-level feature division and initialize nodes of a graph convolution network based on an original feature graph, and perform multi-scale and multi-level global-local information interaction by using the graph convolution network to implement further feature extraction;
and a classifying unit 404, configured to perform classification using the features subjected to global-local information interaction to obtain an identity corresponding to the current cow face.
The specific implementation of each unit in this embodiment may refer to embodiment 1, which is not described herein any more; it should be noted that the system provided in this embodiment is only illustrated by the division of the functional units, and in practical applications, the functions may be allocated to different functional units as needed to complete, that is, the internal structure is divided into different functional units to complete all or part of the functions described above.
Example 3:
as shown in fig. 5, the present embodiment provides a computer apparatus including a processor 502, a memory, an input device 503, a display device 504, and a network interface 505, which are connected by a system bus 501. Wherein, the processor 502 is used for providing calculation and control capability, the memory includes a nonvolatile storage medium 506 and an internal memory 507, the nonvolatile storage medium 506 stores an operating system, a computer program and a database, the internal memory 507 provides an environment for the operating system and the computer program in the nonvolatile storage medium 506 to run, and when the computer program is executed by the processor 502, the face recognition method of the above embodiment 1 is implemented as follows:
acquiring a cattle face image;
performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map;
based on the original feature map, carrying out multi-scale and multi-level feature division and initializing nodes of a graph convolution network, and carrying out multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction;
and classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
Example 4:
the present embodiment provides a storage medium, which is a computer-readable storage medium, and stores a computer program, and when the computer program is executed by a processor, the method for recognizing a cow face according to embodiment 1 is implemented as follows:
acquiring a cow face image;
performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map;
based on the original feature map, performing multi-scale and multi-level feature division and initializing nodes of a graph convolution network, and performing multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction;
and classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
In conclusion, the invention carries out multilevel and multi-scale global-local information interaction on the extracted original features through the graph convolution network, effectively fuses the global-local information of the cattle face image, and thus obviously improves the accuracy of cattle face identification.
The above description is only for the preferred embodiments of the present invention, but the protection scope of the present invention is not limited thereto, and any person skilled in the art can substitute or change the technical solution and the inventive concept of the present invention within the scope of the present invention.

Claims (10)

1. A cattle face identification method based on a graph convolution network model is characterized by comprising the following steps:
acquiring a cow face image;
performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map;
based on the original feature map, performing multi-scale and multi-level feature division and initializing nodes of a graph convolution network, and performing multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction;
and classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
2. The method according to claim 1, wherein the performing multi-scale and multi-level feature division and initializing nodes of a graph convolution network based on an original feature map, and performing multi-scale and multi-level global-local information interaction by using the graph convolution network specifically comprises:
constructing a graph with a three-layer structure based on the original characteristic graph, wherein the graph is used as a graph structure in a graph convolution network;
converting the original feature map into a three-layer feature matrix by using pooling operations of different sizes based on the three-layer structure map;
initializing graph nodes of corresponding layers by utilizing the three-layer characteristic matrix to obtain the size and the position of an information source area of each graph node of each layer;
constructing a three-layer three-dimensional structure according to the size and the position of the information source area of each layer of graph nodes;
reforming to obtain an adjacent matrix in the graph convolution network according to the three layers of characteristic matrices;
and performing information interaction fusion by using a layer of graph convolution layer in the graph convolution network based on the adjacent matrix in the graph convolution network.
3. The method of claim 2, wherein the graph based on the three-layer structure is obtained by converting the original feature graph into a three-layer feature matrix using different sizes of pooling operations, as follows:
fmatrix-i=φi(fI)
wherein f ismatrix-iThe feature matrix of the ith layer is represented, the size is n multiplied by m, n represents the number of graph nodes of the ith layer, m represents the number of channels of the original feature graph, fIRepresents the original characteristic diagram phiiIndicating that the ith layer uses a corresponding pooling operation from fIExtracting characteristic vectors and arranging the characteristic vectors into a characteristic matrix in sequence;
said ith layer pooling from f using a respective layer pooling operationIThe operation of extracting feature vectors and arranging the feature vectors into a feature matrix in sequence specifically comprises the following steps:
extracting an i multiplied by C characteristic map from the original characteristic map by using a corresponding pooling kernel;
and (3) recombining the i multiplied by C characteristic diagrams into a characteristic matrix of i multiplied by i rows and C columns, wherein i represents the corresponding layer number, and C represents the channel number of the original characteristic diagram.
4. The cattle face identification method according to claim 2, wherein the three-layer three-dimensional structure has a first layer having one graph node, a second layer having four graph nodes, and a third layer having nine graph nodes;
the graph nodes in each layer are arranged according to the positions of the acquired information areas in the original characteristic graph; and the adjacent graph nodes on the same layer and the adjacent graph nodes on different layers all adopt an information extraction mode of edge overlapping, and establish connection according to the coverage relation.
5. The method according to claim 2, wherein the adjacent matrix in the graph convolution network is obtained by reforming according to the three-layer feature matrix, and the following formula is:
A=Ψ(fmatrix-1,fmatrix-2,fmatrix-3)
wherein A represents an adjacency matrix in a graph convolution network, Ψ represents a method of reforming a feature matrix, and fmatrix-1,fmatrix-2,fmatrix-3Respectively representing the feature matrixes extracted from the three levels.
6. The method according to claim 2, wherein the information interaction fusion is performed by using a layer of graph convolution layer in the graph convolution network based on the adjacency matrix in the graph convolution network, as follows:
Figure FDA0003562194520000021
wherein, the first and the second end of the pipe are connected with each other,
Figure FDA0003562194520000022
a represents an adjacency matrix in the graph convolution network, X represents a feature matrix composed of feature vectors of all graph nodes, and W represents the weight of the graph convolution network.
7. The bovine face identification method according to any one of claims 1 to 6, wherein the feature extraction network selects the top 41 layers of ResNet 50;
the method comprises the following steps of performing initial feature extraction on a cattle face image by using a feature extraction network to obtain an original feature map, wherein the method specifically comprises the following steps:
inputting the cattle face image into a feature extraction network to obtain an original feature map with the size of W multiplied by H multiplied by C, wherein W represents the width, H represents the height and C represents the number of channels.
8. A cattle face identification system based on a graph convolution network model, which is characterized by comprising:
an acquisition unit configured to acquire a cow face image;
the first feature extraction unit is used for performing primary feature extraction on the cattle face image by using a feature extraction network to obtain an original feature map;
the second feature extraction unit is used for carrying out multi-scale and multi-level feature division and initializing nodes of the graph convolution network based on the original feature graph, and carrying out multi-scale and multi-level global-local information interaction by utilizing the graph convolution network to realize further feature extraction;
and the classification unit is used for classifying by using the characteristics subjected to global-local information interaction to obtain the identity corresponding to the current cow face.
9. A computer device comprising a processor and a memory for storing a program executable by the processor, wherein the processor, when executing the program stored in the memory, implements the bovine face identification method of any one of claims 1-7.
10. A storage medium storing a program, wherein the program, when executed by a processor, implements the bovine face identification method according to any one of claims 1 to 7.
CN202210292944.5A 2022-03-24 2022-03-24 Cattle face identification method, system, equipment and medium based on graph convolution network model Pending CN114743215A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210292944.5A CN114743215A (en) 2022-03-24 2022-03-24 Cattle face identification method, system, equipment and medium based on graph convolution network model

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210292944.5A CN114743215A (en) 2022-03-24 2022-03-24 Cattle face identification method, system, equipment and medium based on graph convolution network model

Publications (1)

Publication Number Publication Date
CN114743215A true CN114743215A (en) 2022-07-12

Family

ID=82278030

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210292944.5A Pending CN114743215A (en) 2022-03-24 2022-03-24 Cattle face identification method, system, equipment and medium based on graph convolution network model

Country Status (1)

Country Link
CN (1) CN114743215A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116403004A (en) * 2023-06-07 2023-07-07 长春大学 Cow face fusion feature extraction method based on cow face correction

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116403004A (en) * 2023-06-07 2023-07-07 长春大学 Cow face fusion feature extraction method based on cow face correction
CN116403004B (en) * 2023-06-07 2024-01-26 长春大学 Cow face fusion feature extraction method based on cow face correction

Similar Documents

Publication Publication Date Title
Johnson et al. Densecap: Fully convolutional localization networks for dense captioning
CN111310707B (en) Bone-based graph annotation meaning network action recognition method and system
CN110348330B (en) Face pose virtual view generation method based on VAE-ACGAN
Li et al. Group-wise deep object co-segmentation with co-attention recurrent neural network
CN111429460B (en) Image segmentation method, image segmentation model training method, device and storage medium
CN107818314B (en) Face image processing method, device and server
WO2023185785A1 (en) Image processing method, model training method, and related apparatuses
JP2021507394A (en) How to generate a human hairstyle based on multi-feature search and deformation
CN107886474B (en) Image processing method, device and server
CN111696028A (en) Method and device for processing cartoon of real scene image, computer equipment and storage medium
CN111652974A (en) Method, device and equipment for constructing three-dimensional face model and storage medium
CN111553267A (en) Image processing method, image processing model training method and device
CN113570684A (en) Image processing method, image processing device, computer equipment and storage medium
Wu et al. DSN: A new deformable subnetwork for object detection
CN111108508B (en) Face emotion recognition method, intelligent device and computer readable storage medium
Zhang et al. Detail-preserving cyclegan-adain framework for image-to-ink painting translation
Gonçalves et al. Carcass image segmentation using CNN-based methods
US20230360256A1 (en) Contextual instance decoupling-based multi-person pose estimation method and apparatus
CN114897136A (en) Multi-scale attention mechanism method and module and image processing method and device
CN114743215A (en) Cattle face identification method, system, equipment and medium based on graph convolution network model
CN111444313A (en) Knowledge graph-based question and answer method and device, computer equipment and storage medium
CN111091055A (en) Face shape recognition method, device, equipment and computer readable storage medium
CN114764870A (en) Object positioning model processing method, object positioning device and computer equipment
CN112132281A (en) Model training method, device, server and medium based on artificial intelligence
Ke et al. SRN: Side-output residual network for object reflection symmetry detection and beyond

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination