Package jazzparser :: Package formalisms :: Package music_halfspan :: Package semantics :: Module distance :: Class OptimizedDependencyRecovery
[hide private]
[frames] | no frames]

Class OptimizedDependencyRecovery

source code

                            object --+        
                                     |        
base.semantics.distance.DistanceMetric --+    
                                         |    
      base.semantics.distance.FScoreMetric --+
                                             |
                                            OptimizedDependencyRecovery

Aligns the two dependency graphs in the way that optimizes their dependency recovery and reports that dependency recovery. This gives a metric that can be used when the alignment between the graphs is not known, such as when parsing MIDI.

Instance Methods [hide private]
 
_get_identifier(self)
A human-readable identifier for the metric represented by this instance.
source code
 
fscore_match(self, sem1, sem2)
Subclasses must provide this.
source code

Inherited from base.semantics.distance.FScoreMetric: distance, format_distance, total_distance

Inherited from base.semantics.distance.DistanceMetric: __init__, print_computation

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

Class Variables [hide private]
  name = 'optdeprec'

Inherited from base.semantics.distance.FScoreMetric: OPTIONS

Properties [hide private]
  identifier
A human-readable identifier for the metric represented by this instance.

Inherited from object: __class__

Method Details [hide private]

_get_identifier(self)

source code 

A human-readable identifier for the metric represented by this instance.

Overrides: base.semantics.distance.DistanceMetric._get_identifier
(inherited documentation)

fscore_match(self, sem1, sem2)

source code 

Subclasses must provide this. It should return a tuple. The first three values must be floats: score given to the matching between the two inputs; max score that could be given to the first; max score for the second. There may be more values in the tuple.

Overrides: base.semantics.distance.FScoreMetric.fscore_match
(inherited documentation)

Property Details [hide private]

identifier

A human-readable identifier for the metric represented by this instance.

Get Method:
_get_identifier(self) - A human-readable identifier for the metric represented by this instance.