
ghostnet_050
Image classification368 ops2.6M params
A mobile CNN that makes most of its feature maps as cheap ghosts of a few real ones.
Image classification · 368 operations Checked
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.
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
How this diagram was made
timm.create_model('ghostnet_130', pretrained=False) About this model's family
GhostNet is a lightweight convolutional network for embedded devices built on one observation: the feature maps of successful CNNs are highly redundant, and nobody had designed an architecture around that. Instead of producing every channel with a full convolution, the Ghost module makes a handful of intrinsic feature maps and then conjures the rest, the ghosts, from them with cheap linear operations. The module is pitched as a plug-and-play replacement for convolution layers in existing networks.
In the graph each Ghost module is a primary convolution producing m intrinsic maps, followed by per-channel linear operations that turn each one into s outputs, the last of which is an identity that keeps the intrinsic map itself. Those cheap operations are small depthwise convolutions, and after sweeping kernel sizes the authors settled on 3 by 3. Two Ghost modules stacked make a Ghost bottleneck: the first expands the channels, the second reduces them to match a shortcut, with batch normalization and ReLU after each except that ReLU is dropped after the second module, as MobileNetV2 suggested. When the stride is 2, a depthwise convolution is inserted between the two modules and the shortcut gets a downsampling layer.
The whole network copies the layout of MobileNetV3 and swaps in Ghost bottlenecks: a 16-filter standard convolution first, bottlenecks of gradually increasing width grouped into stages, stride 2 only at the end of each stage, and squeeze-and-excite in some blocks. One deliberate difference: GhostNet does not use the hard-swish nonlinearity because of its latency. A global average pooling and a convolution then produce a 1280-dimensional vector for classification. The three captured members are GhostNet-0.5x, GhostNet-1.0x and GhostNet-1.3x, where the suffix is the width multiplier that scales every layer's channel count, and cost, roughly with its square. On ImageNet the paper reports higher accuracy, for example 75.7% top-1, than MobileNetV3 at similar computational cost.
Key idea. The Ghost module, which generates most of a layer's feature maps from a few intrinsic ones through cheap per-channel linear operations, and the Ghost bottleneck and GhostNet built from it. Unlike earlier efficient designs that pair pointwise convolutions with depthwise ones, the primary convolution here can have any kernel size and the linear operations can be diverse, with an identity path preserving the intrinsic maps.
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
@misc{han2020ghostnetfeaturescheapoperations,
title={GhostNet: More Features from Cheap Operations},
author={Kai Han and Yunhe Wang and Qi Tian and Jianyuan Guo and Chunjing Xu and Chang Xu},
year={2020},
eprint={1911.11907},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/1911.11907},
}