Skip to content

Unofficial PyTorch implementation of Attention Rollout

Notifications You must be signed in to change notification settings

BoCtrl-C/attention-rollout

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Attention Rollout

The code contained in this repository stands as a didactic example presented at the Artificial Intelligence and Deep Learning course organized by Sezione Fisica Medica of Università degli Studi di Roma Tor Vergata.

This repo contains the following files:

  • vision_transformer.py, which is a modified version of vision_transformer.py that makes it possible to recover attention matrices.
  • attention_rollout.py, which provides the functions to compute and display attention rollout.
  • example.ipynb, which shows how to compute and display attention rollout.

About

Unofficial PyTorch implementation of Attention Rollout

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published