Using python and matplotlib, I would like to compute some data, then plot it in a window, then compute some more, then update the plot in the same window. Each computation can be 1 second to 1 minute. Is there a way to achieve this without pain, across platforms (including osx)?
I know that 'interactive mode' is supposed to handle this. But this requires changing the backend of matplotlib and installing a special "framework build" of python on osx. Completely unacceptable. I really don't want to require users to do that.
Animations in matplotlib are time-driven, not 'event driven'. Impedance mismatch: doable, but not great - I would have to put the 'computation loop' into the 'animation loop'. I'd rather not.
Multiprocessing to the rescue? i.e. compute, throw results to separate process over queue, render in the other process? I can't, for the life of me, get matplotlib to render anything in another process. Maybe this is another 'backend/build' issue.
...there's gotta be a way, this seems so basic...