Semantic-Segment-Anything
Semantic-Segment-Anything copied to clipboard
Human class
Can we get the mask only showing a human body? Not with all the other elements in the image/video
You can achieve this by using SSA and making some modifications. We have released a new close-set segmentation model based on SAM. If you want to segment a single class e.g., 'human body', there are two ways: (1) you can find an existing model or use your previously trained single class segmentor as the semantic branch in SSA (https://github.com/fudan-zvg/Semantic-Segment-Anything/blob/main/scripts/main_ssa.py#L48); (2) you can use a multi-category segmentation semantic segmentation model as the semantic branch and add a post-processing step to classify other categories as background.
We have open-sourced the close-set version SSA code. Please refer to the readme and try running one of them with some modifications.