From the course: Hands-On Introduction to Transformers for Computer Vision
Unlock this course with a free trial
Join today to access over 24,700 courses taught by industry experts.
Visualizing attention - PyTorch Tutorial
From the course: Hands-On Introduction to Transformers for Computer Vision
Visualizing attention
- [Instructor] Welcome everyone to chapter seven, video two. It's going to be our last video of the course here. We're going to be visualizing attention. We're going to be bringing everything together of what we've learned so far of transformers, inference pipelines, working with data sets. We're going to try to understand exactly what is happening in our model, where our model looks when it makes its predictions. Super insightful and help you understand how your model makes those predictions, how to diagnose model failures, as well as just bring a little bit more trust to your transformer. We're going to start by importing libraries. Make sure you have that transformers library as well as fiftyone in here. We're going to be working with that same ImageNet data set, classic example here. And be shooting open the app to begin working with it. Once again, sticking to the basics here, we're going to be working with the google/vit-base-patch16. We're going to use some pre-trained weights…