Open linghu8812 opened 3 years ago
Yes, it can solve the problem. https://github.com/WongKinYiu/yolor/issues/16#issuecomment-853717447
I noticed the same thing - would it help if I sent a pull request to the paper
branch to fix this issue @WongKinYiu ?
The problem seems to stem from here:
if isinstance(output, torch.Tensor):
output = output.cpu().numpy()
from what I've seen output
is (at least sometimes) actually a ragged list of tensors of different shapes, so this line doesn't trigger.
An inelegant solution could be something like so:
for i, o in enumerate(output):
if o is not None:
if isinstance(o, torch.Tensor):
o = o.cpu().numpy()
Hello! When I finish training with branch paper, it encountered with an error:
perhaps it should be this?