---
title: models.sam.sam3.maskformer_segmentation API Reference
description: Explore the ultralytics.models.sam.sam3.maskformer_segmentation module for segmentation heads and predictors used with SAM3.
keywords: Ultralytics, SAM3, MaskFormer, segmentation head, mask prediction, deep learning, Python, API reference
---

# Reference for `ultralytics/models/sam/sam3/maskformer_segmentation.py`

!!! success "Improvements"

    This page is sourced from [https://github.com/ultralytics/ultralytics/blob/main/ultralytics/models/sam/sam3/maskformer_segmentation.py](https://github.com/ultralytics/ultralytics/blob/main/ultralytics/models/sam/sam3/maskformer_segmentation.py). Have an improvement or example to add? Open a [Pull Request](https://docs.ultralytics.com/help/contributing) — thank you! 🙏

<br>

## ::: ultralytics.models.sam.sam3.maskformer_segmentation.LinearPresenceHead

<br><br><hr><br>

## ::: ultralytics.models.sam.sam3.maskformer_segmentation.MaskPredictor

<br><br><hr><br>

## ::: ultralytics.models.sam.sam3.maskformer_segmentation.SegmentationHead

<br><br><hr><br>

## ::: ultralytics.models.sam.sam3.maskformer_segmentation.PixelDecoder

<br><br><hr><br>

## ::: ultralytics.models.sam.sam3.maskformer_segmentation.UniversalSegmentationHead

<br><br>
