Giter Club home page Giter Club logo

go-nuclear's Introduction

Plant Nuclei Segmentation Pipelines

This repository hosts the code and guides for the pipelines used in the paper A deep learning-based toolkit for 3D nuclei segmentation and quantitative analysis in cellular and tissue context. It is structured in to four folders:

  • stardist/ contains a 3D StarDist training and inference pipeline, run-stardist.
  • plantseg/ contains configuration files for training and inference with PlantSeg.
  • cellpose/ contains scripts for training and inference with Cellpose.
  • evaluation/ contains modules for evaluating the segmentation results.

Table of Contents

Tools and Workflows

StarDist

See run-stardist's README.md for more details.

This is one of the most important contribution of this repository. If your nuclei are more or less uniform in shape, please consider using the run-stardist pipeline in this repository. It generate separate and round instance segmentation masks for your nuclei images.

  • The code and tutorial for running StarDist inference is in the stardist/ folder
  • The pretrained model is automatically downloaded during inference (also available at BioImage.IO: StarDist Plant Nuclei 3D ResNet)
  • An example of segmentation results is shown below.

stardist_raw_and_segmentation

PlantSeg

See PlantSeg's README.md for more details.

If your nuclei have irregular shapes, please consider using the PlantSeg pipeline. It generates instance masks for your nuclei images regardless of their nucleus size and shape.

  • The code and tutorial for running PlantSeg inference is in the plantseg/ folder
  • The pretrained model is automatically downloaded during inference (also available at BioImage.IO: PlantSeg Plant Nuclei 3D UNet)
  • An example of segmentation results is shown below.

plantseg_raw_and_gasp_segmentation

Cellpose

See Cellpose's README.md for more details.

  • The guide for running Cellpose inference and training is in the cellpose/ folder

Data

Training Data

The training data is publicly available on Zenodo at [TODO](to be published after paper submission).

An example of the raw image:

raw

Some key information about the training data is listed below:

original_voxel_size = {  # z, y, x
    1135: [0.28371836501901143, 0.12678642066720086, 0.12678642066720086],  # validation
    1136: [0.2837183895131086,  0.12756971653115998, 0.12756971653115998],  # training
    1137: [0.2837183895131086,  0.1266211463645486,  0.1266211463645486 ],  # training
    1139: [0.2799036917562724,  0.12674335484590543, 0.12674335484590543],  # training
    1170: [0.27799632231404964, 0.12698523961670266, 0.12698522349145364],  # training
}  # [0.2837, 0.1268, 0.1268] is taken as the median

original_median_extents = {  # z, y, x
    1135: [16, 32, 33],  # validation
    1136: [16, 32, 32],  # training
    1137: [16, 32, 32],  # training
    1139: [16, 32, 33],  # training
    1170: [16, 29, 30],  # training
    'average':
}  # [16, 32, 32] is taken as the median

Note for training Cellpose: The best image form for training StarDist and PlantSeg models are the original forms, i.e. the linked dataset is the one that provide the best results. However, to train Cellpose which only takes 2D training data, the images are prepared to be 2D slices of the rescaled isotropic 3D images. The 2D slices includes all XY, XZ and YZ slices ordered randomly by a random prefix in the file name. The 2D slices are saved as TIFF files.

Preparing Data for Inference

Both HDF5 files and TIFF files can be directly used for both run-stardist and plant-seg inference. Go to the respective folders's README.md for more details.

Cite

If you find this work useful, please cite our paper and the respective tools' papers:

@article {Vijayan2024.02.19.580954,
  author = {Athul Vijayan and Tejasvinee Atul Mody and Qin Yu and Adrian Wolny and Lorenzo Cerrone and Soeren Strauss and Miltos Tsiantis and Richard S. Smith and Fred Hamprecht and Anna Kreshuk and Kay Schneitz},
  title = {A deep learning-based toolkit for 3D nuclei segmentation and quantitative analysis in cellular and tissue context},
  elocation-id = {2024.02.19.580954},
  year = {2024},
  doi = {10.1101/2024.02.19.580954},
  publisher = {Cold Spring Harbor Laboratory},
  URL = {https://www.biorxiv.org/content/early/2024/02/21/2024.02.19.580954},
  eprint = {https://www.biorxiv.org/content/early/2024/02/21/2024.02.19.580954.full.pdf},
  journal = {bioRxiv}
}

go-nuclear's People

Contributors

qin-yu avatar

Watchers

Kay Schneitz avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.