Model (Spark 4.2.0 JavaDoc)
- Type Parameters:
M- model type
- All Implemented Interfaces:
Serializable,org.apache.spark.internal.Logging,Params,Identifiable
- Direct Known Subclasses:
ALSModel,BisectingKMeansModel,BucketedRandomProjectionLSHModel,Bucketizer,ChiSqSelectorModel,CountVectorizerModel,CrossValidatorModel,FPGrowthModel,GaussianMixtureModel,IDFModel,ImputerModel,IsotonicRegressionModel,KMeansModel,LDAModel,MaxAbsScalerModel,MinHashLSHModel,MinMaxScalerModel,OneHotEncoderModel,OneVsRestModel,PCAModel,PipelineModel,PredictionModel,RFormulaModel,RobustScalerModel,StandardScalerModel,StringIndexerModel,TargetEncoderModel,TrainValidationSplitModel,UnivariateFeatureSelectorModel,VarianceThresholdSelectorModel,VectorIndexerModel,Word2VecModel
public abstract class Model<M extends Model<M>> extends Transformer
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.spark.internal.Logging
org.apache.spark.internal.Logging.LogStringContext, org.apache.spark.internal.Logging.SparkShellLoggingFilter -
Constructor Summary
Constructors
-
Method Summary
abstract MCreates a copy of this instance with the same UID and some extra params.
booleanIndicates whether this
Modelhas a corresponding parent.parent()The parent estimator that produced this model.
Sets the parent of this model (Java API).
Methods inherited from interface org.apache.spark.internal.Logging
initializeForcefully, initializeLogIfNecessary, initializeLogIfNecessary, initializeLogIfNecessary$default$2, isTraceEnabled, log, logBasedOnLevel, logDebug, logDebug, logDebug, logDebug, logError, logError, logError, logError, logInfo, logInfo, logInfo, logInfo, logName, LogStringContext, logTrace, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, logWarning, MDC, org$apache$spark$internal$Logging$$log_, org$apache$spark$internal$Logging$$log__$eq, withLogContextMethods inherited from interface org.apache.spark.ml.param.Params
clear, copyValues, defaultCopy, estimateMatadataSize, explainParam, explainParams, extractParamMap, extractParamMap, get, getDefault, getOrDefault, getParam, hasDefault, hasParam, isDefined, isSet, onParamChange, set, set, set, setDefault, setDefault, shouldOwn
-
Constructor Details
-
Model
public Model()
-
-
Method Details
-
copy
public abstract M copy
(ParamMap extra) Description copied from interface:
ParamsCreates a copy of this instance with the same UID and some extra params. Subclasses should implement this method and set the return type properly. See
defaultCopy().- Specified by:
copyin interfaceParams- Specified by:
copyin classTransformer- Parameters:
extra- (undocumented)- Returns:
- (undocumented)
-
hasParent
public boolean hasParent()
Indicates whether this
Modelhas a corresponding parent. -
parent
The parent estimator that produced this model.
- Returns:
- (undocumented)
- Note:
- For ensembles' component Models, this value can be null.
-
setParent
Sets the parent of this model (Java API).
- Parameters:
parent- (undocumented)- Returns:
- (undocumented)
-