Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Library for Display missing #145

Open
torstenandrecht opened this issue Aug 3, 2024 · 3 comments
Open

Library for Display missing #145

torstenandrecht opened this issue Aug 3, 2024 · 3 comments

Comments

@torstenandrecht
Copy link

when I execute python all-in-one.py I get the following error message:

Traceback (most recent call last):
File "/home/andrecht/enviroplus-python/examples/all-in-one.py", line 20, in
from PIL import Image, ImageDraw, ImageFont
ModuleNotFoundError: No module named 'PIL'

Solution:
pip install Pillow

Source:
https://stackoverflow.com/questions/8863917/importerror-no-module-named-pil

@slokhorst
Copy link

Same issue here. I also had to apt install libopenblas0 on Raspberry Pi OS Lite Bookwork 32-bit to get the display to work.

@arijitsadhu
Copy link

pip install Pillow failed to build the wheel, giving the error:
"RequiredDependencyException:
The headers or library files could not be found for jpeg,
a required dependency when compiling Pillow from source."

So following the link installed directly from apt:
sudo apt install python3-pil

@gilbertfrancois
Copy link

I saw the same issue. The easiest way to fix it is to install both numpy and pillow system wide with apt. Then the required C libraries are included and the 2 python packages are also available in the virtual environment.

sudo apt install python3-numpy python3-pil

However, in my case, the display still stays blank, without returning an error. I'll make a new issue for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants