Author Topic: StarAlignment Mosaic doesn't find tranform on mosaic'd image  (Read 6109 times)

Offline Nocturnal

  • PixInsight Jedi Council Member
  • *******
  • Posts: 2727
    • http://www.carpephoton.com
Hi,

I've embarked on a rather ambitious (stupid?) project of a 6 panel mosaic. I did a 4 panel mosaic a night later thinking that was more reasonable but that seems to have gone wrong enough that SA won't stick 'em together at all. Perhaps my images are disjoint.

Anyway, I've stitched 3 images together from left to right and now it's time to go up. I use the preview option, really cool by the way. In the screenshot you see the previews I've created. If I make HM_g6_crop the reference frame I can easily mosaic that with HM_f6_crop. You can see the resulting mosaic on the left. When I try to make the 3 panel mosaic the reference frame it can't find a solution. What can I do to help it find a solution? Is the black border a problem? I think the screenshots and videos show that this should work.


Oh, I realize I need to do DBE etc. on the images first but I won't attempt that unless I know I can create the mosaic so I'm doing that first to try.
Best,

    Sander
---
Edge HD 1100
QHY-8 for imaging, IMG0H mono for guiding, video cameras for occulations
ASI224, QHY5L-IIc
HyperStar3
WO-M110ED+FR-III/TRF-2008
Takahashi EM-400
PIxInsight, DeepSkyStacker, PHD, Nebulosity

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #1 on: 2009 December 19 15:15:53 »
Hi Sander,

Extremely cool mosaic!

Your Preview01 on HM_g6_mosaic (the 3-frame mosaic) doesn't define a valid overlapping region with HM_f6, due to the rotation of the aligned HM_g6 ("valid" here means "sufficiently restrictive"). The black areas are no problem at all.

Instead of a single preview on HM_g6_mosaic, define three or four previews adapted to the north edge of the HM_g6 frame. In this way you'll restrict the star matching process to a smaller region closer to the actual overlapping area. The previews can be overlapped; that's no problem. You can define any number of previews, and SA will gather all of them into a single (complex, non-rectangular) region.

Let me know if this works. Definitely you can build this mosaic. SA can build any mosaic as long as you can feed it with overlapped images and enough RAM to work :)

Additional suggestions:

- Reduce the detection scales parameter (Star Detection section) to 4 or 3, in order to detect more stars, for the sake of accuracy. A huge mosaic like this one requires a very accurate geometry at each building step; otherwise errors accumulate and the outer frames can be misplaced.

- Use surface spline interpolation, for the same reason.

- For such a large mosaic, consider the possibility of using StarGenerator to create a reference frame.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline NKV

  • PTeam Member
  • PixInsight Guru
  • ****
  • Posts: 677
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #2 on: 2009 December 19 21:04:27 »
- For such a large mosaic, consider the possibility of using StarGenerator to create a reference frame.
Juan, i have trouble with StarGenerator. I can't align images to generated stars. The fields look very similar, but 50% of stars have different positions, so the problem in Epoch. Can you show how SG+SA work with images used for last video tutorial. Do you have my images? All information in fits header.
Best regards,
Nikolay.

Offline Nocturnal

  • PixInsight Jedi Council Member
  • *******
  • Posts: 2727
    • http://www.carpephoton.com
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #3 on: 2009 December 20 14:17:13 »
Hi Juan,

I did as you said and built a stair case like set of previews. I can see the matching stars so I'm really trying to help SA do the matching. Still it won't. Was my third panel so distorted when it was mosaic'd that it just doesn't match the other panels anymore?

I've uploaded a cropped mosaic and the panel I'm trying to match to it, if you'd like to try.

http://cid-a93625fef5ca95fb.skydrive.live.com/browse.aspx/Heart%20Mosaic?uc=2&nl=1
Best,

    Sander
