Jump to content

  •  

CNers have asked about a donation box for Cloudy Nights over the years, so here you go. Donation is not required by any means, so please enjoy your stay.

Photo

DeepSkyStacker preview looks different to the saved file

This topic has been archived. This means that you cannot reply to this topic.
10 replies to this topic

#1 sharkmelley

sharkmelley

    Cosmos

  • *****
  • topic starter
  • Posts: 8,226
  • Joined: 19 Feb 2013

Posted 27 February 2020 - 04:46 AM

A very common question about DeepSkyStacker (DSS) is that the DSS preview looks different to using Photoshop to open the stacked file.  The short answer is that it certainly seems to be the case that the DSS preview stretches the data in unexpected ways.

 

Over the next couple of posts I will investigate this, using a test raw file downloadable from my Google Drive:

 https://drive.google...WfnDXYW-v65d0Cr

 

There are two completely different ways people use DSS:

  • Method 1 - put the raw CR2/NEF/ARW/DNG files into DSS for stacking
  • Method 2 - convert CR2/NEF/ARW/DNG to TIFs using Photoshop/Lightroom/RawTherapee then put those TIFs into DSS for stacking

I'll do things backwards, so in this first post I'll examine Method 2.

 

This is what the file looks like when saved as a 16bit TIF from Photoshop/Lightroom/RawTherapee:

 

BBStepWedge_Annotated.jpg

 

Each vertical bar is half (or twice) the intensity of the neighbouring bar.  The number of vertical bars you can see will depend on the quality and/or adjustments of your display.

 

This is what it looks like when opened in DSS:

 

DSS_TIF.jpg

 

The DSS preview initially displays the file correctly.

 

The result after stacking is this:

 

DSS_TIFStacked.jpg

 

With the default settings the DSS preview looks very weird.

 

Saving the result as a 16-bit TIF ("Embed adjustments in the saved image but do not apply them") and opening in Photoshop gives this:

 

PS_TifProcessing16bit.jpg

 

It looks totally normal!

 

But if I use Photoshop to open the autosave.tif or a saved 32-bit TIF, it looks wrong:

 

PS_AutosaveTif.jpg

 

This is because 32-bit mode in Photoshop expects linear data but this file contains sRGB data i.e. data with gamma applied.

 

Conclusion:

When stacking TIF files in DSS save the result as 16-bit TIF and don't use the autosave.tif file.  Ignore the DSS preview of the stacked data.

 

Mark


Edited by sharkmelley, 27 February 2020 - 06:30 AM.


#2 sharkmelley

sharkmelley

    Cosmos

  • *****
  • topic starter
  • Posts: 8,226
  • Joined: 19 Feb 2013

Posted 27 February 2020 - 05:00 AM

 In this second post I'll examine Method 1.

This is what the raw file looks like when opened in DSS:

 

DSS_Raw.jpg

The DSS preview looks wrong - it is too contrasty with too few vertical bars showing.

The result after stacking is this:

DSS_RawStacked.jpg

With the default settings, the DSS preview again looks very weird.

But if I use Photoshop to open the autosave.tif or a saved 32-bit TIF, it looks fairly normal and shows the expected number of vertical bars with the correct fall off in intensities:

PS_AutosaveRaw.jpg

This is because the image file is linear and 32-bit mode in Photoshop expects linear data.  The muted colours are because DSS does not know how to apply the appropriate camera correction matrix (CCM), which is a necessary step for accurate colour that the Photoshop/Lightroom/RawTherapee raw conversion does automatically - see Method 2.

Saving the result as a 16-bit TIF ("Embed adjustments in the saved image but do not apply them") and opening in Photoshop gives this:

PS_RawProcessing16bit.jpg

 

It looks wrong because outside the special 32-bit mode, Photoshop expects data with gamma applied but this image file is linear.

Conclusion:

When stacking raw files in DSS use the autosave.tif file or save the result as a 32-bit TIF and use Photoshop to open it.  Ignore the DSS preview of the stacked data.

Mark


Edited by sharkmelley, 27 February 2020 - 06:34 AM.


#3 Jim Davis

Jim Davis

    Fly Me to the Moon

  • *****
  • Posts: 5,819
  • Joined: 05 Jul 2014

Posted 27 February 2020 - 09:41 AM

Thanks for doing the analysis. Very helpful



#4 Seven007

Seven007

    Vostok 1

  • -----
  • Posts: 140
  • Joined: 14 Nov 2019

Posted 28 February 2020 - 01:22 PM

Very interesting, good analysis!

#5 Jerry Lodriguss

Jerry Lodriguss

    Voyager 1

  • ****-
  • Posts: 7,803
  • Joined: 19 Jul 2008

Posted 29 February 2020 - 12:40 AM

It looks wrong because outside the special 32-bit mode, Photoshop expects data with gamma applied but this image file is linear.

Conclusion:

When stacking raw files in DSS use the autosave.tif file or save the result as a 32-bit TIF and use Photoshop to open it.  Ignore the DSS preview of the stacked data.

Hi Mark,

 

How are you converting the 32-bit autosave.tif file to 16 bits in PS?

 

Jerry



#6 sharkmelley

sharkmelley

    Cosmos

  • *****
  • topic starter
  • Posts: 8,226
  • Joined: 19 Feb 2013

Posted 29 February 2020 - 02:40 AM

Hi Mark,

 

How are you converting the 32-bit autosave.tif file to 16 bits in PS?

 

