Dear all, I have been dealing with a sporadic problem with our Nikon TI2-Eclipse’s perfect focus system for some time now.
My issues always arise when doing very large and long timelapse experiments. Here is my typical scenario:
I am using a 20x air objective (NA 0.75). I have ~500-1000 FOVs. I take an image of all FOVs approximately every 5-10 minutes. I am imaging in phase contrast only. After about 1-1.5 hours, I notice some FOVs are now beginning to exhibit focus loss (PFS status is still showing ON). After a few more hours the entire experiment is defocussed due to systematic drift. Nikon’s own software (NIS elements) reports that the PFS is on and locking.
Some notes:
I am imaging bacteria in PDMS microfluidic devices, a defocus of +/- 0.15 micron is enough to visibly blur the image.
I am imaging a total area of 15mm x 10 mm
There is no stage drift at all.
Temperature fluctuations are minimal (at most +/- 0.1 degree in a 37C incubator)
This seems to happen more often with 20x air than 40x air.
This seems to happen more often when I have very many FOVs.
The only solution is to click “refocus” in ND acquisition and try to fix the bad FOVs, or restart the experiment entirely.
I leave the PFS on between FOVs and between timepoints.
The coverslip is very clean.
The PDMS device bonded to our coverslip does not warp the coverslip much. A constant PFS offset is enough to cover all FOVs in the imaging area.
So far I have been unable to figure out why this is happening. Any help would be very greatly appreciated.
Also, not every objective is compatible with the PFS. You should go here: Objective Selector | Nikon Instruments Inc. and find the objectives you are using. At the bottom of the lens info page, you will find "Ti2-E PFS Compatible”. If it is not checked, then the lens is not supposed to work with PFS. We find they sometimes do anyway, but are often finicky.
Yes I made sure to clean the lens with lens paper before the experiment.
Interestingly most of our objectives are not listed on Nikon’s objective selector. I think they reducd the number of phase contrast objectives sold. We are using a Plan Apo Lambda 20x Ph2 DM NA 0.75 WD 1mm objective. Nikon’s NIS Elements lists it as PFS compatible when we select it.
We also had a non-PFS objective which we were able to “trick” into working with PFS, but this current one is certainly not one of those, and I think should be compatible with the Ti2-E (after all, Nikon sold it to us along with the scope!).
I think it might be useful to see some images/videos of the problem. You state that 150nm is enough to notice the drift - but have you measured the total drift offset over your time domain? You can find this by zeroing the focus drive before you correct the focus after the drifting has occurred.
It seems odd to me that you would expect the PFS system to be accurate to 150nm when the lateral resolution of this objective at 870nm (LED in PFS) is only ~700nm. The odds that PFS would be reproducible at 150nm would be very low.
I think 150nm is probably not super accurate. 150nm is when I begin observing changes in the image, but I would say that major defocus probably happens at around 300nm.
Thank you for your suggestions. I will extract the metadata from an experiment I recently captured and check the total drift of the Z position of the objective over time.
This is just based on some experience. When the stage is stationary for instance, I am able to disable the PFS and move the objective up and down quite a bit (all the way to +/- the entire PFS range), and upon re-activating the PFS have the objective snap back to a position which produces the exact sharp before it was moves.
The inaccuracy, as I have just found, comes from if I disable the PFS and, rather than making large movements of the objective, actually make miniscule adjustments (+/- 0.5 micron). Re-enabling the PFS after these adjustments actually does not snap the objective back, but rather hardly moves it at all.
I understand your comment about the lateral resolution, but that ought not to affect the position of the maximum intensity of the PSF’s IR beam hitting the line-CCD right? Unless with a 20x objective the beam is so broad relative to the movement I want that one cannot measure that maximum to within the required accuracy here? To be fair I did today find a paper which states that Nikon’s PFS is only accurate to within 1/4 of the objective’s DoF, but since I am using a 20x objective I would expect the DoF to be large, and so 1/4 DoF accuracy to be plenty.
My intuition is that you’re right, I am probably expecting too much from PFS with this objective, however what would explain a greater accuracy when snapping back from a large distance vs snapping back from a very small distance? It is almost as if at small distances the position of the objective is controlled by a proportional-only controller, not reaching its setpoint. (I did confirm in NIS-Elements that the Z stage is set to use closed loop control, and they quote a step size of 20nm). Unfortunately there are very few details I can find online about exactly how the Z position is actually controlled.
Edit: indeed it even seems to make a difference what direction the PFS is focussing from. If from above the focal plane, it does a worse job of snapping back to where I want it, if from below, it is far more consistent.
This sounds frustrating! I don’t have a direct answer but will share a few anecdotes from PFS struggles in the past in hopes they help your brainstorming.
To be sure we’re on the same page, for a specific Z position of the objective, PFS setting is dependent on the refractive index difference between the glass coverslip and what is immediately on top of the coverslip.
I suspect there are two things happening:
Something in some of the wells is causing a shift in the PFS position (obviously, see below on exploring the cause for this)
The software is updating the Z position after each image. Because the PFS in those wells is landing on an out of focus Z, that OOF Z becomes the updated starting Z. Eventually the updated Z falls outside the PFS range and all wells go out of focus.
Working around the problem:
Will things stay in focus if you don’t update the Z position? The risk with this is if there’s gravity drift of the objective over time the system won’t correct for that.
If you have time in the experiment, you could macro the software to turn off PFS, run a quick image based autofocus (start w 5um range, 2um step), re-engage PFS at each position. I’m guessing you don’t have this time for the real experiment, but maybe it would be helpful for troubleshooting what’s going on.
Identifying the problem:
-I’ve definitely seen PFS setting change when the SAMPLE RI across the entire field of view changes by even a little bit. Anecdote: Many moons ago I had a user working with tissue culture cells on glass imaging with DIC at 40x air or 60x oil. They would start with sparse cells (FOV was <~40% cell) that would divide and become confluent (FOV >~60% cell, numbers VERY approximate). The difference in percent FOV covered by cell membrane introduced minor changes to the PFS position, presumably because the RI difference between glass and water is not the same as the RI difference between glass and the cell membrane. In that case, the change happened once and remained in the not-quite-in-focus position, unlike your problem where it just keeps getting worse. I identified this as the cause because it was literally the only thing different and by checking the PFS value for different areas of the same sample that had different cell coverage.
Some ideas for figuring out if that’s what’s happening:
Is there anything about the FOVs that first go out of focus that are similar to each other but different from the rest?
After the system has drifted during your experiment, if you turn off the PFS, refocus and reactivate the PFS, what is the PFS setting value relative to before? This might hint at a change in the sample that’s not visible by eye.
If you refocus after the 1.5 hour drift, does it continue to drift in the same way, drift less, stabilize? Do the positions that initially go out of focus stay the same or are there new ones?
A few other things that come to mind, acknowledging you’ve likely already tried several:
Check that there isn’t dust on the PFS mirror
Be extra-super sure the objective side of the sample is 100% clean immediately before you image. Lens cleaner is best for salt and fingerprints, organic solvent for anything really goopy (like adhesive). And always check for dust.
If the PDMS is part of the FOV, try to determine if there’s anything that could change the RI difference between the coverslip and the PDMS. I don’t have experience with PDMS to provide specific suggestions, but some non-specific ideas are evaporation of some PDMS component, temperature change during the experiment, absorbance of media from the samples, etc.
Anecdote: Agar pads change RI as the water evaporates. Putting aa chamber around the samples with an agar pad and including some extra wet kimwipes helps minimize evaporation and stabilizes the RI.
My guess is it’s more of a problem with higher sample numbers just because of statistics–more positions provides more opportunities to find imperfections.
The 20x v 40x error rate difference sounds familiar but I’m not coming up with a good explanation of why.
I hope this provides you with some ideas to test out. Feel free to reach out if you want to work through ideas for controls. Good luck!
The only thing which will change in the image is the size of individual cells in these trenches, which are probably <10% of the FOV, and on average there is no systematic change in the image as cells grow and divide and get washed away.
I am not sure what you mean here. I explicitly do not redefine Z every time the PFS triggers before taking an image of an FOV. I only supply X,Y, and PFS offset. NIS Elements does have a setting to redefine Z, but I do not turn it on. My understand is that this will maintain a constant physical distance between the objective and coverslip, allowing Z to change freely as needed to maintain this condition.
I have tried this, and you are right, I do not have time for it. I typically require 3-5 min time resolution and it is not possible with ~500-1000 FOVs. When I have accepted a lower time resolution, then yes this does work at maintaining a focus (but then I am at the whim of software autofocus inaccuracy).
Not that I can see. It seems to be happening everywhere. All FOVs are pretty much identical. However I have noticed now that the defocus might be cyclical in nature. And that it’s not actually drifting, it’s just being inaccurate, and only focussing correctly very few times. Here is an example from an experiment last night https://youtu.be/qDmOpFUULl8 The total time is about 10 hours in this video.
What do you mean by “what is the PFS setting value relative to before”? If I pause the experiment in a blurred frame (which was previously in focus a few hours ago), turn off the PFS, move the objective a bit, and then re-enable the PFS, then the focus will lock back to the blurry plane (with that FOV’s PFS offset). With a bit of random coaxing it might focus a bit better.
This is interesting. I have tried this and it seems to be completely random. What I do know is:
The defocus will start eventually.
If I stop it and refocus the FOVs, this will buy the experiment a little bit of time, maybe even many hours, but it will eventually start to defocus again.
I will try and access this. Thank you.
We are making sure they are as clean as possible. Generally our coverslips need to be extremely clean anyway, since we are bonding microfluidic devices to them.
Most of the FOV is PDMS, a small amount is media flowing through channels. The RI of our PDMS is around 1.414, and I think our glass is probably ~1.5. I have actually tested the PFS behaviour on parts of the coverslip outside of the PDMS boundary, in case multiple reflection was causing there to be >1 PFS locking plane, but there was no difference.
It might be something to do with this. I’ve only started to observe this phenomenon when beginning to image hundreds of FOVs. In our very simlpe experiments where we do not require the stage to move much, and only image a handful of FOVs (10-50), we very rarely see any focus loss. In these new ultra high throughput experiments I’m trying to do, the stage is pretty much always moving, scanning a much larger area, there is not even a gap between timepoints. I wonder if this could have anything to do with it. However I have made sure to optimise the layout of my FOVs to avoid huge jumps in XY.
Yes this issue does happen with 40x, there is defocus, but it’s not as bad as with 20x (although it still renders many of my frames unusable in 40x).
I’m going to focus on this before addressing anything else:
I have actually tested the PFS behaviour on parts of the coverslip outside of the PDMS boundary, in case multiple reflection was causing there to be >1 PFS locking plane, but there was no difference.
When you say there was no difference, do you mean it still lost focus even when it was just glass-air?
Yes, focus loss (I just observe a small imperfection on the coverslip and see how its image changes. Additionally there’s no large difference in the PFS offset, implying that the PFS is locking to the same reflective plane.
Additionally, today I did a test on a dry mother machine, so no fluid flowing through it, no cell growth, just a blank device with nothing happening, and I observed the same behaviour in both 40x and 20x when imaging a very lage number of FOVs continuously. So I’m beginning to think it’s to do with this. But I can’t imagine how excessive stage movement would result in this behaviour. When imaging a small number of FOVs the effect is reduced, sometimes almost entirely.
I’ve also now tested several things when doing my high throughput experiments, including:
Adding a 0.1 second delay before imaging after moving to a new FOV
Turning off PFS when moving the stage
Explicitly adding a macro in the imaging loop giving the microscope up to 8 seconds to wait for PFS to focus (suggested by @ARC via email correspondence).
I’m still thinking part of it is that something about the PDMS is changing. Can you encase the PDMS in something impervious, like a small cap?
Have you repeated a small position time series on the PDMS-only sample? I can’t remember if you’ve already stated this, but be sure to adjust the delay/Interval so that the time difference between the first position for each round is similar to that difference when you’re running 500-1000 positions so that total time is duplicated.
When you ran it on the glass-air (not sample, no PDMS chamber) were you doing the full 500-1000 position time series?