diff --git a/BERT/README.md b/BERT/README.md index 288db035ade35b5217b322af2c9e47b3b6d1cf9e..a6ef69f3a1f00232c5a6926ae06fb10ea8fb93d5 100644 --- a/BERT/README.md +++ b/BERT/README.md @@ -376,13 +376,13 @@ src.data.Reset(...); paddle::PaddleTensor pos_id; paddle::PaddleTensor segmeng_id; -paddle::PaddleTensor self_attention_bias; -paddle::PaddleTensor next_segment_index; +paddle::PaddleTensor input_mask; // create iutput tensors and run prediction std::vector output; -predictor->Run({src_id, pos_id, segmeng_id, self_attention_bias, next_segment_index}, &output); +predictor->Run({src_id, pos_id, segmeng_id, input_mask}, &output); +// XNLI task for example std::cout << "example_id\tcontradiction\tentailment\tneutral"; for (size_t i = 0; i < output.front().data.length() / sizeof(float); i += 3) { std::cout << static_cast(output.front().data.data())[i] << "\t"