1. 27 Mar, 2013 1 commit
    • Ronald S. Bultje's avatar
      Scatter-based scantables. · 513157e0
      Ronald S. Bultje authored
      This gains about 0.2% on derf, 0.1% on hd and 0.4% on stdhd. I can put
      this under an experimental flag if wanted, just trying to get my patch
      queue in shape.
      
      Change-Id: Ibe1a30fe0e0b07bec4802e0f3ff0ba22e505f576
      513157e0
  2. 26 Mar, 2013 8 commits
    • Deb Mukherjee's avatar
      Implicit weighted prediction experiment · 23144d23
      Deb Mukherjee authored
      Adds an experiment to use a weighted prediction of two INTER
      predictors, where the weight is one of (1/4, 3/4), (3/8, 5/8),
      (1/2, 1/2), (5/8, 3/8) or (3/4, 1/4), and is chosen implicitly
      based on consistency of the predictors to the already
      reconstructed pixels to the top and left of the current macroblock
      or superblock.
      
      Currently the weighting is not applied to SPLITMV modes, which
      default to the usual (1/2, 1/2) weighting. However the code is in
      place controlled by a macro. The same weighting is used for Y and
      UV components, where the weight is derived from analyzing the Y
      component only.
      
      Results (over compound inter-intra experiment)
      derf: +0.18%
      yt: +0.34%
      hd: +0.49%
      stdhd: +0.23%
      
      The experiment suggests bigger benefit for explicitly signaled weights.
      
      Change-Id: I5438539ff4485c5752874cd1eb078ff14bf5235a
      23144d23
    • Ronald S. Bultje's avatar
      Add col/row-based coefficient scanning patterns for 1D 8x8/16x16 ADSTs. · d9094d8f
      Ronald S. Bultje authored
      These are mostly just for experimental purposes. I saw small gains (in
      the 0.1% range) when playing with this on derf.
      
      Change-Id: Ib21eed477bbb46bddcd73b21c5c708a5b46abedc
      d9094d8f
    • Ronald S. Bultje's avatar
      Redo banding for all transforms. · 3120dbdd
      Ronald S. Bultje authored
      Now that the first AC coefficient in both directions use the same DC
      as their context, there no longer is a purpose in letting both have
      their own band. Merging these two bands allows us to split bands for
      some of the very high-frequency AC bands.
      
      In addition, I'm redoing the banding for the 1D-ADST col/row scans. I
      don't think the old banding made any sense at all (it merged the last
      coefficient of the first row/col in the same band as the first two of
      the second row/col), which was clearly an oversight from the band being
      applied in scan-order (rather than in their actual position). Now,
      coefficients at the same position will be in the same band, regardless
      what scan order is used. I think this makes most sense for the purpose
      of banding, which is basically "predict energy for this coefficient
      depending on the energy of context coefficients" (i.e. pt).
      
      After full re-training, together with previous patch, derf gains about
      1.2-1.3%, and hd/stdhd gain about 0.9-1.0%.
      
      Change-Id: I7a0cc12ba724e88b278034113cb4adaaebf87e0c
      3120dbdd
    • Ronald S. Bultje's avatar
      Use above/left (instead of previous in scan-order) as token context. · 790fb132
      Ronald S. Bultje authored
      Pearson correlation for above or left is significantly higher than for
      previous-in-scan-order (absolute values depend on position in scan, but
      in general, we gain about 0.1-0.2 by using either above or left; using
      both basically just makes this even better). For eob branch skipping,
      we continue to use the previous token in scan order.
      
      This helps about 0.9% on derf after re-training on a limited data set.
      Full re-training and results on larger-resolution clips are pending.
      
      Note that this commit breaks trellis, so we can probably get further
      gains out of it by fixing trellis at some later point.
      
      Change-Id: Iead68e296fc3a105cca746b5e3da9555d6010cfe
      790fb132
    • Dmitry Kovalev's avatar
      Decomposition of vp9_decode_frame function. · 4a3d7860
      Dmitry Kovalev authored
      Moving code from vp9_decode_frame function into setup_loopfilter and
      setup_segmentation functions. A little bit of cleanup.
      
      Change-Id: I2cce1813e4d7aeec701ccf752bf57e3bdd41b51c
      4a3d7860
    • John Koleszar's avatar
      Add an in-loop deringing experiment · 441e2eab
      John Koleszar authored
      Adds a per-frame, strength adjustable, in loop deringing filter. Uses
      the existing vp9_post_proc_down_and_across 5 tap thresholded blur
      code, with a brute force search for the threshold.
      
      Results almost strictly positive on the YT HD set, either having no
      effect or helping PSNR in the range of 1-3% (overall average 0.8%).
      Results more mixed for the CIF set, (-0.5 min, 1.4 max, 0.1 avg).
      This has an almost strictly negative impact to SSIM, so examining a
      different filter or a more balanced search heuristic is in order.
      
      Other test set results pending.
      
      Change-Id: I5ca6ee8fe292dfa3f2eab7f65332423fa1710b58
      441e2eab
    • Deb Mukherjee's avatar
      Bugfix in model coef prob experiment · d14c7265
      Deb Mukherjee authored
      Fixes an issue with model based update that got into
      the original patch that was merged.
      
      Change-Id: Ie42d3d0aff2e48cd187d96664dbd3e9d6d3ac22f
      d14c7265
    • Deb Mukherjee's avatar
      Modeling default coef probs with distribution · fd18d5df
      Deb Mukherjee authored
      Replaces the default tables for single coefficient magnitudes with
      those obtained from an appropriate distribution. The EOB node
      is left unchanged. The model is represeted as a 256-size codebook
      where the index corresponds to the probability of the Zero or the
      One node. Two variations are implemented corresponding to whether
      the Zero node or the One-node is used as the peg. The main advantage
      is that the default prob tables will become considerably smaller and
      manageable. Besides there is substantially less risk of over-fitting
      for a training set.
      
      Various distributions are tried and the one that gives the best
      results is the family of Generalized Gaussian distributions with
      shape parameter 0.75. The results are within about 0.2% of fully
      trained tables for the Zero peg variant, and within 0.1% of the
      One peg variant.
      
      The forward updates are optionally (controlled by a macro)
      model-based, i.e. restricted to only convey probabilities from the
      codebook. Backward updates can also be optionally (controlled by
      another macro) model-based, but is turned off by default. Currently
      model-based forward updates work about the same as unconstrained
      updates, but there is a drop in performance with backward-updates
      being model based.
      
      The model based approach also allows the probabilities for the key
      frames to be adjusted from the defaults based on the base_qindex of
      the frame. Currently the adjustment function is a placeholder that
      adjusts the prob of EOB and Zero node from the nominal one at higher
      quality (lower qindex) or lower quality (higher qindex) ends of the
      range. The rest of the probabilities are then derived based on the
      model from the adjusted prob of zero.
      
      Change-Id: Iae050f3cbcc6d8b3f204e8dc395ae47b3b2192c9
      fd18d5df
  3. 25 Mar, 2013 1 commit
    • Dmitry Kovalev's avatar
      Code cleanup. · 7cc14e59
      Dmitry Kovalev authored
      Lower case variable names, code simplification by using already defined
      clamp and read_le16 functions.
      
      Change-Id: I8fd544365bd8d1daed86d7b2ae0843e4ef80df08
      7cc14e59
  4. 21 Mar, 2013 3 commits
    • Yunqing Wang's avatar
      Optimize 16x16 idct10 function · 869d6c05
      Yunqing Wang authored
      Wrote sse2 version of vp9_short_idct10_16x16 function. Compared
      to c version, the sse2 version is 2.3X faster.
      
      Change-Id: I314c4f09369648721798321eeed6f58e38857f26
      869d6c05
    • Dmitry Kovalev's avatar
      Changing initialization order of mb_to_top_edge & mb_to_bottom_edge · 40794024
      Dmitry Kovalev authored
      Making consistent initialization of mb_to_{top,botton,left,right}_edge
      variables after set_mb_row & set_mb_col calls. A little bit of code cleanup
      additionally.
      
      Change-Id: I245bfe32c5701e9836956dc25cf8c770d109cbc1
      40794024
    • Yunqing Wang's avatar
      Optimize 16x16 idct function · ec310066
      Yunqing Wang authored
      Wrote sse2 version of vp9_short_idct16x16 function. Compared to c
      version, the sse2 version is over 2.5X faster.
      
      Change-Id: I38536e2b846427a2cc5c5423aaf305fd0e605d61
      ec310066
  5. 20 Mar, 2013 1 commit
  6. 18 Mar, 2013 2 commits
    • Yunqing Wang's avatar
      Optimize 8x8 idct function · 6344c84c
      Yunqing Wang authored
      Wrote sse2 functions of vp9_short_idct8x8 and vp9_short_idct10_8x8.
      Compared to c version, the sse2 version is 2X faster. The decoder
      test didn't show noticeable gain since 8x8 idct doesn't take much
      of decoding time (less than 1% in my test).
      
      Change-Id: I56313e18cd481700b3b52c4eda5ca204ca6365f3
      6344c84c
    • John Koleszar's avatar
      Replace scaling byte with explicit display size · 8a3f55f2
      John Koleszar authored
      If the intended display size is different than the size the frame is
      coded at, then send that size explicitly in the bitstream. Adds a new
      bit to the frame header to indicate whether the extra size fields
      are present.
      
      Change-Id: I525c66f22d207efaf1e5f903c6a2a91b80245854
      8a3f55f2
  7. 16 Mar, 2013 1 commit
    • Deb Mukherjee's avatar
      Context-pred fix to not use top/left on edges · b1921b2f
      Deb Mukherjee authored
      This fix resolves some of the mismatch issues being seen
      recently. While this is the right thing to do when tiling
      is used for this experiment, it is not the underlying cause
      of the the mismatches.
      Something else is causing writing outside of the allowable
      frame area in the encoder leading to this mismatch.
      
      Change-Id: If52c6f67555aa18ab8762865384e323b47237277
      b1921b2f
  8. 15 Mar, 2013 1 commit
    • Dmitry Kovalev's avatar
      Motion vector code cleanup. · 4a0686e7
      Dmitry Kovalev authored
      Moving identical code to separate functions, variable declaration and
      initialization on the same line.
      
      Change-Id: Ifa6474a64189f9d8051e88e19850453b0227752c
      4a0686e7
  9. 14 Mar, 2013 3 commits
    • Dmitry Kovalev's avatar
      Cleaning up frame decoding functionality. · 9285703e
      Dmitry Kovalev authored
      Change-Id: I25424904fb8541fc19d00d9fbc592379374b98c0
      9285703e
    • John Koleszar's avatar
      Fix pulsing issue with scaling · 9b7be888
      John Koleszar authored
      Updates the YV12_BUFFER_CONFIG structure to be crop-aware. The
      exiting width/height parameters are left unchanged, storing the
      width and height algined to a 16 byte boundary. The cropped
      dimensions are added as new fields.
      
      This fixes a nasty visual pulse when switching between scaled and
      unscaled frame dimensions due to a mismatch between the scaling
      ratio and the 16-byte aligned sizes.
      
      Change-Id: Id4a3f6aea6b9b9ae38bdfa1b87b7eb2cfcdd57b6
      9b7be888
    • John Koleszar's avatar
      Add VP9_GET_REFERENCE control · b3c350a1
      John Koleszar authored
      This is like VP8_COPY_REFERENCE, but returns a pointer to the reference
      frame rather than a copy of it. This is useful when the application
      doesn't know what the size of the reference is, as is the case when
      scaling is in effect.
      
      Change-Id: I63667109f65510364d0e397ebe56217140772085
      b3c350a1
  10. 13 Mar, 2013 1 commit
    • Yaowu Xu's avatar
      removed reference to "LLM" and "x8" · 00555263
      Yaowu Xu authored
      The commit changed the name of files and function to remove obselete
      reference to LLM and x8.
      
      Change-Id: I973b20fc1a55149ed68b5408b3874768e6f88516
      00555263
  11. 12 Mar, 2013 2 commits
    • Paul Wilkins's avatar
      Change buffer update rules on ARF overlay. · 8be3056c
      Paul Wilkins authored
      When coding the frame that corresponds to the midpoint frame
      defining an ARF, do not update the last reference frame buffer.
      Previously this buffer was updated meaning that when coding the next
      ARF all the reference buffers were the same (or nearly so).
      Turning the update off means that the frame before is still available
      as an alternative predictor and for use in compound prediction.
      
      Also fixed inconsistency in test for mismatch (patch from JK).
      
      Net average gains (derf 0.049, yt 0.163, yt-hd 0.207, std-hd 0.286)
      
      Change-Id: Ifee21da21ccbb1648ac2eafe890d3ce60562c7bc
      8be3056c
    • Dmitry Kovalev's avatar
      Code cleanup. · 2891d70b
      Dmitry Kovalev authored
      Removing redundant code, introducing new functions for better
      decomposition, adding 'clamp' function to vp9_common.h.
      
      Change-Id: Ic3b8ca13bbc38f60f0c9c43910b5802005e31aaf
      2891d70b
  12. 09 Mar, 2013 1 commit
    • Deb Mukherjee's avatar
      Continued experiment with nonzero count · a28139c8
      Deb Mukherjee authored
      Adds probability updates for extra bits for the nzcs, code for
      getting nzc stats, plus some minor cleanups and fixes.
      
      Change-Id: If2814e7f04fb52f5025ad9f400f3e6c50a00b543
      a28139c8
  13. 07 Mar, 2013 5 commits
    • Yunqing Wang's avatar
      Optimize add_constant_residual function · f2407826
      Yunqing Wang authored
      Optimized adding constant diff to predictor, which gave about
      2% decoder performance gain.
      
      Change-Id: I47db20c31428e8c4a8f16214a85cbe386a6e9303
      f2407826
    • Yunqing Wang's avatar
      Allocate 16-byte aligned diff buffer · b339aea6
      Yunqing Wang authored
      This was done based on John's suggestion.
      
      Change-Id: I62516a513c31fe3dbea0d6cd063df79d9e819ec8
      b339aea6
    • Ronald S. Bultje's avatar
      Re-add support for ADST in superblocks. · d3724abe
      Ronald S. Bultje authored
      This also changes the RD search to take account of the correct block
      index when searching (this is required for ADST positioning to work
      correctly in combination with tx_select).
      
      Change-Id: Ie50d05b3a024a64ecd0b376887aa38ac5f7b6af6
      d3724abe
    • Yunqing Wang's avatar
      Fix issue in add_residual intrinsic function · 31623715
      Yunqing Wang authored
      Yaowu found this function had a compiling issue with MSVC because
      of using _mm_storel_pi((__m64 *)(dest + 0 * stride), (__m128)p0).
      To be safe, changed back to use integer store instruction.
      
      Also, for some build, diff could not always be 16-byte aligned.
      Changed that in the code.
      
      Change-Id: I9995e5446af15dad18f3c5c0bad1ae68abef6c0d
      31623715
    • Deb Mukherjee's avatar
      Coding con-zero count rather than EOB for coeffs · eb6ef241
      Deb Mukherjee authored
      This patch revamps the entropy coding of coefficients to code first
      a non-zero count per coded block and correspondingly remove the EOB
      token from the token set.
      
      STATUS:
      Main encode/decode code achieving encode/decode sync - done.
      Forward and backward probability updates to the nzcs - done.
      Rd costing updates for nzcs - done.
      Note: The dynamic progrmaming apporach used in trellis quantization
      is not exactly compatible with nzcs. A suboptimal approach has been
      used instead where branch costs are updated to account for changes
      in the nzcs.
      
      TODO:
      Training the default probs/counts for nzcs
      
      Change-Id: I951bc1e22f47885077a7453a09b0493daa77883d
      eb6ef241
  14. 06 Mar, 2013 1 commit
    • Yunqing Wang's avatar
      Optimize add_residual function · 943c6d71
      Yunqing Wang authored
      Optimized adding diff to predictor, which gave 0.8% decoder
      performance gain.
      
      Change-Id: Ic920f0baa8cbd13a73fa77b7f9da83b58749f0f8
      943c6d71
  15. 05 Mar, 2013 2 commits
    • Dmitry Kovalev's avatar
      Code cleanup. · 7f99c3c5
      Dmitry Kovalev authored
      Removing redundant 'extern' keywords, fixing formatting and #include order,
      code simplification.
      
      Change-Id: I0e5fdc8009010f3f885f13b5d76859b9da511758
      7f99c3c5
    • Ronald S. Bultje's avatar
      Make superblocks independent of macroblock code and data. · 111ca421
      Ronald S. Bultje authored
      Split macroblock and superblock tokenization and detokenization
      functions and coefficient-related data structs so that the bitstream
      layout and related code of superblock coefficients looks less like it's
      a hack to fit macroblocks in superblocks.
      
      In addition, unify chroma transform size selection from luma transform
      size (i.e. always use the same size, as long as it fits the predictor);
      in practice, this means 32x32 and 64x64 superblocks using the 16x16 luma
      transform will now use the 16x16 (instead of the 8x8) chroma transform,
      and 64x64 superblocks using the 32x32 luma transform will now use the
      32x32 (instead of the 16x16) chroma transform.
      
      Lastly, add a trellis optimize function for 32x32 transform blocks.
      
      HD gains about 0.3%, STDHD about 0.15% and derf about 0.1%. There's
      a few negative points here and there that I might want to analyze
      a little closer.
      
      Change-Id: Ibad7c3ddfe1acfc52771dfc27c03e9783e054430
      111ca421
  16. 04 Mar, 2013 2 commits
    • Yunqing Wang's avatar
      Optimize vp9_short_idct4x4llm function · e8bc9f42
      Yunqing Wang authored
      Wrote a SSE2 vp9_short_idct4x4llm to improve the decoder
      performance.
      
      Change-Id: I90b9d48c4bf37aaf47995bffe7e584e6d4a2c000
      e8bc9f42
    • Jingning Han's avatar
      Support 16K sequence coding · 5957b2b5
      Jingning Han authored
      Fixed a couple of variable/function definitions, as well as header
      handling to support 16K sequence coding at high bit-rates.
      
      The width and height are each specified by two bytes in the header.
      Use an extra byte to explicitly indicate the scaling factors in
      both directions, each ranging from 0 to 15.
      
      Tested coding up to 16400x16400 dimension.
      
      Change-Id: Ibc2225c6036620270f2c0cf5172d1760aaec10ec
      5957b2b5
  17. 01 Mar, 2013 1 commit
    • Yunqing Wang's avatar
      Add eob<=10 case in idct32x32 · c550bb3b
      Yunqing Wang authored
      Simplified idct32x32 calculation when there are only 10 or less
      non-zero coefficients in 32x32 block. This helps the decoder
      performance.
      
      Change-Id: If7f8893d27b64a9892b4b2621a37fdf4ac0c2a6d
      c550bb3b
  18. 28 Feb, 2013 3 commits
  19. 27 Feb, 2013 1 commit
    • Dmitry Kovalev's avatar
      Motion vectors code cleanup. · 0c0de002
      Dmitry Kovalev authored
      Fixing indentation, removing redundant parenthesis, deciphering single
      letter variable names, better spacing.
      
      Change-Id: I1d447a7d69eddbf1e94e0820423615f40ea2d591
      0c0de002