!21915 fix dqn GPU unnecessary ctx set

Merge pull request !21915 from caojian05/ms_master_dqn_bugfix
This commit is contained in:
i-robot 2021-08-21 14:26:18 +00:00 committed by Gitee
commit 7c1996ad63
1 changed files with 0 additions and 2 deletions

View File

@ -49,7 +49,6 @@ if __name__ == "__main__":
context.set_context(mode=context.GRAPH_MODE, device_target=args.device_target)
if args.device_target == 'GPU':
cfg = cfg_gpu
context.set_context(device_id=1)
env = gym.make(cfg.game)
env = env.unwrapped
@ -105,4 +104,3 @@ if __name__ == "__main__":
times_numpy = np.array(times)
print(rewards_numpy.mean(), times_numpy.mean())