Skip to main content
QUICK REVIEW

[Paper Review] CAT: Cross-Attention Transformer for One-Shot Object Detection

Weidong Lin, Yuyan Deng|arXiv (Cornell University)|Apr 30, 2021
Advanced Neural Network ApplicationsComputer Science22 references8 citations
TL;DR

This paper proposes a Cross-Attention Transformer (CAT) module for one-shot object detection that enhances semantic similarity comparison between query and target images by modeling bidirectional, grid-level correspondence through dual-stream transformers. The method achieves state-of-the-art accuracy on COCO, VOC, and FSOD benchmarks while running nearly 2.5× faster than the prior SOTA CoAE, due to efficient feature compression without performance loss.

ABSTRACT

Given a query patch from a novel class, one-shot object detection aims to detect all instances of that class in a target image through the semantic similarity comparison. However, due to the extremely limited guidance in the novel class as well as the unseen appearance difference between query and target instances, it is difficult to appropriately exploit their semantic similarity and generalize well. To mitigate this problem, we present a universal Cross-Attention Transformer (CAT) module for accurate and efficient semantic similarity comparison in one-shot object detection. The proposed CAT utilizes transformer mechanism to comprehensively capture bi-directional correspondence between any paired pixels from the query and the target image, which empowers us to sufficiently exploit their semantic characteristics for accurate similarity comparison. In addition, the proposed CAT enables feature dimensionality compression for inference speedup without performance loss. Extensive experiments on COCO, VOC, and FSOD under one-shot settings demonstrate the effectiveness and efficiency of our method, e.g., it surpasses CoAE, a major baseline in this task by 1.0% in AP on COCO and runs nearly 2.5 times faster. Code will be available in the future.

Motivation & Objective

  • To address the challenge of detecting novel object classes with only one annotated example in one-shot object detection.
  • To improve semantic similarity comparison between query and target images under extreme class imbalance and appearance variation.
  • To develop a lightweight, efficient, and universal module that enhances feature representation for one-shot detection without sacrificing accuracy.
  • To achieve both superior detection performance and faster inference speed compared to existing state-of-the-art methods.

Proposed method

  • The CAT module employs two interleaved transformer streams to compute cross-attention between grid-level features from the query and target images, capturing bidirectional correspondence at the pixel-patch level.
  • The model uses a Siamese backbone (ResNet-50) to extract shared features from both query and target images before feeding them into the CAT module.
  • The CAT module enables effective feature dimensionality compression by leveraging the rich correspondence information, reducing the final feature dimension to 256 without performance degradation.
  • The framework is integrated into a two-stage detection pipeline: first, the CAT enhances features based on query-target correspondence; second, a region proposal network and classifier detect and classify objects.
  • The model is trained using standard one-shot detection protocols, with data splits consistent across COCO, VOC, and FSOD benchmarks.
  • Hyperparameter ablation shows that setting the compressed feature dimension $d_m = 256$ achieves the best trade-off between accuracy and speed.

Experimental results

Research questions

  • RQ1Can a transformer-based module effectively model bidirectional, grid-level correspondence between query and target images to improve one-shot object detection?
  • RQ2How does the proposed CAT module enhance semantic similarity comparison under limited supervision and large appearance variation?
  • RQ3To what extent can feature dimensionality be compressed after CAT processing without degrading detection performance?
  • RQ4Does the proposed method achieve both higher accuracy and faster inference than existing state-of-the-art one-shot detectors?
  • RQ5How does the model generalize from seen to unseen classes in zero-shot and few-shot settings?

Key findings

  • On the COCO dataset, the proposed method achieves 1.0% higher average AP and 0.9% higher AP50 compared to the re-implemented CoAE baseline.
  • On the VOC dataset, the model improves mAP by 1.3 points on unseen classes and shows slightly better generalization than CoAE.
  • On the FSOD dataset, the model achieves 1.7% higher AP and 2.5% higher AP75 on novel classes compared to CoAE.
  • The model runs at 16.3 FPS on an NVIDIA RTX-2080Ti, which is nearly 2.5× faster than CoAE’s 5.9 FPS, despite using a smaller feature dimension.
  • Ablation studies confirm that $d_m = 256$ provides the optimal balance between accuracy and inference speed, with $d_m = 1024$ leading to overfitting and $d_m = 128$ causing a 2-point AP drop.
  • Visualization results demonstrate that the CAT module progressively refines attention maps to focus on objects matching the query class, confirming its role in enhancing semantic correspondence.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.