ml.dmlc.xgboost4j.java.XGBoostError: [14:43:22] src/metric/elementwise_metric.cc:28: Check failed: (preds.size()) == (info.labels.size()) label and prediction size not match, hint: use merror or mlogloss for multi-class classification

GitHub | geoHeil | 5 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    xgboost 4j spark test failure version v0.6.0

    GitHub | 5 months ago | geoHeil
    ml.dmlc.xgboost4j.java.XGBoostError: [14:43:22] src/metric/elementwise_metric.cc:28: Check failed: (preds.size()) == (info.labels.size()) label and prediction size not match, hint: use merror or mlogloss for multi-class classification

    Root Cause Analysis

    1. ml.dmlc.xgboost4j.java.XGBoostError

      [14:43:22] src/metric/elementwise_metric.cc:28: Check failed: (preds.size()) == (info.labels.size()) label and prediction size not match, hint: use merror or mlogloss for multi-class classification

      at ml.dmlc.xgboost4j.java.JNIErrorHandle.checkCall()
    2. ml.dmlc.xgboost4j
      XGBoostModel$$anonfun$1.apply
      1. ml.dmlc.xgboost4j.java.JNIErrorHandle.checkCall(JNIErrorHandle.java:48)
      2. ml.dmlc.xgboost4j.java.Booster.evalSet(Booster.java:178)
      3. ml.dmlc.xgboost4j.scala.Booster.evalSet(Booster.scala:97)
      4. ml.dmlc.xgboost4j.scala.spark.XGBoostModel$$anonfun$1.apply(XGBoostModel.scala:80)
      5. ml.dmlc.xgboost4j.scala.spark.XGBoostModel$$anonfun$1.apply(XGBoostModel.scala:62)
      5 frames
    3. Spark
      Executor$TaskRunner.run
      1. org.apache.spark.rdd.RDD$$anonfun$mapPartitions$1$$anonfun$apply$23.apply(RDD.scala:766)
      2. org.apache.spark.rdd.RDD$$anonfun$mapPartitions$1$$anonfun$apply$23.apply(RDD.scala:766)
      3. org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:38)
      4. org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:319)
      5. org.apache.spark.rdd.RDD.iterator(RDD.scala:283)
      6. org.apache.spark.rdd.MapPartitionsRDD.compute(MapPartitionsRDD.scala:38)
      7. org.apache.spark.rdd.RDD.computeOrReadCheckpoint(RDD.scala:319)
      8. org.apache.spark.rdd.RDD.iterator(RDD.scala:283)
      9. org.apache.spark.scheduler.ResultTask.runTask(ResultTask.scala:70)
      10. org.apache.spark.scheduler.Task.run(Task.scala:85)
      11. org.apache.spark.executor.Executor$TaskRunner.run(Executor.scala:274)
      11 frames
    4. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
      3. java.lang.Thread.run(Thread.java:745)
      3 frames