AndersonJo/dqn-pytorch

Expanded tensor size mismatch

Opened this issue · 0 comments

I get the following error when running the DQN in train mode:

File "dqn.py", line 507, in optimize target_values[non_final_mask] = reward_batch[non_final_mask] + target_pred.max(1)[0] * gamma RuntimeError: The expanded size of the tensor (1) must match the existing size (30) at non-singleton dimension 1

I'm running PyTorch 0.4.0 and Torchvision 0.2.1. Do you know how to solve this problem?