Complete warning + cleanup

This commit is contained in:
LysandreJik
2019-12-10 14:33:24 -05:00
parent dc4e9e5cb3
commit 6a73382706
2 changed files with 2 additions and 3 deletions

View File

@@ -299,7 +299,6 @@ def evaluate(args, model, tokenizer, prefix=""):
# XLNet and XLM use a more complex post-processing procedure
if args.model_type in ['xlnet', 'xlm']:
start_n_top = model.config.start_n_top if hasattr(model, "config") else model.module.config.start_n_top
end_n_top = model.config.end_n_top if hasattr(model, "config") else model.module.config.end_n_top