---
Edge HD 1100
QHY-8 for imaging, IMG0H mono for guiding, video cameras for occulations
ASI224, QHY5L-IIc
HyperStar3
WO-M110ED+FR-III/TRF-2008
Takahashi EM-400
PIxInsight, DeepSkyStacker, PHD, Nebulosity

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #4 on: 2009 December 21 15:15:39 »
Hi Sander,

Quote
Was my third panel so distorted when it was mosaic'd that it just doesn't match the other panels anymore?

Yes, that's exactly what happens. I've been able to align your fourth (top right) mosaic frame by tweaking SA parameters (scale tolerance = 0.15) and making some trial-error work, but with just 10 or 16 stars, and leading to even more distortion.

To minimize cumulative errors, I'd build this mosaic in three steps. Let's number your six mosaic frames:

1 2 3
4 5 6

I'd generate three sub-mosaics: (1,4), (2,5) and (3,6). Then I'd join [(1,4),(2,5)] and finally {[(1,4),(2,5)],(3,6)}. This should work pretty well.

However, the best way to generate these wide-field mosaics is through a synthetic master frame made with StarGenerator. Calculate the approximate equatorial coordinates of the center of your mosaic (perhaps you can use the information stored in FITS headers), and create a synthetic field up to magnitude 12 at least. For maximum accuracy, use DynamicAlignment instead of SA. DA is more accurate to model distortions, and hence to adapt your frames to a map projection, because it is not restricted to a relatively rigid registration model, as SA is. SA's initial star matching procedure is based on triangle similarity, which restricts the model basically to an affine transformation (translation+rotation+scaling). Although SA can overcome this limitation partially to include moderate small-scale distortions, DA allows you to adapt your images virtually to any geometry. Your mosaic can be very well defined with just six or eight alignment stars on each frame. This involves some manual work, but the result is worth the extra work. Your mosaic will have the geometry of a Lambert conformal conic projection: it will reproduce true angles on the sky, which is a nice property :)
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline Niall Saunders

  • PTeam Member
  • PixInsight Jedi Knight
  • *****
  • Posts: 1456
  • We have cookies? Where ?
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #5 on: 2009 December 21 16:33:14 »
Quote
However, the best way to generate these wide-field mosaics is through a synthetic master frame made with StarGenerator

Hi Juan,

I have been trying for several days now - and can't figure out how to drive StarGenerator at all. Having already downloaded the WHOLE of the USNO-A database (6GB  :-\) so that I could see stars down to Mag20 in Cartes du Ciel, I am a bit upset that I now have to download another MAMMOTH dataset to be able to use StarGenerator (although I have been tempted to just try 'cut-and-paste' straight from CdC into PI, and see if DynamicAlignment will work with THAT data  ;D)

So far though, I have downloaded the "n1500.dat" file - thinking (stupidly  ???) that this was the datafile that covered M1 (Crab Nebula) at RA 05h35'07" Dec +22deg01'28" - but, if it is the correct datafile, then I still have no idea how to get SG to create the 'map'.

Now, I do know that the following is an entry from the n1500.dat file - so how could I set up SG to synthesise a star field centred on this entry :-

Quote
172108.6+190133   937030073   68493705    -750     179  -218  -218  74  74 120 120 15090 15194 -9999 -99 -9999 -99 14048  28 13734  36 13694  40  2   O G  0154501726

As usual, thanks in advance,
Cheers,
Niall Saunders
Clinterty Observatories
Aberdeen, UK

Altair Astro GSO 10" f/8 Ritchey Chrétien CF OTA on EQ8 mount with homebrew 3D Balance and Pier
Moonfish ED80 APO & Celestron Omni XLT 120
QHY10 CCD & QHY5L-II Colour
9mm TS-OAG and Meade DSI-IIC

Offline Andres.Pozo

  • PTeam Member
  • PixInsight Padawan
  • ****
  • Posts: 927
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #6 on: 2009 December 22 02:06:26 »
So far though, I have downloaded the "n1500.dat" file - thinking (stupidly  ???) that this was the datafile that covered M1 (Crab Nebula) at RA 05h35'07" Dec +22deg01'28" - but, if it is the correct datafile, then I still have no idea how to get SG to create the 'map'.
That is not the correct file. You have to download http://pixinsight.com/export/StarGenerator/PPMX.bin. It is only documented in the installation section of the announcement of the tool for MacOS: http://pixinsight.com/forum/index.php?topic=1366

