Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Amazing tool, but Can I add object classes? #56

Open
tanuki-create opened this issue Dec 5, 2023 · 3 comments
Open

Amazing tool, but Can I add object classes? #56

tanuki-create opened this issue Dec 5, 2023 · 3 comments
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@tanuki-create
Copy link

For example, can I add 'Can' as the object class?
or Should I train the segmentation model?

Is there any way to select additional class?

I would like to use segment models for regenerating 'coffee can' which a person holds.

Thank you master, this is a great tool.

@wkpark
Copy link
Owner

wkpark commented Dec 5, 2023

segm/ yolov5_ins*.pth models support coco Instance segmentation (see also https://github.com/open-mmlab/mmyolo/tree/main/configs/yolov5 ) and you can select any COCO class objects.

in this case, you can use "Inpainting Helper" after "Generate" an image.

  • COCO class supports 81 predefined classes.

additionally, you can use yolov8 instant segment models, (Please see ultralytics models
such as

  • Open Image V7, which includes 600 pre-trained classes. (recommend)
  • ImageNet, which includes 1000 pretrained classes. (also supported but need to add a class definition JSON map to show readable classes)

in this case, you have to download selected yolov8 models and copy it to to_your_sd_webui_dir/models/yolo/ and click the refresh button right of the model selection input to show newly added models.

image

@tanuki-create
Copy link
Author

tanuki-create commented Dec 5, 2023

Thank you for your fast reply!

I tried it but not working...

I was able to add the model, but the output did not change at all. (I tried the low confidence as well)

Should I train the segmentation model of Yolo?

スクリーンショット 2023-12-05 8 28 48

@wkpark
Copy link
Owner

wkpark commented Dec 6, 2023

  1. Generate an image or drop image to the "Inpaint helper" found in the "u DDetailer" accordions.
  2. do not choose object classes -> it will detect all detectable classes
  3. checkbox "detect only"
  4. inpainting test
  5. based on these results, you can choose the object now.

basically, we don't know what "Tin can" is. but we can only select based on detected results.

@wkpark wkpark self-assigned this Jan 24, 2024
@wkpark wkpark added the documentation Improvements or additions to documentation label Jan 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants