[SciPy-user] Update to my SciPy document
dkuhlman at rexx.com
Fri Jun 23 18:51:22 CDT 2006
On Thu, Jun 22, 2006 at 09:11:34PM +0200, Francesc Altet wrote:
> - From PyTables 1.3 on, NumPy (and hence SciPy) arrays are supported right
> out of the box in Array objects (the ones you are using). So, if you write a
> NumPy array, you will get a NumPy array (the same goes for Numeric and
> numarray). In other objects (EArray, VLArray or Table) you can make use of
> the 'flavor' parameter in constructors to tell PyTables: 'Hey, every time
> that I read from this object, please, return me an (rec)array with the
> appropriate flavor'. Of course, PyTables will try hard to avoid doing data
> copies in conversions (i.e. the array protocol is used whenever possible).
Thanks for updating me on this. I've shamelessly copied the above
paragraph (with minor edits) into my document. Thank you. (But,
please let me know if that bothers you.)
> - The procedure for installation can be simplified somewhat:
> $ tar xvzf orig/pytables-1.3.2.tar.gz
> $ cd pytables-1.3.2
> $ python setup.py build
> $ sudo python setup.py install
$ python setup.py build_ext --inplace
$ python setup.py build
because that's what the PyTables README.txt says to do. If I use
"build" instead of "build_ext", does that mean that I would not
need to install Pyrex?
> - Perhaps a nice feature of PyTables that you could document is its
> capability to read slices of arrays directly from disk. You can do this by
> providing the start, stop and step parameters to node.read() method, but it
> would be more appropriate (specially when dealing with multidimensional
> data) using the __getitem__ method that expose all the data nodes. Examples:
> node # Get the first element of potentially multidimensional node
> node[1:4:3] # Get an slice
> node[1:4:3, 2:10:2, ..., 3] # The complete syntax for slices is supported.
Slick. I've added several examples and a note.
Thanks for the help.
More information about the SciPy-user