import imageio
from PIL import Image

def make_video(output_dir, num_file = 100):
    # Create the frames
    frames = []
    for i in range(num_file):
        new_frame = Image.open(output_dir + "iter/" + "iter_"+str(i)+".png")
        frames.append(new_frame)
    imageio.mimsave(output_dir+"video.gif", frames, duration=0.1)
