| Automating the measurement of pig body temperature is beneficial to real-time monitoring of the health status of pigs,sow estrus and ovulation testing.Infrared thermal imaging technology was used to collect the infrared thermal image of pigs.The chemometric modeling method was used to establish the multivariate calibration model between body surface temperature,ambient temperature and rectal temperature.Two automatic detection methods for key temperature measurement parts were proposed.The main conclusions were summarized as follows:(1)Univariate and multiple linear regression models were established between sow body surface temperature,ambient temperature and sow body temperature.The study found that the surface temperature extracted from the 9 body regions was positively correlated with the rectal temperature(r=0.34-0.68).Among them,the univariate regression equation based on the average surface temperature of the ear base region was the best,and the prediction set correlation coefficient R_P and the root mean square error RMSEP were 0.66 and 0.42°C,respectively.The full-featured model had a better predictive effect than the univariate linear regression equation,with R_P and RMSEP of 0.76 and 0.37°C,respectively.In addition,the application of the feature selection method LARS-Lasso determined 7 important features to establish a simplified model,which were 0.80 and 0.80 for the positive and predicted sets,respectively,and the RMSEs were 0.30 and 0.35°C,respectively.(2)The convolutional neural network was applied to the direct segmentation of the main temperature-measuring parts of the pig(eye and ear regions).Four different convolutional neural network models FCN-16s,FCN-8s,U-Net-3 and U-Net-4 were constructed using python.The performance of four convolutional neural network models was compared and analyzed.The results show that the U-Net-4 network structure has the best segmentation effect,and the average regional coincidence degree is 78.75%.However,when the computing power of the computing device is not enough,the U-Net-3 model can be selected to achieve a better segmentation effect.(3)The identification method of the key points in the eyes and ear bases of pigs was proposed,and the detection problem of the main temperature measurement parts of pigs was transformed into the positioning problem of the main temperature measurement parts.The convolutional neural network architectures A-E with different depths were designed to obtain the optimal architecture E.And when the Dropout probability was set to 0.6,the model worked best.The average error of the verification set and the average error of the prediction set were 1.96%and 2.65%,respectively.The prediction error of the key points of the test piece of the pig face was less than 5%and 10%,respectively,which were 89.5%and 97.4%.The model is able to locate the key points of the pig face well and can be used for the measurement of pig body temperature.In this paper,infrared thermography was used to measure the surface temperature of sows.The chemometric modeling provided a more accurate and reliable method for measuring the rectal temperature of non-contact sows.At the same time,two automatic detection methods for key temperature measurement parts were proposed which were helpful to automate the measurement of sow body temperature and provide reference for pig health management. |