Closed moritzsalla closed 3 years ago
Ok, I got it to work on Thonny running Python 3.7.3 (/usr/bin/python3). However, running my script in terminal using pyenv 3.9 (/home/pi/.pyenv/shims/python) gives me this error:
ModuleNotFoundError: No module named 'sense_hat'
I'm installing 3.7.3 on pyenv to see if that will run it.
Update: after installing 3.7.3 using pyenv and sense-hat using pip, I am getting the original numpy error.
After finding this page: https://www.raspberrypi.org/forums/viewtopic.php?t=154230, I followed all steps, but I'm still stuck with either the "missing module" or "Importing the numpy C-extensions failed" error.
I tried:
sudo apt-get remove python-sense-hat python3-sense-hat
sudo pip install sense_hat
sudo pip3 install sense_hat
and:
sudo apt-get update
sudo apt-get install python-sense-hat python3-sense-hat -y
furthermore:
sudo apt-get remove python-sense-hat python3-sense-hat
sudo -H pip install sense_hat
sudo -H pip3 install sense_hat
also:
git clone https://github.com/RPi-Distro/python-sense-hat
cd python-sense-hat
sudo python setup.py install
sudo python3 setup.py install
Thonny on Python 3.7.3 (/usr/bin/python3) works fine, but I need it working with pyenv in bash.
Your original numpy error said libf77blas.so.3
is missing. It can be installed by running:
sudo apt install libatlas-base-dev
Is it possible to run sense-hat on 3.7.0? If not, what is the highest python version it can run on? I have tried 3.9.0, which also fails.