1

How can I use Speex to encode/decode from within python? Are there any wrappers? I found an old project pySpeex but it is obsolete now (requires Python 2.2).

Ηλίας
  • 2,560
  • 4
  • 30
  • 44

1 Answers1

1

I think starting from pySpeex (and tweaking any issue that may arise if you're using Python 2.6, say, in lieu of 2.2) is by far the path of least resistance -- there aren't that many backward incompatibilities between 2.2 and 2.6, after all, so the amount of work should be pretty limited (and then you can contribute the patches, if any, back to pySpeex's maintainers to gain some good karma -- why not, after all?).

Alex Martelli
  • 854,459
  • 170
  • 1,222
  • 1,395
  • That would be an interesting project! – Ηλίας Mar 27 '10 at 08:50
  • 1
    if you look here http://www.voicechatter.org/forum/viewtopic.php?f=10&t=563 somebody has succesfully compiled it probably on 2.6. – systempuntoout Mar 27 '10 at 13:39
  • 1
    System, as the author of that file I have to tell you, that wasn't a compile. I had help putting that together. They aren't PySpeex based, that is actually a direct Ctypes library that quite frankly sucks. Since Python is handling all of the types and function calls (which incur quite the overhead) it doesn't scale well at all. PySpeex is compiled with Pyrex, which is pretty much dead at this point in time, and that's the only solution I had. Not knowing a thing about C, I didn't know how to port the pyx over to Cython appropriately. – ThantiK Jun 13 '11 at 16:13