Pandas M1 error mach-o, but wrong architecture

Viewed 283

I am trying to get pandas running on my Mac M1 but it doesn't work. I have installed it by different ways : pip install, conda install...

I have a Conda environment and python 3.7. I can work directly in PyCharm, all packages work and my version of pandas is 1.3.4. However, when I open a Jupyter Notebook, I have error with the library pandas. I have created a Kernel in my Jupyter Notebook.

When I run this : import pandas as pd, I have this error :

ImportError: dlopen(/opt/homebrew/lib/python3.9/site-packages/pandas/_libs/interval.cpython-39-darwin.so, 2): no suitable image found.  Did find:
    /opt/homebrew/lib/python3.9/site-packages/pandas/_libs/interval.cpython-39-darwin.so: mach-o, but wrong architecture
    /opt/homebrew/lib/python3.9/site-packages/pandas/_libs/interval.cpython-39-darwin.so: mach-o, but wrong architecture 

For this command file $(which python) , I have this result :

/Users/mathilderoblot/opt/anaconda3/envs/project/envs/rre-rent/bin/python: Mach-O 64-bit executable x86_64

And arch : arm64

I have already tried to reinstalling pandas after removing it.

0 Answers
Related