評價此頁

torch.cuda.current_stream#

torch.cuda.current_stream(device=None)[原始碼]#

返回給定裝置的當前選定的 Stream

引數

device (torch.deviceint, 可選) – 選定的裝置。如果 deviceNone(預設值),則返回當前裝置(由 current_device() 指定)的當前選定的 Stream

返回型別