Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save jelc53/564d02b06d41b14845ee693011fb4651 to your computer and use it in GitHub Desktop.
Save jelc53/564d02b06d41b14845ee693011fb4651 to your computer and use it in GitHub Desktop.
finetune_deepsolar.txt
Finetuning processing
Step 1 (Optional): Train Classification Model
- data_dir = '/home/ubuntu/deepsolar/data/bdappv-france/ft_100/'
- old_ckpt_path = '/home/ubuntu/deepsolar/models/deepsolar_pretrained.pth'
- ckpt_save_dir = 'checkpoint/bdappv_ft100_w0.01'
- model_name = 'deepsolar_classification'
- imbalance_rate = 1
- learning_rate = 0.01
- weight_decay = 0.01
- update image dataset class to exlcude val 'true_seg' images
Step 2: Finetune Segmentation Model (Level 1, ft_100)
- data_dir = '/home/ubuntu/deepsolar/data/bdappv-france/ft_100/'
- basic_params_path = '/home/ubuntu/deepsolar/models/deepsolar_pretrained.pth'
or if completed step 1, '/home/ubuntu/deepsolar/src/checkpoint/bdappv_ft100_w0.01/deepsolar_classification_5.tar'
- old_ckpt_path = '/home/ubuntu/deepsolar/models/deepsolar_seg_pretrained.pth'
- ckpt_save_dir = 'checkpoint/bdappv_ft100_w0.01'
- model_name = 'deepsolar_seg_level1'
- level = 1
- imbalance_rate = 1
- learning_rate = 0.01
- weight_decay = 0.01
- update image dataset class to exlcude val 'true_seg' images
Step 3: Finetune Segmentation Model (Level 2, ft_100)
- data_dir = '/home/ubuntu/deepsolar/data/bdappv-france/ft_100/'
- basic_params_path = '/home/ubuntu/deepsolar/models/deepsolar_pretrained.pth'
or if completed step 1, '/home/ubuntu/deepsolar/src/checkpoint/bdappv_ft100_w0.01/deepsolar_classification_5.tar'
- old_ckpt_path = '/home/ubuntu/deepsolar/src/checkpoint/bdappv_ft100_w0.01/deepsolar_seg_level1_5.tar'
- ckpt_save_dir = 'checkpoint/bdappv_ft100_w0.01'
- model_name = 'deepsolar_seg_level2'
- level = 2
- imbalance_rate = 1
- learning_rate = 0.01
- weight_decay = 0.01
- update image dataset class to exlcude val 'true_seg' images
Step 4: Test Segmentation Model (ft_eval)
- data_dir = '/home/ubuntu/deepsolar/data/bdappv-france/ft_eval'
- old_ckpt_path = '/home/ubuntu/deepsolar/src/checkpoint/bdappv_ft100_w.01/deepsolar_seg_level2_5.tar.pth'
- class_threshold = 0.5
- seg_threshold = 0.37
- level = 2
- imbalance_rate = 1
- learning_rate = 0.01
- weight_decay = 0.01
- update image dataset class to exlcude val 'true_seg' images
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment