Commit b5521404 authored by Justin Carpentier's avatar Justin Carpentier

core: revert proposition of loadNumpyArray

Not working so well
parent a9371f21
......@@ -574,11 +574,13 @@ namespace eigenpy
}
};
#endif
#define numpy_import_array() {if (_import_array() < 0) {PyErr_Print(); PyErr_SetString(PyExc_ImportError, "numpy.core.multiarray failed to import"); } }
template<typename MatType>
void enableEigenPySpecific()
{
loadNumpyArray();
numpy_import_array();
if(check_registration<MatType>()) return;
bp::to_python_converter<MatType,EigenToPy<MatType> >();
......
......@@ -27,9 +27,6 @@
namespace eigenpy
{
/* Load numpy through Python */
void loadNumpyArray();
/* Enable Eigen-Numpy serialization for a set of standard MatrixBase instance. */
void EIGENPY_EXPORT enableEigenPy();
......
......@@ -10,19 +10,6 @@
namespace eigenpy
{
void loadNumpyArray()
{
static bool loaded = false;
if(loaded) return;
if(_import_array() < 0)
{
PyErr_Print(); PyErr_SetString(PyExc_ImportError, "numpy.core.multiarray failed to import");
}
else
loaded = true;
}
/* Enable Eigen-Numpy serialization for a set of standard MatrixBase instances. */
void enableEigenPy()
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment