GithubHelp home page GithubHelp logo

vectorious's Introduction

vectorious

version travis climate coverage

A high performance linear algebra library, written in JavaScript and optimized with C++ bindings to BLAS.

Usage

In node.js
$ npm install vectorious
var v = require('vectorious'),
    Matrix = v.Matrix,
    Vector = v.Vector,
    BLAS = v.BLAS; // access BLAS routines

Will use your local BLAS copy (if any). Some notes for different operating systems:

In browser

Download a release and use it like this:

<script src="vectorious-4.x.x.min.js"></script>
<script>
  var A = new Matrix([[1], [2], [3]]),
      B = new Matrix([[1, 3, 5]]),
      C = A.multiply(B);

  console.log('C:', C.toArray());
  /* C: [
    [1, 3, 5],
    [2, 6, 10],
    [3, 9, 15]
  ] */
</script>

Examples

Basic

Machine learning

Documentation

The documentation is located in the wiki section of this repository.

Go to wiki.

Benchmarks

Internal benchmarks are located in the wiki section of this repository.

Go to wiki.

Compared to other libraries

The following benchmarks compare Vectorious 4.1.0 with three popular matrix/vector libraries:

The graphs show operations per second on the vertical (y) axis.

Below is a graph comparing the vector operations add, angle, dot, magnitude (aka L2-norm), normalize and scale.

The operations were performed on vectors generated with Vector.random(1048576).

Vector operations

Below is a graph comparing the matrix operations add, scale and transpose.

The operations were performed on matrices generated with Matrix.random(512, 512).

Matrix operations

vectorious's People

Contributors

mateogianolio avatar metabench avatar waylonflinn avatar lucidrains avatar xuefeng-zhu avatar akdor1154 avatar

Watchers

James Cloos avatar  avatar

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.