Netmamba+ Achieves 1.7x Faster, Accurate Network Traffic Classification

Accurate network traffic classification is increasingly vital for maintaining network security and quality of service, yet current methods struggle with computational demands, biased data and real-world traffic distributions. Tongze Wang, Xiaohui Xie, and Wenduo Wang, from Tsinghua University, alongside colleagues including Chuyi Wang, Jinzhou Liu and Boyan Huang, present NetMamba+, a novel framework designed to overcome these limitations. Their research introduces an efficient architecture leveraging Mamba and Flash, a multimodal traffic representation scheme and a label distribution-aware fine-tuning strategy, achieving up to a 6.44% improvement in F1 score over existing state-of-the-art approaches. Significantly, NetMamba+ also demonstrates enhanced efficiency and few-shot learning capabilities, representing the first adaptation of the Mamba architecture to network traffic classification and paving the way for more robust and scalable traffic analysis systems.

NetMamba+ tackles traffic classification inefficiencies and biases

Scientists have developed NetMamba+, a new framework addressing critical challenges in network traffic classification, a field essential for network security and quality of service management. The research tackles the computational inefficiency of Transformer architectures, inadequate traffic representations that lose crucial data while retaining biases, and the difficulties of handling long-tail distributions common in real-world network data. This work introduces three key innovations: an efficient architecture leveraging Mamba and Flash Attention mechanisms, a multimodal traffic representation scheme designed to preserve essential information and eliminate biases, and a label distribution-aware fine-tuning strategy to optimise performance with imbalanced datasets. Evaluation experiments utilising extensive datasets across four classification tasks demonstrate NetMamba+’s superior performance, achieving F1 score improvements of up to 6.44% compared to current state-of-the-art methods.

The team achieved this breakthrough by moving away from traditional Transformer architectures, which suffer from quadratic computational complexity, and instead adopting Mamba, a linear-time state space model. Through careful experimentation, researchers determined that a unidirectional Mamba configuration with residual connections was optimally suited for efficiently learning patterns within sequential network traffic data. Alternatively, the study also explored integrating Flash Attention into a vanilla Transformer to accelerate attention mechanisms using IO-aware techniques, further enhancing efficiency. This architectural shift significantly reduces computational and memory demands, making real-time online traffic classification feasible even on network devices with limited resources.

The research establishes a foundation for more scalable and efficient network analysis tools. Furthermore, the study unveils a novel multimodal traffic representation scheme that captures both header and payload information, alongside critical transmission patterns. To mitigate biases and improve accuracy, the researchers implemented techniques such as packet anonymisation, byte allocation balancing, and stride-based data cutting. This comprehensive approach ensures that essential traffic characteristics are preserved while minimising the influence of potentially misleading data. The resulting representation provides a more robust and reliable foundation for accurate traffic classification, particularly in complex network environments.

This detailed approach to data representation is a significant contribution to the field. Experiments demonstrate that NetMamba+ not only achieves superior classification accuracy but also exhibits excellent efficiency, delivering 1.7x higher inference throughput than the best baseline while maintaining comparable memory usage. The framework also showcases strong few-shot learning capabilities, achieving better performance with fewer labelled data points. An implemented online traffic classification system further validates the framework’s robustness, achieving a throughput of 261.87 Mb/s. As the first framework to adapt the Mamba architecture for network traffic classification, NetMamba+ opens new possibilities for efficient and accurate traffic analysis, paving the way for more secure and reliable network infrastructure.

NetMamba+ architecture for traffic classification shows promising results

Scientists developed NetMamba+, a novel framework addressing critical challenges in encrypted network traffic classification, namely computational inefficiency, inadequate traffic representations, and poor handling of long-tail data distributions. The research team engineered an efficient architecture leveraging either Mamba or FlashAttention as a backbone, replacing the computationally expensive Transformer architecture typically used in traffic analysis. Specifically, they implemented a unidirectional Mamba variant with residual connections, omitting omnidirectional scans and redundant blocks to optimise performance for sequential network traffic data. Alternatively, the team integrated FlashAttention into a vanilla Transformer, employing pre-normalisation and a GeGLU-activated feedforward network to improve stability and accuracy respectively.

