latimaging.blogg.se

Waifu2x ffmpeg tutorial
Waifu2x ffmpeg tutorial









waifu2x ffmpeg tutorial
  1. #Waifu2x ffmpeg tutorial how to
  2. #Waifu2x ffmpeg tutorial software

#Waifu2x ffmpeg tutorial software

  • upscaled_video.mp4 is the name of the output video file.If I'm read the information in the link correctly, you just log in to Google Colab (remote into it?) instal Video2X and all its dependencies and then run the software like normal, it just outputs to your Google drive.
  • wav file) to the output stream (the video)
  • -acodec copy tells FFmpeg to copy the audio from the input stream (the.
  • I chose yuv420p because it is one of the most compatible pixel formats. The lower number the higher the quality but the larger the file size, with a range of 15-25 a good trade-off between file size and quality. Libx264 is a widely supported codec, so a safe bet.
  • vcodec libx264 is the codec you're using.
  • original-audio.wav is the audio file you want to combine with the frames into a video.
  • Change example to the text you chose in step 3.
  • example%04d.jpg is the way the frames you upscaled are named.
  • This should be the same as the upscaled images, in my case 1440x1080. It depends on the original video's frame rate. 29.970628 is a common fps for older American shows, but it could be 24, 30, or 60.
  • -r is the frame rate of the exported file.
  • Type in:įfmpeg -r 29.970628 -f image2 -s 1440x1080 -i example%04d.jpg -i original-audio.wav -vcodec libx264 -crf 20 -pix_fmt yuv420p -acodec copy upscaled_video.mp4
  • Now you will give FFmpeg the command to combine the frames and the audio.
  • waifu2x ffmpeg tutorial

    The part after cd depends on where your work folder is of course. Do this by typing in: cd C:\Users\UserName \Desktop\upscale-projects\example\frames-upscaled.

  • Copy ffmpeg.exe into the example/frames-upscaled folder.
  • Move the exported audio file to example/frames-upscaled.
  • Once AI Gigapixel is done upscaling the frames, you can combine these frames with the audio into a video. It could take a day/multiple days to convert an entire episode/movie depending on the length and the upscaled resolution (4K takes a lot longer than 1080p). How fast the entire upscaling process also depends on your PC. You'll just have to find out for yourself. How many frames you can upscale in one go depends on your PC's specs. Upscaling an entire episode can take a long time, so start small. Select a few hundred frames when first getting your footing with this whole workflow and drag and drop them in the window. Once you have a working set of settings, you can start upscaling footage. Change the settings until you are happy with the results. In the preview window, you can see the result of the upcoming upscale.
  • Keep Color Profile to Yes, as it's faster.
  • The few artifacts created by the JPG format at Maximum Quality won't be noticed when you later convert the frames to a video. Since the original is PNG, you will need to choose Convert File Format: Yes. It is smaller and results in a fast upscale process.
  • For video it's best to output in JPG format.
  • I save to a Custom Folder and point it to upscale-projects\example\frames-upscaled.
  • I chose Low and Low, as it gave just a bit of smoothing/noise removal without going overboard. Just try out everything to see what gives the best result for your project.
  • Suppress Noise and Remove Blur can improve the quality of the end result.
  • I want to make the upscaled image have the height of 4K footage, so I input 2160 pixels.
  • You can base the upscale's resolution by scale, width or height.
  • Personal preference.īelow I will explain what all the settings mean:
  • -hide_banner hides FFmpeg compilation information.
  • PNG is bigger than JPG, but JPG creates extra artifacts that the upscaling program can't handle very well. png is the extension of the exported file. Adding text before the frame number helps to keep multiple video's worths of extracted frames organized.

    #Waifu2x ffmpeg tutorial how to

    example%04d tells FFmpeg how to name the frames (example0001.png, example0002, etc.).

    waifu2x ffmpeg tutorial

    Change it to the name and extension of your source video file.

  • example.mkv is the source file in my case.
  • Type in:įfmpeg -i example.mkv example%04d.png -hide_banner
  • Now you will give FFmpeg the command to export the frames.
  • waifu2x ffmpeg tutorial

    Do this by typing in: cd C:\Users\UserName \Desktop\upscale-projects\example\video. Put ffmpeg.exe in the folder you also put your source video into.Get your source video and put it into example/video.











    Waifu2x ffmpeg tutorial