platform/upstream/libvpx.git
6 years agoMerge "For keyframe-only coding do not boost in q mode"
Urvang Joshi [Wed, 17 Oct 2018 20:25:02 +0000 (20:25 +0000)]
Merge "For keyframe-only coding do not boost in q mode"

6 years agoFor keyframe-only coding do not boost in q mode
Urvang Joshi [Wed, 17 Oct 2018 18:48:10 +0000 (11:48 -0700)]
For keyframe-only coding do not boost in q mode

If we are using keyframe only coding - either coding a
single frame, or a sequence of keyframes - in the end-usage=q
mode, use the cq_level directly as the quality of each
coded frame, rather than boost them.

Ported from AV1: 563a0d1eb92bdc1e987df071a568d8406c4ffa92

Change-Id: I6dc929b8b4f0aa18e279139077f3a87958c92245

6 years agoRefactor SSE2 Code for 4-tap interpolation filter on width 16.
chiyotsai [Tue, 16 Oct 2018 19:26:34 +0000 (12:26 -0700)]
Refactor SSE2 Code for 4-tap interpolation filter on width 16.

Some repeated codes are refactored as inline functions. No performance
degradation is observed. These inline functions can be used for width 8
and width 4.

Change-Id: Ibf08cc9ebd2dd47bd2a6c2bcc1616f9d4c252d4d

6 years agoAdd SSE2 support for 4-tap interpolation filter for width 16.
chiyotsai [Wed, 17 Oct 2018 00:50:37 +0000 (17:50 -0700)]
Add SSE2 support for 4-tap interpolation filter for width 16.

Horizontal filter on 64x64 block: 1.59 times as fast as baseline.
Vertical filter on 64x64 block: 2.5 times as fast as baseline.
2D filter on 64x64 block: 1.96 times as fast as baseline.

Change-Id: I12e46679f3108616d5b3475319dd38b514c6cb3c

6 years agoMerge "Reduce the cpi->scaled_ref_idx array size by 1."
Wan-Teh Chang [Wed, 17 Oct 2018 14:43:22 +0000 (14:43 +0000)]
Merge "Reduce the cpi->scaled_ref_idx array size by 1."

6 years agoMerge "Refactor tpl dependency model to support multi-layer ARF updates"
Jingning Han [Tue, 16 Oct 2018 21:24:17 +0000 (21:24 +0000)]
Merge "Refactor tpl dependency model to support multi-layer ARF updates"

6 years agoMerge "Refactor GOP reference frame ordering for tpl model"
Jingning Han [Tue, 16 Oct 2018 21:23:52 +0000 (21:23 +0000)]
Merge "Refactor GOP reference frame ordering for tpl model"

6 years agoMerge "Record gop size"
Jingning Han [Tue, 16 Oct 2018 21:07:55 +0000 (21:07 +0000)]
Merge "Record gop size"

6 years agoMerge "Fix a bug in ml_prune_rect_partition()"
Hui Su [Tue, 16 Oct 2018 20:58:45 +0000 (20:58 +0000)]
Merge "Fix a bug in ml_prune_rect_partition()"

6 years agoMerge "Fix the filter tap calculation in mips optimizations"
Yunqing Wang [Tue, 16 Oct 2018 17:55:37 +0000 (17:55 +0000)]
Merge "Fix the filter tap calculation in mips optimizations"

6 years agoFix a bug in ml_prune_rect_partition()
Hui Su [Tue, 16 Oct 2018 16:50:13 +0000 (09:50 -0700)]
Fix a bug in ml_prune_rect_partition()

The quantization step size should be scaled properly for high bit depth
settings.

This only affects speed 0.
Encoder speed change is almost neutral.
There is a small coding gain of 0.09%.

Change-Id: I96b2bae03a53ce8ccd6428e3a050cfe18e06a024

6 years agoRefactor tpl dependency model to support multi-layer ARF updates
Jingning Han [Tue, 16 Oct 2018 17:09:52 +0000 (10:09 -0700)]
Refactor tpl dependency model to support multi-layer ARF updates

Refactor to form a systematic reference frame update system for
the temporal dependency model. This prepares to support the multi-
layer ARF system.

Change-Id: Idb90fbe3966695b487c1a0a52f4626b0b6807434

6 years agoMerge "Enable ML based partition search breakout for HBD"
Hui Su [Tue, 16 Oct 2018 17:14:27 +0000 (17:14 +0000)]
Merge "Enable ML based partition search breakout for HBD"

6 years agoFix the filter tap calculation in mips optimizations
Yunqing Wang [Tue, 16 Oct 2018 16:24:18 +0000 (09:24 -0700)]
Fix the filter tap calculation in mips optimizations

