From 086c721a77517023969bff25e820cc1a1c1faa61 Mon Sep 17 00:00:00 2001 From: Vladimir Mandic Date: Sun, 25 Apr 2021 16:58:18 -0400 Subject: [PATCH] update browser demo defaults --- demo/index.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/demo/index.js b/demo/index.js index 2249cf7a..562824c6 100644 --- a/demo/index.js +++ b/demo/index.js @@ -1,15 +1,15 @@ // @ts-nocheck -/* global tf */ import Human from '../dist/human.esm.js'; // equivalent of @vladmandic/human // import Human from '../dist/human.esm-nobundle.js'; // this requires that tf is loaded manually and bundled before human can be used import Menu from './helpers/menu.js'; import GLBench from './helpers/gl-bench.js'; import webRTC from './helpers/webrtc.js'; -// const userConfig = {}; +const userConfig = {}; let human; +/* const userConfig = { backend: 'humangl', async: false, @@ -32,6 +32,7 @@ const userConfig = { // body: { enabled: true, modelPath: 'blazepose.json' }, // object: { enabled: true }, }; +*/ // ui options const ui = { @@ -619,7 +620,9 @@ async function main() { // create instance of human human = new Human(userConfig); if (typeof tf !== 'undefined') { + // eslint-disable-next-line no-undef log('TensorFlow external version:', tf.version); + // eslint-disable-next-line no-undef human.tf = tf; // use externally loaded version of tfjs }