Thanks to visit codestin.com
Credit goes to Github.com

Skip to content

maurosilber/SMO

Repository files navigation

PyPi License PyPi Conda Paper

SMO

SMO is a Python package that implements the Silver Mountain Operator (SMO), which allows to recover an unbiased estimation of the background intensity distribution in a robust way.

Citation

To learn more about the theory behind SMO, you can read:

If you use this software, please cite the peer-reviewed article.

Usage

To obtain a background-corrected image, it is as straightforward as:

import skimage.data
from smo import SMO

image = skimage.data.human_mitosis()
smo = SMO(sigma=0, size=7, shape=(1024, 1024))
background_corrected_image = smo.bg_corrected(image)

where we used a sample image from scikit-image. By default, the background correction subtracts the median value of the background distribution. Note that the background regions will end up with negative values, but with a median value of 0.

A notebook explaining in more detail the meaning of the parameters and other possible uses for SMO is available here: examples/usage.ipynb Open In Colab.

Installation

It can be installed with pip from PyPI:

pip install smo

or with conda from the conda-forge channel:

conda install -c conda-forge smo

Development

To set up a development environment:

git clone https://github.com/maurosilber/SMO
cd SMO
pixi install

Code style is enforced via pre-commit hooks with lefthook.

About

Robust and unbiased estimation of the background distribution for fluorescence microscopy.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages