File size nearly doubles for Sony A1 files

Started by bschafer, May 16, 2021, 07:12:19 AM

Previous topic - Next topic

bschafer

It appears that when geolocation data to the new sony a1 raw(arw) files causes the file size to nearly double
The raw file is too large (~65 meg) to attach but i can provide via other methods if needed

Windows 10, exif tool version 12.25 via the Geosetter program

Thanks Bob

StarGeek

To clarify, you're saying that exiftool (via geosetter) is nearly doubling the size of the file?

Can you provide a before and after image through Dropbox, Google drive, or something similar?  If you want it to be private, you can PM the links directly to Phil through this forum from his profile page (hit "Send PM" on the left).  Make it clear that it's in reference to this thread.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

bschafer

Thank you for reviewing this.
Some more investigation/information from my end
The Original (files with issues) files were in the Sony A1
Compressed Raw Format.
Using the Geosetter program if I write the geolocation information
into xmp sidecar files the image file size remains unchanged

Today I shot in Sony Uncompressed Raw format and used Geosetter
to write the geolocation info into the image file and the size remains
unchanged.

Here is a link to files that exhibited the issue
https://drive.google.com/drive/folders/1GPXGdthkkadfvqrmobrIOZboNc8INcPw?usp=sharing

Thanks and please let me know if you need more info
Bob

StarGeek

Quote from: bschafer on May 16, 2021, 01:30:45 PM
Using the Geosetter program if I write the geolocation information
into xmp sidecar files the image file size remains unchanged

Yes, because nothing is being written to the original file

QuoteToday I shot in Sony Uncompressed Raw format and used Geosetter
to write the geolocation info into the image file and the size remains
unchanged.

Are you able to replicate the problem or does it seem to be a one time issue?

I compared the files as best I could with exiftool and couldn't find anything that stands out.  The JpgFromRawStart and ThumbnailOffset, both which indicate where the preview images start, showed that the increase in size occurs before the preview images.

I don't have any experience with digging into the raw file data, so hopefully Phil can take a look at some point.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

bschafer

Thanks for taking a look!  I can consistently replicate the issue.
The same issue occured with the Geotag photos desktop app
https://www.geotagphotos.net/

A futher clarification is that the issue occurs when captured in sony's
lossless compressed raw files. Another program I use, Irfanview,
has problems displaying the lossless compressed raw files as well



Phil Harvey

What produced the "original" file that you uploaded?  I can't check my samples now, but I suspect this wasn't straight from the camera.  I've never seen a file like this -- the SubIFD contains both stripped and tiled data, but the strips and the tiles both reference the same data, which is why the size doubles when rewritten by ExifTool.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

bschafer

Thanks for taking a look Phil
It is straight form the new Sony A1 camera.  For this model sony introduced a new
"LOSSLESS COMPRESSED RAW"   format.  this issue only seems to occur with that
format. When I switched to uncompressed raw the issue disappeared.   The uncompressed
raw files are about 100 mb in size and the lossless compressed raw files are about 60 mb in file size.

I added an additional file, a1_00062.arw to the google drive folder.  This is one of the native(uncompressed)
raw files from the camera

Phil Harvey

Then this is a bug in the Sony firmware. :(

If I added a patch to deal with this, the solution would be for ExifTool to report an error in the file and refuse to write it.  Patching this to rewrite the file without duplicating the raw data would be a real mess. :(

At the very least, I should issue a warning so the user is informed about this problem.  I'll see about adding this in the next release.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

bschafer

Thanks Phil

I noticed Sony had a firmware update, which I just applied and the issue still occurs. So the problem
exists with both Firmware version 1.00 and 1.01.

Is there specific information I should try to pass along to Sony, (I'm not sure how I would do this but
I can try) 

Thanks again for taking a look at the issue and for your amazing software

Bob

Phil Harvey

Hi Bob,

Don't even bother trying.  Sony doesn't pay attention to reports like this.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).


walti

Sorry for resurrecting an old topic... I see that this bug is still present and I think that no one can solve the problem.  :'(
Anyway, the bug does not involves DNG files generated from A1 ARW, both compressed or uncompressed.
And converting to DNG the double-sized ARW restores (almost) the original size of the file.

I've switched my workflow to a new level:
- generate XMP with the -o option of exiftool
- modifiy XMP with "-tagsfromfile @ -srcfile %d%f.xmp" options of exiftool
- importing files in Lightroom and converting to DNG

Works fine.

Thanks all.