Skip to content

Latest commit

 

History

History

object-segementation

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Object Segmentation Examples

This directory contains two example scripts that demonstrate how to perform object segmentation on Gaudi with graph mode.

Single-HPU inference

ClipSeg Model

python3 run_example.py \
    --model_name_or_path "CIDAS/clipseg-rd64-refined" \
    --image_path "http://images.cocodataset.org/val2017/000000039769.jpg" \
    --prompt "cat, remote, blanket" \
    --warmup 3 \
    --n_iterations 20 \
    --use_hpu_graphs \
    --bf16 \
    --print_result

Models that have been validated:

Segment Anything Model

python3 run_example_sam.py \
    --model_name_or_path "facebook/sam-vit-huge" \
    --image_path "https://huggingface.co/ybelkada/segment-anything/resolve/main/assets/car.png" \
    --point_prompt "450,600" \
    --warmup 3 \
    --n_iterations 20 \
    --use_hpu_graphs \
    --bf16 \
    --print_result

Models that have been validated: