VMAF 的全称是:Visual Multimethod Assessment Fusion,视频质量多方法评价融合。这项技术是由美国Netflix公司开发的一套主观视频质量评价体系。2016年1月,VMAF 正式开源;
官网下载地址:https://github.com/Netflix/vmaf
根据官网介绍160606 VMAF:Toward A Practical Perceptual Video Quality Metric
上图可以看到从4个不同畸变视频截取出的静态画面的局部内容,上方两个视频检测出其PSNR值为大约31dB,下方两个的PSNR值约为34dB。人们很难察觉“人群”视频有何差异,但两个“狐狸”视频的差异就很明显了。人类观察者针对两个“人群”视频给出的DMOS分数分别为82(上方)和96(下方),而两个“狐狸”视频的DMOS分数分别为27和58。
VMAF引入深度学习机制,进行更符合人眼视觉的视频评价标准。进行视频质量评分。
在vmaf-master\model文件夹下,有一些训练好的模型数据,可以根据自己的实际需要,进行评测。
\vmaf-master\x64\Release>vmafossexec
Usage: vmafossexec fmt width height ref_path dis_path model_path
[--log log_path] [--log-fmt log_fmt] [--thread n_thread] [--subsample n_subsample]
[--disable-clip] [--disable-avx] [--psnr] [--ssim] [--ms-ssim] [--phone-model] [--ci]
fmt:
yuv420p
yuv422p
yuv444p
yuv420p10le
yuv422p10le
yuv444p10le
log_fmt:
xml (default)
json
n_thread:
maximum threads to use (default 0 - use all threads)
n_subsample:
n indicates computing on one of every n frames (default 1)
vmafossexec yuv420p 640 480 orignal5.yuv test.yuv vmaf_v0.6.1.pkl --psnr --ssim --log test.txt
1、命令行
ffmpeg -s 640x480 -i orignal5.yuv -s 640x480 -i 1.yuv -lavfi libvmaf =”ssim=1:enable_transform=1:log_path=mylog.txt” -f null –
2、源码
ff_vf_libvmaf
3、可配参数
static const AVOption libvmaf_options[] = {
{"model_path", "Set the model to be used for computing vmaf.", OFFSET(model_path), AV_OPT_TYPE_STRING, {.str="/usr/local/share/model/vmaf_v0.6.1.pkl"}, 0, 1, FLAGS},
{"log_path", "Set the file path to be used to store logs.", OFFSET(log_path), AV_OPT_TYPE_STRING, {.str=NULL}, 0, 1, FLAGS},
{"log_fmt", "Set the format of the log (xml or json).", OFFSET(log_fmt), AV_OPT_TYPE_STRING, {.str=NULL}, 0, 1, FLAGS},
{"enable_transform", "Enables transform for computing vmaf.", OFFSET(enable_transform), AV_OPT_TYPE_BOOL, {.i64=0}, 0, 1, FLAGS},
{"phone_model", "Invokes the phone model that will generate higher VMAF scores.", OFFSET(phone_model), AV_OPT_TYPE_BOOL, {.i64=0}, 0, 1, FLAGS},
{"psnr", "Enables computing psnr along with vmaf.", OFFSET(psnr), AV_OPT_TYPE_BOOL, {.i64=0}, 0, 1, FLAGS},
{"ssim", "Enables computing ssim along with vmaf.", OFFSET(ssim), AV_OPT_TYPE_BOOL, {.i64=0}, 0, 1, FLAGS},
{"ms_ssim", "Enables computing ms-ssim along with vmaf.", OFFSET(ms_ssim), AV_OPT_TYPE_BOOL, {.i64=0}, 0, 1, FLAGS},
{"pool", "Set the pool method to be used for computing vmaf.", OFFSET(pool), AV_OPT_TYPE_STRING, {.str=NULL}, 0, 1, FLAGS},
{ NULL }
};