title: Numpy import fails when embedding python in c
body: <p>I'm trying to embed a python program to c++ code. the problem I have is to use python script that contain an numpy import.
  for example, if i use the following c++ code</p>
  
  <pre><code>#include &lt;Python.h&gt;
  int main(int argc,char *argv[])
  {
  double 
      x=2.,
      xp=4.,
      dt=6.,
      y=8,
      yp=1,
      dz=6;
  Py_Initialize();
  
  PyObject* myModuleString = PyString_FromString((char*)"log");
  PyObject* myModule = PyImport_Import(myModuleString);
  
  
  PyObject* myFunction = PyObject_GetAttrString(myModule,(char*)"derive");
  PyObject* args = PyTuple_Pack(  6,
  PyFloat_FromDouble(x),
  PyFloat_FromDouble(xp),
  PyFloat_FromDouble(dt),
  PyFloat_FromDouble(y),
  PyFloat_FromDouble(yp),
  PyFloat_FromDouble(dz));
  
  PyObject* myResult = PyObject_CallObject(myFunction, args);
  
  PyObject *ts= PyTuple_GetItem(myResult,0);
  PyObject *zs= PyTuple_GetItem(myResult,1);
  double result_t = PyFloat_AsDouble(ts);
  double result_z = PyFloat_AsDouble(zs);
  printf("%3f \n %f \n", result_t,result_z);
  
  Py_Finalize();
  
  system("pause");
  
  return 0;
  }
  </code></pre>
  
  <p>with the following log.py script which contain the function <code>derive</code></p>
  
  <pre><code>def derive(x,xp,dt,y,yp,dz):
  return log(abs(x - xp)/dt),exp((y-yp)/dz)
  </code></pre>
  
  <p>it runs correctly, but if the log.py contain <code>from numpy import array</code>, it fails</p>
  
  <pre><code>from numpy import array
  def derive(x,xp,dt,y,yp,dz):
  return log(abs(x - xp)/dt),exp((y-yp)/dz)
  </code></pre>