Fix issue with ltx caching

This commit is contained in:
Jaret Burkett
2026-08-30 11:01:52 -06:00
parent 764b5064fb
commit 74ed5fddb0
4 changed files with 54 additions and 15 deletions

View File

@@ -21,6 +21,7 @@ import argparse
import glob
import json
import os
import shutil
import subprocess
import sys
import time
@@ -235,7 +236,10 @@ def run_one(
out_dir = os.path.join(out_dir, f"qtype_{qtype_override}")
os.makedirs(out_dir, exist_ok=True)
for old in glob.glob(os.path.join(out_dir, "*")):
os.remove(old)
if os.path.isdir(old):
shutil.rmtree(old)
else:
os.remove(old)
from toolkit.config_modules import GenerateImageConfig, ModelConfig
from toolkit.util.get_model import get_model_class