Stability-AI / generative-models

Generative Models by Stability AI
MIT License
23.14k stars 2.56k forks source link

fix video writing issue #326 #327

Open wzds2015 opened 3 months ago

wzds2015 commented 3 months ago

Some issue in imageio api to write video. Switch to opencv and write one frame each time.

murphybread commented 3 months ago

Thanks to this, the mp4 comes out fine and is about 300 KB!

I'm getting that warning after the change, but what does it say? How does it affect the output of this project?

OpenCV: FFMPEG: tag 0x5634504d/'MP4V' is not supported with codec id 12 and format 'mp4 / MP4 (MPEG-4 Part 14)' OpenCV: FFMPEG: fallback to use tag 0x7634706d/'mp4v'

KenanHuang commented 3 months ago

The writting plugin requires imageio_ffmpeg or av plugin if you want to output a video.

The problem might be solved after trying the following command: apt-get update # step 1 apt-get install ffmpeg # step 2 pip install av imageio_ffmpeg # step 3