Archive for January, 2013

On Structural Immutability

Posted: January 21, 2013 in Uncategorized

Recently I’ve being doing quite a bit of coding with vectors, matrices and various higher dimensional mathematical arrays. This is motivated by the fact that I need them for my work at Nuroko, and also because I’m working on a new library for numerical computing in Clojure: core.matrix

There’s lots of interesting stuff to do in this space, but one detail that has recently caught my eye is the concept which, for want of a a better definition, I’m calling “Structural Immutability”.

(more…)

Advertisements

My machine learning talk from the Clojure Conj 2012 is now online:

Enjoy!

“The first rule of macro club is: Don’t write macros”

I wrote this originally as an answer to a StackOverflow question. But the question got closed by some trigger-happy mods before I clicked post. How unfriendly!

Anyway, in case it is useful to people wondering when they should and shouldn’t use macros, I thought I would post it here instead….

(more…)

Matrices and vectors are the fundamental building blocks of many of the areas of programming I find most interesting: machine learning, simulations, statistical analysis, 3D games, computer-generated art etc.

Unfortunately, using matrices presents some problems in the Clojure world. There are actually a number of really good libraries available, but they are all incompatible and designed / optimised for different use cases. Choosing the right one is hard, and a lot of effort gets wasted converting between them and duplicating code.

This post is about how we might fix this in the Clojure world

(more…)

Evolutionary art with Clojure

Posted: January 3, 2013 in Uncategorized

Came across a great little project for evolutionary art with Clojure:

The concept is simple but powerful – apply evolutionary principles to images, where the “DNA” of the image is a S-expression that generates it. New images can be created by random mutation / crossover of previous images.

The “fitness” function is just a simple subjective evaluation by the human “do I like this image?”

It uses Clisk under the hood for image generation.