
Explore attention mechanisms and transformers across vision tasks, from vision transformers to detection and segmentation, with unsupervised and semi-supervised pre-training and practical Hugging Face tooling.
Explore how transformers and attention mechanisms evolved from NLP to computer vision, guided by inductive bias, self attention, and unsupervised pre training across image classification, detection, and segmentation.
Explore inductive bias in neural networks by treating networks as graphs from fully connected to convolution and attention, and compare weak versus strong biases in Transformers and graph neural networks.
Explore how attention mechanisms differ from fully connected layers by dynamically weighting input features via self-attention, enabling context-aware connections across image patches and words.
Explore how attention mechanisms align encoder and decoder states with dot-product scores and softmax weights to produce a context vector and alignment map, improving neural machine translation.
Explore how attention mechanisms power transformers by replacing recurrent sequence processing with parallel attention over input tokens, enabling fast, order-aware representations.
Explore the self attention mechanism for images by projecting words into queries, keys, and values to compute an attention map, aligning each word with others via softmax and dot products.
Explore the self-attention mechanism as a matrix operation on word embeddings, using Q, K, V projections, dot products, and softmax to compute token-wise attention maps.
Learn how multi-head attention in transformers encodes multiple feature views with separate Q, K, V projections, then concatenates heads to produce richer vision representations for computer vision.
Learn encoder-decoder attention in transformers, where the encoder uses self-attention and multi-head attention, and the decoder uses auto regressive decoding with encoder keys and values.
Transformers offer scalable, parallel self-attention for encoding token sequences, enabling multimodal, encoder-only advantages, while large model capacity demands unsupervised pretraining and compression strategies.
Unsupervised pre-training empowers transformers to learn from massive data without labels through generative, context-based, and cross-model self-supervised tasks, dramatically boosting accuracy before downstream supervised tasks.
Explore how self-attention extends from natural language processing to computer vision, compare attention to convolution, and expand local scope to global relations across images, channels, and time.
Explore the encoder-decoder design pattern, a universal backbone across deep learning and transformer architectures, mapping inputs to latent features and decoding to outputs such as classes, masks, or translations.
Explore how convolutional encoders act as a backbone to extract local, translation-invariant features through kernels and multi-channel maps, producing a 7x7 feature map that summarizes the image and discusses limitations.
See how self attention in vision uses q, k, v projections to model global relations between patches, contrasting with fixed convolution kernels via a convolution encoder enabling dynamic multi-head attention.
explore spatial, channel, and temporal attention in vision transformers, comparing 2d patch attention with channel-wise relations and temporal relations across video frames.
Explore the unified pattern of self-attention across text, image, channel, spatial, and temporal data by generalizing the QKV formulation and dimensionality choices, including patches, channels, and tokens.
Explore local versus global attention in computer vision, comparing dynamic local self-attention with convolution and non-local global attention, and learn how criss-cross attention reduces memory and computation across image patches.
Analyze how attention and transformer mechanisms relax inductive bias to capture global relations versus convolution. Heavy computations and larger parameters demand data; local attention and unsupervised pretraining offer remedies.
Explore how transformers enable image classification, from vision transformers and data efficient transformers to swin transformers, comparing CNN backbones, patch-based tokens, and self-attention mechanisms.
Transform vision by converting image patches into tokens, applying position embeddings and a classification token to replace convolution in ViT and DeiT, pre-trained on large datasets.
discover how shifted window transformers reduce attention complexity by performing self-attention within local windows and shifting windows across layers to enable cross-window communication for classification, detection, and segmentation.
Explore transformer-based object detection with encoder-decoder architectures, comparing single-shot detectors like YOLO to DETR, and applying to tasks such as San Francisco street sign detection.
Compare traditional and deep learning object detection methods, from region proposals and one- and two-stage detectors to transformers-based approaches, using CNN feature maps and confidence-based filtering for multi-object classification.
Explore how YOLO uses a backbone to produce a seven-by-seven feature map, anchors, and dual heads for classification and bounding-box regression. Learn how IOU-based matching and non-maximum suppression yield detections.
Explore detection transformers (DETR) that use a transformer encoder-decoder with a scene backbone to perform object detection without anchors or NMS, using 1-to-1 bipartite matching.
Compare yolov5 and detr on san francisco street sign data; yolov5 offers faster inference for embedded deployment, while detr delivers higher mean average precision on server-scale setups after fine-tuning.
Explore transformers in image segmentation within computer vision, reviewing component-based segmentation and the unit architecture, and compare segmentation transformer and trans unit approaches for semantic and panoptic segmentation.
Explore semantic, instance, and panoptic segmentation, and how conv nets with encoder-decoder structures like U-net and FPN produce pixelwise masks and labels.
Explore transformer-based image segmentation, replacing encoders with self-attention and using patch embeddings, for semantic, instance, and panoptic segmentation via segmenter and detection transformer variants.
Explore how spatio-temporal transformers model spatial and temporal relations in video for moving object detection. Learn about temporal attention, optical flow, and multi-task learning with object queries.
Explore practical usage of transformers with pre-trained models using the hugging phase transformer pipeline api. Apply these vision transformer architectures to image classification, segmentation, and object detection.
Operate the Hugging Face pipeline to connect tasks, pre-trained models, preprocessing, and post-processing, delivering outputs from any input, with model hub options for sentiment analysis, question answering, and summarization.
Leverage the huggingface vision transformers via the pipeline to perform image classification, object detection, and panoptic segmentation, configuring models and interpreting top-k results and probabilities.
Demonstrates a quick, shareable model demo with Gradio and Hugging Face Spaces, using a text input that returns text output; launches a temporary or permanent endpoint via Spaces.
Summarizes attention mechanisms, inductive bias, and transformer roles in vision, detailing encoder-decoder architectures, image patches, and applications to image classification, detection, segmentation, and video analysis.
Transformer Networks are the new trend in Deep Learning nowadays. Transformer models have taken the world of NLP by storm since 2017. Since then, they become the mainstream model in almost ALL NLP tasks. Transformers in CV are still lagging, however they started to take over since 2020.
We will start by introducing attention and the transformer networks. Since transformers were first introduced in NLP, they are easier to be described with some NLP example first. From there, we will understand the pros and cons of this architecture. Also, we will discuss the importance of unsupervised or semi supervised pre-training for the transformer architectures, discussing Large Scale Language Models (LLM) in brief, like BERT and GPT.
This will pave the way to introduce transformers in CV. Here we will try to extend the attention idea into the 2D spatial domain of the image. We will discuss how convolution can be generalized using self attention, within the encoder-decoder meta architecture. We will see how this generic architecture is almost the same in image as in text and NLP, which makes transformers a generic function approximator. We will discuss the channel and spatial attention, local vs. global attention among other topics.
In the next three modules, we will discuss the specific networks that solve the big problems in CV: classification, object detection and segmentation. We will discuss Vision Transformer (ViT) from Google, Shifter Window Transformer (SWIN) from Microsoft, Detection Transformer (DETR) from Facebook research, Segmentation Transformer (SETR) and many others. Then we will discuss the application of Transformers in video processing, through Spatio-Temporal Transformers with application to Moving Object Detection, along with Multi-Task Learning setup.
Finally, we will show how those pre-trained arcthiectures can be easily applied in practice using the famous Huggingface library using the Pipeline interface.