5

I'm on Ubuntu 14.04 and I had numba 0.15 working fine.

I ran:

pip install --user --upgrade numba

to upgrade to numba 0.16 but now when I try to import numba I get the following error:

~/.local/lib/python2.7/site-packages/numba/__init__.py in <module>()
      4 from __future__ import print_function, division, absolute_import
      5 import re
----> 6 from . import testing, decorators
      7 from ._version import get_versions
      8 from . import special, types, config

~/.local/lib/python2.7/site-packages/numba/decorators.py in <module>()
      5 import warnings
      6 from . import sigutils
----> 7 from .targets import registry
      8
      9 # -----------------------------------------------------------------------------

~/.local/lib/python2.7/site-packages/numba/targets/registry.py in <module>()
      1 from __future__ import print_function, division, absolute_import
      2
----> 3 from . import cpu
      4 from .descriptors import TargetDescriptor
      5 from .. import dispatcher, utils, typing

~/.local/lib/python2.7/site-packages/numba/targets/cpu.py in <module>()
      3 import sys
      4
----> 5 import llvmlite.llvmpy.core as lc
      6 import llvmlite.llvmpy.ee as le
      7 import llvmlite.binding as ll

ImportError: No module named llvmlite.llvmpy.core

This is very strange especially since I found this:

Q: Do I need to remove or update llvmpy?

A: No, Numba no longer uses llvmpy at all.

from here: https://groups.google.com/a/continuum.io/forum/#!topic/numba-users/cGKF7MORo7o

any ideas?

Community
  • 1
  • 1
evan54
  • 3,585
  • 5
  • 34
  • 61
  • You might be facing similar problems related to [this](http://stackoverflow.com/questions/28782512/getting-python-numba-working-on-ubuntu-14-10-or-fedora-21-with-python-2-7) installing numba on Ubuntu – imbr May 27 '15 at 00:09

2 Answers2

2

Answer can be found here:

Numba 0.16 has changed from using llvmpy to llvmlite as our wrapper around the LLVM library. (We also upgraded from LLVM 3.3 to LLVM 3.5 at the same time.)

The installation process is described here:

https://github.com/numba/numba/blob/master/README.md#custom-python-environments New link below...

(Also note that llvmlite (much like LLVM 3.5) requires a C++11 compiler to build, which can be hard to come by on older distributions.)

The line is:

https://github.com/numba/numba/blob/master/README.rst#custom-python-environments

evan54
  • 3,585
  • 5
  • 34
  • 61
2

my solution to fix it :

pip install numba==0.43.0
pip install llvmlite==0.32.1
Milad shiri
  • 812
  • 7
  • 5