Support multi models.

This commit is contained in:
corkborg
2023-12-28 02:28:15 +09:00
parent 57bc257b94
commit ba6c3b640a
5 changed files with 176 additions and 17 deletions
+21 -5
View File
@@ -5,16 +5,16 @@ forked from [https://github.com/picobyte/stable-diffusion-webui-wd14-tagger]()
## install
```
venv/bin/python -m venv venv
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt
```
## usage
```
usage: run.py [-h] [--dir DIR | --file FILE] [--threthold THRETHOLD] [--ext EXT]
usage: run.py [-h] (--dir DIR | --file FILE) [--threthold THRETHOLD] [--ext EXT]
[--model {wd14-vit.v1,wd14-vit.v2,wd14-convnext.v1,wd14-convnext.v2,wd14-convnextv2.v1,wd14-swinv2-v1,wd-v1-4-moat-tagger.v2,mld-caformer.dec-5-97527,mld-tresnetd.6-30000}]
options:
-h, --help show this help message and exit
@@ -23,16 +23,32 @@ options:
--threthold THRETHOLD
予測値の足切り確率(デフォルトは0.35)
--ext EXT dirの場合にキャプションファイルにつける拡張子
--model {wd14-vit.v1,wd14-vit.v2,wd14-convnext.v1,wd14-convnext.v2,wd14-convnextv2.v1,wd14-swinv2-v1,wd-v1-4-moat-tagger.v2,mld-caformer.dec-5-97527,mld-tresnetd.6-30000}
予測に使用するモデル名
```
single file
```
python3 run.py --file image.jpg
python run.py --file image.jpg
```
batch execution
```
python3 run.py --dir dir/dir
python run.py --dir dir/dir
```
## Support Models
```
python run.py --file image.jpg --model wd14-vit.v1
python run.py --file image.jpg --model wd14-vit.v2
python run.py --file image.jpg --model wd14-convnext.v1
python run.py --file image.jpg --model wd14-convnext.v2
python run.py --file image.jpg --model wd14-convnextv2.v1
python run.py --file image.jpg --model wd14-swinv2-v1
python run.py --file image.jpg --model wd-v1-4-moat-tagger.v2
python run.py --file image.jpg --model mld-caformer.dec-5-97527
python run.py --file image.jpg --model mld-tresnetd.6-30000
```