<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic And in this specific case you in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184496#M27278</link>
    <description>&lt;P&gt;And in this specific case you could also try ippiReduceBits.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Adriaan van Os&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 16 May 2020 08:06:03 GMT</pubDate>
    <dc:creator>Adriaan_van_Os</dc:creator>
    <dc:date>2020-05-16T08:06:03Z</dc:date>
    <item>
      <title>Binarizing an image via thresholding</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184494#M27276</link>
      <description>&lt;P&gt;Hi, the search function is messed up and unusable, so I am creating a new topic without being able to search for a similar thread.&lt;/P&gt;&lt;P&gt;&amp;nbsp;I want to simply binarize a 8bit single channel (gray) image with a threshold. Eg. pixels &amp;gt;= 128 will be set to 255, other pixels (which are &amp;lt;&amp;nbsp; 128) will be set to 0.&lt;/P&gt;&lt;P&gt;None of the ipp thresholding functions seem to work for this. Closest one is Threshold_LTValGTVal which does not accept 128 and 127 as the thresholdLT and thresholdGT values. It says thresholdGT must be &amp;gt;= thresholdLT, which leaves the pixels equal to the threshold as is, if I set both of them to 128.&lt;/P&gt;&lt;P&gt;I believe binarizing an image over a single threshold is a very common operation and I don't want to to aritmetic operations or thresholding twice to achive such a simple task. What am I missing?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Update: the reason i dont want to use arithmetic operations, eg. divide by 128 to binarize is :&lt;/P&gt;
&lt;PRE class="brush:cpp; class-name:dark;"&gt;uint8_t testimg[8] = {1, 126, 127, 128, 129, 139, 254, 255};
uint8_t testout[8] = {0};

ippiDivC_8u_C1RSfs(testimg, 8, 128, testout, 8, IppiSize{8, 1}, 0);

