This is the program i have been working on:
import math
from PIL import Image,ImageDraw
w,h = 220,190
shape = [(40,40),(w - 100,h - 50),(200,100),(40,40)]
img = Image.new('RGB',(w,h))
img1 = ImageDraw.Draw(img)
img.line(shape,fill = 'blue',width =2)
img.show()
After running this file, it is showing this output->
File "c:\Users\i3\AppData\Roaming\jupyter\runtime\Python Programs\image.py", line 2, in <module>
from PIL import Image,ImageDraw
ModuleNotFoundError: No module named 'PIL'
I am running this file in vscode and the extensions that I am using are python, pylance, pip manager, python for vscode. All the extensions are updated and even the application is updated, too. In case for displaying the image I have installed another application and made it default in the system, but I don't know how I should made it default in vscode.