Spaces:
Sleeping
Sleeping
Mhammad Ibrahim
commited on
Commit
·
f781087
1
Parent(s):
061f0ef
update
Browse files- app.py +0 -1
- requirements.txt +0 -2
app.py
CHANGED
@@ -14,7 +14,6 @@ from transformers import AutoTokenizer, AutoModelForTokenClassification, pipelin
|
|
14 |
tokenizer = AutoTokenizer.from_pretrained("Mhammad2023/bert-finetuned-ner")
|
15 |
model = AutoModelForTokenClassification.from_pretrained(
|
16 |
"Mhammad2023/bert-finetuned-ner",
|
17 |
-
from_tf=True,
|
18 |
torch_dtype=torch.float32
|
19 |
)
|
20 |
classifier = pipeline("token-classification", model=model, tokenizer=tokenizer, device="cpu")
|
|
|
14 |
tokenizer = AutoTokenizer.from_pretrained("Mhammad2023/bert-finetuned-ner")
|
15 |
model = AutoModelForTokenClassification.from_pretrained(
|
16 |
"Mhammad2023/bert-finetuned-ner",
|
|
|
17 |
torch_dtype=torch.float32
|
18 |
)
|
19 |
classifier = pipeline("token-classification", model=model, tokenizer=tokenizer, device="cpu")
|
requirements.txt
CHANGED
@@ -2,6 +2,4 @@ gradio>=4.0.0
|
|
2 |
transformers>=4.21.0
|
3 |
torch>=1.12.0
|
4 |
tokenizers>=0.13.0
|
5 |
-
tensorflow>=2.8.0
|
6 |
-
tf-keras
|
7 |
accelerate
|
|
|
2 |
transformers>=4.21.0
|
3 |
torch>=1.12.0
|
4 |
tokenizers>=0.13.0
|
|
|
|
|
5 |
accelerate
|