From patchwork Wed Jul 19 15:23:07 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Tobias Rapp X-Patchwork-Id: 4369 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.1.76 with SMTP id 73csp963422vsb; Wed, 19 Jul 2017 08:23:31 -0700 (PDT) X-Received: by 10.28.136.147 with SMTP id k141mr238556wmd.131.1500477811622; Wed, 19 Jul 2017 08:23:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1500477811; cv=none; d=google.com; s=arc-20160816; b=XGNLuBaZ2fPzlE4kDyZk/8widuc6CnxzfGizJfdAdMISppT/3CcYYm0Zbj3YbKB5VY 1WP6ktmaaRFBuBXRrN9+ypNFe6wpg0CxznPovoIYNr4n1lFHR1qkyQXBlPg34Teycp+q C97zT91Feelf1GBHQunObf5+D+c6VUOxU64uy1oRO+NwSF7Msio3K0lMuGLfAlxB7WcM QhOjRX+WRjLyGVkRVjzm2OrO0YIGGEu8ktPdzv/vhmMxKG3fH8hzoN2DmOW/CjEgBVMr p7IOBjJz/Af+A7Mpo0pQHd00Z6rdAydxGPIe9hjpn+lBJUTirXYpSBJM+YOYW6l+JjA6 V8Gg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence:subject :in-reply-to:mime-version:user-agent:date:message-id:organization :from:references:to:delivered-to:arc-authentication-results; bh=SfU8jOLScnTUEv0T4aFbfjuHkWWSNwQ5xP4osLMm6QY=; b=GQPlug/POLZJkDBAtYPCU1dlBDoT96rAo7CMQdzaNvAzLXxR/BMoFdmRMkBbIoSrgV 7z4gtxDlGae6A2JsTmxB3azyMtDrZf1Rx5/2ZZa0jHgCaVJPMTj5oWqcgqYpB3zzYh7F 6rsvwMBFVDrDNcKjtnY2IOJbHrpUXtqAKOs5fkIuJWT4WSCxO/uy9hfVGvXkwEqXyLfp c+gE41Cc1IFwjn2s4uqUM8Vzktf/xcdthyAbsIkbIsym0dh7MjpnAxLq/j8dtt/XzY1k 0PG9si3LogeZpNu4y5EdCQLVmzwfTOjdwx3BDhp15aEj9QNwbGVWSaxfHznTYvTLhZfi y60A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id t104si4408926wrc.384.2017.07.19.08.23.30; Wed, 19 Jul 2017 08:23:31 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 7F817689B64; Wed, 19 Jul 2017 18:23:20 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mx01.mail.netstorage.at (mx01.mail.netstorage.at [89.207.144.13]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 1BBB3689722 for ; Wed, 19 Jul 2017 18:23:14 +0300 (EEST) Received: from p1002.netstorage.at (p1002.netstorage.at [89.207.146.186]) by mx01.mail.netstorage.at (Postfix) with ESMTPS id 1253BA2AED for ; Wed, 19 Jul 2017 17:23:08 +0200 (CEST) Received: from mailix (noaport.de [46.237.252.213]) by p1002.netstorage.at (Postfix) with ESMTPA id B4F1E815D5 for ; Wed, 19 Jul 2017 17:23:07 +0200 (CEST) Received: from [127.0.0.1] (HSI-KBW-46-237-252-214.hsi.kabel-badenwuerttemberg.de [46.237.252.214]) by mailix with ESMTPSA (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128) ; Wed, 19 Jul 2017 17:23:07 +0200 To: ffmpeg-devel@ffmpeg.org References: <1500457259-23469-1-git-send-email-t.rapp@noa-archive.com> <20170719122401.GA3182013@phare.normalesup.org> <32844f6e-8a36-4a91-52a0-5cb8311de470@noa-archive.com> <20170719150630.GA3247812@phare.normalesup.org> From: Tobias Rapp Organization: NOA GmbH Message-ID: Date: Wed, 19 Jul 2017 17:23:07 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <20170719150630.GA3247812@phare.normalesup.org> X-PPP-Message-ID: <20170719152307.8653.70162@p1002.netstorage.at> X-PPP-Vhost: noa-archive.com X-NetStorage-MailScanner-Information: Please contact the ISP for more information X-NetStorage-MailScanner-ID: 1253BA2AED.ABE43 X-NetStorage-MailScanner: Found to be clean X-NetStorage-MailScanner-SpamCheck: not spam (whitelisted), SpamAssassin (nicht zwischen gespeichert, Wertung=-0.5, benoetigt 6, autolearn=not spam, BAYES_00 -0.50) X-NetStorage-MailScanner-From: t.rapp@noa-archive.com X-Spam-Status: No Subject: Re: [FFmpeg-devel] [PATCH] fate: add tests for psnr and ssim filter X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" On 19.07.2017 17:06, Nicolas George wrote: > Le primidi 1er thermidor, an CCXXV, Tobias Rapp a écrit : >> Indeed they are remainders from previous edits. It seems that stripping any >> whitespace within the filter string is enough to ensure that it is passed as >> one argument token to ffmpeg. So fixed locally. > > I suppose you left the quotes, otherwise the semicolon separates > commands and the brackets are globbing patterns. Indeed, see attached patch for reference (WIP as it still contains the CPUFLAGS work-around). >>>> + -f null /dev/null >> BTW: Is it OK to redirect output to "/dev/null" here or does this introduce >> an unwanted platform dependency (i.e. blocks FATE from running on >> MSYS/Windows)? > > With -f null, you can put anything you want there. I usually put -, but > that is just a convenience to be able to change it to "-f fmt - | cmd". OK. Regards, Tobias From 430a2c8cfb455cbd11af119987fffa0919f71cc5 Mon Sep 17 00:00:00 2001 From: Tobias Rapp Date: Tue, 11 Jul 2017 12:38:06 +0200 Subject: [PATCH] fate: add tests for psnr and ssim filter Signed-off-by: Tobias Rapp --- tests/fate/filter-video.mak | 16 +++++++++++++ tests/ref/fate/filter-refcmp-psnr-rgb | 45 +++++++++++++++++++++++++++++++++++ tests/ref/fate/filter-refcmp-psnr-yuv | 45 +++++++++++++++++++++++++++++++++++ tests/ref/fate/filter-refcmp-ssim-rgb | 30 +++++++++++++++++++++++ tests/ref/fate/filter-refcmp-ssim-yuv | 30 +++++++++++++++++++++++ 5 files changed, 166 insertions(+) create mode 100644 tests/ref/fate/filter-refcmp-psnr-rgb create mode 100644 tests/ref/fate/filter-refcmp-psnr-yuv create mode 100644 tests/ref/fate/filter-refcmp-ssim-rgb create mode 100644 tests/ref/fate/filter-refcmp-ssim-yuv diff --git a/tests/fate/filter-video.mak b/tests/fate/filter-video.mak index 53fc7a6..515fdb2 100644 --- a/tests/fate/filter-video.mak +++ b/tests/fate/filter-video.mak @@ -698,6 +698,22 @@ FATE_FILTER_SAMPLES-$(call ALLYES, MOV_DEMUXER H264_DECODER AAC_FIXED_DECODER PC fate-filter-meta-4560-rotate0: tests/data/file4560-override2rotate0.mov fate-filter-meta-4560-rotate0: CMD = framecrc -flags +bitexact -c:a aac_fixed -i $(TARGET_PATH)/tests/data/file4560-override2rotate0.mov +fate-filter-refcmp%: CMD = ffmpeg -flags +bitexact -sws_flags +accurate_rnd+bitexact -fflags +bitexact \ + -lavfi "testsrc2=size=300x200:rate=1:duration=5,format=$(PIXFMT),split[ref][tmp];[tmp]avgblur=4[enc];[enc][ref]$(REFCMP),metadata=print:file=-" \ + -f null /dev/null + +FATE_FILTER_SAMPLES-$(call ALLYES, FFMPEG LAVFI_INDEV AVGBLUR_FILTER PSNR_FILTER METADATA_FILTER) += fate-filter-refcmp-psnr-rgb fate-filter-refcmp-psnr-yuv +fate-filter-refcmp-psnr%: REFCMP = psnr +fate-filter-refcmp-psnr-rgb: PIXFMT = rgb24 +fate-filter-refcmp-psnr-yuv: PIXFMT = yuv422p + +FATE_FILTER_SAMPLES-$(call ALLYES, FFMPEG LAVFI_INDEV AVGBLUR_FILTER SSIM_FILTER METADATA_FILTER) += fate-filter-refcmp-ssim-rgb fate-filter-refcmp-ssim-yuv +fate-filter-refcmp-ssim%: REFCMP = ssim +# FIXME: override CPUFLAGS to avoid failure on x86 (issue #6519) +fate-filter-refcmp-ssim%: CPUFLAGS = 0 +fate-filter-refcmp-ssim-rgb: PIXFMT = rgb24 +fate-filter-refcmp-ssim-yuv: PIXFMT = yuv422p + FATE_SAMPLES_FFPROBE += $(FATE_METADATA_FILTER-yes) FATE_SAMPLES_FFMPEG += $(FATE_FILTER_SAMPLES-yes) FATE_FFMPEG += $(FATE_FILTER-yes) diff --git a/tests/ref/fate/filter-refcmp-psnr-rgb b/tests/ref/fate/filter-refcmp-psnr-rgb new file mode 100644 index 0000000..7d413f4 --- /dev/null +++ b/tests/ref/fate/filter-refcmp-psnr-rgb @@ -0,0 +1,45 @@ +frame:0 pts:0 pts_time:0 +lavfi.psnr.mse.r=1381.80 +lavfi.psnr.psnr.r=16.73 +lavfi.psnr.mse.g=896.00 +lavfi.psnr.psnr.g=18.61 +lavfi.psnr.mse.b=277.38 +lavfi.psnr.psnr.b=23.70 +lavfi.psnr.mse_avg=851.73 +lavfi.psnr.psnr_avg=18.83 +frame:1 pts:1 pts_time:1 +lavfi.psnr.mse.r=1380.37 +lavfi.psnr.psnr.r=16.73 +lavfi.psnr.mse.g=975.91 +lavfi.psnr.psnr.g=18.24 +lavfi.psnr.mse.b=435.72 +lavfi.psnr.psnr.b=21.74 +lavfi.psnr.mse_avg=930.67 +lavfi.psnr.psnr_avg=18.44 +frame:2 pts:2 pts_time:2 +lavfi.psnr.mse.r=1403.20 +lavfi.psnr.psnr.r=16.66 +lavfi.psnr.mse.g=954.05 +lavfi.psnr.psnr.g=18.34 +lavfi.psnr.mse.b=494.22 +lavfi.psnr.psnr.b=21.19 +lavfi.psnr.mse_avg=950.49 +lavfi.psnr.psnr_avg=18.35 +frame:3 pts:3 pts_time:3 +lavfi.psnr.mse.r=1452.80 +lavfi.psnr.psnr.r=16.51 +lavfi.psnr.mse.g=1001.02 +lavfi.psnr.psnr.g=18.13 +lavfi.psnr.mse.b=557.39 +lavfi.psnr.psnr.b=20.67 +lavfi.psnr.mse_avg=1003.74 +lavfi.psnr.psnr_avg=18.11 +frame:4 pts:4 pts_time:4 +lavfi.psnr.mse.r=1401.25 +lavfi.psnr.psnr.r=16.67 +lavfi.psnr.mse.g=1009.80 +lavfi.psnr.psnr.g=18.09 +lavfi.psnr.mse.b=602.42 +lavfi.psnr.psnr.b=20.33 +lavfi.psnr.mse_avg=1004.49 +lavfi.psnr.psnr_avg=18.11 diff --git a/tests/ref/fate/filter-refcmp-psnr-yuv b/tests/ref/fate/filter-refcmp-psnr-yuv new file mode 100644 index 0000000..942542a --- /dev/null +++ b/tests/ref/fate/filter-refcmp-psnr-yuv @@ -0,0 +1,45 @@ +frame:0 pts:0 pts_time:0 +lavfi.psnr.mse.y=222.06 +lavfi.psnr.psnr.y=24.67 +lavfi.psnr.mse.u=339.38 +lavfi.psnr.psnr.u=22.82 +lavfi.psnr.mse.v=705.41 +lavfi.psnr.psnr.v=19.65 +lavfi.psnr.mse_avg=372.23 +lavfi.psnr.psnr_avg=22.42 +frame:1 pts:1 pts_time:1 +lavfi.psnr.mse.y=236.74 +lavfi.psnr.psnr.y=24.39 +lavfi.psnr.mse.u=416.17 +lavfi.psnr.psnr.u=21.94 +lavfi.psnr.mse.v=704.98 +lavfi.psnr.psnr.v=19.65 +lavfi.psnr.mse_avg=398.66 +lavfi.psnr.psnr_avg=22.12 +frame:2 pts:2 pts_time:2 +lavfi.psnr.mse.y=234.79 +lavfi.psnr.psnr.y=24.42 +lavfi.psnr.mse.u=435.72 +lavfi.psnr.psnr.u=21.74 +lavfi.psnr.mse.v=699.60 +lavfi.psnr.psnr.v=19.68 +lavfi.psnr.mse_avg=401.23 +lavfi.psnr.psnr_avg=22.10 +frame:3 pts:3 pts_time:3 +lavfi.psnr.mse.y=250.88 +lavfi.psnr.psnr.y=24.14 +lavfi.psnr.mse.u=479.73 +lavfi.psnr.psnr.u=21.32 +lavfi.psnr.mse.v=707.55 +lavfi.psnr.psnr.v=19.63 +lavfi.psnr.mse_avg=422.26 +lavfi.psnr.psnr_avg=21.88 +frame:4 pts:4 pts_time:4 +lavfi.psnr.mse.y=241.05 +lavfi.psnr.psnr.y=24.31 +lavfi.psnr.mse.u=505.04 +lavfi.psnr.psnr.u=21.10 +lavfi.psnr.mse.v=716.00 +lavfi.psnr.psnr.v=19.58 +lavfi.psnr.mse_avg=425.79 +lavfi.psnr.psnr_avg=21.84 diff --git a/tests/ref/fate/filter-refcmp-ssim-rgb b/tests/ref/fate/filter-refcmp-ssim-rgb new file mode 100644 index 0000000..4a06eb4 --- /dev/null +++ b/tests/ref/fate/filter-refcmp-ssim-rgb @@ -0,0 +1,30 @@ +frame:0 pts:0 pts_time:0 +lavfi.ssim.R=0.72 +lavfi.ssim.G=0.76 +lavfi.ssim.B=0.89 +lavfi.ssim.All=0.79 +lavfi.ssim.dB=6.74 +frame:1 pts:1 pts_time:1 +lavfi.ssim.R=0.70 +lavfi.ssim.G=0.74 +lavfi.ssim.B=0.85 +lavfi.ssim.All=0.77 +lavfi.ssim.dB=6.31 +frame:2 pts:2 pts_time:2 +lavfi.ssim.R=0.71 +lavfi.ssim.G=0.75 +lavfi.ssim.B=0.84 +lavfi.ssim.All=0.76 +lavfi.ssim.dB=6.29 +frame:3 pts:3 pts_time:3 +lavfi.ssim.R=0.70 +lavfi.ssim.G=0.73 +lavfi.ssim.B=0.83 +lavfi.ssim.All=0.76 +lavfi.ssim.dB=6.11 +frame:4 pts:4 pts_time:4 +lavfi.ssim.R=0.71 +lavfi.ssim.G=0.74 +lavfi.ssim.B=0.80 +lavfi.ssim.All=0.75 +lavfi.ssim.dB=6.05 diff --git a/tests/ref/fate/filter-refcmp-ssim-yuv b/tests/ref/fate/filter-refcmp-ssim-yuv new file mode 100644 index 0000000..0cd46c8 --- /dev/null +++ b/tests/ref/fate/filter-refcmp-ssim-yuv @@ -0,0 +1,30 @@ +frame:0 pts:0 pts_time:0 +lavfi.ssim.Y=0.80 +lavfi.ssim.U=0.76 +lavfi.ssim.V=0.69 +lavfi.ssim.All=0.76 +lavfi.ssim.dB=6.25 +frame:1 pts:1 pts_time:1 +lavfi.ssim.Y=0.80 +lavfi.ssim.U=0.73 +lavfi.ssim.V=0.68 +lavfi.ssim.All=0.75 +lavfi.ssim.dB=6.08 +frame:2 pts:2 pts_time:2 +lavfi.ssim.Y=0.80 +lavfi.ssim.U=0.73 +lavfi.ssim.V=0.68 +lavfi.ssim.All=0.75 +lavfi.ssim.dB=6.10 +frame:3 pts:3 pts_time:3 +lavfi.ssim.Y=0.79 +lavfi.ssim.U=0.72 +lavfi.ssim.V=0.68 +lavfi.ssim.All=0.75 +lavfi.ssim.dB=5.94 +frame:4 pts:4 pts_time:4 +lavfi.ssim.Y=0.80 +lavfi.ssim.U=0.72 +lavfi.ssim.V=0.68 +lavfi.ssim.All=0.75 +lavfi.ssim.dB=5.97 -- 2.7.4