Investigating Contrastive Learning for Conditional Variational Autoencoders in Network Intrusion Detection
Applied Sciences · 21.08.2026 · 16 (16) · 8323
DOI: 10.3390/app16168323 ↗Kurz gefasst
Fachartikel in der Zeitschrift Applied Sciences, online erschienen am 21.08.2026. Verfasst von Huy Minh Dinh und 3 weiteren Autor:innen. Die Arbeit nennt 44 Literaturangaben. Der Volltext ist frei zugänglich (Open Access, CC BY 4.0).
Abstract (Originalsprache)
Class imbalance, where majority-class samples vastly outnumber minority-class samples, remains a persistent challenge in network intrusion detection systems (NIDS), often causing classifiers to overlook rare but critical attack types while yielding misleadingly optimistic performance metrics. Synthetic data generation is a common mitigation strategy. However, existing methods often fail to capture the non-linear network traffic and neglect inter-class relationships with the majority class, resulting in inconsistent performance gains. This study investigates three contrastive learning loss functions, Contrastive Loss, Soft Nearest Neighbor Loss, and Supervised Contrastive Loss, integrated into a Conditional Variational Autoencoder (CVAE) regularised via the standard Kullback-Leibler divergence objective. Experiments were conducted on four widely used NIDS benchmark datasets (NSL-KDD, UNSW-NB15, CIC-IDS2017, and CSE-CIC-IDS2018), with synthetic data evaluated using four machine learning classifiers against the original imbalanced data, a non-contrastive CVAE, and conventional oversampling approaches. The results show that the effectiveness of integrating contrastive learning into the CVAE framework is dependent on the specific dataset, minority class, contrastive loss function, and distance metric, with the proposed approach outperforming traditional oversampling techniques in several settings without degrading majority-class performance or overall accuracy. These findings provide practical guidance for selecting contrastive learning objectives in class-imbalanced NIDS scenarios.
Zitieren
APA
Dinh, H. M., Zong, W., Chow, Y., & Susilo, W. (2026). Investigating Contrastive Learning for Conditional Variational Autoencoders in Network Intrusion Detection. Applied Sciences, 16(16), 8323. https://doi.org/10.3390/app16168323
Vancouver
Dinh HM, Zong W, Chow Y, Susilo W. Investigating Contrastive Learning for Conditional Variational Autoencoders in Network Intrusion Detection. Applied Sciences. 2026;16(16):8323. doi:10.3390/app16168323
BibTeX
@article{Dinh2026,
author = {Dinh, Huy Minh and Zong, Wei and Chow, Yang-Wai and Susilo, Willy},
title = {Investigating Contrastive Learning for Conditional Variational Autoencoders in Network Intrusion Detection},
journal = {Applied Sciences},
year = {2026},
volume = {16},
number = {16},
pages = {8323},
doi = {10.3390/app16168323}
}
EUVIMED