Package tipy :: Module cmbn :: Class Combiner
[hide private]
[frames] | no frames]

Class Combiner

source code

object --+
         |
        Combiner
Known Subclasses:

Base class for all combiners.

Class Hierarchy for Combiner
Class Hierarchy for Combiner

Nested Classes [hide private]
  __metaclass__
Metaclass for defining Abstract Base Classes (ABCs).
Instance Methods [hide private]
 
__init__(self)
Combiner creator.
source code
Prediction
filter(self, prediction)
Sort the tokens according to their probabilities.
source code
 
combine(self, predictionList)
Method for combining predictors's prediction list.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  MIN_PROBABILITY = 0.0
  MAX_PROBABILITY = 1.0
  __abstractmethods__ = frozenset(['combine'])
  _abc_cache = <_weakrefset.WeakSet object at 0x7f2a42360ed0>
  _abc_negative_cache = <_weakrefset.WeakSet object at 0x7f2a423...
  _abc_negative_cache_version = 39
  _abc_registry = <_weakrefset.WeakSet object at 0x7f2a42360e90>
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

source code 

Combiner creator.

Overrides: object.__init__

filter(self, prediction)

source code 

Sort the tokens according to their probabilities.

The duplicate tokens are merged to a single token (their probabilities are summed).

Parameters:
Returns: Prediction
The sorted Prediction instance.

combine(self, predictionList)

source code 

Method for combining predictors's prediction list.

The combine() method is the main method of the Combiner. It must be implemented by every combiners.

Decorators:
  • @abc.abstractmethod

Class Variable Details [hide private]

_abc_negative_cache

Value:
<_weakrefset.WeakSet object at 0x7f2a42360f10>