Discriminability-Aware Symmetric Bit-Wise Feature Encoding for Resource-Constrained IoT Traffic Classification
Abstract
Resource-constrained traffic classification requires mapping heterogeneous numerical features into a fixed-length binary input. Equal-width encoding ignores differences in discriminability, whereas range-only allocation may spend precision on weak predictors. We propose discriminability-aware symmetric bit-wise feature encoding (DA-SBFE), which combines training-fold mutual information with a robust numerical range to allocate tiered feature precision under a fixed budget. P4-programmable SmartNICs serve as a deployment-oriented case study because constrained per-packet processing motivates compact, deterministic representations. We do not claim hardware deployment. On 83,868 packets from the official UNSW IoT traces, DA-SBFE with BNN-Large achieved 0.9330 ± 0.0019 macro-F1 at 256 bits versus 0.9185 ± 0.0020 for Range-SBFE, with positive differences in all five folds. The gain increased from 0.0144 at 256 bits to 0.0348 at 192 bits and 0.0556 at 128 bits, and remained at 0.0176 after removing port features. Cross-day transfer showed only a small positive mean difference (0.0032) with mixed seed-level directions, so stable temporal robustness was not established. Deterministic integer XNOR–popcount inference matched PyTorch for all 16,774 held-out packets. The evidence supports DA-SBFE as a software-validated encoding method. Compilation, resource-use measurement, throughput evaluation, and latency evaluation remain future work.