Does SGP talk to Planewave's PWI AutoFocus?

That’s a pretty nice V-curve considering he only used 5 points, 500 micron steps, and very few stars (5-15) detected.

The current SGP algorithm could not do this.

KG

One can run the focus analysis directly from PlateSolve 2.29, just start it and click on Tools/Focus Analysis. Then you click on the first (any) file in the folder containing all the the AF fit files. I did this on the latest data set from @Kurious_George, and the resulting focus position looks the same (5689.2):

But, looking at how the Status bar evolves, there appears to be no plate solving going on, it appears only to use the HFD data from the “Measuring stars…” process. No “Search Center” or “Plate Geometry” is ever reported, and it looks to quick to do any platesolving. If this is how PWI works as well (with PlateSolve) then I would say Han is right, it is only down to using a better star detection routine. I might be wrong but you can run it yourselves with PlateSolve2 to check.

Playing around with it I could not find any output files with the results, so not sure how one would interface with it. I know how to invoke the PlateSolve2 plate solving from the command line, like SGP, but I dont know how to invoke this routine from the command line and get the results. This is maybe proprietary information.

Mikael

1 Like

I also did a quick test with SGP. I opened each FIT file @Kurious_George sent us, and noted the HFR value reported in the Image Statistics. The HFR values, starting from the lowest focus position 4536, are:

5.23
4.05
3.48
3.04
2.88
3.28
4.54
5.72

Then I fitted a quadratic curve to it using Matlab:

which gave me a best focus position of 5728. Using Matlab one also gets the error in the estimated best focus position, which gives that there is 95% confidence that the best focus position is between 5671 and 5784, given the experimental data and the quadratic model. This means that any value in between these limits can be considered equally probable as being the true minimum, with 95% confidence that it doesnt lie outside this region.

Of note is that if I use exactly the same data from SGP, but with a hyperbolic fit, I get a best focus position of 5699, so close to the PWI value.

ADDED NOTE: I did only a quick inspection of the star detections in SGP, but I couldnt find any detected galaxy cores, nor double detections, so this might not be a good data set for detecting the problems @Kurious_George have been mentioning.

KG,

The curve drawn is the calculated hyperbolic. The real curve would be something you get when you connect the dots with lines. That will look much different. So the quality is indicated by the closest distance between the drawn curve and the dots.

Using Platesolve2 for measuring “star diameters” would fulfill your original request which started this discussion.

The menu indicates option to select an image area, so I presume and list of detected stars is extracted.

Easiest and proper step would be if @Jared would ask PWI how to use PlateSolve2 to extract the star diameters from a bunch of images and if this is within his license to use PlateSolve2.
(An other way would be to place a clone program and record the command line, presuming it is command line driven).

I’m also a little puzzled why Platesolve3 is not used, but I have no idea if version Platesove3 exist and what the differences are.

Han

PWI curve

mikaelA, I missed your post. Yes that PlateSolve2 option looks interesting. I have put both the ASTAP HFD values and PlateSolve2 values in a spreadsheet. After increasing the PlateSolve2 star diameters with a factor 1.25 they match almost perfect with the ASTAP values:

Han

Hi folks,

Here’s the same data, cropped to 1024 x 1024, to simulate less stars and a higher percentage of outliers…

https://spaces.hightail.com/receive/ZKrYqucGuP/Y3VyaW91c2dtb25rQGdtYWlsLmNvbQ==

KG

…it does appear that if SGP used PlateSolve2, it would likely match the performance of PWI3 if followed up with a V-curve fit.

KG

Yes but nobody except PWI knows at this moment how to interface with PlateSolve2 for this special “image analyse” function. For the moment try ASTAP with the SGP beta version and see how it performance with focusing.

If Jared is interested in using Platesolve2 this way he has to contact PWI.

Please see the code snippets I posted at the start of this thread. I think they provide some ideas regarding how SGP may use PlateSolve2?

@Kurious_George,

Hi,

I appreciate that you still desire to have SGP interface to PWI3/PlateSolve2 but whether or not this ever comes about I do think it would be nice if you have not already done so, to give the ASTAP method a decent try and to post some results for comparison by the rest of us.

My personal experience is that the SGP/HFR focus method generally gave consistently good results when focusing with L filter on well-populated starfields but consistency dropped considerably when stars were few or faint, as when using RGB or NB filters or when imaging away from Milky Way centre. I think the ASTAP option greatly reduces this problem.

I appreciate that you are using a very different scope to mine so it would be nice, and possibly educational, to see some of your focus images and results that do actually show the impact of ‘double stars, small galaxies and other non-star objects that can throw the V-Curve off 100+ microns - Post 14’. For what its worth my opinion is that the poor results you had were as likely due to poor determination of HFR on out-of-focus images on the AF wings as to the objects you assert are the problem. The image that you posted at 87, does not really seem to demonstrate the non-stellar object point you expected. The results posted by @han and @mikaelA seem closely grouped and are very possibly within the limits of what is achievable with current technology in a reasonable time period.

I appreciate that you also still have the frustration of cross-talk between PWI3 and SGP over precise focuser positioning. The classic system integrator’s nightmare!

Mike

1 Like