The interp filter tap calculation was not accurate to tell the
difference between 2 taps and 4 taps. This patch fixed the bug, and
resolved Jenkins test failures in mips sub-pel filter optimizations.

BUG=webm:1568

Change-Id: I51eb8adb7ed194ef2ea7dd4aa57aa9870ee38cfc

6 years agoMerge "fix output file check in vpxenc tests script."
Jerome Jiang [Tue, 16 Oct 2018 06:09:36 +0000 (06:09 +0000)]
Merge "fix output file check in vpxenc tests script."

6 years agoMerge "Add frame_gop_index to GF_GROUP"
Jingning Han [Tue, 16 Oct 2018 03:49:52 +0000 (03:49 +0000)]
Merge "Add frame_gop_index to GF_GROUP"

6 years agoMerge "Add encoder side frame buffer for tpl model"
Jingning Han [Tue, 16 Oct 2018 03:49:25 +0000 (03:49 +0000)]
Merge "Add encoder side frame buffer for tpl model"

6 years agofix output file check in vpxenc tests script.
Jerome Jiang [Tue, 16 Oct 2018 00:10:22 +0000 (17:10 -0700)]
fix output file check in vpxenc tests script.

BUG=webm:1556

Change-Id: I4be40e9bf667cd9896017f38d866a47d3e19dcaf

6 years agoMerge "CHANGELOG: fix v1.7.0 release date"
James Zern [Tue, 16 Oct 2018 03:04:37 +0000 (03:04 +0000)]
Merge "CHANGELOG: fix v1.7.0 release date"

6 years agoMerge "Add indep loop for motion_compensated_prediction"
Angie Chiang [Tue, 16 Oct 2018 00:43:25 +0000 (00:43 +0000)]
Merge "Add indep loop for motion_compensated_prediction"

6 years agoEnable ML based partition search breakout for HBD
Hui Su [Mon, 15 Oct 2018 17:41:21 +0000 (10:41 -0700)]
Enable ML based partition search breakout for HBD

For speed 0:
coding loss 0.045%; encoder speedup 6%.

For speed 1(only affects videos smaller than 720p):
coding loss 0.11%; encoder speedup 6.5%.

Change-Id: Ie441c9bad2021503e86fefd2f1fa3e1a42070bec

6 years agoA temporary fix to mips sub-pel filters
Yunqing Wang [Mon, 15 Oct 2018 22:27:49 +0000 (15:27 -0700)]
A temporary fix to mips sub-pel filters

There are Jenkins test failures in mips sub-pel filter optimizations.
[ RUN      ] MSA/ConvolveTest.MatchesReferenceSubpixelFilter/5
../libvpx/test/convolve_test.cc:889: Failure
Expected equality of these values:
  lookup(ref, y * kOutputStride + x)
    Which is: 255
  lookup(out, y * kOutputStride + x)
    Which is: 11
mismatch at (1,0), filters (4,0,1)

This relates to the 4-tap kernel added recently. This CL is a temporary
fix, while we investigate the issue.

BUG=webm:1568

Change-Id: If64c552b794425687cca4fbed893d8ccb73c89a5

6 years agoRefactor GOP reference frame ordering for tpl model
Jingning Han [Mon, 15 Oct 2018 22:27:02 +0000 (15:27 -0700)]
Refactor GOP reference frame ordering for tpl model

Process the frames in the order of GOP structure definition.
Decouple the dependency on rc->baseline_gf_interval.

Change-Id: I0d42c542aca552975cc8f08b0eb8b22ccf6a9537

6 years agoRecord gop size
Jingning Han [Mon, 15 Oct 2018 22:21:23 +0000 (15:21 -0700)]
Record gop size

Keep the frame operations needed within a group of picture.

Change-Id: Iece2e855f21860c930b34a3c586f084f7c61db00

6 years agoAdd frame_gop_index to GF_GROUP
Jingning Han [Mon, 15 Oct 2018 18:48:39 +0000 (11:48 -0700)]
Add frame_gop_index to GF_GROUP

Add frame_gop_index to track the frame offset within a group of
picture. This reworks the GOP frame offset calculation and use
case. The coding stats remain identical.

Change-Id: I94d0957bcc327f6bbeac6e84157635663c36b953

6 years agoAdd encoder side frame buffer for tpl model
Jingning Han [Mon, 15 Oct 2018 17:11:57 +0000 (10:11 -0700)]
Add encoder side frame buffer for tpl model

Add an encoder side reference frame buffer pool to store the
reference frames for tpl model. This servces as an intermediate
step to support multi-layer ARF system. The buffer memory size will
be optimized afterwards.

Change-Id: If2d2f095d4911a4996f6c2a0b0a8e3d235ceadb2

