diff --git a/CHANGELOG.md b/CHANGELOG.md index e6ef1bbd..5ef16290 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,7 +9,7 @@ ## Changelog -### **HEAD -> main** 2022/08/21 mandic00@live.com +### **HEAD -> main** 2022/08/24 mandic00@live.com - expand type safety - full eslint rule rewrite diff --git a/demo/faceid/index.js b/demo/faceid/index.js index b9807b6b..35441db1 100644 --- a/demo/faceid/index.js +++ b/demo/faceid/index.js @@ -4,6 +4,6 @@ author: ' */ -import*as B from"../../dist/human.esm.js";var l,R="human",g="person",p=(...t)=>console.log("indexdb",...t);async function v(){return l?!0:new Promise(t=>{let a=indexedDB.open(R,1);a.onerror=s=>p("error:",s),a.onupgradeneeded=s=>{p("create:",s.target),l=s.target.result,l.createObjectStore(g,{keyPath:"id",autoIncrement:!0})},a.onsuccess=s=>{l=s.target.result,p("open:",l),t(!0)}})}async function x(){let t=[];return l||await v(),new Promise(a=>{let s=l.transaction([g],"readwrite").objectStore(g).openCursor(null,"next");s.onerror=i=>p("load error:",i),s.onsuccess=i=>{i.target.result?(t.push(i.target.result.value),i.target.result.continue()):a(t)}})}async function y(){return l||await v(),new Promise(t=>{let a=l.transaction([g],"readwrite").objectStore(g).count();a.onerror=s=>p("count error:",s),a.onsuccess=()=>t(a.result)})}async function C(t){l||await v();let a={name:t.name,descriptor:t.descriptor,image:t.image};l.transaction([g],"readwrite").objectStore(g).put(a),p("save:",a)}async function D(t){l||await v(),l.transaction([g],"readwrite").objectStore(g).delete(t.id),p("delete:",t)}var b={modelBasePath:"../../models",filter:{equalization:!0},face:{enabled:!0,detector:{rotation:!0,return:!0,cropFactor:1.6,mask:!1},description:{enabled:!0},iris:{enabled:!0},emotion:{enabled:!1},antispoof:{enabled:!0},liveness:{enabled:!0}},body:{enabled:!1},hand:{enabled:!1},object:{enabled:!1},gesture:{enabled:!0}},E={order:2,multiplier:25,min:.2,max:.8},c={minConfidence:.6,minSize:224,maxTime:1e4,blinkMin:10,blinkMax:800,threshold:.5,mask:b.face.detector.mask,rotation:b.face.detector.rotation,cropFactor:b.face.detector.cropFactor,...E},o={faceCount:!1,faceConfidence:!1,facingCenter:!1,lookingCenter:!1,blinkDetected:!1,faceSize:!1,antispoofCheck:!1,livenessCheck:!1,elapsedMs:0},I=()=>o.faceCount&&o.faceSize&&o.blinkDetected&&o.facingCenter&&o.lookingCenter&&o.faceConfidence&&o.antispoofCheck&&o.livenessCheck,r={face:null,record:null},u={start:0,end:0,time:0},n=new B.Human(b);n.env.perfadd=!1;n.draw.options.font='small-caps 18px "Lato"';n.draw.options.lineHeight=20;var e={video:document.getElementById("video"),canvas:document.getElementById("canvas"),log:document.getElementById("log"),fps:document.getElementById("fps"),match:document.getElementById("match"),name:document.getElementById("name"),save:document.getElementById("save"),delete:document.getElementById("delete"),retry:document.getElementById("retry"),source:document.getElementById("source"),ok:document.getElementById("ok")},w={detect:0,draw:0},h={detect:0,draw:0},S=0,f=(...t)=>{e.log.innerText+=t.join(" ")+` -`,console.log(...t)},k=t=>e.fps.innerText=t;async function H(){k("starting webcam...");let t={audio:!1,video:{facingMode:"user",resizeMode:"none",width:{ideal:document.body.clientWidth}}},a=await navigator.mediaDevices.getUserMedia(t),s=new Promise(i=>{e.video.onloadeddata=()=>i(!0)});e.video.srcObject=a,e.video.play(),await s,e.canvas.width=e.video.videoWidth,e.canvas.height=e.video.videoHeight,n.env.initial&&f("video:",e.video.videoWidth,e.video.videoHeight,"|",a.getVideoTracks()[0].label),e.canvas.onclick=()=>{e.video.paused?e.video.play():e.video.pause()}}async function T(){var t;if(!e.video.paused){(t=r.face)!=null&&t.tensor&&n.tf.dispose(r.face.tensor),await n.detect(e.video);let a=n.now();h.detect=1e3/(a-w.detect),w.detect=a,requestAnimationFrame(T)}}async function L(){let t=n.next(n.result);n.draw.canvas(e.video,e.canvas),await n.draw.all(e.canvas,t);let a=n.now();if(h.draw=1e3/(a-w.draw),w.draw=a,k(`fps: ${h.detect.toFixed(1).padStart(5," ")} detect | ${h.draw.toFixed(1).padStart(5," ")} draw`),o.faceCount=n.result.face.length===1,o.faceCount){let i=Object.values(n.result.gesture).map(m=>m.gesture);(i.includes("blink left eye")||i.includes("blink right eye"))&&(u.start=n.now()),u.start>0&&!i.includes("blink left eye")&&!i.includes("blink right eye")&&(u.end=n.now()),o.blinkDetected=o.blinkDetected||Math.abs(u.end-u.start)>c.blinkMin&&Math.abs(u.end-u.start)c.minConfidence&&(n.result.face[0].faceScore||0)>c.minConfidence,o.antispoofCheck=(n.result.face[0].real||0)>c.minConfidence,o.livenessCheck=(n.result.face[0].live||0)>c.minConfidence,o.faceSize=n.result.face[0].box[2]>=c.minSize&&n.result.face[0].box[3]>=c.minSize}let s=32;for(let[i,m]of Object.entries(o)){let d=document.getElementById(`ok-${i}`);d||(d=document.createElement("div"),d.innerText=i,d.className="ok",d.style.top=`${s}px`,e.ok.appendChild(d)),typeof m=="boolean"?d.style.backgroundColor=m?"lightgreen":"lightcoral":d.innerText=`${i}:${m}`,s+=28}return I()||o.elapsedMs>c.maxTime?(e.video.pause(),n.result.face[0]):(o.elapsedMs=Math.trunc(n.now()-S),new Promise(i=>{setTimeout(async()=>{await L(),i(n.result.face[0])},30)}))}async function z(){var t,a,s,i;if(e.name.value.length>0){let m=(t=e.canvas.getContext("2d"))==null?void 0:t.getImageData(0,0,e.canvas.width,e.canvas.height),d={id:0,name:e.name.value,descriptor:(a=r.face)==null?void 0:a.embedding,image:m};await C(d),f("saved face record:",d.name,"descriptor length:",(i=(s=r.face)==null?void 0:s.embedding)==null?void 0:i.length),f("known face records:",await y())}else f("invalid name")}async function P(){r.record&&r.record.id>0&&await D(r.record)}async function j(){var i,m;if((i=e.canvas.getContext("2d"))==null||i.clearRect(0,0,c.minSize,c.minSize),!r.face||!r.face.tensor||!r.face.embedding)return!1;if(console.log("face record:",r.face),n.tf.browser.toPixels(r.face.tensor,e.canvas),await y()===0)return f("face database is empty"),document.body.style.background="black",e.delete.style.display="none",!1;let t=await x(),a=t.map(d=>d.descriptor).filter(d=>d.length>0),s=n.match(r.face.embedding,a,E);return r.record=t[s.index]||null,r.record&&(f(`best match: ${r.record.name} | id: ${r.record.id} | similarity: ${Math.round(1e3*s.similarity)/10}%`),e.name.value=r.record.name,e.source.style.display="",(m=e.source.getContext("2d"))==null||m.putImageData(r.record.image,0,0)),document.body.style.background=s.similarity>c.threshold?"darkgreen":"maroon",s.similarity>c.threshold}async function M(){var t,a;return o.faceCount=!1,o.faceConfidence=!1,o.facingCenter=!1,o.blinkDetected=!1,o.faceSize=!1,o.antispoofCheck=!1,o.livenessCheck=!1,o.elapsedMs=0,e.match.style.display="none",e.retry.style.display="none",e.source.style.display="none",document.body.style.background="black",await H(),await T(),S=n.now(),r.face=await L(),e.canvas.width=((t=r.face.tensor)==null?void 0:t.shape[1])||c.minSize,e.canvas.height=((a=r.face.tensor)==null?void 0:a.shape[0])||c.minSize,e.source.width=e.canvas.width,e.source.height=e.canvas.height,e.canvas.style.width="",e.match.style.display="flex",e.save.style.display="flex",e.delete.style.display="flex",e.retry.style.display="block",I()?j():(f("did not find valid face"),!1)}async function q(){var t,a;f("human version:",n.version,"| tfjs version:",n.tf.version["tfjs-core"]),f("face embedding model:",b.face.description.enabled?"faceres":"",(t=b.face.mobilefacenet)!=null&&t.enabled?"mobilefacenet":"",(a=b.face.insightface)!=null&&a.enabled?"insightface":""),f("options:",JSON.stringify(c).replace(/{|}|"|\[|\]/g,"").replace(/,/g," ")),k("loading..."),f("known face records:",await y()),await H(),await n.load(),k("initializing..."),e.retry.addEventListener("click",M),e.save.addEventListener("click",z),e.delete.addEventListener("click",P),await n.warmup(),await M()}window.onload=q; +import*as I from"../../dist/human.esm.js";var l,z="human",g="person",p=(...t)=>console.log("indexdb",...t);async function v(){return l?!0:new Promise(t=>{let n=indexedDB.open(z,1);n.onerror=r=>p("error:",r),n.onupgradeneeded=r=>{p("create:",r.target),l=r.target.result,l.createObjectStore(g,{keyPath:"id",autoIncrement:!0})},n.onsuccess=r=>{l=r.target.result,p("open:",l),t(!0)}})}async function D(){let t=[];return l||await v(),new Promise(n=>{let r=l.transaction([g],"readwrite").objectStore(g).openCursor(null,"next");r.onerror=i=>p("load error:",i),r.onsuccess=i=>{i.target.result?(t.push(i.target.result.value),i.target.result.continue()):n(t)}})}async function y(){return l||await v(),new Promise(t=>{let n=l.transaction([g],"readwrite").objectStore(g).count();n.onerror=r=>p("count error:",r),n.onsuccess=()=>t(n.result)})}async function M(t){l||await v();let n={name:t.name,descriptor:t.descriptor,image:t.image};l.transaction([g],"readwrite").objectStore(g).put(n),p("save:",n)}async function B(t){l||await v(),l.transaction([g],"readwrite").objectStore(g).delete(t.id),p("delete:",t)}var b={modelBasePath:"../../models",filter:{equalization:!0},face:{enabled:!0,detector:{rotation:!0,return:!0,cropFactor:1.6,mask:!1},description:{enabled:!0},iris:{enabled:!0},emotion:{enabled:!1},antispoof:{enabled:!0},liveness:{enabled:!0}},body:{enabled:!1},hand:{enabled:!1},object:{enabled:!1},gesture:{enabled:!0}},S={order:2,multiplier:25,min:.2,max:.8},c={minConfidence:.6,minSize:224,maxTime:1e4,blinkMin:10,blinkMax:800,threshold:.5,mask:b.face.detector.mask,rotation:b.face.detector.rotation,cropFactor:b.face.detector.cropFactor,...S},o={faceCount:!1,faceConfidence:!1,facingCenter:!1,lookingCenter:!1,blinkDetected:!1,faceSize:!1,antispoofCheck:!1,livenessCheck:!1,elapsedMs:0},H=()=>o.faceCount&&o.faceSize&&o.blinkDetected&&o.facingCenter&&o.lookingCenter&&o.faceConfidence&&o.antispoofCheck&&o.livenessCheck,s={face:null,record:null},f={start:0,end:0,time:0},a=new I.Human(b);a.env.perfadd=!1;a.draw.options.font='small-caps 18px "Lato"';a.draw.options.lineHeight=20;var e={video:document.getElementById("video"),canvas:document.getElementById("canvas"),log:document.getElementById("log"),fps:document.getElementById("fps"),match:document.getElementById("match"),name:document.getElementById("name"),save:document.getElementById("save"),delete:document.getElementById("delete"),retry:document.getElementById("retry"),source:document.getElementById("source"),ok:document.getElementById("ok")},w={detect:0,draw:0},h={detect:0,draw:0},T=0,u=(...t)=>{e.log.innerText+=t.join(" ")+` +`,console.log(...t)},k=t=>e.fps.innerText=t;async function L(){k("starting webcam...");let t={audio:!1,video:{facingMode:"user",resizeMode:"none",width:{ideal:document.body.clientWidth}}},n=await navigator.mediaDevices.getUserMedia(t),r=new Promise(i=>{e.video.onloadeddata=()=>i(!0)});e.video.srcObject=n,e.video.play(),await r,e.canvas.width=e.video.videoWidth,e.canvas.height=e.video.videoHeight,a.env.initial&&u("video:",e.video.videoWidth,e.video.videoHeight,"|",n.getVideoTracks()[0].label),e.canvas.onclick=()=>{e.video.paused?e.video.play():e.video.pause()}}async function R(){var t;if(!e.video.paused){(t=s.face)!=null&&t.tensor&&a.tf.dispose(s.face.tensor),await a.detect(e.video);let n=a.now();h.detect=1e3/(n-w.detect),w.detect=n,requestAnimationFrame(R)}}async function F(){let t=a.next(a.result);a.draw.canvas(e.video,e.canvas),await a.draw.all(e.canvas,t);let n=a.now();if(h.draw=1e3/(n-w.draw),w.draw=n,k(`fps: ${h.detect.toFixed(1).padStart(5," ")} detect | ${h.draw.toFixed(1).padStart(5," ")} draw`),o.faceCount=a.result.face.length===1,o.faceCount){let i=Object.values(a.result.gesture).map(m=>m.gesture);(i.includes("blink left eye")||i.includes("blink right eye"))&&(f.start=a.now()),f.start>0&&!i.includes("blink left eye")&&!i.includes("blink right eye")&&(f.end=a.now()),o.blinkDetected=o.blinkDetected||Math.abs(f.end-f.start)>c.blinkMin&&Math.abs(f.end-f.start)c.minConfidence&&(a.result.face[0].faceScore||0)>c.minConfidence,o.antispoofCheck=(a.result.face[0].real||0)>c.minConfidence,o.livenessCheck=(a.result.face[0].live||0)>c.minConfidence,o.faceSize=a.result.face[0].box[2]>=c.minSize&&a.result.face[0].box[3]>=c.minSize}let r=32;for(let[i,m]of Object.entries(o)){let d=document.getElementById(`ok-${i}`);d||(d=document.createElement("div"),d.innerText=i,d.className="ok",d.style.top=`${r}px`,e.ok.appendChild(d)),typeof m=="boolean"?d.style.backgroundColor=m?"lightgreen":"lightcoral":d.innerText=`${i}:${m}`,r+=28}return H()||o.elapsedMs>c.maxTime?(e.video.pause(),a.result.face[0]):(o.elapsedMs=Math.trunc(a.now()-T),new Promise(i=>{setTimeout(async()=>{await F(),i(a.result.face[0])},30)}))}async function j(){var t,n,r,i;if(e.name.value.length>0){let m=(t=e.canvas.getContext("2d"))==null?void 0:t.getImageData(0,0,e.canvas.width,e.canvas.height),d={id:0,name:e.name.value,descriptor:(n=s.face)==null?void 0:n.embedding,image:m};await M(d),u("saved face record:",d.name,"descriptor length:",(i=(r=s.face)==null?void 0:r.embedding)==null?void 0:i.length),u("known face records:",await y())}else u("invalid name")}async function q(){s.record&&s.record.id>0&&await B(s.record)}async function O(){var i,m,d,C;if((i=e.canvas.getContext("2d"))==null||i.clearRect(0,0,c.minSize,c.minSize),!((m=s==null?void 0:s.face)!=null&&m.tensor)||!((d=s==null?void 0:s.face)!=null&&d.embedding))return!1;if(console.log("face record:",s.face),a.tf.browser.toPixels(s.face.tensor,e.canvas),await y()===0)return u("face database is empty"),document.body.style.background="black",e.delete.style.display="none",!1;let t=await D(),n=t.map(x=>x.descriptor).filter(x=>x.length>0),r=a.match(s.face.embedding,n,S);return s.record=t[r.index]||null,s.record&&(u(`best match: ${s.record.name} | id: ${s.record.id} | similarity: ${Math.round(1e3*r.similarity)/10}%`),e.name.value=s.record.name,e.source.style.display="",(C=e.source.getContext("2d"))==null||C.putImageData(s.record.image,0,0)),document.body.style.background=r.similarity>c.threshold?"darkgreen":"maroon",r.similarity>c.threshold}async function E(){var t,n;return o.faceCount=!1,o.faceConfidence=!1,o.facingCenter=!1,o.blinkDetected=!1,o.faceSize=!1,o.antispoofCheck=!1,o.livenessCheck=!1,o.elapsedMs=0,e.match.style.display="none",e.retry.style.display="none",e.source.style.display="none",document.body.style.background="black",await L(),await R(),T=a.now(),s.face=await F(),e.canvas.width=((t=s.face.tensor)==null?void 0:t.shape[1])||c.minSize,e.canvas.height=((n=s.face.tensor)==null?void 0:n.shape[0])||c.minSize,e.source.width=e.canvas.width,e.source.height=e.canvas.height,e.canvas.style.width="",e.match.style.display="flex",e.save.style.display="flex",e.delete.style.display="flex",e.retry.style.display="block",H()?O():(u("did not find valid face"),!1)}async function $(){var t,n;u("human version:",a.version,"| tfjs version:",a.tf.version["tfjs-core"]),u("face embedding model:",b.face.description.enabled?"faceres":"",(t=b.face.mobilefacenet)!=null&&t.enabled?"mobilefacenet":"",(n=b.face.insightface)!=null&&n.enabled?"insightface":""),u("options:",JSON.stringify(c).replace(/{|}|"|\[|\]/g,"").replace(/,/g," ")),k("loading..."),u("known face records:",await y()),await L(),await a.load(),k("initializing..."),e.retry.addEventListener("click",E),e.save.addEventListener("click",j),e.delete.addEventListener("click",q),await a.warmup(),await E()}window.onload=$; //# sourceMappingURL=index.js.map diff --git a/demo/faceid/index.js.map b/demo/faceid/index.js.map index c448e0ee..d9e1c020 100644 --- a/demo/faceid/index.js.map +++ b/demo/faceid/index.js.map @@ -1,7 +1,7 @@ { "version": 3, "sources": ["index.ts", "indexdb.ts"], - "sourcesContent": ["/**\n * Human demo for browsers\n * @default Human Library\n * @summary \n * @author \n * @copyright \n * @license MIT\n */\n\nimport * as H from '../../dist/human.esm.js'; // equivalent of @vladmandic/Human\nimport * as indexDb from './indexdb'; // methods to deal with indexdb\n\nconst humanConfig = { // user configuration for human, used to fine-tune behavior\n modelBasePath: '../../models',\n filter: { equalization: true }, // lets run with histogram equilizer\n face: {\n enabled: true,\n detector: { rotation: true, return: true, cropFactor: 1.6, mask: false }, // return tensor is used to get detected face image\n description: { enabled: true }, // default model for face descriptor extraction is faceres\n // mobilefacenet: { enabled: true, modelPath: 'https://vladmandic.github.io/human-models/models/mobilefacenet.json' }, // alternative model\n // insightface: { enabled: true, modelPath: 'https://vladmandic.github.io/insightface/models/insightface-mobilenet-swish.json' }, // alternative model\n iris: { enabled: true }, // needed to determine gaze direction\n emotion: { enabled: false }, // not needed\n antispoof: { enabled: true }, // enable optional antispoof module\n liveness: { enabled: true }, // enable optional liveness module\n },\n body: { enabled: false },\n hand: { enabled: false },\n object: { enabled: false },\n gesture: { enabled: true }, // parses face and iris gestures\n};\n\n// const matchOptions = { order: 2, multiplier: 1000, min: 0.0, max: 1.0 }; // for embedding model\nconst matchOptions = { order: 2, multiplier: 25, min: 0.2, max: 0.8 }; // for faceres model\n\nconst options = {\n minConfidence: 0.6, // overal face confidence for box, face, gender, real, live\n minSize: 224, // min input to face descriptor model before degradation\n maxTime: 10000, // max time before giving up\n blinkMin: 10, // minimum duration of a valid blink\n blinkMax: 800, // maximum duration of a valid blink\n threshold: 0.5, // minimum similarity\n mask: humanConfig.face.detector.mask,\n rotation: humanConfig.face.detector.rotation,\n cropFactor: humanConfig.face.detector.cropFactor,\n ...matchOptions,\n};\n\nconst ok = { // must meet all rules\n faceCount: false,\n faceConfidence: false,\n facingCenter: false,\n lookingCenter: false,\n blinkDetected: false,\n faceSize: false,\n antispoofCheck: false,\n livenessCheck: false,\n elapsedMs: 0, // total time while waiting for valid face\n};\nconst allOk = () => ok.faceCount && ok.faceSize && ok.blinkDetected && ok.facingCenter && ok.lookingCenter && ok.faceConfidence && ok.antispoofCheck && ok.livenessCheck;\nconst current: { face: H.FaceResult | null, record: indexDb.FaceRecord | null } = { face: null, record: null }; // current face record and matched database record\n\nconst blink = { // internal timers for blink start/end/duration\n start: 0,\n end: 0,\n time: 0,\n};\n\n// let db: Array<{ name: string, source: string, embedding: number[] }> = []; // holds loaded face descriptor database\nconst human = new H.Human(humanConfig); // create instance of human with overrides from user configuration\n\nhuman.env.perfadd = false; // is performance data showing instant or total values\nhuman.draw.options.font = 'small-caps 18px \"Lato\"'; // set font used to draw labels when using draw methods\nhuman.draw.options.lineHeight = 20;\n\nconst dom = { // grab instances of dom objects so we dont have to look them up later\n video: document.getElementById('video') as HTMLVideoElement,\n canvas: document.getElementById('canvas') as HTMLCanvasElement,\n log: document.getElementById('log') as HTMLPreElement,\n fps: document.getElementById('fps') as HTMLPreElement,\n match: document.getElementById('match') as HTMLDivElement,\n name: document.getElementById('name') as HTMLInputElement,\n save: document.getElementById('save') as HTMLSpanElement,\n delete: document.getElementById('delete') as HTMLSpanElement,\n retry: document.getElementById('retry') as HTMLDivElement,\n source: document.getElementById('source') as HTMLCanvasElement,\n ok: document.getElementById('ok') as HTMLDivElement,\n};\nconst timestamp = { detect: 0, draw: 0 }; // holds information used to calculate performance and possible memory leaks\nconst fps = { detect: 0, draw: 0 }; // holds calculated fps information for both detect and screen refresh\nlet startTime = 0;\n\nconst log = (...msg) => { // helper method to output messages\n dom.log.innerText += msg.join(' ') + '\\n';\n console.log(...msg); // eslint-disable-line no-console\n};\nconst printFPS = (msg) => dom.fps.innerText = msg; // print status element\n\nasync function webCam() { // initialize webcam\n printFPS('starting webcam...');\n // @ts-ignore resizeMode is not yet defined in tslib\n const cameraOptions: MediaStreamConstraints = { audio: false, video: { facingMode: 'user', resizeMode: 'none', width: { ideal: document.body.clientWidth } } };\n const stream: MediaStream = await navigator.mediaDevices.getUserMedia(cameraOptions);\n const ready = new Promise((resolve) => { dom.video.onloadeddata = () => resolve(true); });\n dom.video.srcObject = stream;\n void dom.video.play();\n await ready;\n dom.canvas.width = dom.video.videoWidth;\n dom.canvas.height = dom.video.videoHeight;\n if (human.env.initial) log('video:', dom.video.videoWidth, dom.video.videoHeight, '|', stream.getVideoTracks()[0].label);\n dom.canvas.onclick = () => { // pause when clicked on screen and resume on next click\n if (dom.video.paused) void dom.video.play();\n else dom.video.pause();\n };\n}\n\nasync function detectionLoop() { // main detection loop\n if (!dom.video.paused) {\n if (current.face?.tensor) human.tf.dispose(current.face.tensor); // dispose previous tensor\n await human.detect(dom.video); // actual detection; were not capturing output in a local variable as it can also be reached via human.result\n const now = human.now();\n fps.detect = 1000 / (now - timestamp.detect);\n timestamp.detect = now;\n requestAnimationFrame(detectionLoop); // start new frame immediately\n }\n}\n\nasync function validationLoop(): Promise { // main screen refresh loop\n const interpolated = human.next(human.result); // smoothen result using last-known results\n human.draw.canvas(dom.video, dom.canvas); // draw canvas to screen\n await human.draw.all(dom.canvas, interpolated); // draw labels, boxes, lines, etc.\n const now = human.now();\n fps.draw = 1000 / (now - timestamp.draw);\n timestamp.draw = now;\n printFPS(`fps: ${fps.detect.toFixed(1).padStart(5, ' ')} detect | ${fps.draw.toFixed(1).padStart(5, ' ')} draw`); // write status\n ok.faceCount = human.result.face.length === 1; // must be exactly detected face\n if (ok.faceCount) { // skip the rest if no face\n const gestures: string[] = Object.values(human.result.gesture).map((gesture: H.GestureResult) => gesture.gesture); // flatten all gestures\n if (gestures.includes('blink left eye') || gestures.includes('blink right eye')) blink.start = human.now(); // blink starts when eyes get closed\n if (blink.start > 0 && !gestures.includes('blink left eye') && !gestures.includes('blink right eye')) blink.end = human.now(); // if blink started how long until eyes are back open\n ok.blinkDetected = ok.blinkDetected || (Math.abs(blink.end - blink.start) > options.blinkMin && Math.abs(blink.end - blink.start) < options.blinkMax);\n if (ok.blinkDetected && blink.time === 0) blink.time = Math.trunc(blink.end - blink.start);\n ok.facingCenter = gestures.includes('facing center');\n ok.lookingCenter = gestures.includes('looking center'); // must face camera and look at camera\n ok.faceConfidence = (human.result.face[0].boxScore || 0) > options.minConfidence && (human.result.face[0].faceScore || 0) > options.minConfidence;\n ok.antispoofCheck = (human.result.face[0].real || 0) > options.minConfidence;\n ok.livenessCheck = (human.result.face[0].live || 0) > options.minConfidence;\n ok.faceSize = human.result.face[0].box[2] >= options.minSize && human.result.face[0].box[3] >= options.minSize;\n }\n let y = 32;\n for (const [key, val] of Object.entries(ok)) {\n let el = document.getElementById(`ok-${key}`);\n if (!el) {\n el = document.createElement('div');\n el.innerText = key;\n el.className = 'ok';\n el.style.top = `${y}px`;\n dom.ok.appendChild(el);\n }\n if (typeof val === 'boolean') el.style.backgroundColor = val ? 'lightgreen' : 'lightcoral';\n else el.innerText = `${key}:${val}`;\n y += 28;\n }\n if (allOk()) { // all criteria met\n dom.video.pause();\n return human.result.face[0];\n }\n if (ok.elapsedMs > options.maxTime) { // give up\n dom.video.pause();\n return human.result.face[0];\n }\n // run again\n ok.elapsedMs = Math.trunc(human.now() - startTime);\n return new Promise((resolve) => {\n setTimeout(async () => {\n await validationLoop(); // run validation loop until conditions are met\n resolve(human.result.face[0]); // recursive promise resolve\n }, 30); // use to slow down refresh from max refresh rate to target of 30 fps\n });\n}\n\nasync function saveRecords() {\n if (dom.name.value.length > 0) {\n const image = dom.canvas.getContext('2d')?.getImageData(0, 0, dom.canvas.width, dom.canvas.height) as ImageData;\n const rec = { id: 0, name: dom.name.value, descriptor: current.face?.embedding as number[], image };\n await indexDb.save(rec);\n log('saved face record:', rec.name, 'descriptor length:', current.face?.embedding?.length);\n log('known face records:', await indexDb.count());\n } else {\n log('invalid name');\n }\n}\n\nasync function deleteRecord() {\n if (current.record && current.record.id > 0) {\n await indexDb.remove(current.record);\n }\n}\n\nasync function detectFace() {\n dom.canvas.getContext('2d')?.clearRect(0, 0, options.minSize, options.minSize);\n if (!current.face || !current.face.tensor || !current.face.embedding) return false;\n console.log('face record:', current.face); // eslint-disable-line no-console\n human.tf.browser.toPixels(current.face.tensor as unknown as H.TensorLike, dom.canvas);\n if (await indexDb.count() === 0) {\n log('face database is empty');\n document.body.style.background = 'black';\n dom.delete.style.display = 'none';\n return false;\n }\n const db = await indexDb.load();\n const descriptors = db.map((rec) => rec.descriptor).filter((desc) => desc.length > 0);\n const res = human.match(current.face.embedding, descriptors, matchOptions);\n current.record = db[res.index] || null;\n if (current.record) {\n log(`best match: ${current.record.name} | id: ${current.record.id} | similarity: ${Math.round(1000 * res.similarity) / 10}%`);\n dom.name.value = current.record.name;\n dom.source.style.display = '';\n dom.source.getContext('2d')?.putImageData(current.record.image, 0, 0);\n }\n document.body.style.background = res.similarity > options.threshold ? 'darkgreen' : 'maroon';\n return res.similarity > options.threshold;\n}\n\nasync function main() { // main entry point\n ok.faceCount = false;\n ok.faceConfidence = false;\n ok.facingCenter = false;\n ok.blinkDetected = false;\n ok.faceSize = false;\n ok.antispoofCheck = false;\n ok.livenessCheck = false;\n ok.elapsedMs = 0;\n dom.match.style.display = 'none';\n dom.retry.style.display = 'none';\n dom.source.style.display = 'none';\n document.body.style.background = 'black';\n await webCam();\n await detectionLoop(); // start detection loop\n startTime = human.now();\n current.face = await validationLoop(); // start validation loop\n dom.canvas.width = current.face.tensor?.shape[1] || options.minSize;\n dom.canvas.height = current.face.tensor?.shape[0] || options.minSize;\n dom.source.width = dom.canvas.width;\n dom.source.height = dom.canvas.height;\n dom.canvas.style.width = '';\n dom.match.style.display = 'flex';\n dom.save.style.display = 'flex';\n dom.delete.style.display = 'flex';\n dom.retry.style.display = 'block';\n if (!allOk()) { // is all criteria met?\n log('did not find valid face');\n return false;\n }\n return detectFace();\n}\n\nasync function init() {\n log('human version:', human.version, '| tfjs version:', human.tf.version['tfjs-core']);\n log('face embedding model:', humanConfig.face.description.enabled ? 'faceres' : '', humanConfig.face['mobilefacenet']?.enabled ? 'mobilefacenet' : '', humanConfig.face['insightface']?.enabled ? 'insightface' : '');\n log('options:', JSON.stringify(options).replace(/{|}|\"|\\[|\\]/g, '').replace(/,/g, ' '));\n printFPS('loading...');\n log('known face records:', await indexDb.count());\n await webCam(); // start webcam\n await human.load(); // preload all models\n printFPS('initializing...');\n dom.retry.addEventListener('click', main);\n dom.save.addEventListener('click', saveRecords);\n dom.delete.addEventListener('click', deleteRecord);\n await human.warmup(); // warmup function to initialize backend for future faster detection\n await main();\n}\n\nwindow.onload = init;\n", "let db: IDBDatabase; // instance of indexdb\n\nconst database = 'human';\nconst table = 'person';\n\nexport interface FaceRecord { id: number, name: string, descriptor: number[], image: ImageData }\n\nconst log = (...msg) => console.log('indexdb', ...msg); // eslint-disable-line no-console\n\nexport async function open() {\n if (db) return true;\n return new Promise((resolve) => {\n const request: IDBOpenDBRequest = indexedDB.open(database, 1);\n request.onerror = (evt) => log('error:', evt);\n request.onupgradeneeded = (evt: IDBVersionChangeEvent) => { // create if doesnt exist\n log('create:', evt.target);\n db = (evt.target as IDBOpenDBRequest).result;\n db.createObjectStore(table, { keyPath: 'id', autoIncrement: true });\n };\n request.onsuccess = (evt) => { // open\n db = (evt.target as IDBOpenDBRequest).result;\n log('open:', db);\n resolve(true);\n };\n });\n}\n\nexport async function load(): Promise {\n const faceDB: FaceRecord[] = [];\n if (!db) await open(); // open or create if not already done\n return new Promise((resolve) => {\n const cursor: IDBRequest = db.transaction([table], 'readwrite').objectStore(table).openCursor(null, 'next');\n cursor.onerror = (evt) => log('load error:', evt);\n cursor.onsuccess = (evt) => {\n if ((evt.target as IDBRequest).result) {\n faceDB.push((evt.target as IDBRequest).result.value);\n (evt.target as IDBRequest).result.continue();\n } else {\n resolve(faceDB);\n }\n };\n });\n}\n\nexport async function count(): Promise {\n if (!db) await open(); // open or create if not already done\n return new Promise((resolve) => {\n const store: IDBRequest = db.transaction([table], 'readwrite').objectStore(table).count();\n store.onerror = (evt) => log('count error:', evt);\n store.onsuccess = () => resolve(store.result);\n });\n}\n\nexport async function save(faceRecord: FaceRecord) {\n if (!db) await open(); // open or create if not already done\n const newRecord = { name: faceRecord.name, descriptor: faceRecord.descriptor, image: faceRecord.image }; // omit id as its autoincrement\n db.transaction([table], 'readwrite').objectStore(table).put(newRecord);\n log('save:', newRecord);\n}\n\nexport async function remove(faceRecord: FaceRecord) {\n if (!db) await open(); // open or create if not already done\n db.transaction([table], 'readwrite').objectStore(table).delete(faceRecord.id); // delete based on id\n log('delete:', faceRecord);\n}\n"], - "mappings": ";;;;;;AASA,UAAYA,MAAO,0BCTnB,IAAIC,EAEEC,EAAW,QACXC,EAAQ,SAIRC,EAAM,IAAIC,IAAQ,QAAQ,IAAI,UAAW,GAAGA,CAAG,EAErD,eAAsBC,GAAO,CAC3B,OAAIL,EAAW,GACR,IAAI,QAASM,GAAY,CAC9B,IAAMC,EAA4B,UAAU,KAAKN,EAAU,CAAC,EAC5DM,EAAQ,QAAWC,GAAQL,EAAI,SA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Human demo for browsers\n * @default Human Library\n * @summary \n * @author \n * @copyright \n * @license MIT\n */\n\nimport * as H from '../../dist/human.esm.js'; // equivalent of @vladmandic/Human\nimport * as indexDb from './indexdb'; // methods to deal with indexdb\n\nconst humanConfig = { // user configuration for human, used to fine-tune behavior\n modelBasePath: '../../models',\n filter: { equalization: true }, // lets run with histogram equilizer\n face: {\n enabled: true,\n detector: { rotation: true, return: true, cropFactor: 1.6, mask: false }, // return tensor is used to get detected face image\n description: { enabled: true }, // default model for face descriptor extraction is faceres\n // mobilefacenet: { enabled: true, modelPath: 'https://vladmandic.github.io/human-models/models/mobilefacenet.json' }, // alternative model\n // insightface: { enabled: true, modelPath: 'https://vladmandic.github.io/insightface/models/insightface-mobilenet-swish.json' }, // alternative model\n iris: { enabled: true }, // needed to determine gaze direction\n emotion: { enabled: false }, // not needed\n antispoof: { enabled: true }, // enable optional antispoof module\n liveness: { enabled: true }, // enable optional liveness module\n },\n body: { enabled: false },\n hand: { enabled: false },\n object: { enabled: false },\n gesture: { enabled: true }, // parses face and iris gestures\n};\n\n// const matchOptions = { order: 2, multiplier: 1000, min: 0.0, max: 1.0 }; // for embedding model\nconst matchOptions = { order: 2, multiplier: 25, min: 0.2, max: 0.8 }; // for faceres model\n\nconst options = {\n minConfidence: 0.6, // overal face confidence for box, face, gender, real, live\n minSize: 224, // min input to face descriptor model before degradation\n maxTime: 10000, // max time before giving up\n blinkMin: 10, // minimum duration of a valid blink\n blinkMax: 800, // maximum duration of a valid blink\n threshold: 0.5, // minimum similarity\n mask: humanConfig.face.detector.mask,\n rotation: humanConfig.face.detector.rotation,\n cropFactor: humanConfig.face.detector.cropFactor,\n ...matchOptions,\n};\n\nconst ok = { // must meet all rules\n faceCount: false,\n faceConfidence: false,\n facingCenter: false,\n lookingCenter: false,\n blinkDetected: false,\n faceSize: false,\n antispoofCheck: false,\n livenessCheck: false,\n elapsedMs: 0, // total time while waiting for valid face\n};\nconst allOk = () => ok.faceCount && ok.faceSize && ok.blinkDetected && ok.facingCenter && ok.lookingCenter && ok.faceConfidence && ok.antispoofCheck && ok.livenessCheck;\nconst current: { face: H.FaceResult | null, record: indexDb.FaceRecord | null } = { face: null, record: null }; // current face record and matched database record\n\nconst blink = { // internal timers for blink start/end/duration\n start: 0,\n end: 0,\n time: 0,\n};\n\n// let db: Array<{ name: string, source: string, embedding: number[] }> = []; // holds loaded face descriptor database\nconst human = new H.Human(humanConfig); // create instance of human with overrides from user configuration\n\nhuman.env.perfadd = false; // is performance data showing instant or total values\nhuman.draw.options.font = 'small-caps 18px \"Lato\"'; // set font used to draw labels when using draw methods\nhuman.draw.options.lineHeight = 20;\n\nconst dom = { // grab instances of dom objects so we dont have to look them up later\n video: document.getElementById('video') as HTMLVideoElement,\n canvas: document.getElementById('canvas') as HTMLCanvasElement,\n log: document.getElementById('log') as HTMLPreElement,\n fps: document.getElementById('fps') as HTMLPreElement,\n match: document.getElementById('match') as HTMLDivElement,\n name: document.getElementById('name') as HTMLInputElement,\n save: document.getElementById('save') as HTMLSpanElement,\n delete: document.getElementById('delete') as HTMLSpanElement,\n retry: document.getElementById('retry') as HTMLDivElement,\n source: document.getElementById('source') as HTMLCanvasElement,\n ok: document.getElementById('ok') as HTMLDivElement,\n};\nconst timestamp = { detect: 0, draw: 0 }; // holds information used to calculate performance and possible memory leaks\nconst fps = { detect: 0, draw: 0 }; // holds calculated fps information for both detect and screen refresh\nlet startTime = 0;\n\nconst log = (...msg) => { // helper method to output messages\n dom.log.innerText += msg.join(' ') + '\\n';\n console.log(...msg); // eslint-disable-line no-console\n};\nconst printFPS = (msg) => dom.fps.innerText = msg; // print status element\n\nasync function webCam() { // initialize webcam\n printFPS('starting webcam...');\n // @ts-ignore resizeMode is not yet defined in tslib\n const cameraOptions: MediaStreamConstraints = { audio: false, video: { facingMode: 'user', resizeMode: 'none', width: { ideal: document.body.clientWidth } } };\n const stream: MediaStream = await navigator.mediaDevices.getUserMedia(cameraOptions);\n const ready = new Promise((resolve) => { dom.video.onloadeddata = () => resolve(true); });\n dom.video.srcObject = stream;\n void dom.video.play();\n await ready;\n dom.canvas.width = dom.video.videoWidth;\n dom.canvas.height = dom.video.videoHeight;\n if (human.env.initial) log('video:', dom.video.videoWidth, dom.video.videoHeight, '|', stream.getVideoTracks()[0].label);\n dom.canvas.onclick = () => { // pause when clicked on screen and resume on next click\n if (dom.video.paused) void dom.video.play();\n else dom.video.pause();\n };\n}\n\nasync function detectionLoop() { // main detection loop\n if (!dom.video.paused) {\n if (current.face?.tensor) human.tf.dispose(current.face.tensor); // dispose previous tensor\n await human.detect(dom.video); // actual detection; were not capturing output in a local variable as it can also be reached via human.result\n const now = human.now();\n fps.detect = 1000 / (now - timestamp.detect);\n timestamp.detect = now;\n requestAnimationFrame(detectionLoop); // start new frame immediately\n }\n}\n\nasync function validationLoop(): Promise { // main screen refresh loop\n const interpolated = human.next(human.result); // smoothen result using last-known results\n human.draw.canvas(dom.video, dom.canvas); // draw canvas to screen\n await human.draw.all(dom.canvas, interpolated); // draw labels, boxes, lines, etc.\n const now = human.now();\n fps.draw = 1000 / (now - timestamp.draw);\n timestamp.draw = now;\n printFPS(`fps: ${fps.detect.toFixed(1).padStart(5, ' ')} detect | ${fps.draw.toFixed(1).padStart(5, ' ')} draw`); // write status\n ok.faceCount = human.result.face.length === 1; // must be exactly detected face\n if (ok.faceCount) { // skip the rest if no face\n const gestures: string[] = Object.values(human.result.gesture).map((gesture: H.GestureResult) => gesture.gesture); // flatten all gestures\n if (gestures.includes('blink left eye') || gestures.includes('blink right eye')) blink.start = human.now(); // blink starts when eyes get closed\n if (blink.start > 0 && !gestures.includes('blink left eye') && !gestures.includes('blink right eye')) blink.end = human.now(); // if blink started how long until eyes are back open\n ok.blinkDetected = ok.blinkDetected || (Math.abs(blink.end - blink.start) > options.blinkMin && Math.abs(blink.end - blink.start) < options.blinkMax);\n if (ok.blinkDetected && blink.time === 0) blink.time = Math.trunc(blink.end - blink.start);\n ok.facingCenter = gestures.includes('facing center');\n ok.lookingCenter = gestures.includes('looking center'); // must face camera and look at camera\n ok.faceConfidence = (human.result.face[0].boxScore || 0) > options.minConfidence && (human.result.face[0].faceScore || 0) > options.minConfidence;\n ok.antispoofCheck = (human.result.face[0].real || 0) > options.minConfidence;\n ok.livenessCheck = (human.result.face[0].live || 0) > options.minConfidence;\n ok.faceSize = human.result.face[0].box[2] >= options.minSize && human.result.face[0].box[3] >= options.minSize;\n }\n let y = 32;\n for (const [key, val] of Object.entries(ok)) {\n let el = document.getElementById(`ok-${key}`);\n if (!el) {\n el = document.createElement('div');\n el.innerText = key;\n el.className = 'ok';\n el.style.top = `${y}px`;\n dom.ok.appendChild(el);\n }\n if (typeof val === 'boolean') el.style.backgroundColor = val ? 'lightgreen' : 'lightcoral';\n else el.innerText = `${key}:${val}`;\n y += 28;\n }\n if (allOk()) { // all criteria met\n dom.video.pause();\n return human.result.face[0];\n }\n if (ok.elapsedMs > options.maxTime) { // give up\n dom.video.pause();\n return human.result.face[0];\n }\n // run again\n ok.elapsedMs = Math.trunc(human.now() - startTime);\n return new Promise((resolve) => {\n setTimeout(async () => {\n await validationLoop(); // run validation loop until conditions are met\n resolve(human.result.face[0]); // recursive promise resolve\n }, 30); // use to slow down refresh from max refresh rate to target of 30 fps\n });\n}\n\nasync function saveRecords() {\n if (dom.name.value.length > 0) {\n const image = dom.canvas.getContext('2d')?.getImageData(0, 0, dom.canvas.width, dom.canvas.height) as ImageData;\n const rec = { id: 0, name: dom.name.value, descriptor: current.face?.embedding as number[], image };\n await indexDb.save(rec);\n log('saved face record:', rec.name, 'descriptor length:', current.face?.embedding?.length);\n log('known face records:', await indexDb.count());\n } else {\n log('invalid name');\n }\n}\n\nasync function deleteRecord() {\n if (current.record && current.record.id > 0) {\n await indexDb.remove(current.record);\n }\n}\n\nasync function detectFace() {\n dom.canvas.getContext('2d')?.clearRect(0, 0, options.minSize, options.minSize);\n if (!current?.face?.tensor || !current?.face?.embedding) return false;\n console.log('face record:', current.face); // eslint-disable-line no-console\n human.tf.browser.toPixels(current.face.tensor as unknown as H.TensorLike, dom.canvas);\n if (await indexDb.count() === 0) {\n log('face database is empty');\n document.body.style.background = 'black';\n dom.delete.style.display = 'none';\n return false;\n }\n const db = await indexDb.load();\n const descriptors = db.map((rec) => rec.descriptor).filter((desc) => desc.length > 0);\n const res = human.match(current.face.embedding, descriptors, matchOptions);\n current.record = db[res.index] || null;\n if (current.record) {\n log(`best match: ${current.record.name} | id: ${current.record.id} | similarity: ${Math.round(1000 * res.similarity) / 10}%`);\n dom.name.value = current.record.name;\n dom.source.style.display = '';\n dom.source.getContext('2d')?.putImageData(current.record.image, 0, 0);\n }\n document.body.style.background = res.similarity > options.threshold ? 'darkgreen' : 'maroon';\n return res.similarity > options.threshold;\n}\n\nasync function main() { // main entry point\n ok.faceCount = false;\n ok.faceConfidence = false;\n ok.facingCenter = false;\n ok.blinkDetected = false;\n ok.faceSize = false;\n ok.antispoofCheck = false;\n ok.livenessCheck = false;\n ok.elapsedMs = 0;\n dom.match.style.display = 'none';\n dom.retry.style.display = 'none';\n dom.source.style.display = 'none';\n document.body.style.background = 'black';\n await webCam();\n await detectionLoop(); // start detection loop\n startTime = human.now();\n current.face = await validationLoop(); // start validation loop\n dom.canvas.width = current.face.tensor?.shape[1] || options.minSize;\n dom.canvas.height = current.face.tensor?.shape[0] || options.minSize;\n dom.source.width = dom.canvas.width;\n dom.source.height = dom.canvas.height;\n dom.canvas.style.width = '';\n dom.match.style.display = 'flex';\n dom.save.style.display = 'flex';\n dom.delete.style.display = 'flex';\n dom.retry.style.display = 'block';\n if (!allOk()) { // is all criteria met?\n log('did not find valid face');\n return false;\n }\n return detectFace();\n}\n\nasync function init() {\n log('human version:', human.version, '| tfjs version:', human.tf.version['tfjs-core']);\n log('face embedding model:', humanConfig.face.description.enabled ? 'faceres' : '', humanConfig.face['mobilefacenet']?.enabled ? 'mobilefacenet' : '', humanConfig.face['insightface']?.enabled ? 'insightface' : '');\n log('options:', JSON.stringify(options).replace(/{|}|\"|\\[|\\]/g, '').replace(/,/g, ' '));\n printFPS('loading...');\n log('known face records:', await indexDb.count());\n await webCam(); // start webcam\n await human.load(); // preload all models\n printFPS('initializing...');\n dom.retry.addEventListener('click', main);\n dom.save.addEventListener('click', saveRecords);\n dom.delete.addEventListener('click', deleteRecord);\n await human.warmup(); // warmup function to initialize backend for future faster detection\n await main();\n}\n\nwindow.onload = init;\n", "let db: IDBDatabase; // instance of indexdb\n\nconst database = 'human';\nconst table = 'person';\n\nexport interface FaceRecord { id: number, name: string, descriptor: number[], image: ImageData }\n\nconst log = (...msg) => console.log('indexdb', ...msg); // eslint-disable-line no-console\n\nexport async function open() {\n if (db) return true;\n return new Promise((resolve) => {\n const request: IDBOpenDBRequest = indexedDB.open(database, 1);\n request.onerror = (evt) => log('error:', evt);\n request.onupgradeneeded = (evt: IDBVersionChangeEvent) => { // create if doesnt exist\n log('create:', evt.target);\n db = (evt.target as IDBOpenDBRequest).result;\n db.createObjectStore(table, { keyPath: 'id', autoIncrement: true });\n };\n request.onsuccess = (evt) => { // open\n db = (evt.target as IDBOpenDBRequest).result;\n log('open:', db);\n resolve(true);\n };\n });\n}\n\nexport async function load(): Promise {\n const faceDB: FaceRecord[] = [];\n if (!db) await open(); // open or create if not already done\n return new Promise((resolve) => {\n const cursor: IDBRequest = db.transaction([table], 'readwrite').objectStore(table).openCursor(null, 'next');\n cursor.onerror = (evt) => log('load error:', evt);\n cursor.onsuccess = (evt) => {\n if ((evt.target as IDBRequest).result) {\n faceDB.push((evt.target as IDBRequest).result.value);\n (evt.target as IDBRequest).result.continue();\n } else {\n resolve(faceDB);\n }\n };\n });\n}\n\nexport async function count(): Promise {\n if (!db) await open(); // open or create if not already done\n return new Promise((resolve) => {\n const store: IDBRequest = db.transaction([table], 'readwrite').objectStore(table).count();\n store.onerror = (evt) => log('count error:', evt);\n store.onsuccess = () => resolve(store.result);\n });\n}\n\nexport async function save(faceRecord: FaceRecord) {\n if (!db) await open(); // open or create if not already done\n const newRecord = { name: faceRecord.name, descriptor: faceRecord.descriptor, image: faceRecord.image }; // omit id as its autoincrement\n db.transaction([table], 'readwrite').objectStore(table).put(newRecord);\n log('save:', newRecord);\n}\n\nexport async function remove(faceRecord: FaceRecord) {\n if (!db) await open(); // open or create if not already done\n db.transaction([table], 'readwrite').objectStore(table).delete(faceRecord.id); // delete based on id\n log('delete:', faceRecord);\n}\n"], + "mappings": ";;;;;;AASA,UAAYA,MAAO,0BCTnB,IAAIC,EAEEC,EAAW,QACXC,EAAQ,SAIRC,EAAM,IAAIC,IAAQ,QAAQ,IAAI,UAAW,GAAGA,CAAG,EAErD,eAAsBC,GAAO,CAC3B,OAAIL,EAAW,GACR,IAAI,QAASM,GAAY,CAC9B,IAAMC,EAA4B,UAAU,KAAKN,EAAU,CAAC,EAC5DM,EAAQ,QAAWC,GAAQL,EAAI,SAAUK,CAAG,EAC5CD,EAAQ,gBAAmBC,GAA+B,CACxDL,EAAI,UAAWK,EAAI,MAAM,EACzBR,EAAMQ,EAAI,OAA4B,OACtCR,EAAG,kBAAkBE,EAAO,CAAE,QAAS,KAAM,cAAe,EAAK,CAAC,CACpE,EACAK,EAAQ,UAAaC,GAAQ,CAC3BR,EAAMQ,EAAI,OAA4B,OACtCL,EAAI,QAASH,CAAE,EACfM,EAAQ,EAAI,CACd,CACF,CAAC,CACH,CAEA,eAAsBG,GAA8B,CAClD,IAAMC,EAAuB,CAAC,EAC9B,OAAKV,GAAI,MAAMK,EAAK,EACb,IAAI,QAASC,GAAY,CAC9B,IAAMK,EAAqBX,EAAG,YAAY,CAACE,CAAK,EAAG,WAAW,EAAE,YAAYA,CAAK,EAAE,WAAW,KAAM,MAAM,EAC1GS,EAAO,QAAWH,GAAQL,EAAI,cAAeK,CAAG,EAChDG,EAAO,UAAaH,GAAQ,CACrBA,EAAI,OAAsB,QAC7BE,EAAO,KAAMF,EAAI,OAAsB,OAAO,KAAK,EAClDA,EAAI,OAAsB,OAAO,SAAS,GAE3CF,EAAQI,CAAM,CAElB,CACF,C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UAAY,IAAIqB,EAAArB,EAAY,KAAK,gBAAjB,MAAAqB,EAAmC,QAAU,gBAAkB,IAAIW,EAAAhC,EAAY,KAAK,cAAjB,MAAAgC,EAAiC,QAAU,cAAgB,EAAE,EACpNpB,EAAI,WAAY,KAAK,UAAUV,CAAO,EAAE,QAAQ,eAAgB,EAAE,EAAE,QAAQ,KAAM,GAAG,CAAC,EACtFY,EAAS,YAAY,EACrBF,EAAI,sBAAuB,MAAc0B,EAAM,CAAC,EAChD,MAAMvB,EAAO,EACb,MAAMR,EAAM,KAAK,EACjBO,EAAS,iBAAiB,EAC1BN,EAAI,MAAM,iBAAiB,QAASuC,CAAI,EACxCvC,EAAI,KAAK,iBAAiB,QAASuB,CAAW,EAC9CvB,EAAI,OAAO,iBAAiB,QAAS+B,CAAY,EACjD,MAAMhC,EAAM,OAAO,EACnB,MAAMwC,EAAK,CACb,CAEA,OAAO,OAASC", "names": ["H", "db", "database", "table", "log", "msg", "open", "resolve", "request", "evt", "load", "faceDB", "cursor", "count", "store", "save", "faceRecord", "newRecord", "remove", "humanConfig", "matchOptions", "options", "ok", "allOk", "current", "blink", "human", "dom", "timestamp", "fps", "startTime", "log", "msg", "printFPS", "webCam", "cameraOptions", "stream", "ready", "resolve", "detectionLoop", "_a", "now", "validationLoop", "interpolated", "gestures", "gesture", "y", "key", "val", "el", "saveRecords", "_b", "_c", "_d", "image", "rec", "save", "count", "deleteRecord", "remove", "detectFace", "db", "load", "descriptors", "desc", "res", "main", "init"] } diff --git a/demo/faceid/index.ts b/demo/faceid/index.ts index eaecb971..aea5028f 100644 --- a/demo/faceid/index.ts +++ b/demo/faceid/index.ts @@ -199,7 +199,7 @@ async function deleteRecord() { async function detectFace() { dom.canvas.getContext('2d')?.clearRect(0, 0, options.minSize, options.minSize); - if (!current.face || !current.face.tensor || !current.face.embedding) return false; + if (!current?.face?.tensor || !current?.face?.embedding) return false; console.log('face record:', current.face); // eslint-disable-line no-console human.tf.browser.toPixels(current.face.tensor as unknown as H.TensorLike, dom.canvas); if (await indexDb.count() === 0) { diff --git a/demo/typescript/index.js.map b/demo/typescript/index.js.map index c395667a..ca92fb46 100644 --- a/demo/typescript/index.js.map +++ b/demo/typescript/index.js.map @@ -1,7 +1,7 @@ { "version": 3, "sources": ["index.ts"], - "sourcesContent": ["/**\n * Human demo for browsers\n * @default Human Library\n * @summary \n * @author \n * @copyright \n * @license MIT\n */\n\nimport * as H from '../../dist/human.esm.js'; // equivalent of @vladmandic/Human\n\nconst humanConfig: Partial = { // user configuration for human, used to fine-tune behavior\n // backend: 'wasm' as const,\n // wasmPath: 'https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@3.18.0/dist/',\n // cacheSensitivity: 0,\n async: false,\n modelBasePath: '../../models',\n filter: { enabled: true, equalization: false, flip: false },\n face: { enabled: true, detector: { rotation: false }, mesh: { enabled: true }, attention: { enabled: false }, iris: { enabled: true }, description: { enabled: true }, emotion: { enabled: true } },\n body: { enabled: true },\n hand: { enabled: true },\n object: { enabled: false },\n gesture: { enabled: true },\n};\n\nconst human = new H.Human(humanConfig); // create instance of human with overrides from user configuration\n\nhuman.env.perfadd = false; // is performance data showing instant or total values\nhuman.draw.options.font = 'small-caps 18px \"Lato\"'; // set font used to draw labels when using draw methods\nhuman.draw.options.lineHeight = 20;\n// human.draw.options.fillPolygons = true;\n\nconst dom = { // grab instances of dom objects so we dont have to look them up later\n video: document.getElementById('video') as HTMLVideoElement,\n canvas: document.getElementById('canvas') as HTMLCanvasElement,\n log: document.getElementById('log') as HTMLPreElement,\n fps: document.getElementById('status') as HTMLPreElement,\n perf: document.getElementById('performance') as HTMLDivElement,\n};\nconst timestamp = { detect: 0, draw: 0, tensors: 0, start: 0 }; // holds information used to calculate performance and possible memory leaks\nconst fps = { detectFPS: 0, drawFPS: 0, frames: 0, averageMs: 0 }; // holds calculated fps information for both detect and screen refresh\n\nconst log = (...msg) => { // helper method to output messages\n dom.log.innerText += msg.join(' ') + '\\n';\n console.log(...msg); // eslint-disable-line no-console\n};\nconst status = (msg) => dom.fps.innerText = msg; // print status element\nconst perf = (msg) => dom.perf.innerText = 'tensors:' + (human.tf.memory().numTensors as number).toString() + ' | performance: ' + JSON.stringify(msg).replace(/\"|{|}/g, '').replace(/,/g, ' | '); // print performance element\n\nasync function webCam() { // initialize webcam\n status('starting webcam...');\n // @ts-ignore resizeMode is not yet defined in tslib\n const options: MediaStreamConstraints = { audio: false, video: { facingMode: 'user', resizeMode: 'none', width: { ideal: document.body.clientWidth }, height: { ideal: document.body.clientHeight } } };\n const stream: MediaStream = await navigator.mediaDevices.getUserMedia(options);\n const ready = new Promise((resolve) => { dom.video.onloadeddata = () => resolve(true); });\n dom.video.srcObject = stream;\n void dom.video.play();\n await ready;\n dom.canvas.width = dom.video.videoWidth;\n dom.canvas.height = dom.video.videoHeight;\n const track: MediaStreamTrack = stream.getVideoTracks()[0];\n const capabilities: MediaTrackCapabilities | string = track.getCapabilities ? track.getCapabilities() : '';\n const settings: MediaTrackSettings | string = track.getSettings ? track.getSettings() : '';\n const constraints: MediaTrackConstraints | string = track.getConstraints ? track.getConstraints() : '';\n log('video:', dom.video.videoWidth, dom.video.videoHeight, track.label, { stream, track, settings, constraints, capabilities });\n dom.canvas.onclick = () => { // pause when clicked on screen and resume on next click\n if (dom.video.paused) void dom.video.play();\n else dom.video.pause();\n };\n}\n\nasync function detectionLoop() { // main detection loop\n if (!dom.video.paused) {\n if (timestamp.start === 0) timestamp.start = human.now();\n // log('profiling data:', await human.profile(dom.video));\n await human.detect(dom.video); // actual detection; were not capturing output in a local variable as it can also be reached via human.result\n const tensors = human.tf.memory().numTensors; // check current tensor usage for memory leaks\n if (tensors - timestamp.tensors !== 0) log('allocated tensors:', tensors - timestamp.tensors); // printed on start and each time there is a tensor leak\n timestamp.tensors = tensors;\n fps.detectFPS = Math.round(1000 * 1000 / (human.now() - timestamp.detect)) / 1000;\n fps.frames++;\n fps.averageMs = Math.round(1000 * (human.now() - timestamp.start) / fps.frames) / 1000;\n if (fps.frames % 100 === 0 && !dom.video.paused) log('performance', { ...fps, tensors: timestamp.tensors });\n }\n timestamp.detect = human.now();\n requestAnimationFrame(detectionLoop); // start new frame immediately\n}\n\nasync function drawLoop() { // main screen refresh loop\n if (!dom.video.paused) {\n const interpolated = human.next(human.result); // smoothen result using last-known results\n if (human.config.filter.flip) human.draw.canvas(interpolated.canvas as HTMLCanvasElement, dom.canvas); // draw processed image to screen canvas\n else human.draw.canvas(dom.video, dom.canvas); // draw original video to screen canvas // better than using procesed image as this loop happens faster than processing loop\n await human.draw.all(dom.canvas, interpolated); // draw labels, boxes, lines, etc.\n perf(interpolated.performance); // write performance data\n }\n const now = human.now();\n fps.drawFPS = Math.round(1000 * 1000 / (now - timestamp.draw)) / 1000;\n timestamp.draw = now;\n status(dom.video.paused ? 'paused' : `fps: ${fps.detectFPS.toFixed(1).padStart(5, ' ')} detect | ${fps.drawFPS.toFixed(1).padStart(5, ' ')} draw`); // write status\n setTimeout(drawLoop, 30); // use to slow down refresh from max refresh rate to target of 30 fps\n}\n\nasync function main() { // main entry point\n log('human version:', human.version, '| tfjs version:', human.tf.version['tfjs-core']);\n log('platform:', human.env.platform, '| agent:', human.env.agent);\n status('loading...');\n await human.load(); // preload all models\n log('backend:', human.tf.getBackend(), '| available:', human.env.backends);\n log('models stats:', human.getModelStats());\n log('models loaded:', Object.values(human.models).filter((model) => model !== null).length);\n status('initializing...');\n await human.warmup(); // warmup function to initialize backend for future faster detection\n await webCam(); // start webcam\n await detectionLoop(); // start detection loop\n await drawLoop(); // start draw loop\n}\n\nwindow.onload = main;\n"], + "sourcesContent": ["/**\n * Human demo for browsers\n * @default Human Library\n * @summary \n * @author \n * @copyright \n * @license MIT\n */\n\nimport * as H from '../../dist/human.esm.js'; // equivalent of @vladmandic/Human\n\nconst humanConfig: Partial = { // user configuration for human, used to fine-tune behavior\n // backend: 'wasm' as const,\n // wasmPath: 'https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@3.20.0/dist/',\n // cacheSensitivity: 0,\n async: false,\n modelBasePath: '../../models',\n filter: { enabled: true, equalization: false, flip: false },\n face: { enabled: true, detector: { rotation: false }, mesh: { enabled: true }, attention: { enabled: false }, iris: { enabled: true }, description: { enabled: true }, emotion: { enabled: true } },\n body: { enabled: true },\n hand: { enabled: true },\n object: { enabled: false },\n gesture: { enabled: true },\n};\n\nconst human = new H.Human(humanConfig); // create instance of human with overrides from user configuration\n\nhuman.env.perfadd = false; // is performance data showing instant or total values\nhuman.draw.options.font = 'small-caps 18px \"Lato\"'; // set font used to draw labels when using draw methods\nhuman.draw.options.lineHeight = 20;\n// human.draw.options.fillPolygons = true;\n\nconst dom = { // grab instances of dom objects so we dont have to look them up later\n video: document.getElementById('video') as HTMLVideoElement,\n canvas: document.getElementById('canvas') as HTMLCanvasElement,\n log: document.getElementById('log') as HTMLPreElement,\n fps: document.getElementById('status') as HTMLPreElement,\n perf: document.getElementById('performance') as HTMLDivElement,\n};\nconst timestamp = { detect: 0, draw: 0, tensors: 0, start: 0 }; // holds information used to calculate performance and possible memory leaks\nconst fps = { detectFPS: 0, drawFPS: 0, frames: 0, averageMs: 0 }; // holds calculated fps information for both detect and screen refresh\n\nconst log = (...msg) => { // helper method to output messages\n dom.log.innerText += msg.join(' ') + '\\n';\n console.log(...msg); // eslint-disable-line no-console\n};\nconst status = (msg) => dom.fps.innerText = msg; // print status element\nconst perf = (msg) => dom.perf.innerText = 'tensors:' + (human.tf.memory().numTensors as number).toString() + ' | performance: ' + JSON.stringify(msg).replace(/\"|{|}/g, '').replace(/,/g, ' | '); // print performance element\n\nasync function webCam() { // initialize webcam\n status('starting webcam...');\n // @ts-ignore resizeMode is not yet defined in tslib\n const options: MediaStreamConstraints = { audio: false, video: { facingMode: 'user', resizeMode: 'none', width: { ideal: document.body.clientWidth }, height: { ideal: document.body.clientHeight } } };\n const stream: MediaStream = await navigator.mediaDevices.getUserMedia(options);\n const ready = new Promise((resolve) => { dom.video.onloadeddata = () => resolve(true); });\n dom.video.srcObject = stream;\n void dom.video.play();\n await ready;\n dom.canvas.width = dom.video.videoWidth;\n dom.canvas.height = dom.video.videoHeight;\n const track: MediaStreamTrack = stream.getVideoTracks()[0];\n const capabilities: MediaTrackCapabilities | string = track.getCapabilities ? track.getCapabilities() : '';\n const settings: MediaTrackSettings | string = track.getSettings ? track.getSettings() : '';\n const constraints: MediaTrackConstraints | string = track.getConstraints ? track.getConstraints() : '';\n log('video:', dom.video.videoWidth, dom.video.videoHeight, track.label, { stream, track, settings, constraints, capabilities });\n dom.canvas.onclick = () => { // pause when clicked on screen and resume on next click\n if (dom.video.paused) void dom.video.play();\n else dom.video.pause();\n };\n}\n\nasync function detectionLoop() { // main detection loop\n if (!dom.video.paused) {\n if (timestamp.start === 0) timestamp.start = human.now();\n // log('profiling data:', await human.profile(dom.video));\n await human.detect(dom.video); // actual detection; were not capturing output in a local variable as it can also be reached via human.result\n const tensors = human.tf.memory().numTensors; // check current tensor usage for memory leaks\n if (tensors - timestamp.tensors !== 0) log('allocated tensors:', tensors - timestamp.tensors); // printed on start and each time there is a tensor leak\n timestamp.tensors = tensors;\n fps.detectFPS = Math.round(1000 * 1000 / (human.now() - timestamp.detect)) / 1000;\n fps.frames++;\n fps.averageMs = Math.round(1000 * (human.now() - timestamp.start) / fps.frames) / 1000;\n if (fps.frames % 100 === 0 && !dom.video.paused) log('performance', { ...fps, tensors: timestamp.tensors });\n }\n timestamp.detect = human.now();\n requestAnimationFrame(detectionLoop); // start new frame immediately\n}\n\nasync function drawLoop() { // main screen refresh loop\n if (!dom.video.paused) {\n const interpolated = human.next(human.result); // smoothen result using last-known results\n if (human.config.filter.flip) human.draw.canvas(interpolated.canvas as HTMLCanvasElement, dom.canvas); // draw processed image to screen canvas\n else human.draw.canvas(dom.video, dom.canvas); // draw original video to screen canvas // better than using procesed image as this loop happens faster than processing loop\n await human.draw.all(dom.canvas, interpolated); // draw labels, boxes, lines, etc.\n perf(interpolated.performance); // write performance data\n }\n const now = human.now();\n fps.drawFPS = Math.round(1000 * 1000 / (now - timestamp.draw)) / 1000;\n timestamp.draw = now;\n status(dom.video.paused ? 'paused' : `fps: ${fps.detectFPS.toFixed(1).padStart(5, ' ')} detect | ${fps.drawFPS.toFixed(1).padStart(5, ' ')} draw`); // write status\n setTimeout(drawLoop, 30); // use to slow down refresh from max refresh rate to target of 30 fps\n}\n\nasync function main() { // main entry point\n log('human version:', human.version, '| tfjs version:', human.tf.version['tfjs-core']);\n log('platform:', human.env.platform, '| agent:', human.env.agent);\n status('loading...');\n await human.load(); // preload all models\n log('backend:', human.tf.getBackend(), '| available:', human.env.backends);\n log('models stats:', human.getModelStats());\n log('models loaded:', Object.values(human.models).filter((model) => model !== null).length);\n status('initializing...');\n await human.warmup(); // warmup function to initialize backend for future faster detection\n await webCam(); // start webcam\n await detectionLoop(); // start detection loop\n await drawLoop(); // start draw loop\n}\n\nwindow.onload = main;\n"], "mappings": ";;;;;;AASA,UAAYA,MAAO,0BAEnB,IAAMC,EAAiC,CAIrC,MAAO,GACP,cAAe,eACf,OAAQ,CAAE,QAAS,GAAM,aAAc,GAAO,KAAM,EAAM,EAC1D,KAAM,CAAE,QAAS,GAAM,SAAU,CAAE,SAAU,EAAM,EAAG,KAAM,CAAE,QAAS,EAAK,EAAG,UAAW,CAAE,QAAS,EAAM,EAAG,KAAM,CAAE,QAAS,EAAK,EAAG,YAAa,CAAE,QAAS,EAAK,EAAG,QAAS,CAAE,QAAS,EAAK,CAAE,EAClM,KAAM,CAAE,QAAS,EAAK,EACtB,KAAM,CAAE,QAAS,EAAK,EACtB,OAAQ,CAAE,QAAS,EAAM,EACzB,QAAS,CAAE,QAAS,EAAK,CAC3B,EAEMC,EAAQ,IAAM,QAAMD,CAAW,EAErCC,EAAM,IAAI,QAAU,GACpBA,EAAM,KAAK,QAAQ,KAAO,yBAC1BA,EAAM,KAAK,QAAQ,WAAa,GAGhC,IAAMC,EAAM,CACV,MAAO,SAAS,eAAe,OAAO,EACtC,OAAQ,SAA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I,OAAQmB,CAAY,EAC7Cb,EAAKa,EAAa,WAAW,CAC/B,CACA,IAAMC,EAAMrB,EAAM,IAAI,EACtBG,EAAI,QAAU,KAAK,MAAM,IAAO,KAAQkB,EAAMnB,EAAU,KAAK,EAAI,IACjEA,EAAU,KAAOmB,EACjBf,EAAOL,EAAI,MAAM,OAAS,SAAW,QAAQE,EAAI,UAAU,QAAQ,CAAC,EAAE,SAAS,EAAG,GAAG,cAAcA,EAAI,QAAQ,QAAQ,CAAC,EAAE,SAAS,EAAG,GAAG,QAAQ,EACjJ,WAAWgB,EAAU,EAAE,CACzB,CAEA,eAAeG,GAAO,CACpBlB,EAAI,iBAAkBJ,EAAM,QAAS,kBAAmBA,EAAM,GAAG,QAAQ,YAAY,EACrFI,EAAI,YAAaJ,EAAM,IAAI,SAAU,WAAYA,EAAM,IAAI,KAAK,EAChEM,EAAO,YAAY,EACnB,MAAMN,EAAM,KAAK,EACjBI,EAAI,WAAYJ,EAAM,GAAG,WAAW,EAAG,eAAgBA,EAAM,IAAI,QAAQ,EACzEI,EAAI,gBAAiBJ,EAAM,cAAc,CAAC,EAC1CI,EAAI,iBAAkB,OAAO,OAAOJ,EAAM,MAAM,EAAE,OAAQuB,GAAUA,IAAU,IAAI,EAAE,MAAM,EAC1FjB,EAAO,iBAAiB,EACxB,MAAMN,EAAM,OAAO,EACnB,MAAMQ,EAAO,EACb,MAAMS,EAAc,EACpB,MAAME,EAAS,CACjB,CAEA,OAAO,OAASG", "names": ["H", "humanConfig", "human", "dom", "timestamp", "fps", "log", "msg", "status", "perf", "webCam", "options", "stream", "ready", "resolve", "track", "capabilities", "settings", "constraints", "detectionLoop", "tensors", "drawLoop", "interpolated", "now", "main", "model"] } diff --git a/package.json b/package.json index 7ff1f240..d49f6d6a 100644 --- a/package.json +++ b/package.json @@ -78,26 +78,26 @@ "@tensorflow/tfjs-tflite": "0.0.1-alpha.8", "@types/node": "^18.7.13", "@types/offscreencanvas": "^2019.7.0", - "@typescript-eslint/eslint-plugin": "^5.34.0", - "@typescript-eslint/parser": "^5.34.0", - "@vladmandic/build": "^0.7.10", + "@typescript-eslint/eslint-plugin": "^5.35.1", + "@typescript-eslint/parser": "^5.35.1", + "@vladmandic/build": "^0.7.11", "@vladmandic/pilogger": "^0.4.6", "@vladmandic/tfjs": "github:vladmandic/tfjs", "@webgpu/types": "^0.1.21", "canvas": "^2.9.3", "esbuild": "^0.15.5", - "eslint": "8.22.0", + "eslint": "8.23.0", "eslint-config-airbnb-base": "^15.0.0", "eslint-plugin-html": "^7.1.0", "eslint-plugin-import": "^2.26.0", "eslint-plugin-json": "^3.1.0", "eslint-plugin-node": "^11.1.0", - "eslint-plugin-promise": "^6.0.0", + "eslint-plugin-promise": "^6.0.1", "node-fetch": "^3.2.10", "rimraf": "^3.0.2", "seedrandom": "^3.0.5", "tslib": "^2.4.0", - "typedoc": "0.23.10", - "typescript": "4.7.4" + "typedoc": "0.23.11", + "typescript": "4.8.2" } } diff --git a/test/build.log b/test/build.log index 4a2ab08f..9922205f 100644 --- a/test/build.log +++ b/test/build.log @@ -1,39 +1,39 @@ -2022-08-24 08:07:27 DATA:  Build {"name":"@vladmandic/human","version":"2.9.4"} -2022-08-24 08:07:27 INFO:  Application: {"name":"@vladmandic/human","version":"2.9.4"} -2022-08-24 08:07:27 INFO:  Environment: {"profile":"production","config":".build.json","package":"package.json","tsconfig":true,"eslintrc":true,"git":true} -2022-08-24 08:07:27 INFO:  Toolchain: {"build":"0.7.10","esbuild":"0.15.5","typescript":"4.7.4","typedoc":"0.23.10","eslint":"8.22.0"} -2022-08-24 08:07:27 INFO:  Build: {"profile":"production","steps":["clean","compile","typings","typedoc","lint","changelog"]} -2022-08-24 08:07:27 STATE: Clean: {"locations":["dist/*","types/lib/*","typedoc/*"]} -2022-08-24 08:07:27 STATE: Compile: {"name":"tfjs/nodejs/cpu","format":"cjs","platform":"node","input":"tfjs/tf-node.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":159,"outputBytes":608} -2022-08-24 08:07:27 STATE: Compile: {"name":"human/nodejs/cpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node.js","files":75,"inputBytes":653111,"outputBytes":306819} -2022-08-24 08:07:27 STATE: Compile: {"name":"tfjs/nodejs/gpu","format":"cjs","platform":"node","input":"tfjs/tf-node-gpu.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":167,"outputBytes":612} -2022-08-24 08:07:27 STATE: Compile: {"name":"human/nodejs/gpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-gpu.js","files":75,"inputBytes":653115,"outputBytes":306823} -2022-08-24 08:07:27 STATE: Compile: {"name":"tfjs/nodejs/wasm","format":"cjs","platform":"node","input":"tfjs/tf-node-wasm.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":206,"outputBytes":664} -2022-08-24 08:07:27 STATE: Compile: {"name":"human/nodejs/wasm","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-wasm.js","files":75,"inputBytes":653167,"outputBytes":306873} -2022-08-24 08:07:27 STATE: Compile: {"name":"tfjs/browser/version","format":"esm","platform":"browser","input":"tfjs/tf-version.ts","output":"dist/tfjs.version.js","files":1,"inputBytes":1125,"outputBytes":358} -2022-08-24 08:07:27 STATE: Compile: {"name":"tfjs/browser/esm/nobundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":1088,"outputBytes":583} -2022-08-24 08:07:27 STATE: Compile: {"name":"human/browser/esm/nobundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm-nobundle.js","files":75,"inputBytes":653086,"outputBytes":305692} -2022-08-24 08:07:28 STATE: Compile: {"name":"tfjs/browser/esm/custom","format":"esm","platform":"browser","input":"tfjs/tf-custom.ts","output":"dist/tfjs.esm.js","files":11,"inputBytes":1344,"outputBytes":2879073} -2022-08-24 08:07:28 STATE: Compile: {"name":"human/browser/iife/bundle","format":"iife","platform":"browser","input":"src/human.ts","output":"dist/human.js","files":75,"inputBytes":3531576,"outputBytes":1706402} -2022-08-24 08:07:28 STATE: Compile: {"name":"human/browser/esm/bundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm.js","files":75,"inputBytes":3531576,"outputBytes":3154419} -2022-08-24 08:07:33 STATE: Typings: {"input":"src/human.ts","output":"types/lib","files":30} -2022-08-24 08:07:35 STATE: TypeDoc: {"input":"src/human.ts","output":"typedoc","objects":77,"generated":true} -2022-08-24 08:07:35 STATE: Compile: {"name":"demo/typescript","format":"esm","platform":"browser","input":"demo/typescript/index.ts","output":"demo/typescript/index.js","files":1,"inputBytes":6714,"outputBytes":3134} -2022-08-24 08:07:35 STATE: Compile: {"name":"demo/faceid","format":"esm","platform":"browser","input":"demo/faceid/index.ts","output":"demo/faceid/index.js","files":2,"inputBytes":15501,"outputBytes":7733} -2022-08-24 08:07:46 STATE: Lint: {"locations":["*.json","src/**/*.ts","test/**/*.js","demo/**/*.js"],"files":111,"errors":0,"warnings":0} -2022-08-24 08:07:47 STATE: ChangeLog: {"repository":"https://github.com/vladmandic/human","branch":"main","output":"CHANGELOG.md"} -2022-08-24 08:07:47 STATE: Copy: {"input":"tfjs/tfjs.esm.d.ts"} -2022-08-24 08:07:47 INFO:  Done... -2022-08-24 08:07:47 STATE: API-Extractor: {"succeeeded":true,"errors":0,"warnings":198} -2022-08-24 08:07:47 STATE: Copy: {"input":"types/human.d.ts"} -2022-08-24 08:07:47 INFO:  Analyze models: {"folders":8,"result":"models/models.json"} -2022-08-24 08:07:47 STATE: Models {"folder":"./models","models":13} -2022-08-24 08:07:47 STATE: Models {"folder":"../human-models/models","models":42} -2022-08-24 08:07:47 STATE: Models {"folder":"../blazepose/model/","models":4} -2022-08-24 08:07:47 STATE: Models {"folder":"../anti-spoofing/model","models":1} -2022-08-24 08:07:47 STATE: Models {"folder":"../efficientpose/models","models":3} -2022-08-24 08:07:47 STATE: Models {"folder":"../insightface/models","models":5} -2022-08-24 08:07:47 STATE: Models {"folder":"../movenet/models","models":3} -2022-08-24 08:07:47 STATE: Models {"folder":"../nanodet/models","models":4} -2022-08-24 08:07:48 STATE: Models: {"count":57,"totalSize":383017442} -2022-08-24 08:07:48 INFO:  Human Build complete... {"logFile":"test/build.log"} +2022-08-28 13:08:21 DATA:  Build {"name":"@vladmandic/human","version":"2.9.4"} +2022-08-28 13:08:21 INFO:  Application: {"name":"@vladmandic/human","version":"2.9.4"} +2022-08-28 13:08:21 INFO:  Environment: {"profile":"production","config":".build.json","package":"package.json","tsconfig":true,"eslintrc":true,"git":true} +2022-08-28 13:08:21 INFO:  Toolchain: {"build":"0.7.11","esbuild":"0.15.5","typescript":"4.8.2","typedoc":"0.23.11","eslint":"8.23.0"} +2022-08-28 13:08:21 INFO:  Build: {"profile":"production","steps":["clean","compile","typings","typedoc","lint","changelog"]} +2022-08-28 13:08:21 STATE: Clean: {"locations":["dist/*","types/lib/*","typedoc/*"]} +2022-08-28 13:08:21 STATE: Compile: {"name":"tfjs/nodejs/cpu","format":"cjs","platform":"node","input":"tfjs/tf-node.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":159,"outputBytes":608} +2022-08-28 13:08:21 STATE: Compile: {"name":"human/nodejs/cpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node.js","files":75,"inputBytes":653111,"outputBytes":306819} +2022-08-28 13:08:21 STATE: Compile: {"name":"tfjs/nodejs/gpu","format":"cjs","platform":"node","input":"tfjs/tf-node-gpu.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":167,"outputBytes":612} +2022-08-28 13:08:21 STATE: Compile: {"name":"human/nodejs/gpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-gpu.js","files":75,"inputBytes":653115,"outputBytes":306823} +2022-08-28 13:08:21 STATE: Compile: {"name":"tfjs/nodejs/wasm","format":"cjs","platform":"node","input":"tfjs/tf-node-wasm.ts","output":"dist/tfjs.esm.js","files":1,"inputBytes":206,"outputBytes":664} +2022-08-28 13:08:21 STATE: Compile: {"name":"human/nodejs/wasm","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-wasm.js","files":75,"inputBytes":653167,"outputBytes":306873} +2022-08-28 13:08:21 STATE: Compile: {"name":"tfjs/browser/version","format":"esm","platform":"browser","input":"tfjs/tf-version.ts","output":"dist/tfjs.version.js","files":1,"inputBytes":1125,"outputBytes":358} +2022-08-28 13:08:21 STATE: Compile: {"name":"tfjs/browser/esm/nobundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":1088,"outputBytes":583} +2022-08-28 13:08:21 STATE: Compile: {"name":"human/browser/esm/nobundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm-nobundle.js","files":75,"inputBytes":653086,"outputBytes":305692} +2022-08-28 13:08:21 STATE: Compile: {"name":"tfjs/browser/esm/custom","format":"esm","platform":"browser","input":"tfjs/tf-custom.ts","output":"dist/tfjs.esm.js","files":11,"inputBytes":1344,"outputBytes":2879073} +2022-08-28 13:08:21 STATE: Compile: {"name":"human/browser/iife/bundle","format":"iife","platform":"browser","input":"src/human.ts","output":"dist/human.js","files":75,"inputBytes":3531576,"outputBytes":1706402} +2022-08-28 13:08:21 STATE: Compile: {"name":"human/browser/esm/bundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm.js","files":75,"inputBytes":3531576,"outputBytes":3154419} +2022-08-28 13:08:26 STATE: Typings: {"input":"src/human.ts","output":"types/lib","files":30} +2022-08-28 13:08:27 STATE: TypeDoc: {"input":"src/human.ts","output":"typedoc","objects":77,"generated":true} +2022-08-28 13:08:27 STATE: Compile: {"name":"demo/typescript","format":"esm","platform":"browser","input":"demo/typescript/index.ts","output":"demo/typescript/index.js","files":1,"inputBytes":6714,"outputBytes":3134} +2022-08-28 13:08:27 STATE: Compile: {"name":"demo/faceid","format":"esm","platform":"browser","input":"demo/faceid/index.ts","output":"demo/faceid/index.js","files":2,"inputBytes":15488,"outputBytes":7788} +2022-08-28 13:08:38 STATE: Lint: {"locations":["*.json","src/**/*.ts","test/**/*.js","demo/**/*.js"],"files":111,"errors":0,"warnings":0} +2022-08-28 13:08:38 STATE: ChangeLog: {"repository":"https://github.com/vladmandic/human","branch":"main","output":"CHANGELOG.md"} +2022-08-28 13:08:38 STATE: Copy: {"input":"tfjs/tfjs.esm.d.ts"} +2022-08-28 13:08:38 INFO:  Done... +2022-08-28 13:08:39 STATE: API-Extractor: {"succeeeded":true,"errors":0,"warnings":198} +2022-08-28 13:08:39 STATE: Copy: {"input":"types/human.d.ts"} +2022-08-28 13:08:39 INFO:  Analyze models: {"folders":8,"result":"models/models.json"} +2022-08-28 13:08:39 STATE: Models {"folder":"./models","models":13} +2022-08-28 13:08:39 STATE: Models {"folder":"../human-models/models","models":42} +2022-08-28 13:08:39 STATE: Models {"folder":"../blazepose/model/","models":4} +2022-08-28 13:08:39 STATE: Models {"folder":"../anti-spoofing/model","models":1} +2022-08-28 13:08:39 STATE: Models {"folder":"../efficientpose/models","models":3} +2022-08-28 13:08:39 STATE: Models {"folder":"../insightface/models","models":5} +2022-08-28 13:08:39 STATE: Models {"folder":"../movenet/models","models":3} +2022-08-28 13:08:39 STATE: Models {"folder":"../nanodet/models","models":4} +2022-08-28 13:08:40 STATE: Models: {"count":57,"totalSize":383017442} +2022-08-28 13:08:40 INFO:  Human Build complete... {"logFile":"test/build.log"} diff --git a/test/test.log b/test/test.log index d328348a..7913cbbd 100644 --- a/test/test.log +++ b/test/test.log @@ -1,976 +1,976 @@ -2022-08-24 08:09:14 INFO:  @vladmandic/human version 2.9.4 -2022-08-24 08:09:14 INFO:  User: vlado Platform: linux Arch: x64 Node: v18.1.0 -2022-08-24 08:09:14 INFO:  demos: [{"cmd":"../demo/nodejs/node.js","args":[]},{"cmd":"../demo/nodejs/node-simple.js","args":[]},{"cmd":"../demo/nodejs/node-fetch.js","args":[]},{"cmd":"../demo/nodejs/node-event.js","args":["samples/in/ai-body.jpg"]},{"cmd":"../demo/nodejs/node-similarity.js","args":["samples/in/ai-face.jpg","samples/in/ai-upper.jpg"]},{"cmd":"../demo/nodejs/node-canvas.js","args":["samples/in/ai-body.jpg","samples/out/ai-body.jpg"]},{"cmd":"../demo/multithread/node-multiprocess.js","args":[]},{"cmd":"../demo/facematch/node-match.js","args":[]}] -2022-08-24 08:09:14 INFO:  {"cmd":"../demo/nodejs/node.js","args":[]} start -2022-08-24 08:09:15 INFO:  {"cmd":"../demo/nodejs/node-simple.js","args":[]} start -2022-08-24 08:09:15 INFO:  {"cmd":"../demo/nodejs/node-fetch.js","args":[]} start -2022-08-24 08:09:18 INFO:  {"cmd":"../demo/nodejs/node-event.js","args":["samples/in/ai-body.jpg"]} start -2022-08-24 08:09:18 INFO:  {"cmd":"../demo/nodejs/node-similarity.js","args":["samples/in/ai-face.jpg","samples/in/ai-upper.jpg"]} start -2022-08-24 08:09:19 INFO:  {"cmd":"../demo/nodejs/node-canvas.js","args":["samples/in/ai-body.jpg","samples/out/ai-body.jpg"]} start -2022-08-24 08:09:19 INFO:  {"cmd":"../demo/multithread/node-multiprocess.js","args":[]} start -2022-08-24 08:09:20 INFO:  {"cmd":"../demo/facematch/node-match.js","args":[]} start -2022-08-24 08:09:22 INFO:  tests: ["test-node.js","test-node-gpu.js","test-node-wasm.js"] -2022-08-24 08:09:22 INFO:  -2022-08-24 08:09:22 INFO:  test-node.js start -2022-08-24 08:09:23 INFO:  test-node.js test: configuration validation -2022-08-24 08:09:23 STATE: test-node.js passed: configuration default validation [] -2022-08-24 08:09:23 STATE: test-node.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] -2022-08-24 08:09:23 INFO:  test-node.js test: model load -2022-08-24 08:09:23 STATE: test-node.js passed: models loaded 23 12 [{"name":"ssrnetage","loaded":false,"url":null},{"name":"gear","loaded":false,"url":null},{"name":"blazeposedetect","loaded":false,"url":null},{"name":"blazepose","loaded":false,"url":null},{"name":"centernet","loaded":true,"url":"file://models/mb3-centernet.json"},{"name":"efficientpose","loaded":false,"url":null},{"name":"mobilefacenet","loaded":false,"url":null},{"name":"insightface","loaded":false,"url":null},{"name":"emotion","loaded":true,"url":"file://models/emotion.json"},{"name":"facedetect","loaded":true,"url":"file://models/blazeface.json"},{"name":"faceiris","loaded":true,"url":"file://models/iris.json"},{"name":"facemesh","loaded":true,"url":"file://models/facemesh.json"},{"name":"faceres","loaded":true,"url":"file://models/faceres.json"},{"name":"ssrnetgender","loaded":false,"url":null},{"name":"handpose","loaded":false,"url":null},{"name":"handskeleton","loaded":true,"url":"file://models/handlandmark-full.json"},{"name":"handtrack","loaded":true,"url":"file://models/handtrack.json"},{"name":"liveness","loaded":true,"url":"file://models/liveness.json"},{"name":"movenet","loaded":true,"url":"file://models/movenet-lightning.json"},{"name":"nanodet","loaded":false,"url":null},{"name":"posenet","loaded":false,"url":null},{"name":"segmentation","loaded":true,"url":"file://models/selfie.json"},{"name":"antispoof","loaded":true,"url":"file://models/antispoof.json"}] -2022-08-24 08:09:23 INFO:  test-node.js memory: {"memory":{"unreliable":true,"numTensors":1921,"numDataBuffers":1921,"numBytes":63673064}} -2022-08-24 08:09:23 INFO:  test-node.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":63673064,"numTensors":1921,"numStringTensors":0,"numDataBuffers":1921,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} -2022-08-24 08:09:23 INFO:  test-node.js test: warmup -2022-08-24 08:09:23 STATE: test-node.js passed: create human -2022-08-24 08:09:23 INFO:  test-node.js human version: 2.9.4 -2022-08-24 08:09:23 INFO:  test-node.js platform: linux x64 agent: NodeJS v18.1.0 -2022-08-24 08:09:23 INFO:  test-node.js tfjs version: 3.20.0 -2022-08-24 08:09:23 INFO:  test-node.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v18.1.0","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"3.20.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.7.3-dev20220521","gpu":false},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":169} -2022-08-24 08:09:23 STATE: test-node.js passed: set backend: tensorflow -2022-08-24 08:09:23 STATE: test-node.js tensors 1921 -2022-08-24 08:09:23 STATE: test-node.js passed: load models -2022-08-24 08:09:23 STATE: test-node.js result: defined models: 23 loaded models: 12 -2022-08-24 08:09:23 STATE: test-node.js passed: warmup: none default -2022-08-24 08:09:23 DATA:  test-node.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} -2022-08-24 08:09:23 DATA:  test-node.js result: performance: load: null total: null -2022-08-24 08:09:23 STATE: test-node.js passed: warmup none result match -2022-08-24 08:09:23 STATE: test-node.js event: image -2022-08-24 08:09:23 STATE: test-node.js event: detect -2022-08-24 08:09:23 STATE: test-node.js event: warmup -2022-08-24 08:09:23 STATE: test-node.js passed: warmup: face default -2022-08-24 08:09:23 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.42,"keypoints":4} -2022-08-24 08:09:23 DATA:  test-node.js result: performance: load: null total: 364 -2022-08-24 08:09:23 STATE: test-node.js passed: warmup face result match -2022-08-24 08:09:23 STATE: test-node.js event: image -2022-08-24 08:09:23 STATE: test-node.js event: detect -2022-08-24 08:09:23 STATE: test-node.js event: warmup -2022-08-24 08:09:23 STATE: test-node.js passed: warmup: body default -2022-08-24 08:09:23 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:23 DATA:  test-node.js result: performance: load: null total: 243 -2022-08-24 08:09:23 STATE: test-node.js passed: warmup body result match -2022-08-24 08:09:23 STATE: test-node.js details: {"face":{"boxScore":0.92,"faceScore":1,"age":23.7,"gender":"female","genderScore":0.97},"emotion":[{"score":0.63,"emotion":"angry"},{"score":0.22,"emotion":"fear"}],"body":{"score":0.92,"keypoints":17},"hand":{"boxScore":0.52,"fingerScore":0.73,"keypoints":21},"gestures":[{"face":0,"gesture":"facing right"},{"face":0,"gesture":"mouth 10% open"},{"hand":0,"gesture":"pinky forward"},{"hand":0,"gesture":"palm up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} -2022-08-24 08:09:23 INFO:  test-node.js test: details verification -2022-08-24 08:09:23 STATE: test-node.js start default -2022-08-24 08:09:23 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:23 STATE: test-node.js event: image -2022-08-24 08:09:24 STATE: test-node.js event: detect -2022-08-24 08:09:24 STATE: test-node.js passed: detect: samples/in/ai-body.jpg default -2022-08-24 08:09:24 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:24 DATA:  test-node.js result: performance: load: null total: 232 -2022-08-24 08:09:24 STATE: test-node.js passed: details face length 1 -2022-08-24 08:09:24 STATE: test-node.js passed: details face score 1 0.93 1 -2022-08-24 08:09:24 STATE: test-node.js passed: details face age/gender 23.7 female 0.97 85.47 -2022-08-24 08:09:24 STATE: test-node.js passed: details face arrays 4 478 1024 -2022-08-24 08:09:24 STATE: test-node.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} -2022-08-24 08:09:24 STATE: test-node.js passed: details face anti-spoofing 0.79 -2022-08-24 08:09:24 STATE: test-node.js passed: details face liveness 0.83 -2022-08-24 08:09:24 STATE: test-node.js passed: details body length 1 -2022-08-24 08:09:24 STATE: test-node.js passed: details body 0.92 17 6 -2022-08-24 08:09:24 STATE: test-node.js passed: details hand length 1 -2022-08-24 08:09:24 STATE: test-node.js passed: details hand 0.51 0.73 point -2022-08-24 08:09:24 STATE: test-node.js passed: details hand arrays 21 5 7 -2022-08-24 08:09:24 STATE: test-node.js passed: details gesture length 7 -2022-08-24 08:09:24 STATE: test-node.js passed: details gesture first {"face":0,"gesture":"facing right"} -2022-08-24 08:09:24 STATE: test-node.js passed: details object length 1 -2022-08-24 08:09:24 STATE: test-node.js passed: details object 0.72 person -2022-08-24 08:09:24 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996928} -2022-08-24 08:09:24 STATE: test-node.js event: image -2022-08-24 08:09:24 STATE: test-node.js event: detect -2022-08-24 08:09:24 STATE: test-node.js passed: tensor shape: [1,1200,1200,4] dtype: float32 -2022-08-24 08:09:24 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996928} -2022-08-24 08:09:24 STATE: test-node.js event: image -2022-08-24 08:09:24 STATE: test-node.js event: detect -2022-08-24 08:09:24 STATE: test-node.js passed: tensor shape: [1200,1200,4] dtype: float32 -2022-08-24 08:09:25 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:25 STATE: test-node.js event: image -2022-08-24 08:09:25 STATE: test-node.js event: detect -2022-08-24 08:09:25 STATE: test-node.js passed: tensor shape: [1,1200,1200,3] dtype: float32 -2022-08-24 08:09:25 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:25 STATE: test-node.js event: image -2022-08-24 08:09:25 STATE: test-node.js event: detect -2022-08-24 08:09:25 STATE: test-node.js passed: tensor shape: [1200,1200,3] dtype: float32 -2022-08-24 08:09:25 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} -2022-08-24 08:09:25 STATE: test-node.js event: image -2022-08-24 08:09:26 STATE: test-node.js event: detect -2022-08-24 08:09:26 STATE: test-node.js passed: tensor shape: [1,1200,1200,4] dtype: int32 -2022-08-24 08:09:26 INFO:  test-node.js test default -2022-08-24 08:09:26 STATE: test-node.js start async -2022-08-24 08:09:26 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:26 STATE: test-node.js event: image -2022-08-24 08:09:26 STATE: test-node.js event: detect -2022-08-24 08:09:26 STATE: test-node.js passed: detect: samples/in/ai-body.jpg async -2022-08-24 08:09:26 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:26 DATA:  test-node.js result: performance: load: null total: 212 -2022-08-24 08:09:26 STATE: test-node.js passed: default result face match 1 female 0.97 -2022-08-24 08:09:26 INFO:  test-node.js test sync -2022-08-24 08:09:26 STATE: test-node.js start sync -2022-08-24 08:09:26 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:26 STATE: test-node.js event: image -2022-08-24 08:09:26 STATE: test-node.js event: detect -2022-08-24 08:09:26 STATE: test-node.js passed: detect: samples/in/ai-body.jpg sync -2022-08-24 08:09:26 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:26 DATA:  test-node.js result: performance: load: null total: 203 -2022-08-24 08:09:26 STATE: test-node.js passed: default sync 1 female 0.97 -2022-08-24 08:09:26 INFO:  test-node.js test: image process -2022-08-24 08:09:26 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:26 STATE: test-node.js passed: image input null [1,256,256,3] -2022-08-24 08:09:26 INFO:  test-node.js test: image null -2022-08-24 08:09:26 STATE: test-node.js passed: invalid input could not convert input to tensor -2022-08-24 08:09:26 INFO:  test-node.js test face similarity -2022-08-24 08:09:26 STATE: test-node.js start face similarity -2022-08-24 08:09:26 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:26 STATE: test-node.js event: image -2022-08-24 08:09:27 STATE: test-node.js event: detect -2022-08-24 08:09:27 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face similarity -2022-08-24 08:09:27 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} -2022-08-24 08:09:27 DATA:  test-node.js result: performance: load: null total: 203 -2022-08-24 08:09:27 STATE: test-node.js start face similarity -2022-08-24 08:09:27 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:27 STATE: test-node.js event: image -2022-08-24 08:09:27 STATE: test-node.js event: detect -2022-08-24 08:09:27 STATE: test-node.js passed: detect: samples/in/ai-body.jpg face similarity -2022-08-24 08:09:27 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:27 DATA:  test-node.js result: performance: load: null total: 213 -2022-08-24 08:09:27 STATE: test-node.js start face similarity -2022-08-24 08:09:27 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} -2022-08-24 08:09:27 STATE: test-node.js event: image -2022-08-24 08:09:27 STATE: test-node.js event: detect -2022-08-24 08:09:27 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg face similarity -2022-08-24 08:09:27 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 4 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.71,"class":"person"} {"score":0.75,"keypoints":7} -2022-08-24 08:09:27 DATA:  test-node.js result: performance: load: null total: 185 -2022-08-24 08:09:27 STATE: test-node.js passed: face descriptor -2022-08-24 08:09:27 STATE: test-node.js passed: face similarity {"similarity":[1,0.44727452329649126,0.5567935850640406],"descriptors":[1024,1024,1024]} -2022-08-24 08:09:27 INFO:  test-node.js test object -2022-08-24 08:09:27 STATE: test-node.js start object -2022-08-24 08:09:27 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:27 STATE: test-node.js event: image -2022-08-24 08:09:28 STATE: test-node.js event: detect -2022-08-24 08:09:28 STATE: test-node.js passed: detect: samples/in/ai-body.jpg object -2022-08-24 08:09:28 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:28 DATA:  test-node.js result: performance: load: null total: 210 -2022-08-24 08:09:28 STATE: test-node.js passed: centernet -2022-08-24 08:09:28 STATE: test-node.js start object -2022-08-24 08:09:30 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:30 STATE: test-node.js event: image -2022-08-24 08:09:30 STATE: test-node.js event: detect -2022-08-24 08:09:30 STATE: test-node.js passed: detect: samples/in/ai-body.jpg object -2022-08-24 08:09:30 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 3 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.86,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:30 DATA:  test-node.js result: performance: load: null total: 213 -2022-08-24 08:09:30 STATE: test-node.js passed: nanodet -2022-08-24 08:09:30 INFO:  test-node.js test sensitive -2022-08-24 08:09:30 STATE: test-node.js start sensitive -2022-08-24 08:09:30 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:30 STATE: test-node.js event: image -2022-08-24 08:09:30 STATE: test-node.js event: detect -2022-08-24 08:09:30 STATE: test-node.js passed: detect: samples/in/ai-body.jpg sensitive -2022-08-24 08:09:30 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:30 DATA:  test-node.js result: performance: load: null total: 167 -2022-08-24 08:09:30 STATE: test-node.js passed: sensitive result match -2022-08-24 08:09:30 STATE: test-node.js passed: sensitive face result match -2022-08-24 08:09:30 STATE: test-node.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] -2022-08-24 08:09:30 STATE: test-node.js passed: sensitive body result match -2022-08-24 08:09:30 STATE: test-node.js passed: sensitive hand result match -2022-08-24 08:09:30 INFO:  test-node.js test body -2022-08-24 08:09:30 STATE: test-node.js start blazepose -2022-08-24 08:09:34 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:34 STATE: test-node.js event: image -2022-08-24 08:09:35 STATE: test-node.js event: detect -2022-08-24 08:09:35 STATE: test-node.js passed: detect: samples/in/ai-body.jpg blazepose -2022-08-24 08:09:35 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.99,"keypoints":39} -2022-08-24 08:09:35 DATA:  test-node.js result: performance: load: null total: 218 -2022-08-24 08:09:35 STATE: test-node.js passed: blazepose -2022-08-24 08:09:35 STATE: test-node.js start efficientpose -2022-08-24 08:09:36 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:36 STATE: test-node.js event: image -2022-08-24 08:09:36 STATE: test-node.js event: detect -2022-08-24 08:09:36 STATE: test-node.js passed: detect: samples/in/ai-body.jpg efficientpose -2022-08-24 08:09:36 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.75,"keypoints":13} -2022-08-24 08:09:36 DATA:  test-node.js result: performance: load: null total: 242 -2022-08-24 08:09:36 STATE: test-node.js passed: efficientpose -2022-08-24 08:09:36 STATE: test-node.js start posenet -2022-08-24 08:09:37 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:37 STATE: test-node.js event: image -2022-08-24 08:09:37 STATE: test-node.js event: detect -2022-08-24 08:09:37 STATE: test-node.js passed: detect: samples/in/ai-body.jpg posenet -2022-08-24 08:09:37 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.96,"keypoints":16} -2022-08-24 08:09:37 DATA:  test-node.js result: performance: load: null total: 172 -2022-08-24 08:09:37 STATE: test-node.js passed: posenet -2022-08-24 08:09:37 STATE: test-node.js start movenet -2022-08-24 08:09:37 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:37 STATE: test-node.js event: image -2022-08-24 08:09:38 STATE: test-node.js event: detect -2022-08-24 08:09:38 STATE: test-node.js passed: detect: samples/in/ai-body.jpg movenet -2022-08-24 08:09:38 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:38 DATA:  test-node.js result: performance: load: null total: 179 -2022-08-24 08:09:38 STATE: test-node.js passed: movenet -2022-08-24 08:09:38 INFO:  test-node.js test face matching -2022-08-24 08:09:38 STATE: test-node.js passed: face database 40 -2022-08-24 08:09:38 STATE: test-node.js passed: face match {"first":{"index":4,"similarity":0.7827852615252829}} {"second":{"index":4,"similarity":0.5002052633015844}} {"third":{"index":4,"similarity":0.5401587887998899}} -2022-08-24 08:09:38 INFO:  test-node.js test face similarity alternative -2022-08-24 08:09:38 STATE: test-node.js start face embeddings -2022-08-24 08:09:38 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:38 STATE: test-node.js event: image -2022-08-24 08:09:39 STATE: test-node.js event: detect -2022-08-24 08:09:39 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face embeddings -2022-08-24 08:09:39 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:39 DATA:  test-node.js result: performance: load: null total: 186 -2022-08-24 08:09:39 STATE: test-node.js passed: mobilefacenet {"embedding":192} -2022-08-24 08:09:39 STATE: test-node.js start face embeddings -2022-08-24 08:09:40 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:40 STATE: test-node.js event: image -2022-08-24 08:09:40 STATE: test-node.js event: detect -2022-08-24 08:09:40 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face embeddings -2022-08-24 08:09:40 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:40 DATA:  test-node.js result: performance: load: null total: 192 -2022-08-24 08:09:40 STATE: test-node.js passed: insightface {"embedding":512} -2022-08-24 08:09:40 INFO:  test-node.js test face attention -2022-08-24 08:09:40 STATE: test-node.js start face attention -2022-08-24 08:09:41 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:41 STATE: test-node.js event: image -2022-08-24 08:09:41 STATE: test-node.js event: detect -2022-08-24 08:09:41 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face attention -2022-08-24 08:09:41 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:41 DATA:  test-node.js result: performance: load: null total: 175 -2022-08-24 08:09:41 STATE: test-node.js passed: face attention -2022-08-24 08:09:41 INFO:  test-node.js test detectors -2022-08-24 08:09:41 STATE: test-node.js start detectors -2022-08-24 08:09:41 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:41 STATE: test-node.js event: image -2022-08-24 08:09:41 STATE: test-node.js event: detect -2022-08-24 08:09:41 STATE: test-node.js passed: detect: samples/in/ai-body.jpg detectors -2022-08-24 08:09:41 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:41 DATA:  test-node.js result: performance: load: null total: 83 -2022-08-24 08:09:41 STATE: test-node.js passed: detector result face match -2022-08-24 08:09:41 STATE: test-node.js passed: detector result hand match -2022-08-24 08:09:41 INFO:  test-node.js test: multi-instance -2022-08-24 08:09:41 STATE: test-node.js start multi instance -2022-08-24 08:09:41 STATE: test-node.js event: image -2022-08-24 08:09:42 STATE: test-node.js event: detect -2022-08-24 08:09:42 STATE: test-node.js passed: detect: random multi instance -2022-08-24 08:09:42 DATA:  test-node.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} -2022-08-24 08:09:42 DATA:  test-node.js result: performance: load: null total: 80 -2022-08-24 08:09:42 INFO:  test-node.js test: first instance -2022-08-24 08:09:42 STATE: test-node.js start multi instance -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} -2022-08-24 08:09:42 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg multi instance -2022-08-24 08:09:42 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:09:42 DATA:  test-node.js result: performance: load: null total: 85 -2022-08-24 08:09:42 INFO:  test-node.js test: second instance -2022-08-24 08:09:42 STATE: test-node.js start multi instance -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} -2022-08-24 08:09:42 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg multi instance -2022-08-24 08:09:42 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:09:42 DATA:  test-node.js result: performance: load: null total: 85 -2022-08-24 08:09:42 INFO:  test-node.js test: concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js start concurrent -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:42 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:43 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} -2022-08-24 08:09:43 STATE: test-node.js event: image -2022-08-24 08:09:43 STATE: test-node.js event: image -2022-08-24 08:09:43 STATE: test-node.js event: image -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 963 -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 963 -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 963 -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 963 -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 963 -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 963 -2022-08-24 08:09:43 STATE: test-node.js event: detect -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 698 -2022-08-24 08:09:43 STATE: test-node.js event: detect -2022-08-24 08:09:43 STATE: test-node.js event: detect -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 698 -2022-08-24 08:09:43 STATE: test-node.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:09:43 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:43 DATA:  test-node.js result: performance: load: null total: 698 -2022-08-24 08:09:43 INFO:  test-node.js test: monkey-patch -2022-08-24 08:09:43 STATE: test-node.js event: image -2022-08-24 08:09:43 STATE: test-node.js event: detect -2022-08-24 08:09:43 STATE: test-node.js passed: monkey patch -2022-08-24 08:09:43 STATE: test-node.js passed: segmentation [65536] -2022-08-24 08:09:43 STATE: test-node.js passeed: equal usage -2022-08-24 08:09:43 INFO:  test-node.js test: input compare -2022-08-24 08:09:43 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:44 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2022-08-24 08:09:44 STATE: test-node.js passed: image compare 0 23.275441687091504 -2022-08-24 08:09:44 INFO:  test-node.js events: {"image":29,"detect":29,"warmup":2} -2022-08-24 08:09:44 INFO:  test-node.js tensors 4105 -2022-08-24 08:09:44 INFO:  test-node.js test complete: 21025 ms -2022-08-24 08:09:44 INFO:  -2022-08-24 08:09:44 INFO:  test-node-gpu.js start -2022-08-24 08:09:45 INFO:  test-node-gpu.js test: configuration validation -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: configuration default validation [] -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] -2022-08-24 08:09:45 INFO:  test-node-gpu.js test: model load -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: models loaded 23 12 [{"name":"ssrnetage","loaded":false,"url":null},{"name":"gear","loaded":false,"url":null},{"name":"blazeposedetect","loaded":false,"url":null},{"name":"blazepose","loaded":false,"url":null},{"name":"centernet","loaded":true,"url":"file://models/mb3-centernet.json"},{"name":"efficientpose","loaded":false,"url":null},{"name":"mobilefacenet","loaded":false,"url":null},{"name":"insightface","loaded":false,"url":null},{"name":"emotion","loaded":true,"url":"file://models/emotion.json"},{"name":"facedetect","loaded":true,"url":"file://models/blazeface.json"},{"name":"faceiris","loaded":true,"url":"file://models/iris.json"},{"name":"facemesh","loaded":true,"url":"file://models/facemesh.json"},{"name":"faceres","loaded":true,"url":"file://models/faceres.json"},{"name":"ssrnetgender","loaded":false,"url":null},{"name":"handpose","loaded":false,"url":null},{"name":"handskeleton","loaded":true,"url":"file://models/handlandmark-full.json"},{"name":"handtrack","loaded":true,"url":"file://models/handtrack.json"},{"name":"liveness","loaded":true,"url":"file://models/liveness.json"},{"name":"movenet","loaded":true,"url":"file://models/movenet-lightning.json"},{"name":"nanodet","loaded":false,"url":null},{"name":"posenet","loaded":false,"url":null},{"name":"segmentation","loaded":true,"url":"file://models/selfie.json"},{"name":"antispoof","loaded":true,"url":"file://models/antispoof.json"}] -2022-08-24 08:09:45 INFO:  test-node-gpu.js memory: {"memory":{"unreliable":true,"numTensors":1921,"numDataBuffers":1921,"numBytes":63673064}} -2022-08-24 08:09:45 INFO:  test-node-gpu.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":63673064,"numTensors":1921,"numStringTensors":0,"numDataBuffers":1921,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} -2022-08-24 08:09:45 INFO:  test-node-gpu.js test: warmup -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: create human -2022-08-24 08:09:45 INFO:  test-node-gpu.js human version: 2.9.4 -2022-08-24 08:09:45 INFO:  test-node-gpu.js platform: linux x64 agent: NodeJS v18.1.0 -2022-08-24 08:09:45 INFO:  test-node-gpu.js tfjs version: 3.20.0 -2022-08-24 08:09:45 INFO:  test-node-gpu.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v18.1.0","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"3.20.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.7.3-dev20220521","gpu":true},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":169} -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: set backend: tensorflow -2022-08-24 08:09:45 STATE: test-node-gpu.js tensors 1921 -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: load models -2022-08-24 08:09:45 STATE: test-node-gpu.js result: defined models: 23 loaded models: 12 -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: warmup: none default -2022-08-24 08:09:45 DATA:  test-node-gpu.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} -2022-08-24 08:09:45 DATA:  test-node-gpu.js result: performance: load: null total: null -2022-08-24 08:09:45 STATE: test-node-gpu.js passed: warmup none result match -2022-08-24 08:09:45 STATE: test-node-gpu.js event: image -2022-08-24 08:09:49 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:49 STATE: test-node-gpu.js event: warmup -2022-08-24 08:09:49 STATE: test-node-gpu.js passed: warmup: face default -2022-08-24 08:09:49 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.42,"keypoints":4} -2022-08-24 08:09:49 DATA:  test-node-gpu.js result: performance: load: null total: 4201 -2022-08-24 08:09:49 STATE: test-node-gpu.js passed: warmup face result match -2022-08-24 08:09:49 STATE: test-node-gpu.js event: image -2022-08-24 08:09:49 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:49 STATE: test-node-gpu.js event: warmup -2022-08-24 08:09:49 STATE: test-node-gpu.js passed: warmup: body default -2022-08-24 08:09:49 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:49 DATA:  test-node-gpu.js result: performance: load: null total: 144 -2022-08-24 08:09:49 STATE: test-node-gpu.js passed: warmup body result match -2022-08-24 08:09:49 STATE: test-node-gpu.js details: {"face":{"boxScore":0.92,"faceScore":1,"age":23.7,"gender":"female","genderScore":0.97},"emotion":[{"score":0.63,"emotion":"angry"},{"score":0.22,"emotion":"fear"}],"body":{"score":0.92,"keypoints":17},"hand":{"boxScore":0.52,"fingerScore":0.73,"keypoints":21},"gestures":[{"face":0,"gesture":"facing right"},{"face":0,"gesture":"mouth 10% open"},{"hand":0,"gesture":"pinky forward"},{"hand":0,"gesture":"palm up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} -2022-08-24 08:09:49 INFO:  test-node-gpu.js test: details verification -2022-08-24 08:09:49 STATE: test-node-gpu.js start default -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:50 STATE: test-node-gpu.js event: image -2022-08-24 08:09:50 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg default -2022-08-24 08:09:50 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:50 DATA:  test-node-gpu.js result: performance: load: null total: 138 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face length 1 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face score 1 0.93 1 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face age/gender 23.7 female 0.97 85.47 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face arrays 4 478 1024 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face anti-spoofing 0.79 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details face liveness 0.83 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details body length 1 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details body 0.92 17 6 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details hand length 1 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details hand 0.51 0.73 point -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details hand arrays 21 5 7 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details gesture length 7 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details gesture first {"face":0,"gesture":"facing right"} -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details object length 1 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: details object 0.72 person -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996928} -2022-08-24 08:09:50 STATE: test-node-gpu.js event: image -2022-08-24 08:09:50 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: float32 -2022-08-24 08:09:50 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996928} -2022-08-24 08:09:50 STATE: test-node-gpu.js event: image -2022-08-24 08:09:51 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: tensor shape: [1200,1200,4] dtype: float32 -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:51 STATE: test-node-gpu.js event: image -2022-08-24 08:09:51 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: tensor shape: [1,1200,1200,3] dtype: float32 -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:51 STATE: test-node-gpu.js event: image -2022-08-24 08:09:51 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: tensor shape: [1200,1200,3] dtype: float32 -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} -2022-08-24 08:09:51 STATE: test-node-gpu.js event: image -2022-08-24 08:09:51 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:51 STATE: test-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: int32 -2022-08-24 08:09:51 INFO:  test-node-gpu.js test default -2022-08-24 08:09:51 STATE: test-node-gpu.js start async -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:52 STATE: test-node-gpu.js event: image -2022-08-24 08:09:52 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg async -2022-08-24 08:09:52 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:52 DATA:  test-node-gpu.js result: performance: load: null total: 135 -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: default result face match 1 female 0.97 -2022-08-24 08:09:52 INFO:  test-node-gpu.js test sync -2022-08-24 08:09:52 STATE: test-node-gpu.js start sync -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:52 STATE: test-node-gpu.js event: image -2022-08-24 08:09:52 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg sync -2022-08-24 08:09:52 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:52 DATA:  test-node-gpu.js result: performance: load: null total: 140 -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: default sync 1 female 0.97 -2022-08-24 08:09:52 INFO:  test-node-gpu.js test: image process -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: image input null [1,256,256,3] -2022-08-24 08:09:52 INFO:  test-node-gpu.js test: image null -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: invalid input could not convert input to tensor -2022-08-24 08:09:52 INFO:  test-node-gpu.js test face similarity -2022-08-24 08:09:52 STATE: test-node-gpu.js start face similarity -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:52 STATE: test-node-gpu.js event: image -2022-08-24 08:09:52 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face similarity -2022-08-24 08:09:52 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} -2022-08-24 08:09:52 DATA:  test-node-gpu.js result: performance: load: null total: 131 -2022-08-24 08:09:52 STATE: test-node-gpu.js start face similarity -2022-08-24 08:09:52 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:52 STATE: test-node-gpu.js event: image -2022-08-24 08:09:53 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg face similarity -2022-08-24 08:09:53 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:53 DATA:  test-node-gpu.js result: performance: load: null total: 148 -2022-08-24 08:09:53 STATE: test-node-gpu.js start face similarity -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2022-08-24 08:09:53 STATE: test-node-gpu.js event: image -2022-08-24 08:09:53 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg face similarity -2022-08-24 08:09:53 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 4 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.71,"class":"person"} {"score":0.75,"keypoints":7} -2022-08-24 08:09:53 DATA:  test-node-gpu.js result: performance: load: null total: 161 -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: face descriptor -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: face similarity {"similarity":[1,0.447238756461232,0.556914029877052],"descriptors":[1024,1024,1024]} -2022-08-24 08:09:53 INFO:  test-node-gpu.js test object -2022-08-24 08:09:53 STATE: test-node-gpu.js start object -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:53 STATE: test-node-gpu.js event: image -2022-08-24 08:09:53 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg object -2022-08-24 08:09:53 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:53 DATA:  test-node-gpu.js result: performance: load: null total: 154 -2022-08-24 08:09:53 STATE: test-node-gpu.js passed: centernet -2022-08-24 08:09:53 STATE: test-node-gpu.js start object -2022-08-24 08:09:54 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:54 STATE: test-node-gpu.js event: image -2022-08-24 08:09:55 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg object -2022-08-24 08:09:55 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 3 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.86,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:09:55 DATA:  test-node-gpu.js result: performance: load: null total: 582 -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: nanodet -2022-08-24 08:09:55 INFO:  test-node-gpu.js test sensitive -2022-08-24 08:09:55 STATE: test-node-gpu.js start sensitive -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:55 STATE: test-node-gpu.js event: image -2022-08-24 08:09:55 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg sensitive -2022-08-24 08:09:55 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:55 DATA:  test-node-gpu.js result: performance: load: null total: 100 -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: sensitive result match -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: sensitive face result match -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: sensitive body result match -2022-08-24 08:09:55 STATE: test-node-gpu.js passed: sensitive hand result match -2022-08-24 08:09:55 INFO:  test-node-gpu.js test body -2022-08-24 08:09:55 STATE: test-node-gpu.js start blazepose -2022-08-24 08:09:56 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:56 STATE: test-node-gpu.js event: image -2022-08-24 08:09:56 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:56 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg blazepose -2022-08-24 08:09:56 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.99,"keypoints":39} -2022-08-24 08:09:56 DATA:  test-node-gpu.js result: performance: load: null total: 233 -2022-08-24 08:09:56 STATE: test-node-gpu.js passed: blazepose -2022-08-24 08:09:56 STATE: test-node-gpu.js start efficientpose -2022-08-24 08:09:57 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:57 STATE: test-node-gpu.js event: image -2022-08-24 08:09:58 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:58 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg efficientpose -2022-08-24 08:09:58 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.75,"keypoints":13} -2022-08-24 08:09:58 DATA:  test-node-gpu.js result: performance: load: null total: 780 -2022-08-24 08:09:58 STATE: test-node-gpu.js passed: efficientpose -2022-08-24 08:09:58 STATE: test-node-gpu.js start posenet -2022-08-24 08:09:58 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:58 STATE: test-node-gpu.js event: image -2022-08-24 08:09:58 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:58 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg posenet -2022-08-24 08:09:58 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.96,"keypoints":16} -2022-08-24 08:09:58 DATA:  test-node-gpu.js result: performance: load: null total: 120 -2022-08-24 08:09:58 STATE: test-node-gpu.js passed: posenet -2022-08-24 08:09:58 STATE: test-node-gpu.js start movenet -2022-08-24 08:09:58 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:09:58 STATE: test-node-gpu.js event: image -2022-08-24 08:09:59 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg movenet -2022-08-24 08:09:59 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:09:59 DATA:  test-node-gpu.js result: performance: load: null total: 92 -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: movenet -2022-08-24 08:09:59 INFO:  test-node-gpu.js test face matching -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: face database 40 -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: face match {"first":{"index":4,"similarity":0.7828184453007331}} {"second":{"index":4,"similarity":0.5001334216773398}} {"third":{"index":4,"similarity":0.5403054967489764}} -2022-08-24 08:09:59 INFO:  test-node-gpu.js test face similarity alternative -2022-08-24 08:09:59 STATE: test-node-gpu.js start face embeddings -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:59 STATE: test-node-gpu.js event: image -2022-08-24 08:09:59 STATE: test-node-gpu.js event: detect -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings -2022-08-24 08:09:59 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:09:59 DATA:  test-node-gpu.js result: performance: load: null total: 149 -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: mobilefacenet {"embedding":192} -2022-08-24 08:09:59 STATE: test-node-gpu.js start face embeddings -2022-08-24 08:09:59 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:09:59 STATE: test-node-gpu.js event: image -2022-08-24 08:10:00 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: performance: load: null total: 165 -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: insightface {"embedding":512} -2022-08-24 08:10:00 INFO:  test-node-gpu.js test face attention -2022-08-24 08:10:00 STATE: test-node-gpu.js start face attention -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:10:00 STATE: test-node-gpu.js event: image -2022-08-24 08:10:00 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face attention -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: performance: load: null total: 243 -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: face attention -2022-08-24 08:10:00 INFO:  test-node-gpu.js test detectors -2022-08-24 08:10:00 STATE: test-node-gpu.js start detectors -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:10:00 STATE: test-node-gpu.js event: image -2022-08-24 08:10:00 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg detectors -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: performance: load: null total: 53 -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detector result face match -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detector result hand match -2022-08-24 08:10:00 INFO:  test-node-gpu.js test: multi-instance -2022-08-24 08:10:00 STATE: test-node-gpu.js start multi instance -2022-08-24 08:10:00 STATE: test-node-gpu.js event: image -2022-08-24 08:10:00 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detect: random multi instance -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: performance: load: null total: 57 -2022-08-24 08:10:00 INFO:  test-node-gpu.js test: first instance -2022-08-24 08:10:00 STATE: test-node-gpu.js start multi instance -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2022-08-24 08:10:00 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:00 DATA:  test-node-gpu.js result: performance: load: null total: 45 -2022-08-24 08:10:00 INFO:  test-node-gpu.js test: second instance -2022-08-24 08:10:00 STATE: test-node-gpu.js start multi instance -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance -2022-08-24 08:10:01 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:01 DATA:  test-node-gpu.js result: performance: load: null total: 48 -2022-08-24 08:10:01 INFO:  test-node-gpu.js test: concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js start concurrent -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:10:01 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2022-08-24 08:10:01 STATE: test-node-gpu.js event: image -2022-08-24 08:10:01 STATE: test-node-gpu.js event: image -2022-08-24 08:10:01 STATE: test-node-gpu.js event: image -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 688 -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 688 -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 689 -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 689 -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 689 -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 689 -2022-08-24 08:10:02 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 427 -2022-08-24 08:10:02 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:02 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 427 -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:02 DATA:  test-node-gpu.js result: performance: load: null total: 427 -2022-08-24 08:10:02 INFO:  test-node-gpu.js test: monkey-patch -2022-08-24 08:10:02 STATE: test-node-gpu.js event: image -2022-08-24 08:10:02 STATE: test-node-gpu.js event: detect -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: monkey patch -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: segmentation [65536] -2022-08-24 08:10:02 STATE: test-node-gpu.js passeed: equal usage -2022-08-24 08:10:02 INFO:  test-node-gpu.js test: input compare -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} -2022-08-24 08:10:02 STATE: test-node-gpu.js passed: image compare 0 23.275441687091504 -2022-08-24 08:10:02 INFO:  test-node-gpu.js events: {"image":29,"detect":29,"warmup":2} -2022-08-24 08:10:02 INFO:  test-node-gpu.js tensors 4105 -2022-08-24 08:10:02 INFO:  test-node-gpu.js test complete: 17370 ms -2022-08-24 08:10:03 INFO:  -2022-08-24 08:10:03 INFO:  test-node-wasm.js start -2022-08-24 08:10:04 DATA:  test-node-wasm.js stdout: 2022-08-24 08:10:04 INFO:  { supported: true, backend: true, simd: true, multithread: false } -2022-08-24 08:10:04 STATE: test-node-wasm.js passed: model server: https://vladmandic.github.io/human/models/ -2022-08-24 08:10:04 INFO:  test-node-wasm.js test: configuration validation -2022-08-24 08:10:04 STATE: test-node-wasm.js passed: configuration default validation [] -2022-08-24 08:10:04 STATE: test-node-wasm.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] -2022-08-24 08:10:04 INFO:  test-node-wasm.js test: model load -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: models loaded 23 12 [{"name":"ssrnetage","loaded":false,"url":null},{"name":"gear","loaded":false,"url":null},{"name":"blazeposedetect","loaded":false,"url":null},{"name":"blazepose","loaded":false,"url":null},{"name":"centernet","loaded":true,"url":"https://vladmandic.github.io/human/models/mb3-centernet.json"},{"name":"efficientpose","loaded":false,"url":null},{"name":"mobilefacenet","loaded":false,"url":null},{"name":"insightface","loaded":false,"url":null},{"name":"emotion","loaded":true,"url":"https://vladmandic.github.io/human/models/emotion.json"},{"name":"facedetect","loaded":true,"url":"https://vladmandic.github.io/human/models/blazeface.json"},{"name":"faceiris","loaded":true,"url":"https://vladmandic.github.io/human/models/iris.json"},{"name":"facemesh","loaded":true,"url":"https://vladmandic.github.io/human/models/facemesh.json"},{"name":"faceres","loaded":true,"url":"https://vladmandic.github.io/human/models/faceres.json"},{"name":"ssrnetgender","loaded":false,"url":null},{"name":"handpose","loaded":false,"url":null},{"name":"handskeleton","loaded":true,"url":"https://vladmandic.github.io/human/models/handlandmark-full.json"},{"name":"handtrack","loaded":true,"url":"https://vladmandic.github.io/human/models/handtrack.json"},{"name":"liveness","loaded":true,"url":"https://vladmandic.github.io/human/models/liveness.json"},{"name":"movenet","loaded":true,"url":"https://vladmandic.github.io/human/models/movenet-lightning.json"},{"name":"nanodet","loaded":false,"url":null},{"name":"posenet","loaded":false,"url":null},{"name":"segmentation","loaded":true,"url":"https://vladmandic.github.io/human/models/selfie.json"},{"name":"antispoof","loaded":true,"url":"https://vladmandic.github.io/human/models/antispoof.json"}] -2022-08-24 08:10:06 INFO:  test-node-wasm.js memory: {"memory":{"unreliable":false,"numTensors":1921,"numDataBuffers":1921,"numBytes":63673064}} -2022-08-24 08:10:06 INFO:  test-node-wasm.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":63673064,"numTensors":1921,"numStringTensors":0,"numDataBuffers":1921,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} -2022-08-24 08:10:06 INFO:  test-node-wasm.js test: warmup -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: create human -2022-08-24 08:10:06 INFO:  test-node-wasm.js human version: 2.9.4 -2022-08-24 08:10:06 INFO:  test-node-wasm.js platform: linux x64 agent: NodeJS v18.1.0 -2022-08-24 08:10:06 INFO:  test-node-wasm.js tfjs version: 3.20.0 -2022-08-24 08:10:06 INFO:  test-node-wasm.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v18.1.0","backends":["cpu","wasm"],"initial":false,"tfjs":{"version":"3.20.0"},"offscreen":false,"perfadd":false,"tensorflow":{},"wasm":{"supported":true,"backend":true,"simd":true,"multithread":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":126} -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: set backend: wasm -2022-08-24 08:10:06 STATE: test-node-wasm.js tensors 1921 -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: load models -2022-08-24 08:10:06 STATE: test-node-wasm.js result: defined models: 23 loaded models: 12 -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: warmup: none default -2022-08-24 08:10:06 DATA:  test-node-wasm.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} -2022-08-24 08:10:06 DATA:  test-node-wasm.js result: performance: load: null total: null -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: warmup none result match -2022-08-24 08:10:06 STATE: test-node-wasm.js event: image -2022-08-24 08:10:06 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:06 STATE: test-node-wasm.js event: warmup -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: warmup: face default -2022-08-24 08:10:06 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} -2022-08-24 08:10:06 DATA:  test-node-wasm.js result: performance: load: null total: 503 -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: warmup face result match -2022-08-24 08:10:06 STATE: test-node-wasm.js event: image -2022-08-24 08:10:06 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:06 STATE: test-node-wasm.js event: warmup -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: warmup: body default -2022-08-24 08:10:06 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:10:06 DATA:  test-node-wasm.js result: performance: load: null total: 353 -2022-08-24 08:10:06 STATE: test-node-wasm.js passed: warmup body result match -2022-08-24 08:10:06 STATE: test-node-wasm.js details: {"face":{"boxScore":0.93,"faceScore":1,"age":23.7,"gender":"female","genderScore":0.97},"emotion":[{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}],"body":{"score":0.92,"keypoints":17},"hand":{"boxScore":0.51,"fingerScore":0.73,"keypoints":21},"gestures":[{"face":0,"gesture":"facing right"},{"face":0,"gesture":"mouth 21% open"},{"hand":0,"gesture":"pinky forward"},{"hand":0,"gesture":"palm up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} -2022-08-24 08:10:06 INFO:  test-node-wasm.js test: details verification -2022-08-24 08:10:06 STATE: test-node-wasm.js start default -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:07 STATE: test-node-wasm.js event: image -2022-08-24 08:10:07 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg default -2022-08-24 08:10:07 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:10:07 DATA:  test-node-wasm.js result: performance: load: null total: 331 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face length 1 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face score 1 0.93 1 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face age/gender 23.7 female 0.97 85.47 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face arrays 4 478 1024 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face anti-spoofing 0.79 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details face liveness 0.83 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details body length 1 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details body 0.92 17 6 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details hand length 1 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details hand 0.51 0.73 point -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details hand arrays 21 5 7 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details gesture length 7 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details gesture first {"face":0,"gesture":"facing right"} -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details object length 1 -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: details object 0.72 person -2022-08-24 08:10:07 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1413675264} -2022-08-24 08:10:07 STATE: test-node-wasm.js event: image -2022-08-24 08:10:08 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:08 STATE: test-node-wasm.js passed: tensor shape: [1,1200,1200,4] dtype: float32 -2022-08-24 08:10:08 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1413675264} -2022-08-24 08:10:08 STATE: test-node-wasm.js event: image -2022-08-24 08:10:08 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:08 STATE: test-node-wasm.js passed: tensor shape: [1200,1200,4] dtype: float32 -2022-08-24 08:10:08 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:08 STATE: test-node-wasm.js event: image -2022-08-24 08:10:09 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:09 STATE: test-node-wasm.js passed: tensor shape: [1,1200,1200,3] dtype: float32 -2022-08-24 08:10:09 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:09 STATE: test-node-wasm.js event: image -2022-08-24 08:10:09 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:09 STATE: test-node-wasm.js passed: tensor shape: [1200,1200,3] dtype: float32 -2022-08-24 08:10:09 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} -2022-08-24 08:10:09 STATE: test-node-wasm.js event: image -2022-08-24 08:10:10 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:10 STATE: test-node-wasm.js passed: tensor shape: [1,1200,1200,4] dtype: int32 -2022-08-24 08:10:10 INFO:  test-node-wasm.js test default -2022-08-24 08:10:10 STATE: test-node-wasm.js start async -2022-08-24 08:10:10 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:10 STATE: test-node-wasm.js event: image -2022-08-24 08:10:10 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:10 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg async -2022-08-24 08:10:10 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:10:10 DATA:  test-node-wasm.js result: performance: load: null total: 304 -2022-08-24 08:10:10 STATE: test-node-wasm.js passed: default result face match 1 female 0.97 -2022-08-24 08:10:10 INFO:  test-node-wasm.js test sync -2022-08-24 08:10:10 STATE: test-node-wasm.js start sync -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:11 STATE: test-node-wasm.js event: image -2022-08-24 08:10:11 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg sync -2022-08-24 08:10:11 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:10:11 DATA:  test-node-wasm.js result: performance: load: null total: 321 -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: default sync 1 female 0.97 -2022-08-24 08:10:11 INFO:  test-node-wasm.js test: image process -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: image input null [1,256,256,3] -2022-08-24 08:10:11 INFO:  test-node-wasm.js test: image null -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: invalid input could not convert input to tensor -2022-08-24 08:10:11 INFO:  test-node-wasm.js test face similarity -2022-08-24 08:10:11 STATE: test-node-wasm.js start face similarity -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:11 STATE: test-node-wasm.js event: image -2022-08-24 08:10:11 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face similarity -2022-08-24 08:10:11 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} -2022-08-24 08:10:11 DATA:  test-node-wasm.js result: performance: load: null total: 297 -2022-08-24 08:10:11 STATE: test-node-wasm.js start face similarity -2022-08-24 08:10:11 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:11 STATE: test-node-wasm.js event: image -2022-08-24 08:10:12 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:12 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg face similarity -2022-08-24 08:10:12 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:10:12 DATA:  test-node-wasm.js result: performance: load: null total: 316 -2022-08-24 08:10:12 STATE: test-node-wasm.js start face similarity -2022-08-24 08:10:12 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} -2022-08-24 08:10:12 STATE: test-node-wasm.js event: image -2022-08-24 08:10:12 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:12 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg face similarity -2022-08-24 08:10:12 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 4 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.71,"class":"person"} {"score":0.75,"keypoints":7} -2022-08-24 08:10:12 DATA:  test-node-wasm.js result: performance: load: null total: 314 -2022-08-24 08:10:12 STATE: test-node-wasm.js passed: face descriptor -2022-08-24 08:10:12 STATE: test-node-wasm.js passed: face similarity {"similarity":[1,0.5266119940661309,0.4858842904087851],"descriptors":[1024,1024,1024]} -2022-08-24 08:10:12 INFO:  test-node-wasm.js test object -2022-08-24 08:10:12 STATE: test-node-wasm.js start object -2022-08-24 08:10:12 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:12 STATE: test-node-wasm.js event: image -2022-08-24 08:10:13 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:13 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg object -2022-08-24 08:10:13 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} -2022-08-24 08:10:13 DATA:  test-node-wasm.js result: performance: load: null total: 314 -2022-08-24 08:10:13 STATE: test-node-wasm.js passed: centernet -2022-08-24 08:10:13 STATE: test-node-wasm.js start object -2022-08-24 08:10:13 WARN:  test-node-wasm.js missing kernel ops {"title":"object","model":"nanodet","url":"https://vladmandic.github.io/human-models/models/nanodet.json","missing":["sparsetodense"],"backkend":"wasm"} -2022-08-24 08:10:13 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:13 STATE: test-node-wasm.js event: image -2022-08-24 08:10:14 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg object -2022-08-24 08:10:14 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:14 DATA:  test-node-wasm.js result: performance: load: null total: 207 -2022-08-24 08:10:14 ERROR: test-node-wasm.js failed: nanodet [] -2022-08-24 08:10:14 INFO:  test-node-wasm.js test sensitive -2022-08-24 08:10:14 STATE: test-node-wasm.js start sensitive -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:14 STATE: test-node-wasm.js event: image -2022-08-24 08:10:14 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg sensitive -2022-08-24 08:10:14 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:14 DATA:  test-node-wasm.js result: performance: load: null total: 230 -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: sensitive result match -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: sensitive face result match -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: sensitive face emotion result [{"score":0.46,"emotion":"neutral"},{"score":0.24,"emotion":"fear"},{"score":0.17,"emotion":"sad"}] -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: sensitive body result match -2022-08-24 08:10:14 STATE: test-node-wasm.js passed: sensitive hand result match -2022-08-24 08:10:14 INFO:  test-node-wasm.js test body -2022-08-24 08:10:14 STATE: test-node-wasm.js start blazepose -2022-08-24 08:10:16 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:16 STATE: test-node-wasm.js event: image -2022-08-24 08:10:17 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:17 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg blazepose -2022-08-24 08:10:17 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.99,"keypoints":39} -2022-08-24 08:10:17 DATA:  test-node-wasm.js result: performance: load: null total: 388 -2022-08-24 08:10:17 STATE: test-node-wasm.js passed: blazepose -2022-08-24 08:10:17 STATE: test-node-wasm.js start efficientpose -2022-08-24 08:10:18 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:18 STATE: test-node-wasm.js event: image -2022-08-24 08:10:18 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:18 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg efficientpose -2022-08-24 08:10:18 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.75,"keypoints":13} -2022-08-24 08:10:18 DATA:  test-node-wasm.js result: performance: load: null total: 639 -2022-08-24 08:10:18 STATE: test-node-wasm.js passed: efficientpose -2022-08-24 08:10:18 STATE: test-node-wasm.js start posenet -2022-08-24 08:10:19 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:19 STATE: test-node-wasm.js event: image -2022-08-24 08:10:19 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:19 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg posenet -2022-08-24 08:10:19 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.96,"keypoints":16} -2022-08-24 08:10:19 DATA:  test-node-wasm.js result: performance: load: null total: 271 -2022-08-24 08:10:19 STATE: test-node-wasm.js passed: posenet -2022-08-24 08:10:19 STATE: test-node-wasm.js start movenet -2022-08-24 08:10:19 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:19 STATE: test-node-wasm.js event: image -2022-08-24 08:10:20 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg movenet -2022-08-24 08:10:20 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:20 DATA:  test-node-wasm.js result: performance: load: null total: 242 -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: movenet -2022-08-24 08:10:20 INFO:  test-node-wasm.js test face matching -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: face database 40 -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: face match {"first":{"index":4,"similarity":0.7827852754786533}} {"second":{"index":4,"similarity":0.5660821189104794}} {"third":{"index":4,"similarity":0.45074189882665594}} -2022-08-24 08:10:20 INFO:  test-node-wasm.js test face similarity alternative -2022-08-24 08:10:20 STATE: test-node-wasm.js start face embeddings -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:20 STATE: test-node-wasm.js event: image -2022-08-24 08:10:20 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face embeddings -2022-08-24 08:10:20 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:20 DATA:  test-node-wasm.js result: performance: load: null total: 234 -2022-08-24 08:10:20 STATE: test-node-wasm.js passed: mobilefacenet {"embedding":192} -2022-08-24 08:10:20 STATE: test-node-wasm.js start face embeddings -2022-08-24 08:10:21 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:21 STATE: test-node-wasm.js event: image -2022-08-24 08:10:21 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:21 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face embeddings -2022-08-24 08:10:21 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:21 DATA:  test-node-wasm.js result: performance: load: null total: 270 -2022-08-24 08:10:21 STATE: test-node-wasm.js passed: insightface {"embedding":512} -2022-08-24 08:10:21 INFO:  test-node-wasm.js test face attention -2022-08-24 08:10:21 STATE: test-node-wasm.js start face attention -2022-08-24 08:10:21 WARN:  test-node-wasm.js missing kernel ops {"title":"face attention","model":"facemesh","url":"https://vladmandic.github.io/human-models/models/facemesh-attention.json","missing":["atan2"],"backkend":"wasm"} -2022-08-24 08:10:21 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:21 STATE: test-node-wasm.js event: image -2022-08-24 08:10:21 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:21 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face attention -2022-08-24 08:10:21 DATA:  test-node-wasm.js result: face: 0 body: 1 hand: 1 gesture: 2 object: 0 person: 0 {} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:21 DATA:  test-node-wasm.js result: performance: load: null total: 117 -2022-08-24 08:10:21 ERROR: test-node-wasm.js failed: face attention {"annotations":0} -2022-08-24 08:10:21 INFO:  test-node-wasm.js test detectors -2022-08-24 08:10:21 STATE: test-node-wasm.js start detectors -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:22 STATE: test-node-wasm.js event: image -2022-08-24 08:10:22 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg detectors -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: performance: load: null total: 114 -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: detector result face match -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: detector result hand match -2022-08-24 08:10:22 INFO:  test-node-wasm.js test: multi-instance -2022-08-24 08:10:22 STATE: test-node-wasm.js start multi instance -2022-08-24 08:10:22 STATE: test-node-wasm.js event: image -2022-08-24 08:10:22 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: detect: random multi instance -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: performance: load: null total: 96 -2022-08-24 08:10:22 INFO:  test-node-wasm.js test: first instance -2022-08-24 08:10:22 STATE: test-node-wasm.js start multi instance -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg multi instance -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: performance: load: null total: 109 -2022-08-24 08:10:22 INFO:  test-node-wasm.js test: second instance -2022-08-24 08:10:22 STATE: test-node-wasm.js start multi instance -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg multi instance -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:22 DATA:  test-node-wasm.js result: performance: load: null total: 107 -2022-08-24 08:10:22 INFO:  test-node-wasm.js test: concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js start concurrent -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:22 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:23 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} -2022-08-24 08:10:23 STATE: test-node-wasm.js event: image -2022-08-24 08:10:23 STATE: test-node-wasm.js event: image -2022-08-24 08:10:23 STATE: test-node-wasm.js event: image -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 1290 -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 1290 -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 1290 -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 1290 -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 1290 -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 1290 -2022-08-24 08:10:24 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 971 -2022-08-24 08:10:24 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:24 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 971 -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg concurrent -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} -2022-08-24 08:10:24 DATA:  test-node-wasm.js result: performance: load: null total: 971 -2022-08-24 08:10:24 INFO:  test-node-wasm.js test: monkey-patch -2022-08-24 08:10:24 STATE: test-node-wasm.js event: image -2022-08-24 08:10:24 STATE: test-node-wasm.js event: detect -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: monkey patch -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: segmentation [65536] -2022-08-24 08:10:24 STATE: test-node-wasm.js passeed: equal usage -2022-08-24 08:10:24 INFO:  test-node-wasm.js test: input compare -2022-08-24 08:10:24 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} -2022-08-24 08:10:25 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} -2022-08-24 08:10:25 STATE: test-node-wasm.js passed: image compare 0 23.280073018790848 -2022-08-24 08:10:25 INFO:  test-node-wasm.js events: {"image":29,"detect":29,"warmup":2} -2022-08-24 08:10:25 INFO:  test-node-wasm.js tensors 4107 -2022-08-24 08:10:25 INFO:  test-node-wasm.js test complete: 20477 ms -2022-08-24 08:10:25 STATE: all tests complete -2022-08-24 08:10:25 INFO:  status {"test":"../demo/nodejs/node.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/nodejs/node-simple.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/nodejs/node-fetch.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/nodejs/node-event.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/nodejs/node-similarity.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/nodejs/node-canvas.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/multithread/node-multiprocess.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"../demo/facematch/node-match.js","passed":1,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"test-node.js","passed":125,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"test-node-gpu.js","passed":125,"failed":0} -2022-08-24 08:10:25 INFO:  status {"test":"test-node-wasm.js","passed":124,"failed":2} -2022-08-24 08:10:25 INFO:  failures {"count":2} -2022-08-24 08:10:25 WARN:  failed {"test":"test-node-wasm.js","message":["error",["failed: nanodet",[]]]} -2022-08-24 08:10:25 WARN:  failed {"test":"test-node-wasm.js","message":["error",["failed: face attention",{"annotations":0}]]} +2022-08-28 13:09:53 INFO:  @vladmandic/human version 2.9.4 +2022-08-28 13:09:53 INFO:  User: vlado Platform: linux Arch: x64 Node: v18.1.0 +2022-08-28 13:09:53 INFO:  demos: [{"cmd":"../demo/nodejs/node.js","args":[]},{"cmd":"../demo/nodejs/node-simple.js","args":[]},{"cmd":"../demo/nodejs/node-fetch.js","args":[]},{"cmd":"../demo/nodejs/node-event.js","args":["samples/in/ai-body.jpg"]},{"cmd":"../demo/nodejs/node-similarity.js","args":["samples/in/ai-face.jpg","samples/in/ai-upper.jpg"]},{"cmd":"../demo/nodejs/node-canvas.js","args":["samples/in/ai-body.jpg","samples/out/ai-body.jpg"]},{"cmd":"../demo/multithread/node-multiprocess.js","args":[]},{"cmd":"../demo/facematch/node-match.js","args":[]}] +2022-08-28 13:09:53 INFO:  {"cmd":"../demo/nodejs/node.js","args":[]} start +2022-08-28 13:09:54 INFO:  {"cmd":"../demo/nodejs/node-simple.js","args":[]} start +2022-08-28 13:09:55 INFO:  {"cmd":"../demo/nodejs/node-fetch.js","args":[]} start +2022-08-28 13:09:58 INFO:  {"cmd":"../demo/nodejs/node-event.js","args":["samples/in/ai-body.jpg"]} start +2022-08-28 13:09:58 INFO:  {"cmd":"../demo/nodejs/node-similarity.js","args":["samples/in/ai-face.jpg","samples/in/ai-upper.jpg"]} start +2022-08-28 13:09:59 INFO:  {"cmd":"../demo/nodejs/node-canvas.js","args":["samples/in/ai-body.jpg","samples/out/ai-body.jpg"]} start +2022-08-28 13:09:59 INFO:  {"cmd":"../demo/multithread/node-multiprocess.js","args":[]} start +2022-08-28 13:10:00 INFO:  {"cmd":"../demo/facematch/node-match.js","args":[]} start +2022-08-28 13:10:02 INFO:  tests: ["test-node.js","test-node-gpu.js","test-node-wasm.js"] +2022-08-28 13:10:02 INFO:  +2022-08-28 13:10:02 INFO:  test-node.js start +2022-08-28 13:10:02 INFO:  test-node.js test: configuration validation +2022-08-28 13:10:02 STATE: test-node.js passed: configuration default validation [] +2022-08-28 13:10:02 STATE: test-node.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] +2022-08-28 13:10:02 INFO:  test-node.js test: model load +2022-08-28 13:10:02 STATE: test-node.js passed: models loaded 23 12 [{"name":"ssrnetage","loaded":false,"url":null},{"name":"gear","loaded":false,"url":null},{"name":"blazeposedetect","loaded":false,"url":null},{"name":"blazepose","loaded":false,"url":null},{"name":"centernet","loaded":true,"url":"file://models/mb3-centernet.json"},{"name":"efficientpose","loaded":false,"url":null},{"name":"mobilefacenet","loaded":false,"url":null},{"name":"insightface","loaded":false,"url":null},{"name":"emotion","loaded":true,"url":"file://models/emotion.json"},{"name":"facedetect","loaded":true,"url":"file://models/blazeface.json"},{"name":"faceiris","loaded":true,"url":"file://models/iris.json"},{"name":"facemesh","loaded":true,"url":"file://models/facemesh.json"},{"name":"faceres","loaded":true,"url":"file://models/faceres.json"},{"name":"ssrnetgender","loaded":false,"url":null},{"name":"handpose","loaded":false,"url":null},{"name":"handskeleton","loaded":true,"url":"file://models/handlandmark-full.json"},{"name":"handtrack","loaded":true,"url":"file://models/handtrack.json"},{"name":"liveness","loaded":true,"url":"file://models/liveness.json"},{"name":"movenet","loaded":true,"url":"file://models/movenet-lightning.json"},{"name":"nanodet","loaded":false,"url":null},{"name":"posenet","loaded":false,"url":null},{"name":"segmentation","loaded":true,"url":"file://models/selfie.json"},{"name":"antispoof","loaded":true,"url":"file://models/antispoof.json"}] +2022-08-28 13:10:02 INFO:  test-node.js memory: {"memory":{"unreliable":true,"numTensors":1921,"numDataBuffers":1921,"numBytes":63673064}} +2022-08-28 13:10:02 INFO:  test-node.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":63673064,"numTensors":1921,"numStringTensors":0,"numDataBuffers":1921,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} +2022-08-28 13:10:02 INFO:  test-node.js test: warmup +2022-08-28 13:10:02 STATE: test-node.js passed: create human +2022-08-28 13:10:02 INFO:  test-node.js human version: 2.9.4 +2022-08-28 13:10:02 INFO:  test-node.js platform: linux x64 agent: NodeJS v18.1.0 +2022-08-28 13:10:02 INFO:  test-node.js tfjs version: 3.20.0 +2022-08-28 13:10:02 INFO:  test-node.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v18.1.0","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"3.20.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.7.3-dev20220521","gpu":false},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":169} +2022-08-28 13:10:02 STATE: test-node.js passed: set backend: tensorflow +2022-08-28 13:10:02 STATE: test-node.js tensors 1921 +2022-08-28 13:10:02 STATE: test-node.js passed: load models +2022-08-28 13:10:02 STATE: test-node.js result: defined models: 23 loaded models: 12 +2022-08-28 13:10:02 STATE: test-node.js passed: warmup: none default +2022-08-28 13:10:02 DATA:  test-node.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} +2022-08-28 13:10:02 DATA:  test-node.js result: performance: load: null total: null +2022-08-28 13:10:02 STATE: test-node.js passed: warmup none result match +2022-08-28 13:10:02 STATE: test-node.js event: image +2022-08-28 13:10:03 STATE: test-node.js event: detect +2022-08-28 13:10:03 STATE: test-node.js event: warmup +2022-08-28 13:10:03 STATE: test-node.js passed: warmup: face default +2022-08-28 13:10:03 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.42,"keypoints":4} +2022-08-28 13:10:03 DATA:  test-node.js result: performance: load: null total: 315 +2022-08-28 13:10:03 STATE: test-node.js passed: warmup face result match +2022-08-28 13:10:03 STATE: test-node.js event: image +2022-08-28 13:10:03 STATE: test-node.js event: detect +2022-08-28 13:10:03 STATE: test-node.js event: warmup +2022-08-28 13:10:03 STATE: test-node.js passed: warmup: body default +2022-08-28 13:10:03 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:03 DATA:  test-node.js result: performance: load: null total: 223 +2022-08-28 13:10:03 STATE: test-node.js passed: warmup body result match +2022-08-28 13:10:03 STATE: test-node.js details: {"face":{"boxScore":0.92,"faceScore":1,"age":23.7,"gender":"female","genderScore":0.97},"emotion":[{"score":0.63,"emotion":"angry"},{"score":0.22,"emotion":"fear"}],"body":{"score":0.92,"keypoints":17},"hand":{"boxScore":0.52,"fingerScore":0.73,"keypoints":21},"gestures":[{"face":0,"gesture":"facing right"},{"face":0,"gesture":"mouth 10% open"},{"hand":0,"gesture":"pinky forward"},{"hand":0,"gesture":"palm up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} +2022-08-28 13:10:03 INFO:  test-node.js test: details verification +2022-08-28 13:10:03 STATE: test-node.js start default +2022-08-28 13:10:03 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:03 STATE: test-node.js event: image +2022-08-28 13:10:03 STATE: test-node.js event: detect +2022-08-28 13:10:03 STATE: test-node.js passed: detect: samples/in/ai-body.jpg default +2022-08-28 13:10:03 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:03 DATA:  test-node.js result: performance: load: null total: 206 +2022-08-28 13:10:03 STATE: test-node.js passed: details face length 1 +2022-08-28 13:10:03 STATE: test-node.js passed: details face score 1 0.93 1 +2022-08-28 13:10:03 STATE: test-node.js passed: details face age/gender 23.7 female 0.97 85.47 +2022-08-28 13:10:03 STATE: test-node.js passed: details face arrays 4 478 1024 +2022-08-28 13:10:03 STATE: test-node.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} +2022-08-28 13:10:03 STATE: test-node.js passed: details face anti-spoofing 0.79 +2022-08-28 13:10:03 STATE: test-node.js passed: details face liveness 0.83 +2022-08-28 13:10:03 STATE: test-node.js passed: details body length 1 +2022-08-28 13:10:03 STATE: test-node.js passed: details body 0.92 17 6 +2022-08-28 13:10:03 STATE: test-node.js passed: details hand length 1 +2022-08-28 13:10:03 STATE: test-node.js passed: details hand 0.51 0.73 point +2022-08-28 13:10:03 STATE: test-node.js passed: details hand arrays 21 5 7 +2022-08-28 13:10:03 STATE: test-node.js passed: details gesture length 7 +2022-08-28 13:10:03 STATE: test-node.js passed: details gesture first {"face":0,"gesture":"facing right"} +2022-08-28 13:10:03 STATE: test-node.js passed: details object length 1 +2022-08-28 13:10:03 STATE: test-node.js passed: details object 0.72 person +2022-08-28 13:10:04 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996928} +2022-08-28 13:10:04 STATE: test-node.js event: image +2022-08-28 13:10:04 STATE: test-node.js event: detect +2022-08-28 13:10:04 STATE: test-node.js passed: tensor shape: [1,1200,1200,4] dtype: float32 +2022-08-28 13:10:04 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996928} +2022-08-28 13:10:04 STATE: test-node.js event: image +2022-08-28 13:10:04 STATE: test-node.js event: detect +2022-08-28 13:10:04 STATE: test-node.js passed: tensor shape: [1200,1200,4] dtype: float32 +2022-08-28 13:10:04 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:04 STATE: test-node.js event: image +2022-08-28 13:10:04 STATE: test-node.js event: detect +2022-08-28 13:10:04 STATE: test-node.js passed: tensor shape: [1,1200,1200,3] dtype: float32 +2022-08-28 13:10:05 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:05 STATE: test-node.js event: image +2022-08-28 13:10:05 STATE: test-node.js event: detect +2022-08-28 13:10:05 STATE: test-node.js passed: tensor shape: [1200,1200,3] dtype: float32 +2022-08-28 13:10:05 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} +2022-08-28 13:10:05 STATE: test-node.js event: image +2022-08-28 13:10:05 STATE: test-node.js event: detect +2022-08-28 13:10:05 STATE: test-node.js passed: tensor shape: [1,1200,1200,4] dtype: int32 +2022-08-28 13:10:05 INFO:  test-node.js test default +2022-08-28 13:10:05 STATE: test-node.js start async +2022-08-28 13:10:05 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:05 STATE: test-node.js event: image +2022-08-28 13:10:06 STATE: test-node.js event: detect +2022-08-28 13:10:06 STATE: test-node.js passed: detect: samples/in/ai-body.jpg async +2022-08-28 13:10:06 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:06 DATA:  test-node.js result: performance: load: null total: 194 +2022-08-28 13:10:06 STATE: test-node.js passed: default result face match 1 female 0.97 +2022-08-28 13:10:06 INFO:  test-node.js test sync +2022-08-28 13:10:06 STATE: test-node.js start sync +2022-08-28 13:10:06 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:06 STATE: test-node.js event: image +2022-08-28 13:10:06 STATE: test-node.js event: detect +2022-08-28 13:10:06 STATE: test-node.js passed: detect: samples/in/ai-body.jpg sync +2022-08-28 13:10:06 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:06 DATA:  test-node.js result: performance: load: null total: 190 +2022-08-28 13:10:06 STATE: test-node.js passed: default sync 1 female 0.97 +2022-08-28 13:10:06 INFO:  test-node.js test: image process +2022-08-28 13:10:06 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:06 STATE: test-node.js passed: image input null [1,256,256,3] +2022-08-28 13:10:06 INFO:  test-node.js test: image null +2022-08-28 13:10:06 STATE: test-node.js passed: invalid input could not convert input to tensor +2022-08-28 13:10:06 INFO:  test-node.js test face similarity +2022-08-28 13:10:06 STATE: test-node.js start face similarity +2022-08-28 13:10:06 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:06 STATE: test-node.js event: image +2022-08-28 13:10:06 STATE: test-node.js event: detect +2022-08-28 13:10:06 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face similarity +2022-08-28 13:10:06 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} +2022-08-28 13:10:06 DATA:  test-node.js result: performance: load: null total: 182 +2022-08-28 13:10:06 STATE: test-node.js start face similarity +2022-08-28 13:10:06 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:06 STATE: test-node.js event: image +2022-08-28 13:10:07 STATE: test-node.js event: detect +2022-08-28 13:10:07 STATE: test-node.js passed: detect: samples/in/ai-body.jpg face similarity +2022-08-28 13:10:07 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:07 DATA:  test-node.js result: performance: load: null total: 194 +2022-08-28 13:10:07 STATE: test-node.js start face similarity +2022-08-28 13:10:07 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2022-08-28 13:10:07 STATE: test-node.js event: image +2022-08-28 13:10:07 STATE: test-node.js event: detect +2022-08-28 13:10:07 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg face similarity +2022-08-28 13:10:07 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 4 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.71,"class":"person"} {"score":0.75,"keypoints":7} +2022-08-28 13:10:07 DATA:  test-node.js result: performance: load: null total: 169 +2022-08-28 13:10:07 STATE: test-node.js passed: face descriptor +2022-08-28 13:10:07 STATE: test-node.js passed: face similarity {"similarity":[1,0.44727452329649126,0.5567935850640406],"descriptors":[1024,1024,1024]} +2022-08-28 13:10:07 INFO:  test-node.js test object +2022-08-28 13:10:07 STATE: test-node.js start object +2022-08-28 13:10:07 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:07 STATE: test-node.js event: image +2022-08-28 13:10:07 STATE: test-node.js event: detect +2022-08-28 13:10:07 STATE: test-node.js passed: detect: samples/in/ai-body.jpg object +2022-08-28 13:10:07 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:07 DATA:  test-node.js result: performance: load: null total: 186 +2022-08-28 13:10:07 STATE: test-node.js passed: centernet +2022-08-28 13:10:07 STATE: test-node.js start object +2022-08-28 13:10:08 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:08 STATE: test-node.js event: image +2022-08-28 13:10:08 STATE: test-node.js event: detect +2022-08-28 13:10:08 STATE: test-node.js passed: detect: samples/in/ai-body.jpg object +2022-08-28 13:10:08 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 3 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.86,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:08 DATA:  test-node.js result: performance: load: null total: 196 +2022-08-28 13:10:08 STATE: test-node.js passed: nanodet +2022-08-28 13:10:08 INFO:  test-node.js test sensitive +2022-08-28 13:10:08 STATE: test-node.js start sensitive +2022-08-28 13:10:08 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:08 STATE: test-node.js event: image +2022-08-28 13:10:09 STATE: test-node.js event: detect +2022-08-28 13:10:09 STATE: test-node.js passed: detect: samples/in/ai-body.jpg sensitive +2022-08-28 13:10:09 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:09 DATA:  test-node.js result: performance: load: null total: 151 +2022-08-28 13:10:09 STATE: test-node.js passed: sensitive result match +2022-08-28 13:10:09 STATE: test-node.js passed: sensitive face result match +2022-08-28 13:10:09 STATE: test-node.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] +2022-08-28 13:10:09 STATE: test-node.js passed: sensitive body result match +2022-08-28 13:10:09 STATE: test-node.js passed: sensitive hand result match +2022-08-28 13:10:09 INFO:  test-node.js test body +2022-08-28 13:10:09 STATE: test-node.js start blazepose +2022-08-28 13:10:11 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:11 STATE: test-node.js event: image +2022-08-28 13:10:11 STATE: test-node.js event: detect +2022-08-28 13:10:11 STATE: test-node.js passed: detect: samples/in/ai-body.jpg blazepose +2022-08-28 13:10:11 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.99,"keypoints":39} +2022-08-28 13:10:11 DATA:  test-node.js result: performance: load: null total: 202 +2022-08-28 13:10:11 STATE: test-node.js passed: blazepose +2022-08-28 13:10:11 STATE: test-node.js start efficientpose +2022-08-28 13:10:12 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:12 STATE: test-node.js event: image +2022-08-28 13:10:12 STATE: test-node.js event: detect +2022-08-28 13:10:12 STATE: test-node.js passed: detect: samples/in/ai-body.jpg efficientpose +2022-08-28 13:10:12 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.75,"keypoints":13} +2022-08-28 13:10:12 DATA:  test-node.js result: performance: load: null total: 229 +2022-08-28 13:10:12 STATE: test-node.js passed: efficientpose +2022-08-28 13:10:12 STATE: test-node.js start posenet +2022-08-28 13:10:13 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:13 STATE: test-node.js event: image +2022-08-28 13:10:13 STATE: test-node.js event: detect +2022-08-28 13:10:13 STATE: test-node.js passed: detect: samples/in/ai-body.jpg posenet +2022-08-28 13:10:13 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.96,"keypoints":16} +2022-08-28 13:10:13 DATA:  test-node.js result: performance: load: null total: 171 +2022-08-28 13:10:13 STATE: test-node.js passed: posenet +2022-08-28 13:10:13 STATE: test-node.js start movenet +2022-08-28 13:10:13 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:13 STATE: test-node.js event: image +2022-08-28 13:10:13 STATE: test-node.js event: detect +2022-08-28 13:10:13 STATE: test-node.js passed: detect: samples/in/ai-body.jpg movenet +2022-08-28 13:10:13 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:13 DATA:  test-node.js result: performance: load: null total: 154 +2022-08-28 13:10:13 STATE: test-node.js passed: movenet +2022-08-28 13:10:13 INFO:  test-node.js test face matching +2022-08-28 13:10:13 STATE: test-node.js passed: face database 40 +2022-08-28 13:10:13 STATE: test-node.js passed: face match {"first":{"index":4,"similarity":0.7827852615252829}} {"second":{"index":4,"similarity":0.5002052633015844}} {"third":{"index":4,"similarity":0.5401587887998899}} +2022-08-28 13:10:13 INFO:  test-node.js test face similarity alternative +2022-08-28 13:10:13 STATE: test-node.js start face embeddings +2022-08-28 13:10:14 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:14 STATE: test-node.js event: image +2022-08-28 13:10:14 STATE: test-node.js event: detect +2022-08-28 13:10:14 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face embeddings +2022-08-28 13:10:14 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:14 DATA:  test-node.js result: performance: load: null total: 167 +2022-08-28 13:10:14 STATE: test-node.js passed: mobilefacenet {"embedding":192} +2022-08-28 13:10:14 STATE: test-node.js start face embeddings +2022-08-28 13:10:15 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:15 STATE: test-node.js event: image +2022-08-28 13:10:15 STATE: test-node.js event: detect +2022-08-28 13:10:15 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face embeddings +2022-08-28 13:10:15 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:15 DATA:  test-node.js result: performance: load: null total: 174 +2022-08-28 13:10:15 STATE: test-node.js passed: insightface {"embedding":512} +2022-08-28 13:10:15 INFO:  test-node.js test face attention +2022-08-28 13:10:15 STATE: test-node.js start face attention +2022-08-28 13:10:15 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:15 STATE: test-node.js event: image +2022-08-28 13:10:15 STATE: test-node.js event: detect +2022-08-28 13:10:15 STATE: test-node.js passed: detect: samples/in/ai-face.jpg face attention +2022-08-28 13:10:15 DATA:  test-node.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:15 DATA:  test-node.js result: performance: load: null total: 154 +2022-08-28 13:10:15 STATE: test-node.js passed: face attention +2022-08-28 13:10:15 INFO:  test-node.js test detectors +2022-08-28 13:10:15 STATE: test-node.js start detectors +2022-08-28 13:10:16 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:16 STATE: test-node.js event: image +2022-08-28 13:10:16 STATE: test-node.js event: detect +2022-08-28 13:10:16 STATE: test-node.js passed: detect: samples/in/ai-body.jpg detectors +2022-08-28 13:10:16 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:16 DATA:  test-node.js result: performance: load: null total: 75 +2022-08-28 13:10:16 STATE: test-node.js passed: detector result face match +2022-08-28 13:10:16 STATE: test-node.js passed: detector result hand match +2022-08-28 13:10:16 INFO:  test-node.js test: multi-instance +2022-08-28 13:10:16 STATE: test-node.js start multi instance +2022-08-28 13:10:16 STATE: test-node.js event: image +2022-08-28 13:10:16 STATE: test-node.js event: detect +2022-08-28 13:10:16 STATE: test-node.js passed: detect: random multi instance +2022-08-28 13:10:16 DATA:  test-node.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} +2022-08-28 13:10:16 DATA:  test-node.js result: performance: load: null total: 82 +2022-08-28 13:10:16 INFO:  test-node.js test: first instance +2022-08-28 13:10:16 STATE: test-node.js start multi instance +2022-08-28 13:10:16 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2022-08-28 13:10:16 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg multi instance +2022-08-28 13:10:16 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:16 DATA:  test-node.js result: performance: load: null total: 80 +2022-08-28 13:10:16 INFO:  test-node.js test: second instance +2022-08-28 13:10:16 STATE: test-node.js start multi instance +2022-08-28 13:10:16 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2022-08-28 13:10:16 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg multi instance +2022-08-28 13:10:16 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:16 DATA:  test-node.js result: performance: load: null total: 79 +2022-08-28 13:10:16 INFO:  test-node.js test: concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js start concurrent +2022-08-28 13:10:16 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:16 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:16 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:17 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:17 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2022-08-28 13:10:17 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2022-08-28 13:10:17 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:17 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:17 STATE: test-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2022-08-28 13:10:17 STATE: test-node.js event: image +2022-08-28 13:10:17 STATE: test-node.js event: image +2022-08-28 13:10:17 STATE: test-node.js event: image +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 924 +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 924 +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 924 +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 924 +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 924 +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 924 +2022-08-28 13:10:18 STATE: test-node.js event: detect +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 678 +2022-08-28 13:10:18 STATE: test-node.js event: detect +2022-08-28 13:10:18 STATE: test-node.js event: detect +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 678 +2022-08-28 13:10:18 STATE: test-node.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:10:18 DATA:  test-node.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:18 DATA:  test-node.js result: performance: load: null total: 678 +2022-08-28 13:10:18 INFO:  test-node.js test: monkey-patch +2022-08-28 13:10:18 STATE: test-node.js event: image +2022-08-28 13:10:18 STATE: test-node.js event: detect +2022-08-28 13:10:18 STATE: test-node.js passed: monkey patch +2022-08-28 13:10:18 STATE: test-node.js passed: segmentation [65536] +2022-08-28 13:10:18 STATE: test-node.js passeed: equal usage +2022-08-28 13:10:18 INFO:  test-node.js test: input compare +2022-08-28 13:10:18 STATE: test-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:18 STATE: test-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2022-08-28 13:10:18 STATE: test-node.js passed: image compare 0 23.275441687091504 +2022-08-28 13:10:18 INFO:  test-node.js events: {"image":29,"detect":29,"warmup":2} +2022-08-28 13:10:18 INFO:  test-node.js tensors 4105 +2022-08-28 13:10:18 INFO:  test-node.js test complete: 15623 ms +2022-08-28 13:10:18 INFO:  +2022-08-28 13:10:18 INFO:  test-node-gpu.js start +2022-08-28 13:10:19 INFO:  test-node-gpu.js test: configuration validation +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: configuration default validation [] +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] +2022-08-28 13:10:19 INFO:  test-node-gpu.js test: model load +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: models loaded 23 12 [{"name":"ssrnetage","loaded":false,"url":null},{"name":"gear","loaded":false,"url":null},{"name":"blazeposedetect","loaded":false,"url":null},{"name":"blazepose","loaded":false,"url":null},{"name":"centernet","loaded":true,"url":"file://models/mb3-centernet.json"},{"name":"efficientpose","loaded":false,"url":null},{"name":"mobilefacenet","loaded":false,"url":null},{"name":"insightface","loaded":false,"url":null},{"name":"emotion","loaded":true,"url":"file://models/emotion.json"},{"name":"facedetect","loaded":true,"url":"file://models/blazeface.json"},{"name":"faceiris","loaded":true,"url":"file://models/iris.json"},{"name":"facemesh","loaded":true,"url":"file://models/facemesh.json"},{"name":"faceres","loaded":true,"url":"file://models/faceres.json"},{"name":"ssrnetgender","loaded":false,"url":null},{"name":"handpose","loaded":false,"url":null},{"name":"handskeleton","loaded":true,"url":"file://models/handlandmark-full.json"},{"name":"handtrack","loaded":true,"url":"file://models/handtrack.json"},{"name":"liveness","loaded":true,"url":"file://models/liveness.json"},{"name":"movenet","loaded":true,"url":"file://models/movenet-lightning.json"},{"name":"nanodet","loaded":false,"url":null},{"name":"posenet","loaded":false,"url":null},{"name":"segmentation","loaded":true,"url":"file://models/selfie.json"},{"name":"antispoof","loaded":true,"url":"file://models/antispoof.json"}] +2022-08-28 13:10:19 INFO:  test-node-gpu.js memory: {"memory":{"unreliable":true,"numTensors":1921,"numDataBuffers":1921,"numBytes":63673064}} +2022-08-28 13:10:19 INFO:  test-node-gpu.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":63673064,"numTensors":1921,"numStringTensors":0,"numDataBuffers":1921,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} +2022-08-28 13:10:19 INFO:  test-node-gpu.js test: warmup +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: create human +2022-08-28 13:10:19 INFO:  test-node-gpu.js human version: 2.9.4 +2022-08-28 13:10:19 INFO:  test-node-gpu.js platform: linux x64 agent: NodeJS v18.1.0 +2022-08-28 13:10:19 INFO:  test-node-gpu.js tfjs version: 3.20.0 +2022-08-28 13:10:19 INFO:  test-node-gpu.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v18.1.0","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"3.20.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.7.3-dev20220521","gpu":true},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":169} +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: set backend: tensorflow +2022-08-28 13:10:19 STATE: test-node-gpu.js tensors 1921 +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: load models +2022-08-28 13:10:19 STATE: test-node-gpu.js result: defined models: 23 loaded models: 12 +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: warmup: none default +2022-08-28 13:10:19 DATA:  test-node-gpu.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} +2022-08-28 13:10:19 DATA:  test-node-gpu.js result: performance: load: null total: null +2022-08-28 13:10:19 STATE: test-node-gpu.js passed: warmup none result match +2022-08-28 13:10:19 STATE: test-node-gpu.js event: image +2022-08-28 13:10:24 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:24 STATE: test-node-gpu.js event: warmup +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: warmup: face default +2022-08-28 13:10:24 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.42,"keypoints":4} +2022-08-28 13:10:24 DATA:  test-node-gpu.js result: performance: load: null total: 4115 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: warmup face result match +2022-08-28 13:10:24 STATE: test-node-gpu.js event: image +2022-08-28 13:10:24 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:24 STATE: test-node-gpu.js event: warmup +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: warmup: body default +2022-08-28 13:10:24 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:24 DATA:  test-node-gpu.js result: performance: load: null total: 133 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: warmup body result match +2022-08-28 13:10:24 STATE: test-node-gpu.js details: {"face":{"boxScore":0.92,"faceScore":1,"age":23.7,"gender":"female","genderScore":0.97},"emotion":[{"score":0.63,"emotion":"angry"},{"score":0.22,"emotion":"fear"}],"body":{"score":0.92,"keypoints":17},"hand":{"boxScore":0.52,"fingerScore":0.73,"keypoints":21},"gestures":[{"face":0,"gesture":"facing right"},{"face":0,"gesture":"mouth 10% open"},{"hand":0,"gesture":"pinky forward"},{"hand":0,"gesture":"palm up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} +2022-08-28 13:10:24 INFO:  test-node-gpu.js test: details verification +2022-08-28 13:10:24 STATE: test-node-gpu.js start default +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:24 STATE: test-node-gpu.js event: image +2022-08-28 13:10:24 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg default +2022-08-28 13:10:24 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:24 DATA:  test-node-gpu.js result: performance: load: null total: 129 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face length 1 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face score 1 0.93 1 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face age/gender 23.7 female 0.97 85.47 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face arrays 4 478 1024 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face anti-spoofing 0.79 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details face liveness 0.83 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details body length 1 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details body 0.92 17 6 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details hand length 1 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details hand 0.51 0.73 point +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details hand arrays 21 5 7 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details gesture length 7 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details gesture first {"face":0,"gesture":"facing right"} +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details object length 1 +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: details object 0.72 person +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996928} +2022-08-28 13:10:24 STATE: test-node-gpu.js event: image +2022-08-28 13:10:24 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:24 STATE: test-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: float32 +2022-08-28 13:10:25 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996928} +2022-08-28 13:10:25 STATE: test-node-gpu.js event: image +2022-08-28 13:10:25 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:25 STATE: test-node-gpu.js passed: tensor shape: [1200,1200,4] dtype: float32 +2022-08-28 13:10:25 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:25 STATE: test-node-gpu.js event: image +2022-08-28 13:10:25 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:25 STATE: test-node-gpu.js passed: tensor shape: [1,1200,1200,3] dtype: float32 +2022-08-28 13:10:25 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:25 STATE: test-node-gpu.js event: image +2022-08-28 13:10:25 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:25 STATE: test-node-gpu.js passed: tensor shape: [1200,1200,3] dtype: float32 +2022-08-28 13:10:26 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} +2022-08-28 13:10:26 STATE: test-node-gpu.js event: image +2022-08-28 13:10:26 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:26 STATE: test-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: int32 +2022-08-28 13:10:26 INFO:  test-node-gpu.js test default +2022-08-28 13:10:26 STATE: test-node-gpu.js start async +2022-08-28 13:10:26 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:26 STATE: test-node-gpu.js event: image +2022-08-28 13:10:26 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:26 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg async +2022-08-28 13:10:26 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:26 DATA:  test-node-gpu.js result: performance: load: null total: 141 +2022-08-28 13:10:26 STATE: test-node-gpu.js passed: default result face match 1 female 0.97 +2022-08-28 13:10:26 INFO:  test-node-gpu.js test sync +2022-08-28 13:10:26 STATE: test-node-gpu.js start sync +2022-08-28 13:10:26 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:26 STATE: test-node-gpu.js event: image +2022-08-28 13:10:27 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg sync +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: performance: load: null total: 162 +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: default sync 1 female 0.97 +2022-08-28 13:10:27 INFO:  test-node-gpu.js test: image process +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: image input null [1,256,256,3] +2022-08-28 13:10:27 INFO:  test-node-gpu.js test: image null +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: invalid input could not convert input to tensor +2022-08-28 13:10:27 INFO:  test-node-gpu.js test face similarity +2022-08-28 13:10:27 STATE: test-node-gpu.js start face similarity +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:27 STATE: test-node-gpu.js event: image +2022-08-28 13:10:27 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face similarity +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: performance: load: null total: 158 +2022-08-28 13:10:27 STATE: test-node-gpu.js start face similarity +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:27 STATE: test-node-gpu.js event: image +2022-08-28 13:10:27 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg face similarity +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: performance: load: null total: 163 +2022-08-28 13:10:27 STATE: test-node-gpu.js start face similarity +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} +2022-08-28 13:10:27 STATE: test-node-gpu.js event: image +2022-08-28 13:10:27 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg face similarity +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 4 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.71,"class":"person"} {"score":0.75,"keypoints":7} +2022-08-28 13:10:27 DATA:  test-node-gpu.js result: performance: load: null total: 134 +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: face descriptor +2022-08-28 13:10:27 STATE: test-node-gpu.js passed: face similarity {"similarity":[1,0.447238756461232,0.556914029877052],"descriptors":[1024,1024,1024]} +2022-08-28 13:10:27 INFO:  test-node-gpu.js test object +2022-08-28 13:10:27 STATE: test-node-gpu.js start object +2022-08-28 13:10:28 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:28 STATE: test-node-gpu.js event: image +2022-08-28 13:10:28 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:28 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg object +2022-08-28 13:10:28 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:28 DATA:  test-node-gpu.js result: performance: load: null total: 205 +2022-08-28 13:10:28 STATE: test-node-gpu.js passed: centernet +2022-08-28 13:10:28 STATE: test-node-gpu.js start object +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:29 STATE: test-node-gpu.js event: image +2022-08-28 13:10:29 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg object +2022-08-28 13:10:29 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 3 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.86,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:29 DATA:  test-node-gpu.js result: performance: load: null total: 481 +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: nanodet +2022-08-28 13:10:29 INFO:  test-node-gpu.js test sensitive +2022-08-28 13:10:29 STATE: test-node-gpu.js start sensitive +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:29 STATE: test-node-gpu.js event: image +2022-08-28 13:10:29 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg sensitive +2022-08-28 13:10:29 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:29 DATA:  test-node-gpu.js result: performance: load: null total: 109 +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: sensitive result match +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: sensitive face result match +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: sensitive body result match +2022-08-28 13:10:29 STATE: test-node-gpu.js passed: sensitive hand result match +2022-08-28 13:10:29 INFO:  test-node-gpu.js test body +2022-08-28 13:10:29 STATE: test-node-gpu.js start blazepose +2022-08-28 13:10:31 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:31 STATE: test-node-gpu.js event: image +2022-08-28 13:10:31 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:31 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg blazepose +2022-08-28 13:10:31 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.99,"keypoints":39} +2022-08-28 13:10:31 DATA:  test-node-gpu.js result: performance: load: null total: 231 +2022-08-28 13:10:31 STATE: test-node-gpu.js passed: blazepose +2022-08-28 13:10:31 STATE: test-node-gpu.js start efficientpose +2022-08-28 13:10:32 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:32 STATE: test-node-gpu.js event: image +2022-08-28 13:10:33 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg efficientpose +2022-08-28 13:10:33 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.75,"keypoints":13} +2022-08-28 13:10:33 DATA:  test-node-gpu.js result: performance: load: null total: 845 +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: efficientpose +2022-08-28 13:10:33 STATE: test-node-gpu.js start posenet +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:33 STATE: test-node-gpu.js event: image +2022-08-28 13:10:33 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg posenet +2022-08-28 13:10:33 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.96,"keypoints":16} +2022-08-28 13:10:33 DATA:  test-node-gpu.js result: performance: load: null total: 116 +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: posenet +2022-08-28 13:10:33 STATE: test-node-gpu.js start movenet +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:33 STATE: test-node-gpu.js event: image +2022-08-28 13:10:33 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg movenet +2022-08-28 13:10:33 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:33 DATA:  test-node-gpu.js result: performance: load: null total: 94 +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: movenet +2022-08-28 13:10:33 INFO:  test-node-gpu.js test face matching +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: face database 40 +2022-08-28 13:10:33 STATE: test-node-gpu.js passed: face match {"first":{"index":4,"similarity":0.7828184453007331}} {"second":{"index":4,"similarity":0.5001334216773398}} {"third":{"index":4,"similarity":0.5403054967489764}} +2022-08-28 13:10:33 INFO:  test-node-gpu.js test face similarity alternative +2022-08-28 13:10:33 STATE: test-node-gpu.js start face embeddings +2022-08-28 13:10:34 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:34 STATE: test-node-gpu.js event: image +2022-08-28 13:10:34 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:34 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings +2022-08-28 13:10:34 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:34 DATA:  test-node-gpu.js result: performance: load: null total: 143 +2022-08-28 13:10:34 STATE: test-node-gpu.js passed: mobilefacenet {"embedding":192} +2022-08-28 13:10:34 STATE: test-node-gpu.js start face embeddings +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:35 STATE: test-node-gpu.js event: image +2022-08-28 13:10:35 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings +2022-08-28 13:10:35 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:35 DATA:  test-node-gpu.js result: performance: load: null total: 158 +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: insightface {"embedding":512} +2022-08-28 13:10:35 INFO:  test-node-gpu.js test face attention +2022-08-28 13:10:35 STATE: test-node-gpu.js start face attention +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:35 STATE: test-node-gpu.js event: image +2022-08-28 13:10:35 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg face attention +2022-08-28 13:10:35 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:35 DATA:  test-node-gpu.js result: performance: load: null total: 198 +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: face attention +2022-08-28 13:10:35 INFO:  test-node-gpu.js test detectors +2022-08-28 13:10:35 STATE: test-node-gpu.js start detectors +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:35 STATE: test-node-gpu.js event: image +2022-08-28 13:10:35 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg detectors +2022-08-28 13:10:35 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:35 DATA:  test-node-gpu.js result: performance: load: null total: 49 +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: detector result face match +2022-08-28 13:10:35 STATE: test-node-gpu.js passed: detector result hand match +2022-08-28 13:10:35 INFO:  test-node-gpu.js test: multi-instance +2022-08-28 13:10:35 STATE: test-node-gpu.js start multi instance +2022-08-28 13:10:36 STATE: test-node-gpu.js event: image +2022-08-28 13:10:36 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: detect: random multi instance +2022-08-28 13:10:36 DATA:  test-node-gpu.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} +2022-08-28 13:10:36 DATA:  test-node-gpu.js result: performance: load: null total: 50 +2022-08-28 13:10:36 INFO:  test-node-gpu.js test: first instance +2022-08-28 13:10:36 STATE: test-node-gpu.js start multi instance +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance +2022-08-28 13:10:36 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:36 DATA:  test-node-gpu.js result: performance: load: null total: 44 +2022-08-28 13:10:36 INFO:  test-node-gpu.js test: second instance +2022-08-28 13:10:36 STATE: test-node-gpu.js start multi instance +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance +2022-08-28 13:10:36 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:36 DATA:  test-node-gpu.js result: performance: load: null total: 52 +2022-08-28 13:10:36 INFO:  test-node-gpu.js test: concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js start concurrent +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} +2022-08-28 13:10:36 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} +2022-08-28 13:10:37 STATE: test-node-gpu.js event: image +2022-08-28 13:10:37 STATE: test-node-gpu.js event: image +2022-08-28 13:10:37 STATE: test-node-gpu.js event: image +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 674 +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 674 +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 675 +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 675 +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 675 +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 675 +2022-08-28 13:10:37 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 412 +2022-08-28 13:10:37 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:37 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 412 +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:37 DATA:  test-node-gpu.js result: performance: load: null total: 412 +2022-08-28 13:10:37 INFO:  test-node-gpu.js test: monkey-patch +2022-08-28 13:10:37 STATE: test-node-gpu.js event: image +2022-08-28 13:10:37 STATE: test-node-gpu.js event: detect +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: monkey patch +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: segmentation [65536] +2022-08-28 13:10:37 STATE: test-node-gpu.js passeed: equal usage +2022-08-28 13:10:37 INFO:  test-node-gpu.js test: input compare +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796928} +2022-08-28 13:10:37 STATE: test-node-gpu.js passed: image compare 0 23.275441687091504 +2022-08-28 13:10:37 INFO:  test-node-gpu.js events: {"image":29,"detect":29,"warmup":2} +2022-08-28 13:10:37 INFO:  test-node-gpu.js tensors 4105 +2022-08-28 13:10:37 INFO:  test-node-gpu.js test complete: 18316 ms +2022-08-28 13:10:39 INFO:  +2022-08-28 13:10:39 INFO:  test-node-wasm.js start +2022-08-28 13:10:39 DATA:  test-node-wasm.js stdout: 2022-08-28 13:10:39 INFO:  { supported: true, backend: true, simd: true, multithread: false } +2022-08-28 13:10:39 STATE: test-node-wasm.js passed: model server: https://vladmandic.github.io/human/models/ +2022-08-28 13:10:39 INFO:  test-node-wasm.js test: configuration validation +2022-08-28 13:10:39 STATE: test-node-wasm.js passed: configuration default validation [] +2022-08-28 13:10:39 STATE: test-node-wasm.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] +2022-08-28 13:10:39 INFO:  test-node-wasm.js test: model load +2022-08-28 13:10:41 STATE: test-node-wasm.js passed: models loaded 23 12 [{"name":"ssrnetage","loaded":false,"url":null},{"name":"gear","loaded":false,"url":null},{"name":"blazeposedetect","loaded":false,"url":null},{"name":"blazepose","loaded":false,"url":null},{"name":"centernet","loaded":true,"url":"https://vladmandic.github.io/human/models/mb3-centernet.json"},{"name":"efficientpose","loaded":false,"url":null},{"name":"mobilefacenet","loaded":false,"url":null},{"name":"insightface","loaded":false,"url":null},{"name":"emotion","loaded":true,"url":"https://vladmandic.github.io/human/models/emotion.json"},{"name":"facedetect","loaded":true,"url":"https://vladmandic.github.io/human/models/blazeface.json"},{"name":"faceiris","loaded":true,"url":"https://vladmandic.github.io/human/models/iris.json"},{"name":"facemesh","loaded":true,"url":"https://vladmandic.github.io/human/models/facemesh.json"},{"name":"faceres","loaded":true,"url":"https://vladmandic.github.io/human/models/faceres.json"},{"name":"ssrnetgender","loaded":false,"url":null},{"name":"handpose","loaded":false,"url":null},{"name":"handskeleton","loaded":true,"url":"https://vladmandic.github.io/human/models/handlandmark-full.json"},{"name":"handtrack","loaded":true,"url":"https://vladmandic.github.io/human/models/handtrack.json"},{"name":"liveness","loaded":true,"url":"https://vladmandic.github.io/human/models/liveness.json"},{"name":"movenet","loaded":true,"url":"https://vladmandic.github.io/human/models/movenet-lightning.json"},{"name":"nanodet","loaded":false,"url":null},{"name":"posenet","loaded":false,"url":null},{"name":"segmentation","loaded":true,"url":"https://vladmandic.github.io/human/models/selfie.json"},{"name":"antispoof","loaded":true,"url":"https://vladmandic.github.io/human/models/antispoof.json"}] +2022-08-28 13:10:41 INFO:  test-node-wasm.js memory: {"memory":{"unreliable":false,"numTensors":1921,"numDataBuffers":1921,"numBytes":63673064}} +2022-08-28 13:10:41 INFO:  test-node-wasm.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":63673064,"numTensors":1921,"numStringTensors":0,"numDataBuffers":1921,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} +2022-08-28 13:10:41 INFO:  test-node-wasm.js test: warmup +2022-08-28 13:10:41 STATE: test-node-wasm.js passed: create human +2022-08-28 13:10:41 INFO:  test-node-wasm.js human version: 2.9.4 +2022-08-28 13:10:41 INFO:  test-node-wasm.js platform: linux x64 agent: NodeJS v18.1.0 +2022-08-28 13:10:41 INFO:  test-node-wasm.js tfjs version: 3.20.0 +2022-08-28 13:10:41 INFO:  test-node-wasm.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v18.1.0","backends":["cpu","wasm"],"initial":false,"tfjs":{"version":"3.20.0"},"offscreen":false,"perfadd":false,"tensorflow":{},"wasm":{"supported":true,"backend":true,"simd":true,"multithread":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":126} +2022-08-28 13:10:41 STATE: test-node-wasm.js passed: set backend: wasm +2022-08-28 13:10:41 STATE: test-node-wasm.js tensors 1921 +2022-08-28 13:10:41 STATE: test-node-wasm.js passed: load models +2022-08-28 13:10:41 STATE: test-node-wasm.js result: defined models: 23 loaded models: 12 +2022-08-28 13:10:41 STATE: test-node-wasm.js passed: warmup: none default +2022-08-28 13:10:41 DATA:  test-node-wasm.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} +2022-08-28 13:10:41 DATA:  test-node-wasm.js result: performance: load: null total: null +2022-08-28 13:10:41 STATE: test-node-wasm.js passed: warmup none result match +2022-08-28 13:10:41 STATE: test-node-wasm.js event: image +2022-08-28 13:10:42 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:42 STATE: test-node-wasm.js event: warmup +2022-08-28 13:10:42 STATE: test-node-wasm.js passed: warmup: face default +2022-08-28 13:10:42 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} +2022-08-28 13:10:42 DATA:  test-node-wasm.js result: performance: load: null total: 483 +2022-08-28 13:10:42 STATE: test-node-wasm.js passed: warmup face result match +2022-08-28 13:10:42 STATE: test-node-wasm.js event: image +2022-08-28 13:10:42 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:42 STATE: test-node-wasm.js event: warmup +2022-08-28 13:10:42 STATE: test-node-wasm.js passed: warmup: body default +2022-08-28 13:10:42 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:42 DATA:  test-node-wasm.js result: performance: load: null total: 354 +2022-08-28 13:10:42 STATE: test-node-wasm.js passed: warmup body result match +2022-08-28 13:10:42 STATE: test-node-wasm.js details: {"face":{"boxScore":0.93,"faceScore":1,"age":23.7,"gender":"female","genderScore":0.97},"emotion":[{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}],"body":{"score":0.92,"keypoints":17},"hand":{"boxScore":0.51,"fingerScore":0.73,"keypoints":21},"gestures":[{"face":0,"gesture":"facing right"},{"face":0,"gesture":"mouth 21% open"},{"hand":0,"gesture":"pinky forward"},{"hand":0,"gesture":"palm up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} +2022-08-28 13:10:42 INFO:  test-node-wasm.js test: details verification +2022-08-28 13:10:42 STATE: test-node-wasm.js start default +2022-08-28 13:10:42 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:42 STATE: test-node-wasm.js event: image +2022-08-28 13:10:43 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg default +2022-08-28 13:10:43 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 7 object: 1 person: 1 {"score":1,"age":23.7,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:43 DATA:  test-node-wasm.js result: performance: load: null total: 359 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face length 1 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face score 1 0.93 1 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face age/gender 23.7 female 0.97 85.47 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face arrays 4 478 1024 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face anti-spoofing 0.79 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details face liveness 0.83 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details body length 1 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details body 0.92 17 6 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details hand length 1 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details hand 0.51 0.73 point +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details hand arrays 21 5 7 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details gesture length 7 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details gesture first {"face":0,"gesture":"facing right"} +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details object length 1 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: details object 0.72 person +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1413675264} +2022-08-28 13:10:43 STATE: test-node-wasm.js event: image +2022-08-28 13:10:43 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: tensor shape: [1,1200,1200,4] dtype: float32 +2022-08-28 13:10:43 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1413675264} +2022-08-28 13:10:43 STATE: test-node-wasm.js event: image +2022-08-28 13:10:44 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:44 STATE: test-node-wasm.js passed: tensor shape: [1200,1200,4] dtype: float32 +2022-08-28 13:10:44 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:44 STATE: test-node-wasm.js event: image +2022-08-28 13:10:44 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:44 STATE: test-node-wasm.js passed: tensor shape: [1,1200,1200,3] dtype: float32 +2022-08-28 13:10:44 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:44 STATE: test-node-wasm.js event: image +2022-08-28 13:10:45 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:45 STATE: test-node-wasm.js passed: tensor shape: [1200,1200,3] dtype: float32 +2022-08-28 13:10:45 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} +2022-08-28 13:10:45 STATE: test-node-wasm.js event: image +2022-08-28 13:10:45 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:45 STATE: test-node-wasm.js passed: tensor shape: [1,1200,1200,4] dtype: int32 +2022-08-28 13:10:45 INFO:  test-node-wasm.js test default +2022-08-28 13:10:45 STATE: test-node-wasm.js start async +2022-08-28 13:10:45 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:45 STATE: test-node-wasm.js event: image +2022-08-28 13:10:46 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg async +2022-08-28 13:10:46 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:46 DATA:  test-node-wasm.js result: performance: load: null total: 323 +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: default result face match 1 female 0.97 +2022-08-28 13:10:46 INFO:  test-node-wasm.js test sync +2022-08-28 13:10:46 STATE: test-node-wasm.js start sync +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:46 STATE: test-node-wasm.js event: image +2022-08-28 13:10:46 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg sync +2022-08-28 13:10:46 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:46 DATA:  test-node-wasm.js result: performance: load: null total: 328 +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: default sync 1 female 0.97 +2022-08-28 13:10:46 INFO:  test-node-wasm.js test: image process +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: image input null [1,256,256,3] +2022-08-28 13:10:46 INFO:  test-node-wasm.js test: image null +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: invalid input could not convert input to tensor +2022-08-28 13:10:46 INFO:  test-node-wasm.js test face similarity +2022-08-28 13:10:46 STATE: test-node-wasm.js start face similarity +2022-08-28 13:10:46 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:46 STATE: test-node-wasm.js event: image +2022-08-28 13:10:47 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:47 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face similarity +2022-08-28 13:10:47 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 6 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.82,"class":"person"} {"score":0.47,"keypoints":3} +2022-08-28 13:10:47 DATA:  test-node-wasm.js result: performance: load: null total: 300 +2022-08-28 13:10:47 STATE: test-node-wasm.js start face similarity +2022-08-28 13:10:47 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:47 STATE: test-node-wasm.js event: image +2022-08-28 13:10:47 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:47 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg face similarity +2022-08-28 13:10:47 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:47 DATA:  test-node-wasm.js result: performance: load: null total: 336 +2022-08-28 13:10:47 STATE: test-node-wasm.js start face similarity +2022-08-28 13:10:47 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2022-08-28 13:10:47 STATE: test-node-wasm.js event: image +2022-08-28 13:10:48 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:48 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg face similarity +2022-08-28 13:10:48 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 4 object: 1 person: 1 {"score":1,"age":23.5,"gender":"female"} {"score":0.71,"class":"person"} {"score":0.75,"keypoints":7} +2022-08-28 13:10:48 DATA:  test-node-wasm.js result: performance: load: null total: 305 +2022-08-28 13:10:48 STATE: test-node-wasm.js passed: face descriptor +2022-08-28 13:10:48 STATE: test-node-wasm.js passed: face similarity {"similarity":[1,0.5266119940661309,0.4858842904087851],"descriptors":[1024,1024,1024]} +2022-08-28 13:10:48 INFO:  test-node-wasm.js test object +2022-08-28 13:10:48 STATE: test-node-wasm.js start object +2022-08-28 13:10:48 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:48 STATE: test-node-wasm.js event: image +2022-08-28 13:10:48 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:48 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg object +2022-08-28 13:10:48 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 1 person: 1 {"score":1,"age":29.6,"gender":"female"} {"score":0.72,"class":"person"} {"score":0.92,"keypoints":17} +2022-08-28 13:10:48 DATA:  test-node-wasm.js result: performance: load: null total: 331 +2022-08-28 13:10:48 STATE: test-node-wasm.js passed: centernet +2022-08-28 13:10:48 STATE: test-node-wasm.js start object +2022-08-28 13:10:49 WARN:  test-node-wasm.js missing kernel ops {"title":"object","model":"nanodet","url":"https://vladmandic.github.io/human-models/models/nanodet.json","missing":["sparsetodense"],"backkend":"wasm"} +2022-08-28 13:10:49 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:49 STATE: test-node-wasm.js event: image +2022-08-28 13:10:50 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg object +2022-08-28 13:10:50 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 8 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:50 DATA:  test-node-wasm.js result: performance: load: null total: 213 +2022-08-28 13:10:50 ERROR: test-node-wasm.js failed: nanodet [] +2022-08-28 13:10:50 INFO:  test-node-wasm.js test sensitive +2022-08-28 13:10:50 STATE: test-node-wasm.js start sensitive +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:50 STATE: test-node-wasm.js event: image +2022-08-28 13:10:50 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg sensitive +2022-08-28 13:10:50 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:50 DATA:  test-node-wasm.js result: performance: load: null total: 250 +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: sensitive result match +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: sensitive face result match +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: sensitive face emotion result [{"score":0.46,"emotion":"neutral"},{"score":0.24,"emotion":"fear"},{"score":0.17,"emotion":"sad"}] +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: sensitive body result match +2022-08-28 13:10:50 STATE: test-node-wasm.js passed: sensitive hand result match +2022-08-28 13:10:50 INFO:  test-node-wasm.js test body +2022-08-28 13:10:50 STATE: test-node-wasm.js start blazepose +2022-08-28 13:10:52 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:52 STATE: test-node-wasm.js event: image +2022-08-28 13:10:52 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:52 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg blazepose +2022-08-28 13:10:52 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.99,"keypoints":39} +2022-08-28 13:10:52 DATA:  test-node-wasm.js result: performance: load: null total: 404 +2022-08-28 13:10:52 STATE: test-node-wasm.js passed: blazepose +2022-08-28 13:10:52 STATE: test-node-wasm.js start efficientpose +2022-08-28 13:10:53 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:53 STATE: test-node-wasm.js event: image +2022-08-28 13:10:54 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:54 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg efficientpose +2022-08-28 13:10:54 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.75,"keypoints":13} +2022-08-28 13:10:54 DATA:  test-node-wasm.js result: performance: load: null total: 656 +2022-08-28 13:10:54 STATE: test-node-wasm.js passed: efficientpose +2022-08-28 13:10:54 STATE: test-node-wasm.js start posenet +2022-08-28 13:10:54 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:54 STATE: test-node-wasm.js event: image +2022-08-28 13:10:55 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg posenet +2022-08-28 13:10:55 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.96,"keypoints":16} +2022-08-28 13:10:55 DATA:  test-node-wasm.js result: performance: load: null total: 282 +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: posenet +2022-08-28 13:10:55 STATE: test-node-wasm.js start movenet +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:55 STATE: test-node-wasm.js event: image +2022-08-28 13:10:55 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg movenet +2022-08-28 13:10:55 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 10 object: 0 person: 1 {"score":1,"age":29.6,"gender":"female"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:55 DATA:  test-node-wasm.js result: performance: load: null total: 248 +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: movenet +2022-08-28 13:10:55 INFO:  test-node-wasm.js test face matching +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: face database 40 +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: face match {"first":{"index":4,"similarity":0.7827852754786533}} {"second":{"index":4,"similarity":0.5660821189104794}} {"third":{"index":4,"similarity":0.45074189882665594}} +2022-08-28 13:10:55 INFO:  test-node-wasm.js test face similarity alternative +2022-08-28 13:10:55 STATE: test-node-wasm.js start face embeddings +2022-08-28 13:10:55 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:55 STATE: test-node-wasm.js event: image +2022-08-28 13:10:56 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:56 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face embeddings +2022-08-28 13:10:56 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:56 DATA:  test-node-wasm.js result: performance: load: null total: 257 +2022-08-28 13:10:56 STATE: test-node-wasm.js passed: mobilefacenet {"embedding":192} +2022-08-28 13:10:56 STATE: test-node-wasm.js start face embeddings +2022-08-28 13:10:56 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:56 STATE: test-node-wasm.js event: image +2022-08-28 13:10:57 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:57 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face embeddings +2022-08-28 13:10:57 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:57 DATA:  test-node-wasm.js result: performance: load: null total: 281 +2022-08-28 13:10:57 STATE: test-node-wasm.js passed: insightface {"embedding":512} +2022-08-28 13:10:57 INFO:  test-node-wasm.js test face attention +2022-08-28 13:10:57 STATE: test-node-wasm.js start face attention +2022-08-28 13:10:57 WARN:  test-node-wasm.js missing kernel ops {"title":"face attention","model":"facemesh","url":"https://vladmandic.github.io/human-models/models/facemesh-attention.json","missing":["atan2"],"backkend":"wasm"} +2022-08-28 13:10:57 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:57 STATE: test-node-wasm.js event: image +2022-08-28 13:10:57 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:57 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg face attention +2022-08-28 13:10:57 DATA:  test-node-wasm.js result: face: 0 body: 1 hand: 1 gesture: 2 object: 0 person: 0 {} {} {"score":0.47,"keypoints":3} +2022-08-28 13:10:57 DATA:  test-node-wasm.js result: performance: load: null total: 114 +2022-08-28 13:10:57 ERROR: test-node-wasm.js failed: face attention {"annotations":0} +2022-08-28 13:10:57 INFO:  test-node-wasm.js test detectors +2022-08-28 13:10:57 STATE: test-node-wasm.js start detectors +2022-08-28 13:10:57 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:57 STATE: test-node-wasm.js event: image +2022-08-28 13:10:58 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg detectors +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: performance: load: null total: 115 +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: detector result face match +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: detector result hand match +2022-08-28 13:10:58 INFO:  test-node-wasm.js test: multi-instance +2022-08-28 13:10:58 STATE: test-node-wasm.js start multi instance +2022-08-28 13:10:58 STATE: test-node-wasm.js event: image +2022-08-28 13:10:58 STATE: test-node-wasm.js event: detect +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: detect: random multi instance +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: performance: load: null total: 92 +2022-08-28 13:10:58 INFO:  test-node-wasm.js test: first instance +2022-08-28 13:10:58 STATE: test-node-wasm.js start multi instance +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg multi instance +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: performance: load: null total: 104 +2022-08-28 13:10:58 INFO:  test-node-wasm.js test: second instance +2022-08-28 13:10:58 STATE: test-node-wasm.js start multi instance +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg multi instance +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:10:58 DATA:  test-node-wasm.js result: performance: load: null total: 105 +2022-08-28 13:10:58 INFO:  test-node-wasm.js test: concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js start concurrent +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:58 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:59 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:59 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2022-08-28 13:10:59 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2022-08-28 13:10:59 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:10:59 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:10:59 STATE: test-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2022-08-28 13:10:59 STATE: test-node-wasm.js event: image +2022-08-28 13:10:59 STATE: test-node-wasm.js event: image +2022-08-28 13:10:59 STATE: test-node-wasm.js event: image +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 1269 +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 1269 +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 1269 +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 1269 +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 1269 +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 1269 +2022-08-28 13:11:00 STATE: test-node-wasm.js event: detect +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-upper.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 0 gesture: 0 object: 0 person: 1 {"score":0.96,"gender":"unknown"} {} {"score":0.75,"keypoints":7} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 967 +2022-08-28 13:11:00 STATE: test-node-wasm.js event: detect +2022-08-28 13:11:00 STATE: test-node-wasm.js event: detect +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-face.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.91,"gender":"unknown"} {} {"score":0.47,"keypoints":3} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 967 +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: detect: samples/in/ai-body.jpg concurrent +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: face: 1 body: 1 hand: 1 gesture: 0 object: 0 person: 1 {"score":0.93,"gender":"unknown"} {} {"score":0.92,"keypoints":17} +2022-08-28 13:11:00 DATA:  test-node-wasm.js result: performance: load: null total: 967 +2022-08-28 13:11:00 INFO:  test-node-wasm.js test: monkey-patch +2022-08-28 13:11:00 STATE: test-node-wasm.js event: image +2022-08-28 13:11:00 STATE: test-node-wasm.js event: detect +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: monkey patch +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: segmentation [65536] +2022-08-28 13:11:00 STATE: test-node-wasm.js passeed: equal usage +2022-08-28 13:11:00 INFO:  test-node-wasm.js test: input compare +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2022-08-28 13:11:00 STATE: test-node-wasm.js passed: image compare 0 23.280073018790848 +2022-08-28 13:11:00 INFO:  test-node-wasm.js events: {"image":29,"detect":29,"warmup":2} +2022-08-28 13:11:00 INFO:  test-node-wasm.js tensors 4107 +2022-08-28 13:11:00 INFO:  test-node-wasm.js test complete: 21212 ms +2022-08-28 13:11:00 STATE: all tests complete +2022-08-28 13:11:00 INFO:  status {"test":"../demo/nodejs/node.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/nodejs/node-simple.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/nodejs/node-fetch.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/nodejs/node-event.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/nodejs/node-similarity.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/nodejs/node-canvas.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/multithread/node-multiprocess.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"../demo/facematch/node-match.js","passed":1,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"test-node.js","passed":125,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"test-node-gpu.js","passed":125,"failed":0} +2022-08-28 13:11:00 INFO:  status {"test":"test-node-wasm.js","passed":124,"failed":2} +2022-08-28 13:11:00 INFO:  failures {"count":2} +2022-08-28 13:11:00 WARN:  failed {"test":"test-node-wasm.js","message":["error",["failed: nanodet",[]]]} +2022-08-28 13:11:00 WARN:  failed {"test":"test-node-wasm.js","message":["error",["failed: face attention",{"annotations":0}]]}