Stacking via WCS results in blank images

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Stacking via WCS results in blank images

cduston
Hello,

   Running AstroImageJ 3.2.0 on Ubuntu MATE here. I have a pair of images which appear to have valid WCS - at least, at the top of the image it says (WCS=RA,DEC, PA+Scale). So if I try to stack these via Process -> Align Stack using WCS or aperatures, and click "use only WCS headers for alignment", I get the success message (something like "images saved in subdirectory 'aligned'").

So I open the aligned images as a stack, but they are blank, and in no image data anywhere. There is a plate scale (X,Y, and RA, Dec) but all count values are identically 0.

Anyone know what is causing this? I can do a fine alignment using aperatures, but I'm having some SIMBAD-search problems later with the new plate solutions, so I'd like to preserve the WCS from the original images if possible.

Thanks!
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Stacking via WCS results in blank images

karenacollins
Administrator

Since AIJ is creating a new directory for the aligned images, I think you opened the images as a "virtual stack". If that is the case, can you try opening the images directly into memory to see if you still have that problem? In this case, the images will be keep in memory and not written to a subdirectory. Let me know if you still see the problem.


One thing to check. Make sure the option "Remove background and scale to common level" is not enabled on the alignment setup panel.


Either way, if you can send me the two sample images directly to karenacollins at outlook dot com, I can try to reproduce the problem on my system. My limitation is that I run Microsoft Windows and don't have access to an Ubuntu machine, but if I can't duplicate under Windows, I can try it on a system with an alternate linux distribution.


Karen

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Stacking via WCS results in blank images

cduston
Hi Karen,
    Thanks so much for helping.

1) The "remove background and scale" option is not checked.

2) Tried to load them directly into memory, by leaving the "virtual stack" button unchecked. In this case, with "Use only WCS headers..." checked, I get blank images immediately post-alignment. I guess that's expected behavior - the images look exactly like the ones copied into "aligned". There is a 0 at every pixel.

I will send these images to you right now, and if we find a fix I'll add it to this thread.

Thanks!

Chris

On Thu, Jul 6, 2017 at 5:58 AM, karenacollins [via AstroImageJ] <[hidden email]> wrote:

Since AIJ is creating a new directory for the aligned images, I think you opened the images as a "virtual stack". If that is the case, can you try opening the images directly into memory to see if you still have that problem? In this case, the images will be keep in memory and not written to a subdirectory. Let me know if you still see the problem.


One thing to check. Make sure the option "Remove background and scale to common level" is not enabled on the alignment setup panel.


Either way, if you can send me the two sample images directly to karenacollins at outlook dot com, I can try to reproduce the problem on my system. My limitation is that I run Microsoft Windows and don't have access to an Ubuntu machine, but if I can't duplicate under Windows, I can try it on a system with an alternate linux distribution.


Karen




If you reply to this email, your message will be added to the discussion below:
http://astroimagej.1065399.n5.nabble.com/Stacking-via-WCS-results-in-blank-images-tp708p709.html
To unsubscribe from Stacking via WCS results in blank images, click here.
NAML

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Stacking via WCS results in blank images

karenacollins
Administrator

Hi Chris,


Thanks for the images. I do see the problem here and there is nothing you are doing wrong. However, the plate-solve headers that are added to the image headers are not in standard WCS format. There is enough info there to display RA and Dec, the plate scale, and the sky orientation arrows, but for WCS alignment to work, the images must have the WCS header keywords and values for CRPIX1, CRPIX2, CRVAL1 and CRVAL2, so that there is a specific pixel and associated RA and DEC that can be compared from image to image, and so the CRPIX1 and CRPIX2 values can be easily adjusted to account for the shift so that RA and Dec will display properly after the images have been aligned.


That's probably more than you wanted to know, but the bottom line is that the form of plate solution in your headers can not currently be used to align images. Your version of headers could probably be used for alignment when I can get time, but I won't be able to figure out how to implement that in the near future. The other issue is that there are several different formats of non-standard WCS headers, and it is probably not practical for me to support them all. I should at least consider showing an error message when the appropriate WCS headers are not available.


At least for now, you will have to plate solve using a different method (e.g. the AIJ link to astrometry.net, or astrometry.net directly, or TheSkyX since I know that it adds WCS compliant headers), or align using apertures, which I think would work fairly well for the sample images you sent. The downside of aligning using apertures is that the RA and Dec display may be wrong after alignment since the CRPIX1 and CRPIX2 are not in the headers for AIJ to adjust.


I apologize that I am not able to support the current format of plate solution in your headers at the present time,


Karen



Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Stacking via WCS results in blank images

cduston
Hi Karen,
     This is great, thanks for your detailed answer.

I agree - I think a warning message is appropriate. If I was using IRAF I might have noticed the missing header keywords, but with something like AstroImageJ I had no idea what to look out for. Part of my decision making was driven by the fact that these images come from the itelescope network, so the presence of the WCS in the first place made me think they "knew what they were doing", and an additional plate solution would not be needed.

But, your solution worked perfectly - I just did another plate solution (via Astrometry.net) and the aligned images look fine. This was very easy, so I don't view this as "needing to be supported by AstroImageJ", but I do think a warning message when I tried to do the original alignment would have been appropriate, and could have directed me to a solution without having to bother you.

But, this solves my problem so thanks very much, I really appreciate the attention to this issue.

Chris

On Fri, Jul 7, 2017 at 6:52 AM, karenacollins [via AstroImageJ] <[hidden email]> wrote:

Hi Chris,


Thanks for the images. I do see the problem here and there is nothing you are doing wrong. However, the plate-solve headers that are added to the image headers are not in standard WCS format. There is enough info there to display RA and Dec, the plate scale, and the sky orientation arrows, but for WCS alignment to work, the images must have the WCS header keywords and values for CRPIX1, CRPIX2, CRVAL1 and CRVAL2, so that there is a specific pixel and associated RA and DEC that can be compared from image to image, and so the CRPIX1 and CRPIX2 values can be easily adjusted to account for the shift so that RA and Dec will display properly after the images have been aligned.


That's probably more than you wanted to know, but the bottom line is that the form of plate solution in your headers can not currently be used to align images. Your version of headers could probably be used for alignment when I can get time, but I won't be able to figure out how to implement that in the near future. The other issue is that there are several different formats of non-standard WCS headers, and it is probably not practical for me to support them all. I should at least consider showing an error message when the appropriate WCS headers are not available.


At least for now, you will have to plate solve using a different method (e.g. the AIJ link to astrometry.net, or astrometry.net directly, or TheSkyX since I know that it adds WCS compliant headers), or align using apertures, which I think would work fairly well for the sample images you sent. The downside of aligning using apertures is that the RA and Dec display may be wrong after alignment since the CRPIX1 and CRPIX2 are not in the headers for AIJ to adjust.


I apologize that I am not able to support the current format of plate solution in your headers at the present time,


Karen






If you reply to this email, your message will be added to the discussion below:
http://astroimagej.1065399.n5.nabble.com/Stacking-via-WCS-results-in-blank-images-tp708p714.html
To unsubscribe from Stacking via WCS results in blank images, click here.
NAML

Loading...