htyangs / Deep-Learning-for-Dendritic-Spines-Detection

Benchmarking Yolov2, Faster-RCNN and Shape-Priors-CNN on dendritic spines detection

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Deep-Learning-for-Dendritic-Spines-Detection

Benchmarking Yolov2, Faster-RCNN and Shape-Priors-CNN on dendritic spines detection

Please read the report for more details

1-Faster-RCNN:

capture reconstruction

The model is already trained.

  • The final weights are in Faster-RCNN/inference_graph.

  • The results are in Faster-RCNN/results

  • To re-calculate the predictions on the test set run F1_score_and_predictions.py

  • To recalculate on other images change the path to the folder containing the images.

2-SP-CNN:

capture reconstruction

capture reconstruction

run the jupyter notebook. Note that the train images are not complete (due to size issues), but they will give you a sense of the overall pipeline.

3-YOLOv2:

Testing:

  • create a text file and name it test.txt. this file contain the path to images you want to test on. Get inspired by an already existing test.txt and train.txt to get an idea.

  • To calculate the map, f1-score... at a specific threshold (say 0.5, change it to other values for precision-recall graph) do the following:

From darknet folder run :./darknet detector map cfg/obj.data cfg/yolo-obj.cfg backup/yolo-obj_last.weights -thresh 0.5

  • To test on a specific image (say the image's name is img.png) do the following:

From darknet folder run: ./darknet detector test cfg/obj.data cfg/yolo-obj.cfg backup/yolo-obj_last.weights img.png -thresh 0.55

References:

About

Benchmarking Yolov2, Faster-RCNN and Shape-Priors-CNN on dendritic spines detection


Languages

Language:Python 68.1%Language:C 21.5%Language:Jupyter Notebook 4.8%Language:Cuda 3.3%Language:C++ 1.4%Language:CMake 0.3%Language:Shell 0.1%Language:Batchfile 0.1%Language:Dockerfile 0.1%Language:Makefile 0.1%Language:C# 0.1%Language:PowerShell 0.0%