To addresse the problem of poor detection accuracy or even false detection of wildlife caused by rainy environment at night. In this paper, a wildlife target detection algorithm based on improved YOLOX-s network is proposed. Our algorithm comprises the MobileViT-Pooling module, the Dynamic Head module, and the Focal-IoU module.First, the MobileViT-Pooling module is introduced.It is based on the MobileViT attention mechanism, which uses a spatial pooling operator with no parameters as a token mixer module to reduce the number of network parameters. This module performs feature extraction on three feature layers of the backbone network output respectively, senses the global information and strengthens the weight of the effective information. Second, the Dynamic Head module is used on the downstream task of network detection, which fuses the information of scale sensing, spatial sensing, and task sensing and improves the representation ability of the target detection head. Lastly, the Focal idea is utilized to improve the IoU loss function, which balances the learning of high and low quality IoU for the network. Experimental results reveal that our algorithm achieves a notable performance boost with mAP@0.5 reaching 87.8% (an improvement of 7.9%) and mAP@0.5:0.95 reaching 62.0% (an improvement of 5.3%). This advancement significantly augments the night-time wildlife detection accuracy under rainy conditions, concurrently diminishing false detections in such challenging environments.