Juan, I think that this should be way better documented, or even adding a link inside the application to download this file. I lost a lot of time until I discovered PPMX.bin. It seems that I am not the only one.

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #7 on: 2010 January 03 09:24:11 »
Andrés,

Quote
Juan, I think that this should be way better documented, or even adding a link inside the application to download this file. I lost a lot of time until I discovered PPMX.bin. It seems that I am not the only one.

Point taken. I'll try to release a video on StarGenerator as soon as possible (and I know from good sources that an excellent video on this tool is being cooked). Besides that, I'll think on a way to download star database files from the StarGenerator interface. Thanks for pointing out this problem.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline pfile

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 4729
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #8 on: 2010 January 03 22:30:03 »
i recently did a much less ambitious mosaic, involving only two panels.

now i'm sure that all of my problems are down to inexperience with PI, but i had two issues. first was that even though each panel was the same depth stack and the same exposure, the two panels were taken on different nights under slightly different sky conditions. despite trying to normalize the two panels and do identical processing on them, the final images had different background and foreground brightness. while i was able to tweak the histograms to get them pretty close luminance and color wise, the seam would still be obvious without employing some kind of seam blending.

the second problem was that the mosaic creation tool (or rather the star detection) seemed to be kind of nondeterministic. sometimes it would fail to find star matches and sometimes it would succeed, in back to back applications of the tool. its likely that i had to provide it with more guidance; actually i have not upgraded to the latest and greatest version that works with previews. anyway because of the sketchy star detection it was sometimes applying all kinds of crazy transformations to the images when all that was needed was translation.

so i decided to just panelize the two images using pixel math and do all the processing on the images that way, then at the end crop them back into two separate images, and attempt to align them somehow.

since i have a lot of experience with hugin (and enfuse), i used enfuse to do an exposure fusion on 10 separate stretches of the panelized image, and then hugin to do the final stitch on the two cropped images. i only had to define 6 control points, which is pretty darn easy with stars. hugin's gui is a little wonky on such narrow FOV images, but i did manage to get it to work. you really only need the gui to define the cropping, but that's important because otherwise it might generate a 2TB tiff file :) at any rate hugin does pretty reasonable seam blending...



anyhow, it's just a thought. probably if i knew PI better i would not have to resort to hugin, but it's the devil i know :)

Offline Niall Saunders

  • PTeam Member
  • PixInsight Jedi Knight
  • *****
  • Posts: 1456
  • We have cookies? Where ?
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #9 on: 2010 January 04 03:22:51 »
I'll tell you what - no matter HOW you put together that mosaic, it sure is impressive.

I really like the colour saturation - it seems 'natural'

Well done.
Cheers,
Niall Saunders
Clinterty Observatories
Aberdeen, UK

Altair Astro GSO 10" f/8 Ritchey Chrétien CF OTA on EQ8 mount with homebrew 3D Balance and Pier
Moonfish ED80 APO & Celestron Omni XLT 120
QHY10 CCD & QHY5L-II Colour
9mm TS-OAG and Meade DSI-IIC

Offline pfile

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 4729
Re: StarAlignment Mosaic doesn't find tranform on mosaic'd image
« Reply #10 on: 2010 January 04 13:24:31 »
thanks niall. i don't want to hijack the thread but i just wanted to put hugin out there as an alternative for making mosaics. i suspect that sander may have to put in just as much work into Pixinsight to get the mosaic to align as you'd have to do to manually enter the control points in hugin. at least it can be done with a gui.

the full size is not much to be proud of - this is the first time i tried to do deconvolution in PI and i'm left with some ringing artifacts and sharpening of bogus features. maybe i'll post it in another thread.