Type | Other |
Stats | 1,502 |
Reviews | (138) |
Published | Mar 9, 2024 |
Base Model | |
Hash | AutoV2 1E5B90318D |
Credits to @novowels for that name :clueless:
Small segmentation model aiming to create accurate masks of eyes for improved inpainting quality with adetailer extension.
Can also be downloaded at HF: https://huggingface.co/Anzhc/Anzhcs_YOLOs
Script im using: https://github.com/Anzhc/Training-script-for-Ultralytics-YOLO
Usage
Put into `automatic1111/models/adetailer`, or any other place that you know will work with YOLOv8 models.
Set erosion/dilution to 0. (Or very low values)
Use.
DISCLAIMER: It was trained on 1024px, and under common circumstances will perform best in that resolution, but Adetailer default is 640, and currently you can't change that. Bing-su said that my pr breaks normal models, though i wasn't able to reproduce that, so, currently this model WILL NOT perform as on showcase images, unless you change ultralytics.py in a way that i did in my pr.
For XL models max padding is required, if you want eyes to stay consistent to each other. For hires you might need to modify UI to extend slider values to 512. Otherwise you will get this, as other eye is not in range of inpainted area:
What it does?
Creates own mask per eye found, each can be inpainted with unique prompt.
I did switch annotation style roughly 1/3 into process, so it's not quite uniform and accurate as it could be, but it still is probably one of the most accurate options available. It works by trying to select only sclera+pupils area, which let you use very high denoise. I tested up to 0.85, and it was decent coherence still, as it was only inpainting area where it can't ruin composition.
It still has some minor issues with selecting edge precisely, so you can see those small lines where it's not inpainted, but it would be fair to assume it's easily fixed with small dilution for the time being.