|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Objectorg.apache.spark.mllib.clustering.PowerIterationClusteringModel
public class PowerIterationClusteringModel
:: Experimental ::
Model produced by PowerIterationClustering
.
param: k number of clusters
param: assignments an RDD of clustering PowerIterationClustering#Assignment
s
Constructor Summary | |
---|---|
PowerIterationClusteringModel(int k,
RDD<PowerIterationClustering.Assignment> assignments)
|
Method Summary | |
---|---|
RDD<PowerIterationClustering.Assignment> |
assignments()
|
int |
k()
|
static PowerIterationClusteringModel |
load(SparkContext sc,
String path)
|
void |
save(SparkContext sc,
String path)
Save this model to the given path. |
Methods inherited from class Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PowerIterationClusteringModel(int k, RDD<PowerIterationClustering.Assignment> assignments)
Method Detail |
---|
public static PowerIterationClusteringModel load(SparkContext sc, String path)
public int k()
public RDD<PowerIterationClustering.Assignment> assignments()
public void save(SparkContext sc, String path)
Saveable
This saves: - human-readable (JSON) model metadata to path/metadata/ - Parquet formatted data to path/data/
The model may be loaded using Loader.load
.
save
in interface Saveable
sc
- Spark context used to save model data.path
- Path specifying the directory in which to save this model.
If the directory already exists, this method throws an exception.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |