我在尝试运行PyTorch中的vnet实现(https://github.com/mattmacy/vnet.pytorch),在使用以下参数对扫描进行归一化后:
x_max = 512 y_max = 512 z_max = 500 voxspacing = 0.7
当我在数据加载器的for循环行调用tran
函数时,我得到了一个
轴不匹配数组错误。
我不知道如何修复这个问题。任何帮助都会非常有用。我在机器学习方面是个新手
回答:
注释掉第417和418行,问题就会得到解决
问题是由于这两行代码引起的
if self.transform is not None: img = self.transform(img)