Zhihui Liu, Wenhui Niu, Yuxi Le, Yinan Gong, Wenxuan Zhao, Tianchun Pu, Daicheng Han, Jiatao Ge, Hong Gu, Yongxin Zhang, Limin Feng
The aim of this study is to enhance the classification accuracy of mammalian hair scale images using deep learning techniques, particularly SimCLR (Simple Framework for Contrastive Learning of Visual Representations) pretraining with unlabeled data, providing reliable technical support for species identification. We created a mammalian scanning electron microscope image dataset of 9,953 valid images of 33 mammal species. Four segmentation models-U-Net, SegNet, DeepLabV3+, and Segment Anything Model (SAM)-were evaluated for performance. SAM achieved the highest segmentation accuracy overall, although minor errors were still observed in the delineation of scales with clearly defined edges. SimCLR was pretrained on 2 datasets: one containing all 33 species, and a subset of 25 species with over 200 images per species. These models achieved Top-1 accuracies of 94.64% and 94.40%, exceeding ResNet-50, EfficientNet_b0, and ViT-B/16 trained from scratch, comparable to transfer learning (pretrained on ImageNet) results of ResNet-50 and EfficientNet_b0, and superior to that of ViT-B/16. Score-CAM visualizations revealed that the network's attention was focused on image regions that correspond to the morphological features traditionally used for species identification, demonstrating strong biological interpretability. Additionally, t-SNE visualizations confirmed the model's ability to effectively distinguish between different species. Cosine distance-based clustering of species-specific scale features further highlighted interspecies similarity patterns and commonly misclassified species pairs. The results demonstrate that deep learning models, particularly with the integration of SimCLR pretraining, are highly effective in classifying mammalian hair scales, providing a reliable method for species identification.