原文:pytorch报错:ValueError: Expected more than 1 value per channel when training, got input size torch.Size([1,512,1,1])

.pytorch报错:ValueError: Expected more than value per channel when training, got input size torch.Size , , , .网上查找的原因为模型中用了batchnomolization,训练中用batch训练的时候当前batch恰好只含一个sample,而由于BatchNorm操作需要多于一个数据计算平均 ...

2019-11-14 16:53 0 1890 推荐指数:

查看详情

 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM