Introduction

Are you interested to know where an object is in the image? What is the shape of the object? Which pixels belong to the object? To accomplish this, we need to segment the image, i.e., classify each pixel of the image to the object it belongs to or give each pixel of the image a label contrary to giving one label to an image.

Thus, image segmentation is the task of learning a pixel-wise mask for each object in the image. Unlike object detection, which gives the bounding box coordinates for each object present in the image, image segmentation gives a far more granular understanding of the object(s) in the image.

Image for post

Figure 1: Semantic segmentation and Instance segmentation.

Image segmentation can be broadly divided into two types:

  • Semantic segmentation: Here, each pixel belongs to a particular class. The left image in figure 1 is an example of semantic segmentation. The pixels either belong to the person(a class) or background(another class).
  • Instance segmentation: Here, each pixel belongs to a particular class. However, pixels belonging to discrete objects are labeled with a different color(mask value). The right image in figure 1 is an example of instance, segmentation. The pixels belonging to the person’s class are colored differently.

This report will build a semantic segmentation model and train it on  Oxford-IIIT Pet Dataset. We will interactively visualize our model’s predictions in Weights & Biases.

#wandb #semantic-segmentation #deep-learning #keras #tensorflow

Image Segmentation using Keras and W&B
7.05 GEEK