编辑 | blame | 历史 | 原始文档

---
title: Semantic Segmentation with Masks
type: templates
category: Computer Vision
cat: computer-vision
order: 105
meta_title: Semantic Segmentation with Masks Data Labeling Template

meta_description: Template for performing semantic segmentation with brush masks with Label Studio for your machine learning and data science projects.

Image segmentation using a brush and producing a mask.



Open in Label Studio

Interactive Template Preview

Labeling Configuration

<View>
  <Image name="image" value="$image" zoom="true"/>
  <BrushLabels name="tag" toName="image">
    <Label value="Airplane" background="rgba(255, 0, 0, 0.7)"/>
    <Label value="Car" background="rgba(0, 0, 255, 0.7)"/>
  </BrushLabels>
</View>

About the labeling configuration

All labeling configurations must be wrapped in View tags.

Use the Image object tag to display the image and allow the annotator to zoom the image:
xml <Image name="image" value="$image" zoom="true"/>

Use the BrushLabels control tag to apply brush masks to the image, using the Label tag to specify the value and color of the brush mask:
xml <BrushLabels name="tag" toName="image"> <Label value="Airplane" background="rgba(255, 0, 0, 0.7)"/> <Label value="Car" background="rgba(0, 0, 255, 0.7)"/> </BrushLabels>

Related tags