Lune

ICML2024Top-tier venue

Sample-specific Masks for Visual Reprogramming-based Prompting

Chengyi Cai, Zesheng Ye, Lei Feng, Jianzhong Qi, Feng Liu

Abstract

Visual reprogramming (VR) is a prompting technique that aims to re-purpose a pre-trained model (e.g., a classifier on ImageNet) to target tasks (e.g., medical data prediction) by learning a small-scale pattern added into input images instead of tuning considerable parameters within the model. The location of the pattern within input samples is usually determined by a pre-defined mask shared across all samples. In this paper, we show that the shared mask potentially limits VR's generalization and increases its approximation error due to the lack of sample-level adaptation. Motivated by this finding, we design a new framework for VR called sample-specific multi-channel masks (SMM). Specifically, SMM employs a lightweight ConvNet and patch-wise interpolation to generate sample-specific three-channel masks instead of a shared and pre-defined mask. Since we generate different masks for individual samples, SMM is theoretically shown to reduce approximation error for the target tasks compared with existing state-of-the-art VR methods. We also empirically demonstrate its performance gain on both ResNet and ViT. The success of SMM further highlights the broader applicability of VR in leveraging the latent knowledge of pre-trained models for various target tasks. Our code is available at https: //github.com/tmlr-group/SMM .

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

13 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Enhancing Visual Prompting through Expanded Transformation Space and Overfitting Mitigation cites Conditional Prompt Learning for Vision-Language Models
  • Enhancing Visual Prompting through Expanded Transformation Space and Overfitting Mitigation cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Enhancing Visual Prompting through Expanded Transformation Space and Overfitting Mitigation cites Learning Transferable Visual Models From Natural Language Supervision
  • Enhancing Visual Prompting through Expanded Transformation Space and Overfitting Mitigation cites Bayesian-guided Label Mapping for Visual Reprogramming
  • Conditional Prompt Learning for Vision-Language Models cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Conditional Prompt Learning for Vision-Language Models cites Learning Transferable Visual Models From Natural Language Supervision
  • Generalization-Preserved Learning: Closing the Backdoor to Catastrophic Forgetting in Continual Deepfake Detection cites Bayesian-guided Label Mapping for Visual Reprogramming
  • Standing on the Shoulders of Giants: Reprogramming Visual-Language Model for General Deepfake Detection cites Learning Transferable Visual Models From Natural Language Supervision
  • Learning Transferable Visual Models From Natural Language Supervision cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Prime Once, then Reprogram Locally: An Efficient Alternative to Black-Box Service Model Adaptation cites Conditional Prompt Learning for Vision-Language Models
  • Prime Once, then Reprogram Locally: An Efficient Alternative to Black-Box Service Model Adaptation cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Prime Once, then Reprogram Locally: An Efficient Alternative to Black-Box Service Model Adaptation cites Learning Transferable Visual Models From Natural Language Supervision
  • Prime Once, then Reprogram Locally: An Efficient Alternative to Black-Box Service Model Adaptation cites Bayesian-guided Label Mapping for Visual Reprogramming
  • Bayesian-guided Label Mapping for Visual Reprogramming cites Conditional Prompt Learning for Vision-Language Models
  • Bayesian-guided Label Mapping for Visual Reprogramming cites An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale
  • Bayesian-guided Label Mapping for Visual Reprogramming cites Voice2Series: Reprogramming Acoustic Models for Time Series Classification
  • Bayesian-guided Label Mapping for Visual Reprogramming cites Learning Transferable Visual Models From Natural Language Supervision
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers13

  1. Standing on the Shoulders of Giants: Reprogramming Visual-Language Model for General Deepfake DetectionKaiqing Lin, Yuzhen Lin, Weixiang Li, Taiping Yao et al.AAAI 2025 · 32 citations
  2. Bayesian-guided Label Mapping for Visual ReprogrammingChengyi Cai, Zesheng Ye, Lei Feng, Jianzhong Qi et al.NeurIPS 2024 · 14 citations
  3. Prime Once, then Reprogram Locally: An Efficient Alternative to Black-Box Service Model AdaptationYunbei Zhang, Chengyi Cai, Feng Liu, Jihun HammCVPR 2026 · 5 citations
  4. Generalization-Preserved Learning: Closing the Backdoor to Catastrophic Forgetting in Continual Deepfake DetectionXueyi Zhang, Peiyin Zhu, Chengwei Zhang, Zhiyuan Yan et al.ICCV 2025 · 3 citations
  5. Enhancing Visual Prompting through Expanded Transformation Space and Overfitting MitigationShohei EnomotoNeurIPS 2025 · 1 citation

Builds on14

  1. Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
  2. An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
  3. LoRA: Low-Rank Adaptation of Large Language ModelsEdward J. Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu et al.ICLR 2022 · 18,833 citations
  4. Conditional Prompt Learning for Vision-Language ModelsKaiyang Zhou, Jingkang Yang, Chen Change Loy, Ziwei LiuCVPR 2022 · 1,438 citations
  5. Voice2Series: Reprogramming Acoustic Models for Time Series ClassificationChao-Han Huck Yang, Yun-Yun Tsai, Pin-Yu ChenICML 2021 · 150 citations

Related papers

  1. Attribute-based Visual Reprogramming for Vision-Language ModelsChengyi Cai, Zesheng Ye, Lei Feng, Jianzhong Qi et al.ICLR 2025
  2. Understanding Model Reprogramming for CLIP via Decoupling Visual PromptsChengyi Cai, Zesheng Ye, Lei Feng, Jianzhong Qi et al.ICML 2025
  3. Endowing Visual Reprogramming with Adversarial RobustnessShengjie Zhou, Xin Cheng, Haiyang Xu, Ming Yan et al.ICLR 2025
  4. Visual Prompting via Image InpaintingAmir Bar, Yossi Gandelsman, Trevor Darrell, Amir Globerson et al.NeurIPS 2022 · 340 citations
  5. MEDICAL IMAGE UNDERSTANDING WITH PRETRAINED VISION LANGUAGE MODELS: A COMPREHENSIVE STUDYZiyuan Qin, Huahui Yi, Qicheng Lao, Kang LiICLR 2023 · 25 citations
Dusk over the sea between two cliffs drawn in fine vertical lines