Spaces:
Running
on
Zero
Running
on
Zero
AlekseyCalvin
commited on
Commit
•
e956e8f
1
Parent(s):
1451d75
Update app.py
Browse files
app.py
CHANGED
@@ -25,6 +25,8 @@ os.environ["TRANSFORMERS_CACHE"] = cache_path
|
|
25 |
os.environ["HF_HUB_CACHE"] = cache_path
|
26 |
os.environ["HF_HOME"] = cache_path
|
27 |
|
|
|
|
|
28 |
torch.backends.cuda.matmul.allow_tf32 = True
|
29 |
|
30 |
dtype = torch.bfloat16
|
|
|
25 |
os.environ["HF_HUB_CACHE"] = cache_path
|
26 |
os.environ["HF_HOME"] = cache_path
|
27 |
|
28 |
+
device = "cuda" if torch.cuda.is_available() else "cpu"
|
29 |
+
|
30 |
torch.backends.cuda.matmul.allow_tf32 = True
|
31 |
|
32 |
dtype = torch.bfloat16
|