Package ML :: Package Composite :: Module CompositeCOM :: Class CompositeServer
[hide private]
[frames] | no frames]

Class CompositeServer

source code

object --+
         |
        CompositeServer

exposes an interface for composite COM servers

This interface does not support modifying the composite, only
 classifying new examples

**Public Methods**

 - LoadComposite

 - ClassifyExample

 - ShowComposite

 - GetVoteDetails

 - SetInputOrder

 - GetDescriptorNames

 - Close

**Public Attributes**

  None
 
**ProgID**

  RD.Composite



Instance Methods [hide private]
 
Close(self)
Blows out the local composite...
source code
 
LoadComposite(self, fileName)
Loads a (pickled) composite from a file...
source code
 
ShowComposite(self)
returns a string representation of the composite...
source code
 
GetVoteDetails(self)
returns a list of the results of the last vote...
source code
 
SetInputOrder(self, colNames)
Sets the input order for the composite...
source code
 
GetDescriptorNames(self)
returns a list of the descriptor names the composite expects...
source code
 
ClassifyExample(self, example, threshold=0)
classifies a new example...
source code

Inherited from object: __delattr__, __getattribute__, __hash__, __init__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Class Variables [hide private]
  _public_methods_ = ['LoadComposite', 'ClassifyExample', 'ShowC...
  _public_attrs_ = []
  _reg_clsid_ = '{9F62358E-9043-4BF9-93C7-47BED8BE522F}'
  _reg_progid_ = "RD.Composite"
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

Close(self)

source code 
Blows out the local composite

**Note**

  _LoadComposite()_ must be called after this for further use of the
  composite

LoadComposite(self, fileName)

source code 
Loads a (pickled) composite from a file

**Arguments**
  - fileName: the name of the file to load

ShowComposite(self)

source code 
returns a string representation of the composite

    

GetVoteDetails(self)

source code 
returns a list of the results of the last vote

    

SetInputOrder(self, colNames)

source code 
Sets the input order for the composite

this is used so that the composite can remap inputs which are not
in an order it expects

**Arguments**

  - colNames: a list of the names of the columns in the data which will be
     passed in to the composite

**Notes**

  - there must be a column name which matches each of the composite's
    descriptors (accessible via _GetDescriptorNames()_)

GetDescriptorNames(self)

source code 
returns a list of the descriptor names the composite expects

    

ClassifyExample(self, example, threshold=0)

source code 
classifies a new example

**Arguments**

  - example: a list containing the example to be classified

  - threshold: the threshold to be used for high-confidence predictions

**Returns**

  a list two elements long:

     1) the classification (this will be -1 if the confidence of the prediction
        was below _threshold_

     2) the confidence


Class Variable Details [hide private]

_public_methods_

Value:
['LoadComposite', 'ClassifyExample', 'ShowComposite', 'GetVoteDetails'\
, 'SetInputOrder', 'GetDescriptorNames', 'Close']