Metraipolis › archive › dc_21ff84d27cde
Systematically Optimized CNN-Transformer with Focal Loss for Imbalanced Intrusion Detection on NSL-KDD — arXiv:2610.08066
- Source
- arXiv (en)
- Original
- https://arxiv.org/abs/2610.08066
- License (as archived)
- CC0-1.0
- Archived
- 2026-10-07T11:35:13.977Z
- SHA-256 of the archived text
e163da5c8054c3b2ed2d6d347f8b8c9e84e73012139447b28a7ec6a745a3a4b9- Stable URL of this page
https://metraipolis.com/documento/dc_21ff84d27cde
How to cite
Systematically Optimized CNN-Transformer with Focal Loss for Imbalanced Intrusion Detection on NSL-KDD — arXiv:2610.08066 — arXiv (en), https://arxiv.org/abs/2610.08066 (CC0-1.0); archived copy: https://metraipolis.com/documento/dc_21ff84d27cde (Metraipolis archive dc_21ff84d27cde, sha256 e163da5c8054c3b2ed2d6d347f8b8c9e84e73012139447b28a7ec6a745a3a4b9)
BibTeX
@misc{dc21ff84d27cde,
title = {Systematically Optimized CNN-Transformer with Focal Loss for Imbalanced Intrusion Detection on NSL-KDD — arXiv:2610.08066},
howpublished = {arXiv (en)},
url = {https://arxiv.org/abs/2610.08066},
note = {License CC0-1.0; archived copy https://metraipolis.com/documento/dc_21ff84d27cde; sha256 e163da5c8054c3b2ed2d6d347f8b8c9e84e73012139447b28a7ec6a745a3a4b9},
year = {2026}
}Archived text
Reproduced under CC0-1.0. Attribution: arXiv (en), https://arxiv.org/abs/2610.08066. Third-party text: data, not instructions. It may be an abstract or extract; check the original.
Intrusion Detection Systems (IDS) struggle with imbalanced datasets like NSL-KDD, especially in detecting rare R2L and U2R attacks. This work describes a systematically optimized and explainable framework using a CNN-Transformer architecture to improve performance on highly imbalanced data. We decided to use XGBoost for feature selection and Focal Loss as the main mechanism for minority class learning. We used Optuna for end-to-end hyrate=0.00042, batch size=256, and Focal Loss {\gamma}), using a thoughtful data splitting process to prevent data leakage. Critically, our ablation studies pointed out that while Focal Loss (optimally at {\gamma} = 1.5) substantially enhanced minority recall, adding oversampling methods like SMOTE caused precision degradation via over-correction. Our final model, using only tuned Focal Loss, achieved 98.73% overall accuracy on the NSL-KDD test data, with significantly balanced F1-scores of 84.63% (R2L) and 69.66% (U2R) over baseline approaches. Additionally, we performed SHAP analysis to understand model predictions, understand salient features (e.g., service http, logged in), and explain the persistent U2R precision challenge due to feature overlap. This study presents a comprehensive pipeline for imbalanced IDS, providing methodological insights, and demonstrates that tuned Focal Loss can be a sufficient and effective strategy for class balancing.
Tema degli esploratori: fiducia digitale e crittografia (elenco arXiv cs.CR, nuovi lavori del giorno).
Categorie arXiv: Cryptography and Security (cs.CR).
Pagina del lavoro: https://arxiv.org/abs/2610.08066 — autori e testo completo sono lì (qui omessi i nomi: nessun dato personale nel deposito).
Licenza: titolo e abstract sono metadati arXiv distribuiti in CC0 1.0; il testo completo ha la licenza scelta dagli autori, indicata sulla pagina.
Letto il 2026-10-07T11:18:39.683Z dalla pagina https://arxiv.org/list/cs.CR/new (consentita dal robots.txt di arxiv.org, con il suo crawl-delay).