- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello there,
I'm new with IPP and I'm looking for a simple way to calculate the center of gravity of an image.
At the moment I'm using:
IppStatus ippiMoments64s_(const Ipp8u* pSrc, int srcStep, IppiSize roiSize, IppiMomentState_64s* pState);
and
IppStatus ippiGetSpatialMoment_64s(const IppiMomentState_64s* pState, int mOrd, int nOrd, int nChannel, IppiPoint roiOffset, Ipp64s* pValue, int scaleFactor);
as decriped in the ipp manual 11-47 p.774 to get the center of gravity in x and y.
This costs me 144us on a Core2Duo 2,15Mhz and 850us on an Atom 1,6Ghz.
Is there a faster way to calculate the center of gravity? My feeling is that a simple for-loop is already faster than calculation all the moments.
Thanks
Trucki
I'm new with IPP and I'm looking for a simple way to calculate the center of gravity of an image.
At the moment I'm using:
IppStatus ippiMoments64s_
and
IppStatus ippiGetSpatialMoment_64s(const IppiMomentState_64s* pState, int mOrd, int nOrd, int nChannel, IppiPoint roiOffset, Ipp64s* pValue, int scaleFactor);
as decriped in the ipp manual 11-47 p.774 to get the center of gravity in x and y.
This costs me 144us on a Core2Duo 2,15Mhz and 850us on an Atom 1,6Ghz.
Is there a faster way to calculate the center of gravity? My feeling is that a simple for-loop is already faster than calculation all the moments.
Thanks
Trucki
Link Copied
5 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Trucki,
It seems yes, to calculte the center of gravity, the simple for-loop may faster than calculation all the moments.
oruse some ofipp function combinations, for exmaple,
M(0,0)=ippisum();
M(1,0)=ippiDotProd (pSrc, X Coordinate matrix)
M(0,1)=ippiDotProd (PSrc, y Coordinate matrix)
Would you like submit this as a feature request, for example ippiGetCenterGravity()?
Regards,
Ying
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It looks like you might be interested to try DMIP (Defered Mode Image Processing) layer we built on top of IPP which help in creation processing pipeline consisting from several IPP calls.
Vladimir
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
thanks fr your answers.
I'm going to test ippisum and ippidotprod.
I don't think, that I will need a COG-Funktion in the next ipp lib, because I have to find a solution now.
What is DMIP? Do you have a link?
Trucki
thanks fr your answers.
I'm going to test ippisum and ippidotprod.
I don't think, that I will need a COG-Funktion in the next ipp lib, because I have to find a solution now.
What is DMIP? Do you have a link?
Trucki
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Trucki,
DMIP is a parallel processing layer we built on top of IPP. It is available as IPP sample (separate download).
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here are a few resource that may help: http://software.intel.com/en-us/forums/showthread.php?t=67621
Thanks,
Chao

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page