Number element slow to decode (5 seconds to recognize number 120)

27 views
Skip to first unread message

Jason Veldicott

unread,
Mar 9, 2012, 12:39:43 AM3/9/12
to dragonf...@googlegroups.com
It takes 4.9 seconds on my computer to decode "one hundred and twenty".  Code used is included below. 

The Number element is a great one to have, allowing natural number dictation, but this kind of delay would be noticeable during dictation.

My impression is that it may be due to a large parse tree being generated for number recognition.

Enhancement in a later version to improve speed?

Jason


words = [("one", 1000000), etc...
start = time.clock()
r=Number(name="number")         
s = state_.State(words, [], None)   # <== may need to add engine here in last arg
s.initialize_decoding()
for result in r.decode(s):
    if s.finished():                 
        root = s.build_parse_tree()                
        Text(str(root.value()), pause=0).execute()
        end = time.clock()
        print "TIME: %.2gs" % (end-start)           
        return

Jason Veldicott

unread,
Mar 9, 2012, 2:33:03 AM3/9/12
to dragonf...@googlegroups.com
Oops.. it's now taking 0.8 seconds.

Not sure why the change in time taken to decode. 


--
You received this message because you are subscribed to the Google Groups "Dragonfly Speech Recognition" group.
To view this discussion on the web visit https://groups.google.com/d/msg/dragonflyspeech/-/RIdQPT3RN3gJ.
To post to this group, send email to dragonf...@googlegroups.com.
To unsubscribe from this group, send email to dragonflyspee...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/dragonflyspeech?hl=en.

Reply all
Reply to author
Forward
0 new messages