Update app.py
Browse files
app.py
CHANGED
@@ -13,15 +13,17 @@ import csv
|
|
13 |
from datetime import datetime
|
14 |
import json
|
15 |
|
16 |
-
zero = torch.Tensor([0])
|
17 |
print('outside',zero.device)
|
18 |
|
19 |
import spaces
|
20 |
|
|
|
|
|
21 |
@spaces.GPU
|
22 |
def test(n):
|
23 |
print(n)
|
24 |
-
print('
|
25 |
# device = zero.device
|
26 |
print('1 ',torch.Tensor([1]).cuda())
|
27 |
return 0
|
|
|
13 |
from datetime import datetime
|
14 |
import json
|
15 |
|
16 |
+
zero = torch.Tensor([0])
|
17 |
print('outside',zero.device)
|
18 |
|
19 |
import spaces
|
20 |
|
21 |
+
print('after spaces', zero.device)
|
22 |
+
|
23 |
@spaces.GPU
|
24 |
def test(n):
|
25 |
print(n)
|
26 |
+
print('inside device', zero.device)
|
27 |
# device = zero.device
|
28 |
print('1 ',torch.Tensor([1]).cuda())
|
29 |
return 0
|