To achieve comprehensive traffic representation, researchers designed a multimodal scheme capturing both header and payload packet content, alongside critical transmission patterns. This involved techniques such as packet anonymisation, byte allocation balancing, and stride-based data cutting to mitigate biases and enhance classification performance. The study pioneered a label distribution-aware fine-tuning strategy to counteract the effects of long-tailed distributions common in real-world traffic data. This strategy assigns higher weights and enforces larger margins for minority classes, improving performance on imbalanced datasets.

Experiments employed extensive datasets for four main classification tasks, demonstrating NetMamba+’s superior performance. The system delivers an F1 score improvement of up to 6.44% compared to state-of-the-art baselines. Furthermore, NetMamba+ achieves 1.7x higher inference throughput than the best baseline, while maintaining comparable memory usage. The team harnessed self-supervised pre-training on large unlabeled datasets, reconstructing masked strides, zeroed packet sizes, and zeroed inter-arrival times to learn generic traffic representations. Finally, an online traffic classification system was implemented, achieving a robust throughput of 261.87 Mb/s, validating the framework’s real-world applicability and efficiency. This work establishes NetMamba+ as the first framework adapting the Mamba architecture for network traffic classification, opening new avenues for efficient and accurate traffic analysis in complex network environments.

NetMamba+ boosts traffic classification speed and accuracy significantly

Scientists have developed NetMamba+, a new framework for network traffic classification that addresses limitations in computational efficiency, traffic representation, and handling of imbalanced datasets. Experiments revealed that NetMamba+ achieves an improvement of up to 6.44% in F1 score compared to state-of-the-art baseline models across four main classification tasks. The team measured a significant increase in inference throughput, with NetMamba+ delivering 1.7x faster performance than the best existing baseline while maintaining comparable memory usage. Researchers designed NetMamba+ with an efficient architecture leveraging either Mamba or Flash Attention, replacing traditional Transformer architectures to overcome quadratic self-attention limitations.

Tests prove that the unidirectional Mamba configuration, equipped with a residual connection, is particularly well-suited for learning patterns within sequential network traffic data. Furthermore, the study implemented a multimodal traffic representation scheme, preserving crucial information from packet headers and payloads while actively mitigating biases through techniques like packet anonymization and balanced byte allocation. Data shows that NetMamba+ excels in few-shot learning scenarios, achieving superior classification performance even with limited labeled data. The breakthrough delivers a novel label distribution-aware fine-tuning strategy, assigning higher weights to minority classes to counteract the effects of long-tailed distributions commonly found in real-world traffic data.

Specifically, the team extracted multimodal flow features and performed self-supervised pre-training on large unlabeled datasets, reconstructing masked strides, zeroed packet sizes, and zeroed inter-arrival times to learn generic traffic representations. Measurements confirm that the implemented online traffic classification system, powered by NetMamba+, achieves a robust throughput of 261.87 Mb/s, demonstrating its practical viability for real-world deployment. In out-of-distribution tasks, NetMamba+ consistently achieved AUROC scores exceeding 94%. This work, as the first to adapt the Mamba architecture for network traffic classification, opens new possibilities for efficient and accurate traffic analysis in complex network environments and enhances user experience and network management capabilities.

👉 More information
🗞 NetMamba+: A Framework of Pre-trained Models for Efficient and Accurate Network Traffic Classification
🧠 ArXiv: https://arxiv.org/abs/2601.21792

Rohail T.

Rohail T.

As a quantum scientist exploring the frontiers of physics and technology. My work focuses on uncovering how quantum mechanics, computing, and emerging technologies are transforming our understanding of reality. I share research-driven insights that make complex ideas in quantum science clear, engaging, and relevant to the modern world.

Latest Posts by Rohail T.:

Ueval Benchmark Achieves Robust Multimodal Generation Evaluation with 1,000 Expert Questions

Ueval Benchmark Achieves Robust Multimodal Generation Evaluation with 1,000 Expert Questions

January 31, 2026
Low-Compute AI Models Pose Big Threats, Profiling over 5,000 Instances

Low-Compute AI Models Pose Big Threats, Profiling over 5,000 Instances

January 31, 2026
Stimulated Magnonic Frequency Combs Achieve Efficient Control over Spectral Line Number

Stimulated Magnonic Frequency Combs Achieve Efficient Control over Spectral Line Number

January 31, 2026