Coder Social home page Coder Social logo

Weight updates on the GPU about somoclu HOT 1 CLOSED

peterwittek avatar peterwittek commented on July 18, 2024
Weight updates on the GPU

from somoclu.

Comments (1)

peterwittek avatar peterwittek commented on July 18, 2024

Commits 0ff6a92 and 31d41b5 implement in-place codebook updates for the dense and sparse CPU kernels when compiled without MPI.

A similar mechanism was implemented for the GPU (commit b3b4440), but the update does not happen on the GPU. There are two ways of doing it, and neither of them would be efficient:

  1. Formulate the in-place update as W = W + H X, where W is the codebook, X is the data, and H is the matrix of the update weights (it includes the learning rate). H could be calculated efficiently on the GPU, and W+HX is a standard BLAS call. The problem is that H would have to be in the GPU memory, and its size is #rows x #columns x #data_points, where the rows and columns refer to the map. So calculating H would severely restrict the size of the problems that can be solved on the GPU.
  2. The second option is writing a kernel that calculates the W update directly. The problem here is the memory access patterns: each entry of the X matrix would have to be fetched #rows x #columns times, which simply cannot be efficient.

from somoclu.

Related Issues (20)

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.