public class LogisticRegressionModelServable extends Object implements ModelServable<LogisticRegressionModelServable>, LogisticRegressionModelParams<LogisticRegressionModelServable>
FEATURES_COL
PREDICTION_COL
RAW_PREDICTION_COL
Constructor and Description |
---|
LogisticRegressionModelServable() |
Modifier and Type | Method and Description |
---|---|
Map<Param<?>,Object> |
getParamMap()
Returns a map which should contain value for every parameter that meets one of the following
conditions.
|
static LogisticRegressionModelServable |
load(String path) |
LogisticRegressionModelServable |
setModelData(InputStream... modelDataInputs)
Sets model data using the serialized model data from the given input streams.
|
DataFrame |
transform(DataFrame input)
Applies the TransformerServable on the given input DataFrame and returns the result
DataFrame.
|
protected org.apache.flink.api.java.tuple.Tuple2<Double,DenseVector> |
transform(Vector feature)
The main logic that predicts one input data point.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getFeaturesCol, setFeaturesCol
getPredictionCol, setPredictionCol
getRawPredictionCol, setRawPredictionCol
get, getParam, set
public DataFrame transform(DataFrame input)
TransformerServable
transform
in interface TransformerServable<LogisticRegressionModelServable>
input
- the input datapublic LogisticRegressionModelServable setModelData(InputStream... modelDataInputs) throws IOException
ModelServable
setModelData
in interface ModelServable<LogisticRegressionModelServable>
IOException
public static LogisticRegressionModelServable load(String path) throws IOException
IOException
protected org.apache.flink.api.java.tuple.Tuple2<Double,DenseVector> transform(Vector feature)
feature
- The input feature.public Map<Param<?>,Object> getParamMap()
WithParams
1) set(...) has been called to set value for this parameter.
2) The parameter is a public final field of this WithParams instance. This includes fields inherited from its interfaces and super-classes.
The subclass which implements this interface could meet this requirement by returning a
member field of the given map type, after having initialized this member field using the
ParamUtils.initializeMapWithDefaultValues(Map, WithParams)
method.
getParamMap
in interface WithParams<LogisticRegressionModelServable>
Copyright © 2019–2023 The Apache Software Foundation. All rights reserved.