Package jazzparser :: Package misc :: Package chordlabel :: Module baumwelch
[hide private]
[frames] | no frames]

Module baumwelch

source code

Baum-Welch EM trainer for the chord labeling model.


Author: Mark Granroth-Wilding <mark.granroth-wilding@ed.ac.uk>

Classes [hide private]
  HPBaumWelchTrainer
Baum-Welch training for jazzparser.misc.chordlabel.HPChordLabeler models.
Functions [hide private]
 
sequence_updates(sequence, last_model, empty_arrays, array_ids, update_initial=True)
Evaluates the forward/backward probability matrices for a single sequence under the model that came from the previous iteration and returns matrices that contain the updates to be made to the distributions during this iteration.
source code
Variables [hide private]
  ADD_SMALL = 1e-06
  __package__ = 'jazzparser.misc.chordlabel'
Function Details [hide private]

sequence_updates(sequence, last_model, empty_arrays, array_ids, update_initial=True)

source code 

Evaluates the forward/backward probability matrices for a single sequence under the model that came from the previous iteration and returns matrices that contain the updates to be made to the distributions during this iteration.

This is wrapped up in a function so it can be run in parallel for each sequence. Once all sequences have been evaluated, the results are combined and model updated.

Parameters:
  • update_initial (bool) - if update_initial=False, the initial state distribution updates won't be made for this sequence