Branch: master
Find file History
Latest commit df63b74 Feb 6, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information. merge eval_camvid and eval_cityscapes Dec 5, 2018 use -1 as unlabeled May 28, 2017 args --pretrained_model -> --pretrained-model May 25, 2018 set setNumThreads Feb 6, 2019



Please create class_weight.npy using first. Just run:

$ python

Start training

First, move to this directory (i.e., examples/segnet) and run:

$ python [--gpu <gpu>]

PlotReport extension uses matplotlib. If you got RuntimeError: Invalid DISPLAY variable error on Linux environment, adding an environment variable specification is recommended:

$ MPLBACKEND=Agg python [--gpu <gpu>]


Experimental settings

We used the completely same parameters for all settings.

Implementation Optimizer Learning rage Momentum Weight decay Model code
ChainerCV MomentumSGD 0.1 0.9 0.0005
Official MomentumSGD 0.1 0.9 0.0005 segnet_basic_train.prototxt

Quick Demo

Here is a quick demo using our pretrained weights. The pretrained model is automatically downloaded from the internet.

$ wget
$ python [--gpu <gpu>] [--pretrained-model <model_path>] 0001TP_008550.png

Comparizon with the paper results

Implementation Global accuracy Class accuracy mean IoU
ChainerCV 82.7 % 67.1 % 49.4 %
Official 82.8 % 62.3% 46.3 %

The evaluation can be conducted using chainercv/examples/semantic_segmentation/


  1. Vijay Badrinarayanan, Alex Kendall and Roberto Cipolla "SegNet: A Deep Convolutional Encoder-Decoder Architecture for Image Segmentation." PAMI, 2017.
  2. Vijay Badrinarayanan, Ankur Handa and Roberto Cipolla "SegNet: A Deep Convolutional Encoder-Decoder Architecture for Robust Semantic Pixel-Wise Labelling." arXiv preprint arXiv:1505.07293, 2015.
  3. Original implementation