Recognition of individual pigs is critical to the monitoring of pig body size and physiological health status in large-scale pig farms. In this study, deep learning methods were introduced in the intelligent recognition and segmentation of individual replacement pigs, which can realize the non-contact surveillance of each pig. Swin Transformer was used for the recognition and segmentation of individual pigs based on the surveillance data, and different models were compared to find the model with the fastest training speed and most accurate results. Finally, a recognition accuracy of 93.0% and segmentation accuracy of 86.9% for individual pigs were achieved with the surveillance video images of pigs based on Swin Transformer. Even in some complex scenarios such as overlapping, occlusion, and deformation, the method still exhibited excellent recognition performance for replacement pigs. Importantly, this method can greatly save labor as well as help intelligent and unmanned pig production and facilitate the modernization of pig industry.
Of past years, wearing masks has turned into a necessity in daily life due to the rampant new coronavirus and the increasing importance people place on health and life safety. However, current mask detection algorithms are difficult to run on low-computing-power hardware platforms and have low accuracy. To resolve this discrepancy, a lightweight mask inspection algorithm ECGYOLO based on improved YOLOv7tiny is proposed. This algorithm uses GhostNet to replace the original convolutional layer with ECG module instead of ELAN module, which greatly improves the inspection efficiency and decreases the parameters of the model. In the meantime, the ECA (efficient channel attention) mechanism is led into the neck section to boost the feature fetch capability of the channel, and Mosaic and Mixup data enhancement techniques are adopted in training to obtain mask images under different viewpoints to improve the comprehensiveness and effectiveness of the model. Experiments show that the mAP (mean average precision) of the algorithm is raised by 4.4% to 92.75%, and the number of arguments is decreased by 1.14 M to 5.06M compared with the original YOLOv7tiny. ECGYOLO is more efficient than other algorithms at present and can meet the real-time and lightweight needs of mask detection.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.