Views
No views yet
eva02_large_patch14_448.mim_m38m_ft_in22k_in1kanimetimm/e621-wdtagger-v1-w640-ws-full| # | Macro@0.40 (F1/MCC/P/R) | Micro@0.40 (F1/MCC/P/R) | Macro@Best (F1/P/R) |
|---|---|---|---|
| Validation | 0.678 / 0.685 / 0.546 / 0.935 | 0.472 / 0.531 / 0.322 / 0.884 | 0.427 / 0.440 / 0.449 |
| Test | 0.677 / 0.685 / 0.545 / 0.935 | 0.472 / 0.531 / 0.322 / 0.884 | 0.425 / 0.436 / 0.450 |
Full-split evaluation completed on validation/test (185k+ samples each).
| Category | Name | Alpha | Threshold | Micro@Thr (F1/P/R) | Macro@0.40 (F1/P/R) | Macro@Best (F1/P/R) |
|---|---|---|---|---|---|---|
| 0 | general | 1 | 0.60 | 0.631 / 0.684 / 0.585 | 0.263 / 0.177 / 0.568 | 0.352 / 0.358 / 0.386 |
| 4 | character | 1 | 0.65 | 0.895 / 0.941 / 0.853 | 0.715 / 0.598 / 0.922 | 0.872 / 0.906 / 0.847 |
| 5 | species | 1 | 0.60 | 0.836 / 0.848 / 0.824 | 0.544 / 0.421 / 0.825 | 0.712 / 0.761 / 0.682 |
| 9 | rating | 1 | 0.65 | 0.912 / 0.918 / 0.906 | 0.813 / 0.700 / 0.989 | 0.884 / 0.869 / 0.903 |
Micro@Thr uses category-level thresholds from thresholds.json.Macro/Micro@0.40 uses fixed threshold 0.40.Macro@Best uses tag-level best-threshold search on evaluation splits.0.48.selected_tags.csv currently stores category-level thresholds as initial best_threshold; it will be replaced by real tag-level thresholds after full evaluation.eva02_large_E621_FULL_V1eva02_large_E621_FULL_V1/model.onnxeva02_large_E621_FULL_V1/model.onnx.dataeva02_large_E621_FULL_V1/model.safetensorseva02_large_E621_FULL_V1/preprocess.jsoneva02_large_E621_FULL_V1/selected_tags.csveva02_large_E621_FULL_V1/tags.jsoneva02_large_E621_FULL_V1/thresholds.jsoneva02_large_E621_FULL_V1/config.jsonmodel.onnxmodel.onnx.dataselected_tags.csvtags.json (optional helper metadata)thresholds.json (optional helper thresholds)hf download nzs234/eva02_large_E621_FULL_V1 model.onnx model.onnx.data selected_tags.csv tags.json thresholds.json --repo-type model --local-dir ./eva02_large_E621_FULL_V11import json
2import numpy as np
3import onnxruntime as ort
4from PIL import Image
5from huggingface_hub import hf_hub_download
6
7repo = "nzs234/eva02_large_E621_FULL_V1"
8
9onnx_path = hf_hub_download(repo_id=repo, filename="model.onnx")
10_ = hf_hub_download(repo_id=repo, filename="model.onnx.data")
11tags_path = hf_hub_download(repo_id=repo, filename="tags.json")
12thr_path = hf_hub_download(repo_id=repo, filename="thresholds.json")
13
14sess = ort.InferenceSession(onnx_path, providers=["CUDAExecutionProvider", "CPUExecutionProvider"])
15input_name = sess.get_inputs()[0].name
16
17with open(tags_path, "r", encoding="utf-8") as f:
18 tags = json.load(f)
19
20# You can preprocess with the same logic described in preprocess.json
21img = Image.open("your_image.jpg").convert("RGB").resize((448, 448))
22x = np.asarray(img).astype(np.float32) / 255.0
23x = np.transpose(x, (2, 0, 1))[None, ...]
24
25pred = sess.run(None, {input_name: x})[0][0]
26print("num_tags:", pred.shape[0])model.safetensors is also provided for PyTorch-side workflows and conversion pipelines.stable-diffusion-webui-wd14-tagger, put files under a model folder, for example:1stable-diffusion-webui/extensions/stable-diffusion-webui-wd14-tagger/models/eva02_large_E621_FULL_V1/
2 model.onnx
3 model.onnx.data
4 selected_tags.csv
5 tags.json
6 thresholds.jsoneva02_large_E621_FULL_V1 in the extension model dropdown.selected_tags.csv is required by most WD14-style UIs.tags.json and thresholds.json are optional for plain WD14 UI, but useful for custom tools.model.onnx and model.onnx.data in the same folder.animetimm/swinv2_base_window8_256.e621v1-full