Perceptually compare two JPEGs from the same source image with different color profiles
05:34 29 Jul 2026

I have two JPEG files that were generated from the exact same source image (a whole slide image/WSI), but they were saved using two different ICC color profiles before JPEG compression (I am assuming one uses standard sRGB, while the other uses an unknown/vendor-specific profile). Using low level tools I see there is no color profile in those JPEG file (no APP2 marker).

I want to write a Python script to programmatically compare the two images and determine whether they are visually/perceptually identical under proper color management, versus measuring raw, uncalibrated RGB pixel differences.

What I have tried so far is:

$ magick compare -metric RMSE sRGB.jpg unknown_icc.jpg null:
2354.61 (0.035929)

Which seems to indicate a very low variation (but again how do I interpret this result?).

I have also tried:

Which gives:

compare_color_maps

I am having a hard time understanding this 'difference' image. How should I interpret the color difference ? What is it supposed to tell me ?

python image-processing colors color-profile