Is there a way to find the ImageDimensions of an image file without Import'ing each one? The reason being that I have a directory with millions of JPEGs and it's really slow to Import each one separately.


The documentation says how to do this.

Import["image.jpg", "ImageSize"] // AbsoluteTiming

{0.052691, {2048, 1366}}

  • $\begingroup$ Nice, I totally missed that! $\endgroup$ – M.R. Jul 10 at 20:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.