]> granicus.if.org Git - libvpx/log
libvpx
6 years agoMerge "Bug fix for second reference stats."
Paul Wilkins [Tue, 12 Dec 2017 11:56:10 +0000 (11:56 +0000)]
Merge "Bug fix for second reference stats."

6 years agoMerge "vp9 svc: Allow denoising next to highest resolution."
Jerome Jiang [Tue, 12 Dec 2017 05:27:11 +0000 (05:27 +0000)]
Merge "vp9 svc: Allow denoising next to highest resolution."

6 years agovp9 svc: Allow denoising next to highest resolution.
Jerome Jiang [Fri, 8 Dec 2017 18:38:18 +0000 (10:38 -0800)]
vp9 svc: Allow denoising next to highest resolution.

Denoise 2 spatial layes at most.

Add noise sensitivity level 2 for vp9 such that applications can control
whether to denoise the second highest spatial layer.

Add tests to cover this case.

Change-Id: Ic327d14b29adeba3f0dae547629f43b98d22997f

6 years agoMerge "Fix build warnings for gcc 6.3"
Jerome Jiang [Mon, 11 Dec 2017 18:27:17 +0000 (18:27 +0000)]
Merge "Fix build warnings for gcc 6.3"

6 years agoBug fix for second reference stats.
paulwilkins [Mon, 4 Dec 2017 13:41:44 +0000 (13:41 +0000)]
Bug fix for second reference stats.

Immediately following a key frame the trailing second reference
error in the first pass stats will be based on a reference frame from
the prior key frame group and will thus usually be much larger.

This fix eliminates that effect (which typically triggers a short arf
group immediately after a key frame). It also changes the accounting
for the first frame in each new arf group.

This change gives large gains on a couple of clips that contain mid
sequence key frames (e.g. 6% on 1080P tennis). Overall there was
a net gain in PSNR and PSNR-HVS ~(0.05- 0.4%) and mixed results for
SSIM (+/- 0.2%).

Change-Id: I8e00538ac2c0b5c2e7e637903cac329ce5c2a375

6 years agoFix build warnings for gcc 6.3
Jerome Jiang [Wed, 6 Dec 2017 00:11:05 +0000 (16:11 -0800)]
Fix build warnings for gcc 6.3

Clean up some alias.

BUG=webm:1465

Change-Id: I99e186162db9f9e15375fef01564692434eda619

6 years agoMerge "Add frame width & height to frame pkt. Add test."
Jerome Jiang [Wed, 6 Dec 2017 22:37:15 +0000 (22:37 +0000)]
Merge "Add frame width & height to frame pkt. Add test."

6 years agoAdd frame width & height to frame pkt. Add test.
Jerome Jiang [Wed, 29 Nov 2017 23:06:35 +0000 (15:06 -0800)]
Add frame width & height to frame pkt. Add test.

Used to return correct frame width and height when dynamic resizing happens.

BUG=webm:1474

Change-Id: Ia2043f7e1635b3821848a67b9b134f47f14b0f3a

6 years agovp9-svc: Set downsampling filter for VGA layer.
Marco [Wed, 6 Dec 2017 19:21:29 +0000 (11:21 -0800)]
vp9-svc: Set downsampling filter for VGA layer.

Downsampling filter for SVC was set to subsample (phase 0)
for HD -> VGA, and bilinear averaging (phase 8) for VGA -> QVGA.
This change makes it bilinear averaging for HD -> VGA.

Given the recent commit 9f9d4f8, quality is improved with
this change: avgPSNR/SSIM up ~1-3% on HD clips in RTC set.
Speed decrease of ~1% for 3 layer SVC.

Change-Id: If834a320e372b8b922a6bf7cab4227703b1beae6

6 years agoMerge "vp9: Nonrd-pickmode: move some early exits up."
Marco Paniconi [Wed, 6 Dec 2017 19:18:51 +0000 (19:18 +0000)]
Merge "vp9: Nonrd-pickmode: move some early exits up."

6 years agoMerge "Add max luma picture width/height constraint in VP9 level"
Hui Su [Wed, 6 Dec 2017 18:46:19 +0000 (18:46 +0000)]
Merge "Add max luma picture width/height constraint in VP9 level"

6 years agovp9: Nonrd-pickmode: move some early exits up.
Marco [Wed, 6 Dec 2017 18:11:54 +0000 (10:11 -0800)]
vp9: Nonrd-pickmode: move some early exits up.

Move the early exit checks on usable_ref_frame and
skip_ref_find_pref up before the check on flag_svc_subpel.
The code under flag_svc_subpel requires frame_mv to be set
for the golden/spatial reference, which is only set if the
both those exits don't pass.

No change in behavior.

Change-Id: Id304276c745eeb389ff85fa2dcf510d5976bc413

6 years agovp9-svc: Allow for nonzero motion on spatial reference.
Marco [Fri, 1 Dec 2017 23:20:41 +0000 (15:20 -0800)]
vp9-svc: Allow for nonzero motion on spatial reference.

