Coder Social home page Coder Social logo

gpleiss / falkon Goto Github PK

View Code? Open in Web Editor NEW

This project forked from falkonml/falkon

0.0 1.0 0.0 7.71 MB

Large-scale, multi-GPU capable, kernel solver

Home Page: https://falkonml.github.io/falkon/

License: MIT License

Shell 6.14% Python 68.17% Cuda 5.95% C++ 1.54% C 0.07% Jupyter Notebook 18.13%

falkon's Introduction

Falkon

Python implementation of the Falkon algorithm for large-scale, approximate kernel ridge regression.

The code is well optimized and can scale to problems with tens of millions of points. Full kernel matrices are never computed explicitly so that you will not run out of memory on large problems.

Preconditioned conjugate gradient optimization ensures that only few iterations are necessary to obtain good results.

The basic algorithm is a Nyström approximation to KRR, which needs only three hyperparameters:

  1. The number of centers M - this controls the quality of the approximation: a higher number of centers will produce more accurate results at the expense of more computation time, and higher memory requirements.
  2. The penalty term, which controls the amount of regularization.
  3. The kernel function. A good default is always the Gaussian (or RBF) kernel (falkon.kernels.GaussianKernel).

For more information about the algorithm and the optimized solver, download our paper: Kernel methods through the roof: handling billions of points efficiently

The API is sklearn-like, so that Falkon should be easy to integrate in your existing code.

Documentation

Extensive documentation is available at https://falkonml.github.io/falkon/. Several worked-through examples are also provided in the docs.

If you find a bug, please open a new issue on GitHub!

Installing

Prerequisites are PyTorch >= 1.4 (with the CUDA toolkit if GPU support is desired) and a patched version of KeOps (which is distributed as a git submodule of this repository), cmake, and a C++ compiler which can compile PyTorch extensions (i.e. capable of compiling with -std=c++11).

Once the prerequisites are met, you can pip install . from the root of this repository.

For more detailed installation instructions see the docs.

Reference

If you find this library useful for your work, please cite the following publication:

@misc{falkonlibrary2020,
    title={Kernel methods through the roof: handling billions of points efficiently},
    authors={Meanti, Giacomo and Carratino, Luigi and Rosasco, Lorenzo and Rudi, Alessandro},
    year = {2020},
    archivePrefix = {arXiv},
    eprint = {2006.10350}
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.