Image Segmentation

A computer vision technique that divides an image into pixel-precise regions, such as a person, their clothing, and the background.

What is image segmentation?

Image segmentation is a computer vision process that divides a digital image into distinct regions at the pixel level. Where object detection only says "there is a person in this photo", segmentation traces the exact boundary of that person, separating them from the background, their hair from their face, and one garment from another.

The garment-level variant is often called person parsing: labeling every pixel as skin, hair, top, bottoms, shoes, or background.

A photo and its segmentation map with color-coded regions
A photo and its segmentation map with color-coded regions

Role in virtual try-on

Segmentation is one of the first steps in a try-on pipeline:

  1. Garment masking: identifying the exact pixels of the clothing to be replaced, which becomes the mask for image inpainting.
  2. Background isolation: ensuring generation never alters the scene around the person.
  3. Occlusion handling: detecting hair, hands, or accessories in front of the clothing so they are preserved on top of the new garment.

Segmentation tells the system where things are at the pixel level; pose estimation tells it how the body is positioned. Garment transfer needs both.

FAQ

Questions, answered.

What's the difference between segmentation and background removal?

Background removal is one application of segmentation: a two-region split (subject vs background). Try-on pipelines need finer-grained parsing that distinguishes individual garments, skin, and hair within the subject.

Related terms

Pose Estimation
Computer vision technology that detects the position of human body joints and landmarks in images or video.
Image Inpainting
Regenerating a masked region of an image while leaving the rest untouched.
Garment Transfer
The AI process of rendering a clothing item from a product photo onto an image of a person.
Occlusion
Hiding the right parts of a virtual object behind real-world elements that are closer to the viewer.

See it on your own products.

Install Genlook on Shopify in minutes and let shoppers preview products before they buy.