build fix

pull/70/head
Vladimir Mandic 2021-02-21 14:06:13 -05:00
parent 3e84e00179
commit 8b5deabf7e
21 changed files with 443159 additions and 10278 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,7 +1,7 @@
{
"inputs": {
"dist/human.esm.js": {
"bytes": 1347291,
"bytes": 3288323,
"imports": []
},
"demo/draw.js": {
@ -43,29 +43,29 @@
"imports": [],
"exports": [],
"inputs": {},
"bytes": 2022083
"bytes": 2100196
},
"dist/demo-browser-index.js": {
"imports": [],
"exports": [],
"inputs": {
"dist/human.esm.js": {
"bytesInOutput": 1339815
"bytesInOutput": 3287206
},
"demo/draw.js": {
"bytesInOutput": 6204
"bytesInOutput": 10609
},
"demo/menu.js": {
"bytesInOutput": 10696
"bytesInOutput": 13698
},
"demo/gl-bench.js": {
"bytesInOutput": 6759
"bytesInOutput": 9352
},
"demo/browser.js": {
"bytesInOutput": 17340
"bytesInOutput": 24054
}
},
"bytes": 1388199
"bytes": 3345183
}
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

98273
dist/human.esm.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

82
dist/human.esm.json vendored
View File

@ -5,7 +5,7 @@
"imports": []
},
"dist/tfjs.esm.js": {
"bytes": 1073613,
"bytes": 2926074,
"imports": []
},
"src/tfjs/backend.ts": {
@ -499,7 +499,7 @@
"imports": [],
"exports": [],
"inputs": {},
"bytes": 1924848
"bytes": 2116348
},
"dist/human.esm.js": {
"imports": [],
@ -508,121 +508,121 @@
],
"inputs": {
"src/blazeface/facemesh.ts": {
"bytesInOutput": 1445
"bytesInOutput": 2799
},
"src/posenet/keypoints.ts": {
"bytesInOutput": 1690
"bytesInOutput": 2522
},
"src/log.ts": {
"bytesInOutput": 252
"bytesInOutput": 307
},
"dist/tfjs.esm.js": {
"bytesInOutput": 1064610
"bytesInOutput": 2847565
},
"src/tfjs/backend.ts": {
"bytesInOutput": 1205
"bytesInOutput": 1971
},
"src/blazeface/blazeface.ts": {
"bytesInOutput": 2185
"bytesInOutput": 4926
},
"src/blazeface/box.ts": {
"bytesInOutput": 834
"bytesInOutput": 1663
},
"src/blazeface/util.ts": {
"bytesInOutput": 858
"bytesInOutput": 2253
},
"src/blazeface/coords.ts": {
"bytesInOutput": 28983
"bytesInOutput": 40670
},
"src/blazeface/facepipeline.ts": {
"bytesInOutput": 5040
"bytesInOutput": 11628
},
"src/human.ts": {
"bytesInOutput": 10441
"bytesInOutput": 16795
},
"src/faceboxes/faceboxes.ts": {
"bytesInOutput": 1549
"bytesInOutput": 2704
},
"src/profile.ts": {
"bytesInOutput": 606
"bytesInOutput": 952
},
"src/age/age.ts": {
"bytesInOutput": 775
"bytesInOutput": 1468
},
"src/gender/gender.ts": {
"bytesInOutput": 1237
"bytesInOutput": 2575
},
"src/emotion/emotion.ts": {
"bytesInOutput": 1180
"bytesInOutput": 2279
},
"src/embedding/embedding.ts": {
"bytesInOutput": 794
"bytesInOutput": 1574
},
"src/posenet/posenet.ts": {
"bytesInOutput": 1007
"bytesInOutput": 2172
},
"src/posenet/modelBase.ts": {
"bytesInOutput": 646
"bytesInOutput": 1258
},
"src/posenet/heapSort.ts": {
"bytesInOutput": 1017
"bytesInOutput": 1442
},
"src/posenet/buildParts.ts": {
"bytesInOutput": 456
"bytesInOutput": 1506
},
"src/posenet/decodePose.ts": {
"bytesInOutput": 1292
"bytesInOutput": 4651
},
"src/posenet/vectors.ts": {
"bytesInOutput": 346
"bytesInOutput": 779
},
"src/posenet/decoders.ts": {
"bytesInOutput": 768
"bytesInOutput": 1851
},
"src/posenet/decodeMultiple.ts": {
"bytesInOutput": 557
"bytesInOutput": 1710
},
"src/posenet/util.ts": {
"bytesInOutput": 354
"bytesInOutput": 791
},
"src/handpose/handpose.ts": {
"bytesInOutput": 1263
"bytesInOutput": 2291
},
"src/handpose/box.ts": {
"bytesInOutput": 938
"bytesInOutput": 1893
},
"src/handpose/handdetector.ts": {
"bytesInOutput": 1668
"bytesInOutput": 3379
},
"src/handpose/util.ts": {
"bytesInOutput": 816
"bytesInOutput": 2198
},
"src/handpose/handpipeline.ts": {
"bytesInOutput": 2449
"bytesInOutput": 5811
},
"src/handpose/anchors.ts": {
"bytesInOutput": 126985
"bytesInOutput": 221202
},
"src/gesture/gesture.ts": {
"bytesInOutput": 2391
"bytesInOutput": 4071
},
"src/imagefx.js": {
"bytesInOutput": 10975
"bytesInOutput": 18706
},
"src/image.ts": {
"bytesInOutput": 2379
"bytesInOutput": 4545
},
"config.js": {
"bytesInOutput": 1426
"bytesInOutput": 2172
},
"src/sample.ts": {
"bytesInOutput": 55295
"bytesInOutput": 55311
},
"package.json": {
"bytesInOutput": 2572
"bytesInOutput": 3333
}
},
"bytes": 1347291
"bytes": 3288323
}
}
}

