[BioPython] Support Vector Machine

Michiel Jan Laurens de Hoon mdehoon@ims.u-tokyo.ac.jp
Wed, 04 Dec 2002 17:33:09 +0900


It looks like the Python-C wrapper stuff in cSVMmodule.c was not 
generated automatically but written by hand, which could be error prone 
and cause a memory leak.

Wrappers for C functions can be generated automatically with SWIG and 
Pyfort. Pyfort is specifically written to be used with Numerical Python, 
see http://pyfortran.sourceforge.net/.
(don't be appalled by the mention of Fortran, pyfort can handle C too).
My guess is that the memory leaks will go away if the hand-written code 
is replaced by an automatically generated wrapper.  I can help out with 
the details, if needed.

--Michiel.


Michael Sorich wrote:

> 
> I have noticed that inputing the xs and ys to the train function of the 
> SVM module as arrays instead of lists results in a memory leak. Has 
> anyone else noticed this? I thing the problem is somewhere in the _F 
> function of the Trainer class.
> 
> Has anyone done any work to optimising the training code? It seems a 
> little slow. Could someone who understands the code comment on the easy 
> of doing this (eg using numeric arrays wherever possible)?
> 
> Thanks
> 
> Michael
> 
> 
> 
> 
> _________________________________________________________________
> STOP MORE SPAM with the new MSN 8 and get 2 months FREE* 
> http://join.msn.com/?page=features/junkmail
> 
> _______________________________________________
> BioPython mailing list  -  BioPython@biopython.org
> http://biopython.org/mailman/listinfo/biopython
> 
> 


-- 
Michiel de Hoon, Assistant Professor
University of Tokyo, Institute of Medical Science
Human Genome Center
4-6-1 Shirokane-dai, Minato-ku
Tokyo 108-8639
Japan
http://bonsai.ims.u-tokyo.ac.jp/~mdehoon