Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to output file as MP4? #328

Open
waqasazizbabre opened this issue Jul 19, 2023 · 3 comments
Open

How to output file as MP4? #328

waqasazizbabre opened this issue Jul 19, 2023 · 3 comments

Comments

@waqasazizbabre
Copy link

waqasazizbabre commented Jul 19, 2023

--png gives a folder with png sequence. How can I save as mp4?

I get this error. and the video does not save.

Traceback (most recent call last):
  File "/content/arXiv2020-RIFE/inference_video.py", line 294, in <module>
    os.rename(targetNoAudio, vid_out_name)
FileNotFoundError: [Errno 2] No such file or directory: 'video1_4X_99fps_noaudio.mp4' -> 'video1_4X_99fps.mp4'
@hzwer
Copy link
Owner

hzwer commented Jul 20, 2023

I'm not too sure why your mp4 can't be exported. I personally recommend using mmfpeg to process png images to mp4.

@waqasazizbabre
Copy link
Author

ffmpeg -r 60 -f image2 -s 1920x1080 -i pic%04d.png -vcodec libx264 -crf 25  -pix_fmt yuv420p test.mp4

I found the above but I don't know how can I tell to pick the outputted folder in this command

Also, originally, I wanted to ask how can I set the output format to mp4?
I know its --png for PNG sequence but I don't know what is it for MP4? is it --mp4??
Sorry I am learning

@waqasazizbabre
Copy link
Author

the size of every interpolated png is 1.5 MB(1080p). which makes a 2 minutes video like 20GB or so. I don't want to export into PNG. This is the same when I use RIFE in flowframes. video formats result in smaller size for flowframes. thats why I wanted to know how to export into video formats.

and thanks for your reply

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants