<div dir="ltr"><div class="gmail_extra"><div><div class="m_-6004183161502149653gmail_signature"><div dir="ltr"><div><div dir="ltr"><br></div></div></div></div></div><div class="gmail_quote">On Mon, Oct 17, 2016 at 8:30 PM, Ashok Kumar Mishra <span dir="ltr"><<a href="mailto:ashok@multicorewareinc.com" target="_blank">ashok@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="m_-6004183161502149653gmail-h5">On Mon, Oct 17, 2016 at 3:14 PM, Bhavna Hariharan <span dir="ltr"><<a href="mailto:bhavna@multicorewareinc.com" target="_blank">bhavna@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div><div class="m_-6004183161502149653gmail-m_7408146970871364652m_-8872129524165594866m_9111306467446214862gmail_signature"><div dir="ltr"><div><div dir="ltr"><br></div></div></div></div></div><div class="gmail_quote"><div><div class="m_-6004183161502149653gmail-m_7408146970871364652h5">On Mon, Oct 17, 2016 at 2:57 PM, Pradeep Ramachandran <span dir="ltr"><<a href="mailto:pradeep@multicorewareinc.com" target="_blank">pradeep@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="m_-6004183161502149653gmail-m_7408146970871364652m_-8872129524165594866m_9111306467446214862gmail-h5">On Fri, Oct 14, 2016 at 7:20 PM, <span dir="ltr"><<a href="mailto:bhavna@multicorewareinc.com" target="_blank">bhavna@multicorewareinc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="m_-6004183161502149653gmail-m_7408146970871364652m_-8872129524165594866m_9111306467446214862gmail-m_8623240897589776712HOEnZb"><div class="m_-6004183161502149653gmail-m_7408146970871364652m_-8872129524165594866m_9111306467446214862gmail-m_8623240897589776712h5"># HG changeset patch<br>
# User Bhavna Hariharan <<a href="mailto:bhavna@multicorewareinc.com" target="_blank">bhavna@multicorewareinc.com</a>><br>
# Date 1476275329 -19800<br>
# Wed Oct 12 17:58:49 2016 +0530<br>
# Node ID 854149baceefa075c3b1af12433680<wbr>ffda2e3b64<br>
# Parent c97805dad9148ad3cddba10a67ed55<wbr>96508e8f86<br>
limitTU: fix energy calculation used in limiting TU recursion<br>
<br>
This commit changes the output of limit TU<br>
<br>
diff -r c97805dad914 -r 854149baceef source/encoder/search.cpp<br>
--- a/source/encoder/search.cpp Thu Oct 13 17:53:48 2016 +0800<br>
+++ b/source/encoder/search.cpp Wed Oct 12 17:58:49 2016 +0530<br>
@@ -3420,14 +3420,15 @@<br>
if (m_param->limitTU && bCheckSplit)<br>
{<br>
// Stop recursion if the TU's energy level is minimal<br>
+ uint32_t numCoeff = trSize * trSize;<br>
if (cbfFlag[TEXT_LUMA][0] == 0)<br>
bCheckSplit = false;<br>
- else if (numSig[TEXT_LUMA][0] < (cuGeom.numPartitions / 16))<br>
+ else if (numSig[TEXT_LUMA][0] < (numCoeff / 64))<br>
{<br>
uint32_t energy = 0;<br>
- for (uint32_t i = 0; i < cuGeom.numPartitions; i++)<br>
+ for (uint32_t i = 0; i < numCoeff; i++)<br>
energy += abs(coeffCurY[i]);<br>
- if (energy < numSig[TEXT_LUMA][0])<br>
+ if (energy == numSig[TEXT_LUMA][0])<br>
bCheckSplit = false;<br></div></div></blockquote><div><br></div></div></div><div>Can you give an example where CheckSplit is disabled here? I am finding it hard to reason conditions under which this condition is satisfied.</div></div></div></div></blockquote><div><br></div></div></div><div>Energy will be equal to the number of significant coefficients when each of the non-zero coefficients is one. </div><span><div> </div></span></div></div></div></blockquote><div><br></div></div></div><div>I feel this condition may not be satisfied(very rare). You are calculating energy as sum of abs values of transform coefficients and checking with a threshold(number of coefficients).</div><div>There is a very less chance that both will be same. Either it should be less than equal to or greater than equal to. This may be a test to replicate a zero coefficient TU block. We </div><div>should check the subjective quality particularly for limit TU, considering larger TUs produce more ringing artifacts. </div></div></div></div></blockquote><div><br></div><div><br></div><div>The number of significant coefficients can never be less than the energy, if the energy is greater than the number of coefficients we don't want to limit the TU depth. We noticed a performance improvement up to 9% for certain videos. We checked the visual quality for the videos and have not observed any ringing artifacts so far. </div><div><br></div><div>croud run:</div><div><br></div><div>with energy check - encoded 500 frames in 545.41s (0.93 fps), 8878.75 kb/s, Avg QP:38.00, SSIM Mean Y: 0.8659922 ( 8.729 dB)<br></div><div>without energy check - encoded 500 frames in 568.05s (0.85 fps), 8879.27 kb/s, Avg QP:38.00, SSIM Mean Y: 0.8660624 ( 8.731 dB)<br></div><div>Improvement in performance - 8.6%</div><div>Hit percentage of energy check - 61%</div><div><br></div><div>kimono:</div><div><br></div><div>with energy check - encoded 240 frames in 286.38s (0.84 fps), 4361.14 kb/s, Avg QP:26.83, SSIM Mean Y: 0.9579188 (13.759 dB)</div><div>without energy check - encoded 240 frames in 312.36s (0.77 fps), 4361.61 kb/s, Avg QP:26.83, SSIM Mean Y: 0.9579364 (13.761 dB)</div><div>Improvement in performance - 8.3% </div><div><div>Hit percentage of energy check - 70%</div></div><div><br></div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span class="m_-6004183161502149653gmail-"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="m_-6004183161502149653gmail-m_7408146970871364652m_-8872129524165594866m_9111306467446214862gmail-m_8623240897589776712HOEnZb"><div class="m_-6004183161502149653gmail-m_7408146970871364652m_-8872129524165594866m_9111306467446214862gmail-m_8623240897589776712h5">
}<br>
}<br>
</div></div>______________________________<wbr>_________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org" target="_blank">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/l<wbr>istinfo/x265-devel</a><br>
</blockquote></div><br></div></div>
<br>______________________________<wbr>_________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org" target="_blank">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/l<wbr>istinfo/x265-devel</a></blockquote><div><br></div></span></div><br></div></div>
<br>______________________________<wbr>_________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org" target="_blank">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/l<wbr>istinfo/x265-devel</a><br>
<br></blockquote></span></div><br></div></div>
<br>______________________________<wbr>_________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org" target="_blank">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/l<wbr>istinfo/x265-devel</a><br>
<br></blockquote></div><br></div></div>