1.College of Artificial Intelligence/Key Laboratory of Breeding Equipment of Ministry of Agriculture and Rural Affairs,Nanjing Agricultural University,Nanjing 210031,China
2.Agricultural Technology Promotion Center in Haimen District,Nantong 226199,China
To solve the problems of high difficulty and poor real-time detection of traditional cage chicken vocalization, this paper proposes a chicken vocalization detection algorithm based on lightweight TransformerCNN. Firstly, by introducing the EfficientViT lightweight network to replace the original backbone network, the number of parameters and computational complexity are reduced, and the real-time performance of network algorithm detection is improved; Secondly, replacing ReLU with Hardswift activation function can improve the recognition accuracy of the model without adding additional weights and bias parameters. Finally, by combining linear self-attention mechanism instead of traditional Softmax operation, the model's ability to capture chicken vocalization features is further enhanced, improving the robustness of detection. The results show that: 1) Compared with the basic TransformerCNN model, the introduction of EfficientViT, linear self-attention, and Hardswift activation function significantly improves the inference speed and computational complexity of the model. Although the average accuracy slightly decreases, it performs better in real-time performance and lightweight nature. 2) Compared with other lightweight backbone networks, EfficientViT has significant advantages in inference speed, computational complexity, and model storage requirements, making it suitable for real-time audio classification tasks.3) Compared with mainstream audio classification models, TC+EfficientViT has improved detection accuracy, real-time performance, and model size, which can better meet the requirements of efficient and real-time deployment. In conclusion, in the intelligent welfare breeding environment, through contactless detection of chicken vocalization, a database of vocalizations in cage chicken populations can be established, providing key data for further analysis of chicken health status.
在声音降噪后,需要做连续的加窗、分帧处理,再提取每一帧的声音特征参数作为模型输入。在特征参数的选取上,由于呼吸道疾病、热应激等异常情况会对家禽声道造成破坏性影响,从而影响它们的呼吸行为和发声特征,并且会增加某些频率(谐波)的强度,抑制了其他频率。基于此,选择梅尔子带的能量分布(Energy of mel sub bands, MFENs)、梅尔频率倒谱系数(Mel-frequency cepstral coefficients, MFCCs)等可以反映鸡只声音谐波的特征。其中,梅尔子带能量分布与MFCCs的区别如图3所示,在MFCCs的计算中,取对数的目的是考虑非线性尺度上的能量分布,离散傅里叶变换的目的是对能量带之间进行去相关操作,但是在笼养鸡场环境下,即便经过降噪处理,音频中仍然含有部分噪声,因此,上述两步计算会降低系统性能。综上,梅尔子带能量分布从理论上比MFCCs更能表现鸡只不同发声[17-18]。
XinX F, ZhengM Q, WenJ, WangJ M. Situation analysis, future prospect, and countermeasures of China’s broiler industry in China in 2023 [J]. Chinese Journal of Animal Husbandry, 2024, 60(3): 312-317 (in Chinese)
[5]
CarrollB T, AndersonD V, DaleyW, HarbertS, BrittonD F, JackwoodM W. Detecting symptoms of diseases in poultry through audio signal processing[C].In:2014 IEEE Global Conference on Signal and Information Processing (GlobalSIP).Atlanta:IEEE, 2014: 1132-1135
[6]
RizwanM, CarrollB T, AndersonD V, DaleyW, HarbertS, BrittonD F, JackwoodM W. Identifying rale sounds in chickens using audio signals for early disease detection in poultry[C]. In:2016 IEEE Global Conference on Signal and Information Processing (GlobalSIP).Washington: IEEE, 2016: 55-59
[7]
MahdavianA, MinaeiS, MarchettoP M, AlmasganjF, RahimiS, YangC. Acoustic features of vocalization signal in poultry health monitoring[J]. Applied Acoustics, 2021, 175: 107756
YuanC, ShenM X, YaoW, LiuL S, ChenJ. Detection method for whole-life cycle cough of white-feathered broiler based on vocalization characteristics and deep learning [J]. Journal of Nanjing Agricultural University, 2023, 46(5): 975-985 (in Chinese)
[10]
CuanK X, ZhangT M, HuangJ D, FangC, GuanY. Detection of avian influenza-infected chickens based on a chicken sound convolutional neural network[J]. Computers and Electronics in Agriculture, 2020, 178: 105688
SunZ G, ZhangM, LiuJ G, WangJ Q, WuQ Y, WangG T. Research on white feather broiler health monitoring method based on sound detection and transfer learning[J]. Computers and Electronics in Agriculture, 2023, 214: 108319
[13]
CarpentierL, BerckmansD, YoussefA, BerckmansD, van WaterschootT, JohnstonD, FergusonN, EarleyB, FontanaI, TulloE, GuarinoM, VrankenE, NortonT. Automatic cough detection for bovine respiratory disease in a calf house[J]. Biosystems Engineering, 2018, 173: 45-56
WangK Y, ZhaoX Y, HeY. Review on noninvasive monitoring technology of poultry behavior andphysiological information[J]. Transactions of the Chinese Society of Agricultural Engineering, 2017, 33(20): 197-209 (in Chinese)
[16]
InouyeJ M, BlemkerS S, InouyeD I. Towards undistorted and noise-free speech in an MRI scanner: Correlation subtraction followed by spectral noise gating [J]. The Journal of the Acoustical Society of America, 2014, 135(3): 1019-1022
[17]
van MaerckeD, SalomonsE. The Harmonoise sound propagation model: further developments and comparison with other models[J]. Proceedings NAG-DAGA conference, Rotterdam, The Netherlands. 2009
[18]
HillE M, KoayG, HeffnerR S, HeffnerH E. Audiogram of the chicken (gallus gallus domesticus) from 2 Hz to 9 kHz [J]. Journal of Comparative Physiology A, 2014, 200(10): 863-870
[19]
ManningL, ChaddS A, BainesR N. Key health and welfare indicators for broiler production[J]. World’s Poultry Science Journal. 2007, 63(1): 46-62
DuX D, TengG H, NortonT, WangC Y, LiuM L. Classification and recognition of laying hens’ vocalization based on texture features of spectrogram [J]. Transactions of the Chinese Society of Agricultural Machinery, 2019, 50(9): 215-220 (in Chinese)
[22]
LiL, DoroslovačkiM, LoewM H. Approximating the gradient of cross-entropy loss function[J]. IEEE Access, 2020, 8: 111626-111635
[23]
AydinA, BahrC, ViazziS, ExadaktylosV, BuyseJ, BerckmansD. A novel method to automatically measure the feed intake of broiler chickens by sound technology[J]. Computers and Electronics in Agriculture, 2014, 101: 17-23
[24]
LiuX Y, PengH W, ZhengN X, YangY Q, HuH, YuanY X. EfficientViT: Memory efficient vision transformer with cascaded group attention[C].In:CVF Conference on Computer Vision and Pattern Recognition (CVPR). Vancouver: IEEE, 2023: 14420-14430
[25]
CholletF. Xception: Deep learning with depthwise separable convolutions[C].In: Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR). Honolulu:IEEE,2017: 1251-1258
[26]
SunL J, WuC Y, ChingW K, AkutsuT. On the compressive power of autoencoders with linear and ReLU activation functions[J]. Neural Computation, 2025, 37(2): 235-259
[27]
KatharopoulosA, VyasA, PappasN, FleuretF. Transformers are RNNs: Fast autoregressive transformers with linear attention[C].In:Proceedings of the 37th International Conference on Machine Learning. Vienna: Proceedings of Machine Learning Research, 2020,199: 5156-5165
[28]
XiongY, ZengZ, ChakrabortyR, TanM, FungG, LiY, SinghV. Nyströmformer: A nyström-based algorithm for approximating self-attention [J]. Proceedings of the AAAI Conference on Artificial Intelligence, 2021, 35(16): 14138-14148