Skip to content
fn

mobilenet_v3_small

→MobileNetV3927K
mobilenet_v3_small(pretrained: bool = False, overrides: object = {})

MobileNet-v3-Small feature-extracting backbone.

Builds a MobileNetV3 with the NAS-designed Small topology from Howard et al., 2019 (Table 2): 11 inverted-residual bottleneck blocks with selective SE attention and aggressive hard-swish usage from the very first stage, followed by a 1×1 expansion to 576 channels. 927k parameters headless (2.5M with the classification head, which is Table 3's figure) and 67.4% ImageNet-1k top-1 accuracy (Table 3) — the lower-latency variant of the family, targeting tight mobile budgets.

Model Size

Parameters

pretrainedbool= False
No checkpoint is published for mobilenet_v3_small, so True raises NotImplementedError rather than return randomly initialised weights. mobilenet_v3_small_cls is the checkpointed variant.
**overridesobject= {}
Keyword overrides forwarded into MobileNetV3Config.

Returns

MobileNetV3

Backbone with the MobileNet-v3-Small configuration applied (or with overrides merged on top of it).

Notes

See Howard et al., "Searching for MobileNetV3", ICCV 2019 (arXiv:1905.02244), Table 2 (V3-Small spec) and Table 3 (ImageNet accuracy).

Examples

>>> import lucid
>>> from lucid.models.vision.mobilenet_v3 import mobilenet_v3_small
>>> model = mobilenet_v3_small()
>>> x = lucid.randn(1, 3, 224, 224)
>>> out = model(x)
>>> out.last_hidden_state.shape
(1, 576, 7, 7)

Used by 1