This implementation uses PanDerm for skin lesion segmentation.
Main dependencies: Pytorch, Pytorch Lightning, MMSegmentation
cd segmentation
conda create -n dermseg python=3.10
conda activate dermseg
pip install torch==2.2.1 torchvision==0.17.1 --index-url https://download.pytorch.org/whl/cu118
pip install -r requirements.txt
pip install -U openmim
mim install mmengine==0.10.4
mim install mmcv==2.1.0
mim install mmsegmentation==1.2.2- Download datasets:
- Change
--parent_pathin run.sh accordingly
-
Download Pretrained Weights
-
Set Pretrained Path
- Modify
--parent_pathin run.sh accordingly
- Modify
-
Start Training
bash run.sh
Note: Adjust the path config to your desired storage location
-
Evaluation
- Add
--evaluatetorun.shfor evaluation mode
cd segmentation add --evaluate - Add
See evaluate.ipynb to learn:
- Using it for skin lesion segmentation