Any news on pypy3 + numpy?
On 22/09/18 16:12, Neal Becker wrote:
https://mail.python.org/pipermail//pypy-dev/2016-September/014644.html
_______________________________________________ pypy-dev mailing list pypy-dev@python.org https://mail.python.org/mailman/listinfo/pypy-dev That was two years ago. Now you can just do pip install numpy, which will download the latest upstream numpy and build it, using any openblas/atlas you have available. Or you can try
pip install --extra-index https://antocuni.github.io/pypy-wheels/ubuntu numpy on ubuntu, or on windows download from gohlke's site https://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy which seems to have 1.14.5-pp360-win32.whl but not 1.15.0 Matti
On 22/09/18 16:12, Neal Becker wrote:
https://mail.python.org/pipermail//pypy-dev/2016-September/014644.html
_______________________________________________ pypy-dev mailing list pypy-dev@python.org https://mail.python.org/mailman/listinfo/pypy-dev That was two years ago. Now you can just do pip install numpy, which will download the latest upstream numpy and build it, using any openblas/atlas you have available. Or you can try
pip install --extra-index https://antocuni.github.io/pypy-wheels/ubuntu numpy
on ubuntu, or on windows download from gohlke's site https://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy which seems to have 1.14.5-pp360-win32.whl but not 1.15.0
Matti Reason I asked is, Here's what I get:
import numpy Traceback (most recent call last): File "/home/nbecker/.local/lib/python3.5/site-
Matti Picus wrote: pypy3 Python 3.5.3 (c573badf1521, Apr 25 2018, 17:27:42) [PyPy 6.0.0 with GCC 8.0.1 20180424 (Red Hat 8.0.1-0.22)] on linux Type "help", "copyright", "credits" or "license" for more information. packages/numpy/core/__init__.py", line 16, in <module> from . import multiarray ImportError: cannot import name 'multiarray' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/nbecker/.local/lib/python3.5/site-packages/numpy/__init__.py", line 142, in <module> from . import add_newdocs File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/add_newdocs.py", line 13, in <module> from numpy.lib import add_newdoc File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/lib/__init__.py", line 8, in <module> from .type_check import * File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/lib/type_check.py", line 11, in <module> import numpy.core.numeric as _nx File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/core/__init__.py", line 26, in <module> raise ImportError(msg) ImportError: Importing the multiarray numpy extension module failed. Most likely you are trying to import a failed build of numpy. If you're working with a numpy git repo, try `git clean -xdf` (removes all files not under version control). Otherwise reinstall numpy. Original error was: cannot import name 'multiarray'
Matti Picus wrote:
On 22/09/18 16:12, Neal Becker wrote:
https://mail.python.org/pipermail//pypy-dev/2016-September/014644.html
_______________________________________________ pypy-dev mailing list pypy-dev@python.org https://mail.python.org/mailman/listinfo/pypy-dev That was two years ago. Now you can just do pip install numpy, which will download the latest upstream numpy and build it, using any openblas/atlas you have available. Or you can try
pip install --extra-index https://antocuni.github.io/pypy-wheels/ubuntu numpy
on ubuntu, or on windows download from gohlke's site https://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy which seems to have 1.14.5-pp360-win32.whl but not 1.15.0
Matti Reason I asked is, Here's what I get: pypy3 Python 3.5.3 (c573badf1521, Apr 25 2018, 17:27:42) [PyPy 6.0.0 with GCC 8.0.1 20180424 (Red Hat 8.0.1-0.22)] on linux Type "help", "copyright", "credits" or "license" for more information.
import numpy Traceback (most recent call last): File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/core/__init__.py", line 16, in <module> from . import multiarray ImportError: cannot import name 'multiarray'
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/nbecker/.local/lib/python3.5/site-packages/numpy/__init__.py", line 142, in <module> from . import add_newdocs File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/add_newdocs.py", line 13, in <module> from numpy.lib import add_newdoc File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/lib/__init__.py", line 8, in <module> from .type_check import * File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/lib/type_check.py", line 11, in <module> import numpy.core.numeric as _nx File "/home/nbecker/.local/lib/python3.5/site- packages/numpy/core/__init__.py", line 26, in <module> raise ImportError(msg) ImportError: Importing the multiarray numpy extension module failed. Most likely you are trying to import a failed build of numpy. If you're working with a numpy git repo, try `git clean -xdf` (removes all files not under version control). Otherwise reinstall numpy.
Original error was: cannot import name 'multiarray'
_______________________________________________ pypy-dev mailing list pypy-dev@python.org https://mail.python.org/mailman/listinfo/pypy-dev My guess, from the path /home/nbecker/.local/lib/python3.5/site-packages/numpy is that you are
On 23/09/18 17:32, Neal Becker wrote: trying to use a numpy from cpython on pypy. Are you sure you did what I suggested, or did you simply set your PYTHONPATH to the cpython site-packages? Matti
Thanks! I've gotten much further now than before. Now I've hit this when importing my c++ module which uses pybind11: pypy3 test3.py Traceback (most recent call last): File "test3.py", line 9, in <module> from constellation import QAMconstellation, bipolar ImportError: QAMconstellation64_base: dynamic attributes are currently not supported in conjunction with PyPy!
Remember there is the really bad issue where pypy3 uses the wrong folder for packages - the cpython one! This is fixed in hg, but not in a release yet(i think). On Monday, September 24, 2018, Neal Becker <ndbecker2@gmail.com> wrote:
Thanks! I've gotten much further now than before. Now I've hit this when importing my c++ module which uses pybind11:
pypy3 test3.py Traceback (most recent call last): File "test3.py", line 9, in <module> from constellation import QAMconstellation, bipolar ImportError: QAMconstellation64_base: dynamic attributes are currently not supported in conjunction with PyPy!
_______________________________________________ pypy-dev mailing list pypy-dev@python.org https://mail.python.org/mailman/listinfo/pypy-dev
René Dudfield wrote:
Remember there is the really bad issue where pypy3 uses the wrong folder for packages - the cpython one!
You mean that pypy3 is using ~/.local/lib/python3.5/site-packages? That would be a big problem, except that fedora28 is currently using python3.6, while pypy3 is python3.5, so there is no conflict at the moment.
This is fixed in hg, but not in a release yet(i think).
... Fixed in pypy hg? I guess pybind11 would also have to be fixed.
participants (3)
-
Matti Picus -
Neal Becker -
René Dudfield