1. 06 Sep, 2017 1 commit
    • Debargha Mukherjee's avatar
      Make loop-restoration use 64x64 processing units · 7a5587a8
      Debargha Mukherjee authored
      Changes loop-restoration to use processing unit size that is
      64x64 for luma; for chroma the processing unit is coupled to
      64x64 support region for luma.
      Thus for chroma the processing unit size is 32x32 for 4:2:0,
      32x64 for 4:2:2 and 64x64 for 4:4:4, etc.
      
      While the Wiener filter output should not change with this patch,
      the sgr filter will change since the boundary pixel handling in
      sgr is internal within the filter.
      
      Change-Id: I65a9e2df88927a19445420ce400acb1fcf7afa93
      7a5587a8
  2. 05 Sep, 2017 4 commits
    • Wei-Ting Lin's avatar
      ncobmc-adapt-weight: applying at the encoder as new motion mode · 01d4d8f2
      Wei-Ting Lin authored
      Change-Id: I1cd1197b48a3315fe4f44578b80634be73de17a3
      01d4d8f2
    • Rupert Swarbrick's avatar
      Fix tile height/width calculation · 9a3640d8
      Rupert Swarbrick authored
      In the bitstream in bug 709, the frame has a width of 13318 mi
      units. This rounds up to 13328 mi units (when rounding to a whole
      number of max superblocks) but then the shift right by log2_tile_cols
      gives floor(13328/32) = floor(416.5) = 416. Of course 32*416 = 13312
      which is less than 13318.
      
      This patch moves the <mi_cols, log2_tile_cols> -> tile_width
      calculation (and the equivalent calculation for tile_height) into a
      common function which gets the rounding right.
      
      BUG=aomedia:709
      
      Change-Id: If5e8e6b7a3c6f3d336cda9edd94a17595eaf5406
      9a3640d8
    • Rupert Swarbrick's avatar
      Allow tile_rows/tile_cols to not be a power of 2 · 940942ba
      Rupert Swarbrick authored
      The example bitstream in bug 710 shows what might go on. This has a
      frame with mi_cols=540 and log2_tile_cols=3. But 540/8 = 67.5, which
      gets rounded up to give a tile_width of 5*16=80. However, 540/80 =
      6.75 which means that the frame finishes somewhere in the middle of
      tile 7 (and tile 8 is completely empty).
      
      This patch clamps tile_rows/tile_cols to ensure that can't happen. The
      bitstream still signals ceil(log2(tile_<rows/cols>)) so there's no
      change there.
      
      BUG=aomedia:710
      
      Change-Id: Idfad658ef59cf71674100f5e74bd53dd192c6a84
      940942ba
    • Jonathan Matthews's avatar
      Reset delta_lf_present_flag as required · a48b1e68
      Jonathan Matthews authored
      BUG=aomedia:721
      
      Change-Id: Ic6e767b1c11399379391a2ba92e3ec53dd0a2be0
      a48b1e68
  3. 04 Sep, 2017 3 commits
    • clang-format's avatar
      apply clang-format · 4eafefe0
      clang-format authored
      Change-Id: If0b48a4ee1f7902d8c6154945ccef68a2b5aabb5
      4eafefe0
    • Rupert Swarbrick's avatar
      Check for early end of data when reading tiles · cd75739f
      Rupert Swarbrick authored
      BUG=aomedia:709
      
      Change-Id: I26f8938a744f7ebfd9734929502730b17de348f9
      cd75739f
    • Rupert Swarbrick's avatar
      Replace an assertion with a proper error on bad bitstream · 5c73c003
      Rupert Swarbrick authored
      The example in bug 712 is a bitstream that signals a global motion
      type of ROTZOOM, but its second frame has shear parameters that fail
      the is_affine_shear_allowed check at warped_motion.c:754. This is
      quite possible (and it's not obvious how to change the bitstream
      format so that you can't signal something like this).
      
      This patch replaces the failing assertion with a proper "no you
      can't!" error.
      
      BUG=aomedia:712
      
      Change-Id: I6a32632d17031b777acd2f78a887491a40177785
      5c73c003
  4. 03 Sep, 2017 1 commit
    • Rupert Swarbrick's avatar
      Move loop restoration coefficients to within the frame · 6c545216
      Rupert Swarbrick authored
      Rather than encoding the loop restoration coefficients at the start of
      the frame header, this patch moves them to occur just after certain
      top-level superblocks.
      
      You might hope that we could just encode coefficients on top-level
      superblocks where the top-left corner of the superblock was also the
      top-left corner of the loop restoration tile. Unfortunately, this
      can't work with the superres experiment, where the loop restoration
      tiles don't necessarily line up with the superblocks. Indeed, in
      general there can be multiple different loop restoration coefficients
      that apply in a given top-level superblock. This patch defines a
      function, av1_loop_restoration_corners_in_sb, which yields the
      rectangle [rrow0, rrow1) x [rcol0, rcol1) of loop restoration tiles
      whose top left corners lie in this top-level superblock.
      
      The total file size should be unchanged by this patch: the bits have
      just been moved from the frame header and spread out among the rest of
      the frame.
      
      Change-Id: Icf43b0560964a63dea0d2cd801313f04139188d7
      6c545216
  5. 02 Sep, 2017 1 commit
  6. 01 Sep, 2017 2 commits
    • David Barker's avatar
      Miscellaneous fixes for var-tx · 16c64e33
      David Barker authored
      Lots of small bug fixes, mainly around the transform size coding:
      
      * The loop filter was accidentally using the non-subsampled
        block size for the V plane, due to comparing a plane index
        (0, 1, or 2) against PLANE_TYPE_UV (== 1)
      
      * We allowed an initial update of the transform partition probabilities
        even on frames where we know they will never be used
        (because tx_mode != TX_MODE_SELECT).
        Further, these probabilities would not be reverted at the end
        of the frame, leading to the probability delta persisting across frames.
      
        Change this to behave more like the non-var-tx transform size coding,
        where probability deltas are only coded for frames with
        tx_mode == TX_MODE_SELECT, and the deltas only apply for one frame.
      
      * Fix decoder for the case where the video as a whole isn't lossless,
        and we have tx_mode == TX_MODE_SELECT, but the current segment
        *is* lossless.
        Note that the encoder already does the right thing in this case.
      
      * Don't allow the transform splitting to recurse "below" 4x4.
        This is really just a refactor, but means we can increase the
        maximum depth when subdividing rectangular transforms if we
        want to, whereas the previous code would have needed special cases
        for 4x8 and 8x4 transforms.
      
      * Finally, when we hit the maximum splitting depth, don't update
        the counts as if we had coded a 'no split' symbol.
      
      Change-Id: Iaebdacc9de81d2e93d3c49241e719bbc02e32682
      16c64e33
    • Rupert Swarbrick's avatar
      Encode loop restoration coefficients per tile · 09b5b168
      Rupert Swarbrick authored
      This is a baby-step towards encoding the coefficients at the start of
      superblocks at the top-left of loop restoration tiles. Note that this
      patch causes us to reset "wiener_info" and "sgrproj_info" at each tile
      boundary, which will cause a performance drop.
      
      This is necessary because, in order for tiles to be processed in
      parallel, we cannot delta-encode coefficients across tile boundaries
      if the coefficients are signalled within tiles. We could probably do
      better than the current patch by, say, delta-encoding against previous
      frames.
      
      This patch also fixes up the costing in pickrst.c to match
      
      Change-Id: I5b8b91d63aaf49627cde40219c31c0ac776dfd38
      09b5b168
  7. 31 Aug, 2017 6 commits
    • Cheng Chen's avatar
      Refactor init of segment dequant in delta_q · 49d30e63
      Cheng Chen authored
      Change-Id: I51c80a22db9c4930d18676aab1496106f44f4f3e
      49d30e63
    • Stanislav Vitvitskyy's avatar
      Using CDFs for read_partition special case · 8711cf5f
      Stanislav Vitvitskyy authored
      Test results:
      akiyo	    -0.05%
      bowing	    -0.072%
      bridge	    -0.042%
      bus	    -0.156%
      coastguard  -0.645%
      container   -0.087%
      deadline     0.007%
      flower       0.02%
      football    -0.009%
      foreman      0.03%
      hall         0.087%
      highway     -0.041%
      husky       -0.031%
      mad900       0.015%
      mobile      -0.007%
      mother       0.012%
      news         0.039%
      pamphlet     0.061%
      paris       -0.003%
      sign        -0.148%
      silent       0.003%
      students    -0.009%
      tempete     -0.061%
      waterfall    0.666
      
      Change-Id: I96c2fd3a6fbc5f8e5cf7f3b881ef89335e58d5ac
      8711cf5f
    • Luc Trudeau's avatar
      [CFL] Asserts for chroma_sub8x8 · c84c21c4
      Luc Trudeau authored
      When Chroma from Luma is combined with chroma_sub8x8, the prediction
      used for sub8x8 blocks originates from multiple luma blocks. Extra
      asserts are added to validate that the prediction buffer contains all
      the required information.
      
      Change-Id: I305c46ce9b8292697e1d5b181d123461026da11c
      c84c21c4
    • hui su's avatar
      Remove probablity model for coeffecient tokens · b53682f5
      hui su authored
      Remove the token prob tables and counters.
      
      Change-Id: Ic63d52d80bb922fc10b586c27a20f2378618168c
      b53682f5
    • Jingning Han's avatar
      Enable motion field estimation in DRL · ffbb0f91
      Jingning Han authored
      Enable the use of motion field estimation in the dynamic motion
      vector referencing system. With default experiments on, it improves
      the compression performance:
      
      lowres 1.2%
      midres 1.5%
      
      Change-Id: Ifc5b15a7239b5c3212ea50f326ab99d372034658
      ffbb0f91
    • Jingning Han's avatar
      Add frame index to the decoded frames · c723b348
      Jingning Han authored
      Add frame index to the deocded frames. Store such information to
      the reference frame buffer pool. This design allows each frame
      to know its index in natural order, as well as its reference
      frames positions.
      
      Change-Id: I5bb36928dc5750a4fdcc582dca0d244d6482f400
      c723b348
  8. 30 Aug, 2017 1 commit
  9. 29 Aug, 2017 1 commit
  10. 25 Aug, 2017 1 commit
    • David Barker's avatar
      Fix tile boundary calculation · 5c06a646
      David Barker authored
      Fix a rare case in which the tile boundary information was not
      set up properly in the decoder when using LOOPFILTERING_ACROSS_TILES
      
      The situation was:
      * One frame uses loop filtering across tiles. Then its tile
        boundary information is not needed, so is not calculated.
      * The next frame (in decode order) has the same size and the
        same tile layout, but doesn't use loop filtering across tiles.
      * Now the tile boundary information *is* needed, but we weren't
        recalculating it. This resulted in the loop filter being
        applied across tile boundaries even though we signalled not to.
      
      Since the conditions on when we can reuse the previous frame's
      boundary information are complex, and the overhead of calculating
      the tile boundaries is low, we avoid this issue by simply
      recalculating the boundary information each frame.
      
      Change-Id: I1f3cbb0537535bf38faaed4c21c07142e747f962
      5c06a646
  11. 24 Aug, 2017 1 commit
    • Rupert Swarbrick's avatar
      Correct apparent typo in fix for bug 693 · 17a61d4e
      Rupert Swarbrick authored
      Patch 323d535d fixes the reported bug but doesn't correctly read a
      global transformation of type TRANSLATION or AFFINE. Fortunately,
      clang gives a warning about the ignored expression.
      
      Change-Id: I1127d5d5b809bf016872a3ba97903599869d5357
      17a61d4e
  12. 23 Aug, 2017 1 commit
  13. 22 Aug, 2017 3 commits
    • Yaowu Xu's avatar
      Revert "Prevent access of array using -1 index" · 03dc6799
      Yaowu Xu authored
      This reverts commit 38cdce8e.
      
      Reason for revert: <INSERT REASONING HERE>
      
      It is reported that this introduced a segment fault, revert now to investigate. 
      
      Change-Id: I229dcdc09462ae4eb9cf2a3da4ce59aa9eafe65e
      03dc6799
    • Lester Lu's avatar
      Refactor lgt · 918fe698
      Lester Lu authored
      Change get_lgt in order to integrate a later experiment
      lgt_from_pred with lgt. There are two main changes.
      
      The main purpose for this change is to unify get_fwd_lgt and
      get_inv_lgt functions into a get_lgt function so the lgt basis
      functions can always be selected through the same function in
      both forward and inverse transform paths. The structure of those
      functions will also be consistent with the get_lgt_from_pred
      functions that will be added in the lgt-from-pred experiment.
      
      These changes have no impact on the bitstream.
      
      Change-Id: Ifd3dfc1a9e1a250495830ddbf42c201e80aa913e
      918fe698
    • Debargha Mukherjee's avatar
      Adds the option to use 5x5 Wiener for chroma · 1cb757cb
      Debargha Mukherjee authored
      Change-Id: I1b789acc18f1e69fb5db069ccd8bd17815938e9d
      1cb757cb
  14. 21 Aug, 2017 1 commit
  15. 19 Aug, 2017 2 commits
    • Cheng Chen's avatar
      Change experimental flag name · 13fc8194
      Cheng Chen authored
      CONFIG_UV_LVL --> CONFIG_LOOPFILTER_LEVEL
      Change name because the experiment combines filter level search
      in U, V plane, and horizontal, vertical search in Y plane.
      
      Change-Id: Ia05b8f80cd93b60a0305eb94e5783559ef904c13
      13fc8194
    • Cheng Chen's avatar
      Dual deblocking filter strength thresholds · 179479fe
      Cheng Chen authored
      A new experiment for deblocking filter that separates vertical
      and horizontal filter strengths. This experiment is based on the
      assumption that non-flatness characteristics of vertical and
      horizontal direction may differ. Therefore selecting different
      filter strengths for vertical and horizontal can improve deblocking
      performance.
      
      The process of finding proper filter strength:
      1. Search through the filter level under the constraint that
         (vertical == horizontal), and find the best solution.
      2. Fix vertical level as the best solution found in step 1 and vary
         horizontal level to find the best value.
      3. Fix the selected horizontal level, vary vertical level to find
         its best value.
      
      The experiment is working with UV_LVL, sharing the same config flag.
      The searching for horizontal and vertical filter strength only applies
      on Y plane for now.
      
      The experimental flag should be changed to filter_level later.
      
      Change-Id: I164eec8d3ccb3da7ff109c5c55f4b52c1536ddf1
      179479fe
  16. 18 Aug, 2017 1 commit
    • Hui Su's avatar
      Remove dpcm-intra experiment · 400bf651
      Hui Su authored
      Coding gain becomes tiny on top of other experiments.
      
      Change-Id: Ia89b1c2a2653f3833dff8ac8bb612eaa3ba18446
      400bf651
  17. 17 Aug, 2017 1 commit
    • Yushin Cho's avatar
      cdef-dist and daala-dist is runtime switchable · e30a47ca
      Yushin Cho authored
      Use --tune=[cdef-dist|daala-dist] to enable them.
      
      Also, this commit set the use_activity_masking of PVQ as 0 by deafult,
      which means that PVQ assumes daala-dist is not used by default.
      
      Since we're currently not signaling which metric the encoder did use
      in the bitstream, the compile flag AV1_PVQ_ENABLE_ACTIVITY_MASKING will tell PVQ
      whether daala-dist is used or not.
      
      This commit is the last part of prep-work to remove DIST_8X8, CDEF_DIST,
      and DAALA_DIST experimental flags.
      
      Change-Id: Ia465b4d6fe64aac7f04852c8f9f4bac3409d2435
      e30a47ca
  18. 16 Aug, 2017 2 commits
    • Frederic Barbier's avatar
      Fix memory corruption · 94e3856e
      Frederic Barbier authored
      Fix a memory corruption introduced by commit
      f190a165
      
      On some cases, when empty tiles are present,
      av1_set_across_tile_boundary_info() writes beyond mode info array.
      
      Sanity check added.
      
      BUG=aomedia:690
      
      Change-Id: I8d87a2e183c69d0ed039c8b2f77b30434f837974
      94e3856e
    • Zoe Liu's avatar
      Add dependency of ext-comp-refs on one-sided-compound · 5a978838
      Zoe Liu authored
      When ext-comp-refs is enabled, one-sided-compound is enabled by default,
      which ensures the use of ext-comp-refs is an extension of
      one-sided-compound. Both coding tools allow the use of same-sided
      reference frame pairs for compound prediction.
      
      Also, remove the dependency of ext-comp-refs on var-refs, i.e. these two
      coding tools can be independently enabled. They can still work together
      if both are enabled simultaneously.
      
      Change-Id: I3134e7e2956dc35d557fe814f5d801d473683650
      5a978838
  19. 15 Aug, 2017 1 commit
    • Debargha Mukherjee's avatar
      Miscellaneous fixes for resize/frame-superres · 17e7b081
      Debargha Mukherjee authored
      1. Fixes logic for disabling global motion w/ resize. Turns off
      conditional write/read of global parameters since it does not
      work currenlty. To be fixed later.
      2. Fixes call for av1_scale_if_required in encoder_frame_with_resize
      function
      3. Remove asserts for the scaled convolve functions
      
      Change-Id: I6a0f18b5ab5cc819bc27ef9fc2f28b0e391643a0
      17e7b081
  20. 11 Aug, 2017 1 commit
    • Steinar Midtskogen's avatar
      Add experiment CONFIG_CDEF_SINGLEPASS: Make CDEF single pass · 5978212b
      Steinar Midtskogen authored
      Low latency, cpu-used=0:
         PSNR | PSNR Cb | PSNR Cr | PSNR HVS |    SSIM | MS SSIM | CIEDE 2000
      -0.3162 | -0.6719 | -0.6535 |   0.0089 | -0.3890 | -0.1515 |    -0.6682
      
      High latency, cpu-used=0:
         PSNR | PSNR Cb | PSNR Cr | PSNR HVS |    SSIM | MS SSIM | CIEDE 2000
      -0.0293 | -0.3556 | -0.5505 |   0.0684 | -0.0862 |  0.0513 |    -0.2765
      
      Low latency, cpu-used=4:
         PSNR | PSNR Cb | PSNR Cr | PSNR HVS |    SSIM | MS SSIM | CIEDE 2000
      -0.2248 | -0.7764 | -0.6630 |  -0.2109 | -0.3240 | -0.2532 |    -0.6980
      
      High latency, cpu-used=4:
         PSNR | PSNR Cb | PSNR Cr | PSNR HVS |    SSIM | MS SSIM | CIEDE 2000
      -0.1118 | -0.5841 | -0.7406 |  -0.0463 | -0.2442 | -0.1064 |    -0.4187
      
      Change-Id: I9ca8399c8f45489541a66f535fb3d771eb1d59ab
      5978212b
  21. 10 Aug, 2017 1 commit
    • Urvang Joshi's avatar
      Remove PALETTE flag · c6300aa1
      Urvang Joshi authored
      This experiment is now adopted as it was cleared by Tapas.
      
      Note: Palette use can still be controlled by command-line option
      "--tune-content=..." in 'aomenc'.
      
      Change-Id: I832f49f20f60c34bdef5b424755849c496687e87
      c6300aa1
  22. 04 Aug, 2017 1 commit
    • Steinar Midtskogen's avatar
      CDEF cleanup · 94de0aaa
      Steinar Midtskogen authored
      Name changes and code moves to bring code more in line with the
      design doc and an upcoming single-pass patch.  No functional changes.
      
      Change-Id: I2bccd58c644e534b139f420b623390aa971fbdb0
      94de0aaa
  23. 02 Aug, 2017 1 commit
  24. 01 Aug, 2017 2 commits