APPLeNet: Visual Attention Parameterized Prompt Learning for Few-Shot Remote Sensing Image Generalization using CLIP

Mainak Singha, Ankit Jha, Bhupendra Solanki, Shirsha Bose, Biplab Banerjee

Introduction

Remote Sensing (RS) image analysis is frequently hindered by a significant "generalization gap." Models trained on satellite imagery from one geographic region or sensor often fail when deployed in different environments due to variations in atmospheric conditions, sensor characteristics, and spatial resolutions—a phenomenon known as domain shift. While large-scale Vision-Language Models (VLMs) like CLIP have demonstrated remarkable zero-shot capabilities in general computer vision, they often struggle with the unique textures and multi-scale objects inherent to RS data.

Existing adaptation techniques, such as Context Optimization (CoOp) and Conditional Context Optimization (CoCoOp), attempt to bridge this gap by learning continuous prompt embeddings. However, these methods typically rely on high-level visual features, failing to capture the mid-level textures and fine-grained details essential for RS scene classification. Furthermore, they often fail to disentangle environmental "style" from semantic "content" and suffer from token redundancy. To address these challenges, this paper introduces APPLeNet (Visual Attention Parameterized Prompt Learning Network).

Methodology

APPLeNet enhances the CLIP architecture through a novel prompt-learning framework designed specifically for the complexities of RS imagery. The architecture is built upon three primary innovations:

1. Multi-Scale Feature and Style Injection

Unlike standard methods that utilize only the final layer of a vision encoder, APPLeNet extracts features from multiple intermediate blocks. This multi-scale approach allows the model to incorporate both fine-grained local textures and global structural information. To handle domain shift, the model calculates "style primitives" using batch-normalization statistics (mean and variance) from domain-specific image batches. This allows the model to distinguish between the actual scene content and the artifacts of the specific sensor or environment.

2. Attention-Driven Injection Module

The extracted multi-scale content and style features are processed through a lightweight, residual attention block. This module projects the combined features into "visual tokens," which are then integrated into the learnable text prompt embeddings. Research indicated that placing the class token at the end of the learnable context (e.g., [Token1][Token2]...[Class]) provided the best performance, as it allows the visual-conditioned tokens to establish the context for the final classification.

3. Context Redundancy Penalizing (CRP) Loss

A common pitfall in prompt learning is the collapse of learned tokens into redundant representations. APPLeNet introduces the Context Redundancy Penalizing (CRP) loss, an anti-correlation regularizer that penalizes high similarity between different token embeddings. By forcing the model to learn a diverse set of descriptors, CRP loss ensures that the limited prompt capacity is utilized efficiently, which is critical in few-shot learning scenarios.

Experimental Evaluation

The performance of APPLeNet was evaluated using four major RS benchmarks: PatternNet, RSICD, RESISC45, and MLRSNet. The authors also developed "v2" versions of these datasets, identifying 16 overlapping classes to create a robust framework for single-source multi-target domain generalization.

Key Results

APPLeNet was tested across three distinct generalization tasks:

  • Base-to-New Class Generalization: APPLeNet outperformed CLIP’s zero-shot baseline by 33.47% on seen classes and 4.04% on unseen classes. It also surpassed previous state-of-the-art methods like ProGrad by approximately 2-3% in harmonic mean across all datasets.
  • Cross-Dataset Generalization: When trained on PatternNet and evaluated on the other three datasets, APPLeNet significantly narrowed the generalization gap, outperforming CoCoOp by up to 2.1% on novel domains.
  • Single-Source Multi-Target Domain Generalization: In this rigorous setup, APPLeNet achieved a top-1 accuracy of 81.03% on RSICDv2, a substantial improvement over the 61.40% achieved by standard Empirical Risk Minimization (ERM).

Discussion and Limitations

The success of APPLeNet lies in its ability to disentangle style from content and its enforcement of token diversity. By treating batch statistics as a proxy for domain style, the model effectively "subtracts" domain-specific noise, focusing on invariant semantic features.

However, the authors noted a potential "sweet spot" regarding model complexity. While increasing the number of attention modules improved performance on the source domain, it eventually led to diminishing returns or slight performance degradation on target domains. This suggests that excessive complexity may lead to overfitting the injection process to the source domain's specific style.

Conclusion

APPLeNet represents a significant advancement in adapting Vision-Language Models for remote sensing. By integrating multi-scale visual features and domain-specific style primitives into a diverse, non-redundant prompt space, it sets a new benchmark for few-shot scene classification and domain generalization. Future research may explore the integration of even larger foundation models or the adaptation of this framework for multi-modal RS data, such as combining optical imagery with Synthetic Aperture Radar (SAR).

Summary updated

BibTeX
@inproceedings{singha2023applenet,
  author = {Mainak Singha and Ankit Jha and Bhupendra Solanki and Shirsha Bose and Biplab Banerjee},
  title = {{APPLeNet: Visual Attention Parameterized Prompt Learning for Few-Shot Remote Sensing Image Generalization using CLIP}},
  booktitle = {Workshops @ CVPR},
  year = {2023},
}
Figure