Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
KhoiDOO committed Aug 11, 2024
1 parent 765bb19 commit cb652ef
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
7 changes: 7 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
accelerate==0.33.0
classifier-free-guidance-pytorch==0.6.10
denoising-diffusion-pytorch==2.0.12
imageio==2.34.2
opencv-python==4.10.0.84
scikit-learn==1.5.1
wandb==0.17.6
8 changes: 3 additions & 5 deletions utils/vid.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
from tqdm import tqdm
from PIL import Image

import imageio.v3 as iio
import argparse
import zipfile
import cv2
import os

Expand All @@ -27,8 +25,8 @@

video = cv2.VideoWriter(vid_path, 0, 1, (width, height))

for img in tqdm(imgs):
video.write(iio.imread(img))
for idx in tqdm(range(len(imgs))):
video.write(cv2.imread(os.path.join(runs_dir, f'sample-{idx+1}.png')))

cv2.destroyAllWindows()
cv2.destroyAllWindows()
video.release()

0 comments on commit cb652ef

Please sign in to comment.