Skip to main content
Segment an image using OneFormer.

Parameters

Union[str, Image.Image, np.ndarray]
required
RGB input image.
str
default:"'panoptic'"
“panoptic”, “semantic” or “instance”.
float | None
Optional HTTP timeout.

Returns

Dict[str, Any]: Backend-specific segmentation output.

Example

Example Output

OneFormer semantic segmentation output with label map

Related topics

oneformer