nv-tlabs / ASE

Other
795 stars 130 forks source link

torch squeeze in htl_players causes a crash when testing with only 1 enviornment #50

Closed Robokan closed 1 year ago

Robokan commented 1 year ago

current_action = torch.squeeze(current_action.detach()) around line 91 in hrl_players will cause a crash if you are testing with only on environment. changing it to: current_action = current_action.detach()

fixes the crash.

xbpeng commented 1 year ago

thanks a lot for pointing that out, fixed: https://github.com/nv-tlabs/ASE/commit/f0e41937095014ec972c7f3ae9f3f15a99978a99

Robokan commented 1 year ago

I just found another case in ase_players. Line 88. This one will crash it when testing the llc networks just by itself. current_action = torch.squeeze(current_action.detach()) should be: current_action = current_action.detach()

xbpeng commented 1 year ago

thanks, fixed