Comments (2)
Fixed it.
FIrst of all, the default gcc on MacOS is from Xcode, which does not support openmp. Therefore, I installed a newer (4.8.5) version of gcc using:
conda install -c anaconda gcc
Then, I run the installation again:
python setup.py build_ext --inplace
It would have the following error:
running build_ext
building '_BLP' extension
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Users/chengnie/anaconda/include -arch x86_64 -I/Users/chengnie/anaconda/include/python3.5m -c _BLP.c -o build/temp.macosx-10.7-x86_64-3.5/_BLP.o -fopenmp
_BLP.c:453:31: fatal error: numpy/arrayobject.h: No such file or directory
#include "numpy/arrayobject.h"
^
compilation terminated.
error: command 'gcc' failed with exit status 1
Then I modified the setup.py file by adding the following line to Line 23:
include_dirs=[numpy.get_include()],
Now I can install the package and run it without any issue. It was way faster than the Matlab code. Thank you, @joonro !
from blp-python.
Hi -
Thank you very much for the kind words. I'm glad it was useful for you.
from blp-python.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from blp-python.