[Pytables-users] Fwd: Runtime warning and import error after installation

2012-08-20 Thread PyTables Org
Forwarding bounced message.
~Josh

 From: Arang Rhie arr...@gmail.com
 Date: August 20, 2012 3:59:06 AM GMT+01:00
 To: pytables-users@lists.sourceforge.net
 Subject: Runtime warning and import error after installation
 
 Hi,
 
 I'm new to PyTable, and now getting really frustrating with the installation 
 process.
 1. What is the HDF5 runtime?
 I've installed HDF5 following the instruction given by HDF5.
 What file is PyTable looking for? And how can I set the path to it?
 I've installed HDF5 under /usr/local/hdf5 and set the environment 
 variable $HDF5_DIR on /usr/local/hdf5.
 But still setup.py is not recognizing it without the 
 --hdf5=/usr/local/hdf5 option.
 Moreover,  I don't understand the 'shared library' of HDF5. does that 
 mean to install hdf5-1.8.9-linux-x86_64-shared.tar.gz from HDF5?
 I've untar the ~shared.tar.gz under /usr/local/hdf5-shared and set the 
 $LD_LIBRARY_PATH as /usr/local/hdf5-shared.
What else do I need to do in addition?
 2. I've configured LZO with --enable-shared option, and followed the 
 instruction (make, make check, make test, make install).
I've completed without any error, and the shared libraries where set under 
 /usr/local/lib.
Do I need to explicitly set other variables for running setup.py?
 
 
 
 [root@gmi-student tables-2.4.0]# python setup.py install 
 --hdf5=/usr/local/hdf5
 * Found numpy 1.6.2 package installed.
 * Found numexpr 2.0.1 package installed.
 * Found Cython 0.16 package installed.
 * Found HDF5 headers at ``/usr/local/hdf5/include``, library at 
 ``/usr/local/hdf5/lib``.
 .. WARNING:: Could not find the HDF5 runtime.
The HDF5 shared library was *not* found in the default library
paths. In case of runtime problems, please remember to install it.
 * Found LZO 2 headers at ``/usr/local/include``, library at 
 ``/usr/local/lib``.
 .. WARNING:: Could not find the LZO 2 runtime.
The LZO 2 shared library was *not* found in the default library
paths. In case of runtime problems, please remember to install it.
 * Skipping detection of LZO 1 since LZO 2 has already been found.
 * Found bzip2 headers at ``/usr/include``, library at ``/usr/lib64``.
 running install
 running build
 running build_py
 running build_ext
 running build_scripts
 running install_lib
 running install_scripts
 changing mode of /usr/bin/ptdump to 755
 changing mode of /usr/bin/ptrepack to 755
 changing mode of /usr/bin/nctoh5 to 755
 running install_egg_info
 Removing /usr/lib64/python2.7/site-packages/tables-2.4.0-py2.7.egg-info
 Writing /usr/lib64/python2.7/site-packages/tables-2.4.0-py2.7.egg-info
 [root@gmi-student tables-2.4.0]# python
 Python 2.7 (r27:82500, Sep 16 2010, 18:02:00) 
 [GCC 4.5.1 20100907 (Red Hat 4.5.1-3)] on linux2
 Type help, copyright, credits or license for more information.
  import tables
 Traceback (most recent call last):
   File stdin, line 1, in module
   File tables/__init__.py, line 30, in module
 from tables.utilsExtension import getPyTablesVersion, getHDF5Version
 ImportError: libhdf5.so.7: cannot open shared object file: No such file or 
 directory
 
 Serena Rhie
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] How would I update specific rows from a table with rows of a second table?

2012-05-06 Thread PyTables Org
Forwarding,
~Josh

