From 93120eb6b91f12d619570248242020bdf5c4cae2 Mon Sep 17 00:00:00 2001 From: Ethanfel Date: Fri, 27 Mar 2026 20:49:56 +0100 Subject: [PATCH] feat: auto-resolve synchformer checkpoint from prismaudio models dir When synchformer_ckpt input is empty, look for synchformer_state_dict.pth in the ComfyUI prismaudio models directory automatically. Co-Authored-By: Claude Sonnet 4.6 --- nodes/feature_extractor.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/nodes/feature_extractor.py b/nodes/feature_extractor.py index 3d750ca..200d6ef 100644 --- a/nodes/feature_extractor.py +++ b/nodes/feature_extractor.py @@ -170,6 +170,13 @@ class PrismAudioFeatureExtractor: "--cot_text", caption_cot, "--output", cached_path, ] + # Auto-resolve synchformer checkpoint from the prismaudio models dir + if not synchformer_ckpt: + import folder_paths + candidate = os.path.join(folder_paths.models_dir, "prismaudio", "synchformer_state_dict.pth") + if os.path.exists(candidate): + synchformer_ckpt = candidate + print(f"[PrismAudio] Auto-resolved synchformer checkpoint: {synchformer_ckpt}", flush=True) if synchformer_ckpt: cmd.extend(["--synchformer_ckpt", synchformer_ckpt])