6 years agoCHANGELOG: fix v1.7.0 release date
James Zern [Mon, 15 Oct 2018 21:12:38 +0000 (14:12 -0700)]
CHANGELOG: fix v1.7.0 release date

BUG=webm:1567

Change-Id: Ia6091445504c8c94334bc062c945238782553d44

6 years agoRefactor tpl model setup to support multi-layer ARF setup
Jingning Han [Thu, 11 Oct 2018 19:16:01 +0000 (12:16 -0700)]
Refactor tpl model setup to support multi-layer ARF setup

Generalize the tpl model framework to support the newly designed
GOP structure system. The existing tpl model assumes single layer
ARF.

This design will separate the tpl model operation for GOP with
and without ARF cases. When a GOP has ARF, the maximum lookahead
offset would upper limit the needed frame buffer to build the
tpl model for the entire GOP. When a GOP does not have ARF, we
would use the temporal model in a different approach.

The first step will focus on GOP with ARF. All the tpl model related
operation will only be triggered by ARF frame generation.

Change-Id: I13ab03a7bc68f5a4f6b03f2cb01c10befe955e73

6 years agoMerge "Turn on ml_var_partition_pruning for HBD"
Hui Su [Sat, 13 Oct 2018 15:04:24 +0000 (15:04 +0000)]
Merge "Turn on ml_var_partition_pruning for HBD"

6 years agoMerge "Optimize apply_temporal_filter function"
Yunqing Wang [Sat, 13 Oct 2018 03:12:43 +0000 (03:12 +0000)]
Merge "Optimize apply_temporal_filter function"

6 years agoMerge "Remove unused variable from VP9_COMP"
Jingning Han [Sat, 13 Oct 2018 02:10:26 +0000 (02:10 +0000)]
Merge "Remove unused variable from VP9_COMP"

6 years agoOptimize apply_temporal_filter function
Yunqing Wang [Fri, 12 Oct 2018 19:25:36 +0000 (12:25 -0700)]
Optimize apply_temporal_filter function

This patch optimized apply_temporal_filter function. The diff^2 for each
pixel in the 16x16 block is calculated once beforehand, so that we don't
calculate it multiple times while evaluating a pixel's neighbors. This
would speed up the function.

Change-Id: Ibdb8b041f317fd6df198950e2acf9cfcde26860d

6 years agoTurn on ml_var_partition_pruning for HBD
Hui Su [Fri, 12 Oct 2018 17:59:48 +0000 (10:59 -0700)]
Turn on ml_var_partition_pruning for HBD

This affects speed 0 and 1 only.

Tested on lowres_bd10(480p) and midres_bd10(720p),
                   speed 0       speed 1
coding loss:        0.07%         0.10%
encoder speedup:     14%          6.5%

Change-Id: I5812400d8c7393321b7284d3fca06026842390b5

6 years agoMerge "Enable ML based rect partition pruning for HBD"
Hui Su [Fri, 12 Oct 2018 19:59:53 +0000 (19:59 +0000)]
Merge "Enable ML based rect partition pruning for HBD"

6 years agoEnable ML based rect partition pruning for HBD
Hui Su [Thu, 11 Oct 2018 21:33:40 +0000 (14:33 -0700)]
Enable ML based rect partition pruning for HBD

Tested on lowres_bd10(480p) and midres_bd10(720p), average coding
loss is 0.09%; average encoding speedup is 9%.

Only speed 0 is affected.

Change-Id: Ia8d48c1c6d1669745f0e956b172572a37e42f0c7

6 years agoMerge "Make 4-tap interp filter coefficients even numbers"
Yunqing Wang [Fri, 12 Oct 2018 16:14:00 +0000 (16:14 +0000)]
Merge "Make 4-tap interp filter coefficients even numbers"

6 years agoRemove unused variable from VP9_COMP
Jingning Han [Thu, 11 Oct 2018 22:23:19 +0000 (15:23 -0700)]
Remove unused variable from VP9_COMP

Change-Id: I61447b7a21ac5b03f2a6accd6e433d8f9369e508

6 years agoMake 4-tap interp filter coefficients even numbers
Yunqing Wang [Thu, 11 Oct 2018 22:13:47 +0000 (15:13 -0700)]
Make 4-tap interp filter coefficients even numbers

This CL modified 4-tap interp filter coefficients to be even numbers,
which would help in writing 4-tap filter SIMD optimizations. The coding
performance change was negligible. Speed 1 borg test showed:
        avg_psnr:  ovr_psnr:    ssim:
lowres:  -0.003    -0.012      -0.017
midres:  0.029     0.018        0.043
hdres:   0.024     0.044        0.033

Change-Id: Id7c54bb9a9c1aee19c41bc6f1dc3b9682d158bba

