-
Notifications
You must be signed in to change notification settings - Fork 31
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
CUDA acceleration for VMAF #163
Comments
Seems possible. What we'd probably need is:
|
I would like to see it implemented too but unfortunately i dont think the ffmpeg part is ready so maybe an option to run vmaf from its binary and not via ffmpeg ? |
@alexheretic I'll keep an eye out for the ffmpeg implementation and will update accordingly. I also have nvidia hardware to test and will look into cuda detection. |
@TychoRasch https://github.com/Netflix/vmaf/blob/master/Dockerfile.cuda#L39 looks like their docker is running a patched ffmpeg |
@TychoRasch correction looks like libvmaf_cuda is in latest ffmpeg |
@alexheretic I know i was not part of the initial request, but i was looking for this and saw this in the FFMPEG docs, |
Works for me |
`/opt/ffmpeg_vmaf/bin/ffmpeg -hwaccel cuda -hwaccel_output_format cuda -codec:v h264_cuvid -i test.mp4 -hwaccel cuda -hwaccel_output_format cuda -codec:v h264_cuvid -i test.mp4 -filter_complex " [q] command received. Exiting. [Parsed_libvmaf_cuda_2 @ 0x7fb038005080] VMAF score: 99.265020 tail -n 20 output.json |
I've added an experimental branch throwing in the example args for CUDA accelerated vmaf #178. This should be easier to test now vmaf runs are simpler single process calls (since #177). Since I can't test myself please let me know how the args should be changed in the PR. E.g. how The PR can be installed locally with |
Here is what I get as output using the above PR with vmaf cuda ffmpeg build: D:>ab-av1 vmaf --cuda --reference source.mov --distorted test.mkv Could be wrong but the path should look like: libvmaf_cuda=model_path=vmaf_4k_v0.6.1 |
In addition to N-cards, there are also A-cards and Intel integrated graphics. Might consider purchasing a second-hand graphics card, which would be cheaper. Making full use of these hardware to accelerate VMAF calculations is a good thing. |
Any intention of adding this into main? I see the cuda branch is quote dated now. There is already a way to encode with av1_nvenc (from #201) so this would be the final step for full hw with nvidia cards. |
Any update here? |
With release v3.0.0 of VMAF, CUDA support has been added.
https://github.com/Netflix/vmaf/releases/tag/v3.0.0
Now it is my understanding that this speeds up the VMAF calculation enormously, with users on reddit claiming a 10x speedup. Is it possible to add an option to ab-av1 that allows for CUDA acceleration on the VMAF calculation if the user has an NVidia GPU?
The text was updated successfully, but these errors were encountered: