Sergeant Calhoun

Wreck-It Ralph

Wreck it Ralph's face in 8bit art.

Another movie I saw in the plane was Wreck-It Ralph, I did not have particular expectation, as Alias was moderately positive about it and it was unclear to me where this movie stands in the Disney / Pixar situation. Still animation movies are a good match for my fried brain at the end of the flight.

The movie takes place within a gaming arcade, characters from one cabinet visit others while there are no humans playing the games. Wreck-It Ralph is the bad guy of the Fix-it Felix game, which is now 30 years old, and getting tired of his bad-guy role. Tired of his bad guy role, he manages to snatch a medal in another game, a first person shooter choke full of alien bugs, but ends up stranded with in a candy themed racing game, unleashing some serious troubles for the three involved games.

A blond woman in black armour and gun

There are two aspects to the movie, the bad guy trying to be good story, and a look at graphical culture of video games. The first is clearly aimed at a younger audience, while the latter is probably targeted more at people like myself. I found the plot pretty good, while the happy ending was predictable, I found myself surprised by the direction it took, maybe because I was tired.

I liked the way the world of video-games was depicted, a lot of references to existing games without them becoming too over-bearing, and a story set in three very different environment: an 8-bit platform game, Fix-it-Felix Jr (the Junior is typical of that time), a japanese style 16-bit racing game (including the japanese music), Sugar Rush, and a US style 32-bit first person shooter, Hero’s duty. Characters from the various look like their games, and move like they do in their games, Fix-it-Felix temps to hop around while, while Sergeant Calhoun actually walks and jumps. I also like the fact that while the main character is male, there are two strong female characters in the story and the player is a girl.

So while this movie is certainly no Toy Story, it was still a pleasant watch that brought back good memories of 8-bit games.

Flattr this!

Various Characters, one of them playing the piano

Cloud Atlas

Various Characters, one of them playing the piano

One of the few things you can do in a long-haul flight is to watch movies, among them, Cloud Atlas by the Wachowski siblings. I had only seen a trailer sometime last year and was generally to busy to hear about the various critiques of the movie, the explanation in the in-flight entertainment system was more confusing that anything else, so I was just curious.

Cloud Atlas is a set of stories in different times and place: a lawyer sailing back home in the 19th century, a young gay composer trying to make his way in the early 20th in England, century, a journalist in the US 60’s, a retired editor’s misadventures in the present day, a clone’s interrogation in some science fiction Korea and an epic quest in some post-apocalyptic earth. The various stories are connected first because of some birthmark that is common among all characters and some references from one story to the other.

A colleague found the story confusing, but I suppose that having read way to much cyberpunk novels, multi-threaded narration is not really a problem for me. I really like the idea of the movie, movies which are too new-agy tend to irritate, but here this was kept at a reasonable level, I also like the fact that the tone was not to moralising. I found the visuals gorgeous, and liked the acting, which also meant that the fact the same actors were present in the various story-strands was not too obvious.

My main problem with the movie is that it is slow, way to slow. Watching a movie that is nearly three hours long is OK when you are in a long flight, but still, there were a lot of places that could have been cut in a tighter fashion, in particular in the post-apocalyptic and the science-fiction story. I don’t think that those days, people really need twice as much exposition just because the setting is science-fiction. This slow pace also undermined the connection between the stories, I feel that shorter chunks, a better multiplexing, would have helped glue the various pieces together better.

In conclusion a good film that could have been much better had it been cut tighter. A must see for fantasy-lovers, but probably not a recommendation for people who don’t have the patience of looking at a three hour long movie.

Flattr this!

Cover of the book “The Electronic Link to Retail also Known as EDI (Electronic Data Interchange)” by Alan Castro

The Electronic Link to Retail Also Known as EDI

Cover of the book “The Electronic Link to Retail also Known as EDI (Electronic Data Interchange)” by Alan Castro

Lately, I have been trying to get some basic understanding of the Electronic Data Interchange (EDI) protocol, so I started reading the book The Electronic Link to Retail Also Known as EDI (Electronic Data Interchange) by Alan Castro, a short (52 pages) book on the subject.

The Electronic Link to Retail also Known as EDI
(Electronic Data Interchange)

ISBN : 978-1-420875973

This must be the worst written technical book I have ever put my eyes on. There is no structure, no plan, no insight, just some badly written english intermixed with some poorly formatted, non-documented examples. Is the author a human that should forever banned of touching a keyboard, or a really bad markov-chain algorithm? I would tend to think the first, because algorithms tend to produce better english.