6 years agoMerge "ML_VAR_PARTITION: adjust model threshold"
Hui Su [Thu, 11 Oct 2018 23:41:57 +0000 (23:41 +0000)]
Merge "ML_VAR_PARTITION: adjust model threshold"

6 years agoMerge "Call tpl model build at the beginning of a GOP"
Jingning Han [Thu, 11 Oct 2018 16:22:01 +0000 (16:22 +0000)]
Merge "Call tpl model build at the beginning of a GOP"

6 years agoMerge "Revert "vp8: Increase rate threshold for overshoot-drop""
Marco Paniconi [Thu, 11 Oct 2018 10:25:12 +0000 (10:25 +0000)]
Merge "Revert "vp8: Increase rate threshold for overshoot-drop""

6 years agoRevert "vp8: Increase rate threshold for overshoot-drop"
Marco Paniconi [Thu, 11 Oct 2018 10:24:16 +0000 (10:24 +0000)]
Revert "vp8: Increase rate threshold for overshoot-drop"

This reverts commit bc066684ca4deff24d02ee56071d731b431bf438.

Reason for revert: <INSERT REASONING HERE>
Regression in webrtc perf test

Original change's description:
> vp8: Increase rate threshold for overshoot-drop
>
> Increase the rate threshold for the dropping when
> overshoot is detected during encoding. This helps
> to prevent some unneccessary drops for hard content.
>
> Change-Id: I258bf33883d46347efd44e1e192cb25c444d05fe

TBR=sprang@chromium.org,marpan@google.com,builds@webmproject.org

# Not skipping CQ checks because original CL landed > 1 day ago.

Change-Id: Ib0e84747430ba6d04e479f9efd86d628b80a1e67

6 years agoMerge changes Ia5978d91,I3e3754f3
Angie Chiang [Thu, 11 Oct 2018 01:18:45 +0000 (01:18 +0000)]
Merge changes Ia5978d91,I3e3754f3

* changes:
  Simplify mode_estimation / tpl_model_store
  Move [inter/intra]_cost change to mode_estimation

6 years agoAdd indep loop for motion_compensated_prediction
Angie Chiang [Wed, 10 Oct 2018 22:10:07 +0000 (15:10 -0700)]
Add indep loop for motion_compensated_prediction

This is for non_greedy_mv experiment only
This is part of the change of changing mv search order according
feature_score.

Change-Id: I432efccd83d448a4a275dffd37921c76c3d84588

6 years agoMerge "Loopfilter Multi-Thread Optimization"
Harish Mahendrakar [Thu, 11 Oct 2018 00:03:26 +0000 (00:03 +0000)]
Merge "Loopfilter Multi-Thread Optimization"

6 years agoMerge "subpel asm: fix whitespace"
James Zern [Wed, 10 Oct 2018 22:11:15 +0000 (22:11 +0000)]
Merge "subpel asm: fix whitespace"

6 years agoCall tpl model build at the beginning of a GOP
Jingning Han [Wed, 10 Oct 2018 21:52:30 +0000 (14:52 -0700)]
Call tpl model build at the beginning of a GOP

The gop index 0 is default as kf / gf. The effective first coding
frame controlled by the current GOP rate allocation is indexed 1.
Call the tpl model build for the current GOP once at index 1
position. This would unify the calling system for single/multi-layer
ARF GOP structure.

Change-Id: I4ce69337e04646098d5513c0aa56b4e0b4483337

6 years agoMerge "Use 4-tap interp filter in speed 1 sub-pel motion search"
Yunqing Wang [Wed, 10 Oct 2018 21:05:44 +0000 (21:05 +0000)]
Merge "Use 4-tap interp filter in speed 1 sub-pel motion search"

6 years agosubpel asm: fix whitespace
Johann [Wed, 10 Oct 2018 14:44:49 +0000 (07:44 -0700)]
subpel asm: fix whitespace

Change-Id: I7a3314a268cf6049a7260361043e76d4561085c6

6 years agoSimplify mode_estimation / tpl_model_store
Angie Chiang [Tue, 9 Oct 2018 20:40:47 +0000 (13:40 -0700)]
Simplify mode_estimation / tpl_model_store

1) Let mode_estimation() save the results into tpl_frame directly
2) In tpl_model_store(), replace copies of tpl_stats parameters by
   memset()

Change-Id: Ia5978d91cb60cf896bd53d3f27701ef9ae3ba09a

6 years agoMove [inter/intra]_cost change to mode_estimation
Angie Chiang [Tue, 9 Oct 2018 19:43:36 +0000 (12:43 -0700)]
Move [inter/intra]_cost change to mode_estimation

Change-Id: I3e3754f349d31d17554f02bd14cd34620057ddcb

