segment-anything
segment-anything copied to clipboard
SAM binary segmentation mask to YOLO format
Hey Everyone !!
I have a dataset with only bounding box annotations . I wanted to generate Segmentation masks using the available bounding box and made us of SAM model . SAM gives Segmentation masks in binary format , when I plotted the masks the results very pretty impressive . Now I want to built an instance segmentation model on the above dataset using YOLOV8 or YOLOV5 . But for this I want to convert my Segmentation masks in binary format to YOLO format. I have tried with the opencv"s find contour too but it was a failure . Can some one please guide me there !!
Thank You !!
Try something like this https://colab.research.google.com/drive/1FJGF47MkLMpU4Kc3qzQumKJ7zqIQfORG?usp=sharing