From bdb087fc7ea70f843101f11e6e0a71c5d1872c3f Mon Sep 17 00:00:00 2001 From: Brandon Thomas Date: Tue, 21 Jan 2025 22:53:35 -0500 Subject: [PATCH] change output dir param name --- animation/StableAnimator/inference_advanced.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/animation/StableAnimator/inference_advanced.py b/animation/StableAnimator/inference_advanced.py index a0ff0fa..560282c 100644 --- a/animation/StableAnimator/inference_advanced.py +++ b/animation/StableAnimator/inference_advanced.py @@ -150,7 +150,7 @@ def parse_args(): # TODO FIX parser.add_argument( - "--output_dir", + "--frame_output_dir", type=str, default=None, required=True @@ -438,7 +438,7 @@ if __name__ == "__main__": face_encoder=face_encoder, ).to(device='cuda', dtype=weight_dtype) - os.makedirs(args.output_dir, exist_ok=True) + os.makedirs(args.frame_output_dir, exist_ok=True) pose_images = prepare_pose_frames(args) num_frames = len(pose_images) @@ -492,14 +492,14 @@ if __name__ == "__main__": ).frames[0] out_file = os.path.join( - args.output_dir, + args.frame_output_dir, f"animation_video.mp4", ) for i in range(num_frames): img = video_frames[i] video_frames[i] = np.array(img) - png_out_file = os.path.join(args.output_dir, "animated_images") + png_out_file = os.path.join(args.frame_output_dir, "animated_images") os.makedirs(png_out_file, exist_ok=True) export_to_gif(video_frames, out_file, 8) save_frames_as_png(video_frames, png_out_file)