Author Topic: JPG conversion - File size efficiency question  (Read 8409 times)

Offline Citizenzoltan

  • Newcomer
  • *
  • Posts: 15
    • View Profile
JPG conversion - File size efficiency question
« on: February 22, 2013, 03:00:16 PM »
Hi, I started using Dx0 Optics pro 8 recently for my Raw editing and do the conversion via DxO instead of using PM5 for this part of my workflow. When I convert my NEF to JPG, I noticed that with the usual 90% JPG Quality setting in DxO, the file size was significantly smaller vs. what I normally get from PM5, which made me think about it and I ran a small test.

I took a tiff file I edited in Photoshop CS6 and used 6 different applications (including PM5, latest build) to convert to JPG, all set to 90% JPG Quality. I used a Mac with Mountain Lion OSX. Pls. find below a screenshot on file sizes each program ended up with. On average it was 8.9Mb vs. PM5 @ 24.1 Mb. That's a huge difference. I looked at the details at 800% and (subjectively), I couldn't find any significant difference across the 6 renditions. The only difference was the huge file size PM5 created. I did not enable sharpening, color space changing or resizing, it was just pure 'as is' conversion from Tiff to JPG @ 90% quality (see also attached). I then tested at what % of JPG quality would PM5 create a 9Mb JPG file (like the other apps created at 90%). I had to lower the quality setting to 37%!

Do you have any explanation to this phenomenon? Frankly this concerns me when it comes to disk space efficiency. I would encourage others to do their tests too. Maybe I'm missing a trick? Thanks for looking into this in advance.



[attachment deleted by admin]

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: JPG conversion - File size efficiency question
« Reply #1 on: February 22, 2013, 03:52:57 PM »
Hi, I started using Dx0 Optics pro 8 recently for my Raw editing and do the conversion via DxO instead of using PM5 for this part of my workflow. When I convert my NEF to JPG, I noticed that with the usual 90% JPG Quality setting in DxO, the file size was significantly smaller vs. what I normally get from PM5, which made me think about it and I ran a small test.

I took a tiff file I edited in Photoshop CS6 and used 6 different applications (including PM5, latest build) to convert to JPG, all set to 90% JPG Quality. I used a Mac with Mountain Lion OSX. Pls. find below a screenshot on file sizes each program ended up with. On average it was 8.9Mb vs. PM5 @ 24.1 Mb. That's a huge difference. I looked at the details at 800% and (subjectively), I couldn't find any significant difference across the 6 renditions. The only difference was the huge file size PM5 created. I did not enable sharpening, color space changing or resizing, it was just pure 'as is' conversion from Tiff to JPG @ 90% quality (see also attached). I then tested at what % of JPG quality would PM5 create a 9Mb JPG file (like the other apps created at 90%). I had to lower the quality setting to 37%!

Do you have any explanation to this phenomenon? Frankly this concerns me when it comes to disk space efficiency. I would encourage others to do their tests too. Maybe I'm missing a trick? Thanks for looking into this in advance.

Sure.  All of the other apps are likely using Chrominance Subsampling without letting you control it directly.  Turn it on in PM and you'll see your file sizes drop by 30%, no matter what quality setting.  Quality 100 with no Chroma Subsampling is effectively lossless compression.  Even quality 90 is nearly lossless.

There should be no concern that PM is wasting your disk space.  Choose the quality based on the disk space you're willing to use for a photo in PM and is should hit the target pretty much spot-on.  If you don't want to play around with quality settings, just enable the subsampling, put the quality slider all the way to the left, and set the "Limit file size to:" checkbox and enter a size you like.  PM will do the rest.

HTH,

-Kirk

Offline Citizenzoltan

  • Newcomer
  • *
  • Posts: 15
    • View Profile
Re: JPG conversion - File size efficiency question
« Reply #2 on: February 22, 2013, 04:08:33 PM »
I just tested it and with the "Subsample chroma" ticked , Qual set to zero and file size pre-determined it indeed seems the best way to control the file size at highest possible quality. I did a comparison to the other apps' renderings and it looked the same way. Thanks again for your quick response and good advice!

Offline Luiz Muzzi

  • Hero Member
  • *****
  • Posts: 704
    • View Profile
    • Luiz Muzzi Photography
Re: JPG conversion - File size efficiency question
« Reply #3 on: February 23, 2013, 12:02:03 PM »
Kirk,
I generally use DPP to convert from canon raw to jpeg 100%.
Do you think it would be better to use DPP just to convert to a TIFF file and then use PM to "save as" a jpeg 100%?
Would there be any difference in the quality of the jpeg files?
Thanks in advance for any help or opinion.

-Luiz Muzzi

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: JPG conversion - File size efficiency question
« Reply #4 on: February 23, 2013, 12:32:45 PM »
Luiz,

I think that you might as well just go from RAW directly to JPEG in DPP.   Why clutter up your drives with TIFF files you don't need?

-Kirk

Offline Luiz Muzzi

  • Hero Member
  • *****
  • Posts: 704
    • View Profile
    • Luiz Muzzi Photography
Re: JPG conversion - File size efficiency question
« Reply #5 on: February 23, 2013, 12:55:36 PM »
Thanks for your quick reply.

-Luiz Muzzi

Offline photojoca

  • Newcomer
  • *
  • Posts: 4
    • View Profile
Re: JPG conversion - File size efficiency question
« Reply #6 on: April 10, 2013, 02:08:06 PM »
Interesting discussion.

I always leave the jpeg quality setting at max and make whatever changes I need to the image itself based on the intended final use of the image.  So for newsprint I do x and y to the resolution and for web maybe something else.

By leaving the quality at max I figure the software will give me the best quality given the size/resolution restrictions I placed on it.  Is that a correct assumption?

It seems to give me manageable file sizes with no surprises later.  I don't like the idea of reducing quality on a slider because I'm not sure what is getting reduced... is it resolution, image size, colour data...?

Offline Kirk Baker

  • Senior Software Engineer
  • Camera Bits Staff
  • Superhero Member
  • *****
  • Posts: 25020
    • View Profile
    • Camera Bits, Inc.
Re: JPG conversion - File size efficiency question
« Reply #7 on: April 10, 2013, 03:48:16 PM »
Interesting discussion.

I always leave the jpeg quality setting at max and make whatever changes I need to the image itself based on the intended final use of the image.  So for newsprint I do x and y to the resolution and for web maybe something else.

By leaving the quality at max I figure the software will give me the best quality given the size/resolution restrictions I placed on it.  Is that a correct assumption?

Yes.  You'll get the highest JPEG quality with Subsample Chroma turned off and the slider set all the way to the right.  You will also get the largest file size for a given width and height of an image that way.

It seems to give me manageable file sizes with no surprises later.  I don't like the idea of reducing quality on a slider because I'm not sure what is getting reduced... is it resolution, image size, colour data...?

When you set the JPEG quality lower it does more quantization and if you turn on Chroma Subsampling it throws out color information.  At really low JPEG quality levels you'll see very obvious artifacts (fringing around details, recognizable blocks, etc.).  For web use you can easily get away with JPEG quality of 75-80 and get really nice compression as well, and most people won't notice the difference between it and one generated at the highest (near lossless) quality.

It may be worthwhile for you to do some experimentation.  It could save you a lot of bandwidth and still allow you to put larger images on your website that still look really good.

-Kirk