I had a chance to repeat my original example from February 2020 where SGP differed noticeably from PWI3. Luckily the object was up and I was also up. (-:

I also included a SGP run result using my current V 3.1.0.451 with 8 points, 350 step size, min star diameter = 2, crop 5%, HFR.

SGP Best Focus = 5968
PWI3 Best Focus = 5900

https://spaces.hightail.com/receive/X9N7NUX5G8

KG

@Kurious_George
Hi,

First observation is that the SGP AF Result / AF graph was obtained with the SGP HFR star analysis method rather than the HFD ASTAP method:

Using @han ASTAPs Hyperbolic curve fitting method gives focal positions of 5888 (Image centre) and 5919 (full frame), so PWIs of 5899 sits close to the middle of this range, and both within the 95% confidence limit mentioned by @mikaelA. SGP would not load your images (not 16bit fits) so not sure what result SGP would give using ASTAP’s image metrics but assume it would give a very similar result.

Looking at your 5734 image, it does appear that two galaxies were included in the 132 ‘star’ detections but these seem to have skewed the result only marginally at worst. Looking at the 4684 and 7134 images I see the same two galaxies were also included in the metrics for these images (han, I hope I have that right).

Eitherway, I think the ASTAP metrics would give you a significant improvement with ‘difficult cases’ and arguably almost imperceptably different to PWI3.

Awaiting your feedback

Mike

1 Like

I have contacted Matt Dieterich of PlaneWave and he is willing to ask the question within PlaneWave if it is possible to share the information how to access PlateSolve2 externally for “image analyzing”. I have no idea what will come out this.

For the moment it is save to assume that ASTAP will perform similar as PlateSolve2 for this purpose.

1 Like

I downloaded and installed the above SGP test file on my Windows 7 64-bit machine. It doesn’t start when I select the desktop icon.

KG

According to the Download page the current releases of SGP are supported on Win 8 & 10, not Win 7.

Got it. I’ll try testing tonight using HFD - ASAP.

KG

Unfortunately I can’t test it. The beta SGP version doesn’t connect to Pinpoint. That’s what I use for fast plate solving.

KG

KG, you could select Platesolve2 or ASTAP for solving. Or run a focus test without solving

Will try again tonight. Working around a project and seeing is very good. (-:

Looks like there may be a bug?

AutofocusError2

[11/13/20 19:01:46.359][DEBUG][Camera Thread][AF;] Display image preview using asynch task…
[11/13/20 19:01:46.409][DEBUG][Main Thread][AF;] --> Find stars (normal)
[11/13/20 19:01:46.427][DEBUG][Main Thread][AF;] AF frame was too large… downsample = 0.75…
[11/13/20 19:01:47.155][DEBUG][Main Thread][AF;] Star detection using min star size of 2px…
[11/13/20 19:01:47.155][DEBUG][Main Thread][AF;] Star detection using max star size of 40px…
[11/13/20 19:01:47.171][DEBUG][Main Thread][AF;] Find stars took: 762 ms…
[11/13/20 19:01:47.171][DEBUG][Main Thread][AF;] Star list contains 76 stars…
[11/13/20 19:01:47.171][DEBUG][Main Thread][AF;] Calculating HFR with sample size: 1
[11/13/20 19:01:47.282][DEBUG][Camera Thread][AF;] MessageBoxHelper Show Error! : Object reference not set to an instance of an object.
at SequenceGenerator.MessageBoxHelper.a(Form A_0, String A_1, String A_2, MessageBoxButtons A_3, MessageBoxIcon A_4)
[11/13/20 19:01:47.298][WARN][Camera Thread][AF;] HFD value from auto focuser is 0!, trying again…
[11/13/20 19:01:47.363][ERROR][Camera Thread][AF;] Auto focus received a bad HFD value 2 times in a row! Something may be wrong! : Auto focus received a bad HFD value 2 times in a row! Something may be wrong!
at rd.a(AutoFocusData A_0, tk& A_1, tk[] A_2)
[11/13/20 19:01:47.363][DEBUG][Camera Thread][AF;] MoveFocuserAbs: Start, move to 5606…
[11/13/20 19:01:47.363][DEBUG][Camera Thread][AF;] ASCOM Focuser: MoveSync - start…
[11/13/20 19:01:47.363][DEBUG][Camera Thread][AF;] Focuser moving to 5606
[11/13/20 19:01:47.364][DEBUG][Camera Thread][AF;] Focuser move call complete
[11/13/20 19:01:47.364][DEBUG][Move Monitor Thread][AF;] ASCOM Focuser: Move monitor thread is started…
[11/13/20 19:02:00.373][DEBUG][Move Monitor Thread][AF;] ASCOM Focuser: Move monitor thread -> movement complete
[11/13/20 19:02:00.374][DEBUG][Camera Thread][AF;] ASCOM Focuser: MoveSync - Focuser reports it is done moving, continuing…
[11/13/20 19:02:00.374][DEBUG][Camera Thread][AF;] MoveFocuserAbs: End, move complete, at 5606…
[11/13/20 19:02:00.374][DEBUG][Camera Thread][AF;] Auto focus (finally): closing dialog…
[11/13/20 19:03:19.816][DEBUG][Camera Thread][AF;] Auto focus complete…
[11/13/20 19:03:19.825][DEBUG][Camera Thread][NONE] SGM_FOCUSER_AUTO_FOCUS complete…
[11/13/20 19:03:19.825][DEBUG][Camera Thread][NONE] Camera thread is IDLE…