By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,923 Members | 1,279 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,923 IT Pros & Developers. It's quick & easy.

Resize image NO PIL!!

P: n/a
I have created an image hosting site and when a user uploads an image,
I want a service to run on the server to create a few thumbnails while
the user does other things.

My stupid host (pair.com) doesn't have PIL installed and I'm too much
of a stupid newbie to figure out how to get it to work with them
(access denied while installing it, of course).

Also, they don't have any python interface setup for GD.

Anyway, I don't know what my options are. I'm thinking:

1) Find another host with mod_python, PIL, and other Python goodies
2) use PHP to create the thumbnails
3) Open the images into a buffer and try to do the calculations
myself

I'm thinking I might have to go with 1.

I want the script to run as a service so I don't know how well number
2 would work and I certainly don't want number 3 (on a time-line
here).

Any suggestions?

Thanks
cbmeeks
http://www.signaldev.com

May 29 '07 #1
Share this Question
Share on Google+
5 Replies


P: n/a
cbmeeks wrote:
I have created an image hosting site and when a user uploads an image,
I want a service to run on the server to create a few thumbnails while
the user does other things.

My stupid host (pair.com) doesn't have PIL installed and I'm too much
of a stupid newbie to figure out how to get it to work with them
(access denied while installing it, of course).

Also, they don't have any python interface setup for GD.

Anyway, I don't know what my options are. I'm thinking:

1) Find another host with mod_python, PIL, and other Python goodies
2) use PHP to create the thumbnails
3) Open the images into a buffer and try to do the calculations
myself
Have you checked to see if Imagemagick is available? You could use the
"convert" command via os.system or something along those lines...

Dave
May 29 '07 #2

P: n/a
Nope. They don't support that either. I emailed them (again) asking
for these features or at least see if they are in the works sometime
in the future and I keep getting their standard response which is
basically "you can do it yourself if you upgrade to our $249/mo
dedicated plan".

I'd go with EC2 for $70/mo first!

Thanks

cbmeeks
On May 28, 11:12 pm, Dave Benjamin <r...@lackingtalent.comwrote:
cbmeeks wrote:
I have created an image hosting site and when a user uploads an image,
I want a service to run on the server to create a few thumbnails while
the user does other things.
My stupid host (pair.com) doesn't have PIL installed and I'm too much
of a stupid newbie to figure out how to get it to work with them
(access denied while installing it, of course).
Also, they don't have any python interface setup for GD.
Anyway, I don't know what my options are. I'm thinking:
1) Find another host with mod_python, PIL, and other Python goodies
2) use PHP to create the thumbnails
3) Open the images into a buffer and try to do the calculations
myself

Have you checked to see if Imagemagick is available? You could use the
"convert" command via os.system or something along those lines...

Dave

May 29 '07 #3

P: n/a
I have created an image hosting site and when a user uploads an image,
I want a service to run on the server to create a few thumbnails while
the user does other things.

My stupid host (pair.com) doesn't have PIL installed and I'm too much
of a stupid newbie to figure out how to get it to work with them
(access denied while installing it, of course).

Also, they don't have any python interface setup for GD.

Anyway, I don't know what my options are. I'm thinking:

1) Find another host with mod_python, PIL, and other Python goodies
2) use PHP to create the thumbnails
3) Open the images into a buffer and try to do the calculations
myself

I'm thinking I might have to go with 1.

I want the script to run as a service so I don't know how well number
2 would work and I certainly don't want number 3 (on a time-line
here).
Why don't you put PIL where your modules are? You are surely allowed
to upload your own python modules somewhere where you can access them
(and import them) so you can put PIL into the same place and happily
import them just as any other module you wrote. You might need to find
out what the architecture of the machine is (as far as I remember PIL
has some C extensions) and compile PIL for that architecture.

HTH,
Daniel
May 29 '07 #4

P: n/a
In article <11*********************@g4g2000hsf.googlegroups.c om>,
cbmeeks <cb*****@gmail.comwrote:
>
My stupid host (pair.com) doesn't have PIL installed and I'm too much
of a stupid newbie to figure out how to get it to work with them
(access denied while installing it, of course).

Also, they don't have any python interface setup for GD.

Anyway, I don't know what my options are. I'm thinking:

1) Find another host with mod_python, PIL, and other Python goodies
webfaction.com -- I almost went with pair.com because they're reliable,
but I decided to choose a provider that supports Python.
--
Aahz (aa**@pythoncraft.com) <* http://www.pythoncraft.com/

"as long as we like the same operating system, things are cool." --piranha
May 30 '07 #5

P: n/a
Thanks for the suggestions. I checked out webfaction.com and they
looked nice. Might move from Pair over there.

I think what I am going to do is splurge and go with Amazon's EC2 ($72/
month). But it's root level access so I can do anything.

Last night I got a Python daemon running that monitored the MySQLdb
every 10 seconds (just for testing) and it would process "thumb_jobs"
by calling PIL.

Worked nicely.

I will have to experiment with tight batch control (as in, not
processing the same pic more than once) and threading.

cbmeeks
http://www.signaldev.com

On May 30, 5:50 pm, a...@pythoncraft.com (Aahz) wrote:
In article <1180406398.615904.22...@g4g2000hsf.googlegroups.c om>,

cbmeeks <cbme...@gmail.comwrote:
My stupid host (pair.com) doesn't have PIL installed and I'm too much
of a stupid newbie to figure out how to get it to work with them
(access denied while installing it, of course).
Also, they don't have any python interface setup for GD.
Anyway, I don't know what my options are. I'm thinking:
1) Find another host with mod_python, PIL, and other Python goodies

webfaction.com -- I almost went with pair.com because they're reliable,
but I decided to choose a provider that supports Python.
--
Aahz (a...@pythoncraft.com) <* http://www.pythoncraft.com/

"as long as we like the same operating system, things are cool." --piranha

Jun 1 '07 #6

This discussion thread is closed

Replies have been disabled for this discussion.