On Apr 30, 2012, at 5:04 PM, pytables-users-boun...@lists.sourceforge.net wrote:
 From: Christian Werner freizeitbeauftrag...@googlemail.com
 Date: April 30, 2012 5:03:59 PM GMT+02:00
 To: pytables-users@lists.sourceforge.net
 Subject: How would I update specific rows from a table with rows of a second 
 table?
 
 
 Hi group.
 
 Please consider this scenario. I have produced a large h5 file holding the 
 outcome of some simulations (hdf file holds some groups and about 5 tables, 
 but for my question this does not matter). 
 How I had to rerun my simulation but only for certain fields and thus I have 
 a second h5 file with the same structure but only for certain fields of the 
 original file (old age classes, see below).
 
 Or to be more verbose:
 
 Table (original)
 idyearspecies age data1   data2   data3   ...
 1 1990spruce  75  1.2 3.2 3.3 ...
 1 1991spruce  75  1.3 3.1 2.2 ...
 ...
 1 1990spruce  125 1.1 2.1 1.5 ...
 ...
 1 1990pine145 1.1 2.1 1.5 ...
 ...
 2 1990spruce  45  1.2 3.2 3.3 ...
 2 1991spruce  55  1.3 3.1 2.2 ...
 ...
 
 I had to rerun my simulations for old vegetation classes. So this table only 
 contains the following lines (e.g., spruce age  80)
 
 Table (new)
 idyearspecies age data1   data2   data3   ...
 ...
 1 1990spruce  125 1.1 2.1 1.5 ...
 ...
 1 1990pine145 1.1 2.1 1.5 ...
 
 So basically I need to use the rows of the new table and overwrite the 
 corresponding rows of the old table to form the updated one. I do need to 
 retain the original order (sort order id  year  species  age). Those 
 columns combined give a unique row identifier...
 
 The final table would have the same size and order as the original table with 
 only the rows containing data for old age classes updated with the new 
 simulation results...
 
 Can anyone give me a hint how to achieve this?
 
 I guess I need to introduce a new (unique index) column first in both tables 
 (e.g., combining  id + year + species + age so I can match those rows by this 
 identifier), right? Does anyone have some example code for me?
 
 Problem is, the 2 h5 files are about 7GB each.
 
 Cheers,
 Christian
 
 
 




--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] Choice of table structure

2011-12-13 Thread PyTables Org
Forwarding to the list. ~Josh.

Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: December 13, 2011 7:50:22 AM GMT+01:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: Davide Cittaro daweonl...@gmail.com
 Date: December 13, 2011 7:50:03 AM GMT+01:00
 To: pytables-users@lists.sourceforge.net 
 pytables-users@lists.sourceforge.net
 Subject: Choice of table structure
 
 
 Hi all, I need to store millions of entries made by a n-long string, a n 
 array of integers and an ID for every string/array couple. Are there best 
 practices to structure a proper pytable for this? Also, does the structure 
 influence compression efficiency?
 
 d
 
 --
 Composed on a phone, sorry for the misprints
 
 

--
Systems Optimization Self Assessment
Improve efficiency and utilization of IT resources. Drive out cost and 
improve service delivery. Take 5 minutes to use this Systems Optimization 
Self Assessment. http://www.accelacomm.com/jaw/sdnl/114/51450054/___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] Ubuntu 11.10: blosc is not supported?

2011-12-06 Thread PyTables Org
Forwarding to the list. ~JoshBegin forwarded message:From: pytables-users-boun...@lists.sourceforge.netDate: December 6, 2011 2:20:35 PM GMT+01:00To: pytables-users-ow...@lists.sourceforge.netSubject: Auto-discard notificationThe attached message has been automatically discarded.From: Martin Felder martin.fel...@zsw-bw.deDate: December 6, 2011 2:05:15 PM GMT+01:00To: pytables-users@lists.sourceforge.netSubject: Ubuntu 11.10: blosc is not supported?Hi,I installed pytables via the Ubuntu package manager (currently version 2.1.2-3.1build1), and we use it a lot for production work. Thanks for this great package!So far I haven't tried enabling compression, but since it says in the documentation BLOSC comes with it, I created a filter with complib="blosc", only to get:ValueError: compression library ``blosc`` is not supported; it must be one of: zlib, lzo, bzip2Do I have to compile a newer version from source to enable BLOSC?Thanks,Martinattachment: martin.felder.vcf--
Cloud Services Checklist: Pricing and Packaging Optimization
This white paper is intended to serve as a reference, checklist and point of 
discussion for anyone considering optimizing the pricing and packaging model 
of a cloud services business. Read Now!
http://www.accelacomm.com/jaw/sfnl/114/51491232/___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] Some experiences with PyTables

