[PYTHON MATRIX-SIG] Re: Saving HUGE arrays

Konrad Hinsen hinsen@ibs.ibs.fr
Thu, 21 Nov 96 13:04:04 +0100


> I presume PyBuffer_GetInfo() should fail on non-contiguous arrays ?

That would make it useless for many applications, since non-contiguous
arrays can occur anywhere.

> PyBuffer_GetInfo() must check if the buffer is available read-only
> (immutable objects) or read/write (mutable, e.g. contiguous arrays).
> 
> We could add it a mode argument, ala fopen() ('r', 'w').

How about a stream-like protocol, i.e. implementing read() and write()?
That could be done for non-contiguous arrays, and still be efficient.

Konrad.
-- 
-------------------------------------------------------------------------------
Konrad Hinsen                          | E-Mail: hinsen@ibs.ibs.fr
Laboratoire de Dynamique Moleculaire   | Tel.: +33-4.76.88.99.28
Institut de Biologie Structurale       | Fax:  +33-4.76.88.54.94
41, av. des Martyrs                    | Deutsch/Esperanto/English/
38027 Grenoble Cedex 1, France         | Nederlands/Francais
-------------------------------------------------------------------------------

=================
MATRIX-SIG  - SIG on Matrix Math for Python

send messages to: matrix-sig@python.org
administrivia to: matrix-sig-request@python.org
=================