Quantcast
Channel: Active questions tagged gcc - Stack Overflow
Viewing all articles
Browse latest Browse all 22240

Compile error on python weave module (ubuntu)

$
0
0

I try to run the file Diehl&Cook_spiking_MNIST.py here:https://github.com/peter-u-diehl/stdp-mnist.

the output:

/home/showtsai/data/py2_env/lib/python2.7/site-packages/brian_no_units.py:4: UserWarning: Turning off units  warnings.warn("Turning off units")time needed to load training set: 11.9281079769time needed to load test set: 2.18607211113brian.stateupdater: WARNING  Using codegen CStateUpdaterbrian.stateupdater: WARNING  Using codegen CStateUpdatercreate neuron group Acreate recurrent connections(400, 3) ./weights/../random/AeAi.npy(160000, 3) ./weights/../random/AiAe.npycreate monitors for Acreate connections between X and A(313600, 3) ./weights/XeAe.npycreating /tmp/weave-showtsai-sAzJ3f/python27_intermediate/compiler_2e1ec47136bac12e4e2e13b18cd08c1ec++: error: unrecognized command line option ‘-ffast-math -march=native’brian.experimental.codegen.stateupdaters: WARNING  C compilation failed, falling back on Python.c++: error: unrecognized command line option ‘-ffast-math -march=native’brian.experimental.codegen.stateupdaters: WARNING  C compilation failed, falling back on Python.c++: error: unrecognized command line option ‘-ffast-math -march=native’Traceback (most recent call last):  File "spiking_MNIST.py", line 455, in <module>    b.run(single_example_time, report='text')  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/brian/network.py", line 938, in run    report=report, report_period=report_period)  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/brian/network.py", line 574, in run    self.update()  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/brian/network.py", line 518, in update    f()  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/brian/neurongroup.py", line 501, in update    spikes = self._threshold(self) # get spikes  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/brian/threshold.py", line 186, in __call__    extra_compile_args=self._extra_compile_args)  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave/inline_tools.py", line 370, in inline    **kw)  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave/inline_tools.py", line 500, in compile_function    verbose=verbose, **kw)  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave/ext_tools.py", line 373, in compile    verbose=verbose, **kw)  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave/build_tools.py", line 279, in build_extension    setup(name=module_name, ext_modules=[ext],verbose=verb)  File "/home/showtsai/data/py2_env/lib/python2.7/site-packages/numpy/distutils/core.py", line 171, in setup    return old_setup(**new_attr)  File "/usr/lib/python2.7/distutils/core.py", line 166, in setup    raise SystemExit, "error: "+ str(msg)weave.build_tools.CompileError: error: Command "c++ -pthread -DNDEBUG -g -fwrapv -O2 -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave -I/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave/scxx -I/home/showtsai/data/py2_env/lib/python2.7/site-packages/weave/blitz -I/home/showtsai/data/py2_env/lib/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -c /home/showtsai/.cache/weave/python27_compiled/sc_d99244cd82bb18764cebf838c5d78a220.cpp -o /tmp/weave-showtsai-sAzJ3f/python27_intermediate/compiler_2e1ec47136bac12e4e2e13b18cd08c1e/home/showtsai/.cache/weave/python27_compiled/sc_d99244cd82bb18764cebf838c5d78a220.o -MMD -MF /tmp/weave-showtsai-sAzJ3f/python27_intermediate/compiler_2e1ec47136bac12e4e2e13b18cd08c1e/home/showtsai/.cache/weave/python27_compiled/sc_d99244cd82bb18764cebf838c5d78a220.o.d -O3 -ffast-math -march=native" failed with exit status 1

The error occurs when compiling the weave module.

Is it because of the version of gcc?

environment:

ubuntu 16.04.6python 2.7.12weave 0.17.0gcc 5.4.0 20160609

Viewing all articles
Browse latest Browse all 22240

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>