Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -16,7 +16,7 @@ loaded_tokenizer = AutoTokenizer.from_pretrained("runaksh/Symptom-2-disease_dist
|
|
| 16 |
|
| 17 |
# Function for class prediction
|
| 18 |
def predict(sample, validate=True):
|
| 19 |
-
classifier = pipeline("text-classification", model=
|
| 20 |
pred = classifier(sample)[0]['label']
|
| 21 |
return pred
|
| 22 |
|
|
|
|
| 16 |
|
| 17 |
# Function for class prediction
|
| 18 |
def predict(sample, validate=True):
|
| 19 |
+
classifier = pipeline("text-classification", model=loaded_model, tokenizer=loaded_tokenizer)
|
| 20 |
pred = classifier(sample)[0]['label']
|
| 21 |
return pred
|
| 22 |
|