A Wednesday 08 December 2010 23:12:16 Michael Hoffman escrigué: > Hi, > > I have a similar problem to this one from 2007: > > http://article.gmane.org/gmane.comp.python.pytables.user/533/ > > I am trying to add to an enormous EArray in the extensible direction, > but doing this is very slow since it requires that an entire slice be > generated in memory and then stored to disk. (It also seems to me > that this wastes a lot of disk space even with compression--the > files are much larger than when I used a CArray for this task.) > > I submitted this as issue #317 > <http://www.pytables.org/trac/ticket/317>.
Well, the elegant way to solve this is to not allow such a big slices to happen. But I recognize that sometimes this can be inconvenient. In these cases, you can use the the `Leaf.truncate()` method: http://www.pytables.org/docs/manual/ch04.html#id340646 that despite its name, it lets you enlarge your dimensions too. Now that I think, do you think that adding a new `.extend()` method as an alias of `.truncate()` would be useful? Anyway, I've opened a ticket about this: http://www.pytables.org/trac/ticket/326 > Are there any other solutions to this problem? I often know the > number of rows in advance, but still want to be able to expand > later. Hope this helps, -- Francesc Alted ------------------------------------------------------------------------------ This SF Dev2Dev email is sponsored by: WikiLeaks The End of the Free Internet http://p.sf.net/sfu/therealnews-com _______________________________________________ Pytables-users mailing list Pytables-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/pytables-users