Pages: [1]   Go Down

Author Topic: Saving speeds: tiff vs psd  (Read 4460 times)

Abdulrahman Aljabri

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 307
    • http://www.aljabri.com
Saving speeds: tiff vs psd
« on: April 01, 2016, 09:43:12 am »

I just can't understand why one 16bit file with multiple layers takes no more than few seconds to save in tiff format while takes a full minute to save in psd? The funny thing is that the tiff file usually ends up being larger by 100mb. What gives?   
Logged
MY SITE: AL

Torbjörn Tapani

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 319
Re: Saving speeds: tiff vs psd
« Reply #1 on: April 01, 2016, 10:45:53 am »

For work files uncompressed TIFF is the best option in my opinion. Save takes seconds. Files are huge but you can delete them when you are done if you wish. There is no way to disable compression on PSD as you have noticed. Writing a huge file is way faster than compressing it.
Logged

Abdulrahman Aljabri

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 307
    • http://www.aljabri.com
Re: Saving speeds: tiff vs psd
« Reply #2 on: April 01, 2016, 11:04:44 am »

For work files uncompressed TIFF is the best option in my opinion. Save takes seconds. Files are huge but you can delete them when you are done if you wish. There is no way to disable compression on PSD as you have noticed. Writing a huge file is way faster than compressing it.

So you are saying photoshop first saves and then compresses psd files all at the same time and that is why they take longer time but have smaller size?
Logged
MY SITE: AL

Torbjörn Tapani

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 319
Re: Saving speeds: tiff vs psd
« Reply #3 on: April 01, 2016, 11:42:16 am »

No, with PSD Photoshop first compress image data (this takes time) then writes it to disk. With TIFF the compression is optional.
Logged

digitaldog

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 20646
  • Andrew Rodney
    • http://www.digitaldog.net/
Re: Saving speeds: tiff vs psd
« Reply #4 on: April 01, 2016, 12:25:36 pm »

I just can't understand why one 16bit file with multiple layers takes no more than few seconds to save in tiff format while takes a full minute to save in psd? The funny thing is that the tiff file usually ends up being larger by 100mb. What gives?
http://www.digitaldog.net/files/TiffvsPSD.pdf
Logged
http://www.digitaldog.net/
Author "Color Management for Photographers".

Abdulrahman Aljabri

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 307
    • http://www.aljabri.com
Re: Saving speeds: tiff vs psd
« Reply #5 on: April 01, 2016, 01:08:43 pm »

http://www.digitaldog.net/files/TiffvsPSD.pdf

digitaldog to the rescue!!!

All makes sense now. Compress and save takes more time. The composite increases file size.

Thanks
Logged
MY SITE: AL

Redcrown

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 507
Re: Saving speeds: tiff vs psd
« Reply #6 on: April 01, 2016, 05:56:00 pm »

One factor that has existed for a long time: A 16 BIT file saved by Photoshop as tiff with LZW compression will actually be LARGER than the same file saved as tiff with no compression.

Not a Photoshop fault, just a strange aspect of LZW. Using LZW on 8 bit is OK.

Andrew, your "TIFF vs PSD" document does not mention that issue. In fact, you recommend using LZW/TIFF on 16 bit files, which may be bad advice. 
Logged

digitaldog

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 20646
  • Andrew Rodney
    • http://www.digitaldog.net/
Re: Saving speeds: tiff vs psd
« Reply #7 on: April 01, 2016, 06:17:51 pm »

One factor that has existed for a long time: A 16 BIT file saved by Photoshop as tiff with LZW compression will actually be LARGER than the same file saved as tiff with no compression.
Not on this end! The LZW is a bit larger than the ZIP (which may not be supported in older products; PS pops this warning) both BOTH are smaller than a TIFF with NO compression.


TIFF with LZW = 94.3MB
TIFF with ZIP = 83.6 MB
TIFF with no compression = 101.3MB
Logged
http://www.digitaldog.net/
Author "Color Management for Photographers".

Redcrown

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 507
Re: Saving speeds: tiff vs psd
« Reply #8 on: April 01, 2016, 11:44:18 pm »

Andrew, please double check. This issue with LZW compression of 16 bit images has been out there a long time.

Here Thomas Knoll mentions it: https://forums.adobe.com/message/1402822

Just a few of many others:

http://havecamerawilltravel.com/photographer/tiff-image-compression
http://www.luminescentphoto.com/blog/2012/11/30/a-quick-look-at-tiff-compression-options/
http://www.scantips.com/basics9t.html
http://www.amateurphotographer.co.uk/forums/threads/16-bit-tiff-compression.78046/

I've read that this is the reason Adobe removed the LZW option from Lightroom and ACR when exporting or saving a 16 bit tiffs. If you set 8 bit in either, the LZW option is offered. But if you set 16 bit, the LZW option disappears. However, it's still available when you save from Photoshop.
Logged

Redcrown

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 507
Re: Saving speeds: tiff vs psd
« Reply #9 on: April 02, 2016, 02:15:20 am »

Another strange thing about LZW compression I forgot about, had to re-test to make sure I remembered it correctly.

Convert an image from 16 bit to 8 bit and then back 16 bit. Then save that "fake" 16 bit image as tiff with LZW compression. For some reason I don't understand, that image will be much smaller. Up to half the size of the original 16 bit, tiff/LZW image. And now it will be smaller that a tiff no compression,

If you make a round trip from 16 to 8 back to 16 and save with no compression, then there is no significant difference in file size. The images will compare slightly different, as expected, but the file size is the same. Only LZW shows a size difference.

