Category Archives: Coding

Clustering coordinate points together with quad-trees

Recently I needed to show a heat map of a quite a lot of coor­di­nate points for a little project of mine that ended up in a data visu­al­iza­tion con­test (that unfor­tu­nately I didn’t win, even though I made to the final­ists). The idea was to show the dis­tri­b­u­tion of the geo­ref­er­enced wikipedia pages through a heat map, so when I first heard about open​heatmap.com I knew it was the tool to use. Open​HeatMap.com is an excel­lent project by Pete Warden that takes a dataset as a CSV, Excel or Google Spread­sheet file and con­vert it to a nice, brows­able heat map pre­sen­ta­tion.
Read more »

Simulated Annealing

For a prob­lem I’m work­ing on I got stuck onto the clas­si­cal sit­u­a­tion of local max­i­mum. After trying to work around the prob­lem in sev­eral more or less cre­ative ways, I thought of the sim­u­lated anneal­ing algo­rithm. Con­sid­er­ing it’s been a while since I last saw it I tried to search for it on the web and sur­pris­ingly there is not much stuff about it, and the few bits I found are often con­trad­dic­tory. After quite a lot of dig­ging I decided to write about it here. As a warn­ing I should prob­a­bly say that there will be dig­ging into some basic sta­tis­tic and com­plex­ity analy­sis, as well as a quick formal intro­duc­tion to the prob­lem of the knap­sack. You should be able to follow even if you don’t know noth­ing about those topics, but having some foun­da­tions in these areas would be of great help.
Read more »

Google Wave impressions from a developer point of view

A couple of days ago I finally had my Google Wave sand­box account. Given that I just fin­ished devel­op­ing my very first robot, I thought I’d share some impres­sions on the whole thing. From the user-​side, things are far from being ready. Some impor­tant fea­tures are still miss­ing, just to name one you can’t remove user from a wave once they joined (or, alter­na­tively, there’s no way to ignore a wave). Indeed, given that I joined sev­eral waves to try other people appli­ca­tions, I’m get­ting con­tin­u­ous noti­fi­ca­tions. But anyway, the whole thing is to me like a great devel­op­ment play­ground where I can make all the sorts of experiments.

Read more »

Dealing with algorithms and data structures

One of the rea­sons I haven’t been writ­ing on this blog that much lately is that I’ve been ter­ri­bly busy with uni­ver­sity given that I just cleared out six exams in six months. That said, for one of my three exams that I still have left, I had to develop an infer­ence engine writ­ten in C++. Since this was a fairly large project that had to deal with some sort of NP-​complete prob­lems (see also: uni­fi­ca­tion) and given that this was the first time I wrote some­thing seri­ous in C++ (i.e.: that would involve more than a class and that didn’t con­tain the “Hello world” string) I had the chance to learn quite a few new things.

Read more »