Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -5,7 +5,7 @@ import re
|
|
| 5 |
import os
|
| 6 |
from typing import List, Tuple
|
| 7 |
import spaces
|
| 8 |
-
|
| 9 |
|
| 10 |
|
| 11 |
|
|
@@ -41,6 +41,7 @@ class SinaReasonMedicalChat:
|
|
| 41 |
def load_model(self):
|
| 42 |
"""Load the SinaReason medical model and tokenizer using Unsloth"""
|
| 43 |
try:
|
|
|
|
| 44 |
print(f"Loading medical model with Unsloth: {MODEL_NAME}")
|
| 45 |
print("cuda" if torch.cuda.is_available() else "cpu")
|
| 46 |
|
|
|
|
| 5 |
import os
|
| 6 |
from typing import List, Tuple
|
| 7 |
import spaces
|
| 8 |
+
|
| 9 |
|
| 10 |
|
| 11 |
|
|
|
|
| 41 |
def load_model(self):
|
| 42 |
"""Load the SinaReason medical model and tokenizer using Unsloth"""
|
| 43 |
try:
|
| 44 |
+
from unsloth import FastLanguageModel
|
| 45 |
print(f"Loading medical model with Unsloth: {MODEL_NAME}")
|
| 46 |
print("cuda" if torch.cuda.is_available() else "cpu")
|
| 47 |
|