[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Random access loops performing slowly
From: |
David Bateman |
Subject: |
Re: Random access loops performing slowly |
Date: |
Mon, 15 Oct 2007 11:27:12 +0200 |
User-agent: |
Thunderbird 1.5.0.7 (X11/20060921) |
Bhaskar Mehta wrote:
> As a followup, the matrix I mention is at
> http://www.l3s.de/~mehta/sorted_movielens_144_test_users.txt
>
> The simple bmmread script reads the matrix market sparse format for
> octave/matlab (see end of email for code). I run octave 2.9.14
>
> Would someone be willing to try my code on octave 2.9.15 and see if the
> problem has been fixed ?
> Best regards,
> Bhaskar
>
> function out=bmmread(k)
>
> Y=load(k);
> out=spconvert(Y(2:end,:));
>
For Octave 2.9.15 I get
T = 17.328
T = 96.160
On the same machine with Matlab2007a I get
T = 2.3750
T = 6.0512
So yes there is about a factor of 10 difference. However, I suspect this
is due to the JIT in matlab give the form of the code... Writing the two
line for-loop as an oct-file and I suspect this will be much much faster..
D.
--
David Bateman address@hidden
Motorola Labs - Paris +33 1 69 35 48 04 (Ph)
Parc Les Algorithmes, Commune de St Aubin +33 6 72 01 06 33 (Mob)
91193 Gif-Sur-Yvette FRANCE +33 1 69 35 77 01 (Fax)
The information contained in this communication has been classified as:
[x] General Business Information
[ ] Motorola Internal Use Only
[ ] Motorola Confidential Proprietary