Update There is currently a big update coming which will feature lineage tracking ability, full texture generation within cells, spatial fluorescence (membrane, nucleoid, ribosome, etc), and more advanced image simulation models. It will also (hopefully) bring about full modularity of SyMBac so you can plug in individual parts of the pipeline to your own workflows. Additionally, preliminary support for using SyMBac entirely from Napari is coming. You can follow the progress in the full_rework
branch.
Read the paper: Synthetic Micrographs of Bacteria (SyMBac) allows accurate segmentation of bacterial cells using deep neural networks , Georgeos Hardo, Maximillian Noka, Somenath Bakshi
[New! Try the Colab version] (please let me know if you run into issues)
SyMBac is a tool to generate synthetic phase contrast or fluorescence images of bacteria. Currently the tool only supports bacteria growing in the mother machine, however support for bacteria growing in monolayers (and maybe even biofilms!) is coming.
Because you're sick of generating your own training data by hand! Synthetic images provide an instant source of high quality and unlimited training data for machine learning image segmentation algorithms!
The images are tuned to perfectly replicate your experimental setup, no matter what your microscope's objective is (we have tested 20x air all the way to 100x oil), no matter your imaging modality (phase contrast/fluorescence), and no matter the geometry of your microfluidic device.
Additionally,
That is up to you. SyMBac is not a machine learning tool. It is a tool to generate unlimited free training data which accurately represents your experiment. It is up to you to train a machine learning network on these synthetic images. We do however provide example notebooks for how to train a U-net (as implemented by DeLTA).
Please make sure you have an NVIDIA GPU and a working installation of CUDA
and cudNN
. If you don't have an NVIDIA GPU then the convolution will default to the CPU, and be very slow.
SyMBac is meant to be run interactively (in a notebook + with a small Qt/GTK intWWerface), so make sure that you are running this on a local machine (you should have access to the machine's display).
pip install SyMBac
Or to install the development version, run:
pip install git+https://github.com/georgeoshardo/SyMBac
Activate the Jupyter widgets extension. This is needed to interact with slides in the notebooks to optimise images.
jupyter nbextension enable --py widgetsnbextension
Check the version of CUDA
you have installed using nvcc --version
and install the appropriate version of cupy. For example, if you have CUDA 11.4
you would install as follows:
pip install cupy-cuda114
If you installed CUDA on Ubuntu 18.04+ using the new Nvidia supplied repositories, it is a real possibility that nvcc
won't work. You need to run nvcc
from the binary folder of where your cuda installation is.
See FAQs "Do I need to have a GPU?"
get_sample_images()["E. coli 100x"]
from SyMBac.misc
for an example image.ContextException: Could not create GL context
when trying to visualise my simulation in real time
conda install -c conda-forge libstdcxx-ng
, and if you're on Ubuntu/Debian sudo apt install libgl1-mesa-dri