<?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 ippiScale_32f8u - rounding incorrect? in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1377360#M27983</link>
    <description>&lt;P&gt;I noticed when attempting to match the behavior of ippiScale_32f8u that I was getting unexpected results from the intel function.&lt;/P&gt;
&lt;P&gt;Specifically, scaling the following float rounds down to 0 instead of up to 1.&lt;/P&gt;
&lt;P&gt;float a = 0.00196078443;&lt;/P&gt;
&lt;P&gt;Since the float range is 0.0 to 1.0 and the 8u range is inherently 0 to 255, a * 255 =&amp;nbsp;0.50000002965. And thus the function should round up I believe, but the scaling function outputs 0 for this. &amp;nbsp;Am I misunderstanding how this should work?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 15 Apr 2022 07:02:38 GMT</pubDate>
    <dc:creator>rkuo</dc:creator>
    <dc:date>2022-04-15T07:02:38Z</dc:date>
    <item>
      <title>ippiScale_32f8u - rounding incorrect?</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1377360#M27983</link>
      <description>&lt;P&gt;I noticed when attempting to match the behavior of ippiScale_32f8u that I was getting unexpected results from the intel function.&lt;/P&gt;
&lt;P&gt;Specifically, scaling the following float rounds down to 0 instead of up to 1.&lt;/P&gt;
&lt;P&gt;float a = 0.00196078443;&lt;/P&gt;
&lt;P&gt;Since the float range is 0.0 to 1.0 and the 8u range is inherently 0 to 255, a * 255 =&amp;nbsp;0.50000002965. And thus the function should round up I believe, but the scaling function outputs 0 for this. &amp;nbsp;Am I misunderstanding how this should work?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Apr 2022 07:02:38 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1377360#M27983</guid>
      <dc:creator>rkuo</dc:creator>
      <dc:date>2022-04-15T07:02:38Z</dc:date>
    </item>
    <item>
      <title>Re: ippiScale_32f8u - rounding incorrect?</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1379271#M27995</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Thank you for contacting us!&lt;/P&gt;
&lt;P&gt;Could you help provide out the information: IPP version, CPU platform, OS, etc? As well as a simple reproducer.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have a nice day.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Ruqiu&lt;/P&gt;</description>
      <pubDate>Sat, 23 Apr 2022 10:47:42 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1379271#M27995</guid>
      <dc:creator>Ruqiu_C_Intel</dc:creator>
      <dc:date>2022-04-23T10:47:42Z</dc:date>
    </item>
    <item>
      <title>Re: ippiScale_32f8u - rounding incorrect?</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1379325#M27997</link>
      <description>&lt;P&gt;I literally just gave you the code to try.&lt;/P&gt;
&lt;P&gt;I think I figured it out ... this is due to the use of "bankers rounding" aka "round to nearest, ties to even".&amp;nbsp; This makes sense, but should be documented in the function behavior.&lt;/P&gt;</description>
      <pubDate>Sun, 24 Apr 2022 07:03:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ippiScale-32f8u-rounding-incorrect/m-p/1379325#M27997</guid>
      <dc:creator>rkuo</dc:creator>
      <dc:date>2022-04-24T07:03:45Z</dc:date>
    </item>
  </channel>
</rss>

