With the development of science technology and the progress of society,the demand for identity recognition is more and more extensive.And for identity recognition,the current mainstream solution is facial recognition.At present,face recognition technology has matured day by day,and its related applications have also tended to be complete,while there are relatively few studies on animal face recognition.Animal facial recognition has a wide range of needs in agriculture,and as pigs are currently the most widely farmed animals,their facial recognition has naturally become a hot issue in this field.The overall similarity of the pig faces is high,and because the pig faces are always not clean,their facial features will also be affected.Therefore,the pig face is a difficult problem to solve in the recognition of animal faces.Pig face recognition has great application prospects in intelligent pig raising and agricultural insurance.Facing a large amount of pig data,a method with good generalization and high precision is required for pig face recognition.In this paper,exploratory research is carried out for the difficulty of pig face facial recognition.Deep learning technology learns the rules and representation levels in the data set,and the learned content is helpful for the model to recognize images,audio and other data.The idea of deep learning has once again promoted the development of convolutional neural networks.Convolutional neural networks based on deep learning ideas can also be called deep convolutional neural networks.Deep convolutional neural networks have a wide range of applications in face recognition,so it is a reasonable choice to use deep neural networks to solve pig face recognition.The main work of this paper can be divided into four parts:1.Cooperating with local farms to collect pig face data,organizing and preparing a set of pig face feature point detection data set and a set of pig face recognition data set.The pig face feature point data set comes from 206 pigs with a scale of 6099.The pig face recognition dataset comes from 77 pigs with a scale of 7622;2.A method of pig face feature points detection based on convolutional neural network is proposed.First,the pig face data is collected and the feature points are marked,and a new collection method is used to solve the problem that the pig’s mouth is usually invisible.Further structure calculation is performed on pig face data and human face data,and pig faces and human faces with high similarity are matched to construct a pig face and face matching data set;after that,use the matching dataset to train TPS(Thin Plate Spline)deformed convolutional neural network,and obtain the deformed pig face dataset to suit the detection of facial feature points model;finally,use the deformed pig face dataset to fine-tune the facial feature point detection neural network model to obtain the pig face feature point detection model.The experiment results show that using this method to detect pig face feature points,the accuracy rate reaches 94.4%;3.A deep learning pig face recognition method based on keypoint information(DLPFK)is proposed,which uses the feature point information to process the image with attention mechanism,and uses the deep convolutional neural network model for pig face recognition to achieve the purpose of pig identity recognition.The specific method of the attention mechanism is to weaken the entire image and then strengthen the pixels around the feature points,so that the network can focus on the foreground,that is,the pig face,so as to alleviate the problem of similar image backgrounds in the process of pig face recognition.The parameters suitable for the attention mechanism formula are determined through several experiments;4.The deep convolutional neural network framework for pig face recognition is implemented.First,a number of advanced neural networks are selected for benchmarking,that is,the neural network is directly used for recognition,and the best networks are selected,and then these networks are tested.Using the DLPFK method proposed in this paper to conduct experiments,the best recognition accuracy rate of94.7% is achieved on the Xception neural network,which is 4.2% higher than the accuracy rate of 90.5% using the Xception neural network alone,and the best performance in the benchmark test.The accuracy of the good Inception-ResNe-V2 neural network is 90.9% higher than that of 3.8%. |