Solved by Audrey in post #3 
              
              
                Thanks for your help. I added os.environ['CUDA_LAUNCH_BLOCKING'] = '1' in my code and ran it again. Errors occurred as following: 
C:/w/1/s/windows/pytorch/aten/src/THC/THCTensorIndex.cu:361: block: [36,0,0], thread: [64,0,0] Assertion `srcIndex < srcSelectDimSize` failed.
C:/w/1/s/windows/pytorch/a…