Author Topic: StarAlignment - number of tries  (Read 7549 times)

Offline TrickyDicky

  • Newcomer
  • Posts: 46
StarAlignment - number of tries
« on: 2012 August 17 21:22:32 »
I've been waiting for 2 days to finish off registration of phots, some of them were registered almost "on the go", some of them go through several tries.
At this moment for this particular photo the try number is #29 and it's been, I don't know, something like 6 hours ..
I'd like to limit the number of tries and if a photo can not be registered - so be it!
How to select the max number of tries?

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: StarAlignment - number of tries
« Reply #1 on: 2012 August 18 02:08:06 »
Open the Star Matching section and enter something like 2000 or 1000 for the maximum stars parameter. This will disable the automatic probing routine. Also see this thread for a similar problem.

However, this happens because some of your images cannot be aligned for some reason. You may want to inspect your images to detect the wrong shots prior to calibration and registration.

Quote
I've been waiting for 2 days to finish off registration

Wow! This should never happen. What machine are you using?
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline TrickyDicky

  • Newcomer
  • Posts: 46
Re: StarAlignment - number of tries
« Reply #2 on: 2012 August 18 09:42:29 »
I use win7-64 I-7 8GBram.
How to limit the number of tries?

Offline georg.viehoever

  • PTeam Member
  • PixInsight Jedi Master
  • ******
  • Posts: 2132
Re: StarAlignment - number of tries
« Reply #3 on: 2012 August 18 10:54:20 »
...Wow! This should never happen. What machine are you using?

I have seen this when memory becomes short during matching. Some step within StarAlignment seems to use a lot of memory (with the default settings), and a 4 GB machine gets into swapping. StarAlignment can than take days until it fails.

Georg
Georg (6 inch Newton, unmodified Canon EOS40D+80D, unguided EQ5 mount)

Offline TrickyDicky

  • Newcomer
  • Posts: 46
Re: StarAlignment - number of tries
« Reply #4 on: 2012 August 18 19:51:49 »
Onec I eliminated photos that caused troubbles, the whole process of registration of 46 photos took less than 3mins and the maximum number of tries in one ore two cases was 5.
So, It would be nice to have somewhere access to that number and set it much much lowere than the default - which is, I think, 30..

Here is the resultant image:

Offline Eddy Timmermans

  • PixInsight Addict
  • ***
  • Posts: 149
Re: StarAlignment - number of tries
« Reply #5 on: 2012 August 20 02:29:09 »
I experienced the same problem. SA will only stack about 15 of my images and then continue to try forever.
DeepSkyStacker however stacks them all in one go.
For the moment my equipment is far from ideal, but I still want to image the heavens and try each time to do better.
I really love the BatchPreProcessing script, but until my imaging improves I'll have to use DSS for stacking and PI for processing.

Eddy


Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: StarAlignment - number of tries
« Reply #6 on: 2012 August 20 04:17:16 »
Hi Eddy,

Finally I've had some time to download your raw frames from Endor. StarAlignment fails to register your images because it rejects most of the stars due to bad tracking. By default, SA rejects too distorted or oblong stars because they are inaccurate alignment references. While this can be avoided by tweaking parameters, I don't recommend you to do this. Other applications may be less restrictive than StarAlignment, but they are not giving you any solution to the actual problem that you have with your images.

As we have discussed here before, you should fix all tracking errors in your imaging hardware. There are no valid software solutions to this problem.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: StarAlignment - number of tries
« Reply #7 on: 2012 August 20 04:42:00 »
The next version of the BatchPreprocessing script will have the automatic probing feature disabled by default, so this problem will be fixed (Rationale: In a batch image preprocessing task all frames should be registered in a single attempt. The automatic probing feature of StarAlignment has been designed to help register images in very difficult cases, mainly in cases where there is very little overlap between images, or strong scale differences. These cases should never occur in a batch preprocessing task).

For now, a workaround is patching the script. This is actually very easy, but requires you to edit one of the script's source files:

1. Locate the folder where the script is installed. On Windows, this should be:

C:\Program Files\PixInsight\src\scripts\BatchPreprocessing

On OS X, the folder is within the PixInsight64.app application bundle. Right-click PixInsight64.app and select "Show Package Contents", then navigate to the src/scripts folder inside the package.

2. Copy the BatchPreprocessing folder to a location where you have write permission. For example, a good place is your Documents folder under your home folder.

3. Open the Script Editor window in PixInsight.

