[Pymat-users] pymat 3d support
Brought to you by:
ajssf
From: Tal T. <ta...@cs...> - 2004-10-18 16:25:09
|
At some point about a year ago I tried fixing the 2-d limitation and managed to get a version working that took arbitrary dimensional arrays. I don't remember how I did it exactly, but it wasn't difficult. Basically I read the documentation on how both Matlab and python stored their arrays and figured out a way to change the code so that you were transferring the array information instead of the array dimension by dimension. I believe both array representations basically use a large flat array that stores the N-dimensional array content and then a set of variables that store the information about the number and size of the dimensions. I never tested the code much or else I would have checked it back in. By now, it's too late because the code base has changed too much from the code that I originally altered. Please let us know if you fix this. Also, I'd be happy to help and to send you my old code. Cheers, Tal Tversky ta...@cs... Rolv Erlend Bredesen writes: > Hi Guys, > I want the "rank > 2 arrays" limitation fixed. > If some of you have good hints I can look into it. > > Sincerely Rolv > > > ---------- Forwarded message ---------- > Date: Mon, 18 Oct 2004 10:25:55 -0400 > From: Andrew Sterian <ste...@cl...> > To: ro...@st... > Subject: Re: pymat 3d support > > Hi Rolv, > > I don't really know how MATLAB works with higher dimension > arrays. I also haven't really used the python-MATLAB connection > in a long time. There is a new project on Sourceforge now > at http://sourceforge.net/projects/pymat that has some developers > that may be more informed. > > ro...@st... wrote: > > Hi Andrew. > > I'm using python a lot for numerical computing. > > Especially using matlab as a backend for plotting has been very useful. > > > > Now I want to fix this limitation of pymat: > > > > """ > > The following limitations apply to the current version of PyMat: > > 1. Only 1-D and 2-D double-precision (real or complex) MATLAB arrays > > are supported (and single character strings). Matrices of higher > > dimension, structure arrays, cell arrays, etc. are not yet supported. > > """ > > > > So I wonder if you could give me some hints on sending 3D, 4D and larger > > arrays into matlab through pymat. > > > > (know about the reshape/flatten trix) > > > > I already understand most of the code and have compiled it myself. > > > > Sincerely Rolv |