Hi All,

I'm trying to use pytables with compression without much success...

I'm trying to put compression in a single EArray, where I'm trying to store a string (actually, a byte-array, with the contents of a bitmap). That object is in: texture._imageData

The code I'm using is below. Without setting any compression, my file ends up with 6 MB (and if I pass a zip later, it ends up with 600 k, so, it appears no compression is in effect), and with the code below it ends using the same space, when it should be much closer to 600k, as that image is the thing that eats most space in the file.

Code
----------------------------------------------------------------------------
filters = Filters(complevel=9)
atom = StringAtom(shape=(0,), length=1)
array = file.createEArray(textureGroup, 'imageData', atom, "Image Data", filters = filters, expectedrows = len(texture._imageData))
array.append(texture._imageData)
----------------------------------------------------------------------------

Any hints on why do I have no compression?

Thanks,

Fabio Zadrozny



-- 
Fabio Zadrozny
------------------------------------------------------
Software Developer

ESSS - Engineering Simulation and Scientific Software
www.esss.com.br

Pydev Extensions
www.fabioz.com/pydev

PyDev - Python Development Enviroment for Eclipse
pydev.sf.net
pydev.blogspot.com


Reply via email to