[Python-projects] HMM test cases

Orestis Markou orestis at orestis.gr
Mon Feb 11 10:39:45 CET 2008


Replying to python-projects for posterity. In my case I have ~350  
states and ~460 observations and the numpy performance is good enough.  
I'll look into potential improvements, though.
--
Orestis Markou
orestis at orestis.gr
http://orestis.gr/




On 11 Φεβ 2008, at 11:28 ΠΜ, Ludovic.Aubry wrote:

> On Mon, Feb 11, 2008 at 11:05:05AM +0200, Orestis Markou wrote:
>> Hi, thanks for answering.
>>
>> As it turns out, I fixed my numpy implementation (I've only  
>> implemented
>> forward and viterbi, for now). I used unittests with small models and
>> compared forward probability and viterbi results with the old and new
>> model. You can find my (very basic) implementation at
>> http://code.google.com/p/greeklish/source/browse/trunk/greeklish/new_hmm.py
>>
>> (disregard the methods starting with _, they're just testing my numpy
>> porting logic)
>>
>> I was wondering why numpy wasn't fast enough for you. Did you  
>> actually
>> see a big improvement with C or Fortran?
> That's only for training (estimating A and B from data) that we  
> needed C
> or Fortran; mostly because we tried to do train chains with about 30  
> states
> and 300000 possible observations.
>
> ps: As Alexandre told you, we should follow-up this conversation on
> python-projects at logilab.org or at least drop contact at logilab.fr from  
> CC.
> -- 
> Ludovic Aubry                                 LOGILAB, Paris (France).
> http://www.logilab.com   http://www.logilab.fr  http://www.logilab.org



More information about the Python-Projects mailing list