Back to eand.py project, and with additional features. We discussed last time a numerical differentiation method capable of handling arbitrarily-noisy signals, however one could rapidly oppose it two limitations.
The most evident, perhaps, is the fact that the current implementation only deals with monodimensional signals, i.e. functions of a single variable, while our world is slightly more complicated. Yet most signals encountered in nature hopefully meet certain conditions of regularity so that the problem can be at least partially circumvented. The other important issue is somehow more tricky, namely the necessity of equally-spaced samples. Although quite a lot of practical differentiation problems may boil down to this framework at the cost of reasonable approximations, the question particularly holds when information is not equally distributed or accessible accross dimensions.
Both issues are tackled in a recent article by Riachy et al. (2011), presenting theoretical developments and implementation suggestions, which I merely coded back into Python.
Multidimensional randomly-sampled signal (left) and first-order partial derivative estimate along first axis (right)
As before, the corresponding code is available on eand.py package’s repository, and you can download it and modify it as you wish under the terms of the GNU General Public License version 3. Oh, and I just found out that iPython project offered a nice interface to display code and associated outputs, so that you can understand that I really meant each letter when I named the package :)
Next time, something completely different!
One month now that I’ve been in Heraklion, Greece, and joined the Computer Vision and Robotics Laboratory of FORTH-ICS as a visiting researcher until September. Of course many things to say, also about the life in Crete, but I shall leave the best for future posts and rather tell about annoying, computer science and math-related stuff :)
It’s been some time, now, that I’ve recurrently been using open-source software, not so much for philosophical reasons but rather for efficiency over cost ratio (which is not necessarily infinite if you consider cost as ergonomics alongside with price). Recently I’ve also switched from Windows 7 to full Unix-like solutions and finally stuck to Lubuntu, an operating system based on Ubuntu, except lightweight and really fast (and ugly, but that’s part of the deal).
Anyway, now that I will be regularly producing programs as part of my research, I’ve chosen to release all sources publicly when possible (i.e. basically when no licensing or top-secret issue comes in the way). I’ve created a GitHub repository for the occasion, and by the way, my thanks go to AmmarkoV for the help and tips (check out his website, it’s cool and geeky). First contribution is called eand.py (Easy Algebraic Numerical Differentiation for Python) and consists primarily in an implementation of a derivative estimator introduced in a recent article by Mboup et al. (2009) which you can download and read here.
Noisy signal (left) and first-order derivative estimate using eand.py (right)
Although the theoretical framework is relatively dense, I included some demonstration files to try to make things easy to visualize. The whole package is released under the GNU GPL license. Of course, contributions, comments and suggestions of improvement are most welcome.