Early lifespan prediction in Caenorhabditis elegans via contrastive learning and channel attention

Miaomiao Jin, Weiyang Chen, Yi Pan

Published: 01 Dec 2025, Last Modified: 26 Jan 2026Journal of Bioinformatics and Computational BiologyEveryoneRevisionsCC BY-SA 4.0
Abstract: Early lifespan prediction in Caenorhabditis elegans faces the challenges of indistinct discriminative signals, subtle and localized key features, difficulty in data annotation, and poor generalization. We propose Contrastive Learning-guided Channel Attention Modulation (CLCAM), in which supervised contrastive learning clusters individuals with the same lifespan and separates different classes. The resulting embedding drives channel-wise gains that are additively coupled to the backbone, thereby amplifying subtle morphological cues. At inference, the contrastive branch is removed, keeping FLOPs essentially unchanged with a modest runtime cost on our hardware. On a public dataset, CLCAM achieves an AUC-ROC of 0.84, showing a consistent improvement over the EfficientNet-B3 baseline (0.82) and a substantial gain over the prior WormNet model (0.61). Grad-CAM indicates attention focused on the pharynx and body-wall musculature, supporting the biological plausibility of the model’s decisions. CLCAM offers a clear, low-overhead paradigm for early lifespan phenotyping. CLCAM code is available at https://github.com/JMM502/CLCAM/tree/master/clcam.
Loading