All models

smp_PSPNet_dpn131

Scene parsing with a four-level pyramid pooling head, captured here over many segmentation_models_pytorch encoders.

Segmentation · 214 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (27 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Family
PSPNet
Parameters
78.1M
Operations
214
Framework
PyTorch
Recurrent
No
Published
CVPR 2017
Cited by
255 (as of 18 October 2026)
Authors
Hengshuang Zhao, Jianping Shi, Xiaojuan Qi and others
License
MIT
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m9702
Graph hash
18ed89d6e505e197e9c07ba8f0d72c2c3588afec7fd68a9b148ed898a6fe4b97
Skeleton hash
4652fd7abe13d3a570fd4146d3e932f6217dc2df81d9ed99b27f5732fb4e8164
Architecture hash
7b8d39c5e3fc5f5db2c0f5f7ad53751493e33d4fb66bc03cf8f030f0b9dcd1d9
Diagram SHA-256
857b34c6f069d17daa97744fca34d6f599b1938c0f4bf667a06470cebeaf0b34
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

About this model's family

PSPNet, the Pyramid Scene Parsing Network, is a model for scene parsing, which is based on semantic segmentation and aims to assign each pixel in the image a category label. Its starting point is a diagnosis: the major issue for FCN based models is a lack of a suitable strategy to utilize global scene category clues. The paper's favourite example is a boat mistaken as a car, an error that the context of a boathouse near a river would have prevented.

The answer is the pyramid pooling module, which fuses features under four different pyramid scales. The coarsest level is global pooling producing a single bin, while the following levels split the feature map into sub-regions and pool each location separately. The module used in the paper has four levels with bin sizes of 1×1, 2×2, 3×3 and 6×6. After each level a 1×1 convolution reduces the context representation to 1/N of its original dimension, where N is the level size. Those low-dimension maps are upsampled by bilinear interpolation to the original feature-map size and concatenated into the final pyramid pooling global feature. In the paper this module sits on a pretrained ResNet with the dilated network strategy, whose final feature map is 1/8 of the input image. The prior is concatenated with the original feature map and a convolution layer generates the final prediction map.

A second contribution is an effective optimization strategy for deep ResNet based on deeply supervised loss. In the ResNet101 model the auxiliary classifier is applied after the fourth stage, the res4b22 residue block. In the testing phase that auxiliary branch is abandoned and only the master branch makes the final prediction. In the ablations, average pooling works better than max pooling in all settings. An auxiliary loss weight of 0.4 yields the best performance. The approach came first in the ImageNet scene parsing challenge 2016, the PASCAL VOC 2012 benchmark and the Cityscapes benchmark. A single PSPNet reached 85.4% mIoU on PASCAL VOC 2012 and 80.2% on Cityscapes. The first author's PyTorch reimplementation, semseg, mainly uses ResNet50/101/152 as backbone and can be adapted to other classification structures.

Key idea. PSPNet adds a pyramid pooling module that aggregates context from different regions at several scales on top of a pixel-prediction network, giving the final prediction a global scene prior.

  • pspnet
  • pyramid scene parsing network
  • pyramid pooling module
  • ppm
  • scene parsing
  • semantic segmentation
  • ade20k
  • cityscapes
  • pascal voc
  • segmentation_models_pytorch
  • smp pspnet

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@misc{zhao2017pyramidsceneparsingnetwork,
      title={Pyramid Scene Parsing Network}, 
      author={Hengshuang Zhao and Jianping Shi and Xiaojuan Qi and Xiaogang Wang and Jiaya Jia},
      year={2017},
      eprint={1612.01105},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/1612.01105}, 
}