Fully Convolutional Networks: From Image to Segmentation Map
An FCN turns a standard image classifier into a pixel-level labeler by replacing its final layers with convolutions to preserve spatial data. It's used for semantic segmentation, like identifying all cars and roads in a street scene.
WHY IT EXISTS: Traditional Convolutional Neural Networks (CNNs) excel at image classification—telling you what is in an image (e.g., 'a cat'). But their final fully-connected layers discard all spatial information to produce that single label. To figure out where the cat is by labeling its pixels, you would need to run the classifier on thousands of overlapping image patches, which is extremely slow and inefficient.
THE MENTAL MODEL: Think of an FCN as converting a classification network into a 'pixel-labeling machine.' Instead of collapsing an image's features into a single 'cat' or 'dog' label, it takes those high-level features and intelligently upsamples them back into a full-resolution map. The output is an image of the same size as the input, but where each pixel's value represents a class label, like 'cat,' 'grass,' or 'sky.'
HOW IT WORKS: An FCN modifies a pre-trained classification network (like VGG or AlexNet) in two ways. First, it removes the final, dense fully-connected layers and replaces them with 1x1 convolutional layers. This preserves the spatial feature map. Second, since pooling layers in the network progressively shrink the feature map, the FCN uses upsampling layers (transposed convolutions) to enlarge the final, coarse feature map back to the original image's dimensions. The key innovation is using 'skip connections' to combine the deep, semantic information from the final layers with the shallow, fine-grained appearance information from earlier layers. This fusion produces segmentations that are both semantically correct and spatially precise.
WHEN TO USE IT: Use FCNs for any dense prediction task where you need a corresponding output for every input pixel. Its primary application is semantic segmentation, a core task in autonomous driving (identifying drivable areas, pedestrians), medical imaging (outlining tumors or organs), and satellite image analysis (classifying land use).
WHEN NOT TO USE IT: FCNs are overkill for simple image classification. They also don't distinguish between different instances of the same object class—for example, they label all cars as 'car' but cannot separate 'car 1' from 'car 2'. For that, you need an instance segmentation model like Mask R-CNN.
ONE CANONICAL EXAMPLE: A classic FCN architecture, FCN-8s, adapts the VGG16 network. It takes the output from the final two pooling layers (pool4 and pool5) and the prediction from the final convolutional layer. It upsamples the final layer's output by 2x and adds it to the pool4 output. This combined map is then upsampled again by 2x and added to the pool3 output. Finally, this result is upsampled by 8x to produce the final, detailed segmentation map, effectively combining features from three different network depths.
Read the original → arxiv.org
Get five bites like this every day.
Tezvyn delivers a daily feed of 60-second tech bites with quizzes to lock in what you learn.