This was uncovered way back when a lot of filters and plugins would not work on 16 bit images. So people would convert to 8 bit, run the filter/plugin, and convert back to 16 bit for any further processing. A folly, for sure, but still something that was done by many.
Logged

digitaldog

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 20646
  • Andrew Rodney
    • http://www.digitaldog.net/
Re: Saving speeds: tiff vs psd
« Reply #10 on: April 02, 2016, 10:39:40 am »

Andrew, please double check.
Different 16-bit file, same results! YMMV of course; much has to do with the content of the TIFF (layers etc):

Logged
http://www.digitaldog.net/
Author "Color Management for Photographers".

Redcrown

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 507
Re: Saving speeds: tiff vs psd
« Reply #11 on: April 02, 2016, 01:40:08 pm »

All compression techniques depend on image content, of course. The more detail and noise the less the compression. Thus, "YMMV" is accurate.

But I can't find any image of mine that has so little detail that a 16 bit TIFF/LZW version is smaller than a version with no compression. Makes me curious about the two images whose sizes you show here. Are they typical, average photographs? Or are they test images of a blank sky, shot at ISO 50 and out of focus?

I selected an image from my Canon 5D3. Average scene detail, ISO 400 with some noise reduction applied in ACR. The following snippet from Bridge shows the file sizes of several 16 bit versions. The base "no compression" version is 126.71 MB. The LZW version is 148.95 MB. That's 22.24 MB or about 18% larger.

A version with a heavy dose of Topaz Denoise brings it down to 139.85 MB. Still larger than the no compression version. So I created 3 more versions by filling the image with increasing amounts of blank gray. As expected, the LZW compression becomes more efficient as more detail is removed. When I finally destroy enough of the image, the LZW version becomes smaller than the no compression version.

In a previous test, I processed 100 images from a landscape session. I made two 16 bit versions of each, one with no compression and one with LZW. All the LZW versions were bigger, by 10% to 20%. Some of those images contained 2/3 sky with little detail. Some were exposure brackets for HDR and contained significant blown out or clipped portions (zero detail).



https://kellyphoto.smugmug.com/Other/Temp-Upload/n-5RJTN/i-BtmzQRv/0/O/i-BtmzQRv.jpg


Here is a link to the image I used, if you or anyone else wants to test with it.
Would you be willing to share the images you used to show LZW compression is efficient?

https://www.dropbox.com/s/kqyqy6yp0pjeyj7/08%20Original.dng?dl=0
Logged

digitaldog

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 20646
  • Andrew Rodney
    • http://www.digitaldog.net/
Re: Saving speeds: tiff vs psd
« Reply #12 on: April 02, 2016, 01:44:40 pm »

All compression techniques depend on image content, of course. The more detail and noise the less the compression. Thus, "YMMV" is accurate.
But I can't find any image of mine that has so little detail that a 16 bit TIFF/LZW version is smaller than a version with no compression.
And I found two of vastly different sizes initially. So again: YMMV!
There's no free lunch here either! Saving a TIFF without compression, on this end is (with the two files I worked with), nearly instant. Compression option slows this down a second or three. ZIP compression as Photoshop indicates, may not be compatible with other 'TIFF readers' but none the less, I routinely pick that option because the document is the smallest, no issue with the modern TIFF readers I'm using and the time to save and open isn't an issue. For me.
Logged
http://www.digitaldog.net/
Author "Color Management for Photographers".

kirkt

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 604
Re: Saving speeds: tiff vs psd
« Reply #13 on: April 04, 2016, 11:47:34 am »

A lot of this can be controlled in the Preferences.  Disabling PSD and PSB compression is now available via the Preferences.  You used to have (the option) to disable PSB compression via a plug-in you could download from Adobe.

kirk

Logged

Redcrown

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 507
Re: Saving speeds: tiff vs psd
« Reply #14 on: April 04, 2016, 12:53:49 pm »

Thanks Kirkt, didn't know that option had been added. However, it seems to suffer from an old "bug" involving the "Maximize Compatibility" feature.

"Maximize Compatibility" controls whether Photoshop places a additional, but hidden flattened version of the image in the file so non-Adobe programs can read and display it. That's the Adobe definition of compatibility.

That extra version makes the file bigger, of course. So turning Compatibility off should avoid that extra copy and result in a smaller file. However, setting Compatibility to "Never" only works on layered files. If a file is truly flat, the setting is ignored and an extra copy of the image is included in the file regardless.

You can see this by saving a flat file with the compatibility setting on and off. The file sizes are the same. Then go back and add a do-nothing layer and save two versions. Now the file sizes will be different and the compatibility=never version will be smaller. It has the extra do-nothing layer, but it does not have the extra compatibility copy.

Now save two versions of a flat file, one with compression enabled, one with it disabled. The file sizes are the same. Add a blank layer and save 2 more versions. With the blank layer added, the compressed version will be smaller than any other version. Proof that the "Disable Compression" option is ignored on flat files, only works on layered files.
Logged

digitaldog

  • Sr. Member
  • ****
  • Offline Offline
  • Posts: 20646
  • Andrew Rodney
    • http://www.digitaldog.net/
Re: Saving speeds: tiff vs psd
« Reply #15 on: April 04, 2016, 01:25:31 pm »

"Maximize Compatibility" controls whether Photoshop places a additional, but hidden flattened version of the image in the file so non-Adobe programs can read and display it.
OR an Adobe program called Lightroom:)
http://blogs.adobe.com/jkost/2010/06/maximize_compatibility.html
Further, there are non Adobe app's that can read layers without this set (Affinity Photo for example).
Best to leave it on.
Logged
http://www.digitaldog.net/
Author "Color Management for Photographers".
Pages: [1]   Go Up