santa hat
deerdeer nosedeer glow
Sign In
HW Tagger Release

GitHub link: https://github.com/HaW-Tagger/HWtagger/

The install instructions are available on Github.

You can directly download all the models for the models path using this link: https://huggingface.co/PhoenixAscencio/HWtagger
There is a basic tutorial on how to use the tagger available on the github wiki: https://github.com/HaW-Tagger/HWtagger/wiki/How-to-use-(basic-tutorial)

Same tutorial on Civitai: https://civitai.com/articles/5752/hw-tagger-how-to-use-basic-tutorial

Hello everyone, I'm gonna explain why we made this tagger in this section and it will permit you to understand what is its purpose.
I started making LORAs in December with the help of @Wasabi who explained to me a lot of things about how it worked on a base level. In January, I started seeing some problems with the base checkpoints and other things that were hurting us, so We decided to make a common dataset for better lighting compositions, better tags/tokens in general, ...
Except that We encountered a first hurdle, It was the inability to easily share and modify our tags on images since We both used a different method to tag our images.
I then started making a software that would help us share out datasets by simply sharing a database with images and we could see what the other changed and have simple ways to edit it. In the 20th of February, the framework for the tagger was working properly and I decided to share it with @Wasabi, We then developed together the released tool that is now completely different from the tool from the 20th of February.

What's the goal of the tool:

  • Fast tagging and loading of datasets

  • Easy way to move and share datasets

  • Easy way to have different settings for how we tag images

  • Improved compatibility between the tags of the different taggers

What's not the goal (but could happen in the far, far future):

  • Gathering/Downloading images from online services (use Grabber)

  • Training of LORAs/Checkpoints directly in the tagger (use LORA Easy Trainer)

Features

  • Fast Dataset autotagging leveraging CUDA enabled GPUs

  • Comprehensive tags modification

  • Retrieving tags from online sources

  • Easy share of databases

  • Similarity check

  • Token check tools

  • Visual tagging

  • Conflict verification

  • Tags recommendations

  • Easy trigger tag modification

  • Image modification detection

  • Auto-completion of tags

  • Multi-selection edit of images

  • Automatic cropping of images

  • Filling of transparent backgrounds

  • Multiple sorting algorithms for images, like brightness levels and other experimental features like shading smoothness control as well as underlighting

  • ...

Did we succeed on these goals ?

Overall, yes but We sill still try to expand and refine the capabilities of the checkpoint

Fast tagging and loading of datasets

We used Pyside6 to increase the speed of database loading and memory management, On large datasets, the loading is pretty fast, especially compared to other tools (like the tagger extension for Auto1111) but could be improved with asynchronous loading of the images themselves.

We improved the speed at which the autotaggers run by making them use the full power of CUDA, but this requires the use of a NVIDIA graphic card.

Overall the experience feels pretty smooth, and since this is my first project that is this big in scope, it's pretty good for a release (@Wasabi has more experience).

Easy way to move and share datasets

Every information for a single dataset is stored in a single file (which can be quite big), you can merge databases together and easily share everything using a zip and it will store all tags where they do come from so I thing it's been achieved.

Easy way to have different settings for how we tag images

The tag categories does its job pretty well and I think everything is okay regarding that, you can achieve diversity in the tool, We will probably need to add more websites to get tags from and more automatic taggers, but the way We made things permit the use of multiple automatic taggers and sources of images.

Improved compatibility between the tags of the different taggers

We have setup a way to make tags interact together by using a LOW/HIGH system for tag filtering:

High              Low             Base tags
rabbit hat                        bunny hat
                  bunny hat       rabbit hat

When filtering all the tags, we put them together in a set, we then remove all tags that are in a blacklist, (for example: highres, translated, ...). Then we add all tags that are considered HIGH tags when the BASE tags is present, (in this example: images with bunny hat have the tag rabbit hat added), then we check the LOW tags and remove them from the tags if any of the BASE tags are present (rabbit hat is present so we remove bunny hat from the tags).

If multiple base tags are in the line, then the presence of one of it triggers the addition of the high tags.
There is also an exclusive setting per line (True or False), it is used to show conflicts when multiple base tags are present in the image, if it's set to False, the conflict won't be shown.

Future Plans

Never hesitate to suggest new additions and improvements to the tagger, on our discord or any other place (you can send it to us through DMs on Discord or Civitai, but it's always better to ask to the both of use, because we could have a different opinion on the feature).

No promises for any future plans, but We are thinking of adding these features:

Near-future:

  • Better settings for the tagger and a more fluid experience to change the settings between databases and have more settings exposed.

  • We are currently experimenting with captions (LLM captions)

  • Better databases combinations, to migrate tags between databases

  • JPEG artifacts detection and basic artifacts detection and tagging them

  • integrating rough art/sketch art detection

Far-future:

  • Dynamic cropping for automatic character classification in combination with LLM captioning for precise and less prone to error tagging, character feature list to assist the LLM for the tagging part (less verbose)

  • Create a list of feature/attributes for common characters for LLM captioning, recommending potential missing tags and other potential features

Credits

Main creators:

Used Tools:

35

Comments