mirror of
https://github.com/THUDM/CogVideo.git
synced 2025-06-14 20:09:18 +08:00
Merge pull request #121 from HaiyiMei/patch-1
Fix bug of `cli_vae_demo.py` when `args.mode == "both"`
This commit is contained in:
commit
edc382c74f
@ -133,5 +133,6 @@ if __name__ == "__main__":
|
|||||||
elif args.mode == "both":
|
elif args.mode == "both":
|
||||||
assert args.video_path, "Video path must be provided for encoding."
|
assert args.video_path, "Video path must be provided for encoding."
|
||||||
encoded_output = encode_video(args.model_path, args.video_path, dtype, device)
|
encoded_output = encode_video(args.model_path, args.video_path, dtype, device)
|
||||||
|
torch.save(encoded_output, args.output_path + "/encoded.pt")
|
||||||
decoded_output = decode_video(args.model_path, args.output_path + "/encoded.pt", dtype, device)
|
decoded_output = decode_video(args.model_path, args.output_path + "/encoded.pt", dtype, device)
|
||||||
save_video(decoded_output, args.output_path)
|
save_video(decoded_output, args.output_path)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user