Can I identify Google Photos recompressed JPEGs from metadata after Google Takeout?

Asked 8/28/2018

5 views

2 answers

0

I downloaded my library with Google Takeout and found that some JPEGs may have been recompressed by Google Photos when stored in "High quality," while others were kept at original quality. Since both versions are still .jpg files, is there a reliable way to tell which images were altered? Are there metadata tags or other clues that can help distinguish recompressed Google Photos files from originals?

Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0

Photography Stack Exchange contributor

7y ago

2 Answers

2

Google does add some tags to images that it recompresses, including images stored as "High Quality", which may be downsampled to 16MP or less. Images stored at "Original" quality appear to be kept unaltered. At this time, the following tags appear to be added or altered:

  • XMPToolkit = XMP Core 5.5.0
  • ImageUniqueID

The following command may list images that have been altered by Google:

exiftool -if '($XMPToolkit =~ /^XMP\ Core\ [\.\d]+$/) \
   and ($ImageUniqueID)' -s2 -q -FilePath -ext jpg .

Some caveates

  • The command may include images not altered by Google. Other programs may use the same, or similar, XMPToolkit strings that Google does, especially if they happen to use the same image-writing library that Google does. For instance, GIMP uses "XMP Core 4.4.0-Exiv2". Photoshop uses "Adobe XMP Core 5.3-c011 66.145661, 2012/02/06-14:56:27" (as noted by StarGeek).

  • The command may miss images altered by Google. This depends on how Google has changed their image processing over the years. For instance, it's not known (to me) when Google started using the ImageUniqueID tag. So some images may not have it set.

  • There are other tags that may be altered by Google, but they are not reliable to check because many JPEG images have them, including those straight from my camera (FujiFilm X-T20):

    • JPEGDigest
    • YCbCrSubSampling

Other options

You may also guess whether images have been altered by comparing file sizes or using tools like jpegjudge.

Originally by user75526. Source · Licensed CC BY-SA 4.0

user75526

7y ago

0

AI Answer

Generated from our catalog & community — verify before relying on it.

Sometimes, but not perfectly. Based on community testing, Google Photos may add or alter metadata on recompressed JPEGs, including tags such as XMPToolkit and ImageUniqueID. Originals stored at "Original" quality appear to remain unaltered.

A suggested exiftool check is:

exiftool -if '($XMPToolkit =~ /^XMP\ Core\ [\.\d]+$/) and ($ImageUniqueID)' -s2 -q -FilePath -ext jpg .

This can help surface likely Google-altered files, but it is not definitive. Other software can write similar XMPToolkit values, so you may get false positives.

A second practical clue is file size: if you know the normal JPEG size your camera produces, noticeably smaller files may indicate extra compression. Google Photos "High quality" images may also be downsampled to 16MP or less.

So the best answer is: use metadata as a hint, not proof, and combine it with file size and image dimensions when comparing suspected recompressed files to originals.

UniqueBot

AI

7y ago

Your Answer