Spaces:
Sleeping
Sleeping
Commit
·
d1d1581
1
Parent(s):
1a31d5d
Update r_shiny_app/global.R
Browse files- r_shiny_app/global.R +2 -2
r_shiny_app/global.R
CHANGED
|
@@ -33,10 +33,10 @@ torch <- reticulate::import("torch")
|
|
| 33 |
if(torch$cuda$is_available()){
|
| 34 |
print(paste0("CUDA AVAILABLE. Num devices: ", torch$cuda$device_count()))
|
| 35 |
# print(paste0("current", torch$current_device()))
|
| 36 |
-
fflush.console()
|
| 37 |
device=as.integer(0)
|
| 38 |
print(paste0("Set up device ordinal "), device)
|
| 39 |
-
fflush.console();
|
| 40 |
torch$cuda$set_device(device)
|
| 41 |
print(paste0("Device setted up"))
|
| 42 |
#torch$cuda$set_device(as.integer(1))
|
|
|
|
| 33 |
if(torch$cuda$is_available()){
|
| 34 |
print(paste0("CUDA AVAILABLE. Num devices: ", torch$cuda$device_count()))
|
| 35 |
# print(paste0("current", torch$current_device()))
|
| 36 |
+
# fflush.console()
|
| 37 |
device=as.integer(0)
|
| 38 |
print(paste0("Set up device ordinal "), device)
|
| 39 |
+
# fflush.console();
|
| 40 |
torch$cuda$set_device(device)
|
| 41 |
print(paste0("Device setted up"))
|
| 42 |
#torch$cuda$set_device(as.integer(1))
|