Skip to content

🫐 very simple neural network framework and NPM package, powered by WASM

License

Notifications You must be signed in to change notification settings

Maksasj/blueb.js

Repository files navigation

blueb.js 🫐

blueb.js - very simple neural network framework npm package, powered by wasm.

Overview

Underhood blueb.js uses my C stb style single-header blueberry.h library as neural network framework, as well as some other utility C libraries such as lemon.h and peach.h, for memory allocations and linear algebra functionality respectively.

Higly inspired by tsodings nn library github.com/tsoding/nn.h

Sadly this time blueb.js is a NEW javascript framework btw.

Links

  1. Live demonstration of a web application what uses blueb.js maksasj.github.io/nnate
  2. Node package page npmjs.com/package/blueb.js
  3. Source code avaiable at github.com/Maksasj/blueb.js
  4. blueberry.h and other C libraries source code github.com/Maksasj/caifu

Cool looking widgets license version NPM Version

Build

  1. Build manually
    First of all requirements:

    • Clang 14.0.0
    • wasm-ld
    • Node (Have test with Node v20.11.0)

    Building process involves building wasm and node package, in root directory you can find a bash.sh file. This bash script can be used for building a wasm module.

    # Build wasm module
    set -xe
    
    clang \
        -Wall \
        -Wextra \
        -I3dparty/caifu/lemon \
        -I3dparty/caifu \
        --target=wasm32 \
        -o blueberry.o \
        -c ./src/c/blueberry.c \
    
    wasm-ld \
        -m wasm32 \
        --no-entry --export-all --allow-undefined \
        -o dist/blueberry.wasm blueberry.o \
    
    # Delete temporary object file
    rm blueberry.o

    Therefore node package could be builded with simple, command.

    npm run build

    Actually above command will automatically try to build wasm file and node package and put everything into dist folder.

License

blueb.js is free and open source library/package. All code in this repository is licensed under

About

🫐 very simple neural network framework and NPM package, powered by WASM

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published