File size: 786 Bytes
2b049c8 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | ---
license: apache-2.0
tags:
- onnx
- segmentation
- sam2
- ezonnx
---
### EdgeTAM
ONNX models for inference with [EZONNX](https://github.com/ikeboo/ezonnx)
- Model type:
Segmentation
- Official repository:
[EdgeTAM](https://github.com/facebookresearch/EdgeTAM)
- Setup
```
pip install git+https://github.com/ikeboo/ezonnx.git
```
- Usage
```python
from ezonnx import EdgeTAM, visualize_images
tam = EdgeTAM()
res = tam.set_image("images/cat.jpg")
# add point with positive or not and its label
res = tam.set_point((240, 180), True, 1)
res = tam.set_point((50,50), True, 2)
res = tam.set_point((400,50), True, 2)
res = tam.set_point((150, 330), True, 3)
visualize_images("Masked Image",res.visualized_img)
``` |