Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Peter_L_4
Beginner
112 Views

Numpy linked against MKL not utilizing all cores

Hey Guys,

I'm using MKL to speed up numpy and doing some benchmark of matrix multiplication. Mostly I followed the instruction in https://software.intel.com/en-us/articles/numpyscipy-with-intel-mkl. It works great on my dev Mac machine but when I build it the same way on a ec2 c3.2xlarge instance, only one core is used with the benchmark script. I'm pretty sure it has 8 physical core... 

Has anyone encounter this before or the processor on ec2 doesn't support MKL?

Thanks,

Peter

0 Kudos
1 Reply
112 Views

Hi Peter,

   I see https://aws.amazon.com/ec2/instance-types/ ec2 c3.2xlarge the details. ( I do not have any experience in using aws).

  Since your build/installation of numpy/scipy with MKL was successful and your benchmark is also running properly with MKL functions, from my understanding, and you mentioned it is using only 1 core,  it may be something related to the threading control is not done for MKL.

You can set the MKL threading environment variables to the number of cores and see whether that helps. Please refer below document. 

    https://software.intel.com/en-us/node/528546

--Vipin

 

 

Reply