RuntimeError: cannot reshape tensor of 0 elements into shape [-1, 0] because the unspecified dimension size -1 can be any value and is ambiguous

Hello,

When training a model I am getting this error. Any ideas?

RuntimeError: cannot reshape tensor of 0 elements into shape [-1, 0] because the unspecified dimension size -1 can be any value and is ambiguous

hi.

check input data’s tensor shape.

it seem to be input data is None or empty tensor.

1 Like