Jobayer
@jjobayer90
287 Following
126 Followers
6 replies
125 recasts
248 reactions
8 replies
76 recasts
320 reactions
4 replies
35 recasts
195 reactions
34 replies
328 recasts
1118 reactions
64 replies
562 recasts
2511 reactions
24 replies
124 recasts
777 reactions
The differences between the APIs of numpy, cupy and torch are so fascinating....
```
>>> import torch as np
>>> np.arange(10)
tensor([0, 1, 2, 3, 4, 5, 6, 7, 8, 9])
>>> a = np.zeros(20)
>>> a[19:-1:-2] = np.arange(10)
```
Torch doesn't let you have ranges that go backwards 🤣
Would love more consistency 43 replies
557 recasts
2262 reactions
77 replies
1587 recasts
6295 reactions
76 replies
280 recasts
1399 reactions
7 replies
9 recasts
35 reactions
27 replies
44 recasts
226 reactions
1 reply
2 recasts
18 reactions
29 replies
2 recasts
64 reactions
12 replies
82 recasts
444 reactions
1 reply
2 recasts
2 reactions
172 replies
1307 recasts
4573 reactions
28 replies
264 recasts
1062 reactions
28 replies
99 recasts
301 reactions
0 reply
20 recasts
21 reactions
1 reply
12 recasts
184 reactions