bjoo commited on
Commit ·
3e81029
1
Parent(s): c60840a
Revert "Add files using upload-large-folder tool"
Browse filesThis reverts commit c60840a1cd24a85f427b09bc3ccaf77fd8b04974.
- _archive/nodes_unregistered/__init_old__.py +0 -35
- _archive/nodes_unregistered/gemini-code-1782954683883.py +0 -66
- _archive/nodes_unregistered/lora_classifier.py +0 -149
- _archive/workflows/0705_director.json +0 -0
- _archive/workflows/0705_optimized.json +0 -0
- dataset_builder/__pycache__/caption.cpython-313.pyc +0 -0
- dataset_builder/__pycache__/detect.cpython-313.pyc +0 -0
- dataset_builder/__pycache__/scene_split.cpython-313.pyc +0 -0
- dataset_builder/__pycache__/webui.cpython-313.pyc +0 -0
- dataset_builder/yolov8n.pt +0 -3
_archive/nodes_unregistered/__init_old__.py
DELETED
|
@@ -1,35 +0,0 @@
|
|
| 1 |
-
# __init__.py (통합 로더)
|
| 2 |
-
import traceback
|
| 3 |
-
|
| 4 |
-
NODE_CLASS_MAPPINGS = {}
|
| 5 |
-
NODE_DISPLAY_NAME_MAPPINGS = {}
|
| 6 |
-
|
| 7 |
-
def register_node(class_name, node_class, display_name):
|
| 8 |
-
NODE_CLASS_MAPPINGS[class_name] = node_class
|
| 9 |
-
NODE_DISPLAY_NAME_MAPPINGS[class_name] = display_name
|
| 10 |
-
|
| 11 |
-
# 리사이즈
|
| 12 |
-
try:
|
| 13 |
-
from .wan_resizer import WanNativeResize_Dolphin
|
| 14 |
-
register_node("WanNativeResize_Dolphin", WanNativeResize_Dolphin, "🐬 Wan Native Resize (Dolphin)")
|
| 15 |
-
except Exception as e: print(e)
|
| 16 |
-
|
| 17 |
-
# 트리플 매트릭스
|
| 18 |
-
try:
|
| 19 |
-
from .arch_logic_v16 import DolphinTripleLoraMatrix
|
| 20 |
-
register_node("DolphinTripleLoraMatrix", DolphinTripleLoraMatrix, "🐬 Dolphin Triple Lora Matrix (Wan 2.2)")
|
| 21 |
-
except Exception as e: print(e)
|
| 22 |
-
|
| 23 |
-
# 스토리 스플리터
|
| 24 |
-
try:
|
| 25 |
-
from .promp_logic_v32_story import DolphinMultiActionPromptNode_V32
|
| 26 |
-
register_node("DolphinMultiActionPromptNode_V32", DolphinMultiActionPromptNode_V32, "🐬 Dolphin Story Splitter V32")
|
| 27 |
-
except Exception as e: print(e)
|
| 28 |
-
|
| 29 |
-
# 디렉터
|
| 30 |
-
try:
|
| 31 |
-
from .dolphin_director import DolphinDirector
|
| 32 |
-
register_node("DolphinDirector", DolphinDirector, "🐬 Dolphin Director (V1)")
|
| 33 |
-
except Exception as e: print(e)
|
| 34 |
-
|
| 35 |
-
__all__ = ['NODE_CLASS_MAPPINGS', 'NODE_DISPLAY_NAME_MAPPINGS']
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_archive/nodes_unregistered/gemini-code-1782954683883.py
DELETED
|
@@ -1,66 +0,0 @@
|
|
| 1 |
-
import json
|
| 2 |
-
|
| 3 |
-
def convert_workflow(input_file, output_file):
|
| 4 |
-
with open(input_file, 'r', encoding='utf-8') as f:
|
| 5 |
-
data = json.load(f)
|
| 6 |
-
|
| 7 |
-
for node in data.get('nodes', []):
|
| 8 |
-
# 1. Story Splitter 구버전 -> V32 최신버전으로 교체
|
| 9 |
-
if node.get('type', '').startswith('DolphinMultiActionPromptNode_'):
|
| 10 |
-
node['type'] = 'DolphinMultiActionPromptNode_V32'
|
| 11 |
-
|
| 12 |
-
# 2. Architect V15/V16 -> Triple Lora Matrix 로 교체
|
| 13 |
-
if node.get('type', '').startswith('DolphinArchitect'):
|
| 14 |
-
node_id = node['id']
|
| 15 |
-
node['type'] = 'DolphinTripleLoraMatrix'
|
| 16 |
-
|
| 17 |
-
# [입력 슬롯 최적화]
|
| 18 |
-
# 구버전의 3개 모델 입력창을 제거하고, 1개의 통합 'model' 입력으로 전환
|
| 19 |
-
new_inputs = []
|
| 20 |
-
for inp in node.get('inputs', []):
|
| 21 |
-
if inp['name'] == 'model_base':
|
| 22 |
-
inp['name'] = 'model' # 슬롯 0번 유지
|
| 23 |
-
new_inputs.append(inp)
|
| 24 |
-
node['inputs'] = new_inputs
|
| 25 |
-
|
| 26 |
-
# [출력 슬롯 재구성]
|
| 27 |
-
# 새로운 노드의 7개 출력(M_BASE, C_BASE, M_HIGH, C_HIGH, M_LOW, C_LOW, string)에 맞춤
|
| 28 |
-
node['outputs'] = [
|
| 29 |
-
{"name": "M_BASE", "type": "MODEL", "links": []},
|
| 30 |
-
{"name": "C_BASE", "type": "CLIP", "links": []},
|
| 31 |
-
{"name": "M_HIGH", "type": "MODEL", "links": []},
|
| 32 |
-
{"name": "C_HIGH", "type": "CLIP", "links": []},
|
| 33 |
-
{"name": "M_LOW", "type": "MODEL", "links": []},
|
| 34 |
-
{"name": "C_LOW", "type": "CLIP", "links": []},
|
| 35 |
-
{"name": "applied_loras", "type": "STRING", "links": []}
|
| 36 |
-
]
|
| 37 |
-
|
| 38 |
-
# [위젯 초기화]
|
| 39 |
-
# 24개짜리 무거운 UI를 지우고, 가벼운 콤보+텍스트 UI로 리셋
|
| 40 |
-
node['widgets_values'] = [
|
| 41 |
-
"None", "0.5, 0.2, 0.5",
|
| 42 |
-
"None", "1.0, 0.5, 0.0",
|
| 43 |
-
"None", "1.0, 1.0, 1.0"
|
| 44 |
-
]
|
| 45 |
-
|
| 46 |
-
# [링크(선) 지능형 재연결]
|
| 47 |
-
# M_HIGH와 M_LOW의 출력 포트 번호가 변경된 것을 찾아 선을 다시 이어줌
|
| 48 |
-
for link in data.get('links', []):
|
| 49 |
-
# link = [link_id, origin_id, origin_slot, target_id, target_slot, type]
|
| 50 |
-
if link[1] == node_id:
|
| 51 |
-
if link[2] == 1: # 구버전 M_HIGH
|
| 52 |
-
link[2] = 2 # 신버전 M_HIGH 포트(2번)로 이동
|
| 53 |
-
node['outputs'][2]['links'].append(link[0])
|
| 54 |
-
elif link[2] == 2: # 구버전 M_LOW
|
| 55 |
-
link[2] = 4 # 신버전 M_LOW 포트(4번)로 이동
|
| 56 |
-
node['outputs'][4]['links'].append(link[0])
|
| 57 |
-
elif link[2] == 0: # M_BASE는 그대로 유지
|
| 58 |
-
node['outputs'][0]['links'].append(link[0])
|
| 59 |
-
|
| 60 |
-
with open(output_file, 'w', encoding='utf-8') as f:
|
| 61 |
-
json.dump(data, f, indent=4)
|
| 62 |
-
|
| 63 |
-
print(f"✅ 변환 완료! 생성된 '{output_file}' 파일을 ComfyUI에 드래그 앤 드롭 하세요.")
|
| 64 |
-
|
| 65 |
-
# 스크립트 실행
|
| 66 |
-
convert_workflow('0705_optimized.json', '0705_v32_matrix.json')
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_archive/nodes_unregistered/lora_classifier.py
DELETED
|
@@ -1,149 +0,0 @@
|
|
| 1 |
-
# -*- coding: utf-8 -*-
|
| 2 |
-
"""
|
| 3 |
-
LoRA Manager 로컬 DB(civitai에서 스캔 시 이미 긁어온 태그/메타데이터)를 읽어서
|
| 4 |
-
WAN 계열 로라만 골라 1차 자동 분류 결과를 JSON으로 뽑는다.
|
| 5 |
-
|
| 6 |
-
분류 축 2개:
|
| 7 |
-
1) 기술 호환성: wan_version(2.1/2.2/unknown), variant(i2v/t2v/unknown),
|
| 8 |
-
stage(high/low/base-or-single) - 전부 filename + base_model 필드에서 추출
|
| 9 |
-
2) 행위/내용 카테고리: civitai에서 스캔한 model_tags를 미리 정한 카테고리
|
| 10 |
-
사전에 매핑 (여러 개 중복 가능 - 로라 하나가 pov+anal 같이 여러 태그를 가질 수 있음)
|
| 11 |
-
|
| 12 |
-
DB 자체를 수정하지 않는다(읽기 전용). 결과는 review용 JSON 하나로 뽑아서,
|
| 13 |
-
사람이 눈으로 훑고 필요하면 손으로 고칠 수 있게 한다 - 자동분류 결과를 그대로
|
| 14 |
-
자동 적용(로라 자동 선택)하는 건 지난번에 "예외 동작이 너무 많다"고 명시적으로
|
| 15 |
-
거부하셨던 방향이라 이 스크립트는 딱 "분류표 생성"까지만 한다.
|
| 16 |
-
"""
|
| 17 |
-
import sqlite3
|
| 18 |
-
import json
|
| 19 |
-
import os
|
| 20 |
-
import re
|
| 21 |
-
|
| 22 |
-
DB_PATH = os.path.join(
|
| 23 |
-
os.environ.get("LOCALAPPDATA", ""), "ComfyUI-LoRA-Manager", "cache", "model", "comfyui.sqlite")
|
| 24 |
-
OUT_PATH = os.path.join(os.path.dirname(__file__), "dolphin_lora_classification.json")
|
| 25 |
-
|
| 26 |
-
# 태그 -> 카테고리. 순서는 우선순위(먼저 매치되는 걸 "primary"로 씀). 카테고리 자체는
|
| 27 |
-
# 중복 허용(한 로라가 여러 카테고리에 다 들어갈 수 있음).
|
| 28 |
-
CATEGORY_TAG_MAP = {
|
| 29 |
-
"oral": {"oral", "blowjob", "deepthroat", "fellatio", "irrumatio"},
|
| 30 |
-
"anal": {"anal"},
|
| 31 |
-
"position_action": {"cowgirl", "doggystyle", "missionary", "riding", "sex", "penetration",
|
| 32 |
-
"reverse cowgirl", "standing sex", "piledriver"},
|
| 33 |
-
"masturbation": {"masturbation", "fingering", "handjob"},
|
| 34 |
-
"pov": {"pov"},
|
| 35 |
-
"fetish_other": {"futanari", "bdsm", "feet", "pee", "piss", "cum", "creampie", "squirting"},
|
| 36 |
-
"character_identity": {"character", "celebrity"},
|
| 37 |
-
"style_render": {"photorealistic", "realistic", "anime", "style", "illustrious"},
|
| 38 |
-
"toy_prop": {"sex toy", "dildo", "sex machine", "vibrator"},
|
| 39 |
-
"kink_dynamic": {"femdom", "bdsm"},
|
| 40 |
-
"dance_movement": {"dance", "poses", "pose"},
|
| 41 |
-
# 콘텐츠 카테고리가 아니라 "이 로라 자체가 lightx2v류 가속/증류 로라"라는 표시.
|
| 42 |
-
# 클립 콘텐츠용 로라 풀에서 걸러내야 할 대상 - Model Loader에서 이미 쓰는 것과
|
| 43 |
-
# 겹치는 속도용 로라를 실수로 클립 로라 슬롯에 넣지 않도록 구분해둔다.
|
| 44 |
-
"speed_distillation": {"distill", "distillation", "fast", "faster", "speed up", "lightning",
|
| 45 |
-
"lightx2v", "accelerator"},
|
| 46 |
-
}
|
| 47 |
-
|
| 48 |
-
FILENAME_STAGE_RE = re.compile(r"(high[_-]?noise|_high\b)", re.IGNORECASE)
|
| 49 |
-
FILENAME_LOW_RE = re.compile(r"(low[_-]?noise|_low\b)", re.IGNORECASE)
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
def classify_wan_version(base_model, file_name):
|
| 53 |
-
bm = (base_model or "").lower()
|
| 54 |
-
fn = (file_name or "").lower()
|
| 55 |
-
if "2.2" in bm or "2.2" in fn or "wan2.2" in fn or "wan22" in fn:
|
| 56 |
-
version = "2.2"
|
| 57 |
-
elif "wan video 14b" in bm or "2.1" in bm or "wan2.1" in fn or "wan21" in fn:
|
| 58 |
-
version = "2.1"
|
| 59 |
-
elif bm.startswith("wan"):
|
| 60 |
-
version = "unknown-wan"
|
| 61 |
-
else:
|
| 62 |
-
version = None # WAN 계열 아님(Flux/Pony/SDXL 등) - 호출부에서 걸러냄
|
| 63 |
-
if "i2v" in bm or "i2v" in fn:
|
| 64 |
-
variant = "i2v"
|
| 65 |
-
elif "t2v" in bm or "t2v" in fn:
|
| 66 |
-
variant = "t2v"
|
| 67 |
-
else:
|
| 68 |
-
variant = "unknown"
|
| 69 |
-
return version, variant
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
def classify_stage(file_name):
|
| 73 |
-
fn = file_name or ""
|
| 74 |
-
if FILENAME_STAGE_RE.search(fn):
|
| 75 |
-
return "high"
|
| 76 |
-
if FILENAME_LOW_RE.search(fn):
|
| 77 |
-
return "low"
|
| 78 |
-
return "base_or_single" # high/low 구분 없는 단일 파일 (base 겸용이거나 non-split)
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
def main():
|
| 82 |
-
if not os.path.exists(DB_PATH):
|
| 83 |
-
print(f"❌ LoRA Manager DB를 못 찾음: {DB_PATH}")
|
| 84 |
-
return
|
| 85 |
-
|
| 86 |
-
con = sqlite3.connect(f"file:{DB_PATH}?mode=ro", uri=True)
|
| 87 |
-
cur = con.cursor()
|
| 88 |
-
cur.execute("""
|
| 89 |
-
SELECT file_path, file_name, base_model, trained_words, notes, usage_tips
|
| 90 |
-
FROM models WHERE model_type='lora'
|
| 91 |
-
""")
|
| 92 |
-
rows = cur.fetchall()
|
| 93 |
-
|
| 94 |
-
cur.execute("SELECT file_path, tag FROM model_tags WHERE model_type='lora'")
|
| 95 |
-
tags_by_path = {}
|
| 96 |
-
for file_path, tag in cur.fetchall():
|
| 97 |
-
tags_by_path.setdefault(file_path, []).append(tag)
|
| 98 |
-
con.close()
|
| 99 |
-
|
| 100 |
-
results = []
|
| 101 |
-
skipped_non_wan = 0
|
| 102 |
-
for file_path, file_name, base_model, trained_words, notes, usage_tips in rows:
|
| 103 |
-
version, variant = classify_wan_version(base_model, file_name)
|
| 104 |
-
if version is None:
|
| 105 |
-
skipped_non_wan += 1
|
| 106 |
-
continue
|
| 107 |
-
|
| 108 |
-
tags = set(t.lower() for t in tags_by_path.get(file_path, []))
|
| 109 |
-
categories = [cat for cat, keywords in CATEGORY_TAG_MAP.items() if tags & keywords]
|
| 110 |
-
|
| 111 |
-
try:
|
| 112 |
-
trained = json.loads(trained_words) if trained_words else []
|
| 113 |
-
except (ValueError, TypeError):
|
| 114 |
-
trained = []
|
| 115 |
-
|
| 116 |
-
results.append({
|
| 117 |
-
"file_name": file_name,
|
| 118 |
-
"file_path": file_path,
|
| 119 |
-
"wan_version": version,
|
| 120 |
-
"variant": variant,
|
| 121 |
-
"stage": classify_stage(file_name),
|
| 122 |
-
"categories": categories or ["uncategorized"],
|
| 123 |
-
"trigger_words": trained,
|
| 124 |
-
"raw_tags": sorted(tags),
|
| 125 |
-
"notes": notes or "",
|
| 126 |
-
"usage_tips": usage_tips or "",
|
| 127 |
-
})
|
| 128 |
-
|
| 129 |
-
results.sort(key=lambda r: (r["wan_version"], r["variant"], r["file_name"]))
|
| 130 |
-
|
| 131 |
-
with open(OUT_PATH, "w", encoding="utf-8") as f:
|
| 132 |
-
json.dump(results, f, ensure_ascii=False, indent=1)
|
| 133 |
-
|
| 134 |
-
print(f"✅ WAN 계열 로라 {len(results)}개 분류 완료 (비WAN {skipped_non_wan}개 제외)")
|
| 135 |
-
print(f" -> {OUT_PATH}")
|
| 136 |
-
|
| 137 |
-
from collections import Counter
|
| 138 |
-
ver_counts = Counter((r["wan_version"], r["variant"]) for r in results)
|
| 139 |
-
print("\n버전/variant 분포:")
|
| 140 |
-
for k, v in ver_counts.most_common():
|
| 141 |
-
print(f" {k}: {v}")
|
| 142 |
-
cat_counts = Counter(c for r in results for c in r["categories"])
|
| 143 |
-
print("\n카테고리 분포:")
|
| 144 |
-
for k, v in cat_counts.most_common():
|
| 145 |
-
print(f" {k}: {v}")
|
| 146 |
-
|
| 147 |
-
|
| 148 |
-
if __name__ == "__main__":
|
| 149 |
-
main()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
_archive/workflows/0705_director.json
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
_archive/workflows/0705_optimized.json
DELETED
|
The diff for this file is too large to render.
See raw diff
|
|
|
dataset_builder/__pycache__/caption.cpython-313.pyc
DELETED
|
Binary file (13.6 kB)
|
|
|
dataset_builder/__pycache__/detect.cpython-313.pyc
DELETED
|
Binary file (6.49 kB)
|
|
|
dataset_builder/__pycache__/scene_split.cpython-313.pyc
DELETED
|
Binary file (10.5 kB)
|
|
|
dataset_builder/__pycache__/webui.cpython-313.pyc
DELETED
|
Binary file (25.6 kB)
|
|
|
dataset_builder/yolov8n.pt
DELETED
|
@@ -1,3 +0,0 @@
|
|
| 1 |
-
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:f59b3d833e2ff32e194b5bb8e08d211dc7c5bdf144b90d2c8412c47ccfc83b36
|
| 3 |
-
size 6549796
|
|
|
|
|
|
|
|
|
|
|
|