mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-09-30 03:13:48 +08:00
eefc084302
version: sunnypilot v2025.003.000 (dev) date: 2025-12-18T05:48:43 master commit: 16c052af0835f049a67b80251d8cc1114fc08bb4
19 lines
315 B
Python
19 lines
315 B
Python
from tinygrad import Tensor, Device
|
|
|
|
#N = 1024
|
|
N = 32
|
|
t = Tensor.rand(N, N, N, device="CPU").realize()
|
|
d1 = Device.DEFAULT + ":1"
|
|
d2 = Device.DEFAULT + ":2"
|
|
d3 = Device.DEFAULT + ":3"
|
|
|
|
for i in range(3):
|
|
t.to_(d1)
|
|
t.realize()
|
|
# t.to_("CPU")
|
|
# t.realize()
|
|
t.to_(d2)
|
|
t.realize()
|
|
t.to_(d3)
|
|
t.realize()
|