Does anyone have any recommendations for web based scripts or services which deal with managing large image repositories? I work with an eCommerce web site that has over 150,000 products and need a better solution to maintain product images. Right now, product images are just dumped into two directories on the web server - one for full size images and one for thumbnails - and the product pages just reference the image files directly. Opening the directory to list what's there takes forever due to the large volume of images there.

Ideally, I'm looking for something that is web based, self-hosted, will allow for easy upload of large amounts of images, ability to generate cached, dynamic, on-the-fly resized images, and optimize the file system storage of these images.

Ideally, I'd like to be able to reference any image within the system using a special formatted URL like:

domain.com/image/100x75/filename.jpg
OR
domain.com/image.php?file=filename.jpg&w=100&h=75

Something that will allow me to build links with custom widths, heights, and filenames, and the system will just pull a cached version or generate the appropriate image on the fly if the cached version doesn't exist. Also, and this is a big key requirement, the image filename we provide must remain. If a file I upload to the system is named abc123.jpg, then the system cannot rename the image from abc123.jpg. The image file names tie back to product part numbers so that is the link to dynamically create these links to the images from product pages.

Does anyone have any recommendations as to either opensource or commercial scripts/software that can meet these needs?

I've spent time searching for something like this, and all I come up with are Digital Asset Management Software (DAM), which tend to get into image meta data, tagging, searching functions, etc. All of those types of features are really overkill for what I need. Since I'm dealing with large amounts of images, I have no desire to be able to search images based on tags or categorizations. I just want to dump the images into the system in one swoop and programatically create links to the images from product pages.