diff --git a/deploy/gpu_worker/gpu_worker.py b/deploy/gpu_worker/gpu_worker.py index 72bb73aed..a3ace3b11 100644 --- a/deploy/gpu_worker/gpu_worker.py +++ b/deploy/gpu_worker/gpu_worker.py @@ -22,7 +22,6 @@ from __future__ import annotations -import json import logging import os import platform @@ -200,9 +199,7 @@ def _download(url: str, path: Path) -> bool: return False -def _call_musetalk( - video_path: Path, audio_path: Path, out_path: Path -) -> tuple[bool, float, str, bool]: +def _call_musetalk(video_path: Path, audio_path: Path, out_path: Path) -> tuple[bool, float, str, bool]: """调用本地 MuseTalk /inference. 返回 (success, duration_seconds, error_msg, retryable)。 @@ -245,9 +242,13 @@ def _probe_duration(path: Path) -> float: out = subprocess.check_output( [ - "ffprobe", "-v", "error", - "-show_entries", "format=duration", - "-of", "default=noprint_wrappers=1:nokey=1", + "ffprobe", + "-v", + "error", + "-show_entries", + "format=duration", + "-of", + "default=noprint_wrappers=1:nokey=1", str(path), ], stderr=subprocess.DEVNULL,