Suppress more evaluation verbose during training

This commit is contained in:
terrytangyuan 2015-10-31 13:05:52 -04:00
parent 15a0d27eed
commit 610b70b79e

View File

@ -98,7 +98,8 @@ def train(params, dtrain, num_boost_round=10, evals=(), obj=None, feval=None,
if len(evals) < 1:
raise ValueError('For early stopping you need at least one set in evals.')
sys.stderr.write("Will train until {} error hasn't decreased in {} rounds.\n".format(\
if verbose_eval:
sys.stderr.write("Will train until {} error hasn't decreased in {} rounds.\n".format(\
evals[-1][1], early_stopping_rounds))
# is params a list of tuples? are we using multiple eval metrics?