[SciPy-user] Cannot handle sparse matrices, yet.
Nils Wagner
nwagner at mecha.uni-stuttgart.de
Wed Oct 15 09:59:21 EDT 2003
Arnd Baecker schrieb:
>
> Hi Nils,
>
> though not feeling as an expert on this, may I still
> ask if you are 100% sure that k0 is really stored as a full matrix?
> Somehow it seems that the stored k0 still "knows" that it
> came from a sparse matrix.
> Does save -mat -v4 k0 lead to a resonably larger
> file than save -mat -v4 k00 ?
Yes.
> Is the shape of k0 the right one?
Yes
> What happens if you assign a new matrix k1=IdentityMatrix * k0
> and store that ?
Nothing changes.
>
> Presumably you this kind of tests already ...
>
> Arnd
The matrix is complex. Is this a problem for loadmat ?
Nils
>
> On Wed, 15 Oct 2003, Nils Wagner wrote:
>
> > Dear experts,
> >
> > At the beginning I have used
> >
> > k0=full(k00)
> >
> > to convert the sparse matrix k00 to a full matrix k0.
> > Then I have used the -v4 option in Matlab to save the full matrix
> >
> > save -mat -v4 k0
> >
> > However, I cannot import the f u l l matrix k0 in scioy
> >
> > Traceback (most recent call last):
> > File "matlab.py", line 4, in ?
> > io.loadmat("k0",appendmat=0)
> > File "/usr/local/lib/python2.1/site-packages/scipy/io/mio.py", line
> > 423, in loadmat
> > raise ValueError, "Cannot handle sparse matrices, yet."
> > ValueError: Cannot handle sparse matrices, yet.
> >
> > For what reason ?
> >
> > Nils
> > _______________________________________________
> > SciPy-user mailing list
> > SciPy-user at scipy.net
> > http://www.scipy.net/mailman/listinfo/scipy-user
> >
> _______________________________________________
> SciPy-user mailing list
> SciPy-user at scipy.net
> http://www.scipy.net/mailman/listinfo/scipy-user
More information about the SciPy-User
mailing list