Considering end users can provide very large images, would it make sense to implement an image resize, before or while copying the images to the final destination:
A more complex option is to create several image size, serve the appropriate one inline and link to a larger one if needed.