Skip to content

Overload: A Latency Attack on Object Detection for Edge DevicesOverload: Latency Attacks on Object Detection for Edge Devices

arXiv· arXiv:2304.05370· CVPR 2024· Erh-Chung Chen, Pin-Yu Chen, I-Hsin Chung, Che-rung LeeNational Tsing Hua University; IBM ResearchIndexed by this site · 27 days ago· Originally publishedAttacks

Quick read

Attacks

Based on the paper PDF (AI-generated); refer to the original

The authors propose Overload, a latency attack framework targeting NMS in object detection, and claim that on Nvidia Jetson NX it can extend YOLOv5s single-image inference time by about 13.0×.

Threat modelWhite-box attack: the attacker fully knows the model architecture and can directly read intermediate information; the goal is to add perturbations within an ϵ-ball to maximize the processing time (including queueing wait) of the victim object detection model; the victim system is an object detection model that relies on NMS, deployed on edge devices.

Questions
Real-time object detection systems (such as unmanned stores and autonomous driving) are required to respond within strict time limits; the authors study a class of latency attacks that aim to increase inference time, which poses a greater threat to edge devices.
Methods
The authors analyze the time complexity of NMS and argue that the time is dominated by the number of objects fed into NMS; on this basis they propose Overload: maximize only the confidence of each object to produce a large number of objects, and use spatial attention to generate more objects in sparse regions.
Experiments and results
On Jetson NX, adversarial examples take on average about 13.0×/11.0× the time of the original image for YOLOv5s/YOLOv5n; when the pipeline is entirely adversarial examples, FPS drops from 43.5 to 4.3; the authors claim the attack is NMS-agnostic.
Limitations and future work
The authors note that the evaluation was conducted only in a white-box setting; black-box delayed attacks, impact on downstream tasks, and defense strategies are left for future work; the attack does not directly apply to NMS-free models such as DETR and CenterNet.
Experimental setupYOLOv5s、YOLOv5n et al. · MS COCO 2017 validation set · elapsed time (ms)、objects et al.
Evaluated models
YOLOv5sYOLOv5nYOLOv7YOLOv7-tinyYOLOv8sYOLOv8nYOLOv3YOLOv3-tinySSDRetinanetFCOS
Benchmarks
MS COCO 2017 validation set
Metrics
elapsed time (ms)objectsboxesFPSRecallmAP@50
AI summaryThe researchers propose a latency attack framework for object detection named Overload, whose goal is to extend model inference time rather than cause misclassification; experiments show that the inference time for a single image can be extended to ten times the normal setting. The method is based on a newly constructed optimization problem and a technique called spatial attention, and can generate latency attacks at scale. Experiments were conducted on an Nvidia NX device using the YOLOv5 model. The authors state that the attack is independent of non-maximum suppression (NMS) and poses a potential new threat to all object detection tasks that require NMS, especially for systems with limited computational resources.

The researchers propose a latency attack framework for object detection named Overload, whose goal is to extend model inference time rather than cause misclassification; experiments show that the inference time for a single image can be extended to ten times the normal setting. The method is based on a newly constructed optimization problem and a technique called spatial attention, and can generate latency attacks at scale. Experiments were conducted on an Nvidia NX device using the YOLOv5 model. The authors state that the attack is independent of non-maximum suppression (NMS) and poses a potential new threat to all object detection tasks that require NMS, especially for systems with limited computational resources.

Paper analysis