2011-12-06 Thread PyTables Org
Forwarding to the list. ~Josh.

Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: December 6, 2011 9:27:27 PM GMT+01:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: Edward C. Jones edcjo...@comcast.net
 Date: December 6, 2011 9:25:08 PM GMT+01:00
 To: pytables-users@lists.sourceforge.net
 Subject: Some experiences with PyTables
 
 
 My computer has an up-to-date Debian stable distribution installed.  I have
 the following Debian packages (plus most dev packages):
python 2.6.6-3+squeeze6
python-numpy 1:1.4.1-5
hdf5-tools 1.8.4-patch1-2
libhdf5-serial-1.8.4 1.8.4-patch1-2
 I have compiled and installed PyTables 2.3.1.
 
 1. There seems to be an unpythonic design choice with the start, stop, step
   convention for PyTables.  Anything that is unnatural to a Python
   programmer should be heavily documented.
 2. There may be a bug in itersorted.
 
 Here is code for (1) and (2):
 
 #! /usr/bin/env python
 
 import random, tables
 
 h5file = tables.openFile('mytable.h5', mode='w')
 
 class silly_class(tables.IsDescription):
num = tables.Int32Col(pos=0)
 
 mytable = h5file.createTable(h5file.root, 'mytable', silly_class,
 'a few ints', expectedrows=4)
 
 row = mytable.row
 for i in range(10):
row['num'] = random.randint(0, 99)
row.append()
 mytable.flush()
 mytable.cols.num.createCSIndex()
 
 # Python's idiom for start, stop, step:
 print 'Python:', range(9, -1, -1)
 
 output = mytable.readSorted('num', start=0, stop=10, step=-1)
 print 'readSorted:', 0, 10, -1, output
 
 # copy supports a negative step.  It seems that start and stop are applied
 # _after_ the sort is done.  Very unlike Python.  Please document thoroughly.
 print h5file.root.mytable[:]
 h5file.root.mytable.copy(h5file.root, 'mytable2', sortby='num',
 start=0, stop=5, step=-1)
 print h5file.root.mytable2[:]
 
 # The following raises an OverflowError.  The documentation (2.3.1) says
 # negative steps are supported for itersorted.  Documentation error or bug
 # in itersorted?
 output = [x['num'] for x in mytable.itersorted('num',
 start=0, stop=10, step=-1)]
 print 'itersorted:', 0, 10, -1, output
 
 3. Null bytes are stripped from the end of strings when they are stored in a
   table.  Since a Python does not expect this, it needs to be explicitly
   documented in all the relevant places.  Here is some code:
 
 #! /usr/bin/env python
 
 import tables
 
 def hash2hex(stringin):
out = list()
for c in stringin:
s = hex(ord(c))[2:]
if len(s) == 1:
s = '0' + s
out.append(s)
return ''.join(out)
 
 h5file = tables.openFile('mytable.h5', mode='w')
 
 class silly_class(tables.IsDescription):
astring = tables.StringCol(16, pos=0)
 
 mytable = h5file.createTable(h5file.root, 'mytable', silly_class,
 'a few strings', expectedrows=4)
 
 # Problem when string ends with null bytes:
 nasty = 'abdcef' + '\x00\x00'
 print repr(nasty)
 print hash2hex(nasty)
 
 row = mytable.row
 row['astring'] = nasty
 row.append()
 mytable.flush()
 print repr(mytable[0][0])
 print hash2hex(mytable[0][0])
 h5file.close()
 
 4. Has the 64K limit for attributes been lifted?
 
 5. The reference manual for numpy contains _many_ small examples.  They
   partially compensate for any lack of precision or excessive precision in
   the documents.  Also many people learn best from examples.
 
 6. Suppose that the records (key, data1) and (key, data2) are two rows in a
   table with (key, data1) being a earlier row than (key, data2).  Both
   records have the same value in the first column.  If a CSIndex is created
   using the first column, will (key, data1) still be before (key, data2) in
   the index?  This property is called stability.  Some sorting algorithms
   guarantee this and others don't.  Are the sorts in PyTables stable?
 
 7. The table.append in PyTables behaves like extend in Python. Why?
 
 8. I get a mysterious PerformanceWarning from the PyTables file table.py,
   line 2742. This message needs to be split into two messages.  In my case,
   after I appended to a table, 'row' in self.__dict__ was True and
   self.row._getUnsavedNrows() was 1.  To resolve the problem, I added a
   line that flushes the table after every append.  Does
   h5file.mytable.flush() do something that h5file.flush() doesn't?  Do I
   need to flush every table after every append or are there only certain
   situations when this is needed?  What does preempted from alive nodes
   mean?
 
 9. Does the following code contain a bug in PyTables?
 
 #! /usr/bin/env python
 
 import sys
 import numpy, tables
 
 # No failure if projections and winsize are small enough.  In the original
 # program, gauss.shape is (2000, 196, 196).
 projections = 105
 winsize = 2500
 h5 = tables.openFile('mess.h5', mode='w')
 shape = (projections, winsize)
 

[Pytables-users] Giant HDF5/PyTables error message

2011-12-05 Thread PyTables Org
Forwarding to list. ~Josh.

Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: December 3, 2011 12:52:46 AM GMT+01:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: Edward C. Jones edcjo...@comcast.net
 Date: December 3, 2011 12:50:13 AM GMT+01:00
 To: pytables-users@lists.sourceforge.net
 Subject: Giant HDF5/PyTables error message
 
 
 The following gigantic (but hard to interpret) error message was generated
 by the line of code:
 
 self.h5.root.sortlist.cols.score.createCSIndex()
 
 Is there a document on how to interpret HDF5 error messages in a PyTables
 context?  What kind of errors in my code create these error messages?  Which
 styles of PyTables programming tends to lead to HDF5 errors?  If I cannot
 figure out a way to analyze these messages, I will have to remove much of
 the PyTables from my code.
 
 (I wrapped long lines)
 HDF5-DIAG: Error detected in HDF5 (1.8.4-patch1) thread 4148012736:
  #000: ../../../src/H5Dio.c line 174 in H5Dread(): can't read data
major: Dataset
minor: Read failed
  #001: ../../../src/H5Dio.c line 404 in H5D_read(): can't read data
major: Dataset
minor: Read failed
  #002: ../../../src/H5Dchunk.c line 1733 in H5D_chunk_read():
 unable to read raw data chunk
major: Low-level I/O
minor: Read failed
  #003: ../../../src/H5Dchunk.c line 2742 in H5D_chunk_lock():
 data pipeline read failed
major: Data filters
minor: Filter operation failed
  #004: ../../../src/H5Z.c line 1017 in H5Z_pipeline():
 filter returned failure during read
major: Data filters
minor: Read failed
  #005: blosc/blosc_filter.c line 232 in blosc_filter():
 Blosc decompression error
major: Data filters
minor: Callback failed
 Traceback (most recent call last):
  File ./mrq.py, line 133, in module
options.scoretask)
  File /home/edcjones/imagedb/imgSeek/mrquery/DB.py, line 56, in __init__
self.New(basename, topdirs, scoretask, excluded_dirs)
  File /home/edcjones/imagedb/imgSeek/mrquery/DB.py, line 180, in New
hashbin.HashBin(self)
  File /home/edcjones/imagedb/imgSeek/mrquery/hashbin.py,
   line 74, in __init__
self.mrq.reversesort_sortlist(self.quota)
  File /home/edcjones/imagedb/imgSeek/mrquery/DB.py,
   line 951, in reversesort_sortlist
