LinearRegressionModel 的 Maven 存储库
maven repository for LinearRegressionModel
我正在尝试启动 spark 教程中的示例,但无法编译:
final LinearRegressionModel model =
LinearRegressionWithSGD.train(JavaRDD.toRDD(parsedData),numIterations, stepSize);
我找不到 LinearRegressionWithSGD
的 Maven 依赖项和导入包。这个不行:
<groupId>org.apache.spark</groupId>
<artifactId>spark-core_2.10</artifactId>
<version>2.1.0</version>
我应该选哪个?
您应该使用 spark-mllib
库:
<!-- https://mvnrepository.com/artifact/org.apache.spark/spark-mllib_2.10 -->
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-mllib_2.10</artifactId>
<version>2.1.0</version>
</dependency>
我正在尝试启动 spark 教程中的示例,但无法编译:
final LinearRegressionModel model =
LinearRegressionWithSGD.train(JavaRDD.toRDD(parsedData),numIterations, stepSize);
我找不到 LinearRegressionWithSGD
的 Maven 依赖项和导入包。这个不行:
<groupId>org.apache.spark</groupId>
<artifactId>spark-core_2.10</artifactId>
<version>2.1.0</version>
我应该选哪个?
您应该使用 spark-mllib
库:
<!-- https://mvnrepository.com/artifact/org.apache.spark/spark-mllib_2.10 -->
<dependency>
<groupId>org.apache.spark</groupId>
<artifactId>spark-mllib_2.10</artifactId>
<version>2.1.0</version>
</dependency>