Skip to content

Roth-Lab/merfish-segmentation

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

95 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MERFISH Nuclei Segmentation

Segmenting images

Creating a conda environment

Create a conda environment from the environment.yml file: conda env create -f environment.yml. Unfortunately this may not work because the environment.yml file sometimes doesn't work cross-platform. In that case, use pip to install StarDist. There are platform-specific troubleshooting instructions for installation here.

Script usage

segment.py [-h] --model_num MODEL_NUM --img_dir IMG_DIR [--img_ext IMG_EXT] [--out_dir OUT_DIR]

For --model_num, choose one of the following:

  • 1: StarDist Pretrained model trained with a subset of 2D fluorescent images from the Kaggle 2018 Data Science Bowl dataset with no additional training
  • 2: StarDist Model 1 trained with 5 additional U2OS nuclei images
  • 3: StarDist Model 1 trained with 10 additional U2OS nuclei images
  • 4: StarDist 5 U2OS nuclei training images, same as Model 2
  • 5: StarDist 10 U2OS nuclei training images, same as Model 3
  • 6: StarDist All 26 U2OS nuclei training images
  • 7: StarDist All 26 U2OS nuclei training images Random flip/rotation
  • 8: StarDist All 26 U2OS nuclei training images Random intensity change
  • 9: StarDist All 26 U2OS nuclei training images Random Gaussian noise
  • 10: StarDist 26 U2OS readout probe channel training images
  • 11: StarDist 26 U2OS 2-channel images with nuclei and readout probe channels
  • 12: StarDist Model 3 trained with 7 4t1 nuclei training images
  • 13: SplineDist All 26 U2OS nuclei training images

Accessing nuclei masks used for training models

The nuclei masks are on the numbers cluster at the following path: /projects/molonc/roth_lab/archive/merfish-masks.

Within that directory are the directories u2os and 4t1 that contain all the files generated by QPath (see: https://github.com/stardist/stardist#annotating-images for how they were generated). The ground_truth directory in each of those directories contains the directory images which are the original nuclei images, and masks which are the manually labelled nuclei masks. To modify these, open the project.qpproj file in QPath. It may prompt to update the paths, which can all be pointed to images in the */ground_truth/images directory. Then the same steps in the stardist github README above can be taken to export the updated masks.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jupyter Notebook 95.0%
  • C 3.0%
  • C++ 1.5%
  • Other 0.5%