[SciPy-user] Example 1 - Error

William Hunter willemjagter at gmail.com
Fri Jul 28 03:01:45 EDT 2006


Gaël;

About "AttributeError: rowind not found"

I got the same in the beginning, and like your colleague I also thought that
this scipy business is overrated...

You need to fix linsolve.py, which you can do by hand (i.e., cut from the
website and paste into your local linsolve.py file).

If you go to http://projects.scipy.org/scipy/scipy/timeline and scroll down to

Changeset [2117] by rc

and click on it, you'll see the part of the file that changed. If you
correct your file
you won't (shouldn't) get that error.

How in the world are you supposed to know this, right? Stéfan pointed this very
issue out to me as I was under the impression that one will need to
get the whole
SVN version of scipy, but it's not necessary. I also got a mail from Robert (rc)
explaining that he made the change, but at that stage I was still new
to all this,
and I didn't really know what was going on or what it meant. I think this is one
of the biggest threats to potential Matlab(r) to SciPy converts or people like
myself who don't have a programming background. (I'll write another mail with
my thoughts on this and how one may adress it).

I think I should probably add this to the Scipy_Tutorial wiki,
although I did mention
that you need the latest version of linsolve.py in the tutorial. In
all fairness, for new
users (like myself!) one assumes that one has the latest version, but you know
what they say about assumptions...

I hope this helps.

-- 
Regards,
WH

On 27/07/06, Gael Varoquaux <gael.varoquaux at normalesup.org> wrote:
>    I get another error in the example 1 :
>
> In [20]: time xsp3 = linsolve.spsolve(Asp.tocsr(),b)
> ---------------------------------------------------------------------------
> exceptions.AttributeError                            Traceback (most
> recent call last)
>
> /home/varoquau/<ipython console>
>
> /usr/lib/python2.4/site-packages/IPython/iplib.py in ipmagic(self, arg_s)
>    857         else:
>    858             magic_args = self.var_expand(magic_args)
> --> 859             return fn(magic_args)
>    860
>    861     def ipalias(self,arg_s):
>
> /usr/lib/python2.4/site-packages/IPython/Magic.py in magic_time(self,
> parameter_s)
>   1584         else:
>   1585             st = clk()
> -> 1586             exec code in glob
>   1587             end = clk()
>   1588             out = None
>
> /home/varoquau/<timed exec>
>
> /usr/lib/python2.4/site-packages/scipy/linsolve/linsolve.py in
> spsolve(A, b, permc_spec)
>     66     else:
>     67         mat, csc = _toCS_superLU( A )
> ---> 68         ftype, lastel, data, index0, index1 = \
>     69                mat.ftype, mat.nnz, mat.data, mat.rowind,
> mat.indptr
>     70         gssv = eval('_superlu.' + ftype + 'gssv')
>
> /usr/lib/python2.4/site-packages/scipy/sparse/sparse.py in
> __getattr__(self, attr)
>    235             return self.getnnz()
>    236         else:
> --> 237             raise AttributeError, attr + " not found"
>    238
>    239     def transpose(self):
>
> AttributeError: rowind not found
>
>    Maybe it is because my version of linsolve is not recent enough, but
> it fails with enthon 1.0.0 beta4. That not to pretty to see when you are
> doing the tutorial to see weather you are going to switch from Matlab to
> scipy (as a colleague of mine was doing when he found the error).
>
> --
>    Gaël
> _______________________________________________
> SciPy-user mailing list
> SciPy-user at scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user


More information about the SciPy-User mailing list