Want to discover music? Lose your iPod!

I was pretty upset when I discovered a few months ago that I had, substantially, lost all my music. Something actually worse than merely having all the files erased: for some reason I still don’t understand, my files had been corrupted (it seems) at random. Some of them you could play fine all the way through, some would stop in the middle of the song, some wouldn’t even start playing… A nightmare.

First, I had to find an automated way to detect corrupt files and either detect the cause or make sure no new files were getting corrupted every day. (The latter happened, so as of today I still don’t know how my library got spoiled.) Then, I had to build a new library from the remains of the previous one.

But my point is that this accident turned out to be a chance for me. A chance to give some thoughts to the way I listen to music, and discover how much I have been conditioned (yes, in the Pavlov understanding) by the iPod/iTunes way to listen to music. These are the thoughts I want to share today.
Continue reading

Reason and linear models

Today I found yet another (recent) paper reading:

It is reasonable to suppose that [complex phenomenon] can be approximated by a linear function of a combination of [collected features].

Wiktionary provides three possible meanings to the word “reasonable”:

  1. Just; fair; agreeable to reason.
  2. Not expensive; fairly priced.
  3. Satisfactory.

In this case, only the second one applies for sure. Otherwise, a linear model is indeed

  • simple, often the simplest, to use/solve,
  • readable: if the regressands have semantics, then so have the linear coefficients,
  • able to capture the dynamics of your problem, sometimes.

But this does not make it reasonable per se. If you have measures that validate your choice of this kind of model, then yes, there’s some reason around. Otherwise, please remind that not everything is approximable by a linear function (even in the real world) and explain what you mean by “reasonable”.

How to play any DVD on Ubuntu

I recently found myself in a situation where I couldn’t read a DVD I’d just bought here (in the US) because of the protections and region-lock on the disc. This got me pretty upset since every device on the chain and every piece of software involved were legal (my machine is a factory Sony Vaio Z running Ubuntu 11.04). So here is the summary of the additional software (legal as well) I had to install to get things working.

Continue reading

N900 tethering on Ubuntu 11.04

I’ve recently been unpleased to discover that tethering (over USB) my Nokia N900 didn’t work any more on Ubuntu 11.04 (even with up-to-date versions of all packages), while it used to work perfectly on 10.10 and 10.04. There is a thread on Ubuntu Forums about this, and an associated bug report on Launchpad. The fix I found is from Ubuntu Forums, here it is.

Edit: looks like the bug will be corrected in 11.10.

Continue reading

Student’s test in Python

I like to simulate stochastic processes, to the extent one can say such a thing… Anyway, I have to. In my experience, “simulation” often translates to “time-consuming process” while “stochastic” implies dealing with randomness, a world where intuition is sometimes misleading. As an example of things not to do in this world, I will report here on my last fail.

So I had these simulations to run. Each simulation was approximately an hour long, and yielded a real number. I then needed to run enough of them so I could estimate the mean output (with, say, 3 digits of precision). My first idea was to keep on launching new simulations until the first digits of the mean output, computed run after run, stay the same long enough. For example, if the successive means were 1.00, 4.03, 2.57, 2.46, 2.67, 2.53, 2.51, 2.52, 2.52, 2.51, 2.50, 2.51, 2.51, 2.51 and 2.51, after these 15 runs I would decide the ultimate value was about 2.51 ± 0.1.

This is wrong.

Continue reading