<?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 DMIP and more How-to's in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901730#M12864</link>
    <description>&lt;P&gt;Thanks for your answer and sorry for my bad example code. Within my code I had an additional convert node changing the image type from IppC1 to IppC3 so what is inputted into the CCMSTransform node already is IppC3.&lt;/P&gt;
&lt;P&gt;The source image is 16byte aligned and has a step as a multiple of 64. Normally I don't use borders, that was just a test. So the source image IMO is correctly aligned (or not?).&lt;/P&gt;
&lt;P&gt;My code compiled perfectly and also execute. It just doesn't it with the DoInplace function. Even if I implement a Copy function and set the state to idmNormal and set inplace[0] = 1 the DoInplace function is not called&lt;/P&gt;</description>
    <pubDate>Fri, 12 Feb 2010 10:39:16 GMT</pubDate>
    <dc:creator>renegr</dc:creator>
    <dc:date>2010-02-12T10:39:16Z</dc:date>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901722#M12856</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;until now I was not really sure whether overhead of tiled image processing around IPP can increase IPP's performance even more. I did not have enough time to wrote something like DMIP to test it. So I was very happy to read the article in Dr. Dobbs journal.&lt;/P&gt;
&lt;P&gt;I'm now very enthusiastic to implement our algorithms with DMIP - unfortunately the examples mostly show the same usages.&lt;/P&gt;
&lt;P&gt;What I would like to request are examples on&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;how to implement a resize node&lt;/LI&gt;
&lt;LI&gt;how to implement a rotation node and - if the rotation angle changes, do I have to recompile the graph?&lt;/LI&gt;
&lt;LI&gt;how to give an input image size to the graph and query for the destination image size (width/height)&lt;/LI&gt;
&lt;LI&gt;what to do to make the compiler use the inplace algorithm (e.g. I have a pipeline Ipp16u/1ch-&amp;gt;&lt;B&gt;Node1&lt;/B&gt;-&amp;gt;Ipp16u/3ch-&amp;gt;&lt;B&gt;Node2&lt;/B&gt;-&amp;gt;Ipp16u/3ch-&amp;gt;&lt;B&gt;Node3&lt;/B&gt;-&amp;gt;Ipp16u/3ch&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;It is clear that &lt;B&gt;Node1&lt;/B&gt; can't be processed inline but I don't know why on my Node2/Node3 the inplace function is &lt;SPAN style="text-decoration: underline;"&gt;not&lt;/SPAN&gt; called. Of course Node2 and 3 are not Filter kernel nodes, just per pixel processing.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Thanks in advance&lt;/P&gt;
&lt;P&gt;Renegr&lt;/P&gt;</description>
      <pubDate>Thu, 04 Feb 2010 09:05:24 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901722#M12856</guid>
      <dc:creator>renegr</dc:creator>
      <dc:date>2010-02-04T09:05:24Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901723#M12857</link>
      <description>I forgot to mention that I've set the inplace member of Node for Node2 and Node3 to 1</description>
      <pubDate>Thu, 04 Feb 2010 10:16:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901723#M12857</guid>
      <dc:creator>renegr</dc:creator>
      <dc:date>2010-02-04T10:16:34Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901724#M12858</link>
      <description>&lt;P&gt;Strange warning when calling Image::CopyBorder &lt;I&gt;"Image right border 2 is less than required right border 4294232 in Image 00..."&lt;/I&gt;&lt;/P&gt;
&lt;P&gt;
&lt;PRE&gt;[cpp]IppiSize roi = { 64, 64 };
Image Srce( ipp16u, ippC1, roi, 2, 2, 2, 2);
Src = Copy( Image( buffer1, ipp16u, ippC1, roi, roi.width*2));
idmStatus stat = Src.CopyBorder( ippBorderMirror, 2, 2, 2, 2);
[/cpp]&lt;/PRE&gt;
&lt;/P&gt;</description>
      <pubDate>Fri, 05 Feb 2010 09:40:14 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901724#M12858</guid>
      <dc:creator>renegr</dc:creator>
      <dc:date>2010-02-05T09:40:14Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901725#M12859</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;thanks for your interest to DMIP. Could you please share a graph you try to implement with DMIP so we can better understand what happens?&lt;/P&gt;
&lt;P&gt;Note, DMIP does not support yet geometric operation, lke Resize. It is something we want to add in future.&lt;/P&gt;
&lt;P&gt;Regards,&lt;BR /&gt; Vladimir&lt;/P&gt;</description>
      <pubDate>Sun, 07 Feb 2010 17:21:05 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901725#M12859</guid>
      <dc:creator>Vladimir_Dudnik</dc:creator>
      <dc:date>2010-02-07T17:21:05Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901726#M12860</link>
      <description>&lt;P&gt;The code's very simple, just for debugging purposes&lt;/P&gt;
&lt;P&gt;
&lt;PRE&gt;[bash]class CCMSTransform : public Node_1_1
{
public:
  const char* ObjectName(void) { return "CMSTransform"; };

  CCMSTransform()
  {
    inplace[0] = 1;
    canOMP = 1;
  }

  bool SrcType()
  {
    return (paramCompile.srcChan[0] == ippC3) &amp;amp;&amp;amp; (paramCompile.srcType[0] == ipp8u || paramCompile.srcType[0] == ipp16u);
  }

  bool DstType()
  {
    paramCompile.dstChan[0] = paramCompile.srcChan[0];
    paramCompile.dstType[0] = paramCompile.srcType[0];
    return true;
  }

  idmStatus Do(int maxNumThread, int idThread)
  {
    IppiSize roi;
    int shift=0;
    idmStatus idmStat = SetOMPRoi( paramCompile.srcRoi.width, paramExecute.sliceHeight, roi, shift, maxNumThread, idThread);
    if (idmStat != idmOK)
      return idmFatalError;
    else if (roi.height == 0) // slices for last threads can be empty
      return idmOK;
    return idmOK;
  }

  idmStatus DoInplace(int maxNumThread, int idThread)
  {
    maxNumThread;
    idThread;
    return idmOK;
  }
};


Graph gr;
IppiSize roi = { 64, 64 };
Image* Src = new Image( ipp16u, ippC1, roi, 2, 2, 2, 2);
*Src = Copy( Image( buffer1, ipp16u, ippC1, roi, roi.width*2));
idmStatus stat = Src-&amp;gt;CopyBorder( ippBorderMirror, 2, 2, 2, 2);
Image* Dst = new Image( buffer2, ipp16u, ippC3, roi, roi.width*2*3);
SrcNode srcNode; srcNode.Init( Src); srcNode.SetStatus( idmTemporary);
DstNode dstNode; dstNode.Init( Dst); dstNode.SetStatus( idmTemporary);
CCMSTransform trans; trans.SetStatus( idmTemporary);

int iSrc = gr.Add( &amp;amp;srcNode);
int iCMS = gr.Add( &amp;amp;trans);
int iDst = gr.Add( &amp;amp;dstNode);

stat = gr.Link( iSrc, 0, iCMS, 0);
stat = gr.Link( iCMS, 0, iDst, 0);

stat = gr.Compile( 64);
stat = gr.Execute();
[/bash]&lt;/PRE&gt;
&lt;/P&gt;
&lt;P&gt;The breakpoint in DoInplace is never reached.&lt;/P&gt;
&lt;P&gt;One comment, the SrcNode implementation seems to copy the source image into a temporary pointer instead of directly using the src image pointer (SrcNode::paramCompile::pSrc[0] != SrcNode::paramCompile::pDst[0]).&lt;/P&gt;
&lt;BR /&gt;</description>
      <pubDate>Mon, 08 Feb 2010 10:18:36 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901726#M12860</guid>
      <dc:creator>renegr</dc:creator>
      <dc:date>2010-02-08T10:18:36Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901727#M12861</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;Strange warning when calling Image::CopyBorder "Image right border 2 is less than required right border 4294232 in Image 00..."&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You miss one default parameter in Image member-function call:&lt;/P&gt;
&lt;P&gt;idmStatus CopyBorder(IppiBorderType borderType=ippBorderRepl,&lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt; Scalar borderValue=0&lt;/STRONG&gt;&lt;/SPAN&gt;,&lt;/P&gt;
&lt;P&gt;int top=0, int bot=0, int lef=0, int rig=0);&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;In that case first value is treated as borderValue and 'rig' isn't equal to 2.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Igor&lt;/P&gt;</description>
      <pubDate>Fri, 12 Feb 2010 06:37:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901727#M12861</guid>
      <dc:creator>Igor_B_Intel1</dc:creator>
      <dc:date>2010-02-12T06:37:26Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901728#M12862</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;One comment, the SrcNode implementation seems to copy the source image into a temporary pointer instead of directly using the src image pointer&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Creation or not creation of the small temporary buffer after src node depends on:&lt;/P&gt;
&lt;P&gt;1. How alighned image data pointer and step.&lt;/P&gt;
&lt;P&gt;2. Does image contains prepared sufficien for the next operation border.&lt;/P&gt;
&lt;P&gt;All od these produce some restrictions on inplace operations after src nodes. In your case I see src image C1 and dst image C3 (so I guess your custom node is going to change color chanels number). Such operation cannot be inplace cause src buffer size is less than dst.&lt;/P&gt;
&lt;P&gt;By the way: your graph cannot be compiled. To get it workable set:&lt;/P&gt;
&lt;P&gt;paramCompile.dstType[0] = ippC3 in Dstype method instead of copiing from srcType whith is ippC1.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Igor&lt;/P&gt;</description>
      <pubDate>Fri, 12 Feb 2010 06:48:09 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901728#M12862</guid>
      <dc:creator>Igor_B_Intel1</dc:creator>
      <dc:date>2010-02-12T06:48:09Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901729#M12863</link>
      <description>&lt;P&gt;Forgorthree thing what I did to get your example workable:&lt;/P&gt;
&lt;P&gt;1.&lt;/P&gt;
&lt;PRE&gt;[bash]&lt;PRE name="code" class="bash"&gt;bool SrcType()   
  {   
    return (paramCompile.srcChan[0] == &lt;STRONG&gt;ippC1&lt;/STRONG&gt;) &amp;amp;&amp;amp; (paramCompile.srcType[0] == ipp8u || paramCompile.srcType[0] ==   
ipp16u);   
  } [/bash]&lt;/PRE&gt;
&lt;PRE&gt;[bash][/bash]&lt;/PRE&gt;
&lt;PRE&gt;[bash]2. Change status to idmNormal from idmTemporary.[/bash]&lt;/PRE&gt;
&lt;PRE&gt;[bash]3. Implement Copy method.[/bash]&lt;/PRE&gt;
&lt;PRE&gt;[bash][/bash]&lt;/PRE&gt;
&lt;PRE&gt;[bash][/bash]&lt;/PRE&gt;
&lt;/PRE&gt;</description>
      <pubDate>Fri, 12 Feb 2010 07:23:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901729#M12863</guid>
      <dc:creator>Igor_B_Intel1</dc:creator>
      <dc:date>2010-02-12T07:23:16Z</dc:date>
    </item>
    <item>
      <title>DMIP and more How-to's</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901730#M12864</link>
      <description>&lt;P&gt;Thanks for your answer and sorry for my bad example code. Within my code I had an additional convert node changing the image type from IppC1 to IppC3 so what is inputted into the CCMSTransform node already is IppC3.&lt;/P&gt;
&lt;P&gt;The source image is 16byte aligned and has a step as a multiple of 64. Normally I don't use borders, that was just a test. So the source image IMO is correctly aligned (or not?).&lt;/P&gt;
&lt;P&gt;My code compiled perfectly and also execute. It just doesn't it with the DoInplace function. Even if I implement a Copy function and set the state to idmNormal and set inplace[0] = 1 the DoInplace function is not called&lt;/P&gt;</description>
      <pubDate>Fri, 12 Feb 2010 10:39:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/DMIP-and-more-How-to-s/m-p/901730#M12864</guid>
      <dc:creator>renegr</dc:creator>
      <dc:date>2010-02-12T10:39:16Z</dc:date>
    </item>
  </channel>
</rss>

