ESPFormer: Doubly-Stochastic Attention with Expected Sliced Transport Plans

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Shahbazi, Ashkan, Akbari, Elaheh, Salehi, Darian, Liu, Xinran, Naderializadeh, Navid, Kolouri, Soheil
Format: Preprint
Veröffentlicht: 2025
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866916839628472320
author Shahbazi, Ashkan
Akbari, Elaheh
Salehi, Darian
Liu, Xinran
Naderializadeh, Navid
Kolouri, Soheil
author_facet Shahbazi, Ashkan
Akbari, Elaheh
Salehi, Darian
Liu, Xinran
Naderializadeh, Navid
Kolouri, Soheil
contents While self-attention has been instrumental in the success of Transformers, it can lead to over-concentration on a few tokens during training, resulting in suboptimal information flow. Enforcing doubly-stochastic constraints in attention matrices has been shown to improve structure and balance in attention distributions. However, existing methods rely on iterative Sinkhorn normalization, which is computationally costly. In this paper, we introduce a novel, fully parallelizable doubly-stochastic attention mechanism based on sliced optimal transport, leveraging Expected Sliced Transport Plans (ESP). Unlike prior approaches, our method enforces doubly stochasticity without iterative Sinkhorn normalization, significantly enhancing efficiency. To ensure differentiability, we incorporate a temperature-based soft sorting technique, enabling seamless integration into deep learning models. Experiments across multiple benchmark datasets, including image classification, point cloud classification, sentiment analysis, and neural machine translation, demonstrate that our enhanced attention regularization consistently improves performance across diverse applications. Our implementation code can be found at https://github.com/dariansal/ESPFormer.
format Preprint
id arxiv_https___arxiv_org_abs_2502_07962
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle ESPFormer: Doubly-Stochastic Attention with Expected Sliced Transport Plans
Shahbazi, Ashkan
Akbari, Elaheh
Salehi, Darian
Liu, Xinran
Naderializadeh, Navid
Kolouri, Soheil
Machine Learning
While self-attention has been instrumental in the success of Transformers, it can lead to over-concentration on a few tokens during training, resulting in suboptimal information flow. Enforcing doubly-stochastic constraints in attention matrices has been shown to improve structure and balance in attention distributions. However, existing methods rely on iterative Sinkhorn normalization, which is computationally costly. In this paper, we introduce a novel, fully parallelizable doubly-stochastic attention mechanism based on sliced optimal transport, leveraging Expected Sliced Transport Plans (ESP). Unlike prior approaches, our method enforces doubly stochasticity without iterative Sinkhorn normalization, significantly enhancing efficiency. To ensure differentiability, we incorporate a temperature-based soft sorting technique, enabling seamless integration into deep learning models. Experiments across multiple benchmark datasets, including image classification, point cloud classification, sentiment analysis, and neural machine translation, demonstrate that our enhanced attention regularization consistently improves performance across diverse applications. Our implementation code can be found at https://github.com/dariansal/ESPFormer.
title ESPFormer: Doubly-Stochastic Attention with Expected Sliced Transport Plans
topic Machine Learning
url https://arxiv.org/abs/2502.07962