Skip to content

Python notebook for building semantic segmentation from high resolution satellite imagery. A part of project SEERI, a collaboration between Braga Tech. and GIZ in developing website for estimating solar potential on building rooftop.

Notifications You must be signed in to change notification settings

widifadi/SEERI-Building_Segmentation

Repository files navigation

SEERI Building Segmentation

The provided Google Colab code is the result from the project SEERI, a collaboration between Braga Tech. and GIZ. The code will produce a vectorize building shape from deep learning process for building segmentation that will be fed to the SEERI website, which then be used for estimating solar potential on the rooftop.

How to Run

To run the code several data have to be downloaded first. After setting-up the folder structures in google drive which will be done automatically using the provided code, label class, image, and shapefile data has to be uploaded to the following directories:

  1. label class directory: /content/drive/MyDrive/proj_name/
  2. image directory: /content/drive/MyDrive/proj_name/original_data/img/
  3. shapefile directory: /content/drive/MyDrive/original_data/shp/building_shp/

Label class file can be downloaded from this repository or from this link, and the sample data that was used in the project can be downloaded here.

Moreover, the prediction model resulted from the training will be stored in this directory:
/content/drive/MyDrive/proj_name/model/bss_model/

The prediction model that was used in the project can be downloaded here, which can then be uploaded to the directory mentioned above.

Here are the result of model training and image segmentation process. Prediction Result Best IoU Plot Best Dice Loss Plot

About Building Regularization

The regularization on the predicted building shape was done using the repo from: https://github.com/zorzi-s/projectRegularization, the pretrained weights needed to run the code can be downloaded from the provided repo. The pretrained weights should be uploaded to the following directories:
/content/drive/MyDrive/proj_name/model/pretrained_weights_gan/

Note that as some error occured when using regularize.py from the provided repo on google colab, the code was slightly adjusted and the modified code can be downloaded here or from this repository.

The figure below shows the result of the building shape after regularization process. Regularized Result

Credit

Some of the original code that was used in the project are the following:

About

Python notebook for building semantic segmentation from high resolution satellite imagery. A part of project SEERI, a collaboration between Braga Tech. and GIZ in developing website for estimating solar potential on building rooftop.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published