Semantic segmentation of PV systems based on FixMatchSeg paper and Solar panel segmentation github repository.
This work uses recent overflight images from city and district of Munich and a [USA dataset] to train a semi-supervised segmentation model that identifies locations of PV systems in images.
- USA dataset: The labaled dataset used in the supervised part of the model.
- Munich dataset: The unlabeled dataset used in the unsupervised part of the model.
It undergoes two-step augmentation using imgaug:- Weak augmentation: Random rotation in the range of [−20, 20] degrees + elastic distortion.
- Strong augmentation on weakly augmented images: Modify sharpness, contrast and add Gaussian blur.
The segmentation model is a U-net using pixel-wise binary cross entropy as the loss function.
- Follow the instructions in the data readme to download the data.
- To split the unlabaled Munich data into [224,224], run:
python run.py split_images_unlabeled
- To create masks for the labeled USA data, run:
python run.py make_masks
- To split the images of the labeled USA data into [224,224], run:
python run.py split_images
- Train the segmentation model
python run.py train_segmenter
For more details you can refer to the pipeline in the original Solar panel segmentation repository.
The segmentation masks from the segmentation model were used to do image-wise classification, i.e. whether the image contains a PV system or not, since the segmentation model was originally trained on images containing PV systems and others not.
Both classification and segmentation were tested on 10% of the labeled Munich data and these were the results:
Classification:
- Accuracy: 93.26%
- Precision: 89.83%
- Recall: 99.09%
Segmentantation dice coefficient of 0.909