When Learned IDS Model Selection Collapses to a Static Choice: A Measurement Study at the Edge

Nuonan Ouyang, Bonan Zhang, Adrian Shatte, Zhigang Lu, Chao Chen, Wei XiangarXiv 2026

It’s late, you’ve had a long day, and the last thing you want is a lecture on hyperparameter tuning. But imagine you’ve built a "smart" thermostat for a high-security server room. You’ve given it a fancy Reinforcement Learning (RL) brain so it can decide when to run a heavy-duty, power-hungry security scan and when to stick to a light, breezy check. You're proud of it—until you realize that after weeks of training, the "brain" has decided to just run the light check 100% of the time.

Did it actually learn to adapt, or did it just find a shortcut? This paper, "When Learned IDS Model Selection Collapses to a Static Choice," is a wake-up call for anyone trying to put "smart" model selection on edge devices like IoT sensors or Raspberry Pis.

TL;DR

Researchers found that complex Reinforcement Learning agents designed to switch between different security models often "collapse" into just picking one cheap model and staying there forever. By creating a rigorous measurement framework, they show that a simple, old-school rule-of-thumb can actually outperform "AI" selectors in saving energy and meeting real-time deadlines.

What Problem Does This Paper Address?

Edge devices (think smart cameras or industrial sensors) are caught in a tug-of-war. They need to run Intrusion Detection Systems (IDS) to stay secure, but they have tiny batteries and limited processing power.

The "obvious" solution is runtime model selection: use a lightweight, "cheap" model when things are quiet, and switch to a "heavy," accurate model when a threat is suspected. Researchers often use Reinforcement Learning (RL) to manage this switching.

However, the authors noticed a recurring flaw in how these systems are evaluated. If an RL agent is "better" than a static heavy model, is it because it's "smart" and adapting to the situation? Or did it just learn that the heavy model is too expensive and decided to use the light one all the time? If it's the latter, you don't have an adaptive system; you just have a static light model with extra steps (and extra code).

Methods

The authors built a physical testbed using a Raspberry Pi 4B and a high-precision USB-C power meter to measure exactly how much "juice" these models consume in the real world.

Figure 1: Physical apparatus. A 5-V supply feeds the Raspberry Pi 4B through the POWER-Z KM003C USB-C meter; host orchestration reaches the Pi through the network switch; the external SSD stores evidence artifacts. Teal: network/control; amber: power measurement; dashed: evidence storage. The drawing shows roles and paths only.

They introduced a few clever auditing tools:

  • Pairwise Non-degeneracy Criterion: A mathematical test to see if your reward function actually allows for switching. If the "cost" of a better model is always higher than the "reward" for its extra accuracy, the math dictates the agent will never switch.
  • Matched Static Controls: They compared the RL agent not just against a "heavy" model, but against a static version of whatever model the agent ended up picking most of the time.
  • DeadlineGuard: A simple, causal rule they created that switches models based on how many rows of data are arriving per second, ensuring the system doesn't fall behind.

Datasets

The study primarily used TON-IoT, a dataset that blends IoT telemetry (like fridge temperature) with network traffic and operating system events. For extra validation and "sanity checks," they also used:

  • CICIoT2023
  • N-BaIoT

Key Insights and Ideas

  • The "Collapse" is Real: In many scenarios, the RL agents (both Tabular Q-learning and Deep Q-Networks) simply stopped adapting. They found one model (LightLR) that was "good enough" for the reward function and never left it.
  • Attribution Error: Many papers claim RL is great because it beats a static "heavy" model. This paper shows that's often a lie—the RL agent is just realizing that the heavy model isn't worth the energy, but it isn't actually doing any "intelligent" switching.
  • The Default Action Trap: When an RL agent encounters a situation it wasn't trained for (like a sudden massive spike in traffic), it relies on "tie-breaking" rules in its code. In this study, that led to the agent picking a model that produced a staggering 67.76% false-positive rate. That’s a security nightmare triggered by a simple coding default.
  • Simple Rules Can Win: Their DeadlineGuard rule—which doesn't use RL at all—was the only method that successfully managed a variable workload without missing a single processing deadline.

Key Results

  • Energy Savings: Compared to a static medium-weight model (MedRF), the DeadlineGuard rule saved 43.7 Joules per 500-second run (about a 3% saving) while ensuring zero deadline misses.
  • RL Failure: Both the Tabular-Q and DQN selectors collapsed to picking the same model (LightLR) in 100% of the tested windows during the primary campaign.
  • The Cost of "Smart" Selection: The DQN (Deep Q-Network) selector itself consumed a small but measurable amount of extra energy just to make its decisions, which is a significant overhead for a device that isn't actually changing its mind.

Limitations and Future Work

The authors are honest about the boundaries of their study:

  • Hardware Specifics: These results are specific to the Raspberry Pi 4B. Different chips might change the energy-vs-accuracy math.
  • Thermal Limits: While they included temperature in their models, the Pi never got hot enough during these specific tests to trigger "thermal throttling" or force a model switch for cooling reasons.
  • Fixed Thresholds: They used a standard 0.5 threshold for all detectors; adjusting these thresholds might change which models are considered "optimal."

The big takeaway? Before you deploy a "learning" system at the edge, audit your reward function. If the math says switching is never worth it, your AI is just a very expensive way to make a static choice.

Summary updated

Abstract

Runtime model selection trades detection quality against energy and latency. However, comparing a selector only with a more costly static detector conflates detector choice with the benefit of adaptation. We present a framework for analysis and physical measurement that combines a pairwise reward criterion, matched static controls, paired blocks, a fixed load-prevalence factorial design, and reporting of actions outside training support. On one Raspberry Pi 4B with four frozen TON-IoT detectors, tabular Q-learning and a deep Q-network (DQN) both select LightLR throughout. A retrospective audit using validation data only rules out preference reversals for MedRF versus LightLR and HeavyMLP versus LightLR. However, TinyDT has a higher reward than LightLR in seven of the 2,500 windows, so the audit does not establish global LightLR optimality. We also evaluate a causal DeadlineGuard rule under a fixed factorial design with three arrival rates (50, 100, and 4,000 rows/s) and three attack prevalences (0.10, 0.50, and 0.90). Compared with Static-MedRF, DeadlineGuard saves 43.7 J per 500-s run (2.98%; 95% paired CI 41.4--46.0 J) and eliminates all 512 deadline misses among 5,000 windows, at a cost of 1.373 percentage points in F1. Outside training support, Tabular-Q's deterministic tie-breaking rule selects TinyDT, resulting in a false-positive rate of 67.76%. These single-board results motivate joint audits of reward attainability, realized actions, attribution against matched static controls, service feasibility, and default actions outside training support.
BibTeX
@misc{ouyang2026when,
  author = {Nuonan Ouyang and Bonan Zhang and Adrian Shatte and Zhigang Lu and Chao Chen and Wei Xiang},
  title = {{When Learned IDS Model Selection Collapses to a Static Choice: A Measurement Study at the Edge}},
  year = {2026},
  eprint = {2611.29968},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.29968},
}
Figure