Tuesday, July 2, 2013

Pytables/Numpy: lesson learned

Today's PyTables/NumPy lesson that I learned the hard way (i.e. through time wasted): When you use the __getitem__ method from a PyTables Table, and you pass an integer, you don't get back a record array. You get back the same thing as if you pass an integer to the __getitem__ method of a record array - namely a numpy.void instance, which is used presumably because NumPy doesn't know what to call whatever you have stashed together in one record.

No comments:

Post a Comment