![]() |
Numpy on Maemo 5
Does anyone know if the fabulous scientific computing library Numpy has been successfully ported to Maemo. The problem is that it uses a legacy fortran library, lapack, for it's linear algebra backend.
Fortran is currently not a supported language for the Maemo SDK. Does Numpy mind if clapack is used instead? And is BLAS avaliable for the platform? As I have never compiled clapack, or numpy myself. And as I'm newbie at developing for Maemo. I feel this task is a bit to difficult for me alone at the moment. So is anyone else interested in helping out with this task? I think it could be a very useful thing to have it would greatly simplify doing all kinds of number crunching on the device. E.g computer vision, statistical analysis, data mining etc. Even some pointers could be a great help. |
Re: Numpy on Maemo 5
Perhaps you could first check these ARM/ARMEL ports of Numpy:
http://packages.debian.org/search?keywords=python-numpy For statistical analysis and data mining I will experiment with R on N900 when I get the device. It is widely used in scientific computing and runs on ARM too. Due to R I use Matlab only rarely these days. R has an API too. For computer vision I could try running OpenCV at some point. |
Re: Numpy on Maemo 5
AFAIK, numpy only deals with Fortran in so far as it provides binding support. Compiling scipy for Maemo, however, is probably a different beast...
This would be very interesting for me too, once I get my N900. The same for R on Maemo, including the Python binding! |
Re: Numpy on Maemo 5
Ok, so I tried compiling Numpy in scratchbox. I was happy to find that the sourcecode ships with rudimental blas and lapack implementations in c. Using these numpy compiles without problem. As do matplotlib. So it is actually easy to have a lightweight numpy/matplotlib on the IT. That more or less eases my need, since that means I can make applications which relies on linear algebra and plotting but not on extreme performance.
Of course it would also be great to have the real lapack for it's efficiency. I actually tried to compile clapack and cblas. It worked and the test program passed most tests (it is apparently normal for a lapack installation to fail some of the tests. Simply because they are compiled on a different compiler) However, it is almost 10 Mbyte library. |
Re: Numpy on Maemo 5
Quote:
How do I tell the script not to use fortran compiler but compile clapack instead and how and where do I configure all that? |
Re: Numpy on Maemo 5
Quote:
clapack compiles fine and works on its own, but I never used it for my Numpy installation. Long answer: My primary goal was to gain access to the powerful matrix operations of numpy. And to be able to use matplotlib for fancy plotting. Hence, when I realized that numpy works well without lapack (3-4 times slower than an optimized lapack though) I lost some of my initial interest. Btw, welcome to the forum. / David |
Re: Numpy on Maemo 5
Quote:
Are you going to upload your packages and sources? Have you tried to compile as well? I guess you would need to compile a gfortan as a compiler first? |
Re: Numpy on Maemo 5
I've just compiled and packaged up Numpy, need to wait for the repos to open again and then I'll upload it.
Talking about lapack, I can't for the life of me get it to actually compile correctly, it ends up with linker errors even though I'm building against libf2c, if anyone fancies taking a look at it (or a clapack debian build) then please do so. Onto other matters, I've also just packaged up Octave, which I'll also push to extras-devel. It only uses some of the add-on libs (e.g. blas, fftw, and a couple of extras), but really we could do with compiling all of the other support libs and getting them all pushed to extras-* and included in the Octave build. FYI I uploaded fort77 (which is a script that wraps f2c + gcc and behaves like f77 (and in fact provides a symlink with that name so many programs can compile unaltered), you just have to remember to link against libf2c. |
Re: Numpy on Maemo 5
Quote:
Mypaint depends on numpy, and I discovered yesterday that numpy wasn't in Fremantle :eek: (think it's in Mer though...) Got my n900 three days ago... so Thanks! |
Re: Numpy on Maemo 5
I've just finished compiling numpy+scipy and uploaded it to my repository:
deb http://n900.tannerlab.com/ fremantle free deb-src http://n900.tannerlab.com/ fremantle free |
| All times are GMT. The time now is 07:41. |
vBulletin® Version 3.8.8