Jerry

Hi Jerry,

 

To produce faithful and consistent colours, first subtract as much background as possible in 32-bit mode because all operations in 32-bit mode are linear. This is a key point that detractors of Photoshop always seem to miss.  The great power of 32-bit mode is that the image is being displayed on the screen accurately but we can work on the data as linear.

 

The best way to do this subtraction is to sample the background then create a "New Fill layer" of "Solid Colour" with mode set to "Subtract" and Opacity set to "99%".  Avoid black clipping in any case. 

 

Then you are ready to go back to 16-bit mode.  Merge the layers and perform Image->Mode->16 Bits/Channel.  In the HDR Toning dialog I choose "Exposure and Gamma" as the method with the defaults left as 0.0 and 1.0.   Then use traditional stretching on the image.

 

However, I'm certainly interested to hear about alternative ways of doing this.

 

Mark


Edited by sharkmelley, 29 February 2020 - 02:46 AM.


#7 Jerry Lodriguss

Jerry Lodriguss

    Voyager 1

  • ****-
  • Posts: 7,803
  • Joined: 19 Jul 2008

Posted 29 February 2020 - 06:22 AM

To produce faithful and consistent colours, first subtract as much background as possible in 32-bit mode because all operations in 32-bit mode are linear. This is a key point that detractors of Photoshop always seem to miss.  The great power of 32-bit mode is that the image is being displayed on the screen accurately but we can work on the data as linear.

 

The best way to do this subtraction is to sample the background then create a "New Fill layer" of "Solid Colour" with mode set to "Subtract" and Opacity set to "99%".  Avoid black clipping in any case. 

 

Then you are ready to go back to 16-bit mode.  Merge the layers and perform Image->Mode->16 Bits/Channel.  In the HDR Toning dialog I choose "Exposure and Gamma" as the method with the defaults left as 0.0 and 1.0.   Then use traditional stretching on the image.

Hi Mark,

 

Thanks, I'm going to give this a try and report back.

 

Have to remember set the PS sample tool to 16-bit readout to sample the sky to subtract the sky foreground.

 

Jerry



#8 OllieN

OllieN

    Lift Off

  • -----
  • Posts: 1
  • Joined: 01 Mar 2020

Posted 01 March 2020 - 02:12 PM

Wow, this could be revolutionary..  I have been stacking Nikon NEF files and using the 16 bit TIF output.  I've just run a quick test of a D5500 NEF of a bowl of fruit and get the same results as you - the TIF output is very dark and constrasty and the histogram is right against the left with pixels having been squashed right into the bottom levels (only 1 pixel black clipped though)  I guess this will make detail much harder to recover.  I will have to have a reprocess of some images and see.. 

 

The Autosave is much better, though it appears in CS6 I have no option to adjust or edit in 32 bit..

 

Many thanks for this work.



#9 sharkmelley

sharkmelley

    Cosmos

  • *****
  • topic starter
  • Posts: 8,226
  • Joined: 19 Feb 2013

Posted 01 March 2020 - 03:19 PM

The Autosave is much better, though it appears in CS6 I have no option to adjust or edit in 32 bit.

 

Unfortunately earlier versions of Photoshop don't provide 32-bit support for my suggestion of creating a fill layer in subtract mode to remove the bulk of the light pollution. However there is a Plan B!  

 

Open the 16 bit TIF output and then assign a linear profile to it i.e. a profile with gamma=1.0  The image will again display correctly while you are working on the linear data.  A fill layer in subtract mode is again the best method of subtracting the bulk of the light pollution.   You can convert to a normal sRGB or AdobeRGB profile at any time - preferably after subtracting the light pollution.   I can provide detailed instructions for those unfamiliar with playing with profiles.

 

I take exactly the same approach in PixInsight - I use the ColourManagementSetup tool to apply a linear profile to the linear stacked data.  I can then work on an image that is being displayed correctly on the screen.

 

Mark


Edited by sharkmelley, 01 March 2020 - 03:25 PM.


#10 17.5Dob

17.5Dob

    Voyager 1

  • *****
  • Posts: 10,353
  • Joined: 21 Mar 2013

Posted 01 March 2020 - 06:26 PM

Wow, this could be revolutionary..  I have been stacking Nikon NEF files and using the 16 bit TIF output. 

 

I've always used the 32 bit Autosave. It's easy enough to convert to 16 bit in PS, but it's ready to go in PI.



#11 sharkmelley

sharkmelley

    Cosmos

  • *****
  • topic starter
  • Posts: 8,226
  • Joined: 19 Feb 2013

Posted 01 March 2020 - 07:02 PM

I've always used the 32 bit Autosave. It's easy enough to convert to 16 bit in PS, but it's ready to go in PI.

Unless you use a linear colour management profile in PI, the 32-bit linear image will not be displayed correctly.  Typically this means that a huge amount of stretching is required before nebulosity begins to appear.  In my opinion this creates an unnecessary obstacle for those unfamiliar with the reasons behind it - especially those moving from a DSS/Photoshop paradigm to a pure PixInsight paradigm.

 

Mark


Edited by sharkmelley, 01 March 2020 - 07:06 PM.



CNers have asked about a donation box for Cloudy Nights over the years, so here you go. Donation is not required by any means, so please enjoy your stay.


Recent Topics






Cloudy Nights LLC
Cloudy Nights Sponsor: Astronomics