fa.bianp.net

memory efficient bindigs for libsvm

Category: General, scikit-learn

scikits.learn.svm now uses LibSVM-dense instead of LibSVM for some support vector machine related algorithms when input is a dense matrix. As a result most of the copies associated with argument passing are avoided, giving 50% less memory footprint and several times less than the python bindings that ship with libsvm, which stores data in the very inefficient python list structure. On the performance side I didn't see any significant difference, although on large datasets less memory footprint can make the difference between swapping or not.