24458
dist/human.node-gpu.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

24458
dist/human.node.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

82
dist/human.node.json vendored
View File

@ -5,7 +5,7 @@
"imports": []
},
"dist/tfjs.esm.js": {
"bytes": 690,
"bytes": 1287,
"imports": []
},
"src/tfjs/backend.ts": {
@ -499,128 +499,128 @@
"imports": [],
"exports": [],
"inputs": {},
"bytes": 705433
"bytes": 819941
},
"dist/human.node-gpu.js": {
"imports": [],
"exports": [],
"inputs": {
"dist/tfjs.esm.js": {
"bytesInOutput": 551
"bytesInOutput": 1238
},
"src/blazeface/facemesh.ts": {
"bytesInOutput": 1476
"bytesInOutput": 2859
},
"src/posenet/keypoints.ts": {
"bytesInOutput": 1677
"bytesInOutput": 2527
},
"src/human.ts": {
"bytesInOutput": 10449
"bytesInOutput": 16854
},
"src/log.ts": {
"bytesInOutput": 251
"bytesInOutput": 307
},
"src/tfjs/backend.ts": {
"bytesInOutput": 1304
"bytesInOutput": 2045
},
"src/blazeface/blazeface.ts": {
"bytesInOutput": 2329
"bytesInOutput": 5074
},
"src/blazeface/facepipeline.ts": {
"bytesInOutput": 5089
"bytesInOutput": 11690
},
"src/blazeface/box.ts": {
"bytesInOutput": 854
"bytesInOutput": 1713
},
"src/blazeface/util.ts": {
"bytesInOutput": 848
"bytesInOutput": 2247
},
"src/blazeface/coords.ts": {
"bytesInOutput": 28973
"bytesInOutput": 40670
},
"src/faceboxes/faceboxes.ts": {
"bytesInOutput": 1586
"bytesInOutput": 2757
},
"src/profile.ts": {
"bytesInOutput": 604
"bytesInOutput": 950
},
"src/age/age.ts": {
"bytesInOutput": 822
"bytesInOutput": 1525
},
"src/gender/gender.ts": {
"bytesInOutput": 1310
"bytesInOutput": 2663
},
"src/emotion/emotion.ts": {
"bytesInOutput": 1247
"bytesInOutput": 2360
},
"src/embedding/embedding.ts": {
"bytesInOutput": 838
"bytesInOutput": 1627
},
"src/posenet/posenet.ts": {
"bytesInOutput": 1030
"bytesInOutput": 2210
},
"src/posenet/modelBase.ts": {
"bytesInOutput": 656
"bytesInOutput": 1303
},
"src/posenet/heapSort.ts": {
"bytesInOutput": 1017
"bytesInOutput": 1440
},
"src/posenet/buildParts.ts": {
"bytesInOutput": 454
"bytesInOutput": 1506
},
"src/posenet/decodePose.ts": {
"bytesInOutput": 1282
"bytesInOutput": 4649
},
"src/posenet/vectors.ts": {
"bytesInOutput": 345
"bytesInOutput": 772
},
"src/posenet/decoders.ts": {
"bytesInOutput": 823
"bytesInOutput": 1937
},
"src/posenet/decodeMultiple.ts": {
"bytesInOutput": 553
"bytesInOutput": 1710
},
"src/posenet/util.ts": {
"bytesInOutput": 352
"bytesInOutput": 788
},
"src/handpose/handpose.ts": {
"bytesInOutput": 1304
"bytesInOutput": 2340
},
"src/handpose/handdetector.ts": {
"bytesInOutput": 1813
"bytesInOutput": 3551
},
"src/handpose/box.ts": {
"bytesInOutput": 958
"bytesInOutput": 1945
},
"src/handpose/handpipeline.ts": {
"bytesInOutput": 2470
"bytesInOutput": 5870
},
"src/handpose/util.ts": {
"bytesInOutput": 806
"bytesInOutput": 2198
},
"src/handpose/anchors.ts": {
"bytesInOutput": 126985
"bytesInOutput": 221202
},
"src/gesture/gesture.ts": {
"bytesInOutput": 2391
"bytesInOutput": 4071
},
"src/image.ts": {
"bytesInOutput": 2362
"bytesInOutput": 4573
},
"src/imagefx.js": {
"bytesInOutput": 10973
"bytesInOutput": 18690
},
"config.js": {
"bytesInOutput": 1426
"bytesInOutput": 2172
},
"src/sample.ts": {
"bytesInOutput": 55295
"bytesInOutput": 55311
},
"package.json": {
"bytesInOutput": 2569
"bytesInOutput": 3341
}
},
"bytes": 276844
"bytes": 443407
}
}
}

