pouya-pezeshkpour
commited on
Commit
•
b61207b
1
Parent(s):
47adf64
Update README.md
Browse files
README.md
CHANGED
@@ -28,10 +28,11 @@ tokenizer = BertTokenizer.from_pretrained(model_name)
|
|
28 |
model = BertModel.from_pretrained(model_name)
|
29 |
|
30 |
|
31 |
-
def run_model(input_string
|
32 |
input_ids = tokenizer.encode(input_string, return_tensors="pt")
|
33 |
-
res = model.generate(input_ids, **generator_args)
|
34 |
-
output = tokenizer.batch_decode(res, skip_special_tokens=True)
|
|
|
35 |
print(output)
|
36 |
return output
|
37 |
|
|
|
28 |
model = BertModel.from_pretrained(model_name)
|
29 |
|
30 |
|
31 |
+
def run_model(input_string):
|
32 |
input_ids = tokenizer.encode(input_string, return_tensors="pt")
|
33 |
+
#res = model.generate(input_ids, **generator_args)
|
34 |
+
#output = tokenizer.batch_decode(res, skip_special_tokens=True)
|
35 |
+
output = model(input_ids)
|
36 |
print(output)
|
37 |
return output
|
38 |
|