Synapseml  0.10.0
Public Member Functions | Static Public Member Functions | List of all members
Synapse.ML.Nn.KNNModel Class Reference

KNNModel implements KNNModel More...

Inheritance diagram for Synapse.ML.Nn.KNNModel:
Inheritance graph
[legend]
Collaboration diagram for Synapse.ML.Nn.KNNModel:
Collaboration graph
[legend]

Public Member Functions

 KNNModel ()
 Creates a KNNModel without any parameters. More...
 
 KNNModel (string uid)
 Creates a KNNModel with a UID that is used to give the KNNModel a unique ID. More...
 
KNNModel SetBallTree (object value)
 Sets value for ballTree More...
 
KNNModel SetFeaturesCol (string value)
 Sets value for featuresCol More...
 
KNNModel SetK (int value)
 Sets value for k More...
 
KNNModel SetLeafSize (int value)
 Sets value for leafSize More...
 
KNNModel SetOutputCol (string value)
 Sets value for outputCol More...
 
KNNModel SetValuesCol (string value)
 Sets value for valuesCol More...
 
object GetBallTree ()
 Gets ballTree value More...
 
string GetFeaturesCol ()
 Gets featuresCol value More...
 
int GetK ()
 Gets k value More...
 
int GetLeafSize ()
 Gets leafSize value More...
 
string GetOutputCol ()
 Gets outputCol value More...
 
string GetValuesCol ()
 Gets valuesCol value More...
 
void Save (string path)
 Saves the object so that it can be loaded later using Load. Note that these objects can be shared with Scala by Loading or Saving in Scala. More...
 
JavaMLWriter Write ()
 
Returns
a JavaMLWriter instance for this ML instance.

 
JavaMLReader< KNNModelRead ()
 Get the corresponding JavaMLReader instance. More...
 

Static Public Member Functions

static KNNModel Load (string path)
 Loads the KNNModel that was previously saved using Save(string). More...
 

Detailed Description

KNNModel implements KNNModel

Constructor & Destructor Documentation

◆ KNNModel() [1/2]

Synapse.ML.Nn.KNNModel.KNNModel ( )
inline

Creates a KNNModel without any parameters.

◆ KNNModel() [2/2]

Synapse.ML.Nn.KNNModel.KNNModel ( string  uid)
inline

Creates a KNNModel with a UID that is used to give the KNNModel a unique ID.

Parameters
uidAn immutable unique ID for the object and its derivatives.

Member Function Documentation

◆ GetBallTree()

object Synapse.ML.Nn.KNNModel.GetBallTree ( )

Gets ballTree value

Returns
ballTree: the ballTree model used for performing queries

◆ GetFeaturesCol()

string Synapse.ML.Nn.KNNModel.GetFeaturesCol ( )

Gets featuresCol value

Returns
featuresCol: The name of the features column

◆ GetK()

int Synapse.ML.Nn.KNNModel.GetK ( )

Gets k value

Returns
k: number of matches to return

◆ GetLeafSize()

int Synapse.ML.Nn.KNNModel.GetLeafSize ( )

Gets leafSize value

Returns
leafSize: max size of the leaves of the tree

◆ GetOutputCol()

string Synapse.ML.Nn.KNNModel.GetOutputCol ( )

Gets outputCol value

Returns
outputCol: The name of the output column

◆ GetValuesCol()

string Synapse.ML.Nn.KNNModel.GetValuesCol ( )

Gets valuesCol value

Returns
valuesCol: column holding values for each feature (key) that will be returned when queried

◆ Load()

static KNNModel Synapse.ML.Nn.KNNModel.Load ( string  path)
static

Loads the KNNModel that was previously saved using Save(string).

Parameters
pathThe path the previous KNNModel was saved to
Returns
New KNNModel object, loaded from path.

◆ Read()

JavaMLReader<KNNModel> Synapse.ML.Nn.KNNModel.Read ( )

Get the corresponding JavaMLReader instance.

Returns
an JavaMLReader<KNNModel> instance for this ML instance.

◆ Save()

void Synapse.ML.Nn.KNNModel.Save ( string  path)

Saves the object so that it can be loaded later using Load. Note that these objects can be shared with Scala by Loading or Saving in Scala.

Parameters
pathThe path to save the object to

◆ SetBallTree()

KNNModel Synapse.ML.Nn.KNNModel.SetBallTree ( object  value)

Sets value for ballTree

Parameters
valuethe ballTree model used for performing queries
Returns
New KNNModel object

◆ SetFeaturesCol()

KNNModel Synapse.ML.Nn.KNNModel.SetFeaturesCol ( string  value)

Sets value for featuresCol

Parameters
valueThe name of the features column
Returns
New KNNModel object

◆ SetK()

KNNModel Synapse.ML.Nn.KNNModel.SetK ( int  value)

Sets value for k

Parameters
valuenumber of matches to return
Returns
New KNNModel object

◆ SetLeafSize()

KNNModel Synapse.ML.Nn.KNNModel.SetLeafSize ( int  value)

Sets value for leafSize

Parameters
valuemax size of the leaves of the tree
Returns
New KNNModel object

◆ SetOutputCol()

KNNModel Synapse.ML.Nn.KNNModel.SetOutputCol ( string  value)

Sets value for outputCol

Parameters
valueThe name of the output column
Returns
New KNNModel object

◆ SetValuesCol()

KNNModel Synapse.ML.Nn.KNNModel.SetValuesCol ( string  value)

Sets value for valuesCol

Parameters
valuecolumn holding values for each feature (key) that will be returned when queried
Returns
New KNNModel object

The documentation for this class was generated from the following file: