ford442 commited on
Commit
c687aa5
·
verified ·
1 Parent(s): a8057ad

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -48,7 +48,7 @@ def upload_to_ftp(filename):
48
  except Exception as e:
49
  print(f"FTP upload error: {e}")
50
 
51
- device = torch.device("cuda")
52
  torch_dtype = torch.bfloat16
53
 
54
  checkpoint = "microsoft/Phi-3.5-mini-instruct"
 
48
  except Exception as e:
49
  print(f"FTP upload error: {e}")
50
 
51
+ device = torch.device("cuda:0" if torch.cuda.is_available() else "cpu")
52
  torch_dtype = torch.bfloat16
53
 
54
  checkpoint = "microsoft/Phi-3.5-mini-instruct"