6 years agoMerge changes I67700eba,I9e8f8ed3,Id93565cc
Angie Chiang [Tue, 9 Oct 2018 18:33:32 +0000 (18:33 +0000)]
Merge changes I67700eba,I9e8f8ed3,Id93565cc

* changes:
  Move feature_score into an independent for loop
  Add set_mv_limits()
  Move lambda into TplDepFrame

6 years agoUse 4-tap interp filter in speed 1 sub-pel motion search
Yunqing Wang [Mon, 8 Oct 2018 23:21:54 +0000 (16:21 -0700)]
Use 4-tap interp filter in speed 1 sub-pel motion search

Added the 4-tap interp filter, and used it for speed 1 sub-pel motion
search. Speed 2 motion search still used bilinear filter as before.

Speed 1 borg test showed good bit savings.
        avg_psnr:  ovr_psnr:    ssim:
lowres:  -1.125    -1.179      -1.021
midres:  -0.717    -0.710      -0.543
hdres:   -0.357    -0.370      -0.342
Speed test at speed 1 showed ~10% encoder time increase, which was
partially because of no SIMD version of 4-tap filter.

Change-Id: Ic9b48cdc6a964538c20144108526682d64348301

6 years agoAdd accurate sub-pel motion search
Yunqing Wang [Mon, 8 Oct 2018 22:10:12 +0000 (15:10 -0700)]
Add accurate sub-pel motion search

Added the accurate sub-pel motion search. In this patch, used the 8-tap
filter in sub-pel motion search, and this was enabled at speed 0.

Speed 0 borg test showed that
        avg_psnr:  ovr_psnr:    ssim:
lowres:  -1.363     -1.403     -1.282
midres:  -0.842     -0.849     -0.720
hdres:   -0.480     -0.488     -0.503
Speed test at speed 0 showed ~8% encoder time increase.

Change-Id: I194ca709681ea588f3f6381093940e22d03c4d7b

6 years agoMerge "Set up the unit scaling factor for motion search"
Yunqing Wang [Tue, 9 Oct 2018 16:08:06 +0000 (16:08 +0000)]
Merge "Set up the unit scaling factor for motion search"

6 years agoMove feature_score into an independent for loop
Angie Chiang [Mon, 8 Oct 2018 23:37:15 +0000 (16:37 -0700)]
Move feature_score into an independent for loop

We aim at change the mv search order according to feature_score
This is part of the change.

Change-Id: I67700eba014df92190eabc78060cf29adf0fc38b

6 years agoAdd set_mv_limits()
Angie Chiang [Mon, 8 Oct 2018 22:51:05 +0000 (15:51 -0700)]
Add set_mv_limits()

Change-Id: I9e8f8ed3eb150b3af1f465f595000bd05d43f3f6

6 years agoSet up the unit scaling factor for motion search
Yunqing Wang [Mon, 8 Oct 2018 18:43:02 +0000 (11:43 -0700)]
Set up the unit scaling factor for motion search

Set up the unit scaling factor used during motion search.

Change-Id: I6fda018d593b7ad4b7658d44c39be950a502d192

6 years agoLoopfilter Multi-Thread Optimization
Supradeep T R [Tue, 12 Jun 2018 08:27:39 +0000 (13:57 +0530)]
Loopfilter Multi-Thread Optimization

Take the original loopfilter multi-thread optimization
(dafe064289a917977439ab6f4f002b9946496084) along with the fixes for bugs
1558 and 1562.

BUG=webm:1558
BUG=webm:1562

Change-Id: Ibbf6bd13f4ffff0e79184ccfd6b85a49e067a6d8

6 years agoMove lambda into TplDepFrame
Angie Chiang [Mon, 8 Oct 2018 21:35:26 +0000 (14:35 -0700)]
Move lambda into TplDepFrame

Change-Id: Id93565cca41e00d4ab5de4c6de30accabf2adc52

6 years agoReduce the cpi->scaled_ref_idx array size by 1.
Wan-Teh Chang [Fri, 5 Oct 2018 18:27:01 +0000 (11:27 -0700)]
Reduce the cpi->scaled_ref_idx array size by 1.

The last element of the cpi->scaled_ref_idx array was not used, so
reduce the array size by 1.

The corresponding libaom CL is
https://aomedia-review.googlesource.com/c/aom/+/72445.

Change-Id: I9166f0fbe1a7898c8b611b1535fcc74b4f766997

6 years agoMerge "Avoid null checks related to pool->frame_bufs."
Wan-Teh Chang [Mon, 8 Oct 2018 20:51:28 +0000 (20:51 +0000)]
Merge "Avoid null checks related to pool->frame_bufs."