self.h5.root.sortlist.cols.score.createCSIndex()
  File /usr/local/lib/python2.6/dist-packages/tables/table.py,
   line 3437, in createCSIndex
_blocksizes=_blocksizes, _testmode=_testmode, _verbose=_verbose)
  File /usr/local/lib/python2.6/dist-packages/tables/table.py,
   line 3412, in createIndex
tmp_dir, _blocksizes, _verbose)
  File /usr/local/lib/python2.6/dist-packages/tables/table.py,
   line 360, in _column__createIndex
self.pathname, 0, table.nrows, lastrow=True, update=False )
  File /usr/local/lib/python2.6/dist-packages/tables/table.py,
   line 2405, in _addRowsToIndex
[self._read(startLR, self.nrows, 1, colname)],
  File /usr/local/lib/python2.6/dist-packages/tables/table.py,
   line 1759, in _read
self.row._fillCol(result, start, stop, step, field)
  File tableExtension.pyx, line 1134,
  in tables.tableExtension.Row._fillCol (tables/tableExtension.c:10214)
  File tableExtension.pyx,
   line 548, in tables.tableExtension.Table._read_records
  (tables/tableExtension.c:5400)
 tables.exceptions.HDF5ExtError: Problems reading records.
 Closing remaining open files: /extra/thumbs/BrianYoung_data/temp.h5... done
 /extra/thumbs/BrianYoung_data/pytables-HsQPfE.tmp... done
 /extra/thumbs/BrianYoung_data/mrq.h5...
 HDF5-DIAG: Error detected in HDF5 (1.8.4-patch1) thread 4148012736:
  #000: ../../../src/H5Dio.c line 174 in H5Dread(): can't read data
major: Dataset
minor: Read failed
  #001: ../../../src/H5Dio.c line 404 in H5D_read(): can't read data
major: Dataset
minor: Read failed
  #002: ../../../src/H5Dchunk.c line 1733 in H5D_chunk_read():
unable to read raw data chunk
major: Low-level I/O
minor: Read failed
  #003: ../../../src/H5Dchunk.c line 2742 in H5D_chunk_lock():
data pipeline read failed
major: Data filters
minor: Filter operation failed
  #004: ../../../src/H5Z.c line 1017 in H5Z_pipeline():
filter returned failure during read
major: Data filters
minor: Read failed
  #005: blosc/blosc_filter.c line 232 in blosc_filter():
Blosc decompression error
major: Data filters
minor: Callback failed
 Error in atexit._run_exitfuncs:
 Traceback (most recent call last):
  File /usr/lib/python2.6/atexit.py, line 24, in _run_exitfuncs
func(*targs, **kargs)
  File /usr/local/lib/python2.6/dist-packages/tables/file.py,
 line 2337, in close_open_files
fileh.close()
  File 

[Pytables-users] Fwd: Changes in container attributes not preserved in the h5 file

2011-11-04 Thread PyTables Org
Forwarding to the list. ~Josh

Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: November 4, 2011 1:16:34 AM GMT+01:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: Edward C. Jones edcjo...@comcast.net
 Date: November 4, 2011 1:14:17 AM GMT+01:00
 To: pytables-users@lists.sourceforge.net
 Subject: Changes in container attributes not preserved in the h5 file
 
 
 My computer has an up-to-date Debian stable distribution installed. It comes 
 with Python 2.6.6.
 I have compiled and installed PyTables 2.3.
 
 Here are two small programs:
 
 Program 1:
 
 #! /usr/bin/env python
 
 import tables
 
 h5file = tables.openFile(table1.h5, mode = w)
 
 class silly_class(tables.IsDescription):
char = tables.StringCol(1, pos=1)
 
 mytable = h5file.createTable(h5file.root, 'silly', silly_class, silly)
 mytable.attrs.myint = 5
 mytable.attrs.mylist = [0, 1]
 mytable.attrs.mydict = {1 : 'a', 2 : 'b'}
 mytable.attrs.myint += 2
 mytable.attrs.mylist.append(2)
 mytable.attrs.mydict[3] = 'c'
 print mytable.attrs.myint, mytable.attrs.mylist, mytable.attrs.mydict
 h5file.close()
 
 Program 2:
 
 #! /usr/bin/env python
 
 import tables
 
 h5file = tables.openFile(table1.h5, mode = r+)
 print h5file.root.silly.attrs.myint, h5file.root.silly.attrs.mylist, \
