public class ALSModel extends Model<ALSModel> implements ALSParams
Constructor and Description |
---|
ALSModel(ALS parent,
ParamMap fittingParamMap,
int k,
RDD<scala.Tuple2<Object,float[]>> userFactors,
RDD<scala.Tuple2<Object,float[]>> itemFactors) |
Modifier and Type | Method and Description |
---|---|
ParamMap |
fittingParamMap()
Fitting parameters, such that parent.fit(..., fittingParamMap) could reproduce the model.
|
ALS |
parent()
The parent estimator that produced this model.
|
ALSModel |
setPredictionCol(String value) |
DataFrame |
transform(DataFrame dataset,
ParamMap paramMap)
Transforms the dataset with provided parameter map as additional parameters.
|
StructType |
transformSchema(StructType schema,
ParamMap paramMap)
:: DeveloperApi ::
|
transform, transform
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
alpha, getAlpha, getImplicitPrefs, getItemCol, getNonnegative, getNumItemBlocks, getNumUserBlocks, getRank, getRatingCol, getUserCol, implicitPrefs, itemCol, nonnegative, numItemBlocks, numUserBlocks, rank, ratingCol, userCol, validateAndTransformSchema
getMaxIter, maxIter
getRegParam, regParam
getPredictionCol, predictionCol
checkpointInterval, getCheckpointInterval
addOutputColumn, checkInputColumn, explainParams, get, getParam, isSet, paramMap, params, set, set, validate, validate
uid
initializeIfNecessary, initializeLogging, isTraceEnabled, log_, log, logDebug, logDebug, logError, logError, logInfo, logInfo, logName, logTrace, logTrace, logWarning, logWarning
public ALS parent()
Model
public ParamMap fittingParamMap()
Model
fittingParamMap
in class Model<ALSModel>
public ALSModel setPredictionCol(String value)
public DataFrame transform(DataFrame dataset, ParamMap paramMap)
Transformer
transform
in class Transformer
dataset
- input datasetparamMap
- additional parameters, overwrite embedded paramspublic StructType transformSchema(StructType schema, ParamMap paramMap)
PipelineStage
Derives the output schema from the input schema and parameters. The schema describes the columns and types of the data.
transformSchema
in class PipelineStage
schema
- Input schema to this stageparamMap
- Parameters passed to this stage