6 years agoMerge "Correct a for loop in init_ref_frame_bufs."
Wan-Teh Chang [Mon, 8 Oct 2018 19:07:02 +0000 (19:07 +0000)]
Merge "Correct a for loop in init_ref_frame_bufs."

6 years agoMerge "Turn on ml_var_partition_pruning for speed 1"
Hui Su [Mon, 8 Oct 2018 17:25:23 +0000 (17:25 +0000)]
Merge "Turn on ml_var_partition_pruning for speed 1"

6 years agoCorrect a for loop in init_ref_frame_bufs.
Wan-Teh Chang [Mon, 8 Oct 2018 17:03:06 +0000 (10:03 -0700)]
Correct a for loop in init_ref_frame_bufs.

The cm->ref_frame_map and pool->frame_bufs arrays are of different sizes
(REF_FRAMES and FRAME_BUFFERS, respectively), so init_ref_frame_bufs()
cannot iterate over these two arrays using the same for loop.

Change-Id: Ica5bbd9d0c30ea3d089ad2d4bcf6cd8ae2daea64

6 years agoAvoid null checks related to pool->frame_bufs.
Wan-Teh Chang [Mon, 8 Oct 2018 16:41:55 +0000 (09:41 -0700)]
Avoid null checks related to pool->frame_bufs.

It seems that null pointer checks such as the following may make clang
scan-build think pool->frame_bufs may be a null pointer:

    buf = (buf_idx != INVALID_IDX) ? &pool->frame_bufs[buf_idx] : NULL;
    if (buf != NULL) {

This "misinformation" may make scan-build warn about the ref_cnt_fb()
function's use of its 'bufs' argument (Dereference of null pointer) when
we pass pool->frame_bufs to ref_cnt_fb().

Rewriting the above code as:

    if (buf_idx != INVALID_IDX) {
      buf = &pool->frame_bufs[buf_idx];

not only is clearer but also avoids confusing scan-build.

Change-Id: Ia64858dbd7ff89f74ba1a4fc9239b0c4413592c8

6 years agoMerge "Changes to facilitate accurate sub-pel motion search"
Yunqing Wang [Mon, 8 Oct 2018 15:41:09 +0000 (15:41 +0000)]
Merge "Changes to facilitate accurate sub-pel motion search"

6 years agoMerge "Fix bug in prepare_nb_full_mvs"
Angie Chiang [Sat, 6 Oct 2018 00:42:47 +0000 (00:42 +0000)]
Merge "Fix bug in prepare_nb_full_mvs"

6 years agoTurn on ml_var_partition_pruning for speed 1
Hui Su [Tue, 2 Oct 2018 21:40:27 +0000 (14:40 -0700)]
Turn on ml_var_partition_pruning for speed 1

Coding loss:
lowres 0.08%; midres 0.11%; hdres 0.07%

Average encoding speedup is about 6%.

Change-Id: I950291cf0f1d610bcdedeb150bcbefea2f5579bc

6 years agoML_VAR_PARTITION: adjust model threshold
Hui Su [Wed, 3 Oct 2018 16:07:07 +0000 (09:07 -0700)]
ML_VAR_PARTITION: adjust model threshold

Make decisions more aggressively to improve encoding speed.

Coding gains(avg-psnr) after this change over baseline:
rtc       1.55% for speed 7;  2.89% for speed 8.
ytlivehr  2.20% for speed 6.

Change-Id: If6ac4a942a5b4708bcc6b0a49bd92fbc4d67c3f8

6 years agoChanges to facilitate accurate sub-pel motion search
Yunqing Wang [Fri, 5 Oct 2018 17:42:48 +0000 (10:42 -0700)]
Changes to facilitate accurate sub-pel motion search

This patch included changes to facilitate accurate sub-pel motion
search. More patch will follow to turn on accurate sub-pel motion
search.

Change-Id: I224c28c338353fe5c7609372162f79885c54248f

6 years agoFix bug in prepare_nb_full_mvs
Angie Chiang [Thu, 4 Oct 2018 22:17:02 +0000 (15:17 -0700)]
Fix bug in prepare_nb_full_mvs

Previously, the prepare_nb_full_mvs might construct nb_full_mv with
wrong mvs (from other ref frame).
The following changes will fix the bug.
1) Let ready in TplDepStats becomes int array
2) Add parameter rf_idx
3) Use mv_arr instead of mv to build the nb_full_mv

Change-Id: I199798aec4c6762d54799562e142457cc26ee043

6 years agoMerge "Clean up vp9_firstpass.h"
Jingning Han [Thu, 4 Oct 2018 15:26:31 +0000 (15:26 +0000)]
Merge "Clean up vp9_firstpass.h"

6 years agoMerge "Add mv_{dist/cost}_sum to TplDepFrame"
Angie Chiang [Thu, 4 Oct 2018 00:48:42 +0000 (00:48 +0000)]
Merge "Add mv_{dist/cost}_sum to TplDepFrame"

6 years agoClean up vp9_firstpass.h
Jingning Han [Wed, 3 Oct 2018 23:01:26 +0000 (16:01 -0700)]
Clean up vp9_firstpass.h

Remove unused functions and macros.

Change-Id: I46458a60f75637c66af0e18ad876a2634e5818bb

6 years agovp8: Increase rate threshold for overshoot-drop
Marco Paniconi [Wed, 3 Oct 2018 22:25:32 +0000 (15:25 -0700)]
vp8: Increase rate threshold for overshoot-drop

Increase the rate threshold for the dropping when
overshoot is detected during encoding. This helps
to prevent some unneccessary drops for hard content.

Change-Id: I258bf33883d46347efd44e1e192cb25c444d05fe

6 years agoMerge changes I66b35ef7,Ic9ed6ed6,Ie5818689
Angie Chiang [Wed, 3 Oct 2018 01:05:21 +0000 (01:05 +0000)]
Merge changes I66b35ef7,Ic9ed6ed6,Ie5818689

* changes:
  Add mv_dist/mv_cost to TplDepStats
  Change interface of motion_compensated_prediction
  Separate lambda from nb_mvs_inconsistency()

6 years agoMerge "Change the frame used to set up encoder in tests to 0."
Chi Yo Tsai [Wed, 3 Oct 2018 00:07:55 +0000 (00:07 +0000)]
Merge "Change the frame used to set up encoder in tests to 0."

6 years agoChange the frame used to set up encoder in tests to 0.
chiyotsai [Tue, 2 Oct 2018 20:51:48 +0000 (13:51 -0700)]
Change the frame used to set up encoder in tests to 0.

Change-Id: Ied460b6ff53a58050d53dec8d32b627de5de3f3a

6 years agoMerge "Minor clean-up in tiny_ssim.c"
Jingning Han [Tue, 2 Oct 2018 21:16:35 +0000 (21:16 +0000)]
Merge "Minor clean-up in tiny_ssim.c"

6 years agoMerge "Force even arf group length where possible."
Jingning Han [Tue, 2 Oct 2018 21:16:19 +0000 (21:16 +0000)]
Merge "Force even arf group length where possible."

6 years agoMerge "Keep metric log only for the displayable frames"
Jingning Han [Tue, 2 Oct 2018 18:24:29 +0000 (18:24 +0000)]
Merge "Keep metric log only for the displayable frames"

6 years agoMerge "Fix vpxenc per frame psnr and ssim print"
Jingning Han [Tue, 2 Oct 2018 18:24:25 +0000 (18:24 +0000)]
Merge "Fix vpxenc per frame psnr and ssim print"

6 years agoMinor clean-up in tiny_ssim.c
Jingning Han [Tue, 2 Oct 2018 17:21:43 +0000 (10:21 -0700)]
Minor clean-up in tiny_ssim.c

Report the correct filename in error message.
Explicitly assign floating point value to double type.

Change-Id: I42fd2da6e16b1e3e7ec221d5d562a728a93c0196

6 years agoForce even arf group length where possible.
Paul Wilkins [Tue, 2 Oct 2018 15:11:14 +0000 (16:11 +0100)]
Force even arf group length where possible.

This patch tweaks the calculation of the active maximum GF interval
and also the break out clause for the GF interval loop. The changes
force the maximum and where possible the  break out value to be odd
which in turn will result in an even length ARF group if ARF coding is
selected (vs GF only coding).

The primary aim was to improve coding with multi layer arf groups.
For the single layer case there are small net gains in 3 out of 4 sets
(low,md, hd) and a small net drop for the NF2K set.

For multi-layer the gains (opsnr, ssim, psnr-hvs : -ve = better) were:-

Low res: -0.109, -0.038, -0.036
Mid res: -0.204, -0.171, -0.242
Hd res: -0.330, -0.471, -0.496
NF 2k: -0.165, -0.149, -0.157

Change-Id: I245f8561f5d1bd34312a0133c670c2154a0da23f

6 years agoKeep metric log only for the displayable frames
Jingning Han [Mon, 1 Oct 2018 22:31:27 +0000 (15:31 -0700)]
Keep metric log only for the displayable frames

The end-to-end reconstruction quality is represented only by the
displayable frames. Drop the coding stats from ARF frames.

Change-Id: Ib8241db448611f4b6477f107930eaa273f960e20

6 years agoFix vpxenc per frame psnr and ssim print
Jingning Han [Mon, 1 Oct 2018 22:26:00 +0000 (15:26 -0700)]
Fix vpxenc per frame psnr and ssim print