For nonrd pickmode on a given spatial layer, the spatial
(golden) reference was always only using zeromv for prediction.
In this patch if the downsampling filter used for generating
the lower spatial layer is an averaging filter (nonzero phase),
we allow for subpel motion on the spatial (golden) reference to
compensate for the shift. This is done by forcing the testing of
nonzero motion mode to compensate for spatial downsampling shift.

Improvement for cases where the downsampling is averaging filter.
In the current code this is only done for generating
resolutions <= QVGA.

Improvement for avgPSNR/SSIM on RTC set for speed 7: ~1.2%.
Gain is larger (~2-3%) for VGA clips with 2 spatial layers.
~1% speed slowdown for 3 layer SVC on mac.

Change-Id: I9ec4fa20a38947934fc650594596c25280c3b289

6 years agoMerge "vpx_dsp: [loongson] optimize variance v2."
Shiyou Yin [Mon, 4 Dec 2017 01:30:06 +0000 (01:30 +0000)]
Merge "vpx_dsp: [loongson] optimize variance v2."

6 years agoAdd max luma picture width/height constraint in VP9 level
Hui Su [Wed, 29 Nov 2017 01:38:47 +0000 (17:38 -0800)]
Add max luma picture width/height constraint in VP9 level

BUG=b/65412009

Change-Id: I9e1478dcbd2ef9e97f5f8fb5a1c733b5f5cdf396

6 years agofilter out asm includes
Johann [Fri, 1 Dec 2017 23:03:49 +0000 (15:03 -0800)]
filter out asm includes

Don't add include files to the archive. Avoids build failures for
Windows such as:
the input file 'libvpx_g.a(x86_abi_support.asm.o)' has no sections

Change-Id: If9c8e70c0ec913b7ad7dd6a08d4fa19011114ad2

6 years agoexplicitly label .text sections
Johann [Fri, 1 Dec 2017 22:31:04 +0000 (14:31 -0800)]
explicitly label .text sections

nasm should infer .text but does not for windows:
https://bugzilla.nasm.us/show_bug.cgi?id=3392451

Change-Id: Ib195465e5f33405f5ff61c4cf88aa2a72640cacb

6 years agonasm defaults to -Ox
Johann [Fri, 1 Dec 2017 20:46:37 +0000 (12:46 -0800)]
nasm defaults to -Ox

No need to specify default behaviour. The original change introducing nasm:
https://chromium.googlesource.com/webm/libvpx/+/7be093ea4d50c8d38438f88cb9fa817c1c9de8dd
mentions requiring 2.0.9, which was the first release to default to this behaviour:
http://www.nasm.us/doc/nasmdoc2.html
"The -Ox mode is recommended for most uses, and is the default since NASM 2.09."

Change-Id: Ia914c4deede5aa447277b5189bb4fcf7e54c338d

6 years agoMerge "pass 'win64' instead of 'x64' to the assembler"
Johann Koenig [Fri, 1 Dec 2017 22:07:03 +0000 (22:07 +0000)]
Merge "pass 'win64' instead of 'x64' to the assembler"

6 years agopass 'win64' instead of 'x64' to the assembler
Johann [Fri, 1 Dec 2017 18:58:44 +0000 (10:58 -0800)]
pass 'win64' instead of 'x64' to the assembler

nasm does not accept x64

yasm has accepted (and appears to prefer) win64 at least as far back as
1.0.0:
http://yasm.tortall.net/releases/Release1.0.0.html

Change-Id: Ied881b1df0570da256b1bd7e131e7817e47f768f

6 years agovp9-svc: Set num_inter_modes in non-rd pickmode.
Marco [Fri, 1 Dec 2017 18:30:45 +0000 (10:30 -0800)]
vp9-svc: Set num_inter_modes in non-rd pickmode.

Set num_inter_modes based on ref_mode_set_svc, which is
smaller set than ref_mode_set (which may use alt-ref).

No change in behavior.

Change-Id: I31169bb09028db230552c6fca0a86959d1ade692

6 years agovpx_dsp: [loongson] optimize variance v2.
Shiyou Yin [Fri, 1 Dec 2017 05:44:48 +0000 (13:44 +0800)]
vpx_dsp: [loongson] optimize variance v2.

1. Delete unnecessary zero setting process.
2. Optimize the method of calculating SSE in vpx_varianceWxH.

Change-Id: I58890c6a2ed1543379acb48e03e620c144f6515f

6 years agoMerge "mips msa optimize vpx_scaled_2d function"
Kaustubh Raste [Fri, 1 Dec 2017 01:24:25 +0000 (01:24 +0000)]
Merge "mips msa optimize vpx_scaled_2d function"

6 years agoMerge "Nonrd-pickmode: avoid duplicate computation of UV predictor."
Marco Paniconi [Fri, 1 Dec 2017 00:23:52 +0000 (00:23 +0000)]
Merge "Nonrd-pickmode: avoid duplicate computation of UV predictor."

6 years agoMerge "decouple spatial-svc from encoder abi"
James Zern [Fri, 1 Dec 2017 00:22:34 +0000 (00:22 +0000)]
Merge "decouple spatial-svc from encoder abi"

