More abstractly, I think Prismatic's Graph library [1] is very similar to the topologies that you are describing. Unfortunately, they haven't open-sourced it yet. In the article they touch upon the subject of different ways to execute the same graph, which would allow you to parallelize parts that don't depend on each other (see 'Flexible execution strategies' section).
[1]: http://blog.getprismatic.com/blog/2012/10/1/prismatics-graph-at-strange-loop.html Stathis On Friday, 9 November 2012 23:37:49 UTC, Stephen Olsen wrote: > > Hey all, > > I've been thinking about and wanting to do some music transcription > projects recently (inferring musical notes from audio) and what the best > way to write systems like this is clojure would be. There are java > libraries and things like fftw that can handle the *hard* parts like > computing fourier transformations. These libraries are not necessarily easy > to use idiomatically from clojure or easily composable though. I'm also > having a hard time seeing the best way to wire up different components so > that a stream of audio can flow between them. > > What I think I want is a toolkit for creating signal processing graphs in > idiomatic clojure. It seems like the main abstractions that I'd want would > be similar to what storm uses for data processing; stream sources, bolts > and topologies to show how they connect. That way one could code up some > pieces, use common built in bolts to get things like frequency information, > declare how the pieces fit together and then run the system in a variety of > different ways. > > I'd also like the library to be built on a set of protocols so the > processing graphs can be run in a variety of settings. In process in an > async manner (something similar to the way lamina works), paralyzed across > many machines with storm or even in the web browser leveraging the new > html5 audio data apis. > > I plan to build this library and what I'm looking for is some feedback and > guidance before I begin. I'd especially love to hear from anyone that is > working on these kinds of systems in clojure. > > A Couple of the main questions I have before I can begin are these. > > 1) Are streams, bolts and topologies the right level of abstraction for > building systems like this? They will need to be a little more complicated > than the way storm does things I think. Different bolts will need to > operate on different length intervals of the signal. (an fft bolt will need > one bin size but then later down stream a pitch tracking bolt will need > different interval sizes) I guess giving bolts a buffer size would be > necessary and every time that buffer is filled the analysis function would > be called. > > 2) What is the best way to implement asynchronous streaming binary data in > clojure? > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en