- MobileViT代码分析
代码地址: https://github.com/Le0v1n/ml_code/tree/main/Classification/MobileViT
- MobileViT实际速度测试
测试平台:
- GPU:NVIDIA RTX 3070
- CPU: Intel I5-10400F
- RAM: 16GB
- OS: Windows 11
- Class num: 27
- Tensor size:3 × 224 × 224 3 \times 224 \times 224 3 ×224 ×224
- Batch size: 1
- Unit: Average FPS
模型规格CPU速度GPU速度MobileViT-S11.061356.2663MobileViT-XS13.620557.7125MobileViT-XXS25.149158.2903
可以看到,MobileViT模型规格越小,对CPU速度影响最大,对于GPU而言,大的吞吐量非常适合使用大规格模型。
- 在花分类数据集上的实验结果
3.1 实验设置:
- GPU:NVIDIA RTX 3070
- CPU: Intel I5-10400F
- RAM: 16GB
- OS: Windows 11
- 数据集:花分类数据集
- Class num: 5
- 数据集来源:霹雳吧啦WZ
- 模型:MobileViT-XXS v.s MobileViT-XXS-SE(Squeeze-and-Excitation Attention)
- Tensor size:3 × 224 × 224 3 \times 224 \times 224 3 ×224 ×224
- Batch size: 64
- Epoch num: 150
- Unit: Top-1 Accuracy
- Learning rate strategy: Cosine Annealing Warm Restarts
3.2 实验结果——训练集
; 3.3 实验结果——验证集
3.4 结论
- 曲线出现明显波动是因为学习率变化策略
- 有点过拟合
- SE还是很稳的
Original: https://blog.csdn.net/weixin_44878336/article/details/127739224
Author: Le0v1n
Title: MobileViT代码分析及添加SE注意力的实验结果
原创文章受到原创版权保护。转载请注明出处:https://www.johngo689.com/655133/
转载文章受原作者版权保护。转载请注明原作者出处!