Official Request for Improved Autofocus in SGP

I think some people are missing the point on what’s been deemed HFR triggered AF. The original post suggesting to use the image was actually more about NOT focusing when it’s not needed. You could still have all of the existing triggers for when to focus and look at the image to decide if they should trigger or not. If the image meets the pass criteria, you’d skip the focus. If it fails, it doesn’t matter why it fails, the focus runs. But it would have run anyway without the option that was requested to check if the image still looked good.

Thanks,

Beo

1 Like

I have been a bit perplexed by the many comments on SGP’s AF routine. Overwhelmingly, my imaging has been with a 14.5" iDK which has proven to be extremely stable focus-wise. Still I have had invariable success with SGP’s AF.
Only exception has been with a globular cluster in the center of the frame. Usually that is fine too but, on occasion, I have had to shift off-target to focus when imaging globulars.
So, colour me confused as to all the difficulties reported here and, especially, on “the other thread.”
One thing, thoroughly perplexing to me is that some seem not to be binning focus exposures. Why? My camera has a full frame download of 28 secs! Does anyone have worse? Still, I bin focus frames at 3X3. A full run of nine 5 sec focus frames takes 2 mins and 20-something seconds.
Sure, faster would be nicer but it confuses me when I read of at least one user reporting ten minute focus runs. Bin the focus frames, for heaven’s sake!

1 Like

i generally have pretty good success but i do find that if i start the night too far out of focus (like previous night’s last filter was narrowband but current night’s first filter is broadband + a change in temperature) that SGP’s routine will get lost. when too far out of focus it seems to pick up hot pixels and ignore the (rather large) stars.

but if initial focus is close, then it works every time. this problem is a bit of a nuisance and makes the system a little less automated than i would like, but for me it is not a showstopper.

so yeah, i too am a bit confused over all the hate for the AF routine in that other thread… i agree it can be improved, especially with respect to outlier rejection when far out of focus, but overall it works OK for me.

3 Likes

When Focuslock was first postulated, I was concerned about how it accommodates filter offsets and the quality of focus mechanisms, in so much that all my premium focus mechanisms have some lateral shift when moving, certainly more than my RMS guiding error. How do you find it in practice?

With FocusLock, I believe you can constrain the movement to between frames. Would’t this address your issue ?

Like Terry, I too am a bit bemused by the perceived deficiencies, although I do appreciate that I am only using refractors.

However, please do not interpret this comment as meaning I am opposed to development or recitification of issues eg for those with long FL scopes or COs. I simply wanted to present a view from a long time user who has not experienced difficulties, including now running two remote rigs.

For globular clusters, Steve and I have found reducing sub exposure time during AF has helped, eg from 7 or 8 secs down to 3 or 4 secs with a TEC140/QSI690 at F7 and 0.75”/px helped significantly on M15 recently.

We all know that SGP’s AF works for people, I’m one of them, but I also have huge issues with 1 of my FSQ’s and so have other people, please let this thread not fall into camp’s, I would suggest that people with real issues (me included) provide quantifying data so the developers can analyse and enhance the routine. This thread is about improvements, if all is working for you :+1:

Agreed Yves :+1:

Filter offsets are pretty simple and similiar to SGP, once you figure out the amount you can program it into the Focuslock GUI so when the filter is used FL will keep the “astigmatism” the correct amount for the guide camera allowing the main camera to be in focus for that filter. Not sure how that works if the offsets are very large.

That said, I do not actively use offsets since my filters are pretty parafocal and I image at f/8 so the CFZ is large enough to handle any slight differences. I mostly do LRGB and made sure the L was the base for focus with the setup. I really have not noticed the RGB being out of focus. But that will likely change as I am putting together an f/4 imaging Newt. So I can come back and comment on the offset with some more experience.

My focus mechanism is a Optec TCF-S and there is little lateral shift. But observing FL in action many times over the last couple of years, the focus shift is pretty much in the same direction(temp drift) and the step amounts to maintain focus are usually pretty small for my setup (5-15steps?) I do have SGP stamp the focuser positon on all my files, so it is easy to see the progression through the night. Some nights are pretty stable and the position floats around in 50-step range. Even then, I do not have ruined images due to focus and PHD handles it well with my RMS staying low to give nice round stars.

The only pain to the entire setup is when I remove the main camera or guider. Then I have to get them parafocal again. But it does not take very long really. I was using FocusMax to focus the main camera because I couldnt get SGP to work well. But now I have tweaked the parameters and use SGP to focus most the time. Focusing the guider is easy since the ONAG has a focuser built in and you adjust until the FL focus indicator turns green.

All of this assumes you have the backspace to handle the ONAG too, some scopes it will just not work. There is the OAG version too (Lacerta) for small backfocus situations, but I do not have it and cannot comment how well it works. Though I will likely get it since I will need a OAG for the Newt.

Hope that answers your questions. If not, let me know.

