torch.cpu.set_device¶ torch.cpu.set_device(device)[原始碼][原始碼]¶ 設定目前的裝置,在 CPU 中我們不執行任何動作。 注意:此函數的存在僅為了方便裝置無關的程式碼。