updated build process

pull/50/head
Vladimir Mandic 2020-11-16 23:58:06 -05:00
parent 25ea29feca
commit e3b8d8abbf
19 changed files with 2085 additions and 516 deletions

File diff suppressed because one or more lines are too long

View File

@ -38,17 +38,15 @@
"dist/demo-browser-index.js.map": {
"imports": [],
"inputs": {},
"bytes": 5414452
"bytes": 5414456
},
"dist/demo-browser-index.js": {
"imports": [],
"exports": [],
"inputs": {
"dist/human.esm.js": {
"bytesInOutput": 1926649
},
"dist/human.esm.js": {
"bytesInOutput": 0
},
"demo/draw.js": {
"bytesInOutput": 7341
},

View File

@ -5,7 +5,7 @@
"imports": []
},
"package.json": {
"bytes": 3763,
"bytes": 2021,
"imports": []
},
"src/age/age.js": {
@ -361,6 +361,9 @@
},
"dist/human.esm-nobundle.js": {
"imports": [],
"exports": [
"default"
],
"inputs": {
"src/face/blazeface.js": {
"bytesInOutput": 5445
@ -453,7 +456,7 @@
"bytesInOutput": 163
},
"src/human.js": {
"bytesInOutput": 260
"bytesInOutput": 10583
},
"src/hand/box.js": {
"bytesInOutput": 1979
@ -461,23 +464,11 @@
"src/hand/util.js": {
"bytesInOutput": 1854
},
"src/human.js": {
"bytesInOutput": 174
},
"config.js": {
"bytesInOutput": 1431
},
"package.json": {
"bytesInOutput": 0
},
"package.json": {
"bytesInOutput": 20
},
"src/human.js": {
"bytesInOutput": 10149
},
"src/human.js": {
"bytesInOutput": 0
}
},
"bytes": 250185

File diff suppressed because one or more lines are too long

224
dist/human.esm.json vendored
View File

@ -12316,7 +12316,7 @@
]
},
"package.json": {
"bytes": 3763,
"bytes": 2021,
"imports": []
},
"src/age/age.js": {
@ -12695,10 +12695,13 @@
"dist/human.esm.js.map": {
"imports": [],
"inputs": {},
"bytes": 5323444
"bytes": 5323466
},
"dist/human.esm.js": {
"imports": [],
"exports": [
"default"
],
"inputs": {
"node_modules/node-fetch/browser.js": {
"bytesInOutput": 500
@ -12815,7 +12818,7 @@
"bytesInOutput": 4072
},
"src/tf.js": {
"bytesInOutput": 41
"bytesInOutput": 80
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend.js": {
"bytesInOutput": 9356
@ -12830,121 +12833,13 @@
"bytesInOutput": 677
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 16
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 34
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 22
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 24
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 32
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 18
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 100
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 48
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 16
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 144
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 32
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 54
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 200
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 46
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 16
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 30
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 64
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 40
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 286
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 42
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 38
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 44
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 74
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 24
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 34
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 128
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 34
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 28
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 22
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 46
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 158
"bytesInOutput": 2038
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_registry.js": {
"bytesInOutput": 837
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_registry.js": {
"bytesInOutput": 78
"bytesInOutput": 915
},
"node_modules/@tensorflow/tfjs-core/dist/util.js": {
"bytesInOutput": 1672
},
"node_modules/@tensorflow/tfjs-core/dist/util.js": {
"bytesInOutput": 1221
"bytesInOutput": 2893
},
"node_modules/@tensorflow/tfjs-core/dist/profiler.js": {
"bytesInOutput": 1957
@ -12956,22 +12851,13 @@
"bytesInOutput": 3740
},
"node_modules/@tensorflow/tfjs-core/dist/tensor.js": {
"bytesInOutput": 1770
},
"node_modules/@tensorflow/tfjs-core/dist/tensor.js": {
"bytesInOutput": 43
},
"node_modules/@tensorflow/tfjs-core/dist/tensor.js": {
"bytesInOutput": 3101
"bytesInOutput": 4914
},
"node_modules/@tensorflow/tfjs-core/dist/types.js": {
"bytesInOutput": 1571
},
"node_modules/@tensorflow/tfjs-core/dist/tensor_util.js": {
"bytesInOutput": 139
},
"node_modules/@tensorflow/tfjs-core/dist/tensor_util.js": {
"bytesInOutput": 509
"bytesInOutput": 648
},
"node_modules/@tensorflow/tfjs-core/dist/engine.js": {
"bytesInOutput": 19994
@ -13001,34 +12887,16 @@
"bytesInOutput": 572
},
"node_modules/@tensorflow/tfjs-core/dist/ops/gather_nd_util.js": {
"bytesInOutput": 109
},
"node_modules/@tensorflow/tfjs-core/dist/ops/gather_nd_util.js": {
"bytesInOutput": 1253
"bytesInOutput": 1362
},
"node_modules/@tensorflow/tfjs-core/dist/ops/scatter_nd_util.js": {
"bytesInOutput": 181
},
"node_modules/@tensorflow/tfjs-core/dist/ops/scatter_nd_util.js": {
"bytesInOutput": 2480
"bytesInOutput": 2661
},
"node_modules/@tensorflow/tfjs-core/dist/ops/slice_util.js": {
"bytesInOutput": 571
},
"node_modules/@tensorflow/tfjs-core/dist/ops/slice_util.js": {
"bytesInOutput": 6015
"bytesInOutput": 6586
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 218
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 33
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 103
"bytesInOutput": 354
},
"node_modules/@tensorflow/tfjs-core/dist/ops/mul.js": {
"bytesInOutput": 318
@ -13049,14 +12917,11 @@
"bytesInOutput": 226
},
"node_modules/@tensorflow/tfjs-core/dist/ops/segment_util.js": {
"bytesInOutput": 218
"bytesInOutput": 1142
},
"node_modules/@tensorflow/tfjs-core/dist/ops/reduce_util.js": {
"bytesInOutput": 181
},
"node_modules/@tensorflow/tfjs-core/dist/ops/segment_util.js": {
"bytesInOutput": 924
},
"node_modules/@tensorflow/tfjs-core/dist/ops/scalar.js": {
"bytesInOutput": 470
},
@ -13088,56 +12953,26 @@
"bytesInOutput": 924
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 2422
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
"bytesInOutput": 3465
},
"node_modules/@tensorflow/tfjs-core/dist/ops/rotate_util.js": {
"bytesInOutput": 218
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/ops/array_ops_util.js": {
"bytesInOutput": 1901
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/ops/selu_util.js": {
"bytesInOutput": 77
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/ops/erf_util.js": {
"bytesInOutput": 146
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/log.js": {
"bytesInOutput": 146
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/complex_util.js": {
"bytesInOutput": 1673
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 1043
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/kernels/types.js": {
"bytesInOutput": 602
},
@ -13388,28 +13223,19 @@
"bytesInOutput": 505
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/backend_wasm.js": {
"bytesInOutput": 92
"bytesInOutput": 6428
},
"node_modules/@tensorflow/tfjs-backend-wasm/wasm-out/tfjs-backend-wasm-threaded-simd.worker.js": {
"bytesInOutput": 3432
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/backend_wasm.js": {
"bytesInOutput": 5622
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/backend_wasm.js": {
"bytesInOutput": 714
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/base.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/index.js": {
"bytesInOutput": 0
},
"src/tf.js": {
"bytesInOutput": 39
},
"src/human.js": {
"bytesInOutput": 260
"bytesInOutput": 10611
},
"src/hand/box.js": {
"bytesInOutput": 1979
@ -13417,23 +13243,11 @@
"src/hand/util.js": {
"bytesInOutput": 1854
},
"src/human.js": {
"bytesInOutput": 174
},
"config.js": {
"bytesInOutput": 1431
},
"package.json": {
"bytesInOutput": 0
},
"package.json": {
"bytesInOutput": 21
},
"src/human.js": {
"bytesInOutput": 10177
},
"src/human.js": {
"bytesInOutput": 0
}
},
"bytes": 1933724

2
dist/human.js.map vendored

File diff suppressed because one or more lines are too long

211
dist/human.json vendored
View File

@ -12316,7 +12316,7 @@
]
},
"package.json": {
"bytes": 3763,
"bytes": 2021,
"imports": []
},
"src/age/age.js": {
@ -12695,10 +12695,11 @@
"dist/human.js.map": {
"imports": [],
"inputs": {},
"bytes": 5291150
"bytes": 5291172
},
"dist/human.js": {
"imports": [],
"exports": [],
"inputs": {
"node_modules/node-fetch/browser.js": {
"bytesInOutput": 500
@ -12818,7 +12819,7 @@
"bytesInOutput": 10691
},
"src/tf.js": {
"bytesInOutput": 41
"bytesInOutput": 80
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend.js": {
"bytesInOutput": 9355
@ -12833,121 +12834,13 @@
"bytesInOutput": 677
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 16
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 34
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 22
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 24
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 32
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 18
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 100
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 48
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 16
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 144
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 32
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 54
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 200
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 46
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 16
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 30
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 64
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 40
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 286
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 42
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 38
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 44
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 74
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 24
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 34
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 128
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 34
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 36
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 28
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 22
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 46
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_names.js": {
"bytesInOutput": 158
"bytesInOutput": 2038
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_registry.js": {
"bytesInOutput": 832
},
"node_modules/@tensorflow/tfjs-core/dist/kernel_registry.js": {
"bytesInOutput": 78
"bytesInOutput": 910
},
"node_modules/@tensorflow/tfjs-core/dist/util.js": {
"bytesInOutput": 1672
},
"node_modules/@tensorflow/tfjs-core/dist/util.js": {
"bytesInOutput": 1221
"bytesInOutput": 2893
},
"node_modules/@tensorflow/tfjs-core/dist/profiler.js": {
"bytesInOutput": 1957
@ -12959,22 +12852,13 @@
"bytesInOutput": 3740
},
"node_modules/@tensorflow/tfjs-core/dist/tensor.js": {
"bytesInOutput": 1770
},
"node_modules/@tensorflow/tfjs-core/dist/tensor.js": {
"bytesInOutput": 43
},
"node_modules/@tensorflow/tfjs-core/dist/tensor.js": {
"bytesInOutput": 3092
"bytesInOutput": 4905
},
"node_modules/@tensorflow/tfjs-core/dist/types.js": {
"bytesInOutput": 1571
},
"node_modules/@tensorflow/tfjs-core/dist/tensor_util.js": {
"bytesInOutput": 139
},
"node_modules/@tensorflow/tfjs-core/dist/tensor_util.js": {
"bytesInOutput": 509
"bytesInOutput": 648
},
"node_modules/@tensorflow/tfjs-core/dist/engine.js": {
"bytesInOutput": 19994
@ -13004,34 +12888,16 @@
"bytesInOutput": 572
},
"node_modules/@tensorflow/tfjs-core/dist/ops/gather_nd_util.js": {
"bytesInOutput": 109
},
"node_modules/@tensorflow/tfjs-core/dist/ops/gather_nd_util.js": {
"bytesInOutput": 1253
"bytesInOutput": 1362
},
"node_modules/@tensorflow/tfjs-core/dist/ops/scatter_nd_util.js": {
"bytesInOutput": 181
},
"node_modules/@tensorflow/tfjs-core/dist/ops/scatter_nd_util.js": {
"bytesInOutput": 2480
"bytesInOutput": 2661
},
"node_modules/@tensorflow/tfjs-core/dist/ops/slice_util.js": {
"bytesInOutput": 571
},
"node_modules/@tensorflow/tfjs-core/dist/ops/slice_util.js": {
"bytesInOutput": 6015
"bytesInOutput": 6586
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 218
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 33
},
"node_modules/@tensorflow/tfjs-core/dist/globals.js": {
"bytesInOutput": 103
"bytesInOutput": 354
},
"node_modules/@tensorflow/tfjs-core/dist/ops/mul.js": {
"bytesInOutput": 318
@ -13052,14 +12918,11 @@
"bytesInOutput": 226
},
"node_modules/@tensorflow/tfjs-core/dist/ops/segment_util.js": {
"bytesInOutput": 218
"bytesInOutput": 1142
},
"node_modules/@tensorflow/tfjs-core/dist/ops/reduce_util.js": {
"bytesInOutput": 181
},
"node_modules/@tensorflow/tfjs-core/dist/ops/segment_util.js": {
"bytesInOutput": 924
},
"node_modules/@tensorflow/tfjs-core/dist/ops/scalar.js": {
"bytesInOutput": 470
},
@ -13091,56 +12954,26 @@
"bytesInOutput": 924
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 2422
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
"bytesInOutput": 3465
},
"node_modules/@tensorflow/tfjs-core/dist/ops/rotate_util.js": {
"bytesInOutput": 218
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/ops/array_ops_util.js": {
"bytesInOutput": 1901
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/ops/selu_util.js": {
"bytesInOutput": 77
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/ops/erf_util.js": {
"bytesInOutput": 146
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/log.js": {
"bytesInOutput": 146
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/complex_util.js": {
"bytesInOutput": 1670
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-core/dist/backends/backend_util.js": {
"bytesInOutput": 1043
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/kernels/types.js": {
"bytesInOutput": 602
},
@ -13391,26 +13224,17 @@
"bytesInOutput": 505
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/backend_wasm.js": {
"bytesInOutput": 92
"bytesInOutput": 6425
},
"node_modules/@tensorflow/tfjs-backend-wasm/wasm-out/tfjs-backend-wasm-threaded-simd.worker.js": {
"bytesInOutput": 3432
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/backend_wasm.js": {
"bytesInOutput": 5619
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/backend_wasm.js": {
"bytesInOutput": 714
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/base.js": {
"bytesInOutput": 0
},
"node_modules/@tensorflow/tfjs-backend-wasm/dist/index.js": {
"bytesInOutput": 0
},
"src/tf.js": {
"bytesInOutput": 39
},
"src/hand/box.js": {
"bytesInOutput": 1975
},
@ -13420,9 +13244,6 @@
"config.js": {
"bytesInOutput": 1431
},
"package.json": {
"bytesInOutput": 0
},
"package.json": {
"bytesInOutput": 21
}

475
dist/human.node-nobundle.json vendored Normal file
View File

@ -0,0 +1,475 @@
{
"inputs": {
"config.js": {
"bytes": 8721,
"imports": []
},
"package.json": {
"bytes": 2021,
"imports": []
},
"src/age/age.js": {
"bytes": 1966,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/profile.js"
}
]
},
"src/body/buildParts.js": {
"bytes": 2035,
"imports": [
{
"path": "src/body/heapSort.js"
}
]
},
"src/body/decodeMultiple.js": {
"bytes": 5605,
"imports": [
{
"path": "src/body/buildParts.js"
},
{
"path": "src/body/decodePose.js"
},
{
"path": "src/body/vectors.js"
}
]
},
"src/body/decodePose.js": {
"bytes": 4540,
"imports": [
{
"path": "src/body/keypoints.js"
},
{
"path": "src/body/vectors.js"
}
]
},
"src/body/heapSort.js": {
"bytes": 1590,
"imports": []
},
"src/body/keypoints.js": {
"bytes": 2291,
"imports": []
},
"src/body/modelBase.js": {
"bytes": 874,
"imports": [
{
"path": "src/tf.js"
}
]
},
"src/body/modelMobileNet.js": {
"bytes": 584,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/body/modelBase.js"
}
]
},
"src/body/modelPoseNet.js": {
"bytes": 1922,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/body/modelMobileNet.js"
},
{
"path": "src/body/decodeMultiple.js"
},
{
"path": "src/body/util.js"
}
]
},
"src/body/posenet.js": {
"bytes": 830,
"imports": [
{
"path": "src/body/modelMobileNet.js"
},
{
"path": "src/body/modelPoseNet.js"
},
{
"path": "src/body/decodeMultiple.js"
},
{
"path": "src/body/keypoints.js"
},
{
"path": "src/body/util.js"
}
]
},
"src/body/util.js": {
"bytes": 2262,
"imports": [
{
"path": "src/body/keypoints.js"
}
]
},
"src/body/vectors.js": {
"bytes": 1273,
"imports": [
{
"path": "src/body/keypoints.js"
}
]
},
"src/embedding/embedding.js": {
"bytes": 2105,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/profile.js"
}
]
},
"src/emotion/emotion.js": {
"bytes": 3004,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/profile.js"
}
]
},
"src/face/blazeface.js": {
"bytes": 6941,
"imports": [
{
"path": "src/tf.js"
}
]
},
"src/face/box.js": {
"bytes": 1920,
"imports": [
{
"path": "src/tf.js"
}
]
},
"src/face/coords.js": {
"bytes": 37909,
"imports": []
},
"src/face/facemesh.js": {
"bytes": 2471,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/face/blazeface.js"
},
{
"path": "src/face/facepipeline.js"
},
{
"path": "src/face/coords.js"
}
]
},
"src/face/facepipeline.js": {
"bytes": 13788,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/face/box.js"
},
{
"path": "src/face/util.js"
},
{
"path": "src/face/coords.js"
}
]
},
"src/face/util.js": {
"bytes": 3078,
"imports": []
},
"src/gender/gender.js": {
"bytes": 3407,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/profile.js"
}
]
},
"src/gesture.js": {
"bytes": 3306,
"imports": []
},
"src/hand/anchors.js": {
"bytes": 224151,
"imports": []
},
"src/hand/box.js": {
"bytes": 3211,
"imports": [
{
"path": "src/tf.js"
}
]
},
"src/hand/handdetector.js": {
"bytes": 4221,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/hand/box.js"
}
]
},
"src/hand/handpipeline.js": {
"bytes": 7558,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/hand/box.js"
},
{
"path": "src/hand/util.js"
}
]
},
"src/hand/handpose.js": {
"bytes": 3026,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/hand/handdetector.js"
},
{
"path": "src/hand/handpipeline.js"
},
{
"path": "src/hand/anchors.js"
}
]
},
"src/hand/util.js": {
"bytes": 3030,
"imports": []
},
"src/human.js": {
"bytes": 15693,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/face/facemesh.js"
},
{
"path": "src/age/age.js"
},
{
"path": "src/gender/gender.js"
},
{
"path": "src/emotion/emotion.js"
},
{
"path": "src/embedding/embedding.js"
},
{
"path": "src/body/posenet.js"
},
{
"path": "src/hand/handpose.js"
},
{
"path": "src/gesture.js"
},
{
"path": "src/image.js"
},
{
"path": "src/profile.js"
},
{
"path": "config.js"
},
{
"path": "package.json"
}
]
},
"src/image.js": {
"bytes": 5688,
"imports": [
{
"path": "src/tf.js"
},
{
"path": "src/imagefx.js"
}
]
},
"src/imagefx.js": {
"bytes": 19352,
"imports": []
},
"src/profile.js": {
"bytes": 1061,
"imports": []
},
"src/tf.js": {
"bytes": 1178,
"imports": []
}
},
"outputs": {
"dist/human.node-nobundle.js.map": {
"imports": [],
"inputs": {},
"bytes": 686879
},
"dist/human.node-nobundle.js": {
"imports": [],
"exports": [],
"inputs": {
"src/face/blazeface.js": {
"bytesInOutput": 5449
},
"src/face/box.js": {
"bytesInOutput": 1673
},
"src/face/util.js": {
"bytesInOutput": 2491
},
"src/face/coords.js": {
"bytesInOutput": 30889
},
"src/face/facepipeline.js": {
"bytesInOutput": 9781
},
"src/face/facemesh.js": {
"bytesInOutput": 1942
},
"src/profile.js": {
"bytesInOutput": 897
},
"src/age/age.js": {
"bytesInOutput": 1212
},
"src/gender/gender.js": {
"bytesInOutput": 2032
},
"src/emotion/emotion.js": {
"bytesInOutput": 1884
},
"src/embedding/embedding.js": {
"bytesInOutput": 1407
},
"src/body/modelBase.js": {
"bytesInOutput": 642
},
"src/body/modelMobileNet.js": {
"bytesInOutput": 389
},
"src/body/heapSort.js": {
"bytesInOutput": 1147
},
"src/body/buildParts.js": {
"bytesInOutput": 1355
},
"src/body/keypoints.js": {
"bytesInOutput": 1833
},
"src/body/vectors.js": {
"bytesInOutput": 1087
},
"src/body/decodePose.js": {
"bytesInOutput": 3231
},
"src/body/decodeMultiple.js": {
"bytesInOutput": 1734
},
"src/body/util.js": {
"bytesInOutput": 1963
},
"src/body/modelPoseNet.js": {
"bytesInOutput": 1671
},
"src/body/posenet.js": {
"bytesInOutput": 877
},
"src/hand/handdetector.js": {
"bytesInOutput": 2931
},
"src/hand/handpipeline.js": {
"bytesInOutput": 4887
},
"src/hand/anchors.js": {
"bytesInOutput": 127039
},
"src/hand/handpose.js": {
"bytesInOutput": 1828
},
"src/gesture.js": {
"bytesInOutput": 2332
},
"src/imagefx.js": {
"bytesInOutput": 13874
},
"src/image.js": {
"bytesInOutput": 4063
},
"src/human.js": {
"bytesInOutput": 10626
},
"src/tf.js": {
"bytesInOutput": 184
},
"src/hand/box.js": {
"bytesInOutput": 1979
},
"src/hand/util.js": {
"bytesInOutput": 1854
},
"config.js": {
"bytesInOutput": 1431
},
"package.json": {
"bytesInOutput": 20
}
},
"bytes": 250498
}
}
}

File diff suppressed because one or more lines are too long

1473
dist/human.node.json vendored

File diff suppressed because it is too large Load Diff

20
package-lock.json generated
View File

@ -821,9 +821,9 @@
}
},
"esbuild": {
"version": "0.8.6",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.8.6.tgz",
"integrity": "sha512-JBN3gYqc6j/fX2s2zjwGoVbHGODFOIpzbRCSI9OM3rkvYuALqB91EUjoBW6uuwmiURPgH5IksJNN6ndTY778sw==",
"version": "0.8.8",
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.8.8.tgz",
"integrity": "sha512-1Wo7L5Y6FpUUalF2APCh9cJi+IZ60jU9IBpTZSXA7jj3HItpAxPTmeIqGsaRW66rjg8SU6rvLnvQpgWqkCkCeA==",
"dev": true
},
"escalade": {
@ -1398,9 +1398,9 @@
}
},
"google-protobuf": {
"version": "3.13.0",
"resolved": "https://registry.npmjs.org/google-protobuf/-/google-protobuf-3.13.0.tgz",
"integrity": "sha512-ZIf3qfLFayVrPvAjeKKxO5FRF1/NwRxt6Dko+fWEMuHwHbZx8/fcaAao9b0wCM6kr8qeg2te8XTpyuvKuD9aKw==",
"version": "3.14.0",
"resolved": "https://registry.npmjs.org/google-protobuf/-/google-protobuf-3.14.0.tgz",
"integrity": "sha512-bwa8dBuMpOxg7COyqkW6muQuvNnWgVN8TX/epDRGW5m0jcrmq2QJyCyiV8ZE2/6LaIIqJtiv9bYokFhfpy/o6w==",
"dev": true
},
"graceful-fs": {
@ -2751,9 +2751,9 @@
"dev": true
},
"yargs": {
"version": "16.1.0",
"resolved": "https://registry.npmjs.org/yargs/-/yargs-16.1.0.tgz",
"integrity": "sha512-upWFJOmDdHN0syLuESuvXDmrRcWd1QafJolHskzaw79uZa7/x53gxQKiR07W59GWY1tFhhU/Th9DrtSfpS782g==",
"version": "16.1.1",
"resolved": "https://registry.npmjs.org/yargs/-/yargs-16.1.1.tgz",
"integrity": "sha512-hAD1RcFP/wfgfxgMVswPE+z3tlPFtxG8/yWUrG2i17sTWGCGqWnxKcLTF4cUKDUK8fzokwsmO9H0TDkRbMHy8w==",
"dev": true,
"requires": {
"cliui": "^7.0.2",
@ -2761,7 +2761,7 @@
"get-caller-file": "^2.0.5",
"require-directory": "^2.1.1",
"string-width": "^4.2.0",
"y18n": "^5.0.2",
"y18n": "^5.0.5",
"yargs-parser": "^20.2.2"
}
},

View File

@ -28,7 +28,7 @@
"@vladmandic/pilogger": "^0.2.7",
"chokidar": "^3.4.3",
"dayjs": "^1.9.6",
"esbuild": "^0.8.6",
"esbuild": "^0.8.8",
"eslint": "^7.13.0",
"eslint-config-airbnb-base": "^14.2.1",
"eslint-plugin-import": "^2.22.1",
@ -42,15 +42,8 @@
"scripts": {
"start": "node --trace-warnings --unhandled-rejections=strict --trace-uncaught --no-deprecation src/node.js",
"lint": "eslint src/*.js demo/*.js",
"dev": "npm install && node --trace-warnings --unhandled-rejections=strict --trace-uncaught --no-deprecation dev-server/dev-server.js",
"changelog": "node dev-server/changelog.js",
"build-iife": "esbuild --bundle --minify-whitespace --platform=browser --sourcemap --target=es2018 --format=iife --external:fs --external:buffer --external:util --global-name=Human --metafile=dist/human.json --outfile=dist/human.js src/human.js",
"build-esm-bundle": "esbuild --bundle --minify-whitespace --platform=browser --sourcemap --target=es2018 --format=esm --external:fs --external:buffer --external:util --metafile=dist/human.esm.json --outfile=dist/human.esm.js src/human.js",
"build-esm-nobundle": "esbuild --bundle --minify-whitespace --platform=browser --sourcemap --target=es2018 --format=esm --external:@tensorflow --external:fs --external:buffer --external:util --metafile=dist/human.esm-nobundle.json --outfile=dist/human.esm-nobundle.js src/human.js",
"build-node-bundle": "esbuild --bundle --minify-whitespace --platform=node --sourcemap --target=es2018 --format=cjs --metafile=dist/human.node.json --outfile=dist/human.node.js src/human.js",
"build-node-nobundle": "esbuild --bundle --minify-whitespace --platform=node --sourcemap --target=es2018 --format=cjs --external:@tensorflow --metafile=dist/human.node.json --outfile=dist/human.node-nobundle.js src/human.js",
"build-demo": "esbuild --bundle --minify-whitespace --log-level=error --platform=browser --sourcemap --target=es2018 --format=esm --external:fs --external:buffer --external:util --metafile=dist/demo-browser-index.json --outfile=dist/demo-browser-index.js demo/browser.js",
"build": "rimraf dist/* && npm run build-iife && npm run build-esm-bundle && npm run build-esm-nobundle && npm run build-node-bundle && npm run build-node-nobundle && npm run build-demo && npm run changelog",
"dev": "npm install && node server/dev.js",
"build": "npm install && rimraf dist/* && node server/build.js && node server/changelog.js",
"update": "npm update --depth 20 --force && npm dedupe && npm prune && npm audit"
},
"keywords": [

94
server/build.js Executable file
View File

@ -0,0 +1,94 @@
#!/usr/bin/env -S node --trace-warnings
const esbuild = require('esbuild');
const log = require('@vladmandic/pilogger');
// keeps esbuild service instance cached
let es;
// common configuration
const common = {
minifyWhitespace: true,
bundle: true,
sourcemap: true,
logLevel: 'error',
target: 'es2018',
};
// all build targets
const config = {
iifeBundle: {
platform: 'browser',
format: 'iife',
globalName: 'Human',
metafile: 'dist/human.json',
entryPoints: ['src/human.js'],
outfile: 'dist/human.js',
external: ['fs', 'buffer', 'util'],
},
esmBundle: {
platform: 'browser',
format: 'esm',
metafile: 'dist/human.esm.json',
entryPoints: ['src/human.js'],
outfile: 'dist/human.esm.js',
external: ['fs', 'buffer', 'util'],
},
esmNoBundle: {
platform: 'browser',
format: 'esm',
metafile: 'dist/human.esm-nobundle.json',
entryPoints: ['src/human.js'],
outfile: 'dist/human.esm-nobundle.js',
external: ['fs', 'buffer', 'util', '@tensorflow'],
},
nodeBundle: {
platform: 'node',
format: 'cjs',
metafile: 'dist/human.node.json',
entryPoints: ['src/human.js'],
outfile: 'dist/human.node.js',
},
nodeNoBundle: {
platform: 'node',
format: 'cjs',
metafile: 'dist/human.node-nobundle.json',
entryPoints: ['src/human.js'],
outfile: 'dist/human.node-nobundle.js',
external: ['@tensorflow'],
},
demo: {
platform: 'browser',
format: 'esm',
metafile: 'dist/demo-browser-index.json',
entryPoints: ['demo/browser.js'],
outfile: 'dist/demo-browser-index.js',
external: ['fs', 'buffer', 'util'],
},
};
// rebuild on file change
async function build(f, msg) {
log.info('Build: file', msg, f);
if (!es) es = await esbuild.startService();
// common build options
try {
// rebuild all targets
for (const [target, options] of Object.entries(config)) {
await es.build({ ...common, ...options });
log.state('Build complete:', target);
}
if (!module.parent) process.exit(0);
} catch (err) {
// catch errors and print where it occured
log.error('Build error', JSON.stringify(err.errors || err, null, 2));
if (!module.parent) process.exit(1);
}
}
if (!module.parent) {
log.header();
build('all', 'startup');
} else {
exports.build = build;
}

View File

@ -15,17 +15,17 @@ const zlib = require('zlib');
const http2 = require('http2');
const path = require('path');
const chokidar = require('chokidar');
const esbuild = require('esbuild');
const log = require('@vladmandic/pilogger');
const build = require('./build.js');
// app configuration
// you can provide your server key and certificate or use provided self-signed ones
// self-signed certificate generated using:
// openssl req -x509 -newkey rsa:4096 -nodes -keyout dev-server.key -out dev-server.crt -days 365 -subj "/C=US/ST=Florida/L=Miami/O=@vladmandic"
// openssl req -x509 -newkey rsa:4096 -nodes -keyout https.key -out https.crt -days 365 -subj "/C=US/ST=Florida/L=Miami/O=@vladmandic"
// client app does not work without secure server since browsers enforce https for webcam access
const options = {
key: fs.readFileSync('dev-server/dev-server.key'),
cert: fs.readFileSync('dev-server/dev-server.crt'),
key: fs.readFileSync('server/https.key'),
cert: fs.readFileSync('server/https.crt'),
root: '..',
default: 'demo/index.html',
port: 8000,
@ -50,46 +50,6 @@ const mime = {
'.wasm': 'application/wasm',
};
// keeps esbuild service instance cached
let es;
// rebuild on file change
async function build(f, msg) {
log.info('Monitor: file', msg, f);
if (!es) es = await esbuild.startService();
// common build options
const cfg = {
// minify: true,
minifyWhitespace: true,
bundle: true,
sourcemap: true,
logLevel: 'error',
platform: 'browser',
target: 'es2018',
format: 'esm',
external: ['fs', 'buffer', 'util'],
};
// only rebuilding esm module and demo application
// for full production build use "npm run build"
try {
// rebuild library fist
cfg.entryPoints = ['src/human.js'];
cfg.outfile = 'dist/human.esm.js';
cfg.metafile = 'dist/human.esm.json';
await es.build(cfg);
// then rebuild client app so it can use freshly rebuild library
cfg.entryPoints = ['demo/browser.js'];
cfg.outfile = 'dist/demo-browser-index.js';
cfg.metafile = 'dist/demo-browser-index.json';
await es.build(cfg);
// done
log.state('Build complete');
} catch (err) {
// catch errors and print where it occured
log.error('Build error', JSON.stringify(err.errors || err, null, 2));
}
}
// watch filesystem for any changes and notify build when needed
async function watch() {
const watcher = chokidar.watch(options.monitor, {
@ -104,9 +64,9 @@ async function watch() {
});
// single event handler for file add/change/delete
watcher
.on('add', (evt) => build(evt, 'add'))
.on('change', (evt) => build(evt, 'modify'))
.on('unlink', (evt) => build(evt, 'remove'))
.on('add', (evt) => build.build(evt, 'add'))
.on('change', (evt) => build.build(evt, 'modify'))
.on('unlink', (evt) => build.build(evt, 'remove'))
.on('error', (err) => log.error(`Client watcher error: ${err}`))
.on('ready', () => log.state('Monitoring:', options.monitor));
}
@ -171,7 +131,7 @@ async function main() {
const server = http2.createSecureServer(options, httpRequest);
server.on('listening', () => log.state('HTTP2 server listening:', options.port));
server.listen(options.port);
await build('all', 'startup');
await build.build('all', 'startup');
}
main();

2
wiki

@ -1 +1 @@
Subproject commit 9d84cc749cd93244b811fbbf4378dd6f443e3abc
Subproject commit 86775430d497ec4c35f3703267cd273d16498179