Saving Image with PIL

PIL isn’t an attribute of newImg1 but newImg1 is an instance of PIL.Image so it has a save method, thus the following should work.

newImg1.save("img1.png","PNG")

Note that just calling a file .png doesn’t make it one so you need to specify the file format as a second parameter.

try:

type(newImg1)
dir(newImg1)

and

help(newImg1.save)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)