PyTorch Forums
Libtorch can use "target[c][label == c] = 1" like python?
yzqxmuex
(Yzqxmuex)
March 2, 2021, 8:44am
1
c is channel values that integer constant。label is a tensor with shape {h,w}.Thank you very much!