Logo

Indie Machine Learning and Video Game Dev

Neural Net Downloads
How to
Useful links
Hardware Reviews
Get Merch
About

Tensorflow.js gflops test

by Mathieu Poliquin

The test uses the following code. Please press the “Start Test” button after the Host Info section.

  const matSize = 2 * 1024;
  const mat1 = tf.ones([matSize, matSize], tf.float32);
  const mat2 = tf.ones([matSize, matSize], tf.float32);
  const matmulTime = await tf.time(() => tf.matMul(mat1, mat2));
  var time = matmulTime.kernelMs / 1000;
  totalFlops = 2 * Math.pow(matSize,3);
  gflops = 1.0e-9 * totalFlops / time;

Host Info

GPU
TF Version
TF Backend
WebGL version
Force f16 textures
Debug Mode

Note: Works only on Chrome Desktop version for now

Test Result
MatMul

Output

tags: tensorflow.js - gflops - performance - test - benchmark