Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RAW Images stored in Google Photos cannot be downloaded #9

Closed
Snuggle opened this issue Aug 18, 2021 · 3 comments
Closed

RAW Images stored in Google Photos cannot be downloaded #9

Snuggle opened this issue Aug 18, 2021 · 3 comments

Comments

@Snuggle
Copy link
Contributor

Snuggle commented Aug 18, 2021

It seems that raw photos from dedicated cameras that are stored in Google Photos won't be able to be downloaded as Python's pillow library doesn't seem to support them. As this is an upstream issue it might be difficult to find a fix, but it seems that most RAW formats aren't supported by Pillow and instead rawpy is usually used.

I have thousands of .arw images stored in my Google Photos which is a raw image format used by almost all Sony cameras.

Upstream Issue: python-pillow/Pillow#3124

Finished Downloading Shared Albums.

Reading Entire Library From Server...

Downloading Library:  16%|████████████████████████████████████████████▉  | 3539/22777 [00:04<00:09, 1956.83 media items/s]
ERROR: media item could not be downloaded because: unknown file extension: .arw
ERROR: media item could not be downloaded because: unknown file extension: .arw
ERROR: media item could not be downloaded because: unknown file extension: .arw
ERROR: media item could not be downloaded because: unknown file extension: .arw
ERROR: media item could not be downloaded because: unknown file extension: .arw
@NicholasDawson
Copy link
Owner

The reason I use Pillow is to embed the description of a media item in Google Photos into the EXIF data of the downloaded image manually since this information is not stored in the image file, but in a database on their servers.

I don't think that RAW files would need this type of functionality and from my simple research, it seems EXIF data is not supported on RAW files.

I think I will add an exception that will just skip the Description field if the file is not supported by Pillow.

What do you think?

@Snuggle
Copy link
Contributor Author

Snuggle commented Aug 28, 2021

@NicholasDawson, hmm. I think .ARW files do still contain EXIF data. After popping one of my .ARWs from my Sony camera into this website http://exif.regex.info/exif.cgi I end up seeing the EXIF data below for example.

I would think that information such as lens type, ISO, exposure time, f/stop would be quite important to someone who took photos on a dedicated camera, so I'd keep all of this EXIF data if possible, though I can't see the use case for a 'Description' field.

Is skipping description but keeping all the other EXIF data an option?

image

@NicholasDawson
Copy link
Owner

NicholasDawson commented Aug 29, 2021

Yes by default the normal data included in the image is kept, the description field is appended to the existing exif data on the image.

So skipping the description on unsupported files would work, and I think it is the best solution here.

NicholasDawson pushed a commit that referenced this issue Nov 23, 2021
NicholasDawson pushed a commit that referenced this issue Jul 1, 2022
Former-commit-id: c9df4da
NicholasDawson pushed a commit that referenced this issue Jul 16, 2022
Former-commit-id: c9df4da
Former-commit-id: 4df0422
NicholasDawson pushed a commit that referenced this issue Jul 16, 2022
Former-commit-id: c9df4da
Former-commit-id: f73eb85e806d45a65991523cae30fc060f261d89
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants