Re: [Numpy-discussion] Contiguous flags not quite right yet.

2007-03-22 Thread Travis Oliphant
Charles R Harris wrote: > All three shapes are both C_CONTIGUOUS and F_CONTIGUOUS. I think > ignoring all 1's in the shape would give the right results for > otherwise contiguous arrays because in those positions the index can > only take the value 0. > I've thought about this before too. But

[Numpy-discussion] Contiguous flags not quite right yet.

2007-03-22 Thread Charles R Harris
Example. In [18]:a = array([1,2,3]) In [19]:a.flags Out[19]: C_CONTIGUOUS : True F_CONTIGUOUS : True OWNDATA : True WRITEABLE : True ALIGNED : True UPDATEIFCOPY : False In [20]:a.shape = (1,3) In [21]:a.flags Out[21]: C_CONTIGUOUS : True F_CONTIGUOUS : False OWNDATA : True WRITEABLE