Skip to content
This repository has been archived by the owner on May 24, 2018. It is now read-only.

Compiles with ps-lite, but undefined symbol on importing the Python wrapper #202

Open
viktor-ferenczi opened this issue Jul 18, 2015 · 2 comments

Comments

@viktor-ferenczi
Copy link
Contributor

OS: Ubuntu 14.04 amd64
Python: 2.7.10 (Anaconda)

Complete build log and config.mk contents:
https://gist.github.com/viktor-ferenczi/acfc91d20bf0af8efde9

Error on importing wrapper:

$ python
Python 2.7.10 |Anaconda 2.3.0 (64-bit)| (default, May 28 2015, 17:02:03) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
Anaconda is brought to you by Continuum Analytics.
Please check out: http://continuum.io/thanks and https://binstar.org
>>> import cxxnet
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/fviktor/dev/cxxnet/wrapper/cxxnet.py", line 20, in <module>
    cxnlib = ctypes.cdll.LoadLibrary(CXXNET_PATH)
  File "/home/fviktor/anaconda/lib/python2.7/ctypes/__init__.py", line 443, in LoadLibrary
    return self._dlltype(name)
  File "/home/fviktor/anaconda/lib/python2.7/ctypes/__init__.py", line 365, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: /home/fviktor/dev/cxxnet/wrapper/libcxxnetwrapper.so: undefined symbol: _ZTIN2ps9ParameterE
>>> 

Same error if I try to import into the system's default Python instance:

$ /usr/bin/python2.7
Python 2.7.6 (default, Jun 22 2015, 17:58:13) 
[GCC 4.8.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import cxxnet
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/fviktor/dev/cxxnet/wrapper/cxxnet.py", line 20, in <module>
    cxnlib = ctypes.cdll.LoadLibrary(CXXNET_PATH)
  File "/usr/lib/python2.7/ctypes/__init__.py", line 443, in LoadLibrary
    return self._dlltype(name)
  File "/usr/lib/python2.7/ctypes/__init__.py", line 365, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: /home/fviktor/dev/cxxnet/wrapper/libcxxnetwrapper.so: undefined symbol: _ZTIN2ps9ParameterE
>>> 

So it wasn't compiled properly for either of them.

Is it a problem with build configuration or I'm overlooking something here?

I can compile cxxnet without ps-lite (for single GPU support) and the Python wrapper works fine with Anaconda's Python instance.

@viktor-ferenczi viktor-ferenczi changed the title Compiles with ps-lite, but missing symbol on importing library Compiles with ps-lite, but undefined symbol on importing library: _ZTIN2ps9ParameterE Jul 18, 2015
@viktor-ferenczi viktor-ferenczi changed the title Compiles with ps-lite, but undefined symbol on importing library: _ZTIN2ps9ParameterE Compiles with ps-lite, but undefined symbol on importing library Jul 18, 2015
@viktor-ferenczi viktor-ferenczi changed the title Compiles with ps-lite, but undefined symbol on importing library Compiles with ps-lite, but undefined symbol on importing the Python wrapper Jul 18, 2015
@weihaoxie
Copy link

I also face the same problem with you.But I don't know why.Does anyone know how to deal with it.

@viktor-ferenczi
Copy link
Contributor Author

No, I did not manage to fix this. I failed to compile with multi-GPU support. What I could do is using the single GPU build and split my task (folds) between the two GPUs. Drawback is that you have to solve the scheduling on your own, so this is less convenient.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants