[Tutor] image processing
jeremiah
jeremiah.jester at panasonic.aero
Tue Sep 23 23:38:29 CEST 2008
I'm trying to do simple image manipulation but am getting an error. any
ideas what i am doing wrong here?
Thanks
JJ
#!/usr/bin/python
import ImageFilter,Image
name="test.jpg"
file=open("./"+name,"w")
pic=Image.open(file)
pic.rotate(45)
pic.save("new_" + name)
pic.show()
the error:
Traceback (most recent call last):
File "image_filter.py", line 7, in <module>
pic=Image.open(file)
File "/usr/lib/python2.5/site-packages/PIL/Image.py", line 1893, in
open
prefix = fp.read(16)
IOError: [Errno 9] Bad file descriptor
Disclaimer: The information contained in this transmission, including any
attachments, may contain confidential information of Panasonic Avionics
Corporation. This transmission is intended only for the use of the
addressee(s) listed above. Unauthorized review, dissemination or other use
of the information contained in this transmission is strictly prohibited.
If you have received this transmission in error or have reason to believe
you are not authorized to receive it, please notify the sender by return
email and promptly delete the transmission.
More information about the Tutor
mailing list