4. Select File > Open (from the Script Editor menu, *not* from PI's main menu).

5. Locate the folder where you have copied the BatchPreprocessing folder in step 2.

6. Open the 'BatchPreprocessing-engine.js' file

7. Press Ctrl+F (Cmd+F on OS X) and search for "new StarAlignment" (without the quotes). It should be around line 940 of the script (sorry, I don't have the same version that you have right now, so I don't know the exact line number).

8. After "new StarAlignment", add the following line:

SA.maxStars = 2000;

Take a look at the attached screenshot, where you can see an example.

9. Save the script by pressing Ctrl+S (Cmd+S)

10. Now you can run the modified script by selecting Script > Execute Script File from the main menu, and selecting the 'BatchPreprocessing.js' file from the folder where you copied the script in step 2. Note that the modified script is no longer available from the Script > Batch Processing menu, since it is not featured.

Hope this helps.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline georg.viehoever

  • PTeam Member
  • PixInsight Jedi Master
  • ******
  • Posts: 2132
Re: StarAlignment - number of tries
« Reply #8 on: 2012 August 20 06:38:44 »
Hi Juan,
your fix to BatchProcessing does not fix the core problem: After a couple of tries StarAligmnent becomes incredibly slow - I believe due to high memory consumption. And even for reasonable well (but not perfectly) tracked images I sometimes see SA requiring 2-3 tries.

I would rather prefer some way to tell SA to limit its memory consumption, or to give up if RANSAC does not make reasonable progress.

Georg
Georg (6 inch Newton, unmodified Canon EOS40D+80D, unguided EQ5 mount)

Offline Eddy Timmermans

  • PixInsight Addict
  • ***
  • Posts: 149
Re: StarAlignment - number of tries
« Reply #9 on: 2012 August 20 11:48:15 »
Today I tried to stack 80 images of 90 seconds that I took 2 nights ago using BatchPreprocessing.

It worked flawlessly !

Now that I know how to do it, I can focus more on the processing part.

Eddy

Offline gvanhau

  • PixInsight Old Hand
  • ****
  • Posts: 345
Re: StarAlignment - number of tries
« Reply #10 on: 2012 August 20 14:19:25 »
Hello

I agree with Georg, A Limit could be usefull here.

Normally Star aligment takes no more than 10 or 15 minutes for me (depending on number of images of course).
A week or so ago I did a mistake, when selecting the images I included one of another object.  After more than 18+ hours I desided to abbort the process.....

Regards
Geert


Geert Vanhauwaert

Offline TrickyDicky

  • Newcomer
  • Posts: 46
Re: StarAlignment - number of tries
« Reply #11 on: 2012 August 22 06:08:40 »
So, Juan, will you consider adding the feature of selecting the number of tries?

Offline lómbido

  • Newcomer
  • Posts: 15
Re: StarAlignment - number of tries
« Reply #12 on: 2012 October 18 00:27:14 »
Hello everyone,
I present myself. I am new in PixInsight and astrophoto  too. I have 20 images to preprocess and even did not check how long it takes automatically, I had to abort the process. I realized the time consuming process is Star Alignment so I can make the test with it and the calibrated images instead the whole preprocessing script. I have limited the Maximum Stars to 2000 in Star Matching and the process goes right in time but performance are not desirable. Changing the reference image the best result I got  is four images registered while in other software I got sixteen proper registered images in automatic mode. If anyone wants help me I can upload the calibrated files.

Many thanks and regards.

Offline lómbido

  • Newcomer
  • Posts: 15
Re: StarAlignment - number of tries
« Reply #13 on: 2012 October 18 01:14:13 »
Images location just in case. Note the object is NGC253 instead NGC3628 as the file name says.
https://www.dropbox.com/sh/bbi7thlav8b5nm9/haK1rnf6Sr
thanks
« Last Edit: 2012 October 18 01:32:57 by lómbido »

Offline lómbido

  • Newcomer
  • Posts: 15
Re: StarAlignment - number of tries
« Reply #14 on: 2012 October 19 00:19:57 »
Good morning,
I have eliminated the files that were placed in the above link. I have continued working on the same frames. What is new is that apart from dark frames I have added the correspondent flat and bias frames during calibration. Doing this the alignment convergence takes only a few minutes. I am happy about that but the integrated image is moved as if registration was not accurate enough. Registration is succeeded for all the frames while other software pre-processors  eliminate a couple of them. Any idea?

Many thanks and regards