使用torch.nn.BCELoss()需要input >= 0. && input <= 1,但是我的网络最后没有加sigmoid,用nn.BCEWithLogitsLoss()替换torch.nn.BCELoss()即可。