by Matt Revelle
A few months back I started working on a news classifier for Highput. I had originally planned to use Clojure to write Hadoop jobs, but found that most of the input data was available as a stream and the allure of continuously producing results was too much. RSS feeds, twitter streams, and collaborative ranking (e.g, HN, reddit) are continuous, the classifier should be as well. The data retrieval, extraction, transformation, and loading (ETL) was done using a distributed workflow built from three simple components...
January, 3 2010 • 0 Comments • 1 Faves
Earlier today on #clojure, there was a brief discussion on how larger (including infinite!) arity functions are implemented in Clojure. An example similar to what started the discussion: (apply + (range 100)) The interesting bit happens in RestFn and how the compiler lays out the bytecode. The implementation of + is: (defn + "Returns the sum of nums. (+) returns 0." {:inline (fn [x y] `(. clojure.lang.Numbers (add ~x ~y))) :inline-arities #{2}} ([] 0) ([x] (cast Number x)) ([x y] (. clojure...
June, 20 2009 • 0 Comments • 0 Faves