ian-coccimiglio / SAMLab

Generating label images from SAM predictions
MIT License
1 stars 0 forks source link

Generating labels for a particular object #1

Open kulkarnikeerti opened 3 months ago

kulkarnikeerti commented 3 months ago

Hi @ian-coccimiglio

Thank you for the notebook. Could you please let me know if it is possible to generate labels for a particular object? For example, if there is a human in an image and I would like to generate a label just for human and everything else is a background. thanks in advance

https://github.com/ian-coccimiglio/SAMLab/blob/534b6ccb684a7e4b9c808bd27cb2a04a326bef24/make_label_images.py#L20

ian-coccimiglio commented 3 months ago

Hi there, what I think you're looking for is something like Lang-SAM. This allows you to combine the power of natural language with object segmentation. It works decently well for objects that are well annotated.

kulkarnikeerti commented 3 months ago

Thank you so much! I will work with this repo. I don't know if this is the right platform to ask. I see that these repos generate masks for the given images/objects. Do they also have labels for the objects? I tried to visualize the values in the generated masks in SAMlab but no luck. I also would like to have labeled images with assigned ids for the specified objects. Have come across something like this during you research?