aten/src/ATen/cuda/CUDAStream.cpp
// Note: these unsafe methods do not retain the stream before returning it.
// This is unsafe behavior and these methods SHOULD NOT BE USED.
// They are here only for legacy compatibility.
these unsafe methods do not retain the stream before returning it.
these unsafe methods do not retain the stream before returning it .
CUDAStreamInternals* CUDAStream_getCurrentStreamOnDeviceUnsafe(int64_t device) {
    initCUDAStreamsOnce();
    check_gpu(device);
    return current_streams[device];
  }
CUDAStreamInternals * CUDAStream_getCurrentStreamOnDeviceUnsafe ( int64_t device ) { initCUDAStreamsOnce ( ) ; check_gpu ( device ) ; return current_streams [ device ] ; }
Note: these unsafe methods do not retain the stream before returning it.
Note : these unsafe methods do not retain the stream before returning it .