mirror of https://github.com/vladmandic/human
update
parent
09fe21c7af
commit
3f6d0aa9eb
|
@ -65,7 +65,7 @@ export default {
|
|||
modelPath: '../models/blazeface-back.json', // can be 'blazeface-front', 'blazeface-back' or 'faceboxes'
|
||||
// 'blazeface-front' is blazeface model optimized for large faces such as front-facing camera
|
||||
// 'blazeface-back' is blazeface model optimized for smaller and/or distanct faces
|
||||
// 'faceboxes' is alternative model to 'blazeface
|
||||
// 'faceboxes' is alternative model to 'blazeface'
|
||||
inputSize: 256, // fixed value: 128 for front and 256 for 'back'
|
||||
rotation: false, // use best-guess rotated face image or just box with rotation as-is
|
||||
// false means higher performance, but incorrect mesh mapping if face angle is above 20 degrees
|
||||
|
|
|
@ -8,9 +8,8 @@ import draw from './draw.js';
|
|||
import Menu from './menu.js';
|
||||
import GLBench from './gl-bench.js';
|
||||
|
||||
const userConfig = {}; // add any user configuration overrides
|
||||
// const userConfig = {}; // add any user configuration overrides
|
||||
|
||||
/*
|
||||
const userConfig = {
|
||||
backend: 'wasm',
|
||||
async: false,
|
||||
|
@ -19,7 +18,6 @@ const userConfig = {
|
|||
body: { enabled: false },
|
||||
hand: { enabled: false },
|
||||
};
|
||||
*/
|
||||
|
||||
const human = new Human(userConfig);
|
||||
|
||||
|
@ -532,6 +530,8 @@ async function main() {
|
|||
if (ui.modelsPreload && !ui.useWorker) {
|
||||
status('loading');
|
||||
await human.load(userConfig); // this is not required, just pre-loads all models
|
||||
const loaded = Object.keys(human.models).filter((a) => human.models[a]).map((b) => b);
|
||||
log('Demo loaded models:', loaded);
|
||||
}
|
||||
if (!ui.useWorker) {
|
||||
status('initializing');
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -17,7 +17,7 @@
|
|||
"imports": []
|
||||
},
|
||||
"demo/browser.js": {
|
||||
"bytes": 26721,
|
||||
"bytes": 26849,
|
||||
"imports": [
|
||||
{
|
||||
"path": "dist/human.esm.js",
|
||||
|
@ -43,7 +43,7 @@
|
|||
"imports": [],
|
||||
"exports": [],
|
||||
"inputs": {},
|
||||
"bytes": 2037877
|
||||
"bytes": 2038335
|
||||
},
|
||||
"dist/demo-browser-index.js": {
|
||||
"imports": [],
|
||||
|
@ -51,7 +51,7 @@
|
|||
"entryPoint": "demo/browser.js",
|
||||
"inputs": {
|
||||
"dist/human.esm.js": {
|
||||
"bytesInOutput": 1331552
|
||||
"bytesInOutput": 1331550
|
||||
},
|
||||
"demo/draw.js": {
|
||||
"bytesInOutput": 6241
|
||||
|
@ -63,10 +63,10 @@
|
|||
"bytesInOutput": 6759
|
||||
},
|
||||
"demo/browser.js": {
|
||||
"bytesInOutput": 17341
|
||||
"bytesInOutput": 17645
|
||||
}
|
||||
},
|
||||
"bytes": 1379974
|
||||
"bytes": 1380276
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1645,9 +1645,9 @@
|
|||
}
|
||||
},
|
||||
"google-protobuf": {
|
||||
"version": "3.15.2",
|
||||
"resolved": "https://registry.npmjs.org/google-protobuf/-/google-protobuf-3.15.2.tgz",
|
||||
"integrity": "sha512-HU67XsVFarxjHceJgrX0K75zzUFS+95LTArAncQ1BI156oEZR+fWXgk6Fxn4fNIpmrB0fwklwjXhMB0DQe0YNg==",
|
||||
"version": "3.15.3",
|
||||
"resolved": "https://registry.npmjs.org/google-protobuf/-/google-protobuf-3.15.3.tgz",
|
||||
"integrity": "sha512-+q6w/pTPS8hmdeHe+OWO7PRKOkqtPM4+dxUUOtC9lLgiaLUd7FQq+0EkTt9UmEHf2KMigkbV1fIxSr73t/JG/A==",
|
||||
"dev": true
|
||||
},
|
||||
"graceful-fs": {
|
||||
|
@ -2655,9 +2655,9 @@
|
|||
"dev": true
|
||||
},
|
||||
"string-width": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.0.tgz",
|
||||
"integrity": "sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg==",
|
||||
"version": "4.2.1",
|
||||
"resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.1.tgz",
|
||||
"integrity": "sha512-LL0OLyN6AnfV9xqGQpDBwedT2Rt63737LxvsRxbcwpa2aIeynBApG2Sm//F3TaLHIR1aJBN52DWklc06b94o5Q==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"emoji-regex": "^8.0.0",
|
||||
|
@ -2837,9 +2837,9 @@
|
|||
"dev": true
|
||||
},
|
||||
"typescript": {
|
||||
"version": "4.3.0-dev.20210225",
|
||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.3.0-dev.20210225.tgz",
|
||||
"integrity": "sha512-EdKY+0vy3jYPqWZDj6x3VTC30e3Rq+flaFpCLH9r2bwX0+VTOqZuM3qOQpWoq4L1c4p/ye2xJd3Y79iweqzlCw==",
|
||||
"version": "4.3.0-dev.20210226",
|
||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.3.0-dev.20210226.tgz",
|
||||
"integrity": "sha512-jxqKjVQsHkEMbyacr5CFpWnU3pv7H9QBljjORr3ct7qq+Q7ynHHmmFd5zQjU8HgHZYOMapIBhLsZSeqUeduQGQ==",
|
||||
"dev": true
|
||||
},
|
||||
"uri-js": {
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
"seedrandom": "^3.0.5",
|
||||
"simple-git": "^2.35.2",
|
||||
"tslib": "^2.1.0",
|
||||
"typescript": "^4.3.0-dev.20210225"
|
||||
"typescript": "^4.3.0-dev.20210226"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "node --trace-warnings --unhandled-rejections=strict --trace-uncaught --no-deprecation src/node.js",
|
||||
|
|
|
@ -52,7 +52,8 @@ async function main() {
|
|||
logger.info('TFJS Flags:', tf.env().features);
|
||||
logger.info('Loading models:');
|
||||
await human.load(config);
|
||||
for (const model of Object.keys(human.models)) logger.info(' Loaded:', model);
|
||||
const loaded = Object.keys(human.models).filter((a) => human.models[a]).map((b) => b);
|
||||
logger.info('Loaded:', loaded);
|
||||
logger.info('Memory state:', human.tf.engine().memory());
|
||||
logger.info('Test Complete');
|
||||
}
|
||||
|
|
2
wiki
2
wiki
|
@ -1 +1 @@
|
|||
Subproject commit d99aa10997927e21559297d3b8e58718cb7c1f28
|
||||
Subproject commit ac89ded33d7063aa059575eae1df3f81bfb35b7f
|
Loading…
Reference in New Issue