0
I can't import image in tkinter anyone can help me??.....after running this code this kind of error occur "no module name PIL"
From tkinter import * Import tkinter as tk From PIL import Image to, Image root = tk.Tk() img = ImageTk.PhotoImage(Image.open(path)) panel = tk.Label(root, image = img) panel.pack(side = "bottom", fill = "both", expand ="yes") root.mainloop()
14 odpowiedzi
+ 1
pip install pillow
+ 1
Really? Then try to get some info at pillow s website
+ 1
Try:
pip install pillow --no-cache-dir
+ 1
What error out gave?
+ 1
Try degrading you pip to 6.2.0
0
My python version is 3.8 so......it's not downloading
0
No it's not working
0
Again no working couldn't find a version that satisfied the requirement 6.2.0 is the error
0
Not***
0
pip install pillow --no-cache-dir Collecting pillow Downloading https://files.pythonhosted.org/packages/5b/bb/cdc8086db1f15d0664dd22a62c69613cdc00f1dd430b5b19df1bea83f2a3/Pillow-6.2.1.tar.gz (37.7MB) |████████████████████████████████| 37.7MB 3.3MB/s Installing collected packages: pillow Running setup.py install for pillow ... error ERROR: Command errored out with exit status 1: command: 'c:\python38\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\roy\\AppData\\Local\\Temp\\pip-install-lmfy2vgl\\pillow\\setup.py'"'"'; __file__='"'"'C:\\Users\\roy\\AppData\\Local\\Temp\\pip-install-lmfy2vgl\\pillow\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\roy\AppData\Local\Temp\pip-record-sj5st7e8\install-record.txt' --single-version-externally-managed --compile cwd: C:\Users\roy\AppData\Local\Temp\pip-install-lmfy2vgl\pillow\ Complet
0
Error
0
Do you use intellij? It can help a lot....
Anyway try Python 3.7. Either 3.8 is incompatible with current releases of pillow, or there is some problem with ya system.....
0
I have no idea about intellij????
0
It's an ide to code in Python.
Just write the input statement and let intellij itself download the required libraries