Skip to content

salamullahuet/segmentation-projects

Repository files navigation

segmentation-projects

Following segmentation strategy is foolowed in this repository. The focus was on cell detection/segmentation of microglia and TAMs. We analyzed microglia and TAMs in four areas of the right brain hemisphere (midbrain, corpus callosum, tumor microenvironment, and intra-tumoral areas) and identified three main cell types. We manually marked 250 highly ramified cells in the midbrain using Napari software. The selected cells for our ground truth, was trained with a CNN (Convolutional Neural Network) model and TensorflowTensorFlow to achieve an F1 score of 0.83 for pixel position. The tiff file format uses 80 frames for both the raw images and their masks in our dataset. Our CNN architecture consists of an encoder (contracting layers) and decoder (expanding layers) framework, which consists of two types of layers: contracting layers which use general convolutional layers for feature extraction from the cells, and expanding layers, which employ transposed 2D convolutional layers to localize cell areas in an image. The CNN model undergoes three training stages by enabling and disabling augmentation features while CNN is trained. Phase 1 Training: During the initial training period, only images containing brain cells were considered. Since the 400 × 400 pixel sub-images of the raw images/masks are equally divided, only the sub-images containing brain cells are considered by the filtering. Phase 2 training: The CNN model is trained on the filtered dataset in phase 2 training using randomly generated rectangles and ellipses drawn on the cells in the sub-images using the image drawing module of the Python image library (PIL). Phase 3 Training: The entire dataset is used for training in the latter stage of the process, with augmentation and random ellipses and rectangles for cell features.

This code is implemented using google colab.

Releases

No releases published

Packages

No packages published