pip install torch===1.2.0 torchvision===0.4.0 -f https://download.pytorch.org/whl/torch_stable.html
主要是为了解决 Pytorch:module 'torch' has no attribute 'bool'问题
我原来的版本为1.0.0
但是torch.Booltensor是1.2.0之后才有的
比较操作返回的数据类型由 torch.uint8 变为 torch.bool
1>>> torch.tensor([1, 2, 3]) < torch.tensor([3, 1, 2])
2tensor([1, 0, 0], dtype=torch.uint8)