0

I would like to call C++ functions in python which return uBLAS vector/matrices. There is a package to do this called PyUblas, but am having trouble getting this to work in Ubuntu.

Can anyone walk me through the steps to get this sample to work?

Also, I am somewhat confused with the installation instructions. I did not follow the instructions to install boost and numpy since I have already installed them from the Ubuntu repositories.

al0
  • 308
  • 1
  • 2
  • 13

2 Answers2

1

I guess that wasn't so hard. Here's what I did to run the small sample on the website and in test/samply.py.

After downloading and unpacking PyUblas, and having the necessary libraries installed, cd into PyUblas-VERSION

./configure.py --help
./configure.py --some-options
sudo python setup.py install
cd test/
g++ -I/usr/include/python2.7 -fPIC -g -fpic -shared sample_ext.cpp -lboost_python -lpython2.7 -o sample_ext.so
python sample.py 
al0
  • 308
  • 1
  • 2
  • 13
0

It's going to be difficult to help without knowing what exactly your issues are. My first guess if the tests aren't working would be that your config file is not pointing to the right directories/files.

Dwight
  • 360
  • 1
  • 3
  • 15