Smart Focus Lost - Frequently happening 3.1.0.313

Tonight has been pretty much a disaster from an auto focus point of view, not sure what is happening but the graph looks good, but SGPro carries on and then fails and reverts back to last known good

image

Simon

sg_logfile_af_3_20191019212901.txt (86.7 KB)

Can you provide the main log file?

@Ken

Here you go

sg_logfile_20191019154116.zip (111.8 KB)

@STAstro

You may be exceeding the limits of the auto focus parameters.

Normally you would use something like 7 or 9 data points with enough steps in between to cause the worst HFR calculation to be no more than about 3x the best HFR calculation (ie, best focus). The fact that the curve is still “red” means the routine does not have enough data to be confident in the fit. When it does, it will turn green.

It looks like you have specified at least 17 data points and 50 steps in between. I would recommend trying 9 data points and 125 steps in between. I would disable Smart Focus until you verify it actually helps.

If you have been successfully using these values previous to .313, then this is something Ken or Jared will have to address.

For my Optec Gemini focuser, I use 9 data points and 1800 (very tiny) steps between data points:

image

Charlie

@chasmiller46

Indeed my setting shve not changed, I have always used these settings, my auto focus data points are actually set to 9

image

In previous versions Smart Focus was set to disabled as I have a scope with a central obstruction, so it must have been one of the updates that re-enabled it

The new quadratic routine should have given you an OK for this run. I will check it and see why it was rejected. My guess is the Quality was < .9 (90%) which is the current default cutoff. It does not show but will show in your log. Issues like this will require a little tweaking of the routine. Continuing the run toward the right as the HFRs are getting progressively better is good policy and I think should be the default. However, the quadratic needs a symmetric curve to give reliable results and I have code in there that makes it symmetric. However in this case it does not appear to have been invoked. I will check this out, it can definitely be fixed.

@chasmiller46 is definitely correct in that you need a much larger step interval. I would suggest trying 100. Please send me your logs as you get them. Logs from folks like you that are having problems are the ones I really need to refine this routine.

@jmacon

Thanks, for the info, I have already increased the step size to 100 based on @chasmiller46, so I will see how that works out, I have also re-enabled the “Disable Smart Focus”

This would not have helped in the case you posted above. We can be smarter about the kind of problem you are seeing there… which is created by a shallow curve with weak data on one side (this is part of the lift for SGPro 4.0… to be smarter about getting good data). Doubling your step size will add some depth there… Smart focus or not, the fit quality was less than the allowable tolerance (98% it looks like). The minimum is currently at 99%… but may be adjusted before release. In the meantime, if, for some reason, increasing your step size leaves you with curves you feel good about, but SGPro says are no good, you can decrease the threshold size in sequences and profiles by adding this:

quadratic_fit_min_quality=0.98

Or whatever you feel appropriate, but keep it as high as possible…

1 Like

Where / how do you change the quadratic_fit_min_quality value?

Top secret:

image

Obviously, you type quadratic_fit_min_quality in there instead of the temp comp one pictured above. If you use multiple variables, separate them with a semicolon

Actually, the minimum acceptable Quality for the new quadratic focus routine has been 90%. For those having problems with it accepting your curves, you will probably want to set it around 80%.
90% has worked really well for the dozen or so users who sent us sample log files during the initial development phase of this code. But all of them had fairly good to really good curves. For those with more challenging curves, particularly if you are having focus problems with globular clusters, just try something around 80%. That will do much better for you. Setting it lower that the initial trial at 90% does not really have much effect for users with good curves. The reason for this is that almost all of their curves are coming in around quality > 95%, the vast majority have quality > 98%. But lower quality curves are going to need a lower threshold.

NOTE: be sure you use “quadratic_fit_min_quality=0.80” if you want to set the quality threshold to 80%, the actual parameter is a fraction of 1.

Excellent, about to install new Beta and further testing will take place once it clears here… thank you.

@STAstro, another thing I noticed in analyzing the log from your run, you are focusing on various filters that are not L. You had several focus runs with OIII and one with Ha. These filters will usually give poorer results with focus runs than L does. Particularly the narrowband. I would strongly suggest that you only focus with the L filter and determine what your filter offsets are for the other filters.
With this approach you always forcus with the L filter which gives the best results. All the other filters receive an automatic focus adjustment prior to use.

@jmacon

Ah ok, well I do not use an L filter, I typically use R filter for focusing, however in the sequence after centering it picks the first filter in the sequence to focus on, I guess I’ll have to use the Focus on Specific filter option. I am not concerned about offsets because all my filters are Astronomik filters and are all Par Focal, I verified this with Astronomik

Great. This will help. But I would suggest you double check the parfocal-ness of your filters. My Astrodon filters were supposed to be par-focal so I ignored that issue for a couple of years. Then I checked and found they were off enough to cause some serious out of focus issues with the NB filters.

One step ahead of you there, ran an auto focus against all filters and they all land around the same spot :slight_smile: