VectorAssembler无法强制转换为org.apache.spark.ml.feature.OneHotEncoder

时间:2016-09-16 20:14:21

标签: java-8 apache-spark-sql

是否可以将VectorAssembler转换为OneHotEncoder

以下代码是我疯狂的测试。

Pipeline lPipeline = new Pipeline();
lPipeline.setStages(this.getPipelineStages());
OneHotEncoder lOHE1 = (OneHotEncoder)lPipeline.getStages()[2];

0 个答案:

没有答案