Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: WavPack decoder in Python (Read 6989 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

WavPack decoder in Python

I recently decided to learn some Python, and to make it interesting for myself I decided to write a 'fun' program. The result is this WavPack decoder! The decoder is very slow (as Python is not really designed with heavy number crunching in mind) but it might be interesting for some people. I was also able to run this code on my phone - however as it took about 4 hours to decode one file I wouldn't suggest this as a solution for playing WavPack files on your phone 

Link to code

WavPack decoder in Python

Reply #1
Cool . I love python myself, but i seriously couldn't understand what was going on (this stuff is way too complicated for me.

Quote
however as it took about 4 hours to decode one file


haha. Maybe using numpy arrays would help?

How about building an encoder? that might be more fun.


WavPack decoder in Python

Reply #3
Maybe using numpy arrays would help?

How about building an encoder? that might be more fun.


Thanks, I'll check out numpy.
The code works fine with Psyco and gets a good speed-up using it, still too slow to be very useful though (on a machine that can decode a WavPack file in a few seconds with the C version it takes a couple of minutes with the Python decoder).
I'm actually current writing a WavPack encoder in Java    But I probably won't convert it to Python, I really only wrote the decoder to teach myself how Python is put together.