please help the newbie!

dpickles at pacbell.net dpickles at pacbell.net
Fri Jan 6 00:27:34 EST 2006


In my Python research, I have found a nice little voice recognition
script on the internet that does exactly what I need, and the demo
recognizes phrases with pretty much 100%accuracy.
The script can be found here:

http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/93025

What I want to do is make this code into a module, so I can use it in
other programs. For example:

import voicerecognition as vr
vr.StartRecognition(["one", "two", "three"])
result = vr.GetRecognized()
if result == "one":
     print "You said: one"
else:
     print "You did not say 'one'."


Any help would be appreciated. I have tried this, but IDLE keeps
freezing whenever I try to use the module with a test script.
As I said, I am a newbie and do not know very much about classes,
instances, and all those __funky__ modules.

Can anybody give me some tips on turning this into a module???
Thank you!




More information about the Python-list mailing list