Giter Site home page Giter Site logo

mobilenetv3's Introduction

MobileNetV3

DeepVAC-compliant MobileNetV3 implementation

简介

本项目实现了符合DeepVAC规范的MobileNet V3

项目依赖

  • deepvac >= 0.5.6
  • pytorch >= 1.8.0
  • opencv-python
  • numpy

如何运行本项目

1. 阅读DeepVAC规范

可以粗略阅读,建立起第一印象。

2. 准备运行环境

使用Deepvac规范指定Docker镜像

3. 准备数据集

自行准备。

4. 修改配置文件

修改config.py文件。主要修改内容:

  • 指定训练集、验证集、测试集的图片目录前缀、对应的标注txt文件和分隔符
# line 43-45
fileline_path = 'data/train_cls.txt'
delimiter = ' ' 
sample_path_prefix = <your sample_path_prefix>

# line 65
fileline_path = 'data/val_cls.txt'

# line 79
fileline_path = 'data/test_cls.txt'
  • 修改分类数
config.core.DeepvacCls.cls_num = 4

5. 训练

执行命令:

python3 train.py

6. 测试

指定要测试模型和测试数据的路径,在config.py指定待测模型和数据路径:

fileline_path = 'data/test_cls.txt'
config.core.DeepvacClsTest.model_path = "your test model dir / pretrained weights"

然后运行测试脚本:

python3 test.py

7, 更多功能

如果要在本项目中开启如下功能:

  • 预训练模型加载
  • checkpoint加载
  • 使用tensorboard
  • 启用TorchScript
  • 转换ONNX
  • 转换NCNN
  • 转换CoreML
  • 开启量化
  • 开启自动混合精度训练

请参考DeepVAC

mobilenetv3's People

Contributors

gemfield avatar buptlihang avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.