类 VectorAssembler
- java.lang.Object
-
- org.apache.flink.ml.feature.vectorassembler.VectorAssembler
-
- 所有已实现的接口:
Serializable,org.apache.flink.ml.api.AlgoOperator<VectorAssembler>,org.apache.flink.ml.api.Stage<VectorAssembler>,org.apache.flink.ml.api.Transformer<VectorAssembler>,org.apache.flink.ml.common.param.HasHandleInvalid<VectorAssembler>,org.apache.flink.ml.common.param.HasInputCols<VectorAssembler>,org.apache.flink.ml.common.param.HasOutputCol<VectorAssembler>,VectorAssemblerParams<VectorAssembler>,org.apache.flink.ml.param.WithParams<VectorAssembler>
public class VectorAssembler extends Object implements org.apache.flink.ml.api.Transformer<VectorAssembler>, VectorAssemblerParams<VectorAssembler>
A Transformer which combines a given list of input columns into a vector column. Input columns would be numerical or vectors whose sizes are specified by theVectorAssemblerParams.INPUT_SIZESparameter. Invalid input data with null values or values with wrong sizes would be dealt with according to the strategy specified by theHasHandleInvalidparameter as follows:- keep: If the input column data is null, a vector would be created with the specified size and NaN values. The vector would be used in the assembling process to represent the input column data. If the input column data is a vector, the data would be used in the assembling process even if it has a wrong size.
- skip: If the input column data is null or a vector with wrong size, the input row would be filtered out and not be sent to downstream operators.
- error: If the input column data is null or a vector with wrong size, an exception would be thrown.
- 另请参阅:
- 序列化表格
-
-
字段概要
-
从接口继承的字段 org.apache.flink.ml.common.param.HasHandleInvalid
ERROR_INVALID, HANDLE_INVALID, KEEP_INVALID, SKIP_INVALID
-
从接口继承的字段 org.apache.flink.ml.feature.vectorassembler.VectorAssemblerParams
INPUT_SIZES
-
-
构造器概要
构造器 构造器 说明 VectorAssembler()
-
方法概要
所有方法 静态方法 实例方法 具体方法 修饰符和类型 方法 说明 Map<org.apache.flink.ml.param.Param<?>,Object>getParamMap()static VectorAssemblerload(org.apache.flink.table.api.bridge.java.StreamTableEnvironment env, String path)voidsave(String path)org.apache.flink.table.api.Table[]transform(org.apache.flink.table.api.Table... inputs)-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
从接口继承的方法 org.apache.flink.ml.feature.vectorassembler.VectorAssemblerParams
getInputSizes, setInputSizes
-
-
-
-
方法详细资料
-
transform
public org.apache.flink.table.api.Table[] transform(org.apache.flink.table.api.Table... inputs)
- 指定者:
transform在接口中org.apache.flink.ml.api.AlgoOperator<VectorAssembler>
-
save
public void save(String path) throws IOException
- 指定者:
save在接口中org.apache.flink.ml.api.Stage<VectorAssembler>- 抛出:
IOException
-
load
public static VectorAssembler load(org.apache.flink.table.api.bridge.java.StreamTableEnvironment env, String path) throws IOException
- 抛出:
IOException
-
getParamMap
public Map<org.apache.flink.ml.param.Param<?>,Object> getParamMap()
- 指定者:
getParamMap在接口中org.apache.flink.ml.param.WithParams<VectorAssembler>
-
-