- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi All,
I wrote a non-threaded program which loads12 video clips (CIF resolution)from hardisk and apply some object recognition using openCV. From my observation, the CPU usage is around 60% (task distribution for both cores are not equal). So i thought in order to utilize my multi-core system, i should modify the program to be a threaded one. Well, I created a thread to handle each video clips. Each of the thread will have their own set of CvCapture pointer, retrieveit's own video frames, process anddisplay them. After executing the program, the CPU usage turned out to be 100%. My feeling tells me that this must be something wrong as the CPU usage should be lesser than 60% (theoretically) Anyonefacing this before?
*i'm using WinXP with Intel C2D T7400. Program developed using C++
*i'm using win32 threads (eg: _beginthreadex)
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sawguan,
I suggest you consider using a profiler program such a vTune or CodeAnalyst. This will quickly locate where the code is spending it's time.
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Or am I missing something? (for example, the CPU utilization increased, but the total run time didn't decrease?)
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page