DEV Community

Baaz
Baaz

Posted on

What Is Semantic Segmentation?

Semantic segmentation is a computer-vision task that assigns a class label to every pixel in an image-so a model outputs a dense map where each pixel is marked as road, person, tumor, or background, rather than a single label or a bounding box. It works by passing the image through an encoder-decoder neural network that extracts features, upsamples them back to full resolution, and predicts a class for each pixel.

Most machine-learning models answer a coarse question about an image: what is in it, or roughly where. Semantic segmentation answers a far finer one-what is every single pixel? That pixel-level understanding is what lets a self-driving car separate drivable road from sidewalk, a radiologist's tool outline a tumor to the millimeter, and a factory camera flag the exact region of a defect. This guide explains what semantic segmentation is, how it differs from classification, object detection, and instance segmentation, and how the models actually work-from encoder-decoder architectures to the loss functions and metrics that train and grade them. It also covers where segmentation is used, why annotation is the hard part, and how teams move from a research prototype to a production pipeline. Baaz has built vision-intelligence systems and pixel-level annotation pipelines since 2018. This is the framing we use when a client asks whether segmentation is the right tool for their problem.

Top comments (0)