Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -9,6 +9,12 @@ import torch
|
|
9 |
# Check if CUDA (GPU) is available
|
10 |
print("CUDA available:", torch.cuda.is_available())
|
11 |
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
# Set a seed for reproducibility
|
13 |
set_seed(42)
|
14 |
|
|
|
9 |
# Check if CUDA (GPU) is available
|
10 |
print("CUDA available:", torch.cuda.is_available())
|
11 |
|
12 |
+
if torch.cuda.is_available():
|
13 |
+
print("GPU Name:", torch.cuda.get_device_name(0))
|
14 |
+
else:
|
15 |
+
print("No GPU detected. Running on CPU.")
|
16 |
+
|
17 |
+
|
18 |
# Set a seed for reproducibility
|
19 |
set_seed(42)
|
20 |
|