uNet based segmentation for Multiple Sclerosis lesions in python using Keras.
The segmentation process is split in two. Modelfitting.py are training the model and saving the model used for predicting on test data and Predict.py is predicting on the test data
The Modelfitting.py uses early stopping. Make sure to change this parameter depended on your purpose.
Furthermore, the code contains different loss functions and metrics. These can be changes accordingly and based on purpose. The optimizers can be found here: https://keras.io/api/optimizers/
The uNet should be suitable for other segmentations approaches such as brain tumor segmentation, cerebral hemorrhage segmentation etc.
Just send an Issue and I will look into it
Currently working on different unsupervised methods for segmentation. The idea is to develop a good enough unsupervised segmentation of Multiple Sclerosis lesions to use as input to the uNet for complete automatic segmentation (no manual segmentation is needed to obtain ground truth). Stay tuned for more!