0.0.8 • Published 2 years ago

libsvm-wasm v0.0.8

Weekly downloads
-
License
ISC
Repository
github
Last release
2 years ago

libsvm-wasm

Brief

This is a wasm export for libsvm It allows you to directly run & train svm model in js env without installing any non-js dependency.

Build

git submodule init
git submodule update
make

After this command, you will get the wasm in dist folder.

Usage

Note: No bundle support for now. You may want to build on yourself or use ts-node to write a ts script.

import {SVM} from './src/libsvm';

const svm = new SVM();
await svm.init()
const data = [[-1, -1], [1, 1], [2, 2], [-2, -2]]
const label = [-1, 1, 1, -1];

svm.feedSamples(data, label);
await svm.train();
svm.predict([3, 3]);

Roadmap

  • Building & Bundling & Packaging
  • Benchmark V.S. native
  • More API
  • SIMD operation to enhance performance
  • Store Model using native fs API
0.0.8

2 years ago

0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago