easyVmaf
easyVmaf copied to clipboard
Can it support CUDA acceleration?
Hi,
libVmaf seems to be able to use CUDA for computational acceleration(https://github.com/Netflix/vmaf/pull/1185), which is a great improvement. easyVmaf can support this feature? Using the CPU for computation is a bit slow.
Thank you.
Hi @sirstrone
Sorry for my late reply, easyVmaf is just a wrapper to automatically deal with the preprocessing required for VMAF computations. So it fully rely on ffmpeg and libvmaf at the end of the day. I just took a look to cuda option, I would say it is not supported but should be really simply to add it.
would be great if someone can share some sample ffmpeg commands to compute vmaf with cuda to get started.
Hi @gdavila
Thank you for your reply.
I previously tried following the vmaf-cuda PR and compiled an FFmpeg integrated with LibVmaf-cuda. Its usage is very simple; you just need to replace the inputCmd.
inputCmd = f'-hwaccel cuda -hwaccel_output_format cuda -an {self.main.videoSrc} -hwaccel cuda -hwaccel_output_format cuda -an {self.ref.videoSrc} -map 0:v -map 1:v'
However, currently, this PR only supports Vmaf's CUDA acceleration and seems to lack support for SSIM and other metrics computation. I am not sure how to replace the SSIM alignment part of easyVmaf.
FYI VMAF 3.0 includes native cuda support. Perhaps this can be revisited?