CPA-Enhancer: Chain-of-Thought Prompted Adaptive Enhancer for Object Detection under Unknown Degradations

Yuwei Zhang, Yan Wu, Yanming Liu, Xinyue PengarXiv 2024

TL;DR

This paper introduces CPA-Enhancer, a novel plug-and-play module for object detection that adapts its image enhancement strategy to unknown degradations using Chain-of-Thought (CoT) prompts. This approach significantly improves detection performance on degraded images without requiring prior knowledge of the degradation type, setting a new state-of-the-art.

What Problem Does This Paper Address?

Object detection models perform exceptionally well on clean images, but their performance plummets when faced with degraded inputs like fog, low light, or rain. Existing solutions typically require knowing the specific degradation type beforehand and training separate models for each. This is impractical for real-world scenarios where degradations are often unknown and can be a combination of multiple types. The paper aims to bridge this gap by developing a unified, adaptive enhancement model that can handle diverse, unknown degradations without prior knowledge.

Methods

The core innovation is the CPA-Enhancer, a plug-and-play module designed to be integrated with existing object detectors. It consists of two key components:

  • CoT-prompt Generation Module (CGM): This module generates "Chain-of-Thought" (CoT) prompts. These prompts are learnable parameters that encode degradation-specific contextual information. The CoT approach guides the model through a series of logical steps, allowing it to progressively infer and adapt to the degradation.
  • Content-driven Prompt Block (CPB): This block facilitates the interaction between the input image features and the CoT prompts. It calculates spatial importance maps and uses transformer blocks to allow the model to dynamically adjust its enhancement strategy based on the degradation type inferred by the prompts. This interaction helps the model focus on enhancing relevant features for detection.

The CPA-Enhancer is designed as an encoder-decoder architecture that refines features before they are fed into a standard object detector (YOLOv3 in this case).

Datasets

The authors utilized a combination of existing and synthetically generated datasets:

  • Real-world datasets: RTTS (foggy), ExDark (low-light).
  • Synthetic datasets: Created by applying various degradation models (fog, low-light, snow, rain, noise) to clean images from the VOC dataset. This includes datasets like VocFogTrain (VF-T), VocDarkTrain (VD-T), VocSnowTrain (VS-T), VocRainTrain (VR-T), and VocNoiseTrain (VN-T) for training, and corresponding test sets. They also created multi-degradation datasets (VM-T) for all-in-one training.
  • Downstream task datasets: ACDC (semantic segmentation), DARK FACE (face detection).

Key Insights and Ideas

  • Chain-of-Thought for Image Enhancement: Applying CoT prompting, a technique previously successful in NLP, to image enhancement for object detection is a novel idea. It allows for a more nuanced and step-by-step adaptation to unknown degradations.
  • Adaptive Enhancement without Prior Knowledge: The core strength of CPA-Enhancer is its ability to adapt without needing to know the specific degradation type, making it highly practical for real-world applications.
  • CoT Prompts Improve Robustness: The CoT prompts help the model learn hierarchical representations and dependencies, leading to more stable performance across a varying number of degradation tasks.
  • Plug-and-Play Efficiency: The module can be easily integrated into existing object detection pipelines, offering significant performance gains with a relatively small increase in parameters and inference time.

Key Results

  • State-of-the-Art Performance: CPA-Enhancer significantly outperforms existing methods on various degraded datasets, including RTTS, ExDark, and synthetic datasets, setting new state-of-the-art mAP50 scores. For instance, on the RTTS dataset in the all-in-one setting, it achieved 56.35% mAP50, surpassing other methods.
  • Robustness to Multiple Degradations: In the "all-in-one" setting, CPA-Enhancer demonstrated strong performance across multiple degradation types simultaneously, outperforming specialized methods.
  • Improved Downstream Task Performance: When cascaded with semantic segmentation models (DeepLabv3+, SegFormer) on the ACDC dataset, CPA-Enhancer achieved a notable improvement in mIoU (e.g., 72.2% for Ours(S)), outperforming previous best results by 6.7 points. It also showed significant gains in face detection on the DARK FACE dataset.
  • Efficiency: The model adds only 3M trainable parameters and requires an additional 3ms per image compared to the YOLOv3 baseline on a single RTX 4090 GPU.

Limitations and Future Work

  • Parameter Efficiency: While efficient, the majority of parameters in CPA-Enhancer originate from the transformer block within the CPB. The authors suggest future work could explore more optimized attention schemes or retrieval-augmented methods to further reduce parameter count.
  • Generalization to Wider Degradations: The paper focuses on specific degradation types. Future work could aim to create a more universal model capable of handling an even wider range of degradations.
  • Further Exploration of Prompt Design: While CoT prompts are effective, exploring alternative prompt generation strategies or prompt fusion techniques could yield further improvements.

Summary updated

BibTeX
@misc{zhang2024cpa,
  author = {Yuwei Zhang and Yan Wu and Yanming Liu and Xinyue Peng},
  title = {{CPA-Enhancer: Chain-of-Thought Prompted Adaptive Enhancer for Object Detection under Unknown Degradations}},
  year = {2024},
  eprint = {2403.11220},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2403.11220},
}
Figure