Are any of the folks following this thread using both of the following features of auto-focus at the same time:

  1. Auto adjust focus per filter
  2. Temperature Compensation

Does this work for you? It fails misrably for me. Many tests on two different scope/camera combos.

I am not sure that I have a confirmation from the developers that this is an acknowledged bug and that it is a high priority to fix it.

It is causing major problems for me with the auto-focus routine. For years this was not an issue for me because my Baader filters were enough par-focal for me to just use L for focusing. When I shifted to Astrodon filters, the focus range is 75 steps, which is about 3 focus intervals, a huge difference. I can’t successfully mix different filters for the same target. This has forced me to focus for every filter then take many images with that filter. This means I have to run the focus routine for NB filters, which we all agree is very problematic. Particularly when the auto-focus routine accepts terrible data points as legitimate, and then moves the focus to some totally bogus position. We badly need a measure of focus quality so the routine will do nothing if the curve quality is poor.
See my thread “Auto adjust focus per filter - failure to work”

Yes, there is a check box in the options to “only focus between exposures”. Honestly I have not noticed my guiding being any worse by allowing it to focus whenever. But I can check the box to see if there is any difference. Honestly the entire guide loop of exposure, download, analyses, correction is really short thinking about it. Most people are probably using 1-5s exposures so the rest adds maybe 1-2s? Looking at my FocusLock plots, the focus changes on the timescale of every few minutes I think. So it is not like it is constantly correcting, at least I hope it isn’t!

I run an F/3.8 Newt and I purchased the OAG Lacerta version. I could not get it to work successfully so I returned it. The insert in the light path that makes it work also reduces the FOV and light intensity, which I was very annoyed with. It was not nearly as sensitive in detecting the perfect focus position as I had hoped, not really any better than using the SGP routine. Specifically what did not work for me was getting the software to actually detect the focus changes. I played with it for a couple of hours then gave up.

I would like to hear of any other users experiences with the Lacerta. If it works really well for some, I would be willing to try it again. I can’t say that I tried that hard to make it work. When the developers release a new version of the auto focus routine that implements some of theses suggestions and fixes the reported bugs, I do not see a need to try Lacerta again. With improvementes and bug fixes it will be amazingly effective.

It is important to understand that there are some very different use cases these days than have been used in the past. With big, slower systems like this, you may only focus once every hour or so, so a several-minute run might not be that big of an issue.

Keep in mind that today there are a lot of CMOS imagers, using smaller systems, often refractors or camera lenses that are more complex optically, which can have a much greater focus shift over time than big, simple and stable systems. CMOS imagers may also expose on the order of tens of seconds, rather than tens of minutes. Many of us also have very large temperature gradients from the time the sun sets to minimum temperature each night, as much as 50-60 degrees or more. We may need to focus every few minutes early in the evening, and no less often than every 30 minutes, to deal with the way our scopes or lenses handle the cooling and how our focus shifts.

In this context, any focus run that takes several minutes to complete (and note, this IS with binning, and this is with CMOS cameras that have very fast downloads compared to classic CCD cameras…instead of 20-30 second download times, ours are usually a couple of seconds) is a focus run that takes too long to complete. Frequent focus is additional overhead on top of frequent dithering, frequent frame downloads, so it is a constant march towards finding ways to optimize and minimize our overhead time, so that we can spend most of our time exposing the night sky, rather than most of our time focusing, dithering, and downloading frames.

FTR, binning or not does not really have any impact on frame download time with CMOS cameras. In my case, with SGP’s native ZWO camera support, it takes about 1.2 seconds on average to download a frame…1x1, 2x2, 3x3…it doesn’t really seem to matter.

1 Like

Since when are refractors complex optical systems? The Petzval designs aside, which this comment would be valid for if that were the only system in scope, but the vast majority of refractor imagers don’t use those systems. Complex optical systems would be RC’s, for an example of “complex”.

No disagreement, but a solid solution really should not care if you are using a CCD vs a CMOS camera, nor should it be skewed in either direction as it does not have to be. Example:

Take your CMOS camera and your Lens, and set up your system. Download FocusMax (either the free 3.8 version or the 4.0 version which has a trial for it) and install it. Run through its calibration process of curve definition. Now focus with it. Now take the same gear into SGP and do the same thing. Compare the results, both in terms of focus quality and time to achieve that end.

You dont have to compare the results to some ancient CCD technology though. Take a well made FLI 16200 sensor. In 12Mhz focus mode it downloads frames just as fast as the CMOS camera. The same issues are found when using SGP vs other methods of focusing. I can do the same test with FocusMax, and find the same results.

The solution needs to come in a more comprehensive approach to focusing that is applicable across technology (CMOS vs CCD) boundaries. It is possible, there are other solutions that do this today beyond FocusMax. That should be the ask here, and it should not be divided in camps of CMOS vs CCD. It does not have to be.

