Stochastic Vision Transformers with Wasserstein Distance-Aware Attention

Franciskus Xaverius Erick, Mina Rezaei, Johanna Paula Müller, Bernhard Kainz
11/30/2023
cs.CVcs.AI
transformer-attentioncontrastive-ssl

No confident code implementation found for this paper. 1 possible match can be shown below.

Abstract

Self-supervised learning is one of the most promising approaches to acquiring knowledge from limited labeled data. Despite the substantial advancements made in recent years, self-supervised models have posed a challenge to practitioners, as they do not readily provide insight into the model's confidence and uncertainty.

Show full abstract

Tackling this issue is no simple feat, primarily due to the complexity involved in implementing techniques that can make use of the latent representations learned during pre-training without relying on explicit labels. Motivated by this, we introduce a new stochastic vision transformer that integrates uncertainty and distance awareness into self-supervised learning (SSL) pipelines. Instead of the conventional deterministic vector embedding, our novel stochastic vision transformer encodes image patches into elliptical Gaussian distributional embeddings. Notably, the attention matrices of these stochastic representational embeddings are computed using Wasserstein distance-based attention, effectively capitalizing on the distributional nature of these embeddings. Additionally, we propose a regularization term based on Wasserstein distance for both pre-training and fine-tuning processes, thereby incorporating distance awareness into latent representations. We perform extensive experiments across different tasks such as in-distribution generalization, out-of-distribution detection, dataset corruption, semi-supervised settings, and transfer learning to other datasets and tasks. Our proposed method achieves superior accuracy and calibration, surpassing the self-supervised baseline in a wide range of experiments on a variety of datasets.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 1 weaker match is hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{erick2023stochastic,
  title  = {Stochastic Vision Transformers with Wasserstein Distance-Aware Attention},
  author = {Franciskus Xaverius Erick and Mina Rezaei and Johanna Paula Müller and Bernhard Kainz},
  year   = {2023},
  eprint = {2311.18645},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2311.18645v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2311.18645.svg)](https://codeofpaper.com/paper/2311.18645)

Discussion