6 questions; open one to read the full answer

  1. What problem does this paper attempt to solve?

    The study investigates latency attacks aimed at increasing inference time and proposes Overload, an attack framework targeting NMS in object detection.

    Core question: How to construct adversarial examples that maximize the inference latency of object detection models (especially on edge devices), so that they cannot respond within the time limit.

    • Scenario and importance: The authors state that real-time applications such as unmanned stores and autonomous driving require detection to be completed within strict time constraints, and lengthened latency can cause serious failures; edge devices have limited compute, making the threat greater.
    • Shortcomings of existing methods: The authors state that Phantom Sponge [35] and Daedalus [38] need to compute gradients for all IoU pairs, incurring high computational cost and GPU memory overhead, and that there is a lack of systematic research on the impact on edge devices.
    • Core observation: After analyzing the time complexity of NMS, the authors argue that its time cost is dominated by the total number of objects fed into NMS, |C| (approximately quadratic growth), while the effect of the number of surviving boxes is negligible (Figure 2, Equation 4).
    • Proposed in the paper: The latency attack framework Overload simplifies the objective to maximizing object confidence and proposes a spatial attention technique to generate more objects in sparse regions; the authors state that the attack is NMS-agnostic.
    • Threat model:
      • Objective: Under the constraint that the perturbation does not exceed the ϵ-ball, maximize the total time cost of the victim model processing requests (including queuing wait, Equations 1–2).
      • Knowledge: White-box; the attacker fully knows the model architecture and can directly read intermediate information; the authors acknowledge that this setting is not very feasible in reality.
      • Capability: Add perturbations to input images and send malicious requests in batches to exhaust shared resources (DoS scenario).
      • Victim system: Object detection models that rely on NMS post-processing, deployed on edge devices with limited compute.
  2. What related research exists?

    Related work falls into four categories: object detection and NMS, adversarial attacks against detection, latency attacks, and two baselines directly compared.

    Object detection and NMS

    • Single-stage detectors such as SSD [13] and the YOLO series [22] generally use NMS to remove duplicate predictions; DIoU, CIoU [43], and others improve the pruning criterion of NMS.
    • The authors note that prior research on NMS time is scarce because benchmark data are clean and evaluation is performed on high-end GPUs, so NMS time is ignored.

    Adversarial attacks against object detection

    • The paper summarizes four types of objectives: appearing attack (generating nonexistent objects [42]), hiding attack (hiding objects [40]), mis-classifying attack [3], and mis-locating attack [21].
    • The authors consider Overload close in spirit to appearing attack but different in purpose: it does not pursue specific false detections but produces a large number of objects to slow down processing.

    Latency attacks

    • Sponge attack: demonstrated the feasibility of latency attacks on translation models with fixed-length sequences.
    • Sloth/slowdown attack [19]: a latency attack against dynamic vision models with early exit.

    Directly compared baselines

    • Daedalus [38]: produces a large number of bounding boxes to reduce mAP; Phantom Sponge [35]: increases the total number of objects fed into NMS to extend time while maintaining recall. The authors criticize both for needing to track gradients of all IoU pairs, for high computation and GPU memory cost, and for lacking investigation of edge devices.
    • Comparison benchmark: MS COCO 2017 validation set (the paper randomly takes 1,000 images); comparison metrics are number of objects, Recall, mAP@50, and resource consumption (Table 5, Table 6).

    The authors position this paper as: theoretically identifying the number of objects fed into NMS as the key objective of latency attacks, thereby simplifying the objective design, achieving a stronger attack effect with less computation and GPU memory, and systematically verifying the threat to edge devices and multiple NMS implementations.

  3. How does the paper address this problem?

    The latency attack is formalized as maximizing the sum of confidences of objects fed into NMS, and spatial attention is used to guide perturbations toward sparse regions.

    Overall approach: first show that NMS time is dominated by the number of objects fed in, then simplify the attack objective to "make the model output as many high-confidence objects as possible," generate adversarial images with PGD-style iterations, and use spatial attention to improve efficiency. The framework is named Overload.

    Problem formulation

    • Attack objective: 𝔼x ∼ 𝒳 maxδ ≤ ϵ Ttotal(x+δ), i.e., maximize the total time for a set of requests within an ϵ-ball; total time = inference time + queueing wait time.
    • The authors consider directly optimizing T infeasible (it is affected by external factors such as scheduling and caching and cannot be directly differentiated in a white-box setting), so the time must be parameterized as a function of the model output.

    NMS complexity analysis

    • Complexity of the four NMS steps: filtering O(|C|), sorting O(|C| log |C|), pairwise IoU computation O(|C|²), pruning O(|C|²) (Appendix A).
    • The authors give the approximation: Ttotal = s(|𝒞|2 + |ℬ||𝒞|), where |C| is the number of objects fed into NMS and |B| is the number of output boxes; experiments in Figure 2 show that time grows quadratically with |C|, and the ratio of worst to best case is constant, i.e., the effect of the number of surviving boxes is negligible.

    Attack objective design

    • Objective function: maxx ∑i=0n Fl(Fconf(M(x)i)), i.e., maximize the sum of the confidences of all output objects after transformation by a monotonically increasing function Fl; Fconf takes the object confidence c when the class probability exceeds the threshold Tconf, and otherwise takes c·pi.
    • The authors argue that the two terms in prior work, "minimize pairwise IoU" and "minimize box area," not only fail to improve effectiveness but also increase GPU memory and time, so only the confidence term is kept; the basis is that in Figure 2 increasing the number of objects can increase time by up to 20×, whereas increasing the number of boxes at fixed |C| yields only about 2×.

    Spatial attention and generation procedure

    • Purpose: make the attack focus on object-sparse regions rather than regions that already contain objects. Procedure (Figure 3): the image is divided into an m × m grid; the weight Wi,j of each grid cell is adjusted according to the number of existing objects (a region that cannot produce more objects or is already dense enough is down-weighted); update as xadv = xorg + η·Wi,j·∆x, where ∆x is the gradient of the objective function.
    • The paper does not give complete hyperparameters such as the number of iterations or the default value of ϵ (in the comparison experiments Overload uses ϵ = 15, Table 5).

    Success criteria and evaluation method

    • Metrics are the number of objects fed into NMS, the number of boxes output by NMS, and single-image time (ms, including model inference and NMS); after sorting by time, each quantile is reported; pipeline simulation (with different proportions of adversarial examples) is also used to measure FPS.
  4. What experiments did the paper conduct?

    YOLOv5s/v5n measured on Jetson NX: adversarial examples take on average about 13.0×/11.0× the time of the original image, and pipeline, cross-GPU, IoU threshold, comparison baseline, and ablation experiments were also conducted.

    Experimental setup

    • Models tested: main experiments on YOLOv5s and YOLOv5n (compiled to TensorRT); Appendix C adds YOLOv7, YOLOv7-tiny, YOLOv8s, YOLOv8n, YOLOv3, and YOLOv3-tiny, plus small-scale experiments on SSD, Retinanet, and FCOS.
    • Data: 1,000 randomly selected images from the MS COCO 2017 validation set, batch size 1, input size (640, 640).
    • Hardware: main experiments on Nvidia Jetson NX; cross-hardware experiments on A100, A10, and 1080 Ti; resource consumption experiments on Nvidia V100 (32GB).
    • Baselines: Phantom Sponge and Daedalus; the ablation baseline is vanilla PGD.
    • Metrics: objects (number of objects fed into NMS), boxes (number of boxes output by NMS), time (ms, including inference and NMS), FPS; comparison experiments additionally report Recall and mAP@50.
    • Result presentation: after sorting by time, min/0.10/0.25/0.50/0.75/0.90/max quantiles are reported; the paper does not report the number of repetitions or variance.

    Main results

    According to Table 1 (Nvidia Jetson NX, 50% quantile, time in ms):

    Swipe horizontally to read the table

    ModelAdversarial objectsAdversarial boxesAdversarial timeOriginal image time
    YOLOv5s240002250217.816.4
    YOLOv5n223632315128.911.5
    • The authors report that adversarial examples take on average about 13.0× (YOLOv5s) and 11.0× (YOLOv5n) the time of the original image; the max quantile times reach 293.8 ms and 258.7 ms, respectively.
    • The authors state that under the experimental configuration the YOLO models output at most 25,200 objects, and the attack generates more than 20,000 ghost objects for over 90% (YOLOv5s) and over 60% (YOLOv5n) of the images.

    Pipeline and cross-GPU experiments

    • Pipeline simulation (Table 2): as the proportion of adversarial examples rises from 0 to 100%, the average single-image time for YOLOv5s rises from 23 ms to 230 ms and FPS drops from 43.5 to 4.3; for YOLOv5n it rises from 20 ms to 135 ms and FPS drops from 50.0 to 7.4. The authors state that in the worst case inference time increases tenfold, constituting a potential warning for real applications.
    • Cross-GPU (Table 3, YOLOv5s): the Tatk/Torg ratio is about 3–6 on A100, A10, and 1080 Ti (e.g., 1080 Ti from 11 ms to 62 ms), and 23 ms to 230 ms on Jetson. The authors state that the attack generalizes to different GPUs, but its strength depends on the hardware configuration.

    IoU-invariant verification and baseline comparison

    • IoU threshold (Table 4): at the 50% quantile, YOLOv5s times at TIoU = 0.00/0.45/0.80/1.00 are 200.0/217.8/234.7/245.4 ms, respectively; the authors state that although the best case reduces objects by more than 95%, the time is close to the other cases, indicating that the number of surviving boxes has little effect.
    • Comparison with baselines (Table 5): Overload (ϵ = 15) generates about 20,000 objects, Recall 44, mAP@50 < 0.001; Phantom Sponge at ϵ = 70 generates about 19,000 objects, Recall 18, and at ϵ = 30 generates 9,000 objects, Recall 77; Daedalus generates about 1,500 objects. The authors explicitly caution that the three have different objectives and perturbation constraints, so the comparison results should not be over-interpreted.
    • Resource consumption (Table 6, V100): Overload with a batch of 16 has a peak GPU memory of 7.5 GB and takes about 180 s; Overload + LIoU cannot run due to GPU memory overflow; Overload + Larea uses 7.9 GB and takes 240 s. The main text also states that Daedalus sequentially generates 10 images in about 145 minutes with a peak of about 8.5 GB.

    Other ablations and analyses

    • Objective function (Table 7): x²/2 and −log(1−x) generate significantly fewer objects than log(x) and tanh(x); the authors explain that an effective Fl should be monotonically increasing with a monotonically decreasing derivative.
    • Spatial attention (Table 8): SA generates about 2,000 more objects than vanilla PGD for YOLOv5s/v5n (e.g., at the 50% quantile for YOLOv5n: 22,363 vs 16,755).
    • Grid size (Table 9): the authors state that around 5 × 5 is a relatively good configuration, and at 20 × 20 some grid cells cannot be effectively attacked.
    • Other models (Appendix C, Table 10): objects at the 50% quantile — YOLOv7 20,578, YOLOv7-tiny 23,163, YOLOv8s 8,313 (model limit 8,400), YOLOv3 14,015; time was not measured for these models (not optimized for edge devices). The SSD experiment generates only about 300–1,000 objects; the authors consider that its softmax normalization makes the attack highly dependent on image content, leaving room for improvement.
    • Transferability (Appendix D): no transferability was observed within the YOLOv5 family, which the authors speculate is related to FPN multi-scale features; an ensemble attack of YOLOv3+YOLOv5s can generate a large number of objects for both models simultaneously, but the strength is slightly weaker than attacking each separately (Table 11).
  5. What are some points that can be further explored?

    The authors acknowledge that the evaluation is limited to the white-box setting, and leave black-box attacks, downstream impact, and defenses for future work; the experimental coverage is mainly the YOLO family and Jetson NX.

    Limitations and future directions noted by the authors

    • White-box setting (4.5 Discussion, Limitation): All evaluations are conducted under the white-box setting, and the authors acknowledge that this setting may be impractical in reality; generating physical universal patches that can increase inference time under the black-box setting is a key research direction, but evaluating practicality is beyond the scope of this paper.
    • Black-box attacks (5 Conclusion): Black-box latency attacks have not yet been studied; the authors believe that spatial attention is a gradient-free process and may help black-box attacks.
    • Impact on downstream tasks (5 Conclusion): The impact of latency attacks on downstream task performance requires more research.
    • Defenses (5 Conclusion): Defense strategies against latency attacks are an important topic but beyond the scope of this paper; Section 4.5 discusses three possible defenses (limiting maximum execution time, limiting the number of objects fed into NMS, adversarial training) and their costs.
    • NMS-free models (4.5 Discussion): The attack cannot be directly applied to NMS-free models such as DETR and CenterNet; the authors cite an underwater detection benchmark stating that 11 of 12 models still rely on NMS.
    • Other architectures (Appendix C): The objective function (Equation 5) is designed specifically for the YOLO family and may not be optimal for other architectures; the authors believe that the idea of Overload applies to most detectors that integrate NMS, but implementation details require further research.

    Scope of experiments

    • The models tested in the main experiments are YOLOv5s and YOLOv5n, 2 in total; the appendix extends to YOLOv7/v7-tiny, YOLOv8s/v8n, YOLOv3/v3-tiny (reporting only objects/boxes, without measuring time cost), while SSD, Retinanet, and FCOS have only small-scale or illustrative experiments.
    • The data are 1,000 random images from the MS COCO 2017 validation set; the hardware is Jetson NX (main), A100/A10/1080 Ti (cross-GPU), and V100 (resource consumption).
    • Transferability experiments cover only within the YOLOv5 family and the YOLOv3+YOLOv5s ensemble combination.
    • The paper does not report the number of iterations for attack generation, the default ϵ, the number of repetitions, or statistical variance.
    • Defenses are discussed only, with no defense evaluation under adaptive attacks.
  6. Summarize the main content of the paper

    Overload carries out a latency attack by maximizing the number of objects fed into NMS; the authors claim that on Jetson NX it extends YOLOv5 single-image time by about tenfold.

    A latency attack paper targeting object detection proposes an attack framework, Overload, aimed at detection models deployed on edge devices that rely on NMS post-processing.

    • Problem: Unlike adversarial attacks that pursue misclassification, latency attacks aim to lengthen inference time so that real-time systems (unmanned stores, autonomous driving) cannot respond on time; in the white-box setting, the attacker adds perturbations within an ϵ-ball to maximize the processing time of the victim model.
    • Method highlights: The authors analyze the four-step complexity of NMS and argue that its time cost is dominated by the number of objects fed into NMS, |C| (approximately quadratic growth), while the effect of the number of surviving boxes is negligible; on this basis, they simplify the attack objective to maximizing the sum of confidences of all objects, and use spatial attention (adjusting pixel weights according to grid object density) to generate more objects in sparse regions.
    • Main results:
      • On Jetson NX, the average time cost of adversarial examples for YOLOv5s/YOLOv5n is about 13.0×/11.0× that of the original images (Table 1, 50% quantile 217.8/128.9 ms vs. 16.4/11.5 ms).
      • When the pipeline is entirely adversarial examples, YOLOv5s FPS drops from 43.5 to 4.3 (Table 2).
      • Generation cost: about 180 s for a batch of 16 images, with peak GPU memory of 7.5 GB, lower than the variant with an added IoU term (the latter overflows GPU memory) (Table 6).
      • The appendix extends to models such as YOLOv7/v8/v3 (e.g., YOLOv7 50% quantile 20,578 objects); the authors state that the attack is NMS-agnostic.
    • Negative results: No transferability was observed within the YOLOv5 family; on SSD, only about 300–1,000 objects were generated.
    • Authors' conclusion: Overload achieves a stronger attack with a simpler objective and poses a threat to systems with limited compute; black-box attacks, downstream impact, and defenses are left for future work, and the authors state that disclosing this vulnerability analysis helps accelerate the design of safer edge devices.
Read originalCVPR 2024