6 years agoNonrd-pickmode: avoid duplicate computation of UV predictor.
Marco [Thu, 30 Nov 2017 20:08:00 +0000 (12:08 -0800)]
Nonrd-pickmode: avoid duplicate computation of UV predictor.

Avoids duplicate computation of UV predictor.

Bit-exact when static_threshold is zero.
Small/neutral difference on RTC set with nonzero static_threshold
(since UV predictor won't be skipped with this change).

Small speed gain, ~1-2%, at speed 8.

Change-Id: Iba8d22a307768b391e29d63c9826aac5a4d9c285

6 years agodecouple spatial-svc from encoder abi
James Zern [Thu, 30 Nov 2017 18:52:25 +0000 (10:52 -0800)]
decouple spatial-svc from encoder abi

this is only meant for testing. along with --enable-experimental
--enable-spatial-svc require VPX_TEST_SPATIAL_SVC to be defined rather
than bumping the encoder ABI.

Change-Id: I7f34d9f60300fa31ccf22e1a4aa619392c391b2e

6 years agoFix to copy partition.
Marco [Thu, 30 Nov 2017 04:01:44 +0000 (20:01 -0800)]
Fix to copy partition.

Update the prev_partition on early exits in
choose_partitioning().

Change-Id: I382ffcab8e647c00b14283d15c3dd11bb0ac6f50

6 years agoMerge changes Icd9c866b,I81717e47
Shiyou Yin [Thu, 30 Nov 2017 00:53:50 +0000 (00:53 +0000)]
Merge changes Icd9c866b,I81717e47

* changes:
  vp8: [loongson] optimize regular quantize v2.
  vp8: [loongson] optimize vp8_short_fdct4x4_mmi v2.

6 years agoMerge "vpx: [loongson] fix bug in var_filter_block2d_bil_16x"
Shiyou Yin [Thu, 30 Nov 2017 00:53:37 +0000 (00:53 +0000)]
Merge "vpx: [loongson] fix bug in var_filter_block2d_bil_16x"

6 years agoMerge "Add PSNR Cb and Cr metric to opsnr.stt"
Jingning Han [Wed, 29 Nov 2017 22:56:47 +0000 (22:56 +0000)]
Merge "Add PSNR Cb and Cr metric to opsnr.stt"

6 years agoMerge "vp9-svc: Don't allow encode_breakout on golden ref."
Marco Paniconi [Wed, 29 Nov 2017 22:41:31 +0000 (22:41 +0000)]
Merge "vp9-svc: Don't allow encode_breakout on golden ref."

6 years agovp9-svc: Don't allow encode_breakout on golden ref.
Marco [Wed, 29 Nov 2017 21:37:21 +0000 (13:37 -0800)]
vp9-svc: Don't allow encode_breakout on golden ref.

For 1 pass cbr SVC: GOLDEN is the spatial reference,
better not to check for encoder_breakout on this reference.

Small positive ~0.075% (mostly neutral) gain in avgPSNR/SSIM metrics.
No observed change in encoder speed.

Change-Id: Ib337f16d6771105bf06384c6a23ad047fc690418

6 years agovp9-svc: Clean conditon for allowing copy_partition.
Marco [Wed, 29 Nov 2017 20:48:20 +0000 (12:48 -0800)]
vp9-svc: Clean conditon for allowing copy_partition.

Make condition explicit on non_reference_frame.

No change in behavior.

Change-Id: Iec5068bccd93c7c7be67634c5c090580b2dbb20d

6 years agoMerge "Remove unnecessary includes of emmintrin_compat.h"
Kyle Siefring [Wed, 29 Nov 2017 19:14:45 +0000 (19:14 +0000)]
Merge "Remove unnecessary includes of emmintrin_compat.h"

6 years agoRemove unnecessary includes of emmintrin_compat.h
Kyle Siefring [Wed, 29 Nov 2017 16:48:24 +0000 (11:48 -0500)]
Remove unnecessary includes of emmintrin_compat.h

Change-Id: Ie60381a0c6ee01f828cd364a43f01517f4cb03e9

6 years agovp8: [loongson] optimize regular quantize v2.
Shiyou Yin [Wed, 29 Nov 2017 08:59:22 +0000 (16:59 +0800)]
vp8: [loongson] optimize regular quantize v2.

1. Optimize the memset with mmi.
2. Optimize macro REGULAR_SELECT_EOB.

Change-Id: Icd9c866b0e6aef08874b2f123e9b0e09919445ff

6 years agomips msa optimize vpx_scaled_2d function
Kaustubh Raste [Wed, 29 Nov 2017 07:57:04 +0000 (13:27 +0530)]
mips msa optimize vpx_scaled_2d function

Change-Id: I638507b360c71489ab0e87bd558d2719ad995333

6 years agovp8: [loongson] optimize vp8_short_fdct4x4_mmi v2.
Shiyou Yin [Wed, 29 Nov 2017 03:58:38 +0000 (11:58 +0800)]
vp8: [loongson] optimize vp8_short_fdct4x4_mmi v2.

Optimize the calculate process of a,b,c,d.

Change-Id: I81717e47bc988ace1412d478513e7dd3cb6b0cc9

6 years agovpx{enc,dec}: add --help
James Zern [Tue, 28 Nov 2017 02:35:37 +0000 (18:35 -0800)]
vpx{enc,dec}: add --help

only output short usage to stderr on error, with --help use stdout

Change-Id: I7089f3bca829817e14b14c766f4f3eaee6f54e5c

6 years agoAdd PSNR Cb and Cr metric to opsnr.stt
Jingning Han [Mon, 27 Nov 2017 23:04:32 +0000 (15:04 -0800)]
Add PSNR Cb and Cr metric to opsnr.stt

Change-Id: I24e1741c00f9514647c7db2758a7ababd4e96932

6 years agovpx: [loongson] fix bug in var_filter_block2d_bil_16x
Shiyou Yin [Fri, 22 Sep 2017 07:29:21 +0000 (15:29 +0800)]
vpx: [loongson] fix bug in var_filter_block2d_bil_16x

Which cause failed case:
1. MMI/VpxSubpelVarianceTest.Ref/6
2. MMI/VpxSubpelVarianceTest.Ref/7
3. MMI/VpxSubpelVarianceTest.ExtremeRef/6
4. MMI/VpxSubpelVarianceTest.ExtremeRef/7

Change-Id: I122ca20089e14ac324edd61295cf8f506e06afc8

6 years agovp9-svc: Fix condition for setting downsampling filter.
Marco [Tue, 28 Nov 2017 22:28:26 +0000 (14:28 -0800)]
vp9-svc: Fix condition for setting downsampling filter.

Use (width * height) for setting downsampling filter type.

Change-Id: If4acfde7ff9339e0584155f8a4d15b2f134211f2

6 years agoquantize x86: dedup some parts
Johann [Wed, 23 Aug 2017 22:27:25 +0000 (15:27 -0700)]
quantize x86: dedup some parts

Change-Id: I9f95f47bc7ecbb7980f21cbc3a91f699624141af

6 years agovp9-svc: Fix to the layer buffer settings.
Marco [Tue, 21 Nov 2017 23:04:53 +0000 (15:04 -0800)]
vp9-svc: Fix to the layer buffer settings.

For the case when the number of temporal layers > 1,
the buffer levels (starting/optimal_buffer_level,
and maximum_buffer_size) were not scaled properly.

In vp9_update_layer_context_change_config():
when setting the layer-buffer levels, fix is to scale
the layer-target_bandwidth by the target_bandwidth
(which is the full stream bandwidth) instead of the
spatial_layer_target.

This is needed because prior to the call
vp9_update_layer_context_change_config(), set_rc_buffer_sizes()
is called which sets the buffer levels based on target bandwidth
(which is the full bandwidth for the SVC stream).

This fix properly sets the layer-buffer levels based on the
layer-bandwidth, and leads to better rate targeting.

Small/neutral change in avgPSNR/SSIM metrics on RTC set.

Change-Id: Ic0f4f7f3487c37b9a9adb4781ae5edfed7140a57

6 years agoMerge "[CFI] Remove function pointer casts"
Peter Collingbourne [Tue, 21 Nov 2017 18:42:40 +0000 (18:42 +0000)]
Merge "[CFI] Remove function pointer casts"

6 years agoMerge "vp8 simulcast: fix compile warnings."
Jerome Jiang [Tue, 21 Nov 2017 01:22:46 +0000 (01:22 +0000)]
Merge "vp8 simulcast: fix compile warnings."

6 years ago[CFI] Remove function pointer casts
Vlad Tsyrklevich [Mon, 20 Nov 2017 21:40:54 +0000 (13:40 -0800)]
[CFI] Remove function pointer casts

Control Flow Integrity [1] indirect call checking verifies that function
pointers only call valid functions with a matching type signature. This
change eliminates function pointer casts to make libvpx CFI-safe.

[1] https://www.chromium.org/developers/testing/control-flow-integrity

Change-Id: I7e08522d195a43c88cda06fa20414426c8c4372c

6 years agovp8 simulcast: fix compile warnings.
Jerome Jiang [Tue, 21 Nov 2017 00:18:31 +0000 (16:18 -0800)]
vp8 simulcast: fix compile warnings.

Clean up some prints.

Change-Id: I199350e34a8b6fbff9601fcbd11ec68d24da5073

6 years agoMerge "Optimize AVX2 get16x16var and get32x16var functions"
Kyle Siefring [Mon, 20 Nov 2017 22:37:57 +0000 (22:37 +0000)]
Merge "Optimize AVX2 get16x16var and get32x16var functions"

6 years agoMerge "vp9 svc: fix a few compile warnings."
Jerome Jiang [Mon, 20 Nov 2017 18:52:58 +0000 (18:52 +0000)]
Merge "vp9 svc: fix a few compile warnings."

6 years agovp9-svc: Enbale scale partition reference frames.
Marco [Fri, 17 Nov 2017 17:47:03 +0000 (09:47 -0800)]
vp9-svc: Enbale scale partition reference frames.

For reference frames: enable scale partition for
superblocks with low source sad or if bsize on lower-resoln
is at least 32x32.

Keep feature disabled for base temporal layer.

Small regression in avgPNSR/SSIM metrics, ~0.5-1%.
Speedup ~2-3% on mac for SVC (3 spatial/3 temporal layers) at speed 7.

Change-Id: I5987eb7763845b680059128b538bb5188be0cca5

6 years agovp9 svc: fix a few compile warnings.
Jerome Jiang [Fri, 17 Nov 2017 22:33:21 +0000 (14:33 -0800)]
vp9 svc: fix a few compile warnings.

Change-Id: I4cb878600038066513ab73f3658990d1245ff2fb

6 years agoOptimize AVX2 get16x16var and get32x16var functions
Kyle Siefring [Fri, 17 Nov 2017 18:43:05 +0000 (13:43 -0500)]
Optimize AVX2 get16x16var and get32x16var functions

Change-Id: If8b91aaa883c01107f0ea3468139fa24cfb301d2

6 years agoMerge "Disable allow_partition_search_skip for speed 2."
Paul Wilkins [Fri, 17 Nov 2017 10:34:56 +0000 (10:34 +0000)]
Merge "Disable allow_partition_search_skip for speed 2."

6 years agoMerge "Code cleanup."
Paul Wilkins [Fri, 17 Nov 2017 10:34:46 +0000 (10:34 +0000)]
Merge "Code cleanup."

6 years agoMerge "Remove decay_accumulator clause from alt ref breakout."
Paul Wilkins [Fri, 17 Nov 2017 10:34:37 +0000 (10:34 +0000)]
Merge "Remove decay_accumulator clause from alt ref breakout."

6 years agoMerge "Add clause to alt ref group breakout."
Paul Wilkins [Fri, 17 Nov 2017 10:34:26 +0000 (10:34 +0000)]
Merge "Add clause to alt ref group breakout."

6 years agoMerge "vp9: Fix mem rel for non-ref for external buffer."
Jerome Jiang [Fri, 17 Nov 2017 00:31:16 +0000 (00:31 +0000)]
Merge "vp9: Fix mem rel for non-ref for external buffer."

6 years agoDisable allow_partition_search_skip for speed 2.
paulwilkins [Thu, 16 Nov 2017 16:15:06 +0000 (16:15 +0000)]
Disable allow_partition_search_skip for speed 2.

When allow_partition_search_skip  is set the two pass code
can optionally skip the partition search in the rd loop if the image
appears static (based on selection of 0,0 motion).

Unfortunately 0,0 motion does not necessarily mean that there are
no meaningful changes or that motion or intra modes will not be selected
in the second pass.

Disabling "allow_partition_search_skip" may hurt the encode speed a little
for a small number of clips but can have a big impact on compression.
The most notable example of this in our test sets is "bridge_close_cif"
where this change gives a gains of 18%, 12% and 16% in opsnr, ssim and
psnr-hvs.

Change-Id: I765e288b5c0cd82bce00a148e7653a21e9203024

6 years agovp9 svc: Rework/fix scale partitioning on boundary.
Jerome Jiang [Tue, 14 Nov 2017 01:21:26 +0000 (17:21 -0800)]
vp9 svc: Rework/fix scale partitioning on boundary.

Enable partition copy on boundary and scale blocks along the boundary.
Rename copy_partition_svc to scale_partition_svc.

Do not copy if the block crosses the boundary.

Change-Id: I37a04d48f11b15c4ea67facd7631193ec2f62150

6 years agofwd txfm ssse3: use GLOBAL() for loading constants
Johann [Wed, 15 Nov 2017 21:01:44 +0000 (13:01 -0800)]
fwd txfm ssse3: use GLOBAL() for loading constants

Fixes a build issue when relocation is not allowed:
relocation R_X86_64_32 against '.rodata' can not be used when making a shared object

Change-Id: Ica3e90c926847bc384e818d7854f0030f4d69aa0

6 years agoCode cleanup.
paulwilkins [Wed, 15 Nov 2017 17:07:28 +0000 (17:07 +0000)]
Code cleanup.

Removal of parameters to and code in calc_frame_boost() that is no
longer required.

No change to results from previous patch.

Change-Id: Ic92da35613fdc247d22fddf24d09679fc5329017

6 years agoRemove decay_accumulator clause from alt ref breakout.
paulwilkins [Wed, 15 Nov 2017 16:58:05 +0000 (16:58 +0000)]
Remove decay_accumulator clause from alt ref breakout.

The decay accumulator clause covers similar ground to the
new clause that tests the accumulated second reference error
so it has been removed to reduce complexity.

Change-Id: I4ec1cce32d72bd4ee463ad7def2831a68447d525

6 years agoAdd clause to alt ref group breakout.
paulwilkins [Wed, 15 Nov 2017 16:39:54 +0000 (16:39 +0000)]
Add clause to alt ref group breakout.

Add a clause to the breakout test for alt ref groups that
examines the size of the accumulated second reference
frame error compared to the cost of intra coding.

This clause causes a reduction in the average group length for many
clips. Alongside the change to the group length the minimum
boost is increased.

On balance the results are positive for psnr and psnr-hvs
but is negative for ssim/fast ssim for the smaller image formats.

Strong gains on some harder clips (eg ducks take off (midres) ~20%,
husky (lowres) 6-17%. Most of the negative cases are lower motion
clips. Subsequent patch hopefully will help with those.

Change-Id: Ic1f5dbb9153d5089e58b1540470e799f91a65dc4

6 years agovp9-svc: Fix flag for usage of reuse-lowres partition
Marco [Wed, 15 Nov 2017 03:52:54 +0000 (19:52 -0800)]
vp9-svc: Fix flag for usage of reuse-lowres partition

Fix/cleaup the conditioning for usage of the reuse-lowres
partition feature.

Replace the non-reference condition with the top temporal
layer, and put this condition in the speed feature.

This prevents doing update_partition_svc() on every
VGA frame, instead it will now only do update for VGA in
the top temporal layer frames.

Also this makes it easier to test/enable this feature
for lower layer temporal frames.

Change-Id: Ia897afbc6fe5c84c5693e310bcaa6a87ce017be5

6 years agotiny_ssim.c : clang compile error fix
Scott LaVarnway [Tue, 14 Nov 2017 12:38:00 +0000 (04:38 -0800)]
tiny_ssim.c : clang compile error fix

Change-Id: Ic10ba580fd5da7d6ff7fa0f33db72fb0c1a97801

6 years agoMerge "add 10 and 12 bit to tiny_ssim"
James Bankoski [Tue, 14 Nov 2017 00:15:24 +0000 (00:15 +0000)]
Merge "add 10 and 12 bit to tiny_ssim"

6 years agoMerge "vp9 svc: Change conditions on VPX_ENCODER_ABI_VERSION."
Jerome Jiang [Mon, 13 Nov 2017 21:04:41 +0000 (21:04 +0000)]
Merge "vp9 svc: Change conditions on VPX_ENCODER_ABI_VERSION."

6 years agovp9 svc: Change conditions on VPX_ENCODER_ABI_VERSION.
Jerome Jiang [Mon, 13 Nov 2017 19:05:20 +0000 (11:05 -0800)]
vp9 svc: Change conditions on VPX_ENCODER_ABI_VERSION.

VPX_ENCODER_ABI_VERSION was bumped up in 93e83f.

Change-Id: Id5707f9f9db56fa96549bc8f54e1cfa04e7fa4cd

6 years agoadd 10 and 12 bit to tiny_ssim
Jim Bankoski [Mon, 13 Nov 2017 14:44:17 +0000 (06:44 -0800)]
add 10 and 12 bit to tiny_ssim

Change-Id: I92e4dba2d1682a0d77ad9a214ec4312b1cf4d42e

6 years agoNew content type to improve grain retention.
paulwilkins [Wed, 27 Sep 2017 17:17:18 +0000 (18:17 +0100)]
New content type to improve grain retention.

For new VP9 only content type adjust  the rate distortion and ARF
filter based on the relative spatial variance of the source and
reconstruction.

In regards to the RD loop the method favors modes where the
reconstruction variance is similar to the source variance. However it
is currently only applied to regions where the source variance is quite
low.

For very low variance blocks it applies a further bias against intra
coding and large prediction block sizes (the later in particular limit
the usefulness of the loop filter).

The final part of this change is to lower the strength of the ARF
filter for blocks where the source has very low spatial variance, to
encourage some low amplitude texture or noise to pass through
the filter.

This change improves the retention of film grain and fine noise /
texture in spatially flat regions, but as expected causes a significant
drop in PSNR on many clips. This is to be expected because similar
but misaligned noise or texture will give a lower PSNR than a flat
noise free reconstruction. However, it is worth noting that most clips
show a strong gain in FAST SSIM.

The features are enabled on the vpxenc command line by setting
--tune-content=film.

VPX_ENCODER_ABI_VERSION bumped for this change and cvbr.

Change-Id: I26a4e4edfa3dc5cacead82fa701fe7a9118ccd0a

6 years agoSmall parameter clean up.
paulwilkins [Mon, 6 Nov 2017 11:24:34 +0000 (11:24 +0000)]
Small parameter clean up.

Removed three parameters that are no longer needed in calls
to calc_arf_boost() and associated minor changes.

No impact on encode results.

Change-Id: Ieaf31d0d2e1990b99cf69647170145a1bbfbb9fb

6 years agoMerge "Fix to frames considered in arf boost calculation."
Paul Wilkins [Mon, 13 Nov 2017 16:36:43 +0000 (16:36 +0000)]
Merge "Fix to frames considered in arf boost calculation."

6 years agoMerge "CVBR command line option."
Paul Wilkins [Mon, 13 Nov 2017 16:32:39 +0000 (16:32 +0000)]
Merge "CVBR command line option."

6 years agovpx: [x86] add vpx_satd_avx2()
Scott LaVarnway [Fri, 10 Nov 2017 18:19:52 +0000 (10:19 -0800)]
vpx: [x86] add vpx_satd_avx2()

SSE2 instrinsic vs AVX2 intrinsic speed gains:
blocksize   16: ~1.33
blocksize   64: ~1.51
blocksize  256: ~3.03
blocksize 1024: ~3.71

Change-Id: I79b28cba82d21f9dd765e79881aa16d24fd0cb58

6 years agoMerge "vpx: [x86] add vp9_block_error_fp_avx2()"
Scott LaVarnway [Fri, 10 Nov 2017 00:45:47 +0000 (00:45 +0000)]
Merge "vpx: [x86] add vp9_block_error_fp_avx2()"

6 years agoMerge "vp9-svc: Avoid minmax variance for non-reference frames."
Marco Paniconi [Fri, 10 Nov 2017 00:30:04 +0000 (00:30 +0000)]
Merge "vp9-svc: Avoid minmax variance for non-reference frames."

6 years agovp9-svc: Avoid minmax variance for non-reference frames.
Marco [Thu, 9 Nov 2017 23:24:10 +0000 (15:24 -0800)]
vp9-svc: Avoid minmax variance for non-reference frames.

For choose_partitioning (speed >= 6): avoid computation
of minmax variance for non-reference frames in SVC.

Existing condition only avoided this for speed >= 8.
Combine that existing logic with non-reference condition.

Small speedup (~0.5-1%) for 3 layer SVC,
neutral change on avgPSNR/SSIM metrics.

Change-Id: I3e9f3a1af0647b15e475cf170d9402908d672ee5

6 years agoMerge "runtime error fix: bitdepth_conversion_avx2.h"
James Zern [Fri, 10 Nov 2017 00:15:03 +0000 (00:15 +0000)]
Merge "runtime error fix: bitdepth_conversion_avx2.h"

6 years agovp9: Fix mem rel for non-ref for external buffer.
Jerome Jiang [Tue, 7 Nov 2017 21:00:01 +0000 (13:00 -0800)]
vp9: Fix mem rel for non-ref for external buffer.

Release frame buffers for non-ref when the decoder is destroyed.

Enable the non ref test.

BUG=b/68819248

Change-Id: Id87ef3b0a62318f9812e927cd957c05c859047fa

6 years agoMerge "vp9: SVC feature to use partition from lower resolution."
Jerome Jiang [Thu, 9 Nov 2017 23:28:44 +0000 (23:28 +0000)]
Merge "vp9: SVC feature to use partition from lower resolution."

6 years agovp9: SVC feature to use partition from lower resolution.
Jerome Jiang [Wed, 8 Nov 2017 23:12:44 +0000 (15:12 -0800)]
vp9: SVC feature to use partition from lower resolution.

For SVC with 3 spatial layers:
Add feature to copy/upscale partition from middle spatial layer
to the upper/highest resolution, when superblock sad is not high.

Enabled for speed >= 7 and only for non-reference frames.

Speedup ~3-4%, small loss in avgPNSR/SSIM of ~1%.

Change-Id: I7f0a2716c0fde28bade0f86159d11b7e31d6ab8d

6 years agoruntime error fix: bitdepth_conversion_avx2.h
Scott LaVarnway [Thu, 9 Nov 2017 20:26:43 +0000 (12:26 -0800)]
runtime error fix: bitdepth_conversion_avx2.h

Change-Id: I7364a157de39eb7137b599808474b8d46d19d376

6 years agoMerge "fail early on oversize frames"
Johann Koenig [Thu, 9 Nov 2017 19:50:04 +0000 (19:50 +0000)]
Merge "fail early on oversize frames"

6 years agovpx: [x86] add vp9_block_error_fp_avx2()
Scott LaVarnway [Thu, 9 Nov 2017 00:06:29 +0000 (16:06 -0800)]
vpx: [x86] add vp9_block_error_fp_avx2()

SSE2 asm vs AVX2 intrinsics speed gains:
blocksize   16: ~1.00
blocksize   64: ~1.17
blocksize  256: ~1.67
blocksize 1024: ~1.81

Change-Id: I2a86db239cf57e3ff617890ccb2d236aba83ad5e

6 years agoFix to frames considered in arf boost calculation.
paulwilkins [Wed, 1 Nov 2017 14:21:39 +0000 (14:21 +0000)]
Fix to frames considered in arf boost calculation.

For a chosen interval "i" the existing arf boost calculation examined frames
+/- (i-1) frames from the current location in the second pass.

This change checks to make sure that the forward search does not extend
beyond the next key frame in the event that the distance to the next key
frame is < (i - 1).

Small metrics gains on all our  test sets but these are localized to a few clips
(e.g. midres set psnr-hvs sintel -2.59% but overall average was only -0.185%)

Change-Id: I26fc9ce582b6d58fa1113a238395e12ad3123cf6

6 years agoMerge "vp9: Add nonref frame buffer test."
Jerome Jiang [Thu, 9 Nov 2017 04:41:10 +0000 (04:41 +0000)]
Merge "vp9: Add nonref frame buffer test."

6 years agovp9: Add nonref frame buffer test.
Jerome Jiang [Wed, 8 Nov 2017 01:20:34 +0000 (17:20 -0800)]
vp9: Add nonref frame buffer test.

The new test will run a SVC bitstream which has non ref frames.
It checks the number of buffer acquired and released to make sure all
external frame buffers are released.

Add a new test bitstream:
vp90-2-22-svc_1280x720_1.webm
which has 400 frames in total, and 1 spatial layer and 2 temporal layers.
There is one non ref frame every other frame.

Disabled for now. Will be enabled with the fix.

BUG=b/68819248

Change-Id: I0515336fd9809a9e1fceba90e4dce53dabaf53a5

6 years agoMerge "Support building AVX-512 and implement sadx4 for AVX-512"
Johann Koenig [Wed, 8 Nov 2017 16:28:40 +0000 (16:28 +0000)]
Merge "Support building AVX-512 and implement sadx4 for AVX-512"

6 years agoCVBR command line option.
paulwilkins [Tue, 10 Oct 2017 18:49:59 +0000 (19:49 +0100)]
CVBR command line option.

Added command line control of Corpus VBR.

The new corpus vbr mode is a variant of standard
VBR (end-usage=0) where the complexity distribution
mid point is passed in rather than calculated for a specific
clip or chunk.

The new variant is enabled by setting a new command line
parameter --corpus-complexity to a zero value. Omitting
this parameter or setting it to 0 will cause the codec to use
standard vbr mode.

The correct value for a given corpus needs to be derived
experimentally using a training set such that the average
rate for the corpus is close to the target value.

For example our using our low res test set with upper and lower
vbr limits of 50%-150% and a corpus complexity value of 650
gives a similar average data rate across the set to using standard
vbr. However, with the corpus mode easier clips will be allocated
fewer bits and harder clips more bits rather than having the same
rate target for all.

Change-Id: I03f0fc8c6fb0ee32dc03720fea6a3f1949118589

6 years agoNonrd_pickmode: avoid computing UV cost when early_term is set.
Marco [Fri, 3 Nov 2017 18:29:35 +0000 (11:29 -0700)]
Nonrd_pickmode: avoid computing UV cost when early_term is set.

For nonrd_pickmode: if early_term is set there should be
no need to include UV in rdcost (when color_sensitivity is set).

Neutral change on RTC and RTC_derf metrics, for speed >= 5.
No change for ytlive metrics.

Very small speed gain (~0.5%) on some clips with strong color content.

Change-Id: Ifc00928ecd935fc71e94935ceef0ae7481249f07

7 years agoSupport building AVX-512 and implement sadx4 for AVX-512
Kyle Siefring [Tue, 31 Oct 2017 15:19:19 +0000 (11:19 -0400)]
Support building AVX-512 and implement sadx4 for AVX-512

The added AVX-512 support requires the subset of AVX-512 added in Skylake-X.

Change-Id: I39666b00d10bf96d06c709823663eb09b89265b7

7 years agoCompound prediction mode for nonrd pickmode.
Marco [Wed, 25 Oct 2017 22:45:11 +0000 (15:45 -0700)]
Compound prediction mode for nonrd pickmode.

Allow for compound prediction mode in nonrd_pickmode for ZEROMV.
For real-time encoding, 1 pass with non-zero lag-in-frames.

Added speed feature to control the feature.
Enabled for speed >=6 for now, under VBR mode.

avgPSNR/SSIM metrics positive on ytlive set, for speed 6:
some clips up by ~3-5%, some clips neutral gain, average gain
across clips is ~1%.

Small/negligible decrease in speed.

Change-Id: I7a60c7596e69b9a928410c5ee2f9141eecd8613d

7 years agofail early on oversize frames
Johann [Fri, 3 Nov 2017 16:49:13 +0000 (09:49 -0700)]
fail early on oversize frames

Even though frame_size is calculated in uint64_t, it winds up in an int
size value.

This was exposed with the msan test because the memset is called with
(int)frame_size, leading to a segfault.

Change-Id: I7fd930360dca274adb8f3e43e5e6785204808861

7 years agoMerge "vp9: Move allocation of vt2 after early exits."
Jerome Jiang [Wed, 1 Nov 2017 16:58:01 +0000 (16:58 +0000)]
Merge "vp9: Move allocation of vt2 after early exits."

7 years agovp9: Move allocation of vt2 after early exits.
Jerome Jiang [Tue, 31 Oct 2017 23:53:46 +0000 (16:53 -0700)]
vp9: Move allocation of vt2 after early exits.

Remove the memory deallocation on the early exits.

Change-Id: I00b4a814ae6705105ecab89644d055ca3311d9f4

7 years agoMerge "vp9: Reduce stack usage of choose_partitioning."
Jerome Jiang [Tue, 31 Oct 2017 21:42:18 +0000 (21:42 +0000)]
Merge "vp9: Reduce stack usage of choose_partitioning."

7 years agovp9: Reduce stack usage of choose_partitioning.
Jerome Jiang [Tue, 31 Oct 2017 02:21:24 +0000 (19:21 -0700)]
vp9: Reduce stack usage of choose_partitioning.

Move vt2 to heap.
Reduce the stack usage from ~87K to ~44K.

BUG=b/68362457

Change-Id: I8f5f93712934d59a8cc4564378172d409a736a2e

7 years agoMerge "vp9: Reduce stack usage of choose_partioning."
Jerome Jiang [Mon, 30 Oct 2017 23:39:41 +0000 (23:39 +0000)]
Merge "vp9: Reduce stack usage of choose_partioning."