RuntimeError: Could not load any ArrayFire libraries.

Open
#239 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
macos, python

Research direction

Reproduce the import in the reported conda environment using the macOS commands, then inspect arrayfire/init.py and arrayfire/library.py, especially the _clibrary() path that raises the error. Compare the command-line and Python environments; done means identifying a reproducible cause and documenting or testing a fix for loading the ArrayFire libraries.

Written by the indexing model from the issue text.

Description

Hi, I am using MACOS, I have 1. Download and install binaries 2. pip install arrayfire 3. export DYLD_LIBRARY_PATH=/opt/arrayfire/lib:$DYLD_LIBRARY_PATH

It can be used with command line
Screenshot 2020-10-15 at 08 29 41

But when I use the same conda environment and python VeM.py which is a script containing import arrayfire, it shows

Traceback (most recent call last):
  File "/Users/zetao/Documents/code/edu/python_code/first_try/VEM_deblur.py", line 3, in <module>
    import arrayfire as af 
  File "/Users/zetao/opt/anaconda3/lib/python3.7/site-packages/arrayfire/__init__.py", line 56, in <module>
    from .library    import *
  File "/Users/zetao/opt/anaconda3/lib/python3.7/site-packages/arrayfire/library.py", line 643, in <module>
    backend = _clibrary()
  File "/Users/zetao/opt/anaconda3/lib/python3.7/site-packages/arrayfire/library.py", line 619, in __init__
    raise RuntimeError("Could not load any ArrayFire libraries.\n" + more_info_str)
RuntimeError: Could not load any ArrayFire libraries.

Can anyone kindly explain why?

Dominant language
Python
Stars
422
Forks
63
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from arrayfire/arrayfire-python

All issues in arrayfire/arrayfire-python

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.