Code: Select all
sudo apt-get install python-pil
How can I fix this?Reading package lists... Done
Building dependecy tree
Reading state information... Done
E: Unable to locate package python-pil
I replaced it. But now I am getting the following error:gkreidl wrote:replace
from tkinter import *
Then your code should work.
Traceback (most recent call last):
File "/home/pi/tkinterpy1.py", line 2, in <module>
root = Tk()
NameError: name 'Tk' is not defined
Wow. Thank you for informing me! Do you know of any alternatives that I could use to display an image?joan wrote:The PIL Image show function used to use a program called xv to display the image on *nix systems.
xv has been effectively deprecated for some time.
That might be why you get no display.
pi@raspberrypi ~/Pillow-2.3.0 $ sudo python3 setup.py
usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
or: setup.py --help [cmd1 cmd2 ...]
or: setup.py --help-commands
or: setup.py cmd --help