use of com.alibaba.alink.pipeline.Pipeline in project Alink by alibaba.
the class LogisticRegressionMixVecTest method batchMixVecTest15.
@Test
public void batchMixVecTest15() {
BatchOperator<?> trainData = (BatchOperator<?>) getData();
Pipeline pipeline = new Pipeline().add(new LogisticRegression().setVectorCol("svec2").setWithIntercept(false).setStandardization(false).setLabelCol("labels").setPredictionCol("pred"));
PipelineModel model = pipeline.fit(trainData);
model.transform(trainData).collect();
}
use of com.alibaba.alink.pipeline.Pipeline in project Alink by alibaba.
the class LogisticRegressionMixVecTest method batchMixVecTest8.
@Test
public void batchMixVecTest8() {
BatchOperator<?> trainData = (BatchOperator<?>) getData();
Pipeline pipeline = new Pipeline().add(new LogisticRegression().setVectorCol("vec").setWithIntercept(false).setStandardization(true).setLabelCol("labels").setPredictionCol("pred"));
PipelineModel model = pipeline.fit(trainData);
model.transform(trainData).collect();
}
use of com.alibaba.alink.pipeline.Pipeline in project Alink by alibaba.
the class LogisticRegressionMixVecTest method batchMixVecTest6.
@Test
public void batchMixVecTest6() {
BatchOperator<?> trainData = (BatchOperator<?>) getData();
Pipeline pipeline = new Pipeline().add(new LogisticRegression().setVectorCol("vec").setWithIntercept(false).setStandardization(false).setLabelCol("labels").setPredictionCol("pred"));
PipelineModel model = pipeline.fit(trainData);
model.transform(trainData).collect();
}
use of com.alibaba.alink.pipeline.Pipeline in project Alink by alibaba.
the class LogisticRegressionMixVecTest method batchMixVecTest12.
@Test
public void batchMixVecTest12() {
BatchOperator<?> trainData = (BatchOperator<?>) getData();
Pipeline pipeline = new Pipeline().add(new VectorAssembler().setSelectedCols(new String[] { "svec", "vec", "f0", "f1", "f2", "f3" }).setOutputCol("allvec")).add(new LogisticRegression().setVectorCol("allvec").setWithIntercept(true).setReservedCols(new String[] { "labels", "allvec" }).setLabelCol("labels").setPredictionCol("pred"));
PipelineModel model = pipeline.fit(trainData);
model.transform(trainData).collect();
}
use of com.alibaba.alink.pipeline.Pipeline in project Alink by alibaba.
the class LogisticRegressionMixVecTest method batchMixVecTest23.
@Test
public void batchMixVecTest23() {
BatchOperator<?> trainData = (BatchOperator<?>) getData();
Pipeline pipeline = new Pipeline().add(new LogisticRegression().setVectorCol("svec2").setWithIntercept(true).setStandardization(false).setLabelCol("labels").setPredictionCol("pred"));
PipelineModel model = pipeline.fit(trainData);
model.transform(trainData).collect();
}
Aggregations