JRX
JRX
MModular
Created by Jack Clayton on 9/8/2023 in #questions
Native apple silicon macOS m1 and m2 support
ok, I managed to solve my problem. the issue comes from the fact that I had system python linked as python_lib in modular.cfg but in runtime I was using libraries from pyenv python. After setting the right python_lib mojo works well with pyenv python. I had to rebuild python with shared libraries though
110 replies
MModular
Created by Jack Clayton on 9/8/2023 in #questions
Native apple silicon macOS m1 and m2 support
I've tried to set up conda for myself and for python installed with conda mojo works. unfortunately for python from pyenv it doesnt 😢
110 replies
MModular
Created by Jack Clayton on 9/8/2023 in #questions
Native apple silicon macOS m1 and m2 support
I guess it makes sense, the trouble is that I already have pyenv installed on my system and it sounds like having both that and miniconda is asking for trouble
110 replies
MModular
Created by Jack Clayton on 9/8/2023 in #questions
Native apple silicon macOS m1 and m2 support
hi, I'm completely new to mojo, just installed it on a mac laptop and I'm trying to go through tutorials. Trying to go through the matrix multiplication example but when I try to import numpy I get this:
Traceback (most recent call last):
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/__init__.py", line 23, in <module>
from . import multiarray
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/multiarray.py", line 10, in <module>
from . import overrides
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/overrides.py", line 6, in <module>
from numpy.core._multiarray_umath import (
ModuleNotFoundError: No module named 'numpy.core._multiarray_umath'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "<string>", line 6, in <module>
File "<string>", line 25, in <module>
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/__init__.py", line 141, in <module>
from . import core
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/__init__.py", line 49, in <module>
raise ImportError(msg)
ImportError:

IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE!

Importing the numpy C-extensions failed. This error can happen for
many reasons, often due to issues with your setup or how NumPy was
installed.

We have compiled some common reasons and troubleshooting tips at:

https://numpy.org/devdocs/user/troubleshooting-importerror.html
Traceback (most recent call last):
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/__init__.py", line 23, in <module>
from . import multiarray
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/multiarray.py", line 10, in <module>
from . import overrides
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/overrides.py", line 6, in <module>
from numpy.core._multiarray_umath import (
ModuleNotFoundError: No module named 'numpy.core._multiarray_umath'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "<string>", line 6, in <module>
File "<string>", line 25, in <module>
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/__init__.py", line 141, in <module>
from . import core
File "/Users/jt/.pyenv/versions/ml2/lib/python3.10/site-packages/numpy/core/__init__.py", line 49, in <module>
raise ImportError(msg)
ImportError:

IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE!

Importing the numpy C-extensions failed. This error can happen for
many reasons, often due to issues with your setup or how NumPy was
installed.

We have compiled some common reasons and troubleshooting tips at:

https://numpy.org/devdocs/user/troubleshooting-importerror.html
I'm not fully sure what's the relationship between mojo and my system python, but it seems to be importing numpy from the virtualenv.
110 replies