import imageio
import os



fnames = []

for img in os.listdir("styled_mix"):
        fnames.append(os.path.join("styled_mix/", img))

fnames.sort()

with imageio.get_writer('content-mixed.gif', mode='I',duration = 0.9) as writer:
    for fname in fnames:
        image = imageio.imread(fname)
        writer.append_data(image)