h5file.root.silly.attrs.mydict
 h5file.close()
 
 I run program 1 and the printout is: 7 [0, 1, 2] {1: 'a', 2: 'b', 3: 'c'}.
 Then I run program 2 where the printout is: 7 [0, 1] {1: 'a', 2: 'b'}.
 
 When an attribute is a Python container, and I make changes inside the 
 container, these changes
 are not present when table1.h5 is reopened. What am I doing wrong?
 
 
 

--
RSA(R) Conference 2012
Save $700 by Nov 18
Register now
http://p.sf.net/sfu/rsa-sfdev2dev1___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] Efficient way to do nested grouping of rows ?!?

2011-09-12 Thread PyTables Org
Forwarding to list. Your email address doesn't appear to be registered. See 
http://sourceforge.net/mail/?group_id=63486 for more information.

Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: September 13, 2011 7:51:22 AM GMT+02:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: Christian Werner werner_christ...@gmx.net
 Date: September 13, 2011 7:51:13 AM GMT+02:00
 To: pytables-users@lists.sourceforge.net
 Subject: Efficient way to do nested grouping of rows ?!?
 
 
 Hi list.
 
 I was pulling my hair out all day trying to implement the following but 
 cannot seem to see the light. Not sure if the subject line was all that 
 descriptive but here it goes:
 
 Say I have a massive table (10 mio lines) stored in a hdf file.
 The simplyfied table structure looks something like this:
 
 id  yearareareplvar1var2var3
 1   199012.31   1.4 1.341.23
 1   199112.31   0.9 0.3 1.3
 1   199212.31   1.3 1.1 1.7
 1   199012.32   1.5 1.4 1.3
 1   199112.32   1.1 0.5 1.53
 1   199212.32   1.6 1.3 1.8
 1   199012.33   1.8 1.741.3
 1   199112.33   1.4 0.5 1.43
 1   199212.33   1.7 1.3 1.8
 2   19904.5 1   3.3 3.6 2.3
 2   19914.5 1   5.6 6.7 1.2
 2   19924.5 1   6.5 4.5 3.3
 2   19904.5 2   3.3 3.6 2.3
 2   19914.5 2   5.6 6.7 1.2
 2   19924.5 2   6.5 4.5 3.3
 2   19904.5 3   3.3 3.6 2.3
 2   19914.5 3   5.6 6.7 1.2
 2   19924.5 3   6.5 4.5 3.3
 3   199012.91   1.3 1.1 0.4
 3   199112.91   3.2 3.4 5.6
 3   199212.91   3.5 3.4 3.5
 ...
 
 The pytables table is sorted by field id. Currently I use the following 
 code:
 
 import itertools
 import numpy as np
 
 var = 'var1'
 
 def id_selector(row):
return row['id']
 
 icnt = 0
 for i, rows_grouped_by_id in itertools.groupby(table, id_selector):