I never said it should be divided. I never said the AF solution shouldn’t support any kind of system. You are inferring these things out of nowhere.

I simply wanted people who were asking why anyone is having problems with AF, when they themselves do not, to understand that there are other needs beyond the needs of classic CCD+big reflector type systems (that are often quite stable when it comes to focus), that there are different kinds systems that behave differently in different kinds of environments. CMOS systems are a more recent thing in the market, and they often have different behavior than classic CCD based systems.

And, Bill, I’m not interested in integrating a third-party product. I don’t want to have to pay more money for another third party product…I’m not interested in seeing SGP become more like Voyager, or whatever your product of the week may be. I’m more interested in the single integrated “with a kitchen sink” product that SGP is. I have FocusMax 3.x, have had it for quite some time. It doesn’t matter what it can do or how. The only thing that matters to me here is what SGP can or cannot do with AF, and how it could do AF better. I think the Main Sequence guys are already more interested in enhancing their own product rather than integrating third party products anyway.

2 Likes

Jon, @focus3 is a product of Software Bisque. FocusMax is an industry standard for focus of unattended equipment. These are not the products of the week, as you said. I get that you find the Italian software to feel like its some new thing, but it was written in 2012. That is about 7 years ago. Regardless of any of that… there is a good need for SGP to get some better focus capability, and I don’t think its useful at all to downplay other methods, especially those that YOU have touted as being superior.

Don’t make me reveal the truth. Be realistic here.

I get it Jon - Speed and accuracy. Some of the very fast systems are particularly sensitive.
Some ideas (some already mentioned, some new):

  • change the spread/number of points dynamically - wider for the initial focus and then fewer points and over a narrower span later on, when tracking focus during the night
  • ROI
  • 3 - point quadratic fit rather than “v” for quick results
  • focus training wizard, to establish filter offsets - saves a lot of grief with waiting for NB exposures
  • HFR % threshold trigger (like mass detection on PHD2)
  • exposure control - to regulate star detection, for instance throttle back if too many stars detected on first AF run
  • star selection - I notice that the detected stars change with focus (more detected closer to focus)- some way to use same stars throughout might improve robustness
1 Like

Excellent list Buzz. I would add the following to this list:

  1. Focus Quality Measure, with options for action to take if Quality is unacceptable.
    Possibilities for unacceptable focus:
    …a) rerun X times
    …b) use focus position indicated by the current temperature on the best fit line. This requires the user specify what the best fit line is, ie. a slope and offset.
    …c) leave focus where it is

  2. Robust procedure for eliminating bad focus points. This could be just ignoring that point, or performing a rerun on that point if it can be determined as a bad point immediately. Obvious cases are a value of zero (common when conditions are bad), or there are enough previous points to determine this point is bad.

  3. Some process to permit a successful focus run for targets such as globular clusters that often fail. Possibly limiting the selected stars to small stars would allow many of these to succeed. This would also mostly eliminate flagging 2 or 3 stars as a single star. This should be avoided because it distorts the accuracy of the HFR, which changes over a much smaller range than a single star does as the routine goes from out of focus to focus.

1 Like

Hi,

Good to see that the focus routine is getting some attention. A couple of years ago I was fully committed to SGP, however, I was forced to abandon it after migrating my imaging OTAs from refractor to fast Newtonians (12 inch F/4 and 160mm F/3.3). I never got consistent results with fast-obstructed systems, no matter how much I tweaked the routine.

I moved to FocusMax and after passing the initial burden I got excellent and consistent results for any of my systems (CMOS/CCD + Refractors/Newtonian/CDK).

I have requested several times to add support for FM on SGP’s forum and the idea hasn’t been welcomed by most users, the main objection is the inconvenience of running a separate program (multiple windows, a messy interface, etc). I never understood this concern since SGP already uses 3rd party applications for plate solve and autoguiding. The other objection is price, FM is not free, this true for the latest versions but there is a free fully functional version available.

I’ll be great if FM support is added to SGP, not just to give more options to the users but also to allow us to easily asses SGP’s built-in routine in terms of quality and speed.

Clear skies,

Jose

Hi,

Interesting how this hole topic is evolving when it comes to the magics of AF!
I read many, many valuable ideas that could be good proposals for future success in AF robustness! So I’m on the list, too.

One thing no one mentioned: Often it’s all about Backlash Compensation!

Many Absolute Focusers claim to be “absolute” - believe me, they aren’t! And that’s because of “good old” gear-backlash. The often claimed medicine is “to overshoot” which I cannot sort into this “precise” discussion regarding “AF-Mathematics”.

I think SGpro must face practice and not theory! There are programs out there - I even don’t dare to say it’s AstroArt - which can calculate the ACTUAL Backlash Compensation (load status of the focuser (push,pull,cam-head weight,…) has implications on the backlash of most “Absolute Focusers”).

I like the variety of given ideas here in this thread, but perhaps the backlash thing should also be discussed.