Hi Johan, (and for the mailing list record,)
I've tackled the translation of all Biskit modules to Numpy. Everything is
tested and checked in but I am pretty sure there are still some bugs waiting for
discovery. So in terms of stability, revision 2.0.1 on sourceforge is a better
bet now than the CVS.
My first attempt yesterday ended after hours of search/replace and debugging in
real trouble -- there must be some un-obvious differences between the normal
numpy functions (dot, sum, svd, or something else) and their Numeric
counterpart. I canceled this and used the alter_code1.py script instead. Now we
are not actually importing numpy but the compability wrapper numpy.oldnumeric
which requires less changes (N.nonzero is not returning a tuple, numpy.ndarray
is aliased to N.arraytype etc.). New modules should use numpy directly.
Biggles and Bio still use Numeric. So Numeric needs to installed in parallel.
Also the test data are still containing the old Numeric arrays, I guess they
cannot be unpickled unless Numeric is installed. I've included some conversion
from Numeric to Numpy arrays in the unpickling hook of ProfileCollection but it
so far didn't seem necessary for any other classes. May be cleaner though to do
the same for PDBModel.xyz, Trajectory.frames, and Complex.info so that arrays
are always guaranteed to be numpy.
The new numpy routines are noticeable faster -- the short tests now run through
in 120 rather than 150 s. The PDBModel test code takes 1.7 rather than 2.2 s.
And this is still the old PDBModel, so not yet including the big speedup from my
PDBModel refacturing. Moreover, the transition also resolved a bug in
Statistics/Density.py ... yet another Numeric bug.
Ah, actually I just noticed that I forgot to convert the scripts/ folder...
following soon but the testing will be more difficult there.
Dr. Raik Gruenberg