We can't find the internet
Attempting to reconnect
Something went wrong!
Attempting to reconnect
← All tracks
0 / 4
Devices and Data Movement
PyTorchDevice-agnostic code, and the discipline of moving data once. Graded by counting the copies your code causes rather than by owning a GPU, so the lesson holds on the machine you have.
0
/ 4 solved
- 1. Not solved yet. How many copies did that cost
- 2. Not solved yet. Where does a new tensor go
- 3. Not solved yet. The metric that stops the pipeline
- 4. Not solved yet. The constant that stayed behind
Check yourself
4 questions · one attempt eachThese do not count toward finishing the track. They are here to catch the things that are easy to read past.
Which of torch.tensor(a) and torch.as_tensor(a) shares memory with the NumPy array?
a = np.ones(3)
torch.tensor(a)
torch.as_tensor(a)
Question 1 of 4