Update README.md
Browse files
README.md
CHANGED
@@ -31,7 +31,7 @@ layout = [[381, 91, 505, 115], [738, 96, 804, 122]] # all boxes are resized bet
|
|
31 |
feature_extractor = ErnieFeatureExtractor()
|
32 |
|
33 |
# Tokenize context & questions
|
34 |
-
context_encodings = prepare_context_info(tokenizer, context, layout
|
35 |
question = "what is it?"
|
36 |
tokenized_res = ernie_qa_tokenize(tokenizer, question, context_encodings)
|
37 |
tokenized_res['input_ids'] = torch.tensor([tokenized_res['input_ids']]).to(device)
|
|
|
31 |
feature_extractor = ErnieFeatureExtractor()
|
32 |
|
33 |
# Tokenize context & questions
|
34 |
+
context_encodings = prepare_context_info(tokenizer, context, layout)
|
35 |
question = "what is it?"
|
36 |
tokenized_res = ernie_qa_tokenize(tokenizer, question, context_encodings)
|
37 |
tokenized_res['input_ids'] = torch.tensor([tokenized_res['input_ids']]).to(device)
|