The section about the author is a pretty good example of the style of english present in most of the book.

My name is Alan Castro. I became a computer consultant for the past twenty years. In the 1980’s, I was part of the process of developing the Electronic Data Interchange, also known as EDI. I had put the first company in use with EDI. As the years went on I have developed EDI to flow thru the software packages so there would be no manual entry.

I have also developed an EDI package that can run on its own. This is when the data is transmitted in your system, the data is also ready to be transmitted as an invoice or an advanced ship notice.

In short, this is a really worthless book, that will not help anybody understand EDI.

Flattr this!

Teaching Algorithms


I have always been a little wary of calls for computer science or programming to be taught at school. Most of them felt like basic corporatism, trying to get people started in a given trade early, similar calls have been made by lawyers, and music teachers managed to get music teaching into the constitution in Switzerland. I had some computer science course when I was in Collège, the Geneva equivalent of high-school, and they were pretty random in quality in scope, nobody knew exactly what computer science was exactly, and what such a course should teach, coding? using a word-processor?

Later, just after I finished my computer degree, I did some hours standing in for a sick teacher in Cycle d’Orientation, the school before high-school in Geneva. The course was officially computer science, and I felt very proud of teaching with my brand new degree. Problem was, what was given was in fact a recycled typewriter course, one part was something I cannot do even today – touch type with 10 fingers – and the other one is something I abhor – using a word processor like a typewriter, using the courier font and doing the line breaks by hand. This was twenty years ago.

Teaching maths properly is already something hard, and math, at least at pre-university levels, is a pretty much stable and agreed-upon subject. Designing a proper high-school computer science course is far from trivial, in particular when considering the course should be stable long enough to be able to train the teachers, evaluate them, integrate the course into the general teaching framework. While computer hardware is cheaper and cheaper, whatever is used for the course will need to be adapted very often, this means a reasonable supporting staff. Finding proper teachers is also not going to be trivial, there is a strong demand for people with technical degrees, so there is a high risk you end up with computer science teacher that only have a superficial understanding of the subject.

In short, there are many things that can go very wrong and few people that would be able to judge the quality of the course: not the parents, not the other teachers, certainly not the politicians. Getting a hot new technology into schools has always been a good way for contractors and consultants to get juicy contracts.

So why did I change my mind? Algorithms. More precisely, the level to which programs affect our daily lives. Inventing stupid t-shirts, doing , simulating new planes, or even driving cars, things in the real world are increasingly done by computers. A baby born nowadays will interact with algorithms way more often that with, say animal farms. Currently they are taught basic facts about animals, but nothing about the algorithms. They are told stories about the bad wolf in the woods, but nothing about the nasty program that lurks behind the the firewall.

I don’t think that kids should be taught computer science and programming as a trade, but as a way to understand one increasingly important part of our society, algorithms.

Flattr this!

The HAM problem

Complexity of HAM

While I was tinkering with my code to render Amiga HAM images, one challenge was finding good images. So I considered generating them myself, but this is not as easy as it sounds. Building an image with a colour palette requires Colour quantisation, but HAM is a little bit trickier.

When selecting your palette for a classical colour palette image, like for an instance a GIF image, you want to have one representative for each colour cluster. In a HAM image you have two choices for each pixel: select a close colour in the palette, or derive the colour from the previous pixel.

Another way to describe the problem is that of a robot that needs to follow a path in 3 dimensional space, the robot is only allowed to either move along one of the axis (Manhattan norm) or to teleport to one of P arbitrary points. The goal is to select the teleport points and to plan a path of the robot: either move along one axis or teleport, so that its path is a close as possible to the points in the original path (the image to encode).

The position along each axis is discrete, for each there are P possibilities. There are also P teleportation points (palette entries) each with P3 possible values. So the total number of palettes is 𝐂 (P3, P). For each point in the path, there are 4 × P choices (1 teleport and 3 moves). So the number of possibles paths of length N is (4 × P)N. Clearly the total solution space is pretty big: 𝐂 (P3, P) × (4 × P)N. For a classical HAM file, N = 320 × 400 and R = 24, which is around 3.17 × 10231235 possibilities, so an exhaustive search is not a reasonable approach.

If the problem would only be that of finding a path, without the colour-table jumps, some linear programming would do the trick, but here, the selection of the path and the selection of the colour table are deeply connected…

Flattr this!