diff --git a/demo/animate.py b/demo/animate.py index b71f1940..7b31a161 100644 --- a/demo/animate.py +++ b/demo/animate.py @@ -125,7 +125,7 @@ def __init__(self, config="configs/prompts/animation.yaml") -> None: print("Initialization Done!") - def __call__(self, source_image, motion_sequence, random_seed, step, guidance_scale, size=512): + def __call__(self, source_image, motion_sequence, random_seed, step, guidance_scale, size=512, savedir = f"demo/outputs"): prompt = n_prompt = "" random_seed = int(random_seed) step = int(step) @@ -185,11 +185,10 @@ def __call__(self, source_image, motion_sequence, random_seed, step, guidance_sc samples_per_video = torch.cat(samples_per_video) time_str = datetime.datetime.now().strftime("%Y-%m-%dT%H-%M-%S") - savedir = f"demo/outputs" animation_path = f"{savedir}/{time_str}.mp4" os.makedirs(savedir, exist_ok=True) save_videos_grid(samples_per_video, animation_path) return animation_path - \ No newline at end of file +