Hi,
Im trying your method on different datraset, but getting bellow error.
please help me to fix
/content/ReID-MGN-master/ReID-MGN-master/utils/TripletLoss.py:56: UserWarning: This overload of addmm is deprecated:
addmm(Number beta, Number alpha, Tensor mat1, Tensor mat2)
Consider using one of the following signatures instead:
addmm_(Tensor mat1, Tensor mat2, , Number beta, Number alpha) (Triggered internally at /pytorch/torch/csrc/utils/python_argparser.cpp:1005.)
dist.addmm(1, -2, inputs, inputs.t())
total loss:14.65 Triplet_Loss:2.70 CrossEntropy_Loss:5.98 Traceback (most recent call last):
File "main.py", line 155, in
main.train()
File "main.py", line 48, in train
loss = self.loss(outputs, labels)
File "/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward(input, *kwargs)
File "/content/ReID-MGN-master/ReID-MGN-master/loss.py", line 14, in forward
Triplet_Loss = [triplet_loss(output, labels) for output in outputs[1:4]]
File "/content/ReID-MGN-master/ReID-MGN-master/loss.py", line 14, in
Triplet_Loss = [triplet_loss(output, labels) for output in outputs[1:4]]
File "/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward(input, **kwargs)
File "/content/ReID-MGN-master/ReID-MGN-master/utils/TripletLoss.py", line 63, in forward
dist_an.append(dist[i][mask[i] == 0].min().unsqueeze(0))
RuntimeError: operation does not have an identity.
Hi, Im trying your method on different datraset, but getting bellow error. please help me to fix
/content/ReID-MGN-master/ReID-MGN-master/utils/TripletLoss.py:56: UserWarning: This overload of addmm is deprecated: addmm(Number beta, Number alpha, Tensor mat1, Tensor mat2) Consider using one of the following signatures instead: addmm_(Tensor mat1, Tensor mat2, , Number beta, Number alpha) (Triggered internally at /pytorch/torch/csrc/utils/python_argparser.cpp:1005.) dist.addmm(1, -2, inputs, inputs.t()) total loss:14.65 Triplet_Loss:2.70 CrossEntropy_Loss:5.98 Traceback (most recent call last): File "main.py", line 155, in
main.train()
File "main.py", line 48, in train
loss = self.loss(outputs, labels)
File "/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward( input, *kwargs)
File "/content/ReID-MGN-master/ReID-MGN-master/loss.py", line 14, in forward
Triplet_Loss = [triplet_loss(output, labels) for output in outputs[1:4]]
File "/content/ReID-MGN-master/ReID-MGN-master/loss.py", line 14, in
Triplet_Loss = [triplet_loss(output, labels) for output in outputs[1:4]]
File "/usr/local/lib/python3.7/dist-packages/torch/nn/modules/module.py", line 889, in _call_impl
result = self.forward( input, **kwargs)
File "/content/ReID-MGN-master/ReID-MGN-master/utils/TripletLoss.py", line 63, in forward
dist_an.append(dist[i][mask[i] == 0].min().unsqueeze(0))
RuntimeError: operation does not have an identity.