mirror of https://github.com/vladmandic/human
fix types typo
parent
15fa4eaa1a
commit
bd269021f2
|
@ -9,8 +9,9 @@
|
|||
|
||||
## Changelog
|
||||
|
||||
### **HEAD -> main** 2022/02/10 mandic00@live.com
|
||||
### **HEAD -> main** 2022/02/14 mandic00@live.com
|
||||
|
||||
- add config option wasmplatformfetch
|
||||
|
||||
### **2.6.3** 2022/02/10 mandic00@live.com
|
||||
|
||||
|
|
|
@ -65,16 +65,16 @@
|
|||
"@tensorflow/tfjs-layers": "^3.13.0",
|
||||
"@tensorflow/tfjs-node": "^3.13.0",
|
||||
"@tensorflow/tfjs-node-gpu": "^3.13.0",
|
||||
"@types/node": "^17.0.17",
|
||||
"@types/node": "^17.0.18",
|
||||
"@types/offscreencanvas": "^2019.6.4",
|
||||
"@typescript-eslint/eslint-plugin": "^5.11.0",
|
||||
"@typescript-eslint/parser": "^5.11.0",
|
||||
"@typescript-eslint/eslint-plugin": "^5.12.0",
|
||||
"@typescript-eslint/parser": "^5.12.0",
|
||||
"@vladmandic/build": "^0.7.0",
|
||||
"@vladmandic/pilogger": "^0.4.2",
|
||||
"@vladmandic/tfjs": "github:vladmandic/tfjs",
|
||||
"canvas": "^2.9.0",
|
||||
"dayjs": "^1.10.7",
|
||||
"esbuild": "^0.14.21",
|
||||
"esbuild": "^0.14.22",
|
||||
"eslint": "8.9.0",
|
||||
"eslint-config-airbnb-base": "^15.0.0",
|
||||
"eslint-plugin-html": "^6.2.0",
|
||||
|
|
|
@ -225,7 +225,7 @@ export interface Config {
|
|||
*
|
||||
* default: auto-detects to link to CDN `jsdelivr` when running in browser
|
||||
*/
|
||||
wasmPlatformFetch: false,
|
||||
wasmPlatformFetch: boolean,
|
||||
|
||||
/** Print debug statements to console
|
||||
*
|
||||
|
|
|
@ -21,7 +21,7 @@ const calculateGaze = (face: FaceResult): { bearing: number, strength: number }
|
|||
(eyeCenter[0] - irisCenter[0]) / eyeSize[0] - offsetIris[0],
|
||||
eyeRatio * (irisCenter[1] - eyeCenter[1]) / eyeSize[1] - offsetIris[1],
|
||||
];
|
||||
let strength = Math.sqrt((eyeDiff[0] ** 2) + (eyeDiff[1] ** 2)); // vector length is a diagonal between two differences
|
||||
let strength = Math.sqrt((eyeDiff[0] * eyeDiff[0]) + (eyeDiff[1] * eyeDiff[1])); // vector length is a diagonal between two differences
|
||||
strength = Math.min(strength, face.boxRaw[2] / 2, face.boxRaw[3] / 2); // limit strength to half of box size to avoid clipping due to low precision
|
||||
const bearing = (radians([0, 0], eyeDiff) + (Math.PI / 2)) % Math.PI; // using eyeDiff instead eyeCenter/irisCenter combo due to manual adjustments and rotate clockwise 90degrees
|
||||
return { bearing, strength };
|
||||
|
|
|
@ -1,24 +1,24 @@
|
|||
2022-02-14 07:52:23 [36mINFO: [39m Application: {"name":"@vladmandic/human","version":"2.6.3"}
|
||||
2022-02-14 07:52:23 [36mINFO: [39m Environment: {"profile":"production","config":".build.json","package":"package.json","tsconfig":true,"eslintrc":true,"git":true}
|
||||
2022-02-14 07:52:23 [36mINFO: [39m Toolchain: {"build":"0.7.0","esbuild":"0.14.21","typescript":"4.5.5","typedoc":"0.22.11","eslint":"8.9.0"}
|
||||
2022-02-14 07:52:23 [36mINFO: [39m Build: {"profile":"production","steps":["clean","compile","typings","typedoc","lint","changelog"]}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Clean: {"locations":["dist/*","types/lib/*","typedoc/*"]}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"tfjs/nodejs/cpu","format":"cjs","platform":"node","input":"tfjs/tf-node.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":102,"outputBytes":644}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"human/nodejs/cpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node.js","files":64,"inputBytes":562626,"outputBytes":293604}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"tfjs/nodejs/gpu","format":"cjs","platform":"node","input":"tfjs/tf-node-gpu.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":110,"outputBytes":648}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"human/nodejs/gpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-gpu.js","files":64,"inputBytes":562630,"outputBytes":293608}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"tfjs/nodejs/wasm","format":"cjs","platform":"node","input":"tfjs/tf-node-wasm.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":149,"outputBytes":685}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"human/nodejs/wasm","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-wasm.js","files":64,"inputBytes":562667,"outputBytes":293647}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"tfjs/browser/version","format":"esm","platform":"browser","input":"tfjs/tf-version.ts","output":"dist/tfjs.version.js","files":1,"inputBytes":1063,"outputBytes":394}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"tfjs/browser/esm/nobundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":1068,"outputBytes":615}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"human/browser/esm/nobundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm-nobundle.js","files":64,"inputBytes":562597,"outputBytes":292357}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"tfjs/browser/esm/custom","format":"esm","platform":"browser","input":"tfjs/tf-custom.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":110,"outputBytes":1337647}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"human/browser/iife/bundle","format":"iife","platform":"browser","input":"src/human.ts","output":"dist/human.js","files":64,"inputBytes":1899629,"outputBytes":1629209}
|
||||
2022-02-14 07:52:23 [35mSTATE:[39m Compile: {"name":"human/browser/esm/bundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm.js","files":64,"inputBytes":1899629,"outputBytes":2106801}
|
||||
2022-02-14 07:52:27 [35mSTATE:[39m Typings: {"input":"src/human.ts","output":"types/lib","files":112}
|
||||
2022-02-14 07:52:29 [35mSTATE:[39m TypeDoc: {"input":"src/human.ts","output":"typedoc","objects":69,"generated":true}
|
||||
2022-02-14 07:52:29 [35mSTATE:[39m Compile: {"name":"demo/typescript","format":"esm","platform":"browser","input":"demo/typescript/index.ts","output":"demo/typescript/index.js","files":1,"inputBytes":5863,"outputBytes":2915}
|
||||
2022-02-14 07:52:29 [35mSTATE:[39m Compile: {"name":"demo/faceid","format":"esm","platform":"browser","input":"demo/faceid/index.ts","output":"demo/faceid/index.js","files":2,"inputBytes":15174,"outputBytes":7820}
|
||||
2022-02-14 07:52:36 [35mSTATE:[39m Lint: {"locations":["*.json","src/**/*.ts","test/**/*.js","demo/**/*.js"],"files":95,"errors":0,"warnings":0}
|
||||
2022-02-14 07:52:36 [35mSTATE:[39m ChangeLog: {"repository":"https://github.com/vladmandic/human","branch":"main","output":"CHANGELOG.md"}
|
||||
2022-02-14 07:52:36 [36mINFO: [39m Done...
|
||||
2022-02-17 08:14:40 [36mINFO: [39m Application: {"name":"@vladmandic/human","version":"2.6.3"}
|
||||
2022-02-17 08:14:40 [36mINFO: [39m Environment: {"profile":"production","config":".build.json","package":"package.json","tsconfig":true,"eslintrc":true,"git":true}
|
||||
2022-02-17 08:14:40 [36mINFO: [39m Toolchain: {"build":"0.7.0","esbuild":"0.14.22","typescript":"4.5.5","typedoc":"0.22.11","eslint":"8.9.0"}
|
||||
2022-02-17 08:14:40 [36mINFO: [39m Build: {"profile":"production","steps":["clean","compile","typings","typedoc","lint","changelog"]}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Clean: {"locations":["dist/*","types/lib/*","typedoc/*"]}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"tfjs/nodejs/cpu","format":"cjs","platform":"node","input":"tfjs/tf-node.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":102,"outputBytes":644}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"human/nodejs/cpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node.js","files":64,"inputBytes":562644,"outputBytes":293608}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"tfjs/nodejs/gpu","format":"cjs","platform":"node","input":"tfjs/tf-node-gpu.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":110,"outputBytes":648}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"human/nodejs/gpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-gpu.js","files":64,"inputBytes":562648,"outputBytes":293612}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"tfjs/nodejs/wasm","format":"cjs","platform":"node","input":"tfjs/tf-node-wasm.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":149,"outputBytes":685}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"human/nodejs/wasm","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-wasm.js","files":64,"inputBytes":562685,"outputBytes":293651}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"tfjs/browser/version","format":"esm","platform":"browser","input":"tfjs/tf-version.ts","output":"dist/tfjs.version.js","files":1,"inputBytes":1063,"outputBytes":394}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"tfjs/browser/esm/nobundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":1068,"outputBytes":615}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"human/browser/esm/nobundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm-nobundle.js","files":64,"inputBytes":562615,"outputBytes":292361}
|
||||
2022-02-17 08:14:40 [35mSTATE:[39m Compile: {"name":"tfjs/browser/esm/custom","format":"esm","platform":"browser","input":"tfjs/tf-custom.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":110,"outputBytes":1334770}
|
||||
2022-02-17 08:14:41 [35mSTATE:[39m Compile: {"name":"human/browser/iife/bundle","format":"iife","platform":"browser","input":"src/human.ts","output":"dist/human.js","files":64,"inputBytes":1896770,"outputBytes":1626294}
|
||||
2022-02-17 08:14:41 [35mSTATE:[39m Compile: {"name":"human/browser/esm/bundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm.js","files":64,"inputBytes":1896770,"outputBytes":2101597}
|
||||
2022-02-17 08:14:46 [35mSTATE:[39m Typings: {"input":"src/human.ts","output":"types/lib","files":112}
|
||||
2022-02-17 08:14:48 [35mSTATE:[39m TypeDoc: {"input":"src/human.ts","output":"typedoc","objects":69,"generated":true}
|
||||
2022-02-17 08:14:48 [35mSTATE:[39m Compile: {"name":"demo/typescript","format":"esm","platform":"browser","input":"demo/typescript/index.ts","output":"demo/typescript/index.js","files":1,"inputBytes":5863,"outputBytes":2915}
|
||||
2022-02-17 08:14:48 [35mSTATE:[39m Compile: {"name":"demo/faceid","format":"esm","platform":"browser","input":"demo/faceid/index.ts","output":"demo/faceid/index.js","files":2,"inputBytes":15174,"outputBytes":7820}
|
||||
2022-02-17 08:14:55 [35mSTATE:[39m Lint: {"locations":["*.json","src/**/*.ts","test/**/*.js","demo/**/*.js"],"files":95,"errors":0,"warnings":0}
|
||||
2022-02-17 08:14:56 [35mSTATE:[39m ChangeLog: {"repository":"https://github.com/vladmandic/human","branch":"main","output":"CHANGELOG.md"}
|
||||
2022-02-17 08:14:56 [36mINFO: [39m Done...
|
||||
|
|
1368
test/test.log
1368
test/test.log
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue