LeeRock / mobilenetv2.pytorch

72.2% MobileNet V2 model on ImageNet with PyTorch Implementation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

PyTorch Implemention of MobileNet V2

+ Release of next generation of MobileNets in mobilenetv3.pytorch

Reproduction of MobileNet V2 architecture as described in MobileNetV2: Inverted Residuals and Linear Bottlenecks by Mark Sandler, Andrew Howard, Menglong Zhu, Andrey Zhmoginov and Liang-Chieh Chen on ILSVRC2012 benchmark with PyTorch framework. Adapted from pytorch-classification and pytorch-mobilenet-v2.

This implementation provides an example procedure of training and validating any prevalent deep neural network architecture, with modular data processing, training, logging and visualization integrated.

Requirements

Dataset

Download the ImageNet dataset and move validation images to labeled subfolders. To do this, you can use the following script: https://raw.githubusercontent.com/soumith/imagenetloader.torch/master/valprep.sh

Pretrained models

Our pretrained model achieves 72.192% top-1 accuracy and 90.534% top-5 accuracy on ImageNet validation set, which is higher than the statistics reported in the original paper and official TensorFlow implementation.

Pretrained model can be easily imported using the following lines and then finetuned for other vision tasks or utilized in resource-limited platforms.

from models.imagenet import mobilenetv2

net = mobilenetv2()
net.load_state_dict(torch.load('pretrained/mobilenetv2-0c6065bc.pth'))

Citations

The following is a BibTeX entry for the MobileNet V2 paper that you should cite if you use this model.

@InProceedings{Sandler_2018_CVPR,
author = {Sandler, Mark and Howard, Andrew and Zhu, Menglong and Zhmoginov, Andrey and Chen, Liang-Chieh},
title = {MobileNetV2: Inverted Residuals and Linear Bottlenecks},
booktitle = {The IEEE Conference on Computer Vision and Pattern Recognition (CVPR)},
month = {June},
year = {2018}
}

License

This repository is licensed under the Apache License 2.0.

About

72.2% MobileNet V2 model on ImageNet with PyTorch Implementation

License:Apache License 2.0


Languages

Language:Python 100.0%