Thanks, that would be useful.  It appears PyAudio is the closest to what I need.  So seeing how to translate numpy data into PyAudio data would be useful.

On Tue, Mar 24, 2015 at 10:27 PM, Hjalmar Turesson <hturesson@gmail.com> wrote:
I have a little function that plays back numpy arrays using PyAudio. I think PyAudio is pretty platform independent (but it takes a bit of installing). My code is not perfect, but it is simple and works ok. Want it?

Hjalmar

On Tue, Mar 24, 2015 at 6:15 PM, Todd <toddrjen@gmail.com> wrote:


On Mar 24, 2015 9:51 PM, "Kiko" <kikocorreoso@gmail.com> wrote:
>
>
>
> 2015-03-24 21:39 GMT+01:00 Todd <toddrjen@gmail.com>:
>>
>> Is anyone aware of a well-maintained, simple, cross-platform python package that can play a numpy array as sound over speakers? 
>>
>> I am aware of https://wiki.python.org/moin/Audio/.  However, in all the cases there, as far as I can find they either do not support numpy arrays, are not cross-platform, cannot playback sound at all, or are unmaintained.  There is also PySoundCard, which would do what I need but also appears to be unmaintained (no release in over a year, and no commits in 5 months, no release with serious bugfixes mentioned in commits).
>
>
> Could this be useful for your use case? http://nbviewer.ipython.org/github/ipython/ipython/blob/2.x/examples/Interactive%20Widgets/Beat%20Frequencies.ipynb
>  

Sorry, I should have been more specific.  I am really looking for a way to play audio as part of a script.  Your link would certainly work for playing back sound in an interactive manner in a notebook. However, it is not really useful as part general-purpose script or function,  or when control of the playback is needed. Thank you, though, that is certainly very useful in many situations.


_______________________________________________
SciPy-User mailing list
SciPy-User@scipy.org
http://mail.scipy.org/mailman/listinfo/scipy-user



_______________________________________________
SciPy-User mailing list
SciPy-User@scipy.org
http://mail.scipy.org/mailman/listinfo/scipy-user