Fix compiler error and make the encoder properly log the psnr and
ssim.

Change-Id: I7b35541131acaa60117bb1e458508b82a4b4677e

6 years agoIntroduce the ml_var_partition_pruning feature
Hui Su [Sat, 29 Sep 2018 21:48:56 +0000 (14:48 -0700)]
Introduce the ml_var_partition_pruning feature

Add the ml_var_partition_pruning encoder speed feature that
uses a neural net model to prune partition-none and partition-split
search. The model uses prediction residue variance and quantization
step size as input features.

Encoding speed gain for speed 0(tested over 20 hdres clips):
            QP=30    QP=40
average     17.7%    18.3%
max        24.46%    26.6%

Coding loss:
lowres 0.071%;  midres 0.098%;  hdres 0.163%

Currently it is enabled for speed 0 low-bit depth only. It needs to be
tuned for other settings.

Change-Id: Ifb7417daa6bb6e7c97bb676269ce54ab0dc7b8c8

6 years agoMerge "Remove deprecated get_arf_buffer_indices()"
Jingning Han [Sat, 29 Sep 2018 04:20:31 +0000 (04:20 +0000)]
Merge "Remove deprecated get_arf_buffer_indices()"

6 years agoMerge "Remove deprecated arf_update_index from GF_GROUP"
Jingning Han [Sat, 29 Sep 2018 04:20:27 +0000 (04:20 +0000)]
Merge "Remove deprecated arf_update_index from GF_GROUP"

6 years agoMerge "Add ml_var_partition experiment"
Hui Su [Sat, 29 Sep 2018 02:00:16 +0000 (02:00 +0000)]
Merge "Add ml_var_partition experiment"

6 years agoMerge changes I93308a09,If85c36b4,I918eb36a
Angie Chiang [Fri, 28 Sep 2018 23:09:19 +0000 (23:09 +0000)]
Merge changes I93308a09,If85c36b4,I918eb36a

* changes:
  Add vpx_clear_system_state to new mv search func
  Change mv color to red
  Call vp9_full_pixel_diamond_new in tpl mv search

6 years agoAdd mv_{dist/cost}_sum to TplDepFrame
Angie Chiang [Fri, 28 Sep 2018 22:52:03 +0000 (15:52 -0700)]
Add mv_{dist/cost}_sum to TplDepFrame

Change-Id: Iacce1f88630ba93ff72d745a83dd4b853b6b61af

6 years agoAdd mv_dist/mv_cost to TplDepStats
Angie Chiang [Fri, 28 Sep 2018 22:40:57 +0000 (15:40 -0700)]
Add mv_dist/mv_cost to TplDepStats

Change-Id: I66b35ef76c229d4eb3bf3c913619a0e219c4c2f9

6 years agoChange interface of motion_compensated_prediction
Angie Chiang [Fri, 28 Sep 2018 21:35:21 +0000 (14:35 -0700)]
Change interface of motion_compensated_prediction

Change the interface of vp9_full_pixel_diamond_new

Change-Id: Ic9ed6ed61c5178f3f445f40860ebaac7ea17f75d

6 years agoSeparate lambda from nb_mvs_inconsistency()
Angie Chiang [Fri, 28 Sep 2018 21:23:23 +0000 (14:23 -0700)]
Separate lambda from nb_mvs_inconsistency()

Change-Id: Ie5818689233ae01742ca595e2c8c3f3664bb426c

6 years agoRemove deprecated get_arf_buffer_indices()
Jingning Han [Fri, 28 Sep 2018 18:30:56 +0000 (11:30 -0700)]
Remove deprecated get_arf_buffer_indices()

Change-Id: I6d0c8a1a61d861aa0353cde76a833c7c0b222279

6 years agoRemove deprecated arf_update_index from GF_GROUP
Jingning Han [Fri, 28 Sep 2018 18:28:35 +0000 (11:28 -0700)]
Remove deprecated arf_update_index from GF_GROUP

As we move to unify the GOP structure layout control, the variable
arf_update_idx and arf_ref_idx are deprecated.

Change-Id: Iadcb9e6033d419d4b2015fe747c23be59a7da787

6 years agoMerge "Fix minor bug in calculation of max arf group length."
Jingning Han [Fri, 28 Sep 2018 17:38:26 +0000 (17:38 +0000)]
Merge "Fix minor bug in calculation of max arf group length."

6 years agoMerge "Adjustment of GOP intra factor for multi-layer."
Jingning Han [Fri, 28 Sep 2018 17:38:14 +0000 (17:38 +0000)]
Merge "Adjustment of GOP intra factor for multi-layer."