问题描述
当在数据块中使用评估集时,是否有任何方法可以访问xgboost scala中的训练和验证错误?
val xgbParam = Map(
"colsample_bytree" -> 0.6,"subsample" -> 0.8,"eta" -> 0.05,"max_depth" -> 4,"num_round" -> 1000,//"min_child_weight" -> 11,"objective" -> "reg:tweedie","tweedie_variance_power" -> 1.8,"num_workers" -> 10,"num_threads" -> 1,"eval_sets" -> Map("valid" -> valid),"num_early_stopping_rounds" -> 5,"maximize_evaluation_metrics" -> false,"verbose_eval" -> 1)
val xgbregressor = new XGBoostRegressor(xgbParam).
setFeaturesCol("features").
setLabelCol("label")
val xgbregressorModel = xgbregressor.fit(train)
我正在使用verbose_eval-> 1,但似乎无法正常工作。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)