Create optimizer only when args.do_train is True
I am facing the same problem as #544 . When only setting args.do_eval to evaluate a trained model, there will be an error due to optimizer initialization. I think it is unnecessary to create an optimizer if args.do_train is False. Thanks for your review.
Great, thanks @MottoX!