Namespace(backbone='resnet', batchSize=4, epoch_size=3, gpu_id='0', lr=1e-07, nAveGrad=1, nEpochs=100, nTestInterval=1, nThreads=1, phaseprediction='prediction', phasetest='test', phasetrain='train', resume_epoch=0, snapshot=3, testBatch=1, useTest=True, wd=0.0005)
------------ Options -------------
backbone: resnet
batchSize: 4
epoch_size: 3
gpu_id: 0
gpu_ids: [0]
lr: 1e-07
nAveGrad: 1
nEpochs: 100
nTestInterval: 1
nThreads: 1
phaseprediction: prediction
phasetest: test
phasetrain: train
resume_epoch: 0
snapshot: 3
testBatch: 1
useTest: True
wd: 0.0005
-------------- End ----------------
Constructing DeepLabv3+ model...
Number of classes: 2
Output stride: 16
Number of Input Channels: 3
这是相关的参数设置,gpu:为2080ti,cuda:10.0
预测单张图片(1024*768)的速度很慢,要7-10s,有什么方法可以缩短时间到1-2s
请问,如何优化pytorch的模型预测速度
- 写回答
- 好问题 0 提建议
- 追加酬金
- 关注问题
- 邀请回答
-