RuntimeError: indices should be either on cpu or on the same device as the indexed tensor (cpu
报了这个问题
在util.py脚本中添加
at = at.to(j.device)
使得这两个变量在同一个设备运行 即可 直接train.py文件
报了这个问题
在util.py脚本中添加
at = at.to(j.device)
使得这两个变量在同一个设备运行 即可 直接train.py文件