Pages

Friday, February 10, 2012

Post-GSoC work, End(?) of University

I have done the seamless cloning project for GIMP and finished it in August. So, you may ask, why on earth is it not integrated yet? The answer is short and simple - last university semester combined with real life. But, I'm not here to bring excuses, I'm here to bring results:

On Thursday I had my last university exam (Computational Complexity). Unless I fail, and I hope I don't, I finished university!

In the last two weeks of university, I had more and more free time so I began working again on my GSoC project. The current things that are waiting to happen are:

Fix the triangulation refinement implementation. For those who are not familiar with the algorithm behind the scene, the algorithm itself is based on interpolation of image differences in a triangular mesh. Therfor, it is a critical part.The algorithm currently would get stuck in an infinite loop of refining the triangulation, even though it was gauranteed to stop (meaning an implementation bug). I think I just fixed it now (now as in 5 minutes ago), more on this below.

Make the algorithm iterate over tiles inside of allocating a big chunk of memory, and thus limiting the maximal image size for the algorithm.

Fix memory leaks (there are several known leaks, and hopefully none unknown).

Improve a small glitch on the borders of the image.

Optimize the speed!

Get it reviewed, and merge back to master.

Being free of university, and free from other work (I have a day work on which I don't work "after-hours"), I'm now free from chores on evenings (if I get home at sane hours) and weekends. For the first time in the last 3.5 years, I really have free time with nothing on my mind. So don't worry, I'll get into GIMP :D

Now, before I get into details on my GSoC bug, a short "what's going on?".

Last time I left the geometry library, I was completly stuck with no idea what was the bug.

When I got to it again, I decided to re-write it in a language which is more type-safe (no pointer bugs), with less memory issues (garbage collection), and much easier to debug (no offense, but gdb isn't always ideal). Eventually I chose C# (and not Java, my favorite language) in order to learn a bit.

I have been spending my free time between the exams, in the last two weekends, to re-write the library. The re-write was something like "look at the code and write it in a different language". Almost no structural changes or anything, so that I'll keep synced with the source.

I don't even feel like explaining this. It is so trivial (and if not, go learn C!) Other than feeling stupid silly for falling on such a bug for days of debugging, I don't have anything else I can say... So, with all the dislike of some people to high level languages, I like type safety. It saved my here simply since this code, when converted directly to C#, didn't compile and produce an error instead!

So, Hurray for C#, Hurray for end of University (hopefully) at least untill second degree, and just some other random hapiness. And don't worry, I'm not gone yet :)

Edit: More silly bugs found. I'm starting to like re-writing stuff - way better than debugging...Edit 2 (February 11th, 2012): The geometry library works, at least in C#. Now it's time to re-implement in C.

About this blog

This is my blog, dedicated to programming, digital art, and the GIMP project. I'm one of the not-so-active-yet-still-active GIMP developers, and I'm known on the web as LightningIsMyName. I graduated the first degree in computer science this year, and on my free time I like to play with programming.

My main interests are Computer Graphics (both as a digital artist and as a programmer) and photography. My "native" programming language is Java, but I also program in Python, C and Scheme.