摘要:
原因:这个原因是因为在使用Crossentropyloss作为损失函数时,output=net(input)的output应该是[batchsize, n_class, height, weight],而label则是[batchsize, height, weight],label是单通道灰度图; 阅读全文
posted @ 2020-04-09 11:39
DuanYongchun
阅读(12303)
评论(0)
推荐(1)
摘要:
在出现错误的地方加上: with torch.no_grad(): test_loader = init_data_loader(X_test, y_test, torch.device('cpu'), batch_size, num_workers=0) print("Starting infer 阅读全文
posted @ 2020-04-09 00:50
DuanYongchun
阅读(30492)
评论(1)
推荐(1)

浙公网安备 33010602011771号