torch.cuda.current_stream¶ torch.cuda.current_stream(device=None)[原始碼][原始碼]¶ 傳回給定設備目前選定的 Stream。 參數 device ( torch.device 或 int, 選填) – 選擇的裝置。如果 device 為 None (預設值),則回傳由 current_device() 所指定的目前裝置的當前選擇的 Stream。 回傳類型 Stream