[Biojava-l] Relations between trainers

Matthew Pocock matthew_pocock at yahoo.co.uk
Wed Mar 5 22:47:49 EST 2003


Hi Oscar,

For viterbi training, you need to do the following:

* Create your model & initialize with random parameters
* Create a hmm training context and register the model with it
* do
   o foreach training sequence
     - get the viterbi aignment of the model to your sequence
     - add one count to the training context for each time a state or 
transition is used
   o call the context's train method
* while the alignments change

Good luck. I'd be interested to see what you end up with. If you need a 
hand with any of the APIs, send questions to the list.

Matthew

Oscar Lopes wrote:
> Hi!
> 
> I'm a graduate student and I'm using biojava to implement Viterbi 
> training algorithm.
> I spent some time digging in the code, but I still can't make the 
> relation between
> TrainigAlgorithm, DistributionTrainer, etc...
> 
> What are the key classes that I can use? How does it work? I tried to 
> look at
> BaumWelchTrainer, but it didn't make sense how I would implement Viterbi 
> Trainig.
> Besides, I kept getting confused with DistributionTrainer and 
> DistributionTrainerContext...
> 
> Can anybody help me?? It would be nice if someone explain to me how the 
> whole thing works.
> 
> Thanks in advance
> 
>                           Óscar Lopes
> 
> Ps. Sorry about my english.... :)
> 
> oscar at gauss.inesc.pt
> ombl at rnl.ist.utl.pt
> 
> _______________________________________________
> Biojava-l mailing list  -  Biojava-l at biojava.org
> http://biojava.org/mailman/listinfo/biojava-l
> 


-- 
BioJava Consulting LTD - Support and training for BioJava
http://www.biojava.co.uk



More information about the Biojava-l mailing list