[Tutor] image processing
Jerry Hill
malaclypse2 at gmail.com
Tue Sep 23 23:52:56 CEST 2008
On Tue, Sep 23, 2008 at 5:38 PM, jeremiah
<jeremiah.jester at panasonic.aero> wrote:
> I'm trying to do simple image manipulation but am getting an error. any
> ideas what i am doing wrong here?
>
> file=open("./"+name,"w")
> pic=Image.open(file)
You're opening the file for "w"riting, then asking PIL to read it.
That's not going to work. In fact, there's no reason for you to open
the file yourself. Just pass the filename, like this:
pic=Image.open(name)
--
Jerry
More information about the Tutor
mailing list