Image segmentation is a process of converting an image into a collection of subgroups of pixels that are called image segments.