소스 검색

Added warning if cuda is disabled, to avoid silent failure

Maxime Chevalier-Boisvert 7 년 전
부모
커밋
d4d83a9bf6
1개의 변경된 파일3개의 추가작업 그리고 0개의 파일을 삭제
  1. 3 0
      pytorch-rl/arguments.py

+ 3 - 0
pytorch-rl/arguments.py

@@ -64,4 +64,7 @@ def get_args():
     args.cuda = not args.no_cuda and torch.cuda.is_available()
     args.vis = not args.no_vis
 
+    if not args.cuda:
+        print('*** WARNING: CUDA NOT ENABLED ***')
+
     return args