【问题标题】:XGBoost4J successfully built but can't import ml.dmlc.xgboost4j.java.{DMatrix => JDMatrix}XGBoost4J 构建成功但无法导入 ml.dmlc.xgboost4j.java.{DMatrix => JDMatrix}
【发布时间】:2018-03-28 13:15:25
【问题描述】:

我仔细按照here的安装说明,注意设置JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home/

通过mvn package 安装返回BUILD SUCCESS。但是,当我尝试从示例文件夹运行 BasicWalkThrough.scala 时,我在

上遇到错误
<console>:14: error: not found: value ml
   import ml.dmlc.xgboost4j.java.{DMatrix => JDMatrix}

有人可以帮忙解决这个问题吗?

操作系统:OSX 10.12

【问题讨论】:

    标签: scala xgboost


    【解决方案1】:

    您需要使用指向您构建的 xboost jar 的 conf 选项运行 spark-shell:

    ./bin/spark-shell --conf spark.jars=/xgboost/jvm-packages/xgboost4j-example/target/xgboost4j-example-0.8-SNAPSHOT-jar-with-dependencies.jar
    

    【讨论】:

      猜你喜欢
      • 2021-11-02
      • 1970-01-01
      • 2019-07-20
      • 2017-05-10
      • 1970-01-01
      • 2015-12-12
      • 1970-01-01
      • 2021-02-15
      • 1970-01-01
      相关资源
      最近更新 更多