File Exchange

image thumbnail

Getting Started with Semantic Segmentation using DL

version 1.0.6 (3.82 MB) by Kevin Chng
Getting Started with Deep Learning Semantic Segmentation using your own image dataset


Updated 27 Feb 2019

View Version History

View License

Overview :

This example shows how to train a semantic segmentation deep learning network using your own dataset. In this example, I will demonstrate how to label the pixel in the image by using MATAB image labeler app.After completing the labelling, I will export the labelling to workspace as 'gTruth'.
Later, I modify example below to accept gTruth as dataset.
After my modification, you do not need to modify anything, it would be workable if you run them directly. However, if the accuracy of network is not satisfied, you may tune the network with different hyperparameter setting and network selection.

Highlights :

1) Label your image at pixel level by MATLAB image labeler app
2) Concept and workflow of semantic segmentation using deep learning
3) Create two datastore (Image datastore and pixel Label datastore)
4) Modify Vgg16 or Vgg19 to SegNet
5) Classify the image by trained SegNet

Product Focus :

Deep Learning Toolbox

Written at 26 February 2019

Cite As

Kevin Chng (2021). Getting Started with Semantic Segmentation using DL (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (4)

Kevin Chng


are available in the helper function in train_semantic_segmentation_network.mlx

you may use deep network designer to modify the network for grayscale. Or build the network from scratch.

Hritam Basak

I have a dataset of medical images is dicom format and I converted them to grayscale i try this procedure.this works fine but the problem arises during training the network as it required 360×480×3 image but my images are 360×480×1
What to do?

Mohanad Bahshwan

These two functions are not available:
- resizePixelLabels()
- resizeImages()

Can you please check and fix it? Thanks.

Safwana Razak

MATLAB Release Compatibility
Created with R2018b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!