def eval_squad(strategy, input_meta_data): """Evaluate on the squad dataset.""" bert_config = bert_configs.BertConfig.from_json_file(FLAGS.bert_config_file) tokenizer = tokenization.FullTokenizer( vocab_file=FLAGS.vocab_file, do_lower_case=FLAGS.do_lower_case) eval_metrics = run_squad_helper.eval_squad( strategy, input_meta_data, tokenizer, bert_config, squad_lib_wp) return eval_metrics
def eval_squad(strategy, input_meta_data): """Evaluate on the squad dataset.""" bert_config = albert_configs.AlbertConfig.from_json_file( FLAGS.bert_config_file) tokenizer = tokenization.FullSentencePieceTokenizer( sp_model_file=FLAGS.sp_model_file) eval_metrics = run_squad_helper.eval_squad( strategy, input_meta_data, tokenizer, bert_config, squad_lib_sp) return eval_metrics