Ask Your Question
0

Disable multi core in parallel_for_ function

asked 2016-11-03 04:32:04 -0600

Humam Helfawi gravatar image

updated 2016-11-03 04:36:10 -0600

I want to deny OpenCV from run on multicore. I have built a version without (OpenCL, IPP, CUDA, TBB). However, any OpenCV function that contains parallel_for_ is working on parallel. How can I stop those function from multi cores and stick to only one core?

Note: I am using OpenCV 3.1 on MS Windows OS and Intel processor.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
2

answered 2016-11-03 05:07:33 -0600

LBerger gravatar image

You can fixed number of thread using SetNumThread to 0. some behaviour differs from framework...

edit flag offensive delete link more

Comments

That works many thanks..

Humam Helfawi gravatar imageHumam Helfawi ( 2016-11-03 05:14:37 -0600 )edit

That being said, did you check if pthread support was disabled? you should verify that any parallelization framework is disabled in your build if you want no parallelization at all.

StevenPuttemans gravatar imageStevenPuttemans ( 2016-11-04 05:34:40 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2016-11-03 04:32:04 -0600

Seen: 709 times

Last updated: Nov 03 '16