Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix runtime error on osx #1449

Merged
merged 1 commit into from
Jul 19, 2018
Merged

Fix runtime error on osx #1449

merged 1 commit into from
Jul 19, 2018

Conversation

nishi-t
Copy link
Contributor

@nishi-t nishi-t commented Jul 18, 2018

I get following error when run a tvm sample code on osx after build master and install it by python setup.py install. I'm not sure, but fixed my error by changing "package_data": {'tvm': LIB_LIST} to "data_files": [('tvm', LIB_LIST)].
@abergeron @tqchen Could you review this?

Error message

$ python tvm_sample.py
Traceback (most recent call last):
  File "/Users/tatsuya/misc/nnvm/samples/tvm_concat.py", line 2, in <module>
    import topi
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/topi-0.4.0-py3.6.egg/topi/__init__.py", line 12, in <module>
    from tvm._ffi.libinfo import __version__
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/__init__.py", line 5, in <module>
    from . import tensor
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/tensor.py", line 4, in <module>
    from ._ffi.node import NodeBase, NodeGeneric, register_node, convert_to_node
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/_ffi/node.py", line 8, in <module>
    from .node_generic import NodeGeneric, convert_to_node, const
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/_ffi/node_generic.py", line 7, in <module>
    from .base import string_types
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/_ffi/base.py", line 43, in <module>
    _LIB, _LIB_NAME = _load_lib()
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/_ffi/base.py", line 34, in _load_lib
    lib_path = libinfo.find_lib_path()
  File "/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/_ffi/libinfo.py", line 93, in find_lib_path
    raise RuntimeError(message)
RuntimeError: Cannot find the files.
List of candidates:
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/libtvm.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/build/libtvm.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/build/Release/libtvm.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/lib/libtvm.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/libtvm.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/tvm-0.4.0-py3.6-macosx-10.13-x86_64.egg/tvm/libtvm_runtime.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/build/libtvm_runtime.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/build/Release/libtvm_runtime.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/site-packages/lib/libtvm_runtime.dylib
/Users/tatsuya/venv/nnvm-dev/lib/python3.6/libtvm_runtime.dylib

@tqchen tqchen merged commit be08b81 into apache:master Jul 19, 2018
@tqchen
Copy link
Member

tqchen commented Jul 19, 2018

I am going to go ahead and merge this in for now

@tqchen
Copy link
Member

tqchen commented Jul 19, 2018

After looking at the docs, seems that both data_files and package_data should be fine, maybe data_files is more generalized

tqchen pushed a commit to tqchen/tvm that referenced this pull request Aug 4, 2018
sergei-mironov pushed a commit to sergei-mironov/tvm that referenced this pull request Aug 8, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants