TorchCV - 基于PyTorch的计算机视觉深度学习框架

网友投稿 868 2022-10-30

TorchCV - 基于PyTorch的计算机视觉深度学习框架

TorchCV - 基于PyTorch的计算机视觉深度学习框架

TorchCV: A PyTorch-Based Framework for Deep Learning in Computer Vision

@misc{you2019torchcv, author = {Ansheng You and Xiangtai Li and Zhen Zhu and Yunhai Tong}, title = {TorchCV: A PyTorch-Based Framework for Deep Learning in Computer Vision}, howpublished = {\url{https://github.com/donnyyou/torchcv}}, year = {2019}}

This repository provides source code for most deep learning based cv problems. We'll do our best to keep this repository up-to-date. If you do find a problem about this repository, please raise an issue or submit a pull request.

Implemented Papers

Image ClassificationVGG: Very Deep Convolutional Networks for Large-Scale Image RecognitionResNet: Deep Residual Learning for Image RecognitionDenseNet: Densely Connected Convolutional NetworksShuffleNet: An Extremely Efficient Convolutional Neural Network for Mobile DevicesShuffleNet V2: Practical Guidelines for Ecient CNN Architecture DesignPartial Order Pruning: for Best Speed/Accuracy Trade-off in Neural Architecture Search Semantic SegmentationDeepLabV3: Rethinking Atrous Convolution for Semantic Image SegmentationPSPNet: Pyramid Scene Parsing NetworkDenseASPP: DenseASPP for Semantic Segmentation in Street ScenesAsymmetric Non-local Neural Networks for Semantic Segmentation Object DetectionSSD: Single Shot MultiBox DetectorFaster R-CNN: Towards Real-Time Object Detection with Region Proposal NetworksYOLOv3: An Incremental ImprovementFPN: Feature Pyramid Networks for Object Detection Pose EstimationCPM: Convolutional Pose MachinesOpenPose: Realtime Multi-Person 2D Pose Estimation using Part Affinity Fields Instance SegmentationMask R-CNN Generative Adversarial NetworksPix2pix: Image-to-Image Translation with Conditional Adversarial NetsCycleGAN: Unpaired Image-to-Image Translation using Cycle-Consistent Adversarial Networks.

QuickStart with TorchCV

Now only support Python3.x, pytorch 1.3.

pip3 install -r requirements.txtcd lib/extssh make.sh

Performances with TorchCV

All the performances showed below fully reimplemented the papers' results.

Image Classification

ImageNet (Center Crop Test): 224x224

ModelTrainTestTop-1Top-5BSItersScripts
ResNet50trainval77.5493.5951230WResNet50
ResNet101trainval78.9494.5651230WResNet101
ShuffleNetV2x0.5trainval60.9082.54102440WShuffleNetV2x0.5
ShuffleNetV2x1.0trainval69.7188.91102440WShuffleNetV2x1.0
DFNetV1trainval70.9989.68102440WDFNetV1
DFNetV2trainval74.2291.61102440WDFNetV2

Semantic Segmentation

Cityscapes (Single Scale Whole Image Test): Base LR 0.01, Crop Size 769

ModelBackboneTrainTestmIOUBSItersScripts
PSPNet3x3-Res101trainval78.2084WPSPNet
DeepLabV33x3-Res101trainval79.1384WDeepLabV3

ADE20K (Single Scale Whole Image Test): Base LR 0.02, Crop Size 520

ModelBackboneTrainTestmIOUPixelACCBSItersScripts
PSPNet3x3-Res50trainval41.5280.091615WPSPNet
DeepLabv33x3-Res50trainval42.1680.361615WDeepLabV3
PSPNet3x3-Res101trainval43.6081.301615WPSPNet
DeepLabv33x3-Res101trainval44.1381.421615WDeepLabV3

Object Detection

Pascal VOC2007/2012 (Single Scale Test): 20 Classes

ModelBackboneTrainTestmAPBSEpochsScripts
SSD300VGG1607+12_trainval07_test0.78632235SSD300
SSD512VGG1607+12_trainval07_test0.80832235SSD512
Faster R-CNNVGG1607_trainval07_test0.706115Faster R-CNN

Pose Estimation

OpenPose: Realtime Multi-Person 2D Pose Estimation using Part Affinity Fields

Instance Segmentation

Mask R-CNN

Generative Adversarial Networks

Pix2pixCycleGAN

DataSets with TorchCV

TorchCV has defined the dataset format of all the tasks which you could check in the subdirs of data. Following is an example dataset directory trees for training semantic segmentation. You could preprocess the open datasets with the scripts in folder data/seg/preprocess

Dataset train image 00001.jpg/png 00002.jpg/png ... label 00001.png 00002.png ... val image 00001.jpg/png 00002.jpg/png ... label 00001.png 00002.png ...

Commands with TorchCV

Take PSPNet as an example. ("tag" could be any string, include an empty one.)

Training

cd scripts/seg/cityscapes/bash run_fs_pspnet_cityscapes_seg.sh train tag

Resume Training

cd scripts/seg/cityscapes/bash run_fs_pspnet_cityscapes_seg.sh train tag

Validate

cd scripts/seg/cityscapes/bash run_fs_pspnet_cityscapes_seg.sh val tag

Testing:

cd scripts/seg/cityscapes/bash run_fs_pspnet_cityscapes_seg.sh test tag

Demos with TorchCV

版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。

上一篇:不知不觉,我已经在C站创作四周年了
下一篇:asp.net GridView、DataGrid行单元格自动合并
相关文章

 发表评论

暂时没有评论,来抢沙发吧~