[C++-sig] ERROR:illegal hardware instruction on MAC OS when using import_array()

Qinfeng(Javen) Shi shiqinfeng at gmail.com
Fri Oct 27 08:24:53 CEST 2006


Dear All,

I wrapped a c++ code which can receive numpy.array data in python on linux.
For that I used import_array() in c extension. It works well on linux.
Then I bjam it in MAC OS without any error. But when I import it in python
on MAC OS, it reports a error. It seems that import_array() evoked the
error.

Does anyone know how to solve it? Thanks!

-------------------error------------------
>> test.py
zsh: illegal hardware instruction

-----------------c extension------------
namespace ar=boost::python::numeric;
BOOST_PYTHON_MODULE(coverTree)
{
    import_array();
    //ar::array::set_module_and_type("numpy", "ndarray");
}

-- 
Qinfeng(Javen) Shi

Research School of Information Sciences and Engineering
Australian National University
Locked Bag 8001
Canberra ACT 2601
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/cplusplus-sig/attachments/20061027/0db87438/attachment.htm>


More information about the Cplusplus-sig mailing list