// testout: [0 1 1 1 1 1 2 2]&lt;/PRE&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2020 04:56:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184494#M27276</guid>
      <dc:creator>monarckmills</dc:creator>
      <dc:date>2020-05-15T04:56:39Z</dc:date>
    </item>
    <item>
      <title>Yes, I have stumbled over the</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184495#M27277</link>
      <description>&lt;P&gt;Yes, I have stumbled over the limitations of the IPP threshold functions too. But for 8u and 16u, the alternative is to use ippiLUTPalette.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Adriaan van Os&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2020 23:53:41 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184495#M27277</guid>
      <dc:creator>Adriaan_van_Os</dc:creator>
      <dc:date>2020-05-15T23:53:41Z</dc:date>
    </item>
    <item>
      <title>And in this specific case you</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184496#M27278</link>
      <description>&lt;P&gt;And in this specific case you could also try ippiReduceBits.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Adriaan van Os&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 May 2020 08:06:03 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184496#M27278</guid>
      <dc:creator>Adriaan_van_Os</dc:creator>
      <dc:date>2020-05-16T08:06:03Z</dc:date>
    </item>
    <item>
      <title>Hi Adriaan van Os,</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184497#M27279</link>
      <description>&lt;P&gt;Hi Adriaan van Os,&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;IppStatus ippiCompare_&amp;lt;mod&amp;gt;(const Ipp&amp;lt;datatype&amp;gt;* &lt;EM&gt;pSrc1&lt;/EM&gt;, int &lt;EM&gt;src1Step&lt;/EM&gt;, const&lt;BR /&gt;Ipp&amp;lt;datatype&amp;gt;* &lt;EM&gt;pSrc2&lt;/EM&gt;, int &lt;EM&gt;src2Step&lt;/EM&gt;, Ipp8u* &lt;EM&gt;pDst&lt;/EM&gt;, int &lt;EM&gt;dstStep&lt;/EM&gt;, IppiSize &lt;EM&gt;roiSize&lt;/EM&gt;,&lt;BR /&gt;IppCmpOp &lt;EM&gt;ippCmpOp&lt;/EM&gt;);&lt;BR /&gt;Supported values for mod:&lt;BR /&gt;8u_C1R 16u_C1R 16s_C1R 32f_C1R&lt;BR /&gt;8u_C3R 16u_C3R 16s_C3R 32f_C3R&lt;BR /&gt;8u_C4R 16u_C4R 16s_C4R 32f_C4R&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;This function compares the corresponding pixels of ROI in two source images &lt;EM&gt;pSrc1&lt;/EM&gt;, &lt;EM&gt;pSrc2 &lt;/EM&gt;using the&lt;BR /&gt;&lt;EM&gt;ippCmpOp &lt;/EM&gt;compare operation, and writes the results to a one-channel Ipp8u image &lt;EM&gt;pDst&lt;/EM&gt;. If the result of the&lt;BR /&gt;compare is true, the corresponding output pixel is set to an IPP_MAX_8U value; otherwise, it is set to 0.&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;regards, Igor&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 17 May 2020 18:31:20 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184497#M27279</guid>
      <dc:creator>Igor_A_Intel</dc:creator>
      <dc:date>2020-05-17T18:31:20Z</dc:date>
    </item>
    <item>
      <title>Sorry, copy-pasted wrong</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184498#M27280</link>
      <description>&lt;P&gt;Sorry, copy-pasted wrong reference - you should use compare operation with const value:&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;IPPAPI (IppStatus, ippiCompareC_8u_C1R,(const Ipp8u* pSrc, int srcStep, Ipp8u value,&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Ipp8u* pDst, int dstStep,&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IppiSize roiSize,&amp;nbsp; IppCmpOp ippCmpOp))&lt;/P&gt;&lt;P style="margin-left:0cm; margin-right:0cm"&gt;regards, Igor&lt;/P&gt;</description>
      <pubDate>Sun, 17 May 2020 20:05:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184498#M27280</guid>
      <dc:creator>Igor_A_Intel</dc:creator>
      <dc:date>2020-05-17T20:05:45Z</dc:date>
    </item>
    <item>
      <title>Igor,</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184499#M27281</link>
      <description>&lt;P&gt;Igor,&lt;/P&gt;&lt;P&gt;Yes, thanks, that works in the example case given above.&lt;/P&gt;&lt;P&gt;But now for another example. Suppose I have two threshold values A and B where A &amp;lt;= B, Suppose I want to give all pixels where pixel =&amp;lt; A or pixel &amp;gt;= B a specific value. I call ippiThreshold_LTValGTVal. So far, so good. But what IPP function to call if I want to give all pixels where A &amp;lt; pixel &amp;lt; B a specific value ?&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Adriaan van Os&lt;/P&gt;</description>
      <pubDate>Sun, 17 May 2020 23:35:15 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184499#M27281</guid>
      <dc:creator>Adriaan_van_Os</dc:creator>
      <dc:date>2020-05-17T23:35:15Z</dc:date>
    </item>
    <item>
      <title>Quote:Igor Astakhov (Intel)</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184500#M27282</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Igor Astakhov (Intel) wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sorry, copy-pasted wrong reference - you should use compare operation with const value:&lt;/P&gt;&lt;P&gt;IPPAPI (IppStatus, ippiCompareC_8u_C1R,(const Ipp8u* pSrc, int srcStep, Ipp8u value,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Ipp8u* pDst, int dstStep,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IppiSize roiSize,&amp;nbsp; IppCmpOp ippCmpOp))&lt;/P&gt;&lt;P&gt;regards, Igor&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi Igor, thank you! This is what I was missing.&lt;/P&gt;</description>
      <pubDate>Mon, 18 May 2020 01:53:28 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184500#M27282</guid>
      <dc:creator>monarckmills</dc:creator>
      <dc:date>2020-05-18T01:53:28Z</dc:date>
    </item>
    <item>
      <title>Hi Adriaan van Os,</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184501#M27283</link>
      <description>&lt;P&gt;Hi Adriaan van Os,&lt;/P&gt;&lt;P&gt;regarding&amp;nbsp;Threshold_LTValGTVal - for your use case there should be developed one more API - something like Threshold_LTValG&lt;STRONG&gt;E&lt;/STRONG&gt;Val. We'll consider this new API for future versions.&lt;/P&gt;&lt;P&gt;regards, Igor&lt;/P&gt;</description>
      <pubDate>Mon, 18 May 2020 09:20:49 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Binarizing-an-image-via-thresholding/m-p/1184501#M27283</guid>
      <dc:creator>Igor_A_Intel</dc:creator>
      <dc:date>2020-05-18T09:20:49Z</dc:date>
    </item>
  </channel>
</rss>

