Long-term time-lapse imaging of biological samples requires correcting for focal drift, which would otherwise gradually push the sample out of focus. We present a software-based method that eliminates this time-dependent blur using only a motorized Z-drive, with no additional hardware. The method relies on imaging marks made on the side of the coverslip opposite to the sample. We provide a Beanshell script implementation, evaluate its performance across multiple objectives, and benchmark it against a hardware autofocus system, finding comparable results. Finally, we demonstrate its effectiveness in live imaging of growing bacterial colonies.
Cite
@article{arxiv.2511.20890,
title = {A software-based focus system for wide-field optical microscopy},
author = {Ilyas Djafer-Cherif and Bartlomiej Waclaw},
journal= {arXiv preprint arXiv:2511.20890},
year = {2025}
}