← Latest papers
💻 computer science

DriveSafe AI: Quantifying the Preprocessing Bottleneck in Lightweight Driver Drowsiness Detection

This paper identifies preprocessing bottlenecks, specifically SSD bounding-box limitations, as the primary cause of accuracy loss in lightweight driver drowsiness detection systems and proposes a solution combining CLAHE-adaptive preprocessing, a three-zone confidence protocol, and dynamic quantization to achieve 99.0% accuracy with sub-40ms latency on edge devices.

Original authors: Ankush Karmakar

Published 2026-09-04
📖 1 min read☕ Coffee break read

Original authors: Ankush Karmakar

Original paper licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Technical Summary: DriveSafe AI

Problem Statement

Driver drowsiness is a leading cause of global road fatalities, yet deploying effective detection systems faces two primary barriers: high false alarm rates that erode driver trust, and catastrophic failure when models encounter unseen subjects or camera conditions (cross-dataset generalization). Existing literature reveals a fundamental trade-off: high-accuracy models often require heavy desktop hardware, while lightweight edge-compatible models sacrifice accuracy. Furthermore, most systems are evaluated only on their training distributions, masking generalization failures. This paper identifies a neglected source of accuracy loss: the preprocessing pipeline, specifically the handoff between face detection and classification.

Methodology

The proposed system, DriveSafe AI, employs a systematic pipeline decomposition to isolate accuracy bottlenecks. The architecture consists of:

  1. System Pipeline: Webcam frames undergo SSD (Single Shot Multibox Detector) face detection, followed by CLAHE (Contrast Limited Adaptive Histogram Equalization) preprocessing, classification via MobileNetV2, and a three-zone confidence protocol.
  2. CLAHE-Adaptive Preprocessing: Unlike standard global brightness adjustment, CLAHE operates on local tile regions to normalize non-uniform illumination (e.g., dashboard glare, tunnel lighting), bridging the domain gap between training and testing datasets.
  3. Three-Zone Confidence Protocol: To eliminate false alarms, the system partitions classifier outputs into three zones: Active (low probability), Uncertain (intermediate probability), and Fatigue (high probability). The system refuses to classify inputs falling in the "Uncertain" zone, maintaining high coverage while filtering noise.
  4. Subject-Adaptive Few-Shot Calibration: To address the cross-subject generalization gap, the system implements a few-shot fine-tuning protocol. Given only k=30k=30 labeled frames (approx. 1 second of video) from a new driver, the model:
    • Freezes all layers except the last five.
    • Fine-tunes on the adaptation frames with data augmentation (flips, brightness jitter, noise, cutout).
    • Calibrates a per-subject decision threshold.
    • Applies Test-Time Augmentation (TTA) and temporal smoothing over a 5-frame sliding window.
    • Note: The protocol supports a semi-supervised variant where the 30 frames need only be "active" (alert) frames, collected during the first minute of driving, eliminating the need for manual fatigue labeling at startup.

Key Contributions

The paper presents four primary contributions:

  1. Pipeline Decomposition: A methodology isolating per-stage accuracy contributions, identifying the SSD face-detection handoff as the primary failure mode, introducing a 12.1 percentage-point accuracy gap larger than any architectural variation tested.
  2. CLAHE-Adaptive Preprocessing: A technique that bridges the cross-dataset domain gap through illumination normalization, improving accuracy on the UTA-RLDD dataset from 33.3% to 99.0%.
  3. Three-Zone Confidence Protocol: A mechanism that eliminates false alarms through selective prediction, refusing uncertain inputs while maintaining 94.7% F1 score.
  4. Subject-Adaptive Calibration: A few-shot calibration method that lifts true Leave-One-Subject-Out (LOSO) accuracy from 53.2% to 96.1%, demonstrating the feasibility of personalized, edge-deployed detection.

Experimental Results

Experiments were conducted using the akahana dataset for in-distribution training and the UTA-RLDD benchmark (60 subjects) for cross-subject evaluation.

  • Preprocessing Impact: Without CLAHE, cross-dataset accuracy dropped to 33.3% due to illumination variance. With CLAHE, accuracy reached 99.0%, a 65.7 percentage-point improvement.
  • Generalization Performance:
    • Baseline (No Adaptation): Achieved 53.2% mean accuracy (±19.3% std) under true LOSO evaluation, with a False Alarm Rate (FAR) of 40.9%.
    • Adaptive (Few-Shot): Achieved 96.1% mean accuracy (±4.9% std) with only 30 adaptation frames per subject. FAR dropped to 5.5%, and recall reached 99.2%.
  • Ablation Studies:
    • Increasing adaptation frames from k=10k=10 to k=30k=30 provided the largest gain (+34.3 pp), dwarfing the benefits of TTA or temporal smoothing.
    • Architectural complexity (e.g., adding LSTM or geometric features) failed to improve performance over simple fine-tuning, yielding lower accuracy (59.0%) than the adaptive baseline.
    • Quantization: MobileNetV2 quantized to dynamic 2.4 MB (TFLite) achieved 99.0% accuracy, outperforming MobileNetV3, whose hard-swish activations degraded under weight rounding.
  • Bottleneck Analysis: The SSD face detection step introduced a 12.1 percentage-point accuracy gap compared to full-image classification, exceeding the impact of model architecture changes.

Significance and Claims

The paper argues that the primary barrier to lightweight Driver Drowsiness Detection (DDD) is not neural architecture capacity, but rather preprocessing robustness and subject-specific calibration.

  • Reframing Optimization: The author claims that improvements in preprocessing (specifically illumination normalization) and data adaptation yield greater returns than scaling model complexity. The 12.1 pp gap caused by the detection handoff is the largest single source of error identified.
  • Feasibility of Personalization: The results demonstrate that cross-subject generalization is not an insurmountable barrier requiring massive datasets or complex architectures. Instead, it can be resolved through personalized calibration using minimal data (30 frames).
  • Practical Deployment: The system is designed for edge deployment, utilizing TFLite dynamic quantization and a processing pipeline that fits within real-time constraints (sub-40ms per-frame budget when amortized). The semi-supervised adaptation protocol allows for real-world deployment without requiring drivers to manually label fatigue states during vehicle startup.

The study concludes that future efforts in DDD should prioritize reducing adaptation data requirements (via meta-learning) and validating these adaptive protocols across diverse datasets (NTH-DDD, ZJU-DRO) rather than pursuing further architectural innovations.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →