Skip to content
Tensorflow.js running on WebAssembly backend
HTML JavaScript CSS
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
img
.babelrc
.gitignore
LICENSE
README.md
index.html
index.js
package.json
styles.css
yarn.lock

README.md

Tensorflow.js running on WebAssembly backend

This repo is the code used in my blog post introducing how to run Tensorflow.js on a WebAssembly backend which is a new addition to its greatness.

Close the repo

Clone the repository:

git clone https://github.com/yashints/tjfs-wasm-demo

Install the dependencies

Install the dependencies using npm or yarn:

npm install
# or
yarn

Run the app

Run the app:

yarn watch

The app opens in a new browser window/tab.

Switching between WASM and normal backend

Simply comment the below line in index.js file and run the app again:

await tf.setBackend("wasm");
You can’t perform that action at this time.