x = np.average( [ [r[var] * r['area'] for r in rows_grouped_by_id] )
print i, x
 
 
 This works fine and dandy (and fast). However, how do I efficiently do 
 another nested grouping? Say, I might want 
 to average all replicates (col repl) of a given year (col year) within each 
 and every id. I'm stumped. How would you do that? I feel I should use 
 row-indices, no? I cannot use the .where() construct of table to limit rows 
 on a bunch of rows, can I?
 
 Thanks for any pointers.
 
 C
 
 

--
BlackBerryreg; DevCon Americas, Oct. 18-20, San Francisco, CA
Learn about the latest advances in developing for the 
BlackBerryreg; mobile platform with sessions, labs  more.
See new tools and technologies. Register for BlackBerryreg; DevCon today!
http://p.sf.net/sfu/rim-devcon-copy1 ___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] Windows installation problems

2011-07-26 Thread PyTables Org


Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: July 26, 2011 3:18:45 PM GMT+02:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: José María García Pérez josemaria.alk...@gmail.com
 Date: July 26, 2011 3:18:38 PM GMT+02:00
 To: pytables-users@lists.sourceforge.net
 Subject: Windows installation problems
 
 
 Dear all,
 I have been using PyTables from time to time from long ago. I am trying to 
 use it again, but this time I am not managing to make it work in Windows (I 
 am using it in Linux). I used the binary installation:
 tables-2.2.1.win32-py2.7.exe
 
 I am using a laptop, 32bits with Windows XP, no admin rights and python 2.7. 
 The installation finished without any complain. But then I get the following:
 Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on 
 win32
 Type help, copyright, credits or license for more information.
  import tables
 Traceback (most recent call last):
   File stdin, line 1, in module
   File c:\Home\C08937\Python27\Lib\site-packages\tables\__init__.py, line 
 63,
 in module
 from tables.utilsExtension import getPyTablesVersion, getHDF5Version
 ImportError: DLL load failed: No se pudo iniciar la aplicaci≤n porque su 
 configu
 raci≤n es incorrecta. Reinstalar la aplicaci≤n puede solucionar el problema.
 
 
 I have investigated as much as a I could. I tried Dependency Walker and 
 Resource Hacker, but I get nowhere. I believe I have the required DLLs in 
 the system and accesible in the path. When I open hd5dll.dll with Dependency 
 Walker it complains about:
 Error: The Side-by-Side configuration information for 
 \python27\lib\site-packages\tables\HDF5DLL.DLL contains errors. No se 
 pudo iniciar la aplicacin porque su configuracin es incorrecta. Reinstalar 
 la aplicacin puede solucionar el problema (14001).
 Error: The Side-by-Side configuration information for 
 \python27\lib\site-packages\tables\SZIP.DLL contains errors. No se pudo 
 iniciar la aplicacin porque su configuracin es incorrecta. Reinstalar la 
 aplicacin puede solucionar el problema (14001).
 
 Any clue? Could anybody state a systematic approach to get it working?
 
 Cheers,
 José M.
 
 

--
Magic Quadrant for Content-Aware Data Loss Prevention
Research study explores the data loss prevention market. Includes in-depth
analysis on the changes within the DLP market, and the criteria used to
evaluate the strengths and weaknesses of these DLP solutions.
http://www.accelacomm.com/jaw/sfnl/114/51385063/___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users


[Pytables-users] PyPy and Python3

2011-07-26 Thread PyTables Org


Begin forwarded message:

 From: pytables-users-boun...@lists.sourceforge.net
 Date: July 26, 2011 3:31:00 PM GMT+02:00
 To: pytables-users-ow...@lists.sourceforge.net
 Subject: Auto-discard notification
 
 The attached message has been automatically discarded.
 From: José María García Pérez josemaria.alk...@gmail.com
 Date: July 26, 2011 3:30:53 PM GMT+02:00
 To: pytables-users@lists.sourceforge.net
 Subject: PyPy and Python3
 
 
 Dear all,
 I am pleased to see that the new pytables will be based in the pro version: 
 https://github.com/PyTables/PyTables
 
 Given the focus on performance, is there any plan to support 
 http://www.pypy.org? I assume it won't happen any time soon given the 
 dependency on numpy, and numpy itself being not supported yet (despite the 
 promissing results: 
 http://morepypy.blogspot.com/2011/05/numpy-in-pypy-status-and-roadmap.html).
 
 What is the situation with python 3?
 
 Cheers,
 José M.
 
 

--
Magic Quadrant for Content-Aware Data Loss Prevention
Research study explores the data loss prevention market. Includes in-depth
analysis on the changes within the DLP market, and the criteria used to
evaluate the strengths and weaknesses of these DLP solutions.
http://www.accelacomm.com/jaw/sfnl/114/51385063/___
Pytables-users mailing list
Pytables-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytables-users