98295
dist/human.ts vendored

File diff suppressed because one or more lines are too long

4
dist/human.ts.map vendored

File diff suppressed because one or more lines are too long

82
dist/human.tson vendored
View File

@ -5,7 +5,7 @@
"imports": []
},
"dist/tfjs.esm.js": {
"bytes": 1073613,
"bytes": 2926074,
"imports": []
},
"src/tfjs/backend.ts": {
@ -499,128 +499,128 @@
"imports": [],
"exports": [],
"inputs": {},
"bytes": 1924859
"bytes": 2119570
},
"dist/human.ts": {
"imports": [],
"exports": [],
"inputs": {
"src/blazeface/facemesh.ts": {
"bytesInOutput": 1445
"bytesInOutput": 2913
},
"src/posenet/keypoints.ts": {
"bytesInOutput": 1690
"bytesInOutput": 2710
},
"src/human.ts": {
"bytesInOutput": 10477
"bytesInOutput": 17758
},
"src/log.ts": {
"bytesInOutput": 252
"bytesInOutput": 319
},
"dist/tfjs.esm.js": {
"bytesInOutput": 1064610
"bytesInOutput": 2989323
},
"src/tfjs/backend.ts": {
"bytesInOutput": 1205
"bytesInOutput": 2107
},
"src/blazeface/blazeface.ts": {
"bytesInOutput": 2185
"bytesInOutput": 5146
},
"src/blazeface/box.ts": {
"bytesInOutput": 834
"bytesInOutput": 1753
},
"src/blazeface/util.ts": {
"bytesInOutput": 858
"bytesInOutput": 2381
},
"src/blazeface/coords.ts": {
"bytesInOutput": 28983
"bytesInOutput": 47204
},
"src/blazeface/facepipeline.ts": {
"bytesInOutput": 5040
"bytesInOutput": 12096
},
"src/faceboxes/faceboxes.ts": {
"bytesInOutput": 1549
"bytesInOutput": 2838
},
"src/profile.ts": {
"bytesInOutput": 606
"bytesInOutput": 996
},
"src/age/age.ts": {
"bytesInOutput": 775
"bytesInOutput": 1570
},
"src/gender/gender.ts": {
"bytesInOutput": 1237
"bytesInOutput": 2731
},
"src/emotion/emotion.ts": {
"bytesInOutput": 1180
"bytesInOutput": 2417
},
"src/embedding/embedding.ts": {
"bytesInOutput": 794
"bytesInOutput": 1656
},
"src/posenet/posenet.ts": {
"bytesInOutput": 1007
"bytesInOutput": 2280
},
"src/posenet/modelBase.ts": {
"bytesInOutput": 646
"bytesInOutput": 1322
},
"src/posenet/heapSort.ts": {
"bytesInOutput": 1017
"bytesInOutput": 1564
},
"src/posenet/buildParts.ts": {
"bytesInOutput": 456
"bytesInOutput": 1578
},
"src/posenet/decodePose.ts": {
"bytesInOutput": 1292
"bytesInOutput": 4827
},
"src/posenet/vectors.ts": {
"bytesInOutput": 346
"bytesInOutput": 839
},
"src/posenet/decoders.ts": {
"bytesInOutput": 768
"bytesInOutput": 1945
},
"src/posenet/decodeMultiple.ts": {
"bytesInOutput": 557
"bytesInOutput": 1772
},
"src/posenet/util.ts": {
"bytesInOutput": 354
"bytesInOutput": 837
},
"src/handpose/handpose.ts": {
"bytesInOutput": 1263
"bytesInOutput": 2405
},
"src/handpose/box.ts": {
"bytesInOutput": 938
"bytesInOutput": 1991
},
"src/handpose/handdetector.ts": {
"bytesInOutput": 1668
"bytesInOutput": 3525
},
"src/handpose/util.ts": {
"bytesInOutput": 816
"bytesInOutput": 2320
},
"src/handpose/handpipeline.ts": {
"bytesInOutput": 2449
"bytesInOutput": 6065
},
"src/handpose/anchors.ts": {
"bytesInOutput": 126985
"bytesInOutput": 256534
},
"src/gesture/gesture.ts": {
"bytesInOutput": 2391
"bytesInOutput": 4241
},
"src/imagefx.js": {
"bytesInOutput": 10975
"bytesInOutput": 20118
},
"src/image.ts": {
"bytesInOutput": 2379
"bytesInOutput": 4753
},
"config.js": {
"bytesInOutput": 1426
"bytesInOutput": 2388
},
"src/sample.ts": {
"bytesInOutput": 55295
"bytesInOutput": 55315
},
"package.json": {
"bytesInOutput": 2572
"bytesInOutput": 3569
}
},
"bytes": 1347333
"bytes": 3478889
}
}
}

76493
dist/tfjs.esm.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

7248
dist/tfjs.esm.json vendored

File diff suppressed because it is too large Load Diff

View File

@ -132,7 +132,7 @@ const targets = {
platform: 'browser',
format: 'iife',
globalName: 'Human',
metafile: 'dist/human.tson',
metafile: 'dist/human.iife.json',
entryPoints: ['src/human.ts'],
outfile: 'dist/human.ts',
external: ['fs', 'buffer', 'util'],

View File

@ -288,11 +288,11 @@ class Human {
// run emotion, inherits face from blazeface
this.analyze('Start Embedding:');
if (this.config.async) {
embeddingRes = this.config.face.embedding.enabled ? embedding.predict(face.image, this.config) : {};
embeddingRes = this.config.face.embedding.enabled ? embedding.predict(face.image, this.config) : [];
} else {
this.state = 'run:embedding';
timeStamp = now();
embeddingRes = this.config.face.embedding.enabled ? await embedding.predict(face.image, this.config) : {};
embeddingRes = this.config.face.embedding.enabled ? await embedding.predict(face.image, this.config) : [];
this.perf.embedding = Math.trunc(now() - timeStamp);
}
this.analyze('End Emotion:');