DOI: 10.5281/zenodo.15608129
title: HotPig: a behavioural dataset of pigs under heat stress

description: The widespread use of videos in modern indoor livestock facilities coupled with the availability of efficient and low-cost computer vision  algorithms provides strong incentives for continuously monitoring farm animal behaviour. Deciphering how pigs behave when experiencing prolonged heat stress (HS) is particularly important for animal welfare, as it helps us to better understand how animals use various thermoregulation and heat dissipation mechanisms. This dataset includes the monitoring of continuous behavioural traits for 24 growing pigs first housed at thermoneutrality and then exposed to HS. The data can be used to illustrate the frequencies of specific behavioural traits (time budget) and their deviations due to heat stress, either on average or in animal-centred view (recurrence of patterns, etc.). Outputs can be used to perform behavioural patterns mining, behaviour clustering and modelling. An important effort was made to ensure consistency of the behavioural dataset, with comparison with readings of automatic feeders to decipher feededin visits vs. non-feeding visits. Further video processing algorithms may benefit from the training (labelled images) dataset, but also from the multiple annotation approach (postures and events). This dataset can be used to train any machine learning methods for behaviour prediction from videos in conventional growing pigs.  

Data were collected on 24 pigs that were video-monitored day and night under two contrasted conditions: thermoneutral (TN, 22°C) and HS (32°C). All pigs were housed individually and had free access to an automatic electronic feeder delivering pellets four times a day, and to water. Environmental conditions (temperature, humidity) in the room were recorded by sensors. After acquisition, videos were processed using YOLOv11, a real-time object detection algorithm  that uses a convolutional neural network (CNN), to extract the following behavioural traits: drinking, willingness to eat, lying down, standing up, moving around, curiosity towards the littermate housed in the neighbouring pen, and contact between the two animals (cuddling). A minute frequency sampling rate was applied (each minute correspond to 150 frames processed) for a continuous period of 16 days, spanning the two different thermal conditions (9 days on TN, 6 days on HS, 1 day back to TN). The algorithm was first trained thanks to manual video analysis labelling at the individual scale. Consistency with the automatic electronic feeder’s data (also provided) was thoroughly checked. The dataset allows quantitative criterion to be analysed to decipher inter-individual differences in animal behaviour and their dynamic adaptation to heat stress.
description: Data Description

·         “frames.zip” is the archive of a repository containing the training set (images in jpeg format, and their associated text files containing manual annotations in the YOLO format)

·         “weights.pt” is the resulting trained YOLO model we used to produce the dataset

·         “demo.mp4” is a sample video file with a prediction overlay

·         “series.zip” contains the 24 individual pigs’ time series, sampled on a 1 min rate, these series being:

◦         for each posture, the number of frames in which they were detected

◦         for each event, the number of frames in which they were detected

◦         the corresponding activity labels derived from postures and events 

◦         the mean food intake given by the automatic feeders’ outputs

The series included 23,040 lines (one per minute) representing 384 hours (16 days)