diff --git a/CHANGELOG.md b/CHANGELOG.md index 3d794595..578c8328 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ # @vladmandic/human - Version: **3.1.1** + Version: **3.1.2** Description: **Human: AI-powered 3D Face Detection & Rotation Tracking, Face Description & Recognition, Body Pose Tracking, 3D Hand & Finger Tracking, Iris Analysis, Age & Gender & Emotion Prediction, Gesture Recognition** Author: **Vladimir Mandic ** @@ -9,7 +9,11 @@ ## Changelog -### **HEAD -> main** 2023/08/07 mandic00@live.com +### **3.1.2** 2023/09/18 mandic00@live.com + +- major toolkit upgrade + +### **origin/main** 2023/08/07 mandic00@live.com - full rebuild - major toolkit upgrade diff --git a/dist/human.esm-nobundle.js b/dist/human.esm-nobundle.js index 96aa8d8c..dc3875dd 100644 --- a/dist/human.esm-nobundle.js +++ b/dist/human.esm-nobundle.js @@ -96,7 +96,7 @@ var at=Object.defineProperty;var Jn=Object.getOwnPropertyDescriptor;var Qn=Objec c31 * m[6] + c32 * m[7] + c33 * m[8]; gl_FragColor.a = c22.a; } -`;var lt=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(s,A)=>(n[A]=0,s))},ct=class{constructor(t,n,o){z(this,"uniform",{});z(this,"attribute",{});z(this,"gl");z(this,"id");z(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(b(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(b("filter: could not create shader"),null)});this.gl=t;let s=this.compile(n,this.gl.VERTEX_SHADER),A=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!s||!A)){if(!this.id){b("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,s),this.gl.attachShader(this.id,A),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){b(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),lt(n,"attribute",this.attribute);for(let a in this.attribute)this.attribute[a]=this.gl.getAttribLocation(this.id,a);lt(n,"uniform",this.uniform),lt(o,"uniform",this.uniform);for(let a in this.uniform)this.uniform[a]=this.gl.getUniformLocation(this.id,a)}}};function e1(){let e=0,t=null,n=!1,o=-1,s=[null,null],A=[],a=null,i=null,c=D0(100,100),d={},y={INTERMEDIATE:1},l=c.getContext("webgl");if(!l){b("filter: cannot get webgl context");return}this.gl=l;function m(T,u){if(!(T===c.width&&u===c.height)){if(c.width=T,c.height=u,!a){let g=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);a=l.createBuffer(),l.bindBuffer(l.ARRAY_BUFFER,a),l.bufferData(l.ARRAY_BUFFER,g,l.STATIC_DRAW),l.pixelStorei(l.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}l.viewport(0,0,c.width,c.height),s=[null,null]}}function x(T,u){let g=l.createFramebuffer();l.bindFramebuffer(l.FRAMEBUFFER,g);let w=l.createRenderbuffer();l.bindRenderbuffer(l.RENDERBUFFER,w);let k=l.createTexture();return l.bindTexture(l.TEXTURE_2D,k),l.texImage2D(l.TEXTURE_2D,0,l.RGBA,T,u,0,l.RGBA,l.UNSIGNED_BYTE,null),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MAG_FILTER,l.LINEAR),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.LINEAR),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.CLAMP_TO_EDGE),l.framebufferTexture2D(l.FRAMEBUFFER,l.COLOR_ATTACHMENT0,l.TEXTURE_2D,k,0),l.bindTexture(l.TEXTURE_2D,null),l.bindFramebuffer(l.FRAMEBUFFER,null),{fbo:g,texture:k}}function p(T){return s[T]=s[T]||x(c.width,c.height),s[T]}function f(T=0){if(!i)return;let u=null,g=null,w=!1;e===0?u=t:u=p(o).texture||null,e++,n&&!(T&y.INTERMEDIATE)?(g=null,w=e%2===0):(o=(o+1)%2,g=p(o).fbo||null),l.bindTexture(l.TEXTURE_2D,u),l.bindFramebuffer(l.FRAMEBUFFER,g),l.uniform1f(i.uniform.flipY,w?-1:1),l.drawArrays(l.TRIANGLES,0,6)}function h(T){if(d[T])return i=d[T],l.useProgram((i?i.id:null)||null),i;if(i=new ct(l,Y5,T),!i)return b("filter: could not get webgl program"),null;let u=Float32Array.BYTES_PER_ELEMENT,g=4*u;return l.enableVertexAttribArray(i.attribute.pos),l.vertexAttribPointer(i.attribute.pos,2,l.FLOAT,!1,g,0*u),l.enableVertexAttribArray(i.attribute.uv),l.vertexAttribPointer(i.attribute.uv,2,l.FLOAT,!1,g,2*u),d[T]=i,i}let v={colorMatrix:T=>{let u=new Float32Array(T);u[4]/=255,u[9]/=255,u[14]/=255,u[19]/=255;let g=u[18]===1&&u[3]===0&&u[8]===0&&u[13]===0&&u[15]===0&&u[16]===0&&u[17]===0&&u[19]===0?J5:K5,w=h(g);w&&(l.uniform1fv(w.uniform.m,u),f())},brightness:T=>{let u=(T||0)+1;v.colorMatrix([u,0,0,0,0,0,u,0,0,0,0,0,u,0,0,0,0,0,1,0])},saturation:T=>{let u=(T||0)*2/3+1,g=(u-1)*-.5;v.colorMatrix([u,g,g,0,0,g,u,g,0,0,g,g,u,0,0,0,0,0,1,0])},desaturate:()=>{v.saturation(-1)},contrast:T=>{let u=(T||0)+1,g=-128*(u-1);v.colorMatrix([u,0,0,0,g,0,u,0,0,g,0,0,u,0,g,0,0,0,1,0])},negative:()=>{v.contrast(-2)},hue:T=>{T=(T||0)/180*Math.PI;let u=Math.cos(T),g=Math.sin(T),w=.213,k=.715,N=.072;v.colorMatrix([w+u*(1-w)+g*-w,k+u*-k+g*-k,N+u*-N+g*(1-N),0,0,w+u*-w+g*.143,k+u*(1-k)+g*.14,N+u*-N+g*-.283,0,0,w+u*-w+g*-(1-w),k+u*-k+g*k,N+u*(1-N)+g*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{v.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{v.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{v.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{v.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{v.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{v.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{v.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{v.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:T=>{let u=new Float32Array(T),g=1/c.width,w=1/c.height,k=h($5);k&&(l.uniform1fv(k.uniform.m,u),l.uniform2f(k.uniform.px,g,w),f())},detectEdges:()=>{v.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{v.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{v.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:T=>{let u=T||1;v.convolution.call(this,[0,-1*u,0,-1*u,1+4*u,-1*u,0,-1*u,0])},emboss:T=>{let u=T||1;v.convolution.call(this,[-2*u,-1*u,0,-1*u,1,1*u,0,1*u,2*u])},blur:T=>{let u=T/7/c.width,g=T/7/c.height,w=h(_5);w&&(l.uniform2f(w.uniform.px,0,g),f(y.INTERMEDIATE),l.uniform2f(w.uniform.px,u,0),f())},pixelate:T=>{let u=T/c.width,g=T/c.height,w=h(Q5);w&&(l.uniform2f(w.uniform.size,u,g),f())}};this.add=function(T){let u=Array.prototype.slice.call(arguments,1),g=v[T];A.push({func:g,args:u})},this.reset=function(){A=[]},this.get=function(){return A},this.apply=function(T){m(T.width,T.height),e=0,t||(t=l.createTexture()),l.bindTexture(l.TEXTURE_2D,t),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.NEAREST),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MAG_FILTER,l.NEAREST),l.texImage2D(l.TEXTURE_2D,0,l.RGBA,l.RGBA,l.UNSIGNED_BYTE,T);for(let u=0;uy.data())),a=Math.max(A[0][0],A[1][0],A[2][0]),c=(a>1?255:1)/a,d;if(c>1){let y=[r.sub(n[0],o[0]),r.sub(n[1],o[1]),r.sub(n[2],o[2])],l=[r.sub(s[0],o[0]),r.sub(s[1],o[1]),r.sub(s[2],o[2])],m=[r.mul(y[0],c),r.mul(y[1],c),r.mul(y[2],c)],x=r.stack([m[0],m[1],m[2]],2);d=r.reshape(x,[1,t.shape[0]||0,t.shape[1]||0,3]),r.dispose([...y,...l,...m,x])}else d=r.expandDims(t,0);return r.dispose([...n,...o,...s,n,t,e]),d}var x2=3840,l0=null,c0=null,We=null,X,L0={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function dt(){L0.inputSum=0,L0.cacheDiff=1,L0.sumMethod=0,L0.inputTensor=void 0}function D0(e,t){let n;if(M.browser)if(M.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof M.Canvas!="undefined")n=new M.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof M.Canvas!="undefined"?n=new M.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function y2(e,t){let n=t||D0(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function f2(e,t,n=!0){var m,x,p;if(!e)return t.debug&&b("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof r.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof r.Tensor){let f=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)f=r.expandDims(e,0);else if(e.shape[2]===4){let h=r.slice3d(e,[0,0,0],[-1,-1,3]);f=r.expandDims(h,0),r.dispose(h)}}else e.shape.length===4&&(e.shape[3]===3?f=r.clone(e):e.shape[3]===4&&(f=r.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(f==null||f.shape.length!==4||f.shape[0]!==1||f.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(f.dtype==="int32"){let h=r.cast(f,"float32");r.dispose(f),f=h}return{tensor:f,canvas:t.filter.return?c0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&b("input stream is not ready"),{tensor:null,canvas:l0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,s=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!s)return t.debug&&b("cannot determine input dimensions"),{tensor:null,canvas:l0};let A=o,a=s;if(A>x2&&(A=x2,a=Math.trunc(A*s/o)),a>x2&&(a=x2,A=Math.trunc(a*o/s)),(((m=t.filter)==null?void 0:m.width)||0)>0?A=t.filter.width:(((x=t.filter)==null?void 0:x.height)||0)>0&&(A=o*((t.filter.height||0)/s)),(t.filter.height||0)>0?a=t.filter.height:(t.filter.width||0)>0&&(a=s*((t.filter.width||0)/o)),!A||!a)throw new Error("input error: cannot determine dimension");(!l0||l0.width!==A||l0.height!==a)&&(l0=D0(A,a));let i=l0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?i.putImageData(e,0,0):t.filter.flip&&typeof i.translate!="undefined"?(i.translate(o,0),i.scale(-1,1),i.drawImage(e,0,0,o,s,0,0,l0.width,l0.height),i.setTransform(1,0,0,1,0,0)):i.drawImage(e,0,0,o,s,0,0,l0.width,l0.height),(!c0||l0.width!==c0.width||l0.height!==c0.height)&&(c0=D0(l0.width,l0.height)),t.filter.enabled&&M.webgl.supported?(X||(X=M.browser?new e1:null),M.filter=!!X,X!=null&&X.add?(X.reset(),t.filter.brightness!==0&&X.add("brightness",t.filter.brightness),t.filter.contrast!==0&&X.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&X.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&X.add("blur",t.filter.blur),t.filter.saturation!==0&&X.add("saturation",t.filter.saturation),t.filter.hue!==0&&X.add("hue",t.filter.hue),t.filter.negative&&X.add("negative"),t.filter.sepia&&X.add("sepia"),t.filter.vintage&&X.add("brownie"),t.filter.sepia&&X.add("sepia"),t.filter.kodachrome&&X.add("kodachrome"),t.filter.technicolor&&X.add("technicolor"),t.filter.polaroid&&X.add("polaroid"),t.filter.pixelate!==0&&X.add("pixelate",t.filter.pixelate),((p=X.get())==null?void 0:p.length)>1?c0=X.apply(l0):c0=X.draw(l0)):(t.debug&&b("input process error: cannot initialize filters"),M.webgl.supported=!1,t.filter.enabled=!1,y2(l0,c0))):(y2(l0,c0),X&&(X=null),M.filter=!!X),!n)return{tensor:null,canvas:c0};if(!c0)throw new Error("canvas error: cannot create output");let c,d=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(M.browser&&r.browser)c=r.browser?r.browser.fromPixels(e):null;else{d=e.data.length/e.height/e.width;let f=new Uint8Array(e.data.buffer);c=r.tensor(f,[e.height,e.width,d],"int32")}else if((!We||c0.width!==We.width||c0.height!==We.height)&&(We=D0(c0.width,c0.height)),r.browser&&M.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?c=r.browser.fromPixels(c0):(We=y2(c0),c=r.browser.fromPixels(We));else{let v=y2(c0).getContext("2d").getImageData(0,0,A,a);d=v.data.length/A/a;let T=new Uint8Array(v.data.buffer);c=r.tensor(T,[A,a,d])}if(d===4){let f=r.slice3d(c,[0,0,0],[-1,-1,3]);r.dispose(c),c=f}if(!c)throw new Error("input error: cannot create tensor");let y=r.cast(c,"float32"),l=t.filter.equalization?await d2(y):r.expandDims(y,0);if(r.dispose([c,y]),t.filter.autoBrightness){let f=r.max(l),h=await f.data();t.filter.brightness=h[0]>1?1-h[0]/255:1-h[0],r.dispose(f)}return{tensor:l,canvas:t.filter.return?c0:null}}async function t1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!L0.inputTensor)L0.inputTensor=r.clone(t);else if(L0.inputTensor.shape[1]!==t.shape[1]||L0.inputTensor.shape[2]!==t.shape[2])r.dispose(L0.inputTensor),L0.inputTensor=r.clone(t);else{let o={};o.diff=r.sub(t,L0.inputTensor),o.squared=r.mul(o.diff,o.diff),o.sum=r.sum(o.squared);let A=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;r.dispose([L0.inputTensor,o.diff,o.squared,o.sum]),L0.inputTensor=r.clone(t),n=A<=(e.cacheSensitivity||0)}return n}async function n1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||b("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||b("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=r.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?r.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):r.clone(n),o.diff=r.sub(o.input1,o.input2),o.squared=r.mul(o.diff,o.diff),o.sum=r.sum(o.squared);let A=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return r.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),A}var Qe,_e,$e,p2=class{constructor(){z(this,"browser");z(this,"node");z(this,"worker");z(this,"platform","");z(this,"agent","");z(this,"backends",[]);z(this,"initial");z(this,"filter");z(this,"tfjs");z(this,"offscreen");z(this,"perfadd",!1);z(this,"tensorflow",{version:void 0,gpu:void 0});z(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});z(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});z(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});z(this,"cpu",{model:void 0,flags:[]});z(this,"kernels",[]);q0(this,Qe,void 0);q0(this,_e,void 0);q0(this,$e,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:Je["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return E0(this,Qe)}set Canvas(t){Q0(this,Qe,t),globalThis.Canvas=t}get Image(){return E0(this,_e)}set Image(t){Q0(this,_e,t),globalThis.Image=t}get ImageData(){return E0(this,$e)}set ImageData(t){Q0(this,$e,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(r.engine().registryFactory);try{this.tensorflow={version:r.backend().binding?r.backend().binding.TF_Version:void 0,gpu:r.backend().binding?r.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await r.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await r.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=D0(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=r.getKernelsForBackend(r.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};Qe=new WeakMap,_e=new WeakMap,$e=new WeakMap;var M=new p2;var u2=class{constructor(){z(this,"config");z(this,"element");z(this,"stream");z(this,"devices",[]);z(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});z(this,"start",async t=>{var s,A;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let a=document.getElementById(t.element);if(a&&a instanceof HTMLVideoElement)this.element=a;else return this.config.debug&&b("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&b("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((s=this.config)==null?void 0:s.width)>0&&(n.video.width={ideal:this.config.width}),((A=this.config)==null?void 0:A.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&b("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&b("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&b("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(a){return b("webcam",a),`webcam error: ${a}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(a=>{this.element?this.element.onloadeddata=()=>a(!0):a(!1)}),await this.element.play(),this.config.debug&&b("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&b("webcam error","no stream"),"webcam error no stream")});z(this,"pause",()=>{this.element&&this.element.pause()});z(this,"play",async()=>{this.element&&await this.element.play()});z(this,"stop",()=>{this.config.debug&&b("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var xt={};oe(xt,{"affectnet-mobilenet":()=>To,age:()=>vo,"anti-spoofing":()=>er,antispoof:()=>io,blazeface:()=>lo,"blazeface-back":()=>Ro,"blazeface-front":()=>Mo,"blazepose-detector":()=>Po,"blazepose-full":()=>ko,"blazepose-heavy":()=>wo,"blazepose-lite":()=>Eo,centernet:()=>co,default:()=>yr,efficientpose:()=>zo,"efficientpose-i-lite":()=>tr,"efficientpose-ii-lite":()=>nr,"efficientpose-iv":()=>or,emotion:()=>xo,faceboxes:()=>So,facemesh:()=>yo,"facemesh-attention":()=>Io,"facemesh-attention-pinto":()=>jo,"facemesh-detection-full":()=>No,"facemesh-detection-short":()=>Lo,faceres:()=>fo,"faceres-deep":()=>Oo,gear:()=>Do,"gear-e1":()=>Co,"gear-e2":()=>Wo,gender:()=>Bo,"gender-ssrnet-imdb":()=>Fo,handdetect:()=>Ho,"handlandmark-full":()=>Go,"handlandmark-lite":()=>mo,"handlandmark-sparse":()=>Vo,handskeleton:()=>Zo,handtrack:()=>po,"insightface-efficientnet-b0":()=>rr,"insightface-ghostnet-strides1":()=>sr,"insightface-ghostnet-strides2":()=>Ar,"insightface-mobilenet-emore":()=>ar,"insightface-mobilenet-swish":()=>ir,iris:()=>uo,liveness:()=>ho,meet:()=>Xo,mobileface:()=>qo,mobilefacenet:()=>Uo,models:()=>bo,"movenet-lightning":()=>go,"movenet-multipose":()=>Yo,"movenet-thunder":()=>Ko,nanodet:()=>Jo,"nanodet-e":()=>lr,"nanodet-g":()=>cr,"nanodet-m":()=>dr,"nanodet-t":()=>xr,posenet:()=>Qo,rvm:()=>_o,selfie:()=>$o});var io=853098,lo=538928,co=4030290,xo=820516,yo=1477958,fo=6978814,mo=2023432,po=2964837,uo=2599092,ho=592976,bo=0,go=4650216,To=6920630,vo=161240,Ro=538928,Mo=402048,Po=5928856,ko=6339202,wo=27502466,Eo=2726402,zo=5651240,So=2013002,jo=2387598,Io=2382414,No=1026192,Lo=201268,Oo=13957620,Co=112438,Wo=112438,Do=1498916,Fo=161236,Bo=201808,Ho=3515612,Go=5431368,Vo=5286322,Zo=5502280,Xo=372228,qo=2183192,Uo=5171976,Yo=9448838,Ko=12477112,Jo=7574558,Qo=5032780,_o=3739355,$o=212886,er=853098,tr=2269064,nr=5651240,or=25643252,rr=13013224,sr=8093408,Ar=8049584,ar=6938536,ir=12168584,lr=12319156,cr=7574558,dr=1887474,xr=5294216,yr={antispoof:io,blazeface:lo,centernet:co,emotion:xo,facemesh:yo,faceres:fo,"handlandmark-lite":mo,handtrack:po,iris:uo,liveness:ho,models:bo,"movenet-lightning":go,"affectnet-mobilenet":To,age:vo,"blazeface-back":Ro,"blazeface-front":Mo,"blazepose-detector":Po,"blazepose-full":ko,"blazepose-heavy":wo,"blazepose-lite":Eo,efficientpose:zo,faceboxes:So,"facemesh-attention-pinto":jo,"facemesh-attention":Io,"facemesh-detection-full":No,"facemesh-detection-short":Lo,"faceres-deep":Oo,"gear-e1":Co,"gear-e2":Wo,gear:Do,"gender-ssrnet-imdb":Fo,gender:Bo,handdetect:Ho,"handlandmark-full":Go,"handlandmark-sparse":Vo,handskeleton:Zo,meet:Xo,mobileface:qo,mobilefacenet:Uo,"movenet-multipose":Yo,"movenet-thunder":Ko,nanodet:Jo,posenet:Qo,rvm:_o,selfie:$o,"anti-spoofing":er,"efficientpose-i-lite":tr,"efficientpose-ii-lite":nr,"efficientpose-iv":or,"insightface-efficientnet-b0":rr,"insightface-ghostnet-strides1":sr,"insightface-ghostnet-strides2":Ar,"insightface-mobilenet-emore":ar,"insightface-mobilenet-swish":ir,"nanodet-e":lr,"nanodet-g":cr,"nanodet-m":dr,"nanodet-t":xr};var T0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},p0={};async function fr(e,t){return T0.debug&&b("load model fetch:",e,t),fetch(e,t)}function o1(e){T0.cacheModels=e.cacheModels,T0.verbose=e.debug,T0.modelBasePath=e.modelBasePath}async function L(e){var d,y,l,m;let t=U5(T0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),s="indexeddb://"+o;p0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:xt[o],inCache:!1,url:""},T0.cacheSupported=typeof indexedDB!="undefined";let A={};try{A=T0.cacheSupported&&T0.cacheModels?await r.io.listModels():{}}catch(x){T0.cacheSupported=!1}p0[o].inCache=T0.cacheSupported&&T0.cacheModels&&Object.keys(A).includes(s),p0[o].url=p0[o].inCache?s:t;let a=typeof fetch=="undefined"?{}:{fetchFunc:(x,p)=>fr(x,p)},i=new r.GraphModel(p0[o].url,a),c=!1;try{i.findIOHandler(),T0.debug&&b("model load handler:",i.handler)}catch(x){b("error finding model i/o handler:",t,x)}try{let x=await((d=i.handler)==null?void 0:d.load())||null;p0[o].sizeFromManifest=((y=x==null?void 0:x.weightData)==null?void 0:y.byteLength)||0,x?i.loadSync(x):i=await r.loadGraphModel(p0[o].inCache?s:t,a),p0[o].sizeLoadedWeights=((m=(l=i.artifacts)==null?void 0:l.weightData)==null?void 0:m.byteLength)||0,T0.verbose&&b("load:",{model:o,url:i.modelUrl,bytes:p0[o].sizeLoadedWeights}),c=!0}catch(x){b("error loading model:",t,x)}if(c&&T0.cacheModels&&T0.cacheSupported&&!p0[o].inCache)try{let x=await i.save(s);T0.debug&&b("model saved:",s,x)}catch(x){b("error saving model:",t,x)}return i}var yt="3.1.1";var Y={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ur(){let e=Y.gl;e&&(Y.extensions=e.getSupportedExtensions())}function r1(e){var t;if(e.config.backend==="humangl"&&(Y.name in r.engine().registry&&!((t=Y==null?void 0:Y.gl)!=null&&t.getParameter(Y.gl.VERSION))&&(b("humangl error: backend invalid context"),e.models.reset()),!r.findBackend(Y.name))){try{Y.canvas=D0(100,100)}catch(s){b("humangl error: cannot create canvas:",s);return}try{if(Y.gl=Y.canvas.getContext("webgl2",Y.webGLattr),!Y.gl){b("humangl error: cannot get webgl context");return}if(!Y.gl.getParameter(Y.gl.VERSION).includes("2.0")){b("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}Y.canvas&&(Y.canvas.addEventListener("webglcontextlost",A=>{throw b("humangl error:",A.type),b("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),Y.canvas.addEventListener("webglcontextrestored",A=>{b("humangl error: context restored:",A)}),Y.canvas.addEventListener("webglcontextcreationerror",A=>{b("humangl error: context create:",A)}))}catch(s){b("humangl error: cannot get webgl context:",s);return}try{r.setWebGLContext(2,Y.gl)}catch(s){b("humangl error: cannot set webgl context:",s);return}try{let s=new r.GPGPUContext(Y.gl);r.registerBackend(Y.name,()=>new r.MathBackendWebGL(s),Y.priority)}catch(s){b("humangl error: cannot register webgl backend:",s);return}try{r.getKernelsForBackend("webgl").forEach(A=>{let a={...A,backendName:Y.name};r.registerKernel(a)})}catch(s){b("humangl error: cannot update webgl backend registration:",s);return}try{r.env().flagRegistry.WEBGL_VERSION&&r.env().set("WEBGL_VERSION",2)}catch(s){b("humangl error: cannot set WebGL backend flags:",s);return}ur();let n=r.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&b("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):b("humangl error: no current gl context:",o,Y.gl)}}var O={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function s1(){O.tf255=r.scalar(255,"float32"),O.tf1=r.scalar(1,"float32"),O.tf2=r.scalar(2,"float32"),O.tf05=r.scalar(.5,"float32"),O.tf127=r.scalar(127.5,"float32"),O.rgb=r.tensor1d([.2989,.587,.114],"float32")}async function gr(){var e;return await M.updateBackend(),(e=M.tensorflow)!=null&&e.version?"tensorflow":M.webgpu.supported&&M.webgpu.backend?"webgpu":M.webgl.supported&&M.webgl.backend?"webgl":M.wasm.supported&&M.wasm.backend?"wasm":"cpu"}function Tr(e){let t=[];if(!M.kernels.includes("mod")){let n={kernelName:"Mod",backendName:r.getBackend(),kernelFunc:o=>r.tidy(()=>r.sub(o.inputs.a,r.mul(r.div(o.inputs.a,o.inputs.b),o.inputs.b)))};r.registerKernel(n),M.kernels.push("mod"),t.push("mod")}if(!M.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:r.getBackend(),kernelFunc:o=>r.tidy(()=>r.add(r.mul(r.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),r.mod(o.inputs.a,o.inputs.b)))};r.registerKernel(n),M.kernels.push("floormod"),t.push("floormod")}if(!M.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:r.getBackend(),kernelFunc:o=>r.tidy(()=>{let s=r.getBackend();r.setBackend("cpu");let A=r.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return r.setBackend(s),A})};r.registerKernel(n),M.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&b("registered kernels:",t)}var A1={};async function e2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await gr()),t||M.initial||e.config.backend&&e.config.backend.length>0&&r.getBackend()!==e.config.backend){let s=R();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&b("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&b("running inside electron");let A=Object.keys(r.engine().registryFactory);if(e.config.backend==="humangl"&&!A.includes("humangl")&&(r1(e),A=Object.keys(r.engine().registryFactory)),e.config.debug&&b("available backends:",A),M.browser&&!M.node&&e.config.backend==="tensorflow"&&A.includes("webgl")&&(e.config.debug&&b("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),M.node&&!M.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&A.includes("tensorflow")&&(e.config.debug&&b(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),M.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")b("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let a=await navigator.gpu.requestAdapter();if(e.config.debug&&b("enumerated webgpu adapter:",a),!a)b("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let i="requestAdapterInfo"in a?await a.requestAdapterInfo():void 0;b("webgpu adapter info:",i)}}if(A.includes(e.config.backend)||(b(`error: backend ${e.config.backend} not found in registry`),e.config.backend=M.node?"tensorflow":"webgl",e.config.debug&&b(`override: setting backend ${e.config.backend}`)),e.config.debug&&b("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(r.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&r.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&b("wasm path:",e.config.wasmPath),typeof r.setWasmPaths!="undefined")r.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let a=!1,i=!1;try{a=await r.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),i=await r.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&b(`wasm execution: ${i?"simd":"no simd"} ${a?"multithreaded":"singlethreaded"}`),e.config.debug&&!i&&b("warning: wasm simd support is not enabled")}catch(c){b("wasm detection failed")}}try{await r.setBackend(e.config.backend),await r.ready()}catch(a){return b("error: cannot set backend:",e.config.backend,a),!1}e.config.debug&&(A1=JSON.parse(JSON.stringify(r.env().flags)))}if((r.getBackend()==="humangl"||r.getBackend()==="webgl")&&(r.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&r.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),r.env().flagRegistry.WEBGL_EXP_CONV&&r.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(b("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),r.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),r.getBackend(),e.config.debug){let A=r.env().flags,a={};for(let i of Object.keys(A))A1[i]!==A[i]&&(a[i]=A[i]);e.config.debug&&Object.keys(a).length>0&&b("backend:",r.getBackend(),"flags:",a)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&b("flags:",e.config.flags);for(let[A,a]of Object.entries(e.config.flags))r.env().set(A,a)}r.enableProdMode(),s1(),e.performance.initBackend=Math.trunc(R()-s),e.config.backend=r.getBackend(),await M.updateBackend(),Tr(e.config)}return!0}function h2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:s=>{var A;return t.debug&&b("kernelFunc",n,t.backend,s),(A=s==null?void 0:s.inputs)==null?void 0:A.info}};r.registerKernel(o)}M.kernels=r.getKernelsForBackend(r.getBackend()).map(n=>n.kernelName.toLowerCase())}var Tt={};oe(Tt,{all:()=>_r,body:()=>g2,canvas:()=>Qr,face:()=>b2,gesture:()=>R2,hand:()=>T2,init:()=>gt,object:()=>v2,options:()=>n0,person:()=>Jr});var O0=e=>{if(!e)b("draw error: invalid canvas");else if(!e.getContext)b("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)b("draw error: cannot get canvas context");else return t}return null},ge=e=>Math.round(e*180/Math.PI),H=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Te=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function C0(e,t,n,o,s){let A=t.replace(/\[.*\]/g,"").split(` +`;var lt=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(s,A)=>(n[A]=0,s))},ct=class{constructor(t,n,o){z(this,"uniform",{});z(this,"attribute",{});z(this,"gl");z(this,"id");z(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(b(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(b("filter: could not create shader"),null)});this.gl=t;let s=this.compile(n,this.gl.VERTEX_SHADER),A=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!s||!A)){if(!this.id){b("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,s),this.gl.attachShader(this.id,A),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){b(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),lt(n,"attribute",this.attribute);for(let a in this.attribute)this.attribute[a]=this.gl.getAttribLocation(this.id,a);lt(n,"uniform",this.uniform),lt(o,"uniform",this.uniform);for(let a in this.uniform)this.uniform[a]=this.gl.getUniformLocation(this.id,a)}}};function e1(){let e=0,t=null,n=!1,o=-1,s=[null,null],A=[],a=null,i=null,c=D0(100,100),d={},y={INTERMEDIATE:1},l=c.getContext("webgl");if(!l){b("filter: cannot get webgl context");return}this.gl=l;function m(T,u){if(!(T===c.width&&u===c.height)){if(c.width=T,c.height=u,!a){let g=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);a=l.createBuffer(),l.bindBuffer(l.ARRAY_BUFFER,a),l.bufferData(l.ARRAY_BUFFER,g,l.STATIC_DRAW),l.pixelStorei(l.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}l.viewport(0,0,c.width,c.height),s=[null,null]}}function x(T,u){let g=l.createFramebuffer();l.bindFramebuffer(l.FRAMEBUFFER,g);let w=l.createRenderbuffer();l.bindRenderbuffer(l.RENDERBUFFER,w);let k=l.createTexture();return l.bindTexture(l.TEXTURE_2D,k),l.texImage2D(l.TEXTURE_2D,0,l.RGBA,T,u,0,l.RGBA,l.UNSIGNED_BYTE,null),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MAG_FILTER,l.LINEAR),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.LINEAR),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.CLAMP_TO_EDGE),l.framebufferTexture2D(l.FRAMEBUFFER,l.COLOR_ATTACHMENT0,l.TEXTURE_2D,k,0),l.bindTexture(l.TEXTURE_2D,null),l.bindFramebuffer(l.FRAMEBUFFER,null),{fbo:g,texture:k}}function p(T){return s[T]=s[T]||x(c.width,c.height),s[T]}function f(T=0){if(!i)return;let u=null,g=null,w=!1;e===0?u=t:u=p(o).texture||null,e++,n&&!(T&y.INTERMEDIATE)?(g=null,w=e%2===0):(o=(o+1)%2,g=p(o).fbo||null),l.bindTexture(l.TEXTURE_2D,u),l.bindFramebuffer(l.FRAMEBUFFER,g),l.uniform1f(i.uniform.flipY,w?-1:1),l.drawArrays(l.TRIANGLES,0,6)}function h(T){if(d[T])return i=d[T],l.useProgram((i?i.id:null)||null),i;if(i=new ct(l,Y5,T),!i)return b("filter: could not get webgl program"),null;let u=Float32Array.BYTES_PER_ELEMENT,g=4*u;return l.enableVertexAttribArray(i.attribute.pos),l.vertexAttribPointer(i.attribute.pos,2,l.FLOAT,!1,g,0*u),l.enableVertexAttribArray(i.attribute.uv),l.vertexAttribPointer(i.attribute.uv,2,l.FLOAT,!1,g,2*u),d[T]=i,i}let v={colorMatrix:T=>{let u=new Float32Array(T);u[4]/=255,u[9]/=255,u[14]/=255,u[19]/=255;let g=u[18]===1&&u[3]===0&&u[8]===0&&u[13]===0&&u[15]===0&&u[16]===0&&u[17]===0&&u[19]===0?J5:K5,w=h(g);w&&(l.uniform1fv(w.uniform.m,u),f())},brightness:T=>{let u=(T||0)+1;v.colorMatrix([u,0,0,0,0,0,u,0,0,0,0,0,u,0,0,0,0,0,1,0])},saturation:T=>{let u=(T||0)*2/3+1,g=(u-1)*-.5;v.colorMatrix([u,g,g,0,0,g,u,g,0,0,g,g,u,0,0,0,0,0,1,0])},desaturate:()=>{v.saturation(-1)},contrast:T=>{let u=(T||0)+1,g=-128*(u-1);v.colorMatrix([u,0,0,0,g,0,u,0,0,g,0,0,u,0,g,0,0,0,1,0])},negative:()=>{v.contrast(-2)},hue:T=>{T=(T||0)/180*Math.PI;let u=Math.cos(T),g=Math.sin(T),w=.213,k=.715,N=.072;v.colorMatrix([w+u*(1-w)+g*-w,k+u*-k+g*-k,N+u*-N+g*(1-N),0,0,w+u*-w+g*.143,k+u*(1-k)+g*.14,N+u*-N+g*-.283,0,0,w+u*-w+g*-(1-w),k+u*-k+g*k,N+u*(1-N)+g*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{v.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{v.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{v.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{v.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{v.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{v.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{v.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{v.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:T=>{let u=new Float32Array(T),g=1/c.width,w=1/c.height,k=h($5);k&&(l.uniform1fv(k.uniform.m,u),l.uniform2f(k.uniform.px,g,w),f())},detectEdges:()=>{v.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{v.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{v.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:T=>{let u=T||1;v.convolution.call(this,[0,-1*u,0,-1*u,1+4*u,-1*u,0,-1*u,0])},emboss:T=>{let u=T||1;v.convolution.call(this,[-2*u,-1*u,0,-1*u,1,1*u,0,1*u,2*u])},blur:T=>{let u=T/7/c.width,g=T/7/c.height,w=h(_5);w&&(l.uniform2f(w.uniform.px,0,g),f(y.INTERMEDIATE),l.uniform2f(w.uniform.px,u,0),f())},pixelate:T=>{let u=T/c.width,g=T/c.height,w=h(Q5);w&&(l.uniform2f(w.uniform.size,u,g),f())}};this.add=function(T){let u=Array.prototype.slice.call(arguments,1),g=v[T];A.push({func:g,args:u})},this.reset=function(){A=[]},this.get=function(){return A},this.apply=function(T){m(T.width,T.height),e=0,t||(t=l.createTexture()),l.bindTexture(l.TEXTURE_2D,t),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_S,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_WRAP_T,l.CLAMP_TO_EDGE),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MIN_FILTER,l.NEAREST),l.texParameteri(l.TEXTURE_2D,l.TEXTURE_MAG_FILTER,l.NEAREST),l.texImage2D(l.TEXTURE_2D,0,l.RGBA,l.RGBA,l.UNSIGNED_BYTE,T);for(let u=0;uy.data())),a=Math.max(A[0][0],A[1][0],A[2][0]),c=(a>1?255:1)/a,d;if(c>1){let y=[r.sub(n[0],o[0]),r.sub(n[1],o[1]),r.sub(n[2],o[2])],l=[r.sub(s[0],o[0]),r.sub(s[1],o[1]),r.sub(s[2],o[2])],m=[r.mul(y[0],c),r.mul(y[1],c),r.mul(y[2],c)],x=r.stack([m[0],m[1],m[2]],2);d=r.reshape(x,[1,t.shape[0]||0,t.shape[1]||0,3]),r.dispose([...y,...l,...m,x])}else d=r.expandDims(t,0);return r.dispose([...n,...o,...s,n,t,e]),d}var x2=3840,l0=null,c0=null,We=null,X,L0={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function dt(){L0.inputSum=0,L0.cacheDiff=1,L0.sumMethod=0,L0.inputTensor=void 0}function D0(e,t){let n;if(M.browser)if(M.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof M.Canvas!="undefined")n=new M.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof M.Canvas!="undefined"?n=new M.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function y2(e,t){let n=t||D0(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function f2(e,t,n=!0){var m,x,p;if(!e)return t.debug&&b("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof r.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof r.Tensor){let f=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)f=r.expandDims(e,0);else if(e.shape[2]===4){let h=r.slice3d(e,[0,0,0],[-1,-1,3]);f=r.expandDims(h,0),r.dispose(h)}}else e.shape.length===4&&(e.shape[3]===3?f=r.clone(e):e.shape[3]===4&&(f=r.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(f==null||f.shape.length!==4||f.shape[0]!==1||f.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(f.dtype==="int32"){let h=r.cast(f,"float32");r.dispose(f),f=h}return{tensor:f,canvas:t.filter.return?c0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&b("input stream is not ready"),{tensor:null,canvas:l0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,s=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!s)return t.debug&&b("cannot determine input dimensions"),{tensor:null,canvas:l0};let A=o,a=s;if(A>x2&&(A=x2,a=Math.trunc(A*s/o)),a>x2&&(a=x2,A=Math.trunc(a*o/s)),(((m=t.filter)==null?void 0:m.width)||0)>0?A=t.filter.width:(((x=t.filter)==null?void 0:x.height)||0)>0&&(A=o*((t.filter.height||0)/s)),(t.filter.height||0)>0?a=t.filter.height:(t.filter.width||0)>0&&(a=s*((t.filter.width||0)/o)),!A||!a)throw new Error("input error: cannot determine dimension");(!l0||l0.width!==A||l0.height!==a)&&(l0=D0(A,a));let i=l0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?i.putImageData(e,0,0):t.filter.flip&&typeof i.translate!="undefined"?(i.translate(o,0),i.scale(-1,1),i.drawImage(e,0,0,o,s,0,0,l0.width,l0.height),i.setTransform(1,0,0,1,0,0)):i.drawImage(e,0,0,o,s,0,0,l0.width,l0.height),(!c0||l0.width!==c0.width||l0.height!==c0.height)&&(c0=D0(l0.width,l0.height)),t.filter.enabled&&M.webgl.supported?(X||(X=M.browser?new e1:null),M.filter=!!X,X!=null&&X.add?(X.reset(),t.filter.brightness!==0&&X.add("brightness",t.filter.brightness),t.filter.contrast!==0&&X.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&X.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&X.add("blur",t.filter.blur),t.filter.saturation!==0&&X.add("saturation",t.filter.saturation),t.filter.hue!==0&&X.add("hue",t.filter.hue),t.filter.negative&&X.add("negative"),t.filter.sepia&&X.add("sepia"),t.filter.vintage&&X.add("brownie"),t.filter.sepia&&X.add("sepia"),t.filter.kodachrome&&X.add("kodachrome"),t.filter.technicolor&&X.add("technicolor"),t.filter.polaroid&&X.add("polaroid"),t.filter.pixelate!==0&&X.add("pixelate",t.filter.pixelate),((p=X.get())==null?void 0:p.length)>1?c0=X.apply(l0):c0=X.draw(l0)):(t.debug&&b("input process error: cannot initialize filters"),M.webgl.supported=!1,t.filter.enabled=!1,y2(l0,c0))):(y2(l0,c0),X&&(X=null),M.filter=!!X),!n)return{tensor:null,canvas:c0};if(!c0)throw new Error("canvas error: cannot create output");let c,d=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(M.browser&&r.browser)c=r.browser?r.browser.fromPixels(e):null;else{d=e.data.length/e.height/e.width;let f=new Uint8Array(e.data.buffer);c=r.tensor(f,[e.height,e.width,d],"int32")}else if((!We||c0.width!==We.width||c0.height!==We.height)&&(We=D0(c0.width,c0.height)),r.browser&&M.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?c=r.browser.fromPixels(c0):(We=y2(c0),c=r.browser.fromPixels(We));else{let v=y2(c0).getContext("2d").getImageData(0,0,A,a);d=v.data.length/A/a;let T=new Uint8Array(v.data.buffer);c=r.tensor(T,[A,a,d])}if(d===4){let f=r.slice3d(c,[0,0,0],[-1,-1,3]);r.dispose(c),c=f}if(!c)throw new Error("input error: cannot create tensor");let y=r.cast(c,"float32"),l=t.filter.equalization?await d2(y):r.expandDims(y,0);if(r.dispose([c,y]),t.filter.autoBrightness){let f=r.max(l),h=await f.data();t.filter.brightness=h[0]>1?1-h[0]/255:1-h[0],r.dispose(f)}return{tensor:l,canvas:t.filter.return?c0:null}}async function t1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!L0.inputTensor)L0.inputTensor=r.clone(t);else if(L0.inputTensor.shape[1]!==t.shape[1]||L0.inputTensor.shape[2]!==t.shape[2])r.dispose(L0.inputTensor),L0.inputTensor=r.clone(t);else{let o={};o.diff=r.sub(t,L0.inputTensor),o.squared=r.mul(o.diff,o.diff),o.sum=r.sum(o.squared);let A=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;r.dispose([L0.inputTensor,o.diff,o.squared,o.sum]),L0.inputTensor=r.clone(t),n=A<=(e.cacheSensitivity||0)}return n}async function n1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||b("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||b("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=r.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?r.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):r.clone(n),o.diff=r.sub(o.input1,o.input2),o.squared=r.mul(o.diff,o.diff),o.sum=r.sum(o.squared);let A=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return r.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),A}var Qe,_e,$e,p2=class{constructor(){z(this,"browser");z(this,"node");z(this,"worker");z(this,"platform","");z(this,"agent","");z(this,"backends",[]);z(this,"initial");z(this,"filter");z(this,"tfjs");z(this,"offscreen");z(this,"perfadd",!1);z(this,"tensorflow",{version:void 0,gpu:void 0});z(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});z(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});z(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});z(this,"cpu",{model:void 0,flags:[]});z(this,"kernels",[]);q0(this,Qe,void 0);q0(this,_e,void 0);q0(this,$e,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:Je["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return E0(this,Qe)}set Canvas(t){Q0(this,Qe,t),globalThis.Canvas=t}get Image(){return E0(this,_e)}set Image(t){Q0(this,_e,t),globalThis.Image=t}get ImageData(){return E0(this,$e)}set ImageData(t){Q0(this,$e,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(r.engine().registryFactory);try{this.tensorflow={version:r.backend().binding?r.backend().binding.TF_Version:void 0,gpu:r.backend().binding?r.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await r.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await r.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=D0(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=r.getKernelsForBackend(r.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};Qe=new WeakMap,_e=new WeakMap,$e=new WeakMap;var M=new p2;var u2=class{constructor(){z(this,"config");z(this,"element");z(this,"stream");z(this,"devices",[]);z(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});z(this,"start",async t=>{var s,A;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let a=document.getElementById(t.element);if(a&&a instanceof HTMLVideoElement)this.element=a;else return this.config.debug&&b("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&b("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((s=this.config)==null?void 0:s.width)>0&&(n.video.width={ideal:this.config.width}),((A=this.config)==null?void 0:A.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&b("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&b("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&b("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(a){return b("webcam",a),`webcam error: ${a}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(a=>{this.element?this.element.onloadeddata=()=>a(!0):a(!1)}),await this.element.play(),this.config.debug&&b("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&b("webcam error","no stream"),"webcam error no stream")});z(this,"pause",()=>{this.element&&this.element.pause()});z(this,"play",async()=>{this.element&&await this.element.play()});z(this,"stop",()=>{this.config.debug&&b("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var xt={};oe(xt,{"affectnet-mobilenet":()=>To,age:()=>vo,"anti-spoofing":()=>er,antispoof:()=>io,blazeface:()=>lo,"blazeface-back":()=>Ro,"blazeface-front":()=>Mo,"blazepose-detector":()=>Po,"blazepose-full":()=>ko,"blazepose-heavy":()=>wo,"blazepose-lite":()=>Eo,centernet:()=>co,default:()=>yr,efficientpose:()=>zo,"efficientpose-i-lite":()=>tr,"efficientpose-ii-lite":()=>nr,"efficientpose-iv":()=>or,emotion:()=>xo,faceboxes:()=>So,facemesh:()=>yo,"facemesh-attention":()=>Io,"facemesh-attention-pinto":()=>jo,"facemesh-detection-full":()=>No,"facemesh-detection-short":()=>Lo,faceres:()=>fo,"faceres-deep":()=>Oo,gear:()=>Do,"gear-e1":()=>Co,"gear-e2":()=>Wo,gender:()=>Bo,"gender-ssrnet-imdb":()=>Fo,handdetect:()=>Ho,"handlandmark-full":()=>Go,"handlandmark-lite":()=>mo,"handlandmark-sparse":()=>Vo,handskeleton:()=>Zo,handtrack:()=>po,"insightface-efficientnet-b0":()=>rr,"insightface-ghostnet-strides1":()=>sr,"insightface-ghostnet-strides2":()=>Ar,"insightface-mobilenet-emore":()=>ar,"insightface-mobilenet-swish":()=>ir,iris:()=>uo,liveness:()=>ho,meet:()=>Xo,mobileface:()=>qo,mobilefacenet:()=>Uo,models:()=>bo,"movenet-lightning":()=>go,"movenet-multipose":()=>Yo,"movenet-thunder":()=>Ko,nanodet:()=>Jo,"nanodet-e":()=>lr,"nanodet-g":()=>cr,"nanodet-m":()=>dr,"nanodet-t":()=>xr,posenet:()=>Qo,rvm:()=>_o,selfie:()=>$o});var io=853098,lo=538928,co=4030290,xo=820516,yo=1477958,fo=6978814,mo=2023432,po=2964837,uo=2599092,ho=592976,bo=0,go=4650216,To=6920630,vo=161240,Ro=538928,Mo=402048,Po=5928856,ko=6339202,wo=27502466,Eo=2726402,zo=5651240,So=2013002,jo=2387598,Io=2382414,No=1026192,Lo=201268,Oo=13957620,Co=112438,Wo=112438,Do=1498916,Fo=161236,Bo=201808,Ho=3515612,Go=5431368,Vo=5286322,Zo=5502280,Xo=372228,qo=2183192,Uo=5171976,Yo=9448838,Ko=12477112,Jo=7574558,Qo=5032780,_o=3739355,$o=212886,er=853098,tr=2269064,nr=5651240,or=25643252,rr=13013224,sr=8093408,Ar=8049584,ar=6938536,ir=12168584,lr=12319156,cr=7574558,dr=1887474,xr=5294216,yr={antispoof:io,blazeface:lo,centernet:co,emotion:xo,facemesh:yo,faceres:fo,"handlandmark-lite":mo,handtrack:po,iris:uo,liveness:ho,models:bo,"movenet-lightning":go,"affectnet-mobilenet":To,age:vo,"blazeface-back":Ro,"blazeface-front":Mo,"blazepose-detector":Po,"blazepose-full":ko,"blazepose-heavy":wo,"blazepose-lite":Eo,efficientpose:zo,faceboxes:So,"facemesh-attention-pinto":jo,"facemesh-attention":Io,"facemesh-detection-full":No,"facemesh-detection-short":Lo,"faceres-deep":Oo,"gear-e1":Co,"gear-e2":Wo,gear:Do,"gender-ssrnet-imdb":Fo,gender:Bo,handdetect:Ho,"handlandmark-full":Go,"handlandmark-sparse":Vo,handskeleton:Zo,meet:Xo,mobileface:qo,mobilefacenet:Uo,"movenet-multipose":Yo,"movenet-thunder":Ko,nanodet:Jo,posenet:Qo,rvm:_o,selfie:$o,"anti-spoofing":er,"efficientpose-i-lite":tr,"efficientpose-ii-lite":nr,"efficientpose-iv":or,"insightface-efficientnet-b0":rr,"insightface-ghostnet-strides1":sr,"insightface-ghostnet-strides2":Ar,"insightface-mobilenet-emore":ar,"insightface-mobilenet-swish":ir,"nanodet-e":lr,"nanodet-g":cr,"nanodet-m":dr,"nanodet-t":xr};var T0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},p0={};async function fr(e,t){return T0.debug&&b("load model fetch:",e,t),fetch(e,t)}function o1(e){T0.cacheModels=e.cacheModels,T0.verbose=e.debug,T0.modelBasePath=e.modelBasePath}async function L(e){var d,y,l,m;let t=U5(T0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),s="indexeddb://"+o;p0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:xt[o],inCache:!1,url:""},T0.cacheSupported=typeof indexedDB!="undefined";let A={};try{A=T0.cacheSupported&&T0.cacheModels?await r.io.listModels():{}}catch(x){T0.cacheSupported=!1}p0[o].inCache=T0.cacheSupported&&T0.cacheModels&&Object.keys(A).includes(s),p0[o].url=p0[o].inCache?s:t;let a=typeof fetch=="undefined"?{}:{fetchFunc:(x,p)=>fr(x,p)},i=new r.GraphModel(p0[o].url,a),c=!1;try{i.findIOHandler(),T0.debug&&b("model load handler:",i.handler)}catch(x){b("error finding model i/o handler:",t,x)}try{let x=await((d=i.handler)==null?void 0:d.load())||null;p0[o].sizeFromManifest=((y=x==null?void 0:x.weightData)==null?void 0:y.byteLength)||0,x?i.loadSync(x):i=await r.loadGraphModel(p0[o].inCache?s:t,a),p0[o].sizeLoadedWeights=((m=(l=i.artifacts)==null?void 0:l.weightData)==null?void 0:m.byteLength)||0,T0.verbose&&b("load:",{model:o,url:i.modelUrl,bytes:p0[o].sizeLoadedWeights}),c=!0}catch(x){b("error loading model:",t,x)}if(c&&T0.cacheModels&&T0.cacheSupported&&!p0[o].inCache)try{let x=await i.save(s);T0.debug&&b("model saved:",s,x)}catch(x){b("error saving model:",t,x)}return i}var yt="3.1.2";var Y={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ur(){let e=Y.gl;e&&(Y.extensions=e.getSupportedExtensions())}function r1(e){var t;if(e.config.backend==="humangl"&&(Y.name in r.engine().registry&&!((t=Y==null?void 0:Y.gl)!=null&&t.getParameter(Y.gl.VERSION))&&(b("humangl error: backend invalid context"),e.models.reset()),!r.findBackend(Y.name))){try{Y.canvas=D0(100,100)}catch(s){b("humangl error: cannot create canvas:",s);return}try{if(Y.gl=Y.canvas.getContext("webgl2",Y.webGLattr),!Y.gl){b("humangl error: cannot get webgl context");return}if(!Y.gl.getParameter(Y.gl.VERSION).includes("2.0")){b("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}Y.canvas&&(Y.canvas.addEventListener("webglcontextlost",A=>{throw b("humangl error:",A.type),b("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),Y.canvas.addEventListener("webglcontextrestored",A=>{b("humangl error: context restored:",A)}),Y.canvas.addEventListener("webglcontextcreationerror",A=>{b("humangl error: context create:",A)}))}catch(s){b("humangl error: cannot get webgl context:",s);return}try{r.setWebGLContext(2,Y.gl)}catch(s){b("humangl error: cannot set webgl context:",s);return}try{let s=new r.GPGPUContext(Y.gl);r.registerBackend(Y.name,()=>new r.MathBackendWebGL(s),Y.priority)}catch(s){b("humangl error: cannot register webgl backend:",s);return}try{r.getKernelsForBackend("webgl").forEach(A=>{let a={...A,backendName:Y.name};r.registerKernel(a)})}catch(s){b("humangl error: cannot update webgl backend registration:",s);return}try{r.env().flagRegistry.WEBGL_VERSION&&r.env().set("WEBGL_VERSION",2)}catch(s){b("humangl error: cannot set WebGL backend flags:",s);return}ur();let n=r.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&b("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):b("humangl error: no current gl context:",o,Y.gl)}}var O={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function s1(){O.tf255=r.scalar(255,"float32"),O.tf1=r.scalar(1,"float32"),O.tf2=r.scalar(2,"float32"),O.tf05=r.scalar(.5,"float32"),O.tf127=r.scalar(127.5,"float32"),O.rgb=r.tensor1d([.2989,.587,.114],"float32")}async function gr(){var e;return await M.updateBackend(),(e=M.tensorflow)!=null&&e.version?"tensorflow":M.webgpu.supported&&M.webgpu.backend?"webgpu":M.webgl.supported&&M.webgl.backend?"webgl":M.wasm.supported&&M.wasm.backend?"wasm":"cpu"}function Tr(e){let t=[];if(!M.kernels.includes("mod")){let n={kernelName:"Mod",backendName:r.getBackend(),kernelFunc:o=>r.tidy(()=>r.sub(o.inputs.a,r.mul(r.div(o.inputs.a,o.inputs.b),o.inputs.b)))};r.registerKernel(n),M.kernels.push("mod"),t.push("mod")}if(!M.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:r.getBackend(),kernelFunc:o=>r.tidy(()=>r.add(r.mul(r.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),r.mod(o.inputs.a,o.inputs.b)))};r.registerKernel(n),M.kernels.push("floormod"),t.push("floormod")}if(!M.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:r.getBackend(),kernelFunc:o=>r.tidy(()=>{let s=r.getBackend();r.setBackend("cpu");let A=r.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return r.setBackend(s),A})};r.registerKernel(n),M.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&b("registered kernels:",t)}var A1={};async function e2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await gr()),t||M.initial||e.config.backend&&e.config.backend.length>0&&r.getBackend()!==e.config.backend){let s=R();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&b("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&b("running inside electron");let A=Object.keys(r.engine().registryFactory);if(e.config.backend==="humangl"&&!A.includes("humangl")&&(r1(e),A=Object.keys(r.engine().registryFactory)),e.config.debug&&b("available backends:",A),M.browser&&!M.node&&e.config.backend==="tensorflow"&&A.includes("webgl")&&(e.config.debug&&b("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),M.node&&!M.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&A.includes("tensorflow")&&(e.config.debug&&b(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),M.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")b("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let a=await navigator.gpu.requestAdapter();if(e.config.debug&&b("enumerated webgpu adapter:",a),!a)b("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let i="requestAdapterInfo"in a?await a.requestAdapterInfo():void 0;b("webgpu adapter info:",i)}}if(A.includes(e.config.backend)||(b(`error: backend ${e.config.backend} not found in registry`),e.config.backend=M.node?"tensorflow":"webgl",e.config.debug&&b(`override: setting backend ${e.config.backend}`)),e.config.debug&&b("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(r.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&r.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&b("wasm path:",e.config.wasmPath),typeof r.setWasmPaths!="undefined")r.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let a=!1,i=!1;try{a=await r.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),i=await r.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&b(`wasm execution: ${i?"simd":"no simd"} ${a?"multithreaded":"singlethreaded"}`),e.config.debug&&!i&&b("warning: wasm simd support is not enabled")}catch(c){b("wasm detection failed")}}try{await r.setBackend(e.config.backend),await r.ready()}catch(a){return b("error: cannot set backend:",e.config.backend,a),!1}e.config.debug&&(A1=JSON.parse(JSON.stringify(r.env().flags)))}if((r.getBackend()==="humangl"||r.getBackend()==="webgl")&&(r.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&r.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),r.env().flagRegistry.WEBGL_EXP_CONV&&r.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(b("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),r.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),r.getBackend(),e.config.debug){let A=r.env().flags,a={};for(let i of Object.keys(A))A1[i]!==A[i]&&(a[i]=A[i]);e.config.debug&&Object.keys(a).length>0&&b("backend:",r.getBackend(),"flags:",a)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&b("flags:",e.config.flags);for(let[A,a]of Object.entries(e.config.flags))r.env().set(A,a)}r.enableProdMode(),s1(),e.performance.initBackend=Math.trunc(R()-s),e.config.backend=r.getBackend(),await M.updateBackend(),Tr(e.config)}return!0}function h2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:s=>{var A;return t.debug&&b("kernelFunc",n,t.backend,s),(A=s==null?void 0:s.inputs)==null?void 0:A.info}};r.registerKernel(o)}M.kernels=r.getKernelsForBackend(r.getBackend()).map(n=>n.kernelName.toLowerCase())}var Tt={};oe(Tt,{all:()=>_r,body:()=>g2,canvas:()=>Qr,face:()=>b2,gesture:()=>R2,hand:()=>T2,init:()=>gt,object:()=>v2,options:()=>n0,person:()=>Jr});var O0=e=>{if(!e)b("draw error: invalid canvas");else if(!e.getContext)b("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)b("draw error: cannot get canvas context");else return t}return null},ge=e=>Math.round(e*180/Math.PI),H=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Te=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function C0(e,t,n,o,s){let A=t.replace(/\[.*\]/g,"").split(` `).map(i=>i.trim()),a=Math.max(0,n);for(let i=A.length-1;i>=0;i--){let c=i*s.lineHeight+o;s.shadowColor&&s.shadowColor!==""&&(e.fillStyle=s.shadowColor,e.fillText(A[i],a+5,c+16)),e.fillStyle=s.labelColor,e.fillText(A[i],a+4,c+15)}}function U0(e,t,n,o,s){e.fillStyle=Te(o,s),e.beginPath(),e.arc(t,n,s.pointSize,0,2*Math.PI),e.fill()}function Y0(e,t,n,o,s,A){if(e.beginPath(),e.lineWidth=A.lineWidth,A.useCurves){let a=(t+t+o)/2,i=(n+n+s)/2;e.ellipse(a,i,o/2,s/2,0,0,2*Math.PI)}else e.moveTo(t+A.roundRect,n),e.lineTo(t+o-A.roundRect,n),e.quadraticCurveTo(t+o,n,t+o,n+A.roundRect),e.lineTo(t+o,n+s-A.roundRect),e.quadraticCurveTo(t+o,n+s,t+o-A.roundRect,n+s),e.lineTo(t+A.roundRect,n+s),e.quadraticCurveTo(t,n+s,t,n+s-A.roundRect),e.lineTo(t,n+A.roundRect),e.quadraticCurveTo(t,n,t+A.roundRect,n),e.closePath();e.stroke()}function ft(e,t,n){if(!(t.length<2)){e.beginPath(),e.moveTo(t[0][0],t[0][1]);for(let o of t)e.strokeStyle=Te(o[2]||0,n),e.lineTo(Math.trunc(o[0]),Math.trunc(o[1]));e.stroke(),n.fillPolygons&&(e.closePath(),e.fill())}}function i1(e,t,n){if(!(t.length<2)){if(e.lineWidth=n.lineWidth,!n.useCurves||t.length<=2){ft(e,t,n);return}e.moveTo(t[0][0],t[0][1]);for(let o=0;ot2[e]),JA=Rr.map(e=>t2[e]),QA=Mr.map(e=>t2[e]);function re(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Pr=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],kr=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],wr=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],Er=[[474,475],[475,476],[476,477],[477,474]],zr=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Sr=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],jr=[[469,470],[470,471],[471,472],[472,469]],Ir=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]],_A={lips:re(Pr),leftEye:re(kr),leftEyebrow:re(wr),leftIris:re(Er),rightEye:re(zr),rightEyebrow:re(Sr),rightIris:re(jr),faceOval:re(Ir)};var Nr=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Lr=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Or=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],Cr=[[474,475],[475,476],[476,477],[477,474]],Wr=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Dr=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],Fr=[[469,470],[470,471],[471,472],[472,469]],Br=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]];function se(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Hr={lips:se(Nr),leftEye:se(Lr),leftEyebrow:se(Or),leftIris:se(Cr),rightEye:se(Wr),rightEyebrow:se(Dr),rightIris:se(Fr),faceOval:se(Br)},Gr=Object.entries(Hr).map(([e,t])=>t.map(n=>[n,e])).flat(),$A=new Map(Gr),n2=[61,146,91,181,84,17,314,405,321,375,291,185,40,39,37,0,267,269,270,409,78,95,88,178,87,14,317,402,318,324,308,191,80,81,82,13,312,311,310,415,76,77,90,180,85,16,315,404,320,307,306,184,74,73,72,11,302,303,304,408,62,96,89,179,86,15,316,403,319,325,292,183,42,41,38,12,268,271,272,407],Me=[33,7,163,144,145,153,154,155,133,246,161,160,159,158,157,173,130,25,110,24,23,22,26,112,243,247,30,29,27,28,56,190,226,31,228,229,230,231,232,233,244,113,225,224,223,222,221,189,35,124,46,53,52,65,143,111,117,118,119,120,121,128,245,156,70,63,105,66,107,55,193],Pe=[263,249,390,373,374,380,381,382,362,466,388,387,386,385,384,398,359,255,339,254,253,252,256,341,463,467,260,259,257,258,286,414,446,261,448,449,450,451,452,453,464,342,445,444,443,442,441,413,265,353,276,283,282,295,372,340,346,347,348,349,350,357,465,383,300,293,334,296,336,285,417];var B;function Vr(e,t){var o,s,A,a,i,c,d,y,l;if(!B.drawLabels||((o=B.faceLabels)==null?void 0:o.length)===0)return;let n=B.faceLabels.slice();if(n=H(n,"[id]",e.id.toFixed(0)),e.score&&(n=H(n,"[score]",100*e.score)),e.gender&&(n=H(n,"[gender]",e.gender)),e.genderScore&&(n=H(n,"[genderScore]",100*e.genderScore)),e.age&&(n=H(n,"[age]",e.age)),e.distance&&(n=H(n,"[distance]",100*e.distance)),e.real&&(n=H(n,"[real]",100*e.real)),e.live&&(n=H(n,"[live]",100*e.live)),e.emotion&&e.emotion.length>0){let m=e.emotion.map(x=>`${Math.trunc(100*x.score)}% ${x.emotion}`);m.length>3&&(m.length=3),n=H(n,"[emotions]",m.join(" "))}(A=(s=e.rotation)==null?void 0:s.angle)!=null&&A.roll&&(n=H(n,"[roll]",ge(e.rotation.angle.roll))),(i=(a=e.rotation)==null?void 0:a.angle)!=null&&i.yaw&&(n=H(n,"[yaw]",ge(e.rotation.angle.yaw))),(d=(c=e.rotation)==null?void 0:c.angle)!=null&&d.pitch&&(n=H(n,"[pitch]",ge(e.rotation.angle.pitch))),(l=(y=e.rotation)==null?void 0:y.gaze)!=null&&l.bearing&&(n=H(n,"[gaze]",ge(e.rotation.gaze.bearing))),C0(t,n,e.box[0],e.box[1],B)}function Zr(e,t){var n,o,s,A;if((n=e.annotations)!=null&&n.leftEyeIris&&((o=e.annotations)!=null&&o.leftEyeIris[0])){t.strokeStyle=B.useDepth?"rgba(255, 200, 255, 0.3)":B.color,t.beginPath();let a=Math.abs(e.annotations.leftEyeIris[3][0]-e.annotations.leftEyeIris[1][0])/2,i=Math.abs(e.annotations.leftEyeIris[4][1]-e.annotations.leftEyeIris[2][1])/2;t.ellipse(e.annotations.leftEyeIris[0][0],e.annotations.leftEyeIris[0][1],a,i,0,0,2*Math.PI),t.stroke(),B.fillPolygons&&(t.fillStyle=B.useDepth?"rgba(255, 255, 200, 0.3)":B.color,t.fill())}if((s=e.annotations)!=null&&s.rightEyeIris&&((A=e.annotations)!=null&&A.rightEyeIris[0])){t.strokeStyle=B.useDepth?"rgba(255, 200, 255, 0.3)":B.color,t.beginPath();let a=Math.abs(e.annotations.rightEyeIris[3][0]-e.annotations.rightEyeIris[1][0])/2,i=Math.abs(e.annotations.rightEyeIris[4][1]-e.annotations.rightEyeIris[2][1])/2;t.ellipse(e.annotations.rightEyeIris[0][0],e.annotations.rightEyeIris[0][1],a,i,0,0,2*Math.PI),t.stroke(),B.fillPolygons&&(t.fillStyle=B.useDepth?"rgba(255, 255, 200, 0.3)":B.color,t.fill())}}function Xr(e,t){var n;if(B.drawGaze&&((n=e.rotation)!=null&&n.angle)&&typeof Path2D!="undefined"){t.strokeStyle="pink";let o=e.box[0]+e.box[2]/2-e.box[3]*ge(e.rotation.angle.yaw)/90,s=e.box[1]+e.box[3]/2+e.box[2]*ge(e.rotation.angle.pitch)/90,A=new Path2D(` M ${e.box[0]+e.box[2]/2} ${e.box[1]} C diff --git a/dist/human.esm.js b/dist/human.esm.js index 3bf1e201..c6b6e0d8 100644 --- a/dist/human.esm.js +++ b/dist/human.esm.js @@ -35289,7 +35289,7 @@ async function loadModel(modelPath) { } // package.json -var version = "3.1.1"; +var version = "3.1.2"; // src/tfjs/humangl.ts var config2 = { diff --git a/dist/human.esm.js.map b/dist/human.esm.js.map index 37b13af5..ca48ffc4 100644 --- a/dist/human.esm.js.map +++ b/dist/human.esm.js.map @@ -1,7 +1,7 @@ { "version": 3, "sources": ["tfjs.esm.js", "../src/util/util.ts", "../src/config.ts", "../src/image/imagefxshaders.ts", "../src/image/imagefx.ts", "../src/image/enhance.ts", "../src/image/image.ts", "../src/util/env.ts", "../src/util/webcam.ts", "../models/models.json", "../src/tfjs/load.ts", "../package.json", "../src/tfjs/humangl.ts", "../src/tfjs/constants.ts", "../src/tfjs/backend.ts", "../src/draw/draw.ts", "../src/draw/primitives.ts", "../src/draw/options.ts", "../src/face/facemeshcoords.ts", "../src/face/constants.ts", "../src/draw/face.ts", "../src/draw/body.ts", "../src/draw/hand.ts", "../src/draw/object.ts", "../src/draw/gesture.ts", "../src/draw/labels.ts", "../src/body/blazeposecoords.ts", "../src/body/blazeposedetector.ts", "../src/util/box.ts", "../src/body/blazepose.ts", "../src/object/labels.ts", "../src/object/centernet.ts", "../src/body/efficientposecoords.ts", "../src/body/efficientpose.ts", "../src/face/facemeshutil.ts", "../src/face/blazeface.ts", "../src/face/iris.ts", "../src/face/attention.ts", "../src/face/facemesh.ts", "../src/gear/emotion.ts", "../src/face/faceres.ts", "../src/face/mask.ts", "../src/face/antispoof.ts", "../src/face/liveness.ts", "../src/gear/gear.ts", "../src/gear/ssrnet-age.ts", "../src/gear/ssrnet-gender.ts", "../src/face/mobilefacenet.ts", "../src/face/insightface.ts", "../src/face/angles.ts", "../src/face/anthropometry.ts", "../src/face/face.ts", "../src/hand/fingerdef.ts", "../src/hand/fingergesture.ts", "../src/hand/fingerpose.ts", "../src/gesture/gesture.ts", "../src/hand/handposeutil.ts", "../src/hand/handposeanchors.ts", "../src/hand/handposedetector.ts", "../src/hand/handposepipeline.ts", "../src/hand/handpose.ts", "../src/hand/handtrack.ts", "../src/result.ts", "../src/body/movenetcoords.ts", "../src/util/interpolate.ts", "../src/segmentation/meet.ts", "../src/face/match.ts", "../src/models.ts", "../src/body/movenetfix.ts", "../src/body/movenet.ts", "../src/object/nanodet.ts", "../src/body/posenetutils.ts", "../src/body/posenet.ts", "../src/segmentation/rvm.ts", "../src/segmentation/selfie.ts", "../src/util/persons.ts", "../src/sample.ts", "../src/warmup.ts", "../src/human.ts"], - "sourcesContent": ["/*\n Human\n homepage: \n author: '\n*/\n\nvar wG=Object.create;var QC=Object.defineProperty;var SG=Object.getOwnPropertyDescriptor;var IG=Object.getOwnPropertyNames;var vG=Object.getPrototypeOf,kG=Object.prototype.hasOwnProperty;var qt=(r,t)=>()=>(t||r((t={exports:{}}).exports,t),t.exports),qe=(r,t)=>{for(var e in t)QC(r,e,{get:t[e],enumerable:!0})},NG=(r,t,e,o)=>{if(t&&typeof t==\"object\"||typeof t==\"function\")for(let n of IG(t))!kG.call(r,n)&&n!==e&&QC(r,n,{get:()=>t[n],enumerable:!(o=SG(t,n))||o.enumerable});return r};var Kp=(r,t,e)=>(e=r!=null?wG(vG(r)):{},NG(t||!r||!r.__esModule?QC(e,\"default\",{value:r,enumerable:!0}):e,r));var V0=qt((tle,z0)=>{z0.exports=Nt;var No=null;try{No=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(r){}function Nt(r,t,e){this.low=r|0,this.high=t|0,this.unsigned=!!e}Nt.prototype.__isLong__;Object.defineProperty(Nt.prototype,\"__isLong__\",{value:!0});function Wr(r){return(r&&r.__isLong__)===!0}Nt.isLong=Wr;var R0={},D0={};function Bu(r,t){var e,o,n;return t?(r>>>=0,(n=0<=r&&r<256)&&(o=D0[r],o)?o:(e=Tt(r,(r|0)<0?-1:0,!0),n&&(D0[r]=e),e)):(r|=0,(n=-128<=r&&r<128)&&(o=R0[r],o)?o:(e=Tt(r,r<0?-1:0,!1),n&&(R0[r]=e),e))}Nt.fromInt=Bu;function To(r,t){if(isNaN(r))return t?Lu:_o;if(t){if(r<0)return Lu;if(r>=O0)return B0}else{if(r<=-F0)return Vr;if(r+1>=F0)return L0}return r<0?To(-r,t).neg():Tt(r%oc|0,r/oc|0,t)}Nt.fromNumber=To;function Tt(r,t,e){return new Nt(r,t,e)}Nt.fromBits=Tt;var Zm=Math.pow;function cw(r,t,e){if(r.length===0)throw Error(\"empty string\");if(r===\"NaN\"||r===\"Infinity\"||r===\"+Infinity\"||r===\"-Infinity\")return _o;if(typeof t==\"number\"?(e=t,t=!1):t=!!t,e=e||10,e<2||360)throw Error(\"interior hyphen\");if(o===0)return cw(r.substring(1),t,e).neg();for(var n=To(Zm(e,8)),s=_o,a=0;a>>0:this.low};de.toNumber=function(){return this.unsigned?(this.high>>>0)*oc+(this.low>>>0):this.high*oc+(this.low>>>0)};de.toString=function(t){if(t=t||10,t<2||36>>0,c=u.toString(t);if(a=p,a.isZero())return c+i;for(;c.length<6;)c=\"0\"+c;i=\"\"+c+i}};de.getHighBits=function(){return this.high};de.getHighBitsUnsigned=function(){return this.high>>>0};de.getLowBits=function(){return this.low};de.getLowBitsUnsigned=function(){return this.low>>>0};de.getNumBitsAbs=function(){if(this.isNegative())return this.eq(Vr)?64:this.neg().getNumBitsAbs();for(var t=this.high!=0?this.high:this.low,e=31;e>0&&!(t&1<=0};de.isOdd=function(){return(this.low&1)===1};de.isEven=function(){return(this.low&1)===0};de.equals=function(t){return Wr(t)||(t=Fs(t)),this.unsigned!==t.unsigned&&this.high>>>31===1&&t.high>>>31===1?!1:this.high===t.high&&this.low===t.low};de.eq=de.equals;de.notEquals=function(t){return!this.eq(t)};de.neq=de.notEquals;de.ne=de.notEquals;de.lessThan=function(t){return this.comp(t)<0};de.lt=de.lessThan;de.lessThanOrEqual=function(t){return this.comp(t)<=0};de.lte=de.lessThanOrEqual;de.le=de.lessThanOrEqual;de.greaterThan=function(t){return this.comp(t)>0};de.gt=de.greaterThan;de.greaterThanOrEqual=function(t){return this.comp(t)>=0};de.gte=de.greaterThanOrEqual;de.ge=de.greaterThanOrEqual;de.compare=function(t){if(Wr(t)||(t=Fs(t)),this.eq(t))return 0;var e=this.isNegative(),o=t.isNegative();return e&&!o?-1:!e&&o?1:this.unsigned?t.high>>>0>this.high>>>0||t.high===this.high&&t.low>>>0>this.low>>>0?-1:1:this.sub(t).isNegative()?-1:1};de.comp=de.compare;de.negate=function(){return!this.unsigned&&this.eq(Vr)?Vr:this.not().add(rc)};de.neg=de.negate;de.add=function(t){Wr(t)||(t=Fs(t));var e=this.high>>>16,o=this.high&65535,n=this.low>>>16,s=this.low&65535,a=t.high>>>16,i=t.high&65535,p=t.low>>>16,u=t.low&65535,c=0,l=0,m=0,d=0;return d+=s+u,m+=d>>>16,d&=65535,m+=n+p,l+=m>>>16,m&=65535,l+=o+i,c+=l>>>16,l&=65535,c+=e+a,c&=65535,Tt(m<<16|d,c<<16|l,this.unsigned)};de.subtract=function(t){return Wr(t)||(t=Fs(t)),this.add(t.neg())};de.sub=de.subtract;de.multiply=function(t){if(this.isZero())return _o;if(Wr(t)||(t=Fs(t)),No){var e=No.mul(this.low,this.high,t.low,t.high);return Tt(e,No.get_high(),this.unsigned)}if(t.isZero())return _o;if(this.eq(Vr))return t.isOdd()?Vr:_o;if(t.eq(Vr))return this.isOdd()?Vr:_o;if(this.isNegative())return t.isNegative()?this.neg().mul(t.neg()):this.neg().mul(t).neg();if(t.isNegative())return this.mul(t.neg()).neg();if(this.lt(P0)&&t.lt(P0))return To(this.toNumber()*t.toNumber(),this.unsigned);var o=this.high>>>16,n=this.high&65535,s=this.low>>>16,a=this.low&65535,i=t.high>>>16,p=t.high&65535,u=t.low>>>16,c=t.low&65535,l=0,m=0,d=0,f=0;return f+=a*c,d+=f>>>16,f&=65535,d+=s*c,m+=d>>>16,d&=65535,d+=a*u,m+=d>>>16,d&=65535,m+=n*c,l+=m>>>16,m&=65535,m+=s*u,l+=m>>>16,m&=65535,m+=a*p,l+=m>>>16,m&=65535,l+=o*c+n*u+s*p+a*i,l&=65535,Tt(d<<16|f,l<<16|m,this.unsigned)};de.mul=de.multiply;de.divide=function(t){if(Wr(t)||(t=Fs(t)),t.isZero())throw Error(\"division by zero\");if(No){if(!this.unsigned&&this.high===-2147483648&&t.low===-1&&t.high===-1)return this;var e=(this.unsigned?No.div_u:No.div_s)(this.low,this.high,t.low,t.high);return Tt(e,No.get_high(),this.unsigned)}if(this.isZero())return this.unsigned?Lu:_o;var o,n,s;if(this.unsigned){if(t.unsigned||(t=t.toUnsigned()),t.gt(this))return Lu;if(t.gt(this.shru(1)))return M0;s=Lu}else{if(this.eq(Vr)){if(t.eq(rc)||t.eq(pw))return Vr;if(t.eq(Vr))return rc;var a=this.shr(1);return o=a.div(t).shl(1),o.eq(_o)?t.isNegative()?rc:pw:(n=this.sub(t.mul(o)),s=o.add(n.div(t)),s)}else if(t.eq(Vr))return this.unsigned?Lu:_o;if(this.isNegative())return t.isNegative()?this.neg().div(t.neg()):this.neg().div(t).neg();if(t.isNegative())return this.div(t.neg()).neg();s=_o}for(n=this;n.gte(t);){o=Math.max(1,Math.floor(n.toNumber()/t.toNumber()));for(var i=Math.ceil(Math.log(o)/Math.LN2),p=i<=48?1:Zm(2,i-48),u=To(o),c=u.mul(t);c.isNegative()||c.gt(n);)o-=p,u=To(o,this.unsigned),c=u.mul(t);u.isZero()&&(u=rc),s=s.add(u),n=n.sub(c)}return s};de.div=de.divide;de.modulo=function(t){if(Wr(t)||(t=Fs(t)),No){var e=(this.unsigned?No.rem_u:No.rem_s)(this.low,this.high,t.low,t.high);return Tt(e,No.get_high(),this.unsigned)}return this.sub(this.div(t).mul(t))};de.mod=de.modulo;de.rem=de.modulo;de.not=function(){return Tt(~this.low,~this.high,this.unsigned)};de.and=function(t){return Wr(t)||(t=Fs(t)),Tt(this.low&t.low,this.high&t.high,this.unsigned)};de.or=function(t){return Wr(t)||(t=Fs(t)),Tt(this.low|t.low,this.high|t.high,this.unsigned)};de.xor=function(t){return Wr(t)||(t=Fs(t)),Tt(this.low^t.low,this.high^t.high,this.unsigned)};de.shiftLeft=function(t){return Wr(t)&&(t=t.toInt()),(t&=63)===0?this:t<32?Tt(this.low<>>32-t,this.unsigned):Tt(0,this.low<>>t|this.high<<32-t,this.high>>t,this.unsigned):Tt(this.high>>t-32,this.high>=0?0:-1,this.unsigned)};de.shr=de.shiftRight;de.shiftRightUnsigned=function(t){if(Wr(t)&&(t=t.toInt()),t&=63,t===0)return this;var e=this.high;if(t<32){var o=this.low;return Tt(o>>>t|e<<32-t,e>>>t,this.unsigned)}else return t===32?Tt(e,0,this.unsigned):Tt(e>>>t-32,0,this.unsigned)};de.shru=de.shiftRightUnsigned;de.shr_u=de.shiftRightUnsigned;de.toSigned=function(){return this.unsigned?Tt(this.low,this.high,!1):this};de.toUnsigned=function(){return this.unsigned?this:Tt(this.low,this.high,!0)};de.toBytes=function(t){return t?this.toBytesLE():this.toBytesBE()};de.toBytesLE=function(){var t=this.high,e=this.low;return[e&255,e>>>8&255,e>>>16&255,e>>>24,t&255,t>>>8&255,t>>>16&255,t>>>24]};de.toBytesBE=function(){var t=this.high,e=this.low;return[t>>>24,t>>>16&255,t>>>8&255,t&255,e>>>24,e>>>16&255,e>>>8&255,e&255]};Nt.fromBytes=function(t,e,o){return o?Nt.fromBytesLE(t,e):Nt.fromBytesBE(t,e)};Nt.fromBytesLE=function(t,e){return new Nt(t[0]|t[1]<<8|t[2]<<16|t[3]<<24,t[4]|t[5]<<8|t[6]<<16|t[7]<<24,e)};Nt.fromBytesBE=function(t,e){return new Nt(t[4]<<24|t[5]<<16|t[6]<<8|t[7],t[0]<<24|t[1]<<16|t[2]<<8|t[3],e)}});var Ik=qt(()=>{});var vk=qt(()=>{});var Q2=qt((Y2,Vw)=>{(function(r,t,e){function o(i){var p=this,u=a();p.next=function(){var c=2091639*p.s0+p.c*23283064365386963e-26;return p.s0=p.s1,p.s1=p.s2,p.s2=c-(p.c=c|0)},p.c=1,p.s0=u(\" \"),p.s1=u(\" \"),p.s2=u(\" \"),p.s0-=u(i),p.s0<0&&(p.s0+=1),p.s1-=u(i),p.s1<0&&(p.s1+=1),p.s2-=u(i),p.s2<0&&(p.s2+=1),u=null}function n(i,p){return p.c=i.c,p.s0=i.s0,p.s1=i.s1,p.s2=i.s2,p}function s(i,p){var u=new o(i),c=p&&p.state,l=u.next;return l.int32=function(){return u.next()*4294967296|0},l.double=function(){return l()+(l()*2097152|0)*11102230246251565e-32},l.quick=l,c&&(typeof c==\"object\"&&n(c,u),l.state=function(){return n(u,{})}),l}function a(){var i=4022871197,p=function(u){u=String(u);for(var c=0;c>>0,l-=i,l*=i,i=l>>>0,l-=i,i+=l*4294967296}return(i>>>0)*23283064365386963e-26};return p}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.alea=s})(Y2,typeof Vw==\"object\"&&Vw,typeof define==\"function\"&&define)});var J2=qt((Z2,Ww)=>{(function(r,t,e){function o(a){var i=this,p=\"\";i.x=0,i.y=0,i.z=0,i.w=0,i.next=function(){var c=i.x^i.x<<11;return i.x=i.y,i.y=i.z,i.z=i.w,i.w^=i.w>>>19^c^c>>>8},a===(a|0)?i.x=a:p+=a;for(var u=0;u>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(typeof u==\"object\"&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xor128=s})(Z2,typeof Ww==\"object\"&&Ww,typeof define==\"function\"&&define)});var t1=qt((e1,Uw)=>{(function(r,t,e){function o(a){var i=this,p=\"\";i.next=function(){var c=i.x^i.x>>>2;return i.x=i.y,i.y=i.z,i.z=i.w,i.w=i.v,(i.d=i.d+362437|0)+(i.v=i.v^i.v<<4^(c^c<<1))|0},i.x=0,i.y=0,i.z=0,i.w=0,i.v=0,a===(a|0)?i.x=a:p+=a;for(var u=0;u>>4),i.next()}function n(a,i){return i.x=a.x,i.y=a.y,i.z=a.z,i.w=a.w,i.v=a.v,i.d=a.d,i}function s(a,i){var p=new o(a),u=i&&i.state,c=function(){return(p.next()>>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(typeof u==\"object\"&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xorwow=s})(e1,typeof Uw==\"object\"&&Uw,typeof define==\"function\"&&define)});var o1=qt((r1,Gw)=>{(function(r,t,e){function o(a){var i=this;i.next=function(){var u=i.x,c=i.i,l,m,d;return l=u[c],l^=l>>>7,m=l^l<<24,l=u[c+1&7],m^=l^l>>>10,l=u[c+3&7],m^=l^l>>>3,l=u[c+4&7],m^=l^l<<7,l=u[c+7&7],l=l^l<<13,m^=l^l<<9,u[c]=m,i.i=c+1&7,m};function p(u,c){var l,m,d=[];if(c===(c|0))m=d[0]=c;else for(c=\"\"+c,l=0;l0;--l)u.next()}p(i,a)}function n(a,i){return i.x=a.x.slice(),i.i=a.i,i}function s(a,i){a==null&&(a=+new Date);var p=new o(a),u=i&&i.state,c=function(){return(p.next()>>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(u.x&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xorshift7=s})(r1,typeof Gw==\"object\"&&Gw,typeof define==\"function\"&&define)});var s1=qt((n1,Hw)=>{(function(r,t,e){function o(a){var i=this;i.next=function(){var u=i.w,c=i.X,l=i.i,m,d;return i.w=u=u+1640531527|0,d=c[l+34&127],m=c[l=l+1&127],d^=d<<13,m^=m<<17,d^=d>>>15,m^=m>>>12,d=c[l]=d^m,i.i=l,d+(u^u>>>16)|0};function p(u,c){var l,m,d,f,h,g=[],x=128;for(c===(c|0)?(m=c,c=null):(c=c+\"\\0\",m=0,x=Math.max(x,c.length)),d=0,f=-32;f>>15,m^=m<<4,m^=m>>>13,f>=0&&(h=h+1640531527|0,l=g[f&127]^=m+h,d=l==0?d+1:0);for(d>=128&&(g[(c&&c.length||0)&127]=-1),d=127,f=4*128;f>0;--f)m=g[d+34&127],l=g[d=d+1&127],m^=m<<13,l^=l<<17,m^=m>>>15,l^=l>>>12,g[d]=m^l;u.w=h,u.X=g,u.i=d}p(i,a)}function n(a,i){return i.i=a.i,i.w=a.w,i.X=a.X.slice(),i}function s(a,i){a==null&&(a=+new Date);var p=new o(a),u=i&&i.state,c=function(){return(p.next()>>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(u.X&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xor4096=s})(n1,typeof Hw==\"object\"&&Hw,typeof define==\"function\"&&define)});var i1=qt((a1,Kw)=>{(function(r,t,e){function o(a){var i=this,p=\"\";i.next=function(){var c=i.b,l=i.c,m=i.d,d=i.a;return c=c<<25^c>>>7^l,l=l-m|0,m=m<<24^m>>>8^d,d=d-c|0,i.b=c=c<<20^c>>>12^l,i.c=l=l-m|0,i.d=m<<16^l>>>16^d,i.a=d-c|0},i.a=0,i.b=0,i.c=-1640531527,i.d=1367130551,a===Math.floor(a)?(i.a=a/4294967296|0,i.b=a|0):p+=a;for(var u=0;u>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(typeof u==\"object\"&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.tychei=s})(a1,typeof Kw==\"object\"&&Kw,typeof define==\"function\"&&define)});var u1=qt(()=>{});var c1=qt((p1,Ld)=>{(function(r,t,e){var o=256,n=6,s=52,a=\"random\",i=e.pow(o,n),p=e.pow(2,s),u=p*2,c=o-1,l;function m(C,S,k){var _=[];S=S==!0?{entropy:!0}:S||{};var E=g(h(S.entropy?[C,b(t)]:C==null?x():C,3),_),R=new d(_),D=function(){for(var P=R.g(n),O=i,M=0;P=u;)P/=2,O/=2,M>>>=1;return(P+M)/O};return D.int32=function(){return R.g(4)|0},D.quick=function(){return R.g(4)/4294967296},D.double=D,g(b(R.S),t),(S.pass||k||function(P,O,M,L){return L&&(L.S&&f(L,R),P.state=function(){return f(R,{})}),M?(e[a]=P,O):P})(D,E,\"global\"in S?S.global:this==e,S.state)}function d(C){var S,k=C.length,_=this,E=0,R=_.i=_.j=0,D=_.S=[];for(k||(C=[k++]);E{var vq=Q2(),kq=J2(),Nq=t1(),Tq=o1(),_q=s1(),$q=i1(),Qu=c1();Qu.alea=vq;Qu.xor128=kq;Qu.xorwow=Nq;Qu.xorshift7=Tq;Qu.xor4096=_q;Qu.tychei=$q;l1.exports=Qu});var Bv=qt(()=>{});var zv=qt(()=>{});var RB=qt(()=>{});var DB=qt(()=>{});var AB=qt(()=>{});var FB=qt((Wg,Wv)=>{var Vv=(()=>{var r=typeof document!=\"undefined\"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename!=\"undefined\"&&(r=r||__filename),function(t){t=t||{};function e(){return oe.buffer!=Ge&&_t(oe.buffer),mt}function o(){return oe.buffer!=Ge&&_t(oe.buffer),it}function n(){return oe.buffer!=Ge&&_t(oe.buffer),gt}function s(){return oe.buffer!=Ge&&_t(oe.buffer),Lr}function a(){return oe.buffer!=Ge&&_t(oe.buffer),Lt}function i(){return oe.buffer!=Ge&&_t(oe.buffer),to}function p(){return oe.buffer!=Ge&&_t(oe.buffer),nr}var u=typeof t!=\"undefined\"?t:{},c,l;u.ready=new Promise(function(F,V){c=F,l=V});var m;typeof process!=\"undefined\"&&process.listeners&&(m={uncaughtException:process.listeners(\"uncaughtException\"),unhandledRejection:process.listeners(\"unhandledRejection\")});var d=Object.assign({},u),f=[],h=\"./this.program\",g=(F,V)=>{throw V},x=typeof window==\"object\",b=typeof importScripts==\"function\",C=typeof process==\"object\"&&typeof process.versions==\"object\"&&typeof process.versions.node==\"string\",S=u.ENVIRONMENT_IS_PTHREAD||!1,k=\"\";function _(F){return u.locateFile?u.locateFile(F,k):k+F}var E,R,D,P;function O(F){if(F instanceof Eu)return;j(\"exiting due to exception: \"+F)}if(C){var M=Bv(),L=zv();b?k=L.dirname(k)+\"/\":k=__dirname+\"/\",E=(V,ue)=>(V=zp(V)?new URL(V):L.normalize(V),M.readFileSync(V,ue?void 0:\"utf8\")),D=V=>{var ue=E(V,!0);return ue.buffer||(ue=new Uint8Array(ue)),ue},R=(V,ue,Ee)=>{V=zp(V)?new URL(V):L.normalize(V),M.readFile(V,function(Be,Le){Be?Ee(Be):ue(Le.buffer)})},process.argv.length>1&&(h=process.argv[1].replace(/\\\\/g,\"/\")),f=process.argv.slice(2),process.on(\"uncaughtException\",function(V){if(!(V instanceof Eu))throw V}),process.on(\"unhandledRejection\",function(V){throw V}),g=(V,ue)=>{if(Bo())throw process.exitCode=V,ue;O(ue),process.exit(V)},u.inspect=function(){return\"[Emscripten Module object]\"};let F;try{F=RB()}catch(V){throw console.error('The \"worker_threads\" module is not supported in this node.js build - perhaps a newer version is needed?'),V}global.Worker=F.Worker}else(x||b)&&(b?k=self.location.href:typeof document!=\"undefined\"&&document.currentScript&&(k=document.currentScript.src),typeof r!=\"undefined\"&&r&&(k=r),k.indexOf(\"blob:\")!==0?k=k.substr(0,k.replace(/[?#].*/,\"\").lastIndexOf(\"/\")+1):k=\"\",C||(E=F=>{var V=new XMLHttpRequest;return V.open(\"GET\",F,!1),V.send(null),V.responseText},b&&(D=F=>{var V=new XMLHttpRequest;return V.open(\"GET\",F,!1),V.responseType=\"arraybuffer\",V.send(null),new Uint8Array(V.response)}),R=(F,V,ue)=>{var Ee=new XMLHttpRequest;Ee.open(\"GET\",F,!0),Ee.responseType=\"arraybuffer\",Ee.onload=()=>{if(Ee.status==200||Ee.status==0&&Ee.response){V(Ee.response);return}ue()},Ee.onerror=ue,Ee.send(null)}),P=F=>document.title=F);C&&typeof performance==\"undefined\"&&(global.performance=DB().performance);var B=console.log.bind(console),z=console.warn.bind(console);C&&(B=F=>M.writeSync(1,F+`\n`),z=F=>M.writeSync(2,F+`\n`));var U=u.print||B,j=u.printErr||z;Object.assign(u,d),d=null,u.arguments&&(f=u.arguments),u.thisProgram&&(h=u.thisProgram),u.quit&&(g=u.quit);var q=4,Y=Atomics.load,J=Atomics.store,re=Atomics.compareExchange,ne;u.wasmBinary&&(ne=u.wasmBinary);var ee=u.noExitRuntime||!0;typeof WebAssembly!=\"object\"&&$u(\"no native wasm support detected\");var oe,ie,le=!1,be;function _e(F,V){F||$u(V)}var ve=typeof TextDecoder!=\"undefined\"?new TextDecoder(\"utf8\"):void 0;function Fe(F,V,ue){V>>>=0;for(var Ee=V+ue,Be=V;F[Be]&&!(Be>=Ee);)++Be;if(Be-V>16&&F.buffer&&ve)return ve.decode(F.buffer instanceof SharedArrayBuffer?F.slice(V,Be):F.subarray(V,Be));for(var Le=\"\";V>10,56320|so&1023)}}return Le}function Pe(F,V){return F>>>=0,F?Fe(o(),F,V):\"\"}function st(F,V,ue,Ee){if(ue>>>=0,!(Ee>0))return 0;for(var Be=ue,Le=ue+Ee-1,ge=0;ge=55296&&Ne<=57343){var Pt=F.charCodeAt(++ge);Ne=65536+((Ne&1023)<<10)|Pt&1023}if(Ne<=127){if(ue>=Le)break;V[ue++>>>0]=Ne}else if(Ne<=2047){if(ue+1>=Le)break;V[ue++>>>0]=192|Ne>>6,V[ue++>>>0]=128|Ne&63}else if(Ne<=65535){if(ue+2>=Le)break;V[ue++>>>0]=224|Ne>>12,V[ue++>>>0]=128|Ne>>6&63,V[ue++>>>0]=128|Ne&63}else{if(ue+3>=Le)break;V[ue++>>>0]=240|Ne>>18,V[ue++>>>0]=128|Ne>>12&63,V[ue++>>>0]=128|Ne>>6&63,V[ue++>>>0]=128|Ne&63}}return V[ue>>>0]=0,ue-Be}function lt(F,V,ue){return st(F,o(),V,ue)}var Ge,mt,it,gt,xt,Lr,Lt,to,nr;S&&(Ge=u.buffer);function _t(F){Ge=F,u.HEAP8=mt=new Int8Array(F),u.HEAP16=gt=new Int16Array(F),u.HEAP32=Lr=new Int32Array(F),u.HEAPU8=it=new Uint8Array(F),u.HEAPU16=xt=new Uint16Array(F),u.HEAPU32=Lt=new Uint32Array(F),u.HEAPF32=to=new Float32Array(F),u.HEAPF64=nr=new Float64Array(F)}var sr=u.INITIAL_MEMORY||16777216;if(S)oe=u.wasmMemory,Ge=u.buffer;else if(u.wasmMemory)oe=u.wasmMemory;else if(oe=new WebAssembly.Memory({initial:sr/65536,maximum:65536,shared:!0}),!(oe.buffer instanceof SharedArrayBuffer))throw j(\"requested a shared WebAssembly.Memory but the returned buffer is not a SharedArrayBuffer, indicating that while the browser has SharedArrayBuffer it does not have WebAssembly threads support - you may need to set a flag\"),C&&j(\"(on node you may need: --experimental-wasm-threads --experimental-wasm-bulk-memory and/or recent version)\"),Error(\"bad memory\");oe&&(Ge=oe.buffer),sr=Ge.byteLength,_t(Ge);var ar,ro=[],oo=[],hr=[],Wa=!1;function Bo(){return ee}function Ks(){if(u.preRun)for(typeof u.preRun==\"function\"&&(u.preRun=[u.preRun]);u.preRun.length;)sl(u.preRun.shift());ul(ro)}function Yt(){Wa=!0,!S&&ul(oo)}function Ua(){if(!S){if(u.postRun)for(typeof u.postRun==\"function\"&&(u.postRun=[u.postRun]);u.postRun.length;)l0(u.postRun.shift());ul(hr)}}function sl(F){ro.unshift(F)}function al(F){oo.unshift(F)}function l0(F){hr.unshift(F)}var Ti=0,Bp=null,Ga=null;function Cy(F){Ti++,u.monitorRunDependencies&&u.monitorRunDependencies(Ti)}function wm(F){if(Ti--,u.monitorRunDependencies&&u.monitorRunDependencies(Ti),Ti==0&&(Bp!==null&&(clearInterval(Bp),Bp=null),Ga)){var V=Ga;Ga=null,V()}}function $u(F){u.onAbort&&u.onAbort(F),F=\"Aborted(\"+F+\")\",j(F),le=!0,be=1,F+=\". Build with -sASSERTIONS for more info.\";var V=new WebAssembly.RuntimeError(F);throw l(V),V}var wy=\"data:application/octet-stream;base64,\";function Sm(F){return F.startsWith(wy)}function zp(F){return F.startsWith(\"file://\")}var gr;gr=\"tfjs-backend-wasm-threaded-simd.wasm\",Sm(gr)||(gr=_(gr));function Im(F){try{if(F==gr&&ne)return new Uint8Array(ne);if(D)return D(F);throw\"both async and sync fetching of the wasm failed\"}catch(V){$u(V)}}function Sy(){if(!ne&&(x||b)){if(typeof fetch==\"function\"&&!zp(gr))return fetch(gr,{credentials:\"same-origin\"}).then(function(F){if(!F.ok)throw\"failed to load wasm binary file at '\"+gr+\"'\";return F.arrayBuffer()}).catch(function(){return Im(gr)});if(R)return new Promise(function(F,V){R(gr,function(ue){F(new Uint8Array(ue))},V)})}return Promise.resolve().then(function(){return Im(gr)})}function Iy(){var F={env:Om,wasi_snapshot_preview1:Om};function V(ge,Ne){var Pt=ge.exports;if(u.asm=Pt,Dy(u.asm._emscripten_tls_init),ar=u.asm.__indirect_function_table,al(u.asm.__wasm_call_ctors),ie=Ne,!S){var so=Me.unusedWorkers.length;Me.unusedWorkers.forEach(function(Ka){Me.loadWasmModuleToWorker(Ka,function(){--so||wm(\"wasm-instantiate\")})})}}S||Cy(\"wasm-instantiate\");function ue(ge){V(ge.instance,ge.module)}function Ee(ge){return Sy().then(function(Ne){return WebAssembly.instantiate(Ne,F)}).then(function(Ne){return Ne}).then(ge,function(Ne){j(\"failed to asynchronously prepare wasm: \"+Ne),$u(Ne)})}function Be(){return!ne&&typeof WebAssembly.instantiateStreaming==\"function\"&&!Sm(gr)&&!zp(gr)&&!C&&typeof fetch==\"function\"?fetch(gr,{credentials:\"same-origin\"}).then(function(ge){var Ne=WebAssembly.instantiateStreaming(ge,F);return Ne.then(ue,function(Pt){return j(\"wasm streaming compile failed: \"+Pt),j(\"falling back to ArrayBuffer instantiation\"),Ee(ue)})}):Ee(ue)}if(u.instantiateWasm)try{var Le=u.instantiateWasm(F,V);return Le}catch(ge){j(\"Module.instantiateWasm callback failed with error: \"+ge),l(ge)}return Be().catch(l),{}}var m0,d0,vm={};function Eu(F){this.name=\"ExitStatus\",this.message=\"Program terminated with exit(\"+F+\")\",this.status=F}function vy(F){var V=Me.pthreads[F];delete Me.pthreads[F],V.terminate(),jC(F),Me.runningWorkers.splice(Me.runningWorkers.indexOf(V),1),V.pthread_ptr=0}function ky(F){var V=Me.pthreads[F];V.postMessage({cmd:\"cancel\"})}function il(F){var V=Me.pthreads[F];_e(V),Me.returnWorkerToPool(V)}function Ny(F){var V=Me.getNewWorker();if(!V)return 6;Me.runningWorkers.push(V),Me.pthreads[F.pthread_ptr]=V,V.pthread_ptr=F.pthread_ptr;var ue={cmd:\"run\",start_routine:F.startRoutine,arg:F.arg,pthread_ptr:F.pthread_ptr};return V.runPthread=()=>{C&&V.ref(),V.postMessage(ue,F.transferList),delete V.runPthread},V.loaded&&V.runPthread(),0}var km={varargs:void 0,get:function(){km.varargs+=4;var F=s()[km.varargs-4>>>2];return F},getStr:function(F){var V=Pe(F);return V}};function Nm(F){if(S)return _i(1,1,F);be=F,Bo()||(Me.terminateAllThreads(),u.onExit&&u.onExit(F),le=!0),g(F,new Eu(F))}function Ty(F,V){if(be=F,!V&&S)throw _m(F),\"unwind\";Nm(F)}var Tm=Ty;function _y(F){if(F instanceof Eu||F==\"unwind\")return be;g(1,F)}var Me={unusedWorkers:[],runningWorkers:[],tlsInitFunctions:[],pthreads:{},init:function(){S?Me.initWorker():Me.initMainThread()},initMainThread:function(){for(var F=8;F--;)Me.allocateUnusedWorker()},initWorker:function(){ee=!1},setExitStatus:function(F){be=F},terminateAllThreads:function(){for(var F of Object.values(Me.pthreads))Me.returnWorkerToPool(F);for(var F of Me.unusedWorkers)F.terminate();Me.unusedWorkers=[]},returnWorkerToPool:function(F){var V=F.pthread_ptr;delete Me.pthreads[V],Me.unusedWorkers.push(F),Me.runningWorkers.splice(Me.runningWorkers.indexOf(F),1),F.pthread_ptr=0,C&&F.unref(),jC(V)},receiveObjectTransfer:function(F){},threadInitTLS:function(){Me.tlsInitFunctions.forEach(F=>F())},loadWasmModuleToWorker:function(F,V){F.onmessage=Le=>{var ge=Le.data,Ne=ge.cmd;if(F.pthread_ptr&&(Me.currentProxiedOperationCallerThread=F.pthread_ptr),ge.targetThread&&ge.targetThread!=Wm()){var Pt=Me.pthreads[ge.targetThread];Pt?Pt.postMessage(ge,ge.transferList):j('Internal error! Worker sent a message \"'+Ne+'\" to target pthread '+ge.targetThread+\", but that thread no longer exists!\"),Me.currentProxiedOperationCallerThread=void 0;return}Ne===\"processProxyingQueue\"?pl(ge.queue):Ne===\"spawnThread\"?Ny(ge):Ne===\"cleanupThread\"?il(ge.thread):Ne===\"killThread\"?vy(ge.thread):Ne===\"cancelThread\"?ky(ge.thread):Ne===\"loaded\"?(F.loaded=!0,C&&F.unref(),V&&V(F),F.runPthread&&F.runPthread()):Ne===\"print\"?U(\"Thread \"+ge.threadId+\": \"+ge.text):Ne===\"printErr\"?j(\"Thread \"+ge.threadId+\": \"+ge.text):Ne===\"alert\"?alert(\"Thread \"+ge.threadId+\": \"+ge.text):ge.target===\"setimmediate\"?F.postMessage(ge):Ne===\"callHandler\"?u[ge.handler](...ge.args):Ne&&j(\"worker sent an unknown command \"+Ne),Me.currentProxiedOperationCallerThread=void 0},F.onerror=Le=>{var ge=\"worker sent an error!\";throw j(ge+\" \"+Le.filename+\":\"+Le.lineno+\": \"+Le.message),Le},C&&(F.on(\"message\",function(Le){F.onmessage({data:Le})}),F.on(\"error\",function(Le){F.onerror(Le)}),F.on(\"detachedExit\",function(){}));var ue=[],Ee=[\"onExit\",\"onAbort\",\"print\",\"printErr\"];for(var Be of Ee)u.hasOwnProperty(Be)&&ue.push(Be);F.postMessage({cmd:\"load\",handlers:ue,urlOrBlob:u.mainScriptUrlOrBlob||r,wasmMemory:oe,wasmModule:ie})},allocateUnusedWorker:function(){var F,V=_(\"tfjs-backend-wasm-threaded-simd.worker.js\");F=new Worker(V),Me.unusedWorkers.push(F)},getNewWorker:function(){return Me.unusedWorkers.length==0&&(Me.allocateUnusedWorker(),Me.loadWasmModuleToWorker(Me.unusedWorkers[0])),Me.unusedWorkers.pop()}};u.PThread=Me;function ul(F){for(;F.length>0;)F.shift()(u)}function $y(){var F=Wm(),V=s()[F+52>>>2],ue=s()[F+56>>>2],Ee=V-ue;b0(V,Ee),Um(V)}u.establishStackSpace=$y;function _m(F){if(S)return _i(2,0,F);try{Tm(F)}catch(V){_y(V)}}var Vp=[];function Ey(F){var V=Vp[F];return V||(F>=Vp.length&&(Vp.length=F+1),Vp[F]=V=ar.get(F)),V}function Ry(F,V){var ue=Ey(F)(V);Bo()?Me.setExitStatus(ue):y0(ue)}u.invokeEntryPoint=Ry;function Dy(F){Me.tlsInitFunctions.push(F)}function Ay(F){h0(F,!b,1,!x),Me.threadInitTLS()}function Fy(F){S?postMessage({cmd:\"cleanupThread\",thread:F}):il(F)}function $m(F,V,ue,Ee){return S?_i(3,1,F,V,ue,Ee):Em(F,V,ue,Ee)}function Em(F,V,ue,Ee){if(typeof SharedArrayBuffer==\"undefined\")return j(\"Current environment does not support SharedArrayBuffer, pthreads are not available!\"),6;var Be=[],Le=0;if(S&&(Be.length===0||Le))return $m(F,V,ue,Ee);if(Le)return Le;var ge={startRoutine:ue,pthread_ptr:F,arg:Ee,transferList:Be};return S?(ge.cmd=\"spawnThread\",postMessage(ge,Be),0):Ny(ge)}function Py(){return 65536}var Oy=!0;function My(){return Oy}function pl(F){Atomics.store(s(),F>>2,1),Wm()&&x0(F),Atomics.compareExchange(s(),F>>2,1,0)}u.executeNotifiedProxyingQueue=pl;function Ly(F,V,ue,Ee){if(F==V)setTimeout(()=>pl(Ee));else if(S)postMessage({targetThread:F,cmd:\"processProxyingQueue\",queue:Ee});else{var Be=Me.pthreads[F];if(!Be)return;Be.postMessage({cmd:\"processProxyingQueue\",queue:Ee})}return 1}function By(F,V,ue){return-1}function zy(){$u(\"\")}function Ru(F){Ru.shown||(Ru.shown={}),Ru.shown[F]||(Ru.shown[F]=1,C&&(F=\"warning: \"+F),j(F))}function Vy(){C||b||Ru(\"Blocking on the main thread is very dangerous, see https://emscripten.org/docs/porting/pthreads.html#blocking-on-the-main-browser-thread\")}function Wy(){return Date.now()}function Rm(){return 4294901760}function Uy(){return Rm()}var cl;C?cl=()=>{var F=process.hrtime();return F[0]*1e3+F[1]/1e6}:cl=()=>performance.timeOrigin+performance.now();function Gy(F,V,ue){o().copyWithin(F>>>0,V>>>0,V+ue>>>0)}function Hy(){return C?AB().cpus().length:navigator.hardwareConcurrency}function Ky(F){var V=XC(),ue=F();return Um(V),ue}function _i(F,V){var ue=arguments.length-2,Ee=arguments;return Ky(()=>{for(var Be=ue,Le=Gm(Be*8),ge=Le>>3,Ne=0;Ne>>0]=Pt}return g0(F,Be,Le,V)})}var ll=[];function qy(F,V,ue){ll.length=V;for(var Ee=ue>>3,Be=0;Be>>0];var Le=F<0,ge=Le?vm[-F-1]:rb[F];return ge.apply(null,ll)}function jy(F){try{return oe.grow(F-Ge.byteLength+65535>>>16),_t(oe.buffer),1}catch(V){}}function Xy(F){var V=o().length;if(F=F>>>0,F<=V)return!1;var ue=Rm();if(F>ue)return!1;let Ee=(Pt,so)=>Pt+(so-Pt%so)%so;for(var Be=1;Be<=4;Be*=2){var Le=V*(1+.2/Be);Le=Math.min(Le,F+100663296);var ge=Math.min(ue,Ee(Math.max(F,Le),65536)),Ne=jy(ge);if(Ne)return!0}return!1}function Yy(){throw\"unwind\"}function Dm(F){return S?_i(4,1,F):52}function Am(F,V,ue,Ee,Be){return S?_i(5,1,F,V,ue,Ee,Be):70}var Qy=[null,[],[]];function Zy(F,V){var ue=Qy[F];V===0||V===10?((F===1?U:j)(Fe(ue,0)),ue.length=0):ue.push(V)}function Fm(F,V,ue,Ee){if(S)return _i(6,1,F,V,ue,Ee);for(var Be=0,Le=0;Le>>2],Ne=a()[V+4>>>2];V+=8;for(var Pt=0;Pt>>0]);Be+=Ne}return a()[Ee>>>2]=Be,0}function Pm(F){var V=u[\"_\"+F];return V}function Jy(F,V){e().set(F,V>>>0)}function eb(F,V,ue,Ee,Be){var Le={string:Br=>{var Hp=0;if(Br!=null&&Br!==0){var S0=(Br.length<<2)+1;Hp=Gm(S0),lt(Br,Hp,S0)}return Hp},array:Br=>{var Hp=Gm(Br.length);return Jy(Br,Hp),Hp}};function ge(Br){return V===\"string\"?Pe(Br):V===\"boolean\"?!!Br:Br}var Ne=Pm(F),Pt=[],so=0;if(Ee)for(var Ka=0;Kage===\"number\"||ge===\"boolean\"),Le=V!==\"string\";return Le&&Be&&!Ee?Pm(F):function(){return eb(F,V,ue,arguments,Ee)}}Me.init();var rb=[null,Nm,_m,$m,Dm,Am,Fm],Om={__emscripten_init_main_thread_js:Ay,__emscripten_thread_cleanup:Fy,__pthread_create_js:Em,_emscripten_default_pthread_stack_size:Py,_emscripten_get_now_is_monotonic:My,_emscripten_notify_task_queue:Ly,_emscripten_set_offscreencanvas_size:By,abort:zy,emscripten_check_blocking_allowed:Vy,emscripten_date_now:Wy,emscripten_get_heap_max:Uy,emscripten_get_now:cl,emscripten_memcpy_big:Gy,emscripten_num_logical_cores:Hy,emscripten_receive_on_main_thread_js:qy,emscripten_resize_heap:Xy,emscripten_unwind_to_js_event_loop:Yy,exit:Tm,fd_close:Dm,fd_seek:Am,fd_write:Fm,memory:oe||u.wasmMemory},f0=Iy(),ob=u.___wasm_call_ctors=function(){return(ob=u.___wasm_call_ctors=u.asm.__wasm_call_ctors).apply(null,arguments)},nb=u._init=function(){return(nb=u._init=u.asm.init).apply(null,arguments)},sb=u._init_with_threads_count=function(){return(sb=u._init_with_threads_count=u.asm.init_with_threads_count).apply(null,arguments)},ab=u._get_threads_count=function(){return(ab=u._get_threads_count=u.asm.get_threads_count).apply(null,arguments)},ib=u._register_tensor=function(){return(ib=u._register_tensor=u.asm.register_tensor).apply(null,arguments)},ub=u._dispose_data=function(){return(ub=u._dispose_data=u.asm.dispose_data).apply(null,arguments)},pb=u._dispose=function(){return(pb=u._dispose=u.asm.dispose).apply(null,arguments)},cb=u._Abs=function(){return(cb=u._Abs=u.asm.Abs).apply(null,arguments)},lb=u._Acos=function(){return(lb=u._Acos=u.asm.Acos).apply(null,arguments)},mb=u._Acosh=function(){return(mb=u._Acosh=u.asm.Acosh).apply(null,arguments)},db=u._Add=function(){return(db=u._Add=u.asm.Add).apply(null,arguments)},fb=u._AddN=function(){return(fb=u._AddN=u.asm.AddN).apply(null,arguments)},hb=u._All=function(){return(hb=u._All=u.asm.All).apply(null,arguments)},gb=u._Any=function(){return(gb=u._Any=u.asm.Any).apply(null,arguments)},xb=u._ArgMax=function(){return(xb=u._ArgMax=u.asm.ArgMax).apply(null,arguments)},yb=u._ArgMin=function(){return(yb=u._ArgMin=u.asm.ArgMin).apply(null,arguments)},bb=u._Asin=function(){return(bb=u._Asin=u.asm.Asin).apply(null,arguments)},Cb=u._Asinh=function(){return(Cb=u._Asinh=u.asm.Asinh).apply(null,arguments)},wb=u._Atan=function(){return(wb=u._Atan=u.asm.Atan).apply(null,arguments)},Sb=u._Atan2=function(){return(Sb=u._Atan2=u.asm.Atan2).apply(null,arguments)},Ib=u._Atanh=function(){return(Ib=u._Atanh=u.asm.Atanh).apply(null,arguments)},vb=u._AvgPool=function(){return(vb=u._AvgPool=u.asm.AvgPool).apply(null,arguments)},kb=u._AvgPool3D=function(){return(kb=u._AvgPool3D=u.asm.AvgPool3D).apply(null,arguments)},Nb=u._AvgPool3DGrad=function(){return(Nb=u._AvgPool3DGrad=u.asm.AvgPool3DGrad).apply(null,arguments)},Tb=u._AvgPoolGrad=function(){return(Tb=u._AvgPoolGrad=u.asm.AvgPoolGrad).apply(null,arguments)},_b=u._BatchMatMul=function(){return(_b=u._BatchMatMul=u.asm.BatchMatMul).apply(null,arguments)},$b=u._Bincount=function(){return($b=u._Bincount=u.asm.Bincount).apply(null,arguments)},Eb=u._BitwiseAnd=function(){return(Eb=u._BitwiseAnd=u.asm.BitwiseAnd).apply(null,arguments)},Rb=u._Ceil=function(){return(Rb=u._Ceil=u.asm.Ceil).apply(null,arguments)},Db=u._ClipByValue=function(){return(Db=u._ClipByValue=u.asm.ClipByValue).apply(null,arguments)},Ab=u._Conv2D=function(){return(Ab=u._Conv2D=u.asm.Conv2D).apply(null,arguments)},Fb=u._Conv2DBackpropInput=function(){return(Fb=u._Conv2DBackpropInput=u.asm.Conv2DBackpropInput).apply(null,arguments)},Pb=u._Conv3D=function(){return(Pb=u._Conv3D=u.asm.Conv3D).apply(null,arguments)},Ob=u._Conv3DBackpropFilterV2=function(){return(Ob=u._Conv3DBackpropFilterV2=u.asm.Conv3DBackpropFilterV2).apply(null,arguments)},Mb=u._Conv3DBackpropInputV2=function(){return(Mb=u._Conv3DBackpropInputV2=u.asm.Conv3DBackpropInputV2).apply(null,arguments)},Lb=u._Cos=function(){return(Lb=u._Cos=u.asm.Cos).apply(null,arguments)},Bb=u._Cosh=function(){return(Bb=u._Cosh=u.asm.Cosh).apply(null,arguments)},zb=u._CropAndResize=function(){return(zb=u._CropAndResize=u.asm.CropAndResize).apply(null,arguments)},Vb=u._Cumprod=function(){return(Vb=u._Cumprod=u.asm.Cumprod).apply(null,arguments)},Wb=u._Cumsum=function(){return(Wb=u._Cumsum=u.asm.Cumsum).apply(null,arguments)},Ub=u._DenseBincount=function(){return(Ub=u._DenseBincount=u.asm.DenseBincount).apply(null,arguments)},Gb=u._DepthToSpace=function(){return(Gb=u._DepthToSpace=u.asm.DepthToSpace).apply(null,arguments)},Hb=u._DepthwiseConv2dNative=function(){return(Hb=u._DepthwiseConv2dNative=u.asm.DepthwiseConv2dNative).apply(null,arguments)},Kb=u._Diag=function(){return(Kb=u._Diag=u.asm.Diag).apply(null,arguments)},qb=u._Dilation2D=function(){return(qb=u._Dilation2D=u.asm.Dilation2D).apply(null,arguments)},jb=u._Dilation2DBackpropFilter=function(){return(jb=u._Dilation2DBackpropFilter=u.asm.Dilation2DBackpropFilter).apply(null,arguments)},Xb=u._Dilation2DBackpropInput=function(){return(Xb=u._Dilation2DBackpropInput=u.asm.Dilation2DBackpropInput).apply(null,arguments)},Yb=u._Elu=function(){return(Yb=u._Elu=u.asm.Elu).apply(null,arguments)},Qb=u._EluGrad=function(){return(Qb=u._EluGrad=u.asm.EluGrad).apply(null,arguments)},Zb=u._Equal=function(){return(Zb=u._Equal=u.asm.Equal).apply(null,arguments)},Jb=u._Erf=function(){return(Jb=u._Erf=u.asm.Erf).apply(null,arguments)},eC=u._Exp=function(){return(eC=u._Exp=u.asm.Exp).apply(null,arguments)},tC=u._Expm1=function(){return(tC=u._Expm1=u.asm.Expm1).apply(null,arguments)},rC=u._FlipLeftRight=function(){return(rC=u._FlipLeftRight=u.asm.FlipLeftRight).apply(null,arguments)},oC=u._Floor=function(){return(oC=u._Floor=u.asm.Floor).apply(null,arguments)},nC=u._FloorDiv=function(){return(nC=u._FloorDiv=u.asm.FloorDiv).apply(null,arguments)},sC=u._FusedBatchNorm=function(){return(sC=u._FusedBatchNorm=u.asm.FusedBatchNorm).apply(null,arguments)},aC=u._FusedConv2D=function(){return(aC=u._FusedConv2D=u.asm.FusedConv2D).apply(null,arguments)},iC=u._FusedDepthwiseConv2D=function(){return(iC=u._FusedDepthwiseConv2D=u.asm.FusedDepthwiseConv2D).apply(null,arguments)},uC=u._Gather=function(){return(uC=u._Gather=u.asm.Gather).apply(null,arguments)},pC=u._GatherNd=function(){return(pC=u._GatherNd=u.asm.GatherNd).apply(null,arguments)},cC=u._Greater=function(){return(cC=u._Greater=u.asm.Greater).apply(null,arguments)},lC=u._GreaterEqual=function(){return(lC=u._GreaterEqual=u.asm.GreaterEqual).apply(null,arguments)},mC=u._IsFinite=function(){return(mC=u._IsFinite=u.asm.IsFinite).apply(null,arguments)},dC=u._IsInf=function(){return(dC=u._IsInf=u.asm.IsInf).apply(null,arguments)},fC=u._IsNan=function(){return(fC=u._IsNan=u.asm.IsNan).apply(null,arguments)},hC=u._LRN=function(){return(hC=u._LRN=u.asm.LRN).apply(null,arguments)},gC=u._LRNGrad=function(){return(gC=u._LRNGrad=u.asm.LRNGrad).apply(null,arguments)},xC=u._LeakyRelu=function(){return(xC=u._LeakyRelu=u.asm.LeakyRelu).apply(null,arguments)},yC=u._Less=function(){return(yC=u._Less=u.asm.Less).apply(null,arguments)},bC=u._LessEqual=function(){return(bC=u._LessEqual=u.asm.LessEqual).apply(null,arguments)},CC=u._LinSpace=function(){return(CC=u._LinSpace=u.asm.LinSpace).apply(null,arguments)},wC=u._Log=function(){return(wC=u._Log=u.asm.Log).apply(null,arguments)},SC=u._Log1p=function(){return(SC=u._Log1p=u.asm.Log1p).apply(null,arguments)},IC=u._LogicalAnd=function(){return(IC=u._LogicalAnd=u.asm.LogicalAnd).apply(null,arguments)},vC=u._LogicalNot=function(){return(vC=u._LogicalNot=u.asm.LogicalNot).apply(null,arguments)},kC=u._LogicalOr=function(){return(kC=u._LogicalOr=u.asm.LogicalOr).apply(null,arguments)},NC=u._LogicalXor=function(){return(NC=u._LogicalXor=u.asm.LogicalXor).apply(null,arguments)},TC=u._Max=function(){return(TC=u._Max=u.asm.Max).apply(null,arguments)},_C=u._MaxPool=function(){return(_C=u._MaxPool=u.asm.MaxPool).apply(null,arguments)},$C=u._MaxPool3D=function(){return($C=u._MaxPool3D=u.asm.MaxPool3D).apply(null,arguments)},EC=u._MaxPool3DGrad=function(){return(EC=u._MaxPool3DGrad=u.asm.MaxPool3DGrad).apply(null,arguments)},RC=u._MaxPoolGrad=function(){return(RC=u._MaxPoolGrad=u.asm.MaxPoolGrad).apply(null,arguments)},DC=u._MaxPoolWithArgmax=function(){return(DC=u._MaxPoolWithArgmax=u.asm.MaxPoolWithArgmax).apply(null,arguments)},AC=u._Maximum=function(){return(AC=u._Maximum=u.asm.Maximum).apply(null,arguments)},FC=u._Mean=function(){return(FC=u._Mean=u.asm.Mean).apply(null,arguments)},PC=u._Min=function(){return(PC=u._Min=u.asm.Min).apply(null,arguments)},OC=u._Minimum=function(){return(OC=u._Minimum=u.asm.Minimum).apply(null,arguments)},MC=u._MirrorPad=function(){return(MC=u._MirrorPad=u.asm.MirrorPad).apply(null,arguments)},LC=u._Mod=function(){return(LC=u._Mod=u.asm.Mod).apply(null,arguments)},BC=u._Multinomial=function(){return(BC=u._Multinomial=u.asm.Multinomial).apply(null,arguments)},zC=u._Multiply=function(){return(zC=u._Multiply=u.asm.Multiply).apply(null,arguments)},VC=u._Neg=function(){return(VC=u._Neg=u.asm.Neg).apply(null,arguments)},WC=u._NonMaxSuppressionV3=function(){return(WC=u._NonMaxSuppressionV3=u.asm.NonMaxSuppressionV3).apply(null,arguments)},UC=u._NonMaxSuppressionV4=function(){return(UC=u._NonMaxSuppressionV4=u.asm.NonMaxSuppressionV4).apply(null,arguments)},Mm=u._NonMaxSuppressionV5=function(){return(Mm=u._NonMaxSuppressionV5=u.asm.NonMaxSuppressionV5).apply(null,arguments)},Lm=u._NotEqual=function(){return(Lm=u._NotEqual=u.asm.NotEqual).apply(null,arguments)},ml=u._OneHot=function(){return(ml=u._OneHot=u.asm.OneHot).apply(null,arguments)},GC=u._PadV2=function(){return(GC=u._PadV2=u.asm.PadV2).apply(null,arguments)},HC=u._Pow=function(){return(HC=u._Pow=u.asm.Pow).apply(null,arguments)},Wp=u._Prelu=function(){return(Wp=u._Prelu=u.asm.Prelu).apply(null,arguments)},Bm=u._Prod=function(){return(Bm=u._Prod=u.asm.Prod).apply(null,arguments)},Up=u._RealDiv=function(){return(Up=u._RealDiv=u.asm.RealDiv).apply(null,arguments)},Gp=u._Reciprocal=function(){return(Gp=u._Reciprocal=u.asm.Reciprocal).apply(null,arguments)},KC=u._Relu=function(){return(KC=u._Relu=u.asm.Relu).apply(null,arguments)},K=u._Relu6=function(){return(K=u._Relu6=u.asm.Relu6).apply(null,arguments)},ae=u._ResizeBilinear=function(){return(ae=u._ResizeBilinear=u.asm.ResizeBilinear).apply(null,arguments)},$e=u._ResizeBilinearGrad=function(){return($e=u._ResizeBilinearGrad=u.asm.ResizeBilinearGrad).apply(null,arguments)},at=u._ResizeNearestNeighbor=function(){return(at=u._ResizeNearestNeighbor=u.asm.ResizeNearestNeighbor).apply(null,arguments)},$t=u._ResizeNearestNeighborGrad=function(){return($t=u._ResizeNearestNeighborGrad=u.asm.ResizeNearestNeighborGrad).apply(null,arguments)},Et=u._Reverse=function(){return(Et=u._Reverse=u.asm.Reverse).apply(null,arguments)},Qe=u._RotateWithOffset=function(){return(Qe=u._RotateWithOffset=u.asm.RotateWithOffset).apply(null,arguments)},Ke=u._Round=function(){return(Ke=u._Round=u.asm.Round).apply(null,arguments)},Gt=u._Rsqrt=function(){return(Gt=u._Rsqrt=u.asm.Rsqrt).apply(null,arguments)},no=u._ScatterNd=function(){return(no=u._ScatterNd=u.asm.ScatterNd).apply(null,arguments)},Ha=u._SearchSorted=function(){return(Ha=u._SearchSorted=u.asm.SearchSorted).apply(null,arguments)},zm=u._SelectV2=function(){return(zm=u._SelectV2=u.asm.SelectV2).apply(null,arguments)},dl=u._Selu=function(){return(dl=u._Selu=u.asm.Selu).apply(null,arguments)},qC=u._Sigmoid=function(){return(qC=u._Sigmoid=u.asm.Sigmoid).apply(null,arguments)},br=u._Sign=function(){return(br=u._Sign=u.asm.Sign).apply(null,arguments)},$i=u._Sin=function(){return($i=u._Sin=u.asm.Sin).apply(null,arguments)},Vm=u._Sinh=function(){return(Vm=u._Sinh=u.asm.Sinh).apply(null,arguments)},WU=u._Softmax=function(){return(WU=u._Softmax=u.asm.Softmax).apply(null,arguments)},UU=u._Softplus=function(){return(UU=u._Softplus=u.asm.Softplus).apply(null,arguments)},GU=u._SparseFillEmptyRows=function(){return(GU=u._SparseFillEmptyRows=u.asm.SparseFillEmptyRows).apply(null,arguments)},HU=u._SparseReshape=function(){return(HU=u._SparseReshape=u.asm.SparseReshape).apply(null,arguments)},KU=u._SparseSegmentReduction=function(){return(KU=u._SparseSegmentReduction=u.asm.SparseSegmentReduction).apply(null,arguments)},qU=u._SparseToDense=function(){return(qU=u._SparseToDense=u.asm.SparseToDense).apply(null,arguments)},jU=u._Sqrt=function(){return(jU=u._Sqrt=u.asm.Sqrt).apply(null,arguments)},XU=u._Square=function(){return(XU=u._Square=u.asm.Square).apply(null,arguments)},YU=u._SquaredDifference=function(){return(YU=u._SquaredDifference=u.asm.SquaredDifference).apply(null,arguments)},QU=u._Step=function(){return(QU=u._Step=u.asm.Step).apply(null,arguments)},ZU=u._StridedSlice=function(){return(ZU=u._StridedSlice=u.asm.StridedSlice).apply(null,arguments)},JU=u._Sub=function(){return(JU=u._Sub=u.asm.Sub).apply(null,arguments)},eG=u._Sum=function(){return(eG=u._Sum=u.asm.Sum).apply(null,arguments)},tG=u._Tan=function(){return(tG=u._Tan=u.asm.Tan).apply(null,arguments)},rG=u._Tanh=function(){return(rG=u._Tanh=u.asm.Tanh).apply(null,arguments)},oG=u._TensorScatterUpdate=function(){return(oG=u._TensorScatterUpdate=u.asm.TensorScatterUpdate).apply(null,arguments)},nG=u._Tile=function(){return(nG=u._Tile=u.asm.Tile).apply(null,arguments)},sG=u._TopK=function(){return(sG=u._TopK=u.asm.TopK).apply(null,arguments)},aG=u._Transform=function(){return(aG=u._Transform=u.asm.Transform).apply(null,arguments)},iG=u._Transpose=function(){return(iG=u._Transpose=u.asm.Transpose).apply(null,arguments)},uG=u.__FusedMatMul=function(){return(uG=u.__FusedMatMul=u.asm._FusedMatMul).apply(null,arguments)},pG=u._malloc=function(){return(pG=u._malloc=u.asm.malloc).apply(null,arguments)},cG=u._free=function(){return(cG=u._free=u.asm.free).apply(null,arguments)},lG=u.__emscripten_tls_init=function(){return(lG=u.__emscripten_tls_init=u.asm._emscripten_tls_init).apply(null,arguments)},Wm=u._pthread_self=function(){return(Wm=u._pthread_self=u.asm.pthread_self).apply(null,arguments)},mG=u.___errno_location=function(){return(mG=u.___errno_location=u.asm.__errno_location).apply(null,arguments)},h0=u.__emscripten_thread_init=function(){return(h0=u.__emscripten_thread_init=u.asm._emscripten_thread_init).apply(null,arguments)},dG=u.__emscripten_thread_crashed=function(){return(dG=u.__emscripten_thread_crashed=u.asm._emscripten_thread_crashed).apply(null,arguments)},fG=u._emscripten_main_thread_process_queued_calls=function(){return(fG=u._emscripten_main_thread_process_queued_calls=u.asm.emscripten_main_thread_process_queued_calls).apply(null,arguments)},hG=u._emscripten_main_browser_thread_id=function(){return(hG=u._emscripten_main_browser_thread_id=u.asm.emscripten_main_browser_thread_id).apply(null,arguments)},g0=u._emscripten_run_in_main_runtime_thread_js=function(){return(g0=u._emscripten_run_in_main_runtime_thread_js=u.asm.emscripten_run_in_main_runtime_thread_js).apply(null,arguments)},gG=u._emscripten_dispatch_to_thread_=function(){return(gG=u._emscripten_dispatch_to_thread_=u.asm.emscripten_dispatch_to_thread_).apply(null,arguments)},x0=u.__emscripten_proxy_execute_task_queue=function(){return(x0=u.__emscripten_proxy_execute_task_queue=u.asm._emscripten_proxy_execute_task_queue).apply(null,arguments)},jC=u.__emscripten_thread_free_data=function(){return(jC=u.__emscripten_thread_free_data=u.asm._emscripten_thread_free_data).apply(null,arguments)},y0=u.__emscripten_thread_exit=function(){return(y0=u.__emscripten_thread_exit=u.asm._emscripten_thread_exit).apply(null,arguments)},b0=u._emscripten_stack_set_limits=function(){return(b0=u._emscripten_stack_set_limits=u.asm.emscripten_stack_set_limits).apply(null,arguments)},XC=u.stackSave=function(){return(XC=u.stackSave=u.asm.stackSave).apply(null,arguments)},Um=u.stackRestore=function(){return(Um=u.stackRestore=u.asm.stackRestore).apply(null,arguments)},Gm=u.stackAlloc=function(){return(Gm=u.stackAlloc=u.asm.stackAlloc).apply(null,arguments)},xG=u.dynCall_iijjiiii=function(){return(xG=u.dynCall_iijjiiii=u.asm.dynCall_iijjiiii).apply(null,arguments)},yG=u.dynCall_jiji=function(){return(yG=u.dynCall_jiji=u.asm.dynCall_jiji).apply(null,arguments)};u.keepRuntimeAlive=Bo,u.wasmMemory=oe,u.cwrap=tb,u.ExitStatus=Eu,u.PThread=Me;var Hm;Ga=function F(){Hm||C0(),Hm||(Ga=F)};function C0(F){if(F=F||f,Ti>0)return;if(S){c(u),Yt(),startWorker(u);return}if(Ks(),Ti>0)return;function V(){Hm||(Hm=!0,u.calledRun=!0,!le&&(Yt(),c(u),u.onRuntimeInitialized&&u.onRuntimeInitialized(),Ua()))}u.setStatus?(u.setStatus(\"Running...\"),setTimeout(function(){setTimeout(function(){u.setStatus(\"\")},1),V()},1)):V()}if(u.preInit)for(typeof u.preInit==\"function\"&&(u.preInit=[u.preInit]);u.preInit.length>0;)u.preInit.pop()();C0();var Km;m&&(Km={uncaughtException:process.listeners(\"uncaughtException\").filter(function(F){return!m.uncaughtException.indexOf(F)>-1}),unhandledRejection:process.listeners(\"unhandledRejection\").filter(function(F){return!m.unhandledRejection.indexOf(F)>-1})});var qm;if(typeof WasmBackendModule!=\"undefined\")qm=WasmBackendModule;else if(typeof t!=\"undefined\")qm=t;else throw new Error(\"Could not find wasm module in post.js\");if(Km){var bG=qm._dispose;qm._dispose=function(){bG(),Km.uncaughtException.forEach(function(F){process.removeListener(\"uncaughtException\",F)}),Km.unhandledRejection.forEach(function(F){process.removeListener(\"unhandledRejection\",F)})}}return t.ready}})();typeof Wg==\"object\"&&typeof Wv==\"object\"?Wv.exports=Vv:typeof define==\"function\"&&define.amd?define([],function(){return Vv}):typeof Wg==\"object\"&&(Wg.WasmBackendModuleThreadedSimd=Vv)});var OB=qt((UFt,PB)=>{PB.exports.wasmWorkerContents=`\"use strict\";var Module={};var ENVIRONMENT_IS_NODE=typeof process==\"object\"&&typeof process.versions==\"object\"&&typeof process.versions.node==\"string\";if(ENVIRONMENT_IS_NODE){var nodeWorkerThreads=require(\"worker_threads\");var parentPort=nodeWorkerThreads.parentPort;parentPort.on(\"message\",data=>onmessage({data:data}));var fs=require(\"fs\");Object.assign(global,{self:global,require:require,Module:Module,location:{href:__filename},Worker:nodeWorkerThreads.Worker,importScripts:function(f){(0,eval)(fs.readFileSync(f,\"utf8\")+\"//# sourceURL=\"+f)},postMessage:function(msg){parentPort.postMessage(msg)},performance:global.performance||{now:function(){return Date.now()}}})}var initializedJS=false;var pendingNotifiedProxyingQueues=[];function threadPrintErr(){var text=Array.prototype.slice.call(arguments).join(\" \");if(ENVIRONMENT_IS_NODE){fs.writeSync(2,text+\"\n\");return}console.error(text)}function threadAlert(){var text=Array.prototype.slice.call(arguments).join(\" \");postMessage({cmd:\"alert\",text:text,threadId:Module[\"_pthread_self\"]()})}var err=threadPrintErr;self.alert=threadAlert;Module[\"instantiateWasm\"]=(info,receiveInstance)=>{var instance=new WebAssembly.Instance(Module[\"wasmModule\"],info);receiveInstance(instance);Module[\"wasmModule\"]=null;return instance.exports};self.onunhandledrejection=e=>{throw e.reason??e};self.startWorker=instance=>{Module=instance;postMessage({\"cmd\":\"loaded\"})};self.onmessage=e=>{try{if(e.data.cmd===\"load\"){Module[\"wasmModule\"]=e.data.wasmModule;for(const handler of e.data.handlers){Module[handler]=function(){postMessage({cmd:\"callHandler\",handler:handler,args:[...arguments]})}}Module[\"wasmMemory\"]=e.data.wasmMemory;Module[\"buffer\"]=Module[\"wasmMemory\"].buffer;Module[\"ENVIRONMENT_IS_PTHREAD\"]=true;if(typeof e.data.urlOrBlob==\"string\"){importScripts(e.data.urlOrBlob)}else{var objectUrl=URL.createObjectURL(e.data.urlOrBlob);importScripts(objectUrl);URL.revokeObjectURL(objectUrl)}WasmBackendModuleThreadedSimd(Module)}else if(e.data.cmd===\"run\"){Module[\"__emscripten_thread_init\"](e.data.pthread_ptr,0,0,1);Module[\"establishStackSpace\"]();Module[\"PThread\"].receiveObjectTransfer(e.data);Module[\"PThread\"].threadInitTLS();if(!initializedJS){pendingNotifiedProxyingQueues.forEach(queue=>{Module[\"executeNotifiedProxyingQueue\"](queue)});pendingNotifiedProxyingQueues=[];initializedJS=true}try{Module[\"invokeEntryPoint\"](e.data.start_routine,e.data.arg)}catch(ex){if(ex!=\"unwind\"){if(ex instanceof Module[\"ExitStatus\"]){if(Module[\"keepRuntimeAlive\"]()){}else{Module[\"__emscripten_thread_exit\"](ex.status)}}else{throw ex}}}}else if(e.data.cmd===\"cancel\"){if(Module[\"_pthread_self\"]()){Module[\"__emscripten_thread_exit\"](-1)}}else if(e.data.target===\"setimmediate\"){}else if(e.data.cmd===\"processProxyingQueue\"){if(initializedJS){Module[\"executeNotifiedProxyingQueue\"](e.data.queue)}else{pendingNotifiedProxyingQueues.push(e.data.queue)}}else if(e.data.cmd){err(\"worker.js received unknown command \"+e.data.cmd);err(e.data)}}catch(ex){if(Module[\"__emscripten_thread_crashed\"]){Module[\"__emscripten_thread_crashed\"]()}throw ex}};`});var MB=qt((Ug,Gv)=>{var Uv=(()=>{var r=typeof document!=\"undefined\"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename!=\"undefined\"&&(r=r||__filename),function(t){t=t||{};var e=typeof t!=\"undefined\"?t:{},o,n;e.ready=new Promise(function(K,ae){o=K,n=ae});var s;typeof process!=\"undefined\"&&process.listeners&&(s={uncaughtException:process.listeners(\"uncaughtException\"),unhandledRejection:process.listeners(\"unhandledRejection\")});var a=Object.assign({},e),i=[],p=\"./this.program\",u=(K,ae)=>{throw ae},c=typeof window==\"object\",l=typeof importScripts==\"function\",m=typeof process==\"object\"&&typeof process.versions==\"object\"&&typeof process.versions.node==\"string\",d=\"\";function f(K){return e.locateFile?e.locateFile(K,d):d+K}var h,g,x,b;function C(K){if(K instanceof Bp)return;E(\"exiting due to exception: \"+K)}if(m){var S=Bv(),k=zv();l?d=k.dirname(d)+\"/\":d=__dirname+\"/\",h=(K,ae)=>(K=Ks(K)?new URL(K):k.normalize(K),S.readFileSync(K,ae?void 0:\"utf8\")),x=K=>{var ae=h(K,!0);return ae.buffer||(ae=new Uint8Array(ae)),ae},g=(K,ae,$e)=>{K=Ks(K)?new URL(K):k.normalize(K),S.readFile(K,function(at,$t){at?$e(at):ae($t.buffer)})},process.argv.length>1&&(p=process.argv[1].replace(/\\\\/g,\"/\")),i=process.argv.slice(2),process.on(\"uncaughtException\",function(K){if(!(K instanceof Bp))throw K}),process.on(\"unhandledRejection\",function(K){throw K}),u=(K,ae)=>{if(it())throw process.exitCode=K,ae;C(ae),process.exit(K)},e.inspect=function(){return\"[Emscripten Module object]\"}}else(c||l)&&(l?d=self.location.href:typeof document!=\"undefined\"&&document.currentScript&&(d=document.currentScript.src),r&&(d=r),d.indexOf(\"blob:\")!==0?d=d.substr(0,d.replace(/[?#].*/,\"\").lastIndexOf(\"/\")+1):d=\"\",h=K=>{var ae=new XMLHttpRequest;return ae.open(\"GET\",K,!1),ae.send(null),ae.responseText},l&&(x=K=>{var ae=new XMLHttpRequest;return ae.open(\"GET\",K,!1),ae.responseType=\"arraybuffer\",ae.send(null),new Uint8Array(ae.response)}),g=(K,ae,$e)=>{var at=new XMLHttpRequest;at.open(\"GET\",K,!0),at.responseType=\"arraybuffer\",at.onload=()=>{if(at.status==200||at.status==0&&at.response){ae(at.response);return}$e()},at.onerror=$e,at.send(null)},b=K=>document.title=K);var _=e.print||console.log.bind(console),E=e.printErr||console.warn.bind(console);Object.assign(e,a),a=null,e.arguments&&(i=e.arguments),e.thisProgram&&(p=e.thisProgram),e.quit&&(u=e.quit);var R=4,D;e.wasmBinary&&(D=e.wasmBinary);var P=e.noExitRuntime||!0;typeof WebAssembly!=\"object\"&&hr(\"no native wasm support detected\");var O,M=!1,L;function B(K,ae){K||hr(ae)}var z=typeof TextDecoder!=\"undefined\"?new TextDecoder(\"utf8\"):void 0;function U(K,ae,$e){ae>>>=0;for(var at=ae+$e,$t=ae;K[$t]&&!($t>=at);)++$t;if($t-ae>16&&K.buffer&&z)return z.decode(K.subarray(ae,$t));for(var Et=\"\";ae<$t;){var Qe=K[ae++];if(!(Qe&128)){Et+=String.fromCharCode(Qe);continue}var Ke=K[ae++]&63;if((Qe&224)==192){Et+=String.fromCharCode((Qe&31)<<6|Ke);continue}var Gt=K[ae++]&63;if((Qe&240)==224?Qe=(Qe&15)<<12|Ke<<6|Gt:Qe=(Qe&7)<<18|Ke<<12|Gt<<6|K[ae++]&63,Qe<65536)Et+=String.fromCharCode(Qe);else{var no=Qe-65536;Et+=String.fromCharCode(55296|no>>10,56320|no&1023)}}return Et}function j(K,ae){return K>>>=0,K?U(ne,K,ae):\"\"}function q(K,ae,$e,at){if($e>>>=0,!(at>0))return 0;for(var $t=$e,Et=$e+at-1,Qe=0;Qe=55296&&Ke<=57343){var Gt=K.charCodeAt(++Qe);Ke=65536+((Ke&1023)<<10)|Gt&1023}if(Ke<=127){if($e>=Et)break;ae[$e++>>>0]=Ke}else if(Ke<=2047){if($e+1>=Et)break;ae[$e++>>>0]=192|Ke>>6,ae[$e++>>>0]=128|Ke&63}else if(Ke<=65535){if($e+2>=Et)break;ae[$e++>>>0]=224|Ke>>12,ae[$e++>>>0]=128|Ke>>6&63,ae[$e++>>>0]=128|Ke&63}else{if($e+3>=Et)break;ae[$e++>>>0]=240|Ke>>18,ae[$e++>>>0]=128|Ke>>12&63,ae[$e++>>>0]=128|Ke>>6&63,ae[$e++>>>0]=128|Ke&63}}return ae[$e>>>0]=0,$e-$t}function Y(K,ae,$e){return q(K,ne,ae,$e)}var J,re,ne,ee,oe,ie,le,be,_e;function ve(K){J=K,e.HEAP8=re=new Int8Array(K),e.HEAP16=ee=new Int16Array(K),e.HEAP32=ie=new Int32Array(K),e.HEAPU8=ne=new Uint8Array(K),e.HEAPU16=oe=new Uint16Array(K),e.HEAPU32=le=new Uint32Array(K),e.HEAPF32=be=new Float32Array(K),e.HEAPF64=_e=new Float64Array(K)}var Fe=e.INITIAL_MEMORY||16777216,Pe,st=[],lt=[],Ge=[],mt=!1;function it(){return P}function gt(){if(e.preRun)for(typeof e.preRun==\"function\"&&(e.preRun=[e.preRun]);e.preRun.length;)Lt(e.preRun.shift());Ga(st)}function xt(){mt=!0,Ga(lt)}function Lr(){if(e.postRun)for(typeof e.postRun==\"function\"&&(e.postRun=[e.postRun]);e.postRun.length;)nr(e.postRun.shift());Ga(Ge)}function Lt(K){st.unshift(K)}function to(K){lt.unshift(K)}function nr(K){Ge.unshift(K)}var _t=0,sr=null,ar=null;function ro(K){_t++,e.monitorRunDependencies&&e.monitorRunDependencies(_t)}function oo(K){if(_t--,e.monitorRunDependencies&&e.monitorRunDependencies(_t),_t==0&&(sr!==null&&(clearInterval(sr),sr=null),ar)){var ae=ar;ar=null,ae()}}function hr(K){e.onAbort&&e.onAbort(K),K=\"Aborted(\"+K+\")\",E(K),M=!0,L=1,K+=\". Build with -sASSERTIONS for more info.\";var ae=new WebAssembly.RuntimeError(K);throw n(ae),ae}var Wa=\"data:application/octet-stream;base64,\";function Bo(K){return K.startsWith(Wa)}function Ks(K){return K.startsWith(\"file://\")}var Yt;Yt=\"tfjs-backend-wasm.wasm\",Bo(Yt)||(Yt=f(Yt));function Ua(K){try{if(K==Yt&&D)return new Uint8Array(D);if(x)return x(K);throw\"both async and sync fetching of the wasm failed\"}catch(ae){hr(ae)}}function sl(){if(!D&&(c||l)){if(typeof fetch==\"function\"&&!Ks(Yt))return fetch(Yt,{credentials:\"same-origin\"}).then(function(K){if(!K.ok)throw\"failed to load wasm binary file at '\"+Yt+\"'\";return K.arrayBuffer()}).catch(function(){return Ua(Yt)});if(g)return new Promise(function(K,ae){g(Yt,function($e){K(new Uint8Array($e))},ae)})}return Promise.resolve().then(function(){return Ua(Yt)})}function al(){var K={env:il,wasi_snapshot_preview1:il};function ae(Qe,Ke){var Gt=Qe.exports;e.asm=Gt,O=e.asm.memory,ve(O.buffer),Pe=e.asm.__indirect_function_table,to(e.asm.__wasm_call_ctors),oo(\"wasm-instantiate\")}ro(\"wasm-instantiate\");function $e(Qe){ae(Qe.instance)}function at(Qe){return sl().then(function(Ke){return WebAssembly.instantiate(Ke,K)}).then(function(Ke){return Ke}).then(Qe,function(Ke){E(\"failed to asynchronously prepare wasm: \"+Ke),hr(Ke)})}function $t(){return!D&&typeof WebAssembly.instantiateStreaming==\"function\"&&!Bo(Yt)&&!Ks(Yt)&&!m&&typeof fetch==\"function\"?fetch(Yt,{credentials:\"same-origin\"}).then(function(Qe){var Ke=WebAssembly.instantiateStreaming(Qe,K);return Ke.then($e,function(Gt){return E(\"wasm streaming compile failed: \"+Gt),E(\"falling back to ArrayBuffer instantiation\"),at($e)})}):at($e)}if(e.instantiateWasm)try{var Et=e.instantiateWasm(K,ae);return Et}catch(Qe){E(\"Module.instantiateWasm callback failed with error: \"+Qe),n(Qe)}return $t().catch(n),{}}var l0,Ti;function Bp(K){this.name=\"ExitStatus\",this.message=\"Program terminated with exit(\"+K+\")\",this.status=K}function Ga(K){for(;K.length>0;)K.shift()(e)}function Cy(){hr(\"\")}function wm(){return 4294901760}function $u(){return wm()}function wy(K,ae,$e){ne.copyWithin(K>>>0,ae>>>0,ae+$e>>>0)}function Sm(K){try{return O.grow(K-J.byteLength+65535>>>16),ve(O.buffer),1}catch(ae){}}function zp(K){var ae=ne.length;K=K>>>0;var $e=wm();if(K>$e)return!1;let at=(Gt,no)=>Gt+(no-Gt%no)%no;for(var $t=1;$t<=4;$t*=2){var Et=ae*(1+.2/$t);Et=Math.min(Et,K+100663296);var Qe=Math.min($e,at(Math.max(K,Et),65536)),Ke=Sm(Qe);if(Ke)return!0}return!1}var gr={varargs:void 0,get:function(){gr.varargs+=4;var K=ie[gr.varargs-4>>>2];return K},getStr:function(K){var ae=j(K);return ae}};function Im(K){return 52}function Sy(K,ae,$e,at,$t){return 70}var Iy=[null,[],[]];function m0(K,ae){var $e=Iy[K];ae===0||ae===10?((K===1?_:E)(U($e,0)),$e.length=0):$e.push(ae)}function d0(K,ae,$e,at){for(var $t=0,Et=0;Et<$e;Et++){var Qe=le[ae>>>2],Ke=le[ae+4>>>2];ae+=8;for(var Gt=0;Gt>>0]);$t+=Ke}return le[at>>>2]=$t,0}function vm(K){var ae=e[\"_\"+K];return ae}function Eu(K,ae){re.set(K,ae>>>0)}function vy(K,ae,$e,at,$t){var Et={string:br=>{var $i=0;if(br!=null&&br!==0){var Vm=(br.length<<2)+1;$i=ml(Vm),Y(br,$i,Vm)}return $i},array:br=>{var $i=ml(br.length);return Eu(br,$i),$i}};function Qe(br){return ae===\"string\"?j(br):ae===\"boolean\"?!!br:br}var Ke=vm(K),Gt=[],no=0;if(at)for(var Ha=0;HaQe===\"number\"||Qe===\"boolean\"),Et=ae!==\"string\";return Et&&$t&&!at?vm(K):function(){return vy(K,ae,$e,arguments,at)}}var il={abort:Cy,emscripten_get_heap_max:$u,emscripten_memcpy_big:wy,emscripten_resize_heap:zp,fd_close:Im,fd_seek:Sy,fd_write:d0},Ny=al(),km=e.___wasm_call_ctors=function(){return(km=e.___wasm_call_ctors=e.asm.__wasm_call_ctors).apply(null,arguments)},Nm=e._init=function(){return(Nm=e._init=e.asm.init).apply(null,arguments)},Ty=e._init_with_threads_count=function(){return(Ty=e._init_with_threads_count=e.asm.init_with_threads_count).apply(null,arguments)},Tm=e._get_threads_count=function(){return(Tm=e._get_threads_count=e.asm.get_threads_count).apply(null,arguments)},_y=e._register_tensor=function(){return(_y=e._register_tensor=e.asm.register_tensor).apply(null,arguments)},Me=e._dispose_data=function(){return(Me=e._dispose_data=e.asm.dispose_data).apply(null,arguments)},ul=e._dispose=function(){return(ul=e._dispose=e.asm.dispose).apply(null,arguments)},$y=e._Abs=function(){return($y=e._Abs=e.asm.Abs).apply(null,arguments)},_m=e._Acos=function(){return(_m=e._Acos=e.asm.Acos).apply(null,arguments)},Vp=e._Acosh=function(){return(Vp=e._Acosh=e.asm.Acosh).apply(null,arguments)},Ey=e._Add=function(){return(Ey=e._Add=e.asm.Add).apply(null,arguments)},Ry=e._AddN=function(){return(Ry=e._AddN=e.asm.AddN).apply(null,arguments)},Dy=e._All=function(){return(Dy=e._All=e.asm.All).apply(null,arguments)},Ay=e._Any=function(){return(Ay=e._Any=e.asm.Any).apply(null,arguments)},Fy=e._ArgMax=function(){return(Fy=e._ArgMax=e.asm.ArgMax).apply(null,arguments)},$m=e._ArgMin=function(){return($m=e._ArgMin=e.asm.ArgMin).apply(null,arguments)},Em=e._Asin=function(){return(Em=e._Asin=e.asm.Asin).apply(null,arguments)},Py=e._Asinh=function(){return(Py=e._Asinh=e.asm.Asinh).apply(null,arguments)},Oy=e._Atan=function(){return(Oy=e._Atan=e.asm.Atan).apply(null,arguments)},My=e._Atan2=function(){return(My=e._Atan2=e.asm.Atan2).apply(null,arguments)},pl=e._Atanh=function(){return(pl=e._Atanh=e.asm.Atanh).apply(null,arguments)},Ly=e._AvgPool=function(){return(Ly=e._AvgPool=e.asm.AvgPool).apply(null,arguments)},By=e._AvgPool3D=function(){return(By=e._AvgPool3D=e.asm.AvgPool3D).apply(null,arguments)},zy=e._AvgPool3DGrad=function(){return(zy=e._AvgPool3DGrad=e.asm.AvgPool3DGrad).apply(null,arguments)},Ru=e._AvgPoolGrad=function(){return(Ru=e._AvgPoolGrad=e.asm.AvgPoolGrad).apply(null,arguments)},Vy=e._BatchMatMul=function(){return(Vy=e._BatchMatMul=e.asm.BatchMatMul).apply(null,arguments)},Wy=e._Bincount=function(){return(Wy=e._Bincount=e.asm.Bincount).apply(null,arguments)},Rm=e._BitwiseAnd=function(){return(Rm=e._BitwiseAnd=e.asm.BitwiseAnd).apply(null,arguments)},Uy=e._Ceil=function(){return(Uy=e._Ceil=e.asm.Ceil).apply(null,arguments)},cl=e._ClipByValue=function(){return(cl=e._ClipByValue=e.asm.ClipByValue).apply(null,arguments)},Gy=e._Conv2D=function(){return(Gy=e._Conv2D=e.asm.Conv2D).apply(null,arguments)},Hy=e._Conv2DBackpropInput=function(){return(Hy=e._Conv2DBackpropInput=e.asm.Conv2DBackpropInput).apply(null,arguments)},Ky=e._Conv3D=function(){return(Ky=e._Conv3D=e.asm.Conv3D).apply(null,arguments)},_i=e._Conv3DBackpropFilterV2=function(){return(_i=e._Conv3DBackpropFilterV2=e.asm.Conv3DBackpropFilterV2).apply(null,arguments)},ll=e._Conv3DBackpropInputV2=function(){return(ll=e._Conv3DBackpropInputV2=e.asm.Conv3DBackpropInputV2).apply(null,arguments)},qy=e._Cos=function(){return(qy=e._Cos=e.asm.Cos).apply(null,arguments)},jy=e._Cosh=function(){return(jy=e._Cosh=e.asm.Cosh).apply(null,arguments)},Xy=e._CropAndResize=function(){return(Xy=e._CropAndResize=e.asm.CropAndResize).apply(null,arguments)},Yy=e._Cumprod=function(){return(Yy=e._Cumprod=e.asm.Cumprod).apply(null,arguments)},Dm=e._Cumsum=function(){return(Dm=e._Cumsum=e.asm.Cumsum).apply(null,arguments)},Am=e._DenseBincount=function(){return(Am=e._DenseBincount=e.asm.DenseBincount).apply(null,arguments)},Qy=e._DepthToSpace=function(){return(Qy=e._DepthToSpace=e.asm.DepthToSpace).apply(null,arguments)},Zy=e._DepthwiseConv2dNative=function(){return(Zy=e._DepthwiseConv2dNative=e.asm.DepthwiseConv2dNative).apply(null,arguments)},Fm=e._Diag=function(){return(Fm=e._Diag=e.asm.Diag).apply(null,arguments)},Pm=e._Dilation2D=function(){return(Pm=e._Dilation2D=e.asm.Dilation2D).apply(null,arguments)},Jy=e._Dilation2DBackpropFilter=function(){return(Jy=e._Dilation2DBackpropFilter=e.asm.Dilation2DBackpropFilter).apply(null,arguments)},eb=e._Dilation2DBackpropInput=function(){return(eb=e._Dilation2DBackpropInput=e.asm.Dilation2DBackpropInput).apply(null,arguments)},tb=e._Elu=function(){return(tb=e._Elu=e.asm.Elu).apply(null,arguments)},rb=e._EluGrad=function(){return(rb=e._EluGrad=e.asm.EluGrad).apply(null,arguments)},Om=e._Equal=function(){return(Om=e._Equal=e.asm.Equal).apply(null,arguments)},f0=e._Erf=function(){return(f0=e._Erf=e.asm.Erf).apply(null,arguments)},ob=e._Exp=function(){return(ob=e._Exp=e.asm.Exp).apply(null,arguments)},nb=e._Expm1=function(){return(nb=e._Expm1=e.asm.Expm1).apply(null,arguments)},sb=e._FlipLeftRight=function(){return(sb=e._FlipLeftRight=e.asm.FlipLeftRight).apply(null,arguments)},ab=e._Floor=function(){return(ab=e._Floor=e.asm.Floor).apply(null,arguments)},ib=e._FloorDiv=function(){return(ib=e._FloorDiv=e.asm.FloorDiv).apply(null,arguments)},ub=e._FusedBatchNorm=function(){return(ub=e._FusedBatchNorm=e.asm.FusedBatchNorm).apply(null,arguments)},pb=e._FusedConv2D=function(){return(pb=e._FusedConv2D=e.asm.FusedConv2D).apply(null,arguments)},cb=e._FusedDepthwiseConv2D=function(){return(cb=e._FusedDepthwiseConv2D=e.asm.FusedDepthwiseConv2D).apply(null,arguments)},lb=e._Gather=function(){return(lb=e._Gather=e.asm.Gather).apply(null,arguments)},mb=e._GatherNd=function(){return(mb=e._GatherNd=e.asm.GatherNd).apply(null,arguments)},db=e._Greater=function(){return(db=e._Greater=e.asm.Greater).apply(null,arguments)},fb=e._GreaterEqual=function(){return(fb=e._GreaterEqual=e.asm.GreaterEqual).apply(null,arguments)},hb=e._IsFinite=function(){return(hb=e._IsFinite=e.asm.IsFinite).apply(null,arguments)},gb=e._IsInf=function(){return(gb=e._IsInf=e.asm.IsInf).apply(null,arguments)},xb=e._IsNan=function(){return(xb=e._IsNan=e.asm.IsNan).apply(null,arguments)},yb=e._LRN=function(){return(yb=e._LRN=e.asm.LRN).apply(null,arguments)},bb=e._LRNGrad=function(){return(bb=e._LRNGrad=e.asm.LRNGrad).apply(null,arguments)},Cb=e._LeakyRelu=function(){return(Cb=e._LeakyRelu=e.asm.LeakyRelu).apply(null,arguments)},wb=e._Less=function(){return(wb=e._Less=e.asm.Less).apply(null,arguments)},Sb=e._LessEqual=function(){return(Sb=e._LessEqual=e.asm.LessEqual).apply(null,arguments)},Ib=e._LinSpace=function(){return(Ib=e._LinSpace=e.asm.LinSpace).apply(null,arguments)},vb=e._Log=function(){return(vb=e._Log=e.asm.Log).apply(null,arguments)},kb=e._Log1p=function(){return(kb=e._Log1p=e.asm.Log1p).apply(null,arguments)},Nb=e._LogicalAnd=function(){return(Nb=e._LogicalAnd=e.asm.LogicalAnd).apply(null,arguments)},Tb=e._LogicalNot=function(){return(Tb=e._LogicalNot=e.asm.LogicalNot).apply(null,arguments)},_b=e._LogicalOr=function(){return(_b=e._LogicalOr=e.asm.LogicalOr).apply(null,arguments)},$b=e._LogicalXor=function(){return($b=e._LogicalXor=e.asm.LogicalXor).apply(null,arguments)},Eb=e._Max=function(){return(Eb=e._Max=e.asm.Max).apply(null,arguments)},Rb=e._MaxPool=function(){return(Rb=e._MaxPool=e.asm.MaxPool).apply(null,arguments)},Db=e._MaxPool3D=function(){return(Db=e._MaxPool3D=e.asm.MaxPool3D).apply(null,arguments)},Ab=e._MaxPool3DGrad=function(){return(Ab=e._MaxPool3DGrad=e.asm.MaxPool3DGrad).apply(null,arguments)},Fb=e._MaxPoolGrad=function(){return(Fb=e._MaxPoolGrad=e.asm.MaxPoolGrad).apply(null,arguments)},Pb=e._MaxPoolWithArgmax=function(){return(Pb=e._MaxPoolWithArgmax=e.asm.MaxPoolWithArgmax).apply(null,arguments)},Ob=e._Maximum=function(){return(Ob=e._Maximum=e.asm.Maximum).apply(null,arguments)},Mb=e._Mean=function(){return(Mb=e._Mean=e.asm.Mean).apply(null,arguments)},Lb=e._Min=function(){return(Lb=e._Min=e.asm.Min).apply(null,arguments)},Bb=e._Minimum=function(){return(Bb=e._Minimum=e.asm.Minimum).apply(null,arguments)},zb=e._MirrorPad=function(){return(zb=e._MirrorPad=e.asm.MirrorPad).apply(null,arguments)},Vb=e._Mod=function(){return(Vb=e._Mod=e.asm.Mod).apply(null,arguments)},Wb=e._Multinomial=function(){return(Wb=e._Multinomial=e.asm.Multinomial).apply(null,arguments)},Ub=e._Multiply=function(){return(Ub=e._Multiply=e.asm.Multiply).apply(null,arguments)},Gb=e._Neg=function(){return(Gb=e._Neg=e.asm.Neg).apply(null,arguments)},Hb=e._NonMaxSuppressionV3=function(){return(Hb=e._NonMaxSuppressionV3=e.asm.NonMaxSuppressionV3).apply(null,arguments)},Kb=e._NonMaxSuppressionV4=function(){return(Kb=e._NonMaxSuppressionV4=e.asm.NonMaxSuppressionV4).apply(null,arguments)},qb=e._NonMaxSuppressionV5=function(){return(qb=e._NonMaxSuppressionV5=e.asm.NonMaxSuppressionV5).apply(null,arguments)},jb=e._NotEqual=function(){return(jb=e._NotEqual=e.asm.NotEqual).apply(null,arguments)},Xb=e._OneHot=function(){return(Xb=e._OneHot=e.asm.OneHot).apply(null,arguments)},Yb=e._PadV2=function(){return(Yb=e._PadV2=e.asm.PadV2).apply(null,arguments)},Qb=e._Pow=function(){return(Qb=e._Pow=e.asm.Pow).apply(null,arguments)},Zb=e._Prelu=function(){return(Zb=e._Prelu=e.asm.Prelu).apply(null,arguments)},Jb=e._Prod=function(){return(Jb=e._Prod=e.asm.Prod).apply(null,arguments)},eC=e._RealDiv=function(){return(eC=e._RealDiv=e.asm.RealDiv).apply(null,arguments)},tC=e._Reciprocal=function(){return(tC=e._Reciprocal=e.asm.Reciprocal).apply(null,arguments)},rC=e._Relu=function(){return(rC=e._Relu=e.asm.Relu).apply(null,arguments)},oC=e._Relu6=function(){return(oC=e._Relu6=e.asm.Relu6).apply(null,arguments)},nC=e._ResizeBilinear=function(){return(nC=e._ResizeBilinear=e.asm.ResizeBilinear).apply(null,arguments)},sC=e._ResizeBilinearGrad=function(){return(sC=e._ResizeBilinearGrad=e.asm.ResizeBilinearGrad).apply(null,arguments)},aC=e._ResizeNearestNeighbor=function(){return(aC=e._ResizeNearestNeighbor=e.asm.ResizeNearestNeighbor).apply(null,arguments)},iC=e._ResizeNearestNeighborGrad=function(){return(iC=e._ResizeNearestNeighborGrad=e.asm.ResizeNearestNeighborGrad).apply(null,arguments)},uC=e._Reverse=function(){return(uC=e._Reverse=e.asm.Reverse).apply(null,arguments)},pC=e._RotateWithOffset=function(){return(pC=e._RotateWithOffset=e.asm.RotateWithOffset).apply(null,arguments)},cC=e._Round=function(){return(cC=e._Round=e.asm.Round).apply(null,arguments)},lC=e._Rsqrt=function(){return(lC=e._Rsqrt=e.asm.Rsqrt).apply(null,arguments)},mC=e._ScatterNd=function(){return(mC=e._ScatterNd=e.asm.ScatterNd).apply(null,arguments)},dC=e._SearchSorted=function(){return(dC=e._SearchSorted=e.asm.SearchSorted).apply(null,arguments)},fC=e._SelectV2=function(){return(fC=e._SelectV2=e.asm.SelectV2).apply(null,arguments)},hC=e._Selu=function(){return(hC=e._Selu=e.asm.Selu).apply(null,arguments)},gC=e._Sigmoid=function(){return(gC=e._Sigmoid=e.asm.Sigmoid).apply(null,arguments)},xC=e._Sign=function(){return(xC=e._Sign=e.asm.Sign).apply(null,arguments)},yC=e._Sin=function(){return(yC=e._Sin=e.asm.Sin).apply(null,arguments)},bC=e._Sinh=function(){return(bC=e._Sinh=e.asm.Sinh).apply(null,arguments)},CC=e._Softmax=function(){return(CC=e._Softmax=e.asm.Softmax).apply(null,arguments)},wC=e._Softplus=function(){return(wC=e._Softplus=e.asm.Softplus).apply(null,arguments)},SC=e._SparseFillEmptyRows=function(){return(SC=e._SparseFillEmptyRows=e.asm.SparseFillEmptyRows).apply(null,arguments)},IC=e._SparseReshape=function(){return(IC=e._SparseReshape=e.asm.SparseReshape).apply(null,arguments)},vC=e._SparseSegmentReduction=function(){return(vC=e._SparseSegmentReduction=e.asm.SparseSegmentReduction).apply(null,arguments)},kC=e._SparseToDense=function(){return(kC=e._SparseToDense=e.asm.SparseToDense).apply(null,arguments)},NC=e._Sqrt=function(){return(NC=e._Sqrt=e.asm.Sqrt).apply(null,arguments)},TC=e._Square=function(){return(TC=e._Square=e.asm.Square).apply(null,arguments)},_C=e._SquaredDifference=function(){return(_C=e._SquaredDifference=e.asm.SquaredDifference).apply(null,arguments)},$C=e._Step=function(){return($C=e._Step=e.asm.Step).apply(null,arguments)},EC=e._StridedSlice=function(){return(EC=e._StridedSlice=e.asm.StridedSlice).apply(null,arguments)},RC=e._Sub=function(){return(RC=e._Sub=e.asm.Sub).apply(null,arguments)},DC=e._Sum=function(){return(DC=e._Sum=e.asm.Sum).apply(null,arguments)},AC=e._Tan=function(){return(AC=e._Tan=e.asm.Tan).apply(null,arguments)},FC=e._Tanh=function(){return(FC=e._Tanh=e.asm.Tanh).apply(null,arguments)},PC=e._TensorScatterUpdate=function(){return(PC=e._TensorScatterUpdate=e.asm.TensorScatterUpdate).apply(null,arguments)},OC=e._Tile=function(){return(OC=e._Tile=e.asm.Tile).apply(null,arguments)},MC=e._TopK=function(){return(MC=e._TopK=e.asm.TopK).apply(null,arguments)},LC=e._Transform=function(){return(LC=e._Transform=e.asm.Transform).apply(null,arguments)},BC=e._Transpose=function(){return(BC=e._Transpose=e.asm.Transpose).apply(null,arguments)},zC=e.__FusedMatMul=function(){return(zC=e.__FusedMatMul=e.asm._FusedMatMul).apply(null,arguments)},VC=e._malloc=function(){return(VC=e._malloc=e.asm.malloc).apply(null,arguments)},WC=e._free=function(){return(WC=e._free=e.asm.free).apply(null,arguments)},UC=e.___errno_location=function(){return(UC=e.___errno_location=e.asm.__errno_location).apply(null,arguments)},Mm=e.stackSave=function(){return(Mm=e.stackSave=e.asm.stackSave).apply(null,arguments)},Lm=e.stackRestore=function(){return(Lm=e.stackRestore=e.asm.stackRestore).apply(null,arguments)},ml=e.stackAlloc=function(){return(ml=e.stackAlloc=e.asm.stackAlloc).apply(null,arguments)},GC=e.dynCall_iijjiiii=function(){return(GC=e.dynCall_iijjiiii=e.asm.dynCall_iijjiiii).apply(null,arguments)},HC=e.dynCall_jiji=function(){return(HC=e.dynCall_jiji=e.asm.dynCall_jiji).apply(null,arguments)};e.cwrap=ky;var Wp;ar=function K(){Wp||Bm(),Wp||(ar=K)};function Bm(K){if(K=K||i,_t>0||(gt(),_t>0))return;function ae(){Wp||(Wp=!0,e.calledRun=!0,!M&&(xt(),o(e),e.onRuntimeInitialized&&e.onRuntimeInitialized(),Lr()))}e.setStatus?(e.setStatus(\"Running...\"),setTimeout(function(){setTimeout(function(){e.setStatus(\"\")},1),ae()},1)):ae()}if(e.preInit)for(typeof e.preInit==\"function\"&&(e.preInit=[e.preInit]);e.preInit.length>0;)e.preInit.pop()();Bm();var Up;s&&(Up={uncaughtException:process.listeners(\"uncaughtException\").filter(function(K){return!s.uncaughtException.indexOf(K)>-1}),unhandledRejection:process.listeners(\"unhandledRejection\").filter(function(K){return!s.unhandledRejection.indexOf(K)>-1})});var Gp;if(typeof t!=\"undefined\")Gp=t;else if(typeof WasmBackendModuleThreadedSimd!=\"undefined\")Gp=WasmBackendModuleThreadedSimd;else throw new Error(\"Could not find wasm module in post.js\");if(Up){var KC=Gp._dispose;Gp._dispose=function(){KC(),Up.uncaughtException.forEach(function(K){process.removeListener(\"uncaughtException\",K)}),Up.unhandledRejection.forEach(function(K){process.removeListener(\"unhandledRejection\",K)})}}return t.ready}})();typeof Ug==\"object\"&&typeof Gv==\"object\"?Gv.exports=Uv:typeof define==\"function\"&&define.amd?define([],function(){return Uv}):typeof Ug==\"object\"&&(Ug.WasmBackendModule=Uv)});var zo=class{constructor(t,e){this.backend=t,this.dataMover=e,this.data=new WeakMap,this.dataIdsCount=0}get(t){return this.data.has(t)||this.dataMover.moveData(this.backend,t),this.data.get(t)}set(t,e){this.dataIdsCount++,this.data.set(t,e)}has(t){return this.data.has(t)}delete(t){return this.dataIdsCount--,this.data.delete(t)}numDataIds(){return this.dataIdsCount}},ao=class{refCount(t){return zr(\"refCount\")}incRef(t){return zr(\"incRef\")}timerAvailable(){return!0}time(t){return zr(\"time\")}read(t){return zr(\"read\")}readSync(t){return zr(\"readSync\")}readToGPU(t,e){return zr(\"readToGPU\")}numDataIds(){return zr(\"numDataIds\")}disposeData(t,e){return zr(\"disposeData\")}write(t,e,o){return zr(\"write\")}move(t,e,o,n,s){return zr(\"move\")}createTensorFromGPUData(t,e,o){return zr(\"createTensorFromGPUData\")}memory(){return zr(\"memory\")}floatPrecision(){return zr(\"floatPrecision\")}epsilon(){return this.floatPrecision()===32?1e-7:1e-4}dispose(){return zr(\"dispose\")}};function zr(r){throw new Error(`'${r}' not yet implemented or not found in the registry. This kernel may not be supported by the tfjs backend you have chosen`)}function I0(r){let t=r.length,e=0;for(;t>0;)e=Math.random()*t|0,t--,jm(r,t,e)}function TG(r,t){if(r.length!==t.length)throw new Error(`Array sizes must match to be shuffled together First array length was ${r.length}Second array length was ${t.length}`);let e=r.length,o=0;for(;e>0;)o=Math.random()*e|0,e--,jm(r,e,o),jm(t,e,o)}function qp(r,t,e){return Math.max(r,Math.min(t,e))}function _G(r){return r%2===0?r:r+1}function jm(r,t,e){let o=r[t];r[t]=r[e],r[e]=o}function $G(r){let t=0;for(let e=0;ee+` Shapes ${r} and ${t} must match`)}function io(r){$(r!=null,()=>\"The input to the tensor constructor must be a non-null value.\")}function He(r){if(r.length===0)return 1;let t=r[0];for(let e=1;e0,e,o){return new Promise((n,s)=>{let a=0,i=()=>{if(r()){n();return}a++;let p=t(a);if(e!=null&&a>=e){s();return}o!=null?o(i,p):setTimeout(i,p)};i()})}function MG(r,t){let e=1,o=-1;for(let s=0;s=0)e*=r[s];else if(r[s]===-1){if(o!==-1)throw Error(`Shapes can only have 1 implicit size. Found -1 at dim ${o} and dim ${s}`);o=s}else if(r[s]<0)throw Error(`Shapes can not be < 0. Found ${r[s]} at dim ${s}`);if(o===-1){if(t>0&&t!==e)throw Error(`Size(${t}) must match the product of shape ${r}`);return r}if(e===0)throw Error(`Cannot infer the missing size in [${r}] when there are 0 elements`);if(t%e!==0)throw Error(`The implicit shape can't be a fractional number. Got ${t} / ${e}`);let n=r.slice();return n[o]=t/e,n}function Ei(r,t){let e=t.length;return r=r==null?t.map((o,n)=>n):[].concat(r),$(r.every(o=>o>=-e&&o`All values in axis param must be in range [-${e}, ${e}) but got axis ${r}`),$(r.every(o=>qa(o)),()=>`All values in axis param must be integers but got axis ${r}`),r.map(o=>o<0?e+o:o)}function JC(r,t){let e=[],o=[],n=t!=null&&Array.isArray(t)&&t.length===0,s=t==null||n?null:Ei(t,r).sort(),a=0;for(let i=0;ii)&&r[i]===1&&(e.push(r[i]),o.push(i)),s[a]<=i&&a++}r[i]!==1&&(e.push(r[i]),o.push(i))}return{newShape:e,keptDims:o}}function ew(r,t){return Xm(r,t)}function Xm(r,t){let e=null;if(r==null||r===\"float32\")e=new Float32Array(t);else if(r===\"int32\")e=new Int32Array(t);else if(r===\"bool\")e=new Uint8Array(t);else if(r===\"string\")e=new Array(t);else throw new Error(`Unknown data type ${r}`);return e}function tw(r,t){for(let e=0;et+=e.length),t}function Vo(r){return typeof r==\"string\"||r instanceof String}function v0(r){return typeof r==\"boolean\"}function k0(r){return typeof r==\"number\"}function Ri(r){return Array.isArray(r)?Ri(r[0]):r instanceof Float32Array?\"float32\":r instanceof Int32Array||r instanceof Uint8Array||r instanceof Uint8ClampedArray?\"int32\":k0(r)?\"float32\":Vo(r)?\"string\":v0(r)?\"bool\":\"float32\"}function qs(r){return!!(r&&r.constructor&&r.call&&r.apply)}function Xp(r,t){for(let e=t;e=0;--o)e[o]=e[o+1]*r[o+1];return e}function N0(r,t,e,o=!1){let n=new Array;if(t.length===1){let s=t[0]*(o?2:1);for(let a=0;ap*u)*(o?2:1);for(let p=0;pn*s)*(e?2:1);if(o===0)return[];if(o!==t.length)throw new Error(`[${r}] does not match the input size ${t.length}${e?\" for a complex tensor\":\"\"}.`);return N0(0,r,t,e)}function BG(r,t){if(Array.isArray(r))return r;if(t===\"float32\")return r instanceof Float32Array?r:new Float32Array(r);if(t===\"int32\")return r instanceof Int32Array?r:new Int32Array(r);if(t===\"bool\"||t===\"string\")return Uint8Array.from(new Int32Array(r));throw new Error(`Unknown dtype ${t}`)}function fl(r,t){let e=Yp(r,t);for(let o=0;oo*n,1);if(t==null||t===\"float32\")return Du(r,new Float32Array(e));if(t===\"int32\")return Du(r,new Int32Array(e));if(t===\"bool\")return Du(r,new Uint8Array(e));throw new Error(`Unknown data type ${t}`)}function wt(r){r.forEach(t=>{$(Number.isInteger(t)&&t>=0,()=>`Tensor must have a shape comprised of positive integers but got shape [${r}].`)})}function VG(r,t,e){if(t===0)return 0;if(t===1)return r[0];let o=r[r.length-1];for(let n=0;n{let[n,s]=o.split(\":\");this.urlFlags[n]=KG(n,s)})}};function GG(r){let t={};return r.replace(/[?&]([^=?&]+)(?:=([^&]*))?/g,(e,...o)=>(HG(t,o[0],o[1]),o.join(\"=\"))),t}function HG(r,t,e){r[decodeURIComponent(t)]=decodeURIComponent(e||\"\")}function KG(r,t){let e=t.toLowerCase();return e===\"true\"||e===\"false\"?e===\"true\":`${+e}`===e?+e:t}function A(){return nw}var nw=null;function _0(r){nw=r}var sw;function aw(){if(sw==null){let r;if(typeof window!=\"undefined\")r=window;else if(typeof global!=\"undefined\")r=global;else if(typeof process!=\"undefined\")r=process;else if(typeof self!=\"undefined\")r=self;else throw new Error(\"Could not find a global object\");sw=r}return sw}function qG(){let r=aw();return r._tfGlobals==null&&(r._tfGlobals=new Map),r._tfGlobals}function gl(r,t){let e=qG();if(e.has(r))return e.get(r);{let o=t();return e.set(r,o),e.get(r)}}var Xs=\"Abs\",Wo=\"Acos\",Uo=\"Acosh\",uo=\"Add\",Go=\"AddN\",Ho=\"All\",Ko=\"Any\",Ys=\"ArgMax\",Qs=\"ArgMin\",qo=\"Asin\",jo=\"Asinh\",Xo=\"Atan\",Yo=\"Atanh\",Qo=\"Atan2\",Zo=\"AvgPool\",Di=\"AvgPoolGrad\",Zs=\"AvgPool3D\",Ai=\"AvgPool3DGrad\",Jo=\"BatchMatMul\",Js=\"BatchToSpaceND\",en=\"Bincount\",ja=\"BitwiseAnd\",Bce=\"BroadcastTo\",ea=\"BroadcastArgs\",bo=\"Cast\",tn=\"Ceil\",Co=\"ClipByValue\",Fi=\"Complex\",Pi=\"ComplexAbs\",ta=\"Concat\",rn=\"Conv2D\",Oi=\"Conv2DBackpropFilter\",on=\"Conv2DBackpropInput\",nn=\"Conv3D\",Xa=\"Conv3DBackpropFilterV2\",sn=\"Conv3DBackpropInputV2\",an=\"Cos\",un=\"Cosh\",pn=\"Cumprod\",cn=\"Cumsum\",ln=\"CropAndResize\",ra=\"DenseBincount\",mn=\"DepthToSpace\",dn=\"DepthwiseConv2dNative\",Mi=\"DepthwiseConv2dNativeBackpropFilter\",Li=\"DepthwiseConv2dNativeBackpropInput\",oa=\"Diag\",fn=\"Dilation2D\",Bi=\"Dilation2DBackpropInput\",zi=\"Dilation2DBackpropFilter\",Pu=\"Draw\",hn=\"RealDiv\",Vi=\"Einsum\",gn=\"Elu\",Ya=\"EluGrad\",xn=\"Erf\",yn=\"Equal\",bn=\"Exp\",na=\"ExpandDims\",Cn=\"Expm1\",Wi=\"FFT\",sa=\"Fill\",wn=\"FlipLeftRight\",Sn=\"Floor\",In=\"FloorDiv\",vn=\"FusedBatchNorm\",aa=\"GatherV2\",kn=\"GatherNd\",Nn=\"Greater\",Tn=\"GreaterEqual\",wo=\"Identity\",Ui=\"IFFT\",Gi=\"Imag\",_n=\"IsFinite\",$n=\"IsInf\",En=\"IsNan\",Rn=\"LeakyRelu\",Dn=\"Less\",An=\"LessEqual\",Fn=\"LinSpace\",Pn=\"Log\",On=\"Log1p\",Mn=\"LogicalAnd\",Ln=\"LogicalNot\",Bn=\"LogicalOr\",$0=\"LogicalXor\",zce=\"LogSoftmax\",Vce=\"LowerBound\",zn=\"LRN\",Qa=\"LRNGrad\",Wce=\"MatrixBandPart\",Vn=\"Max\",Wn=\"Maximum\",Un=\"MaxPool\",Hi=\"MaxPoolGrad\",ia=\"MaxPool3D\",Ki=\"MaxPool3DGrad\",ua=\"MaxPoolWithArgmax\",Gn=\"Mean\",Hn=\"Min\",Kn=\"Minimum\",qn=\"MirrorPad\",jn=\"Mod\",Xn=\"Multinomial\",Yn=\"Multiply\",pa=\"Neg\",Qn=\"NotEqual\",Zn=\"NonMaxSuppressionV3\",Za=\"NonMaxSuppressionV4\",Jn=\"NonMaxSuppressionV5\",ca=\"OnesLike\",es=\"OneHot\",la=\"Pack\",ts=\"PadV2\",Uce=\"Pool\",rs=\"Pow\",os=\"Prelu\",ns=\"Prod\",Qp=\"RaggedGather\",Zp=\"RaggedRange\",Jp=\"RaggedTensorToTensor\",ma=\"Range\",qi=\"Real\",ss=\"Reciprocal\",as=\"Relu\",da=\"Reshape\",is=\"ResizeNearestNeighbor\",Ja=\"ResizeNearestNeighborGrad\",us=\"ResizeBilinear\",ei=\"ResizeBilinearGrad\",ps=\"Relu6\",cs=\"Reverse\",ls=\"Round\",ms=\"Rsqrt\",ds=\"ScatterNd\",fs=\"TensorScatterUpdate\",hs=\"SearchSorted\",fa=\"Select\",gs=\"Selu\",ha=\"Slice\",xs=\"Sin\",ys=\"Sinh\",bs=\"Sign\",Cs=\"Sigmoid\",ws=\"Softplus\",Ss=\"Sqrt\",Is=\"Sum\",ga=\"SpaceToBatchND\",xa=\"SplitV\",vs=\"Softmax\",ji=\"SparseFillEmptyRows\",ti=\"SparseReshape\",ya=\"SparseSegmentMean\",ba=\"SparseSegmentSum\",ks=\"SparseToDense\",Ns=\"SquaredDifference\",Xi=\"Square\",Ou=\"StaticRegexReplace\",Ts=\"StridedSlice\",Ca=\"StringNGrams\",Yi=\"StringSplit\",Qi=\"StringToHashBucketFast\",_s=\"Sub\",$s=\"Tan\",Es=\"Tanh\",po=\"Tile\",Rs=\"TopK\",Ds=\"Transform\",co=\"Transpose\",Zi=\"Unique\",wa=\"Unpack\",Ji=\"UnsortedSegmentSum\",Gce=\"UpperBound\",Sa=\"ZerosLike\",So=\"Step\",Mu=\"FromPixels\",As=\"RotateWithOffset\",Io=\"_FusedMatMul\",vo=\"FusedConv2D\",ko=\"FusedDepthwiseConv2D\";function Ia(...r){A().getBool(\"IS_TEST\")||A().getBool(\"PROD\")||console.warn(...r)}function jG(...r){A().getBool(\"IS_TEST\")||A().getBool(\"PROD\")||console.log(...r)}var ec=gl(\"kernelRegistry\",()=>new Map),xl=gl(\"gradRegistry\",()=>new Map);function tc(r,t){let e=uw(r,t);return ec.get(e)}function iw(r){return xl.get(r)}function Ym(r){let t=ec.entries(),e=[];for(;;){let{done:o,value:n}=t.next();if(o)break;let[s,a]=n,[i]=s.split(\"_\");i===r&&e.push(a)}return e}function ri(r){let{kernelName:t,backendName:e}=r,o=uw(t,e);ec.has(o)&&Ia(`The kernel '${t}' for backend '${e}' is already registered`),ec.set(o,r)}function Xce(r){let{kernelName:t}=r;xl.has(t)&&A().getBool(\"DEBUG\")&&Ia(`Overriding the gradient for '${t}'`),xl.set(t,r)}function Yce(r,t){let e=uw(r,t);if(!ec.has(e))throw new Error(`The kernel '${r}' for backend '${t}' is not registered`);ec.delete(e)}function Qce(r){if(!xl.has(r))throw new Error(`The gradient '${r}' for backend is not registered`);xl.delete(r)}function Zce(r,t){Ym(r).forEach(o=>{let n=Object.assign({},o,{backendName:t});ri(n)})}function uw(r,t){return`${t}_${r}`}var y={};qe(y,{arraysEqual:()=>Cr,arraysEqualWithNull:()=>ZC,assert:()=>$,assertNonNegativeIntegerDimensions:()=>wt,assertNonNull:()=>io,assertShapesMatch:()=>yt,bytesFromStringArray:()=>ow,bytesPerElement:()=>jp,checkConversionForErrors:()=>tw,clamp:()=>qp,computeStrides:()=>js,convertBackendValuesAndArrayBuffer:()=>BG,createScalarValue:()=>t4,createShuffledIndices:()=>PG,decodeString:()=>sc,distSquared:()=>RG,encodeString:()=>tu,fetch:()=>o4,fingerPrint64:()=>e4,flatten:()=>Ps,getArrayFromDType:()=>Xm,getTypedArrayFromDType:()=>ew,hasEncodingLoss:()=>LG,hexToLong:()=>yl,indexToLoc:()=>WG,inferDtype:()=>Ri,inferFromImplicitShape:()=>MG,isBoolean:()=>v0,isFunction:()=>qs,isInt:()=>qa,isNumber:()=>k0,isPromise:()=>Fu,isScalarShape:()=>DG,isString:()=>Vo,isTypedArray:()=>Ot,isValidDtype:()=>rw,locToIndex:()=>VG,makeOnesTypedArray:()=>fl,makeZerosNestedTypedArray:()=>zG,makeZerosTypedArray:()=>Yp,nearestDivisor:()=>Xp,nearestLargerEven:()=>_G,now:()=>Wu,parseAxisParam:()=>Ei,randUniform:()=>EG,repeatedTry:()=>OG,rightPad:()=>Au,shuffle:()=>I0,shuffleCombo:()=>TG,sizeFromShape:()=>He,sizeToSquarishShape:()=>FG,squeezeShape:()=>JC,sum:()=>$G,swap:()=>jm,tanh:()=>AG,toNestedArray:()=>Du,toTypedArray:()=>nc});function Qm(r){return r instanceof Float32Array||r instanceof Int32Array||r instanceof Uint8Array||r instanceof Uint8ClampedArray}var mw=Kp(V0());var Vu=mw.default||mw;function yl(r){return Vu.fromString(r,!0,16)}var U0=yl(\"c3a5c85c97cb3127\"),zu=yl(\"b492b66fbe98f273\"),wr=yl(\"9ae16a3b2f90404f\");function lw(r){return r.xor(r.shru(47))}function G0(r,t,e){let o=r.slice(t,t+e);return Vu.fromBytes(Array.from(o),!0,!0)}function St(r,t){return G0(r,t,8)}function W0(r,t){return G0(r,t,4)}function Qt(r,t){return t===0?r:r.shru(t).or(r.shl(64-t))}function eu(r,t,e=yl(\"9ddfea08eb382d69\")){let o=r.xor(t).mul(e);o=o.xor(o.shru(47));let n=t.xor(o).mul(e);return n=n.xor(n.shru(47)),n=n.mul(e),n}function YG(r,t,e,o,n,s){n=n.add(r),s=Qt(s.add(n).add(o),21);let a=n;return n=n.add(t),n=n.add(e),s=s.add(Qt(n,44)),[n.add(o),s.add(a)]}function Jm(r,t,e,o){return YG(St(r,t),St(r,t+8),St(r,t+16),St(r,t+24),e,o)}function QG(r,t=r.length){if(t>=8){let e=wr.add(t*2),o=St(r,0).add(wr),n=St(r,t-8),s=Qt(n,37).mul(e).add(o),a=Qt(o,25).add(n).mul(e);return eu(s,a,e)}if(t>=4){let e=wr.add(t*2),o=W0(r,0);return eu(o.shl(3).add(t),W0(r,t-4),e)}if(t>0){let e=r[0],o=r[t>>1],n=r[t-1],s=e+(o<<8),a=t+(n<<2);return lw(wr.mul(s).xor(U0.mul(a))).mul(wr)}return wr}function ZG(r,t=r.length){let e=wr.add(t*2),o=St(r,0).mul(zu),n=St(r,8),s=St(r,t-8).mul(e),a=St(r,t-16).mul(wr);return eu(Qt(o.add(n),43).add(Qt(s,30)).add(a),o.add(Qt(n.add(wr),18)).add(s),e)}function JG(r,t=r.length){let e=wr.add(t*2),o=St(r,0).mul(wr),n=St(r,8),s=St(r,t-8).mul(e),a=St(r,t-16).mul(wr),i=Qt(o.add(n),43).add(Qt(s,30)).add(a),p=eu(i,o.add(Qt(n.add(wr),18)).add(s),e),u=St(r,16).mul(e),c=St(r,24),l=i.add(St(r,t-32)).mul(e),m=p.add(St(r,t-24)).mul(e);return eu(Qt(u.add(c),43).add(Qt(l,30)).add(m),u.add(Qt(c.add(o),18)).add(l),e)}function e4(r,t=r.length){let e=Vu.fromNumber(81,!0);if(t<=32)return t<=16?QG(r,t):ZG(r,t);if(t<=64)return JG(r,t);let o=e,n=e.mul(zu).add(113),s=lw(n.mul(wr).add(113)).mul(wr),a=[Vu.UZERO,Vu.UZERO],i=[Vu.UZERO,Vu.UZERO];o=o.mul(wr).add(St(r,0));let p=0,u=(t-1>>6)*64,c=u+(t-1&63)-63;do o=Qt(o.add(n).add(a[0]).add(St(r,p+8)),37).mul(zu),n=Qt(n.add(a[1]).add(St(r,p+48)),42).mul(zu),o=o.xor(i[1]),n=n.add(a[0]).add(St(r,p+40)),s=Qt(s.add(i[0]),33).mul(zu),a=Jm(r,p,a[1].mul(zu),o.add(i[0])),i=Jm(r,p+32,s.add(i[1]),n.add(St(r,p+16))),[s,o]=[o,s],p+=64;while(p!==u);let l=zu.add(s.and(255).shl(1));return p=c,i[0]=i[0].add(t-1&63),a[0]=a[0].add(i[0]),i[0]=i[0].add(a[0]),o=Qt(o.add(n).add(a[0]).add(St(r,p+8)),37).mul(l),n=Qt(n.add(a[1]).add(St(r,p+48)),42).mul(l),o=o.xor(i[1].mul(9)),n=n.add(a[0].mul(9).add(St(r,p+40))),s=Qt(s.add(i[0]),33).mul(l),a=Jm(r,p,a[1].mul(l),o.add(i[0])),i=Jm(r,p+32,s.add(i[1]),n.add(St(r,p+16))),[s,o]=[o,s],eu(eu(a[0],i[0],l).add(lw(n).mul(U0)).add(s),eu(a[1],i[1],l).add(o),l)}function t4(r,t){return t===\"string\"?tu(r):nc([r],t)}function r4(r,t){return r instanceof Float32Array&&t===\"float32\"||r instanceof Int32Array&&t===\"int32\"||r instanceof Uint8Array&&t===\"bool\"}function nc(r,t){if(t===\"string\")throw new Error(\"Cannot convert a string[] to a TypedArray\");if(Array.isArray(r)&&(r=Ps(r)),A().getBool(\"DEBUG\")&&tw(r,t),r4(r,t))return r;if(t==null||t===\"float32\"||t===\"complex64\")return new Float32Array(r);if(t===\"int32\")return new Int32Array(r);if(t===\"bool\"){let e=new Uint8Array(r.length);for(let o=0;o{n=o()},a,i=Wu();if(this.backendTimer.timerAvailable())a=this.backendTimer.time(s);else{s();for(let u of n)u.dataSync();a=Promise.resolve({kernelMs:Wu()-i})}if(A().getBool(\"CHECK_COMPUTATION_FOR_ERRORS\"))for(let u=0;u{n4(l,c.dtype,t)})}return{kernelName:t,outputs:n,inputs:e,timeMs:a.then(u=>u.kernelMs),extraInfo:a.then(u=>u.getExtraProfileInfo!=null?u.getExtraProfileInfo():\"\")}}logKernelProfile(t){let{kernelName:e,outputs:o,timeMs:n,inputs:s,extraInfo:a}=t;o.forEach(i=>{Promise.all([i.data(),n,a]).then(p=>{this.logger.logKernelProfile(e,i,p[0],p[1],s,p[2])})})}};function n4(r,t,e){if(t!==\"float32\")return!1;for(let o=0;o0?h:\"\"} `}}console.log(`%c${p}\t%c${i}\t%c${u}D ${l}\t%c${c}\t%c${m}\t%c${a}`,\"font-weight:bold\",\"color:red\",\"color:blue\",\"color: orange\",\"color: green\",\"color: steelblue\")}};function H0(r,t,e){let o={},n={};for(let p=0;po[h.id]=!0),d=!0,n[u.id]=!0;break}if(d)break}}let s={};s[e.id]=!0;let a={};for(let p=r.length-1;p>=0;p--){let u=r[p],c=u.inputs;for(let l=0;l=0;n--){let s=t[n],a=[];if(s.outputs.forEach(p=>{let u=r[p.id];u!=null?a.push(u):a.push(null)}),s.gradient==null)throw new Error(`Cannot compute gradient: gradient function not found for ${s.kernelName}.`);let i=s.gradient(a);for(let p in s.inputs){if(!(p in i))throw new Error(`Cannot backprop through input ${p}. Available gradients found: ${Object.keys(i)}.`);let u=e(()=>i[p]());if(u.dtype!==\"float32\")throw new Error(`Error in gradient for op ${s.kernelName}. The gradient of input ${p} must have 'float32' dtype, but has '${u.dtype}'`);let c=s.inputs[p];if(!Cr(u.shape,c.shape))throw new Error(`Error in gradient for op ${s.kernelName}. The gradient of input '${p}' has shape '${u.shape}', which does not match the shape of the input '${c.shape}'`);if(r[c.id]==null)r[c.id]=u;else{let l=r[c.id];r[c.id]=o(l,u),l.dispose()}}}}var q0=20,bl=3,fw=7;function j0(r,t,e,o){let n=js(t),s=s4(r,t,e,n),a=t.length,i=td(r,t,e,n,s),p=[\"Tensor\"];return o&&(p.push(` dtype: ${e}`),p.push(` rank: ${a}`),p.push(` shape: [${t}]`),p.push(\" values:\")),p.push(i.map(u=>\" \"+u).join(`\n`)),p.join(`\n`)}function s4(r,t,e,o){let n=He(t),s=o[o.length-1],a=new Array(s).fill(0),i=t.length,p=e===\"complex64\"?wl(r):r;if(i>1)for(let u=0;uq0){let g=bl*a,x=Array.from(r.slice(0,g)),b=Array.from(r.slice((i-bl)*a,i*a));return e===\"complex64\"&&(x=wl(x),b=wl(b)),[\"[\"+x.map((C,S)=>Cl(C,n[S],e)).join(\", \")+\", ..., \"+b.map((C,S)=>Cl(C,n[i-bl+S],e)).join(\", \")+\"]\"]}return[\"[\"+(e===\"complex64\"?wl(r):Array.from(r)).map((g,x)=>Cl(g,n[x],e)).join(\", \")+\"]\"]}let u=t.slice(1),c=o.slice(1),l=o[0]*a,m=[];if(i>q0){for(let h=0;h0?m[0]+d:\"\");for(let h=1;h`Length of values '${n}' does not match the size inferred by the shape '${this.size}'.`)}if(e===\"complex64\")throw new Error(\"complex64 dtype TensorBuffers are not supported. Please create a TensorBuffer for the real and imaginary parts separately and call tf.complex(real, imag).\");this.values=o||Xm(e,this.size),this.strides=js(t)}set(t,...e){e.length===0&&(e=[0]),$(e.length===this.rank,()=>`The number of provided coordinates (${e.length}) must match the rank (${this.rank})`);let o=this.locToIndex(e);this.values[o]=t}get(...t){t.length===0&&(t=[0]);let e=0;for(let n of t){if(n<0||n>=this.shape[e]){let s=`Requested out of range element at ${t}. Buffer shape=${this.shape}`;throw new Error(s)}e++}let o=t[t.length-1];for(let n=0;nsc(o))}catch(o){throw new Error(\"Failed to decode the string bytes into utf-8. To get the original bytes, call tensor.bytes().\")}}return t}dataToGPU(t){return this.throwIfDisposed(),Os().readToGPU(this.dataId,t)}dataSync(){this.throwIfDisposed();let t=Os().readSync(this.dataId);if(this.dtype===\"string\")try{return t.map(e=>sc(e))}catch(e){throw new Error(\"Failed to decode the string bytes into utf-8. To get the original bytes, call tensor.bytes().\")}return t}async bytes(){this.throwIfDisposed();let t=await Os().read(this.dataId);return this.dtype===\"string\"?t:new Uint8Array(t.buffer)}dispose(){this.isDisposed||(this.kerasMask&&this.kerasMask.dispose(),Os().disposeTensor(this),this.isDisposedInternal=!0)}get isDisposed(){return this.isDisposedInternal}throwIfDisposed(){if(this.isDisposed)throw new Error(\"Tensor is disposed.\")}print(t=!1){return ac.print(this,t)}clone(){return this.throwIfDisposed(),ac.clone(this)}toString(t=!1){let e=this.dataSync();return j0(e,this.shape,this.dtype,t)}cast(t){return this.throwIfDisposed(),ac.cast(this,t)}variable(t=!0,e,o){return this.throwIfDisposed(),Os().makeVariable(this,t,e,o)}};Object.defineProperty(ut,Symbol.hasInstance,{value:r=>!!r&&r.data!=null&&r.dataSync!=null&&r.throwIfDisposed!=null});function i4(){return gl(\"Tensor\",()=>ut)}i4();var oi=class extends ut{constructor(t,e,o,n){super(t.shape,t.dtype,t.dataId,n),this.trainable=e,this.name=o}assign(t){if(t.dtype!==this.dtype)throw new Error(`dtype of the new value (${t.dtype}) and previous value (${this.dtype}) must match`);if(!Cr(t.shape,this.shape))throw new Error(`shape of the new value (${t.shape}) and previous value (${this.shape}) must match`);Os().disposeTensor(this),this.dataId=t.dataId,Os().incRef(this,null)}dispose(){Os().disposeVariable(this),this.isDisposedInternal=!0}};Object.defineProperty(oi,Symbol.hasInstance,{value:r=>r instanceof ut&&r.assign!=null&&r.assign instanceof Function});var ek={};qe(ek,{assertTypesMatch:()=>Cw,getTensorsInContainer:()=>Sl,isTensorInList:()=>p4,makeTypesMatch:()=>Oe});var hw;(function(r){r.R0=\"R0\",r.R1=\"R1\",r.R2=\"R2\",r.R3=\"R3\",r.R4=\"R4\",r.R5=\"R5\",r.R6=\"R6\"})(hw||(hw={}));var gw;(function(r){r.float32=\"float32\",r.int32=\"int32\",r.bool=\"int32\",r.complex64=\"complex64\"})(gw||(gw={}));var xw;(function(r){r.float32=\"float32\",r.int32=\"int32\",r.bool=\"bool\",r.complex64=\"complex64\"})(xw||(xw={}));var yw;(function(r){r.float32=\"float32\",r.int32=\"float32\",r.bool=\"float32\",r.complex64=\"complex64\"})(yw||(yw={}));var bw;(function(r){r.float32=\"complex64\",r.int32=\"complex64\",r.bool=\"complex64\",r.complex64=\"complex64\"})(bw||(bw={}));var u4={float32:yw,int32:gw,bool:xw,complex64:bw};function dt(r,t){if(r===\"string\"||t===\"string\"){if(r===\"string\"&&t===\"string\")return\"string\";throw new Error(`Can not upcast ${r} with ${t}`)}return u4[r][t]}function ni(r){return dt(r,\"int32\")}function rd(r){return r!=null&&typeof r==\"object\"&&\"texture\"in r&&r.texture instanceof WebGLTexture}function od(r){return typeof GPUBuffer!=\"undefined\"&&r!=null&&typeof r==\"object\"&&\"buffer\"in r&&r.buffer instanceof GPUBuffer}function Oe(r,t){if(r.dtype===t.dtype)return[r,t];let e=dt(r.dtype,t.dtype);return[r.cast(e),t.cast(e)]}function Cw(r,t){$(r.dtype===t.dtype,()=>`The dtypes of the first(${r.dtype}) and second(${t.dtype}) input must match`)}function p4(r,t){return t.some(e=>e.id===r.id)}function Sl(r){let t=[];return J0(r,t,new Set),t}function J0(r,t,e){if(r==null)return;if(r instanceof ut){t.push(r);return}if(!c4(r))return;let o=r;for(let n in o){let s=o[n];e.has(s)||(e.add(s),J0(s,t,e))}}function c4(r){return Array.isArray(r)||typeof r==\"object\"}function ww(r){return r.kernelName!=null}var nd=class{constructor(){this.registeredVariables={},this.nextTapeNodeId=0,this.numBytes=0,this.numTensors=0,this.numStringTensors=0,this.numDataBuffers=0,this.gradientDepth=0,this.kernelDepth=0,this.scopeStack=[],this.numDataMovesStack=[],this.nextScopeId=0,this.tensorInfo=new WeakMap,this.profiling=!1,this.activeProfile={newBytes:0,newTensors:0,peakBytes:0,kernels:[],result:null,get kernelNames(){return Array.from(new Set(this.kernels.map(t=>t.name)))}}}dispose(){for(let t in this.registeredVariables)this.registeredVariables[t].dispose()}},ru=class{constructor(t){this.ENV=t,this.registry={},this.registryFactory={},this.pendingBackendInitId=0,this.state=new nd}async ready(){if(this.pendingBackendInit!=null)return this.pendingBackendInit.then(()=>{});if(this.backendInstance!=null)return;let t=this.getSortedBackends();for(let e=0;e{e.setupFunc!=null&&e.setupFunc(this.backendInstance)})}disposeRegisteredKernels(t){Ym(t).forEach(o=>{o.disposeFunc!=null&&o.disposeFunc(this.registry[t])})}initializeBackend(t){let e=this.registryFactory[t];if(e==null)throw new Error(`Cannot initialize backend ${t}, no registration found.`);try{let o=e.factory();if(o&&!(o instanceof ao)&&typeof o.then==\"function\"){let n=++this.pendingBackendInitId,s=o.then(a=>n(nthis.registryFactory[e].priority-this.registryFactory[t].priority)}initializeBackendsAndReturnBest(){let t=this.getSortedBackends();for(let e=0;ethis.startScope(o),()=>this.endScope(n),()=>(n=e(),n instanceof Promise&&console.error(\"Cannot return a Promise inside of tidy.\"),n))}scopedRun(t,e,o){t();try{let n=o();return e(),n}catch(n){throw e(),n}}nextTensorId(){return ru.nextTensorId++}nextVariableId(){return ru.nextVariableId++}clone(t){let e=T.runKernel(wo,{x:t}),o={x:t},n=a=>({x:()=>{let i=\"float32\",p={x:a},u={dtype:i};return T.runKernel(bo,p,u)}}),s=[];return this.addTapeNode(this.state.activeScope.name,o,[e],n,s,{}),e}runKernel(t,e,o){if(this.backendName==null&&this.backend,!(tc(t,this.backendName)!=null))throw new Error(`Kernel '${t}' not registered for backend '${this.backendName}'`);return this.runKernelFunc({kernelName:t,inputs:e,attrs:o})}shouldCheckForMemLeaks(){return this.ENV.getBool(\"IS_TEST\")}checkKernelForMemLeak(t,e,o){let n=this.backend.numDataIds(),s=0;o.forEach(p=>{s+=p.dtype===\"complex64\"?3:1});let a=this.state.numDataMovesStack[this.state.numDataMovesStack.length-1],i=n-e-s-a;if(i>0)throw new Error(`Backend '${this.backendName}' has an internal memory leak (${i} data ids) after running '${t}'`)}runKernelFunc(t){let e,o=[],n=this.isTapeOn(),s=this.state.numBytes,a=this.state.numTensors;this.shouldCheckForMemLeaks()&&this.state.numDataMovesStack.push(0);let i;this.backendName==null&&this.backend;let p,u=ww(t)?t.kernelName:this.state.activeScope!=null?this.state.activeScope.name:\"\";if(ww(t)){let{kernelName:f,inputs:h,attrs:g}=t;this.backendName==null&&this.backend;let x=tc(f,this.backendName);$(x!=null,()=>`Cannot find registered kernel '${f}' for backend '${this.backendName}'`),i=()=>{let b=this.backend.numDataIds();p=x.kernelFunc({inputs:h,attrs:g,backend:this.backend});let C=Array.isArray(p)?p:[p];this.shouldCheckForMemLeaks()&&this.checkKernelForMemLeak(f,b,C);let S=C.map(k=>k.rank!=null?k:this.makeTensorFromTensorInfo(k));if(n){let k=this.getTensorsForGradient(f,h,S);o=this.saveTensorsForBackwardMode(k)}return S}}else{let{forwardFunc:f}=t,h=g=>{n&&(o=g.map(x=>this.keep(this.clone(x))))};i=()=>{let g=this.backend.numDataIds();p=this.tidy(()=>f(this.backend,h));let x=Array.isArray(p)?p:[p];return this.shouldCheckForMemLeaks()&&this.checkKernelForMemLeak(u,g,x),x}}let{inputs:c,attrs:l}=t,m=ww(t)?null:t.backwardsFunc,d;return this.scopedRun(()=>this.state.kernelDepth++,()=>this.state.kernelDepth--,()=>{!this.ENV.getBool(\"DEBUG\")&&!this.state.profiling?e=i():(d=this.profiler.profileKernel(u,c,()=>i()),this.ENV.getBool(\"DEBUG\")&&this.profiler.logKernelProfile(d),e=d.outputs)}),n&&this.addTapeNode(u,c,e,m,o,l),this.state.profiling&&this.state.activeProfile.kernels.push({name:u,bytesAdded:this.state.numBytes-s,totalBytesSnapshot:this.state.numBytes,tensorsAdded:this.state.numTensors-a,totalTensorsSnapshot:this.state.numTensors,inputShapes:Object.keys(c).map(f=>c[f]!=null?c[f].shape:null),outputShapes:e.map(f=>f.shape),kernelTimeMs:d.timeMs,extraInfo:d.extraInfo}),Array.isArray(p)?e:e[0]}saveTensorsForBackwardMode(t){return t.map(o=>this.keep(this.clone(o)))}getTensorsForGradient(t,e,o){let n=iw(t);if(n!=null){let s=n.inputsToSave||[],a=n.outputsToSave||[],i;n.saveAllInputs?($(Array.isArray(e),()=>\"saveAllInputs is true, expected inputs to be an array.\"),i=Object.keys(e).map(u=>e[u])):i=s.map(u=>e[u]);let p=o.filter((u,c)=>a[c]);return i.concat(p)}return[]}makeTensor(t,e,o,n){if(t==null)throw new Error(\"Values passed to engine.makeTensor() are null\");o=o||\"float32\",n=n||this.backend;let s=t;o===\"string\"&&Vo(t[0])&&(s=t.map(p=>tu(p)));let a=n.write(s,e,o),i=new ut(e,o,a,this.nextTensorId());if(this.trackTensor(i,n),o===\"string\"){let p=this.state.tensorInfo.get(a),u=ow(s);this.state.numBytes+=u-p.bytes,p.bytes=u}return i}makeTensorFromDataId(t,e,o,n){o=o||\"float32\";let s={dataId:t,shape:e,dtype:o};return this.makeTensorFromTensorInfo(s,n)}makeTensorFromTensorInfo(t,e){let{dataId:o,shape:n,dtype:s}=t,a=new ut(n,s,o,this.nextTensorId());return this.trackTensor(a,e),a}makeVariable(t,e=!0,o,n){o=o||this.nextVariableId().toString(),n!=null&&n!==t.dtype&&(t=t.cast(n));let s=new oi(t,e,o,this.nextTensorId());if(this.state.registeredVariables[s.name]!=null)throw new Error(`Variable with name ${s.name} was already registered`);return this.state.registeredVariables[s.name]=s,this.incRef(s,this.backend),s}trackTensor(t,e){this.state.numTensors++,t.dtype===\"string\"&&this.state.numStringTensors++;let o=0;t.dtype!==\"complex64\"&&t.dtype!==\"string\"&&(o=t.size*jp(t.dtype)),this.state.numBytes+=o,this.state.tensorInfo.has(t.dataId)||(this.state.numDataBuffers++,this.state.tensorInfo.set(t.dataId,{backend:e||this.backend,dtype:t.dtype,shape:t.shape,bytes:o})),t instanceof oi||this.track(t)}incRef(t,e){this.trackTensor(t,e),this.backend.incRef(t.dataId)}removeDataId(t,e){this.state.tensorInfo.has(t)&&this.state.tensorInfo.get(t).backend===e&&(this.state.tensorInfo.delete(t),this.state.numDataBuffers--)}disposeTensor(t){if(!this.state.tensorInfo.has(t.dataId))return;let e=this.state.tensorInfo.get(t.dataId);if(this.state.numTensors--,t.dtype===\"string\"&&(this.state.numStringTensors--,this.state.numBytes-=e.bytes),t.dtype!==\"complex64\"&&t.dtype!==\"string\"){let o=t.size*jp(t.dtype);this.state.numBytes-=o}e.backend.disposeData(t.dataId)&&this.removeDataId(t.dataId,e.backend)}disposeVariables(){for(let t in this.state.registeredVariables){let e=this.state.registeredVariables[t];this.disposeVariable(e)}}disposeVariable(t){this.disposeTensor(t),this.state.registeredVariables[t.name]!=null&&delete this.state.registeredVariables[t.name]}memory(){let t=this.backend.memory();return t.numTensors=this.state.numTensors,t.numDataBuffers=this.state.numDataBuffers,t.numBytes=this.state.numBytes,this.state.numStringTensors>0&&(t.unreliable=!0,t.reasons==null&&(t.reasons=[]),t.reasons.push(\"Memory usage by string tensors is approximate (2 bytes per character)\")),t}async profile(t){this.state.profiling=!0;let e=this.state.numBytes,o=this.state.numTensors;this.state.activeProfile.kernels=[],this.state.activeProfile.result=await t(),this.state.profiling=!1,this.state.activeProfile.peakBytes=Math.max(...this.state.activeProfile.kernels.map(n=>n.totalBytesSnapshot)),this.state.activeProfile.newBytes=this.state.numBytes-e,this.state.activeProfile.newTensors=this.state.numTensors-o;for(let n of this.state.activeProfile.kernels)n.kernelTimeMs=await n.kernelTimeMs,n.extraInfo=await n.extraInfo;return this.state.activeProfile}isTapeOn(){return this.state.gradientDepth>0&&this.state.kernelDepth===0}addTapeNode(t,e,o,n,s,a){let i={id:this.state.nextTapeNodeId++,kernelName:t,inputs:e,outputs:o,saved:s},p=iw(t);p!=null&&(n=p.gradFunc),n!=null&&(i.gradient=u=>(u=u.map((c,l)=>{if(c==null){let m=o[l],d=Yp(m.size,m.dtype);return this.makeTensor(d,m.shape,m.dtype)}return c}),n(u.length>1?u:u[0],s,a))),this.state.activeTape.push(i)}keep(t){return t.kept=!0,t}startTape(){this.state.gradientDepth===0&&(this.state.activeTape=[]),this.state.gradientDepth++}endTape(){this.state.gradientDepth--}startScope(t){let e={track:[],name:\"unnamed scope\",id:this.state.nextScopeId++};t&&(e.name=t),this.state.scopeStack.push(e),this.state.activeScope=e}endScope(t){let e=Sl(t),o=new Set(e.map(s=>s.id));for(let s=0;s{!s.kept&&s.scopeId===n.id&&this.track(s)})}gradients(t,e,o,n=!1){if($(e.length>0,()=>\"gradients() received an empty list of xs.\"),o!=null&&o.dtype!==\"float32\")throw new Error(`dy must have 'float32' dtype, but has '${o.dtype}'`);let s=this.scopedRun(()=>this.startTape(),()=>this.endTape(),()=>this.tidy(\"forward\",t));$(s instanceof ut,()=>\"The result y returned by f() must be a tensor.\");let a=H0(this.state.activeTape,e,s);if(!n&&a.length===0&&e.length>0)throw new Error(\"Cannot compute gradient of y=f(x) with respect to x. Make sure that the f you passed encloses all operations that lead from x to y.\");return this.tidy(\"backward\",()=>{let i={};i[s.id]=o==null?l4(s.shape):o,K0(i,a,u=>this.tidy(u),m4);let p=e.map(u=>i[u.id]);return this.state.gradientDepth===0&&(this.state.activeTape.forEach(u=>{for(let c of u.saved)c.dispose()}),this.state.activeTape=null),{value:s,grads:p}})}customGrad(t){return $(qs(t),()=>\"The f passed in customGrad(f) must be a function.\"),(...e)=>{$(e.every(i=>i instanceof ut),()=>\"The args passed in customGrad(f)(x1, x2,...) must all be tensors\");let o,n={};e.forEach((i,p)=>{n[p]=i});let s=(i,p)=>(o=t(...e,p),$(o.value instanceof ut,()=>\"The function f passed in customGrad(f) must return an object where `obj.value` is a tensor\"),$(qs(o.gradFunc),()=>\"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function.\"),o.value),a=(i,p)=>{let u=o.gradFunc(i,p),c=Array.isArray(u)?u:[u];$(c.length===e.length,()=>\"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function that returns the same number of tensors as inputs passed to f(...).\"),$(c.every(m=>m instanceof ut),()=>\"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function that returns a list of only tensors.\");let l={};return c.forEach((m,d)=>{l[d]=()=>m}),l};return this.runKernelFunc({forwardFunc:s,backwardsFunc:a,inputs:n})}}readSync(t){return this.state.tensorInfo.get(t).backend.readSync(t)}read(t){return this.state.tensorInfo.get(t).backend.read(t)}readToGPU(t,e){return this.state.tensorInfo.get(t).backend.readToGPU(t,e)}async time(t){let e=Wu(),o=await this.backend.time(t);return o.wallMs=Wu()-e,o}track(t){return this.state.activeScope!=null&&(t.scopeId=this.state.activeScope.id,this.state.activeScope.track.push(t)),t}get registeredVariables(){return this.state.registeredVariables}reset(){this.pendingBackendInitId++,this.state.dispose(),this.ENV.reset(),this.state=new nd;for(let t in this.registry)this.disposeRegisteredKernels(t),this.registry[t].dispose(),delete this.registry[t];this.backendName=null,this.backendInstance=null,this.pendingBackendInit=null}};ru.nextTensorId=0;ru.nextVariableId=0;function l4(r){let t=fl(He(r),\"float32\");return T.makeTensor(t,r,\"float32\")}function Sw(){let r=aw();if(r._tfengine==null){let t=new hl(r);r._tfengine=new ru(t)}return _0(r._tfengine.ENV),Y0(()=>r._tfengine),r._tfengine}var T=Sw();function m4(r,t){let e={a:r,b:t};return T.runKernel(uo,e)}var ou={};qe(ou,{isBrowser:()=>vw,isMobile:()=>h4,mockIsMobile:()=>f4});function d4(){return typeof navigator!=\"undefined\"&&navigator!=null}var Iw;function f4(r){Iw=r}function h4(r){if(Iw!==void 0)return Iw;if(r||d4()){if(r||(r=navigator),r.product===\"ReactNative\")return!0;let t=r.userAgent||r.vendor||(typeof window!=\"undefined\"?window.opera:\"\");if(!t){let e=r;return e.userAgentData&&e.userAgentData.mobile}return/(android|bb\\d+|meego).+mobile|avantgo|bada\\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\\-(n|u)|c55\\/|capi|ccwa|cdm\\-|cell|chtm|cldc|cmd\\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\\-s|devi|dica|dmob|do(c|p)o|ds(12|\\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\\-|_)|g1 u|g560|gene|gf\\-5|g\\-mo|go(\\.w|od)|gr(ad|un)|haie|hcit|hd\\-(m|p|t)|hei\\-|hi(pt|ta)|hp( i|ip)|hs\\-c|ht(c(\\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\\-(20|go|ma)|i230|iac( |\\-|\\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\\/)|klon|kpt |kwc\\-|kyo(c|k)|le(no|xi)|lg( g|\\/(k|l|u)|50|54|\\-[a-w])|libw|lynx|m1\\-w|m3ga|m50\\/|ma(te|ui|xo)|mc(01|21|ca)|m\\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\\-2|po(ck|rt|se)|prox|psio|pt\\-g|qa\\-a|qc(07|12|21|32|60|\\-[2-7]|i\\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\\-|oo|p\\-)|sdk\\/|se(c(\\-|0|1)|47|mc|nd|ri)|sgh\\-|shar|sie(\\-|m)|sk\\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\\-|v\\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\\-|tdg\\-|tel(i|m)|tim\\-|t\\-mo|to(pl|sh)|ts(70|m\\-|m3|m5)|tx\\-9|up(\\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\\-|your|zeto|zte\\-/i.test(t.substr(0,4))}return!1}function vw(){return typeof window!=\"undefined\"&&window.document!=null||typeof WorkerGlobalScope!=\"undefined\"}var $r=A();$r.registerFlag(\"DEBUG\",()=>!1,r=>{r&&console.warn(\"Debugging mode is ON. The output of every math call will be downloaded to CPU and checked for NaNs. This significantly impacts performance.\")});$r.registerFlag(\"IS_BROWSER\",()=>vw());$r.registerFlag(\"IS_NODE\",()=>typeof process!=\"undefined\"&&typeof process.versions!=\"undefined\"&&typeof process.versions.node!=\"undefined\");$r.registerFlag(\"IS_CHROME\",()=>typeof navigator!=\"undefined\"&&navigator!=null&&navigator.userAgent!=null&&/Chrome/.test(navigator.userAgent)&&/Google Inc/.test(navigator.vendor));$r.registerFlag(\"IS_SAFARI\",()=>typeof navigator!=\"undefined\"&&navigator!=null&&navigator.userAgent!=null&&/Safari/.test(navigator.userAgent)&&/Apple/.test(navigator.vendor));$r.registerFlag(\"PROD\",()=>!1);$r.registerFlag(\"TENSORLIKE_CHECK_SHAPE_CONSISTENCY\",()=>$r.getBool(\"DEBUG\"));$r.registerFlag(\"DEPRECATION_WARNINGS_ENABLED\",()=>!0);$r.registerFlag(\"IS_TEST\",()=>!1);$r.registerFlag(\"CHECK_COMPUTATION_FOR_ERRORS\",()=>$r.getBool(\"DEBUG\"));$r.registerFlag(\"WRAP_TO_IMAGEBITMAP\",()=>!1);$r.registerFlag(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\",()=>!1);$r.registerFlag(\"USE_SETTIMEOUTCUSTOM\",()=>!1);function ir(r,t){let e=r;if(Ot(r))return t===\"string\"?[]:[r.length];if(rd(r)){let n=r.channels||\"RGBA\";return[r.height,r.width*n.length]}else if(od(r))return[r.buffer.size/(t==null?4:jp(t))];if(!Array.isArray(r))return[];let o=[];for(;Array.isArray(e)||Ot(e)&&t!==\"string\";)o.push(e.length),e=e[0];return Array.isArray(r)&&A().getBool(\"TENSORLIKE_CHECK_SHAPE_CONSISTENCY\")&&rk(r,o,[]),o}function rk(r,t,e){if(e=e||[],!Array.isArray(r)&&!Ot(r)){$(t.length===0,()=>`Element arr[${e.join(\"][\")}] is a primitive, but should be an array/TypedArray of ${t[0]} elements`);return}$(t.length>0,()=>`Element arr[${e.join(\"][\")}] should be a primitive, but is an array of ${r.length} elements`),$(r.length===t[0],()=>`Element arr[${e.join(\"][\")}] should have ${t[0]} elements, but has ${r.length} elements`);let o=t.slice(1);for(let n=0;n=0&&(n=o),tk(o,n,t,e),r==null||!Ot(r)&&!Array.isArray(r)&&typeof r!=\"number\"&&typeof r!=\"boolean\"&&typeof r!=\"string\"){let p=r==null?\"null\":r.constructor.name;throw new Error(`Argument '${t}' passed to '${e}' must be a Tensor or TensorLike, but got '${p}'`)}let s=ir(r,n);!Ot(r)&&!Array.isArray(r)&&(r=[r]);let i=n!==\"string\"?nc(r,n):Ps(r,[],!0);return T.makeTensor(i,s,n)}function si(r,t,e,o=\"numeric\"){if(!Array.isArray(r))throw new Error(`Argument ${t} passed to ${e} must be a \\`Tensor[]\\` or \\`TensorLike[]\\``);return r.map((s,a)=>v(s,`${t}[${a}]`,e,o))}var kw=\"__op\";function N(r){let t=Object.keys(r);if(t.length!==1)throw new Error(`Please provide an object with a single key (operation name) mapping to a function. Got an object with ${t.length} keys.`);let e=t[0],o=r[e];e.endsWith(\"_\")&&(e=e.substring(0,e.length-1)),e=e+kw;let n=(...s)=>{T.startScope(e);try{let a=o(...s);return Fu(a)&&console.error(\"Cannot return a Promise inside of tidy.\"),T.endScope(a),a}catch(a){throw T.endScope(null),a}};return Object.defineProperty(n,\"name\",{value:e,configurable:!0}),n}function g4(r,t){let e=v(r,\"real\",\"complex\"),o=v(t,\"imag\",\"complex\");yt(e.shape,o.shape,`real and imag shapes, ${e.shape} and ${o.shape}, must match in call to tf.complex().`);let n={real:e,imag:o};return T.runKernel(Fi,n)}var Er=N({complex_:g4});function Sr(r,t,e,o){if(o==null)o=Ri(r);else if(o===\"complex64\")throw new Error(\"Cannot construct a complex64 tensor directly. Please use tf.complex(real, imag).\");if(od(r)||rd(r)){if(o!==\"float32\"&&o!==\"int32\")throw new Error(`Creating tensor from GPU data only supports 'float32'|'int32' dtype, while the dtype is ${o}.`);return T.backend.createTensorFromGPUData(r,t||e,o)}if(!Ot(r)&&!Array.isArray(r)&&typeof r!=\"number\"&&typeof r!=\"boolean\"&&typeof r!=\"string\")throw new Error(\"values passed to tensor(values) must be a number/boolean/string or an array of numbers/booleans/strings, or a TypedArray\");if(t!=null){wt(t);let n=He(t),s=He(e);$(n===s,()=>`Based on the provided shape, [${t}], the tensor should have ${n} values but has ${s}`);for(let a=0;a`Error creating a new Tensor. Inferred shape (${e}) does not match the provided shape (${t}). `)}}return!Ot(r)&&!Array.isArray(r)&&(r=[r]),t=t||e,r=o!==\"string\"?nc(r,o):Ps(r,[],!0),T.makeTensor(r,t,o)}function ur(r,t,e){let o=ir(r,e);return Sr(r,t,o,e)}var Il={float32:4,float16:2,int32:4,uint16:2,uint8:1,bool:1,complex64:8};var jt=class{static join(t){return new jt(t).slice()}constructor(t){if(this.shards=[],this.previousShardIndex=0,t==null||(t instanceof Array||(t=[t]),t=t.map(o=>Ot(o)?o.buffer:o),t.length===0))return;this.bufferUniformSize=t[0].byteLength;let e=0;for(let o=0;o=this.byteLength)return-1;if(this.bufferUniformSize!=null)return this.previousShardIndex=Math.floor(t/this.bufferUniformSize),this.previousShardIndex;function e(n){return t=n.end?1:0}if(e(this.shards[this.previousShardIndex])===0)return this.previousShardIndex;let o=x4(this.shards,e);return o===-1?-1:(this.previousShardIndex=o,this.previousShardIndex)}};function x4(r,t){let e=0,o=r.length;for(;e<=o;){let n=Math.floor((o-e)/2)+e,s=t(r[n]);if(s===0)return n;s<0?o=n:e=n+1}return-1}var sd=4;async function nk(r,t){let e=[],o=[],n=Array.isArray(r)?r.map(a=>a.name):Object.keys(r);for(let a=0;a{let m=await p.bytes(),d=m.reduce((g,x)=>g+x.length,0)+sd*m.length,f=new Uint8Array(d),h=0;for(let g=0;g{if(t+=s.byteLength,e.push(s.byteLength===s.buffer.byteLength?s:new s.constructor(s)),!(s instanceof Float32Array||s instanceof Int32Array||s instanceof Uint8Array))throw new Error(`Unsupported TypedArray subtype: ${s.constructor.name}`)});let o=new Uint8Array(t),n=0;return e.forEach(s=>{o.set(new Uint8Array(s.buffer),n),n+=s.byteLength}),o.buffer}var Nw=typeof Buffer!=\"undefined\"&&(typeof Blob==\"undefined\"||typeof atob==\"undefined\"||typeof btoa==\"undefined\");function ok(r){return Nw?Buffer.byteLength(r,\"utf8\"):new Blob([r]).size}function sk(r){if(Nw)return Buffer.from(r).toString(\"base64\");let t=new Uint8Array(r),e=\"\";for(let o=0,n=t.length;o{let o=e<<13,n=0;for(;!(o&8388608);)n-=8388608,o<<=1;return o&=-8388609,n+=947912704,o|n},t=new Uint32Array(2048);t[0]=0;for(let e=1;e<1024;e++)t[e]=r(e);for(let e=1024;e<2048;e++)t[e]=939524096+(e-1024<<13);return t}function C4(){let r=new Uint32Array(64);r[0]=0,r[31]=1199570944,r[32]=2147483648,r[63]=3347054592;for(let t=1;t<31;t++)r[t]=t<<23;for(let t=33;t<63;t++)r[t]=2147483648+(t-32<<23);return r}function w4(){let r=new Uint32Array(64);for(let t=0;t<64;t++)r[t]=1024;return r[0]=r[32]=0,r}function S4(){let r=b4(),t=C4(),e=w4();return o=>{let n=new ArrayBuffer(4*o.length),s=new Uint32Array(n);for(let a=0;a>10]+(i&1023)]+t[i>>10];s[a]=p}return new Float32Array(n)}}var ft=class{constructor(){this.saveRouters=[],this.loadRouters=[]}static getInstance(){return ft.instance==null&&(ft.instance=new ft),ft.instance}static registerSaveRouter(t){ft.getInstance().saveRouters.push(t)}static registerLoadRouter(t){ft.getInstance().loadRouters.push(t)}static getSaveHandlers(t){return ft.getHandlers(t,\"save\")}static getLoadHandlers(t,e){return ft.getHandlers(t,\"load\",e)}static getHandlers(t,e,o){let n=[];return(e===\"load\"?ft.getInstance().loadRouters:ft.getInstance().saveRouters).forEach(a=>{let i=a(t,o);i!==null&&n.push(i)}),n}},uk=r=>ft.registerSaveRouter(r),pk=r=>ft.registerLoadRouter(r),ck=r=>ft.getSaveHandlers(r),lk=(r,t)=>ft.getLoadHandlers(r,t);var $w=\"tensorflowjs\",Ew=1,Uu=\"models_store\",nu=\"model_info_store\";function mk(){if(!A().getBool(\"IS_BROWSER\"))throw new Error(\"Failed to obtain IndexedDB factory because the current environmentis not a web browser.\");let r=typeof window==\"undefined\"?self:window,t=r.indexedDB||r.mozIndexedDB||r.webkitIndexedDB||r.msIndexedDB||r.shimIndexedDB;if(t==null)throw new Error(\"The current browser does not appear to support IndexedDB.\");return t}function Rw(r){let t=r.result;t.createObjectStore(Uu,{keyPath:\"modelPath\"}),t.createObjectStore(nu,{keyPath:\"modelPath\"})}var ka=class{constructor(t){if(this.indexedDB=mk(),t==null||!t)throw new Error(\"For IndexedDB, modelPath must not be null, undefined or empty.\");this.modelPath=t}async save(t){if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserLocalStorage.save() does not support saving model topology in binary formats yet.\");return this.databaseAction(this.modelPath,t)}async load(){return this.databaseAction(this.modelPath)}databaseAction(t,e){return new Promise((o,n)=>{let s=this.indexedDB.open($w,Ew);s.onupgradeneeded=()=>Rw(s),s.onsuccess=()=>{let a=s.result;if(e==null){let i=a.transaction(Uu,\"readonly\"),u=i.objectStore(Uu).get(this.modelPath);u.onsuccess=()=>{if(u.result==null)return a.close(),n(new Error(`Cannot find model with path '${this.modelPath}' in IndexedDB.`));o(u.result.modelArtifacts)},u.onerror=c=>(a.close(),n(u.error)),i.oncomplete=()=>a.close()}else{e.weightData=jt.join(e.weightData);let i=va(e),p=a.transaction(nu,\"readwrite\"),u=p.objectStore(nu),c;try{c=u.put({modelPath:this.modelPath,modelArtifactsInfo:i})}catch(m){return n(m)}let l;c.onsuccess=()=>{l=a.transaction(Uu,\"readwrite\");let m=l.objectStore(Uu),d;try{d=m.put({modelPath:this.modelPath,modelArtifacts:e,modelArtifactsInfo:i})}catch(f){return n(f)}d.onsuccess=()=>o({modelArtifactsInfo:i}),d.onerror=f=>{u=p.objectStore(nu);let h=u.delete(this.modelPath);h.onsuccess=()=>(a.close(),n(d.error)),h.onerror=g=>(a.close(),n(d.error))}},c.onerror=m=>(a.close(),n(c.error)),p.oncomplete=()=>{l==null?a.close():l.oncomplete=()=>a.close()}}},s.onerror=a=>n(s.error)})}};ka.URL_SCHEME=\"indexeddb://\";var dk=r=>A().getBool(\"IS_BROWSER\")&&!Array.isArray(r)&&r.startsWith(ka.URL_SCHEME)?I4(r.slice(ka.URL_SCHEME.length)):null;ft.registerSaveRouter(dk);ft.registerLoadRouter(dk);function I4(r){return new ka(r)}function v4(r){return r.startsWith(ka.URL_SCHEME)?r.slice(ka.URL_SCHEME.length):r}var pd=class{constructor(){this.indexedDB=mk()}async listModels(){return new Promise((t,e)=>{let o=this.indexedDB.open($w,Ew);o.onupgradeneeded=()=>Rw(o),o.onsuccess=()=>{let n=o.result,s=n.transaction(nu,\"readonly\"),i=s.objectStore(nu).getAll();i.onsuccess=()=>{let p={};for(let u of i.result)p[u.modelPath]=u.modelArtifactsInfo;t(p)},i.onerror=p=>(n.close(),e(i.error)),s.oncomplete=()=>n.close()},o.onerror=n=>e(o.error)})}async removeModel(t){return t=v4(t),new Promise((e,o)=>{let n=this.indexedDB.open($w,Ew);n.onupgradeneeded=()=>Rw(n),n.onsuccess=()=>{let s=n.result,a=s.transaction(nu,\"readwrite\"),i=a.objectStore(nu),p=i.get(t),u;p.onsuccess=()=>{if(p.result==null)return s.close(),o(new Error(`Cannot find model with path '${t}' in IndexedDB.`));{let c=i.delete(t),l=()=>{u=s.transaction(Uu,\"readwrite\");let d=u.objectStore(Uu).delete(t);d.onsuccess=()=>e(p.result.modelArtifactsInfo),d.onerror=f=>o(p.error)};c.onsuccess=l,c.onerror=m=>(l(),s.close(),o(p.error))}},p.onerror=c=>(s.close(),o(p.error)),a.oncomplete=()=>{u==null?s.close():u.oncomplete=()=>s.close()}},n.onerror=s=>o(n.error)})}};var ai=\"/\",uc=\"tensorflowjs_models\",fk=\"info\",k4=\"model_topology\",N4=\"weight_specs\",T4=\"weight_data\",_4=\"model_metadata\";function hk(r){return{info:[uc,r,fk].join(ai),topology:[uc,r,k4].join(ai),weightSpecs:[uc,r,N4].join(ai),weightData:[uc,r,T4].join(ai),modelMetadata:[uc,r,_4].join(ai)}}function gk(r){for(let t of Object.values(r))window.localStorage.removeItem(t)}function $4(r){let t=r.split(ai);if(t.length<3)throw new Error(`Invalid key format: ${r}`);return t.slice(1,t.length-1).join(ai)}function E4(r){return r.startsWith(Na.URL_SCHEME)?r.slice(Na.URL_SCHEME.length):r}var Na=class{constructor(t){if(!A().getBool(\"IS_BROWSER\")||typeof window==\"undefined\"||typeof window.localStorage==\"undefined\")throw new Error(\"The current environment does not support local storage.\");if(this.LS=window.localStorage,t==null||!t)throw new Error(\"For local storage, modelPath must not be null, undefined or empty.\");this.modelPath=t,this.keys=hk(this.modelPath)}async save(t){if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserLocalStorage.save() does not support saving model topology in binary formats yet.\");{let e=JSON.stringify(t.modelTopology),o=JSON.stringify(t.weightSpecs),n=va(t),s=jt.join(t.weightData);try{this.LS.setItem(this.keys.info,JSON.stringify(n)),this.LS.setItem(this.keys.topology,e),this.LS.setItem(this.keys.weightSpecs,o),this.LS.setItem(this.keys.weightData,sk(s));let a={format:t.format,generatedBy:t.generatedBy,convertedBy:t.convertedBy,signature:t.signature!=null?t.signature:void 0,userDefinedMetadata:t.userDefinedMetadata!=null?t.userDefinedMetadata:void 0,modelInitializer:t.modelInitializer!=null?t.modelInitializer:void 0,initializerSignature:t.initializerSignature!=null?t.initializerSignature:void 0,trainingConfig:t.trainingConfig!=null?t.trainingConfig:void 0};return this.LS.setItem(this.keys.modelMetadata,JSON.stringify(a)),{modelArtifactsInfo:n}}catch(a){throw gk(this.keys),new Error(`Failed to save model '${this.modelPath}' to local storage: size quota being exceeded is a possible cause of this failure: modelTopologyBytes=${n.modelTopologyBytes}, weightSpecsBytes=${n.weightSpecsBytes}, weightDataBytes=${n.weightDataBytes}.`)}}}async load(){let t=JSON.parse(this.LS.getItem(this.keys.info));if(t==null)throw new Error(`In local storage, there is no model with name '${this.modelPath}'`);if(t.modelTopologyType!==\"JSON\")throw new Error(\"BrowserLocalStorage does not support loading non-JSON model topology yet.\");let e={},o=JSON.parse(this.LS.getItem(this.keys.topology));if(o==null)throw new Error(`In local storage, the topology of model '${this.modelPath}' is missing.`);e.modelTopology=o;let n=JSON.parse(this.LS.getItem(this.keys.weightSpecs));if(n==null)throw new Error(`In local storage, the weight specs of model '${this.modelPath}' are missing.`);e.weightSpecs=n;let s=this.LS.getItem(this.keys.modelMetadata);if(s!=null){let i=JSON.parse(s);e.format=i.format,e.generatedBy=i.generatedBy,e.convertedBy=i.convertedBy,i.signature!=null&&(e.signature=i.signature),i.userDefinedMetadata!=null&&(e.userDefinedMetadata=i.userDefinedMetadata),i.modelInitializer!=null&&(e.modelInitializer=i.modelInitializer),i.initializerSignature!=null&&(e.initializerSignature=i.initializerSignature),i.trainingConfig!=null&&(e.trainingConfig=i.trainingConfig)}let a=this.LS.getItem(this.keys.weightData);if(a==null)throw new Error(`In local storage, the binary weight values of model '${this.modelPath}' are missing.`);return e.weightData=ak(a),e}};Na.URL_SCHEME=\"localstorage://\";var xk=r=>A().getBool(\"IS_BROWSER\")&&!Array.isArray(r)&&r.startsWith(Na.URL_SCHEME)?R4(r.slice(Na.URL_SCHEME.length)):null;ft.registerSaveRouter(xk);ft.registerLoadRouter(xk);function R4(r){return new Na(r)}var cd=class{constructor(){$(A().getBool(\"IS_BROWSER\"),()=>\"Current environment is not a web browser\"),$(typeof window==\"undefined\"||typeof window.localStorage!=\"undefined\",()=>\"Current browser does not appear to support localStorage\"),this.LS=window.localStorage}async listModels(){let t={},e=uc+ai,o=ai+fk;for(let n=0;n\"scheme must not be undefined or null.\"),t.endsWith(pc)&&(t=t.slice(0,t.indexOf(pc))),$(t.length>0,()=>\"scheme must not be an empty string.\");let o=Zt.getInstance();$(o.managers[t]==null,()=>`A model store manager is already registered for scheme '${t}'.`),o.managers[t]=e}static getManager(t){let e=Zt.getInstance().managers[t];if(e==null)throw new Error(`Cannot find model manager for scheme '${t}'`);return e}static getSchemes(){return Object.keys(Zt.getInstance().managers)}};function ld(r){if(r.indexOf(pc)===-1)throw new Error(`The url string provided does not contain a scheme. Supported schemes are: ${Zt.getSchemes().join(\",\")}`);return{scheme:r.split(pc)[0],path:r.split(pc)[1]}}async function yk(r,t,e=!1){$(r!==t,()=>`Old path and new path are the same: '${r}'`);let o=ft.getLoadHandlers(r);$(o.length>0,()=>`Copying failed because no load handler is found for source URL ${r}.`),$(o.length<2,()=>`Copying failed because more than one (${o.length}) load handlers for source URL ${r}.`);let n=o[0],s=ft.getSaveHandlers(t);$(s.length>0,()=>`Copying failed because no save handler is found for destination URL ${t}.`),$(s.length<2,()=>`Copying failed because more than one (${o.length}) save handlers for destination URL ${t}.`);let a=s[0],i=ld(r).scheme,p=ld(r).path,u=i===ld(r).scheme,c=await n.load();e&&u&&await Zt.getManager(i).removeModel(p);let l=await a.save(c);return e&&!u&&await Zt.getManager(i).removeModel(p),l.modelArtifactsInfo}async function bk(){let r=Zt.getSchemes(),t={};for(let e of r){let o=await Zt.getManager(e).listModels();for(let n in o){let s=e+pc+n;t[s]=o[n]}}return t}async function Ck(r){let t=ld(r);return Zt.getManager(t.scheme).removeModel(t.path)}async function wk(r,t){return yk(r,t,!1)}async function Sk(r,t){return yk(r,t,!0)}var Dw=class{constructor(){this.messageName=\"setTimeoutCustom\",this.functionRefs=[],this.handledMessageCount=0,this.hasEventListener=!1}fetch(t,e){return fetch(t,e)}now(){return performance.now()}encode(t,e){if(e!==\"utf-8\"&&e!==\"utf8\")throw new Error(`Browser's encoder only supports utf-8, but got ${e}`);return this.textEncoder==null&&(this.textEncoder=new TextEncoder),this.textEncoder.encode(t)}decode(t,e){return new TextDecoder(e).decode(t)}setTimeoutCustom(t,e){if(typeof window==\"undefined\"||!A().getBool(\"USE_SETTIMEOUTCUSTOM\")){setTimeout(t,e);return}this.functionRefs.push(t),setTimeout(()=>{window.postMessage({name:this.messageName,index:this.functionRefs.length-1},\"*\")},e),this.hasEventListener||(this.hasEventListener=!0,window.addEventListener(\"message\",o=>{if(o.source===window&&o.data.name===this.messageName){o.stopPropagation();let n=this.functionRefs[o.data.index];n(),this.handledMessageCount++,this.handledMessageCount===this.functionRefs.length&&(this.functionRefs=[],this.handledMessageCount=0)}},!0))}isTypedArray(t){return Qm(t)}};if(A().get(\"IS_BROWSER\")){A().setPlatform(\"browser\",new Dw);try{Zt.registerManager(Na.URL_SCHEME,new cd)}catch(r){}try{Zt.registerManager(ka.URL_SCHEME,new pd)}catch(r){}}var D4={importFetch:()=>Ik()},Aw;var Fw=class{constructor(){this.util=vk(),this.textEncoder=new this.util.TextEncoder}fetch(t,e){return A().global.fetch!=null?A().global.fetch(t,e):(Aw==null&&(Aw=D4.importFetch()),Aw(t,e))}now(){let t=process.hrtime();return t[0]*1e3+t[1]/1e6}encode(t,e){if(e!==\"utf-8\"&&e!==\"utf8\")throw new Error(`Node built-in encoder only supports utf-8, but got ${e}`);return this.textEncoder.encode(t)}decode(t,e){return t.length===0?\"\":new this.util.TextDecoder(e).decode(t)}isTypedArray(t){return this.util.types.isFloat32Array(t)||this.util.types.isInt32Array(t)||this.util.types.isUint8Array(t)||this.util.types.isUint8ClampedArray(t)}};A().get(\"IS_NODE\")&&!A().get(\"IS_BROWSER\")&&A().setPlatform(\"node\",new Fw);function me(r,t=\"float32\",e){return t=t||\"float32\",wt(r),new tt(r,t,e)}function A4(r,t){let e=v(r,\"x\",\"cast\");if(!rw(t))throw new Error(`Failed to cast to unknown dtype ${t}`);if(t===\"string\"&&e.dtype!==\"string\"||t!==\"string\"&&e.dtype===\"string\")throw new Error(\"Only strings can be casted to strings\");let o={x:e},n={dtype:t};return T.runKernel(bo,o,n)}var We=N({cast_:A4});function F4(r){let e={x:v(r,\"x\",\"clone\",\"string_or_numeric\")};return T.runKernel(wo,e)}var Ur=N({clone_:F4});function md(r,t=!1){console.log(r.toString(t))}Sw();var P4={buffer:me,cast:We,clone:Ur,print:md};Q0(P4);function lde(){A().set(\"PROD\",!0)}function mde(){A().set(\"DEBUG\",!0)}function dde(){A().set(\"DEPRECATION_WARNINGS_ENABLED\",!1),console.warn(\"TensorFlow.js deprecation warnings have been disabled.\")}function Pw(r){A().getBool(\"DEPRECATION_WARNINGS_ENABLED\")&&console.warn(r+\" You can disable deprecation warnings with tf.disableDeprecationWarnings().\")}Z0(Pw);function fde(){T.disposeVariables()}function pr(){return T}function hde(){return T.memory()}function gde(r){return T.profile(r)}function De(r,t){return T.tidy(r,t)}function Mt(r){Sl(r).forEach(e=>e.dispose())}function Rr(r){return T.keep(r)}function xde(r){return T.time(r)}function yde(r){return T.setBackend(r)}function bde(){return T.ready()}function Cde(){return T.backendName}function wde(r){T.removeBackend(r)}function Sde(r){return T.findBackend(r)}function Ide(r){return T.findBackendFactory(r)}function su(r,t,e=1){return T.registerBackend(r,t,e)}function vde(){return T.backend}function kde(r,t){A().setPlatform(r,t)}function O4(r,t){let e=v(r,\"a\",\"add\"),o=v(t,\"b\",\"add\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(uo,n)}var Ce=N({add_:O4});function M4(r,t){let e=v(r,\"a\",\"floorDiv\"),o=v(t,\"b\",\"floorDiv\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(In,n)}var dd=N({floorDiv_:M4});function L4(r,t){let e=v(r,\"a\",\"div\"),o=v(t,\"b\",\"div\");if([e,o]=Oe(e,o),e.dtype===\"int32\"&&o.dtype===\"int32\")return dd(e,o);let n={a:e,b:o},s={};return T.runKernel(hn,n,s)}var je=N({div_:L4});function B4(r,t){let e=v(r,\"a\",\"mul\"),o=v(t,\"b\",\"mul\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(Yn,n)}var se=N({mul_:B4});function z4(r){let t=v(r,\"x\",\"abs\");if(t.dtype===\"complex64\"){let e={x:t};return T.runKernel(Pi,e)}else{let e={x:t};return T.runKernel(Xs,e)}}var Jt=N({abs_:z4});function V4(r){let e={x:v(r,\"x\",\"acos\")};return T.runKernel(Wo,e)}var kk=N({acos_:V4});function W4(r){let e={x:v(r,\"x\",\"acosh\")};return T.runKernel(Uo,e)}var Nk=N({acosh_:W4});function U4(r){$(Array.isArray(r),()=>\"The argument passed to tf.addN() must be a list of tensors\"),$(r.length>=1,()=>`Must pass at least one tensor to tf.addN(), but got ${r.length}`);let t=r.map((n,s)=>v(n,`tensors${s}`,\"addN\")),e=t[0];t.forEach(n=>{if(n.dtype!==e.dtype)throw new Error(\"All tensors passed to tf.addN() must have the same dtype\")}),t.forEach(n=>{if(!Cr(n.shape,e.shape))throw new Error(\"All tensors passed to tf.addN() must have the same shape\")});let o=t;return T.runKernel(Go,o)}var Tk=N({addN_:U4});function G4(r,t=null,e=!1){let n={x:v(r,\"x\",\"all\",\"bool\")},s={axis:t,keepDims:e};return T.runKernel(Ho,n,s)}var _k=N({all_:G4});function H4(r,t=null,e=!1){let n={x:v(r,\"x\",\"any\",\"bool\")},s={axis:t,keepDims:e};return T.runKernel(Ko,n,s)}var $k=N({any_:H4});function K4(r,t=0){let o={x:v(r,\"x\",\"argMax\")},n={axis:t};return T.runKernel(Ys,o,n)}var Ek=N({argMax_:K4});function q4(r,t=0){let o={x:v(r,\"x\",\"argMin\")},n={axis:t};return T.runKernel(Qs,o,n)}var Rk=N({argMin_:q4});function j4(r){let e={x:v(r,\"x\",\"asin\")};return T.runKernel(qo,e)}var Dk=N({asin_:j4});function X4(r){let e={x:v(r,\"x\",\"asinh\")};return T.runKernel(jo,e)}var Ak=N({asinh_:X4});function Y4(r){let e={x:v(r,\"x\",\"atan\")};return T.runKernel(Xo,e)}var Fk=N({atan_:Y4});function Q4(r,t){let e=v(r,\"a\",\"atan2\"),o=v(t,\"b\",\"atan2\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(Qo,n)}var Pk=N({atan2_:Q4});function Z4(r){let e={x:v(r,\"x\",\"atanh\")};return T.runKernel(Yo,e)}var Ok=N({atanh_:Z4});function J4(r,t,e,o,n=\"NHWC\",s){let a=r[3],i=[...t,a],p=Lk(n);return Hu(r,i,e,s,o,null,null,p)}function Mw(r,t,e,o,n,s,a=\"channelsLast\"){let[i,p]=vl(t),u;if(a===\"channelsLast\")u=[i,p,r[3],r[3]];else if(a===\"channelsFirst\")u=[i,p,r[1],r[1]];else throw new Error(`Unknown dataFormat ${a}`);return Hu(r,u,e,o,n,s,!1,a)}function eH(r,t,e,o,n,s,a=\"NDHWC\"){let[i,p,u]=Ow(t),c,l;if(a===\"NDHWC\")l=\"channelsLast\",c=[i,p,u,r[4],r[4]];else if(a===\"NCDHW\")l=\"channelsFirst\",c=[i,p,u,r[1],r[1]];else throw new Error(`Unknown dataFormat ${a}`);return Mk(r,c,e,o,n,!1,l,s)}function Hu(r,t,e,o,n,s,a=!1,i=\"channelsLast\"){let[p,u,c,l]=[-1,-1,-1,-1];if(i===\"channelsLast\")[p,u,c,l]=r;else if(i===\"channelsFirst\")[p,l,u,c]=r;else throw new Error(`Unknown dataFormat ${i}`);let[m,d,,f]=t,[h,g]=vl(e),[x,b]=vl(o),C=cc(m,x),S=cc(d,b),{padInfo:k,outHeight:_,outWidth:E}=oH(n,u,c,h,g,C,S,s,i),R=a?f*l:f,D;return i===\"channelsFirst\"?D=[p,R,_,E]:i===\"channelsLast\"&&(D=[p,_,E,R]),{batchSize:p,dataFormat:i,inHeight:u,inWidth:c,inChannels:l,outHeight:_,outWidth:E,outChannels:R,padInfo:k,strideHeight:h,strideWidth:g,filterHeight:m,filterWidth:d,effectiveFilterHeight:C,effectiveFilterWidth:S,dilationHeight:x,dilationWidth:b,inShape:r,outShape:D,filterShape:t}}function Mk(r,t,e,o,n,s=!1,a=\"channelsLast\",i){let[p,u,c,l,m]=[-1,-1,-1,-1,-1];if(a===\"channelsLast\")[p,u,c,l,m]=r;else if(a===\"channelsFirst\")[p,m,u,c,l]=r;else throw new Error(`Unknown dataFormat ${a}`);let[d,f,h,,g]=t,[x,b,C]=Ow(e),[S,k,_]=Ow(o),E=cc(d,S),R=cc(f,k),D=cc(h,_),{padInfo:P,outDepth:O,outHeight:M,outWidth:L}=nH(n,u,c,l,x,b,C,E,R,D,i),B=s?g*m:g,z;return a===\"channelsFirst\"?z=[p,B,O,M,L]:a===\"channelsLast\"&&(z=[p,O,M,L,B]),{batchSize:p,dataFormat:a,inDepth:u,inHeight:c,inWidth:l,inChannels:m,outDepth:O,outHeight:M,outWidth:L,outChannels:B,padInfo:P,strideDepth:x,strideHeight:b,strideWidth:C,filterDepth:d,filterHeight:f,filterWidth:h,effectiveFilterDepth:E,effectiveFilterHeight:R,effectiveFilterWidth:D,dilationDepth:S,dilationHeight:k,dilationWidth:_,inShape:r,outShape:z,filterShape:t}}function tH(r,t,e,o,n){o==null&&(o=Lw(r,t,e));let s=r[0],a=r[1],i=kl((s-t+2*o)/e+1,n),p=kl((a-t+2*o)/e+1,n);return[i,p]}function rH(r,t,e,o,n,s){n==null&&(n=Lw(r,t[0],o[0]));let a=[0,0,0,e];for(let i=0;i<3;i++)r[i]+2*n>=t[i]&&(a[i]=kl((r[i]-t[i]+2*n)/o[i]+1,s));return a}function Lw(r,t,e,o=1){let n=cc(t,o);return Math.floor((r[0]*(e-1)-e+n)/2)}function vl(r){return typeof r==\"number\"?[r,r,r]:r.length===2?[r[0],r[1],1]:r}function Ow(r){return typeof r==\"number\"?[r,r,r]:r}function cc(r,t){return t<=1?r:r+(r-1)*(t-1)}function oH(r,t,e,o,n,s,a,i,p){let u,c,l;if(typeof r==\"number\"){u={top:r,bottom:r,left:r,right:r,type:r===0?\"VALID\":\"NUMBER\"};let d=tH([t,e],s,o,r,i);c=d[0],l=d[1]}else if(r===\"same\"){c=Math.ceil(t/o),l=Math.ceil(e/n);let m=Math.max(0,(c-1)*o+s-t),d=Math.max(0,(l-1)*n+a-e),f=Math.floor(m/2),h=m-f,g=Math.floor(d/2),x=d-g;u={top:f,bottom:h,left:g,right:x,type:\"SAME\"}}else if(r===\"valid\")u={top:0,bottom:0,left:0,right:0,type:\"VALID\"},c=Math.ceil((t-s+1)/o),l=Math.ceil((e-a+1)/n);else if(typeof r==\"object\"){let m=p===\"channelsLast\"?r[1][0]:r[2][0],d=p===\"channelsLast\"?r[1][1]:r[2][1],f=p===\"channelsLast\"?r[2][0]:r[3][0],h=p===\"channelsLast\"?r[2][1]:r[3][1];u={top:m,bottom:d,left:f,right:h,type:m===0&&d===0&&f===0&&h===0?\"VALID\":\"EXPLICIT\"},c=kl((t-s+m+d)/o+1,i),l=kl((e-a+f+h)/n+1,i)}else throw Error(`Unknown padding parameter: ${r}`);return{padInfo:u,outHeight:c,outWidth:l}}function nH(r,t,e,o,n,s,a,i,p,u,c){let l,m,d,f;if(r===\"valid\"&&(r=0),typeof r==\"number\"){l={top:r,bottom:r,left:r,right:r,front:r,back:r,type:r===0?\"VALID\":\"NUMBER\"};let g=rH([t,e,o,1],[i,p,u],1,[n,s,a],r,c);m=g[0],d=g[1],f=g[2]}else if(r===\"same\"){m=Math.ceil(t/n),d=Math.ceil(e/s),f=Math.ceil(o/a);let h=(m-1)*n+i-t,g=(d-1)*s+p-e,x=(f-1)*a+u-o,b=Math.floor(h/2),C=h-b,S=Math.floor(g/2),k=g-S,_=Math.floor(x/2),E=x-_;l={top:S,bottom:k,left:_,right:E,front:b,back:C,type:\"SAME\"}}else throw Error(`Unknown padding parameter: ${r}`);return{padInfo:l,outDepth:m,outHeight:d,outWidth:f}}function kl(r,t){if(!t)return Math.trunc(r);switch(t){case\"round\":return Math.round(r);case\"ceil\":return Math.ceil(r);case\"floor\":return Math.floor(r);default:throw new Error(`Unknown roundingMode ${t}`)}}function Gu(r){let[t,e,o]=vl(r);return t===1&&e===1&&o===1}function xr(r,t){return Gu(r)||Gu(t)}function Ta(r){return vl(r).every(t=>t>0)}function Lk(r){if(r===\"NHWC\")return\"channelsLast\";if(r===\"NCHW\")return\"channelsFirst\";throw new Error(`Unknown dataFormat ${r}`)}function Bt(r,t,e){if(e!=null){if(typeof t==\"string\")throw Error(`Error in ${r}: pad must be an integer when using dimRoundingMode ${e} but got pad ${t}.`);if(typeof t==\"number\")$(qa(t),()=>`Error in ${r}: pad must be an integer when using dimRoundingMode ${e} but got pad ${t}.`);else if(typeof t==\"object\")t.forEach(o=>{o.forEach(n=>{$(qa(n),()=>`Error in ${r}: pad must be an integer when using dimRoundingMode ${e} but got pad ${n}.`)})});else throw Error(`Error in ${r}: Unknown padding parameter: ${t}`)}}function sH(r,t){let o={x:v(r,\"x\",\"reshape\",\"string_or_numeric\")},n={shape:t};return T.runKernel(da,o,n)}var W=N({reshape_:sH});function aH(r,t,e,o,n){let s=v(r,\"x\",\"avgPool\",\"float32\"),a=1;$(xr(e,a),()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${e} and dilations '${a}'`);let i=s,p=!1;s.rank===3&&(p=!0,i=W(s,[1,s.shape[0],s.shape[1],s.shape[2]])),$(i.rank===4,()=>`Error in avgPool: x must be rank 4 but got rank ${i.rank}.`),Bt(\"avgPool\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n},l=T.runKernel(Zo,u,c);return l=We(l,s.dtype),p?W(l,[l.shape[1],l.shape[2],l.shape[3]]):l}var fd=N({avgPool_:aH});function iH(r,t,e,o,n,s=\"NDHWC\"){let a=v(r,\"x\",\"avgPool3d\",\"float32\"),i=a,p=!1;a.rank===4&&(p=!0,i=W(a,[1,a.shape[0],a.shape[1],a.shape[2],a.shape[3]])),$(i.rank===5,()=>`Error in avgPool3d: x must be rank 5 but got rank ${i.rank}.`),$(s===\"NDHWC\",()=>`Error in avgPool3d: Only NDHWC is currently supported, but got dataFormat of ${s}`),$(typeof e==\"number\"&&e>0||Array.isArray(e)&&e[0]>0&&e[1]>0&&e[2]>0,()=>`Error in avgPool3d: Stride must be > 0, but got '${e}'`),Bt(\"avgPool3d\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n,dataFormat:s},l=T.runKernel(Zs,u,c);return l=We(l,i.dtype),p?W(l,[l.shape[1],l.shape[2],l.shape[3],l.shape[4]]):l}var Bk=N({avgPool3d_:iH});function uH(r,t=0){$(r.length>=1,()=>\"Pass at least one tensor to concat\");let e=si(r,\"tensors\",\"concat\",\"string_or_numeric\");if(e[0].dtype===\"complex64\"&&e.forEach(s=>{if(s.dtype!==\"complex64\")throw new Error(`Cannot concatenate complex64 tensors with a tensor\n with dtype ${s.dtype}. `)}),e.length===1)return Ur(e[0]);let o=e,n={axis:t};return T.runKernel(ta,o,n)}var bt=N({concat_:uH});function pH(r,t,e=!1,o=!1){let n=v(r,\"a\",\"matMul\"),s=v(t,\"b\",\"matMul\");[n,s]=Oe(n,s);let a={a:n,b:s},i={transposeA:e,transposeB:o};return T.runKernel(Jo,a,i)}var Ze=N({matMul_:pH});function cH(r){let e={x:v(r,\"x\",\"sigmoid\",\"float32\")};return T.runKernel(Cs,e)}var $a=N({sigmoid_:cH});function lH(r,t,e){let o=v(r,\"x\",\"slice\",\"string_or_numeric\");if(o.rank===0)throw new Error(\"Slicing scalar is not possible\");let n={x:o},s={begin:t,size:e};return T.runKernel(ha,n,s)}var Xe=N({slice_:lH});function mH(r){let e={x:v(r,\"x\",\"tanh\",\"float32\")};return T.runKernel(Es,e)}var Nl=N({tanh_:mH});function dH(r,t,e,o,n,s){let a=v(r,\"forgetBias\",\"basicLSTMCell\"),i=v(t,\"lstmKernel\",\"basicLSTMCell\"),p=v(e,\"lstmBias\",\"basicLSTMCell\"),u=v(o,\"data\",\"basicLSTMCell\"),c=v(n,\"c\",\"basicLSTMCell\"),l=v(s,\"h\",\"basicLSTMCell\"),m=bt([u,l],1),d=Ze(m,i),f=Ce(d,p),h=f.shape[0],g=f.shape[1]/4,x=[h,g],b=Xe(f,[0,0],x),C=Xe(f,[0,g],x),S=Xe(f,[0,g*2],x),k=Xe(f,[0,g*3],x),_=Ce(se($a(b),Nl(C)),se(c,$a(Ce(a,S)))),E=se(Nl(_),$a(k));return[_,E]}var zk=N({basicLSTMCell_:dH});function fH(r,t,e){let o=v(r,\"x\",\"batchToSpaceND\"),n=t.reduce((i,p)=>i*p);$(o.rank>=1+t.length,()=>`input rank is ${o.rank} but should be > than blockShape.length ${t.length}`),$(e.length===t.length,()=>`crops.length is ${e.length} but should be equal to blockShape.length ${t.length}`),$(o.shape[0]%n===0,()=>`input tensor batch is ${o.shape[0]} but is not divisible by the product of the elements of blockShape ${t.join(\" * \")} === ${n}`);let s={x:o},a={blockShape:t,crops:e};return T.runKernel(Js,s,a)}var hd=N({batchToSpaceND_:fH});function Vk(r){let t;return r.rank===0||r.rank===1?t=W(r,[1,1,1,r.size]):r.rank===2?t=W(r,[1,1,r.shape[0],r.shape[1]]):r.rank===3?t=W(r,[1,r.shape[0],r.shape[1],r.shape[2]]):t=r,t}function hH(r,t,e,o,n,s){s==null&&(s=.001);let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(i.rank===p.rank,()=>\"Batch normalization gradient requires mean and variance to have equal ranks.\"),$(c==null||i.rank===c.rank,()=>\"Batch normalization gradient requires mean and offset to have equal ranks.\"),$(u==null||i.rank===u.rank,()=>\"Batch normalization gradient requires mean and scale to have equal ranks.\");let m={x:Vk(a),scale:u,offset:c,mean:i,variance:p},d={varianceEpsilon:s},f=T.runKernel(vn,m,d);return W(f,a.shape)}var au=N({batchNorm_:hH});function gH(r,t,e,o,n,s){let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;return o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(a.rank===2,()=>`Error in batchNorm2D: x must be rank 2 but got rank ${a.rank}.`),$(i.rank===2||i.rank===1,()=>`Error in batchNorm2D: mean must be rank 2 or rank 1 but got rank ${i.rank}.`),$(p.rank===2||p.rank===1,()=>`Error in batchNorm2D: variance must be rank 2 or rank 1 but got rank ${p.rank}.`),u!=null&&$(u.rank===2||u.rank===1,()=>`Error in batchNorm2D: scale must be rank 2 or rank 1 but got rank ${u.rank}.`),c!=null&&$(c.rank===2||c.rank===1,()=>`Error in batchNorm2D: offset must be rank 2 or rank 1 but got rank ${c.rank}.`),au(a,i,p,c,u,s)}var Wk=N({batchNorm2d_:gH});function xH(r,t,e,o,n,s){let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;return o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(a.rank===3,()=>`Error in batchNorm3D: x must be rank 3 but got rank ${a.rank}.`),$(i.rank===3||i.rank===1,()=>`Error in batchNorm3D: mean must be rank 3 or rank 1 but got rank ${i.rank}.`),$(p.rank===3||p.rank===1,()=>`Error in batchNorm3D: variance must be rank 3 or rank 1 but got rank ${p.rank}.`),u!=null&&$(u.rank===3||u.rank===1,()=>`Error in batchNorm3D: scale must be rank 3 or rank 1 but got rank ${u.rank}.`),c!=null&&$(c.rank===3||c.rank===1,()=>`Error in batchNorm3D: offset must be rank 3 or rank 1 but got rank ${c.rank}.`),au(a,i,p,c,u,s)}var Uk=N({batchNorm3d_:xH});function yH(r,t,e,o,n,s){let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;return o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(a.rank===4,()=>`Error in batchNorm4D: x must be rank 4 but got rank ${a.rank}.`),$(i.rank===4||i.rank===1,()=>`Error in batchNorm4D: mean must be rank 4 or rank 1 but got rank ${i.rank}.`),$(p.rank===4||p.rank===1,()=>`Error in batchNorm4D: variance must be rank 4 or rank 1 but got rank ${p.rank}.`),u!=null&&$(u.rank===4||u.rank===1,()=>`Error in batchNorm4D: scale must be rank 4 or rank 1 but got rank ${u.rank}.`),c!=null&&$(c.rank===4||c.rank===1,()=>`Error in batchNorm4D: offset must be rank 4 or rank 1 but got rank ${c.rank}.`),au(a,i,p,c,u,s)}var Gk=N({batchNorm4d_:yH});function bH(r,t,e){let o=v(r,\"x\",\"bincount\"),n=v(t,\"weights\",\"bincount\");$(o.dtype===\"int32\",()=>`Error in bincount: input dtype must be int32, but got ${o.dtype}`),$(e>=0,()=>`size must be non-negative, but got ${e}.`),$(n.size===o.size||n.size===0,()=>`Error in bincount: weights must have the same size as input or0-length, but got input shape: ${o.shape}, weights shape: ${n.shape}.`);let s={x:o,weights:n},a={size:e};return T.runKernel(en,s,a)}var gd=N({bincount_:bH});function CH(r,t){let e=v(r,\"x\",\"bitwiseAnd\"),o=v(t,\"y\",\"bitwiseAnd\");if(!Cr(e.shape,o.shape))throw new Error(`BitwiseAnd: Tensors must have the same shape. x: ${e.shape}, y: ${o.shape}`);if(e.dtype!==\"int32\"||o.dtype!==\"int32\")throw new Error(`BitwiseAnd: Only supports 'int32' values in tensor, found type of x: ${e.dtype} and type of y: ${o.dtype}`);let n={a:e,b:o};return T.runKernel(ja,n)}var Hk=N({bitwiseAnd_:CH});function wH(r,t){let e=v(r,\"s0\",\"broadcastArgs\",\"int32\"),o=v(t,\"s1\",\"broadcastArgs\",\"int32\");if(e.rank!==1)throw new Error(`broadcastArgs(): first input must be a vector (rank=1). Has rank ${e.rank}`);if(o.rank!==1)throw new Error(`broadcastArgs(): second input must be a vector (rank=1). Has rank ${o.rank}`);let n={s0:e,s1:o};return T.runKernel(ea,n)}var Kk=N({broadcastArgs_:wH});function SH(r,t){let e=v(r,\"broadcastTo\",\"x\"),o=e.shape;if(wt(t),t.lengthe.rank){let u=e.shape.slice();for(;u.length=0;u--)if(n[u]===t[u])s[u]=1;else if(e.shape[u]!==1)throw new Error(`broadcastTo(): [${o}] cannot be broadcast to [${t}].`);if(s.map((u,c)=>u>1?c:-1).filter(u=>u>=0).length===0)return Ur(e);let i={x:e},p={reps:s};return T.runKernel(po,i,p)}var iu=N({broadcastTo_:SH});function IH(r){let e={x:v(r,\"x\",\"ceil\",\"float32\")};return T.runKernel(tn,e)}var qk=N({ceil_:IH});function Ea(r,t,e){wt(r),e=e||Ri(t);let o={shape:r,value:t,dtype:e};return T.runKernel(sa,{},o)}function vH(r,t,e){let o=v(r,\"x\",\"clipByValue\");if($(t<=e,()=>`Error in clip: min (${t}) must be less than or equal to max (${e}).`),t===e)return Ea(o.shape,t,o.dtype);let n={x:o},s={clipValueMin:t,clipValueMax:e};return T.runKernel(Co,n,s)}var jk=N({clipByValue_:vH});function kH(r){return bt(r,0)}var Xk=N({concat1d_:kH});function NH(r,t){return bt(r,t)}var Yk=N({concat2d_:NH});function TH(r,t){return bt(r,t)}var Qk=N({concat3d_:TH});function _H(r,t){return bt(r,t)}var Zk=N({concat4d_:_H});function $H(r,t,e,o,n=\"NHWC\",s=[1,1],a){let i=v(r,\"x\",\"conv2d\",\"float32\"),p=v(t,\"filter\",\"conv2d\",\"float32\"),u=i,c=!1;i.rank===3&&(c=!0,u=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),$(u.rank===4,()=>`Error in conv2d: input must be rank 4, but got rank ${u.rank}.`),$(p.rank===4,()=>`Error in conv2d: filter must be rank 4, but got rank ${p.rank}.`),Bt(\"conv2d\",o,a);let l=n===\"NHWC\"?u.shape[3]:u.shape[1];$(l===p.shape[2],()=>`Error in conv2d: depth of input (${l}) must match input depth for filter ${p.shape[2]}.`),$(xr(e,s),()=>`Error in conv2D: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`),$(Ta(s),()=>\"Error in conv2D: Dilated rates should be larger than 0.\"),$(Ta(e),()=>\"Error in conv2D: Strides should be larger than 0.\");let m={x:u,filter:p},d={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a},f=T.runKernel(rn,m,d);return c?W(f,[f.shape[1],f.shape[2],f.shape[3]]):f}var uu=N({conv2d_:$H});function EH(r,t,e,o,n=\"NWC\",s=1,a){let i=v(r,\"x\",\"conv1d\"),p=v(t,\"filter\",\"conv1d\"),u=i,c=!1;i.rank===2&&(c=!0,u=W(i,[1,i.shape[0],i.shape[1]])),$(u.rank===3,()=>`Error in conv1d: input must be rank 3, but got rank ${u.rank}.`),$(p.rank===3,()=>`Error in conv1d: filter must be rank 3, but got rank ${p.rank}.`),Bt(\"conv1d\",o,a),$(u.shape[2]===p.shape[1],()=>`Error in conv1d: depth of input (${u.shape[2]}) must match input depth for filter ${p.shape[1]}.`),$(xr(e,s),()=>`Error in conv1D: Either stride or dilation must be 1. Got stride ${e} and dilation '${s}'`),$(Ta(s),()=>\"Error in conv1D: Dilated rates should be larger than 0.\"),$(Ta(e),()=>\"Error in conv1D: Stride should be larger than 0.\"),$(n===\"NWC\",()=>`Error in conv1d: got dataFormat of ${n} but only NWC is currently supported.`);let l=W(p,[1,p.shape[0],p.shape[1],p.shape[2]]),m=W(u,[u.shape[0],1,u.shape[1],u.shape[2]]),g=uu(m,l,[1,e],o,\"NHWC\",[1,s],a);return c?W(g,[g.shape[2],g.shape[3]]):W(g,[g.shape[0],g.shape[2],g.shape[3]])}var Jk=N({conv1d_:EH});function RH(r,t,e,o,n,s=\"NHWC\",a){$(r.length===t.rank,()=>`Length of inShape (${r.length}) and rank of dy (${t.rank}) must match`);let i=r,p=t,u=!1;t.rank===3&&(u=!0,p=W(t,[1,t.shape[0],t.shape[1],t.shape[2]]),i=[1,r[0],r[1],r[2]]),$(i.length===4,()=>`Error in conv2dDerInput: inShape must be length 4, but got length ${i.length}.`),$(p.rank===4,()=>`Error in conv2dDerInput: dy must be rank 4, but got rank ${p.rank}`),$(e.rank===4,()=>`Error in conv2dDerInput: filter must be rank 4, but got rank ${e.rank}`);let c=s===\"NHWC\"?i[3]:i[1],l=s===\"NHWC\"?p.shape[3]:p.shape[1];$(c===e.shape[2],()=>`Error in conv2dDerInput: depth of input (${c}) must match input depth for filter ${e.shape[2]}.`),$(l===e.shape[3],()=>`Error in conv2dDerInput: depth of output (${l}) must match output depth for filter ${e.shape[3]}.`),Bt(\"conv2dDerInput\",n,a);let m={dy:p,filter:e},d={strides:o,pad:n,dataFormat:s,dimRoundingMode:a,inputShape:i},f=T.runKernel(on,m,d);return u?W(f,[f.shape[1],f.shape[2],f.shape[3]]):f}var xd=N({conv2DBackpropInput_:RH});function DH(r,t,e,o,n,s){let a=v(r,\"x\",\"conv2dTranspose\"),i=v(t,\"filter\",\"conv2dTranspose\");return xd(e,a,i,o,n,\"NHWC\",s)}var e2=N({conv2dTranspose_:DH});function AH(r,t,e,o,n=\"NDHWC\",s=[1,1,1]){let a=v(r,\"x\",\"conv3d\"),i=v(t,\"filter\",\"conv3d\"),p=a,u=!1;a.rank===4&&(u=!0,p=W(a,[1,a.shape[0],a.shape[1],a.shape[2],a.shape[3]])),$(p.rank===5,()=>`Error in conv3d: input must be rank 5, but got rank ${p.rank}.`),$(i.rank===5,()=>`Error in conv3d: filter must be rank 5, but got rank ${i.rank}.`),$(p.shape[4]===i.shape[3],()=>`Error in conv3d: depth of input (${p.shape[4]}) must match input depth for filter ${i.shape[3]}.`),$(xr(e,s),()=>`Error in conv3D: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`),$(n===\"NDHWC\",()=>`Error in conv3d: got dataFormat of ${n} but only NDHWC is currently supported.`),$(Ta(s),()=>\"Error in conv3D: Dilated rates should be larger than 0.\"),$(Ta(e),()=>\"Error in conv3D: Strides should be larger than 0.\");let c={x:p,filter:i},l={strides:e,pad:o,dataFormat:n,dilations:s},m=T.runKernel(nn,c,l);return u?W(m,[m.shape[1],m.shape[2],m.shape[3],m.shape[4]]):m}var t2=N({conv3d_:AH});function FH(r,t,e,o,n){$(r.length===t.rank,()=>`Length of inShape (${r.length}) and rank of dy (${t.rank}) must match`);let s=r,a=t,i=!1;t.rank===4&&(i=!0,a=W(t,[1,t.shape[0],t.shape[1],t.shape[2],t.shape[3]]),s=[1,r[0],r[1],r[2],r[3]]);let p=s[4],u=a.shape[4];$(s.length===5,()=>`Error in conv3dDerInput: inShape must be length 5, but got length ${s.length}.`),$(a.rank===5,()=>`Error in conv3dDerInput: dy must be rank 5, but got rank ${a.rank}`),$(e.rank===5,()=>`Error in conv3dDerInput: filter must be rank 5, but got rank ${e.rank}`),$(p===e.shape[3],()=>`Error in conv3dDerInput: depth of input (${p}) must match input depth for filter ${e.shape[3]}.`),$(u===e.shape[4],()=>`Error in conv3dDerInput: depth of output (${u}) must match output depth for filter ${e.shape[4]}.`);let c={dy:a,filter:e},l={pad:n,strides:o,inputShape:s},m=T.runKernel(sn,c,l);return i?W(m,[m.shape[1],m.shape[2],m.shape[3],m.shape[4]]):m}var r2=N({conv3DBackpropInput_:FH});function PH(r,t,e,o,n){let s=v(r,\"x\",\"conv3dTranspose\"),a=v(t,\"filter\",\"conv3dTranspose\");return r2(e,s,a,o,n)}var o2=N({conv3dTranspose_:PH});function OH(r){let e={x:v(r,\"x\",\"cos\",\"float32\")};return T.runKernel(an,e)}var n2=N({cos_:OH});function MH(r){let e={x:v(r,\"x\",\"cosh\",\"float32\")};return T.runKernel(un,e)}var s2=N({cosh_:MH});function LH(r,t=0,e=!1,o=!1){let s={x:v(r,\"x\",\"cumprod\")},a={axis:t,exclusive:e,reverse:o};return T.runKernel(pn,s,a)}var a2=N({cumprod_:LH});function BH(r,t=0,e=!1,o=!1){let s={x:v(r,\"x\",\"cumsum\")},a={axis:t,exclusive:e,reverse:o};return T.runKernel(cn,s,a)}var i2=N({cumsum_:BH});function zH(r,t,e,o=!1){let n=v(r,\"x\",\"denseBincount\"),s=v(t,\"weights\",\"denseBincount\");$(n.dtype===\"int32\",()=>`Error in denseBincount: input dtype must be int32, but got ${n.dtype}`),$(n.rank<=2,()=>`Error in denseBincount: input must be at most rank 2, but got rank ${n.rank}.`),$(e>=0,()=>`size must be non-negative, but got ${e}.`),$(s.size===n.size||s.size===0,()=>`Error in denseBincount: weights must have the same shape as x or 0-length, but got x shape: ${n.shape}, weights shape: ${s.shape}.`);let a={x:n,weights:s},i={size:e,binaryOutput:o};return T.runKernel(ra,a,i)}var u2=N({denseBincount_:zH});function VH(r,t,e=\"NHWC\"){let o=v(r,\"x\",\"depthToSpace\",\"float32\"),n=e===\"NHWC\"?o.shape[1]:o.shape[2],s=e===\"NHWC\"?o.shape[2]:o.shape[3],a=e===\"NHWC\"?o.shape[3]:o.shape[1];$(t>1,()=>`blockSize should be > 1 for depthToSpace, but was: ${t}`),$(n*t>=0,()=>`Negative dimension size caused by overflow when multiplying\n ${n} and ${t} for depthToSpace with input shape\n ${o.shape}`),$(s*t>=0,()=>`Negative dimension size caused by overflow when multiplying\n ${s} and ${t} for depthToSpace with input shape\n ${o.shape}`),$(a%(t*t)===0,()=>`Dimension size must be evenly divisible by ${t*t} but is ${a} for depthToSpace with input shape ${o.shape}`);let i={x:o},p={blockSize:t,dataFormat:e};return T.runKernel(mn,i,p)}var p2=N({depthToSpace_:VH});function WH(r,t,e,o,n=\"NHWC\",s=[1,1],a){let i=v(r,\"x\",\"depthwiseConv2d\",\"float32\"),p=v(t,\"filter\",\"depthwiseConv2d\",\"float32\"),u=i,c=!1;i.rank===3&&(c=!0,u=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),$(u.rank===4,()=>`Error in depthwiseConv2d: input must be rank 4, but got rank ${u.rank}.`),$(p.rank===4,()=>`Error in depthwiseConv2d: filter must be rank 4, but got rank ${p.rank}.`);let l=n===\"NHWC\"?u.shape[3]:u.shape[1];$(l===p.shape[2],()=>`Error in depthwiseConv2d: number of input channels (${l}) must match the inChannels dimension in filter ${p.shape[2]}.`),Bt(\"depthwiseConv2d\",o,a);let m={x:u,filter:p},d={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a},f=T.runKernel(dn,m,d);return c?W(f,[f.shape[1],f.shape[2],f.shape[3]]):f}var lc=N({depthwiseConv2d_:WH});function UH(r){let e={x:v(r,\"x\",\"diag\")};return T.runKernel(oa,e)}var c2=N({diag_:UH});function GH(r,t,e,o,n=[1,1],s=\"NHWC\"){let a=v(r,\"x\",\"dilation2d\"),i=v(t,\"filter\",\"dilation2d\");$(a.rank===3||a.rank===4,()=>`Error in dilation2d: input must be rank 3 or 4, but got rank ${a.rank}.`),$(i.rank===3,()=>`Error in dilation2d: filter must be rank 3, but got rank ${i.rank}.`),$(s===\"NHWC\",()=>`Error in dilation2d: Only NHWC is currently supported, but got dataFormat of ${s}`);let p=a,u=!1;a.rank===3&&(p=W(a,[1,a.shape[0],a.shape[1],a.shape[2]]),u=!0),$(p.shape[3]===i.shape[2],()=>`Error in dilation2d: input and filter must have the same depth: ${p.shape[3]} vs ${i.shape[2]}`);let c={x:p,filter:i},l={strides:e,pad:o,dilations:n},m=T.runKernel(fn,c,l);return u?W(m,[m.shape[1],m.shape[2],m.shape[3]]):m}var l2=N({dilation2d_:GH});var Ir={};qe(Ir,{assertAndGetBroadcastShape:()=>rt,getBroadcastDims:()=>m2,getReductionAxes:()=>yd});function m2(r,t){let e=r.length,o=[];for(let n=0;n1&&a===1&&o.unshift(s)}return o}function yd(r,t){let e=[];for(let o=0;o1)&&e.unshift(s)}return e}function rt(r,t){let e=Math.max(r.length,t.length),o=new Array(e);for(let n=0;n`Error in dot: inputs must all be rank 1 or 2, but got ranks ${e.rank} and ${o.rank}.`);let n=e.rank===1?e.size:e.shape[1],s=o.rank===1?o.size:o.shape[0];if($(n===s,()=>`Error in dot: inner dimensions of inputs must match, but got ${n} and ${s}.`),e.rank===1&&o.rank===1){let a=W(e,[1,-1]),i=W(o,[-1,1]),p=Ze(a,i);return W(p,[])}else if(e.rank===1&&o.rank===2){let a=W(e,[1,-1]),i=W(o,[o.shape[0],o.shape[1]]),p=Ze(a,i);return W(p,[p.size])}else if(e.rank===2&&o.rank===1){let a=W(o,[-1,1]),i=Ze(e,a);return W(i,[i.size])}else{let a=W(o,[o.shape[0],o.shape[1]]);return Ze(e,a)}}var f2=N({dot_:XH});function YH(r,...t){let e=t.map((n,s)=>v(n,`tensors${s}`,\"einsum\")),o={equation:r};return T.runKernel(Vi,e,o)}var pu=N({einsum_:YH});function QH(r){let e={x:v(r,\"x\",\"elu\",\"float32\")};return T.runKernel(gn,e)}var Cd=N({elu_:QH});function ZH(r,t){let e=v(r,\"x\",\"ensureShape\",\"string_or_numeric\");if(!ZC(e.shape,t))throw new Error(`EnsureShape: Shape of tensor ${e.shape} is not compatible with expected shape ${t}`);return r}var h2=N({ensureShape_:ZH});function JH(r){let t=v(r,\"x\",\"erf\");$(t.dtype===\"int32\"||t.dtype===\"float32\",()=>\"Input dtype must be `int32` or `float32`.\"),t.dtype===\"int32\"&&(t=We(t,\"float32\"));let e={x:t};return T.runKernel(xn,e)}var g2=N({erf_:JH});function Bw(r,t){for(let e=0;er[s]);return[e,n]}function ii(r,t){let e=t.map(o=>1);return x2(r,e,t)}function tK(r,t,e){$(Bw(t,e),()=>`${r} supports only inner-most axes for now. Got axes ${t} and rank-${e} input.`)}function rK(r,t){if(Bw(r,t))return null;let e=[];for(let o=0;oe.push(o)),e}function oK(r){return r.map((t,e)=>[e,t]).sort((t,e)=>t[1]-e[1]).map(t=>t[0])}function nK(r,t){let e=[];for(let o=t-r;o\"Axis must be <= rank of the tensor\");let o={input:e},n={dim:t};return T.runKernel(na,o,n)}var Ms=N({expandDims_:hK});function gK(r){let e={x:v(r,\"x\",\"expm1\")};return T.runKernel(Cn,e)}var C2=N({expm1_:gK});function xK(r,t){let e=v(r,\"x\",\"tile\",\"string_or_numeric\");$(e.rank===t.length,()=>`Error in transpose: rank of input ${e.rank} must match length of reps ${t}.`);let o={x:e},n={reps:t};return T.runKernel(po,o,n)}var cu=N({tile_:xK});function yK(r,t,e,o=\"float32\"){t==null&&(t=r);let n=me([r,t],o),s=r<=t?r:t;for(let i=0;i`Error in localResponseNormalization: x must be rank 3 or 4 but got\n rank ${s.rank}.`),$(qa(t),()=>`Error in localResponseNormalization: depthRadius must be an integer but got depthRadius ${t}.`);let a=s,i=!1;s.rank===3&&(i=!0,a=W(s,[1,s.shape[0],s.shape[1],s.shape[2]]));let p={x:a},u={depthRadius:t,bias:e,alpha:o,beta:n},c=T.runKernel(zn,p,u);return i?W(c,[c.shape[1],c.shape[2],c.shape[3]]):c}var k2=N({localResponseNormalization_:EK});function RK(r){let e={x:v(r,\"x\",\"log\",\"float32\")};return T.runKernel(Pn,e)}var pi=N({log_:RK});function DK(r){let e={x:v(r,\"x\",\"log1p\")};return T.runKernel(On,e)}var Nd=N({log1p_:DK});function AK(r){return $(qs(r),()=>\"The f passed in grad(f) must be a function\"),(t,e)=>{let o=v(t,\"x\",\"tf.grad\",\"string_or_numeric\"),n=e!=null?v(e,\"dy\",\"tf.grad\"):null;return T.tidy(()=>{let{value:s,grads:a}=T.gradients(()=>r(o),[o],n);return n!=null&&yt(s.shape,n.shape,\"The shape of dy passed in grad(f)(x, dy) must match the shape returned by f(x)\"),Td(a),a[0]})}}function FK(r){return $(qs(r),()=>\"The f passed in grads(f) must be a function\"),(t,e)=>{$(Array.isArray(t),()=>\"The args passed in grads(f)(args) must be an array of `Tensor`s or `TensorLike`s\");let o=si(t,\"args\",\"tf.grads\",\"string_or_numeric\"),n=e!=null?v(e,\"dy\",\"tf.grads\"):null;return T.tidy(()=>{let{value:s,grads:a}=T.gradients(()=>r(...o),o,n);return n!=null&&yt(s.shape,n.shape,\"The shape of dy passed in grads(f)([x1,...], dy) must match the shape returned by f([x1,...])\"),Td(a),a})}}function PK(r){return $(qs(r),()=>\"The f passed in valueAndGrad(f) must be a function\"),(t,e)=>{$(t instanceof ut,()=>\"The x passed in valueAndGrad(f)(x) must be a tensor\"),$(e==null||e instanceof ut,()=>\"The dy passed in valueAndGrad(f)(x, dy) must be a tensor\");let{grads:o,value:n}=T.gradients(()=>r(t),[t],e);return Td(o),{grad:o[0],value:n}}}function OK(r){return $(qs(r),()=>\"The f passed in valueAndGrads(f) must be a function\"),(t,e)=>{$(Array.isArray(t)&&t.every(n=>n instanceof ut),()=>\"The args passed in valueAndGrads(f)(args) must be array of tensors\"),$(e==null||e instanceof ut,()=>\"The dy passed in valueAndGrads(f)(args, dy) must be a tensor\");let o=T.gradients(()=>r(...t),t,e);return e!=null&&yt(o.value.shape,e.shape,\"The shape of dy passed in valueAndGrads(f)([x1,...], dy) must match the shape returned by f([x1,...])\"),Td(o.grads),o}}function zw(r,t){$(qs(r),()=>\"The f passed in variableGrads(f) must be a function\"),$(t==null||Array.isArray(t)&&t.every(u=>u instanceof oi),()=>\"The varList passed in variableGrads(f, varList) must be an array of variables\");let e=t!=null;if(!e){t=[];for(let u in T.registeredVariables)t.push(T.registeredVariables[u])}let o=e?t.filter(u=>!u.trainable):null,n=t.length;t=t.filter(u=>u.trainable),$(t.length>0,()=>`variableGrads() expects at least one of the input variables to be trainable, but none of the ${n} variables is trainable.`);let s=!0,{value:a,grads:i}=T.gradients(r,t,null,s);$(i.some(u=>u!=null),()=>\"Cannot find a connection between any variable and the result of the loss function y=f(x). Please make sure the operations that use variables are inside the function f passed to minimize().\"),$(a.rank===0,()=>`The f passed in variableGrads(f) must return a scalar, but it returned a rank-${a.rank} tensor`);let p={};return t.forEach((u,c)=>{i[c]!=null&&(p[u.name]=i[c])}),o!=null&&o.forEach(u=>p[u.name]=null),{value:a,grads:p}}function vr(r){return T.customGrad(r)}function Td(r){if(r.filter(e=>e==null).length>0)throw new Error(`Cannot compute gradient of y=f(x) with respect to x. Make sure that\n the f you passed encloses all operations that lead from x to y.`)}function MK(r){let e={x:v(r,\"x\",\"neg\")};return T.runKernel(pa,e)}var cr=N({neg_:MK});function LK(r){let e={x:v(r,\"x\",\"softplus\")};return T.runKernel(ws,e)}var _d=N({softplus_:LK});function BK(r){let t=v(r,\"x\",\"logSigmoid\");return vr(o=>({value:cr(_d(cr(o))),gradFunc:a=>se(a,$a(cr(o)))}))(t)}var N2=N({logSigmoid_:BK});function zK(r,t){let e=v(r,\"a\",\"sub\"),o=v(t,\"b\",\"sub\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(_s,n)}var Te=N({sub_:zK});function VK(r,t=-1){let e=v(r,\"logits\",\"logSoftmax\");if(t===-1&&(t=e.rank-1),t!==e.rank-1)throw Error(`Log Softmax along a non-last dimension is not yet supported. Logits was rank ${e.rank} and axis was ${t}`);return vr((n,s)=>{let i=Ra(n,t,!0),p=Te(n,i),u=Te(We(p,\"float32\"),pi(ot($o(p),t,!0)));return s([u]),{value:u,gradFunc:(l,m)=>{let[d]=m,f=!0,h=$o(d);return Te(l,se(ot(l,t,f),h))}}})(e)}var T2=N({logSoftmax_:VK});function WK(r,t=null,e=!1){let o=v(r,\"x\",\"logSumExp\"),n=Ei(t,o.shape),s=Ra(o,n,!0),a=Te(o,s),i=$o(a),p=ot(i,n),u=pi(p),c=Ce(W(s,u.shape),u);if(e){let l=ii(c.shape,n);return W(c,l)}return c}var $d=N({logSumExp_:WK});function UK(r,t){let e=v(r,\"a\",\"logicalAnd\",\"bool\"),o=v(t,\"b\",\"logicalAnd\",\"bool\");rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Mn,n)}var ju=N({logicalAnd_:UK});function GK(r){let e={x:v(r,\"x\",\"logicalNot\",\"bool\")};return T.runKernel(Ln,e)}var Ed=N({logicalNot_:GK});function HK(r,t){let e=v(r,\"a\",\"logicalOr\",\"bool\"),o=v(t,\"b\",\"logicalOr\",\"bool\");rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Bn,n)}var Rd=N({logicalOr_:HK});function KK(r,t){let e=v(r,\"a\",\"logicalXor\",\"bool\"),o=v(t,\"b\",\"logicalXor\",\"bool\");return rt(e.shape,o.shape),ju(Rd(r,t),Ed(ju(r,t)))}var _2=N({logicalXor_:KK});var Dd=2147483648;function qK(r,t,e=\"left\"){let o=v(r,\"sortedSequence\",\"searchSorted\"),n=v(t,\"values\",\"searchSorted\"),s=o.shape[o.shape.length-1],a=n.shape[n.shape.length-1],i=W(o,[-1,s]),p=W(n,[-1,a]);if(i.rank<2)throw new Error(\"Sorted input argument must be at least 2-dimensional\");if(i.shape[0]!==p.shape[0])throw new Error(\"Leading dimension of 'sortedSequence' and 'values' must match.\");if(He(p.shape)>=Dd)throw new Error(`values tensor size must less than ${Dd}`);if(i.shape[1]>=Dd)throw new Error(`trailing dim_size must less than ${Dd} for int32 output type, was ${i.shape[1]}`);let u={sortedSequence:i,values:p},c={side:e};return T.runKernel(hs,u,c)}var $l=N({searchSorted_:qK});function $2(r,t){return $l(r,t,\"left\")}function jK(r,t,e,o,n){let s=v(r,\"x\",\"maxPool\"),a=1,i=s,p=!1;s.rank===3&&(p=!0,i=W(s,[1,s.shape[0],s.shape[1],s.shape[2]])),$(i.rank===4,()=>`Error in maxPool: input must be rank 4 but got rank ${i.rank}.`),$(xr(e,a),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${e} and dilations '${a}'`),Bt(\"maxPool\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n},l=T.runKernel(Un,u,c);return p?W(l,[l.shape[1],l.shape[2],l.shape[3]]):l}var Ad=N({maxPool_:jK});function XK(r,t=[1,1,1],e,o,n,s=\"NDHWC\"){let a=v(r,\"x\",\"maxPool3d\"),i=a,p=!1;a.rank===4&&(p=!0,i=W(a,[1,a.shape[0],a.shape[1],a.shape[2],a.shape[3]])),$(i.rank===5,()=>`Error in maxPool3d: x must be rank 5 but got rank ${i.rank}.`),$(s===\"NDHWC\",()=>`Error in maxPool3d: Only NDHWC is currently supported, but got dataFormat of ${s}`),Bt(\"maxPool3d\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n,dataFormat:s},l=T.runKernel(ia,u,c);return p?W(l,[l.shape[1],l.shape[2],l.shape[3],l.shape[4]]):l}var E2=N({maxPool3d_:XK});function YK(r,t,e,o,n=!1){let a={x:v(r,\"x\",\"maxPoolWithArgmax\")},i={filterSize:t,strides:e,pad:o,includeBatchInIndex:n},p=T.runKernel(ua,a,i);return{result:p[0],indexes:p[1]}}var R2=N({maxPoolWithArgmax_:YK});function QK(r,t){let e=v(r,\"a\",\"maximum\"),o=v(t,\"b\",\"maximum\");[e,o]=Oe(e,o),e.dtype===\"bool\"&&(e=We(e,\"int32\"),o=We(o,\"int32\")),rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Wn,n)}var Fd=N({maximum_:QK});function ZK(r,t=null,e=!1){let n={x:v(r,\"x\",\"mean\")},s={axis:t,keepDims:e};return T.runKernel(Gn,n,s)}var Xu=N({mean_:ZK});function Gr(r,t=\"float32\"){if(wt(r),t===\"complex64\"){let o=Gr(r,\"float32\"),n=Gr(r,\"float32\");return Er(o,n)}let e=Yp(He(r),t);return T.makeTensor(e,r,t)}function Da(r,t=\"float32\"){if(wt(r),t===\"complex64\"){let o=Da(r,\"float32\"),n=Gr(r,\"float32\");return Er(o,n)}let e=fl(He(r),t);return T.makeTensor(e,r,t)}function D2(r,t,{indexing:e=\"xy\"}={}){if(e!==\"xy\"&&e!==\"ij\")throw new TypeError(`${e} is not a valid third argument to meshgrid`);if(r===void 0)return[];let o=v(r,\"x\",\"meshgrid\",r instanceof ut?r.dtype:\"float32\");if(t===void 0)return[o];let n=v(t,\"y\",\"meshgrid\",t instanceof ut?t.dtype:\"float32\"),s=He(o.shape),a=He(n.shape);return e===\"xy\"?(o=W(o,[1,-1]),n=W(n,[-1,1]),[Ze(Da([a,1],o.dtype),o),Ze(n,Da([1,s],n.dtype))]):(o=W(o,[-1,1]),n=W(n,[1,-1]),[Ze(o,Da([1,a],o.dtype)),Ze(Da([s,1],n.dtype),n)])}function JK(r,t){let e=v(r,\"a\",\"minimum\"),o=v(t,\"b\",\"minimum\");[e,o]=Oe(e,o),e.dtype===\"bool\"&&(e=We(e,\"int32\"),o=We(o,\"int32\")),rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Kn,n)}var Yu=N({minimum_:JK});function eq(r,t,e){$(e===\"reflect\"||e===\"symmetric\",()=>`Invalid mode. Mode must be either reflect or symmetric. Got ${e}.`);let o=v(r,\"x\",\"mirrorPad\");if(o.rank===0)throw new Error(\"mirrorPad(scalar) is not defined. Pass non-scalar to mirrorPad\");$(t.length===o.rank,()=>`Padding doesn't match input. Must be ${o.rank}. Got ${t.length}.`);let n=e===\"reflect\"?1:0;for(let i=0;i\"Invalid number of paddings. Must be length of 2 each.\"),$(t[i][0]>=0&&t[i][0]<=o.shape[i]-n&&t[i][1]>=0&&t[i][1]<=o.shape[i]-n,()=>`Padding in dimension ${i} cannot be greater than or equal to ${o.shape[i]-n} or less than 0 for input of shape ${o.shape}`);let s={paddings:t,mode:e},a={x:o};return T.runKernel(qn,a,s)}var A2=N({mirrorPad_:eq});function tq(r,t){let e=v(r,\"a\",\"mod\"),o=v(t,\"b\",\"mod\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(jn,n)}var F2=N({mod_:tq});function rq(r,t=null,e=!1){r=v(r,\"x\",\"moments\");let o=Ei(t,r.shape),n=Xu(r,o,e),s=n.shape;e||(s=ii(n.shape,o));let a=er(Te(We(r,\"float32\"),W(n,s))),i=Xu(a,o,e);return{mean:n,variance:i}}var P2=N({moments_:rq});function oq(r,t,e,o){let n=v(t,\"data\",\"multiRNNCell\"),s=si(e,\"c\",\"multiRNNCell\"),a=si(o,\"h\",\"multiRNNCell\"),i=n,p=[];for(let l=0;l2)throw new Error(`Rank of probabilities must be 1 or 2, but is ${a}`);e=e||Math.random();let p={logits:a===1?W(n,[1,-1]):n},u={numSamples:t,seed:e,normalized:o},c=T.runKernel(Xn,p,u);return a===1?W(c,[c.size]):c}var M2=N({multinomial_:nq});function sq(r,t){let e=v(r,\"a\",\"notEqual\",\"string_or_numeric\"),o=v(t,\"b\",\"notEqual\",\"string_or_numeric\");[e,o]=Oe(e,o),rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Qn,n)}var Pd=N({notEqual_:sq});function aq(r,t,e=1,o=0,n=\"int32\"){if(t<2)throw new Error(`Error in oneHot: depth must be >=2, but it is ${t}`);let a={indices:v(r,\"indices\",\"oneHot\",\"int32\")},i={dtype:n,depth:t,onValue:e,offValue:o};return T.runKernel(es,a,i)}var El=N({oneHot_:aq});function iq(r){let e={x:v(r,\"x\",\"onesLike\")};return T.runKernel(ca,e)}var L2=N({onesLike_:iq});function uq(r,t){let e=v(r,\"v1\",\"outerProduct\"),o=v(t,\"v2\",\"outerProduct\");$(e.rank===1&&o.rank===1,()=>`Error in outerProduct: inputs must be rank 1, but got ranks ${e.rank} and ${o.rank}.`);let n=W(e,[-1,1]),s=W(o,[1,-1]);return Ze(n,s)}var B2=N({outerProduct_:uq});function pq(r,t,e=0){let o=v(r,\"x\",\"pad\");if(o.rank===0)throw new Error(\"pad(scalar) is not defined. Pass non-scalar to pad\");let n={paddings:t,constantValue:e},s={x:o};return T.runKernel(ts,s,n)}var Aa=N({pad_:pq});function cq(r,t,e=0){return $(t.length===2,()=>\"Invalid number of paddings. Must be length of 2.\"),Aa(r,[t],e)}var z2=N({pad1d_:cq});function lq(r,t,e=0){return $(t.length===2&&t[0].length===2&&t[1].length===2,()=>\"Invalid number of paddings. Must be length of 2 each.\"),Aa(r,t,e)}var V2=N({pad2d_:lq});function mq(r,t,e=0){return $(t.length===3&&t[0].length===2&&t[1].length===2&&t[2].length===2,()=>\"Invalid number of paddings. Must be length of 2 each.\"),Aa(r,t,e)}var W2=N({pad3d_:mq});function dq(r,t,e=0){return $(t.length===4&&t[0].length===2&&t[1].length===2&&t[2].length===2&&t[3].length===2,()=>\"Invalid number of paddings. Must be length of 2 each.\"),Aa(r,t,e)}var U2=N({pad4d_:dq});function fq(r,t,e){let o=v(r,\"x\",\"spaceToBatchND\");$(o.rank>=1+t.length,()=>`input rank ${o.rank} should be > than [blockShape] ${t.length}`),$(e.length===t.length,()=>`paddings.shape[0] ${e.length} must be equal to [blockShape] ${t.length}`),$(o.shape.reduce((a,i,p)=>p>0&&p<=t.length?a&&(i+e[p-1][0]+e[p-1][1])%t[p-1]===0:a,!0),()=>`input spatial dimensions ${o.shape.slice(1)} with paddings ${e.toString()} must be divisible by blockShapes ${t.toString()}`);let n={x:o},s={blockShape:t,paddings:e};return T.runKernel(ga,n,s)}var Od=N({spaceToBatchND_:fq});function hq(r,t,e,o,n,s,a){n==null&&(n=[1,1]),s==null&&(s=1),o===0&&(o=\"valid\");let i=v(r,\"x\",\"maxPool\"),p=i,u=!1;i.rank===3&&(u=!0,p=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),$(xr(s,n),()=>`Error in pool: Either strides or dilations must be 1. Got strides ${s} and dilations '${n}'`);let c=Mw(p.shape,t,s,n,o),l=[c.dilationHeight,c.dilationWidth],m;o===\"same\"?m=xq([c.filterHeight,c.filterWidth],l):m=[[0,0],[0,0]];let d=l[0]===1&&l[1]===1,[f,h]=gq([c.inHeight,c.inWidth],l,m),g=d?o:\"valid\",x=d?p:Od(p,l,f),C=(e===\"avg\"?()=>fd(x,t,s,g,a):()=>Ad(x,t,s,g,a))(),S=d?C:hd(C,l,h);return u?W(S,[S.shape[1],S.shape[2],S.shape[3]]):S}function gq(r,t,e){let o=e.map(c=>c[0]),n=e.map(c=>c[1]),s=r.concat(o,n),a=t.map((c,l)=>(c-s[l]%c)%c),i=n.map((c,l)=>c+a[l]),p=t.map((c,l)=>[o[l],i[l]]),u=t.map((c,l)=>[0,a[l]]);return[p,u]}function xq(r,t){let o=r.map((a,i)=>a+(a-1)*(t[i]-1)).map(a=>a-1),n=o.map(a=>Math.floor(a/2)),s=o.map((a,i)=>a-n[i]);return o.map((a,i)=>[n[i],s[i]])}var G2=N({pool_:hq});function yq(r,t){let e=v(r,\"x\",\"prelu\"),o=v(t,\"alpha\",\"prelu\"),n={x:e,alpha:o};return T.runKernel(os,n)}var Md=N({prelu_:yq});function bq(r,t=null,e=!1){let o=v(r,\"x\",\"prod\");o.dtype===\"bool\"&&(o=We(o,\"int32\"));let n={x:o},s={axis:t,keepDims:e};return T.runKernel(ns,n,s)}var H2=N({prod_:bq});function Cq(r,t,e,o){let n=r.map((c,l)=>v(c,`tensors${l}`,\"raggedGather\",\"int32\")),s=v(t,\"paramsDenseValues\",\"raggedGather\"),a=v(e,\"indices\",\"raggedGather\",\"int32\"),i={paramsNestedSplits:n,paramsDenseValues:s,indices:a},p={outputRaggedRank:o},u=T.runKernel(Qp,i,p);return{outputNestedSplits:u.slice(0,u.length-1),outputDenseValues:u[u.length-1]}}var K2=N({raggedGather_:Cq});function wq(r,t,e){let o=v(r,\"starts\",\"raggedRange\"),n=v(t,\"limits\",\"raggedRange\",o.dtype),s=v(e,\"deltas\",\"raggedRange\",o.dtype),a={starts:o,limits:n,deltas:s},i=T.runKernel(Zp,a);return{rtNestedSplits:i[0],rtDenseValues:i[1]}}var q2=N({raggedRange_:wq});function Sq(r,t,e,o,n){let s=v(r,\"shape\",\"raggedTensorToTensor\",\"int32\"),a=v(t,\"values\",\"raggedTensorToTensor\"),i=v(e,\"defaultValue\",\"raggedTensorToTensor\",a.dtype),p=o.map((l,m)=>v(l,`tensors${m}`,\"raggedTensorToTensor\",\"int32\")),u={shape:s,values:a,defaultValue:i,rowPartitionTensors:p},c={rowPartitionTypes:n};return T.runKernel(Jp,u,c)}var j2=N({raggedTensorToTensor_:Sq});function Iq(r,t,e){wt(r);let o=He(r),n=null;if(e==null||e===\"float32\")n=new Float32Array(o);else if(e===\"int32\")n=new Int32Array(o);else if(e===\"bool\")n=new Uint8Array(o);else throw new Error(`Unknown data type ${e}`);for(let s=0;sm1,createVideoElement:()=>Oq,encodeStrings:()=>f1,expectArrayBuffersEqual:()=>Pq,expectArraysClose:()=>Rq,expectArraysEqual:()=>Aq,expectNumbersClose:()=>d1,expectPromiseToFail:()=>Dq,expectValuesInRange:()=>Fq,play:()=>Mq,testEpsilon:()=>Bd});var Eq=.001,m1=.1;function Rq(r,t,e){return e==null&&(e=Bd()),jw(r,t,(o,n)=>Xw(o,n,e))}function Bd(){return T.backend.floatPrecision()===32?Eq:m1}function jw(r,t,e){let o=!0;if((Ot(r)||Ot(t))&&(o=!1),Ot(r)&&Ot(t)&&(o=!0),o){let a=r.constructor.name,i=t.constructor.name;if(a!==i)throw new Error(`Arrays are of different type. Actual: ${a}. Expected: ${i}`)}if(Array.isArray(r)&&Array.isArray(t)){let a=ir(r),i=ir(t);if(!Cr(a,i))throw new Error(`Arrays have different shapes. Actual: [${a}]. Expected: [${i}]`)}let n=Ot(r)?r:Ps(r),s=Ot(t)?t:Ps(t);if(n.length!==s.length)throw new Error(`Arrays have different lengths actual: ${n.length} vs expected: ${s.length}.\nActual: ${n}.\nExpected: ${s}.`);for(let a=0;at.fail(),()=>t()),typeof expect!=\"undefined\"&&expect().nothing()}function Aq(r,t){let e=typeof t==\"string\"||typeof t==\"number\"||typeof t==\"boolean\"?[t]:t;return Vo(r)||Vo(r[0])||Vo(t)||Vo(t[0])?jw(r,e,(o,n)=>o==n):jw(r,t,(o,n)=>Xw(o,n,0))}function d1(r,t,e){if(e==null&&(e=Bd()),!Xw(r,t,e))throw new Error(`Numbers differ: actual === ${r}, expected === ${t}`);typeof expect!=\"undefined\"&&expect().nothing()}function Xw(r,t,e){return!isFinite(r)&&!isFinite(t)?!0:!(isNaN(r)||isNaN(t)||Math.abs(r-t)>e)}function Fq(r,t,e){for(let o=0;oe)throw new Error(`Value out of range:${r[o]} low: ${t}, high: ${e}`)}function Pq(r,t){let e=new Float32Array(r),o=new Float32Array(t);if(e.length!==o.length)throw new Error(`Expected ArrayBuffer to be of length ${o.length}, but it was ${e.length}`);for(let n=0;n{t.addEventListener(\"loadeddata\",o=>e(t)),t.load()})}async function Mq(r){await r.play(),\"requestVideoFrameCallback\"in r&&await new Promise(t=>{r.requestVideoFrameCallback(t)})}var Zu=class{constructor(t,e,o,n,s){this.mean=t,this.stdDev=e,this.dtype=o,this.nextVal=NaN,this.truncated=n,this.truncated&&(this.upper=this.mean+this.stdDev*2,this.lower=this.mean-this.stdDev*2);let a=s||Math.random();this.random=Wd.alea(a.toString())}nextValue(){if(!isNaN(this.nextVal)){let n=this.nextVal;return this.nextVal=NaN,n}let t,e,o=!1;for(;!o;){let n,s,a;do n=2*this.random()-1,s=2*this.random()-1,a=n*n+s*s;while(a>=1||a===0);let i=Math.sqrt(-2*Math.log(a)/a);t=this.mean+this.stdDev*n*i,e=this.mean+this.stdDev*s*i,(!this.truncated||this.isValidTruncated(t))&&(o=!0)}return(!this.truncated||this.isValidTruncated(e))&&(this.nextVal=this.convertValue(e)),this.convertValue(t)}convertValue(t){return this.dtype==null||this.dtype===\"float32\"?t:Math.round(t)}isValidTruncated(t){return t<=this.upper&&t>=this.lower}},zd=class{constructor(t,e,o,n){this.alpha=t,this.beta=1/e,this.dtype=o;let s=n||Math.random();this.randu=Wd.alea(s.toString()),this.randn=new Zu(0,1,o,!1,this.randu()),t<1?this.d=t+2/3:this.d=t-1/3,this.c=1/Math.sqrt(9*this.d)}nextValue(){let t,e,o,n,s,a;for(;;){do n=this.randn.nextValue(),a=1+this.c*n;while(a<=0);if(a*=a*a,t=n*n,e=1-.331*t*t,o=.5*t+this.d*(1-a+Math.log(a)),s=this.randu(),sthis.dtype==null||this.dtype===\"float32\",this.min=t,this.range=e-t,this.dtype=o,n==null&&(n=Math.random()),typeof n==\"number\"&&(n=n.toString()),!this.canReturnFloat()&&this.range<=1)throw new Error(`The difference between ${t} - ${e} <= 1 and dtype is not float`);this.random=Wd.alea(n)}convertValue(t){return this.canReturnFloat()?t:Math.round(t)}nextValue(){return this.convertValue(this.min+this.range*this.random())}};function Lq(r,t,e=1,o=\"float32\",n){if(wt(r),e==null&&(e=1),o==null&&(o=\"float32\"),o!==\"float32\"&&o!==\"int32\")throw new Error(`Unsupported data type ${o}`);let s=new zd(t,e,o,n),a=me(r,o);for(let i=0;i`Error in reverse1D: x must be rank 1 but got rank ${t.rank}.`),mo(t,0)}var C1=N({reverse1d_:jq});function Xq(r,t){let e=v(r,\"x\",\"reverse\");return $(e.rank===2,()=>`Error in reverse2D: x must be rank 2 but got rank ${e.rank}.`),mo(e,t)}var w1=N({reverse2d_:Xq});function Yq(r,t){let e=v(r,\"x\",\"reverse\");return $(e.rank===3,()=>`Error in reverse3D: x must be rank 3 but got rank ${e.rank}.`),mo(e,t)}var S1=N({reverse3d_:Yq});function Qq(r,t){let e=v(r,\"x\",\"reverse\");return $(e.rank===4,()=>`Error in reverse4D: x must be rank 4 but got rank ${e.rank}.`),mo(e,t)}var I1=N({reverse4d_:Qq});function Zq(r){let e={x:v(r,\"x\",\"round\")};return T.runKernel(ls,e)}var Hd=N({round_:Zq});function Jq(r){let e={x:v(r,\"x\",\"rsqrt\",\"float32\")};return T.runKernel(ms,e)}var v1=N({rsqrt_:Jq});function e6(r){let e={x:v(r,\"x\",\"selu\")};return T.runKernel(gs,e)}var k1=N({selu_:e6});function t6(r,t,e,o,n,s=[1,1],a=\"NHWC\"){let i=v(r,\"x\",\"separableConv2d\"),p=v(t,\"depthwiseFilter\",\"separableConv2d\"),u=v(e,\"pointwiseFilter\",\"separableConv2d\"),c=i,l=!1;if(i.rank===3&&(l=!0,c=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),a===\"NCHW\")throw new Error(\"separableConv2d currently does not support dataFormat NCHW; only NHWC is supported\");$(c.rank===4,()=>`Error in separableConv2d: input must be rank 4, but got rank ${c.rank}.`),$(p.rank===4,()=>`Error in separableConv2d: depthwise filter must be rank 4, but got rank ${p.rank}.`),$(u.rank===4,()=>`Error in separableConv2d: pointwise filter must be rank 4, but got rank ${p.rank}.`),$(u.shape[0]===1,()=>`Error in separableConv2d: the first dimension of pointwise filter must be 1, but got ${u.shape[0]}.`),$(u.shape[1]===1,()=>`Error in separableConv2d: the second dimension of pointwise filter must be 1, but got ${u.shape[1]}.`);let m=p.shape[2],d=p.shape[3];$(u.shape[2]===m*d,()=>`Error in separableConv2d: the third dimension of pointwise filter must be ${m*d}, but got ${u.shape[2]}.`);let f=lc(c,p,o,n,a,s),g=uu(f,u,1,\"valid\",a);return l?W(g,[g.shape[1],g.shape[2],g.shape[3]]):g}var N1=N({separableConv2d_:t6});async function r6(r,t){let e=v(r,\"x\",\"setdiff1d\"),o=v(t,\"y\",\"setdiff1d\");$(e.dtype===o.dtype,()=>`x and y should have the same dtype, but got x (${e.dtype}) and y (${o.dtype}).`),$(e.rank===1,()=>`x should be 1D tensor, but got x (${e.shape}).`),$(o.rank===1,()=>`y should be 1D tensor, but got y (${o.shape}).`);let n=await e.data(),s=await o.data(),a=new Set(s),i=0;for(let c=0;c`slice1d expects a rank-1 tensor, but got a rank-${o.rank} tensor`),Xe(o,[t],[e])}var R1=N({slice1d_:a6});function i6(r,t,e){let o=v(r,\"x\",\"slice2d\");return $(o.rank===2,()=>`slice2d expects a rank-2 tensor, but got a rank-${o.rank} tensor`),Xe(o,t,e)}var D1=N({slice2d_:i6});function u6(r,t,e){let o=v(r,\"x\",\"slice3d\");return $(o.rank===3,()=>`slice3d expects a rank-3 tensor, but got a rank-${o.rank} tensor`),Xe(o,t,e)}var A1=N({slice3d_:u6});function p6(r,t,e){let o=v(r,\"x\",\"slice4d\");return $(o.rank===4,()=>`slice4d expects a rank-4 tensor, but got a rank-${o.rank} tensor`),Xe(o,t,e)}var F1=N({slice4d_:p6});function c6(r,t=-1){let e=v(r,\"logits\",\"softmax\",\"float32\");if(t===-1&&(t=e.rank-1),t!==e.rank-1)throw Error(`Softmax along a non-last dimension is not yet supported. Logits was rank ${e.rank} and dim was ${t}`);let o={logits:e},n={dim:t};return T.runKernel(vs,o,n)}var P1=N({softmax_:c6});function l6(r){$(r.dtype===\"complex64\",()=>`The dtype for tf.spectral.fft() must be complex64 but got ${r.dtype}.`);let t={input:r};return T.runKernel(Wi,t)}var fc=N({fft_:l6});function m6(r){$(r.dtype===\"complex64\",()=>`The dtype for tf.spectral.ifft() must be complex64 but got ${r.dtype}.`);let t={input:r};return T.runKernel(Ui,t)}var Ju=N({ifft_:m6});function d6(r){let t=r.shape[r.shape.length-1],e=r.size/t,o;if(t<=2){let n=W(r,[e,t]);o=Ju(n)}else{let n=[e,2*(t-1)],s=W(ci(r),[e,t]),a=W(lu(r),[e,t]),i=mo(Xe(s,[0,1],[e,t-2]),1),p=se(mo(Xe(a,[0,1],[e,t-2]),1),ke(-1)),u=bt([s,i],1),c=bt([a,p],1),l=W(Er(u,c),[n[0],n[1]]);o=Ju(l)}if(o=ci(o),r.rank===3&&r.shape[0]!==0){let n=o,s=r.shape[0];o=W(o,[s,o.shape[0]/s,o.shape[1]]),n.dispose()}return o}var Kd=N({irfft_:d6});function f6(r,t,e=0){let n={x:v(r,\"x\",\"split\")},s={numOrSizeSplits:t,axis:e};return T.runKernel(xa,n,s)}var li=N({split_:f6});function h6(r,t){$(r.dtype===\"float32\",()=>`The dtype for rfft() must be real value but got ${r.dtype}`);let e=r.shape[r.shape.length-1],o=r.size/e,n;if(t!=null&&t0),h=r.shape.map(g=>g);h[r.shape.length-1]=t,n=Xe(r,f,h),e=t}else if(t!=null&&t>e){let f=r.shape.map(h=>h);f[r.shape.length-1]=t-e,n=bt([r,Gr(f)],r.shape.length-1),e=t}else n=r;let s=Ht(n),a=W(Er(n,s),[o,e]),i=fc(a),p=Math.floor(e/2)+1,u=ci(i),c=lu(i),l=li(u,[p,e-p],u.shape.length-1),m=li(c,[p,e-p],c.shape.length-1),d=n.shape.slice();return d[n.shape.length-1]=p,W(Er(l[0],m[0]),d)}var hc=N({rfft_:h6});function g6(r,t){let e=v(r,\"a\",\"squaredDifference\"),o=v(t,\"b\",\"squaredDifference\");[e,o]=Oe(e,o),rt(e.shape,o.shape);let n={a:e,b:o},s={};return T.runKernel(Ns,n,s)}var qd=N({squaredDifference_:g6});function x6(r,t){let e=v(r,\"x\",\"squeeze\",\"string_or_numeric\");return W(e,JC(e.shape,t).newShape)}var gc=N({squeeze_:x6});function y6(r,t=0){let e=si(r,\"tensors\",\"stack\",\"string_or_numeric\");$(e.length>=1,()=>\"Pass at least one tensor to tf.stack\"),e.length>0&&$(t<=e[0].rank,()=>\"Axis must be <= rank of the tensor\");let o=e,n={axis:t};return T.runKernel(la,o,n)}var kr=N({stack_:y6});function b6(r,t=0){let o={x:v(r,\"x\",\"step\")},n={alpha:t};return T.runKernel(So,o,n)}var jd=N({step_:b6});function C6(r,t,e,o,n=0,s=0,a=0,i=0,p=0){let c={x:v(r,\"x\",\"stridedSlice\",\"string_or_numeric\")},l={begin:t,end:e,strides:o,beginMask:n,endMask:s,ellipsisMask:a,newAxisMask:i,shrinkAxisMask:p};return T.runKernel(Ts,c,l)}var O1=N({stridedSlice_:C6});function w6(r){let e={x:v(r,\"x\",\"tan\",\"float32\")};return T.runKernel($s,e)}var M1=N({tan_:w6});function tr(r,t){io(r);let e=ir(r,t);if(e.length!==1)throw new Error(\"tensor1d() requires values to be a flat/TypedArray\");return Sr(r,null,e,t)}function fu(r,t,e){if(io(r),t!=null&&t.length!==2)throw new Error(\"tensor2d() requires shape to have two numbers\");let o=ir(r,e);if(o.length!==2&&o.length!==1)throw new Error(\"tensor2d() requires values to be number[][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor2d() requires shape to be provided when `values` are a flat/TypedArray\");return Sr(r,t,o,e)}function Xd(r,t,e){if(io(r),t!=null&&t.length!==3)throw new Error(\"tensor3d() requires shape to have three numbers\");let o=ir(r,e);if(o.length!==3&&o.length!==1)throw new Error(\"tensor3d() requires values to be number[][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor3d() requires shape to be provided when `values` are a flat array\");return Sr(r,t,o,e)}function L1(r,t,e){if(io(r),t!=null&&t.length!==4)throw new Error(\"tensor4d() requires shape to have four numbers\");let o=ir(r,e);if(o.length!==4&&o.length!==1)throw new Error(\"tensor4d() requires values to be number[][][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor4d() requires shape to be provided when `values` are a flat array\");return Sr(r,t,o,e)}function B1(r,t,e){if(io(r),t!=null&&t.length!==5)throw new Error(\"tensor5d() requires shape to have five numbers\");let o=ir(r,e);if(o.length!==5&&o.length!==1)throw new Error(\"tensor5d() requires values to be number[][][][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor5d() requires shape to be provided when `values` are a flat array\");return Sr(r,t,o,e)}function z1(r,t,e){if(io(r),t!=null&&t.length!==6)throw new Error(\"tensor6d() requires shape to have six numbers\");let o=ir(r,e);if(o.length!==6&&o.length!==1)throw new Error(\"tensor6d() requires values to be number[][][][][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor6d() requires shape to be provided when `values` are a flat array\");return t=t||o,Sr(r,t,o,e)}var hu={};qe(hu,{calculateShapes:()=>V1,validateInput:()=>xc,validateUpdateShape:()=>Yw});function Yw(r,t,e){let o=t.rank>1?t.shape[t.rank-1]:1,n=t.rank>1?t.rank-1:1,s=`Must have updates.shape = indices.shape[:batchDim] + shape[sliceDim:], got updates.shape: ${e.shape}, indices.shape: ${t.shape}, shape: ${r}, sliceDim: ${o}, and batchDim: ${n}.`;if(e.rank1?t.shape[o-1]:1,s=e.length,a=1;for(let l=n;l= 0 but got ${t}`);if(t>n)throw new Error(`'k' passed to topk() must be <= the last dimension (${n}) but got ${t}`);let s={x:o},a={k:t,sorted:e},[i,p]=T.runKernel(Rs,s,a);return{values:i,indices:p}}var U1=N({topk_:I6});function v6(r,t=0,e=1,o,n){if(wt(r),o!=null&&o===\"bool\")throw new Error(\"Unsupported data type $ { dtype }\");let s=new Zu(t,e,o,!0,n),a=me(r,o);for(let i=0;i0,()=>\"The input tensor must be at least 1D\");let o={x:e},n={axis:t},[s,a]=T.runKernel(Zi,o,n);return{values:s,indices:a}}var H1=N({unique_:k6});function N6(r,t,e){let o=v(r,\"x\",\"unsortedSegmentSum\"),n=v(t,\"segmentIds\",\"unsortedSegmentSum\",\"int32\");$(qa(e),()=>\"numSegments must be of dtype int\");let s={x:o,segmentIds:n},a={numSegments:e};return T.runKernel(Ji,s,a)}var K1=N({unsortedSegmentSum_:N6});function T6(r,t=0){let e=v(r,\"x\",\"unstack\",\"string_or_numeric\");$(t>=-e.shape.length&&t`Axis = ${t} is not in [-${e.shape.length}, ${e.shape.length})`);let o={value:e},n={axis:t};return T.runKernel(wa,o,n)}var fo=N({unstack_:T6});function q1(r,t){return $l(r,t,\"right\")}function j1(r,t=!0,e,o){return T.makeVariable(r,t,e,o)}function Yd(r,t){let e=[];for(let s=0;s0,()=>\"mask cannot be scalar\"),yt(i.slice(s,s+a),n.shape,\"mask's shape must match the first K dimensions of tensor's shape,\");let p=1;for(let h=s;hi).reverse()),$(o.rank===t.length,()=>`Error in transpose: rank of input ${o.rank} must match length of perm ${t}.`),t.forEach(a=>{$(a>=0&&a`All entries in 'perm' must be between 0 and ${o.rank-1} but got ${t}`)}),o.rank<=1)return o.clone();let n={x:o},s={perm:t};return o.dtype===\"complex64\"?De(()=>{let a=ci(o),i=lu(o);return a=T.runKernel(co,{x:a},s),i=T.runKernel(co,{x:i},s),e&&(i=cr(i)),Er(a,i)}):T.runKernel(co,n,s)}var yc=N({transpose_:R6});function D6(r,t,e,o,n=!0){let s=v(r,\"v\",\"movingAverage\"),a=v(t,\"x\",\"movingAverage\"),i=v(e,\"decay\",\"movingAverage\");Cw(s,a),$(Cr(s.shape,a.shape),()=>\"Shape mismatch in v and x\");let p=ke(1),u=Te(p,i),c=se(Te(a,s),u);if(n){$(o!=null,()=>\"When using zeroDebias: true, step is required.\");let l=v(o,\"step\",\"movingAverage\");c=je(c,Te(p,ui(i,l)))}return Ce(s,c)}var A6=N({movingAverage_:D6});function F6(r,t,e){wt(e);let o=v(r,\"indices\",\"scatterND\",\"int32\"),n=v(t,\"updates\",\"scatterND\");xc(n,o,e);let s={indices:o,updates:n},a={shape:e};return T.runKernel(ds,s,a)}var P6=N({scatterND_:F6});function X1(r,t,e,o){if(r.dtype!==\"int32\")throw new Error(`tf.sparseToDense() expects the indices to be int32 type, but the dtype was ${r.dtype}.`);if(r.rank>2)throw new Error(`sparseIndices should be a scalar, vector, or matrix, but got shape ${r.shape}.`);let n=r.rank>0?r.shape[0]:1,s=r.rank>1?r.shape[1]:1;if(e.length!==s)throw new Error(`outputShape has incorrect number of elements:, ${e.length}, should be: ${s}.`);let a=t.size;if(!(t.rank===0||t.rank===1&&a===n))throw new Error(`sparseValues has incorrect shape ${t.shape}, should be [] or [${n}]`);if(t.dtype!==o.dtype)throw new Error(\"sparseValues.dtype must match defaultValues.dtype\")}function M6(r,t,e,o=0){wt(e);let n=v(r,\"sparseIndices\",\"sparseToDense\",\"int32\"),s=v(t,\"sparseValues\",\"sparseToDense\",\"string_or_numeric\"),a=v(o,\"defaultValue\",\"sparseToDense\",s.dtype);X1(n,s,e,a);let i={sparseIndices:n,sparseValues:s,defaultValue:a},p={outputShape:e};return T.runKernel(ks,i,p)}var L6=N({sparseToDense_:M6});function B6(r,t){let e=v(t,\"indices\",\"gatherND\",\"int32\"),n={params:v(r,\"x\",\"gatherND\",\"string_or_numeric\"),indices:e};return T.runKernel(kn,n)}var z6=N({gatherND_:B6});function Y1(r,t){if(t==null)return r.shape.slice();if(Cr(r.shape,t))return t;if(r.shape.length===t.length){let e=[];for(let o=0;o`x has to be a floating point tensor since it's going to be scaled, but got a ${n.dtype} tensor instead.`),$(t>=0&&t<1,()=>`rate must be a float in the range [0, 1), but got ${t}.`),t===0)return r instanceof ut?n.clone():n;let s=Y1(n,e),a=1-t,i=je(Sd(Ce(dc(s,0,1,\"float32\",o),a)),a);return se(n,i)}var W6=N({dropout_:V6});function Qw(r){return Math.floor(Math.pow(2,Math.ceil(Math.log(r)/Math.log(2))))}function Rl(r,t,e){let o=1-r%2,n=new Float32Array(r);for(let s=0;s1,()=>`inTopK() expects the predictions to be of rank 2 or higher, but got ${o.rank}`),$(o.rank-1===n.rank,()=>`predictions rank should be 1 larger than targets rank, but got predictions rank ${o.rank} and targets rank ${n.rank}`),yt(o.shape.slice(0,o.shape.length-1),n.shape,\"predictions's shape should be align with the targets' shape, except the last dimension.\");let s=o.shape[o.shape.length-1];$(e>0&&e<=s,()=>`'k' passed to inTopK() must be > 0 && <= the predictions last dimension (${s}), but got ${e}`);let a=await o.data(),i=await n.data(),[p,u]=[a.length/s,s],c=ew(\"bool\",p);for(let l=0;lg.value-h.value),c[l]=0;for(let h=0;hZ1,depthwiseConv2d:()=>tN,matMul:()=>rN});function H6(r,t,e,o,n,s=\"NHWC\",a){let i=r;r.rank===3&&(i=W(r,[1,r.shape[0],r.shape[1],r.shape[2]]));let p=t;p.rank===3&&(p=W(t,[1,t.shape[0],t.shape[1],t.shape[2]])),$(i.rank===4,()=>`Error in conv2dDerFilter: input must be rank 4, but got shape ${i.shape}.`),$(p.rank===4,()=>`Error in conv2dDerFilter: dy must be rank 4, but got shape ${p.shape}.`),$(e.length===4,()=>`Error in conv2dDerFilter: filterShape must be length 4, but got ${e}.`);let u=s===\"NHWC\"?i.shape[3]:i.shape[1],c=s===\"NHWC\"?p.shape[3]:p.shape[1];$(u===e[2],()=>`Error in conv2dDerFilter: depth of input ${u}) must match input depth in filter (${e[2]}.`),$(c===e[3],()=>`Error in conv2dDerFilter: depth of dy (${c}) must match output depth for filter (${e[3]}).`),Bt(\"conv2dDerFilter\",n,a);let l={x:i,dy:p},m={strides:o,pad:n,dataFormat:s,dimRoundingMode:a,filterShape:e};return T.runKernel(Oi,l,m)}var Q1=N({conv2DBackpropFilter_:H6});function ep(r,t,e){if(e==null||e===\"linear\")return r;if(e===\"relu\")return se(r,jd(t));throw new Error(`Cannot compute gradient for fused activation ${e}.`)}function tp(r,t){let e=t,o=yd(r.shape,t.shape);return o.length>0&&(e=ot(e,o)),W(e,r.shape)}function rp(r,t,e,o){if(t===\"linear\")return r;if(t===\"relu\")return du(r);if(t===\"elu\")return Cd(r);if(t===\"relu6\")return Gd(r);if(t===\"prelu\")return Md(r,e);if(t===\"leakyrelu\")return kd(r,o);if(t===\"sigmoid\")return $a(r);throw new Error(`Unknown fused activation ${t}.`)}var op=(r,t)=>!(r>0)||t===\"linear\";function K6({x:r,filter:t,strides:e,pad:o,dataFormat:n=\"NHWC\",dilations:s=[1,1],dimRoundingMode:a,bias:i,activation:p=\"linear\",preluActivationWeights:u,leakyreluAlpha:c}){if(p=p||\"linear\",op(T.state.gradientDepth,p)===!1){$(n===\"NHWC\",()=>`Error in fused conv2d: got dataFormat of ${n} but only NHWC is currently supported for the case of gradient depth is 0 and the activation is not linear.`);let _=uu(r,t,e,o,n,s,a);return i!=null&&(_=Ce(_,i)),rp(_,p,u,c)}let l=v(r,\"x\",\"conv2d\",\"float32\"),m=v(t,\"filter\",\"conv2d\",\"float32\"),d=l,f=!1;l.rank===3&&(f=!0,d=W(l,[1,l.shape[0],l.shape[1],l.shape[2]])),$(d.rank===4,()=>`Error in fused conv2d: input must be rank 4, but got rank ${d.rank}.`),$(m.rank===4,()=>`Error in fused conv2d: filter must be rank 4, but got rank ${m.rank}.`),Bt(\"fused conv2d\",o,a);let h=n===\"NHWC\"?d.shape[3]:d.shape[1];$(m.shape[2]===h,()=>`Error in conv2d: depth of input (${h}) must match input depth for filter ${m.shape[2]}.`),$(xr(e,s),()=>`Error in conv2D: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`);let g=Hu(d.shape,m.shape,e,s,o,a),x;i!=null&&(x=v(i,\"bias\",\"fused conv2d\"),[x]=Oe(x,l),n===\"NHWC\"?rt(g.outShape,x.shape):($(x.shape.length<=1,()=>`Error in fused conv2d: only supports scalar or 1-D Tensor bias for NCHW format but got the bias of rank-${x.shape.length}.`),$(x.shape.length===0||x.shape[0]===g.outChannels||x.shape[0]===1,()=>`Error in fused conv2d: bias shape (${x.shape}) is not compatible with the number of output channels (${g.outChannels})`)));let b;if(u!=null){let _=u.shape;if($(_.length<=1||_.length===3,()=>`Error in fused conv2d: only supports scalar, 1-D Tensor or 3-D Tensor PReLU activation weights but got a tensor of rank-${_.length}.`),_.length===1)$(_[0]===1||_[0]===g.outChannels,()=>`Error in fused conv2d: PReLU activation weights (${_}) is not compatible with the number of output channels (${g.outChannels}).`);else if(_.length===3)try{rt(_,g.outShape)}catch(E){let R=`Error in fused conv2d: PReLU activation weights (${_}) is not compatible with the output shape of the conv2d (${g.outShape}).`;throw Error(R)}b=v(u,\"prelu weights\",\"fused conv2d\")}let C=(_,E)=>{$(n===\"NHWC\",()=>`Error in gradient of fused conv2D: got dataFormat of ${n} but only NHWC is currently supported.`);let[R,D,P,O]=E,M=ep(_,P,p);$(Gu(s),()=>`Error in gradient of fused conv2D: dilation rates greater than 1 are not yet supported in gradients. Got dilations '${s}'`);let L=xd(D.shape,M,R,e,o),B=Q1(D,M,R.shape,e,o),z=[L,B];if(O!=null){let U=tp(O,M);z.push(U)}return z},S={x:d,filter:m,bias:x,preluActivationWeights:b},k={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a,activation:p,leakyreluAlpha:c};return i==null?vr((E,R,D)=>{let P=T.runKernel(vo,S,k);return D([R,E,P]),f&&(P=W(P,[P.shape[1],P.shape[2],P.shape[3]])),{value:P,gradFunc:C}})(d,m):vr((E,R,D,P)=>{let O=T.runKernel(vo,S,k);return P([R,E,O,D]),f&&(O=W(O,[O.shape[1],O.shape[2],O.shape[3]])),{value:O,gradFunc:C}})(d,m,x)}var Z1=N({fusedConv2d_:K6});function q6(r,t,e,o,n,s=[1,1],a){let i=r;r.rank===3&&(i=W(r,[1,r.shape[0],r.shape[1],r.shape[2]]));let p=t;p.rank===3&&(p=W(t,[1,t.shape[0],t.shape[1],t.shape[2]]));let u={x:i,dy:p},c={strides:o,pad:n,dimRoundingMode:a,dilations:s,filterShape:e};return T.runKernel(Mi,u,c)}var J1=N({depthwiseConv2dNativeBackpropFilter_:q6});function j6(r,t,e,o,n,s=[1,1],a){let i=t,p=!1;t.rank===3&&(p=!0,i=W(t,[1,t.shape[0],t.shape[1],t.shape[2]]));let u={dy:i,filter:e},c={strides:o,pad:n,dimRoundingMode:a,dilations:s,inputShape:r},l=T.runKernel(Li,u,c);return p?W(l,[l.shape[1],l.shape[2],l.shape[3]]):l}var eN=N({depthwiseConv2dNativeBackpropInput_:j6});function X6({x:r,filter:t,strides:e,pad:o,dataFormat:n=\"NHWC\",dilations:s=[1,1],dimRoundingMode:a,bias:i,activation:p=\"linear\",preluActivationWeights:u,leakyreluAlpha:c}){if(op(T.state.gradientDepth,p)===!1){let k=lc(r,t,e,o,n,s,a);return i!=null&&(k=Ce(k,i)),rp(k,p,u,c)}let l=v(r,\"x\",\"depthwiseConv2d\",\"float32\"),m=v(t,\"filter\",\"depthwiseConv2d\",\"float32\"),d=l,f=!1;l.rank===3&&(f=!0,d=W(l,[1,l.shape[0],l.shape[1],l.shape[2]])),$(d.rank===4,()=>`Error in fused depthwiseConv2d: input must be rank 4, but got rank ${d.rank}.`),$(m.rank===4,()=>`Error in fused depthwiseConv2d: filter must be rank 4, but got rank ${m.rank}.`),$(d.shape[3]===m.shape[2],()=>`Error in fused depthwiseConv2d: number of input channels (${d.shape[3]}) must match the inChannels dimension in filter ${m.shape[2]}.`),s==null&&(s=[1,1]),$(xr(e,s),()=>`Error in fused depthwiseConv2d: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`),Bt(\"fused depthwiseConv2d\",o,a);let h=Hu(d.shape,m.shape,e,s,o,a,!0),g;i!=null&&(g=v(i,\"bias\",\"fused conv2d\"),[g]=Oe(g,l),rt(h.outShape,g.shape));let x;u!=null&&(x=v(u,\"prelu weights\",\"fused depthwiseConv2d\"));let b=(k,_)=>{$(Gu(s),()=>`Error in gradient of fused depthwiseConv2d: dilation rates greater than 1 are not yet supported. Got dilations '${s}'`);let[E,R,D,P]=_,O=ep(k,D,p),M=eN(R.shape,O,E,e,o,s,a),L=J1(R,O,E.shape,e,o,s,a);if(P!=null){let B=tp(g,O);return[M,L,B]}return[M,L]},C={x:d,filter:m,bias:g,preluActivationWeights:x},S={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a,activation:p,leakyreluAlpha:c};return i==null?vr((_,E,R)=>{let D=T.runKernel(ko,C,S);return R([E,_,D]),f&&(D=W(D,[D.shape[1],D.shape[2],D.shape[3]])),{value:D,gradFunc:b}})(d,m):vr((_,E,R,D)=>{let P=T.runKernel(ko,C,S);return D([E,_,P,R]),f&&(P=W(P,[P.shape[1],P.shape[2],P.shape[3]])),{value:P,gradFunc:b}})(d,m,g)}var tN=N({fusedDepthwiseConv2d_:X6});function Y6({a:r,b:t,transposeA:e=!1,transposeB:o=!1,bias:n,activation:s=\"linear\",preluActivationWeights:a,leakyreluAlpha:i=.2}){if(op(T.state.gradientDepth,s)===!1){let O=Ze(r,t,e,o);return n!=null&&(O=Ce(O,n)),rp(O,s,a,i)}let p=v(r,\"a\",\"fused matMul\"),u=v(t,\"b\",\"fused matMul\");[p,u]=Oe(p,u);let c=e?p.shape[p.rank-2]:p.shape[p.rank-1],l=o?u.shape[u.rank-1]:u.shape[u.rank-2],m=e?p.shape[p.rank-1]:p.shape[p.rank-2],d=o?u.shape[u.rank-2]:u.shape[u.rank-1],f=p.shape.slice(0,-2),h=u.shape.slice(0,-2),g=He(f),x=He(h);$(c===l,()=>`Error in fused matMul: inner shapes (${c}) and (${l}) of Tensors with shapes ${p.shape} and ${u.shape} and transposeA=${e} and transposeB=${o} must match.`);let C=rt(p.shape.slice(0,-2),u.shape.slice(0,-2)).concat([m,d]),S=e?W(p,[g,c,m]):W(p,[g,m,c]),k=o?W(u,[x,d,l]):W(u,[x,l,d]),_;n!=null&&(_=v(n,\"bias\",\"fused matMul\"),[_]=Oe(_,p),rt(C,_.shape));let E;a!=null&&(E=v(a,\"prelu weights\",\"fused matMul\"));let R=(O,M)=>{let[L,B,z,U]=M,j=ep(W(O,z.shape),z,s),q,Y;if(!e&&!o?(q=Ze(j,B,!1,!0),Y=Ze(L,j,!0,!1)):!e&&o?(q=Ze(j,B,!1,!1),Y=Ze(j,L,!0,!1)):e&&!o?(q=Ze(B,j,!1,!0),Y=Ze(L,j,!1,!1)):(q=Ze(B,j,!0,!0),Y=Ze(j,L,!0,!0)),n!=null){let J=tp(U,j);return[q,Y,J]}else return[q,Y]},D={a:S,b:k,bias:_,preluActivationWeights:E},P={transposeA:e,transposeB:o,activation:s,leakyreluAlpha:i};return n==null?vr((M,L,B)=>{let z=T.runKernel(Io,D,P);return B([M,L,z]),{value:W(z,C),gradFunc:R}})(S,k):vr((M,L,B,z)=>{let U=T.runKernel(Io,D,P);return z([M,L,U,B]),{value:W(U,C),gradFunc:R}})(S,k,_)}var rN=N({fusedMatMul_:Y6});function Q6(r){return Rl(r,.54,.46)}var oN=N({hammingWindow_:Q6});function Z6(r){return Rl(r,.5,.5)}var Zd=N({hannWindow_:Z6});function J6(r,t,e,o=!1,n=0){let s=0,a=[];for(;s+t<=r.size;)a.push(Xe(r,s,t)),s+=e;if(o)for(;s`Error in cropAndResize: image must be rank 4,but got rank ${a.rank}.`),$(i.rank===2&&i.shape[1]===4,()=>`Error in cropAndResize: boxes must be have size [${u},4] but had shape ${i.shape}.`),$(p.rank===1&&p.shape[0]===u,()=>`Error in cropAndResize: boxInd must be have size [${u}] but had shape ${i.shape}.`),$(o.length===2,()=>`Error in cropAndResize: cropSize must be of length 2, but got length ${o.length}.`),$(o[0]>=1&&o[1]>=1,()=>`cropSize must be atleast [1,1], but was ${o}`),$(n===\"bilinear\"||n===\"nearest\",()=>`method must be bilinear or nearest, but was ${n}`);let c={image:a,boxes:i,boxInd:p},l={method:n,extrapolationValue:s,cropSize:o};return T.runKernel(ln,c,l)}var sN=N({cropAndResize_:tj});function rj(r){let t=v(r,\"image\",\"flipLeftRight\",\"float32\");$(t.rank===4,()=>`Error in flipLeftRight: image must be rank 4,but got rank ${t.rank}.`);let e={image:t};return T.runKernel(wn,e,{})}var aN=N({flipLeftRight_:rj});function oj(r){let t=v(r,\"image\",\"grayscaleToRGB\"),e=t.rank-1,o=t.shape[e];$(t.rank>=2,()=>`Error in grayscaleToRGB: images must be at least rank 2, but got rank ${t.rank}.`),$(o===1,()=>`Error in grayscaleToRGB: last dimension of a grayscale image should be size 1, but got size ${o}.`);let n=new Array(t.rank);return n.fill(1,0,e),n[e]=3,cu(t,n)}var iN=N({grayscaleToRGB_:oj});function nj(r){let t=v(r,\"image\",\"RGBToGrayscale\"),e=t.rank-1,o=t.shape[e];$(t.rank>=2,()=>`Error in RGBToGrayscale: images must be at least rank 2, but got rank ${t.rank}.`),$(o===3,()=>`Error in RGBToGrayscale: last dimension of an RGB image should be size 3, but got size ${o}.`);let n=t.dtype,s=We(t,\"float32\"),a=tr([.2989,.587,.114]),i;switch(t.rank){case 2:i=pu(\"ij,j->i\",s,a);break;case 3:i=pu(\"ijk,k->ij\",s,a);break;case 4:i=pu(\"ijkl,l->ijk\",s,a);break;case 5:i=pu(\"ijklm,m->ijkl\",s,a);break;case 6:i=pu(\"ijklmn,n->ijklm\",s,a);break;default:throw new Error(\"Not a valid tensor rank.\")}return i=Ms(i,-1),We(i,n)}var uN=N({rgbToGrayscale_:nj});function sj(r,t,e=0,o=.5){let n=v(r,\"image\",\"rotateWithOffset\",\"float32\");$(n.rank===4,()=>`Error in rotateWithOffset: image must be rank 4,but got rank ${n.rank}.`);let s={image:n},a={radians:t,fillValue:e,center:o};return T.runKernel(As,s,a)}var pN=N({rotateWithOffset_:sj});function Eo(r,t,e,o,n,s){o==null&&(o=.5),n==null&&(n=Number.NEGATIVE_INFINITY),s==null&&(s=0);let a=r.shape[0];return e=Math.min(e,a),$(0<=o&&o<=1,()=>`iouThreshold must be in [0, 1], but was '${o}'`),$(r.rank===2,()=>`boxes must be a 2D tensor, but was of rank '${r.rank}'`),$(r.shape[1]===4,()=>`boxes must have 4 columns, but 2nd dimension was ${r.shape[1]}`),$(t.rank===1,()=>\"scores must be a 1D tensor\"),$(t.shape[0]===a,()=>`scores has incompatible shape with boxes. Expected ${a}, but was ${t.shape[0]}`),$(0<=s&&s<=1,()=>`softNmsSigma must be in [0, 1], but was '${s}'`),{maxOutputSize:e,iouThreshold:o,scoreThreshold:n,softNmsSigma:s}}function aj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY){let s=v(r,\"boxes\",\"nonMaxSuppression\",\"float32\"),a=v(t,\"scores\",\"nonMaxSuppression\",\"float32\"),i=Eo(s,a,e,o,n);e=i.maxOutputSize,o=i.iouThreshold,n=i.scoreThreshold;let p={maxOutputSize:e,iouThreshold:o,scoreThreshold:n};return T.runKernel(Zn,{boxes:s,scores:a},p)}var cN=N({nonMaxSuppression_:aj});function lN(r,t,e){let o=ij(r,t,e),n=o<0?-(o+1):o;r.splice(n,0,t)}function ij(r,t,e){return pj(r,t,e||uj)}function uj(r,t){return r>t?1:r>>1);let i=e(t,r[s]);i>0?o=s+1:(n=s,a=!i)}return a?o:-o-1}function ef(r,t,e,o,n){return Jw(r,t,e,o,n,0)}function tf(r,t,e,o,n,s){return Jw(r,t,e,o,n,0,!1,s,!0)}function rf(r,t,e,o,n,s){return Jw(r,t,e,o,n,s,!0)}function Jw(r,t,e,o,n,s,a=!1,i=!1,p=!1){let u=[];for(let g=0;gn&&u.push({score:t[g],boxIndex:g,suppressBeginIndex:0});u.sort(mN);let c=s>0?-.5/s:0,l=[],m=[];for(;l.length0;){let g=u.pop(),{score:x,boxIndex:b,suppressBeginIndex:C}=g;if(x=C;--k){let _=cj(r,b,l[k]);if(_>=o){S=!0;break}if(g.score=g.score*lj(o,c,_),g.score<=n)break}g.suppressBeginIndex=l.length,S||(g.score===x?(l.push(b),m.push(g.score)):g.score>n&&lN(u,g,mN))}let d=l.length,f=e-d;i&&f>0&&(l.push(...new Array(f).fill(0)),m.push(...new Array(f).fill(0)));let h={selectedIndices:l};return a&&(h.selectedScores=m),p&&(h.validOutputs=d),h}function cj(r,t,e){let o=r.subarray(t*4,t*4+4),n=r.subarray(e*4,e*4+4),s=Math.min(o[0],o[2]),a=Math.min(o[1],o[3]),i=Math.max(o[0],o[2]),p=Math.max(o[1],o[3]),u=Math.min(n[0],n[2]),c=Math.min(n[1],n[3]),l=Math.max(n[0],n[2]),m=Math.max(n[1],n[3]),d=(i-s)*(p-a),f=(l-u)*(m-c);if(d<=0||f<=0)return 0;let h=Math.max(s,u),g=Math.max(a,c),x=Math.min(i,l),b=Math.min(p,m),C=Math.max(x-h,0)*Math.max(b-g,0);return C/(d+f-C)}function lj(r,t,e){let o=Math.exp(t*e*e);return e<=r?o:0}function mN(r,t){return r.score-t.score||r.score===t.score&&t.boxIndex-r.boxIndex}async function mj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY){let s=v(r,\"boxes\",\"nonMaxSuppressionAsync\"),a=v(t,\"scores\",\"nonMaxSuppressionAsync\"),i=Eo(s,a,e,o,n);e=i.maxOutputSize,o=i.iouThreshold,n=i.scoreThreshold;let p=await Promise.all([s.data(),a.data()]),u=p[0],c=p[1],{selectedIndices:l}=ef(u,c,e,o,n);return s!==r&&s.dispose(),a!==t&&a.dispose(),tr(l,\"int32\")}var dN=mj;function dj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=0){let a=v(r,\"boxes\",\"nonMaxSuppression\"),i=v(t,\"scores\",\"nonMaxSuppression\"),p=Eo(a,i,e,o,n,s);e=p.maxOutputSize,o=p.iouThreshold,n=p.scoreThreshold,s=p.softNmsSigma;let u={boxes:a,scores:i},c={maxOutputSize:e,iouThreshold:o,scoreThreshold:n,softNmsSigma:s},l=T.runKernel(Jn,u,c);return{selectedIndices:l[0],selectedScores:l[1]}}var fN=N({nonMaxSuppressionWithScore_:dj});async function fj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=0){let a=v(r,\"boxes\",\"nonMaxSuppressionAsync\"),i=v(t,\"scores\",\"nonMaxSuppressionAsync\"),p=Eo(a,i,e,o,n,s);e=p.maxOutputSize,o=p.iouThreshold,n=p.scoreThreshold,s=p.softNmsSigma;let u=await Promise.all([a.data(),i.data()]),c=u[0],l=u[1],{selectedIndices:m,selectedScores:d}=rf(c,l,e,o,n,s);return a!==r&&a.dispose(),i!==t&&i.dispose(),{selectedIndices:tr(m,\"int32\"),selectedScores:tr(d)}}var hN=fj;function hj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=!1){let a=v(r,\"boxes\",\"nonMaxSuppression\"),i=v(t,\"scores\",\"nonMaxSuppression\"),p=Eo(a,i,e,o,n,null),u=p.maxOutputSize,c=p.iouThreshold,l=p.scoreThreshold,m={boxes:a,scores:i},d={maxOutputSize:u,iouThreshold:c,scoreThreshold:l,padToMaxOutputSize:s},f=T.runKernel(Za,m,d);return{selectedIndices:f[0],validOutputs:f[1]}}var gN=N({nonMaxSuppressionPadded_:hj});async function gj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=!1){let a=v(r,\"boxes\",\"nonMaxSuppressionAsync\"),i=v(t,\"scores\",\"nonMaxSuppressionAsync\"),p=Eo(a,i,e,o,n,null),u=p.maxOutputSize,c=p.iouThreshold,l=p.scoreThreshold,[m,d]=await Promise.all([a.data(),i.data()]),{selectedIndices:f,validOutputs:h}=tf(m,d,u,c,l,s);return a!==r&&a.dispose(),i!==t&&i.dispose(),{selectedIndices:tr(f,\"int32\"),validOutputs:ke(h,\"int32\")}}var xN=gj;function xj(r,t,e=!1,o=!1){let n=v(r,\"images\",\"resizeBilinear\");$(n.rank===3||n.rank===4,()=>`Error in resizeBilinear: x must be rank 3 or 4, but got rank ${n.rank}.`),$(t.length===2,()=>`Error in resizeBilinear: new shape must 2D, but got shape ${t}.`),$(o===!1||e===!1,()=>\"Error in resizeBilinear: If halfPixelCenters is true, alignCorners must be false.\");let s=n,a=!1;n.rank===3&&(a=!0,s=W(n,[1,n.shape[0],n.shape[1],n.shape[2]]));let[]=t,i={images:s},p={alignCorners:e,halfPixelCenters:o,size:t},u=T.runKernel(us,i,p);return a?W(u,[u.shape[1],u.shape[2],u.shape[3]]):u}var yN=N({resizeBilinear_:xj});function yj(r,t,e=!1,o=!1){let n=v(r,\"images\",\"resizeNearestNeighbor\");$(n.rank===3||n.rank===4,()=>`Error in resizeNearestNeighbor: x must be rank 3 or 4, but got rank ${n.rank}.`),$(t.length===2,()=>`Error in resizeNearestNeighbor: new shape must 2D, but got shape ${t}.`),$(n.dtype===\"float32\"||n.dtype===\"int32\",()=>\"`images` must have `int32` or `float32` as dtype\"),$(o===!1||e===!1,()=>\"Error in resizeNearestNeighbor: If halfPixelCenters is true, alignCorners must be false.\");let s=n,a=!1;n.rank===3&&(a=!0,s=W(n,[1,n.shape[0],n.shape[1],n.shape[2]]));let[]=t,i={images:s},p={alignCorners:e,halfPixelCenters:o,size:t},u=T.runKernel(is,i,p);return a?W(u,[u.shape[1],u.shape[2],u.shape[3]]):u}var bN=N({resizeNearestNeighbor_:yj});function bj(r,t=\"binary\",e=!1,o=.5){let n=v(r,\"image\",\"threshold\"),s=.2989,a=.587,i=.114,p=n.shape[0]*n.shape[1],u=se(tr([o]),255),c,l,m,d;if($(n.rank===3,()=>`Error in threshold: image must be rank 3,but got rank ${n.rank}.`),$(n.shape[2]===3||n.shape[2]===1,()=>`Error in threshold: image color channel must be equal to 3 or 1but got ${n.shape[2]}.`),$(n.dtype===\"int32\"||n.dtype===\"float32\",()=>`Error in dtype: image dtype must be int32 or float32,but got dtype ${n.dtype}.`),$(t===\"otsu\"||t===\"binary\",()=>`Method must be binary or otsu, but was ${t}`),n.shape[2]===3){[c,l,m]=li(n,[1,1,1],-1);let g=se(c,s),x=se(l,a),b=se(m,i);d=Ce(Ce(g,x),b)}else d=r;if(t===\"otsu\"){let g=gd(We(Hd(d),\"int32\"),ur([]),256);u=Cj(g,p)}let f=e?mc(d,u):qu(d,u);return We(se(f,255),\"int32\")}function Cj(r,t){let e=tr([-1]),o=tr([0]),n=tr([0]),s,a,i,p,u,c;for(let l=0;l`Error in transform: image must be rank 4,but got rank ${a.rank}.`),$(i.rank===2&&(i.shape[0]===a.shape[0]||i.shape[0]===1)&&i.shape[1]===8,()=>\"Error in transform: Input transform should be batch x 8 or 1 x 8\"),$(s==null||s.length===2,()=>`Error in transform: outputShape must be [height, width] or null, but got ${s}.`);let p={image:a,transforms:i},u={interpolation:e,fillMode:o,fillValue:n,outputShape:s};return T.runKernel(Ds,p,u)}var wN=N({transform_:wj});function Sj(r,t,e){let o=v(r,\"a\",\"bandPart\");$(o.rank>=2,()=>`bandPart(): Rank must be at least 2, got ${o.rank}.`);let n=o.shape,[s,a]=o.shape.slice(-2),i,p;typeof t==\"number\"?($(t%1===0,()=>`bandPart(): numLower must be an integer, got ${t}.`),$(t<=s,()=>`bandPart(): numLower (${t}) must not be greater than the number of rows (${s}).`),i=v(t<0?s:t,\"numLower\",\"bandPart\")):($(t.dtype===\"int32\",()=>\"bandPart(): numLower's dtype must be an int32.\"),i=lo(_l(t,0),s,Yu(t,s))),typeof e==\"number\"?($(e%1===0,()=>`bandPart(): numUpper must be an integer, got ${e}.`),$(e<=a,()=>`bandPart(): numUpper (${e}) must not be greater than the number of columns (${a}).`),p=v(e<0?a:e,\"numUpper\",\"bandPart\")):($(e.dtype===\"int32\",()=>\"bandPart(): numUpper's dtype must be an int32.\"),p=lo(_l(e,0),a,Yu(e,a)));let u=W(mu(0,s,1,\"int32\"),[-1,1]),c=mu(0,a,1,\"int32\"),l=Te(u,c),m=ju(mc(l,i),vd(l,cr(p))),d=Gr([s,a],o.dtype);return W(kr(fo(W(o,[-1,s,a])).map(f=>lo(m,f,d))),n)}var SN=N({bandPart_:Sj});function Ij(r){let t;if(Array.isArray(r)){t=!1,$(r!=null&&r.length>0,()=>\"Gram-Schmidt process: input must not be null, undefined, or empty\");let n=r[0].shape[0];for(let s=1;s`Gram-Schmidt: Non-unique lengths found in the input vectors: (${r[s].shape[0]} vs. ${n})`)}else t=!0,r=li(r,r.shape[0],0).map(n=>gc(n,[0]));$(r.length<=r[0].shape[0],()=>`Gram-Schmidt: Number of vectors (${r.length}) exceeds number of dimensions (${r[0].shape[0]}).`);let e=[],o=r;for(let n=0;n{let s=o[n];if(n>0)for(let a=0;a=2,()=>`qr() requires input tensor to have a rank >= 2, but got rank ${r.rank}`),r.rank===2)return vN(r,t);{let e=r.shape.slice(0,r.shape.length-2).reduce((p,u)=>p*u),o=fo(W(r,[e,r.shape[r.shape.length-2],r.shape[r.shape.length-1]]),0),n=[],s=[];o.forEach(p=>{let[u,c]=vN(p,t);n.push(u),s.push(c)});let a=W(kr(n,0),r.shape),i=W(kr(s,0),r.shape);return[a,i]}}function vN(r,t=!1){return T.tidy(()=>{$(r.shape.length===2,()=>`qr2d() requires a 2D Tensor, but got a ${r.shape.length}D Tensor.`);let e=r.shape[0],o=r.shape[1],n=wd(e),s=Ur(r),a=fu([[1]],[1,1]),i=Ur(a),p=e>=o?o:e;for(let u=0;u{let d=Xe(s,[u,u],[e-u,1]),f=Ku(d),h=Xe(s,[u,u],[1,1]),g=lo(qu(h,0),fu([[-1]]),fu([[1]])),x=Te(h,se(g,f)),b=je(d,x);b.shape[0]===1?i=Ur(a):i=bt([a,Xe(b,[1,0],[b.shape[0]-1,b.shape[1]])],0);let C=cr(je(Ze(g,x),f)),S=Xe(s,[u,0],[e-u,o]),k=se(C,i),_=yc(i);if(u===0)s=Te(S,Ze(k,Ze(_,S)));else{let D=Te(S,Ze(k,Ze(_,S)));s=bt([Xe(s,[0,0],[u,o]),D],0)}let E=yc(k),R=Xe(n,[0,u],[e,n.shape[1]-u]);if(u===0)n=Te(R,Ze(Ze(R,i),E));else{let D=Te(R,Ze(Ze(R,i),E));n=bt([Xe(n,[0,0],[e,u]),D],1)}return[i,s,n]}),Mt([c,l,m])}return!t&&e>o&&(n=Xe(n,[0,0],[e,o]),s=Xe(s,[0,0],[o,o])),[n,s]})}var kN=N({qr_:vj});var Rt;(function(r){r[r.NONE=0]=\"NONE\",r[r.MEAN=1]=\"MEAN\",r[r.SUM=2]=\"SUM\",r[r.SUM_BY_NONZERO_WEIGHTS=3]=\"SUM_BY_NONZERO_WEIGHTS\"})(Rt||(Rt={}));function kj(r,t,e=Rt.SUM_BY_NONZERO_WEIGHTS){let o=v(r,\"losses\",\"computeWeightedLoss\"),n=null;t!=null&&(n=v(t,\"weights\",\"computeWeightedLoss\"));let s=n==null?o:se(o,n);if(e===Rt.NONE)return s;if(e===Rt.SUM)return ot(s);if(e===Rt.MEAN){if(n==null)return Xu(s);{let a=o.size/n.size,i=je(ot(s),ot(n));return a>1?je(i,ke(a)):i}}if(e===Rt.SUM_BY_NONZERO_WEIGHTS){if(n==null)return je(ot(s),ke(o.size));{let a=se(n,Da(o.shape)),i=We(ot(Pd(a,ke(0))),\"float32\");return je(ot(s),i)}}throw Error(`Unknown reduction: ${e}`)}var lr=N({computeWeightedLoss_:kj});function Nj(r,t,e,o=Rt.SUM_BY_NONZERO_WEIGHTS){let n=v(r,\"labels\",\"absoluteDifference\"),s=v(t,\"predictions\",\"absoluteDifference\"),a=null;e!=null&&(a=v(e,\"weights\",\"absoluteDifference\")),yt(n.shape,s.shape,\"Error in absoluteDifference: \");let i=Jt(Te(n,s));return lr(i,a,o)}var NN=N({absoluteDifference_:Nj});function Tj(r,t,e,o,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"labels\",\"cosineDistance\"),a=v(t,\"predictions\",\"cosineDistance\"),i=null;o!=null&&(i=v(o,\"weights\",\"cosineDistance\")),yt(s.shape,a.shape,\"Error in cosineDistance: \");let p=ke(1),u=Te(p,ot(se(s,a),e,!0));return lr(u,i,n)}var TN=N({cosineDistance_:Tj});function _j(r,t,e,o=Rt.SUM_BY_NONZERO_WEIGHTS){let n=v(r,\"labels\",\"hingeLoss\"),s=v(t,\"predictions\",\"hingeLoss\"),a=null;e!=null&&(a=v(e,\"weights\",\"hingeLoss\")),yt(n.shape,s.shape,\"Error in hingeLoss: \");let i=ke(1);n=Te(se(ke(2),n),i);let p=du(Te(i,se(n,s)));return lr(p,a,o)}var _N=N({hingeLoss_:_j});function $j(r,t,e,o=1,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"labels\",\"huberLoss\"),a=v(t,\"predictions\",\"huberLoss\"),i=null;e!=null&&(i=v(e,\"weights\",\"huberLoss\")),yt(s.shape,a.shape,\"Error in huberLoss: \");let p=ke(o),u=Jt(Te(a,s)),c=Yu(u,p),l=Te(u,c),m=Ce(se(ke(.5),er(c)),se(p,l));return lr(m,i,n)}var $N=N({huberLoss_:$j});function Ej(r,t,e,o=1e-7,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"labels\",\"logLoss\"),a=v(t,\"predictions\",\"logLoss\"),i=null;e!=null&&(i=v(e,\"weights\",\"logLoss\")),yt(s.shape,a.shape,\"Error in logLoss: \");let p=ke(1),u=ke(o),c=cr(se(s,pi(Ce(a,u)))),l=se(Te(p,s),pi(Ce(Te(p,a),u))),m=Te(c,l);return lr(m,i,n)}var EN=N({logLoss_:Ej});function Rj(r,t,e,o=Rt.SUM_BY_NONZERO_WEIGHTS){let n=v(r,\"labels\",\"meanSquaredError\"),s=v(t,\"predictions\",\"meanSquaredError\"),a=null;e!=null&&(a=v(e,\"weights\",\"meanSquaredError\")),yt(n.shape,s.shape,\"Error in meanSquaredError: \");let i=qd(n,s);return lr(i,a,o)}var RN=N({meanSquaredError_:Rj});function Dj(r,t){let e=v(r,\"labels\",\"sigmoidCrossEntropyWithLogits\"),o=v(t,\"logits\",\"sigmoidCrossEntropyWithLogits\");yt(e.shape,o.shape,\"Error in sigmoidCrossEntropyWithLogits: \");let n=du(o),s=se(o,e),a=Nd($o(cr(Jt(o))));return Ce(Te(n,s),a)}function Aj(r,t,e,o=0,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"multiClassLabels\",\"sigmoidCrossEntropy\"),a=v(t,\"logits\",\"sigmoidCrossEntropy\"),i=null;if(e!=null&&(i=v(e,\"weights\",\"sigmoidCrossEntropy\")),yt(s.shape,a.shape,\"Error in sigmoidCrossEntropy: \"),o>0){let u=ke(o),c=ke(1),l=ke(.5);s=Ce(se(s,Te(c,u)),se(l,u))}let p=Dj(s,a);return lr(p,i,n)}var DN=N({sigmoidCrossEntropy_:Aj});function Fj(r,t,e=-1){if(e===-1&&(e=t.rank-1),e!==t.rank-1)throw Error(`Softmax cross entropy along a non-last dimension is not yet supported. Labels / logits was rank ${t.rank} and dim was ${e}`);return vr((n,s,a)=>{let p=$d(s,[e],!0),u=Te(We(s,\"float32\"),p);a([n,u]);let c=cr(se(u,n));return{value:ot(c,[e]),gradFunc:(d,f)=>{let[h,g]=f,x=ii(d.shape,[e]);return[se(W(d,x),Te(We(h,\"float32\"),$o(g))),se(W(d,x),Te($o(g),We(h,\"float32\")))]}}})(r,t)}function Pj(r,t,e,o=0,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"onehotLabels\",\"softmaxCrossEntropy\"),a=v(t,\"logits\",\"softmaxCrossEntropy\"),i=null;if(e!=null&&(i=v(e,\"weights\",\"softmaxCrossEntropy\")),yt(s.shape,a.shape,\"Error in softmaxCrossEntropy: \"),o>0){let u=ke(o),c=ke(1),l=ke(s.shape[1]);s=Ce(se(s,Te(c,u)),je(u,l))}let p=Fj(s,a);return lr(p,i,n)}var AN=N({softmaxCrossEntropy_:Pj});function Oj(r,t,e,o){let n=v(r,\"indices\",\"sparseFillEmptyRows\",\"int32\"),s=v(t,\"values\",\"sparseFillEmptyRows\"),a=v(e,\"denseShape\",\"sparseFillEmptyRows\",\"int32\"),i=v(o,\"defaultValue\",\"sparseFillEmptyRows\",s.dtype);if(n.rank!==2)throw new Error(`Indices should be Tensor2D but received shape\n ${n.shape}`);if(s.rank!==1)throw new Error(`Values should be Tensor1D but received shape ${s.shape}`);if(a.rank!==1)throw new Error(`Dense shape should be Tensor1D but received shape ${a.shape}`);if(i.rank!==0)throw new Error(`Default value should be a scalar but received shape ${i.shape}`);let p={indices:n,values:s,denseShape:a,defaultValue:i},u=T.runKernel(ji,p);return{outputIndices:u[0],outputValues:u[1],emptyRowIndicator:u[2],reverseIndexMap:u[3]}}var FN=N({sparseFillEmptyRows_:Oj});function Mj(r,t,e){let o=v(r,\"inputIndices\",\"sparseReshape\",\"int32\"),n=v(t,\"inputShape\",\"sparseReshape\",\"int32\"),s=v(e,\"newShape\",\"sparseReshape\",\"int32\");if(o.rank!==2)throw new Error(`Input indices should be Tensor2D but received shape\n ${o.shape}`);if(n.rank!==1)throw new Error(`Input shape should be Tensor1D but received shape ${n.shape}`);if(s.rank!==1)throw new Error(`New shape should be Tensor1D but received shape ${s.shape}`);let a={inputIndices:o,inputShape:n,newShape:s},i=T.runKernel(ti,a);return{outputIndices:i[0],outputShape:i[1]}}var PN=N({sparseReshape_:Mj});function Lj(r,t,e){let o=v(r,\"data\",\"sparseSegmentMean\"),n=v(t,\"indices\",\"sparseSegmentMean\",\"int32\"),s=v(e,\"segmentIds\",\"sparseSegmentMean\",\"int32\");if(o.rank<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.rank!==1)throw new Error(`Indices should be Tensor1D but received shape\n ${n.shape}`);if(s.rank!==1)throw new Error(`Segment ids should be Tensor1D but received shape\n ${s.shape}`);let a={data:o,indices:n,segmentIds:s};return T.runKernel(ya,a)}var ON=N({sparseSegmentMean_:Lj});function Bj(r,t,e){let o=v(r,\"data\",\"sparseSegmentSum\"),n=v(t,\"indices\",\"sparseSegmentSum\",\"int32\"),s=v(e,\"segmentIds\",\"sparseSegmentSum\",\"int32\");if(o.rank<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.rank!==1)throw new Error(`Indices should be Tensor1D but received shape\n ${n.shape}`);if(s.rank!==1)throw new Error(`Segment ids should be Tensor1D but received shape\n ${s.shape}`);let a={data:o,indices:n,segmentIds:s};return T.runKernel(ba,a)}var MN=N({sparseSegmentSum_:Bj});function zj(r,t,e,o,n,s,a,i){let p=v(r,\"data\",\"stringNGrams\",\"string\");if(p.dtype!==\"string\")throw new Error(\"Data must be of datatype string\");if(p.shape.length!==1)throw new Error(`Data must be a vector, saw: ${p.shape}`);let u=v(t,\"dataSplits\",\"stringNGrams\");if(u.dtype!==\"int32\")throw new Error(\"Data splits must be of datatype int32\");let c={separator:e,nGramWidths:o,leftPad:n,rightPad:s,padWidth:a,preserveShortSequences:i},l={data:p,dataSplits:u},m=T.runKernel(Ca,l,c);return{nGrams:m[0],nGramsSplits:m[1]}}var LN=N({stringNGrams_:zj});function Vj(r,t,e=!0){let o=v(r,\"input\",\"stringSplit\",\"string\"),n=v(t,\"delimiter\",\"stringSplit\",\"string\");if(o.rank!==1)throw new Error(`Input should be Tensor1D but received shape ${o.shape}`);if(n.rank!==0)throw new Error(`Delimiter should be a scalar but received shape ${n.shape}`);let s={skipEmpty:e},a={input:o,delimiter:n},i=T.runKernel(Yi,a,s);return{indices:i[0],values:i[1],shape:i[2]}}var BN=N({stringSplit_:Vj});function Wj(r,t){let e=v(r,\"input\",\"stringToHashBucketFast\",\"string\"),o={numBuckets:t};if(t<=0)throw new Error(\"Number of buckets must be at least 1\");let n={input:e};return T.runKernel(Qi,n,o)}var zN=N({stringToHashBucketFast_:Wj});function Uj(r,t,e,o=!0){let n=v(r,\"input\",\"staticRegexReplace\",\"string\"),s={pattern:t,rewrite:e,replaceGlobal:o};return T.runKernel(Ou,{x:n},s)}var VN=N({staticRegexReplace_:Uj});var Gj={fft:fc,ifft:Ju,rfft:hc,irfft:Kd},Hj={hammingWindow:oN,hannWindow:Zd,frame:Jd,stft:nN},Kj={flipLeftRight:aN,grayscaleToRGB:iN,resizeNearestNeighbor:bN,resizeBilinear:yN,rgbToGrayscale:uN,rotateWithOffset:pN,cropAndResize:sN,nonMaxSuppression:cN,nonMaxSuppressionAsync:dN,nonMaxSuppressionWithScore:fN,nonMaxSuppressionWithScoreAsync:hN,nonMaxSuppressionPadded:gN,nonMaxSuppressionPaddedAsync:xN,threshold:CN,transform:wN},qj={bandPart:SN,gramSchmidt:IN,qr:kN},jj={absoluteDifference:NN,computeWeightedLoss:lr,cosineDistance:TN,hingeLoss:_N,huberLoss:$N,logLoss:EN,meanSquaredError:RN,sigmoidCrossEntropy:DN,softmaxCrossEntropy:AN},Xj={sparseFillEmptyRows:FN,sparseReshape:PN,sparseSegmentMean:ON,sparseSegmentSum:MN},Yj={stringNGrams:LN,stringSplit:BN,stringToHashBucketFast:zN,staticRegexReplace:VN};var WN={};qe(WN,{Serializable:()=>Dl,SerializationMap:()=>Fa,getRegisteredName:()=>Zj,registerClass:()=>tS});var Qj=new Map,eS=new Map,Dl=class{getClassName(){return this.constructor.className}static fromConfig(t,e){return new t(e)}},Fa=class{constructor(){this.classNameMap={}}static getMap(){return Fa.instance==null&&(Fa.instance=new Fa),Fa.instance}static register(t){Fa.getMap().classNameMap[t.className]=[t,t.fromConfig]}};function tS(r,t,e){$(r.className!=null,()=>\"Class being registered does not have the static className property defined.\"),$(typeof r.className==\"string\",()=>\"className is required to be a string, but got type \"+typeof r.className),$(r.className.length>0,()=>\"Class being registered has an empty-string as its className, which is disallowed.\"),typeof t==\"undefined\"&&(t=\"Custom\"),typeof e==\"undefined\"&&(e=r.className);let o=e,n=t+\">\"+o;return Fa.register(r),Qj.set(n,r),eS.set(r,n),r}function Zj(r){return eS.has(r)?eS.get(r):r.className}var Nr=class extends Dl{minimize(t,e=!1,o){let{value:n,grads:s}=this.computeGradients(t,o);if(o!=null){let a=o.map(i=>({name:i.name,tensor:s[i.name]}));this.applyGradients(a)}else this.applyGradients(s);return Mt(s),e?n:(n.dispose(),null)}get iterations(){return this.iterations_==null&&(this.iterations_=0),this.iterations_}incrementIterations(){this.iterations_=this.iterations+1}computeGradients(t,e){return zw(t,e)}dispose(){this.iterations_!=null&&Mt(this.iterations_)}async saveIterations(){return this.iterations_==null&&(this.iterations_=0),{name:\"iter\",tensor:ke(this.iterations_,\"int32\")}}async getWeights(){throw new Error(\"getWeights() is not implemented for this optimizer yet.\")}async setWeights(t){throw new Error(`setWeights() is not implemented for this optimizer class ${this.getClassName()}`)}async extractIterations(t){return this.iterations_=(await t[0].tensor.data())[0],t.slice(1)}};Object.defineProperty(Nr,Symbol.hasInstance,{value:r=>r.minimize!=null&&r.computeGradients!=null&&r.applyGradients!=null});var np=class extends Nr{static get className(){return\"Adadelta\"}constructor(t,e,o=null){super(),this.learningRate=t,this.rho=e,this.epsilon=o,this.accumulatedGrads=[],this.accumulatedUpdates=[],o==null&&(this.epsilon=T.backend.epsilon())}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o],a=!1;this.accumulatedGrads[n]==null&&(this.accumulatedGrads[n]={originalName:`${o}/accum_grad`,variable:De(()=>Ht(s).variable(a))}),this.accumulatedUpdates[n]==null&&(this.accumulatedUpdates[n]={originalName:`${o}/accum_var`,variable:De(()=>Ht(s).variable(a))});let i=Array.isArray(t)?t[n].tensor:t[o];if(i==null)return;let p=this.accumulatedGrads[n].variable,u=this.accumulatedUpdates[n].variable;De(()=>{let c=Ce(se(p,this.rho),se(er(i),1-this.rho)),l=se(je(Dr(Ce(u,this.epsilon)),Dr(Ce(p,this.epsilon))),i),m=Ce(se(u,this.rho),se(er(l),1-this.rho));p.assign(c),u.assign(m);let d=Ce(se(l,-this.learningRate),s);s.assign(d)})}),this.incrementIterations()}dispose(){this.accumulatedUpdates!=null&&(Mt(this.accumulatedGrads.map(t=>t.variable)),Mt(this.accumulatedUpdates.map(t=>t.variable)))}async getWeights(){let t=[...this.accumulatedGrads,...this.accumulatedUpdates];return[await this.saveIterations()].concat(t.map(e=>({name:e.originalName,tensor:e.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=t.length/2,o=!1;this.accumulatedGrads=t.slice(0,e).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.accumulatedUpdates=t.slice(e,e*2).map(n=>({originalName:n.name,variable:n.tensor.variable(o)}))}getConfig(){return{learningRate:this.learningRate,rho:this.rho,epsilon:this.epsilon}}static fromConfig(t,e){return new t(e.learningRate,e.rho,e.epsilon)}};var sp=class extends Nr{static get className(){return\"Adagrad\"}constructor(t,e=.1){super(),this.learningRate=t,this.initialAccumulatorValue=e,this.accumulatedGrads=[]}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o];this.accumulatedGrads[n]==null&&(this.accumulatedGrads[n]={originalName:`${o}/accumulator`,variable:De(()=>Ea(s.shape,this.initialAccumulatorValue).variable(!1))});let a=Array.isArray(t)?t[n].tensor:t[o];if(a==null)return;let i=this.accumulatedGrads[n].variable;De(()=>{let p=Ce(i,er(a));i.assign(p);let u=Ce(se(je(a,Dr(Ce(p,T.backend.epsilon()))),-this.learningRate),s);s.assign(u)})}),this.incrementIterations()}dispose(){this.accumulatedGrads!=null&&Mt(this.accumulatedGrads.map(t=>t.variable))}async getWeights(){return[await this.saveIterations()].concat(this.accumulatedGrads.map(t=>({name:t.originalName,tensor:t.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=!1;this.accumulatedGrads=t.map(o=>({originalName:o.name,variable:o.tensor.variable(e)}))}getConfig(){return{learningRate:this.learningRate,initialAccumulatorValue:this.initialAccumulatorValue}}static fromConfig(t,e){return new t(e.learningRate,e.initialAccumulatorValue)}};var ap=class extends Nr{static get className(){return\"Adam\"}constructor(t,e,o,n=null){super(),this.learningRate=t,this.beta1=e,this.beta2=o,this.epsilon=n,this.accumulatedFirstMoment=[],this.accumulatedSecondMoment=[],De(()=>{this.accBeta1=ke(e).variable(),this.accBeta2=ke(o).variable()}),n==null&&(this.epsilon=T.backend.epsilon())}applyGradients(t){let e=Array.isArray(t)?t.map(o=>o.name):Object.keys(t);De(()=>{let o=Te(1,this.accBeta1),n=Te(1,this.accBeta2);e.forEach((s,a)=>{let i=T.registeredVariables[s],p=!1;this.accumulatedFirstMoment[a]==null&&(this.accumulatedFirstMoment[a]={originalName:`${s}/m`,variable:De(()=>Ht(i).variable(p))}),this.accumulatedSecondMoment[a]==null&&(this.accumulatedSecondMoment[a]={originalName:`${s}/v`,variable:De(()=>Ht(i).variable(p))});let u=Array.isArray(t)?t[a].tensor:t[s];if(u==null)return;let c=this.accumulatedFirstMoment[a].variable,l=this.accumulatedSecondMoment[a].variable,m=Ce(se(c,this.beta1),se(u,1-this.beta1)),d=Ce(se(l,this.beta2),se(er(u),1-this.beta2)),f=je(m,o),h=je(d,n);c.assign(m),l.assign(d);let g=Ce(se(je(f,Ce(Dr(h),this.epsilon)),-this.learningRate),i);i.assign(g)}),this.accBeta1.assign(se(this.accBeta1,this.beta1)),this.accBeta2.assign(se(this.accBeta2,this.beta2))}),this.incrementIterations()}dispose(){this.accBeta1.dispose(),this.accBeta2.dispose(),this.accumulatedFirstMoment!=null&&Mt(this.accumulatedFirstMoment.map(t=>t.variable)),this.accumulatedSecondMoment!=null&&Mt(this.accumulatedSecondMoment.map(t=>t.variable))}async getWeights(){let t=[...this.accumulatedFirstMoment,...this.accumulatedSecondMoment];return[await this.saveIterations()].concat(t.map(e=>({name:e.originalName,tensor:e.variable})))}async setWeights(t){t=await this.extractIterations(t),De(()=>{this.accBeta1.assign(ui(this.beta1,this.iterations_+1)),this.accBeta2.assign(ui(this.beta2,this.iterations_+1))});let e=t.length/2,o=!1;this.accumulatedFirstMoment=t.slice(0,e).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.accumulatedSecondMoment=t.slice(e,e*2).map(n=>({originalName:n.name,variable:n.tensor.variable(o)}))}getConfig(){return{learningRate:this.learningRate,beta1:this.beta1,beta2:this.beta2,epsilon:this.epsilon}}static fromConfig(t,e){return new t(e.learningRate,e.beta1,e.beta2,e.epsilon)}};var ip=class extends Nr{static get className(){return\"Adamax\"}constructor(t,e,o,n=null,s=0){super(),this.learningRate=t,this.beta1=e,this.beta2=o,this.epsilon=n,this.decay=s,this.accumulatedFirstMoment=[],this.accumulatedWeightedInfNorm=[],De(()=>{this.iteration=ke(0).variable(),this.accBeta1=ke(e).variable()}),n==null&&(this.epsilon=T.backend.epsilon())}applyGradients(t){let e=Array.isArray(t)?t.map(o=>o.name):Object.keys(t);De(()=>{let o=Te(1,this.accBeta1),n=je(-this.learningRate,Ce(se(this.iteration,this.decay),1));e.forEach((s,a)=>{let i=T.registeredVariables[s],p=!1;this.accumulatedFirstMoment[a]==null&&(this.accumulatedFirstMoment[a]={originalName:`${s}/m`,variable:Ht(i).variable(p)}),this.accumulatedWeightedInfNorm[a]==null&&(this.accumulatedWeightedInfNorm[a]={originalName:`${s}/v`,variable:Ht(i).variable(p)});let u=Array.isArray(t)?t[a].tensor:t[s];if(u==null)return;let c=this.accumulatedFirstMoment[a].variable,l=this.accumulatedWeightedInfNorm[a].variable,m=Ce(se(c,this.beta1),se(u,1-this.beta1)),d=se(l,this.beta2),f=Jt(u),h=Fd(d,f);c.assign(m),l.assign(h);let g=Ce(se(je(n,o),je(m,Ce(h,this.epsilon))),i);i.assign(g)}),this.iteration.assign(Ce(this.iteration,1)),this.accBeta1.assign(se(this.accBeta1,this.beta1))}),this.incrementIterations()}dispose(){this.accBeta1.dispose(),this.iteration.dispose(),this.accumulatedFirstMoment!=null&&Mt(this.accumulatedFirstMoment.map(t=>t.variable)),this.accumulatedWeightedInfNorm!=null&&Mt(this.accumulatedWeightedInfNorm.map(t=>t.variable))}async getWeights(){throw new Error(\"getWeights() is not implemented for Adamax yet.\")}async setWeights(t){throw new Error(\"setWeights() is not implemented for Adamax yet.\")}getConfig(){return{learningRate:this.learningRate,beta1:this.beta1,beta2:this.beta2,epsilon:this.epsilon,decay:this.decay}}static fromConfig(t,e){return new t(e.learningRate,e.beta1,e.beta2,e.epsilon,e.decay)}};var mi=class extends Nr{static get className(){return\"SGD\"}constructor(t){super(),this.learningRate=t,this.setLearningRate(t)}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=Array.isArray(t)?t[n].tensor:t[o];if(s==null)return;let a=T.registeredVariables[o];De(()=>{let i=Ce(se(this.c,s),a);a.assign(i)})}),this.incrementIterations()}setLearningRate(t){this.learningRate=t,this.c!=null&&this.c.dispose(),this.c=Rr(ke(-t))}dispose(){this.c.dispose()}async getWeights(){return[await this.saveIterations()]}async setWeights(t){if(t=await this.extractIterations(t),t.length!==0)throw new Error(\"SGD optimizer does not have settable weights.\")}getConfig(){return{learningRate:this.learningRate}}static fromConfig(t,e){return new t(e.learningRate)}};var up=class extends mi{static get className(){return\"Momentum\"}constructor(t,e,o=!1){super(t),this.learningRate=t,this.momentum=e,this.useNesterov=o,this.accumulations=[],this.m=ke(this.momentum)}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o];this.accumulations[n]==null&&(this.accumulations[n]={originalName:`${o}/momentum`,variable:De(()=>Ht(s).variable(!1))});let a=this.accumulations[n].variable,i=Array.isArray(t)?t[n].tensor:t[o];i!=null&&De(()=>{let p,u=Ce(se(this.m,a),i);this.useNesterov?p=Ce(se(this.c,Ce(i,se(u,this.m))),s):p=Ce(se(this.c,u),s),a.assign(u),s.assign(p)})}),this.incrementIterations()}dispose(){this.m.dispose(),this.accumulations!=null&&Mt(this.accumulations.map(t=>t.variable))}setMomentum(t){this.momentum=t}async getWeights(){return[await this.saveIterations()].concat(this.accumulations.map(t=>({name:t.originalName,tensor:t.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=!1;this.accumulations=t.map(o=>({originalName:o.name,variable:o.tensor.variable(e)}))}getConfig(){return{learningRate:this.learningRate,momentum:this.momentum,useNesterov:this.useNesterov}}static fromConfig(t,e){return new t(e.learningRate,e.momentum,e.useNesterov)}};var pp=class extends Nr{static get className(){return\"RMSProp\"}constructor(t,e=.9,o=0,n=null,s=!1){if(super(),this.learningRate=t,this.decay=e,this.momentum=o,this.epsilon=n,this.accumulatedMeanSquares=[],this.accumulatedMoments=[],this.accumulatedMeanGrads=[],this.centered=s,n==null&&(this.epsilon=T.backend.epsilon()),t==null)throw new Error(\"learningRate for RMSPropOptimizer must be defined.\")}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o],a=!1;this.accumulatedMeanSquares[n]==null&&(this.accumulatedMeanSquares[n]={originalName:`${o}/rms`,variable:De(()=>Ht(s).variable(a))}),this.accumulatedMoments[n]==null&&(this.accumulatedMoments[n]={originalName:`${o}/momentum`,variable:De(()=>Ht(s).variable(a))}),this.accumulatedMeanGrads[n]==null&&this.centered&&(this.accumulatedMeanGrads[n]={originalName:`${o}/mg`,variable:De(()=>Ht(s).variable(a))});let i=Array.isArray(t)?t[n].tensor:t[o];if(i==null)return;let p=this.accumulatedMeanSquares[n].variable,u=this.accumulatedMoments[n].variable;De(()=>{let c=Ce(se(p,this.decay),se(er(i),1-this.decay));if(this.centered){let l=this.accumulatedMeanGrads[n].variable,m=Ce(se(l,this.decay),se(i,1-this.decay)),d=je(se(i,this.learningRate),Dr(Te(c,Ce(er(m),this.epsilon)))),f=Ce(se(u,this.momentum),d);p.assign(c),l.assign(m),u.assign(f);let h=Te(s,f);s.assign(h)}else{let l=Ce(se(p,this.decay),se(er(i),1-this.decay)),m=Ce(se(u,this.momentum),je(se(i,this.learningRate),Dr(Ce(l,this.epsilon))));p.assign(l),u.assign(m);let d=Te(s,m);s.assign(d)}})}),this.incrementIterations()}dispose(){this.accumulatedMeanSquares!=null&&Mt(this.accumulatedMeanSquares.map(t=>t.variable)),this.accumulatedMeanGrads!=null&&this.centered&&Mt(this.accumulatedMeanGrads.map(t=>t.variable)),this.accumulatedMoments!=null&&Mt(this.accumulatedMoments.map(t=>t.variable))}async getWeights(){let t=[...this.accumulatedMeanSquares,...this.accumulatedMoments];return this.centered&&t.push(...this.accumulatedMeanGrads),[await this.saveIterations()].concat(t.map(e=>({name:e.originalName,tensor:e.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=this.centered?t.length/3:t.length/2,o=!1;this.accumulatedMeanSquares=t.slice(0,e).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.accumulatedMoments=t.slice(e,e*2).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.centered&&(this.accumulatedMeanGrads=t.slice(e*2,e*3).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})))}getConfig(){return{learningRate:this.learningRate,decay:this.decay,momentum:this.momentum,epsilon:this.epsilon,centered:this.centered}}static fromConfig(t,e){return new t(e.learningRate,e.decay,e.momentum,e.epsilon,e.centered)}};var Jj=[np,sp,ap,ip,up,pp,mi];function UN(){for(let r of Jj)tS(r)}var fi={};qe(fi,{CompositeArrayBuffer:()=>jt,browserFiles:()=>HN,browserHTTPRequest:()=>jN,concatenateArrayBuffers:()=>ik,copyModel:()=>wk,decodeWeights:()=>ad,encodeWeights:()=>nk,fromMemory:()=>XN,fromMemorySync:()=>iS,getLoadHandlers:()=>lk,getModelArtifactsForJSON:()=>ic,getModelArtifactsForJSONSync:()=>_w,getModelArtifactsInfoForJSON:()=>va,getSaveHandlers:()=>ck,getWeightSpecs:()=>ud,http:()=>nf,isHTTPScheme:()=>of,listModels:()=>bk,loadWeights:()=>KN,moveModel:()=>Sk,registerLoadRouter:()=>pk,registerSaveRouter:()=>uk,removeModel:()=>Ck,weightsLoaderFactory:()=>sS,withSaveHandler:()=>YN,withSaveHandlerSync:()=>QN});var eX=\"model\",tX=\".json\",rX=\".weights.bin\";function GN(r){return new Promise(t=>setTimeout(t)).then(r)}var di=class{constructor(t){if(!A().getBool(\"IS_BROWSER\"))throw new Error(\"browserDownloads() cannot proceed because the current environment is not a browser.\");t.startsWith(di.URL_SCHEME)&&(t=t.slice(di.URL_SCHEME.length)),(t==null||t.length===0)&&(t=eX),this.modelJsonFileName=t+tX,this.weightDataFileName=t+rX}async save(t){if(typeof document==\"undefined\")throw new Error(\"Browser downloads are not supported in this environment since `document` is not present\");let e=jt.join(t.weightData),o=window.URL.createObjectURL(new Blob([e],{type:\"application/octet-stream\"}));if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserDownloads.save() does not support saving model topology in binary formats yet.\");{let n=[{paths:[\"./\"+this.weightDataFileName],weights:t.weightSpecs}],s=id(t,n),a=window.URL.createObjectURL(new Blob([JSON.stringify(s)],{type:\"application/json\"})),i=this.modelJsonAnchor==null?document.createElement(\"a\"):this.modelJsonAnchor;if(i.download=this.modelJsonFileName,i.href=a,await GN(()=>i.dispatchEvent(new MouseEvent(\"click\"))),t.weightData!=null){let p=this.weightDataAnchor==null?document.createElement(\"a\"):this.weightDataAnchor;p.download=this.weightDataFileName,p.href=o,await GN(()=>p.dispatchEvent(new MouseEvent(\"click\")))}return{modelArtifactsInfo:va(t)}}}};di.URL_SCHEME=\"downloads://\";var rS=class{constructor(t){if(t==null||t.length<1)throw new Error(`When calling browserFiles, at least 1 file is required, but received ${t}`);this.jsonFile=t[0],this.weightsFiles=t.slice(1)}async load(){return new Promise((t,e)=>{let o=new FileReader;o.onload=n=>{let s=JSON.parse(n.target.result),a=s.modelTopology;if(a==null){e(new Error(`modelTopology field is missing from file ${this.jsonFile.name}`));return}if(s.weightsManifest==null){e(new Error(`weightManifest field is missing from file ${this.jsonFile.name}`));return}if(this.weightsFiles.length===0){t({modelTopology:a});return}let p=ic(s,u=>this.loadWeights(u));t(p)},o.onerror=n=>e(`Failed to read model topology and weights manifest JSON from file '${this.jsonFile.name}'. BrowserFiles supports loading Keras-style tf.Model artifacts only.`),o.readAsText(this.jsonFile)})}loadWeights(t){let e=[],o=[];for(let a of t)e.push(...a.weights),o.push(...a.paths);let n=this.checkManifestAndWeightFiles(t),s=o.map(a=>this.loadWeightsFile(a,n[a]));return Promise.all(s).then(a=>[e,a])}loadWeightsFile(t,e){return new Promise((o,n)=>{let s=new FileReader;s.onload=a=>{let i=a.target.result;o(i)},s.onerror=a=>n(`Failed to weights data from file of path '${t}'.`),s.readAsArrayBuffer(e)})}checkManifestAndWeightFiles(t){let e=[],o=this.weightsFiles.map(s=>Tw(s.name)),n={};for(let s of t)s.paths.forEach(a=>{let i=Tw(a);if(e.indexOf(i)!==-1)throw new Error(`Duplicate file basename found in weights manifest: '${i}'`);if(e.push(i),o.indexOf(i)===-1)throw new Error(`Weight file with basename '${i}' is not provided.`);n[a]=this.weightsFiles[o.indexOf(i)]});if(e.length!==this.weightsFiles.length)throw new Error(`Mismatch in the number of files in weights manifest (${e.length}) and the number of weight files provided (${this.weightsFiles.length}).`);return n}},oX=r=>A().getBool(\"IS_BROWSER\")&&!Array.isArray(r)&&r.startsWith(di.URL_SCHEME)?nX(r.slice(di.URL_SCHEME.length)):null;ft.registerSaveRouter(oX);function nX(r=\"model\"){return new di(r)}function HN(r){return new rS(r)}function oS(r,t,e,o){a(r),e=e==null?0:e,o=o==null?1:o,i(e,o);let n=0,s=p=>(p.then(u=>{let c=e+ ++n/r.length*(o-e);return t(c),u}),p);function a(p){$(p!=null&&Array.isArray(p)&&p.length>0,()=>\"promises must be a none empty array\")}function i(p,u){$(p>=0&&p<=1,()=>`Progress fraction must be in range [0, 1], but got startFraction ${p}`),$(u>=0&&u<=1,()=>`Progress fraction must be in range [0, 1], but got endFraction ${u}`),$(u>=p,()=>`startFraction must be no more than endFraction, but got startFraction ${p} and endFraction ${u}`)}return Promise.all(r.map(s))}async function nS(r,t){t==null&&(t={});let e=t.fetchFunc==null?A().platform.fetch:t.fetchFunc,o=r.map(l=>e(l,t.requestInit,{isBinary:!0})),n=0,s=.5,i=(t.onProgress==null?await Promise.all(o):await oS(o,t.onProgress,n,s)).map(l=>l.arrayBuffer()),p=.5,u=1;return t.onProgress==null?await Promise.all(i):await oS(i,t.onProgress,p,u)}async function KN(r,t=\"\",e,o){return sS(a=>nS(a,{requestInit:o}))(r,t,e)}function sS(r){return async(t,e=\"\",o)=>{let n=t.map(()=>!1),s={},a=o!=null?o.map(()=>!1):[],i=[];if(t.forEach((d,f)=>{let h=0;d.weights.forEach(g=>{let x=\"quantization\"in g?g.quantization.dtype:g.dtype,b=Il[x]*He(g.shape),C=()=>{n[f]=!0,s[f]==null&&(s[f]=[]),s[f].push({manifestEntry:g,groupOffset:h,sizeBytes:b})};o!=null?o.forEach((S,k)=>{S===g.name&&(C(),a[k]=!0)}):C(),i.push(g.name),h+=b})}),!a.every(d=>d)){let d=o.filter((f,h)=>!a[h]);throw new Error(`Could not find weights in manifest with names: ${d.join(\", \")}. \nManifest JSON has weights with names: ${i.join(\", \")}.`)}let p=n.reduce((d,f,h)=>(f&&d.push(h),d),[]),u=[];p.forEach(d=>{t[d].paths.forEach(f=>{let h=e+(e.endsWith(\"/\")?\"\":\"/\")+f;u.push(h)})});let c=await r(u),l={},m=0;return p.forEach(d=>{let f=t[d].paths.length,h=new jt(c.slice(m,m+f));s[d].forEach(x=>{let b=h.slice(x.groupOffset,x.groupOffset+x.sizeBytes),C=ad(b,[x.manifestEntry]);for(let S in C)l[S]=C[S]}),m+=f}),l}}var sX=\"application/octet-stream\",aX=\"application/json\",Al=class{constructor(t,e){if(this.DEFAULT_METHOD=\"POST\",e==null&&(e={}),this.weightPathPrefix=e.weightPathPrefix,this.onProgress=e.onProgress,this.weightUrlConverter=e.weightUrlConverter,e.fetchFunc!=null?($(typeof e.fetchFunc==\"function\",()=>\"Must pass a function that matches the signature of `fetch` (see https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API)\"),this.fetch=e.fetchFunc):this.fetch=A().platform.fetch,$(t!=null&&t.length>0,()=>\"URL path for http must not be null, undefined or empty.\"),Array.isArray(t)&&$(t.length===2,()=>`URL paths for http must have a length of 2, (actual length is ${t.length}).`),this.path=t,e.requestInit!=null&&e.requestInit.body!=null)throw new Error(\"requestInit is expected to have no pre-existing body, but has one.\");this.requestInit=e.requestInit||{}}async save(t){if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserHTTPRequest.save() does not support saving model topology in binary formats yet.\");let e=Object.assign({method:this.DEFAULT_METHOD},this.requestInit);e.body=new FormData;let o=[{paths:[\"./model.weights.bin\"],weights:t.weightSpecs}],n=id(t,o);if(e.body.append(\"model.json\",new Blob([JSON.stringify(n)],{type:aX}),\"model.json\"),t.weightData!=null){let a=jt.join(t.weightData);e.body.append(\"model.weights.bin\",new Blob([a],{type:sX}),\"model.weights.bin\")}let s=await this.fetch(this.path,e);if(s.ok)return{modelArtifactsInfo:va(t),responses:[s]};throw new Error(`BrowserHTTPRequest.save() failed due to HTTP response status ${s.status}.`)}async load(){let t=await this.fetch(this.path,this.requestInit);if(!t.ok)throw new Error(`Request to ${this.path} failed with status code ${t.status}. Please verify this URL points to the model JSON of the model to load.`);let e;try{e=await t.json()}catch(s){let a=`Failed to parse model JSON of response from ${this.path}.`;throw this.path.endsWith(\".pb\")?a+=\" Your path contains a .pb file extension. Support for .pb models have been removed in TensorFlow.js 1.0 in favor of .json models. You can re-convert your Python TensorFlow model using the TensorFlow.js 1.0 conversion scripts or you can convert your.pb models with the 'pb2json'NPM script in the tensorflow/tfjs-converter repository.\":a+=\" Please make sure the server is serving valid JSON for this request.\",new Error(a)}let o=e.modelTopology,n=e.weightsManifest;if(o==null&&n==null)throw new Error(`The JSON from HTTP path ${this.path} contains neither model topology or manifest for weights.`);return ic(e,s=>this.loadWeights(s))}async loadWeights(t){let e=Array.isArray(this.path)?this.path[1]:this.path,[o,n]=iX(e),s=this.weightPathPrefix||o,a=ud(t),i=[],p=[];for(let c of t)for(let l of c.paths)this.weightUrlConverter!=null?p.push(this.weightUrlConverter(l)):i.push(s+l+n);this.weightUrlConverter&&i.push(...await Promise.all(p));let u=await nS(i,{requestInit:this.requestInit,fetchFunc:this.fetch,onProgress:this.onProgress});return[a,u]}};Al.URL_SCHEME_REGEX=/^https?:\\/\\//;function iX(r){let t=r.lastIndexOf(\"/\"),e=r.lastIndexOf(\"?\"),o=r.substring(0,t),n=e>t?r.substring(e):\"\";return[o+\"/\",n]}function of(r){return r.match(Al.URL_SCHEME_REGEX)!=null}var qN=(r,t)=>{if(typeof fetch==\"undefined\"&&(t==null||t.fetchFunc==null))return null;{let e=!0;if(Array.isArray(r)?e=r.every(o=>of(o)):e=of(r),e)return nf(r,t)}return null};ft.registerSaveRouter(qN);ft.registerLoadRouter(qN);function nf(r,t){return new Al(r,t)}function jN(r,t){return nf(r,t)}var Fl=class{constructor(t){this.modelArtifacts=t}load(){return this.modelArtifacts}},sf=class{constructor(t){this.saveHandler=t}save(t){return this.saveHandler(t)}},aS=class{constructor(t){t.load&&(this.load=()=>Promise.resolve(t.load())),t.save&&(this.save=e=>Promise.resolve(t.save(e)))}};function XN(r,t,e,o){let n=arguments;return new aS(iS(...n))}function iS(r,t,e,o){return arguments.length===1?r.modelTopology!=null||r.weightSpecs!=null?new Fl(r):(console.warn(\"Please call tf.io.fromMemory() with only one argument. The argument should be of type ModelArtifacts. The multi-argument signature of tf.io.fromMemory() has been deprecated and will be removed in a future release.\"),new Fl({modelTopology:r})):(console.warn(\"Please call tf.io.fromMemory() with only one argument. The argument should be of type ModelArtifacts. The multi-argument signature of tf.io.fromMemory() has been deprecated and will be removed in a future release.\"),new Fl({modelTopology:r,weightSpecs:t,weightData:e,trainingConfig:o}))}function YN(r){return new sf(r)}function QN(r){return new sf(r)}var JN={};qe(JN,{confusionMatrix:()=>ZN});function uX(r,t,e){let o=v(r,\"labels\",\"confusionMatrix\"),n=v(t,\"predictions\",\"confusionMatrix\");$(e==null||e>0&&Number.isInteger(e),()=>`If provided, numClasses must be a positive integer, but got ${e}`),$(o.rank===1,()=>`Expected the rank of labels to be 1, but got ${o.rank}`),$(n.rank===1,()=>`Expected the rank of predictions to be 1, but got ${n.rank}`),$(o.shape[0]===n.shape[0],()=>`Mismatch in the number of examples: ${o.shape[0]} vs. ${n.shape[0]}. Labels and predictions should have the same number of elements.`),$(e>0&&Number.isInteger(e),()=>`numClasses is required to be a positive integer, but got ${e}`);let s=El(We(o,\"int32\"),e),a=El(We(n,\"int32\"),e),i=yc(s),p=Ze(i,a);return We(p,\"int32\")}var ZN=N({confusionMatrix_:uX});var oT={};qe(oT,{draw:()=>gX,fromPixels:()=>xX,fromPixelsAsync:()=>dX,toPixels:()=>hX});var cp,eT=!1;function tT(r,t=3){if(t>4)throw new Error(\"Cannot construct Tensor with more than 4 channels from pixels.\");if(r==null)throw new Error(\"pixels passed to tf.browser.fromPixels() can not be null\");let e=!1,o=!1,n=!1,s=!1,a=!1,i=!1;if(r.data instanceof Uint8Array)e=!0;else if(typeof ImageData!=\"undefined\"&&r instanceof ImageData)o=!0;else if(typeof HTMLVideoElement!=\"undefined\"&&r instanceof HTMLVideoElement)n=!0;else if(typeof HTMLImageElement!=\"undefined\"&&r instanceof HTMLImageElement)s=!0;else if(r.getContext!=null)a=!0;else if(typeof ImageBitmap!=\"undefined\"&&r instanceof ImageBitmap)i=!0;else throw new Error(`pixels passed to tf.browser.fromPixels() must be either an HTMLVideoElement, HTMLImageElement, HTMLCanvasElement, ImageData in browser, or OffscreenCanvas, ImageData in webworker or {data: Uint32Array, width: number, height: number}, but was ${r.constructor.name}`);if(tc(Mu,T.backendName)!=null){let f={pixels:r},h={numChannels:t};return T.runKernel(Mu,f,h)}let[u,c]=n?[r.videoWidth,r.videoHeight]:[r.width,r.height],l;if(a)l=r.getContext(\"2d\").getImageData(0,0,u,c).data;else if(o||e)l=r.data;else if(s||n||i){if(cp==null)if(typeof document==\"undefined\")if(typeof OffscreenCanvas!=\"undefined\"&&typeof OffscreenCanvasRenderingContext2D!=\"undefined\")cp=new OffscreenCanvas(1,1).getContext(\"2d\");else throw new Error(\"Cannot parse input in current context. Reason: OffscreenCanvas Context2D rendering is not supported.\");else cp=document.createElement(\"canvas\").getContext(\"2d\",{willReadFrequently:!0});cp.canvas.width=u,cp.canvas.height=c,cp.drawImage(r,0,0,u,c),l=cp.getImageData(0,0,u,c).data}let m;if(t===4)m=new Int32Array(l);else{let f=u*c;m=new Int32Array(f*t);for(let h=0;h4||t===2)throw new Error(`toPixels only supports depth of size 1, 3 or 4 but got ${t}`);if(r.dtype!==\"float32\"&&r.dtype!==\"int32\")throw new Error(`Unsupported type for toPixels: ${r.dtype}. Please use float32 or int32 tensors.`)}function fX(r){let t=(r==null?void 0:r.alpha)||1;if(t>1||t<0)throw new Error(`Alpha value ${t} is suppoed to be in range [0 - 1].`)}async function hX(r,t){let e=v(r,\"img\",\"toPixels\");if(!(r instanceof ut)){let u=e;e=We(u,\"int32\"),u.dispose()}rT(e);let[o,n]=e.shape.slice(0,2),s=e.rank===2?1:e.shape[2],a=await e.data(),i=e.dtype===\"float32\"?255:1,p=new Uint8ClampedArray(n*o*4);for(let u=0;u1)throw new Error(`Tensor values for a float32 Tensor must be in the range [0 - 1] but encountered ${d}.`)}else if(e.dtype===\"int32\"&&(d<0||d>255))throw new Error(`Tensor values for a int32 Tensor must be in the range [0 - 255] but encountered ${d}.`);s===1?(c[0]=d*i,c[1]=d*i,c[2]=d*i):c[m]=d*i}let l=u*4;p[l+0]=Math.round(c[0]),p[l+1]=Math.round(c[1]),p[l+2]=Math.round(c[2]),p[l+3]=Math.round(c[3])}if(t!=null){eT||tc(Pu,T.backendName)!=null&&(console.warn(\"tf.browser.toPixels is not efficient to draw tensor on canvas. Please try tf.browser.draw instead.\"),eT=!0),t.width=n,t.height=o;let u=t.getContext(\"2d\"),c=new ImageData(p,n,o);u.putImageData(c,0,0)}return e!==r&&e.dispose(),p}function gX(r,t,e){let o=v(r,\"img\",\"draw\");if(!(r instanceof ut)){let a=o;o=We(a,\"int32\"),a.dispose()}rT(o),fX(e==null?void 0:e.imageOptions);let n={image:o},s={canvas:t,options:e};T.runKernel(Pu,n,s)}var xX=N({fromPixels_:tT});var af={};qe(af,{prepareAndValidate:()=>nT});function nT(r,t){let e=r.shape.length,o=t.shape.length;if(e<1)throw new Error(`tf.gatherND() expects the input to be rank 1 or higher, but the rank was ${e}.`);if(o<1)throw new Error(`tf.gatherND() expects the indices to be rank 1 or higher, but the rank was ${o}.`);if(t.dtype!==\"int32\")throw new Error(`tf.gatherND() expects the indices to be int32 type, but the dtype was ${t.dtype}.`);if(t.shape[o-1]>e)throw new Error(`index innermost dimension length must be <= tensor rank; saw: ${t.shape[o-1]} vs. ${e}`);if(He(r.shape)===0)throw new Error(`Requested more than 0 entries, but input is empty. Input shape: ${r.shape}.`);let n=t.shape,s=n[n.length-1],a=1;for(let l=0;ll/u),1].slice(0,s);return[p,a,u,c]}var ct={};qe(ct,{assertParamsValid:()=>bX,computeFlatOffset:()=>vX,computeOutShape:()=>wX,getNormalizedAxes:()=>SX,isSliceContinous:()=>IX,maskToAxes:()=>CX,parseSliceParams:()=>kX,sliceInfo:()=>NX,startForAxis:()=>mT,startIndicesWithElidedDims:()=>pT,stopForAxis:()=>dT,stopIndicesWithElidedDims:()=>cT,stridesForAxis:()=>lT,stridesWithElidedDims:()=>aT});var uS=-2,yX=-1;function bX(r,t,e){let o=r.shape.length;$(o===t.length,()=>`Error in slice${o}D: Length of begin ${t} must match the rank of the array (${o}).`),$(o===e.length,()=>`Error in slice${o}D: Length of size ${e} must match the rank of the array (${o}).`);for(let n=0;n`Error in slice${o}D: begin[${n}] + size[${n}] (${t[n]+e[n]}) would overflow input.shape[${n}] (${r.shape[n]})`)}function CX(r){let t=[],e=0;for(;r>0;)r&1&&t.push(e),r/=2,e++;return t}function wX(r,t,e){let o=[];for(let n=0;n0){let d=t[0],f=e+1;c=pT(a,d,f,o,r),l=cT(i,d,f,n,r),m=aT(s,d,f,r)}else for(let d=0;d-1)s[i]=0;else{let p=iT(t,e,i),u=o[p];r&1<-1)s[i]=Number.MAX_SAFE_INTEGER;else{let p=iT(t,e,i),u=o[p];r&1<0?a=Number.MIN_SAFE_INTEGER:a=Number.MAX_SAFE_INTEGER);let p=o[n];return a<0&&(a+=p),a=qp(0,a,p-1),a}function dT(r,t,e,o,n,s){let a=t[n],i=e[n]||1;(r&1<0?a=Number.MAX_SAFE_INTEGER:a=Number.MIN_SAFE_INTEGER);let p=o[n];return a<0&&(a+=p),i>0?a=qp(0,a,p):a=qp(-1,a,p-1),a}function IX(r,t,e){let o=e.length;for(let n=0;n1){o=n;break}for(let n=o+1;n0||e[n]!==r[n])return!1;return!0}function vX(r,t){let e=r.length>0?r[r.length-1]:1;for(let o=0;o{$(a!==-1,()=>\"slice() does not support negative begin indexing.\")});let s;return e==null?s=new Array(n).fill(-1):typeof e==\"number\"?s=[e,...new Array(n-1).fill(-1)]:e.lengtha>=0?a:($(a===-1,()=>`Negative size values should be exactly -1 but got ${a} for the slice() size at index ${i}.`),r.shape[i]-o[i])),[o,s]}function NX(r,t,e,o,n,s,a,i,p){let u;if(o==null?(u=new Array(t.length),u.fill(1)):u=o,a!=null&&a&a-1)throw new Error(\"Multiple ellipses in slice is not allowed.\");let c=!1,l={dims:u.length,numAddAxisAfterEllipsis:0,begin:t.slice(),end:e.slice(),strides:u.slice(),beginMask:n,endMask:s,ellipsisMask:a,newAxisMask:i,shrinkAxisMask:p};for(let C=0;C0?0:-1,m.strides[C]>0?k:k-1];if(S&&m.strides[C]<=0)throw Error(\"only stride 1 allowed on non-range indexing.\");h=h&&m.strides[C]===1;let R=!!(m.beginMask&1<=k)throw Error(`slice index ${m.begin[C]} of dimension ${C} out of bounds.`)}else m.begin[C]=sT(m.begin[C],0,m.strides[C],k,_,E),m.end[C]=sT(m.end[C],1,m.strides[C],k,_,E);let O=m.strides[C]===1&&m.begin[C]===0&&m.end[C]===k;d=d&&O,f=f&&(C===0&&m.strides[C]===1||O)}else d=d&&m.strides[C]===1&&R,f=f&&(C===0&&m.strides[C]===1||R);let D,P=!1;if(m.beginValid&&m.endValid?(D=m.end[C]-m.begin[C],P=!0):S?(D=1,P=!0):R&&k>=0&&(m.strides[C]<0?D=-k:D=k,P=!0),P){let O;D===0||D<0!=m.strides[C]<0?O=0:O=Math.trunc(D/m.strides[C])+(D%m.strides[C]!==0?1:0),g.push(O)}else g.push(-1)}for(let C=0;C=0?x.push(g[S]):S===uS&&x.push(1)}return{finalShapeSparse:x.filter((C,S)=>m.finalShapeGatherIndices[S]!==uS),finalShape:x,isIdentity:d,sliceDim0:f,isSimpleSlice:h,begin:m.begin,end:m.end,strides:m.strides}}function TX(r,t){t.beginMask=0,t.endMask=0,t.shrinkAxisMask=0;let e=0;t.beginValid=r.begin!=null,t.endValid=r.end!=null,t.begin=new Array(t.dims),t.end=new Array(t.dims),t.strides=new Array(t.dims),t.finalShapeGatherIndices=[],t.finalShapeGatherIndicesSparse=[],t.inputShapeGatherIndicesSparse=new Array(t.dims);for(let o=0;o0?s[t]:s[t+1&1];{let a=r<0?o+r:r;return as[1]?s[1]:a}}var _X=\"4.11.0\";var Pl=class{static sgd(t){return new mi(t)}static momentum(t,e,o=!1){return new up(t,e,o)}static rmsprop(t,e=.9,o=0,n=null,s=!1){return new pp(t,e,o,n,s)}static adam(t=.001,e=.9,o=.999,n=null){return new ap(t,e,o,n)}static adadelta(t=.001,e=.95,o=null){return new np(t,e,o)}static adamax(t=.002,e=.9,o=.999,n=null,s=0){return new ip(t,e,o,n,s)}static adagrad(t,e=.1){return new sp(t,e)}};var TGe=Pl;var $X=(()=>typeof requestAnimationFrame!=\"undefined\"?requestAnimationFrame:typeof setImmediate!=\"undefined\"?setImmediate:r=>r())();function pS(){return new Promise(r=>$X(()=>r()))}var w={};qe(w,{ERF_A1:()=>KX,ERF_A2:()=>qX,ERF_A3:()=>jX,ERF_A4:()=>XX,ERF_A5:()=>YX,ERF_P:()=>HX,PARALLELIZE_THRESHOLD:()=>uf,RowPartitionType:()=>Pa,SELU_SCALE:()=>GX,SELU_SCALEALPHA:()=>UX,applyActivation:()=>rp,assertAndGetBroadcastShape:()=>rt,assertAxesAreInnerMostDims:()=>tK,assertParamsConsistent:()=>EX,assignToTypedArray:()=>r5,axesAreInnerMostDims:()=>Bw,calculateShapes:()=>V1,checkEinsumDimSizes:()=>u5,checkPadOnDimRoundingMode:()=>Bt,combineLocations:()=>x2,combineRaggedTensorToTensorShapes:()=>DX,complexWithEvenIndex:()=>JX,complexWithOddIndex:()=>e5,computeConv2DInfo:()=>Hu,computeConv3DInfo:()=>Mk,computeDefaultPad:()=>Lw,computeDilation2DInfo:()=>J4,computeOptimalWindowSize:()=>OX,computeOutAndReduceShapes:()=>eK,computeOutShape:()=>RX,computePool2DInfo:()=>Mw,computePool3DInfo:()=>eH,convertConv2DDataFormat:()=>Lk,decodeEinsumEquation:()=>a5,eitherStridesOrDilationsAreOne:()=>xr,expandShapeToKeepDim:()=>ii,exponent:()=>n5,exponents:()=>o5,fromStringArrayToUint8:()=>$5,fromUint8ToStringArray:()=>_5,getAxesPermutation:()=>rK,getBroadcastDims:()=>m2,getComplexWithIndex:()=>t5,getEinsumComputePath:()=>p5,getEinsumPermutation:()=>i5,getFusedBiasGradient:()=>tp,getFusedDyActivation:()=>ep,getImageCenter:()=>MX,getInnerMostAxes:()=>nK,getPermuted:()=>BX,getRaggedRank:()=>FX,getReductionAxes:()=>yd,getReshaped:()=>LX,getReshapedPermuted:()=>zX,getRowPartitionTypesHelper:()=>AX,getSliceBeginCoords:()=>VX,getSliceSize:()=>WX,getSparseFillEmptyRowsIndicesDenseShapeMismatch:()=>d5,getSparseFillEmptyRowsNegativeIndexErrorMessage:()=>f5,getSparseFillEmptyRowsOutOfRangeIndexErrorMessage:()=>h5,getSparseReshapeEmptyTensorZeroOutputDimErrorMessage:()=>y5,getSparseReshapeInputOutputMismatchErrorMessage:()=>C5,getSparseReshapeInputOutputMultipleErrorMessage:()=>b5,getSparseReshapeMultipleNegativeOneOutputDimErrorMessage:()=>g5,getSparseReshapeNegativeOutputDimErrorMessage:()=>x5,getSparseSegmentReductionIndicesOutOfRangeErrorMessage:()=>v5,getSparseSegmentReductionNegativeSegmentIdsErrorMessage:()=>w5,getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage:()=>S5,getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage:()=>I5,getUndoAxesPermutation:()=>oK,isIdentityPermutation:()=>c5,log:()=>jG,mergeRealAndImagArrays:()=>QX,prepareAndValidate:()=>nT,prepareSplitSize:()=>m5,segment_util:()=>lS,shouldFuse:()=>op,slice_util:()=>ct,splitRealAndImagArrays:()=>ZX,stridesOrDilationsArePositive:()=>Ta,tupleValuesAreOne:()=>Gu,upcastType:()=>dt,validateDefaultValueShape:()=>PX,validateInput:()=>xc,validateUpdateShape:()=>Yw,warn:()=>Ia});function EX(r,t){let e=r[0].length;r.forEach((n,s)=>{$(n.length===e,()=>`Error in concat${e}D: rank of tensors[${s}] must be the same as the rank of the rest (${e})`)}),$(t>=0&&t`Error in concat${e}D: axis must be between 0 and ${e-1}.`);let o=r[0];r.forEach((n,s)=>{for(let a=0;a`Error in concat${e}D: Shape of tensors[${s}] (${n}) does not match the shape of the rest (${o}) along the non-concatenated axis ${s}.`)})}function RX(r,t){let e=r[0].slice();for(let o=1;o=0)if(i>=0){if(i!==s)throw new Error(`rt input.shape and shape=${t} are incompatible: rt input.shape[${n+r}] = ${s} but shape[${n+r}] = ${i}`)}else o[a]=s}return o}function AX(r){let t={FIRST_DIM_SIZE:Pa.FIRST_DIM_SIZE,VALUE_ROWIDS:Pa.VALUE_ROWIDS,ROW_LENGTHS:Pa.ROW_LENGTHS,ROW_SPLITS:Pa.ROW_SPLITS,ROW_LIMITS:Pa.ROW_LIMITS,ROW_STARTS:Pa.ROW_STARTS},e=[];for(let o of r)if(o in t)e.push(t[o]);else break;return e}function FX(r){return r.length===0?0:r[0]===Pa.FIRST_DIM_SIZE?r.length-1:r.length}function PX(r,t){if(r==null||t==null)return;let e=r.length,o=t.length;if(e>=o)throw new Error(`defaultValue.shape=${r} and ragged tensor flatValues.shape=${t}, are incompatible: defaultValue.rank = ${e} must be less than ragged tensor input flatValues.rank = ${o})`);for(let n=0;n=0&&a>=0&&s!==1&&s!==a)throw new Error(`defaultValue.shape=${r}, and ragged tensor input flatValues.shape=${t} are incompatible: defaultValue.shape[${n-r.length}] = ${s} but ragged tensor input.flatValues.shape[${n-r.length}] = ${a}`)}}var uf=30;function OX(r){return r<=uf?r:Xp(r,Math.floor(Math.sqrt(r)))}function MX(r,t,e){let o=e*(typeof r==\"number\"?r:r[0]),n=t*(typeof r==\"number\"?r:r[1]);return[o,n]}function LX(r,t,e,o=!0){let n=[];if(o)n=n.concat(t.slice(0)),n.push(r[0]/e),n=n.concat(r.slice(1));else{n=n.concat(r[0]);let s=t.length;for(let a=0;a=t*2+1||a%2===1?s.push(a):n.push(a);o.push(...n),o.push(0),o.push(...s)}return o}function zX(r,t,e,o=!0){let n=[];o?n.push(r[0]/e):n.push(r[0]*e);for(let s=1;s\",s5=/->/g,fT=\",\",hT=\"...\";function a5(r,t){r=r.replace(/\\s/g,\"\");let e=(r.length-r.replace(s5,\"\").length)/cS.length;if(e<1)throw new Error(\"Equations without an arrow are not supported.\");if(e>1)throw new Error(`Equation must contain exactly one arrow (\"${cS}\").`);let[o,n]=r.split(cS);$(o.indexOf(hT)===-1,()=>`The ellipsis notation (\"${hT}\") is not supported yet.`);let s=o.split(fT),a=s.length;if(t!==a)throw new Error(`Expected ${a} input tensors, received ${t}`);if(a>2)throw new Error(\"Support for more than 2 input tensors is not implemented yet.\");let i=[];for(let m=0;mf.indexOf(d)!==-1))throw new Error(`Output subscripts contain the label ${d} not present in the input subscripts.`);i.indexOf(d)===-1&&i.push(d)}for(let m=0;mn!==-1),{permutationIndices:e,expandDims:o}}function u5(r,t,e){let o=new Array(r);for(let n=0;n`Expected dimension ${o[t[n][a]]} at axis ${a} of input shaped ${JSON.stringify(s)}, but got dimension ${s[a]}`)}}function p5(r,t){let e=r,o=[],n=0;r.length===0&&e.push(-1),n=r.length+1;for(let a=0;at===e)}function l5(r,t){let e=[];for(let o=0;o\"Number of splits must evenly divide the axis.\"),o=new Array(t).fill(r.shape[e]/t);else{let n=t.reduce((a,i)=>(i===-1&&(a+=1),a),0);$(n<=1,()=>\"There should be only one negative value in split array.\");let s=t.indexOf(-1);if(s!==-1){let a=t.reduce((i,p)=>p>0?i+p:i);t[s]=r.shape[e]-a}$(r.shape[e]===t.reduce((a,i)=>a+i),()=>\"The sum of sizes must match the size of the axis dimension.\"),o=t}return o}function d5(r){return`Received SparseTensor with denseShape[0] = 0 but\n indices.shape[0] = ${r}`}function f5(r,t){return`indices(${r}, 0) is invalid: ${t} < 0`}function h5(r,t,e){return`indices(${r}, 0) is invalid: ${t} >= ${e}`}function g5(r,t){return`only one output dimension may be -1, not both ${r} and ${t}`}function x5(r,t){return`size ${r} must be non-negative, not ${t}`}function y5(){return\"reshape cannot infer the missing input size for an empty tensor unless all specified input sizes are non-zero\"}function b5(r,t){let e=He(r),o=He(t);return`Input to reshape is a SparseTensor with ${e}\n dense values, but the requested shape requires a multiple of ${o}. inputShape=${r} outputShape= ${t}`}function C5(r,t){let e=He(r),o=He(t);return`Input to reshape is a tensor with ${e} dense values, but the requested shape has ${o}. inputShape=${r} outputShape=${t}`}function w5(){return\"segment ids must be >= 0\"}function S5(){return\"segment ids are not increasing\"}function I5(r,t){return`Segment id ${r} out of range [0, ${t}), possibly because segmentIds input is not sorted.`}function v5(r,t,e){return`Bad: indices[${r}] == ${t} out of range [0, ${e})`}var lS={};qe(lS,{collectGatherOpShapeInfo:()=>T5,computeOutShape:()=>N5,segOpComputeOptimalWindowSize:()=>k5});function k5(r,t){let e=!1,o;for(r<=uf?(o=r,e=!0):o=Xp(r,Math.floor(Math.sqrt(r)));!e;)o>t||o===r?e=!0:o=Xp(r,o+1);return o}function N5(r,t,e){let o=[],n=r.length;for(let s=0;sn))throw new Error(`Expect batchDims in the range of [-${n}, ${n}], but got ${o}`);if(o<0&&(o+=n),o>s)throw new Error(`batchDims (${o}) must be less than rank(x) (\n ${s}).`);if(esc(t))}catch(t){throw new Error(`Failed to decode encoded string bytes into utf-8, error: ${t}`)}}function $5(r){return r.map(t=>tu(t))}var Wt={};qe(Wt,{nonMaxSuppressionV3Impl:()=>ef,nonMaxSuppressionV4Impl:()=>tf,nonMaxSuppressionV5Impl:()=>rf,whereImpl:()=>Yd});UN();var E5=A();E5.registerFlag(\"KEEP_INTERMEDIATE_TENSORS\",()=>!1,r=>{r&&console.warn(\"Keep intermediate tensors is ON. This will print the values of all intermediate tensors during model inference. Not all models support this mode. For details, check e2e/benchmarks/ model_config.js. This significantly impacts performance.\")});var ho;(function(r){r[r.DT_INVALID=0]=\"DT_INVALID\",r[r.DT_FLOAT=1]=\"DT_FLOAT\",r[r.DT_DOUBLE=2]=\"DT_DOUBLE\",r[r.DT_INT32=3]=\"DT_INT32\",r[r.DT_UINT8=4]=\"DT_UINT8\",r[r.DT_INT16=5]=\"DT_INT16\",r[r.DT_INT8=6]=\"DT_INT8\",r[r.DT_STRING=7]=\"DT_STRING\",r[r.DT_COMPLEX64=8]=\"DT_COMPLEX64\",r[r.DT_INT64=9]=\"DT_INT64\",r[r.DT_BOOL=10]=\"DT_BOOL\",r[r.DT_QINT8=11]=\"DT_QINT8\",r[r.DT_QUINT8=12]=\"DT_QUINT8\",r[r.DT_QINT32=13]=\"DT_QINT32\",r[r.DT_BFLOAT16=14]=\"DT_BFLOAT16\",r[r.DT_QINT16=15]=\"DT_QINT16\",r[r.DT_QUINT16=16]=\"DT_QUINT16\",r[r.DT_UINT16=17]=\"DT_UINT16\",r[r.DT_COMPLEX128=18]=\"DT_COMPLEX128\",r[r.DT_HALF=19]=\"DT_HALF\",r[r.DT_RESOURCE=20]=\"DT_RESOURCE\",r[r.DT_VARIANT=21]=\"DT_VARIANT\",r[r.DT_UINT32=22]=\"DT_UINT32\",r[r.DT_UINT64=23]=\"DT_UINT64\",r[r.DT_FLOAT_REF=101]=\"DT_FLOAT_REF\",r[r.DT_DOUBLE_REF=102]=\"DT_DOUBLE_REF\",r[r.DT_INT32_REF=103]=\"DT_INT32_REF\",r[r.DT_UINT8_REF=104]=\"DT_UINT8_REF\",r[r.DT_INT16_REF=105]=\"DT_INT16_REF\",r[r.DT_INT8_REF=106]=\"DT_INT8_REF\",r[r.DT_STRING_REF=107]=\"DT_STRING_REF\",r[r.DT_COMPLEX64_REF=108]=\"DT_COMPLEX64_REF\",r[r.DT_INT64_REF=109]=\"DT_INT64_REF\",r[r.DT_BOOL_REF=110]=\"DT_BOOL_REF\",r[r.DT_QINT8_REF=111]=\"DT_QINT8_REF\",r[r.DT_QUINT8_REF=112]=\"DT_QUINT8_REF\",r[r.DT_QINT32_REF=113]=\"DT_QINT32_REF\",r[r.DT_BFLOAT16_REF=114]=\"DT_BFLOAT16_REF\",r[r.DT_QINT16_REF=115]=\"DT_QINT16_REF\",r[r.DT_QUINT16_REF=116]=\"DT_QUINT16_REF\",r[r.DT_UINT16_REF=117]=\"DT_UINT16_REF\",r[r.DT_COMPLEX128_REF=118]=\"DT_COMPLEX128_REF\",r[r.DT_HALF_REF=119]=\"DT_HALF_REF\",r[r.DT_RESOURCE_REF=120]=\"DT_RESOURCE_REF\",r[r.DT_VARIANT_REF=121]=\"DT_VARIANT_REF\",r[r.DT_UINT32_REF=122]=\"DT_UINT32_REF\",r[r.DT_UINT64_REF=123]=\"DT_UINT64_REF\"})(ho||(ho={}));var gT;(function(r){let t;(function(e){e[e.LEGACY=0]=\"LEGACY\",e[e.V1=1]=\"V1\",e[e.V2=2]=\"V2\"})(t=r.CheckpointFormatVersion||(r.CheckpointFormatVersion={}))})(gT||(gT={}));var dS={};function D5(r,t){let e={tfOpName:r,category:\"custom\",inputs:[],attrs:[],customExecutor:t};dS[r]=e}function pf(r){return dS[r]}function A5(r){delete dS[r]}function I(r,t,e,o,n){let s=t.inputParams[r];if(s&&s.inputIndexStart!==void 0){let i=s.inputIndexStart,p=s.inputIndexEnd===0?void 0:s.inputIndexEnd===void 0?i+1:s.inputIndexEnd,u=i<0?t.inputNames.length+i:i;if(s.type===\"tensor\")return zt(t.inputNames[u],e,o,n);if(s.type===\"tensors\"){let m=t.inputs.slice(i,p);return t.inputNames.slice(i,p).filter((f,h)=>{var g;return((g=m[h])===null||g===void 0?void 0:g.op)!==\"NoOp\"}).map(f=>zt(f,e,o,n))}let c=zt(t.inputNames[u],e,o,n),l=c.dataSync();return s.type===\"number\"?l[0]:y.toNestedArray(c.shape,l)}let a=t.attrParams[r];return a&&a.value}function zt(r,t,e,o){let[n,s]=Tr(r,e);if(o!=null){let i=o.getHashTableHandleByName(n);if(i!=null)return i}let a=e.currentContextIds.find(i=>!!t[cf(n,i)]);return a!==void 0?t[cf(n,a)][s]:void 0}function fS(r,t,e){return t[cf(r,e.currentContextId)]}function Ls(r,t){let[e,o,n]=Tr(r,t);return[cf(e,t&&t.currentContextId),o,n]}function cf(r,t){return t?`${r}-${t}`:r}function Tr(r,t){if(r===\"\")return[\"\",0,void 0];let e=t!=null&&t.parseNodeNameCache!=null;if(e){let s=t.parseNodeNameCache.get(r);if(s!=null)return s}let o=r.split(\":\"),n;if(o.length===1)n=[r,0,void 0];else{let s=o[0],a=o.length===3?o[1]:void 0,i=Number(o[o.length-1]);n=[s,i,a]}return e&&t.parseNodeNameCache.set(r,n),n}function Ol(r,t,e){let o=I(\"pad\",r,t,e);if(o===\"explicit\"){o=I(\"explicitPaddings\",r,t,e);let n=[[0,0],[0,0],[0,0],[0,0]];for(let s=0;s<4;s++)n[s][0]=o[s*2],n[s][1]=o[s*2+1];return n}return o}function Bs(r){return r.kept?r:Ur(r)}var hS={};qe(hS,{json:()=>F5});var F5=[{tfOpName:\"Add\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"AddV2\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"AddN\",category:\"arithmetic\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}]},{tfOpName:\"BiasAdd\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"Sub\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"RealDiv\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Div\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"DivNoNan\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"FloorDiv\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Mul\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Maximum\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Minimum\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Pow\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"SquaredDifference\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Mod\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"FloorMod\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]}];var gS={};qe(gS,{json:()=>P5});var P5=[{tfOpName:\"Abs\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Acos\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Asin\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Atan\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Atan2\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"y\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Ceil\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ClipByValue\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"clipValueMin\",type:\"number\"},{start:2,name:\"clipValueMax\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Complex\",category:\"basic_math\",inputs:[{start:0,name:\"real\",type:\"tensor\"},{start:1,name:\"imag\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ComplexAbs\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Cos\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Cosh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Elu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Exp\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Floor\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Log\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Imag\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"outputType\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Neg\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Real\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"outputType\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Prelu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"alpha\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Relu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Relu6\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Selu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sigmoid\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sin\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sinh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sqrt\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Rsqrt\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Square\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Tan\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Tanh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sign\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Round\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Expm1\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Log1p\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Reciprocal\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Softplus\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Asinh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Acosh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Atanh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Erf\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LeakyRelu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"alpha\",name:\"alpha\",type:\"number\",defaultValue:.2},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"IsNan\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"IsFinite\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"IsInf\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]}];var xS={};qe(xS,{json:()=>O5});var O5=[{tfOpName:\"EmptyTensorList\",category:\"control\",inputs:[{start:0,name:\"elementShape\",type:\"shape\"},{start:1,name:\"maxNumElements\",type:\"number\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"LoopCond\",category:\"control\",inputs:[{start:0,name:\"pred\",type:\"tensor\"}]},{tfOpName:\"Switch\",category:\"control\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"pred\",type:\"tensor\"}]},{tfOpName:\"Merge\",category:\"control\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}]},{tfOpName:\"Enter\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"frame_name\",name:\"frameName\",type:\"string\"},{tfName:\"is_constant\",name:\"isConstant\",type:\"bool\"}]},{tfOpName:\"Exit\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"NextIteration\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"TensorArrayV3\",category:\"control\",inputs:[{start:0,name:\"size\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"},{tfName:\"dynamic_size\",name:\"dynamicSize\",type:\"bool\"},{tfName:\"clear_after_read\",name:\"clearAfterRead\",type:\"bool\"},{tfName:\"identical_element_shapes\",name:\"identicalElementShapes\",type:\"bool\"},{tfName:\"tensor_array_name\",name:\"name\",type:\"string\"}]},{tfOpName:\"TensorArrayWriteV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"tensor\",type:\"tensor\"},{start:3,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"TensorArrayReadV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"TensorArrayGatherV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"}]},{tfOpName:\"TensorArrayScatterV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"tensor\",type:\"tensor\"},{start:3,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"TensorArrayConcatV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"element_shape_except0\",name:\"elementShapeExcept0\",type:\"shape\",notSupported:!0}]},{tfOpName:\"TensorArraySplitV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"tensor\",type:\"tensor\"},{start:2,name:\"lengths\",type:\"number[]\"},{start:3,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"TensorArraySizeV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"flowIn\",type:\"number\"}]},{tfOpName:\"TensorArrayCloseV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"}]},{tfOpName:\"StatelessIf\",category:\"control\",inputs:[{start:0,name:\"cond\",type:\"tensor\"},{start:1,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"then_branch\",name:\"thenBranch\",type:\"func\"},{tfName:\"else_branch\",name:\"elseBranch\",type:\"func\"}]},{tfOpName:\"If\",category:\"control\",inputs:[{start:0,name:\"cond\",type:\"tensor\"},{start:1,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"then_branch\",name:\"thenBranch\",type:\"func\"},{tfName:\"else_branch\",name:\"elseBranch\",type:\"func\"}]},{tfOpName:\"StatelessWhile\",category:\"control\",inputs:[{start:0,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"cond\",name:\"cond\",type:\"func\"},{tfName:\"body\",name:\"body\",type:\"func\"}]},{tfOpName:\"While\",category:\"control\",inputs:[{start:0,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"cond\",name:\"cond\",type:\"func\"},{tfName:\"body\",name:\"body\",type:\"func\"}]},{tfOpName:\"TensorListScatter\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListScatterV2\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"elementShape\",type:\"shape\"},{start:3,name:\"numElements\",type:\"number\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListGather\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListGetItem\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListSetItem\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListReserve\",category:\"control\",inputs:[{start:0,name:\"elementShape\",type:\"shape\"},{start:1,name:\"numElements\",type:\"number\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListFromTensor\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListStack\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"},{tfName:\"num_elements\",name:\"numElements\",type:\"dtype\"}]},{tfOpName:\"TensorListSplit\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"},{start:2,name:\"lengths\",type:\"number[]\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListConcat\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"}],attrs:[{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"},{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListConcatV2\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"}],attrs:[{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"},{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListPopBack\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListPushBack\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListLength\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"}]},{tfOpName:\"TensorListResize\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"size\",type:\"number\"}]}];var yS={};qe(yS,{json:()=>M5});var M5=[{tfOpName:\"AvgPool\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MaxPool\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[],notSupported:!0},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MaxPoolWithArgmax\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"include_batch_in_index\",name:\"includeBatchInIndex\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"AvgPool3D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MaxPool3D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Conv1D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"stride\",name:\"stride\",type:\"number\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NWC\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"dilation\",name:\"dilation\",type:\"number\",defaultValue:1}]},{tfOpName:\"Conv2D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"useCudnnOnGpu\",name:\"useCudnnOnGpu\",type:\"bool\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"_FusedConv2D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"},{start:2,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"num_args\",name:\"numArgs\",type:\"number\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"use_cudnn_on_gpu\",name:\"useCudnnOnGpu\",type:\"bool\",defaultValue:!0},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\",defaultValue:[1,1,1,1]},{tfName:\"fused_ops\",name:\"fusedOps\",type:\"string[]\",defaultValue:[]},{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:1e-4},{tfName:\"leakyrelu_alpha\",name:\"leakyreluAlpha\",type:\"number\",defaultValue:.2}]},{tfOpName:\"Conv2DBackpropInput\",category:\"convolution\",inputs:[{start:2,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"},{start:0,name:\"outputShape\",type:\"number[]\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\",notSupported:!0}]},{tfOpName:\"DepthwiseConv2d\",category:\"convolution\",inputs:[{start:0,name:\"input\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"DepthwiseConv2dNative\",category:\"convolution\",inputs:[{start:0,name:\"input\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"FusedDepthwiseConv2dNative\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"},{start:2,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"num_args\",name:\"numArgs\",type:\"number\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\",defaultValue:[1,1,1,1]},{tfName:\"fused_ops\",name:\"fusedOps\",type:\"string[]\",defaultValue:[]},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]}]},{tfOpName:\"Conv3D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"Dilation2D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"rates\",name:\"dilations\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"}]}];var bS={};qe(bS,{json:()=>L5});var L5=[{tfOpName:\"Fill\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"},{start:1,name:\"value\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"LinSpace\",category:\"creation\",inputs:[{start:0,name:\"start\",type:\"number\"},{start:1,name:\"stop\",type:\"number\"},{start:2,name:\"num\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"OneHot\",category:\"creation\",inputs:[{start:0,name:\"indices\",type:\"tensor\"},{start:1,name:\"depth\",type:\"number\"},{start:2,name:\"onValue\",type:\"number\",defaultValue:1},{start:3,name:\"offValue\",type:\"number\",defaultValue:0}],attrs:[{tfName:\"axis\",name:\"axis\",type:\"number\",notSupported:!0},{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Ones\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"OnesLike\",category:\"creation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"RandomStandardNormal\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"seed\",name:\"seed\",type:\"number\",defaultValue:0},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"T\",name:\"T\",type:\"number\",notSupported:!0}]},{tfOpName:\"RandomUniform\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"minval\",name:\"minval\",type:\"number\",defaultValue:0},{tfName:\"maxval\",name:\"maxval\",type:\"number\",defaultValue:1},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"seed\",name:\"seed\",type:\"number\",defaultValue:0},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0},{tfName:\"T\",name:\"T\",type:\"number\",notSupported:!0}]},{tfOpName:\"RandomUniformInt\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"minval\",name:\"minval\",type:\"number\"},{tfName:\"maxval\",name:\"maxval\",type:\"number\"},{tfName:\"seed\",name:\"seed\",type:\"number\",defaultValue:0},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0}]},{tfOpName:\"Range\",category:\"creation\",inputs:[{start:0,name:\"start\",type:\"number\"},{start:1,name:\"stop\",type:\"number\"},{start:2,name:\"step\",type:\"number\",defaultValue:0}],attrs:[{tfName:\"Tidx\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"TruncatedNormal\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"means\",name:\"mean\",type:\"number\",defaultValue:0},{tfName:\"stddev\",name:\"stdDev\",type:\"number\",defaultValue:1},{tfName:\"seed\",name:\"seed\",type:\"number\"},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"T\",name:\"T\",type:\"number\",notSupported:!0}]},{tfOpName:\"Zeros\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"ZerosLike\",category:\"creation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Multinomial\",category:\"creation\",inputs:[{start:0,name:\"logits\",type:\"tensor\"},{start:1,name:\"numSamples\",type:\"number\"}],attrs:[{tfName:\"seed\",name:\"seed\",type:\"number\"},{tfName:\"seed2\",name:\"seed2\",type:\"number\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\"},{tfName:\"output_dtype\",name:\"output_dtype\",type:\"dtype\"}]}];var CS={};qe(CS,{json:()=>B5});var B5=[{tfOpName:\"NonMaxSuppressionV2\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"}]},{tfOpName:\"NonMaxSuppressionV3\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"},{start:4,name:\"scoreThreshold\",type:\"number\"}]},{tfOpName:\"NonMaxSuppressionV4\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"},{start:4,name:\"scoreThreshold\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"T_threshold\",name:\"threshold\",type:\"dtype\",notSupported:!0},{tfName:\"pad_to_max_output_size\",name:\"padToMaxOutputSize\",type:\"bool\"}]},{tfOpName:\"NonMaxSuppressionV5\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"},{start:4,name:\"scoreThreshold\",type:\"number\"},{start:5,name:\"softNmsSigma\",type:\"number\"}]},{tfOpName:\"Where\",category:\"dynamic\",inputs:[{start:0,name:\"condition\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ListDiff\",category:\"dynamic\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"y\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]}];var wS={};qe(wS,{json:()=>z5});var z5=[{tfOpName:\"LowerBound\",category:\"evaluation\",inputs:[{start:0,name:\"sortedSequence\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"}]},{tfOpName:\"TopKV2\",category:\"evaluation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"k\",type:\"number\"}],attrs:[{tfName:\"sorted\",name:\"sorted\",type:\"bool\"}]},{tfOpName:\"UpperBound\",category:\"evaluation\",inputs:[{start:0,name:\"sortedSequence\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"}]},{tfOpName:\"Unique\",category:\"evaluation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"UniqueV2\",category:\"evaluation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]}];var SS={};qe(SS,{json:()=>V5});var V5=[{tfOpName:\"PlaceholderWithDefault\",category:\"graph\",inputs:[{start:0,name:\"default\",type:\"tensor\"}],attrs:[{tfName:\"shape\",name:\"shape\",type:\"shape\"},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Placeholder\",category:\"graph\",attrs:[{tfName:\"shape\",name:\"shape\",type:\"shape\"},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Const\",category:\"graph\"},{tfOpName:\"Identity\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"IdentityN\",category:\"graph\",inputs:[{start:0,end:0,name:\"x\",type:\"tensors\"}]},{tfOpName:\"Snapshot\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"Rank\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"Size\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"Shape\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"ShapeN\",category:\"graph\",inputs:[{start:0,end:0,name:\"x\",type:\"tensors\"}]},{tfOpName:\"Print\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"data\",type:\"tensors\"}],attrs:[{tfName:\"message\",name:\"message\",type:\"string\"},{tfName:\"first_n\",name:\"firstN\",type:\"number\",notSupported:!0},{tfName:\"summarize\",name:\"summarize\",type:\"number\",defaultValue:3}]},{tfOpName:\"NoOp\",category:\"graph\",inputs:[]},{tfOpName:\"StopGradient\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"FakeQuantWithMinMaxVars\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"min\",name:\"min\",type:\"number\"},{tfName:\"max\",name:\"max\",type:\"number\"}]}];var IS={};qe(IS,{json:()=>W5});var W5=[{tfOpName:\"HashTable\",category:\"hash_table\",inputs:[],attrs:[{tfName:\"shared_name\",name:\"sharedName\",type:\"string\"},{tfName:\"use_node_name_sharing\",name:\"useNodeNameSharing\",type:\"bool\"},{tfName:\"key_dtype\",name:\"keyDType\",type:\"dtype\"},{tfName:\"value_dtype\",name:\"valueDType\",type:\"dtype\"}]},{tfOpName:\"HashTableV2\",category:\"hash_table\",inputs:[],attrs:[{tfName:\"shared_name\",name:\"sharedName\",type:\"string\"},{tfName:\"use_node_name_sharing\",name:\"useNodeNameSharing\",type:\"bool\"},{tfName:\"key_dtype\",name:\"keyDType\",type:\"dtype\"},{tfName:\"value_dtype\",name:\"valueDType\",type:\"dtype\"}]},{tfOpName:\"LookupTableImport\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableImportV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableFind\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"defaultValue\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableFindV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"defaultValue\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableSize\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"}]},{tfOpName:\"LookupTableSizeV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"}]},{tfOpName:\"InitializeTable\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}]},{tfOpName:\"InitializeTableV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}]}];var vS={};qe(vS,{json:()=>U5});var U5=[{tfOpName:\"ResizeBilinear\",category:\"image\",inputs:[{start:0,name:\"images\",type:\"tensor\"},{start:1,name:\"size\",type:\"number[]\"}],attrs:[{tfName:\"align_corners\",name:\"alignCorners\",type:\"bool\"},{tfName:\"half_pixel_centers\",name:\"halfPixelCenters\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ResizeNearestNeighbor\",category:\"image\",inputs:[{start:0,name:\"images\",type:\"tensor\"},{start:1,name:\"size\",type:\"number[]\"}],attrs:[{tfName:\"align_corners\",name:\"alignCorners\",type:\"bool\"},{tfName:\"half_pixel_centers\",name:\"halfPixelCenters\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"CropAndResize\",category:\"image\",inputs:[{start:0,name:\"image\",type:\"tensor\"},{start:1,name:\"boxes\",type:\"tensor\"},{start:2,name:\"boxInd\",type:\"tensor\"},{start:3,name:\"cropSize\",type:\"number[]\"}],attrs:[{tfName:\"method\",name:\"method\",type:\"string\"},{tfName:\"extrapolation_value\",name:\"extrapolationValue\",type:\"number\"}]},{tfOpName:\"ImageProjectiveTransformV3\",category:\"image\",inputs:[{start:0,name:\"images\",type:\"tensor\"},{start:1,name:\"transforms\",type:\"tensor\"},{start:2,name:\"outputShape\",type:\"number[]\"},{start:3,name:\"fillValue\",type:\"number\"}],attrs:[{tfName:\"interpolation\",name:\"interpolation\",type:\"string\"},{tfName:\"fill_mode\",name:\"fillMode\",type:\"string\"}]}];var kS={};qe(kS,{json:()=>G5});var G5=[{tfOpName:\"Equal\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"NotEqual\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Greater\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"GreaterEqual\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Less\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LessEqual\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LogicalAnd\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LogicalNot\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LogicalOr\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Select\",category:\"logical\",inputs:[{start:0,name:\"condition\",type:\"tensor\"},{start:1,name:\"a\",type:\"tensor\"},{start:2,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"SelectV2\",category:\"logical\",inputs:[{start:0,name:\"condition\",type:\"tensor\"},{start:1,name:\"a\",type:\"tensor\"},{start:2,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"BitwiseAnd\",category:\"logical\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"y\",type:\"tensor\"}]}];var NS={};qe(NS,{json:()=>H5});var H5=[{tfOpName:\"_FusedMatMul\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"},{start:2,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"num_args\",name:\"numArgs\",type:\"number\"},{tfName:\"fused_ops\",name:\"fusedOps\",type:\"string[]\",defaultValue:[]},{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:1e-4},{tfName:\"transpose_a\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"transpose_b\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"leakyrelu_alpha\",name:\"leakyreluAlpha\",type:\"number\",defaultValue:.2},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MatMul\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"transpose_a\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"transpose_b\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"BatchMatMul\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"adj_x\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"adj_y\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"BatchMatMulV2\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"adj_x\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"adj_y\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Transpose\",category:\"matrices\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"perm\",type:\"number[]\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Einsum\",category:\"matrices\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}],attrs:[{tfName:\"equation\",name:\"equation\",type:\"string\"},{tfName:\"N\",name:\"n\",type:\"number\",defaultValue:2},{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"MatrixBandPart\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"numLower\",type:\"tensor\"},{start:1,name:\"numUpper\",type:\"tensor\"}]}];var TS={};qe(TS,{json:()=>K5});var K5=[{tfOpName:\"EuclideanNorm\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\",defaultValue:!1}]},{tfOpName:\"FusedBatchNorm\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"scale\",type:\"tensor\"},{start:2,name:\"offset\",type:\"tensor\"},{start:3,name:\"mean\",type:\"tensor\"},{start:4,name:\"variance\",type:\"tensor\"}],attrs:[{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:.001},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"FusedBatchNormV2\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"scale\",type:\"tensor\"},{start:2,name:\"offset\",type:\"tensor\"},{start:3,name:\"mean\",type:\"tensor\"},{start:4,name:\"variance\",type:\"tensor\"}],attrs:[{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:.001},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"FusedBatchNormV3\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"scale\",type:\"tensor\"},{start:2,name:\"offset\",type:\"tensor\"},{start:3,name:\"mean\",type:\"tensor\"},{start:4,name:\"variance\",type:\"tensor\"}],attrs:[{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:.001},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"LRN\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"depth_radius\",name:\"radius\",type:\"number\",defaultValue:5},{tfName:\"bias\",name:\"bias\",type:\"number\",defaultValue:1},{tfName:\"alpha\",name:\"alpha\",type:\"number\",defaultValue:1},{tfName:\"beta\",name:\"beta\",type:\"number\",defaultValue:.5}]},{tfOpName:\"Softmax\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"LogSoftmax\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]}];var _S={};qe(_S,{json:()=>q5});var q5=[{tfOpName:\"Bincount\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"size\",type:\"number\"},{start:2,name:\"weights\",type:\"tensor\"}]},{tfOpName:\"DenseBincount\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"size\",type:\"number\"},{start:2,name:\"weights\",type:\"tensor\"}],attrs:[{tfName:\"binary_output\",name:\"binaryOutput\",type:\"bool\"}]},{tfOpName:\"Max\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Mean\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Min\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Sum\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"All\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Any\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"ArgMax\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]},{tfOpName:\"ArgMin\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]},{tfOpName:\"Prod\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Cumprod\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"exclusive\",name:\"exclusive\",type:\"bool\"},{tfName:\"reverse\",name:\"reverse\",type:\"bool\"}]},{tfOpName:\"Cumsum\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"exclusive\",name:\"exclusive\",type:\"bool\"},{tfName:\"reverse\",name:\"reverse\",type:\"bool\"}]}];var $S={};qe($S,{json:()=>j5});var j5=[{tfOpName:\"ConcatV2\",category:\"slice_join\",inputs:[{start:0,end:-1,name:\"tensors\",type:\"tensors\"},{start:-1,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"N\",name:\"n\",type:\"number\",defaultValue:2}]},{tfOpName:\"Concat\",category:\"slice_join\",inputs:[{start:1,end:0,name:\"tensors\",type:\"tensors\"},{start:0,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"N\",name:\"n\",type:\"number\",defaultValue:2}]},{tfOpName:\"GatherV2\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"axis\",type:\"number\",defaultValue:0}],attrs:[{tfName:\"batch_dims\",name:\"batchDims\",type:\"number\",defaultValue:0}]},{tfOpName:\"Gather\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"}],attrs:[{tfName:\"validate_indices\",name:\"validateIndices\",type:\"bool\",notSupported:!0}]},{tfOpName:\"Reverse\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"dims\",type:\"bool[]\"}]},{tfOpName:\"ReverseV2\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}]},{tfOpName:\"Slice\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"begin\",type:\"number[]\"},{start:2,name:\"size\",type:\"number[]\"}]},{tfOpName:\"StridedSlice\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"begin\",type:\"number[]\"},{start:2,name:\"end\",type:\"number[]\"},{start:3,name:\"strides\",type:\"number[]\"}],attrs:[{tfName:\"begin_mask\",name:\"beginMask\",type:\"number\",defaultValue:0},{tfName:\"end_mask\",name:\"endMask\",type:\"number\",defaultValue:0},{tfName:\"new_axis_mask\",name:\"newAxisMask\",type:\"number\",defaultValue:0},{tfName:\"ellipsis_mask\",name:\"ellipsisMask\",type:\"number\",defaultValue:0},{tfName:\"shrink_axis_mask\",name:\"shrinkAxisMask\",type:\"number\",defaultValue:0}]},{tfOpName:\"Pack\",category:\"slice_join\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}],attrs:[{tfName:\"axis\",name:\"axis\",type:\"number\",defaultValue:0}]},{tfOpName:\"Unpack\",category:\"slice_join\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"axis\",name:\"axis\",type:\"number\",defaultValue:0},{tfName:\"num\",name:\"num\",type:\"number\",defaultValue:0,notSupported:!0}]},{tfOpName:\"Tile\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"reps\",type:\"number[]\"}]},{tfOpName:\"Split\",category:\"slice_join\",inputs:[{start:0,name:\"axis\",type:\"number\",defaultValue:0},{start:1,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"num_split\",name:\"numOrSizeSplits\",type:\"number\",defaultValue:1}]},{tfOpName:\"SplitV\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"numOrSizeSplits\",type:\"number[]\"},{start:2,name:\"axis\",type:\"number\",defaultValue:0}]},{tfOpName:\"ScatterNd\",category:\"slice_join\",inputs:[{start:0,name:\"indices\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"},{start:2,name:\"shape\",type:\"number[]\"}]},{tfOpName:\"GatherNd\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"}]},{tfOpName:\"SparseToDense\",category:\"slice_join\",inputs:[{start:0,name:\"sparseIndices\",type:\"tensor\"},{start:1,name:\"outputShape\",type:\"number[]\"},{start:2,name:\"sparseValues\",type:\"tensor\"},{start:3,name:\"defaultValue\",type:\"tensor\"}],attrs:[{tfName:\"validate_indices\",name:\"validateIndices\",type:\"bool\",defaultValue:!1,notSupported:!0}]},{tfOpName:\"TensorScatterUpdate\",category:\"slice_join\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}]}];var ES={};qe(ES,{json:()=>X5});var X5=[{tfOpName:\"SparseFillEmptyRows\",category:\"sparse\",inputs:[{start:0,name:\"indices\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"},{start:2,name:\"denseShape\",type:\"tensor\"},{start:3,name:\"defaultValue\",type:\"tensor\"}]},{tfOpName:\"SparseReshape\",category:\"sparse\",inputs:[{start:0,name:\"inputIndices\",type:\"tensor\"},{start:1,name:\"inputShape\",type:\"tensor\"},{start:2,name:\"newShape\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"SparseSegmentMean\",category:\"sparse\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"segmentIds\",type:\"tensor\"}]},{tfOpName:\"SparseSegmentSum\",category:\"sparse\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"segmentIds\",type:\"tensor\"}]}];var RS={};qe(RS,{json:()=>Y5});var Y5=[{tfOpName:\"FFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"IFFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"RFFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"fft_length\",type:\"number\",notSupported:!0}]},{tfOpName:\"IRFFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"fft_length\",type:\"number\",notSupported:!0}]}];var DS={};qe(DS,{json:()=>Q5});var Q5=[{tfOpName:\"StaticRegexReplace\",category:\"string\",inputs:[{start:0,name:\"input\",type:\"tensor\"}],attrs:[{tfName:\"pattern\",name:\"pattern\",type:\"string\"},{tfName:\"rewrite\",name:\"rewrite\",type:\"string\"},{tfName:\"replace_global\",name:\"replaceGlobal\",type:\"bool\"}]},{tfOpName:\"StringNGrams\",category:\"string\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"dataSplits\",type:\"tensor\"}],attrs:[{tfName:\"separator\",name:\"separator\",type:\"string\"},{tfName:\"ngram_widths\",name:\"nGramWidths\",type:\"number[]\"},{tfName:\"left_pad\",name:\"leftPad\",type:\"string\"},{tfName:\"right_pad\",name:\"rightPad\",type:\"string\"},{tfName:\"pad_width\",name:\"padWidth\",type:\"number\"},{tfName:\"preserve_short_sequences\",name:\"preserveShortSequences\",type:\"bool\"}],outputs:[\"ngrams\",\"ngrams_splits\"]},{tfOpName:\"StringSplit\",category:\"string\",inputs:[{start:0,name:\"input\",type:\"tensor\"},{start:1,name:\"delimiter\",type:\"tensor\"}],attrs:[{tfName:\"skip_empty\",name:\"skipEmpty\",type:\"bool\"}],outputs:[\"indices\",\"values\",\"shape\"]},{tfOpName:\"StringToHashBucketFast\",category:\"string\",inputs:[{start:0,name:\"input\",type:\"tensor\"}],attrs:[{tfName:\"num_buckets\",name:\"numBuckets\",type:\"number\"}]}];var AS={};qe(AS,{json:()=>Z5});var Z5=[{tfOpName:\"Cast\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"SrcT\",name:\"sdtype\",type:\"dtype\",notSupported:!0},{tfName:\"DstT\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"ExpandDims\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]},{tfOpName:\"MirrorPad\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"padding\",type:\"number[]\"}],attrs:[{tfName:\"mode\",name:\"mode\",type:\"string\"}]},{tfOpName:\"Pad\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"padding\",type:\"number[]\"}],attrs:[{tfName:\"constant_value\",name:\"constantValue\",type:\"number\",defaultValue:0}]},{tfOpName:\"PadV2\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"padding\",type:\"number[]\"},{start:2,name:\"constantValue\",type:\"number\",defaultValue:0}]},{tfOpName:\"Reshape\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"shape\",type:\"number[]\"}]},{tfOpName:\"EnsureShape\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"shape\",type:\"number[]\"}]},{tfOpName:\"Squeeze\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"axis\",tfDeprecatedName:\"squeeze_dims\",name:\"axis\",type:\"number[]\"}]},{tfOpName:\"SpaceToBatchND\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"blockShape\",type:\"number[]\"},{start:2,name:\"paddings\",type:\"number[]\"}]},{tfOpName:\"BatchToSpaceND\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"blockShape\",type:\"number[]\"},{start:2,name:\"crops\",type:\"number[]\"}]},{tfOpName:\"DepthToSpace\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"block_size\",name:\"blockSize\",type:\"number\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\"}]},{tfOpName:\"BroadcastTo\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"shape\",type:\"number[]\"}],attrs:[]},{tfOpName:\"BroadcastArgs\",category:\"transformation\",inputs:[{start:0,name:\"s0\",type:\"tensor\"},{start:1,name:\"s1\",type:\"tensor\"}],attrs:[]}];var Ml=class{static get Instance(){return this._instance||(this._instance=new this)}constructor(){let t=[hS,gS,xS,yS,bS,CS,wS,SS,IS,vS,kS,NS,TS,_S,$S,ES,RS,DS,AS],e=[].concat(...t.map(o=>o.json));this.opMappers=e.reduce((o,n)=>(o[n.tfOpName]=n,o),{})}transformGraph(t,e={}){let o=t.node,n=[],s=[],a=[],i=o.reduce((h,g)=>(h[g.name]=this.mapNode(g),g.op.startsWith(\"Placeholder\")?n.push(h[g.name]):g.op===\"Const\"?s.push(h[g.name]):(g.input==null||g.input.length===0)&&a.push(h[g.name]),h),{}),p=[],u=[],c={},l={};e!=null&&(c=this.mapSignatureEntries(e.inputs),l=this.mapSignatureEntries(e.outputs));let m=Object.keys(i);m.forEach(h=>{let g=i[h];g.inputNames.forEach((x,b)=>{let[C,,S]=Ls(x),k=i[C];if(k.outputs!=null){let _=k.outputs.indexOf(S);if(_!==-1){let E=`${C}:${_}`;g.inputNames[b]=E}}g.inputs.push(k),k.children.push(g)})}),Object.keys(l).length===0?m.forEach(h=>{let g=i[h];g.children.length===0&&u.push(g)}):Object.keys(l).forEach(h=>{let[g]=Ls(h),x=i[g];x!=null&&(x.signatureKey=l[h],u.push(x))}),Object.keys(c).length>0?Object.keys(c).forEach(h=>{let[g]=Ls(h),x=i[g];x&&(x.signatureKey=c[h],p.push(x))}):p=n;let d={};t.library!=null&&t.library.function!=null&&(d=t.library.function.reduce((h,g)=>(h[g.signature.name]=this.mapFunction(g),h),{}));let f={nodes:i,inputs:p,outputs:u,weights:s,placeholders:n,signature:e,functions:d};return a.length>0&&(f.initNodes=a),f}mapSignatureEntries(t){return Object.keys(t||{}).reduce((e,o)=>(e[t[o].name]=o,e),{})}mapNode(t){let e=pf(t.op)||this.opMappers[t.op]||{};t.attr==null&&(t.attr={});let o={name:t.name,op:t.op,category:e.category,inputNames:(t.input||[]).map(n=>n.startsWith(\"^\")?n.slice(1):n),inputs:[],children:[],inputParams:{},attrParams:{},rawAttrs:t.attr,outputs:e.outputs};return e.inputs!=null&&(o.inputParams=e.inputs.reduce((n,s)=>(n[s.name]={type:s.type,inputIndexStart:s.start,inputIndexEnd:s.end},n),{})),e.attrs!=null&&(o.attrParams=e.attrs.reduce((n,s)=>{let a=s.type,i;switch(s.type){case\"string\":i=lf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=lf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"string[]\":i=yf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=yf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"number\":i=df(t.attr,s.tfName,s.defaultValue||0),i===void 0&&s.tfDeprecatedName&&(i=df(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"number[]\":i=xf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=xf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"bool\":i=mf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=mf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"bool[]\":i=Cf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=Cf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"shape\":i=gf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=gf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"shape[]\":i=bf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=bf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"dtype\":i=ff(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=ff(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"dtype[]\":i=hf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=hf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"func\":i=xT(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=xT(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"tensor\":case\"tensors\":break;default:throw new Error(`Unsupported param type: ${s.type} for op: ${t.op}`)}return n[s.name]={value:i,type:a},n},{})),o}mapFunction(t){let e=t.nodeDef,o=[],n=[],s={};e!=null&&(s=e.reduce((l,m)=>(l[m.name]=this.mapNode(m),m.op===\"Const\"&&n.push(l[m.name]),l),{}));let a=[],i=[];t.signature.inputArg.forEach(l=>{let[m]=Ls(l.name),d={name:m,op:\"Placeholder\",inputs:[],inputNames:[],category:\"graph\",inputParams:{},attrParams:{dtype:{value:FS(l.type),type:\"dtype\"}},children:[]};d.signatureKey=l.name,a.push(d),s[m]=d}),Object.keys(s).forEach(l=>{let m=s[l];m.inputNames.forEach((d,f)=>{let[h,,g]=Ls(d),x=s[h];if(x.outputs!=null){let b=x.outputs.indexOf(g);if(b!==-1){let C=`${h}:${b}`;m.inputNames[f]=C}}m.inputs.push(x),x.children.push(m)})});let u=t.ret;t.signature.outputArg.forEach(l=>{let[m,d]=Ls(u[l.name]),f=s[m];f!=null&&(f.defaultOutput=d,i.push(f))});let c=this.mapArgsToSignature(t);return{nodes:s,inputs:a,outputs:i,weights:n,placeholders:o,signature:c}}mapArgsToSignature(t){return{methodName:t.signature.name,inputs:t.signature.inputArg.reduce((e,o)=>(e[o.name]=this.mapArgToTensorInfo(o),e),{}),outputs:t.signature.outputArg.reduce((e,o)=>(e[o.name]=this.mapArgToTensorInfo(o,t.ret),e),{})}}mapArgToTensorInfo(t,e){let o=t.name;return e!=null&&(o=e[o]),{name:o,dtype:t.type}}};function J5(r){let t=A().global;if(typeof t.atob!=\"undefined\")return t.atob(r);if(typeof Buffer!=\"undefined\")return new Buffer(r,\"base64\").toString();throw new Error(\"Unable to decode base64 in this environment. Missing built-in atob() or Buffer()\")}function yT(r,t){let e=Array.isArray(r)?String.fromCharCode.apply(null,r):J5(r);return t?e:e.toLowerCase()}function lf(r,t,e,o=!1){let n=r[t];return n!=null?yT(n.s,o):e}function mf(r,t,e){let o=r[t];return o?o.b:e}function df(r,t,e){let o=r[t]||{},n=o.i!=null?o.i:o.f!=null?o.f:e;return typeof n==\"number\"?n:parseInt(n,10)}function FS(r){switch(typeof r==\"string\"&&(r=ho[r]),r){case ho.DT_FLOAT:case ho.DT_HALF:return\"float32\";case ho.DT_INT32:case ho.DT_INT64:case ho.DT_INT8:case ho.DT_UINT8:return\"int32\";case ho.DT_BOOL:return\"bool\";case ho.DT_DOUBLE:return\"float32\";case ho.DT_STRING:return\"string\";default:return null}}function xT(r,t,e){let o=r[t];return o&&o.func?o.func.name:e}function ff(r,t,e){let o=r[t];return o&&o.type?FS(o.type):e}function hf(r,t,e){let o=r[t];return o&&o.list&&o.list.type?o.list.type.map(n=>FS(n)):e}function bT(r){if(!r.unknownRank)return r.dim!=null?r.dim.map(t=>typeof t.size==\"number\"?t.size:parseInt(t.size,10)):[]}function gf(r,t,e){let o=r[t];return o&&o.shape?bT(o.shape):e}function xf(r,t,e){let o=r[t];return o?((o.list.f&&o.list.f.length?o.list.f:o.list.i)||[]).map(n=>typeof n==\"number\"?n:parseInt(n,10)):e}function yf(r,t,e,o=!1){let n=r[t];return n&&n.list&&n.list.s?n.list.s.map(s=>yT(s,o)):e}function bf(r,t,e){let o=r[t];return o&&o.list&&o.list.shape?o.list.shape.map(n=>bT(n)):e}function Cf(r,t,e){let o=r[t];return o&&o.list&&o.list.b?o.list.b:e}var wf=class{constructor(t,e,o){this.node=t,this.tensorMap=e,this.context=o,this.inputs=[],this.attrs={},this.inputs=t.inputNames.map(n=>this.getInput(n)),t.rawAttrs!=null&&(this.attrs=Object.keys(t.rawAttrs).reduce((n,s)=>(n[s]=this.getAttr(s),n),{}))}getInput(t){return zt(t,this.tensorMap,this.context)}getAttr(t,e){let o=this.node.rawAttrs[t];if(o.tensor!=null)return zt(t,this.tensorMap,this.context);if(o.i!=null||o.f!=null)return df(this.node.rawAttrs,t,e);if(o.s!=null)return lf(this.node.rawAttrs,t,e);if(o.b!=null)return mf(this.node.rawAttrs,t,e);if(o.shape!=null)return gf(this.node.rawAttrs,t,e);if(o.type!=null)return ff(this.node.rawAttrs,t,e);if(o.list!=null){if(o.list.i!=null||o.list.f!=null)return xf(this.node.rawAttrs,t,e);if(o.list.s!=null)return yf(this.node.rawAttrs,t,e);if(o.list.shape!=null)return bf(this.node.rawAttrs,t,e);if(o.list.b!=null)return Cf(this.node.rawAttrs,t,e);if(o.list.type!=null)return hf(this.node.rawAttrs,t,e)}return e}};var Je={};qe(Je,{OP_SCOPE_SUFFIX:()=>kw,abs:()=>Jt,acos:()=>kk,acosh:()=>Nk,add:()=>Ce,addN:()=>Tk,all:()=>_k,any:()=>$k,argMax:()=>Ek,argMin:()=>Rk,asin:()=>Dk,asinh:()=>Ak,atan:()=>Fk,atan2:()=>Pk,atanh:()=>Ok,avgPool:()=>fd,avgPool3d:()=>Bk,basicLSTMCell:()=>zk,batchNorm:()=>au,batchNorm2d:()=>Wk,batchNorm3d:()=>Uk,batchNorm4d:()=>Gk,batchToSpaceND:()=>hd,bincount:()=>gd,bitwiseAnd:()=>Hk,booleanMaskAsync:()=>E6,broadcastArgs:()=>Kk,broadcastTo:()=>iu,buffer:()=>me,cast:()=>We,ceil:()=>qk,clipByValue:()=>jk,clone:()=>Ur,complex:()=>Er,concat:()=>bt,concat1d:()=>Xk,concat2d:()=>Yk,concat3d:()=>Qk,concat4d:()=>Zk,conv1d:()=>Jk,conv2d:()=>uu,conv2dTranspose:()=>e2,conv3d:()=>t2,conv3dTranspose:()=>o2,cos:()=>n2,cosh:()=>s2,cosineWindow:()=>Rl,cumprod:()=>a2,cumsum:()=>i2,denseBincount:()=>u2,depthToSpace:()=>p2,depthwiseConv2d:()=>lc,diag:()=>c2,dilation2d:()=>l2,div:()=>je,divNoNan:()=>d2,dot:()=>f2,dropout:()=>W6,einsum:()=>pu,elu:()=>Cd,enclosingPowerOfTwo:()=>Qw,ensureShape:()=>h2,equal:()=>bd,erf:()=>g2,euclideanNorm:()=>b2,exp:()=>$o,expandDims:()=>Ms,expm1:()=>C2,eye:()=>wd,fft:()=>fc,fill:()=>Ea,floor:()=>Sd,floorDiv:()=>dd,fused:()=>Zw,gather:()=>Id,gatherND:()=>z6,greater:()=>qu,greaterEqual:()=>vd,ifft:()=>Ju,imag:()=>lu,image:()=>Kj,inTopKAsync:()=>G6,irfft:()=>Kd,isFinite:()=>w2,isInf:()=>S2,isNaN:()=>I2,leakyRelu:()=>kd,less:()=>_l,lessEqual:()=>mc,linalg:()=>qj,linspace:()=>v2,localResponseNormalization:()=>k2,log:()=>pi,log1p:()=>Nd,logSigmoid:()=>N2,logSoftmax:()=>T2,logSumExp:()=>$d,logicalAnd:()=>ju,logicalNot:()=>Ed,logicalOr:()=>Rd,logicalXor:()=>_2,losses:()=>jj,lowerBound:()=>$2,matMul:()=>Ze,max:()=>Ra,maxPool:()=>Ad,maxPool3d:()=>E2,maxPoolWithArgmax:()=>R2,maximum:()=>Fd,mean:()=>Xu,meshgrid:()=>D2,min:()=>Tl,minimum:()=>Yu,mirrorPad:()=>A2,mod:()=>F2,moments:()=>P2,movingAverage:()=>A6,mul:()=>se,multiRNNCell:()=>O2,multinomial:()=>M2,neg:()=>cr,norm:()=>Ku,notEqual:()=>Pd,oneHot:()=>El,ones:()=>Da,onesLike:()=>L2,op:()=>N,outerProduct:()=>B2,pad:()=>Aa,pad1d:()=>z2,pad2d:()=>V2,pad3d:()=>W2,pad4d:()=>U2,pool:()=>G2,pow:()=>ui,prelu:()=>Md,print:()=>md,prod:()=>H2,raggedGather:()=>K2,raggedRange:()=>q2,raggedTensorToTensor:()=>j2,rand:()=>X2,randomGamma:()=>g1,randomNormal:()=>Ud,randomStandardNormal:()=>x1,randomUniform:()=>dc,randomUniformInt:()=>y1,range:()=>mu,real:()=>ci,reciprocal:()=>b1,relu:()=>du,relu6:()=>Gd,reshape:()=>W,reverse:()=>mo,reverse1d:()=>C1,reverse2d:()=>w1,reverse3d:()=>S1,reverse4d:()=>I1,rfft:()=>hc,round:()=>Hd,rsqrt:()=>v1,scalar:()=>ke,scatterND:()=>P6,searchSorted:()=>$l,selu:()=>k1,separableConv2d:()=>N1,setdiff1dAsync:()=>T1,sigmoid:()=>$a,sign:()=>_1,signal:()=>Hj,sin:()=>$1,sinh:()=>E1,slice:()=>Xe,slice1d:()=>R1,slice2d:()=>D1,slice3d:()=>A1,slice4d:()=>F1,softmax:()=>P1,softplus:()=>_d,spaceToBatchND:()=>Od,sparse:()=>Xj,sparseToDense:()=>L6,spectral:()=>Gj,split:()=>li,sqrt:()=>Dr,square:()=>er,squaredDifference:()=>qd,squeeze:()=>gc,stack:()=>kr,step:()=>jd,stridedSlice:()=>O1,string:()=>Yj,sub:()=>Te,sum:()=>ot,tan:()=>M1,tanh:()=>Nl,tensor:()=>ur,tensor1d:()=>tr,tensor2d:()=>fu,tensor3d:()=>Xd,tensor4d:()=>L1,tensor5d:()=>B1,tensor6d:()=>z1,tensorScatterUpdate:()=>W1,tile:()=>cu,topk:()=>U1,transpose:()=>yc,truncatedNormal:()=>G1,unique:()=>H1,unsortedSegmentSum:()=>K1,unstack:()=>fo,upperBound:()=>q1,variable:()=>j1,where:()=>lo,whereAsync:()=>Qd,zeros:()=>Gr,zerosLike:()=>Ht});var CT=(r,t,e,o=Je)=>{switch(r.op){case\"BiasAdd\":case\"AddV2\":case\"Add\":return[o.add(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"AddN\":return[o.addN(I(\"tensors\",r,t,e))];case\"FloorMod\":case\"Mod\":return[o.mod(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Mul\":return[o.mul(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"RealDiv\":case\"Div\":return[o.div(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"DivNoNan\":return[o.divNoNan(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"FloorDiv\":return[o.floorDiv(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Sub\":return[o.sub(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Minimum\":return[o.minimum(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Maximum\":return[o.maximum(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Pow\":return[o.pow(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"SquaredDifference\":return[o.squaredDifference(I(\"a\",r,t,e),I(\"b\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var wT=(r,t,e,o=Je)=>{switch(r.op){case\"Abs\":case\"ComplexAbs\":return[o.abs(I(\"x\",r,t,e))];case\"Acos\":return[o.acos(I(\"x\",r,t,e))];case\"Acosh\":return[o.acosh(I(\"x\",r,t,e))];case\"Asin\":return[o.asin(I(\"x\",r,t,e))];case\"Asinh\":return[o.asinh(I(\"x\",r,t,e))];case\"Atan\":return[o.atan(I(\"x\",r,t,e))];case\"Atan2\":return[o.atan2(I(\"x\",r,t,e),I(\"y\",r,t,e))];case\"Atanh\":return[o.atanh(I(\"x\",r,t,e))];case\"Ceil\":return[o.ceil(I(\"x\",r,t,e))];case\"Complex\":return[o.complex(I(\"real\",r,t,e),I(\"imag\",r,t,e))];case\"Cos\":return[o.cos(I(\"x\",r,t,e))];case\"Cosh\":return[o.cosh(I(\"x\",r,t,e))];case\"Elu\":return[o.elu(I(\"x\",r,t,e))];case\"Erf\":return[o.erf(I(\"x\",r,t,e))];case\"Exp\":return[o.exp(I(\"x\",r,t,e))];case\"Expm1\":return[o.expm1(I(\"x\",r,t,e))];case\"Floor\":return[o.floor(I(\"x\",r,t,e))];case\"Log\":return[o.log(I(\"x\",r,t,e))];case\"Log1p\":return[o.log1p(I(\"x\",r,t,e))];case\"Imag\":return[o.imag(I(\"x\",r,t,e))];case\"Neg\":return[o.neg(I(\"x\",r,t,e))];case\"Reciprocal\":return[o.reciprocal(I(\"x\",r,t,e))];case\"Real\":return[o.real(I(\"x\",r,t,e))];case\"Relu\":return[o.relu(I(\"x\",r,t,e))];case\"Round\":return[o.round(I(\"x\",r,t,e))];case\"Selu\":return[o.selu(I(\"x\",r,t,e))];case\"Sigmoid\":return[o.sigmoid(I(\"x\",r,t,e))];case\"Sin\":return[o.sin(I(\"x\",r,t,e))];case\"Sign\":return[o.sign(I(\"x\",r,t,e))];case\"Sinh\":return[o.sinh(I(\"x\",r,t,e))];case\"Softplus\":return[o.softplus(I(\"x\",r,t,e))];case\"Sqrt\":return[o.sqrt(I(\"x\",r,t,e))];case\"Square\":return[o.square(I(\"x\",r,t,e))];case\"Tanh\":return[o.tanh(I(\"x\",r,t,e))];case\"Tan\":return[o.tan(I(\"x\",r,t,e))];case\"ClipByValue\":return[o.clipByValue(I(\"x\",r,t,e),I(\"clipValueMin\",r,t,e),I(\"clipValueMax\",r,t,e))];case\"Relu6\":return[o.relu6(I(\"x\",r,t,e))];case\"Rsqrt\":return[o.rsqrt(zt(r.inputNames[0],t,e))];case\"LeakyRelu\":return[o.leakyRelu(I(\"x\",r,t,e),I(\"alpha\",r,t,e))];case\"Prelu\":return[o.prelu(I(\"x\",r,t,e),I(\"alpha\",r,t,e))];case\"IsNan\":return[o.isNaN(zt(r.inputNames[0],t,e))];case\"IsInf\":return[o.isInf(zt(r.inputNames[0],t,e))];case\"IsFinite\":return[o.isFinite(zt(r.inputNames[0],t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};function Hr(r,t,e=\"\"){if(!(typeof r==\"number\"||typeof t==\"number\")){y.assert(r.length===t.length,()=>e+` Shapes ${r} and ${t} must match`);for(let o=0;oe+` Shapes ${r} and ${t} must match`)}}}function ST(r){return!(typeof r==\"number\"||r.some(t=>t<0))}function bc(r,t,e){let o=Sf(r,e),n=!ST(o);if(n&&t.length===0)throw new Error(`Tried to calculate elements of an empty list with non-fully-defined elementShape: ${o}`);if(n&&t.forEach(s=>{o=Sf(s.shape,o)}),!ST(o))throw new Error(`Non-fully-defined elementShape: ${o}`);return o}function Sf(r,t){if(typeof r==\"number\")return t;if(typeof t==\"number\")return r;if(r.length!==t.length)throw new Error(`Incompatible ranks during merge: ${r} vs. ${t}`);let e=[];for(let o=0;o=0&&s>=0&&n!==s)throw new Error(`Incompatible shape during merge: ${r} vs. ${t}`);e[o]=n>=0?n:s}return e}var If=class{constructor(t,e,o,n,s,a,i){this.name=t,this.dtype=e,this.maxSize=o,this.elementShape=n,this.identicalElementShapes=s,this.dynamicSize=a,this.clearAfterRead=i,this.tensors=[],this.closed_=!1,this.idTensor=ke(0),Rr(this.idTensor)}get id(){return this.idTensor.id}get closed(){return this.closed_}clearAndClose(t){this.tensors.forEach(e=>{(t==null||!t.has(e.tensor.id))&&e.tensor.dispose()}),this.tensors=[],this.closed_=!0,this.idTensor.dispose()}size(){return this.tensors.length}read(t){if(this.closed_)throw new Error(`TensorArray ${this.name} has already been closed.`);if(t<0||t>=this.size())throw new Error(`Tried to read from index ${t}, but array size is: ${this.size()}`);let e=this.tensors[t];if(e.cleared)throw new Error(`TensorArray ${this.name}: Could not read index ${t} twice because it was cleared after a previous read (perhaps try setting clear_after_read = false?).`);return this.clearAfterRead&&(e.cleared=!0),e.read=!0,e.tensor}readMany(t){return t.map(e=>this.read(e))}write(t,e){if(this.closed_)throw new Error(`TensorArray ${this.name} has already been closed.`);if(t<0||!this.dynamicSize&&t>=this.maxSize)throw new Error(`Tried to write to index ${t}, but array is not resizeable and size is: ${this.maxSize}`);let o=this.tensors[t]||{};if(e.dtype!==this.dtype)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${t},\n because the value dtype is ${e.dtype}, but TensorArray dtype is ${this.dtype}.`);if(this.size()===0&&(this.elementShape==null||this.elementShape.length===0)&&(this.elementShape=e.shape),Hr(this.elementShape,e.shape,`TensorArray ${this.name}: Could not write to TensorArray index ${t}.`),o.read)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${t}, because it has already been read.`);if(o.written)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${t}, because it has already been written.`);o.tensor=e,Rr(e),o.written=!0,this.tensors[t]=o}writeMany(t,e){if(t.length!==e.length)throw new Error(`TensorArray ${this.name}: could not write multiple tensors,because the index size: ${t.length} is not the same as tensors size: ${e.length}.`);t.forEach((o,n)=>this.write(o,e[n]))}gather(t,e){if(e&&e!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but gather requested dtype ${e}`);if(t)t=t.slice(0,this.size());else{t=[];for(let n=0;n=this.maxSize)throw new Error(`Max index must be < array size (${o} vs. ${this.maxSize})`);this.writeMany(t,fo(e,0))}split(t,e){if(e.dtype!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but tensor has dtype ${e.dtype}`);let o=0,n=t.map(p=>(o+=p,o));if(o!==e.shape[0])throw new Error(`Expected sum of lengths to be equal to\n tensor.shape[0], but sum of lengths is\n ${o}, and tensor's shape is: ${e.shape}`);if(!this.dynamicSize&&t.length!==this.maxSize)throw new Error(`TensorArray's size is not equal to the size of lengths (${this.maxSize} vs. ${t.length}), and the TensorArray is not marked as dynamically resizeable`);let s=o===0?0:e.size/o,a=[];De(()=>{e=W(e,[1,o,s]);for(let p=0;p{if(o!==s.dtype)throw new Error(`Invalid data types; op elements ${o}, but list elements ${s.dtype}`);Hr(e,s.shape,\"TensorList shape mismatch: \"),Rr(s)}),this.idTensor=ke(0),this.maxNumElements=n,Rr(this.idTensor)}copy(){return new hi([...this.tensors],this.elementShape,this.elementDtype)}clearAndClose(t){this.tensors.forEach(e=>{(t==null||!t.has(e.id))&&e.dispose()}),this.tensors.length=0,this.idTensor.dispose()}size(){return this.tensors.length}stack(t,e,o=-1){if(e!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e}, but list elements ${this.elementDtype}`);if(o!==-1&&this.tensors.length!==o)throw new Error(`Operation expected a list with ${o} elements but got a list with ${this.tensors.length} elements.`);Hr(t,this.elementShape,\"TensorList shape mismatch: \");let n=bc(this.elementShape,this.tensors,t);return De(()=>{let s=this.tensors.map(a=>W(a,n));return kr(s,0)})}popBack(t,e){if(e!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e}, but list elements ${this.elementDtype}`);if(this.size()===0)throw new Error(\"Trying to pop from an empty list.\");let o=bc(this.elementShape,this.tensors,t),n=this.tensors.pop();return n.kept=!1,Hr(n.shape,t,\"TensorList shape mismatch: \"),W(n,o)}pushBack(t){if(t.dtype!==this.elementDtype)throw new Error(`Invalid data types; op elements ${t.dtype}, but list elements ${this.elementDtype}`);if(Hr(t.shape,this.elementShape,\"TensorList shape mismatch: \"),this.maxNumElements===this.size())throw new Error(\"Trying to push element into a full list.\");Rr(t),this.tensors.push(t)}resize(t){if(t<0)throw new Error(`TensorListResize expects size to be non-negative. Got: ${t}`);if(this.maxNumElements!==-1&&t>this.maxNumElements)throw new Error(`TensorListResize input size ${t} is greater maxNumElement ${this.maxNumElements}.`);let e=new hi([],this.elementShape,this.elementDtype,this.maxNumElements);e.tensors.length=t;for(let o=0;othis.tensors.length)throw new Error(`Trying to access element ${t} in a list with ${this.tensors.length} elements.`);if(this.tensors[t]==null)throw new Error(`element at index ${t} is null.`);Hr(this.tensors[t].shape,e,\"TensorList shape mismatch: \");let n=bc(this.elementShape,this.tensors,e);return W(this.tensors[t],n)}setItem(t,e){if(e.dtype!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e.dtype}, but list elements ${this.elementDtype}`);if(t<0||this.maxNumElements!==-1&&t>=this.maxNumElements)throw new Error(`Trying to set element ${t} in a list with max ${this.maxNumElements} elements.`);Hr(this.elementShape,e.shape,\"TensorList shape mismatch: \"),Rr(e),this.tensors[t]!=null&&(this.tensors[t].kept=!1),this.tensors[t]=e}gather(t,e,o){if(e!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e}, but list elements ${this.elementDtype}`);Hr(this.elementShape,o,\"TensorList shape mismatch: \"),t=t.slice(0,this.size());let n=bc(this.elementShape,this.tensors,o);return t.length===0?ur([],[0].concat(n)):De(()=>{let s=t.map(a=>W(this.tensors[a],n));return kr(s,0)})}concat(t,e){if(t&&t!==this.elementDtype)throw new Error(`TensorList dtype is ${this.elementDtype} but concat requested dtype ${t}`);Hr(this.elementShape,e,\"TensorList shape mismatch: \");let o=bc(this.elementShape,this.tensors,e);return this.size()===0?ur([],[0].concat(o)):De(()=>{let n=this.tensors.map(s=>W(s,o));return bt(n,0)})}};function IT(r,t,e){let o=r.dtype;if(r.shape.length<1)throw new Error(`Tensor must be at least a vector, but saw shape: ${r.shape}`);if(r.dtype!==e)throw new Error(`Invalid data types; op elements ${r.dtype}, but list elements ${e}`);let n=r.shape.slice(1);Hr(n,t,\"TensorList shape mismatch: \");let s=fo(r);return new hi(s,t,o)}function vT(r,t,e,o){return new hi([],r,t,o)}function kT(r,t,e,o){if(t.length!==r.shape[0])throw new Error(`Expected len(indices) == tensor.shape[0], but saw: ${t.length} vs. ${r.shape[0]}`);let n=Math.max(...t);if(o!=null&&o!==-1&&n>=o)throw new Error(`Max index must be < array size (${n} vs. ${o})`);let s=new hi([],e,r.dtype,o),a=fo(r,0);return t.forEach((i,p)=>{s.setItem(i,a[p])}),s}function NT(r,t,e){let o=0,n=t.map(c=>(o+=c,o));if(o!==r.shape[0])throw new Error(`Expected sum of lengths to be equal to\n tensor.shape[0], but sum of lengths is\n ${o}, and tensor's shape is: ${r.shape}`);let s=r.shape.slice(1),a=Sf(s,e),i=o===0?0:r.size/o,p=De(()=>{let c=[];r=W(r,[1,o,i]);for(let l=0;l{switch(r.op){case\"If\":case\"StatelessIf\":{let o=I(\"thenBranch\",r,t,e),n=I(\"elseBranch\",r,t,e),s=I(\"cond\",r,t,e),a=I(\"args\",r,t,e);return(await s.data())[0]?e.functionMap[o].executeFunctionAsync(a,e.tensorArrayMap,e.tensorListMap):e.functionMap[n].executeFunctionAsync(a,e.tensorArrayMap,e.tensorListMap)}case\"While\":case\"StatelessWhile\":{let o=I(\"body\",r,t,e),n=I(\"cond\",r,t,e),s=I(\"args\",r,t,e),a=await e.functionMap[n].executeFunctionAsync(s,e.tensorArrayMap,e.tensorListMap),i=s.map(c=>c.id),p=await a[0].data();a.forEach(c=>{!c.kept&&i.indexOf(c.id)===-1&&c.dispose()});let u=s;for(;p[0];){let c=u;u=await e.functionMap[o].executeFunctionAsync(u,e.tensorArrayMap,e.tensorListMap);let l=u.map(d=>d.id);c.forEach(d=>{!d.kept&&i.indexOf(d.id)===-1&&l.indexOf(d.id)===-1&&d.dispose()});let m=await e.functionMap[n].executeFunctionAsync(u,e.tensorArrayMap,e.tensorListMap);p=await m[0].data(),m.forEach(d=>{!d.kept&&i.indexOf(d.id)===-1&&l.indexOf(d.id)===-1&&d.dispose()})}return u}case\"LoopCond\":{let o=I(\"pred\",r,t,e);return[Bs(o)]}case\"Switch\":{let o=I(\"pred\",r,t,e),n=I(\"data\",r,t,e);return n.kept||(n=Bs(n)),(await o.data())[0]?[void 0,n]:[n,void 0]}case\"Merge\":{let o=r.inputNames.find(n=>zt(n,t,e)!==void 0);if(o){let n=zt(o,t,e);return[Bs(n)]}return}case\"Enter\":{let o=I(\"frameName\",r,t,e),n=I(\"tensor\",r,t,e);return e.enterFrame(o),[Bs(n)]}case\"Exit\":{let o=I(\"tensor\",r,t,e);return e.exitFrame(),[Bs(o)]}case\"NextIteration\":{let o=I(\"tensor\",r,t,e);return e.nextIteration(),[Bs(o)]}case\"TensorArrayV3\":{let o=I(\"size\",r,t,e),n=I(\"dtype\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"dynamicSize\",r,t,e),i=I(\"clearAfterRead\",r,t,e),p=I(\"identicalElementShapes\",r,t,e),u=I(\"name\",r,t,e),c=new If(u,n,o,s,p,a,i);return e.addTensorArray(c),[c.idTensor,ke(1)]}case\"TensorArrayWriteV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"index\",r,t,e),s=I(\"tensor\",r,t,e),a=e.getTensorArray(o.id);return a.write(n,s),[a.idTensor]}case\"TensorArrayReadV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"index\",r,t,e);return[e.getTensorArray(o.id).read(n)]}case\"TensorArrayGatherV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"indices\",r,t,e),s=I(\"dtype\",r,t,e);return[e.getTensorArray(o.id).gather(n,s)]}case\"TensorArrayScatterV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"indices\",r,t,e),s=I(\"tensor\",r,t,e),a=e.getTensorArray(o.id);return a.scatter(n,s),[a.idTensor]}case\"TensorArrayConcatV3\":{let o=I(\"tensorArrayId\",r,t,e),n=e.getTensorArray(o.id),s=I(\"dtype\",r,t,e);return[n.concat(s)]}case\"TensorArraySplitV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"tensor\",r,t,e),s=I(\"lengths\",r,t,e),a=e.getTensorArray(o.id);return a.split(s,n),[a.idTensor]}case\"TensorArraySizeV3\":{let o=I(\"tensorArrayId\",r,t,e),n=e.getTensorArray(o.id);return[ke(n.size(),\"int32\")]}case\"TensorArrayCloseV3\":{let o=I(\"tensorArrayId\",r,t,e),n=e.getTensorArray(o.id);return n.clearAndClose(),[n.idTensor]}case\"TensorListSetItem\":{let o=I(\"tensorListId\",r,t,e),n=I(\"index\",r,t,e),s=I(\"tensor\",r,t,e),a=e.getTensorList(o.id);return a.setItem(n,s),[a.idTensor]}case\"TensorListGetItem\":{let o=I(\"tensorListId\",r,t,e),n=I(\"index\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"elementDType\",r,t,e);return[e.getTensorList(o.id).getItem(n,s,a)]}case\"TensorListScatterV2\":case\"TensorListScatter\":{let o=I(\"indices\",r,t,e),n=I(\"tensor\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"numElements\",r,t,e),i=kT(n,o,s,a);return e.addTensorList(i),[i.idTensor]}case\"TensorListReserve\":case\"EmptyTensorList\":{let o=I(\"elementShape\",r,t,e),n=I(\"elementDType\",r,t,e),s;r.op===\"TensorListReserve\"?s=\"numElements\":s=\"maxNumElements\";let a=I(s,r,t,e),i=r.op===\"TensorListReserve\"?-1:a,p=vT(o,n,a,i);return e.addTensorList(p),[p.idTensor]}case\"TensorListGather\":{let o=I(\"tensorListId\",r,t,e),n=I(\"indices\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"elementDType\",r,t,e);return[e.getTensorList(o.id).gather(n,a,s)]}case\"TensorListStack\":{let o=I(\"tensorListId\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"elementDType\",r,t,e),a=I(\"numElements\",r,t,e);return[e.getTensorList(o.id).stack(n,s,a)]}case\"TensorListFromTensor\":{let o=I(\"tensor\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"elementDType\",r,t,e),a=IT(o,n,s);return e.addTensorList(a),[a.idTensor]}case\"TensorListConcat\":case\"TensorListConcatV2\":{let o=I(\"tensorListId\",r,t,e),n=e.getTensorList(o.id),s=I(\"dtype\",r,t,e),a=I(\"elementShape\",r,t,e);return[n.concat(s,a)]}case\"TensorListPushBack\":{let o=I(\"tensorListId\",r,t,e),n=I(\"tensor\",r,t,e),s=e.getTensorList(o.id);return s.pushBack(n),[s.idTensor]}case\"TensorListPopBack\":{let o=I(\"tensorListId\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"elementDType\",r,t,e);return[e.getTensorList(o.id).popBack(n,s)]}case\"TensorListSplit\":{let o=I(\"tensor\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"lengths\",r,t,e),a=NT(o,s,n);return e.addTensorList(a),[a.idTensor]}case\"TensorListLength\":{let o=I(\"tensorListId\",r,t,e),n=e.getTensorList(o.id);return[ke(n.size(),\"int32\")]}case\"TensorListResize\":{let o=I(\"tensorListId\",r,t,e),n=I(\"size\",r,t,e),a=e.getTensorList(o.id).resize(n);return e.addTensorList(a),[a.idTensor]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};function _T(r,t,e){let[o,n]=I(\"fusedOps\",r,t,e),s=o===\"biasadd\",a=!s,i=n===\"prelu\",p=o===\"fusedbatchnorm\",u=I(\"numArgs\",r,t,e);if(s){if(i&&u!==2)throw new Error(\"FusedConv2d and DepthwiseConv2d with BiasAdd and Prelu must have two extra arguments: bias and alpha.\");if(!i&&s&&u!==1)throw new Error(\"FusedConv2d and DepthwiseConv2d with BiasAdd must have one extra argument: bias.\")}if(p)throw new Error(\"FusedConv2d and DepthwiseConv2d with FusedBatchNorm is not supported\");let c=I(\"strides\",r,t,e),l=Ol(r,t,e),m=I(\"dataFormat\",r,t,e).toUpperCase(),d=I(\"dilations\",r,t,e),[f,h]=I(\"args\",r,t,e);a&&(h=f,f=void 0);let g=I(\"leakyreluAlpha\",r,t,e);return{stride:c,pad:l,dataFormat:m,dilations:d,biasArg:f,preluArg:h,activationFunc:n,leakyreluAlpha:g}}var $T=(r,t,e,o=Je)=>{switch(r.op){case\"Conv1D\":{let n=I(\"stride\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"dataFormat\",r,t,e).toUpperCase(),i=I(\"dilation\",r,t,e);return[o.conv1d(I(\"x\",r,t,e),I(\"filter\",r,t,e),n,s,a,i)]}case\"Conv2D\":{let n=I(\"strides\",r,t,e),s=Ol(r,t,e),a=I(\"dataFormat\",r,t,e).toUpperCase(),i=I(\"dilations\",r,t,e);return[o.conv2d(I(\"x\",r,t,e),I(\"filter\",r,t,e),[n[1],n[2]],s,a,[i[1],i[2]])]}case\"_FusedConv2D\":{let{stride:n,pad:s,dataFormat:a,dilations:i,biasArg:p,preluArg:u,activationFunc:c,leakyreluAlpha:l}=_T(r,t,e);return[o.fused.conv2d({x:I(\"x\",r,t,e),filter:I(\"filter\",r,t,e),strides:[n[1],n[2]],pad:s,dataFormat:a,dilations:[i[1],i[2]],bias:p,activation:c,preluActivationWeights:u,leakyreluAlpha:l})]}case\"FusedDepthwiseConv2dNative\":{let{stride:n,pad:s,dataFormat:a,dilations:i,biasArg:p,preluArg:u,activationFunc:c,leakyreluAlpha:l}=_T(r,t,e);return[o.fused.depthwiseConv2d({x:I(\"x\",r,t,e),filter:I(\"filter\",r,t,e),strides:[n[1],n[2]],pad:s,dataFormat:a,dilations:[i[1],i[2]],bias:p,activation:c,preluActivationWeights:u,leakyreluAlpha:l})]}case\"Conv2DBackpropInput\":case\"Conv2dTranspose\":{let n=I(\"outputShape\",r,t,e),s=I(\"strides\",r,t,e),a=Ol(r,t,e);return[o.conv2dTranspose(I(\"x\",r,t,e),I(\"filter\",r,t,e),n,[s[1],s[2]],a)]}case\"DepthwiseConv2dNative\":case\"DepthwiseConv2d\":{let n=I(\"strides\",r,t,e),s=Ol(r,t,e),a=I(\"dilations\",r,t,e),i=I(\"dataFormat\",r,t,e).toUpperCase();return[o.depthwiseConv2d(I(\"input\",r,t,e),I(\"filter\",r,t,e),[n[1],n[2]],s,i,[a[1],a[2]])]}case\"Conv3D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"dataFormat\",r,t,e).toUpperCase(),i=I(\"dilations\",r,t,e);return[o.conv3d(I(\"x\",r,t,e),I(\"filter\",r,t,e),[n[1],n[2],n[3]],s,a,[i[1],i[2],i[3]])]}case\"AvgPool\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.avgPool(I(\"x\",r,t,e),[a[1],a[2]],[n[1],n[2]],s)]}case\"MaxPool\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.maxPool(I(\"x\",r,t,e),[a[1],a[2]],[n[1],n[2]],s)]}case\"MaxPoolWithArgmax\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e),i=I(\"includeBatchInIndex\",r,t,e),{result:p,indexes:u}=o.maxPoolWithArgmax(I(\"x\",r,t,e),[a[1],a[2]],[n[1],n[2]],s,i);return[p,u]}case\"AvgPool3D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.avgPool3d(I(\"x\",r,t,e),[a[1],a[2],a[3]],[n[1],n[2],n[3]],s)]}case\"MaxPool3D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.maxPool3d(I(\"x\",r,t,e),[a[1],a[2],a[3]],[n[1],n[2],n[3]],s)]}case\"Dilation2D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"dilations\",r,t,e),i=n[1],p=n[2],u=a[1],c=a[2];return[o.dilation2d(I(\"x\",r,t,e),I(\"filter\",r,t,e),[i,p],s,[u,c],\"NHWC\")]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var ET=(r,t,e,o=Je)=>{switch(r.op){case\"Fill\":{let n=I(\"shape\",r,t,e),s=I(\"dtype\",r,t,e),a=I(\"value\",r,t,e);return[o.fill(n,a,s)]}case\"LinSpace\":{let n=I(\"start\",r,t,e),s=I(\"stop\",r,t,e),a=I(\"num\",r,t,e);return[o.linspace(n,s,a)]}case\"Multinomial\":{let n=I(\"logits\",r,t,e),s=I(\"numSamples\",r,t,e),a=I(\"seed\",r,t,e);return[o.multinomial(n,s,a)]}case\"OneHot\":{let n=I(\"indices\",r,t,e),s=I(\"depth\",r,t,e),a=I(\"onValue\",r,t,e),i=I(\"offValue\",r,t,e),p=I(\"dtype\",r,t,e);return[o.oneHot(n,s,a,i,p)]}case\"Ones\":return[o.ones(I(\"shape\",r,t,e),I(\"dtype\",r,t,e))];case\"OnesLike\":return[o.onesLike(I(\"x\",r,t,e))];case\"RandomStandardNormal\":return[o.randomStandardNormal(I(\"shape\",r,t,e),I(\"dtype\",r,t,e),I(\"seed\",r,t,e))];case\"RandomUniform\":return[o.randomUniform(I(\"shape\",r,t,e),I(\"minval\",r,t,e),I(\"maxval\",r,t,e),I(\"dtype\",r,t,e))];case\"RandomUniformInt\":return[o.randomUniformInt(I(\"shape\",r,t,e),I(\"minval\",r,t,e),I(\"maxval\",r,t,e),I(\"seed\",r,t,e))];case\"Range\":{let n=I(\"start\",r,t,e),s=I(\"stop\",r,t,e),a=I(\"step\",r,t,e);return[o.range(n,s,a,I(\"dtype\",r,t,e))]}case\"TruncatedNormal\":{let n=I(\"shape\",r,t,e),s=I(\"mean\",r,t,e),a=I(\"stdDev\",r,t,e),i=I(\"seed\",r,t,e);return[o.truncatedNormal(n,s,a,I(\"dtype\",r,t,e),i)]}case\"Zeros\":return[o.zeros(I(\"shape\",r,t,e),I(\"dtype\",r,t,e))];case\"ZerosLike\":return[o.zerosLike(I(\"x\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};function PS(r,t,e){let o=I(\"boxes\",r,t,e),n=I(\"scores\",r,t,e),s=I(\"maxOutputSize\",r,t,e),a=I(\"iouThreshold\",r,t,e),i=I(\"scoreThreshold\",r,t,e),p=I(\"softNmsSigma\",r,t,e);return{boxes:o,scores:n,maxOutputSize:s,iouThreshold:a,scoreThreshold:i,softNmsSigma:p}}var RT=async(r,t,e,o,n=Je)=>{switch(r.op){case\"NonMaxSuppressionV5\":{let{boxes:s,scores:a,maxOutputSize:i,iouThreshold:p,scoreThreshold:u,softNmsSigma:c}=PS(r,t,e),l=await n.image.nonMaxSuppressionWithScoreAsync(s,a,i,p,u,c);return[l.selectedIndices,l.selectedScores]}case\"NonMaxSuppressionV4\":{let{boxes:s,scores:a,maxOutputSize:i,iouThreshold:p,scoreThreshold:u}=PS(r,t,e),c=I(\"padToMaxOutputSize\",r,t,e),l=await n.image.nonMaxSuppressionPaddedAsync(s,a,i,p,u,c);return[l.selectedIndices,l.validOutputs]}case\"NonMaxSuppressionV3\":case\"NonMaxSuppressionV2\":{let{boxes:s,scores:a,maxOutputSize:i,iouThreshold:p,scoreThreshold:u}=PS(r,t,e);return[await n.image.nonMaxSuppressionAsync(s,a,i,p,u)]}case\"Where\":{let s=n.cast(I(\"condition\",r,t,e),\"bool\"),a=[await n.whereAsync(s)];return s.dispose(),a}case\"ListDiff\":return n.setdiff1dAsync(I(\"x\",r,t,e),I(\"y\",r,t,e));default:throw TypeError(`Node type ${r.op} is not implemented`)}};var DT=(r,t,e,o=Je)=>{switch(r.op){case\"LowerBound\":{let n=I(\"sortedSequence\",r,t,e),s=I(\"values\",r,t,e);return[o.lowerBound(n,s)]}case\"TopKV2\":{let n=I(\"x\",r,t,e),s=I(\"k\",r,t,e),a=I(\"sorted\",r,t,e),i=o.topk(n,s,a);return[i.values,i.indices]}case\"UpperBound\":{let n=I(\"sortedSequence\",r,t,e),s=I(\"values\",r,t,e);return[o.upperBound(n,s)]}case\"Unique\":{let n=I(\"x\",r,t,e),s=o.unique(n);return[s.values,s.indices]}case\"UniqueV2\":{let n=I(\"x\",r,t,e),s=I(\"axis\",r,t,e),a=o.unique(n,s);return[a.values,a.indices]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var AT=(r,t,e,o=Je)=>{switch(r.op){case\"Const\":return t[r.name];case\"PlaceholderWithDefault\":let n=I(\"default\",r,t,e);return[zt(r.name,t,e)||n];case\"Placeholder\":return[zt(r.name,t,e)];case\"Identity\":case\"StopGradient\":case\"FakeQuantWithMinMaxVars\":{let c=I(\"x\",r,t,e);return[Bs(c)]}case\"IdentityN\":return I(\"x\",r,t,e).map(c=>Bs(c));case\"Snapshot\":let s=I(\"x\",r,t,e);return[Bs(s)];case\"Shape\":return[o.tensor1d(I(\"x\",r,t,e).shape,\"int32\")];case\"ShapeN\":return I(\"x\",r,t,e).map(c=>o.tensor1d(c.shape));case\"Size\":return[o.scalar(I(\"x\",r,t,e).size,\"int32\")];case\"Rank\":return[o.scalar(I(\"x\",r,t,e).rank,\"int32\")];case\"NoOp\":return[o.scalar(1)];case\"Print\":let a=I(\"x\",r,t,e),i=I(\"data\",r,t,e),p=I(\"message\",r,t,e),u=I(\"summarize\",r,t,e);console.warn(\"The graph has a tf.print() operation,usually used for debugging, which slows down performance.\"),console.log(p);for(let c=0;ct.dispose()),this.tensorMap.clear(),this.handle.dispose()}size(){return this.tensorMap.size}tensorSize(){return ke(this.size(),\"int32\")}async import(t,e){this.checkKeyAndValueTensor(t,e);let o=await t.data();return this.tensorMap.forEach(n=>n.dispose()),this.tensorMap.clear(),De(()=>{let n=fo(e),s=o.length,a=n.length;y.assert(s===a,()=>`The number of elements doesn't match, keys has ${s} elements, the values has ${a} elements.`);for(let i=0;i{let n=[];for(let s=0;s{switch(r.op){case\"HashTable\":case\"HashTableV2\":{let n=o.getHashTableHandleByName(r.name);if(n!=null)return[n];{let s=I(\"keyDType\",r,t,e),a=I(\"valueDType\",r,t,e),i=new vf(s,a);return o.addHashTable(r.name,i),[i.handle]}}case\"InitializeTable\":case\"InitializeTableV2\":case\"LookupTableImport\":case\"LookupTableImportV2\":{let n=I(\"tableHandle\",r,t,e,o),s=I(\"keys\",r,t,e),a=I(\"values\",r,t,e);return[await o.getHashTableById(n.id).import(s,a)]}case\"LookupTableFind\":case\"LookupTableFindV2\":{let n=I(\"tableHandle\",r,t,e,o),s=I(\"keys\",r,t,e),a=I(\"defaultValue\",r,t,e);return[await o.getHashTableById(n.id).find(s,a)]}case\"LookupTableSize\":case\"LookupTableSizeV2\":{let n=I(\"tableHandle\",r,t,e,o);return[o.getHashTableById(n.id).tensorSize()]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var PT=(r,t,e,o=Je)=>{switch(r.op){case\"ResizeBilinear\":{let n=I(\"images\",r,t,e),s=I(\"size\",r,t,e),a=I(\"alignCorners\",r,t,e),i=I(\"halfPixelCenters\",r,t,e);return[o.image.resizeBilinear(n,[s[0],s[1]],a,i)]}case\"ResizeNearestNeighbor\":{let n=I(\"images\",r,t,e),s=I(\"size\",r,t,e),a=I(\"alignCorners\",r,t,e),i=I(\"halfPixelCenters\",r,t,e);return[o.image.resizeNearestNeighbor(n,[s[0],s[1]],a,i)]}case\"CropAndResize\":{let n=I(\"image\",r,t,e),s=I(\"boxes\",r,t,e),a=I(\"boxInd\",r,t,e),i=I(\"cropSize\",r,t,e),p=I(\"method\",r,t,e),u=I(\"extrapolationValue\",r,t,e);return[o.image.cropAndResize(n,s,a,i,p,u)]}case\"ImageProjectiveTransformV3\":{let n=I(\"images\",r,t,e),s=I(\"transforms\",r,t,e),a=I(\"outputShape\",r,t,e),i=I(\"fillValue\",r,t,e),p=I(\"interpolation\",r,t,e),u=I(\"fillMode\",r,t,e);return[o.image.transform(n,s,p.toLowerCase(),u.toLowerCase(),i,a)]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var OT=(r,t,e,o=Je)=>{switch(r.op){case\"Equal\":return[o.equal(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"NotEqual\":return[o.notEqual(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Greater\":return[o.greater(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"GreaterEqual\":return[o.greaterEqual(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Less\":return[o.less(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"LessEqual\":return[o.lessEqual(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"LogicalAnd\":return[o.logicalAnd(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"LogicalNot\":return[o.logicalNot(I(\"a\",r,t,e))];case\"LogicalOr\":return[o.logicalOr(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Select\":case\"SelectV2\":return[o.where(I(\"condition\",r,t,e),I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"BitwiseAnd\":return[o.bitwiseAnd(I(\"a\",r,t,e),I(\"b\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var MT=(r,t,e,o=Je)=>{switch(r.op){case\"BatchMatMul\":case\"BatchMatMulV2\":case\"MatMul\":return[o.matMul(I(\"a\",r,t,e),I(\"b\",r,t,e),I(\"transposeA\",r,t,e),I(\"transposeB\",r,t,e))];case\"Einsum\":return[o.einsum(I(\"equation\",r,t,e),...I(\"tensors\",r,t,e))];case\"Transpose\":return[o.transpose(I(\"x\",r,t,e),I(\"perm\",r,t,e))];case\"_FusedMatMul\":let[n,s]=I(\"fusedOps\",r,t,e),a=n===\"biasadd\",i=s===\"prelu\",p=I(\"numArgs\",r,t,e),u=I(\"leakyreluAlpha\",r,t,e);if(a){if(i&&p!==2)throw new Error(\"Fused MatMul with BiasAdd and Prelu must have two extra arguments: bias and alpha.\");if(!i&&p!==1)throw new Error(\"Fused MatMul with BiasAdd must have one extra argument: bias.\")}let[c,l]=I(\"args\",r,t,e);return[o.fused.matMul({a:I(\"a\",r,t,e),b:I(\"b\",r,t,e),transposeA:I(\"transposeA\",r,t,e),transposeB:I(\"transposeB\",r,t,e),bias:c,activation:s,preluActivationWeights:l,leakyreluAlpha:u})];case\"MatrixBandPart\":return[o.linalg.bandPart(I(\"a\",r,t,e),I(\"numLower\",r,t,e),I(\"numUpper\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var LT=(r,t,e,o=Je)=>{switch(r.op){case\"EuclideanNorm\":return[o.euclideanNorm(I(\"x\",r,t,e),I(\"axis\",r,t,e),I(\"keepDims\",r,t,e))];case\"FusedBatchNorm\":case\"FusedBatchNormV2\":return[o.batchNorm(I(\"x\",r,t,e),I(\"mean\",r,t,e),I(\"variance\",r,t,e),I(\"offset\",r,t,e),I(\"scale\",r,t,e),I(\"epsilon\",r,t,e))];case\"FusedBatchNormV3\":return[o.batchNorm(I(\"x\",r,t,e),I(\"mean\",r,t,e),I(\"variance\",r,t,e),I(\"offset\",r,t,e),I(\"scale\",r,t,e),I(\"epsilon\",r,t,e))];case\"LRN\":return[o.localResponseNormalization(I(\"x\",r,t,e),I(\"radius\",r,t,e),I(\"bias\",r,t,e),I(\"alpha\",r,t,e),I(\"beta\",r,t,e))];case\"Softmax\":return[o.softmax(I(\"x\",r,t,e))];case\"LogSoftmax\":return[o.logSoftmax(I(\"x\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var BT=(r,t,e,o=Je)=>{switch(r.op){case\"RaggedGather\":{let{outputNestedSplits:n,outputDenseValues:s}=o.raggedGather(I(\"paramsNestedSplits\",r,t,e),I(\"paramsDenseValues\",r,t,e),I(\"indices\",r,t,e),I(\"outputRaggedRank\",r,t,e));return n.concat(s)}case\"RaggedRange\":{let{rtNestedSplits:n,rtDenseValues:s}=o.raggedRange(I(\"starts\",r,t,e),I(\"limits\",r,t,e),I(\"splits\",r,t,e));return[n,s]}case\"RaggedTensorToTensor\":return[o.raggedTensorToTensor(I(\"shape\",r,t,e),I(\"values\",r,t,e),I(\"defaultValue\",r,t,e),I(\"rowPartitionTensors\",r,t,e),I(\"rowPartitionTypes\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var zT=(r,t,e,o=Je)=>{switch(r.op){case\"Max\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.max(I(\"x\",r,t,e),i,p)]}case\"Mean\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.mean(I(\"x\",r,t,e),i,p)]}case\"Min\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.min(I(\"x\",r,t,e),i,p)]}case\"Sum\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.sum(I(\"x\",r,t,e),i,p)]}case\"All\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.all(I(\"x\",r,t,e),i,p)]}case\"Any\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.any(I(\"x\",r,t,e),i,p)]}case\"ArgMax\":{let i=I(\"axis\",r,t,e);return[o.argMax(I(\"x\",r,t,e),i)]}case\"ArgMin\":{let i=I(\"axis\",r,t,e);return[o.argMin(I(\"x\",r,t,e),i)]}case\"Prod\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.prod(I(\"x\",r,t,e),i,p)]}case\"Cumprod\":{let i=I(\"axis\",r,t,e),p=I(\"exclusive\",r,t,e),u=I(\"reverse\",r,t,e);return[o.cumprod(I(\"x\",r,t,e),i,p,u)]}case\"Cumsum\":{let i=I(\"axis\",r,t,e),p=I(\"exclusive\",r,t,e),u=I(\"reverse\",r,t,e);return[o.cumsum(I(\"x\",r,t,e),i,p,u)]}case\"Bincount\":let n=I(\"x\",r,t,e),s=I(\"weights\",r,t,e),a=I(\"size\",r,t,e);return[o.bincount(n,s,a)];case\"DenseBincount\":{let i=I(\"x\",r,t,e),p=I(\"weights\",r,t,e),u=I(\"size\",r,t,e),c=I(\"binaryOutput\",r,t,e);return[o.denseBincount(i,p,u,c)]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var VT=(r,t,e,o=Je)=>{switch(r.op){case\"ConcatV2\":case\"Concat\":{let n=I(\"n\",r,t,e),s=I(\"axis\",r,t,e),a=I(\"tensors\",r,t,e);return a=a.slice(0,n),[o.concat(a,s)]}case\"Gather\":{let n=I(\"x\",r,t,e),s=I(\"indices\",r,t,e);return[o.gather(n,o.cast(s,\"int32\"),0)]}case\"GatherV2\":{let n=I(\"axis\",r,t,e),s=I(\"batchDims\",r,t,e),a=I(\"x\",r,t,e),i=I(\"indices\",r,t,e);return[o.gather(a,o.cast(i,\"int32\"),n,s)]}case\"Reverse\":{let n=I(\"dims\",r,t,e),s=[];for(let i=0;i{let n=I(\"axis\",r,t,e),s=I(\"tensors\",r,t,e),a=s[0].shape,i=o.squeeze(s[0]).shape,p=s.map(u=>{let c=y.arraysEqual(u.shape,a);if(!c&&!y.arraysEqual(o.squeeze(u).shape,i))throw new Error(\"the input tensors shape does not match\");return c?u:o.reshape(u,a)});return[o.stack(p,n)]});case\"Unpack\":{let n=I(\"axis\",r,t,e),s=I(\"tensor\",r,t,e);return o.unstack(s,n)}case\"Tile\":{let n=I(\"reps\",r,t,e);return[o.tile(I(\"x\",r,t,e),n)]}case\"Split\":case\"SplitV\":{let n=I(\"axis\",r,t,e),s=I(\"numOrSizeSplits\",r,t,e),a=I(\"x\",r,t,e);return o.split(a,s,n)}case\"ScatterNd\":{let n=I(\"indices\",r,t,e),s=I(\"values\",r,t,e),a=I(\"shape\",r,t,e);return[o.scatterND(n,s,a)]}case\"GatherNd\":{let n=I(\"x\",r,t,e),s=I(\"indices\",r,t,e);return[o.gatherND(n,s)]}case\"SparseToDense\":{let n=I(\"sparseIndices\",r,t,e),s=I(\"outputShape\",r,t,e),a=I(\"sparseValues\",r,t,e),i=I(\"defaultValue\",r,t,e);return[o.sparseToDense(n,a,s,a.dtype===i.dtype?i:o.cast(i,a.dtype))]}case\"TensorScatterUpdate\":{let n=I(\"indices\",r,t,e),s=I(\"values\",r,t,e),a=I(\"tensor\",r,t,e);return[o.tensorScatterUpdate(a,n,s)]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var WT=(r,t,e,o=Je)=>{switch(r.op){case\"SparseFillEmptyRows\":{let{outputIndices:n,outputValues:s,emptyRowIndicator:a,reverseIndexMap:i}=o.sparse.sparseFillEmptyRows(I(\"indices\",r,t,e),I(\"values\",r,t,e),I(\"denseShape\",r,t,e),I(\"defaultValue\",r,t,e));return[n,s,a,i]}case\"SparseReshape\":{let{outputIndices:n,outputShape:s}=o.sparse.sparseReshape(I(\"inputIndices\",r,t,e),I(\"inputShape\",r,t,e),I(\"newShape\",r,t,e));return[n,s]}case\"SparseSegmentMean\":return[o.sparse.sparseSegmentMean(I(\"data\",r,t,e),I(\"indices\",r,t,e),I(\"segmentIds\",r,t,e))];case\"SparseSegmentSum\":return[o.sparse.sparseSegmentSum(I(\"data\",r,t,e),I(\"indices\",r,t,e),I(\"segmentIds\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var UT=(r,t,e,o=Je)=>{switch(r.op){case\"FFT\":return[o.fft(I(\"x\",r,t,e))];case\"IFFT\":return[o.ifft(I(\"x\",r,t,e))];case\"RFFT\":return[o.rfft(I(\"x\",r,t,e))];case\"IRFFT\":return[o.irfft(I(\"x\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var GT=(r,t,e,o=Je)=>{switch(r.op){case\"StaticRegexReplace\":return[o.string.staticRegexReplace(I(\"input\",r,t,e),I(\"pattern\",r,t,e),I(\"rewrite\",r,t,e),I(\"replaceGlobal\",r,t,e))];case\"StringNGrams\":{let{nGrams:n,nGramsSplits:s}=o.string.stringNGrams(I(\"data\",r,t,e),I(\"dataSplits\",r,t,e),I(\"separator\",r,t,e),I(\"nGramWidths\",r,t,e),I(\"leftPad\",r,t,e),I(\"rightPad\",r,t,e),I(\"padWidth\",r,t,e),I(\"preserveShortSequences\",r,t,e));return[n,s]}case\"StringSplit\":{let{indices:n,values:s,shape:a}=o.string.stringSplit(I(\"input\",r,t,e),I(\"delimiter\",r,t,e),I(\"skipEmpty\",r,t,e));return[n,s,a]}case\"StringToHashBucketFast\":return[o.string.stringToHashBucketFast(I(\"input\",r,t,e),I(\"numBuckets\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var HT=(r,t,e,o=Je)=>{switch(r.op){case\"Cast\":return[o.cast(I(\"x\",r,t,e),I(\"dtype\",r,t,e))];case\"ExpandDims\":{let n=I(\"axis\",r,t,e);return[o.expandDims(I(\"x\",r,t,e),n)]}case\"Squeeze\":{let n=I(\"axis\",r,t,e);return[o.squeeze(I(\"x\",r,t,e),n)]}case\"Reshape\":return[o.reshape(I(\"x\",r,t,e),I(\"shape\",r,t,e))];case\"EnsureShape\":return[o.ensureShape(I(\"x\",r,t,e),I(\"shape\",r,t,e))];case\"MirrorPad\":return[o.mirrorPad(I(\"x\",r,t,e),I(\"padding\",r,t,e),I(\"mode\",r,t,e))];case\"PadV2\":case\"Pad\":return[o.pad(I(\"x\",r,t,e),I(\"padding\",r,t,e),I(\"constantValue\",r,t,e))];case\"SpaceToBatchND\":{let n=I(\"blockShape\",r,t,e),s=I(\"paddings\",r,t,e);return[o.spaceToBatchND(I(\"x\",r,t,e),n,s)]}case\"BatchToSpaceND\":{let n=I(\"blockShape\",r,t,e),s=I(\"crops\",r,t,e);return[o.batchToSpaceND(I(\"x\",r,t,e),n,s)]}case\"DepthToSpace\":{let n=I(\"blockSize\",r,t,e),s=I(\"dataFormat\",r,t,e).toUpperCase();return[o.depthToSpace(I(\"x\",r,t,e),n,s)]}case\"BroadcastTo\":return[o.broadcastTo(I(\"x\",r,t,e),I(\"shape\",r,t,e))];case\"BroadcastArgs\":return[o.broadcastArgs(I(\"s0\",r,t,e),I(\"s1\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};function OS(r,t,e,o,n=De){let s=((a,i,p)=>{switch(a.category){case\"arithmetic\":return n(()=>CT(a,i,p));case\"basic_math\":return n(()=>wT(a,i,p));case\"control\":return TT(a,i,p);case\"convolution\":return n(()=>$T(a,i,p));case\"creation\":return n(()=>ET(a,i,p));case\"dynamic\":return RT(a,i,p);case\"evaluation\":return n(()=>DT(a,i,p));case\"image\":return n(()=>PT(a,i,p));case\"graph\":return n(()=>AT(a,i,p));case\"logical\":return n(()=>OT(a,i,p));case\"matrices\":return n(()=>MT(a,i,p));case\"normalization\":return n(()=>LT(a,i,p));case\"ragged\":return n(()=>BT(a,i,p));case\"reduction\":return n(()=>zT(a,i,p));case\"slice_join\":return n(()=>VT(a,i,p));case\"sparse\":return n(()=>WT(a,i,p));case\"spectral\":return n(()=>UT(a,i,p));case\"string\":return n(()=>GT(a,i,p));case\"transformation\":return n(()=>HT(a,i,p));case\"hash_table\":return FT(a,i,p,o);case\"custom\":let u=pf(a.op);if(u&&u.customExecutor)return u.customExecutor(new wf(a,i,p));throw TypeError(`Custom op ${a.op} is not registered.`);default:throw TypeError(`Unknown op '${a.op}'. File an issue at https://github.com/tensorflow/tfjs/issues so we can add it, or register a custom execution with tf.registerOp()`)}})(r,t,e);return y.isPromise(s)?s.then(a=>[].concat(a)):[].concat(s)}var Ll=class{constructor(t={},e={},o={},n={},s){this.weightMap=t,this.tensorArrayMap=e,this.tensorListMap=o,this.functionMap=n,this.parseNodeNameCache=s,this.rootContext={id:0,frameName:\"\",iterationId:0},this.contexts=[this.rootContext],this.lastId=0,this.generateCurrentContextIds()}newFrame(t,e){return{id:t,frameName:e,iterationId:0}}set currentContext(t){this.contexts!==t&&(this.contexts=t,this.generateCurrentContextIds())}get currentContext(){return this.contexts}get currentContextId(){return this._currentContextIds[0]}get currentContextIds(){return this._currentContextIds}generateCurrentContextIds(){let t=[];for(let e=0;ee.id===0&&e.iterationId===0?\"\":`${e.frameName}-${e.iterationId}`).join(\"/\"):\"\"}enterFrame(t){this.contexts&&(this.lastId++,this.contexts=this.contexts.slice(),this.contexts.push(this.newFrame(this.lastId,t)),this._currentContextIds.unshift(this.contextIdforContexts(this.contexts)))}exitFrame(){if(this.contexts&&this.contexts.length>1)this.contexts=this.contexts.slice(),this.contexts.splice(-1),this.currentContextIds.shift();else throw new Error(\"Cannot exit frame, the context is empty\")}nextIteration(){if(this.contexts&&this.contexts.length>0){this.contexts=this.contexts.slice(),this.lastId++;let t=Object.assign({},this.contexts[this.contexts.length-1]);t.iterationId+=1,t.id=this.lastId,this.contexts.splice(-1,1,t),this._currentContextIds.splice(0,1,this.contextIdforContexts(this.contexts))}else throw new Error(\"Cannot increase frame iteration, the context is empty\")}getWeight(t){return this.weightMap[t]}addTensorArray(t){this.tensorArrayMap[t.id]=t}getTensorArray(t){return this.tensorArrayMap[t]}addTensorList(t){this.tensorListMap[t.id]=t}getTensorList(t){return this.tensorListMap[t]}dispose(t){for(let e in this.tensorArrayMap)this.tensorArrayMap[e].clearAndClose(t);for(let e in this.tensorListMap)this.tensorListMap[e].clearAndClose(t)}};function MS(r,t,e,o){let n=new Set,s=[],a=null,i=null,p=new Set,u=new Set(Object.keys(r).map(m=>Tr(m)[0]));o=o||[];let c=new Set(o.map(m=>Tr(m.name)[0])),l=[...t];for(;l.length>0;){let m=l.pop();if((gu(m)||k8(m)||N8(m))&&a==null&&(a=m,i=a.children.map(d=>d.name).filter(d=>n.has(d))),n.add(m.name),e[m.name]==null&&!u.has(m.name)&&!c.has(m.name)){if(m.inputs.length===0){s.push(m.name);continue}m.inputs.forEach(d=>{p.has(d.name)||(p.add(d.name),l.push(d))})}}return{inputs:r,outputs:t,usedNodes:n,missingInputs:s,dynamicNode:a,syncInputs:i}}function KT(r,t){let{usedNodes:e,inputs:o}=t,n=Object.keys(o).map(g=>Tr(g)[0]).map(g=>r.nodes[g]),s=r.initNodes||[],a=g=>e.has(typeof g==\"string\"?g:g.name);function i(g){return[...new Map(g.map(x=>[x.name,x])).values()]}let p=i([...n,...r.weights,...s]).filter(a),u=i([...p,...Object.values(r.nodes)]).filter(a),c=new Map(u.map(g=>[g.name,g])),l={};for(let g of u){l[g.name]=l[g.name]||0;for(let x of g.children)a(x)||(l[x.name]=Number.POSITIVE_INFINITY),l[x.name]=(l[x.name]||0)+1}let m=Object.entries(l).filter(([,g])=>g===0).map(([g])=>g),d=[...m];for(;m.length>0;){let g=m.pop(),x=c.get(g);for(let b of x.children.filter(a))--l[b.name]===0&&(d.push(b.name),m.push(b.name))}let f=d.map(g=>c.get(g)),h=C8(f,p);return w8(h,p),h}function C8(r,t){let e=new Map(r.map(a=>[a.name,a])),o=t.map(a=>a.name),n=new Set(o);for(;o.length>0;){let a=o.pop(),i=e.get(a);for(let p of i.children)!e.has(p.name)||n.has(p.name)||(n.add(p.name),o.push(p.name))}return r.filter(a=>n.has(a.name))}var Cc=class extends Error{constructor(t){super(`NodesExecutionOrderError: ${t}`)}};function w8(r,t){let e=new Map(r.map((i,p)=>[i.name,p])),o=new Set(t.map(i=>i.name)),n=i=>o.has(typeof i==\"string\"?i:i.name),s=new Set(r.map(i=>i.name)),a=i=>s.has(typeof i==\"string\"?i:i.name);for(let i of r){for(let p of i.children.filter(a)){if(!e.has(p.name))throw new Cc(`Child ${p.name} of node ${i.name} is unreachable.`);if(e.get(i.name)>e.get(p.name))throw new Cc(`Node ${i.name} is scheduled to run after its child ${p.name}.`)}if(!n(i))for(let p of i.inputs){if(!e.has(p.name))throw new Cc(`Input ${p.name} of node ${i.name} is unreachable.`);if(e.get(p.name)>e.get(i.name))throw new Cc(`Node ${i.name} is scheduled to run before its input ${p.name}.`)}}}function qT(r){let t=new Map(r.map((i,p)=>[i.name,p])),e=Number.MAX_SAFE_INTEGER,o=r.map((i,p)=>gu(i)?e:p),n=i=>{let p=o[t.get(i.name)];return p==null?-1:p},s=r.map((i,p)=>i.children.map(n).reduce((u,c)=>Math.max(u,c),o[p])),a=new Map;for(let i=0;it[o].map(n=>n.id));this._weightIds=[].concat(...e),this._weightMap=t}set resourceManager(t){this._resourceManager=t}get inputs(){return this._inputs.map(t=>({name:t.name,shape:t.attrParams.shape?t.attrParams.shape.value:void 0,dtype:t.attrParams.dtype?t.attrParams.dtype.value:void 0}))}get outputs(){return this._outputs.map(t=>({name:t.name,shape:t.attrParams.shape?t.attrParams.shape.value:void 0,dtype:t.attrParams.dtype?t.attrParams.dtype.value:void 0}))}get inputNodes(){return this._inputs.map(t=>t.signatureKey||t.name)}get outputNodes(){return this._outputs.map(t=>{let e=t.signatureKey||t.name;return t.defaultOutput?`${e}:${t.defaultOutput}`:e})}get functions(){return Object.keys(this._functions).reduce((t,e)=>(t[e]=this._functions[e].signature,t),{})}constructor(t,e){this.graph=t,this.parent=e,this.compiledMap=new Map,this.parseNodeNameCache=new Map,this._weightMap={},this.SEPARATOR=\",\",this._functions={},this._functionExecutorMap={},this.keepIntermediateTensors=!1,this._outputs=t.outputs,this._inputs=t.inputs,this._initNodes=t.initNodes,this._signature=t.signature,this._functions=t.functions,t.functions!=null&&Object.keys(t.functions).forEach(o=>{this._functionExecutorMap[o]=new lp(t.functions[o],this)})}getCompilationKey(t,e){let o=t.map(s=>s.name).sort(),n=e.map(s=>s.name).sort();return o.join(this.SEPARATOR)+\"--\"+n.join(this.SEPARATOR)}compile(t,e){let o=MS(t,e,this.weightMap,this._initNodes),{missingInputs:n,dynamicNode:s,syncInputs:a}=o;if(s!=null)throw new Error(`This execution contains the node '${s.name}', which has the dynamic op '${s.op}'. Please use model.executeAsync() instead. Alternatively, to avoid the dynamic ops, specify the inputs [${a}]`);if(n.length>0){let u=e.map(l=>l.name),c=Object.keys(t);throw new Error(`Cannot compute the outputs [${u}] from the provided inputs [${c}]. Missing the following inputs: [${n}]`)}let i=KT(this.graph,o),p=qT(i);return{orderedNodes:i,nodeLiveUntilMap:p}}cloneAndKeepTensor(t){if(t==null)return null;let e=t.clone();return Rr(e),e}cloneTensorList(t){return t?t.map(o=>this.cloneAndKeepTensor(o)):null}cloneTensorMap(t){return Object.fromEntries(Object.entries(t).map(([e,o])=>[e,this.cloneTensorList(o)]))}execute(t,e){this.disposeIntermediateTensors(),t=this.mapInputs(t);let o=Object.keys(t).sort();this.checkInputs(t),this.checkInputShapeAndType(t),e=this.mapOutputs(e),this.checkOutputs(e);let n=o.map(m=>this.graph.nodes[Tr(m)[0]]),s=e.map(m=>Tr(m)[0]),a=new Set(s),i=s.map(m=>this.graph.nodes[m]);i.length===0&&(i=this._outputs);let p=this.getCompilationKey(n,i),u=this.compiledMap.get(p);u==null&&(u=this.compile(t,i),this.compiledMap.set(p,u));try{this.keepIntermediateTensors=A().getBool(\"KEEP_INTERMEDIATE_TENSORS\")}catch(m){this.keepIntermediateTensors=!1,console.warn(m.message)}let c={},l={};return De(()=>{let m=new Ll(this.weightMap,c,l,this.functionExecutorMap,this.parseNodeNameCache),d=Object.assign({},this.weightMap);this.keepIntermediateTensors&&(this.clonedTensorsMap=this.cloneTensorMap(this.weightMap)),Object.keys(t).forEach(x=>{let[b,C]=Tr(x,m),S=[];S[C]=t[x],d[b]=S,this.keepIntermediateTensors&&(this.clonedTensorsMap[b]=this.cloneTensorList(S))});let f=this.getFrozenTensorIds(d),{orderedNodes:h,nodeLiveUntilMap:g}=u;for(let x of h){if(d[x.name])continue;let b=OS(x,d,m,this._resourceManager);if(y.isPromise(b))throw new Error(`The execution of the op '${x.op}' returned a promise. Please use model.executeAsync() instead.`);d[x.name]=b,this.keepIntermediateTensors&&(this.clonedTensorsMap[x.name]=this.cloneTensorList(b)),this.checkTensorForDisposalWithNodeLiveUntilInfo(x,d,m,f,a,g.get(x.name))}return this.parent==null&&m.dispose(f),e.map(x=>zt(x,d,m))})}getFrozenTensorIds(t){let e=[].concat.apply([],Object.keys(t).map(o=>t[o]).map(o=>o.map(n=>n.id)));return new Set(e)}checkTensorForDisposal(t,e,o,n,s,a,i){if(!(gu(e)||a.has(t))){for(let p of o[t])p!=null&&(i[p.id]=(i[p.id]||0)+e.children.length);for(let p of e.inputs){if(gu(p))continue;let u=fS(p.name,o,n);if(u!=null)for(let c of u){if(!c||c.kept||s.has(c.id))continue;let l=i[c.id];l===1?(c.dispose(),delete i[c.id]):l!=null&&i[c.id]--}}}}checkTensorForDisposalWithNodeLiveUntilInfo(t,e,o,n,s,a){function i(p){return gu(p)||s.has(p.name)}if(!(gu(t)||a==null))for(let p of a){if(i(p))continue;let u=fS(p.name,e,o);for(let c of u)!c||c.kept||n.has(c.id)||c.dispose()}}async executeAsync(t,e){return this._executeAsync(t,e)}disposeIntermediateTensors(){this.clonedTensorsMap&&(Object.values(this.clonedTensorsMap).forEach(t=>{for(let e of t)e&&!e.isDisposed&&e.dispose()}),this.clonedTensorsMap=null)}getIntermediateTensors(){return this.clonedTensorsMap}async _executeAsync(t,e,o=!1,n={},s={}){this.disposeIntermediateTensors(),o||(t=this.mapInputs(t),this.checkInputs(t),this.checkInputShapeAndType(t),e=this.mapOutputs(e),this.checkOutputs(e));try{this.keepIntermediateTensors=A().getBool(\"KEEP_INTERMEDIATE_TENSORS\")}catch(m){this.keepIntermediateTensors=!1,console.warn(m.message)}let a=new Ll(this.weightMap,n,s,this.functionExecutorMap,this.parseNodeNameCache);this.keepIntermediateTensors&&(this.clonedTensorsMap=this.cloneTensorMap(this.weightMap));let i=await this.executeWithControlFlow(t,a,e,o),p=e.map(m=>zt(m,i,a)),u=p.map(m=>m.id),c=Object.keys(t).map(m=>t[m].id),l=new Set([...u,...c,...this.weightIds]);return Object.values(i).forEach(m=>{m.forEach(d=>{d&&!d.isDisposed&&!l.has(d.id)&&d.dispose()})}),this.parent==null&&a.dispose(l),p}async executeFunctionAsync(t,e,o){let n=t.reduce((s,a,i)=>(s[this.inputs[i].name]=a,s),{});return this._executeAsync(n,this.outputNodes,!0,e,o)}async executeWithControlFlow(t,e,o,n){let s=Object.keys(t),a=s.map(S=>this.graph.nodes[Tr(S)[0]]),i=o.map(S=>Tr(S)[0]),p=new Set(i),u=i.map(S=>this.graph.nodes[S]);u.length===0&&(u=this._outputs);let{usedNodes:c,missingInputs:l,dynamicNode:m,syncInputs:d}=MS(t,u,this.weightMap,this._initNodes),f=[...a,...this.graph.weights,...this._initNodes||[]].map(S=>({node:S,contexts:e.currentContext})),h=Object.assign({},this.weightMap);Object.keys(t).forEach(S=>{let[k,_]=Tr(S),E=[];E[_]=t[S],h[k]=E});let g={},x=this.getFrozenTensorIds(h),b={};for(;f.length>0;){let S=this.processStack(a,f,e,h,b,x,p,g,c);await Promise.all(S)}m==null&&!n&&console.warn(\"This model execution did not contain any nodes with control flow or dynamic output shapes. You can use model.execute() instead.\");let C=u.filter(S=>!gu(S)&&!zt(S.name,h,e)).map(S=>S.name);if(C.length>0){let S=\"\";throw m!=null&&(S=`Alternatively, to avoid the dynamic ops, use model.execute() and specify the inputs [${d}]`),new Error(`Cannot compute the outputs [${C}] from the provided inputs [${s}]. Consider providing the following inputs: [${l}]. ${S}`)}return h}processStack(t,e,o,n,s,a,i,p,u){let c=[];for(;e.length>0;){let l=e.pop();o.currentContext=l.contexts;let m=\"\";if(l.node.op===\"Enter\"&&I(\"isConstant\",l.node,n,o)&&([m]=Ls(l.node.name,o)),n[l.node.name]==null){let d=OS(l.node,n,o,this._resourceManager);m||([m]=Ls(l.node.name,o));let f=o.currentContext;y.isPromise(d)?c.push(d.then(h=>(n[m]=h,this.keepIntermediateTensors&&(this.clonedTensorsMap[m]=this.cloneTensorList(h)),o.currentContext=f,this.checkTensorForDisposal(m,l.node,n,o,a,i,p),this.processChildNodes(l.node,e,o,n,s,u),h))):(n[m]=d,this.keepIntermediateTensors&&(this.clonedTensorsMap[m]=this.cloneTensorList(d)),this.checkTensorForDisposal(m,l.node,n,o,a,i,p),this.processChildNodes(l.node,e,o,n,s,u))}else this.processChildNodes(l.node,e,o,n,s,u)}return c}processChildNodes(t,e,o,n,s,a){t.children.forEach(i=>{let[p]=Ls(i.name,o);s[p]||!a.has(i.name)||(i.op===\"Merge\"?i.inputNames.some(u=>!!zt(u,n,o))&&(s[p]=!0,e.push({contexts:o.currentContext,node:i})):i.inputNames.every(u=>!!zt(u,n,o))&&(s[p]=!0,e.push({contexts:o.currentContext,node:i})))})}dispose(){Object.keys(this.weightMap).forEach(t=>this.weightMap[t].forEach(e=>e.dispose()))}checkInputShapeAndType(t){Object.keys(t).forEach(e=>{let o=t[e],[n]=Tr(e),s=this.graph.nodes[n];if(s.attrParams.shape&&s.attrParams.shape.value){let a=s.attrParams.shape.value,i=a.length===o.shape.length&&o.shape.every((p,u)=>a[u]===-1||a[u]===p);y.assert(i,()=>`The shape of dict['${s.name}'] provided in model.execute(dict) must be [${a}], but was [${o.shape}]`)}s.attrParams.dtype&&s.attrParams.dtype.value&&y.assert(o.dtype===s.attrParams.dtype.value,()=>`The dtype of dict['${s.name}'] provided in model.execute(dict) must be ${s.attrParams.dtype.value}, but was ${o.dtype}`)})}mapInputs(t){var e,o;let n={};for(let s in t){let a=(o=(e=this._signature)===null||e===void 0?void 0:e.inputs)===null||o===void 0?void 0:o[s];a!=null?n[a.name]=t[s]:n[s]=t[s]}return n}checkInputs(t){let e=Object.keys(t).filter(o=>{let[n]=Tr(o);return this.graph.nodes[n]==null});if(e.length>0)throw new Error(`The dict provided in model.execute(dict) has keys: [${e}] that are not part of graph`)}mapOutputs(t){return t.map(e=>{var o,n;let s=(n=(o=this._signature)===null||o===void 0?void 0:o.outputs)===null||n===void 0?void 0:n[e];return s!=null?s.name:e},{})}checkOutputs(t){t.forEach(e=>{let[o]=Tr(e);if(!this.graph.nodes[o])throw new Error(`The output '${e}' is not found in the graph`)})}};var kf=class{constructor(t={},e={}){this.hashTableNameToHandle=t,this.hashTableMap=e}addHashTable(t,e){this.hashTableNameToHandle[t]=e.handle,this.hashTableMap[e.id]=e}getHashTableHandleByName(t){return this.hashTableNameToHandle[t]}getHashTableById(t){return this.hashTableMap[t]}dispose(){for(let t in this.hashTableMap)this.hashTableMap[t].clearAndClose(),delete this.hashTableMap[t];for(let t in this.hashTableNameToHandle)this.hashTableNameToHandle[t].dispose(),delete this.hashTableNameToHandle[t]}};var T8=\"?tfjs-format=file\",_8=\"model.json\",Bl=class{get modelVersion(){return this.version}get inputNodes(){return this.executor.inputNodes}get outputNodes(){return this.executor.outputNodes}get inputs(){return this.executor.inputs}get outputs(){return this.executor.outputs}get weights(){return this.executor.weightMap}get metadata(){return this.artifacts.userDefinedMetadata}get modelSignature(){return this.signature}get modelStructuredOutputKeys(){return this.structuredOutputKeys}constructor(t,e={},o=fi){this.modelUrl=t,this.loadOptions=e,this.version=\"n/a\",this.io=o,e==null&&(this.loadOptions={}),this.resourceManager=new kf}findIOHandler(){let t=this.modelUrl;if(t.load!=null)this.handler=t;else if(this.loadOptions.requestInit!=null)this.handler=this.io.browserHTTPRequest(t,this.loadOptions);else{let e=this.io.getLoadHandlers(t,this.loadOptions);if(e.length===0)e.push(this.io.browserHTTPRequest(t,this.loadOptions));else if(e.length>1)throw new Error(`Found more than one (${e.length}) load handlers for URL '${[t]}'`);this.handler=e[0]}}load(){if(this.findIOHandler(),this.handler.load==null)throw new Error(\"Cannot proceed with model loading because the IOHandler provided does not have the `load` method implemented.\");let t=this.handler.load();return y.isPromise(t)?t.then(e=>this.loadSync(e)):this.loadSync(t)}loadSync(t){this.artifacts=t;let e=this.artifacts.modelTopology,o=this.artifacts.signature;if(this.artifacts.userDefinedMetadata!=null){let s=this.artifacts.userDefinedMetadata;s.signature!=null&&(o=s.signature),s.structuredOutputKeys!=null&&(this.structuredOutputKeys=s.structuredOutputKeys)}this.signature=o,this.version=`${e.versions.producer}.${e.versions.minConsumer}`;let n=this.io.decodeWeights(this.artifacts.weightData,this.artifacts.weightSpecs);if(this.executor=new lp(Ml.Instance.transformGraph(e,this.signature)),this.executor.weightMap=this.convertTensorMapToTensorsMap(n),this.executor.resourceManager=this.resourceManager,t.modelInitializer!=null&&t.modelInitializer.node!=null){let s=Ml.Instance.transformGraph(t.modelInitializer);this.initializer=new lp(s),this.initializer.weightMap=this.executor.weightMap,this.initializer.resourceManager=this.resourceManager,this.initializerSignature=t.initializerSignature}return!0}async save(t,e){if(typeof t==\"string\"){let o=this.io.getSaveHandlers(t);if(o.length===0)throw new Error(`Cannot find any save handlers for URL '${t}'`);if(o.length>1)throw new Error(`Found more than one (${o.length}) save handlers for URL '${t}'`);t=o[0]}if(t.save==null)throw new Error(\"GraphModel.save() cannot proceed because the IOHandler provided does not have the `save` attribute defined.\");return t.save(this.artifacts)}addStructuredOutputNames(t){if(this.structuredOutputKeys){let e=t instanceof ut?[t]:t,o={};return e.forEach((n,s)=>o[this.structuredOutputKeys[s]]=n),o}return t}predict(t,e){let o=this.execute(t,this.outputNodes);return this.addStructuredOutputNames(o)}async predictAsync(t,e){let o=await this.executeAsync(t,this.outputNodes);return this.addStructuredOutputNames(o)}normalizeInputs(t){var e;if(!(t instanceof ut)&&!Array.isArray(t)){let s=(e=this.signature)===null||e===void 0?void 0:e.inputs;if(s!=null)for(let a in s){let i=s[a];i.resourceId!=null&&(t[a]=this.resourceIdToCapturedInput[i.resourceId])}return t}t=Array.isArray(t)?t:[t];let o=Object.keys(this.resourceIdToCapturedInput).length;if(t.length+o!==this.inputNodes.length)throw new Error(`Input tensor count mismatch, the graph model has ${this.inputNodes.length-o} non-resource placeholders, while there are ${t.length} input tensors provided.`);let n=0;return this.inputNodes.reduce((s,a)=>{var i,p,u;let c=(u=(p=(i=this.signature)===null||i===void 0?void 0:i.inputs)===null||p===void 0?void 0:p[a])===null||u===void 0?void 0:u.resourceId;return c!=null?s[a]=this.resourceIdToCapturedInput[c]:s[a]=t[n++],s},{})}normalizeOutputs(t){return t=t||this.outputNodes,Array.isArray(t)?t:[t]}executeInitializerGraph(){return this.initializer==null?[]:this.initializerSignature==null?this.initializer.execute({},[]):this.initializer.execute({},Object.keys(this.initializerSignature.outputs))}async executeInitializerGraphAsync(){return this.initializer==null?[]:this.initializerSignature==null?this.initializer.executeAsync({},[]):this.initializer.executeAsync({},Object.keys(this.initializerSignature.outputs))}setResourceIdToCapturedInput(t){if(this.resourceIdToCapturedInput={},this.initializerSignature){let e=this.initializerSignature.outputs,o=Object.keys(e);for(let n=0;n1?o:o[0]}async executeAsync(t,e){this.resourceIdToCapturedInput==null&&this.setResourceIdToCapturedInput(await this.executeInitializerGraphAsync()),t=this.normalizeInputs(t),e=this.normalizeOutputs(e);let o=await this.executor.executeAsync(t,e);return o.length>1?o:o[0]}getIntermediateTensors(){return this.executor.getIntermediateTensors()}disposeIntermediateTensors(){this.executor.disposeIntermediateTensors()}convertTensorMapToTensorsMap(t){return Object.keys(t).reduce((e,o)=>(e[o]=[t[o]],e),{})}dispose(){this.executor.dispose(),this.initializer&&(this.initializer.dispose(),this.resourceIdToCapturedInput&&Mt(this.resourceIdToCapturedInput)),this.resourceManager.dispose()}};async function $8(r,t={},e=fi){if(r==null)throw new Error(\"modelUrl in loadGraphModel() cannot be null. Please provide a url or an IOHandler that loads the model\");t==null&&(t={}),t.fromTFHub&&typeof r==\"string\"&&(r=R8(r));let o=new Bl(r,t,e);return await o.load(),o}function E8(r){if(r==null)throw new Error(\"modelUrl in loadGraphModelSync() cannot be null. Please provide model artifacts or an IOHandler that loads the model\");let t;if(r instanceof Array){let[o,n]=r;if(!o)throw new Error(\"modelJSON must be the first element of the array\");if(!n||!(n instanceof ArrayBuffer))throw new Error(\"An ArrayBuffer of weights must be the second element of the array\");if(!(\"modelTopology\"in o))throw new Error(\"Model JSON is missing 'modelTopology'\");if(!(\"weightsManifest\"in o))throw new Error(\"Model JSON is missing 'weightsManifest'\");let s=fi.getWeightSpecs(o.weightsManifest),a=fi.getModelArtifactsForJSONSync(o,s,n);t=fi.fromMemorySync(a)}else if(\"load\"in r)t=r;else if(\"modelTopology\"in r&&\"weightSpecs\"in r&&\"weightData\"in r)t=fi.fromMemorySync(r);else throw new Error(\"Unknown model format\");let e=new Bl(t);return e.load(),e}function R8(r){return r.endsWith(\"/\")||(r=r+\"/\"),`${r}${_8}${T8}`}var D8=\"4.11.0\";function Q(r,t){Array.isArray(r)||(r=[r]),r.forEach(e=>{e!=null&&y.assert(e.dtype!==\"complex64\",()=>`${t} does not support complex64 tensors in the CPU backend.`)})}var A8=Wt.whereImpl,xu=class extends ao{nextDataId(){return xu.nextDataId++}constructor(){super(),this.blockSize=48,this.firstUse=!0,this.data=new zo(this,pr())}write(t,e,o){this.firstUse&&(this.firstUse=!1,A().get(\"IS_NODE\")&&w.warn(`\n============================\nHi, looks like you are running TensorFlow.js in Node.js. To speed things up dramatically, install our node backend, visit https://github.com/tensorflow/tfjs-node for more details. \n============================`));let n={id:this.nextDataId()};return this.data.set(n,{values:t,dtype:o,refCount:1}),n}makeTensorInfo(t,e,o){let n;if(e===\"string\"&&o!=null&&o.length>0&&y.isString(o[0])){let s=o.map(a=>y.encodeString(a));n=this.write(s,t,e)}else n=this.write(o,t,e);return{dataId:n,shape:t,dtype:e}}refCount(t){return this.data.has(t)?this.data.get(t).refCount:0}incRef(t){let e=this.data.get(t);e.refCount++}decRef(t){if(this.data.has(t)){let e=this.data.get(t);e.refCount--}}move(t,e,o,n,s){this.data.set(t,{values:e,dtype:n,refCount:s})}numDataIds(){return this.data.numDataIds()}async read(t){return this.readSync(t)}readSync(t){let{dtype:e,complexTensorInfos:o}=this.data.get(t);if(e===\"complex64\"){let n=this.readSync(o.real.dataId),s=this.readSync(o.imag.dataId);return w.mergeRealAndImagArrays(n,s)}return y.convertBackendValuesAndArrayBuffer(this.data.get(t).values,e)}bufferSync(t){let e=this.readSync(t.dataId);if(t.dtype===\"string\")try{let o=e.map(n=>y.decodeString(n));return me(t.shape,t.dtype,o)}catch(o){throw new Error(\"Failed to decode encoded string bytes into utf-8\")}return me(t.shape,t.dtype,e)}makeOutput(t,e,o){return pr().makeTensorFromTensorInfo(this.makeTensorInfo(e,o,t),this)}disposeData(t,e=!1){if(this.data.has(t)){if(this.data.get(t).refCount--,!e&&this.data.get(t).refCount>0)return!1;let{complexTensorInfos:o}=this.data.get(t);o!=null&&(this.disposeData(o.real.dataId,!0),this.disposeData(o.imag.dataId,!0)),this.data.delete(t)}return!0}disposeIntermediateTensorInfo(t){this.disposeData(t.dataId)}async time(t){let e=y.now();return t(),{kernelMs:y.now()-e}}memory(){return{unreliable:!0,reasons:[\"The reported memory is an upper bound. Due to automatic garbage collection, the true allocated memory may be less.\"]}}where(t){Q([t],\"where\");let e=this.readSync(t.dataId);return A8(t.shape,e)}dispose(){}floatPrecision(){return 32}epsilon(){return super.epsilon()}};xu.nextDataId=0;var Tc={};qe(Tc,{addImpl:()=>zS,bincountImpl:()=>Ic,bincountReduceImpl:()=>Nf,bitwiseAndImpl:()=>VS,castImpl:()=>BS,ceilImpl:()=>WS,concatImpl:()=>mp,equalImpl:()=>US,expImpl:()=>HS,expm1Impl:()=>qS,floorDivImpl:()=>XS,floorImpl:()=>jS,gatherNdImpl:()=>Tf,gatherV2Impl:()=>_f,greaterEqualImpl:()=>QS,greaterImpl:()=>YS,lessEqualImpl:()=>JS,lessImpl:()=>ZS,linSpaceImpl:()=>$f,logImpl:()=>eI,maxImpl:()=>Ef,maximumImpl:()=>tI,minimumImpl:()=>rI,multiplyImpl:()=>zl,negImpl:()=>oI,notEqualImpl:()=>nI,prodImpl:()=>sI,raggedGatherImpl:()=>Rf,raggedRangeImpl:()=>Df,raggedTensorToTensorImpl:()=>Af,rangeImpl:()=>fp,rsqrtImpl:()=>aI,scatterImpl:()=>zs,sigmoidImpl:()=>v_,simpleAbsImpl:()=>LS,sliceImpl:()=>hp,sparseFillEmptyRowsImpl:()=>Ff,sparseReshapeImpl:()=>Pf,sparseSegmentReductionImpl:()=>Nc,sqrtImpl:()=>T_,squaredDifferenceImpl:()=>uI,staticRegexReplaceImpl:()=>pI,stridedSliceImpl:()=>Of,stringNGramsImpl:()=>gp,stringSplitImpl:()=>xp,stringToHashBucketFastImpl:()=>yp,subImpl:()=>lI,tileImpl:()=>Mf,topKImpl:()=>Lf,transposeImpl:()=>vc,uniqueImpl:()=>bp});function LS(r){let t=new Float32Array(r.length);for(let e=0;e{let{x:t}=r.inputs,e=r.backend;Q(t,\"abs\");let o=new Float32Array(y.sizeFromShape(t.shape)),n=e.data.get(t.dataId).values;return o=LS(n),e.makeOutput(o,t.shape,t.dtype)},jT={kernelName:Xs,backendName:\"cpu\",kernelFunc:F8};function ze(r){return(t,e,o,n,s)=>{let a=w.assertAndGetBroadcastShape(t,e),i=a.length,p=y.computeStrides(a),u=y.sizeFromShape(a),c=y.getTypedArrayFromDType(s,u),l=t.length,m=e.length,d=y.computeStrides(t),f=y.computeStrides(e),h=w.getBroadcastDims(t,a),g=w.getBroadcastDims(e,a);if(h.length+g.length===0)for(let x=0;xC[E]=0);let S=y.locToIndex(C,l,d),k=b.slice(-m);g.forEach(E=>k[E]=0);let _=y.locToIndex(k,m,f);c[x]=r(o[S],n[_])}return[c,a]}}function Kt(r){let{inputs:t,backend:e}=r,{real:o,imag:n}=t,s=e.data.get(o.dataId).values,a=e.data.get(n.dataId).values,i=e.makeTensorInfo(o.shape,\"complex64\"),p=e.data.get(i.dataId);return p.complexTensorInfos={real:e.makeTensorInfo(o.shape,\"float32\",s),imag:e.makeTensorInfo(n.shape,\"float32\",a)},i}var XT={kernelName:Fi,backendName:\"cpu\",kernelFunc:Kt};function wc(r,t,e=\"float32\"){if(e===\"complex64\"){let n=wc(r,t,\"float32\"),s=wc(r,t,\"float32\");return Kt({inputs:{real:n,imag:s},backend:r})}let o=y.makeZerosTypedArray(y.sizeFromShape(t),e);return r.makeTensorInfo(t,e,o)}function mr(r){let{inputs:t,backend:e}=r,{x:o}=t;return e.incRef(o.dataId),{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}var YT={kernelName:wo,backendName:\"cpu\",kernelFunc:mr};function Ro(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.data.get(o.dataId).complexTensorInfos.real,s=e.data.get(n.dataId).values;return e.makeTensorInfo(n.shape,n.dtype,s)}var QT={kernelName:qi,backendName:\"cpu\",kernelFunc:Ro};function BS(r,t,e,o){if(o===\"int32\"){let n=Int32Array.from(r);return[t,\"int32\",n]}if(o===\"bool\"){let n=y.toTypedArray([0],e),[s,a]=ze((i,p)=>i!==p?1:0)(t,[],r,n,\"bool\");return[a,\"bool\",s]}throw new Error(`Error in Cast: failed to cast ${e} to ${o}`)}function Do(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dtype:s}=o;if(s===\"complex64\"){if(n.dtype===\"complex64\")return mr({inputs:{x:n},backend:e});let c=wc(e,n.shape,n.dtype),l=Do({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}}),m=Kt({inputs:{real:l,imag:c},backend:e});return e.disposeIntermediateTensorInfo(c),e.disposeIntermediateTensorInfo(l),m}if(n.dtype===\"complex64\"){let c=Ro({inputs:{input:n},backend:e}),l=Do({inputs:{x:c},backend:e,attrs:{dtype:s}});return e.disposeIntermediateTensorInfo(c),l}if(!y.hasEncodingLoss(n.dtype,s)){let c=mr({inputs:{x:n},backend:e});return{dataId:c.dataId,shape:c.shape,dtype:s}}let a=e.data.get(n.dataId).values,[i,p,u]=BS(a,n.shape,n.dtype,s);return e.makeTensorInfo(i,p,u)}var ZT={kernelName:bo,backendName:\"cpu\",kernelFunc:Do};function Ye(r,t,e,o){return e==null?({inputs:n,backend:s})=>{let{a,b:i}=n,p=s;Q([a,i],r);let u=p.data.get(a.dataId).values,c=p.data.get(i.dataId).values,l=a.dtype===\"string\"?w.fromUint8ToStringArray(u):u,m=a.dtype===\"string\"?w.fromUint8ToStringArray(c):c,d=o||a.dtype,[f,h]=t(a.shape,i.shape,l,m,d);return p.makeTensorInfo(h,d,f)}:({inputs:n,backend:s})=>{let{a,b:i}=n,p=s;if(a.dtype===\"complex64\"||i.dtype===\"complex64\"){let u=Do({inputs:{x:a},backend:p,attrs:{dtype:\"complex64\"}}),c=p.data.get(u.dataId),l=c.complexTensorInfos.real,m=c.complexTensorInfos.imag,d=p.data.get(l.dataId).values,f=p.data.get(m.dataId).values,h=Do({inputs:{x:i},backend:p,attrs:{dtype:\"complex64\"}}),g=p.data.get(h.dataId),x=g.complexTensorInfos.real,b=g.complexTensorInfos.imag,C=p.data.get(x.dataId).values,S=p.data.get(b.dataId).values,[k,_,E]=e(a.shape,i.shape,d,f,C,S),R=p.makeTensorInfo(E,\"float32\",k),D=p.makeTensorInfo(E,\"float32\",_),P=Kt({inputs:{real:R,imag:D},backend:p});return p.disposeIntermediateTensorInfo(u),p.disposeIntermediateTensorInfo(h),p.disposeIntermediateTensorInfo(R),p.disposeIntermediateTensorInfo(D),P}else{let u=p.data.get(a.dataId).values,c=p.data.get(i.dataId).values,l=o||a.dtype,[m,d]=t(a.shape,i.shape,u,c,l);return p.makeTensorInfo(d,l,m)}}}function Sc(r){return(t,e,o,n,s,a)=>{let i=w.assertAndGetBroadcastShape(t,e),p=y.sizeFromShape(i),u=i.length,c=y.computeStrides(i),l=y.getTypedArrayFromDType(\"float32\",p),m=y.getTypedArrayFromDType(\"float32\",p),d=w.getBroadcastDims(t,i),f=w.getBroadcastDims(e,i),h=w.mergeRealAndImagArrays(o,n),g=w.mergeRealAndImagArrays(s,a),x=t.length,b=y.computeStrides(t),C=e.length,S=y.computeStrides(e);if(d.length+f.length===0)for(let k=0;kE[M]=0);let R=y.locToIndex(E,x,b),D=_.slice(-C);f.forEach(M=>D[M]=0);let P=y.locToIndex(D,C,S),O=r(h[R*2],h[R*2+1],g[P*2],g[P*2+1]);l[k]=O.real,m[k]=O.imag}return[l,m,i]}}var zS=ze((r,t)=>r+t),P8=Sc((r,t,e,o)=>({real:r+e,imag:t+o})),Oa=Ye(uo,zS,P8),JT={kernelName:uo,backendName:\"cpu\",kernelFunc:Oa};function Ic(r,t,e,o,n){let s=y.sizeFromShape(o),a=y.makeZerosTypedArray(n,e);for(let i=0;i=n||(s>0?a[p]+=t[i]:a[p]+=1)}return a}function Nf(r,t,e,o=!1){let n=r.shape[0],s=r.shape[1],a=me([n,e],t.dtype);for(let i=0;i=e||(o?a.set(1,i,u):t.size>0?a.set(a.get(i,u)+t.get(i,p),i,u):a.set(a.get(i,u)+1,i,u))}return a}var VS=ze((r,t)=>r&t),O8=Ye(ja,VS),e_={kernelName:ja,backendName:\"cpu\",kernelFunc:O8};function Xt(r){return(t,e,o)=>{let n=y.getArrayFromDType(e,t.length);for(let s=0;s{let{x:a}=o;Q(a,r);let i=s,p=i.data.get(a.dataId).values,u;if(a.dtype===\"string\"){if(!Array.isArray(p))throw new Error(\"String tensor's value was not an instance of Array\");u=w.fromUint8ToStringArray(p)}else u=p;let c=e||a.dtype,l=t(u,c,n);return i.makeTensorInfo(a.shape,c,l)}}var WS=Xt(r=>Math.ceil(r)),M8=Ar(tn,WS),t_={kernelName:tn,backendName:\"cpu\",kernelFunc:M8};function mp(r,t,e,o){let n=y.getArrayFromDType(e,y.sizeFromShape(t));if(o&&e!==\"string\"){let s=0;r.forEach(a=>{let i=y.sizeFromShape(a.shape);n.set(a.vals,s),s+=i})}else{let s=0;r.forEach(a=>{let i=e===\"string\"?w.fromUint8ToStringArray(a.vals):a.vals,p=0;for(let u=0;ur===t?1:0),GS=Ye(yn,US,null,\"bool\"),r_={kernelName:yn,backendName:\"cpu\",kernelFunc:GS};var HS=Xt(r=>Math.exp(r)),KS=Ar(bn,HS,\"float32\"),o_={kernelName:bn,backendName:\"cpu\",kernelFunc:KS};var qS=Xt(r=>Math.expm1(r)),L8=Ar(Cn,qS),n_={kernelName:Cn,backendName:\"cpu\",kernelFunc:L8};var jS=Xt(r=>Math.floor(r)),B8=Ar(Sn,jS),s_={kernelName:Sn,backendName:\"cpu\",kernelFunc:B8};var XS=ze((r,t)=>Math.floor(r/t)),z8=Ye(In,XS,null,\"int32\"),a_={kernelName:In,backendName:\"cpu\",kernelFunc:z8};function Tf(r,t,e,o,n,s,a,i,p){let u=me([o,s],e);for(let c=0;c=p/s)throw new Error(`Invalid indices: ${l} does not index into ${i}`);for(let d=0;dr>t?1:0),V8=Ye(Nn,YS,null,\"bool\"),i_={kernelName:Nn,backendName:\"cpu\",kernelFunc:V8};var QS=ze((r,t)=>r>=t?1:0),W8=Ye(Tn,QS,null,\"bool\"),u_={kernelName:Tn,backendName:\"cpu\",kernelFunc:W8};var ZS=ze((r,t)=>rr<=t?1:0),G8=Ye(An,JS,null,\"bool\"),c_={kernelName:An,backendName:\"cpu\",kernelFunc:G8};function $f(r,t,e){let o=(t-r)/(e-1),n=y.makeZerosTypedArray(e,\"float32\");n[0]=r;for(let s=1;sMath.log(r)),H8=Ar(Pn,eI),l_={kernelName:Pn,backendName:\"cpu\",kernelFunc:H8};function Ef(r,t,e,o){let n=y.getTypedArrayFromDType(o,y.sizeFromShape(e));for(let s=0;si)&&(i=u)}n[s]=i}return n}var tI=ze((r,t)=>Math.max(r,t)),K8=Ye(Wn,tI),m_={kernelName:Wn,backendName:\"cpu\",kernelFunc:K8};var rI=ze((r,t)=>Math.min(r,t)),q8=Ye(Kn,rI),d_={kernelName:Kn,backendName:\"cpu\",kernelFunc:q8};var zl=ze((r,t)=>r*t),j8=Sc((r,t,e,o)=>({real:r*e-t*o,imag:r*o+t*e})),dp=Ye(Yn,zl,j8),f_={kernelName:Yn,backendName:\"cpu\",kernelFunc:dp};function oI(r,t,e){let o=y.createScalarValue(-1,e);return zl([],t,o,r,e)}function X8(r){let{inputs:t,backend:e}=r,{x:o}=t;Q(o,\"neg\");let n=e.data.get(o.dataId).values,[s,a]=oI(n,o.shape,o.dtype);return e.makeTensorInfo(a,o.dtype,s)}var h_={kernelName:pa,backendName:\"cpu\",kernelFunc:X8};var nI=ze((r,t)=>r!==t?1:0),Y8=Ye(Qn,nI,null,\"bool\"),g_={kernelName:Qn,backendName:\"cpu\",kernelFunc:Y8};function vc(r,t,e,o,n){let s=t.length,a=y.sizeFromShape(t),i=y.computeStrides(t),p=y.computeStrides(n),u=y.getTypedArrayFromDType(e,y.sizeFromShape(n));for(let c=0;ce.disposeIntermediateTensorInfo(b)),e.makeTensorInfo(x,g,f)}var y_={kernelName:ns,backendName:\"cpu\",kernelFunc:Q8};function Z8(r,t,e){r.forEach((o,n)=>{if(o<0||o>=e){let s=y.indexToLoc(n,t.length,y.computeStrides(t)).join(\",\");throw new Error(`indices[${s}] = ${o} is not in [0, ${e})`)}})}function J8(r,t){for(let e=0;en)throw new Error(\"Ragged splits must not point past values\");for(let s=1;so[s])throw new Error(\"Ragged splits must be sorted in ascending order\")}}function eY(r,t,e,o){let n=[],s=0,a=t.length-1+e.length,i=new Array(a).fill(null).map(()=>[0]);J8(e,o);let p=1;for(let u=0;u=0){let h=i[f],g=h[h.length-1]-d[c];for(let x=c;xn[a]=s)}return t}function b_(r,t){let e=r.slice(0,t);for(;e.length1)throw new Error(\"starts must be a scalar or vector\");if(n.length>1)throw new Error(\"limits must be a scalar or vector\");if(a.length>1)throw new Error(\"deltas must be a scalar or vector\");let i=t.length===0,p=n.length===0,u=a.length===0,c=[];i||c.push(t[0]),p||c.push(n[0]),u||c.push(a[0]);for(let g=1;g0&&bx)S=0;else if(S=Math.ceil(Math.abs((b-x)/C)),S>C_)throw new Error(`Requires ((limit - start) / delta) <= ${C_}`);m[g+1]=m[g]+S}let d=m[l],f=y.getArrayFromDType(e,d),h=0;for(let g=0;go&&(o=s)}return o}static getMaxWidthValueRowID(t){let e=t.length;if(e===0)return 0;let o=0,n=t[0],s=0;for(let a=1;a\"Final length of result must be equal to firstDimension.\"),s}calculateOutputIndexRowSplit(t,e,o,n){let s=t.length,a=[];for(let i=0;i0&&a.length!==t[s-1])throw new Error(\"Invalid row split size.\");return a}calculateOutputIndexValueRowID(t,e,o,n){let s=t.length,a=[];if(s===0)return[];let i=0,p=t[0];if(p>=e.length)throw new Error(`Got currentValueRowId=${p}, which is not less than ${e.length}`);let u=e[p];a.push(u);for(let c=1;c=0&&(++i,i=e.length)throw new Error(`Got nextValueRowId=${l} which is not less than ${e.length}`);u=e[l]}a.push(u)}if(a.length!==t.length)throw new Error(\"Invalid row ids.\");return a}calculateOutputIndex(t,e,o,n){let s=this.getRowPartitionTensor(t),a=this.getRowPartitionTypeByDimension(t);switch(a){case Ao.VALUE_ROWIDS:return this.calculateOutputIndexValueRowID(s,e,o,n);case Ao.ROW_SPLITS:if(s.length-1>e.length)throw new Error(`Row partition size is greater than output size: ${s.length-1} > ${e.length}`);return this.calculateOutputIndexRowSplit(s,e,o,n);default:throw new Error(`Unsupported partition type: ${Ao[a]}`)}}getFirstDimensionSize(){let t=this.rowPartitionValues[0];if(this.rowPartitionTypes.length===0)throw new Error(\"No row_partition_types given.\");let e=this.rowPartitionTypes[0];switch(e){case Ao.FIRST_DIM_SIZE:return t[0];case Ao.VALUE_ROWIDS:throw new Error(\"Cannot handle VALUE_ROWIDS in first dimension.\");case Ao.ROW_SPLITS:return this.rowPartitionValuesShapes[0][0]-1;default:throw new Error(`Cannot handle type ${Ao[e]}`)}}compute(){if(this.rowPartitionValues[0].length<=0)throw new Error(\"Invalid first partition input. Tensor requires at least one element.\");let e=this.getFirstDimensionSize(),o=this.calculateOutputSize(e),n=new Array(this.raggedRank+1);n[n.length-1]=1;for(let p=n.length-2;p>=0;--p)n[p]=n[p+1]*o[p+1];let s=S_(o,!1),a=y.getArrayFromDType(this.valuesDType,y.sizeFromShape(s));if(n[0]*o[0]>0){let p=this.calculateFirstParentOutputIndex(e,n[0],o[0]);for(let u=1;u<=this.raggedRank;++u)p=this.calculateOutputIndex(u-1,p,n[u],o[u]);this.setOutput(this.raggedRank,p,a,s)}return[s,a]}setOutput(t,e,o,n){if(o.length===0)return;let s=this.values,a=o,i=n.slice();i=i.slice(t+1);let p=y.sizeFromShape(i),u=e.length,c=this.defaultValue;if(c.length!==p&&c.length!==1){let f=this.defaultValueShape;De(()=>{let h=W(c,f);c=iu(h,i).dataSync()})}let l=0,m=0,d=0;for(let f=0;f<=u;++f){let h=f=u){let g=o.length;h=Math.floor(g/p)}if(h>d)if(this.defaultValue.length===1)a.subarray(d*p,h*p).fill(this.defaultValue[0]),d=h;else for(;h>d;){let g=a.slice(d*p);w_(g,c,p),++d}h<0?(l=f+1,m=d):(l=f,m=d,d=m+1)}}};function w_(r,t,e){for(let o=0;o= 0`);if(o<-1)throw new Error(`Dimension ${o} must be >= -1`);o=-1}e.push(o)}return e}function Af(r,t,e,o,n,s,a,i,p,u){return new kc(r,t,e,o,n,s,a,i,p,u).compute()}function fp(r,t,e,o){let n=r===t,s=r1;if(n||s||a)return y.makeZerosTypedArray(0,o);let i=Math.abs(Math.ceil((t-r)/e)),p=y.makeZerosTypedArray(i,o);t1/Math.sqrt(r)),nY=Ar(ms,aI),I_={kernelName:ms,backendName:\"cpu\",kernelFunc:nY};function zs(r,t,e,o,n,s,a,i,p,u){let c=[o/n,n],l=r.values,m=t.values;if(o===0)return me(e,t.dtype);let d=p instanceof tt?p:me(c,t.dtype);typeof p==\"string\"||typeof p==\"number\"?d.values.fill(p):typeof p==\"boolean\"&&d.values.fill(+p);for(let f=0;f=o/n)throw new Error(`Invalid indices: ${h} does not index into ${e}`);for(let x=0;x1/(1+Math.exp(-r))),iI=Ie(Cs,r=>1/(1+Math.exp(-r))),k_={kernelName:Cs,backendName:\"cpu\",kernelFunc:iI};function hp(r,t,e,o,n){let s=ct.isSliceContinous(o,t,e),a=y.sizeFromShape(e),i=y.computeStrides(o);if(s){let l=ct.computeFlatOffset(t,i);return n===\"string\"?r.slice(l,l+a):r.subarray(l,l+a)}let p=n===\"string\"?w.fromUint8ToStringArray(r):r,u=me(o,n,p),c=me(e,n);for(let l=0;lf+t[h]);c.set(u.get(...d),...m)}return n===\"string\"?w.fromStringArrayToUint8(c.values):c.values}function Fo(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,size:a}=o;Q(n,\"slice\");let[i,p]=ct.parseSliceParams(n,s,a);ct.assertParamsValid(n,i,p);let u=e.data.get(n.dataId).values,c=hp(u,i,p,n.shape,n.dtype);return e.makeTensorInfo(p,n.dtype,c)}var N_={kernelName:ha,backendName:\"cpu\",kernelFunc:Fo};function Ff(r,t,e,o,n,s,a){let i=t[0],p=s[0],u=new Array(p),c=new Array(i),l=t[1];if(p===0){if(i!==0)throw new Error(w.getSparseFillEmptyRowsIndicesDenseShapeMismatch(i));let g=y.getArrayFromDType(e,0),x=y.getArrayFromDType(n,0);return[g,[0,l],x,u,c]}let m=!0,d=0,f=new Array(p).fill(0);for(let g=0;g=p)throw new Error(w.getSparseFillEmptyRowsOutOfRangeIndexErrorMessage(g,x,p));++f[x],m=m&&x>=d,d=x}let h=!0;for(let g=0;g0&&(f[g]+=f[g-1])}if(h&&m){let g=r,x=o;for(let b=0;b0){d[m-1]=1;for(let g=m-2;g>=0;--g)d[g]=d[g+1]*o[g+1]}let f=[];if(i>0){f[i-1]=1;for(let g=i-2;g>=0;--g)f[g]=f[g+1]*p[g+1]}let h=y.getArrayFromDType(e,a*i);for(let g=0;g0?n[i-1]+1:0;if(l<0)throw new Error(w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage());let m=t.slice();m[0]=l;let d=m.reduce((C,S)=>C*S,1),f=y.getArrayFromDType(e,d);if(i===0)return l>0&&f.fill(a),[f,m];if(l<=0)throw new Error(w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage());let h=0,g=1,x=0,b=n[h];for(;;){let C=0;if(g=C)throw new Error(w.getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage())}if(b<0||b>=l)throw new Error(w.getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage(b,l));b>x&&f.fill(a,x*u,b*u);for(let S=h;S=p[0])throw new Error(w.getSparseSegmentReductionIndicesOutOfRangeErrorMessage(S,o[S],p[0]));for(let _=0;_i)break}return xMath.sqrt(r)),sY=Ie(Ss,r=>Math.sqrt(r)),__={kernelName:Ss,backendName:\"cpu\",kernelFunc:sY};var uI=ze((r,t)=>{let e=r-t;return e*e}),aY=Ye(Ns,uI),$_={kernelName:Ns,backendName:\"cpu\",kernelFunc:aY};var pI=Xt((r,t)=>{let{pattern:e,replaceGlobal:o,rewrite:n}=t;return r.replace(new RegExp(e,o?\"g\":\"\"),n)}),iY=Ar(Ou,pI),E_={kernelName:Ou,backendName:\"cpu\",kernelFunc:iY};function Of(r,t,e,o){let n=me(r,t.dtype);for(let s=0;s0?0:i-p),d=0;d+=u*this.leftPad.length;for(let b=0;bb.forEach(C=>h[g++]=C);for(let b=0;b0){x(t[m+l-1]);for(let b=0;b0){let p=e[0];if(p!==0)throw new Error(`First split value must be 0, got ${p}`);for(let u=1;u=p;if(c=c&&e[u]<=o,!c)throw new Error(`Invalid split value ${e[u]}, must be in [${p}, ${o}]`);p=e[u]}if(p!==o)throw new Error(`Last split value must be data size. Expected ${o}, got ${p}`)}let s=n-1,a=y.getArrayFromDType(\"int32\",n);if(o===0||n===0){let p=new Array(o);for(let u=0;u<=s;++u)a[u]=0;return[p,a]}a[0]=0;for(let p=1;p<=s;++p){let u=e[p]-e[p-1],c=0;this.nGramWidths.forEach(l=>{c+=this.getNumNGrams(u,l)}),this.preserveShort&&u>0&&c===0&&(c=1),a[p]=a[p-1]+c}let i=new Array(a[s]);for(let p=0;p{let m=e[p+1]-e[p],d=this.getNumNGrams(m,l);this.createNGrams(t,u,i,c,d,l),c+=d}),this.preserveShort&&c===a[p]){let l=e[p+1]-e[p];if(l===0)continue;let m=l+2*this.padWidth,d=1;this.createNGrams(t,u,i,c,d,m)}}return[i,a]}};function gp(r,t,e,o,n,s,a,i){return new cI(e,o,n,s,a,i).compute(r,t)}function uY(r,t,e,o){if(!r.length)return;if(t.length===0){for(let s=0;sr-t),pY=Sc((r,t,e,o)=>({real:r-e,imag:t-o})),Vl=Ye(_s,lI,pY),R_={kernelName:_s,backendName:\"cpu\",kernelFunc:Vl};function Mf(r,t){let e=new Array(r.rank);for(let n=0;n{let e=t.value-r.value;return e===0?r.index-t.index:e};function D_(r,t,e=0,o=r.length-1){for(;o>e;){if(o-e>600){let i=o-e+1,p=t-e+1,u=Math.log(i),c=.5*Math.exp(2*u/3),l=.5*Math.sqrt(u*c*(i-c)/i)*Math.sign(p-i/2),m=Math.max(e,Math.floor(t-p*c/i+l)),d=Math.min(o,Math.floor(t+(i-p)*c/i+l));D_(r,t,m,d)}let n=r[t],s=e,a=o;for(y.swap(r,e,t),Wl(r[o],n)>0&&y.swap(r,e,o);s0;)a=a-1}Wl(r[e],n)===0?y.swap(r,e,a):(a=a+1,y.swap(r,a,o)),a<=t&&(e=a+1),t<=a&&(o=a-1)}}function Lf(r,t,e,o,n){let s=t[t.length-1],[a,i]=[r.length/s,s],p=y.getTypedArrayFromDType(e,a*o),u=y.getTypedArrayFromDType(\"int32\",a*o);for(let l=0;lf[C]={value:b,index:C}),o{for(let g=0;gnew xu,1);var mI=Ie(gn,r=>r>=0?r:Math.exp(r)-1),A_={kernelName:gn,backendName:\"cpu\",kernelFunc:mI};function dI(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{alpha:s}=o;Q([n],\"leakyRelu\");let a=y.sizeFromShape(n.shape),i=e.data.get(n.dataId).values,p=y.getTypedArrayFromDType(\"float32\",a);for(let u=0;ur<0?t*r:r);function fI(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t;Q([o,n],\"prelu\");let s=e.data.get(o.dataId).values,a=e.data.get(n.dataId).values,[i,p]=lY(o.shape,n.shape,s,a,\"float32\");return e.makeTensorInfo(p,\"float32\",i)}var P_={kernelName:os,backendName:\"cpu\",kernelFunc:fI};var hI=Ie(as,r=>Math.max(0,r)),O_={kernelName:as,backendName:\"cpu\",kernelFunc:hI};var gI=Ie(ps,r=>Math.min(Math.max(0,r),6)),M_={kernelName:ps,backendName:\"cpu\",kernelFunc:gI};function Cp(r,t,e,o,n){if(e===\"linear\")return mr({inputs:{x:t},backend:r});if(e===\"relu\")return hI({inputs:{x:t},backend:r});if(e===\"elu\")return mI({inputs:{x:t},backend:r});if(e===\"relu6\")return gI({inputs:{x:t},backend:r});if(e===\"prelu\")return fI({inputs:{x:t,alpha:o},backend:r});if(e===\"leakyrelu\")return dI({inputs:{x:t},backend:r,attrs:{alpha:n}});if(e===\"sigmoid\")return iI({inputs:{x:t},backend:r});throw new Error(`Activation ${e} has not been implemented for the CPU backend.`)}function Ve(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{shape:s}=o,a=y.sizeFromShape(n.shape),i=y.inferFromImplicitShape(s,a),p=y.sizeFromShape(i);y.assert(a===p,()=>`The new shape (${i}) has ${p} elements and the old shape (${n.shape}) has ${a} elements. The new shape and old shape must have the same number of elements.`),e.incRef(n.dataId);let u=e.data.get(n.dataId);if(u.complexTensorInfos!=null){let c=u.complexTensorInfos.real,l=u.complexTensorInfos.imag;c.shape=i,l.shape=i}return{dataId:n.dataId,shape:i,dtype:n.dtype}}var L_={kernelName:da,backendName:\"cpu\",kernelFunc:Ve};function xI(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;Q([n,s],\"matMul\");let p=n.shape.length,u=s.shape.length,c=a?n.shape[p-2]:n.shape[p-1],l=i?s.shape[u-1]:s.shape[u-2],m=a?n.shape[p-1]:n.shape[p-2],d=i?s.shape[u-2]:s.shape[u-1],f=n.shape.slice(0,-2),h=s.shape.slice(0,-2),g=y.sizeFromShape(f),x=y.sizeFromShape(h),C=Ir.assertAndGetBroadcastShape(n.shape.slice(0,-2),s.shape.slice(0,-2)).concat([m,d]);y.assert(c===l,()=>`Error in matMul: inner shapes (${c}) and (${l}) of Tensors with shapes ${n.shape} and ${s.shape} and transposeA=${a} and transposeB=${i} must match.`);let S=a?[g,c,m]:[g,m,c],k=i?[x,d,l]:[x,l,d],_=Ve({inputs:{x:n},backend:e,attrs:{shape:S}}),E=Ve({inputs:{x:s},backend:e,attrs:{shape:k}}),R=a?_.shape[1]:_.shape[2],D=a?_.shape[2]:_.shape[1],P=i?E.shape[1]:E.shape[2],O=Math.max(g,x),M=e.data.get(_.dataId).values,L=e.data.get(E.dataId).values,B=y.computeStrides(_.shape),z=y.computeStrides(E.shape),[U,j,q]=a?[B[0],1,B[1]]:[B[0],B[1],1],[Y,J,re]=i?[1,z[1],z[0]]:[z[1],1,z[0]],ne=D*P,ee=me([O,D,P],_.dtype),oe=ee.values,ie=e.blockSize;for(let le=0;leMath.acos(r)),V_={kernelName:Wo,backendName:\"cpu\",kernelFunc:dY};var fY=Ie(Uo,r=>Math.acosh(r)),W_={kernelName:Uo,backendName:\"cpu\",kernelFunc:fY};function hY(r){let{inputs:t,backend:e}=r,o=t;Q(t,\"addN\");let n=o.map(i=>e.data.get(i.dataId).values),s=me(o[0].shape,o[0].dtype),a=s.values;for(let i=0;ib&&(b=k,C=S)}d[g]=C}return u.forEach(g=>e.disposeIntermediateTensorInfo(g)),e.makeTensorInfo(c,\"int32\",d)}var K_={kernelName:Ys,backendName:\"cpu\",kernelFunc:yY};function bY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o;Q(n,\"argMin\");let a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=It({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),a=[a[0]],w.assertAxesAreInnerMostDims(\"argMin\",a,p.shape.length);let[c,l]=w.computeOutAndReduceShapes(p.shape,a),m=y.sizeFromShape(c),d=y.makeZerosTypedArray(m,\"int32\"),f=y.sizeFromShape(l),h=e.data.get(p.dataId).values;for(let g=0;ge.disposeIntermediateTensorInfo(g)),e.makeTensorInfo(c,\"int32\",d)}var q_={kernelName:Qs,backendName:\"cpu\",kernelFunc:bY};var CY=Ie(qo,r=>Math.asin(r)),j_={kernelName:qo,backendName:\"cpu\",kernelFunc:CY};var wY=Ie(jo,r=>Math.asinh(r)),X_={kernelName:jo,backendName:\"cpu\",kernelFunc:wY};var SY=Ie(Xo,r=>Math.atan(r)),Y_={kernelName:Xo,backendName:\"cpu\",kernelFunc:SY};var IY=ze((r,t)=>Math.atan2(r,t)),vY=Ye(Qo,IY),Q_={kernelName:Qo,backendName:\"cpu\",kernelFunc:vY};var kY=Ie(Yo,r=>Math.atanh(r)),Z_={kernelName:Yo,backendName:\"cpu\",kernelFunc:kY};function _c(r,t,e,o,n,s){let a=n.strideHeight,i=n.strideWidth,p=n.dilationHeight,u=n.dilationWidth,c=n.effectiveFilterHeight,l=n.effectiveFilterWidth,m=n.padInfo.top,d=n.padInfo.left,f=s===\"max\"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,h=me(n.outShape,e),g=h.values,x=n.outShape[1]*n.outShape[2]*n.outShape[3],b=n.outShape[2]*n.outShape[3],C=n.outShape[3];for(let S=0;Sj?j=ie:s===\"avg\"&&(q+=ie,Y++)}if(isNaN(j))break}let J=M+L*C+E;g[J]=s===\"avg\"?q/Y:j}}}return h}function Bf(r,t,e,o,n=!1,s=!1){let a=me(o.outShape,\"int32\"),i=o.strideHeight,p=o.strideWidth,u=o.dilationHeight,c=o.dilationWidth,l=o.effectiveFilterHeight,m=o.effectiveFilterWidth,d=o.padInfo.top,f=o.padInfo.left,h=me(t,e,r);for(let g=0;gP&&(P=U,n?O=s?((g*o.inHeight+M)*o.inWidth+B)*o.inChannels+x:(M*o.inWidth+B)*o.inChannels+x:O=L*m+z)}}a.set(O,g,b,_,x)}}return a}function zf(r,t,e,o,n,s){let a=n.strideDepth,i=n.strideHeight,p=n.strideWidth,u=n.dilationDepth,c=n.dilationHeight,l=n.dilationWidth,m=n.effectiveFilterDepth,d=n.effectiveFilterHeight,f=n.effectiveFilterWidth,h=n.padInfo.front,g=n.padInfo.top,x=n.padInfo.left,b=s===\"max\"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,C=me(n.outShape,e),S=C.values,k=n.outShape[1]*n.outShape[2]*n.outShape[3]*n.outShape[4],_=n.outShape[2]*n.outShape[3]*n.outShape[4],E=n.outShape[3]*n.outShape[4],R=n.outShape[4];for(let D=0;D_e?_e=xt:s===\"avg\"&&(ve+=xt,Fe++),isNaN(_e))break}if(isNaN(_e))break}if(isNaN(_e))break}let Pe=be+M;S[Pe]=s===\"avg\"?ve/Math.max(Fe,1):_e}}}}return C}function J_(r,t){let e=me(t.outShape,\"int32\"),o=t.strideDepth,n=t.strideHeight,s=t.strideWidth,a=t.dilationDepth,i=t.dilationHeight,p=t.dilationWidth,u=t.effectiveFilterDepth,c=t.effectiveFilterHeight,l=t.effectiveFilterWidth,m=t.padInfo.front,d=t.padInfo.top,f=t.padInfo.left;for(let h=0;h=L&&(L=re,B=U*c*l+q*c+J)}}}e.set(B,h,x,k,D,g)}}}return e}function NY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t;Q(n,\"avgPool\");let{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1;y.assert(w.eitherStridesOrDilationsAreOne(a,u),()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p),l;if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))l=mr({inputs:{x:n},backend:e});else{let m=e.data.get(n.dataId).values,d=y.computeStrides(n.shape),f=_c(m,n.shape,n.dtype,d,c,\"avg\");l=e.makeTensorInfo(c.outShape,n.dtype,f.values)}return l}var e$={kernelName:Zo,backendName:\"cpu\",kernelFunc:NY};function TY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o;Q(n,\"avgPool3d\");let c=w.computePool3DInfo(n.shape,s,a,1,i,p,u),l=e.data.get(n.dataId).values,m=zf(l,n.shape,n.dtype,y.computeStrides(n.shape),c,\"avg\");return e.makeTensorInfo(m.shape,\"float32\",m.values)}var t$={kernelName:Zs,backendName:\"cpu\",kernelFunc:TY};function _Y(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o;Q([n,s],\"avgPool3DGrad\");let c=w.computePool3DInfo(s.shape,a,i,1,p,u),l=c.strideDepth,m=c.strideHeight,d=c.strideWidth,f=c.filterDepth,h=c.filterHeight,g=c.filterWidth,x=c.dilationDepth,b=c.dilationHeight,C=c.dilationWidth,S=c.effectiveFilterDepth,k=c.effectiveFilterHeight,_=c.effectiveFilterWidth,E=S-1-c.padInfo.front,R=_-1-c.padInfo.left,D=k-1-c.padInfo.top,P=me(s.shape,\"float32\"),O=1/(f*h*g),M=e.bufferSync(n);for(let L=0;L=c.outDepth||Math.floor(ee)!==ee))for(let oe=0;oe=c.outHeight||Math.floor(ie)!==ie))for(let le=0;le<_;le+=C){let be=(J+le)/d;if(be<0||be>=c.outWidth||Math.floor(be)!==be)continue;let _e=M.get(L,ee,ie,be,B);re+=_e}}}P.set(re*O,L,z,U,j,B)}return e.makeTensorInfo(P.shape,P.dtype,P.values)}var r$={kernelName:Ai,backendName:\"cpu\",kernelFunc:_Y};function $Y(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s;Q([n,s],\"avgPoolGrad\");let{filterSize:i,strides:p,pad:u}=o,c=w.computePool2DInfo(a.shape,i,p,1,u),l=c.strideHeight,m=c.strideWidth,d=c.filterHeight,f=c.filterWidth,h=c.dilationHeight,g=c.dilationWidth,x=c.effectiveFilterHeight,b=c.effectiveFilterWidth,C=b-1-c.padInfo.left,S=x-1-c.padInfo.top,k=me(a.shape,\"float32\"),_=1/(d*f),E=e.data.get(n.dataId).values,R=me(n.shape,\"float32\",E);for(let D=0;D=c.outHeight||Math.floor(j)!==j))for(let q=0;q=c.outWidth||Math.floor(Y)!==Y)continue;let J=R.get(D,j,Y,P);z+=J}}k.set(z*_,D,O,M,P)}return e.makeTensorInfo(k.shape,k.dtype,k.values)}var o$={kernelName:Di,backendName:\"cpu\",kernelFunc:$Y};function EY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,scale:s,offset:a,mean:i,variance:p}=t;y.assert(i.shape.length===p.shape.length,()=>\"Batch normalization gradient requires mean and variance to have equal ranks.\"),y.assert(a==null||i.shape.length===a.shape.length,()=>\"Batch normalization gradient requires mean and offset to have equal ranks.\"),y.assert(s==null||i.shape.length===s.shape.length,()=>\"Batch normalization gradient requires mean and scale to have equal ranks.\"),Q([n,i,p,s,a],\"batchNorm\");let{varianceEpsilon:u}=o;u==null&&(u=.001);let c=e.data.get(n.dataId).values,l=e.data.get(i.dataId).values,m=e.data.get(p.dataId).values,d=s?e.data.get(s.dataId).values:new Float32Array([1]),f=a?e.data.get(a.dataId).values:new Float32Array([0]),h=new Float32Array(c.length),g=f.length,x=d.length,b=m.length,C=l.length,S=0,k=0,_=0,E=0;for(let R=0;R=g&&(S=0),k>=C&&(k=0),_>=x&&(_=0),E>=b&&(E=0);return e.makeTensorInfo(n.shape,n.dtype,h)}var n$={kernelName:vn,backendName:\"cpu\",kernelFunc:EY};function RY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,crops:a}=o;Q([n],\"batchToSpaceND\");let i=s.reduce((x,b)=>x*b),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=Ve({inputs:{x:n},backend:e,attrs:{shape:p}}),f=It({inputs:{x:d},backend:e,attrs:{perm:u}}),h=Ve({inputs:{x:f},backend:e,attrs:{shape:c}}),g=Fo({inputs:{x:h},backend:e,attrs:{begin:l,size:m}});return e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),g}var s$={kernelName:Js,backendName:\"cpu\",kernelFunc:RY};function DY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a}=o,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,u=Ic(i,p,s.dtype,s.shape,a);return e.makeTensorInfo([a],s.dtype,u)}var a$={kernelName:en,backendName:\"cpu\",kernelFunc:DY};function AY(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t,s=e.data.get(o.dataId).values,a=e.data.get(n.dataId).values,i=w.assertAndGetBroadcastShape(Array.from(s),Array.from(a));return e.makeTensorInfo([i.length],\"int32\",Int32Array.from(i))}var i$={kernelName:ea,backendName:\"cpu\",kernelFunc:AY};var FY=Ie(Co,(r,t)=>{let e=t;return r>e.clipValueMax?e.clipValueMax:r{let{x:t}=r.inputs,e=r.backend,o=new Float32Array(y.sizeFromShape(t.shape)),n=e.data.get(t.dataId),s=n.complexTensorInfos.real,a=n.complexTensorInfos.imag,i=e.data.get(s.dataId).values,p=e.data.get(a.dataId).values;for(let u=0;uh.shape);w.assertParamsConsistent(a,s);let i=w.computeOutShape(t.map(h=>h.shape),s);if(y.sizeFromShape(i)===0)return e.makeTensorInfo(i,t[0].dtype,[]);let p=t.filter(h=>y.sizeFromShape(h.shape)>0);if(p.length===1)return mr({inputs:{x:p[0]},backend:e});if(p[0].dtype===\"complex64\"){let h=p.map(S=>Ro({inputs:{input:S},backend:e})),g=p.map(S=>Ma({inputs:{input:S},backend:e})),x=yu({inputs:h,backend:e,attrs:{axis:s}}),b=yu({inputs:g,backend:e,attrs:{axis:s}}),C=Kt({inputs:{real:x,imag:b},backend:e});return h.forEach(S=>e.disposeIntermediateTensorInfo(S)),g.forEach(S=>e.disposeIntermediateTensorInfo(S)),e.disposeIntermediateTensorInfo(x),e.disposeIntermediateTensorInfo(b),C}let u=p.map(h=>{let x=[-1,y.sizeFromShape(h.shape.slice(s))];return Ve({inputs:{x:h},backend:e,attrs:{shape:x}})}),c=u.map(h=>({vals:e.data.get(h.dataId).values,shape:h.shape}));i=w.computeOutShape(u.map(h=>h.shape),1);let l=u[0].shape[0]===1,m=mp(c,i,t[0].dtype,l),d=w.computeOutShape(p.map(h=>h.shape),s),f=e.makeTensorInfo(d,t[0].dtype,m);return u.forEach(h=>e.disposeIntermediateTensorInfo(h)),f}var l$={kernelName:ta,backendName:\"cpu\",kernelFunc:yu};function yI(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=o;Q([n,s],\"conv2d\");let l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,s.shape,a,u,i,c,!1,l),d=m.filterHeight,f=m.filterWidth,h=m.dilationHeight,g=m.dilationWidth,x=m.padInfo.left,b=m.padInfo.top,C=m.dataFormat===\"channelsLast\",S=new tt(m.outShape,n.dtype),k=y.computeStrides(n.shape),_=y.computeStrides(s.shape),E=k[0],R=C?k[1]:k[2],D=C?k[2]:1,P=C?1:k[1],O=S.strides[0],M=C?S.strides[1]:S.strides[2],L=C?S.strides[2]:1,B=C?1:S.strides[1],z=e.data.get(n.dataId).values,U=e.data.get(s.dataId).values,j=S.values;for(let q=0;q=m.inHeight)continue;let le=oe*_[0],be=Y+ie*R;for(let _e=0;_e=m.inWidth)continue;let lt=le+Pe*_[1],Ge=be+st*D,mt=lt;for(let it=0;it=u.inDepth)continue;let q=U*D[0],Y=O+j*R[1];for(let J=0;J=u.inHeight)continue;let ie=q+ee*D[1],le=Y+oe*R[2];for(let be=0;be=u.inWidth)continue;let st=ie+Fe*D[2],lt=le+Pe*u.inChannels,Ge=st;for(let mt=0;mtMath.cos(r)),y$={kernelName:an,backendName:\"cpu\",kernelFunc:VY};var WY=Ie(un,r=>Math.cosh(r)),b$={kernelName:un,backendName:\"cpu\",kernelFunc:WY};function UY(r){let{inputs:t,backend:e,attrs:o}=r,{image:n,boxes:s,boxInd:a}=t,{cropSize:i,method:p,extrapolationValue:u}=o,[c,l,m,d]=n.shape,f=s.shape[0],[h,g]=i,x=me([f,h,g,d],\"float32\"),b=e.data.get(s.dataId).values,C=e.data.get(a.dataId).values,S=e.data.get(n.dataId).values,k=y.computeStrides(n.shape),_=y.computeStrides(x.shape);for(let E=0;E=c)continue;let B=h>1?(O-D)*(l-1)/(h-1):0,z=g>1?(M-P)*(m-1)/(g-1):0;for(let U=0;U1?D*(l-1)+U*B:.5*(D+O)*(l-1);if(j<0||j>l-1){for(let q=0;q1?P*(m-1)+re*z:.5*(P+M)*(m-1);if(ne<0||ne>m-1){for(let le=0;le1?P*(m-1)+q*z:.5*(P+M)*(m-1);if(Y<0||Y>m-1){for(let ne=0;nex+f-b-1:(x,b)=>x+b;for(let x=0;xx+f-b-1:(x,b)=>x+b;for(let x=0;x`Only NHWC dataFormat supported on CPU for depthToSpace. Got ${a}`);let i=n.shape[0],p=n.shape[1],u=n.shape[2],c=n.shape[3],l=p*s,m=u*s,d=c/(s*s),f=e.data.get(n.dataId).values,h=new Float32Array(i*l*m*d),g=0;for(let x=0;x`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${a} and dilations '${m}'`);let d=w.computeConv2DInfo(n.shape,s.shape,a,m,i,u,!0),{filterHeight:f,filterWidth:h,dilationHeight:g,dilationWidth:x,padInfo:b}=d,C=b.left,S=b.top,k=d.outChannels/d.inChannels,_=new tt(d.outShape,n.dtype),E=e.data.get(n.dataId).values,R=e.data.get(s.dataId).values,D=_.values;for(let P=0;P=d.inHeight)continue;let q=U*l[0],Y=O+j*c[1];for(let J=0;J=d.inWidth)continue;let ie=q+ee*l[1],le=Y+oe*d.inChannels,be=re,_e=ie;for(let ve=0;ve{let{x:o,filter:n}=r,{strides:s,pad:a,dilations:i}=e,p=t,u=p.data.get(o.dataId).values,c=o.shape.length,l=p.data.get(n.dataId).values,m=n.shape.length,{batchSize:d,inHeight:f,inWidth:h,inChannels:g,outHeight:x,outWidth:b,padInfo:C,strideHeight:S,strideWidth:k,filterHeight:_,filterWidth:E,dilationHeight:R,dilationWidth:D,outShape:P}=w.computeDilation2DInfo(o.shape,n.shape,s,a,\"NHWC\",i),O=y.sizeFromShape(P),M=P.length,L=y.getArrayFromDType(o.dtype,O);for(let z=0;z=0&&oe=0&&lere&&(re=ve)}}}let ne=y.locToIndex([z,U,q,J],M,y.computeStrides(P));L[ne]=re}}}return{dataId:p.write(y.toTypedArray(L,o.dtype),P,o.dtype),shape:P,dtype:o.dtype}}};var E$={kernelName:zi,backendName:\"cpu\",kernelFunc:({inputs:r,backend:t,attrs:e})=>{let{x:o,filter:n,dy:s}=r,{strides:a,pad:i,dilations:p}=e,u=t,c=y.toNestedArray(o.shape,u.data.get(o.dataId).values),l=y.toNestedArray(n.shape,u.data.get(n.dataId).values),{batchSize:m,inHeight:d,inWidth:f,inChannels:h,outHeight:g,outWidth:x,padInfo:b,strideHeight:C,strideWidth:S,filterHeight:k,filterWidth:_,dilationHeight:E,dilationWidth:R,outShape:D}=w.computeDilation2DInfo(o.shape,n.shape,a,i,\"NHWC\",p);y.assert(s.rank===D.length,()=>`Error in ${zi}, dy must have the same rank as output ${D.length}, but got ${s.rank}`);let P=y.toNestedArray(D,u.data.get(s.dataId).values),O=y.makeZerosNestedTypedArray(n.shape,n.dtype);for(let L=0;L=0&&ee=0&&ieY&&(Y=le,J=ne,re=oe)}}}O[J][re][q]+=P[L][B][U][q]}}}return{dataId:u.write(y.toTypedArray(O,o.dtype),n.shape,n.dtype),shape:n.shape,dtype:n.dtype}}};var R$={kernelName:Bi,backendName:\"cpu\",kernelFunc:({inputs:r,backend:t,attrs:e})=>{let{x:o,filter:n,dy:s}=r,{strides:a,pad:i,dilations:p}=e,u=t,c=y.toNestedArray(o.shape,u.data.get(o.dataId).values),l=y.toNestedArray(n.shape,u.data.get(n.dataId).values),{batchSize:m,inHeight:d,inWidth:f,inChannels:h,outHeight:g,outWidth:x,padInfo:b,strideHeight:C,strideWidth:S,filterHeight:k,filterWidth:_,dilationHeight:E,dilationWidth:R,outShape:D}=w.computeDilation2DInfo(o.shape,n.shape,a,i,\"NHWC\",p);y.assert(s.rank===D.length,()=>`Error in ${Bi}, dy must have the same rank as output ${D.length}, but got ${s.rank}`);let P=y.toNestedArray(D,u.data.get(s.dataId).values),O=y.makeZerosNestedTypedArray(o.shape,o.dtype);for(let L=0;L=0&&ee=0&&ieY&&(Y=le,J=ee,re=ie)}}}O[L][J][re][q]+=P[L][B][U][q]}}}return{dataId:u.write(y.toTypedArray(O,o.dtype),o.shape,o.dtype),shape:o.shape,dtype:o.dtype}}};function QY(r){let{inputs:t,backend:e,attrs:o}=r,{image:n}=t,{canvas:s,options:a}=o,{contextOptions:i,imageOptions:p}=a||{},u=(p==null?void 0:p.alpha)||1,c=(i==null?void 0:i.contextType)||\"2d\";if(c!==\"2d\")throw new Error(`Context type ${i.contextType} is not supported by the CPU backend.`);let l=s.getContext(c,(i==null?void 0:i.contextAttributes)||{});if(l==null)throw new Error(`Could not get the context with ${c} type.`);let[m,d]=n.shape.slice(0,2),f=n.shape.length===2?1:n.shape[2],h=e.data.get(n.dataId).values,g=n.dtype===\"float32\"?255:1,x=new Uint8ClampedArray(d*m*4);for(let C=0;C1)throw new Error(`Tensor values for a float32 Tensor must be in the range [0 - 1] but encountered ${E}.`)}else if(n.dtype===\"int32\"&&(E<0||E>255))throw new Error(`Tensor values for a int32 Tensor must be in the range [0 - 255] but encountered ${E}.`);f===1?(S[0]=E*g,S[1]=E*g,S[2]=E*g):S[_]=E*g}let k=C*4;x[k+0]=Math.round(S[0]),x[k+1]=Math.round(S[1]),x[k+2]=Math.round(S[2]),x[k+3]=Math.round(S[3])}s.width=d,s.height=m;let b=new ImageData(x,d,m);return l.putImageData(b,0,0),n}var D$={kernelName:Pu,backendName:\"cpu\",kernelFunc:QY};function gi(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;Q(n,\"sum\");let i;n.dtype===\"bool\"?i=Do({inputs:{x:n},backend:e,attrs:{dtype:\"int32\"}}):i=mr({inputs:{x:n},backend:e});let p=i.shape.length,u=y.parseAxisParam(s,i.shape),c=w.getAxesPermutation(u,p),l=u,m=i;c!=null&&(m=It({inputs:{x:i},backend:e,attrs:{perm:c}}),l=w.getInnerMostAxes(l.length,p)),w.assertAxesAreInnerMostDims(\"sum\",l,m.shape.length);let[d,f]=w.computeOutAndReduceShapes(m.shape,l),h=w.upcastType(m.dtype,\"int32\"),g=wc(e,d,h),x=y.sizeFromShape(f),b=e.data.get(g.dataId).values,C=e.data.get(m.dataId).values;for(let S=0;S=0&&(m=gi({inputs:{x:m},backend:e,attrs:{axis:u[h]-(a.length-d),keepDims:!1}}),f.push(m)),d--)}for(let h of f)h!==m&&e.disposeIntermediateTensorInfo(h);return m}var F$={kernelName:Vi,backendName:\"cpu\",kernelFunc:ZY};function JY(r){let{inputs:t,backend:e}=r,{dy:o,y:n}=t;Q([o,n],\"eluGrad\");let s=new Float32Array(y.sizeFromShape(n.shape)),a=e.data.get(n.dataId).values,i=e.data.get(o.dataId).values;for(let p=0;p=0?s[p]=i[p]:s[p]=i[p]*(u+1)}return e.makeTensorInfo(n.shape,\"float32\",s)}var P$={kernelName:Ya,backendName:\"cpu\",kernelFunc:JY};var eQ=w.ERF_P,tQ=w.ERF_A1,rQ=w.ERF_A2,oQ=w.ERF_A3,nQ=w.ERF_A4,sQ=w.ERF_A5,aQ=Ie(xn,r=>{let t=Math.sign(r),e=Math.abs(r),o=1/(1+eQ*e);return t*(1-((((sQ*o+nQ)*o+oQ)*o+rQ)*o+tQ)*o*Math.exp(-e*e))}),O$={kernelName:xn,backendName:\"cpu\",kernelFunc:aQ};function $c(r){let{inputs:t,backend:e,attrs:o}=r,{input:n}=t,{dim:s}=o,a=n.shape.length,i=n.shape.slice(),p=s;return s<0&&(y.assert(-(a+1)<=s,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+s+1),i.splice(p,0,1),Ve({inputs:{x:n},backend:e,attrs:{shape:i}})}var M$={kernelName:na,backendName:\"cpu\",kernelFunc:$c};var iQ=ze((r,t)=>r/t),Ul=Ye(hn,iQ),Gl={kernelName:hn,backendName:\"cpu\",kernelFunc:Ul};function Vf(r,t,e){let o=r.shape,n=o[0],s=o[1],a=e.data.get(r.dataId),i=a.complexTensorInfos.real,p=a.complexTensorInfos.imag,u=[n,s],c=y.sizeFromShape(u),l=y.getTypedArrayFromDType(\"float32\",c),m=y.getTypedArrayFromDType(\"float32\",c);for(let g=0;g{let{image:o}=r,n=e,s=y.getTypedArrayFromDType(o.dtype,y.sizeFromShape(o.shape)),[a,i,p,u]=o.shape,c=n.data.get(o.dataId).values;for(let m=0;m=0&&C=0,()=>`GatherV2: the index value ${k} is not in [0, ${c-1}]`)}let l=i;i==null&&(l=0);let m=y.sizeFromShape(s.shape),d=w.segment_util.collectGatherOpShapeInfo(n,s,p,l),f=Ve({inputs:{x:n},backend:e,attrs:{shape:[d.batchSize,d.outerSize,d.dimSize,d.sliceSize]}}),h=Ve({inputs:{x:s},backend:e,attrs:{shape:[d.batchSize,m/d.batchSize]}}),g=[d.batchSize,d.outerSize,m/d.batchSize,d.sliceSize],x=e.bufferSync(h),b=e.bufferSync(f),C=_f(b,x,g);return e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),e.makeTensorInfo(d.outputShape,C.dtype,C.values)}var G$={kernelName:aa,backendName:\"cpu\",kernelFunc:gQ};function xQ(r){let{inputs:t,backend:e}=r,{input:o}=t,n=y.sizeFromShape(o.shape),s=o.shape[o.shape.length-1],a=n/s,i=Ve({inputs:{x:o},backend:e,attrs:{shape:[a,s]}}),p=Vf(i,!0,e),u=Ve({inputs:{x:p},backend:e,attrs:{shape:o.shape}});return e.disposeIntermediateTensorInfo(i),e.disposeIntermediateTensorInfo(p),u}var H$={kernelName:Ui,backendName:\"cpu\",kernelFunc:xQ};var yQ=Ie(_n,r=>Number.isFinite(r)?1:0,\"bool\"),K$={kernelName:_n,backendName:\"cpu\",kernelFunc:yQ};var bQ=Ie($n,r=>Math.abs(r)===1/0?1:0,\"bool\"),q$={kernelName:$n,backendName:\"cpu\",kernelFunc:bQ};var CQ=Ie(En,r=>Number.isNaN(r)?1:0,\"bool\"),j$={kernelName:En,backendName:\"cpu\",kernelFunc:CQ};function wQ(r){let{backend:t,attrs:e}=r,{start:o,stop:n,num:s}=e,a=$f(o,n,s);return t.makeTensorInfo([a.length],\"float32\",a)}var X$={kernelName:Fn,backendName:\"cpu\",kernelFunc:wQ};var SQ=Ie(On,r=>Math.log1p(r)),Y$={kernelName:On,backendName:\"cpu\",kernelFunc:SQ};var IQ=ze((r,t)=>r&&t),vQ=Ye(Mn,IQ,null,\"bool\"),Q$={kernelName:Mn,backendName:\"cpu\",kernelFunc:vQ};var kQ=Ie(Ln,r=>r?0:1,\"bool\"),Z$={kernelName:Ln,backendName:\"cpu\",kernelFunc:kQ};var NQ=ze((r,t)=>r||t),TQ=Ye(Bn,NQ,null,\"bool\"),J$={kernelName:Bn,backendName:\"cpu\",kernelFunc:TQ};function _Q(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o;Q(n,\"LRN\");let u=n.shape[3],c=u-1,l=e.data.get(n.dataId).values,m=y.sizeFromShape(n.shape),d=new Float32Array(m);function f(h){let g=h%u,x=h-g+Math.max(0,g-s),b=h-g+Math.min(g+s,c),C=0;for(;x<=b;x++){let S=l[x];C+=S*S}return C}for(let h=0;h`Error in maxPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p),l;if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))l=mr({inputs:{x:n},backend:e});else{let m=e.data.get(n.dataId).values,d=y.computeStrides(n.shape),f=_c(m,n.shape,n.dtype,d,c,\"max\");l=e.makeTensorInfo(c.outShape,n.dtype,f.values)}return l}var oE={kernelName:Un,backendName:\"cpu\",kernelFunc:EQ};function RQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o;Q(n,\"maxPool3d\");let c=w.computePool3DInfo(n.shape,s,a,1,i,p,u),l=e.data.get(n.dataId).values,m=zf(l,n.shape,n.dtype,y.computeStrides(n.shape),c,\"max\");return e.makeTensorInfo(m.shape,\"float32\",m.values)}var nE={kernelName:ia,backendName:\"cpu\",kernelFunc:RQ};function DQ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o;Q([n,s],\"maxPool3DGrad\");let c=w.computePool3DInfo(s.shape,a,i,1,p,u),l=e.bufferSync(s),m=J_(l,c),d=c.strideDepth,f=c.strideHeight,h=c.strideWidth,g=c.dilationDepth,x=c.dilationHeight,b=c.dilationWidth,C=c.effectiveFilterDepth,S=c.effectiveFilterHeight,k=c.effectiveFilterWidth,_=C-1-c.padInfo.front,E=k-1-c.padInfo.left,R=S-1-c.padInfo.top,D=me(s.shape,\"float32\"),P=e.bufferSync(n);for(let O=0;O=c.outDepth||Math.floor(re)!==re))for(let ne=0;ne=c.outHeight||Math.floor(ee)!==ee))for(let oe=0;oe=c.outWidth||Math.floor(ie)!==ie)continue;let le=C*S*k-1-m.get(O,re,ee,ie,M),be=J*S*k+ne*k+oe,_e=le===be?1:0;if(_e===0)continue;let ve=P.get(O,re,ee,ie,M);Y+=ve*_e}}}D.set(Y,O,L,B,z,M)}return e.makeTensorInfo(D.shape,D.dtype,D.values)}var sE={kernelName:Ki,backendName:\"cpu\",kernelFunc:DQ};function AQ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s,output:a}=t,i=s;Q([s,a],\"maxPoolGrad\");let{filterSize:p,strides:u,pad:c,dimRoundingMode:l}=o,m=w.computePool2DInfo(i.shape,p,u,1,c,l),d=e.data.get(i.dataId).values,f=me(m.outShape,i.dtype,Bf(d,i.shape,i.dtype,m).values),h=m.strideHeight,g=m.strideWidth,x=m.dilationHeight,b=m.dilationWidth,C=m.effectiveFilterHeight,S=m.effectiveFilterWidth,k=S-1-m.padInfo.left,_=C-1-m.padInfo.top,E=me(i.shape,\"float32\"),R=e.data.get(n.dataId).values,D=me(n.shape,\"float32\",R);for(let P=0;P=m.outHeight||Math.floor(q)!==q))for(let Y=0;Y=m.outWidth||Math.floor(J)!==J)continue;let re=C*S-1-f.get(P,q,J,O),ne=j*S+Y,ee=re===ne?1:0;if(ee===0)continue;let oe=D.get(P,q,J,O);U+=oe*ee}}E.set(U,P,M,L,O)}return e.makeTensorInfo(E.shape,E.dtype,E.values)}var aE={kernelName:Hi,backendName:\"cpu\",kernelFunc:AQ};function iE(r,t,e,o,n){let s=y.computeStrides(t),a=_c(r,t,e,s,n,\"max\"),i=Bf(r,t,e,n,!0,o);return[a.values,i.values]}var uE={kernelName:ua,backendName:\"cpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{filterSize:n,strides:s,pad:a,includeBatchInIndex:i}=t,p=e;Q(o,\"MaxPoolWithArgmax\");let u=p.data.get(o.dataId).values,c=w.computePool2DInfo(o.shape,n,s,[1,1],a),[l,m]=iE(u,o.shape,o.dtype,i,c),d=p.write(l,c.outShape,o.dtype),f=p.write(m,c.outShape,o.dtype);return[{dataId:d,shape:c.outShape,dtype:o.dtype},{dataId:f,shape:c.outShape,dtype:\"int32\"}]}};function FQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=y.parseAxisParam(s,n.shape),u=w.computeOutAndReduceShapes(n.shape,i)[1],c=y.sizeFromShape(u),l=[],m=e.makeTensorInfo([],\"float32\",new Float32Array([c]));l.push(m);let d=Do({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}});l.push(d);let f=Ul({inputs:{a:d,b:m},backend:e});l.push(f);let h=gi({inputs:{x:f},backend:e,attrs:{axis:s,keepDims:a}});return l.forEach(g=>e.disposeIntermediateTensorInfo(g)),h}var pE={kernelName:Gn,backendName:\"cpu\",kernelFunc:FQ};function PQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;Q(n,\"min\");let i=y.parseAxisParam(s,n.shape),p=i,u=w.getAxesPermutation(p,n.shape.length),c=n;u!=null&&(c=It({inputs:{x:n},backend:e,attrs:{perm:u}}),p=w.getInnerMostAxes(p.length,n.shape.length)),w.assertAxesAreInnerMostDims(\"min\",p,c.shape.length);let[l,m]=w.computeOutAndReduceShapes(c.shape,p),d=y.sizeFromShape(m),f=y.makeZerosTypedArray(y.sizeFromShape(l),c.dtype),h=e.data.get(c.dataId).values;for(let x=0;xC[0]+n.shape[S]+C[1]),p=s.map(C=>C[0]),u=s.map((C,S)=>C[0]+n.shape[S]),c=a===\"reflect\"?0:1,l=e.data.get(n.dataId).values,m=n.shape.length,d=y.computeStrides(n.shape),f=y.sizeFromShape(i),h=i.length,g=y.computeStrides(i),x=y.getTypedArrayFromDType(n.dtype,f);for(let C=0;C=u[_]&&(S[_]=(u[_]-1)*2-S[_]+c);S=S.map((_,E)=>_-p[E]);let k=y.locToIndex(S,m,d);x[C]=l[k]}return{dataId:e.write(x,i,n.dtype),shape:i,dtype:n.dtype}}var lE={kernelName:qn,backendName:\"cpu\",kernelFunc:OQ};var MQ=ze((r,t)=>{let e=r%t;return r<0&&t<0||r>=0&&t>=0?e:(e+t)%t}),LQ=Ye(jn,MQ),mE={kernelName:jn,backendName:\"cpu\",kernelFunc:LQ};var fE=Kp(qw());function SI(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{dim:s}=o,a=n.shape.length,i=s;if(i===-1&&(i=a-1),i!==a-1)throw Error(`Softmax along a non-last dimension is not yet supported. Logits was rank ${a} and dim was ${i}`);let p=y.parseAxisParam([i],n.shape),u=wI({inputs:{x:n},backend:e,attrs:{reductionIndices:p,keepDims:!1}}),c=w.expandShapeToKeepDim(u.shape,p),l=Ve({inputs:{x:u},backend:e,attrs:{shape:c}}),m=Vl({inputs:{a:n,b:l},backend:e}),d=KS({inputs:{x:m},backend:e}),f=gi({inputs:{x:d},backend:e,attrs:{axis:p,keepDims:!1}}),h=Ve({inputs:{x:f},backend:e,attrs:{shape:c}}),g=Ul({inputs:{a:d,b:h},backend:e});return e.disposeIntermediateTensorInfo(u),e.disposeIntermediateTensorInfo(l),e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),g}var dE={kernelName:vs,backendName:\"cpu\",kernelFunc:SI};function BQ(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o;Q(n,\"multinomial\");let p=i?n:SI({inputs:{logits:n},backend:e,attrs:{dim:-1}}),u=p.shape[0],c=p.shape[1],l=e.data.get(p.dataId).values,m=[u,s],d=y.makeZerosTypedArray(y.sizeFromShape(m),\"int32\");for(let f=0;f=0&&l[m]{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=$c({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=yu({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeIntermediateTensorInfo(c)),u}var IE={kernelName:la,backendName:\"cpu\",kernelFunc:II};function qQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{paddings:s,constantValue:a}=o;Q(n,\"pad\");let i=s.map((b,C)=>b[0]+n.shape[C]+b[1]),p=s.map(b=>b[0]),u=e.data.get(n.dataId).values,c=y.sizeFromShape(n.shape),l=n.shape.length,m=y.computeStrides(n.shape),d=y.sizeFromShape(i),f=i.length,h=y.computeStrides(i),g=y.getTypedArrayFromDType(n.dtype,d);a!==0&&g.fill(a);for(let b=0;b_+p[E]),k=y.locToIndex(S,f,h);g[k]=u[b]}return{dataId:e.write(g,i,n.dtype),shape:i,dtype:n.dtype}}var Wf={kernelName:ts,backendName:\"cpu\",kernelFunc:qQ};var jQ=ze((r,t)=>Math.pow(r,t)),XQ=Ye(rs,jQ),vE={kernelName:rs,backendName:\"cpu\",kernelFunc:XQ};function YQ(r){let{inputs:t,backend:e,attrs:o}=r,{paramsNestedSplits:n,paramsDenseValues:s,indices:a}=t,{outputRaggedRank:i}=o,p=n.map(x=>e.data.get(x.dataId).values),u=n.map(x=>x.shape),c=e.data.get(s.dataId).values,l=e.data.get(a.dataId).values,[m,d,f]=Rf(p,u,c,s.shape,s.dtype,l,a.shape,i),h=m.map(x=>e.makeTensorInfo([x.length],\"int32\",x)),g=e.makeTensorInfo(f,s.dtype,d);return h.concat([g])}var kE={kernelName:Qp,backendName:\"cpu\",kernelFunc:YQ};function QQ(r){let{inputs:t,backend:e}=r,{starts:o,limits:n,deltas:s}=t,a=e.data.get(o.dataId).values,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,[u,c]=Df(a,o.shape,o.dtype,i,n.shape,p,s.shape),l=e.makeTensorInfo([u.length],\"int32\",u),m=e.makeTensorInfo([c.length],o.dtype,c);return[l,m]}var NE={kernelName:Zp,backendName:\"cpu\",kernelFunc:QQ};function ZQ(r){let{inputs:t,backend:e,attrs:o}=r,{shape:n,values:s,defaultValue:a,rowPartitionTensors:i}=t,{rowPartitionTypes:p}=o,u=e.data.get(n.dataId).values,c=e.data.get(s.dataId).values,l=e.data.get(a.dataId).values,m=i.map(g=>e.data.get(g.dataId).values),d=i.map(g=>g.shape),[f,h]=Af(u,n.shape,c,s.shape,s.dtype,l,a.shape,m,d,p);return e.makeTensorInfo(f,s.dtype,h)}var TE={kernelName:Jp,backendName:\"cpu\",kernelFunc:ZQ};function JQ(r){let{backend:t,attrs:e}=r,{start:o,stop:n,dtype:s,step:a}=e,i=fp(o,n,a,s);return t.makeTensorInfo([i.length],s,i)}var _E={kernelName:ma,backendName:\"cpu\",kernelFunc:JQ};var e7=Ie(ss,r=>1/r),$E={kernelName:ss,backendName:\"cpu\",kernelFunc:e7};function t7(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o;Q(n,\"resizeBilinear\");let p=y.computeStrides(n.shape),[u,c]=i,[l,m,d,f]=n.shape,h=e.data.get(n.dataId).values,g=new Float32Array(y.sizeFromShape([l,u,c,f])),x=[s&&u>1?m-1:m,s&&c>1?d-1:d],b=[s&&u>1?u-1:u,s&&c>1?c-1:c],C=0,S=x[0]/b[0],k=x[1]/b[1];for(let _=0;_1?u-1:u,a&&d>1?c-1:c],g=[a&&m>1?m-1:m,a&&d>1?d-1:d],x=h[0]/g[0],b=h[1]/g[1],C=e.data.get(s.dataId).values,S=0;for(let k=0;k1?m-1:m,s&&c>1?d-1:d],b=[s&&u>1?u-1:u,s&&c>1?c-1:c],C=x[0]/b[0],S=x[1]/b[1],k=0;for(let _=0;_1?c-1:c,a&&f>1?l-1:l],b=[a&&d>1?d-1:d,a&&f>1?f-1:f],C=x[0]/b[0],S=x[1]/b[1],k=1/C,_=1/S,E=Math.ceil(k)*2+2,R=Math.ceil(_)*2+2;for(let D=0;D=d)continue;let ee=P+ne*p[1],oe=ne*C,ie=Math.min(c-1,a?Math.round(oe):Math.floor(oe));if(O===ie)for(let le=0;le=f)continue;let _e=ee+be*p[2],ve=be*S,Fe=Math.min(l-1,a?Math.round(ve):Math.floor(ve));z===Fe&&(J+=g[_e+Y])}}h[U+Y]=J}}}}return e.makeTensorInfo(n.shape,n.dtype,h)}var AE={kernelName:Ja,backendName:\"cpu\",kernelFunc:n7};function s7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o;Q(n,\"reverse\");let a=n.shape.length,i=y.parseAxisParam(s,n.shape);if(a===0)return mr({inputs:{x:n},backend:e});let p=new tt(n.shape,n.dtype),u=e.bufferSync(n);for(let c=0;cm[d]=n.shape[d]-1-m[d]),p.set(u.get(...m),...l)}return e.makeTensorInfo(p.shape,p.dtype,p.values)}var FE={kernelName:cs,backendName:\"cpu\",kernelFunc:s7};var PE={kernelName:As,backendName:\"cpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{image:o}=r,{radians:n,fillValue:s,center:a}=t,i=e,p=y.getTypedArrayFromDType(o.dtype,y.sizeFromShape(o.shape)),[u,c,l,m]=o.shape,[d,f]=w.getImageCenter(a,c,l),h=255,g=Math.sin(n),x=Math.cos(n),b=i.data.get(o.dataId).values;for(let S=0;S=0&&B=0&&z{let t=Math.floor(r);return r-t<.5?Math.floor(r):r-t>.5?Math.ceil(r):t%2===0?t:t+1}),OE={kernelName:ls,backendName:\"cpu\",kernelFunc:a7};function i7(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n,updates:s}=t,{shape:a}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(s,n,a),m=!0,d=e.bufferSync(n),f=e.bufferSync(s),h=zs(d,f,a,l,u,p,i,c,0,m);return e.makeTensorInfo(a,h.dtype,h.values)}var ME={kernelName:ds,backendName:\"cpu\",kernelFunc:i7};function u7(r,t){let e=0,o=r.length,n=0;for(;e1||n.shape.length===1?1:y.sizeFromShape(n.shape.slice(1));for(let f=0;fr>=0?d7*r:m7*(Math.exp(r)-1)),VE={kernelName:gs,backendName:\"cpu\",kernelFunc:f7};var h7=Ie(bs,r=>r<0?-1:r>0?1:0),WE={kernelName:bs,backendName:\"cpu\",kernelFunc:h7};var g7=Ie(xs,r=>Math.sin(r)),UE={kernelName:xs,backendName:\"cpu\",kernelFunc:g7};var x7=Ie(ys,r=>Math.sinh(r)),GE={kernelName:ys,backendName:\"cpu\",kernelFunc:x7};var y7=11920928955078125e-23,HE=Math.log(y7)+2,b7=Ie(ws,r=>{let t=r>-HE,e=rNumber(g)))),e.makeTensorInfo([h.length],o.dtype,new Int32Array(h))]}var jE={kernelName:ji,backendName:\"cpu\",kernelFunc:w7};function S7(r){let{inputs:t,backend:e}=r,{inputIndices:o,inputShape:n,newShape:s}=t;if(o.shape.length!==2)throw new Error(`Input indices should be a matrix but received shape\n ${o.shape}`);if(n.shape.length!==1)throw new Error(`Input shape should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Target shape should be a vector but received shape ${s.shape}`);let a=Array.from(e.data.get(n.dataId).values),i=e.data.get(o.dataId).values,p=Array.from(e.data.get(s.dataId).values),[u,c,l]=Pf(i,o.shape,o.dtype,a,p);return[e.makeTensorInfo(c,o.dtype,u),e.makeTensorInfo([l.length],s.dtype,new Int32Array(l))]}var XE={kernelName:ti,backendName:\"cpu\",kernelFunc:S7};function I7(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);if(n.shape[0]!==s.shape[0])throw new Error(\"segmentIds and indices should have same size.\");let a=e.data.get(o.dataId).values,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,[u,c]=Nc(a,o.shape,o.dtype,i,p,!0);return e.makeTensorInfo(c,o.dtype,u)}var YE={kernelName:ya,backendName:\"cpu\",kernelFunc:I7};function v7(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);if(n.shape[0]!==s.shape[0])throw new Error(\"segmentIds and indices should have same size.\");let a=e.data.get(o.dataId).values,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,[u,c]=Nc(a,o.shape,o.dtype,i,p);return e.makeTensorInfo(c,o.dtype,u)}var QE={kernelName:ba,backendName:\"cpu\",kernelFunc:v7};function k7(r){let{inputs:t,backend:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=t,{outputShape:i}=o,{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=w.calculateShapes(s,n,i),d=!1,f=e.bufferSync(n),h;switch(s.dtype){case\"bool\":{let g=e.bufferSync(s),x=!!e.data.get(a.dataId).values[0];h=zs(f,g,i,m,c,u,p,l,x,d);break}case\"float32\":{let g=e.bufferSync(s),x=e.data.get(a.dataId).values[0];h=zs(f,g,i,m,c,u,p,l,x,d);break}case\"int32\":{let g=e.bufferSync(s),x=e.data.get(a.dataId).values[0];h=zs(f,g,i,m,c,u,p,l,x,d);break}case\"string\":{let g=e.bufferSync(s),x=y.decodeString(e.data.get(a.dataId).values[0]);h=zs(f,g,i,m,c,u,p,l,x,d);break}default:throw new Error(`Unsupported type ${s.dtype}`)}return e.makeTensorInfo(i,h.dtype,h.values)}var ZE={kernelName:ks,backendName:\"cpu\",kernelFunc:k7};function N7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=o,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=new Array(n.shape.length).fill(0),c=n.shape.slice();return p.map(l=>{let m=[...c];m[i]=l;let d=Fo({inputs:{x:n},backend:e,attrs:{begin:u,size:m}});return u[i]+=l,d})}var JE={kernelName:xa,backendName:\"cpu\",kernelFunc:N7};var eR={kernelName:Xi,backendName:\"cpu\",kernelFunc:({inputs:r,backend:t})=>{let{x:e}=r,o=t;Q(e,\"square\");let n=o.data.get(e.dataId).values,s=new Float32Array(n.length);for(let i=0;i{let e=t;return isNaN(r)?NaN:r>0?1:e.alpha}),tR={kernelName:So,backendName:\"cpu\",kernelFunc:T7};function _7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o;Q(n,\"stridedSlice\");let{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=Ve({inputs:{x:n},backend:e,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let _=ct.computeOutShape(b,C,S),E=Fo({inputs:{x:n},backend:e,attrs:{begin:b,size:_}});k=Ve({inputs:{x:E},backend:e,attrs:{shape:f}}),e.disposeIntermediateTensorInfo(E)}else{let _=e.bufferSync(n),E=Of(d,_,S,b);k=e.makeTensorInfo(f,E.dtype,E.values)}return k}var rR={kernelName:Ts,backendName:\"cpu\",kernelFunc:_7};function $7(r){let{inputs:t,backend:e,attrs:o}=r,{separator:n,nGramWidths:s,leftPad:a,rightPad:i,padWidth:p,preserveShortSequences:u}=o,{data:c,dataSplits:l}=t,m=e.data.get(c.dataId).values,d=e.data.get(l.dataId).values,[f,h]=gp(m,d,n,s,a,i,p,u);return[e.makeTensorInfo([f.length],\"string\",f),e.makeTensorInfo(l.shape,\"int32\",h)]}var oR={kernelName:Ca,backendName:\"cpu\",kernelFunc:$7};function E7(r){let{inputs:t,backend:e,attrs:o}=r,{skipEmpty:n}=o,{input:s,delimiter:a}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(s.shape.length!==1)throw new Error(`Input must be a vector, got shape: ${s.shape}`);if(a.shape.length!==0)throw new Error(`Delimiter must be a scalar, got shape: ${a.shape}`);let i=e.data.get(s.dataId).values,p=e.data.get(a.dataId).values[0],[u,c,l]=xp(i,p,n),m=c.length;return[e.makeTensorInfo([m,2],\"int32\",u),e.makeTensorInfo([m],\"string\",c),e.makeTensorInfo([2],\"int32\",new Int32Array(l))]}var nR={kernelName:Yi,backendName:\"cpu\",kernelFunc:E7};function R7(r){let{inputs:t,backend:e,attrs:o}=r,{numBuckets:n}=o,{input:s}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(n<=0)throw new Error(\"Number of buckets must be at least 1\");let a=e.data.get(s.dataId).values,i=yp(a,n);return e.makeTensorInfo(s.shape,\"int32\",i)}var sR={kernelName:Qi,backendName:\"cpu\",kernelFunc:R7};var D7=Ie($s,r=>Math.tan(r)),aR={kernelName:$s,backendName:\"cpu\",kernelFunc:D7};var A7=Ie(Es,r=>Math.tanh(r)),iR={kernelName:Es,backendName:\"cpu\",kernelFunc:A7};function F7(r){let{inputs:t,backend:e}=r,{tensor:o,indices:n,updates:s}=t,{sliceRank:a,numUpdates:i,sliceSize:p,strides:u,outputSize:c}=w.calculateShapes(s,n,o.shape),l=!1,m=e.bufferSync(n),d=e.bufferSync(s),f=e.bufferSync(o),h=zs(m,d,o.shape,c,p,i,a,u,f,l);return e.makeTensorInfo(o.shape,h.dtype,h.values)}var uR={kernelName:fs,backendName:\"cpu\",kernelFunc:F7};function P7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{reps:s}=o;Q(n,\"tile\");let a=Mf(e.bufferSync(n),s);return e.makeTensorInfo(a.shape,a.dtype,a.values)}var pR={kernelName:po,backendName:\"cpu\",kernelFunc:P7};function O7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{k:s,sorted:a}=o;Q(n,\"topk\");let i=e.data.get(n.dataId).values,[p,u]=Lf(i,n.shape,n.dtype,s,a);return[e.makeTensorInfo(p.shape,p.dtype,p.values),e.makeTensorInfo(u.shape,u.dtype,u.values)]}var cR={kernelName:Rs,backendName:\"cpu\",kernelFunc:O7};function M7(r){let{inputs:t,attrs:e,backend:o}=r,{image:n,transforms:s}=t,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=e,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=y.computeStrides(n.shape),b=x[0],C=x[1],S=x[2],k=y.computeStrides(g),_=k[0],E=k[1],R=k[2],D=y.getTypedArrayFromDType(n.dtype,y.sizeFromShape(g));D.fill(p);let P=o.data.get(n.dataId).values,O=o.data.get(s.dataId).values;for(let L=0;Lt-1)if(t<=1)e=0;else{let o=2*t;e-=o*Math.trunc(e/o),e>=t&&(e=o-e-1)}return y.clamp(0,e,t-1)}function B7(r,t){let e=r;if(e<0)if(t<=1)e=0;else{let o=t-1;e+=t*(Math.trunc(-e/o)+1)}else if(e>t-1)if(t<=1)e=0;else{let o=t-1;e-=t*Math.trunc(e/o)}return y.clamp(0,e,t-1)}function z7(r,t){return r}function V7(r,t){return y.clamp(0,r,t-1)}function ql(r,t,e,o,n,s,a,i,p,u,c){let l=a*o+i*n+p*s+u;return 0<=i&&ie.disposeIntermediateTensorInfo(f)),d}var hR={kernelName:Ji,backendName:\"cpu\",kernelFunc:K7};var q7=[z_,jT,V_,W_,JT,U_,G_,H_,K_,q_,j_,X_,Y_,Q_,Z_,e$,t$,r$,o$,B_,n$,s$,a$,e_,i$,ZT,t_,u$,XT,p$,l$,m$,d$,f$,h$,g$,x$,y$,b$,C$,w$,S$,I$,v$,k$,N$,T$,_$,$$,E$,R$,D$,F$,A_,P$,r_,O$,o_,M$,n_,L$,B$,z$,s_,a_,V$,W$,U$,G$,i_,u_,YT,H$,c$,K$,q$,j$,F_,p_,c_,X$,l_,Y$,Q$,Z$,J$,eE,tE,rE,m_,oE,nE,sE,aE,uE,pE,cE,d_,lE,mE,hE,f_,h_,gE,xE,yE,g_,bE,SE,IE,Wf,vE,P_,y_,kE,NE,TE,_E,QT,Gl,$E,O_,M_,L_,EE,RE,DE,AE,FE,PE,OE,I_,ME,BE,zE,VE,k_,WE,UE,GE,N_,dE,KE,qE,jE,XE,YE,QE,ZE,JE,__,eR,$_,E_,tR,rR,oR,nR,sR,R_,A$,aR,iR,uR,pR,cR,mR,x_,dR,fR,hR,CE];for(let r of q7)ri(r);var Ac={};qe(Ac,{assertNotComplex:()=>Vs,bindCanvasToFramebuffer:()=>rZ,bindColorTextureToFramebuffer:()=>Ql,bindTextureToProgramUniformSampler:()=>BI,bindTextureUnit:()=>bR,bindVertexBufferToProgramAttribute:()=>jf,callAndCheck:()=>ce,canBeRepresented:()=>TI,createFragmentShader:()=>$I,createFramebuffer:()=>OI,createProgram:()=>EI,createStaticIndexBuffer:()=>AI,createStaticVertexBuffer:()=>DI,createTexture:()=>FI,createVertexShader:()=>_I,getBatchDim:()=>yi,getExtensionOrThrow:()=>Ec,getFramebufferErrorMessage:()=>CR,getMaxTexturesInShader:()=>WI,getNumChannels:()=>eZ,getProgramUniformLocation:()=>LI,getProgramUniformLocationOrThrow:()=>MI,getRowsCols:()=>bi,getShapeAs3D:()=>Dc,getTextureShapeFromLogicalShape:()=>zI,getWebGLDisjointQueryTimerVersion:()=>UI,getWebGLErrorMessage:()=>yR,getWebGLMaxTextureSize:()=>VI,hasExtension:()=>qr,isCapableOfRenderingToFloatTexture:()=>GI,isDownloadFloatTextureEnabled:()=>HI,isReshapeFree:()=>Cu,isWebGLFenceEnabled:()=>KI,isWebGLVersionEnabled:()=>Yf,linkProgram:()=>RI,logShaderSourceAndInfoLog:()=>qf,resetMaxTextureSize:()=>oZ,resetMaxTexturesInShader:()=>nZ,unbindColorTextureFromFramebuffer:()=>Xf,unbindTextureUnit:()=>tZ,validateFramebuffer:()=>Rc,validateProgram:()=>Yl,validateTextureSize:()=>PI});var wp={},Uf={alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!0};function vI(r,t){wp[r]=t}function Kr(r,t){if(!(r in wp)||t!=null){let o=X7(r,t);if(o!==null)wp[r]=o;else return console.log(\"Could not get context for WebGL version\",r),null}let e=wp[r];return e==null||e.isContextLost()?(delete wp[r],Kr(r)):(e.disable(e.DEPTH_TEST),e.disable(e.STENCIL_TEST),e.disable(e.BLEND),e.disable(e.DITHER),e.disable(e.POLYGON_OFFSET_FILL),e.disable(e.SAMPLE_COVERAGE),e.enable(e.SCISSOR_TEST),e.enable(e.CULL_FACE),e.cullFace(e.BACK),wp[r])}function j7(r){if(!A().getBool(\"IS_SAFARI\")&&typeof OffscreenCanvas!=\"undefined\"&&r===2)return new OffscreenCanvas(300,150);if(typeof document!=\"undefined\")return document.createElement(\"canvas\");throw new Error(\"Cannot create a canvas in this context\")}function X7(r,t){if(r!==1&&r!==2)throw new Error(\"Cannot get WebGL rendering context, WebGL is disabled.\");let e=t==null?j7(r):t;return e.addEventListener(\"webglcontextlost\",o=>{o.preventDefault(),delete wp[r]},!1),A().getBool(\"SOFTWARE_WEBGL_ENABLED\")&&(Uf.failIfMajorPerformanceCaveat=!1),r===1?e.getContext(\"webgl\",Uf)||e.getContext(\"experimental-webgl\",Uf):e.getContext(\"webgl2\",Uf)}var bu;(function(r){r[r.DENSE=0]=\"DENSE\",r[r.SHARED_BATCH=1]=\"SHARED_BATCH\"})(bu||(bu={}));var dr;(function(r){r[r.RENDER=0]=\"RENDER\",r[r.UPLOAD=1]=\"UPLOAD\",r[r.PIXELS=2]=\"PIXELS\",r[r.DOWNLOAD=3]=\"DOWNLOAD\"})(dr||(dr={}));var rr;(function(r){r[r.UNPACKED_FLOAT16=0]=\"UNPACKED_FLOAT16\",r[r.UNPACKED_FLOAT32=1]=\"UNPACKED_FLOAT32\",r[r.PACKED_4X1_UNSIGNED_BYTE=2]=\"PACKED_4X1_UNSIGNED_BYTE\",r[r.PACKED_2X2_FLOAT32=3]=\"PACKED_2X2_FLOAT32\",r[r.PACKED_2X2_FLOAT16=4]=\"PACKED_2X2_FLOAT16\"})(rr||(rr={}));function Sp(r,t){return[t,r]}function gR(r,t){return r*t}function jl(r){let t=y.sizeFromShape(r),e=Math.ceil(t/4);return y.sizeToSquarishShape(e)}function La(r,t){return[Math.max(1,Math.ceil(t/2)),Math.max(1,Math.ceil(r/2))]}function xR(r,t){let[e,o]=La(r,t);return e*o*4}function Xl(r,t){let e=r,o,n,s,a,i,p,u,c,l,m;return A().getNumber(\"WEBGL_VERSION\")===2?(o=e.R32F,n=e.R16F,s=e.RGBA16F,a=e.RGBA32F,i=e.RED,u=4,c=1,l=e.HALF_FLOAT,m=e.FLOAT,p=e.RGBA8):(o=r.RGBA,n=r.RGBA,s=r.RGBA,a=e.RGBA,i=r.RGBA,u=4,c=4,l=t!=null?t.HALF_FLOAT_OES:null,m=r.FLOAT,p=r.RGBA),{internalFormatFloat:o,internalFormatHalfFloat:n,internalFormatPackedHalfFloat:s,internalFormatPackedFloat:a,textureFormatFloat:i,downloadTextureFormat:p,downloadUnpackNumChannels:u,defaultNumChannels:c,textureTypeHalfFloat:l,textureTypeFloat:m}}function ce(r,t){let e=t();return A().getBool(\"DEBUG\")&&Y7(r),e}function Y7(r){let t=r.getError();if(t!==r.NO_ERROR)throw new Error(\"WebGL Error: \"+yR(r,t))}var Q7=596e-10,Z7=65504;function TI(r){return!!(A().getBool(\"WEBGL_RENDER_FLOAT32_ENABLED\")||r===0||Q7r.getExtension(t),'Extension \"'+t+'\" not supported on this browser.')}function _I(r,t){let e=xi(r,()=>r.createShader(r.VERTEX_SHADER),\"Unable to create vertex WebGLShader.\");if(ce(r,()=>r.shaderSource(e,t)),ce(r,()=>r.compileShader(e)),r.getShaderParameter(e,r.COMPILE_STATUS)===!1)throw console.log(r.getShaderInfoLog(e)),new Error(\"Failed to compile vertex shader.\");return e}function $I(r,t){let e=xi(r,()=>r.createShader(r.FRAGMENT_SHADER),\"Unable to create fragment WebGLShader.\");if(ce(r,()=>r.shaderSource(e,t)),ce(r,()=>r.compileShader(e)),A().get(\"ENGINE_COMPILE_ONLY\"))return e;if(r.getShaderParameter(e,r.COMPILE_STATUS)===!1)throw qf(t,r.getShaderInfoLog(e)),new Error(\"Failed to compile fragment shader.\");return e}var J7=/ERROR: [0-9]+:([0-9]+):/g;function qf(r,t){let e=J7.exec(t);if(e==null){console.log(`Couldn't parse line number in error: ${t}`),console.log(r);return}let o=+e[1],n=r.split(`\n`),s=n.length.toString().length+2,a=n.map((l,m)=>y.rightPad((m+1).toString(),s)+l),i=0;for(let l=0;lr.createProgram(),\"Unable to create WebGLProgram.\")}function RI(r,t){if(ce(r,()=>r.linkProgram(t)),!A().get(\"ENGINE_COMPILE_ONLY\")&&r.getProgramParameter(t,r.LINK_STATUS)===!1)throw console.log(r.getProgramInfoLog(t)),new Error(\"Failed to link vertex and fragment shaders.\")}function Yl(r,t){if(ce(r,()=>r.validateProgram(t)),r.getProgramParameter(t,r.VALIDATE_STATUS)===!1)throw console.log(r.getProgramInfoLog(t)),new Error(\"Shader program validation failed.\")}function DI(r,t){let e=xi(r,()=>r.createBuffer(),\"Unable to create WebGLBuffer\");return ce(r,()=>r.bindBuffer(r.ARRAY_BUFFER,e)),ce(r,()=>r.bufferData(r.ARRAY_BUFFER,t,r.STATIC_DRAW)),e}function AI(r,t){let e=xi(r,()=>r.createBuffer(),\"Unable to create WebGLBuffer\");return ce(r,()=>r.bindBuffer(r.ELEMENT_ARRAY_BUFFER,e)),ce(r,()=>r.bufferData(r.ELEMENT_ARRAY_BUFFER,t,r.STATIC_DRAW)),e}function eZ(){return A().getNumber(\"WEBGL_VERSION\")===2?1:4}function FI(r){return xi(r,()=>r.createTexture(),\"Unable to create WebGLTexture.\")}function PI(r,t){let e=A().getNumber(\"WEBGL_MAX_TEXTURE_SIZE\");if(r<=0||t<=0){let o=`[${r}x${t}]`;throw new Error(\"Requested texture size \"+o+\" is invalid.\")}if(r>e||t>e){let o=`[${r}x${t}]`,n=`[${e}x${e}]`;throw new Error(\"Requested texture size \"+o+\" greater than WebGL maximum on this browser / GPU \"+n+\".\")}}function OI(r){return xi(r,()=>r.createFramebuffer(),\"Unable to create WebGLFramebuffer.\")}function jf(r,t,e,o,n,s,a){let i=r.getAttribLocation(t,e);return i===-1?!1:(ce(r,()=>r.bindBuffer(r.ARRAY_BUFFER,o)),ce(r,()=>r.vertexAttribPointer(i,n,r.FLOAT,!1,s,a)),ce(r,()=>r.enableVertexAttribArray(i)),!0)}function bR(r,t,e){wR(r,e),ce(r,()=>r.activeTexture(r.TEXTURE0+e)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,t))}function tZ(r,t){wR(r,t),ce(r,()=>r.activeTexture(r.TEXTURE0+t)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null))}function MI(r,t,e){return xi(r,()=>r.getUniformLocation(t,e),'uniform \"'+e+'\" not present in program.')}function LI(r,t,e){return r.getUniformLocation(t,e)}function BI(r,t,e,o){ce(r,()=>bR(r,t,o)),ce(r,()=>r.uniform1i(e,o))}function rZ(r){ce(r,()=>r.bindFramebuffer(r.FRAMEBUFFER,null)),ce(r,()=>r.viewport(0,0,r.canvas.width,r.canvas.height)),ce(r,()=>r.scissor(0,0,r.canvas.width,r.canvas.height))}function Ql(r,t,e){ce(r,()=>r.bindFramebuffer(r.FRAMEBUFFER,e)),ce(r,()=>r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,t,0))}function Xf(r,t){ce(r,()=>r.bindFramebuffer(r.FRAMEBUFFER,t)),ce(r,()=>r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,null,0))}function Rc(r){let t=r.checkFramebufferStatus(r.FRAMEBUFFER);if(t!==r.FRAMEBUFFER_COMPLETE)throw new Error(\"Error binding framebuffer: \"+CR(r,t))}function CR(r,t){switch(t){case r.FRAMEBUFFER_INCOMPLETE_ATTACHMENT:return\"FRAMEBUFFER_INCOMPLETE_ATTACHMENT\";case r.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:return\"FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT\";case r.FRAMEBUFFER_INCOMPLETE_DIMENSIONS:return\"FRAMEBUFFER_INCOMPLETE_DIMENSIONS\";case r.FRAMEBUFFER_UNSUPPORTED:return\"FRAMEBUFFER_UNSUPPORTED\";default:return`unknown error ${t}`}}function xi(r,t,e){let o=ce(r,()=>t());if(o==null)throw new Error(e);return o}function wR(r,t){let e=r.MAX_COMBINED_TEXTURE_IMAGE_UNITS-1,o=t+r.TEXTURE0;if(oe){let n=`[gl.TEXTURE0, gl.TEXTURE${e}]`;throw new Error(`textureUnit must be in ${n}.`)}}function yi(r,t=2){return y.sizeFromShape(r.slice(0,r.length-t))}function bi(r){if(r.length===0)throw Error(\"Cannot get rows and columns of an empty shape array.\");return[r.length>1?r[r.length-2]:1,r[r.length-1]]}function Dc(r){let t=[1,1,1];return r.length===0||r.length===1&&r[0]===1||(t=[yi(r),...bi(r)]),t}function zI(r,t=!1){let e=A().getNumber(\"WEBGL_MAX_TEXTURE_SIZE\"),o=A().getNumber(\"WEBGL_MAX_SIZE_FOR_NARROW_TEXTURE\");o===1/0&&A().getBool(\"WEBGL_AUTO_SQUARIFY_NARROW_TEXTURE_SHAPE\")&&(o=e/2),t&&(e=e*2,o=o*2,r=r.map((i,p)=>p>=r.length-2?y.nearestLargerEven(r[p]):r[p]),r.length===1&&(r=[2,r[0]])),r.length!==2&&(r=y.squeezeShape(r).newShape);let n=y.sizeFromShape(r),s=null;r.length<=1&&n<=e?s=[1,n]:r.length===2&&r[0]<=e&&r[1]<=e?s=r:r.length===3&&r[0]*r[1]<=e&&r[2]<=e?s=[r[0]*r[1],r[2]]:r.length===3&&r[0]<=e&&r[1]*r[2]<=e?s=[r[0],r[1]*r[2]]:r.length===4&&r[0]*r[1]*r[2]<=e&&r[3]<=e?s=[r[0]*r[1]*r[2],r[3]]:r.length===4&&r[0]<=e&&r[1]*r[2]*r[3]<=e&&(s=[r[0],r[1]*r[2]*r[3]]);let a=s!=null&&Math.max(...s)>o&&Math.min(...s)<=(t?2:1)&&Math.min(...s)>0;if(s==null||a)if(t){let i=yi(r),p=2,u=2;r.length&&([p,u]=bi(r)),n=i*(p/2)*(u/2),s=y.sizeToSquarishShape(n).map(c=>c*2)}else s=y.sizeToSquarishShape(n);return s}function Gf(r){return r%2===0}function Cu(r,t){if(r=r.slice(-2),t=t.slice(-2),y.arraysEqual(r,t)||!r.length||!t.length||r[0]===0||r[1]===0||t[0]===0||t[1]===0)return!0;if(r.length!==t.length){let e=r[r.length-1],o=t[t.length-1];if(e===o||Gf(e)&&Gf(o)&&(r[0]===1||t[0]===1))return!0}return r[1]===t[1]&&Gf(r[0])&&Gf(t[0])}var Hf,Kf;function VI(r){if(Hf==null){let t=Kr(r);Hf=t.getParameter(t.MAX_TEXTURE_SIZE)}return Hf}function oZ(){Hf=null}function nZ(){Kf=null}function WI(r){if(Kf==null){let t=Kr(r);Kf=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS)}return Math.min(16,Kf)}function UI(r){if(r===0)return 0;let t,e=Kr(r);return qr(e,\"EXT_disjoint_timer_query_webgl2\")&&r===2?t=2:qr(e,\"EXT_disjoint_timer_query\")?t=1:t=0,t}function qr(r,t){return r.getExtension(t)!=null}function Yf(r){try{if(Kr(r)!=null)return!0}catch(t){return console.log(\"Error when getting WebGL context: \",t),!1}return!1}function GI(r){if(r===0)return!1;let t=Kr(r);if(r===1){if(!qr(t,\"OES_texture_float\"))return!1}else if(!qr(t,\"EXT_color_buffer_float\"))return!1;return NI(t)}function HI(r){if(r===0)return!1;let t=Kr(r);if(r===1){if(!qr(t,\"OES_texture_float\")||!qr(t,\"WEBGL_color_buffer_float\"))return!1}else{if(qr(t,\"EXT_color_buffer_float\"))return NI(t);let o=\"EXT_color_buffer_half_float\";if(qr(t,o)){let n=t.getExtension(o);return sZ(t,n)}return!1}return NI(t)}function NI(r){let t=Xl(r),e=r.createTexture();r.bindTexture(r.TEXTURE_2D,e);let o=1,n=1;r.texImage2D(r.TEXTURE_2D,0,t.internalFormatFloat,o,n,0,t.textureFormatFloat,t.textureTypeFloat,null);let s=r.createFramebuffer();r.bindFramebuffer(r.FRAMEBUFFER,s),r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,e,0);let a=r.checkFramebufferStatus(r.FRAMEBUFFER)===r.FRAMEBUFFER_COMPLETE;return r.bindTexture(r.TEXTURE_2D,null),r.bindFramebuffer(r.FRAMEBUFFER,null),r.deleteTexture(e),r.deleteFramebuffer(s),a}function sZ(r,t){let e=Xl(r,t),o=r.createTexture();r.bindTexture(r.TEXTURE_2D,o);let n=1,s=1;r.texImage2D(r.TEXTURE_2D,0,e.internalFormatHalfFloat,n,s,0,e.textureFormatFloat,e.textureTypeHalfFloat,null);let a=r.createFramebuffer();r.bindFramebuffer(r.FRAMEBUFFER,a),r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,o,0);let i=r.checkFramebufferStatus(r.FRAMEBUFFER)===r.FRAMEBUFFER_COMPLETE;return r.bindTexture(r.TEXTURE_2D,null),r.bindFramebuffer(r.FRAMEBUFFER,null),r.deleteTexture(o),r.deleteFramebuffer(a),i}function KI(r){return r!==2?!1:Kr(r).fenceSync!=null}function Vs(r,t){Array.isArray(r)||(r=[r]),r.forEach(e=>{e!=null&&y.assert(e.dtype!==\"complex64\",()=>`${t} does not support complex64 tensors in the WebGL backend.`)})}var Se=A();Se.registerFlag(\"HAS_WEBGL\",()=>Se.getNumber(\"WEBGL_VERSION\")>0);Se.registerFlag(\"WEBGL_VERSION\",()=>Yf(2)?2:Yf(1)?1:0);Se.registerFlag(\"WEBGL_CHECK_NUMERICAL_PROBLEMS\",()=>!1);Se.registerFlag(\"WEBGL_BUFFER_SUPPORTED\",()=>Se.get(\"WEBGL_VERSION\")===2);Se.registerFlag(\"WEBGL_CPU_FORWARD\",()=>!0);Se.registerFlag(\"WEBGL_FORCE_F16_TEXTURES\",()=>!1);Se.registerFlag(\"WEBGL_PACK\",()=>Se.getBool(\"HAS_WEBGL\"));Se.registerFlag(\"WEBGL_PACK_NORMALIZATION\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_CLIP\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_DEPTHWISECONV\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_BINARY_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_UNARY_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_ARRAY_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_IMAGE_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_REDUCE\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_LAZILY_UNPACK\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_CONV_IM2COL\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_CONV2DTRANSPOSE\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_MAX_TEXTURE_SIZE\",()=>VI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_MAX_TEXTURES_IN_SHADER\",()=>WI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\",()=>{let r=Se.getNumber(\"WEBGL_VERSION\");return r===0?0:UI(r)});Se.registerFlag(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\",()=>Se.getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")>0&&!ou.isMobile());Se.registerFlag(\"WEBGL_RENDER_FLOAT32_CAPABLE\",()=>GI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_RENDER_FLOAT32_ENABLED\",()=>Se.getBool(\"WEBGL_FORCE_F16_TEXTURES\")?!1:Se.getBool(\"WEBGL_RENDER_FLOAT32_CAPABLE\"));Se.registerFlag(\"WEBGL_DOWNLOAD_FLOAT_ENABLED\",()=>HI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_FENCE_API_ENABLED\",()=>KI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_SIZE_UPLOAD_UNIFORM\",()=>Se.getBool(\"WEBGL_RENDER_FLOAT32_ENABLED\")?4:0);Se.registerFlag(\"WEBGL_DELETE_TEXTURE_THRESHOLD\",()=>-1,r=>{if(typeof r!=\"number\")throw new Error(`WEBGL_DELETE_TEXTURE_THRESHOLD must be a number but got ${r}.`);if(r<0&&r!==-1)throw new Error(`WEBGL_DELETE_TEXTURE_THRESHOLD must be -1 (indicating never delete) or at least 0, but got ${r}.`)});Se.registerFlag(\"WEBGL_FLUSH_THRESHOLD\",()=>ou.isMobile()?1:-1,r=>{if(typeof r!=\"number\")throw new Error(`WEBGL_FLUSH_THRESHOLD must be a number but got ${r}.`);if(r<0&&r!==-1)throw new Error(`WEBGL_FLUSH_THRESHOLD must be -1 (indicating never manual flush) or at least 0, but got ${r}.`)});Se.registerFlag(\"CPU_HANDOFF_SIZE_THRESHOLD\",()=>128);Se.registerFlag(\"WEBGL_USE_SHAPES_UNIFORMS\",()=>!1);Se.registerFlag(\"TOPK_LAST_DIM_CPU_HANDOFF_SIZE_THRESHOLD\",()=>1e5);Se.registerFlag(\"TOPK_K_CPU_HANDOFF_THRESHOLD\",()=>128);Se.registerFlag(\"WEBGL_EXP_CONV\",()=>!1);Se.registerFlag(\"SOFTWARE_WEBGL_ENABLED\",()=>Se.getBool(\"IS_TEST\"));Se.registerFlag(\"WEBGL_MAX_SIZE_FOR_NARROW_TEXTURE\",()=>1/0);Se.registerFlag(\"WEBGL_AUTO_SQUARIFY_NARROW_TEXTURE_SHAPE\",()=>!1);Se.registerFlag(\"WEBGL2_ISNAN_CUSTOM\",()=>!1);Se.registerFlag(\"ENGINE_COMPILE_ONLY\",()=>!1);function vt(){let r,t,e,o,n,s,a,i,p,u;return A().getNumber(\"WEBGL_VERSION\")===2?(r=\"#version 300 es\",t=\"in\",e=\"out\",o=\"in\",n=\"texture\",s=\"outputColor\",a=\"out vec4 outputColor;\",i=A().getBool(\"WEBGL2_ISNAN_CUSTOM\")?`\n bool isnan_custom(float val) {\n uint floatToUint = floatBitsToUint(val);\n return (floatToUint & 0x7fffffffu) > 0x7f800000u;\n }\n\n bvec4 isnan_custom(vec4 val) {\n return bvec4(isnan_custom(val.x),\n isnan_custom(val.y), isnan_custom(val.z), isnan_custom(val.w));\n }\n\n #define isnan(value) isnan_custom(value)\n `:\"\",p=\"\",u=`\n #define round(value) newRound(value)\n int newRound(float value) {\n return int(floor(value + 0.5));\n }\n\n ivec4 newRound(vec4 value) {\n return ivec4(floor(value + vec4(0.5)));\n }\n `):(r=\"\",t=\"attribute\",e=\"varying\",o=\"varying\",n=\"texture2D\",s=\"gl_FragColor\",a=\"\",i=`\n #define isnan(value) isnan_custom(value)\n bool isnan_custom(float val) {\n return (val > 0. || val < 1. || val == 0.) ? false : true;\n }\n bvec4 isnan_custom(vec4 val) {\n return bvec4(isnan(val.x), isnan(val.y), isnan(val.z), isnan(val.w));\n }\n `,p=`\n uniform float INFINITY;\n\n bool isinf(float val) {\n return abs(val) == INFINITY;\n }\n bvec4 isinf(vec4 val) {\n return equal(abs(val), vec4(INFINITY));\n }\n `,u=`\n int round(float value) {\n return int(floor(value + 0.5));\n }\n\n ivec4 round(vec4 value) {\n return ivec4(floor(value + vec4(0.5)));\n }\n `),{version:r,attribute:t,varyingVs:e,varyingFs:o,texture2D:n,output:s,defineOutput:a,defineSpecialNaN:i,defineSpecialInf:p,defineRound:u}}function Ws(r,t,e=\"index\"){let o=y.computeStrides(t);return o.map((n,s)=>{let a=`int ${r[s]} = ${e} / ${n}`,i=s===o.length-1?`int ${r[s+1]} = ${e} - ${r[s]} * ${n}`:`index -= ${r[s]} * ${n}`;return`${a}; ${i};`}).join(\"\")}function Ip(r,t,e=\"index\"){let o=y.computeStrides(t);return o.map((n,s)=>{let a=`int ${r[s]} = ${e} / outShapeStrides[${s}]`,i=s===o.length-1?`int ${r[s+1]} = ${e} - ${r[s]} * outShapeStrides[${s}]`:`index -= ${r[s]} * outShapeStrides[${s}]`;return`${a}; ${i};`}).join(\"\")}function aZ(r,t){let e=r.length,o=r.map(s=>`${t}[${s}]`),n=new Array(e-1);n[e-2]=o[e-1];for(let s=e-3;s>=0;--s)n[s]=`(${n[s+1]} * ${o[s+1]})`;return n}function SR(r,t,e=\"index\"){let o=r.map((s,a)=>a),n=aZ(o,t);return n.map((s,a)=>{let i=`int ${r[a]} = ${e} / ${n[a]}`,p=a===n.length-1?`int ${r[a+1]} = ${e} - ${r[a]} * ${n[a]}`:`index -= ${r[a]} * ${n[a]}`;return`${i}; ${p};`}).join(\"\")}function Fc(r){let t=y.computeStrides(r).map(e=>e.toString());return`\n int getFlatIndex(ivec3 coords) {\n return coords.x * ${t[0]} + coords.y * ${t[1]} + coords.z;\n }\n`}function Pc(){return`\n int getFlatIndex(ivec3 coords) {\n return coords.x * outShapeStrides[0] + coords.y * outShapeStrides[1] + coords.z;\n }\n`}var Qf=`\n const float FLOAT_MAX = 1.70141184e38;\n const float FLOAT_MIN = 1.17549435e-38;\n\n lowp vec4 encode_float(highp float v) {\n if (isnan(v)) {\n return vec4(255, 255, 255, 255);\n }\n\n highp float av = abs(v);\n\n if(av < FLOAT_MIN) {\n return vec4(0.0, 0.0, 0.0, 0.0);\n } else if(v > FLOAT_MAX) {\n return vec4(0.0, 0.0, 128.0, 127.0) / 255.0;\n } else if(v < -FLOAT_MAX) {\n return vec4(0.0, 0.0, 128.0, 255.0) / 255.0;\n }\n\n highp vec4 c = vec4(0,0,0,0);\n\n highp float e = floor(log2(av));\n highp float m = exp2(fract(log2(av))) - 1.0;\n\n c[2] = floor(128.0 * m);\n m -= c[2] / 128.0;\n c[1] = floor(32768.0 * m);\n m -= c[1] / 32768.0;\n c[0] = floor(8388608.0 * m);\n\n highp float ebias = e + 127.0;\n c[3] = floor(ebias / 2.0);\n ebias -= c[3] * 2.0;\n c[2] += floor(ebias) * 128.0;\n\n c[3] += 128.0 * step(0.0, -v);\n\n return c / 255.0;\n }\n`;var{getBroadcastDims:IR}=w;function vR(r,t,e){let o=[];if(r.forEach(d=>{let f=y.sizeFromShape(d.shapeInfo.logicalShape);if(d.shapeInfo.isUniform?o.push(`uniform float ${d.name}${f>1?`[${f}]`:\"\"};`):(o.push(`uniform sampler2D ${d.name};`),o.push(`uniform int offset${d.name};`)),e.enableShapeUniforms){let{uniformShape:h}=Zf(e.packedInputs,d.shapeInfo.logicalShape,d.shapeInfo.texShape);switch(h.length){case 1:o.push(`uniform int ${d.name}Shape;`);break;case 2:o.push(`uniform ivec2 ${d.name}Shape;`);break;case 3:o.push(`uniform ivec3 ${d.name}Shape;`);break;case 4:o.push(`uniform ivec4 ${d.name}Shape;`);break;default:break}o.push(`uniform ivec2 ${d.name}TexShape;`)}}),e.enableShapeUniforms){switch(t.logicalShape.length){case 1:o.push(\"uniform int outShape;\");break;case 2:o.push(\"uniform ivec2 outShape;\"),o.push(\"uniform int outShapeStrides;\");break;case 3:o.push(\"uniform ivec3 outShape;\"),o.push(\"uniform ivec2 outShapeStrides;\");break;case 4:o.push(\"uniform ivec4 outShape;\"),o.push(\"uniform ivec3 outShapeStrides;\");break;default:break}o.push(\"uniform ivec2 outTexShape;\")}e.customUniforms&&e.customUniforms.forEach(d=>{o.push(`uniform ${d.type} ${d.name}${d.arrayIndex?`[${d.arrayIndex}]`:\"\"};`)});let n=o.join(`\n`),s=r.map(d=>iZ(d,t,e.packedInputs,e.enableShapeUniforms)).join(`\n`),a=t.texShape,i=vt(),p=cZ(i),u,c,l=dZ(i);return t.isPacked?(u=uZ(t.logicalShape,a,e.enableShapeUniforms),c=mZ(i)):(u=pZ(t.logicalShape,a,e.enableShapeUniforms),c=lZ(i)),e.packedInputs&&(l+=xZ),[l,p,c,n,u,s,e.userCode].join(`\n`)}function Mc(r,t=!1){let e=r.shapeInfo.logicalShape;switch(e.length){case 0:return $Z(r,t);case 1:return RZ(r,t);case 2:return AZ(r,t);case 3:return PZ(r,t);case 4:return MZ(r,t);case 5:return LZ(r);case 6:return BZ(r);default:throw new Error(`${e.length}-D input sampling is not yet supported`)}}function kR(r,t){switch(r.shapeInfo.logicalShape.length){case 0:return _Z(r);case 1:return EZ(r,t);case 2:return DZ(r,t);case 3:return FZ(r,t);default:return OZ(r,t)}}function iZ(r,t,e=!1,o){let n=\"\";e?n+=kR(r,o):n+=Mc(r,o);let s=r.shapeInfo.logicalShape,a=t.logicalShape;return s.length<=a.length&&(e?n+=zZ(r,t):n+=VZ(r,t)),n}function uZ(r,t,e){switch(r.length){case 0:return NR();case 1:return yZ(r,t,e);case 2:return NZ(r,t,e);case 3:return CZ(r,t,e);default:return SZ(r,t,e)}}function pZ(r,t,e){switch(r.length){case 0:return NR();case 1:return bZ(r,t,e);case 2:return TZ(r,t,e);case 3:return wZ(r,t,e);case 4:return IZ(r,t,e);case 5:return vZ(r,t);case 6:return kZ(r,t);default:throw new Error(`${r.length}-D output sampling is not yet supported`)}}function cZ(r){return`\n float sampleTexture(sampler2D textureSampler, vec2 uv) {\n return ${r.texture2D}(textureSampler, uv).r;\n }\n `}function lZ(r){return`\n void setOutput(float val) {\n ${r.output} = vec4(val, 0, 0, 0);\n }\n `}function mZ(r){return`\n void setOutput(vec4 val) {\n ${r.output} = val;\n }\n `}function dZ(r){return`${r.version}\n precision highp float;\n precision highp int;\n precision highp sampler2D;\n ${r.varyingFs} vec2 resultUV;\n ${r.defineOutput}\n const vec2 halfCR = vec2(0.5, 0.5);\n\n struct ivec5\n {\n int x;\n int y;\n int z;\n int w;\n int u;\n };\n\n struct ivec6\n {\n int x;\n int y;\n int z;\n int w;\n int u;\n int v;\n };\n\n uniform float NAN;\n ${r.defineSpecialNaN}\n ${r.defineSpecialInf}\n ${r.defineRound}\n\n int imod(int x, int y) {\n return x - y * (x / y);\n }\n\n int idiv(int a, int b, float sign) {\n int res = a / b;\n int mod = imod(a, b);\n if (sign < 0. && mod != 0) {\n res -= 1;\n }\n return res;\n }\n\n //Based on the work of Dave Hoskins\n //https://www.shadertoy.com/view/4djSRW\n #define HASHSCALE1 443.8975\n float random(float seed){\n vec2 p = resultUV * seed;\n vec3 p3 = fract(vec3(p.xyx) * HASHSCALE1);\n p3 += dot(p3, p3.yzx + 19.19);\n return fract((p3.x + p3.y) * p3.z);\n }\n\n ${fZ}\n ${hZ}\n ${gZ}\n `}var fZ=`\nvec2 uvFromFlat(int texNumR, int texNumC, int index) {\n int texR = index / texNumC;\n int texC = index - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\nvec2 packedUVfrom1D(int texNumR, int texNumC, int index) {\n int texelIndex = index / 2;\n int texR = texelIndex / texNumC;\n int texC = texelIndex - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n`,hZ=`\nvec2 packedUVfrom2D(int texelsInLogicalRow, int texNumR,\n int texNumC, int row, int col) {\n int texelIndex = (row / 2) * texelsInLogicalRow + (col / 2);\n int texR = texelIndex / texNumC;\n int texC = texelIndex - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n`,gZ=`\nvec2 packedUVfrom3D(int texNumR, int texNumC,\n int texelsInBatch, int texelsInLogicalRow, int b,\n int row, int col) {\n int index = b * texelsInBatch + (row / 2) * texelsInLogicalRow + (col / 2);\n int texR = index / texNumC;\n int texC = index - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n`,xZ=`\n float getChannel(vec4 frag, vec2 innerDims) {\n vec2 modCoord = mod(innerDims, 2.);\n return modCoord.x == 0. ?\n (modCoord.y == 0. ? frag.r : frag.g) :\n (modCoord.y == 0. ? frag.b : frag.a);\n }\n float getChannel(vec4 frag, int dim) {\n float modCoord = mod(float(dim), 2.);\n return modCoord == 0. ? frag.r : frag.g;\n }\n`;function NR(){return`\n int getOutputCoords() {\n return 0;\n }\n `}function yZ(r,t,e){let o=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)];return o[0]===1?e?`\n int getOutputCoords() {\n return 2 * int(resultUV.x * ceil(float(outTexShape[1]) / 2.0));\n }\n `:`\n int getOutputCoords() {\n return 2 * int(resultUV.x * ${o[1]}.0);\n }\n `:o[1]===1?e?`\n int getOutputCoords() {\n return 2 * int(resultUV.y * ceil(float(outTexShape[0]) / 2.0));\n }\n `:`\n int getOutputCoords() {\n return 2 * int(resultUV.y * ${o[0]}.0);\n }\n `:e?`\n int getOutputCoords() {\n ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(packedTexShape[0], packedTexShape[1]));\n return 2 * (resTexRC.x * packedTexShape[1] + resTexRC.y);\n }\n `:`\n int getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${o[0]}, ${o[1]}));\n return 2 * (resTexRC.x * ${o[1]} + resTexRC.y);\n }\n `}function bZ(r,t,e){return t[0]===1?e?`\n int getOutputCoords() {\n return int(resultUV.x * float(outTexShape[1]));\n }\n `:`\n int getOutputCoords() {\n return int(resultUV.x * ${t[1]}.0);\n }\n `:t[1]===1?e?`\n int getOutputCoords() {\n return int(resultUV.y * float(outTexShape[0]));\n }\n `:`\n int getOutputCoords() {\n return int(resultUV.y * ${t[0]}.0);\n }\n `:e?`\n int getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(outTexShape[0], outTexShape[1]));\n return resTexRC.x * outTexShape[1] + resTexRC.y;\n }\n `:`\n int getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${t[0]}, ${t[1]}));\n return resTexRC.x * ${t[1]} + resTexRC.y;\n }\n `}function CZ(r,t,e){if(e)return`\n ivec3 getOutputCoords() {\n ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n int texelsInLogicalRow = int(ceil(float(outShape[2]) / 2.0));\n int texelsInBatch = texelsInLogicalRow * int(ceil(float(outShape[1]) / 2.0));\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(packedTexShape[0], packedTexShape[1]));\n int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n\n int b = index / texelsInBatch;\n index -= b * texelsInBatch;\n\n int r = 2 * (index / texelsInLogicalRow);\n int c = imod(index, texelsInLogicalRow) * 2;\n\n return ivec3(b, r, c);\n }\n `;let o=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)],n=Math.ceil(r[2]/2),s=n*Math.ceil(r[1]/2);return`\n ivec3 getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${o[0]}, ${o[1]}));\n int index = resTexRC.x * ${o[1]} + resTexRC.y;\n\n int b = index / ${s};\n index -= b * ${s};\n\n int r = 2 * (index / ${n});\n int c = imod(index, ${n}) * 2;\n\n return ivec3(b, r, c);\n }\n `}function wZ(r,t,e){if(e)return`\n ivec3 getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(outTexShape[0], outTexShape[1]));\n int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n ${Ip([\"r\",\"c\",\"d\"],r)}\n return ivec3(r, c, d);\n }\n`;let o=Ws([\"r\",\"c\",\"d\"],r);return`\n ivec3 getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${t[0]}, ${t[1]}));\n int index = resTexRC.x * ${t[1]} + resTexRC.y;\n ${o}\n return ivec3(r, c, d);\n }\n `}function SZ(r,t,e){if(e)return`\n ivec4 getOutputCoords() {\n ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(packedTexShape[0], packedTexShape[1]));\n int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n\n int texelsInLogicalRow = int(ceil(float(outShape[3]) / 2.0));\n int texelsInBatch = texelsInLogicalRow * int(ceil(float(outShape[2]) / 2.0));\n int texelsInBatchN = texelsInBatch * outShape[1];\n\n int b2 = index / texelsInBatchN;\n index -= b2 * texelsInBatchN;\n\n int b = index / texelsInBatch;\n index -= b * texelsInBatch;\n\n int r = 2 * (index / texelsInLogicalRow);\n int c = imod(index, texelsInLogicalRow) * 2;\n\n return ivec4(b2, b, r, c);\n }\n `;let o=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)],n=Math.ceil(r[r.length-1]/2),s=n*Math.ceil(r[r.length-2]/2),a=s,i=\"\",p=\"b, r, c\";for(let u=2;u=1?c=\"coords = 0;\":c=i.map(b=>`coords.${l[b+u]} = 0;`).join(`\n`);let m=\"\";a<2&&s>0?m=\"coords\":m=r.shapeInfo.logicalShape.map((b,C)=>`coords.${l[C+u]}`).join(\", \");let d=\"return outputValue;\",h=y.sizeFromShape(r.shapeInfo.logicalShape)===1,x=y.sizeFromShape(t.logicalShape)===1;if(s===1&&!h&&!x)d=`\n return vec4(outputValue.xy, outputValue.xy);\n `;else if(h&&!x)a===1?d=`\n return vec4(outputValue.x, outputValue.x, 0., 0.);\n `:d=`\n return vec4(outputValue.x);\n `;else if(i.length){let b=s-2,C=s-1;i.indexOf(b)>-1&&i.indexOf(C)>-1?d=\"return vec4(outputValue.x);\":i.indexOf(b)>-1?d=\"return vec4(outputValue.x, outputValue.y, outputValue.x, outputValue.y);\":i.indexOf(C)>-1&&(d=\"return vec4(outputValue.xx, outputValue.zz);\")}return`\n vec4 ${n}() {\n ${p} coords = getOutputCoords();\n ${c}\n vec4 outputValue = get${o}(${m});\n ${d}\n }\n `}function VZ(r,t){let e=r.name,o=e.charAt(0).toUpperCase()+e.slice(1),n=\"get\"+o+\"AtOutCoords\",s=t.texShape,a=r.shapeInfo.texShape,i=r.shapeInfo.logicalShape.length,p=t.logicalShape.length;if(!r.shapeInfo.isUniform&&i===p&&r.shapeInfo.flatOffset==null&&y.arraysEqual(a,s))return`\n float ${n}() {\n return sampleTexture(${e}, resultUV);\n }\n `;let u=Re(p),c=IR(r.shapeInfo.logicalShape,t.logicalShape),l=p-i,m,d=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"];i===0?m=\"\":p<2&&c.length>=1?m=\"coords = 0;\":m=c.map(h=>`coords.${d[h+l]} = 0;`).join(`\n`);let f=\"\";return p<2&&i>0?f=\"coords\":f=r.shapeInfo.logicalShape.map((h,g)=>`coords.${d[g+l]}`).join(\", \"),`\n float ${n}() {\n ${u} coords = getOutputCoords();\n ${m}\n return get${o}(${f});\n }\n `}function Re(r){if(r<=1)return\"int\";if(r===2)return\"ivec2\";if(r===3)return\"ivec3\";if(r===4)return\"ivec4\";if(r===5)return\"ivec5\";if(r===6)return\"ivec6\";throw Error(`GPU for rank ${r} is not yet supported`)}function Zf(r,t,e){let{newShape:o,keptDims:n}=y.squeezeShape(t),s=t.length,a=r&&s===3&&t[0]===1,i=a?t.slice(1):o,p=!r&&s>1&&!y.arraysEqual(t,e)&&o.lengthr[e]).join(\", \")}function _R(r,t,e,o){let n=e.map((c,l)=>{let m={logicalShape:c.shape,texShape:c.isUniform?null:c.texData.texShape,isUniform:c.isUniform,isPacked:c.isUniform?!1:c.texData.isPacked,flatOffset:null};return c.texData!=null&&c.texData.slice!=null&&c.texData.slice.flatOffset>0&&(m.flatOffset=c.texData.slice.flatOffset),{name:t.variableNames[l],shapeInfo:m}}),s=n.map(c=>c.shapeInfo),a={logicalShape:o.shape,texShape:o.texData.texShape,isUniform:!1,isPacked:o.texData.isPacked,flatOffset:null},i=vR(n,a,t),p=$I(r.gl,i),u=r.createProgram(p);return A().get(\"ENGINE_COMPILE_ONLY\")?{program:t,fragmentShader:p,source:i,webGLProgram:u,inShapeInfos:s,outShapeInfo:a,variablesLocations:null,customUniformLocations:null,infLoc:null,nanLoc:null,outShapeLocation:null,outShapeStridesLocation:null,outTexShapeLocation:null}:(r.buildVao(u),Object.assign({program:t,fragmentShader:p,source:i,webGLProgram:u,inShapeInfos:s,outShapeInfo:a},qI(r,t,u)))}function qI(r,t,e){let o=[],n=[],s,a,i,p=null,u=null;u=r.getUniformLocation(e,\"NAN\",!1),A().getNumber(\"WEBGL_VERSION\")===1&&(p=r.getUniformLocation(e,\"INFINITY\",!1));let c=!1;for(let l of t.variableNames){let m={name:l,uniform:r.getUniformLocation(e,l,c),offset:r.getUniformLocation(e,`offset${l}`,c)};t.enableShapeUniforms&&(m.shape=r.getUniformLocation(e,`${l}Shape`,c),m.texShape=r.getUniformLocation(e,`${l}TexShape`,c)),o.push(m)}if(t.enableShapeUniforms&&(s=r.getUniformLocation(e,\"outShape\",c),i=r.getUniformLocation(e,\"outShapeStrides\",c),a=r.getUniformLocation(e,\"outTexShape\",c)),t.customUniforms)for(let l of t.customUniforms)n.push(r.getUniformLocation(e,l.name,c));return{variablesLocations:o,customUniformLocations:n,infLoc:p,nanLoc:u,outShapeLocation:s,outShapeStridesLocation:i,outTexShapeLocation:a}}function TR(r,t){if(r.length!==t.length)throw Error(`Binary was compiled with ${r.length} inputs, but was executed with ${t.length} inputs`);r.forEach((e,o)=>{let n=e.logicalShape,s=t[o],a=s.shape;if(!y.arraysEqual(n,a))throw Error(`Binary was compiled with different shapes than the current args. Shapes ${n} and ${a} must match`);if(e.isUniform&&s.isUniform)return;let i=e.texShape,p=s.isUniform?null:s.texData.texShape;if(!y.arraysEqual(i,p))throw Error(`Binary was compiled with different texture shapes than the current args. Shape ${i} and ${p} must match`)})}function $R(r,t,e,o,n){t.program.enableShapeUniforms||(TR(t.inShapeInfos,e),TR([t.outShapeInfo],[o]));let s=o.texData.texture,a=o.texData.texShape;o.texData.isPacked?r.setOutputPackedMatrixTexture(s.texture,a[0],a[1]):r.setOutputMatrixTexture(s.texture,a[0],a[1]),r.setProgram(t.webGLProgram),r.bindVertexArray(t.webGLProgram.vao),A().getNumber(\"WEBGL_VERSION\")===1&&t.infLoc!==null&&r.gl.uniform1f(t.infLoc,1/0),t.nanLoc!==null&&r.gl.uniform1f(t.nanLoc,NaN);for(let p=0;p{let i=a.texData!=null&&a.texData.slice!=null&&a.texData.slice.flatOffset>0;if(r.enableShapeUniforms&&!a.isUniform){let p=a.texData.texShape,{useSqueezeShape:u,uniformShape:c,keptDims:l}=Zf(r.packedInputs,a.shape,p),m=\"\",d=\"\",f=\"\";if(c.length===1&&r.packedInputs){let k=[Math.ceil(p[0]/2),Math.ceil(p[1]/2)];m=`${k[0]>1}_${k[1]>1}`}else if(c.length===2&&!r.packedInputs)d=`${c[0]>1}_${c[1]>1}`;else if(c.length>2&&!r.packedInputs){let k=y.computeStrides(c);f=`${k[0]===p[1]}_${k[k.length-1]===p[1]}`}let h=a.shape.length,g=c.length===2&&y.arraysEqual(a.shape,p),x=y.sizeFromShape(a.shape)===1,b=w.getBroadcastDims(a.shape,e.shape),C=!r.packedInputs&&h===e.shape.length&&y.arraysEqual(p,e.texData.texShape),S=r.packedInputs||c.length>2?\"\":`${p[0]>1}_${p[1]>1}`;o+=`${h}_${C}_${u?l:\"\"}_${c.length}_${x}_${b}_${g}_${m}_${d}_${f}_${S}_${i}`}else{let p=a.isUniform?\"uniform\":a.texData.texShape;o+=`${a.shape}_${p}_${i}`}});let n=r.userCode,s=r.constructor.name;return s+=\"_\"+o+\"_\"+n+`${A().getNumber(\"WEBGL_VERSION\")}`,s}function pt(r){return A().getBool(\"WEBGL_USE_SHAPES_UNIFORMS\")&&r<=4}var Jf=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!1,this.packedOutput=!0,this.outPackingScheme=bu.DENSE,this.customUniforms=[{name:\"texShape\",type:\"ivec2\"}];let e=vt();this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n ivec3 outCoordsFromFlatIndex(int index) {\n ${this.enableShapeUniforms?Ip([\"r\",\"c\",\"d\"],t):Ws([\"r\",\"c\",\"d\"],t)}\n return ivec3(r, c, d);\n }\n\n void main() {\n ivec2 resTexRC = ivec2(resultUV.yx * vec2(texShape[0], texShape[1]));\n int index = 4 * (resTexRC.x * texShape[1] + resTexRC.y);\n\n vec4 result = vec4(0.);\n\n for (int i=0; i<4; i++) {\n int flatIndex = index + i;\n ivec3 rc = outCoordsFromFlatIndex(flatIndex);\n result[i] = getA(rc.x, rc.y, rc.z);\n }\n\n ${e.output} = result;\n }\n `}};var eh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outPackingScheme=bu.DENSE,this.customUniforms=[{name:\"texShape\",type:\"ivec2\"}];let e=vt();this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n ivec3 outCoordsFromFlatIndex(int index) {\n ${this.enableShapeUniforms?Ip([\"r\",\"c\",\"d\"],t):Ws([\"r\",\"c\",\"d\"],t)}\n return ivec3(r, c, d);\n }\n\n void main() {\n ivec2 resTexRC = ivec2(resultUV.yx * vec2(texShape[0], texShape[1]));\n int index = 4 * (resTexRC.x * texShape[1] + resTexRC.y);\n\n vec4 result = vec4(0.);\n\n for (int i=0; i<4; i++) {\n int flatIndex = index + i;\n ivec3 rc = outCoordsFromFlatIndex(flatIndex);\n result[i] = getChannel(getA(rc.x, rc.y, rc.z), vec2(rc.y, rc.z));\n }\n\n ${e.output} = result;\n }\n `}};var th=class{constructor(t){this.variableNames=[\"A\"],this.outTexUsage=dr.DOWNLOAD;let e=vt();this.outputShape=t,this.userCode=`\n ${Qf}\n\n void main() {\n float x = getAAtOutCoords();\n ${e.output} = encode_float(x);\n }\n `}};var rh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!1,this.outTexUsage=dr.DOWNLOAD;let e=vt();this.outputShape=t,this.userCode=`\n ${Qf}\n\n void main() {\n ivec3 coords = getOutputCoords();\n float x = getChannel(getAAtOutCoords(), vec2(coords.y, coords.z));\n ${e.output} = encode_float(x);\n }\n `}};var GZ={R:0,G:1,B:2,A:3},Zl=class{constructor(t,e=!1,o=\"RGBA\"){this.variableNames=[\"A\"],this.customUniforms=[{name:\"texShape\",type:\"ivec2\"}];let n=vt();this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length);let s=\"result\";e&&(s=\"floor(result * 255. + 0.5)\");let a=\"\";for(let i=0;irv,createBufferFromOutputTexture:()=>sv,createFloat16MatrixTexture:()=>ZI,createFloat16PackedMatrixTexture:()=>tv,createFloat32MatrixTexture:()=>QI,createIndexBuffer:()=>YI,createPackedMatrixTexture:()=>ev,createUnsignedBytesMatrixTexture:()=>JI,createVertexBuffer:()=>XI,createVertexShader:()=>jI,downloadByteEncodedFloatMatrixFromOutputTexture:()=>iv,downloadFloat32MatrixFromBuffer:()=>av,downloadMatrixFromPackedOutputTexture:()=>pv,downloadPackedMatrixFromBuffer:()=>uv,getInternalFormatForFloat16MatrixTexture:()=>sh,getInternalFormatForFloat16PackedMatrixTexture:()=>uh,getInternalFormatForFloat32MatrixTexture:()=>nh,getInternalFormatForPackedMatrixTexture:()=>ih,getInternalFormatForUnsignedBytesMatrixTexture:()=>ah,uploadDenseMatrixToTexture:()=>ov,uploadPixelDataToTexture:()=>nv});function jI(r){let t=vt(),e=`${t.version}\n precision highp float;\n ${t.attribute} vec3 clipSpacePos;\n ${t.attribute} vec2 uv;\n ${t.varyingVs} vec2 resultUV;\n\n void main() {\n gl_Position = vec4(clipSpacePos, 1);\n resultUV = uv;\n }`;return _I(r,e)}function XI(r){let t=new Float32Array([-1,1,0,0,1,-1,-1,0,0,0,1,1,0,1,1,1,-1,0,1,0]);return DI(r,t)}function YI(r){let t=new Uint16Array([0,1,2,2,1,3]);return AI(r,t)}function Jl(r,t,e,o,n,s){PI(t,e);let a=FI(r),i=r.TEXTURE_2D;return ce(r,()=>r.bindTexture(i,a)),ce(r,()=>r.texParameteri(i,r.TEXTURE_WRAP_S,r.CLAMP_TO_EDGE)),ce(r,()=>r.texParameteri(i,r.TEXTURE_WRAP_T,r.CLAMP_TO_EDGE)),ce(r,()=>r.texParameteri(i,r.TEXTURE_MIN_FILTER,r.NEAREST)),ce(r,()=>r.texParameteri(i,r.TEXTURE_MAG_FILTER,r.NEAREST)),A().getNumber(\"WEBGL_VERSION\")===1?ce(r,()=>r.texImage2D(i,0,o,t,e,0,n,s,null)):ce(r,()=>r.texStorage2D(i,1,o,t,e)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null)),{texture:a,texShape:[e,t]}}function nh(r){return r.internalFormatFloat}function QI(r,t,e,o){let[n,s]=Sp(t,e);return Jl(r,n,s,nh(o),o.textureFormatFloat,r.FLOAT)}function sh(r){return r.internalFormatHalfFloat}function ZI(r,t,e,o){let[n,s]=Sp(t,e);return Jl(r,n,s,sh(o),o.textureFormatFloat,o.textureTypeHalfFloat)}function ah(r){return r.downloadTextureFormat}function JI(r,t,e,o){let[n,s]=Sp(t,e);return Jl(r,n,s,ah(o),r.RGBA,r.UNSIGNED_BYTE)}function ih(r){return r.internalFormatPackedFloat}function ev(r,t,e,o){let[n,s]=La(t,e);return Jl(r,n,s,ih(o),r.RGBA,r.FLOAT)}function uh(r){return r.internalFormatPackedHalfFloat}function tv(r,t,e,o){let[n,s]=La(t,e);return Jl(r,n,s,uh(o),r.RGBA,o.textureTypeHalfFloat)}function rv(r,t,e){return ce(r,()=>r.bindBuffer(r.ARRAY_BUFFER,e)),jf(r,t,\"clipSpacePos\",e,3,20,0)&&jf(r,t,\"uv\",e,2,20,12)}function ov(r,t,e,o,n,s){ce(r,()=>r.bindTexture(r.TEXTURE_2D,t));let a,i,p;n instanceof Uint8Array?(a=new Uint8Array(e*o*4),i=r.UNSIGNED_BYTE,p=r.RGBA):(a=new Float32Array(e*o*4),i=r.FLOAT,p=s.internalFormatPackedFloat),a.set(n),A().getNumber(\"WEBGL_VERSION\")===2?ce(r,()=>r.texSubImage2D(r.TEXTURE_2D,0,0,0,e,o,r.RGBA,i,a)):ce(r,()=>r.texImage2D(r.TEXTURE_2D,0,p,e,o,0,r.RGBA,i,a)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null))}function nv(r,t,e){ce(r,()=>r.bindTexture(r.TEXTURE_2D,t)),e.data instanceof Uint8Array?A().getNumber(\"WEBGL_VERSION\")===2?ce(r,()=>r.texSubImage2D(r.TEXTURE_2D,0,0,0,e.width,e.height,r.RGBA,r.UNSIGNED_BYTE,e.data)):ce(r,()=>r.texImage2D(r.TEXTURE_2D,0,r.RGBA,e.width,e.height,0,r.RGBA,r.UNSIGNED_BYTE,e.data)):A().getNumber(\"WEBGL_VERSION\")===2?ce(r,()=>r.texSubImage2D(r.TEXTURE_2D,0,0,0,r.RGBA,r.UNSIGNED_BYTE,e)):ce(r,()=>r.texImage2D(r.TEXTURE_2D,0,r.RGBA,r.RGBA,r.UNSIGNED_BYTE,e)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null))}function sv(r,t,e,o){let n=r.createBuffer();ce(r,()=>r.bindBuffer(r.PIXEL_PACK_BUFFER,n));let i=4*4*t*e;return ce(r,()=>r.bufferData(r.PIXEL_PACK_BUFFER,i,r.STREAM_READ)),ce(r,()=>r.readPixels(0,0,e,t,r.RGBA,r.FLOAT,0)),ce(r,()=>r.bindBuffer(r.PIXEL_PACK_BUFFER,null)),n}function av(r,t,e){let o=r,n=new Float32Array(e);return o.bindBuffer(o.PIXEL_PACK_BUFFER,t),o.getBufferSubData(o.PIXEL_PACK_BUFFER,0,n),o.bindBuffer(o.PIXEL_PACK_BUFFER,null),n}function iv(r,t,e,o){let[n,s]=Sp(t,e),a=4,i=new Uint8Array(gR(t*e,a));return ce(r,()=>r.readPixels(0,0,n,s,o.downloadTextureFormat,r.UNSIGNED_BYTE,i)),new Float32Array(i.buffer)}function uv(r,t,e,o,n,s,a,i){let p=r,u=new Float32Array(xR(s,a));return p.bindBuffer(p.PIXEL_PACK_BUFFER,t),p.getBufferSubData(p.PIXEL_PACK_BUFFER,0,u),p.bindBuffer(p.PIXEL_PACK_BUFFER,null),u}function pv(r,t,e){let o=new Float32Array(t*e*4);return ce(r,()=>r.readPixels(0,0,e,t,r.RGBA,r.FLOAT,o)),o}var kp=class{constructor(t){this.outputTexture=null,this.program=null,this.disposed=!1,this.itemsToPoll=[];let e=A().getNumber(\"WEBGL_VERSION\");if(t!=null?(this.gl=t,vI(e,t)):this.gl=Kr(e),t=this.gl,A().getNumber(\"WEBGL_VERSION\")===2){let s=t;this.createVertexArray=()=>ce(s,()=>s.createVertexArray()),this.bindVertexArray=a=>ce(s,()=>s.bindVertexArray(a)),this.deleteVertexArray=a=>ce(s,()=>s.deleteVertexArray(a)),this.getVertexArray=()=>ce(s,()=>s.getParameter(s.VERTEX_ARRAY_BINDING))}else if(t!=null){let s=t.getExtension(\"OES_vertex_array_object\");if(s==null)throw new Error(\"All WebGL1 implementations are expected to offer OES_vertex_array_object.\");this.createVertexArray=()=>ce(t,()=>s.createVertexArrayOES()),this.bindVertexArray=a=>ce(t,()=>s.bindVertexArrayOES(a)),this.deleteVertexArray=a=>ce(t,()=>s.deleteVertexArrayOES(a)),this.getVertexArray=()=>ce(t,()=>t.getParameter(s.VERTEX_ARRAY_BINDING_OES))}let o=\"WEBGL_color_buffer_float\",n=\"EXT_color_buffer_half_float\";if(this.parallelCompilationExtension=this.gl.getExtension(\"KHR_parallel_shader_compile\"),A().getNumber(\"WEBGL_VERSION\")===1){let s=\"OES_texture_float\",a=\"OES_texture_half_float\";if(this.textureFloatExtension=Ec(this.gl,s),qr(this.gl,a))this.textureHalfFloatExtension=Ec(this.gl,a);else if(A().get(\"WEBGL_FORCE_F16_TEXTURES\"))throw new Error(\"GL context does not support half float textures, yet the environment flag WEBGL_FORCE_F16_TEXTURES is set to true.\");if(this.colorBufferFloatExtension=this.gl.getExtension(o),qr(this.gl,n))this.colorBufferHalfFloatExtension=Ec(this.gl,n);else if(A().get(\"WEBGL_FORCE_F16_TEXTURES\"))throw new Error(\"GL context does not support color renderable half floats, yet the environment flag WEBGL_FORCE_F16_TEXTURES is set to true.\")}else if(o=\"EXT_color_buffer_float\",qr(this.gl,o))this.colorBufferFloatExtension=this.gl.getExtension(o);else if(qr(this.gl,n))this.colorBufferHalfFloatExtension=this.gl.getExtension(n);else throw new Error(\"GL context does not support color renderable floats\");this.vertexBuffer=XI(this.gl),this.indexBuffer=YI(this.gl),this.framebuffer=OI(this.gl),this.textureConfig=Xl(this.gl,this.textureHalfFloatExtension)}get debug(){return A().getBool(\"DEBUG\")}dispose(){if(this.disposed)return;this.program!=null&&console.warn(\"Disposing a GPGPUContext that still has a bound WebGLProgram. This is probably a resource leak, delete the program with GPGPUContext.deleteProgram before disposing.\"),this.outputTexture!=null&&console.warn(\"Disposing a GPGPUContext that still has a bound output matrix texture. This is probably a resource leak, delete the output matrix texture with GPGPUContext.deleteMatrixTexture before disposing.\");let t=this.gl;ce(t,()=>t.finish()),ce(t,()=>t.bindFramebuffer(t.FRAMEBUFFER,null)),ce(t,()=>t.deleteFramebuffer(this.framebuffer)),ce(t,()=>t.bindBuffer(t.ARRAY_BUFFER,null)),ce(t,()=>t.bindBuffer(t.ELEMENT_ARRAY_BUFFER,null)),ce(t,()=>t.deleteBuffer(this.indexBuffer)),this.disposed=!0}createFloat32MatrixTexture(t,e){return this.throwIfDisposed(),QI(this.gl,t,e,this.textureConfig)}createFloat16MatrixTexture(t,e){return this.throwIfDisposed(),ZI(this.gl,t,e,this.textureConfig)}createUnsignedBytesMatrixTexture(t,e){return this.throwIfDisposed(),JI(this.gl,t,e,this.textureConfig)}uploadPixelDataToTexture(t,e){this.throwIfDisposed(),nv(this.gl,t,e)}uploadDenseMatrixToTexture(t,e,o,n){this.throwIfDisposed(),ov(this.gl,t,e,o,n,this.textureConfig)}createFloat16PackedMatrixTexture(t,e){return this.throwIfDisposed(),tv(this.gl,t,e,this.textureConfig)}createPackedMatrixTexture(t,e){return this.throwIfDisposed(),ev(this.gl,t,e,this.textureConfig)}deleteMatrixTexture(t){this.throwIfDisposed(),this.outputTexture===t&&(Xf(this.gl,this.framebuffer),this.outputTexture=null),ce(this.gl,()=>this.gl.deleteTexture(t))}downloadByteEncodedFloatMatrixFromOutputTexture(t,e,o){return this.downloadMatrixDriver(t,()=>iv(this.gl,e,o,this.textureConfig))}downloadPackedMatrixFromBuffer(t,e,o,n,s,a){return uv(this.gl,t,e,o,n,s,a,this.textureConfig)}downloadFloat32MatrixFromBuffer(t,e){return av(this.gl,t,e)}createBufferFromTexture(t,e,o){this.bindTextureToFrameBuffer(t);let n=sv(this.gl,e,o,this.textureConfig);return this.unbindTextureToFrameBuffer(),n}createAndWaitForFence(){let t=this.createFence(this.gl);return this.pollFence(t)}createFence(t){let e,o;if(A().getBool(\"WEBGL_FENCE_API_ENABLED\")){let n=t,s=n.fenceSync(n.SYNC_GPU_COMMANDS_COMPLETE,0);t.flush(),o=()=>{let a=n.clientWaitSync(s,0,0);return a===n.ALREADY_SIGNALED||a===n.CONDITION_SATISFIED},e=s}else A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")>0?(e=this.beginQuery(),this.endQuery(),o=()=>this.isQueryAvailable(e,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\"))):o=()=>!0;return{query:e,isFencePassed:o}}downloadMatrixFromPackedTexture(t,e,o){return this.downloadMatrixDriver(t,()=>pv(this.gl,e,o))}createProgram(t){this.throwIfDisposed();let e=this.gl;this.vertexShader==null&&(this.vertexShader=jI(e));let o=EI(e);ce(e,()=>e.attachShader(o,this.vertexShader)),ce(e,()=>e.attachShader(o,t)),RI(e,o);let n=Object.assign(o,{vao:this.createVertexArray()});return this.debug&&Yl(e,n),n}buildVao(t){this.setProgram(t),this.bindVertexArray(t.vao);let e=this.gl;ce(e,()=>e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,this.indexBuffer)),rv(e,t,this.vertexBuffer)}deleteProgram(t){this.throwIfDisposed(),t===this.program&&(this.program=null),t!=null&&(ce(this.gl,()=>this.gl.deleteProgram(t)),this.deleteVertexArray(t.vao))}setProgram(t){this.throwIfDisposed(),this.program=t,this.program!=null&&this.debug&&Yl(this.gl,this.program),ce(this.gl,()=>this.gl.useProgram(t))}getUniformLocation(t,e,o=!0){return this.throwIfDisposed(),o?MI(this.gl,t,e):LI(this.gl,t,e)}getAttributeLocation(t,e){return this.throwIfDisposed(),ce(this.gl,()=>this.gl.getAttribLocation(t,e))}getUniformLocationNoThrow(t,e){return this.throwIfDisposed(),this.gl.getUniformLocation(t,e)}setInputMatrixTexture(t,e,o){this.throwIfDisposed(),this.throwIfNoProgram(),BI(this.gl,t,e,o)}setOutputMatrixTexture(t,e,o){this.setOutputMatrixTextureDriver(t,o,e)}setOutputPackedMatrixTexture(t,e,o){this.throwIfDisposed();let[n,s]=La(e,o);this.setOutputMatrixTextureDriver(t,n,s)}setOutputMatrixWriteRegion(t,e,o,n){this.setOutputMatrixWriteRegionDriver(o,t,n,e)}setOutputPackedMatrixWriteRegion(t,e,o,n){throw new Error(\"setOutputPackedMatrixWriteRegion not implemented.\")}debugValidate(){this.program!=null&&Yl(this.gl,this.program),Rc(this.gl)}executeProgram(){this.throwIfDisposed(),this.throwIfNoProgram();let t=this.gl;if(this.debug){let e=this.getVertexArray();console.assert(e===this.program.vao,\"VAO changed between setProgram and executeProgram!\"),this.debugValidate()}ce(t,()=>t.drawElements(t.TRIANGLES,6,t.UNSIGNED_SHORT,0))}blockUntilAllProgramsCompleted(){this.throwIfDisposed(),ce(this.gl,()=>this.gl.finish())}getQueryTimerExtension(){return this.disjointQueryTimerExtension==null&&(this.disjointQueryTimerExtension=Ec(this.gl,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")===2?\"EXT_disjoint_timer_query_webgl2\":\"EXT_disjoint_timer_query\")),this.disjointQueryTimerExtension}getQueryTimerExtensionWebGL2(){return this.getQueryTimerExtension()}getQueryTimerExtensionWebGL1(){return this.getQueryTimerExtension()}beginQuery(){if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")===2){let o=this.gl,n=this.getQueryTimerExtensionWebGL2(),s=o.createQuery();return o.beginQuery(n.TIME_ELAPSED_EXT,s),s}let t=this.getQueryTimerExtensionWebGL1(),e=t.createQueryEXT();return t.beginQueryEXT(t.TIME_ELAPSED_EXT,e),e}endQuery(){if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")===2){let e=this.gl,o=this.getQueryTimerExtensionWebGL2();e.endQuery(o.TIME_ELAPSED_EXT);return}let t=this.getQueryTimerExtensionWebGL1();t.endQueryEXT(t.TIME_ELAPSED_EXT)}async waitForQueryAndGetTime(t){return await y.repeatedTry(()=>this.disposed||this.isQueryAvailable(t,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\"))),this.getQueryTime(t,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\"))}getQueryTime(t,e){if(e===0)return null;if(e===2){let o=this.gl;return o.getQueryParameter(t,o.QUERY_RESULT)/1e6}else{let o=this.getQueryTimerExtensionWebGL1();return o.getQueryObjectEXT(t,o.QUERY_RESULT_EXT)/1e6}}isQueryAvailable(t,e){if(e===0)return!0;if(e===2){let o=this.gl,n=this.getQueryTimerExtensionWebGL2(),s=o.getQueryParameter(t,o.QUERY_RESULT_AVAILABLE);return this.disjoint==null&&(this.disjoint=this.gl.getParameter(n.GPU_DISJOINT_EXT)),s&&!this.disjoint}else{let o=this.getQueryTimerExtensionWebGL1(),n=o.getQueryObjectEXT(t,o.QUERY_RESULT_AVAILABLE_EXT);return this.disjoint==null&&(this.disjoint=this.gl.getParameter(o.GPU_DISJOINT_EXT)),n&&!this.disjoint}}pollFence(t){return new Promise(e=>{this.addItemToPoll(()=>t.isFencePassed(),()=>e())})}pollItems(){let t=HZ(this.itemsToPoll.map(e=>e.isDoneFn));for(let e=0;e<=t;++e){let{resolveFn:o}=this.itemsToPoll[e];o()}this.itemsToPoll=this.itemsToPoll.slice(t+1)}addItemToPoll(t,e){if(this.itemsToPoll.push({isDoneFn:t,resolveFn:e}),this.itemsToPoll.length>1)return;let o;\"setTimeoutCustom\"in A().platform&&(o=A().platform.setTimeoutCustom.bind(A().platform)),y.repeatedTry(()=>(this.pollItems(),this.itemsToPoll.length===0),()=>0,null,o)}bindTextureToFrameBuffer(t){this.throwIfDisposed(),Ql(this.gl,t,this.framebuffer),this.debug&&Rc(this.gl)}unbindTextureToFrameBuffer(){this.outputTexture!=null?(Ql(this.gl,this.outputTexture,this.framebuffer),this.debug&&Rc(this.gl)):Xf(this.gl,this.framebuffer)}downloadMatrixDriver(t,e){this.bindTextureToFrameBuffer(t);let o=e();return this.unbindTextureToFrameBuffer(),o}setOutputMatrixTextureDriver(t,e,o){this.throwIfDisposed();let n=this.gl;Ql(n,t,this.framebuffer),this.debug&&Rc(n),this.outputTexture=t,ce(n,()=>n.viewport(0,0,e,o)),ce(n,()=>n.scissor(0,0,e,o))}setOutputMatrixWriteRegionDriver(t,e,o,n){this.throwIfDisposed(),ce(this.gl,()=>this.gl.scissor(t,e,o,n))}throwIfDisposed(){if(this.disposed)throw new Error(\"Attempted to use disposed GPGPUContext.\")}throwIfNoProgram(){if(this.program==null)throw new Error(\"No GPU program is currently set.\")}};function HZ(r){let t=0;for(;t`${r}.${e}`)}function Dt(r,t){return t===1?[r]:lv(r,t)}function SD(r,t){if(r===1)return\"rc\";let e=\"\";for(let o=0;o ${this.enableShapeUniforms?\"outShape\":this.outputShape[0]}`;let e=\"\";for(let o=this.rank-2;o= ${this.enableShapeUniforms?`outShape[${o}]`:this.outputShape[o]}`,o= ${o};\n bool rEdge = rp1 >= ${n};\n `}getOutput(t){let e=this.getSourceCoordsArr(t);return this.rank===1?`getA(rc), (rc + 1 >= ${this.enableShapeUniforms?\"outShape\":this.outputShape[0]} ? 0. : getA(rc + 1)), 0, 0`:`getA(${e[0]}),\n cEdge ? 0. : getA(${e[1]}),\n rEdge ? 0. : getA(${e[2]}),\n rEdge || cEdge ? 0. : getA(${e[3]})`}};var Vc=class{constructor(t,e){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"inputShape\",type:\"ivec3\"}],this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length);let o=\"\";for(let n=0;n<4;n++){let s=\"thisRC = rc;\";n%2===1&&(s+=\"thisRC.z += 1;\"),n>1&&(s+=\"thisRC.y += 1;\"),o+=`\n ${s}\n ${n>0?\"if(thisRC.y < rows && thisRC.z < cols){\":\"\"}\n int flatIndex = getFlatIndex(thisRC);\n\n ivec3 inputRC = inputCoordsFromReshapedOutCoords(flatIndex);\n vec2 inputRCInnerDims = vec2(float(inputRC.y),float(inputRC.z));\n\n result[${n}] =\n getChannel(getA(inputRC.x, inputRC.y, inputRC.z), inputRCInnerDims);\n ${n>0?\"}\":\"\"}\n `}this.userCode=`\n ${KZ(e,this.enableShapeUniforms)}\n ${this.enableShapeUniforms?Pc():Fc(t)}\n\n void main() {\n ivec3 rc = getOutputCoords();\n\n vec4 result = vec4(0.);\n\n ivec3 thisRC;\n int rows = ${this.enableShapeUniforms?\"outShape[1]\":t[1]};\n int cols = ${this.enableShapeUniforms?\"outShape[2]\":t[2]};\n\n ${o}\n\n setOutput(result);\n }\n `}};function KZ(r,t){return`\n ivec3 inputCoordsFromReshapedOutCoords(int index) {\n ${t?SR([\"r\",\"c\",\"d\"],\"inputShape\"):Ws([\"r\",\"c\",\"d\"],r)}\n return ivec3(r, c, d);\n }\n `}var dh=class{constructor(t){this.gpgpu=t,this.numUsedTextures=0,this.numFreeTextures=0,this._numBytesAllocated=0,this._numBytesFree=0,this.freeTextures={},this.usedTextures={},this.logEnabled=!1}acquireTexture(t,e,o){let n=vD(e,o),s=kD(t,n,o);s in this.freeTextures||(this.freeTextures[s]=[]),s in this.usedTextures||(this.usedTextures[s]=[]);let a=ID(t,n,this.gpgpu.gl,this.gpgpu.textureConfig,o);if(this.freeTextures[s].length>0){this.numFreeTextures--,this.numUsedTextures++,this._numBytesFree-=a,this.log();let p=this.freeTextures[s].pop();return this.usedTextures[s].push(p),p}let i;return n===rr.PACKED_2X2_FLOAT32?i=this.gpgpu.createPackedMatrixTexture(t[0],t[1]):n===rr.PACKED_2X2_FLOAT16?i=this.gpgpu.createFloat16PackedMatrixTexture(t[0],t[1]):n===rr.UNPACKED_FLOAT32?i=this.gpgpu.createFloat32MatrixTexture(t[0],t[1]):n===rr.UNPACKED_FLOAT16?i=this.gpgpu.createFloat16MatrixTexture(t[0],t[1]):n===rr.PACKED_4X1_UNSIGNED_BYTE&&(i=this.gpgpu.createUnsignedBytesMatrixTexture(t[0],t[1])),this.usedTextures[s].push(i),this.numUsedTextures++,this._numBytesAllocated+=a,this.log(),i}releaseTexture(t,e,o,n){if(this.freeTextures==null)return;let s=vD(o,n),a=kD(e,s,n);a in this.freeTextures||(this.freeTextures[a]=[]);let i=ID(e,s,this.gpgpu.gl,this.gpgpu.textureConfig,n),p=A().getNumber(\"WEBGL_DELETE_TEXTURE_THRESHOLD\");p!==-1&&this._numBytesAllocated>p?(this.gpgpu.deleteMatrixTexture(t.texture),this._numBytesAllocated-=i):(this.freeTextures[a].push(t),this.numFreeTextures++,this._numBytesFree+=i),this.numUsedTextures--;let u=this.usedTextures[a],c=u&&u.indexOf(t);if(c==null||c<0)throw new Error(\"Cannot release a texture that was never provided by this texture manager\");u[c]=u[u.length-1],u.pop(),this.log()}log(){if(!this.logEnabled)return;let t=this.numFreeTextures+this.numUsedTextures;console.log(\"Free/Used\",`${this.numFreeTextures} / ${this.numUsedTextures}`,`(${t})`);let e=this._numBytesFree/this._numBytesAllocated;console.log(`Bytes allocated: ${this._numBytesAllocated}`),console.log(`Bytes unused: ${this._numBytesFree} (${Math.round(100*e)}%)`)}get numBytesAllocated(){return this._numBytesAllocated}get numBytesFree(){return this._numBytesFree}getNumUsedTextures(){return this.numUsedTextures}getNumFreeTextures(){return this.numFreeTextures}dispose(){if(this.freeTextures!=null){for(let t in this.freeTextures)this.freeTextures[t].forEach(e=>{this.gpgpu.deleteMatrixTexture(e.texture)});for(let t in this.usedTextures)this.usedTextures[t].forEach(e=>{this.gpgpu.deleteMatrixTexture(e.texture)});this.freeTextures=null,this.usedTextures=null,this.numUsedTextures=0,this.numFreeTextures=0,this._numBytesAllocated=0,this._numBytesFree=0}}};function qZ(r,t){let e=r;if(t===e.R32F)return 4;if(t===e.R16F)return 2;if(t===e.RGBA32F)return 16;if(t===r.RGBA)return 16;if(t===e.RGBA16F)return 8;if(t===e.RGBA8)return 4;throw new Error(`Unknown internal format ${t}`)}function ID(r,t,e,o,n){let s=jZ(t,o),a;if(n){let[p,u]=La(r[0],r[1]);a=p*u}else{let[p,u]=Sp(r[0],r[1]);a=p*u}let i=qZ(e,s);return a*i}function jZ(r,t){switch(r){case rr.PACKED_2X2_FLOAT32:return ih(t);case rr.PACKED_2X2_FLOAT16:return uh(t);case rr.UNPACKED_FLOAT32:return nh(t);case rr.UNPACKED_FLOAT16:return sh(t);case rr.PACKED_4X1_UNSIGNED_BYTE:return ah(t);default:throw new Error(`Unknown physical texture type ${r}`)}}function XZ(r){return A().getBool(\"WEBGL_RENDER_FLOAT32_ENABLED\")?r?rr.PACKED_2X2_FLOAT32:rr.UNPACKED_FLOAT32:r?rr.PACKED_2X2_FLOAT16:rr.UNPACKED_FLOAT16}function vD(r,t){if(r===dr.UPLOAD)return rr.PACKED_2X2_FLOAT32;if(r===dr.RENDER||r==null)return XZ(t);if(r===dr.DOWNLOAD||r===dr.PIXELS)return rr.PACKED_4X1_UNSIGNED_BYTE;throw new Error(`Unknown logical texture type ${r}`)}function kD(r,t,e){return`${r[0]}_${r[1]}_${t}_${e}`}var or=class{constructor(t,e){this.variableNames=[\"A\"],this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n float unaryOperation(float x) {\n ${e}\n }\n\n void main() {\n float x = getAAtOutCoords();\n float y = unaryOperation(x);\n\n setOutput(y);\n }\n `}},Ut=\"if (isnan(x)) return x;\",ND=\"return x;\",mv=\"return abs(x);\";var TD=\"return (x >= 0.0) ? x : (exp(x) - 1.0);\",_D=Ut+`\n return (x < 0.0) ? 0.0 : x;\n`,$D=Ut+`\n return (x < 0.0) ? 0.0 : min(6.0, x);\n`,Ba=\"return x;\",ED=\"return 1.0 / (1.0 + exp(-1.0 * x));\";var DD=\"return x;\",AD=`\n vec4 result;\n\n result.r = (x.r >= 0.0) ? x.r : (exp(x.r) - 1.0);\n result.g = (x.g >= 0.0) ? x.g : (exp(x.g) - 1.0);\n result.b = (x.b >= 0.0) ? x.b : (exp(x.b) - 1.0);\n result.a = (x.a >= 0.0) ? x.a : (exp(x.a) - 1.0);\n\n return result;\n`,FD=`\n vec4 result = x * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,PD=`\n vec4 result = min(x, vec4(6.)) * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,OD=\"return 1.0 / (1.0 + exp(-1.0 * x));\",Fr=class{constructor(t,e){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n vec4 unaryOperation(vec4 x) {\n ${e}\n }\n\n void main() {\n vec4 x = getAAtOutCoords();\n vec4 y = unaryOperation(x);\n\n setOutput(y);\n }\n `}};var fh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!1,this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length);let e=t.length,o=Dt(\"rc\",e),n=Re(e),s=SD(e,o),a=o.slice(-2),i=e<=1?\"rc\":`vec2(${a.join(\",\")})`;this.userCode=`\n void main() {\n ${n} rc = getOutputCoords();\n vec4 packedInput = getA(${s});\n\n setOutput(getChannel(packedInput, ${i}));\n }\n `}};var QZ=Wt.whereImpl,ZZ=1e-7,JZ=1e-4,hh={};function e9(r){return r in hh||(hh[r]={}),hh[r]}var t9=A().getNumber(\"CPU_HANDOFF_SIZE_THRESHOLD\"),r9=600;function o9(){return A().global.screen==null?1024:A().global.screen.height*A().global.screen.width*window.devicePixelRatio*r9/1024/1024}var wu=class extends ao{nextDataId(){return wu.nextDataId++}constructor(t){if(super(),this.pendingRead=new WeakMap,this.pendingDisposal=new WeakSet,this.dataRefCount=new WeakMap,this.numBytesInGPU=0,this.uploadWaitMs=0,this.downloadWaitMs=0,this.lastGlFlushTime=0,this.warnedAboutMemory=!1,this.pendingDeletes=0,this.disposed=!1,!A().getBool(\"HAS_WEBGL\"))throw new Error(\"WebGL is not supported on this device\");let e;if(t!=null){if(t instanceof kp)e=t;else{let o=Kr(A().getNumber(\"WEBGL_VERSION\"),t);e=new kp(o)}this.binaryCache={},this.gpgpuCreatedLocally=!1}else{let o=Kr(A().getNumber(\"WEBGL_VERSION\"));e=new kp(o),this.binaryCache=e9(A().getNumber(\"WEBGL_VERSION\")),this.gpgpuCreatedLocally=!0}this.gpgpu=e,this.canvas=this.gpgpu.gl.canvas,this.textureManager=new dh(this.gpgpu),this.numMBBeforeWarning=o9(),this.texData=new zo(this,pr())}numDataIds(){return this.texData.numDataIds()-this.pendingDeletes}writeTexture(t,e,o,n,s,a){let i=this.makeTensorInfo(e,o),p=this.texData.get(i.dataId);p.isPacked=!1,p.texture={texture:t,texShape:[n,s]},p.texShape=[n,s];let u=Dc(e),c=new Zl(u,!1,a),l=this.runWebGLProgram(c,[i],o,[[n,s]]);return l.shape=e,p.texture=null,this.disposeIntermediateTensorInfo(i),l.dataId}write(t,e,o){if((A().getBool(\"WEBGL_CHECK_NUMERICAL_PROBLEMS\")||A().getBool(\"DEBUG\"))&&this.checkNumericalProblems(t),o===\"complex64\"&&t!=null)throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");let n={id:this.nextDataId()};return this.texData.set(n,{shape:e,dtype:o,values:t,usage:dr.UPLOAD,refCount:1}),n}refCount(t){return this.texData.has(t)?this.texData.get(t).refCount:0}incRef(t){let e=this.texData.get(t);e.refCount++}decRef(t){if(this.texData.has(t)){let e=this.texData.get(t);e.refCount--}}move(t,e,o,n,s){if(A().getBool(\"DEBUG\")&&this.checkNumericalProblems(e),n===\"complex64\")throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");this.texData.set(t,{shape:o,dtype:n,values:e,usage:dr.UPLOAD,refCount:s})}disposeIntermediateTensorInfo(t){this.disposeData(t.dataId)}readSync(t){let e=this.texData.get(t),{values:o,dtype:n,complexTensorInfos:s,slice:a,shape:i,isPacked:p}=e;if(a!=null){let m;p?m=new Fr(i,Ba):m=new or(i,Ba);let d=this.runWebGLProgram(m,[{dataId:t,shape:i,dtype:n}],n),f=this.readSync(d.dataId);return this.disposeIntermediateTensorInfo(d),f}if(o!=null)return this.convertAndCacheOnCPU(t);if(n===\"string\")return o;let u=this.activeTimers!=null,c;u&&(c=y.now());let l;if(n===\"complex64\"){let m=this.readSync(s.real.dataId),d=this.readSync(s.imag.dataId);l=w.mergeRealAndImagArrays(m,d)}else l=this.getValuesFromTexture(t);return u&&(this.downloadWaitMs+=y.now()-c),this.convertAndCacheOnCPU(t,l)}async read(t){if(this.pendingRead.has(t)){let f=this.pendingRead.get(t);return new Promise(h=>f.push(h))}let e=this.texData.get(t),{values:o,shape:n,slice:s,dtype:a,complexTensorInfos:i,isPacked:p}=e;if(s!=null){let f;p?f=new Fr(n,Ba):f=new or(n,Ba);let h=this.runWebGLProgram(f,[{dataId:t,shape:n,dtype:a}],a),g=this.read(h.dataId);return this.disposeIntermediateTensorInfo(h),g}if(o!=null)return this.convertAndCacheOnCPU(t);if(A().getBool(\"DEBUG\")&&!A().getBool(\"WEBGL_DOWNLOAD_FLOAT_ENABLED\")&&A().getNumber(\"WEBGL_VERSION\")===2)throw new Error(\"tensor.data() with WEBGL_DOWNLOAD_FLOAT_ENABLED=false and WEBGL_VERSION=2 not yet supported.\");let u=null,c;if(a!==\"complex64\"&&A().get(\"WEBGL_BUFFER_SUPPORTED\")){c=this.decode(t);let f=this.texData.get(c.dataId);u=this.gpgpu.createBufferFromTexture(f.texture.texture,...jl(n))}this.pendingRead.set(t,[]),a!==\"complex64\"&&await this.gpgpu.createAndWaitForFence();let l;if(a===\"complex64\"){let f=await Promise.all([this.read(i.real.dataId),this.read(i.imag.dataId)]),h=f[0],g=f[1];l=w.mergeRealAndImagArrays(h,g)}else if(u==null)l=this.getValuesFromTexture(t);else{let f=y.sizeFromShape(n);l=this.gpgpu.downloadFloat32MatrixFromBuffer(u,f)}if(c!=null&&this.disposeIntermediateTensorInfo(c),u!=null){let f=this.gpgpu.gl;ce(f,()=>f.deleteBuffer(u))}let m=this.convertAndCacheOnCPU(t,l),d=this.pendingRead.get(t);return this.pendingRead.delete(t),d.forEach(f=>f(m)),this.pendingDisposal.has(t)&&(this.pendingDisposal.delete(t),this.disposeData(t)&&pr().removeDataId(t,this),this.pendingDeletes--),m}readToGPU(t,e={}){let o=this.texData.get(t),{values:n,shape:s,slice:a,dtype:i,isPacked:p,texture:u}=o;if(i===\"complex64\")throw new Error(\"Does not support reading texture for complex64 dtype.\");if(a!=null){let d;p?d=new Fr(s,Ba):d=new or(s,Ba);let f=this.runWebGLProgram(d,[{dataId:t,shape:s,dtype:i}],i),h=this.readToGPU(f,e);return this.disposeIntermediateTensorInfo(f),h}if(u==null)throw n!=null?new Error(\"Data is not on GPU but on CPU.\"):new Error(\"There is no data on GPU or CPU.\");let c=this.decode(t,e.customTexShape),l=pr().makeTensorFromTensorInfo(c),m=this.texData.get(c.dataId);return Object.assign({tensorRef:l},m.texture)}bufferSync(t){let e=this.readSync(t.dataId);if(t.dtype===\"string\")try{let o=e.map(n=>y.decodeString(n));return me(t.shape,t.dtype,o)}catch(o){throw new Error(\"Failed to decode encoded string bytes into utf-8\")}return me(t.shape,t.dtype,e)}checkNumericalProblems(t){if(t!=null)for(let e=0;e0}time(t){let e=this.activeTimers,o=[],n=!1;this.programTimersStack==null?(this.programTimersStack=o,n=!0):this.activeTimers.push(o),this.activeTimers=o,t();let s=y.flatten(this.activeTimers.map(p=>p.query)).filter(p=>p!=null),a=y.flatten(this.activeTimers.map(p=>p.name)).filter(p=>p!=null);this.activeTimers=e,n&&(this.programTimersStack=null);let i={uploadWaitMs:this.uploadWaitMs,downloadWaitMs:this.downloadWaitMs,kernelMs:null,wallMs:null};return(async()=>{if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0){let p=await Promise.all(s);i.kernelMs=y.sum(p),i.getExtraProfileInfo=()=>p.map((u,c)=>({name:a[c],ms:u})).map(u=>`${u.name}: ${u.ms}`).join(\", \")}else i.kernelMs={error:\"WebGL query timers are not supported in this environment.\"};return this.uploadWaitMs=0,this.downloadWaitMs=0,i})()}memory(){return{unreliable:!1,numBytesInGPU:this.numBytesInGPU,numBytesInGPUAllocated:this.textureManager.numBytesAllocated,numBytesInGPUFree:this.textureManager.numBytesFree}}startTimer(){return A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0?this.gpgpu.beginQuery():{startMs:y.now(),endMs:null}}endTimer(t){return A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0?(this.gpgpu.endQuery(),t):(t.endMs=y.now(),t)}async getQueryTime(t){if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0)return this.gpgpu.waitForQueryAndGetTime(t);let e=t;return e.endMs-e.startMs}disposeData(t,e=!1){if(this.pendingDisposal.has(t))return!1;if(!this.texData.has(t))return!0;if(e?this.texData.get(t).refCount=0:this.texData.get(t).refCount--,!e&&this.texData.get(t).refCount>0)return!1;if(this.pendingRead.has(t))return this.pendingDisposal.add(t),this.pendingDeletes++,!1;this.releaseGPUData(t);let{complexTensorInfos:o}=this.texData.get(t);return o!=null&&(this.disposeData(o.real.dataId,e),this.disposeData(o.imag.dataId,e)),this.texData.delete(t),!0}releaseGPUData(t){let{texture:e,dtype:o,texShape:n,usage:s,isPacked:a,slice:i}=this.texData.get(t),p=i&&i.origDataId||t,u=this.dataRefCount.get(p);u>1?this.dataRefCount.set(p,u-1):(this.dataRefCount.delete(p),e!=null&&(this.numBytesInGPU-=this.computeBytes(n,o),this.textureManager.releaseTexture(e,n,s,a)));let c=this.texData.get(t);c.texture=null,c.texShape=null,c.isPacked=!1,c.slice=null}getTexture(t){return this.uploadToGPU(t),this.texData.get(t).texture.texture}getDataInfo(t){return this.texData.get(t)}shouldExecuteOnCPU(t,e=t9){return A().getBool(\"WEBGL_CPU_FORWARD\")&&t.every(o=>this.texData.get(o.dataId).texture==null&&y.sizeFromShape(o.shape)0&&y.isString(o[0])){let s=o.map(a=>y.encodeString(a));n=this.write(s,t,e)}else n=this.write(o,t,e);return this.texData.get(n).usage=null,{dataId:n,shape:t,dtype:e}}makeOutput(t,e,o){return pr().makeTensorFromTensorInfo(this.makeTensorInfo(t,e,o),this)}unpackTensor(t){let e=new fh(t.shape);return this.runWebGLProgram(e,[t],t.dtype)}packTensor(t){let e=new mh(t.shape),o=!0;return this.runWebGLProgram(e,[t],t.dtype,null,o)}packedReshape(t,e){let o=[yi(t.shape),...bi(t.shape)],n={dtype:t.dtype,shape:o,dataId:t.dataId},s=[yi(e),...bi(e)],a=new Vc(s,o),i=!0,p=[o],u=this.runWebGLProgram(a,[n],t.dtype,p,i);return{dataId:u.dataId,shape:e,dtype:u.dtype}}decode(t,e){let o=this.texData.get(t),{isPacked:n,shape:s,dtype:a}=o;if(e!=null){let m=y.sizeFromShape(s),d=e[0]*e[1]*4;y.assert(m<=d,()=>\"customTexShape is too small. Row * Column * 4 should be equal or larger than the size of the tensor data.\")}let i=Dc(s),p;n?p=new eh(i):p=new Jf(i);let u=!0,c=[e!=null?e:jl(i)],l=this.runWebGLProgram(p,[{shape:i,dtype:a,dataId:t}],a,c,u,e);return{dtype:a,shape:s,dataId:l.dataId}}runWebGLProgram(t,e,o,n,s=!1,a){let i=this.makeTensorInfo(t.outputShape,o),p=this.texData.get(i.dataId);if(t.packedOutput&&(p.isPacked=!0),t.outPackingScheme===bu.DENSE){let x=a!=null?a:jl(t.outputShape);p.texShape=x.map(b=>b*2)}if(t.outTexUsage!=null&&(p.usage=t.outTexUsage),y.sizeFromShape(i.shape)===0)return p.values=y.getTypedArrayFromDType(i.dtype,0),i;let u=[],c=e.map(x=>{if(x.dtype===\"complex64\")throw new Error(\"GPGPUProgram does not support complex64 input. For complex64 dtypes, please separate the program into real and imaginary parts.\");let b=this.texData.get(x.dataId);if(b.texture==null){if(!t.packedInputs&&y.sizeFromShape(x.shape)<=A().getNumber(\"WEBGL_SIZE_UPLOAD_UNIFORM\"))return{shape:x.shape,texData:null,isUniform:!0,uniformValues:b.values};t.packedInputs&&(b.isPacked=!0,b.shape=x.shape)}if(this.uploadToGPU(x.dataId),!!b.isPacked!=!!t.packedInputs)x=b.isPacked?this.unpackTensor(x):this.packTensor(x),u.push(x),b=this.texData.get(x.dataId);else if(b.isPacked&&!Cu(b.shape,x.shape)){let C=x,S=x.shape;x.shape=b.shape,x=this.packedReshape(x,S),u.push(x),b=this.texData.get(x.dataId),C.shape=S}return{shape:x.shape,texData:b,isUniform:!1}});this.uploadToGPU(i.dataId);let l={shape:i.shape,texData:p,isUniform:!1},m=ER(t,c,l),d=this.getAndSaveBinary(m,()=>_R(this.gpgpu,t,c,l)),f=this.activeTimers!=null,h;f&&(h=this.startTimer()),A().get(\"ENGINE_COMPILE_ONLY\")||$R(this.gpgpu,d,c,l,n),u.forEach(x=>this.disposeIntermediateTensorInfo(x)),f&&(h=this.endTimer(h),this.activeTimers.push({name:t.constructor.name,query:this.getQueryTime(h)}));let g=A().getNumber(\"WEBGL_FLUSH_THRESHOLD\");if(g>0){let x=y.now();x-this.lastGlFlushTime>g&&(this.gpgpu.gl.flush(),this.lastGlFlushTime=x)}if(!A().getBool(\"WEBGL_LAZILY_UNPACK\")&&p.isPacked&&s===!1){let x=this.unpackTensor(i);return this.disposeIntermediateTensorInfo(i),x}return i}compileAndRun(t,e,o,n,s=!1){return o=o||e[0].dtype,this.runWebGLProgram(t,e,o,n,s)}getAndSaveBinary(t,e){return t in this.binaryCache||(this.binaryCache[t]=e()),this.binaryCache[t]}getTextureManager(){return this.textureManager}dispose(){this.disposed||(A().getBool(\"IS_TEST\")||Object.keys(this.binaryCache).forEach(e=>{this.gpgpu.deleteProgram(this.binaryCache[e].webGLProgram),delete this.binaryCache[e]}),this.textureManager.dispose(),this.canvas!=null&&typeof HTMLCanvasElement!=\"undefined\"&&this.canvas instanceof HTMLCanvasElement?this.canvas.remove():this.canvas=null,this.gpgpuCreatedLocally&&(this.gpgpu.program=null,this.gpgpu.dispose()),this.disposed=!0)}floatPrecision(){return this.floatPrecisionValue==null&&(this.floatPrecisionValue=De(()=>{if(!A().get(\"WEBGL_RENDER_FLOAT32_ENABLED\")){let t=A().getBool(\"DEBUG\");A().set(\"DEBUG\",!1);let e=this.abs(ke(1e-8)).dataSync()[0];if(A().set(\"DEBUG\",t),e>0)return 32}return 16})),this.floatPrecisionValue}epsilon(){return this.floatPrecision()===32?ZZ:JZ}uploadToGPU(t){let e=this.texData.get(t),{shape:o,dtype:n,values:s,texture:a,usage:i,isPacked:p}=e;if(a!=null)return;let u=this.activeTimers!=null,c;u&&(c=y.now());let l=e.texShape;if(l==null&&(l=zI(o,p),e.texShape=l),s!=null){let m=Dc(o),d,f=l[1],h=l[0],g=s instanceof Uint8Array||s instanceof Uint8ClampedArray;(p||!g)&&([f,h]=La(l[0],l[1])),p?d=new oh(m,g):d=new Zl(m,g);let x=g?[h,f]:l,b=this.makeTensorInfo(x,n),C=this.texData.get(b.dataId);g?C.usage=dr.PIXELS:C.usage=dr.UPLOAD,C.texShape=x,this.gpgpu.uploadDenseMatrixToTexture(this.getTexture(b.dataId),f,h,s);let S=[[h,f]],k=!0,_=this.runWebGLProgram(d,[b],n,S,k),E=this.texData.get(_.dataId);e.texShape=E.texShape,e.isPacked=E.isPacked,e.usage=E.usage,A().get(\"ENGINE_COMPILE_ONLY\")?this.disposeData(_.dataId):(e.texture=E.texture,e.values=null,this.texData.delete(_.dataId)),this.disposeIntermediateTensorInfo(b),u&&(this.uploadWaitMs+=y.now()-c)}else{let m=this.acquireTexture(l,i,n,p);e.texture=m}}convertAndCacheOnCPU(t,e){let o=this.texData.get(t),{dtype:n}=o;return e!=null&&(o.values=n9(e,n)),o.values}acquireTexture(t,e,o,n){if(this.numBytesInGPU+=this.computeBytes(t,o),!this.warnedAboutMemory&&this.numBytesInGPU>this.numMBBeforeWarning*1024*1024){let s=(this.numBytesInGPU/1024/1024).toFixed(2);this.warnedAboutMemory=!0,console.warn(`High memory usage in GPU: ${s} MB, most likely due to a memory leak`)}return this.textureManager.acquireTexture(t,e,n)}computeBytes(t,e){return t[0]*t[1]*y.bytesPerElement(e)}checkCompileCompletion(){for(let[,t]of Object.entries(this.binaryCache))this.checkCompletion_(t)}async checkCompileCompletionAsync(){let t=[];if(this.gpgpu.parallelCompilationExtension){for(let[,e]of Object.entries(this.binaryCache))t.push(this.checkCompletionAsync_(e));return Promise.all(t)}else{for(let[,e]of Object.entries(this.binaryCache)){let o=new Promise(n=>{try{this.checkCompletion_(e),n(!0)}catch(s){throw s}});t.push(o)}return Promise.all(t)}}async checkCompletionAsync_(t){return this.gpgpu.gl.getProgramParameter(t.webGLProgram,this.gpgpu.parallelCompilationExtension.COMPLETION_STATUS_KHR)?this.checkCompletion_(t):(await pS(),this.checkCompletionAsync_(t))}checkCompletion_(t){if(this.gpgpu.gl.getProgramParameter(t.webGLProgram,this.gpgpu.gl.LINK_STATUS)===!1)throw console.log(this.gpgpu.gl.getProgramInfoLog(t.webGLProgram)),this.gpgpu.gl.getShaderParameter(t.fragmentShader,this.gpgpu.gl.COMPILE_STATUS)===!1?(qf(t.source,this.gpgpu.gl.getShaderInfoLog(t.fragmentShader)),new Error(\"Failed to compile fragment shader.\")):new Error(\"Failed to link vertex and fragment shaders.\");return!0}getUniformLocations(){for(let t of Object.values(this.binaryCache)){this.gpgpu.buildVao(t.webGLProgram);let{variablesLocations:e,customUniformLocations:o,infLoc:n,nanLoc:s,outShapeLocation:a,outShapeStridesLocation:i,outTexShapeLocation:p}=qI(this.gpgpu,t.program,t.webGLProgram);t.variablesLocations=e,t.customUniformLocations=o,t.infLoc=n,t.nanLoc=s,t.outShapeLocation=a,t.outShapeStridesLocation=i,t.outTexShapeLocation=p}}createTensorFromGPUData(t,e,o){t.channels=t.channels||\"RGBA\";let{texture:n,height:s,width:a,channels:i}=t,p=pr().backend;if(!p.gpgpu.gl.isTexture(n))throw new Error(\"The texture is invalid. Also, please make sure the texture and the TFJS WebGL backend are using the same canvas. If you want to use your own custom canvas, you have to create and use the custom TFJS WebGL backend created from the canvas through 'new tf.MathBackendWebGL(customCanvas)'.\");let u=p.writeTexture(n,e,o,s,a,i);return pr().makeTensorFromDataId(u,e,o,p)}};wu.nextDataId=0;function n9(r,t){if(t===\"float32\"||t===\"complex64\")return r;if(t===\"int32\"||t===\"bool\"){let e=t===\"int32\"?new Int32Array(r.length):new Uint8Array(r.length);for(let o=0;onew wu,2);var Cat={forceHalfFloat:MD};var Wc=`\n if (isnan(a)) return a;\n if (isnan(b)) return b;\n`;var Pr=class{constructor(t,e,o){this.variableNames=[\"A\",\"B\"],this.outputShape=w.assertAndGetBroadcastShape(e,o),this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n float binaryOperation(float a, float b) {\n ${t}\n }\n\n void main() {\n float a = getAAtOutCoords();\n float b = getBAtOutCoords();\n setOutput(binaryOperation(a, b));\n }\n `}};var Xr=`\n result.r = isNaN.r ? NAN : result.r;\n result.g = isNaN.g ? NAN : result.g;\n result.b = isNaN.b ? NAN : result.b;\n result.a = isNaN.a ? NAN : result.a;\n`;var jr=class{constructor(t,e,o,n=!1){this.variableNames=[\"A\",\"B\"],this.supportsBroadcasting=!0,this.packedInputs=!0,this.packedOutput=!0,this.outputShape=w.assertAndGetBroadcastShape(e,o);let s=this.outputShape.length;this.enableShapeUniforms=pt(s);let a=\"\";if(n)if(s===0||y.sizeFromShape(this.outputShape)===1)a=`\n result.y = 0.;\n result.z = 0.;\n result.w = 0.;\n `;else if(a=`\n ${Re(s)} coords = getOutputCoords();\n `,s===1)this.enableShapeUniforms?a+=`\n result.y = (coords + 1) >= outShape ? 0. : result.y;\n result.z = 0.;\n result.w = 0.;\n `:a+=`\n result.y = (coords + 1) >= ${this.outputShape[0]} ? 0. : result.y;\n result.z = 0.;\n result.w = 0.;\n `;else{let p=Dt(\"coords\",s);this.enableShapeUniforms?a+=`\n bool nextRowOutOfBounds =\n (${p[s-2]} + 1) >= outShape[${s} - 2];\n bool nextColOutOfBounds =\n (${p[s-1]} + 1) >= outShape[${s} - 1];\n result.y = nextColOutOfBounds ? 0. : result.y;\n result.z = nextRowOutOfBounds ? 0. : result.z;\n result.w = nextColOutOfBounds || nextRowOutOfBounds ? 0. : result.w;\n `:a+=`\n bool nextRowOutOfBounds =\n (${p[s-2]} + 1) >= ${this.outputShape[s-2]};\n bool nextColOutOfBounds =\n (${p[s-1]} + 1) >= ${this.outputShape[s-1]};\n result.y = nextColOutOfBounds ? 0. : result.y;\n result.z = nextRowOutOfBounds ? 0. : result.z;\n result.w = nextColOutOfBounds || nextRowOutOfBounds ? 0. : result.w;\n `}this.userCode=`\n vec4 binaryOperation(vec4 a, vec4 b) {\n ${t}\n }\n\n void main() {\n vec4 a = getAAtOutCoords();\n vec4 b = getBAtOutCoords();\n\n vec4 result = binaryOperation(a, b);\n ${a}\n\n setOutput(result);\n }\n `}};function At(r){let{inputs:t,backend:e}=r,{x:o}=t;return e.incRef(o.dataId),{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}var LD={kernelName:wo,backendName:\"webgl\",kernelFunc:At};function Or(r){let{inputs:t,backend:e}=r,{real:o,imag:n}=t,s=e.makeTensorInfo(o.shape,\"complex64\"),a=e.texData.get(s.dataId),i=At({inputs:{x:o},backend:e}),p=At({inputs:{x:n},backend:e});return a.complexTensorInfos={real:i,imag:p},s}var BD={kernelName:Fi,backendName:\"webgl\",kernelFunc:Or};var dv=\"return (a < 0.) ? b * a : a;\",fv=`\n vec4 aLessThanZero = vec4(lessThan(a, vec4(0.)));\n return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`;function a9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{alpha:s}=o,a=e.makeTensorInfo([],\"float32\",y.createScalarValue(s,\"float32\")),i=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")?new jr(fv,n.shape,a.shape):new Pr(dv,n.shape,a.shape),p=e.runWebGLProgram(i,[n,a],\"float32\");return e.disposeIntermediateTensorInfo(a),p}var zD={kernelName:Rn,backendName:\"webgl\",kernelFunc:a9};var hv=\"return (a < 0.) ? b * a : a;\",gv=`\n vec4 aLessThanZero = vec4(lessThan(a, vec4(0.)));\n return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`;function i9(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t,s=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")?new jr(gv,o.shape,n.shape):new Pr(hv,o.shape,n.shape);return e.runWebGLProgram(s,[o,n],\"float32\")}var VD={kernelName:os,backendName:\"webgl\",kernelFunc:i9};var Po=\"if (isnan(x)) return x;\";function xe({opSnippet:r,packedOpSnippet:t,cpuKernelImpl:e,dtype:o}){return({inputs:n,backend:s})=>{let{x:a}=n,i=s,p=o||a.dtype;if(i.shouldExecuteOnCPU([a])&&e!=null){let l=i.texData.get(a.dataId),m=e(l.values,p);return i.makeTensorInfo(a.shape,p,m)}let u=A().getBool(\"WEBGL_PACK_UNARY_OPERATIONS\")&&t!=null,c;return u?c=new Fr(a.shape,t):c=new or(a.shape,r),i.runWebGLProgram(c,[a],p)}}function nt({opSnippet:r,packedOpSnippet:t,checkOutOfBounds:e=!1,supportsComplex:o=!1,cpuKernelImpl:n,dtype:s}){return({inputs:a,backend:i})=>{let{a:p,b:u}=a,c=i;if(o&&p.dtype===\"complex64\"){let f=c.texData.get(p.dataId),h=c.texData.get(u.dataId),[g,x]=[[f.complexTensorInfos.real,h.complexTensorInfos.real],[f.complexTensorInfos.imag,h.complexTensorInfos.imag]].map(C=>{let[S,k]=C,_={dataId:S.dataId,dtype:S.dtype,shape:p.shape},E={dataId:k.dataId,dtype:k.dtype,shape:u.shape},R=new Pr(r,p.shape,u.shape);return c.runWebGLProgram(R,[_,E],dt(S.dtype,k.dtype))}),b=Or({inputs:{real:g,imag:x},backend:c});return c.disposeIntermediateTensorInfo(g),c.disposeIntermediateTensorInfo(x),b}let l=s||dt(p.dtype,u.dtype);if((p.dtype===\"string\"||u.dtype===\"string\"||c.shouldExecuteOnCPU([p,u]))&&n!=null){let f=c.texData.get(p.dataId).values,h=c.texData.get(u.dataId).values,g=p.dtype===\"string\"?w.fromUint8ToStringArray(f):f,x=p.dtype===\"string\"?w.fromUint8ToStringArray(h):h,[b,C]=n(p.shape,u.shape,g,x,l),S=c.makeTensorInfo(C,l),k=c.texData.get(S.dataId);return k.values=b,S}let m=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")&&t!=null,d;return m?d=new jr(t,p.shape,u.shape,e):d=new Pr(r,p.shape,u.shape),c.runWebGLProgram(d,[p,u],l)}}function Ci(r,t=!1){if(r===\"linear\")return t?DD:ND;if(r===\"relu\")return t?FD:_D;if(r===\"elu\")return t?AD:TD;if(r===\"relu6\")return t?PD:$D;if(r===\"prelu\")return t?gv:hv;if(r===\"leakyrelu\")return t?fv:dv;if(r===\"sigmoid\")return t?OD:ED;throw new Error(`Activation ${r} has not been implemented for the WebGL backend.`)}var Uc=class{constructor(t,e,o,n=!1,s=!1,a=!1,i=null,p=!1,u=!1){this.variableNames=[\"matrixA\",\"matrixB\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=o,this.enableShapeUniforms=pt(this.outputShape.length);let c=n?t[1]:t[2],l=Math.ceil(c/2),m=n?\"i * 2, rc.y\":\"rc.y, i * 2\",d=s?\"rc.z, i * 2\":\"i * 2, rc.z\",f=n?[\"a.xxyy\",\"a.zzww\"]:[\"a.xxzz\",\"a.yyww\"],h=s?[\"b.xzxz\",\"b.ywyw\"]:[\"b.xyxy\",\"b.zwzw\"],g=\"\",x=\"\";i&&(p?g=`vec4 activation(vec4 a) {\n vec4 b = getPreluActivationWeightsAtOutCoords();\n ${i}\n }`:u?g=`vec4 activation(vec4 a) {\n vec4 b = getLeakyreluAlphaAtOutCoords();\n ${i}\n }`:g=`vec4 activation(vec4 x) {\n ${i}\n }`,x=\"result = activation(result);\");let b=a?\"result += getBiasAtOutCoords();\":\"\";a&&this.variableNames.push(\"bias\"),p&&this.variableNames.push(\"preluActivationWeights\"),u&&this.variableNames.push(\"leakyreluAlpha\");let C=\"rc.x\",S=\"rc.x\";t[0]`The new shape (${p}) has ${u} elements and the old shape (${n.shape}) has ${i} elements. The new shape and old shape must have the same number of elements.`);let c=a.texData.get(n.dataId);return c.isPacked&&!Cu(n.shape,p)&&!(c.texture!==null&&Cu(c.shape,p))?GD(n,p,a):(a.incRef(n.dataId),{dataId:n.dataId,shape:p,dtype:n.dtype})}var HD={kernelName:da,backendName:\"webgl\",kernelFunc:te};var rm=class{constructor(t,e){this.variableNames=[\"x\"];let{windowSize:o,batchSize:n,inSize:s,outSize:a}=t;this.outputShape=[n,a];let i=Math.floor(o/4)*4,p=o%4,u=\"sumValue += dot(values, ones);\";if(e!=null){let l=1/e;u=`sumValue += dot(values * ${y.isInt(l)?l.toPrecision(2):l}, ones);`}let c=\"\";s%o>0&&(c=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return 0.0;\n }\n `),this.userCode=`\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float getValue(int batch, int inIdx) {\n ${c}\n return getX(batch, inIdx);\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = outIdx * ${o};\n\n float sumValue = 0.0;\n\n for (int i = 0; i < ${i}; i += 4) {\n int inIdx = inOffset + i;\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n getValue(batch, inIdx + 3)\n );\n\n ${u}\n }\n\n int inIdx = inOffset + ${i};\n if (${p===1}) {\n vec4 values = vec4(getValue(batch, inIdx), 0.0, 0.0, 0.0);\n\n ${u}\n } else if (${p===2}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1), 0.0, 0.0);\n\n ${u}\n } else if (${p===3}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2), 0.0);\n\n ${u}\n }\n setOutput(sumValue);\n }\n `}};var gh=class{constructor(t,e){this.variableNames=[\"x\"];let{windowSize:o,batchSize:n,inSize:s,outSize:a}=t;this.outputShape=[n,a];let i=\"0.0\",p=\"\";e===\"prod\"?i=\"1.0\":e===\"min\"?(i=\"1.0 / 1e-20\",p=\"min\"):e===\"max\"&&(i=\"-1.0 / 1e-20\",p=\"max\");let u=`${e}(${e}(${e}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;e===\"sum\"?u=\"sumValue\":e===\"prod\"?u=\"prodValue\":e===\"all\"?u=\"allValue\":e===\"any\"&&(u=\"anyValue\");let c=Math.floor(o/4)*4,l=o%4,m=`\n if (${e===\"sum\"}) {\n sumValue += dot(values, ones);\n } else if (${e===\"prod\"}) {\n vec2 tmp = vec2(values[0], values[1]) * vec2(values[2], values[3]);\n prodValue *= tmp[0] * tmp[1];\n } else {\n minMaxValue = ${p}(values, minMaxValue);\n if (${e===\"min\"} || ${e===\"max\"}) {\n minMaxValue = ${p}(values, minMaxValue);\n bvec4 isNaN = isnan(values);\n if (isNaN.r || isNaN.g || isNaN.b || isNaN.a) {\n minMaxValue = vec4(NAN);\n }\n }\n }\n `,d=\"vec4\";e===\"all\"?(i=\"1.0\",m=`\n bool reducedAllValue = all(values);\n float floatedReducedAllValue = float(reducedAllValue);\n allValue = float(allValue >= 1.0 && floatedReducedAllValue >= 1.0);\n `,d=\"bvec4\"):e===\"any\"&&(i=\"0.0\",m=`\n bool reducedAnyValue = any(values);\n float floatedReducedAnyValue = float(reducedAnyValue);\n anyValue = float(anyValue >= 1.0 || floatedReducedAnyValue >= 1.0);\n `,d=\"bvec4\");let f=\"\";s%o>0&&(f=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return initializationValue;\n }\n `),this.userCode=`\n const float initializationValue = ${i};\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float getValue(int batch, int inIdx) {\n ${f}\n return getX(batch, inIdx);\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = outIdx * ${o};\n\n vec4 minMaxValue = vec4(${i});\n float prodValue = 1.0;\n float sumValue = 0.0;\n float allValue = 1.0;\n float anyValue = 0.0;\n\n for (int i = 0; i < ${c}; i += 4) {\n int inIdx = inOffset + i;\n ${d} values = ${d}(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n getValue(batch, inIdx + 3)\n );\n\n ${m}\n }\n\n int inIdx = inOffset + ${c};\n if (${l===1}) {\n ${d} values = ${d}(\n getValue(batch, inIdx),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n ${m}\n } else if (${l===2}) {\n ${d} values = ${d}(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n initializationValue,\n initializationValue\n );\n\n ${m}\n } else if (${l===3}) {\n ${d} values = ${d}(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n initializationValue\n );\n\n ${m}\n }\n setOutput(${u});\n }\n `}};function p9(r){let t=[];for(;t.length===0||t[t.length-1].outSize!==1;){let e=t.length?t[t.length-1].outSize:r[1],o=w.computeOptimalWindowSize(e);t.push({inSize:e,windowSize:o,outSize:Math.ceil(e/o)})}return t}function Yr(r,t,e,o){let n=p9(r.shape),s=r;for(let a=0;a6)throw Error(`Transpose for rank ${t} is not yet supported`);let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\",\"resRC.u\",\"resRC.v\"],o=new Array(t);for(let n=0;n6)throw Error(`Packed transpose for rank ${this.rank} is not yet supported.`);let n=Re(this.rank),s=lv(\"rc\",this.rank),a=new Array(this.rank);for(let c=0;c`Error in matMul: inner shapes (${l}) and (${m}) of Tensors with shapes ${r.shape} and ${t.shape} and transposeA=${e} and transposeB=${o} must match.`);let k=e?[x,l,d]:[x,d,l],_=o?[b,f,m]:[b,m,f],E=te({inputs:{x:r},backend:n,attrs:{shape:k}}),R=te({inputs:{x:t},backend:n,attrs:{shape:_}}),D=[E,R],P=Math.max(x,b),O=e?E.shape[1]:E.shape[2],M=s!=null,L=a!=null,B=p===\"leakyrelu\",z=p!=null?Ci(p,!0):null,U=M||L||B||z!=null,j;if((d===1||f===1)&&O>yv&&U===!1){let Y=E,J=R;e&&(Y=Ct({inputs:{x:E},backend:n,attrs:{perm:[0,2,1]}}),D.push(Y)),o&&(J=Ct({inputs:{x:R},backend:n,attrs:{perm:[0,2,1]}}),D.push(J));let re=f!==1,ne=f===1,ee=Y;re&&(ee=te({inputs:{x:Y},backend:n,attrs:{shape:[P,O,1]}}),D.push(ee));let oe=f===1?2:1,ie=J;ne&&(ie=te({inputs:{x:J},backend:n,attrs:{shape:[P,1,O]}}),D.push(ie));let le=tm({inputs:{a:ee,b:ie},backend:n});j=Tp({inputs:{x:le},backend:n,attrs:{axis:oe,keepDims:!0}}),D.push(le)}else{let Y=dt(r.dtype,t.dtype),J=new Uc(k,_,[P,d,f],e,o,M,z,L,B),re=[E,R];if(s!=null&&re.push(s),L&&re.push(a),B){let ne=n.makeTensorInfo([],\"float32\",y.createScalarValue(i,\"float32\"));re.push(ne),D.push(ne)}j=n.runWebGLProgram(J,re,Y)}let q=te({inputs:{x:j},backend:n,attrs:{shape:S}});D.push(j);for(let Y of D)n.disposeIntermediateTensorInfo(Y);return q}function l9(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s,bias:a,preluActivationWeights:i}=t,{transposeA:p,transposeB:u,activation:c,leakyreluAlpha:l}=o;return _p({a:n,b:s,transposeA:p,transposeB:u,backend:e,bias:a,preluActivationWeights:i,leakyreluAlpha:l,activation:c})}var XD={kernelName:Io,backendName:\"webgl\",kernelFunc:l9};var YD=\"return abs(x);\";function m9(r){let{inputs:t,backend:e}=r,{x:o}=t;if(e.shouldExecuteOnCPU([o])&&o.dtype!==\"complex64\"){let s=e.texData.get(o.dataId),a=ch(s.values);return e.makeTensorInfo(o.shape,o.dtype,a)}let n;return A().getBool(\"WEBGL_PACK_UNARY_OPERATIONS\")?n=new Fr(o.shape,YD):n=new or(o.shape,YD),e.runWebGLProgram(n,[o],o.dtype)}var QD={kernelName:Xs,backendName:\"webgl\",kernelFunc:m9};var d9=Ut+`\n if (abs(x) > 1.) {\n return NAN;\n }\n return acos(x);\n`,f9=xe({opSnippet:d9}),ZD={kernelName:Wo,backendName:\"webgl\",kernelFunc:f9};var h9=Ut+`\n if (x < 1.0) return NAN;\nreturn log(x + sqrt(x * x - 1.0));`,g9=xe({opSnippet:h9}),JD={kernelName:Uo,backendName:\"webgl\",kernelFunc:g9};var eA=\"return a + b;\",x9=nt({opSnippet:eA,packedOpSnippet:eA,supportsComplex:!0,cpuKernelImpl:RR}),tA={kernelName:uo,backendName:\"webgl\",kernelFunc:x9};var bh=class{constructor(t,e){this.outputShape=[],this.outputShape=t,this.variableNames=e.map((s,a)=>`T${a}`);let o=[];this.variableNames.forEach(s=>{o.push(`float v${s} = get${s}AtOutCoords();`)});let n=this.variableNames.map(s=>`v${s}`).join(\" + \");this.userCode=`\n void main() {\n ${o.join(`\n `)}\n\n float result = ${n};\n setOutput(result);\n }\n `}};var Ch=class{constructor(t,e){this.outputShape=[],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=t,this.variableNames=e.map((s,a)=>`T${a}`);let o=[];this.variableNames.forEach(s=>{o.push(`vec4 v${s} = get${s}AtOutCoords();`)});let n=this.variableNames.map(s=>`v${s}`).join(\" + \");this.userCode=`\n void main() {\n ${o.join(`\n `)}\n\n vec4 result = ${n};\n setOutput(result);\n }\n `}};function wh(r){let{inputs:t,backend:e}=r,o=t;if(o.length===1)return At({inputs:{x:o[0]},backend:e});if(o.length>A().getNumber(\"WEBGL_MAX_TEXTURES_IN_SHADER\")){let p=Math.floor(o.length/2),u=wh({inputs:o.slice(0,p),backend:e}),c=wh({inputs:o.slice(p),backend:e});return wh({inputs:[u,c],backend:e})}let n=o.map(p=>p.dtype).reduce((p,u)=>dt(p,u)),s=o.map(p=>p.shape),i=A().getBool(\"WEBGL_PACK\")?new Ch(o[0].shape,s):new bh(o[0].shape,s);return e.runWebGLProgram(i,o,n)}var rA={kernelName:Go,backendName:\"webgl\",kernelFunc:wh};function y9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=n.shape.length,p=y.parseAxisParam(s,n.shape),u=p,c=w.getAxesPermutation(u,i),l=n;c!=null&&(l=Ct({inputs:{x:n},backend:e,attrs:{perm:c}}),u=w.getInnerMostAxes(u.length,i)),w.assertAxesAreInnerMostDims(\"all\",u,i);let[m,d]=w.computeOutAndReduceShapes(l.shape,u),f=y.sizeFromShape(d),h=te({inputs:{x:l},backend:e,attrs:{shape:[-1,f]}}),g=Yr(h,h.dtype,\"all\",e),x;if(a){let b=w.expandShapeToKeepDim(m,p);x=te({inputs:{x:g},backend:e,attrs:{shape:b}})}else x=te({inputs:{x:g},backend:e,attrs:{shape:m}});return e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(g),c!=null&&e.disposeIntermediateTensorInfo(l),x}var oA={kernelName:Ho,backendName:\"webgl\",kernelFunc:y9};function b9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=n.shape.length,p=y.parseAxisParam(s,n.shape),u=p,c=w.getAxesPermutation(u,i),l=n;c!=null&&(l=Ct({inputs:{x:n},backend:e,attrs:{perm:c}}),u=w.getInnerMostAxes(u.length,i)),w.assertAxesAreInnerMostDims(\"any\",u,i);let[m,d]=w.computeOutAndReduceShapes(l.shape,u),f=y.sizeFromShape(d),h=te({inputs:{x:l},backend:e,attrs:{shape:[-1,f]}}),g=Yr(h,h.dtype,\"any\",e),x;if(a){let b=w.expandShapeToKeepDim(m,p);x=te({inputs:{x:g},backend:e,attrs:{shape:b}})}else x=te({inputs:{x:g},backend:e,attrs:{shape:m}});return e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(g),c!=null&&e.disposeIntermediateTensorInfo(l),x}var nA={kernelName:Ko,backendName:\"webgl\",kernelFunc:b9};var Sh=class{constructor(t,e,o){this.variableNames=[\"A\"];let{windowSize:n,batchSize:s,outSize:a}=t;o||this.variableNames.push(\"bestIndicesA\"),this.outputShape=[s,a];let i=e===\"max\"?\">\":\"<\",p=o?\"inOffset + i;\":\"round(getBestIndicesA(batch, inOffset + i));\";this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = outIdx * ${n};\n\n int bestIndex = inOffset;\n float bestValue = getA(batch, bestIndex);\n\n for (int i = 0; i < ${n}; i++) {\n int inIdx = ${p};\n float candidate = getA(batch, inIdx);\n if (candidate ${i} bestValue) {\n bestValue = candidate;\n bestIndex = inIdx;\n }\n }\n setOutput(float(bestIndex));\n }\n `}};var Ih=class{constructor(t,e,o,n){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,y.assert(t.length>2,()=>`Packed arg${o.charAt(0).toUpperCase()+o.slice(1)} supports only inputs with rank above 2.`);let s=t[t.length-1],a=Math.ceil(s/e);this.outputShape=t.slice(0,-1),a>1&&this.outputShape.push(a),n||this.variableNames.push(\"bestIndicesA\");let i=this.outputShape,p=i.length,u=Re(p),c=Dt(\"coords\",p),l,m;if(a===1){m=p+1;let R=Re(m);l=`\n ${R} sourceLocR = ${R}(${c.join()}, 0);\n ++${c[p-1]};\n ${R} sourceLocG = ${R}(${c.join()}, 0);\n ++${c[p-2]};\n ${R} sourceLocA = ${R}(${c.join()}, 0);\n --${c[p-1]};\n ${R} sourceLocB = ${R}(${c.join()}, 0);\n --${c[p-2]};`}else m=p,l=`\n ${u} sourceLocR = coords;\n ++${c[p-1]};\n ${u} sourceLocG = coords;\n ++${c[p-2]};\n ${u} sourceLocA = coords;\n --${c[p-1]};\n ${u} sourceLocB = coords;\n --${c[p-2]};`;let d=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"].slice(0,m),f=\".\"+d[m-1],h=d.map(R=>\"int \"+R),g=Dt(\"sourceLocR\",m-1).concat(\"inIdx.r\"),x=Dt(\"sourceLocG\",m-1).concat(\"inIdx.g\"),b=Dt(\"sourceLocB\",m-1).concat(\"inIdx.b\"),C=Dt(\"sourceLocA\",m-1).concat(\"inIdx.a\"),S=o===\"max\"?\"greaterThan\":\"lessThan\",k=n?\"\":`\n inIdx = round(vec4(getBestIndicesAChannel(${g.join()}),\n getBestIndicesAChannel(${x.join()}),\n getBestIndicesAChannel(${b.join()}),\n getBestIndicesAChannel(${C.join()})));`,_=`vec4(\n getAChannel(${g.join()}),\n hasNextCol ? getAChannel(${x.join()}) : 0.,\n hasNextRow ? getAChannel(${b.join()}) : 0.,\n hasNextRow && hasNextCol ? getAChannel(${C.join()}) : 0.)`,E=n?\"\":`\n float getBestIndicesAChannel(${h.join()}) {\n return getChannel(getBestIndicesA(${d.join()}),\n vec2(${d.slice(-2).join()}));\n }`;this.userCode=`\n float getAChannel(${h.join()}) {\n return getChannel(getA(${d.join()}),\n vec2(${d.slice(-2).join()}));\n }\n ${E}\n void main() {\n ${u} coords = getOutputCoords();\n bool hasNextCol = ${c[p-1]} < ${i[p-1]-1};\n bool hasNextRow = ${c[p-2]} < ${i[p-2]-1};\n ${l}\n ivec4 srcIdx = ivec4(sourceLocR${f}, sourceLocG${f},\n sourceLocB${f}, sourceLocA${f}) * ${e};\n ivec4 inIdx = srcIdx;\n vec4 bestIndex = vec4(inIdx);\n vec4 bestValue = ${_};\n\n for (int i = 0; i < ${e}; i++) {\n inIdx = srcIdx;\n ${k}\n vec4 candidate = ${_};\n bvec4 nan = isnan(candidate);\n bvec4 replace = bvec4(\n vec4(${S}(candidate, bestValue)) * (vec4(1.0) - vec4(nan)));\n\n bestValue = vec4(replace.x ? candidate.x : bestValue.x,\n replace.y ? candidate.y : bestValue.y,\n replace.z ? candidate.z : bestValue.z,\n replace.w ? candidate.w : bestValue.w);\n bestIndex = mix(bestIndex, vec4(inIdx), vec4(replace));\n srcIdx++;\n }\n setOutput(bestIndex);\n }\n `}};function sA(r,t,e,o=null){let n=t.shape[0],s=t.shape[1];o!=null&&(n=o.shape[0],s=o.shape[1]);let a=w.computeOptimalWindowSize(s),i={windowSize:a,inSize:s,batchSize:n,outSize:Math.ceil(s/a)},p=new Sh(i,e,o==null),u=[t];o!=null&&u.push(o);let c=r.runWebGLProgram(p,u,\"int32\");if(c.shape[1]===1)return c;let l=sA(r,t,e,c);return r.disposeIntermediateTensorInfo(c),l}function aA(r,t,e,o=null){let n=o!=null?o.shape:t.shape,s=n[n.length-1],a=w.computeOptimalWindowSize(s),i=new Ih(n,a,e,o==null),p=o==null?[t]:[t,o],u=r.runWebGLProgram(i,p,\"int32\");if(u.shape.length===t.shape.length){let c=aA(r,t,e,u);return r.disposeIntermediateTensorInfo(u),c}return u}function vh(r,t,e,o){let n=[e];if(w.assertAxesAreInnerMostDims(\"arg\"+o.charAt(0).toUpperCase()+o.slice(1),n,t.shape.length),!A().getBool(\"WEBGL_PACK_REDUCE\")||t.shape.length<=2){let s=[],a=r.texData.get(t.dataId),i=a!==null&&a.isPacked,p=t;i&&(p=r.unpackTensor(t),s.push(p));let[u,c]=w.computeOutAndReduceShapes(p.shape,n),l=y.sizeFromShape(c),m=te({inputs:{x:p},backend:r,attrs:{shape:[-1,l]}});s.push(m);let d=sA(r,m,o);s.push(d);let f=te({inputs:{x:d},backend:r,attrs:{shape:u}});return s.forEach(h=>r.disposeIntermediateTensorInfo(h)),f}return aA(r,t,o)}function C9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=Ct({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMax\",[a[0]],p.shape.length);let c=vh(e,p,a[0],\"max\");return u.forEach(l=>e.disposeIntermediateTensorInfo(l)),c}var iA={kernelName:Ys,backendName:\"webgl\",kernelFunc:C9};function w9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=Ct({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMin\",[a[0]],p.shape.length);let c=vh(e,p,a[0],\"min\");return u.forEach(l=>e.disposeIntermediateTensorInfo(l)),c}var uA={kernelName:Qs,backendName:\"webgl\",kernelFunc:w9};var S9=Ut+`\n if (abs(x) > 1.) {\n return NAN;\n }\n return asin(x);\n`,I9=xe({opSnippet:S9}),pA={kernelName:qo,backendName:\"webgl\",kernelFunc:I9};var v9=Ut+\"return log(x + sqrt(x * x + 1.0));\",k9=xe({opSnippet:v9}),cA={kernelName:jo,backendName:\"webgl\",kernelFunc:k9};var N9=Ut+`\n return atan(x);\n`,T9=xe({opSnippet:N9}),lA={kernelName:Xo,backendName:\"webgl\",kernelFunc:T9};var _9=Wc+`\n return atan(a, b);\n`,$9=`\n vec4 result = atan(a, b);\n bvec4 isNaNA = isnan(a);\n bvec4 isNaNB = isnan(b);\n bvec4 isNaN = bvec4(isNaNA.x || isNaNB.x, isNaNA.y || isNaNB.y, isNaNA.z || isNaNB.z, isNaNA.w || isNaNB.w);\n `+Xr+`\n return result;\n`,E9=nt({opSnippet:_9,packedOpSnippet:$9}),mA={kernelName:Qo,backendName:\"webgl\",kernelFunc:E9};var R9=Ut+`\n if ((x < -1.0) || (x > 1.0)) return NAN;\nreturn (log(1.0 + x) - log(1.0 - x)) / 2.0;`,D9=xe({opSnippet:R9}),dA={kernelName:Yo,backendName:\"webgl\",kernelFunc:D9};var Us=class{constructor(t,e,o,n=!1,s=!1){if(this.variableNames=[\"x\"],e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");let a=t.filterWidth,i=t.strideHeight,p=t.strideWidth,u=t.dilationHeight,c=t.dilationWidth,l=t.effectiveFilterHeight,m=t.effectiveFilterWidth,d=t.padInfo.top,f=t.padInfo.left;this.outputShape=t.outShape;let h=e===\"avg\",g=`((batch * ${t.inHeight} + xR) * ${t.inWidth} + xC) * ${t.inChannels} + d`,x=`(xR * ${t.inWidth} + xC) * ${t.inChannels} + d`,b=\"0.0\";if(h||(b=\"-1.0 / 1e-20\"),o){let R=\">=\";this.userCode=`\n const ivec2 strides = ivec2(${i}, ${p});\n const ivec2 pads = ivec2(${d}, ${f});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d = coords[3];\n\n ivec2 xRCCorner = coords.yz * strides - pads;\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // max/min x(?, ?, d) to get y(yR, yC, d).\n // ? = to be determined\n float minMaxValue = 0.0;\n float minMaxValueFound = 0.0;\n int minMaxPosition = 0;\n float avgValue = 0.0;\n\n for (int wR = 0; wR < ${l};\n wR += ${u}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${m};\n wC += ${c}) {\n int xC = xCCorner + wC;\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float value = getX(batch, xR, xC, d);\n\n // If a min / max value has already been found, use it. If not,\n // use the current value.\n float currMinMaxValue = mix(\n value, minMaxValue, minMaxValueFound);\n if (value ${R} currMinMaxValue) {\n minMaxValue = value;\n minMaxValueFound = 1.0;\n minMaxPosition = ${n?s?g:x:`wR * ${m} + wC`};\n }\n }\n }\n setOutput(float(minMaxPosition));\n }\n `;return}let C=\"max\",S=`${e}(${e}(${e}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;e===\"avg\"&&(S=\"avgValue / max(count, 1.0)\");let k=Math.floor(a/4)*4,_=a%4,E=`\n if (${h}) {\n avgValue += dot(values, ones);\n } else {\n minMaxValue = ${C}(values, minMaxValue);\n }\n `;this.userCode=`\n const ivec2 strides = ivec2(${i}, ${p});\n const ivec2 pads = ivec2(${d}, ${f});\n const float initializationValue = ${b};\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float count = 0.0;\n\n float getValue(int batch, int xR, int xC, int d) {\n if (xC < 0 || xC >= ${t.inWidth}) {\n return initializationValue;\n }\n count += 1.0;\n return getX(batch, xR, xC, d);\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d = coords[3];\n\n ivec2 xRCCorner = coords.yz * strides - pads;\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // max/min x(?, ?, d) to get y(yR, yC, d).\n // ? = to be determined\n vec4 minMaxValue = vec4(${b});\n float avgValue = 0.0;\n count = 0.0;\n\n for (int wR = 0; wR < ${l};\n wR += ${u}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${k}; wC += 4) {\n int xC = xCCorner + wC * ${c};\n\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n getValue(batch, xR, xC + ${c}, d),\n getValue(batch, xR, xC + 2 * ${c}, d),\n getValue(batch, xR, xC + 3 * ${c}, d)\n );\n\n ${E}\n }\n\n int xC = xCCorner + ${k};\n if (${_===1}) {\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n ${E}\n } else if (${_===2}) {\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n getValue(batch, xR, xC + ${c}, d),\n initializationValue,\n initializationValue\n );\n\n ${E}\n } else if (${_===3}) {\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n getValue(batch, xR, xC + ${c}, d),\n getValue(batch, xR, xC + 2 * ${c}, d),\n initializationValue\n );\n\n ${E}\n }\n }\n setOutput(${S});\n }\n `}},Iu=class{constructor(t,e,o,n=!1,s=!1){if(this.variableNames=[\"x\"],e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");let a=t.filterWidth,i=t.strideDepth,p=t.strideHeight,u=t.strideWidth,c=t.dilationDepth,l=t.dilationHeight,m=t.dilationWidth,d=t.effectiveFilterDepth,f=t.effectiveFilterHeight,h=t.effectiveFilterWidth,g=t.padInfo.front,x=t.padInfo.top,b=t.padInfo.left;this.outputShape=t.outShape;let C=e===\"avg\",S=\"0.0\";if(C||(S=\"-1.0 / 1e-20\"),o){let P=\">=\";this.userCode=`\n const ivec3 strides =\n ivec3(${i}, ${p}, ${u});\n const ivec3 pads = ivec3(${g}, ${x}, ${b});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 xCorner = ivec3(coords.y, coords.z, coords.w) * strides - pads;\n int xDCorner = xCorner.x;\n int xRCorner = xCorner.y;\n int xCCorner = xCorner.z;\n\n // max/min x(?, ?, ?, ch) to get y(yD, yR, yC, ch).\n // ? = to be determined\n float minMaxValue = 0.0;\n float minMaxValueFound = 0.0;\n int minMaxPosition = 0;\n\n for (int wD = 0; wD < ${d};\n wD += ${c}) {\n int xD = xDCorner + wD;\n\n if (xD < 0 || xD >= ${t.inDepth}) {\n continue;\n }\n\n for (int wR = 0; wR < ${f};\n wR += ${l}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${h};\n wC += ${m}) {\n int xC = xCCorner + wC;\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float value = getX(batch, xD, xR, xC, ch);\n\n // If a min / max value has already been found, use it. If not,\n // use the current value.\n float currMinMaxValue = mix(\n value, minMaxValue, minMaxValueFound);\n if (value ${P} currMinMaxValue) {\n minMaxValue = value;\n minMaxValueFound = 1.0;\n minMaxPosition = ${n?s?`(((batch * ${t.inDepth} + xD) * ${t.inHeight} + xR) * ${t.inWidth} + xC) * ${t.inChannels} + ch`:`((xD * ${t.inHeight} + xR) * ${t.inWidth} + xC) * ${t.inChannels} + ch`:`wD * ${f} * ${h} +\n wR * ${h} + wC`};\n }\n }\n }\n }\n setOutput(float(minMaxPosition));\n }\n `;return}let k=\"max\",_=`${e}(${e}(${e}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;e===\"avg\"&&(_=\"avgValue / max(count, 1.0)\");let E=Math.floor(a/4)*4,R=a%4,D=`\n if (${C}) {\n avgValue += dot(values, ones);\n } else {\n minMaxValue = ${k}(values, minMaxValue);\n }\n `;this.userCode=`\n const ivec3 strides =\n ivec3(${i}, ${p}, ${u});\n const ivec3 pads = ivec3(${g}, ${x}, ${b});\n const float initializationValue = ${S};\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float count = 0.0;\n\n float getValue(int batch, int xD, int xR, int xC, int ch) {\n if (xC < 0 || xC >= ${t.inWidth}) {\n return initializationValue;\n }\n count += 1.0;\n return getX(batch, xD, xR, xC, ch);\n }\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 xCorner = ivec3(coords.y, coords.z, coords.w) * strides - pads;\n int xDCorner = xCorner.x;\n int xRCorner = xCorner.y;\n int xCCorner = xCorner.z;\n\n // max/min x(?, ?, ?, d) to get y(yD, yR, yC, ch).\n // ? = to be determined\n vec4 minMaxValue = vec4(${S});\n float avgValue = 0.0;\n count = 0.0;\n\n for (int wD = 0; wD < ${d};\n wD += ${c}) {\n int xD = xDCorner + wD;\n\n if (xD < 0 || xD >= ${t.inDepth}) {\n continue;\n }\n\n for (int wR = 0; wR < ${f};\n wR += ${l}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${E}; wC += 4) {\n int xC = xCCorner + wC * ${m};\n\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n getValue(batch, xD, xR, xC + ${m}, ch),\n getValue(batch, xD, xR, xC + 2 * ${m}, ch),\n getValue(batch, xD, xR, xC + 3 * ${m}, ch)\n );\n\n ${D}\n }\n\n int xC = xCCorner + ${E};\n if (${R===1}) {\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n ${D}\n } else if (${R===2}) {\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n getValue(batch, xD, xR, xC + ${m}, ch),\n initializationValue,\n initializationValue\n );\n\n ${D}\n } else if (${R===3}) {\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n getValue(batch, xD, xR, xC + ${m}, ch),\n getValue(batch, xD, xR, xC + 2 * ${m}, ch),\n initializationValue\n );\n\n ${D}\n }\n }\n }\n setOutput(${_});\n }\n `}};function A9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t;Vs(n,\"avgPool\");let{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1;y.assert(w.eitherStridesOrDilationsAreOne(a,u),()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p);if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))return At({inputs:{x:n},backend:e});let l=new Us(c,\"avg\",!1);return e.runWebGLProgram(l,[n],\"float32\")}var fA={kernelName:Zo,backendName:\"webgl\",kernelFunc:A9};function F9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,p,u),m=new Iu(l,\"avg\",!1);return e.runWebGLProgram(m,[n],\"float32\")}var hA={kernelName:Zs,backendName:\"webgl\",kernelFunc:F9};var kh=class{constructor(t){this.variableNames=[\"dy\"],this.outputShape=t.inShape;let e=t.filterHeight,o=t.filterWidth,n=t.strideHeight,s=t.strideWidth,a=t.dilationHeight,i=t.dilationWidth,p=t.effectiveFilterHeight,u=t.effectiveFilterWidth,c=p-1-t.padInfo.top,l=u-1-t.padInfo.left,m=1/(e*o);this.userCode=`\n const ivec2 pads = ivec2(${c}, ${l});\n const float avgMultiplier = float(${m});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n\n ivec2 dyRCCorner = coords.yz - pads;\n int dyRCorner = dyRCCorner.x;\n int dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${p};\n wR += ${a}) {\n float dyR = float(dyRCorner + wR) / ${n}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${u};\n wC+= ${i}) {\n float dyC = float(dyCCorner + wC) / ${s}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(b, idyR, idyC, d);\n\n dotProd += dyValue * avgMultiplier;\n }\n }\n setOutput(dotProd);\n }\n `}},Nh=class{constructor(t){this.variableNames=[\"dy\"],this.outputShape=t.inShape;let e=t.filterDepth,o=t.filterHeight,n=t.filterWidth,s=t.strideDepth,a=t.strideHeight,i=t.strideWidth,p=t.dilationDepth,u=t.dilationHeight,c=t.dilationWidth,l=t.effectiveFilterDepth,m=t.effectiveFilterHeight,d=t.effectiveFilterWidth,f=l-1-t.padInfo.front,h=m-1-t.padInfo.top,g=d-1-t.padInfo.left,x=1/(e*o*n);this.userCode=`\n const ivec3 pads = ivec3(${f}, ${h}, ${g});\n const float avgMultiplier = float(${x});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 dyCorner = ivec3(coords.y, coords.z, coords.w) - pads;\n int dyDCorner = dyCorner.x;\n int dyRCorner = dyCorner.y;\n int dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, d) with pos mask(:, :, :, ch) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n\n for (int wD = 0; wD < ${l};\n wD += ${p}) {\n float dyD = float(dyDCorner + wD) / ${s}.0;\n\n if (dyD < 0.0 || dyD >= ${t.outDepth}.0 || fract(dyD) > 0.0) {\n continue;\n }\n int idyD = int(dyD);\n\n for (int wR = 0; wR < ${m};\n wR += ${u}) {\n float dyR = float(dyRCorner + wR) / ${a}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 ||\n fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${d};\n wC += ${c}) {\n float dyC = float(dyCCorner + wC) / ${i}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(batch, idyD, idyR, idyC, ch);\n\n dotProd += dyValue * avgMultiplier;\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function P9(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=[1,1,1],m=w.computePool3DInfo(a.shape,i,p,l,u,c),d=new Nh(m);return e.runWebGLProgram(d,[n],a.dtype)}var gA={kernelName:Ai,backendName:\"webgl\",kernelFunc:P9};function O9(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s;Vs([n,s],\"avgPoolGrad\");let{filterSize:i,strides:p,pad:u}=o,c=w.computePool2DInfo(a.shape,i,p,1,u),l=new kh(c);return e.runWebGLProgram(l,[n],a.dtype)}var xA={kernelName:Di,backendName:\"webgl\",kernelFunc:O9};function M9(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;return _p({a:n,b:s,transposeA:a,transposeB:i,backend:e})}var yA={kernelName:Jo,backendName:\"webgl\",kernelFunc:M9};var Th=class{constructor(t,e,o,n,s,a){this.outputShape=[],this.variableNames=[\"x\",\"mean\",\"variance\"],w.assertAndGetBroadcastShape(t,e),w.assertAndGetBroadcastShape(t,o);let i=\"0.0\";n!=null&&(w.assertAndGetBroadcastShape(t,n),this.variableNames.push(\"offset\"),i=\"getOffsetAtOutCoords()\");let p=\"1.0\";s!=null&&(w.assertAndGetBroadcastShape(t,s),this.variableNames.push(\"scale\"),p=\"getScaleAtOutCoords()\"),this.outputShape=t,this.userCode=`\n void main() {\n float x = getXAtOutCoords();\n float mean = getMeanAtOutCoords();\n float variance = getVarianceAtOutCoords();\n float offset = ${i};\n float scale = ${p};\n float inv = scale * inversesqrt(variance + float(${a}));\n setOutput(dot(vec3(x, -mean, offset), vec3(inv, inv, 1)));\n }\n `}};var _h=class{constructor(t,e,o,n,s,a){this.packedInputs=!0,this.packedOutput=!0,this.variableNames=[\"x\",\"mean\",\"variance\"],w.assertAndGetBroadcastShape(t,e),w.assertAndGetBroadcastShape(t,o);let i=\"vec4(0.0)\";n!=null&&(w.assertAndGetBroadcastShape(t,n),this.variableNames.push(\"offset\"),i=\"getOffsetAtOutCoords()\");let p=\"vec4(1.0)\";s!=null&&(w.assertAndGetBroadcastShape(t,s),this.variableNames.push(\"scale\"),p=\"getScaleAtOutCoords()\"),this.outputShape=t,this.userCode=`\n void main() {\n vec4 offset = ${i};\n vec4 scale = ${p};\n\n vec4 x = getXAtOutCoords();\n vec4 mean = getMeanAtOutCoords();\n vec4 variance = getVarianceAtOutCoords();\n\n vec4 inv = scale * inversesqrt(variance + vec4(${a}));\n\n setOutput((x - mean) * inv + offset);\n }\n `}};var L9=({inputs:r,backend:t,attrs:e})=>{let{x:o,mean:n,variance:s,offset:a,scale:i}=r;y.assert(n.shape.length===s.shape.length,()=>\"Batch normalization gradient requires mean and variance to have equal ranks.\"),y.assert(a==null||n.shape.length===a.shape.length,()=>\"Batch normalization gradient requires mean and offset to have equal ranks.\"),y.assert(i==null||n.shape.length===i.shape.length,()=>\"Batch normalization gradient requires mean and scale to have equal ranks.\");let{varianceEpsilon:p}=e;p==null&&(p=.001);let u=[o,n,s],c=null;a!=null&&(c=a.shape,u.push(a));let l=null;i!=null&&(l=i.shape,u.push(i));let m=A().getBool(\"WEBGL_PACK_NORMALIZATION\")?new _h(o.shape,n.shape,s.shape,c,l,p):new Th(o.shape,n.shape,s.shape,c,l,p);return t.runWebGLProgram(m,u,u[0].dtype)},bA={kernelName:vn,backendName:\"webgl\",kernelFunc:L9};var $h=class{constructor(t){this.variableNames=[\"source\"],this.outputShape=t,this.rank=t.length;let e=Re(this.rank);this.customUniforms=[{name:\"start\",arrayIndex:this.rank,type:\"int\"}];let o=B9(this.rank),n,s=t.map((a,i)=>`sourceLoc.${bv[i]} = start[${i}] + coords.${bv[i]};`);n=`\n ${e} sourceLoc;\n ${e} coords = getOutputCoords();\n ${s.join(`\n`)}\n `,this.userCode=`\n void main() {\n ${n}\n setOutput(getSource(${o}));\n }\n `}},bv=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"];function B9(r){if(r===1)return\"sourceLoc\";if(r<=6)return bv.slice(0,r).map(t=>\"sourceLoc.\"+t).join(\",\");throw Error(`Slicing for rank ${r} is not yet supported`)}var Eh=class{constructor(t){this.variableNames=[\"source\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=t,this.rank=t.length,this.customUniforms=[{name:\"start\",arrayIndex:this.rank,type:\"int\"}];let e=Re(this.rank),o=Dt(\"coords\",this.rank),n=Dt(\"sourceLoc\",this.rank),s=this.rank===1?\"sourceLoc\":`vec2(${n.slice(-2).join()})`,a=`getChannel(getSource(${n.join()}), ${s})`,i=`\n result.x = ${a};\n if (++${o[this.rank-1]} < ${t[this.rank-1]}) {\n ++${n[this.rank-1]};\n result.y = ${a};\n --${n[this.rank-1]};\n }\n `,p=this.rank===1?\"\":`\n --${o[this.rank-1]};\n if (++${o[this.rank-2]} < ${t[this.rank-2]}) {\n ++${n[this.rank-2]};\n result.z = ${a};\n if (++${o[this.rank-1]} < ${t[this.rank-1]}) {\n ++${n[this.rank-1]};\n result.w = ${a};\n }\n }\n `,u=this.rank<=4?`sourceLoc = coords +\n ${e}(${t.map((c,l)=>`start[${l}]`).join()});`:t.map((c,l)=>`${n[l]} = ${o[l]} + start[${l}];`).join(`\n`);this.userCode=`\n void main() {\n ${e} coords = getOutputCoords();\n ${e} sourceLoc;\n ${u}\n vec4 result = vec4(0.);\n ${i}\n ${p}\n setOutput(result);\n }\n `}};function z9(r,t,e,o){let n=o.texData.get(r.dataId),s=o.makeTensorInfo(e,r.dtype),a=o.texData.get(s.dataId);Object.assign(a,n),a.refCount=1,a.shape=e,a.dtype=r.dtype;let i=ct.computeFlatOffset(t,y.computeStrides(r.shape));n.slice&&(i+=n.slice.flatOffset),a.slice={flatOffset:i,origDataId:n.slice&&n.slice.origDataId||r.dataId};let p=o.dataRefCount.get(a.slice.origDataId)||1;return o.dataRefCount.set(a.slice.origDataId,p+1),s}function Gs(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,size:a}=o,[i,p]=ct.parseSliceParams(n,s,a);if(ct.assertParamsValid(n,i,p),y.sizeFromShape(p)===0)return e.makeTensorInfo(p,n.dtype,[]);if(e.shouldExecuteOnCPU([n])||n.dtype===\"string\"){let l=e.texData.get(n.dataId),m=pD(l.values,i,p,n.shape,n.dtype);return e.makeTensorInfo(p,n.dtype,m)}let{isPacked:u}=e.texData.get(n.dataId),c=ct.isSliceContinous(n.shape,i,p);if(u||!c){let l=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new Eh(p):new $h(p),m=[i];return e.runWebGLProgram(l,[n],n.dtype,m)}return e.uploadToGPU(n.dataId),z9(n,i,p,e)}var CA={kernelName:ha,backendName:\"webgl\",kernelFunc:Gs};var V9=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,crops:a}=o;y.assert(n.shape.length<=4,()=>\"batchToSpaceND for rank > 4 with a WebGL backend not implemented yet\");let i=s.reduce((b,C)=>b*C),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=[],f=te({inputs:{x:n},backend:e,attrs:{shape:p}}),h=Ct({inputs:{x:f},backend:e,attrs:{perm:u}}),g=te({inputs:{x:h},backend:e,attrs:{shape:c}}),x=Gs({inputs:{x:g},backend:e,attrs:{begin:l,size:m}});return d.push(f),d.push(h),d.push(g),d.forEach(b=>e.disposeIntermediateTensorInfo(b)),x},wA={kernelName:Js,backendName:\"webgl\",kernelFunc:V9};function W9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a}=o,i=e.readSync(n.dataId),p=e.readSync(s.dataId),u=ph(i,p,s.dtype,s.shape,a);return e.makeTensorInfo([a],s.dtype,u)}var SA={kernelName:en,backendName:\"webgl\",kernelFunc:W9};var U9=`\n int r = int(a.r) & int(b.r);\n int g = int(a.g) & int(b.g);\n int rb = int(a.b) & int(b.b);\n int ra = int(a.a) & int(b.a);\n return vec4(r, g, rb, ra);\n`,G9=`\n return float(int(a.r) & int(b.r));\n`;function H9(r){let{inputs:t,backend:e}=r,{a:o,b:n}=t,s=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\"),a=A().getNumber(\"WEBGL_VERSION\");if(e.shouldExecuteOnCPU([o,n])||a===1){let p=e.texData.get(o.dataId).values,u=e.texData.get(n.dataId).values,[c,l]=AR(o.shape,n.shape,p,u,o.dtype),m=e.makeTensorInfo(l,o.dtype),d=e.texData.get(m.dataId);return d.values=c,m}let i;return s?i=new jr(U9,o.shape,n.shape,!1):i=new Pr(G9,o.shape,n.shape),e.runWebGLProgram(i,[o,n],o.dtype)}var IA={kernelName:ja,backendName:\"webgl\",kernelFunc:H9};function K9(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t,s=e.readSync(o.dataId),a=e.readSync(n.dataId),i=w.assertAndGetBroadcastShape(Array.from(s),Array.from(a));return e.makeTensorInfo([i.length],\"int32\",Int32Array.from(i))}var vA={kernelName:ea,backendName:\"webgl\",kernelFunc:K9};var q9=\"return float(a != b);\",Cv=nt({opSnippet:q9,cpuKernelImpl:eD,dtype:\"bool\"}),kA={kernelName:Qn,backendName:\"webgl\",kernelFunc:Cv};function wi(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.texData.get(o.dataId);return At({inputs:{x:n.complexTensorInfos.real},backend:e})}var NA={kernelName:qi,backendName:\"webgl\",kernelFunc:wi};var j9=\"return float(int(x));\";function TA(r,t){let e=new or(r.shape,j9),o=t.runWebGLProgram(e,[r],\"int32\");return{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}function wv(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dtype:s}=o;if(s===\"complex64\"){if(n.dtype===\"complex64\")return At({inputs:{x:n},backend:e});let a=Gr(n.shape),i=wv({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}}),p=Or({inputs:{real:i,imag:a},backend:e});return a.dispose(),e.disposeIntermediateTensorInfo(i),p}if(n.dtype===\"complex64\"){let a=wi({inputs:{input:n},backend:e}),i=wv({inputs:{x:a},backend:e,attrs:{dtype:s}});return e.disposeIntermediateTensorInfo(a),i}if(!y.hasEncodingLoss(n.dtype,s)){let a=At({inputs:{x:n},backend:e});return{dataId:a.dataId,shape:a.shape,dtype:s}}if(e.shouldExecuteOnCPU([n])){let a=e.texData.get(n.dataId).values,[i,p,u]=FR(a,n.shape,n.dtype,s);return e.makeTensorInfo(i,p,u)}if(s===\"int32\")return TA(n,e);if(s===\"bool\"){let a=e.makeTensorInfo([],\"bool\",y.getTypedArrayFromDType(\"bool\",1)),p=Cv({inputs:{a:n,b:a},backend:e});return e.disposeIntermediateTensorInfo(a),p}throw new Error(`Error in Cast: failed to cast ${n.dtype} to ${s}`)}var _A={kernelName:bo,backendName:\"webgl\",kernelFunc:wv};var $A=\"return ceil(x);\",X9=xe({opSnippet:$A,packedOpSnippet:$A,cpuKernelImpl:PR}),EA={kernelName:tn,backendName:\"webgl\",kernelFunc:X9};var Rh=class{constructor(t){this.variableNames=[\"A\"],this.customUniforms=[{name:\"minVal\",type:\"float\"},{name:\"maxVal\",type:\"float\"}],this.outputShape=t,this.userCode=`\n\n void main() {\n float value = getAAtOutCoords();\n if (isnan(value)) {\n setOutput(value);\n return;\n }\n\n setOutput(clamp(value, minVal, maxVal));\n }\n `}};var Dh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"minVal\",type:\"float\"},{name:\"maxVal\",type:\"float\"}],this.outputShape=t,this.userCode=`\n void main() {\n vec4 value = getAAtOutCoords();\n\n if (any(isnan(value))) {\n setOutput(value);\n return;\n }\n\n setOutput(clamp(value, vec4(minVal), vec4(maxVal)));\n }\n `}};function Y9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{clipValueMin:s,clipValueMax:a}=o,i;A().getBool(\"WEBGL_PACK_CLIP\")?i=new Dh(n.shape):i=new Rh(n.shape);let p=[[s],[a]];return e.runWebGLProgram(i,[n],n.dtype,p)}var RA={kernelName:Co,backendName:\"webgl\",kernelFunc:Y9};var Ah=class{constructor(t){this.variableNames=[\"real\",\"imag\"],this.outputShape=t,this.userCode=`\n void main() {\n float re = abs(getRealAtOutCoords());\n float im = abs(getImagAtOutCoords());\n float mx = max(re, im);\n\n // sadly the length function in glsl is not underflow-safe\n // (at least not on Intel GPUs). So the safe solution is\n // to ensure underflow-safety in all cases.\n setOutput(\n mx == 0.0 ? 0.0 : mx * length(vec2(1, min(re, im)/mx))\n );\n }\n `}};function DA(r,t){return{dataId:t.dataId,dtype:t.dtype,shape:r.shape}}function Q9(r){let{inputs:t,backend:e}=r,{x:o}=t,n=e.texData.get(o.dataId),s=new Ah(o.shape),a=[DA(o,n.complexTensorInfos.real),DA(o,n.complexTensorInfos.imag)];return e.runWebGLProgram(s,a,a[0].dtype)}var AA={kernelName:Pi,backendName:\"webgl\",kernelFunc:Q9};var Fh=class{constructor(t){this.outputShape=[],this.outputShape=w.computeOutShape(t,1),this.variableNames=t.map((a,i)=>`T${i}`);let e=new Array(t.length-1);e[0]=t[0][1];for(let a=1;a`T${g}`);let p=new Array(t.length-1);p[0]=t[0][e];for(let h=1;h= ${p[h-1]}) {\n return getChannel(\n getT${h}(${Ph(i,u,g)}),\n vec2(${Ph(c,u,g)}));\n }`}let d=p.length,f=p[p.length-1];m+=`\n return getChannel(\n getT${d}(${Ph(i,u,f)}),\n vec2(${Ph(c,u,f)}));`,this.userCode=`\n float getValue(${i.map(h=>\"int \"+h)}) {\n ${m}\n }\n\n void main() {\n ${s} coords = getOutputCoords();\n vec4 result = vec4(getValue(${a}), 0., 0., 0.);\n\n ${a[n-1]} = ${a[n-1]} + 1;\n if (${a[n-1]} < ${o[n-1]}) {\n result.g = getValue(${a});\n }\n\n ${a[n-2]} = ${a[n-2]} + 1;\n if (${a[n-2]} < ${o[n-2]}) {\n result.a = getValue(${a});\n }\n\n ${a[n-1]} = ${a[n-1]} - 1;\n if (${a[n-2]} < ${o[n-2]} &&\n ${a[n-1]} < ${o[n-1]}) {\n result.b = getValue(${a});\n }\n setOutput(result);\n }\n `}};function Ph(r,t,e){let o=r.indexOf(t);return r.map((s,a)=>a===o?`${s} - ${e}`:s).join()}function $p(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.texData.get(o.dataId);return At({inputs:{x:n.complexTensorInfos.imag},backend:e})}var FA={kernelName:Gi,backendName:\"webgl\",kernelFunc:$p};function Gc(r,t,e){let o=r[0].dtype;if(o===\"complex64\"){let d=r.map(b=>wi({inputs:{input:b},backend:e})),f=r.map(b=>$p({inputs:{input:b},backend:e})),h=Gc(d,t,e),g=Gc(f,t,e),x=Or({inputs:{real:h,imag:g},backend:e});return d.forEach(b=>e.disposeIntermediateTensorInfo(b)),f.forEach(b=>e.disposeIntermediateTensorInfo(b)),e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(g),x}let n=e.shouldExecuteOnCPU(r);if(o===\"string\"&&(n=!0),n){let d=r.map(S=>{let _=[-1,y.sizeFromShape(S.shape.slice(t))];return te({inputs:{x:S},backend:e,attrs:{shape:_}})}),f=d.map(S=>({vals:e.readSync(S.dataId),shape:S.shape})),h=w.computeOutShape(d.map(S=>S.shape),1),g=d[0].shape[0]===1,x=OR(f,h,o,g),b=w.computeOutShape(r.map(S=>S.shape),t),C=e.makeTensorInfo(b,o,x);return d.forEach(S=>e.disposeIntermediateTensorInfo(S)),C}let s=r.filter(d=>y.sizeFromShape(d.shape)>0),a=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")&&s[0].shape.length>1;if(s.length===1){let d=a?new or(r[0].shape,Ba):new Fr(r[0].shape,Ba);return e.runWebGLProgram(d,r,o)}let i=A().getNumber(\"WEBGL_MAX_TEXTURES_IN_SHADER\");if(s.length>i){let d=[];for(let h=0;hf.shape),t);return e.runWebGLProgram(d,s,o)}let{tensors2D:p,outShape:u}=Z9(s,t,e),c=new Fh(p.map(d=>d.shape)),l=e.runWebGLProgram(c,p,o);p.forEach(d=>e.disposeIntermediateTensorInfo(d));let m=te({inputs:{x:l},attrs:{shape:u},backend:e});return e.disposeIntermediateTensorInfo(l),m}function Z9(r,t,e){let o=w.computeOutShape(r.map(s=>s.shape),t);return{tensors2D:r.map(s=>te({inputs:{x:s},attrs:{shape:[-1,y.sizeFromShape(s.shape.slice(t))]},backend:e})),outShape:o}}function Sv(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o,s=y.parseAxisParam(n,t[0].shape)[0],a=t.map(u=>u.shape);w.assertParamsConsistent(a,s);let i=w.computeOutShape(t.map(u=>u.shape),s);if(y.sizeFromShape(i)===0)return e.makeTensorInfo(i,t[0].dtype,[]);let p=t.filter(u=>y.sizeFromShape(u.shape)>0);return p.length===1?At({inputs:{x:p[0]},backend:e}):Gc(p,s,e)}var PA={kernelName:ta,backendName:\"webgl\",kernelFunc:Sv};var Hc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.outputShape=t.outShape;let a=t.padInfo.top,i=t.padInfo.left,p=t.strideHeight,u=t.strideWidth,c=t.dilationHeight,l=t.dilationWidth,m=t.filterHeight,d=t.filterWidth,f=Math.floor(t.inChannels/4)*4,h=t.inChannels%4,g=t.dataFormat===\"channelsLast\",x=g?1:2,b=g?2:3,C=g?3:1,S=\"\",k=\"\";o&&(n?S=`float activation(float a) {\n float b = getPreluActivationWeightsAtOutCoords();\n ${o}\n }`:s?S=`float activation(float a) {\n float b = getLeakyreluAlphaAtOutCoords();\n ${o}\n }`:S=`\n float activation(float x) {\n ${o}\n }\n `,k=\"result = activation(result);\");let _=e?\"result += getBiasAtOutCoords();\":\"\";e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),s&&this.variableNames.push(\"leakyreluAlpha\"),this.userCode=`\n ${S}\n\n const ivec2 strides = ivec2(${p}, ${u});\n const ivec2 pads = ivec2(${a}, ${i});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d2 = coords[${C}];\n\n ivec2 xRCCorner =\n ivec2(coords[${x}], coords[${b}]) * strides - pads;\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // Convolve x(?, ?, d1) with w(:, :, d1, d2) to get y(yR, yC, d2).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${m}; wR++) {\n int xR = xRCorner + wR * ${c};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${d}; wC++) {\n int xC = xCCorner + wC * ${l};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n for (int d1 = 0; d1 < ${f}; d1 += 4) {\n vec4 wValues = vec4(\n getW(wR, wC, d1, d2),\n getW(wR, wC, d1 + 1, d2),\n getW(wR, wC, d1 + 2, d2),\n getW(wR, wC, d1 + 3, d2)\n );\n\n if (${g}) {\n vec4 xValues = vec4(\n getX(batch, xR, xC, d1),\n getX(batch, xR, xC, d1 + 1),\n getX(batch, xR, xC, d1 + 2),\n getX(batch, xR, xC, d1 + 3)\n );\n dotProd += dot(xValues, wValues);\n } else {\n vec4 xValues = vec4(\n getX(batch, d1, xR, xC),\n getX(batch, d1 + 1, xR, xC),\n getX(batch, d1 + 2, xR, xC),\n getX(batch, d1 + 3, xR, xC)\n );\n dotProd += dot(xValues, wValues);\n }\n }\n\n if (${h===1}) {\n\n if (${g}) {\n dotProd +=\n getX(batch, xR, xC, ${f}) *\n getW(wR, wC, ${f}, d2);\n } else {\n dotProd +=\n getX(batch, ${f}, xR, xC) *\n getW(wR, wC, ${f}, d2);\n }\n\n } else if (${h===2}) {\n vec2 wValues = vec2(\n getW(wR, wC, ${f}, d2),\n getW(wR, wC, ${f} + 1, d2)\n );\n\n if (${g}) {\n vec2 xValues = vec2(\n getX(batch, xR, xC, ${f}),\n getX(batch, xR, xC, ${f} + 1)\n );\n dotProd += dot(xValues, wValues);\n } else {\n vec2 xValues = vec2(\n getX(batch, ${f}, xR, xC),\n getX(batch, ${f} + 1, xR, xC)\n );\n dotProd += dot(xValues, wValues);\n }\n\n } else if (${h===3}) {\n vec3 wValues = vec3(\n getW(wR, wC, ${f}, d2),\n getW(wR, wC, ${f} + 1, d2),\n getW(wR, wC, ${f} + 2, d2)\n );\n\n if (${g}) {\n vec3 xValues = vec3(\n getX(batch, xR, xC, ${f}),\n getX(batch, xR, xC, ${f} + 1),\n getX(batch, xR, xC, ${f} + 2)\n );\n dotProd += dot(xValues, wValues);\n } else {\n vec3 xValues = vec3(\n getX(batch, ${f}, xR, xC),\n getX(batch, ${f} + 1, xR, xC),\n getX(batch, ${f} + 2, xR, xC)\n );\n dotProd += dot(xValues, wValues);\n }\n\n }\n }\n }\n\n float result = dotProd;\n ${_}\n ${k}\n setOutput(result);\n }\n `}},Mh=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.outputShape=t.outShape;let e=t.padInfo.front,o=t.padInfo.top,n=t.padInfo.left,s=t.strideDepth,a=t.strideHeight,i=t.strideWidth,p=t.dilationDepth,u=t.dilationHeight,c=t.dilationWidth,l=t.filterDepth,m=t.filterHeight,d=t.filterWidth,f=Math.floor(t.inChannels/4)*4,h=t.inChannels%4;this.userCode=`\n const ivec3 strides = ivec3(${s}, ${a}, ${i});\n const ivec3 pads = ivec3(${e}, ${o}, ${n});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int d2 = coords.u;\n\n ivec3 xFRCCorner = ivec3(coords.y, coords.z, coords.w) * strides - pads;\n int xFCorner = xFRCCorner.x;\n int xRCorner = xFRCCorner.y;\n int xCCorner = xFRCCorner.z;\n\n // Convolve x(?, ?, ?, d1) with w(:, :, :, d1, d2) to get\n // y(yF, yR, yC, d2). ? = to be determined. : = across all\n // values in that axis.\n float dotProd = 0.0;\n for (int wF = 0; wF < ${l}; wF++) {\n int xF = xFCorner + wF * ${p};\n\n if (xF < 0 || xF >= ${t.inDepth}) {\n continue;\n }\n\n for (int wR = 0; wR < ${m}; wR++) {\n int xR = xRCorner + wR * ${u};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${d}; wC++) {\n int xC = xCCorner + wC * ${c};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n for (int d1 = 0; d1 < ${f}; d1 += 4) {\n vec4 xValues = vec4(\n getX(batch, xF, xR, xC, d1),\n getX(batch, xF, xR, xC, d1 + 1),\n getX(batch, xF, xR, xC, d1 + 2),\n getX(batch, xF, xR, xC, d1 + 3)\n );\n vec4 wValues = vec4(\n getW(wF, wR, wC, d1, d2),\n getW(wF, wR, wC, d1 + 1, d2),\n getW(wF, wR, wC, d1 + 2, d2),\n getW(wF, wR, wC, d1 + 3, d2)\n );\n\n dotProd += dot(xValues, wValues);\n }\n\n if (${h===1}) {\n dotProd +=\n getX(batch, xF, xR, xC, ${f}) *\n getW(wF, wR, wC, ${f}, d2);\n } else if (${h===2}) {\n vec2 xValues = vec2(\n getX(batch, xF, xR, xC, ${f}),\n getX(batch, xF, xR, xC, ${f} + 1)\n );\n vec2 wValues = vec2(\n getW(wF, wR, wC, ${f}, d2),\n getW(wF, wR, wC, ${f} + 1, d2)\n );\n dotProd += dot(xValues, wValues);\n } else if (${h===3}) {\n vec3 xValues = vec3(\n getX(batch, xF, xR, xC, ${f}),\n getX(batch, xF, xR, xC, ${f} + 1),\n getX(batch, xF, xR, xC, ${f} + 2)\n );\n vec3 wValues = vec3(\n getW(wF, wR, wC, ${f}, d2),\n getW(wF, wR, wC, ${f} + 1, d2),\n getW(wF, wR, wC, ${f} + 2, d2)\n );\n dotProd += dot(xValues, wValues);\n }\n }\n }\n }\n setOutput(dotProd);\n }\n `}};var Kc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"pads\",type:\"ivec2\"},{name:\"strides\",type:\"ivec2\"},{name:\"dilations\",type:\"ivec2\"},{name:\"inDims\",type:\"ivec2\"}],this.outputShape=t.outShape,this.enableShapeUniforms=pt(this.outputShape.length);let a=t.padInfo.left,i=t.strideWidth,p=t.dilationWidth,u=t.filterHeight,c=t.filterWidth,l=c,m=`\n int xR; int xC; int xCOffset;\n vec4 wTexel; vec4 previous; vec4 final;`;for(let g=0;g=0 && xR < inDims[0]) {\n `;for(let g=0;g<(l+1)/2;g++){let x=g*2;if(m+=`\n xC = xCCorner + ${x*p};\n `,i===1){if(x= 0 && xCOffset < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n `,p===1&&x>0?m+=`\n xC${x} = vec4(xTexelC${x-2}.zw, xTexelC${x}.xy);\n `:m+=`\n xCOffset = xC + 1 - 2;\n\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n previous.zw = vec2(0.0);\n }\n\n xC${x} = vec4(previous.zw, xTexelC${x}.xy);\n } else {\n xC${x} = vec4(0.0, 0.0, xTexelC${x}.xy);\n }\n `):m+=`\n if (xC >= 0 && xC < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n\n xC${x} = xTexelC${x};\n `,x+1= 0 && xCOffset < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.0);\n }\n xTexelC${x+1}Ready = 1;\n }\n `,p>1?m+=`\n xCOffset -= 2;\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n xC${x+1} = vec4(previous.zw, xTexelC${x+1}.xy);\n } else {\n xC${x+1} = vec4(0.0, 0.0, xTexelC${x+1}.xy);\n }\n `:m+=`\n xC${x+1} = vec4(xTexelC${x}.zw, xTexelC${x+1}.xy);\n `):b===1?m+=`\n xC${x+1} = xTexelC${x};\n `:m+=`\n xCOffset = xC + ${b};\n\n if (xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.0);\n }\n xTexelC${x+1}Ready = 1;\n }\n\n xC${x+1} = xTexelC${x+1};\n `}}else x= 0 && xCOffset < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xCOffset, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n\n if(xC + 1 >= 0 && xC + 1 < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xC + 1, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xC + 2 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.0);\n }\n xTexelC${x+1}Ready = 1;\n }\n\n xC${x} = vec4(xTexelC${x}.zw, xTexelC${x+1}.zw);\n `,x+1= 0 && xCOffset < inDims[1]) {\n final = getX(batch, xR, xCOffset, d1);\n }\n xC${x+1} = vec4(xTexelC${x+1}.xy, final.xy);\n `)):(m+=`\n if(xC >= 0 && xC < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n\n xCOffset = xC + strides[1];\n if(xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.);\n }\n xTexelC${x+1}Ready = 1;\n }\n\n xC${x} = vec4(\n xTexelC${x}.xy, xTexelC${x+1}.xy);\n `,x+1= 0) {\n // Use custom imod instead mod. On Intel GPU, mod may generate\n // unexpected value.\n // https://github.com/tensorflow/tfjs/issues/5447\n offsetX = imod(blockIndex, outWidth) * stride[1] - pad[1];\n d1 = offsetX + dilation[1] * (imod(pos, itemsPerBlockRow) /\n inChannels);\n\n if(d1 < inputShape[${i}] && d1 >= 0) {\n\n ch = imod(pos, inChannels);\n\n if (${s}) {\n innerDims = vec2(d1, ch);\n result[${c*2+l}] = getChannel(\n getA(rc.x, d0, int(innerDims.x),\n int(innerDims.y)), innerDims);\n } else {\n innerDims = vec2(d0, d1);\n result[${c*2+l}] = getChannel(\n getA(rc.x, ch, int(innerDims.x),\n int(innerDims.y)), innerDims);\n }\n }\n }\n }\n `;this.userCode=`\n void main() {\n ivec3 rc = getOutputCoords();\n\n vec4 result = vec4(0);\n\n int blockIndex, pos, offsetY, d0, offsetX, d1, ch;\n vec2 innerDims;\n\n ${u}\n\n ${n.output} = result;\n }\n `}};function Bh(r,t){let e=r.length;return e>=3?t?[...r.slice(0,-3),r[e-3]*r[e-2],r[e-1]]:[...r.slice(0,-3),r[e-3],r[e-2]*r[e-1]]:!t&&e===1&&r[0]>1?[r[0],1]:null}function zh({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let p=r.shape,u=o.texData.get(r.dataId),c=e.inChannels,l=p[0]*p[1]*p[2],m=e.outChannels,d=e.dataFormat===\"channelsLast\",f=!1,h=!1,g,x=[];if(s!=null){let S=Bh(s.shape,d);S!=null&&(s=te({inputs:{x:s},backend:o,attrs:{shape:S}}),x.push(s))}if(n!=null){let S=Bh(n.shape,d);S!=null&&(n=te({inputs:{x:n},backend:o,attrs:{shape:S}}),x.push(n))}if(!((l===1||m===1)&&c>yv)&&u.isPacked&&d&&u.texture!=null&&p[2]%2!==0&&y.arraysEqual(u.shape.slice(-3),p.slice(-3))){let S=p[0]*p[1]*(p[2]+1),k={dataId:r.dataId,shape:[1,S,e.inChannels],dtype:r.dtype},_=u.shape;u.shape=u.shape.slice(),u.shape[u.shape.length-2]++,y.assert(Cu(u.shape,k.shape),()=>`packed reshape ${u.shape} to ${k.shape} isn't free`);let E=te({inputs:{x:t},backend:o,attrs:{shape:[1,e.inChannels,e.outChannels]}});x.push(E);let R=_p({a:k,b:E,backend:o,transposeA:f,transposeB:h,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a}),D=o.texData.get(R.dataId);y.assert(D.isPacked,()=>\"batchMatMul result is expected to be packed\"),u.shape=_,D.shape=e.outShape,g=At({inputs:{x:R},backend:o}),g.shape=e.outShape,x.push(R)}else{let S=e.outHeight*e.outWidth,k=te({inputs:{x:r},backend:o,attrs:{shape:d?[e.batchSize,S,e.inChannels]:[e.batchSize,e.inChannels,S]}}),_=te({inputs:{x:t},backend:o,attrs:{shape:[1,e.inChannels,e.outChannels]}}),E=_p({a:d?k:_,b:d?_:k,transposeA:!d,transposeB:h,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a});g=te({inputs:{x:E},backend:o,attrs:{shape:e.outShape}}),x.push(k),x.push(_),x.push(E)}for(let S of x)o.disposeIntermediateTensorInfo(S);return g}function Vh({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let{filterWidth:p,filterHeight:u,inChannels:c,outWidth:l,outHeight:m,dataFormat:d}=e,f=d===\"channelsLast\",h=p*u*c,g=m*l,x=[e.batchSize,h,g],b=!0,C=!1,S=[];if(s!=null){let q=Bh(s.shape,f);q!=null&&(s=te({inputs:{x:s},backend:o,attrs:{shape:q}}),S.push(s))}if(n!=null){let q=Bh(n.shape,f);q!=null&&(n=te({inputs:{x:n},backend:o,attrs:{shape:q}}),S.push(n))}let k=te({inputs:{x:t},backend:o,attrs:{shape:[1,h,y.sizeFromShape(t.shape)/h]}});S.push(k);let _=new Lh(x,e),E=[r.shape,[e.padInfo.top,e.padInfo.left],[e.strideHeight,e.strideWidth],[e.dilationHeight,e.dilationWidth],[e.inChannels],[e.filterWidth*e.inChannels],[e.outWidth]],R=o.runWebGLProgram(_,[r],\"float32\",E),D=te({inputs:{x:R},backend:o,attrs:{shape:x}});S.push(R),S.push(D);let P=n!=null,O=s!=null,M=i===\"leakyrelu\",L=i?Ci(i,!0):null,B=new Uc(f?D.shape:k.shape,f?k.shape:D.shape,f?[e.batchSize,g,e.outChannels]:[e.batchSize,e.outChannels,g],b,C,P,L,O,M),z=f?[D,k]:[k,D];if(n&&z.push(n),O&&z.push(s),M){let q=o.makeTensorInfo([],\"float32\",y.createScalarValue(a,\"float32\"));z.push(q),S.push(q)}let U=o.runWebGLProgram(B,z,\"float32\"),j=te({inputs:{x:U},backend:o,attrs:{shape:e.outShape}});S.push(U);for(let q of S)o.disposeIntermediateTensorInfo(q);return j}function J9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,s.shape,a,u,i,c,!1,l),d;if(m.filterHeight===1&&m.filterWidth===1&&m.dilationHeight===1&&m.dilationWidth===1&&m.strideHeight===1&&m.strideWidth===1&&(m.padInfo.type===\"SAME\"||m.padInfo.type===\"VALID\"))d=zh({x:n,filter:s,convInfo:m,backend:e});else if(m.strideWidth<=2&&l===\"channelsLast\"&&A().getBool(\"WEBGL_EXP_CONV\")){let h=new Kc(m),g=[[m.padInfo.top,m.padInfo.left],[m.strideHeight,m.strideWidth],[m.dilationHeight,m.dilationWidth],[m.inHeight,m.inWidth]];d=e.runWebGLProgram(h,[n,s],\"float32\",g)}else if(A().getBool(\"WEBGL_CONV_IM2COL\"))d=Vh({x:n,filter:s,convInfo:m,backend:e});else{let h=new Hc(m);d=e.runWebGLProgram(h,[n,s],\"float32\")}let f=te({inputs:{x:d},backend:e,attrs:{shape:m.outShape}});return e.disposeIntermediateTensorInfo(d),f}var OA={kernelName:rn,backendName:\"webgl\",kernelFunc:J9};var Wh=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.outputShape=t.filterShape;let e=t.strideHeight,o=t.strideWidth,n=t.padInfo.top,s=t.padInfo.left,a=t.dataFormat===\"channelsLast\";this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int wR = coords.x;\n int wC = coords.y;\n int d1 = coords.z;\n int d2 = coords.w;\n\n // Convolve x(?, ?, d1) with dy(:, :, d2) to get dw(wR, wC, d1, d2).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n\n for (int b = 0; b < ${t.batchSize}; b++) {\n for (int yR = 0; yR < ${t.outHeight}; yR++) {\n int xR = wR + yR * ${e} - ${n};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int yC = 0; yC < ${t.outWidth}; yC++) {\n int xC = wC + yC * ${o} - ${s};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n ${a?`float dyValue = getDy(b, yR, yC, d2);\n float xValue = getX(b, xR, xC, d1);\n dotProd += (xValue * dyValue);`:`float dyValue = getDy(b, d2, yR, yC);\n float xValue = getX(b, d1, xR, xC);\n dotProd += (xValue * dyValue);`}\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Uh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.outputShape=t.inShape;let e=t.filterHeight,o=t.filterWidth,n=t.strideHeight,s=t.strideWidth,a=t.dataFormat===\"channelsLast\",i=e-1-t.padInfo.top,p=o-1-t.padInfo.left,u=a?1:2,c=a?2:3,l=a?3:1;this.userCode=`\n const ivec2 pads = ivec2(${i}, ${p});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d1 = coords[${l}];\n\n ivec2 dyCorner = ivec2(coords[${u}], coords[${c}]) - pads;\n int dyRCorner = dyCorner.x;\n int dyCCorner = dyCorner.y;\n\n // Convolve dy(?, ?, d2) with w(:, :, d1, d2) to compute dx(xR, xC, d1).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${e}; wR++) {\n float dyR = float(dyRCorner + wR) / ${n}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n int wRPerm = ${e} - 1 - wR;\n\n for (int wC = 0; wC < ${o}; wC++) {\n float dyC = float(dyCCorner + wC) / ${s}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n int wCPerm = ${o} - 1 - wC;\n\n for (int d2 = 0; d2 < ${t.outChannels}; d2++) {\n\n if (${a}) {\n float xValue = getDy(batch, idyR, idyC, d2);\n float wValue = getW(wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n } else {\n float xValue = getDy(batch, d2, idyR, idyC);\n float wValue = getW(wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n }\n\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Gh=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.outputShape=t.filterShape;let e=t.strideDepth,o=t.strideHeight,n=t.strideWidth,s=t.padInfo.front,a=t.padInfo.top,i=t.padInfo.left;this.userCode=`\n void main() {\n ivec5 coords = getOutputCoords();\n int wF = coords.x;\n int wR = coords.y;\n int wC = coords.z;\n int d1 = coords.w;\n int d2 = coords.u;\n\n float dotProd = 0.0;\n\n for (int b = 0; b < ${t.batchSize}; b++) {\n for (int yF = 0; yF < ${t.outDepth}; yF++) {\n int xF = wF + yF * ${e} - ${s};\n\n if (xF < 0 || xF >= ${t.inDepth}) {\n continue;\n }\n\n for (int yR = 0; yR < ${t.outHeight}; yR++) {\n int xR = wR + yR * ${o} - ${a};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int yC = 0; yC < ${t.outWidth}; yC++) {\n int xC = wC + yC * ${n} - ${i};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float dyValue = getDy(b, yF, yR, yC, d2);\n float xValue = getX(b, xF, xR, xC, d1);\n dotProd += (xValue * dyValue);\n }\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Hh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.outputShape=t.inShape;let e=t.filterDepth,o=t.filterHeight,n=t.filterWidth,s=t.strideDepth,a=t.strideHeight,i=t.strideWidth,p=e-1-t.padInfo.front,u=o-1-t.padInfo.top,c=n-1-t.padInfo.left;this.userCode=`\n const ivec3 pads = ivec3(${p}, ${u}, ${c});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int d1 = coords.u;\n\n\n ivec3 dyCorner = ivec3(coords.y, coords.z, coords.w) - pads;\n int dyFCorner = dyCorner.x;\n int dyRCorner = dyCorner.y;\n int dyCCorner = dyCorner.z;\n\n float dotProd = 0.0;\n for (int wF = 0; wF < ${e}; wF++) {\n float dyF = float(dyFCorner + wF) / ${s}.0;\n\n if (dyF < 0.0 || dyF >= ${t.outDepth}.0 || fract(dyF) > 0.0) {\n continue;\n }\n int idyF = int(dyF);\n\n int wFPerm = ${e} - 1 - wF;\n\n for (int wR = 0; wR < ${o}; wR++) {\n float dyR = float(dyRCorner + wR) / ${a}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 ||\n fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n int wRPerm = ${o} - 1 - wR;\n\n for (int wC = 0; wC < ${n}; wC++) {\n float dyC = float(dyCCorner + wC) / ${i}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n int wCPerm = ${n} - 1 - wC;\n\n for (int d2 = 0; d2 < ${t.outChannels}; d2++) {\n float xValue = getDy(batch, idyF, idyR, idyC, d2);\n float wValue = getW(wFPerm, wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n }\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function eJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,dataFormat:p,dimRoundingMode:u,filterShape:c}=o,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,c,a,1,i,u,!1,l),d=new Wh(m);return e.runWebGLProgram(d,[n,s],\"float32\")}var MA={kernelName:Oi,backendName:\"webgl\",kernelFunc:eJ};var Kh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"strides\",type:\"vec2\"}],this.outputShape=t.inShape,this.enableShapeUniforms=pt(this.outputShape.length);let e=t.filterHeight,o=t.filterWidth,n=e-1-t.padInfo.top,s=o-1-t.padInfo.left;this.userCode=`\n const ivec2 pads = ivec2(${n}, ${s});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d1 = coords[3];\n\n ivec2 dyCorner = ivec2(coords[1], coords[2]) - pads;\n int dyRCorner = dyCorner.x;\n int dyCCorner = dyCorner.y;\n\n vec4 result = vec4(0.);\n for (int wR = 0; wR < ${e}; wR++) {\n float dyR = float(dyRCorner + wR) / strides[0];\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n int wRPerm = ${e} - 1 - wR;\n\n for (int wC = 0; wC < ${o}; wC++) {\n int wCPerm = ${o} - 1 - wC;\n\n float dyC = float(dyCCorner + wC) / strides[1];\n bool idyCVal = (dyC >= 0.0) && (dyC < ${t.outWidth}.0)\n && (fract(dyC) == 0.0);\n int idyC = int(dyC);\n\n float dyC2 = float(dyCCorner + wC + 1) / strides[1];\n bool idyCVal2 = (dyC2 >= 0.0) && (dyC2 < ${t.outWidth}.0)\n && (fract(dyC2) == 0.0);\n int idyC2 = int(dyC2);\n\n if (idyCVal && idyCVal2) {\n for (int d2 = 0; d2 < ${t.outChannels}; d2 += 2) {\n vec4 wValue = getW(wRPerm, wCPerm, d1, d2);\n vec4 dySample = getDy(batch, idyR, idyC, d2);\n vec4 dySample2 = (idyC / 2 == idyC2 / 2) ?\n dySample : getDy(batch, idyR, idyC2, d2);\n\n vec2 dyValue = mod(float(idyC), 2.) == 0. ?\n dySample.xy : dySample.zw;\n result.xy += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n\n dyValue = mod(float(idyC2), 2.) == 0. ?\n dySample2.xy : dySample2.zw;\n result.zw += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n }\n } else if (idyCVal) {\n for (int d2 = 0; d2 < ${t.outChannels}; d2 += 2) {\n vec4 wValue = getW(wRPerm, wCPerm, d1, d2);\n vec4 dySample = getDy(batch, idyR, idyC, d2);\n vec2 dyValue = mod(float(idyC), 2.) == 0. ?\n dySample.xy : dySample.zw;\n result.xy += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n }\n } else if (idyCVal2) {\n for (int d2 = 0; d2 < ${t.outChannels}; d2 += 2) {\n vec4 wValue = getW(wRPerm, wCPerm, d1, d2);\n vec4 dySample = getDy(batch, idyR, idyC2, d2);\n vec2 dyValue = mod(float(idyC2), 2.) == 0. ?\n dySample.xy : dySample.zw;\n result.zw += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n }\n }\n }\n }\n setOutput(result);\n }\n `}};function tJ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{inputShape:a,strides:i,pad:p,dataFormat:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(u),m=w.computeConv2DInfo(a,s.shape,i,1,p,c,!1,l);if(A().getBool(\"WEBGL_PACK_CONV2DTRANSPOSE\")&&l===\"channelsLast\"){let d=[[m.strideHeight,m.strideWidth]],f=new Kh(m);return e.runWebGLProgram(f,[n,s],\"float32\",d)}else{let d=new Uh(m);return e.runWebGLProgram(d,[n,s],\"float32\")}}var LA={kernelName:on,backendName:\"webgl\",kernelFunc:tJ};function rJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeConv3DInfo(n.shape,s.shape,a,p,i),c=new Mh(u);return e.runWebGLProgram(c,[n,s],\"float32\")}var BA={kernelName:nn,backendName:\"webgl\",kernelFunc:rJ};function oJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,filterShape:p}=o,u=w.computeConv3DInfo(n.shape,p,a,1,i),c=new Gh(u);return e.runWebGLProgram(c,[n,s],\"float32\")}var zA={kernelName:Xa,backendName:\"webgl\",kernelFunc:oJ};function nJ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{pad:a,strides:i,inputShape:p}=o,u=w.computeConv3DInfo(p,s.shape,i,1,a),c=new Hh(u);return e.runWebGLProgram(c,[n,s],\"float32\")}var VA={kernelName:sn,backendName:\"webgl\",kernelFunc:nJ};var sJ=Po+`\n return cos(x);\n`,aJ=`\n vec4 result = cos(x);\n bvec4 isNaN = isnan(x);\n ${Xr}\n return result;\n`,iJ=xe({opSnippet:sJ,packedOpSnippet:aJ}),WA={kernelName:an,backendName:\"webgl\",kernelFunc:iJ};var uJ=`\n float e2x = exp(-x);\n return (e2x + 1.0 / e2x) / 2.0;\n`,pJ=xe({opSnippet:uJ}),UA={kernelName:un,backendName:\"webgl\",kernelFunc:pJ};var qh=class{constructor(t,e,o,n,s){this.variableNames=[\"Image\",\"Boxes\",\"BoxInd\"],this.outputShape=[];let[a,i,p,u]=t,[c]=e,[l,m]=o;this.outputShape=[c,l,m,u];let d=n===\"bilinear\"?1:0,[f,h]=[`${i-1}.0`,`${p-1}.0`],[g,x,b]=l>1?[`${(i-1)/(l-1)}`,\"(y2-y1) * height_ratio\",`y1*${f} + float(y)*(height_scale)`]:[\"0.0\",\"0.0\",`0.5 * (y1+y2) * ${f}`],[C,S,k]=m>1?[`${(p-1)/(m-1)}`,\"(x2-x1) * width_ratio\",`x1*${h} + float(x)*(width_scale)`]:[\"0.0\",\"0.0\",`0.5 * (x1+x2) * ${h}`];this.userCode=`\n const float height_ratio = float(${g});\n const float width_ratio = float(${C});\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int y = coords[1];\n int x = coords[2];\n int d = coords[3];\n\n // get box vals\n float y1 = getBoxes(b,0);\n float x1 = getBoxes(b,1);\n float y2 = getBoxes(b,2);\n float x2 = getBoxes(b,3);\n\n // get image in batch index\n int bInd = round(getBoxInd(b));\n if(bInd < 0 || bInd >= ${a}) {\n return;\n }\n\n float height_scale = ${x};\n float width_scale = ${S};\n\n float in_y = ${b};\n if( in_y < 0.0 || in_y > ${f} ) {\n setOutput(float(${s}));\n return;\n }\n float in_x = ${k};\n if( in_x < 0.0 || in_x > ${h} ) {\n setOutput(float(${s}));\n return;\n }\n\n vec2 sourceFracIndexCR = vec2(in_x,in_y);\n if(${d} == 1) {\n // Compute the four integer indices.\n ivec2 sourceFloorCR = ivec2(sourceFracIndexCR);\n ivec2 sourceCeilCR = ivec2(ceil(sourceFracIndexCR));\n\n float topLeft = getImage(b, sourceFloorCR.y, sourceFloorCR.x, d);\n float bottomLeft = getImage(b, sourceCeilCR.y, sourceFloorCR.x, d);\n float topRight = getImage(b, sourceFloorCR.y, sourceCeilCR.x, d);\n float bottomRight = getImage(b, sourceCeilCR.y, sourceCeilCR.x, d);\n\n vec2 fracCR = sourceFracIndexCR - vec2(sourceFloorCR);\n\n float top = topLeft + (topRight - topLeft) * fracCR.x;\n float bottom = bottomLeft + (bottomRight - bottomLeft) * fracCR.x;\n float newValue = top + (bottom - top) * fracCR.y;\n setOutput(newValue);\n } else {\n // Compute the coordinators of nearest neighbor point.\n ivec2 sourceNearestCR = ivec2(floor(\n sourceFracIndexCR + vec2(0.5,0.5)));\n float newValue = getImage(b, sourceNearestCR.y, sourceNearestCR.x, d);\n setOutput(newValue);\n }\n }\n `}};var cJ=r=>{let{inputs:t,backend:e,attrs:o}=r,{image:n,boxes:s,boxInd:a}=t,{cropSize:i,method:p,extrapolationValue:u}=o,c=new qh(n.shape,s.shape,i,p,u);return e.runWebGLProgram(c,[n,s,a],\"float32\")},GA={kernelName:ln,backendName:\"webgl\",kernelFunc:cJ};var Ep;(function(r){r.Prod=\"*\",r.Sum=\"+\"})(Ep||(Ep={}));var om=class{constructor(t,e,o,n){this.op=t,this.outputShape=e,this.variableNames=[\"x\"],this.customUniforms=[{name:\"index\",type:\"float\"}];let s=this.outputShape.length,a=this.op===Ep.Prod?\"1.0\":\"0.0\",i=o?a:`getX(${HA(s,\"coords\",this.op)})`,p=this.outputShape[this.outputShape.length-1],u=\"\",c=\"\";o?(u=n?`end != ${p-1}`:\"end != 0\",c=n?\"end + 1\":\"end - 1\"):(u=n?`end + pow2 < ${p}`:\"end >= pow2\",c=n?\"end + pow2\":\"end - pow2\"),this.userCode=`\n void main() {\n ${Re(s)} coords = getOutputCoords();\n int end = ${KA(s,\"coords\",this.op)};\n float val = ${i};\n int pow2 = int(pow(2.0, index));\n if (${u}) {\n int idx = ${c};\n ${KA(s,\"coords\",this.op)} = idx;\n val ${this.op}= getX(${HA(s,\"coords\",this.op)});\n }\n setOutput(val);\n }\n `}};function HA(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.x, ${t}.y`;if(r===3)return`${t}.x, ${t}.y, ${t}.z`;if(r===4)return`${t}.x, ${t}.y, ${t}.z, ${t}.w`;throw new Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function KA(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.y`;if(r===3)return`${t}.z`;if(r===4)return`${t}.w`;throw new Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function jh(r,t,e,o,n,s){let a=t.shape.length,i=w.getAxesPermutation([o],a),p=t;i!=null&&(p=Ct({inputs:{x:t},backend:e,attrs:{perm:i}}));let u=w.getInnerMostAxes(1,a)[0];if(u!==a-1)throw new Error(`WebGL cumprod shader expects an inner-most axis=${t.shape.length-1} but got axis=${o}`);let c=p.shape[u],l=At({inputs:{x:p},backend:e});for(let m=0;m<=Math.ceil(Math.log2(c))-1;m++){let d=new om(r,p.shape,!1,s),f=[[m]],h=l;l=e.runWebGLProgram(d,[l],l.dtype,f),e.disposeIntermediateTensorInfo(h)}if(n){let m=new om(r,p.shape,n,s),d=l;l=e.runWebGLProgram(m,[l],l.dtype),e.disposeIntermediateTensorInfo(d)}if(i!=null){let m=w.getUndoAxesPermutation(i),d=Ct({inputs:{x:l},backend:e,attrs:{perm:m}});return e.disposeIntermediateTensorInfo(l),e.disposeIntermediateTensorInfo(p),d}return l}function lJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return jh(Ep.Prod,n,e,s,a,i)}var qA={kernelName:pn,backendName:\"webgl\",kernelFunc:lJ};function mJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return jh(Ep.Sum,n,e,s,a,i)}var jA={kernelName:cn,backendName:\"webgl\",kernelFunc:mJ};function dJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a,binaryOutput:i}=o;if(n.shape.length===1){let p=e.readSync(n.dataId),u=e.readSync(s.dataId),c=ph(p,u,s.dtype,s.shape,a);return e.makeTensorInfo([a],s.dtype,c)}else if(n.shape.length===2){let p=e.bufferSync(n),u=e.bufferSync(s),c=DR(p,u,a,i);return e.makeTensorInfo(c.shape,s.dtype,c.values)}throw new Error(`Error in denseBincount: input must be at most rank 2, but got rank${n.shape.length}.`)}var XA={kernelName:ra,backendName:\"webgl\",kernelFunc:dJ};var Xh=class{constructor(t,e,o){this.variableNames=[\"x\"],this.outputShape=[],this.outputShape=t,this.blockSize=e,this.dataFormat=o,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int h = ${this.getHeightCoordString()};\n int w = ${this.getWidthCoordString()};\n int d = ${this.getDepthCoordString()};\n\n int in_h = h / ${e};\n int offset_h = imod(h, ${e});\n int in_w = w / ${e};\n int offset_w = imod(w, ${e});\n int offset_d = (offset_h * ${e} + offset_w) *\n ${this.getOutputDepthSize()};\n int in_d = d + offset_d;\n\n float result = ${this.getInputSamplingString()};\n setOutput(result);\n }\n `}getHeightCoordString(){return this.dataFormat===\"NHWC\"?\"coords[1]\":\"coords[2]\"}getWidthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[2]\":\"coords[3]\"}getDepthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[3]\":\"coords[1]\"}getOutputDepthSize(){return this.dataFormat===\"NHWC\"?this.outputShape[3]:this.outputShape[1]}getInputSamplingString(){return this.dataFormat===\"NHWC\"?\"getX(b, in_h, in_w, in_d)\":\"getX(b, in_d, in_h, in_w)\"}};function fJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockSize:s,dataFormat:a}=o,i=n.shape[0],p=a===\"NHWC\"?n.shape[1]:n.shape[2],u=a===\"NHWC\"?n.shape[2]:n.shape[3],c=a===\"NHWC\"?n.shape[3]:n.shape[1],l=p*s,m=u*s,d=c/(s*s),f=a===\"NHWC\"?[i,l,m,d]:[i,d,l,m],h=new Xh(f,s,a);return e.runWebGLProgram(h,[n],n.dtype)}var YA={kernelName:mn,backendName:\"webgl\",kernelFunc:fJ};var qc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.customUniforms=[{name:\"pads\",type:\"ivec2\"},{name:\"strides\",type:\"ivec2\"},{name:\"dilations\",type:\"ivec2\"},{name:\"inDims\",type:\"ivec2\"}],this.outputShape=t.outShape,this.enableShapeUniforms=pt(this.outputShape.length);let a=t.filterHeight,i=t.filterWidth,p=t.outChannels/t.inChannels,u=\"\",c=\"\";o&&(n?u=`float activation(float a) {\n float b = getPreluActivationWeightsAtOutCoords();\n ${o}\n }`:s?u=`float activation(float a) {\n float b = getLeakyreluAlphaAtOutCoords();\n ${o}\n }`:u=`\n float activation(float x) {\n ${o}\n }\n `,c=\"result = activation(result);\");let l=e?\"result += getBiasAtOutCoords();\":\"\";e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),s&&this.variableNames.push(\"leakyreluAlpha\"),this.userCode=`\n ${u}\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords.x;\n ivec2 xRCCorner = coords.yz * strides - pads;\n int d2 = coords.w;\n int d1 = d2 / ${p};\n int q = d2 - d1 * ${p};\n\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // Convolve x(?, ?, d1) with w(:, :, d1, q) to get y(yR, yC, d2).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n // TO DO(dsmilkov): Flatten the two for loops and vec4 the operations.\n for (int wR = 0; wR < ${a}; wR++) {\n int xR = xRCorner + wR * dilations[0];\n\n if (xR < 0 || xR >= inDims[0]) {\n continue;\n }\n\n for (int wC = 0; wC < ${i}; wC++) {\n int xC = xCCorner + wC * dilations[1];\n\n if (xC < 0 || xC >= inDims[1]) {\n continue;\n }\n\n float xVal = getX(batch, xR, xC, d1);\n float wVal = getW(wR, wC, d1, q);\n dotProd += xVal * wVal;\n }\n }\n\n float result = dotProd;\n ${l}\n ${c}\n setOutput(result);\n }\n `}};var jc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"pads\",type:\"ivec2\"},{name:\"strides\",type:\"ivec2\"},{name:\"dilations\",type:\"ivec2\"},{name:\"inDims\",type:\"ivec2\"}],this.outputShape=t.outShape,this.enableShapeUniforms=pt(this.outputShape.length);let a=t.outChannels/t.inChannels,i=t.padInfo.left,p=t.strideWidth,u=t.dilationWidth,c=t.filterHeight,l=t.filterWidth,m=l,d=`\n int xR; int xC; int xCOffset;\n vec4 wTexel; vec4 previous; vec4 final;`;for(let x=0;x=0 && xR < inDims[0]) {\n `;for(let x=0;x<(m+1)/2;x++){let b=x*2;if(d+=`\n xC = xCCorner + ${b*u};\n `,p===1){if(b= 0 && xCOffset < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n `,u===1&&b>0?d+=`\n xC${b} = vec4(xTexelC${b-2}.zw, xTexelC${b}.xy);\n `:d+=`\n xCOffset = xC + 1 - 2;\n\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n previous.zw = vec2(0.0);\n }\n\n xC${b} = vec4(previous.zw, xTexelC${b}.xy);\n } else {\n xC${b} = vec4(0.0, 0.0, xTexelC${b}.xy);\n }\n `):d+=`\n if (xC >= 0 && xC < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n\n xC${b} = xTexelC${b};\n `,b+1= 0 && xCOffset < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.0);\n }\n xTexelC${b+1}Ready = 1;\n }\n `,u>1?d+=`\n xCOffset -= 2;\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n xC${b+1} = vec4(previous.zw, xTexelC${b+1}.xy);\n } else {\n xC${b+1} = vec4(0.0, 0.0, xTexelC${b+1}.xy);\n }\n `:d+=`\n xC${b+1} = vec4(xTexelC${b}.zw, xTexelC${b+1}.xy);\n `):C===1?d+=`\n xC${b+1} = xTexelC${b};\n `:d+=`\n xCOffset = xC + ${C};\n\n if (xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.0);\n }\n xTexelC${b+1}Ready = 1;\n }\n\n xC${b+1} = xTexelC${b+1};\n `}}else b= 0 && xCOffset < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xCOffset, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n\n if(xC + 1 >= 0 && xC + 1 < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xC + 1, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xC + 2 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.0);\n }\n xTexelC${b+1}Ready = 1;\n }\n\n xC${b} = vec4(xTexelC${b}.zw, xTexelC${b+1}.zw);\n `,b+1= 0 && xCOffset < inDims[1]) {\n final = getX(batch, xR, xCOffset, d1);\n }\n xC${b+1} = vec4(xTexelC${b+1}.xy, final.xy);\n `)):(d+=`\n if(xC >= 0 && xC < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n\n xCOffset = xC + strides[1];\n if(xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.);\n }\n xTexelC${b+1}Ready = 1;\n }\n\n xC${b} = vec4(\n xTexelC${b}.xy, xTexelC${b+1}.xy);\n `,b+1`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${a} and dilations '${c}'`);let l=w.computeConv2DInfo(n.shape,s.shape,a,c,i,u,!0),m;A().getBool(\"WEBGL_PACK_DEPTHWISECONV\")&&l.strideWidth<=2&&l.outChannels/l.inChannels===1?m=new jc(l):m=new qc(l);let d=[[l.padInfo.top,l.padInfo.left],[l.strideHeight,l.strideWidth],[l.dilationHeight,l.dilationWidth],[l.inHeight,l.inWidth]];return e.runWebGLProgram(m,[n,s],\"float32\",d)}var QA={kernelName:dn,backendName:\"webgl\",kernelFunc:hJ};var Yh=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.outputShape=t.filterShape;let e=t.strideHeight,o=t.strideWidth,n=t.padInfo.top,s=t.padInfo.left,a=t.outChannels/t.inChannels;this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int wR = coords.x;\n int wC = coords.y;\n int d1 = coords.z;\n int dm = coords.w;\n int d2 = d1 * ${a} + dm;\n\n float dotProd = 0.0;\n\n // TO DO: Vec4 over the batch size\n for (int b = 0; b < ${t.batchSize}; b++) {\n for (int yR = 0; yR < ${t.outHeight}; yR++) {\n int xR = wR + yR * ${e} - ${n};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int yC = 0; yC < ${t.outWidth}; yC++) {\n int xC = wC + yC * ${o} - ${s};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float dyValue = getDy(b, yR, yC, d2);\n float xValue = getX(b, xR, xC, d1);\n dotProd += (xValue * dyValue);\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Qh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.outputShape=t.inShape;let e=t.filterHeight,o=t.filterWidth,n=t.strideHeight,s=t.strideWidth,a=e-1-t.padInfo.top,i=o-1-t.padInfo.left,p=t.outChannels/t.inChannels;this.userCode=`\n const ivec2 pads = ivec2(${a}, ${i});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d1 = coords[3];\n ivec2 dyCorner = coords.yz - pads;\n int dyRCorner = dyCorner.x;\n int dyCCorner = dyCorner.y;\n\n float dotProd = 0.0;\n\n for (int wR = 0; wR < ${e}; wR++) {\n float dyR = float(dyRCorner + wR) / ${n}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n int wRPerm = ${e} - 1 - wR;\n\n for (int wC = 0; wC < ${o}; wC++) {\n float dyC = float(dyCCorner + wC) / ${s}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n int wCPerm = ${o} - 1 - wC;\n\n // TO DO: Vec4 over the channelMul\n for (int dm = 0; dm < ${p}; dm++) {\n int d2 = d1 * ${p} + dm;\n float xValue = getDy(batch, idyR, idyC, d2);\n float wValue = getW(wRPerm, wCPerm, d1, dm);\n dotProd += xValue * wValue;\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function gJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,filterShape:c}=o,l=w.computeConv2DInfo(n.shape,c,a,i,p,u,!0),m=new Yh(l);return e.runWebGLProgram(m,[n,s],\"float32\")}var ZA={kernelName:Mi,backendName:\"webgl\",kernelFunc:gJ};function xJ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,inputShape:c}=o,l=w.computeConv2DInfo(c,s.shape,a,i,p,u,!0),m=new Qh(l);return e.runWebGLProgram(m,[n,s],\"float32\")}var JA={kernelName:Li,backendName:\"webgl\",kernelFunc:xJ};var Zh=class{constructor(t){this.variableNames=[\"X\"],this.outputShape=[t,t],this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n float val = coords[0] == coords[1] ? getX(coords[0]) : 0.0;\n setOutput(val);\n }\n `}};function yJ(r){let{inputs:t,backend:e}=r,{x:o}=t,n=[...o.shape,...o.shape],s=y.sizeFromShape(o.shape),a=te({inputs:{x:o},backend:e,attrs:{shape:[s]}}),i=new Zh(s),p=e.runWebGLProgram(i,[a],a.dtype),u=te({inputs:{x:p},backend:e,attrs:{shape:n}});return e.disposeIntermediateTensorInfo(a),e.disposeIntermediateTensorInfo(p),u}var eF={kernelName:oa,backendName:\"webgl\",kernelFunc:yJ};var Jh=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.outputShape=t.outShape;let{inHeight:e,inWidth:o,padInfo:n,strideHeight:s,strideWidth:a,filterHeight:i,filterWidth:p,dilationHeight:u,dilationWidth:c}=t,{top:l,left:m}=n;this.userCode=`\n const ivec2 strides = ivec2(${s}, ${a});\n const ivec2 pads = ivec2(${l}, ${m});\n const float neg_infinity = -3.4e38;\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords.x;\n int d1 = coords.w;\n ivec2 outTopLeftCorner =\n coords.yz * strides - pads;\n int hBeg = outTopLeftCorner.x;\n int wBeg = outTopLeftCorner.y;\n\n float curVal = neg_infinity;\n for (int h = 0; h < ${i}; h++) {\n int hIn = hBeg + h * ${u};\n\n if (hIn >= 0 && hIn < ${e}) {\n for (int w = 0; w < ${p}; w++) {\n int wIn = wBeg + w * ${c};\n\n if (wIn >= 0 && wIn < ${o}) {\n float xVal = getX(batch, hIn, wIn, d1);\n float wVal = getW(h, w, d1);\n\n float val = xVal + wVal;\n if (val > curVal) {\n curVal = val;\n }\n }\n }\n }\n }\n\n float result = curVal;\n setOutput(result);\n }\n `}};function bJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeDilation2DInfo(n.shape,s.shape,a,i,\"NHWC\",p),c,l=new Jh(u);c=e.runWebGLProgram(l,[n,s],\"float32\");let m=te({inputs:{x:c},backend:e,attrs:{shape:u.outShape}});return e.disposeIntermediateTensorInfo(c),m}var tF={kernelName:fn,backendName:\"webgl\",kernelFunc:bJ};function CJ(r){let{inputs:t,backend:e,attrs:o}=r,{equation:n}=o,s=t,{allDims:a,summedDims:i,idDims:p}=w.decodeEinsumEquation(n,s.length);w.checkEinsumDimSizes(a.length,p,s);let{path:u,steps:c}=w.getEinsumComputePath(i,p),l=c.length,m=null,d=a.length,f=[];for(let h=0;h=0&&(m=Tp({inputs:{x:m},backend:e,attrs:{axis:u[h]-(a.length-d),keepDims:!1}}),f.push(m)),d--)}for(let h of f)h!==m&&e.disposeIntermediateTensorInfo(h);return m}var rF={kernelName:Vi,backendName:\"webgl\",kernelFunc:CJ};var wJ=\"return (x >= 0.0) ? x : (exp(x) - 1.0);\",SJ=`\n vec4 result;\n\n result.r = (x.r >= 0.0) ? x.r : (exp(x.r) - 1.0);\n result.g = (x.g >= 0.0) ? x.g : (exp(x.g) - 1.0);\n result.b = (x.b >= 0.0) ? x.b : (exp(x.b) - 1.0);\n result.a = (x.a >= 0.0) ? x.a : (exp(x.a) - 1.0);\n\n return result;\n`,IJ=xe({opSnippet:wJ,packedOpSnippet:SJ}),oF={kernelName:gn,backendName:\"webgl\",kernelFunc:IJ};var vJ=\"return (b >= 0.0) ? a : a * (b + 1.0);\",kJ=`\n vec4 bGTEZero = vec4(greaterThanEqual(b, vec4(0.)));\n return (bGTEZero * a) + ((vec4(1.0) - bGTEZero) * (a * (b + vec4(1.0))));\n`,NJ=r=>{let{inputs:t,backend:e}=r,{dy:o,y:n}=t,s=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")?new jr(kJ,o.shape,n.shape):new Pr(vJ,o.shape,n.shape);return e.runWebGLProgram(s,[o,n],o.dtype)},nF={kernelName:Ya,backendName:\"webgl\",kernelFunc:NJ};var TJ=`\n return vec4(equal(a, b));\n`,_J=\"return float(a == b);\",$J=nt({opSnippet:_J,packedOpSnippet:TJ,dtype:\"bool\",cpuKernelImpl:MR}),sF={kernelName:yn,backendName:\"webgl\",kernelFunc:$J};var EJ=`\n // Error function is calculated approximately with elementary function.\n // See \"Handbook of Mathematical Functions with Formulas,\n // Graphs, and Mathematical Tables\", Abramowitz and Stegun.\n float p = ${w.ERF_P};\n float a1 = ${w.ERF_A1};\n float a2 = ${w.ERF_A2};\n float a3 = ${w.ERF_A3};\n float a4 = ${w.ERF_A4};\n float a5 = ${w.ERF_A5};\n\n float sign = sign(x);\n x = abs(x);\n float t = 1.0 / (1.0 + p * x);\n return sign * (1.0 - (((((a5*t + a4)*t) + a3)*t + a2)*t + a1)*t*exp(-x*x));\n`,RJ=xe({opSnippet:EJ}),aF={kernelName:xn,backendName:\"webgl\",kernelFunc:RJ};var DJ=Po+`\n return exp(x);\n`,AJ=`\n vec4 result = exp(x);\n bvec4 isNaN = isnan(x);\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,Iv=xe({opSnippet:DJ,packedOpSnippet:AJ,cpuKernelImpl:LR,dtype:\"float32\"}),iF={kernelName:bn,backendName:\"webgl\",kernelFunc:Iv};function eg(r){let{inputs:t,attrs:e,backend:o}=r,{dim:n}=e,{input:s}=t,a=s.shape.length,i=s.shape.slice(),p=n;return n<0&&(y.assert(-(a+1)<=n,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+n+1),i.splice(p,0,1),te({inputs:{x:s},backend:o,attrs:{shape:i}})}var uF={kernelName:na,backendName:\"webgl\",kernelFunc:eg};var pF=\"return exp(x) - 1.0;\",FJ=xe({opSnippet:pF,packedOpSnippet:pF,cpuKernelImpl:BR}),cF={kernelName:Cn,backendName:\"webgl\",kernelFunc:FJ};var nm=class{constructor(t,e,o){this.variableNames=[\"real\",\"imag\"];let n=e[1];this.outputShape=e;let s=o?`2.0 * ${Math.PI}`:`-2.0 * ${Math.PI}`,a=o?`${n}.0`:\"1.0\",i;if(t===\"real\")i=\"return real * expR - imag * expI;\";else if(t===\"imag\")i=\"return real * expI + imag * expR;\";else throw new Error(`FFT component must be either \"real\" or \"imag\", got ${t}.`);this.userCode=`\n const float exponentMultiplier = ${s};\n\n float unaryOpComplex(float real, float expR, float imag, float expI) {\n ${i}\n }\n\n float mulMatDFT(int batch, int index) {\n float indexRatio = float(index) / float(${n});\n float exponentMultiplierTimesIndexRatio =\n exponentMultiplier * indexRatio;\n\n float result = 0.0;\n\n for (int i = 0; i < ${n}; i++) {\n // x = (-2|2 * PI / N) * index * i;\n float x = exponentMultiplierTimesIndexRatio * float(i);\n float expR = cos(x);\n float expI = sin(x);\n float real = getReal(batch, i);\n float imag = getImag(batch, i);\n\n result +=\n unaryOpComplex(real, expR, imag, expI) / ${a};\n }\n\n return result;\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n setOutput(mulMatDFT(coords[0], coords[1]));\n }\n `}};function tg(r,t,e){let o=e.texData.get(r.dataId),n=y.sizeFromShape(r.shape),s=r.shape[r.shape.length-1],a=n/s,i=te({inputs:{x:r},backend:e,attrs:{shape:[a,s]}}),p=i.shape,u=new nm(\"real\",p,t),c=new nm(\"imag\",p,t),l=[{dataId:o.complexTensorInfos.real.dataId,dtype:o.complexTensorInfos.real.dtype,shape:p},{dataId:o.complexTensorInfos.imag.dataId,dtype:o.complexTensorInfos.imag.dtype,shape:p}],m=e.runWebGLProgram(u,l,\"float32\"),d=e.runWebGLProgram(c,l,\"float32\"),f=Or({inputs:{real:m,imag:d},backend:e});e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d);let h=te({inputs:{x:f},backend:e,attrs:{shape:r.shape}});return e.disposeIntermediateTensorInfo(i),e.disposeIntermediateTensorInfo(f),h}function PJ(r){let{inputs:t,backend:e}=r,{input:o}=t;return tg(o,!1,e)}var lF={kernelName:Wi,backendName:\"webgl\",kernelFunc:PJ};var rg=class{constructor(t,e){this.outputShape=[],this.customUniforms=[{name:\"value\",type:\"float\"}],this.variableNames=[\"x\"],this.outputShape=t,this.userCode=`\n void main() {\n // Input can be obtained from uniform value.\n setOutput(value);\n }\n `}};function Si(r){let{backend:t,attrs:e}=r,{shape:o,value:n}=e,{dtype:s}=e;if(s=s||y.inferDtype(n),s===\"string\"){let a=y.getArrayFromDType(s,y.sizeFromShape(o));return a.fill(n),t.makeTensorInfo(o,s,a)}else{let a=new rg(o,n),i=[[n]];return t.runWebGLProgram(a,[],s,i)}}var mF={kernelName:sa,backendName:\"webgl\",kernelFunc:Si};var og=class{constructor(t){this.variableNames=[\"Image\"],this.outputShape=[];let e=t[2];this.outputShape=t,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int x = coords[2];\n\n int coordX = ${e} - x - 1;\n float outputValue;\n if(coordX >= 0 && coordX < ${e}) {\n outputValue = getImage(coords[0], coords[1], coordX, coords[3]);\n } else {\n outputValue = getImage(coords[0], coords[1], coords[2], coords[3]);\n }\n setOutput(outputValue);\n }\n `}};var dF={kernelName:wn,backendName:\"webgl\",kernelFunc:({inputs:r,backend:t})=>{let{image:e}=r,o=t,n=new og(e.shape);return o.runWebGLProgram(n,[e],e.dtype)}};var fF=\"return floor(x);\",OJ=xe({opSnippet:fF,packedOpSnippet:fF,cpuKernelImpl:zR}),hF={kernelName:Sn,backendName:\"webgl\",kernelFunc:OJ};var MJ=`\n float s = sign(a) * sign(b);\n int ia = round(a);\n int ib = round(b);\n if (ib != 0) {\n // Windows (D3D) wants guaranteed non-zero int division at compile-time.\n return float(idiv(ia, ib, s));\n } else {\n return NAN;\n }\n`,LJ=`\n ivec4 ia = round(a);\n ivec4 ib = round(b);\n bvec4 cond = notEqual(ib, ivec4(0));\n ivec4 result = ivec4(0);\n vec4 s = sign(a) * sign(b);\n\n // Windows (D3D) wants guaranteed non-zero int division at compile-time.\n if (cond[0]) {\n result[0] = idiv(ia[0], ib[0], s[0]);\n }\n if (cond[1]) {\n result[1] = idiv(ia[1], ib[1], s[1]);\n }\n if (cond[2]) {\n result[2] = idiv(ia[2], ib[2], s[2]);\n }\n if (cond[3]) {\n result[3] = idiv(ia[3], ib[3], s[3]);\n }\n return vec4(result);\n`,BJ=nt({opSnippet:MJ,packedOpSnippet:LJ,dtype:\"int32\"}),gF={kernelName:In,backendName:\"webgl\",kernelFunc:BJ};var ng=class{constructor(t){this.variableNames=[\"A\"];let e=vt(),[o,n]=t;this.outputShape=t,this.userCode=`\n void main() {\n ivec3 coords = getOutputCoords();\n int texR = coords[0];\n int texC = coords[1];\n int depth = coords[2];\n vec2 uv = (vec2(texC, texR) + halfCR) / vec2(${n}.0, ${o}.0);\n\n vec4 values = ${e.texture2D}(A, uv);\n float value;\n if (depth == 0) {\n value = values.r;\n } else if (depth == 1) {\n value = values.g;\n } else if (depth == 2) {\n value = values.b;\n } else if (depth == 3) {\n value = values.a;\n }\n\n setOutput(floor(value * 255.0 + 0.5));\n }\n `}};var sg=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!1,this.packedOutput=!0;let e=vt(),[o,n]=t;this.outputShape=t,this.userCode=`\n void main() {\n ivec3 coords = getOutputCoords();\n int texR = coords[0];\n int texC = coords[1];\n int depth = coords[2];\n\n vec4 result = vec4(0.);\n\n for(int row=0; row<=1; row++) {\n for(int col=0; col<=1; col++) {\n texC = coords[1] + row;\n depth = coords[2] + col;\n\n vec2 uv = (vec2(texC, texR) + halfCR) /\n vec2(${n}.0, ${o}.0);\n vec4 values = ${e.texture2D}(A, uv);\n float value;\n if (depth == 0) {\n value = values.r;\n } else if (depth == 1) {\n value = values.g;\n } else if (depth == 2) {\n value = values.b;\n } else if (depth == 3) {\n value = values.a;\n }\n\n result[row * 2 + col] = floor(value * 255.0 + 0.5);\n }\n }\n\n ${e.output} = result;\n }\n `}};var xF={kernelName:Mu,backendName:\"webgl\",kernelFunc:zJ},Xc,vv=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");function zJ(r){let{inputs:t,backend:e,attrs:o}=r,{pixels:n}=t,{numChannels:s}=o,a=typeof HTMLVideoElement!=\"undefined\"&&n instanceof HTMLVideoElement,i=typeof HTMLImageElement!=\"undefined\"&&n instanceof HTMLImageElement,[p,u]=a?[n.videoWidth,n.videoHeight]:[n.width,n.height],c=[u,p],l=[u,p,s];if(i||a){let h=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");(Xc==null||h!==vv)&&(vv=h,Xc=document.createElement(\"canvas\").getContext(\"2d\",{willReadFrequently:vv})),Xc.canvas.width=p,Xc.canvas.height=u,Xc.drawImage(n,0,0,p,u),n=Xc.canvas}let m=e.makeTensorInfo(c,\"int32\");e.texData.get(m.dataId).usage=dr.PIXELS,e.gpgpu.uploadPixelDataToTexture(e.getTexture(m.dataId),n);let d=A().getBool(\"WEBGL_PACK\")?new sg(l):new ng(l),f=e.runWebGLProgram(d,[m],\"int32\");return e.disposeData(m.dataId),f}function VJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dataFormat:c,dilations:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=o,h=w.convertConv2DDataFormat(c),g=w.computeConv2DInfo(n.shape,s.shape,p,l,u,m,!1,h),x,b=[],C=a!=null,S=i!=null,k=d===\"leakyrelu\",_=()=>{let R=[n,s],D=(P,O)=>{if(O===\"NCHW\"&&P.shape.length===1&&P.shape[0]!==1){let M=te({inputs:{x:P},backend:e,attrs:{shape:[P.shape[0],1,1]}});return b.push(M),M}return P};if(C&&R.push(D(a,c)),S&&R.push(D(i,c)),k){let P=e.makeTensorInfo([],\"float32\",y.createScalarValue(f,\"float32\"));R.push(P),b.push(P)}return R};if(g.filterHeight===1&&g.filterWidth===1&&g.dilationHeight===1&&g.dilationWidth===1&&g.strideHeight===1&&g.strideWidth===1&&(g.padInfo.type===\"SAME\"||g.padInfo.type===\"VALID\"))x=zh({x:n,filter:s,convInfo:g,backend:e,bias:a,activation:d,preluActivationWeights:i,leakyreluAlpha:f});else if(g.strideWidth<=2&&h===\"channelsLast\"&&A().getBool(\"WEBGL_EXP_CONV\")){let R=d?Ci(d,!0):null,D=new Kc(g,C,R,S,k),P=[[g.padInfo.top,g.padInfo.left],[g.strideHeight,g.strideWidth],[g.dilationHeight,g.dilationWidth],[g.inHeight,g.inWidth]],O=_();x=e.runWebGLProgram(D,O,\"float32\",P)}else if(A().getBool(\"WEBGL_CONV_IM2COL\"))x=Vh({x:n,filter:s,convInfo:g,backend:e,bias:a,activation:d,preluActivationWeights:i,leakyreluAlpha:f});else{let R=d?Ci(d,!1):null,D=new Hc(g,C,R,S,k),P=_();x=e.runWebGLProgram(D,P,\"float32\")}let E=te({inputs:{x},backend:e,attrs:{shape:g.outShape}});return b.push(x),b.forEach(R=>e.disposeIntermediateTensorInfo(R)),E}var yF={kernelName:vo,backendName:\"webgl\",kernelFunc:VJ};function WJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dimRoundingMode:l,activation:m,leakyreluAlpha:d}=o,f=[],h=c;h==null&&(h=[1,1]),y.assert(w.eitherStridesOrDilationsAreOne(p,h),()=>`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${p} and dilations '${h}'`);let g=w.computeConv2DInfo(n.shape,s.shape,p,h,u,l,!0),x=A().getBool(\"WEBGL_PACK_DEPTHWISECONV\")&&g.strideWidth<=2&&g.outChannels/g.inChannels===1,b=m?Ci(m,x):null,C=[n,s],S=a!=null,k=i!=null,_=m===\"leakyrelu\";if(S&&C.push(a),k&&C.push(i),_){let P=e.makeTensorInfo([],\"float32\",y.createScalarValue(d,\"float32\"));C.push(P),f.push(P)}let E;x?E=new jc(g,S,b,k,_):E=new qc(g,S,b,k,_);let R=[[g.padInfo.top,g.padInfo.left],[g.strideHeight,g.strideWidth],[g.dilationHeight,g.dilationWidth],[g.inHeight,g.inWidth]],D=e.runWebGLProgram(E,C,\"float32\",R);return f.forEach(P=>e.disposeIntermediateTensorInfo(P)),D}var bF={kernelName:ko,backendName:\"webgl\",kernelFunc:WJ};var ag=class{constructor(t,e,o,n){this.sliceDim=t,this.strides=e,this.paramsShape=n,this.variableNames=[\"x\",\"indices\"],this.outputShape=o;let s=Re(o.length),a=`\n int index;`;for(let i=0;i= ${this.paramsShape[i]};\n flattenIndex += index * ${this.strides[i]};`;this.userCode=`\n void main() {\n ${s} coords = getOutputCoords();\n int flattenIndex = 0;\n bool out_of_bounds = false;\n\n ${a}\n\n setOutput(out_of_bounds ? 0.0 : getX(flattenIndex, coords[1]));\n }\n `}};function UJ(r){let{inputs:t,backend:e}=r,{params:o,indices:n}=t,s=n.shape,a=s[s.length-1],i=y.sizeFromShape(o.shape),[p,u,c,l]=w.prepareAndValidate(o,n),m=te({inputs:{x:n},backend:e,attrs:{shape:[u,a]}}),d=te({inputs:{x:o},backend:e,attrs:{shape:[y.sizeFromShape(o.shape)/c,c]}});if(e.shouldExecuteOnCPU([o,n])||o.dtype===\"string\"){let x=e.readSync(n.dataId),b=e.bufferSync(o),C=VR(x,b,o.dtype,u,a,c,l,o.shape,i);return e.makeTensorInfo(p,o.dtype,C.values)}let f=new ag(a,l,[u,c],o.shape),h=e.runWebGLProgram(f,[d,m],d.dtype),g=te({inputs:{x:h},backend:e,attrs:{shape:p}});return e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(h),g}var CF={kernelName:kn,backendName:\"webgl\",kernelFunc:UJ};var ig=class{constructor(t,e){this.variableNames=[\"A\",\"indices\"],this.outputShape=e,this.rank=e.length;let o=Re(this.rank),n=GJ(t,2);this.userCode=`\n void main() {\n ${o} resRC = getOutputCoords();\n int index = int(getIndices(resRC.x, resRC.z));\n float inBounds = (index >= 0) && (index < ${t[2]}) ? 1.0 : 0.0;\n setOutput(inBounds * getA(${n}));\n }\n `}};function GJ(r,t){let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],o=[];for(let n=0;n=0,()=>`GatherV2: the index value ${k} is not in [0, ${C-1}]`)}}let u=w.segment_util.collectGatherOpShapeInfo(n,s,p,i),c=y.sizeFromShape(s.shape),l=[],m=te({inputs:{x:n},backend:e,attrs:{shape:[u.batchSize,u.outerSize,u.dimSize,u.sliceSize]}}),d=te({inputs:{x:s},backend:e,attrs:{shape:[u.batchSize,c/u.batchSize]}});l.push(m),l.push(d);let f=[u.batchSize,u.outerSize,c/u.batchSize,u.sliceSize];if(e.shouldExecuteOnCPU([n,s])||n.dtype===\"string\"){let b=e.bufferSync(d),C=e.bufferSync(m),S=WR(C,b,f);return l.forEach(k=>e.disposeIntermediateTensorInfo(k)),e.makeTensorInfo(u.outputShape,S.dtype,S.values)}let h=new ig(m.shape,f),g=e.runWebGLProgram(h,[m,d],m.dtype);l.push(g);let x=te({inputs:{x:g},backend:e,attrs:{shape:u.outputShape}});return l.forEach(b=>e.disposeIntermediateTensorInfo(b)),x}var wF={kernelName:aa,backendName:\"webgl\",kernelFunc:kv};var HJ=\"return float(a > b);\",KJ=`\n return vec4(greaterThan(a, b));\n`,qJ=nt({opSnippet:HJ,packedOpSnippet:KJ,cpuKernelImpl:UR,dtype:\"bool\"}),SF={kernelName:Nn,backendName:\"webgl\",kernelFunc:qJ};var jJ=\"return float(a >= b);\",XJ=`\n return vec4(greaterThanEqual(a, b));\n`,YJ=nt({opSnippet:jJ,packedOpSnippet:XJ,dtype:\"bool\",cpuKernelImpl:GR}),IF={kernelName:Tn,backendName:\"webgl\",kernelFunc:YJ};function QJ(r){let{inputs:t,backend:e}=r,{input:o}=t;return tg(o,!0,e)}var vF={kernelName:Ui,backendName:\"webgl\",kernelFunc:QJ};var ZJ=\"return float(!isnan(x) && !isinf(x));\",JJ=xe({opSnippet:ZJ,dtype:\"bool\"}),kF={kernelName:_n,backendName:\"webgl\",kernelFunc:JJ};var eee=\"return float(isinf(x));\",tee=xe({opSnippet:eee,dtype:\"bool\"}),NF={kernelName:$n,backendName:\"webgl\",kernelFunc:tee};var ree=\"return float(isnan(x));\",oee=xe({opSnippet:ree,dtype:\"bool\"}),TF={kernelName:En,backendName:\"webgl\",kernelFunc:oee};var nee=\"return float(a < b);\",see=`\n return vec4(lessThan(a, b));\n`,aee=nt({opSnippet:nee,packedOpSnippet:see,cpuKernelImpl:HR,dtype:\"bool\"}),_F={kernelName:Dn,backendName:\"webgl\",kernelFunc:aee};var iee=\"return float(a <= b);\",uee=`\n return vec4(lessThanEqual(a, b));\n`,pee=nt({opSnippet:iee,packedOpSnippet:uee,cpuKernelImpl:KR,dtype:\"bool\"}),$F={kernelName:An,backendName:\"webgl\",kernelFunc:pee};function cee(r){let{backend:t,attrs:e}=r,{start:o,stop:n,num:s}=e,a=qR(o,n,s);return t.makeTensorInfo([a.length],\"float32\",a)}var EF={kernelName:Fn,backendName:\"webgl\",kernelFunc:cee};var lee=Po+`\n return x < 0.0 ? 0./0. : log(x);\n`,mee=`\n vec4 result = log(x);\n bvec4 isNaN = isnan(x);\n result.r = isNaN.r ? x.r : (x.r < 0.0 ? 0./0. : result.r);\n result.g = isNaN.g ? x.g : (x.g < 0.0 ? 0./0. : result.g);\n result.b = isNaN.b ? x.b : (x.b < 0.0 ? 0./0. : result.b);\n result.a = isNaN.a ? x.a : (x.a < 0.0 ? 0./0. : result.a);\n return result;\n`,dee=xe({opSnippet:lee,packedOpSnippet:mee,cpuKernelImpl:jR}),RF={kernelName:Pn,backendName:\"webgl\",kernelFunc:dee};var fee=Po+`\n return log(1.0 + x);\n`,hee=xe({opSnippet:fee}),DF={kernelName:On,backendName:\"webgl\",kernelFunc:hee};var gee=\"return float(a >= 1.0 && b >= 1.0);\",xee=`\n return vec4(\n vec4(greaterThanEqual(a, vec4(1.0))) *\n vec4(greaterThanEqual(b, vec4(1.0))));\n`,yee=nt({opSnippet:gee,packedOpSnippet:xee,dtype:\"bool\"}),AF={kernelName:Mn,backendName:\"webgl\",kernelFunc:yee};var bee=\"return float(!(x >= 1.0));\",Cee=xe({opSnippet:bee}),FF={kernelName:Ln,backendName:\"webgl\",kernelFunc:Cee};var wee=\"return float(a >= 1.0 || b >= 1.0);\",See=`\n return min(\n vec4(greaterThanEqual(a, vec4(1.0))) +\n vec4(greaterThanEqual(b, vec4(1.0))),\n vec4(1.0));\n`,Iee=nt({opSnippet:wee,packedOpSnippet:See,dtype:\"bool\"}),PF={kernelName:Bn,backendName:\"webgl\",kernelFunc:Iee};var ug=class{constructor(t,e,o,n,s){this.variableNames=[\"x\"],this.outputShape=[];let a=e,i=t[3]-1;this.outputShape=t;let p,u=`float(${o}) + float(${n}) * sum`;s===.5?p=`inversesqrt(${u})`:s===1?p=`1.0/(${u})`:p=`exp(log(${u}) * float(-${s}));`,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int r = coords[1];\n int c = coords[2];\n int d = coords[3];\n float x = getX(b, r, c, d);\n float sum = 0.0;\n for (int j = -${a}; j <= ${a}; j++) {\n int idx = d + j;\n if (idx >= 0 && idx <= ${i}) {\n float z = getX(b, r, c, idx);\n sum += z * z;\n }\n }\n float val = x * ${p};\n setOutput(val);\n }\n `}};var pg=class{constructor(t,e,o,n,s){this.variableNames=[\"x\"],this.outputShape=[],this.packedInputs=!0,this.packedOutput=!0;let a=e,i=t[3]-1;this.outputShape=t;let p,u=`float(${o}) + float(${n}) * sum`;s===.5?p=`inversesqrt(${u})`:s===1?p=`1.0/(${u})`:p=`exp(log(${u}) * float(-${s}));`,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords.x;\n int r = coords.y;\n int c = coords.z;\n int d = coords.w;\n\n bool hasNextCol = d < ${this.outputShape[3]};\n bool hasNextRow = c < ${this.outputShape[2]};\n\n vec4 sum = vec4(0.);\n vec4 xFragAtOutputCoords = getX(b, r, c, d);\n\n vec4 xAtOutputCoords = vec4(\n getChannel(xFragAtOutputCoords, vec2(c, d)),\n hasNextCol ?\n getChannel(xFragAtOutputCoords, vec2(c, d + 1)) : 0.0,\n hasNextRow ?\n getChannel(xFragAtOutputCoords , vec2(c + 1, d)) : 0.0,\n (hasNextRow && hasNextCol) ?\n getChannel(xFragAtOutputCoords, vec2(c + 1, d + 1)) : 0.0\n );\n\n int firstChannel = d - ${a};\n vec2 cache = vec2(0.);\n if(firstChannel >= 0){\n vec4 firstChannelFrag = getX(b, r, c, firstChannel);\n cache.x = getChannel(firstChannelFrag, vec2(c, firstChannel));\n if(hasNextRow){\n cache.y = getChannel(firstChannelFrag, vec2(c + 1, firstChannel));\n }\n }\n\n ivec2 depth = ivec2(d, d + 1);\n for (int j = - ${a}; j <= ${a}; j++) {\n ivec2 idx = depth + j;\n bvec2 aboveLowerBound = greaterThanEqual(idx, ivec2(0));\n bvec2 belowUpperBound = lessThanEqual(idx, ivec2(${i}));\n\n bool depthInRange = aboveLowerBound.x && belowUpperBound.x;\n bool depthPlusOneInRange = aboveLowerBound.y && belowUpperBound.y;\n\n if(depthInRange || depthPlusOneInRange){\n vec4 z = vec4(0.);\n vec4 xFragAtCurrentDepth;\n z.xz = cache.xy;\n if(depthPlusOneInRange && hasNextCol){\n xFragAtCurrentDepth = idx.y != d ?\n getX(b, r, c, idx.y) : xFragAtOutputCoords;\n z.y = getChannel(xFragAtCurrentDepth, vec2(c, idx.y));\n if(hasNextRow){\n z.w = getChannel(xFragAtCurrentDepth, vec2(c + 1, idx.y));\n }\n }\n cache.xy = z.yw;\n sum += z * z;\n }\n }\n vec4 result = xAtOutputCoords * ${p};\n setOutput(result);\n }\n `}};var vee=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o,u=A().getBool(\"WEBGL_PACK_NORMALIZATION\")?new pg(n.shape,s,a,i,p):new ug(n.shape,s,a,i,p);return e.runWebGLProgram(u,[n],n.dtype)},OF={kernelName:zn,backendName:\"webgl\",kernelFunc:vee};var cg=class{constructor(t,e,o,n,s){this.variableNames=[\"inputImage\",\"outputImage\",\"dy\"],this.outputShape=[],this.outputShape=t,this.depth=t[3],this.depthRadius=e,this.bias=o,this.alpha=n,this.beta=s,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int r = coords[1];\n int c = coords[2];\n\n float result = 0.0;\n for (int d = 0; d < ${this.depth}; ++d) {\n int depthBegin = int(max(0.0, float(d - ${e})));\n int depthEnd = int(min(float(${this.depth}),\n float(d + ${e} + 1)));\n\n const int MIN_DEPTH_BEGIN = 0;\n const int MAX_DEPTH_END = ${this.depth};\n\n float norm = 0.0;\n for (int k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; ++k) {\n if (k < depthBegin){\n continue;\n }\n else if (k >= depthBegin && k < depthEnd) {\n norm += getInputImage(b, r, c, k) * getInputImage(b, r, c, k);\n }\n else {\n break;\n }\n }\n\n norm = float(${n}) * norm + float(${o});\n\n for(int k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; ++k){\n if (k < depthBegin){\n continue;\n }\n else if (k >= depthBegin && k < depthEnd){\n float dyi = -2.0 * float(${n})\n * float(${s})\n * getInputImage(b, r, c, k) * getOutputImage(b, r, c, d)\n / norm;\n if (k == d) {\n dyi += pow(norm, -1.0 * ${s});\n }\n if (k == coords[3]) {\n dyi *= getDy(b, r, c, d);\n result += dyi;\n }\n }\n else {\n break;\n }\n }\n }\n setOutput(result);\n }\n `}};var kee=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n,y:s,dy:a}=t,{depthRadius:i,bias:p,alpha:u,beta:c}=o,l=new cg(n.shape,i,p,u,c);return e.runWebGLProgram(l,[n,s,a],n.dtype)},MF={kernelName:Qa,backendName:\"webgl\",kernelFunc:kee};function LF(r,t,e,o){let n=y.sizeFromShape(t),a=y.sizeFromShape(r.shape)/n,i=te({inputs:{x:r},attrs:{shape:[a,n]},backend:o}),p=Yr(i,r.dtype,\"max\",o),u=te({inputs:{x:p},attrs:{shape:e},backend:o});return o.disposeIntermediateTensorInfo(i),o.disposeIntermediateTensorInfo(p),u}function Nv(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{reductionIndices:s,keepDims:a}=o,i=n.shape.length,p=y.parseAxisParam(s,n.shape),u=p,c=w.getAxesPermutation(u,i),l=c!=null,m=e.shouldExecuteOnCPU([n]),d=n;if(l){if(m){let C=e.texData.get(d.dataId).values,S=new Array(i);for(let E=0;E`Error in maxPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p);if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))return At({inputs:{x:n},backend:e});let l=new Us(c,\"max\",!1);return e.runWebGLProgram(l,[n],n.dtype)}var VF={kernelName:Un,backendName:\"webgl\",kernelFunc:$ee};function Eee(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dataFormat:p,dimRoundingMode:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,u,p),m=new Iu(l,\"max\",!1);return e.runWebGLProgram(m,[n],n.dtype)}var WF={kernelName:ia,backendName:\"webgl\",kernelFunc:Eee};var lg=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.outputShape=t.inShape;let e=t.strideHeight,o=t.strideWidth,n=t.dilationHeight,s=t.effectiveFilterHeight,a=t.effectiveFilterWidth,i=s-1-t.padInfo.top,p=a-1-t.padInfo.left,u=s*a-1;this.userCode=`\n const ivec2 pads = ivec2(${i}, ${p});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n\n ivec2 dyRCCorner = coords.yz - pads;\n int dyRCorner = dyRCCorner.x;\n int dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${s};\n wR += ${n}) {\n float dyR = float(dyRCorner + wR) / ${e}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${a}; wC++) {\n float dyC = float(dyCCorner + wC) / ${o}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(b, idyR, idyC, d);\n int maxPosValue = ${u} - int(getMaxPos(b, idyR, idyC, d));\n\n // Get the current value, check it against the value from the\n // position matrix.\n int curPosValue = wR * ${a} + wC;\n float mask = float(maxPosValue == curPosValue ? 1.0 : 0.0);\n\n dotProd += dyValue * mask;\n }\n }\n setOutput(dotProd);\n }\n `}},mg=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.outputShape=t.inShape;let e=t.strideDepth,o=t.strideHeight,n=t.strideWidth,s=t.dilationDepth,a=t.dilationHeight,i=t.dilationWidth,p=t.effectiveFilterDepth,u=t.effectiveFilterHeight,c=t.effectiveFilterWidth,l=p-1-t.padInfo.front,m=u-1-t.padInfo.top,d=c-1-t.padInfo.left,f=p*u*c-1;this.userCode=`\n const ivec3 pads = ivec3(${l}, ${m}, ${d});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 dyCorner = ivec3(coords.y, coords.z, coords.w) - pads;\n int dyDCorner = dyCorner.x;\n int dyRCorner = dyCorner.y;\n int dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, ch) with pos mask(:, :, :, d) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n\n for (int wD = 0; wD < ${p};\n wD += ${s}) {\n float dyD = float(dyDCorner + wD) / ${e}.0;\n\n if (dyD < 0.0 || dyD >= ${t.outDepth}.0 || fract(dyD) > 0.0) {\n continue;\n }\n int idyD = int(dyD);\n\n for (int wR = 0; wR < ${u};\n wR += ${a}) {\n float dyR = float(dyRCorner + wR) / ${o}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 ||\n fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${c};\n wC += ${i}) {\n float dyC = float(dyCCorner + wC) / ${n}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(batch, idyD, idyR, idyC, ch);\n int maxPosValue = ${f} -\n int(getMaxPos(batch, idyD, idyR, idyC, ch));\n\n // Get the current value, check it against the value from the\n // position matrix.\n int curPosValue =\n wD * ${u} * ${c} +\n wR * ${c} + wC;\n float mask = float(maxPosValue == curPosValue ? 1.0 : 0.0);\n\n dotProd += dyValue * mask;\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function Ree(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=[1,1,1],m=w.computePool3DInfo(a.shape,i,p,l,u,c),d=new Iu(m,\"max\",!0),f=e.runWebGLProgram(d,[a],a.dtype),h=new mg(m),g=e.runWebGLProgram(h,[n,f],a.dtype);return e.disposeIntermediateTensorInfo(f),g}var UF={kernelName:Ki,backendName:\"webgl\",kernelFunc:Ree};function Dee(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s,output:a}=t,i=s;Vs([s,a],\"maxPoolGrad\");let{filterSize:p,strides:u,pad:c,dimRoundingMode:l}=o,m=w.computePool2DInfo(i.shape,p,u,1,c,l),d=!0,f=new Us(m,\"max\",d),h=e.runWebGLProgram(f,[i],i.dtype),g=new lg(m),x=e.runWebGLProgram(g,[n,h],i.dtype);return e.disposeIntermediateTensorInfo(h),x}var GF={kernelName:Hi,backendName:\"webgl\",kernelFunc:Dee};function HF(r,t,e,o){let n=new Us(e,\"max\",!1),s=o.runWebGLProgram(n,[r],\"float32\");n=new Us(e,\"max\",!0,!0,t);let a=o.runWebGLProgram(n,[r],\"float32\");return[s,a]}var KF={kernelName:ua,backendName:\"webgl\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{filterSize:n,strides:s,pad:a,includeBatchInIndex:i}=t,p=e;y.assert(o.shape.length===4,()=>`Error in maxPool: input must be rank 4 but got rank ${o.shape.length}.`);let u=[1,1];y.assert(w.eitherStridesOrDilationsAreOne(s,u),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${s} and dilations '${u}'`);let c=w.computePool2DInfo(o.shape,n,s,u,a),[l,m]=HF(o,i,c,p);return[l,m]}};function qF(r,t,e,o){let n=y.sizeFromShape(t),a=y.sizeFromShape(r.shape)/n,i=te({inputs:{x:r},attrs:{shape:[a,n]},backend:o}),p=Yr(i,\"float32\",\"mean\",o),u=te({inputs:{x:p},attrs:{shape:e},backend:o});return o.disposeIntermediateTensorInfo(i),o.disposeIntermediateTensorInfo(p),u}var jF={kernelName:Gn,backendName:\"webgl\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{keepDims:n,axis:s}=t,a=e,i=o.shape.length,p=y.parseAxisParam(s,o.shape),u=p,c=w.getAxesPermutation(u,i),l=c!=null,m=a.shouldExecuteOnCPU([o]),d=[],f=o;if(l){if(m){let S=a.texData.get(f.dataId).values,k=new Array(i);for(let R=0;Rc[0]+t[l]+c[1]);let n=t.length,s=Re(n),a=e.map(c=>c[0]).join(\",\"),i=e.map((c,l)=>c[0]+t[l]).join(\",\"),p=[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,n),u=o===\"reflect\"?0:1;if(n===1){this.userCode=`\n int start = ${a};\n int end = ${i};\n\n void main() {\n int outC = getOutputCoords();\n if (outC < start) {\n outC = start * 2 - outC - ${u};\n } else if(outC >= end) {\n outC = (end - 1) * 2 - outC + ${u};\n }\n setOutput(getX(outC - start));\n }\n `;return}this.userCode=`\n ${s} start = ${s}(${a});\n ${s} end = ${s}(${i});\n\n void main() {\n ${s} outC = getOutputCoords();\n for (int i = 0; i < ${n}; i++) {\n if (outC[i] < start[i]) {\n outC[i] = start[i] * 2 - outC[i] - ${u};\n } else if(outC[i] >= end[i]) {\n outC[i] = (end[i] - 1) * 2 - outC[i] + ${u};\n }\n }\n ${s} coords = outC - start;\n setOutput(getX(${p}));\n }\n `}};var fg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=e.map((f,h)=>f[0]+t[h]+f[1]);let n=t.length,s=Re(n),a=e.map(f=>f[0]).join(\",\"),i=e.map((f,h)=>f[0]+t[h]).join(\",\"),p=Dt(\"rc\",n),u=Dt(\"source\",n),c=`${p[n-1]} < ${this.outputShape[n-1]}`,l=n===1?\"source\":`vec2(${u.slice(-2).join()})`,m=o===\"reflect\"?0:1,d=\"\";if(n===1){let f=`\n ${s} source = rc;\n if (source < start) {\n source = start * 2 - source - ${m};\n } else if (source >= end) {\n source = (end - 1) * 2 - source + ${m};\n }\n source -= start;\n `;d=`\n ${s} rc = outputLoc;\n ${f}\n result[0] = getChannel(getX(${u.join()}), ${l});\n ${p[n-1]} += 1;\n if(${c}) {\n ${f}\n result[1] = getChannel(getX(${u.join()}), ${l});\n }\n `}else{let f=`\n ${s} source = rc;\n ${s} lt = ${s}(lessThan(source, start));\n ${s} gte = ${s}(greaterThanEqual(source, end));\n ${s} orig = 1 - (lt + gte);\n source = orig * source +\n lt * (start * 2 - source - ${m}) +\n gte * ((end - 1) * 2 - source + ${m});\n source -= start;\n `;d=`\n ${s} rc = outputLoc;\n ${f}\n result[0] = getChannel(getX(${u.join()}), ${l});\n ${p[n-1]} += 1;\n if(${c}) {\n ${f}\n result[1] = getChannel(getX(${u.join()}), ${l});\n }\n rc = outputLoc;\n ${p[n-2]} += 1;\n if(${p[n-2]} < ${this.outputShape[n-2]}) {\n ${f}\n result[2] = getChannel(getX(${u.join()}), ${l});\n ${p[n-1]} += 1;\n if(${c}) {\n ${f}\n result[3] = getChannel(getX(${u.join()}), ${l});\n }\n }\n `}this.userCode=`\n const ${s} start = ${s}(${a});\n const ${s} end = ${s}(${i});\n\n void main() {\n ${s} outputLoc = getOutputCoords();\n vec4 result = vec4(0.);\n ${d}\n setOutput(result);\n }\n `}};var Mee=({inputs:r,backend:t,attrs:e})=>{let{x:o}=r,{paddings:n,mode:s}=e,a=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new fg(o.shape,n,s):new dg(o.shape,n,s);return t.runWebGLProgram(a,[o],o.dtype)},QF={kernelName:qn,backendName:\"webgl\",kernelFunc:Mee};var Lee=`if (b == 0.0) return NAN;\n return mod(a, b);`,Bee=`\n vec4 result = mod(a, b);\n bvec4 isNaN = equal(b, vec4(0.0));\n `+Xr+`\n return result;\n`,zee=nt({opSnippet:Lee,packedOpSnippet:Bee}),ZF={kernelName:jn,backendName:\"webgl\",kernelFunc:zee};var hg=class{constructor(t,e,o){this.variableNames=[\"probs\"],this.customUniforms=[{name:\"seed\",type:\"float\"}],this.outputShape=[t,o],this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n\n float r = random(seed);\n float cdf = 0.0;\n\n for (int i = 0; i < ${e-1}; i++) {\n cdf += getProbs(batch, i);\n\n if (r < cdf) {\n setOutput(float(i));\n return;\n }\n }\n\n // If no other event happened, last event happened.\n setOutput(float(${e-1}));\n }\n `}};var Vee=`\nif (a == b) {\n return 1.0;\n};\nreturn a / b;`,Wee=`\n // vec4 one = vec4(equal(a, b));\n // return one + (vec4(1.0) - one) * a / b;\n vec4 result = a / b;\n if(a.x == b.x) {\n result.x = 1.;\n }\n if(a.y == b.y) {\n result.y = 1.;\n }\n if(a.z == b.z) {\n result.z = 1.;\n }\n if(a.w == b.w) {\n result.w = 1.;\n }\n\n return result;\n`,Tv=nt({opSnippet:Vee,packedOpSnippet:Wee,checkOutOfBounds:!0}),JF={kernelName:hn,backendName:\"webgl\",kernelFunc:Tv};var e3=\"return a - b;\",_v=nt({opSnippet:e3,packedOpSnippet:e3,supportsComplex:!0,cpuKernelImpl:yD}),t3={kernelName:_s,backendName:\"webgl\",kernelFunc:_v};function $v(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{dim:s}=o,a=y.parseAxisParam([s],n.shape),i=Nv({inputs:{x:n},backend:e,attrs:{reductionIndices:a,keepDims:!1}}),p=w.expandShapeToKeepDim(i.shape,a),u=te({inputs:{x:i},backend:e,attrs:{shape:p}}),c=_v({inputs:{a:n,b:u},backend:e}),l=Iv({inputs:{x:c},backend:e}),m=Tp({inputs:{x:l},backend:e,attrs:{axis:a,keepDims:!1}}),d=te({inputs:{x:m},backend:e,attrs:{shape:p}}),f=Tv({inputs:{a:l,b:d},backend:e});return e.disposeIntermediateTensorInfo(i),e.disposeIntermediateTensorInfo(u),e.disposeIntermediateTensorInfo(c),e.disposeIntermediateTensorInfo(l),e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d),f}var r3={kernelName:vs,backendName:\"webgl\",kernelFunc:$v};function Uee(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o,p=i?n:$v({inputs:{logits:n},backend:e,attrs:{dim:n.shape.length-1}}),u=p.shape[0],c=p.shape[1],l=new hg(u,c,s),m=[[a]],d=e.runWebGLProgram(l,[p],\"int32\",m);return i||e.disposeIntermediateTensorInfo(p),d}var o3={kernelName:Xn,backendName:\"webgl\",kernelFunc:Uee};var Gee=Ut+`\n return -x;\n`,Hee=`\n vec4 result = -x;\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`;function Kee(r){let{inputs:t,backend:e}=r,{x:o}=t;if(e.shouldExecuteOnCPU([o])){let s=e.texData.get(o.dataId),[a,i]=JR(s.values,o.shape,o.dtype);return e.makeTensorInfo(i,o.dtype,a)}let n;return A().getBool(\"WEBGL_PACK_UNARY_OPERATIONS\")?n=new Fr(o.shape,Hee):n=new or(o.shape,Gee),e.runWebGLProgram(n,[o],o.dtype)}var n3={kernelName:pa,backendName:\"webgl\",kernelFunc:Kee};var qee=Wt.nonMaxSuppressionV3Impl;function jee(r){w.warn(\"tf.nonMaxSuppression() in webgl locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p}=o,u=e.readSync(n.dataId),c=e.readSync(s.dataId),{selectedIndices:l}=qee(u,c,a,i,p);return e.makeTensorInfo([l.length],\"int32\",new Int32Array(l))}var s3={kernelName:Zn,backendName:\"webgl\",kernelFunc:jee};var Xee=Wt.nonMaxSuppressionV4Impl;function Yee(r){w.warn(\"tf.nonMaxSuppression() in webgl locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p,padToMaxOutputSize:u}=o,c=e.readSync(n.dataId),l=e.readSync(s.dataId),{selectedIndices:m,validOutputs:d}=Xee(c,l,a,i,p,u);return[e.makeTensorInfo([m.length],\"int32\",new Int32Array(m)),e.makeTensorInfo([],\"int32\",new Int32Array([d]))]}var a3={kernelName:Za,backendName:\"webgl\",kernelFunc:Yee};var Qee=Wt.nonMaxSuppressionV5Impl;function Zee(r){w.warn(\"tf.nonMaxSuppression() in webgl locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p,softNmsSigma:u}=o,c=e.readSync(n.dataId),l=e.readSync(s.dataId),m=a,d=i,f=p,h=u,{selectedIndices:g,selectedScores:x}=Qee(c,l,m,d,f,h);return[e.makeTensorInfo([g.length],\"int32\",new Int32Array(g)),e.makeTensorInfo([x.length],\"float32\",new Float32Array(x))]}var i3={kernelName:Jn,backendName:\"webgl\",kernelFunc:Zee};var gg=class{constructor(t,e,o,n){this.variableNames=[\"indices\"],this.outputShape=[t,e],this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int index = round(getIndices(coords.x));\n setOutput(mix(float(${n}), float(${o}),\n float(index == coords.y)));\n }\n `}};var Jee=r=>{let{inputs:t,backend:e,attrs:o}=r,{indices:n}=t,{dtype:s,depth:a,onValue:i,offValue:p}=o,u=y.sizeFromShape(n.shape),c=new gg(u,a,i,p),l=te({inputs:{x:n},backend:e,attrs:{shape:[u]}}),m=e.runWebGLProgram(c,[l],s);e.disposeIntermediateTensorInfo(l);let d=[...n.shape,a],f=te({inputs:{x:m},backend:e,attrs:{shape:d}});return e.disposeIntermediateTensorInfo(m),f},u3={kernelName:es,backendName:\"webgl\",kernelFunc:Jee};function sm(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"complex64\"){let n=wi({inputs:{input:o},backend:e}),s=sm({inputs:{x:n},backend:e}),a=$p({inputs:{input:o},backend:e}),i=sm({inputs:{x:a},backend:e}),p=Or({inputs:{real:s,imag:i},backend:e});return e.disposeIntermediateTensorInfo(n),e.disposeIntermediateTensorInfo(s),e.disposeIntermediateTensorInfo(a),e.disposeIntermediateTensorInfo(i),p}else return Si({attrs:{shape:o.shape,dtype:o.dtype,value:o.dtype===\"string\"?\"\":0},backend:e})}var p3={kernelName:Sa,backendName:\"webgl\",kernelFunc:sm};function c3(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"string\")throw new Error(\"onesLike is not supported under string dtype\");if(o.dtype===\"complex64\"){let n=wi({inputs:{input:o},backend:e}),s=c3({inputs:{x:n},backend:e}),a=$p({inputs:{input:o},backend:e}),i=sm({inputs:{x:a},backend:e}),p=Or({inputs:{real:s,imag:i},backend:e});return e.disposeIntermediateTensorInfo(n),e.disposeIntermediateTensorInfo(s),e.disposeIntermediateTensorInfo(a),e.disposeIntermediateTensorInfo(i),p}else return Si({attrs:{shape:o.shape,dtype:o.dtype,value:1},backend:e})}var l3={kernelName:ca,backendName:\"webgl\",kernelFunc:c3};function ete(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o;if(t.length===1)return eg({inputs:{input:t[0]},backend:e,attrs:{dim:n}});let s=t[0].shape,a=t[0].dtype;t.forEach(c=>{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=eg({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=Sv({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeIntermediateTensorInfo(c)),u}var m3={kernelName:la,backendName:\"webgl\",kernelFunc:ete};var xg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.customUniforms=[{name:\"value\",type:\"float\"}],this.outputShape=e.map((u,c)=>u[0]+t[c]+u[1]);let n=t.length,s=Re(n),a=e.map(u=>u[0]).join(\",\"),i=e.map((u,c)=>u[0]+t[c]).join(\",\"),p=[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,n);if(n===1){this.userCode=`\n int start = ${a};\n int end = ${i};\n\n void main() {\n int outC = getOutputCoords();\n if (outC < start || outC >= end) {\n setOutput(value);\n } else {\n setOutput(getX(outC - start));\n }\n }\n `;return}this.userCode=`\n ${s} start = ${s}(${a});\n ${s} end = ${s}(${i});\n\n void main() {\n ${s} outC = getOutputCoords();\n if (any(lessThan(outC, start)) || any(greaterThanEqual(outC, end))) {\n setOutput(value);\n } else {\n ${s} coords = outC - start;\n setOutput(getX(${p}));\n }\n }\n `}};var yg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"value\",type:\"float\"}],this.outputShape=e.map((h,g)=>h[0]+t[g]+h[1]);let n=t.length,s=Re(n),a=e.map(h=>h[0]).join(\",\"),i=e.map((h,g)=>h[0]+t[g]).join(\",\"),p=Dt(\"rc\",n),u=Dt(\"source\",n),c=`${p[n-1]} < ${this.outputShape[n-1]}`,l=n===1?\"source\":`vec2(${u.slice(-2).join()})`,m=[`${s} rc = outputLoc;`,`${p[n-1]} += 1;\n if(${c}) {\n `,n===1?\"\":`}\n rc = outputLoc;\n ${p[n-2]} += 1;\n if(${p[n-2]} < ${this.outputShape[n-2]}) {`,n===1?\"\":` ${p[n-1]} += 1;\n if(${c}) {`],d=n===1?\"rc < start || rc >= end\":\"any(lessThan(rc, start)) || any(greaterThanEqual(rc, end))\",f=\"\";for(let h=0,g=n===1?2:4;h{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{paddings:s,constantValue:a}=o;if(y.sizeFromShape(n.shape)===0){let u=s.map((c,l)=>c[0]+n.shape[l]+c[1]);return Si({backend:e,attrs:{shape:u,value:a,dtype:n.dtype}})}let i=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new yg(n.shape,s,a):new xg(n.shape,s,a),p=[[a]];return e.runWebGLProgram(i,[n],n.dtype,p)},d3={kernelName:ts,backendName:\"webgl\",kernelFunc:Ev};var tte=`\n if(a < 0.0 && floor(b) < b){\n return NAN;\n }\n if (b == 0.0) {\n return 1.0;\n }\n return (round(mod(b, 2.0)) != 1) ?\n pow(abs(a), b) : sign(a) * pow(abs(a), b);\n`,rte=`\n // isModRound1 has 1 for components with round(mod(b, 2.0)) == 1, 0 otherwise.\n vec4 isModRound1 = vec4(equal(round(mod(b, 2.0)), ivec4(1)));\n vec4 multiplier = sign(a) * isModRound1 + (vec4(1.0) - isModRound1);\n vec4 result = multiplier * pow(abs(a), b);\n\n // Ensure that a^0 = 1, including 0^0 = 1 as this correspond to TF and JS\n bvec4 isExpZero = equal(b, vec4(0.0));\n result.r = isExpZero.r ? 1.0 : result.r;\n result.g = isExpZero.g ? 1.0 : result.g;\n result.b = isExpZero.b ? 1.0 : result.b;\n result.a = isExpZero.a ? 1.0 : result.a;\n\n bvec4 isNaN1 = lessThan(a, vec4(0.0));\n bvec4 isNaN2 = lessThan(floor(b), b);\n bvec4 isNaN = bvec4(isNaN1.x && isNaN2.x, isNaN1.y && isNaN2.y, isNaN1.z && isNaN2.z, isNaN1.w && isNaN2.w);\n `+Xr+`\n return result;\n`,ote=nt({opSnippet:tte,packedOpSnippet:rte}),f3={kernelName:rs,backendName:\"webgl\",kernelFunc:ote};function nte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=n.shape.length,p=[],u=y.parseAxisParam(s,n.shape),c=u,l=w.getAxesPermutation(c,i),m=n;l!=null&&(m=Ct({inputs:{x:n},backend:e,attrs:{perm:l}}),c=w.getInnerMostAxes(c.length,i),p.push(m)),w.assertAxesAreInnerMostDims(\"prod\",c,i);let d;if(e.shouldExecuteOnCPU([m])){let f=e.texData.get(m.dataId).values,{outVals:h,outShape:g,outDtype:x}=tD(m.shape,m.dtype,f,c);d=e.makeTensorInfo(g,x,h)}else{let[f,h]=w.computeOutAndReduceShapes(m.shape,c),g=y.sizeFromShape(h),x=te({inputs:{x:m},backend:e,attrs:{shape:[-1,g]}}),b=ni(n.dtype),C=Yr(x,b,\"prod\",e);d=te({inputs:{x:C},backend:e,attrs:{shape:f}}),p.push(x),p.push(C)}if(a){p.push(d);let f=w.expandShapeToKeepDim(d.shape,u);d=te({inputs:{x:d},backend:e,attrs:{shape:f}})}return p.forEach(f=>e.disposeIntermediateTensorInfo(f)),d}var h3={kernelName:ns,backendName:\"webgl\",kernelFunc:nte};function ste(r){let{inputs:t,backend:e,attrs:o}=r,{paramsNestedSplits:n,paramsDenseValues:s,indices:a}=t,{outputRaggedRank:i}=o,p=n.map(x=>e.readSync(x.dataId)),u=n.map(x=>x.shape),c=e.readSync(s.dataId),l=e.readSync(a.dataId),[m,d,f]=rD(p,u,c,s.shape,s.dtype,l,a.shape,i),h=m.map(x=>e.makeTensorInfo([x.length],\"int32\",x)),g=e.makeTensorInfo(f,s.dtype,d);return h.concat([g])}var g3={kernelName:Qp,backendName:\"webgl\",kernelFunc:ste};function ate(r){let{inputs:t,backend:e}=r,{starts:o,limits:n,deltas:s}=t,a=e.readSync(o.dataId),i=e.readSync(n.dataId),p=e.readSync(s.dataId),[u,c]=oD(a,o.shape,o.dtype,i,n.shape,p,s.shape),l=e.makeTensorInfo([u.length],\"int32\",u),m=e.makeTensorInfo([c.length],o.dtype,c);return[l,m]}var x3={kernelName:Zp,backendName:\"webgl\",kernelFunc:ate};function ite(r){let{inputs:t,backend:e,attrs:o}=r,{shape:n,values:s,defaultValue:a,rowPartitionTensors:i}=t,{rowPartitionTypes:p}=o,u=e.readSync(n.dataId),c=e.readSync(s.dataId),l=e.readSync(a.dataId),m=i.map(g=>e.readSync(g.dataId)),d=i.map(g=>g.shape),[f,h]=nD(u,n.shape,c,s.shape,s.dtype,l,a.shape,m,d,p);return e.makeTensorInfo(f,s.dtype,h)}var y3={kernelName:Jp,backendName:\"webgl\",kernelFunc:ite};var Rv=r=>{let{backend:t,attrs:e}=r,{start:o,stop:n,step:s,dtype:a}=e,i=sD(o,n,s,a);return t.makeTensorInfo([i.length],a,i)},b3={kernelName:ma,backendName:\"webgl\",kernelFunc:Rv};var ute=\"return 1.0 / x;\",pte=xe({opSnippet:ute}),C3={kernelName:ss,backendName:\"webgl\",kernelFunc:pte};var cte=Ut+`\n return (x < 0.0) ? 0.0 : x;\n`,lte=`\n vec4 result = x * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,mte=xe({opSnippet:cte,packedOpSnippet:lte}),w3={kernelName:as,backendName:\"webgl\",kernelFunc:mte};var dte=Ut+`\n return (x < 0.0) ? 0.0 : min(6.0, x);\n`,fte=`\n vec4 result = min(x, vec4(6.)) * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,hte=xe({opSnippet:dte,packedOpSnippet:fte}),S3={kernelName:ps,backendName:\"webgl\",kernelFunc:hte};var bg=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m;s?m=\"(vec2(yRC) + vec2(0.5)) * effectiveInputOverOutputRatioRC - vec2(0.5)\":m=\"vec2(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec2 effectiveInputOverOutputRatioRC = vec2(\n ${c[0]/l[0]},\n ${c[1]/l[1]});\n const vec2 inputShapeRC = vec2(${i}.0, ${p}.0);\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n ivec2 yRC = coords.yz;\n\n // Fractional source index.\n vec2 sourceFracIndexRC = ${m};\n\n // Compute the four integer indices.\n ivec2 sourceFloorRC = ivec2(max(sourceFracIndexRC, vec2(0.0)));\n ivec2 sourceCeilRC = ivec2(\n min(inputShapeRC - 1.0, ceil(sourceFracIndexRC)));\n\n float topLeft = getA(b, sourceFloorRC.x, sourceFloorRC.y, d);\n float bottomLeft = getA(b, sourceCeilRC.x, sourceFloorRC.y, d);\n float topRight = getA(b, sourceFloorRC.x, sourceCeilRC.y, d);\n float bottomRight = getA(b, sourceCeilRC.x, sourceCeilRC.y, d);\n\n vec2 fracRC = sourceFracIndexRC - vec2(sourceFloorRC);\n\n float top = topLeft + (topRight - topLeft) * fracRC.y;\n float bottom = bottomLeft + (bottomRight - bottomLeft) * fracRC.y;\n float newValue = top + (bottom - top) * fracRC.x;\n\n setOutput(newValue);\n }\n `}};var Cg=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m;s?m=\"(vec3(yRC) + vec3(0.5)) * effectiveInputOverOutputRatioRC - vec3(0.5)\":m=\"vec3(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec3 effectiveInputOverOutputRatioRC = vec3(\n ${c[0]/l[0]},\n ${c[1]/l[1]},\n ${c[1]/l[1]});\n const vec3 inputShapeRC = vec3(${i}.0, ${p}.0,\n ${p}.0);\n\n float getAValue(int b, int r, int c, int d) {\n return getChannel(getA(b, r, c, d), vec2(c, d));\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n // Calculate values for next column in yRC.z.\n ivec3 yRC = coords.yzz + ivec3(0, 0, 1);\n\n // Fractional source index.\n vec3 sourceFracIndexRC = ${m};\n\n // Compute the four integer indices.\n ivec3 sourceFloorRC = ivec3(max(sourceFracIndexRC, vec3(0.0)));\n ivec3 sourceCeilRC = ivec3(\n min(inputShapeRC - 1.0, ceil(sourceFracIndexRC)));\n\n // Should we calculate next column and row elements in 2x2 packed cell.\n bool hasNextCol = d < ${u-1};\n bool hasNextRow = coords.z < ${o-1};\n\n // In parallel, construct four corners for all four components in\n // packed 2x2 cell.\n vec4 topLeft = vec4(\n getAValue(b, sourceFloorRC.x, sourceFloorRC.y, d),\n hasNextCol ? getAValue(b, sourceFloorRC.x, sourceFloorRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceFloorRC.x, sourceFloorRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceFloorRC.x, sourceFloorRC.z, d + 1) : 0.0);\n\n vec4 bottomLeft = vec4(\n getAValue(b, sourceCeilRC.x, sourceFloorRC.y, d),\n hasNextCol ? getAValue(b, sourceCeilRC.x, sourceFloorRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceCeilRC.x, sourceFloorRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceCeilRC.x, sourceFloorRC.z, d + 1) : 0.0);\n\n vec4 topRight = vec4(\n getAValue(b, sourceFloorRC.x, sourceCeilRC.y, d),\n hasNextCol ? getAValue(b, sourceFloorRC.x, sourceCeilRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceFloorRC.x, sourceCeilRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceFloorRC.x, sourceCeilRC.z, d + 1) : 0.0);\n\n vec4 bottomRight = vec4(\n getAValue(b, sourceCeilRC.x, sourceCeilRC.y, d),\n hasNextCol ? getAValue(b, sourceCeilRC.x, sourceCeilRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceCeilRC.x, sourceCeilRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceCeilRC.x, sourceCeilRC.z, d + 1) : 0.0);\n\n vec3 fracRC = sourceFracIndexRC - vec3(sourceFloorRC);\n\n vec4 top = mix(topLeft, topRight, fracRC.yyzz);\n vec4 bottom = mix(bottomLeft, bottomRight, fracRC.yyzz);\n vec4 newValue = mix(top, bottom, fracRC.x);\n\n setOutput(newValue);\n }\n `}};function gte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,c=A().getBool(\"WEBGL_PACK_IMAGE_OPERATIONS\")?new Cg(n.shape,p,u,s,a):new bg(n.shape,p,u,s,a);return e.runWebGLProgram(c,[n],\"float32\")}var I3={kernelName:us,backendName:\"webgl\",kernelFunc:gte};var wg=class{constructor(t,e,o){this.variableNames=[\"dy\"],this.outputShape=[],this.outputShape=e;let[,n,s]=e,[,a,i]=t,p=[o&&a>1?n-1:n,o&&i>1?s-1:s],u=[o&&a>1?a-1:a,o&&i>1?i-1:i],c=p[0]/u[0],l=p[1]/u[1],m=1/c,d=1/l,f=Math.ceil(m)*2+2,h=Math.ceil(d)*2+2;this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n int r = coords[1];\n int c = coords[2];\n\n float accumulator = 0.0;\n\n const float heightScale = float(${c});\n const float widthScale = float(${l});\n\n const float invHeightScale = float(${m});\n const float invWidthScale = float(${d});\n\n const int winHeight = int(${f});\n const int winWidth = int(${h});\n\n // Compute bounds for where in dy we will look\n float startRLerp = floor(float(r) * invHeightScale);\n int startDyR = int(startRLerp - float(winHeight / 2));\n\n float startCLerp = floor(float(c) * invWidthScale);\n int startDyC = int(startCLerp - float(winWidth / 2));\n\n // Loop over dy\n for (int dyROffset = 0; dyROffset < winHeight; dyROffset++) {\n int dyR = dyROffset + startDyR;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= ${a}) {\n continue;\n }\n\n for (int dyCOffset = 0; dyCOffset < winWidth; dyCOffset++) {\n int dyC = dyCOffset + startDyC;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= ${i}) {\n continue;\n }\n\n float dxR = float(dyR) * heightScale;\n int topDxRIndex = int(floor(dxR));\n int bottomDxRIndex = int(min(ceil(dxR), ${n-1}.0));\n float dxRLerp = dxR - float(topDxRIndex);\n float inverseDxRLerp = 1.0 - dxRLerp;\n\n float dxC = float(dyC) * widthScale;\n int leftDxCIndex = int(floor(dxC));\n int rightDxCIndex = int(min(ceil(dxC), ${s-1}.0));\n float dxCLerp = dxC - float(leftDxCIndex);\n float inverseDxCLerp = 1.0 - dxCLerp;\n\n if (r == topDxRIndex && c == leftDxCIndex) {\n // topLeft\n accumulator +=\n getDy(b, dyR, dyC, d) * inverseDxRLerp * inverseDxCLerp;\n }\n\n if (r == topDxRIndex && c == rightDxCIndex) {\n // topRight\n accumulator += getDy(b, dyR, dyC, d) * inverseDxRLerp * dxCLerp;\n }\n\n if (r == bottomDxRIndex && c == leftDxCIndex) {\n // bottomLeft\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * inverseDxCLerp;\n }\n\n if (r == bottomDxRIndex && c == rightDxCIndex) {\n // bottomRight\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * dxCLerp;\n }\n }\n }\n // End loop over dy\n\n setOutput(accumulator);\n }\n `}};function xte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=new wg(s.shape,n.shape,a);return e.runWebGLProgram(i,[s],s.dtype)}var v3={kernelName:ei,backendName:\"webgl\",kernelFunc:xte};var Sg=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m=n?\"0.5\":\"0.0\",d;s?d=\"max((vec2(yRC) + vec2(0.5)) * effectiveInputOverOutputRatioRC, vec2(0.0))\":d=\"vec2(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec2 effectiveInputOverOutputRatioRC = vec2(\n ${c[0]/l[0]},\n ${c[1]/l[1]});\n const vec2 inputShapeRC = vec2(${i}.0, ${p}.0);\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n ivec2 yRC = coords.yz;\n\n // Fractional source index.\n vec2 sourceFracIndexRC = ${d};\n\n // Compute the coordinators of nearest neighbor point.\n ivec2 sourceNearestRC = ivec2(\n min(inputShapeRC - 1.0, floor(sourceFracIndexRC + ${m})));\n float newValue = getA(b, sourceNearestRC.x, sourceNearestRC.y, d);\n\n setOutput(newValue);\n }\n `}};var Ig=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m=n?\"0.5\":\"0.0\",d;s?d=\"max((vec3(yRC) + vec3(0.5)) * effectiveInputOverOutputRatioRC, vec3(0.0))\":d=\"vec3(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec3 effectiveInputOverOutputRatioRC = vec3(\n ${c[0]/l[0]},\n ${c[1]/l[1]},\n ${c[1]/l[1]});\n const vec3 inputShapeRC = vec3(${i}.0, ${p}.0,\n ${p}.0);\n\n float getAValue(int b, int r, int c, int d) {\n return getChannel(getA(b, r, c, d), vec2(c, d));\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n // Calculate values for next column in yRC.z.\n ivec3 yRC = coords.yzz + ivec3(0, 0, 1);\n\n // Fractional source index.\n vec3 sourceFracIndexRC = ${d};\n\n // Compute the coordinators of nearest neighbor point.\n ivec3 sourceNearestRC = ivec3(\n min(inputShapeRC - 1.0, floor(sourceFracIndexRC + ${m})));\n\n // Should we calculate next column and row elements in 2x2 packed cell.\n bool hasNextCol = d < ${u-1};\n bool hasNextRow = coords.z < ${o-1};\n\n vec4 newValue = vec4(\n getAValue(b, sourceNearestRC.x, sourceNearestRC.y, d),\n hasNextCol ? getAValue(b, sourceNearestRC.x, sourceNearestRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceNearestRC.x, sourceNearestRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceNearestRC.x, sourceNearestRC.z, d + 1) : 0.0);\n\n setOutput(newValue);\n }\n `}};function yte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,c=A().getBool(\"WEBGL_PACK_IMAGE_OPERATIONS\")?new Ig(n.shape,p,u,s,a):new Sg(n.shape,p,u,s,a);return e.runWebGLProgram(c,[n],n.dtype)}var k3={kernelName:is,backendName:\"webgl\",kernelFunc:yte};var vg=class{constructor(t,e,o){this.variableNames=[\"dy\"],this.outputShape=[],this.outputShape=e;let[,n,s]=e,[,a,i]=t,p=[o&&a>1?n-1:n,o&&i>1?s-1:s],u=[o&&a>1?a-1:a,o&&i>1?i-1:i],c=p[0]/u[0],l=p[1]/u[1],m=1/c,d=1/l,f=Math.ceil(m)*2+2,h=Math.ceil(d)*2+2;this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n int r = coords[1];\n int c = coords[2];\n\n float accumulator = 0.0;\n\n const float heightScale = float(${c});\n const float widthScale = float(${l});\n\n const float invHeightScale = float(${m});\n const float invWidthScale = float(${d});\n\n const int winHeight = int(${f});\n const int winWidth = int(${h});\n\n // Compute bounds for where in dy we will look\n float startRLerp = floor(float(r) * invHeightScale);\n int startDyR = int(floor(startRLerp - float(winHeight / 2)));\n\n float startCLerp = floor(float(c) * invWidthScale);\n int startDyC = int(floor(startCLerp - float(winWidth / 2)));\n\n // Loop over dy\n for (int dyROffset = 0; dyROffset < winHeight; dyROffset++) {\n int dyR = dyROffset + startDyR;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= ${a}) {\n continue;\n }\n\n for (int dyCOffset = 0; dyCOffset < winWidth; dyCOffset++) {\n int dyC = dyCOffset + startDyC;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= ${i}) {\n continue;\n }\n\n float sourceFracRow =\n float(${p[0]}) *\n (float(dyR) / float(${u[0]}));\n\n float sourceFracCol =\n float(${p[1]}) *\n (float(dyC) / float(${u[1]}));\n\n int sourceNearestRow = int(min(\n float(int(${n}) - 1),\n ${o} ? float(round(sourceFracRow)) :\n float(floor(sourceFracRow))));\n\n int sourceNearestCol = int(min(\n float(int(${s}) - 1),\n ${o} ? float(round(sourceFracCol)) :\n float(floor(sourceFracCol))));\n\n if (r == sourceNearestRow && c == sourceNearestCol) {\n accumulator += getDy(b, dyR, dyC, d);\n }\n }\n }\n // End loop over dy\n\n setOutput(accumulator);\n }\n `}};function bte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=new vg(s.shape,n.shape,a);return e.runWebGLProgram(i,[s],s.dtype)}var N3={kernelName:Ja,backendName:\"webgl\",kernelFunc:bte};var kg=class{constructor(t,e){this.variableNames=[\"x\"];let o=t.length;if(o>4)throw new Error(`WebGL backend: Reverse of rank-${o} tensor is not yet supported`);if(this.outputShape=t,o===1){this.userCode=`\n void main() {\n int coord = getOutputCoords();\n setOutput(getX(${t[0]} - coord - 1));\n }\n `;return}let n=i=>e.indexOf(i)!==-1&&t[i]!==1?`${t[i]} - coords[${i}] - 1`:`coords[${i}]`,s=t.map((i,p)=>n(p)).join(\",\"),a=Re(o);this.userCode=`\n void main() {\n ${a} coords = getOutputCoords();\n setOutput(getX(${s}));\n }\n `}};var Ng=class{constructor(t,e){this.variableNames=[\"x\"],this.packedInputs=!0,this.packedOutput=!0;let o=t.length;if(o>4)throw new Error(`WebGL backend: Reverse of rank-${o} tensor is not yet supported`);this.outputShape=t;let n=Dt(\"rc\",o),s=`${n[o-1]} + 1 < ${this.outputShape[o-1]}`,a=`${n[o-2]} + 1 < ${this.outputShape[o-2]}`,i=Re(o);o===1?this.userCode=`\n void main(){\n int rc = getOutputCoords();\n vec4 result = vec4(0.);\n result.r = getChannel(getX(${t[0]} - rc - 1),\n ${t[0]} - rc - 1);\n if(${s}){\n result.g = getChannel(getX(${t[0]} - (rc + 1) - 1),\n ${t[0]} - (rc + 1) - 1);\n }\n setOutput(result);\n }\n `:this.userCode=`\n void main() {\n ${i} rc = getOutputCoords();\n vec4 result = vec4(0.);\n result.r = ${p(n.slice())};\n if(${s}){\n result.g = ${u(n.slice())};\n }\n if(${a}) {\n result.b = ${c(n.slice())};\n if(${s}) {\n result.a = ${l(n.slice())};\n }\n }\n setOutput(result);\n }\n `;function p(f){return m(f)}function u(f){return f[o-1]=\"(\"+f[o-1]+\" + 1)\",m(f)}function c(f){return f[o-2]=\"(\"+f[o-2]+\" + 1)\",m(f)}function l(f){return f[o-1]=\"(\"+f[o-1]+\" + 1)\",f[o-2]=\"(\"+f[o-2]+\" + 1)\",m(f)}function m(f){let h=t.map((b,C)=>d(C,f)),g=h.join(\",\"),x=h.slice(-2).join(\",\");return`getChannel(getX(${g}), vec2(${x}))`}function d(f,h){return e.indexOf(f)!==-1&&t[f]!==1?`${t[f]} - ${h[f]} - 1`:`${h[f]}`}}};function Cte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o,a=n.shape.length,i=y.parseAxisParam(s,n.shape);if(a===0)return At({inputs:{x:n},backend:e});let p=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new Ng(n.shape,i):new kg(n.shape,i);return e.runWebGLProgram(p,[n],n.dtype)}var T3={kernelName:cs,backendName:\"webgl\",kernelFunc:Cte};var Tg=class{constructor(t,e){this.variableNames=[\"Image\"],this.outputShape=[],this.customUniforms=[{name:\"params\",type:\"vec4\"}];let o=t[1],n=t[2];this.outputShape=t;let s=\"\";typeof e==\"number\"?s=`float outputValue = ${e.toFixed(2)};`:s=`\n vec3 fill = vec3(${e.join(\",\")});\n float outputValue = fill[coords[3]];`,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int x = coords[2];\n int y = coords[1];\n float coordXFloat = (float(x) - params[0]) * params[3] -\n (float(y) - params[1]) * params[2];\n float coordYFloat = (float(x) - params[0]) * params[2] +\n (float(y) - params[1]) * params[3];\n int coordX = int(round(coordXFloat + params[0]));\n int coordY = int(round(coordYFloat + params[1]));\n ${s}\n if(coordX >= 0 && coordX < ${n} && coordY >= 0 && coordY < ${o}) {\n outputValue = getImage(coords[0], coordY, coordX, coords[3]);\n }\n setOutput(outputValue);\n }\n `}};var _3={kernelName:As,backendName:\"webgl\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{image:o}=r,{radians:n,fillValue:s,center:a}=t,i=e,p=new Tg(o.shape,s),[u,c]=w.getImageCenter(a,o.shape[1],o.shape[2]),l=[[u,c,Math.sin(n),Math.cos(n)]];return i.runWebGLProgram(p,[o],o.dtype,l)}};var wte=`\n // OpenGL ES does not support round function.\n // The algorithm is based on banker's rounding.\n float base = floor(x);\n if ((x - base) < 0.5) {\n return floor(x);\n } else if ((x - base) > 0.5) {\n return ceil(x);\n } else {\n if (mod(base, 2.0) == 0.0) {\n return base;\n } else {\n return base + 1.0;\n }\n }\n`,Ste=xe({opSnippet:wte}),$3={kernelName:ls,backendName:\"webgl\",kernelFunc:Ste};var Ite=\"return inversesqrt(x);\",vte=xe({opSnippet:Ite,cpuKernelImpl:aD}),E3={kernelName:ms,backendName:\"webgl\",kernelFunc:vte};var vu=class{constructor(t,e,o,n,s,a,i=!0,p=!1){this.variableNames=[\"updates\",\"indices\",\"defaultValue\"],this.outputShape=a;let u=Re(s.length),c=Re(a.length),l=\"\";o===1?l=\"i\":o===2&&(l=\"i, j\");let m=`getIndices(${l})`,d=\"\";n===1?d=\"i\":n===2&&(d=\"i, coords[1]\");let f=`getUpdates(${d})`,h=\"\";p&&(h=\"coords[0], coords[1]\");let g=`getDefaultValue(${h})`,x=e>1?\"strides[j]\":\"strides\";this.userCode=`\n ${u} strides = ${u}(${s});\n\n void main() {\n ${c} coords = getOutputCoords();\n float sum = 0.0;\n bool found = false;\n for (int i = 0; i < ${t}; i++) {\n int flattenedIndex = 0;\n for (int j = 0; j < ${e}; j++) {\n int index = round(${m});\n flattenedIndex += index * ${x};\n }\n if (flattenedIndex == coords[0]) {\n sum += ${f};\n found = true;\n }\n }\n setOutput(mix(${g}, sum, float(found)));\n }\n `}};var _g=class{constructor(t,e,o,n,s,a,i=!0,p=!1){this.variableNames=[\"updates\",\"indices\",\"defaultValue\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=a;let u=Re(s.length),c=Re(a.length),l=\"\";o===1?l=\"i\":o===2&&(l=\"i, j\");let m=`getIndices(${l})`,d=\"\";n===1?d=\"i\":n===2&&(d=\"i, coords[1]\");let f=`getUpdates(${d})`,h=\"\";p&&(h=\"coords[0], coords[1]\");let g=`getDefaultValue(${h})`,x=e>1?\"strides[j]\":\"strides\",b=e>1?\"strides[j + 1]\":\"strides\";this.userCode=`\n ${u} strides = ${u}(${s});\n\n void main() {\n ${c} coords = getOutputCoords();\n vec4 sum = vec4(0.);\n vec4 found = vec4(0.);\n for (int i = 0; i < ${t}; i+=2) {\n ivec2 flattenedIndex = ivec2(0);\n for (int j = 0; j < ${e}; j+=2) {\n ivec4 index = round(${m});\n flattenedIndex += index.xz * ${x};\n if (j + 1 < ${e}) {\n flattenedIndex += index.yw * ${b};\n }\n }\n if (flattenedIndex[0] == coords[0] || flattenedIndex[1] == coords[0] ||\n flattenedIndex[0] == coords[0] + 1 || flattenedIndex[1] == coords[0] + 1) {\n vec4 updVals = ${f};\n if (flattenedIndex[0] == coords[0]) {\n sum.xy += updVals.xy;\n found.xy = vec2(1.);\n } else if (flattenedIndex[0] == coords[0] + 1) {\n sum.zw += updVals.xy;\n found.zw = vec2(1.);\n }\n if (flattenedIndex[1] == coords[0]) {\n sum.xy += updVals.zw;\n found.xy = vec2(1.);\n } else if (flattenedIndex[1] == coords[0] + 1) {\n sum.zw += updVals.zw;\n found.zw = vec2(1.);\n }\n }\n }\n setOutput(mix(${g}, sum, found));\n }\n `}};function kte(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n,updates:s}=t,{shape:a}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(s,n,a),m=[l/u,u];if(l===0)return e.makeTensorInfo(a,n.dtype);let d=te({inputs:{x:n},backend:e,attrs:{shape:[p,i]}}),f=te({inputs:{x:s},backend:e,attrs:{shape:[p,u]}}),h=e.makeTensorInfo([],\"float32\",new Float32Array([0])),g;A().getBool(\"WEBGL_PACK\")?g=new _g(p,i,d.shape.length,f.shape.length,c,m):g=new vu(p,i,d.shape.length,f.shape.length,c,m);let x=e.runWebGLProgram(g,[f,d,h],f.dtype),b=te({inputs:{x},backend:e,attrs:{shape:a}});return e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(x),e.disposeIntermediateTensorInfo(h),b}var R3={kernelName:ds,backendName:\"webgl\",kernelFunc:kte};var $g=class{constructor(t,e,o,n){this.variableNames=[\"sortedSequence\",\"values\"],this.customUniforms=[{name:\"numInputs\",type:\"int\"}],this.outputShape=[t,o];let s=\"while (left < right) {\",a=`for (int i = 0; i < ${Math.ceil(Math.log2(e+1))}; ++i) { if (left >= right) break;`,i=A().getNumber(\"WEBGL_VERSION\")===2?s:a,p=n===\"left\"?\"<\":\"<=\";this.userCode=`\n int findBound(int batch, float value) {\n int left = 0;\n int right = numInputs;\n int mid;\n ${i}\n mid = (left + right) / 2;\n if (getSortedSequence(batch, mid) ${p} value) {\n left = mid + 1;\n } else {\n right = mid;\n }\n }\n return right;\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int valueIndex = coords[1];\n\n float value = getValues(batch, valueIndex);\n\n setOutput(float(findBound(batch, value)));\n }\n `}};function Nte(r){let{inputs:t,backend:e,attrs:o}=r,{sortedSequence:n,values:s}=t,{side:a}=o,i=new $g(n.shape[0],n.shape[1],s.shape[1],a),p=[[n.shape[1]]];return e.runWebGLProgram(i,[n,s],\"int32\",p)}var D3={kernelName:hs,backendName:\"webgl\",kernelFunc:Nte};var Eg=class{constructor(t,e,o){this.variableNames=[\"c\",\"a\",\"b\"],this.outputShape=e;let n,s;if(o>4)throw Error(`Where for rank ${o} is not yet supported`);if(o===1)s=\"resRC\",n=\"resRC\";else{let i=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],p=[],u=[];for(let c=0;c= 1.0) {\n setOutput(getA(${s}));\n } else {\n setOutput(getB(${s}));\n }\n }\n `}};function Tte(r){let{inputs:t,backend:e}=r,{condition:o,t:n,e:s}=t,a=new Eg(o.shape.length,n.shape,n.shape.length);return e.runWebGLProgram(a,[o,n,s],dt(n.dtype,s.dtype))}var A3={kernelName:fa,backendName:\"webgl\",kernelFunc:Tte};var _te=`\n // Stable and Attracting Fixed Point (0, 1) for Normalized Weights.\n // see: https://arxiv.org/abs/1706.02515\n float scaleAlpha = ${w.SELU_SCALEALPHA};\n float scale = ${w.SELU_SCALE};\n return (x >= 0.0) ? scale * x : scaleAlpha * (exp(x) - 1.0);\n`,$te=xe({opSnippet:_te}),F3={kernelName:gs,backendName:\"webgl\",kernelFunc:$te};var Ete=Po+`\n return 1.0 / (1.0 + exp(-1.0 * x));\n`,Rte=`\n vec4 result = 1.0 / (1.0 + exp(-1.0 * x));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,Dte=xe({opSnippet:Ete,packedOpSnippet:Rte,cpuKernelImpl:uD}),P3={kernelName:Cs,backendName:\"webgl\",kernelFunc:Dte};var Ate=`\n if (isnan(x)) { return 0.0; }\n return sign(x);\n`,Fte=xe({opSnippet:Ate}),O3={kernelName:bs,backendName:\"webgl\",kernelFunc:Fte};var Pte=Po+`\n return sin(x);\n`,Ote=`\n vec4 result = sin(x);\n bvec4 isNaN = isnan(x);\n ${Xr}\n return result;\n`,Mte=xe({opSnippet:Pte,packedOpSnippet:Ote}),M3={kernelName:xs,backendName:\"webgl\",kernelFunc:Mte};var Lte=`\n float e2x = exp(x);\n return (e2x - 1.0 / e2x) / 2.0;\n`,Bte=xe({opSnippet:Lte}),L3={kernelName:ys,backendName:\"webgl\",kernelFunc:Bte};var zte=`\n float epsilon = 1.1920928955078125e-7;\n float threshold = log(epsilon) + 2.0;\n\n bool too_large = x > -threshold;\n bool too_small = x < threshold;\n\n float result;\n float exp_x = exp(x);\n\n if (too_large){\n result = x;\n }\n else if (too_small){\n result = exp_x;\n }\n else{\n result = log(exp_x + 1.0);\n }\n return result;\n`,Vte=xe({opSnippet:zte}),B3={kernelName:ws,backendName:\"webgl\",kernelFunc:Vte};var Wte=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,paddings:a}=o;y.assert(n.shape.length<=4,()=>\"spaceToBatchND for rank > 4 with a WebGL backend not implemented yet\");let i=s.reduce((x,b)=>x*b),p=[[0,0]];p.push(...a);for(let x=1+s.length;xe.disposeIntermediateTensorInfo(x)),g},z3={kernelName:ga,backendName:\"webgl\",kernelFunc:Wte};function Ute(r){let{inputs:t,backend:e}=r,{indices:o,values:n,denseShape:s,defaultValue:a}=t;if(s.shape.length!==1)throw new Error(`Dense shape must be a vector, saw:\n ${s.shape}`);if(o.shape.length!==2)throw new Error(`Indices must be a matrix, saw:\n ${o.shape}`);if(n.shape.length!==1)throw new Error(`Values must be a vector, saw:\n ${n.shape}`);if(a.shape.length!==0)throw new Error(`Default value must be a scalar, saw:\n ${a.shape}`);let i=e.readSync(o.dataId),p=e.readSync(n.dataId),u=e.readSync(s.dataId),c=e.readSync(a.dataId)[0],[l,m,d,f,h]=cD(i,o.shape,o.dtype,p,n.dtype,u,c);return[e.makeTensorInfo(m,o.dtype,l),e.makeTensorInfo([m[0]],n.dtype,d),e.makeTensorInfo([f.length],\"bool\",new Uint8Array(f.map(g=>Number(g)))),e.makeTensorInfo([h.length],o.dtype,new Int32Array(h))]}var V3={kernelName:ji,backendName:\"webgl\",kernelFunc:Ute};function Gte(r){let{inputs:t,backend:e}=r,{inputIndices:o,inputShape:n,newShape:s}=t;if(o.shape.length!==2)throw new Error(`Input indices should be a matrix but received shape ${o.shape}`);if(n.shape.length!==1)throw new Error(`Input shape should be a vector but received shape ${n.shape}`);if(s.shape.length!==1)throw new Error(`Target shape should be a vector but received shape ${s.shape}`);let a=Array.from(e.readSync(n.dataId)),i=e.readSync(o.dataId),p=Array.from(e.readSync(s.dataId)),[u,c,l]=lD(i,o.shape,o.dtype,a,p);return[e.makeTensorInfo(c,o.dtype,u),e.makeTensorInfo([l.length],s.dtype,new Int32Array(l))]}var W3={kernelName:ti,backendName:\"webgl\",kernelFunc:Gte};function Hte(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);let a=e.readSync(o.dataId),i=e.readSync(n.dataId),p=e.readSync(s.dataId),[u,c]=lh(a,o.shape,o.dtype,i,p,!0);return e.makeTensorInfo(c,o.dtype,u)}var U3={kernelName:ya,backendName:\"webgl\",kernelFunc:Hte};function Kte(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);let a=e.readSync(o.dataId),i=e.readSync(n.dataId),p=e.readSync(s.dataId),[u,c]=lh(a,o.shape,o.dtype,i,p);return e.makeTensorInfo(c,o.dtype,u)}var G3={kernelName:ba,backendName:\"webgl\",kernelFunc:Kte};function qte(r){let{inputs:t,backend:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=t,{outputShape:i}=o,{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=w.calculateShapes(s,n,i),d=!1;if(s.dtype===\"string\"){let x=e.bufferSync(n),b=e.bufferSync(s),C=y.decodeString(e.readSync(a.dataId)[0]),S=iD(x,b,i,m,c,u,p,l,C,d);return e.makeTensorInfo(i,S.dtype,S.values)}let f=new vu(u,p,n.shape.length,s.shape.length,l,[m,1],d),h=e.runWebGLProgram(f,[s,n,a],s.dtype),g=te({inputs:{x:h},backend:e,attrs:{shape:i}});return e.disposeIntermediateTensorInfo(h),g}var H3={kernelName:ks,backendName:\"webgl\",kernelFunc:qte};function jte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=o,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=n.shape.length,c=new Array(u).fill(0),l=n.shape.slice();return p.map(m=>{let d=[...l];d[i]=m;let f=Gs({inputs:{x:n},backend:e,attrs:{begin:c,size:d}});return c[i]+=m,f})}var K3={kernelName:xa,backendName:\"webgl\",kernelFunc:jte};var q3=\"return sqrt(x);\",Xte=xe({opSnippet:q3,packedOpSnippet:q3,cpuKernelImpl:mD}),j3={kernelName:Ss,backendName:\"webgl\",kernelFunc:Xte};var Yte=\"return x * x;\",Qte=xe({opSnippet:Yte}),X3={kernelName:Xi,backendName:\"webgl\",kernelFunc:Qte};var Y3=\"return (a - b) * (a - b);\",Zte=nt({opSnippet:Y3,packedOpSnippet:Y3}),Q3={kernelName:Ns,backendName:\"webgl\",kernelFunc:Zte};function Jte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t;if(n.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");let s=e.readSync(n.dataId),a=w.fromUint8ToStringArray(s),i=dD(a,\"string\",o);return e.makeTensorInfo(n.shape,\"string\",i)}var Z3={kernelName:Ou,backendName:\"webgl\",kernelFunc:Jte};function ere({inputs:r,attrs:t,backend:e}){let{x:o}=r,n=Ut+`\n return x > 0.0 ? 1.0 : float(${t.alpha});\n `,s=new or(o.shape,n);return e.runWebGLProgram(s,[o],o.dtype)}var J3={kernelName:So,backendName:\"webgl\",kernelFunc:ere};var Rg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.outputShape=o;let n=o.length,s=Re(o.length),a=Re(o.length),i=\"\";if(n===1)i=\"coords * strides + begin\";else{let p=0;i=o.map((u,c)=>(p++,o.length===1?`coords * strides[${c}] + begin[${c}]`:`coords[${p-1}] * strides[${c}] + begin[${c}]`)).join(\",\")}this.userCode=`\n ${s} begin = ${s}(${t});\n ${s} strides = ${s}(${e});\n\n void main() {\n ${a} coords = getOutputCoords();\n setOutput(getX(${i}));\n }\n `}};function tre(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o,{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=te({inputs:{x:n},backend:e,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let E=ct.computeOutShape(b,C,S),R=Gs({inputs:{x:n},backend:e,attrs:{begin:b,size:E}});k=te({inputs:{x:R},backend:e,attrs:{shape:f}}),e.disposeIntermediateTensorInfo(R)}else if(e.shouldExecuteOnCPU([n])){let R=e.readSync(n.dataId),D=me(n.shape,n.dtype,R),P=fD(d,D,S,b);k=e.makeTensorInfo(f,n.dtype,P.values)}else{let R=new Rg(b,S,d);k=e.runWebGLProgram(R,[n],n.dtype)}let _=te({inputs:{x:k},backend:e,attrs:{shape:f}});return e.disposeIntermediateTensorInfo(k),_}var eP={kernelName:Ts,backendName:\"webgl\",kernelFunc:tre};function rre(r){let{inputs:t,backend:e,attrs:o}=r,{separator:n,nGramWidths:s,leftPad:a,rightPad:i,padWidth:p,preserveShortSequences:u}=o,{data:c,dataSplits:l}=t,m=e.readSync(c.dataId),d=e.readSync(l.dataId),[f,h]=hD(m,d,n,s,a,i,p,u);return[e.makeTensorInfo([f.length],\"string\",f),e.makeTensorInfo(l.shape,\"int32\",h)]}var tP={kernelName:Ca,backendName:\"webgl\",kernelFunc:rre};function ore(r){let{inputs:t,backend:e,attrs:o}=r,{skipEmpty:n}=o,{input:s,delimiter:a}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(s.shape.length!==1)throw new Error(`Input must be a vector, got shape: ${s.shape}`);if(a.shape.length!==0)throw new Error(`Delimiter must be a scalar, got shape: ${a.shape}`);let i=e.readSync(s.dataId),p=e.readSync(a.dataId)[0],[u,c,l]=gD(i,p,n),m=c.length;return[e.makeTensorInfo([m,2],\"int32\",u),e.makeTensorInfo([m],\"string\",c),e.makeTensorInfo([2],\"int32\",new Int32Array(l))]}var rP={kernelName:Yi,backendName:\"webgl\",kernelFunc:ore};function nre(r){let{inputs:t,backend:e,attrs:o}=r,{numBuckets:n}=o,{input:s}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(n<=0)throw new Error(\"Number of buckets must be at least 1\");let a=e.readSync(s.dataId),i=xD(a,n);return e.makeTensorInfo(s.shape,\"int32\",i)}var oP={kernelName:Qi,backendName:\"webgl\",kernelFunc:nre};var sre=\"return tan(x);\",are=xe({opSnippet:sre}),nP={kernelName:$s,backendName:\"webgl\",kernelFunc:are};var ire=`\n float e2x = exp(-2.0 * abs(x));\n return sign(x) * (1.0 - e2x) / (1.0 + e2x);\n`,ure=xe({opSnippet:ire}),sP={kernelName:Es,backendName:\"webgl\",kernelFunc:ure};function pre(r){let{inputs:t,backend:e,attrs:o}=r,{tensor:n,indices:s,updates:a}=t,{}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(a,s,n.shape),m=[l/u,u];if(l===0)return e.makeTensorInfo(n.shape,s.dtype);let d=te({inputs:{x:s},backend:e,attrs:{shape:[p,i]}}),f=te({inputs:{x:a},backend:e,attrs:{shape:[p,u]}}),h=te({inputs:{x:n},backend:e,attrs:{shape:m}}),g=new vu(p,i,d.shape.length,f.shape.length,c,m,!1,!0),x=e.runWebGLProgram(g,[f,d,h],h.dtype),b=te({inputs:{x},backend:e,attrs:{shape:n.shape}});return e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(x),b}var aP={kernelName:fs,backendName:\"webgl\",kernelFunc:pre};var Dg=class{constructor(t,e){this.variableNames=[\"A\"];let o=new Array(t.length);for(let a=0;a5)throw Error(`Tile for rank ${t} is not yet supported`);if(t===1)return`imod(resRC, ${r[0]})`;let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\",\"resRC.u\"],o=[];for(let n=0;n5){let p=e.readSync(n.dataId),u=n.dtype===\"string\"?p.map(m=>y.decodeString(m)):p,c=me(n.shape,n.dtype,u),l=bD(c,s);return e.makeTensorInfo(l.shape,l.dtype,l.values)}let a=new Dg(n.shape,s);return e.runWebGLProgram(a,[n],n.dtype)}var iP={kernelName:po,backendName:\"webgl\",kernelFunc:Dv};var Ag=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.customUniforms=[{name:\"n\",type:\"int\"},{name:\"firstPass\",type:\"int\"},{name:\"negativeInf\",type:\"float\"},{name:\"dir\",type:\"int\"},{name:\"inc\",type:\"int\"}],this.outputShape=t,this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int elemIdx = coords[1];\n\n // We compare elements pair-wise within a group of size 2 * inc.\n // The comparing rule for each group alternates between ascending\n // and descending. Within each group, we compare each pair at\n // positions i and i+inc. To decide whether an element at position i\n // is x0 or x1, we mod it by 2 * inc, if the result is smaller than\n // inc, it is in the first half of the group, we denote it as x0,\n // otherwise we denote it as x1.\n // For example, as shown in the Bitonic top K paper referenced above,\n // Figure5(a) shows that element[1] is in the\n // second half of the group when group size is 2, but it is in the\n // first half of the group when group size is 4.\n\n bool isFirstInPair = imod(elemIdx, 2 * inc) < inc;\n int i = isFirstInPair ? elemIdx : elemIdx - inc;\n\n int i0 = firstPass == 1 ? i : int(getIndices(batch, i));\n int i1 = firstPass == 1 ? i + inc : int(getIndices(batch, i + inc));\n float x0 = i0 < n ? getX(batch, i0) : negativeInf;\n float x1 = i1 < n ? getX(batch, i1) : negativeInf;\n\n // Denotes which direction indices are in (ascending or descending).\n bool reverse = imod(elemIdx, 2 * dir) >= dir;\n bool isGreater = x0 > x1 || (x0 == x1 && i1 > i0);\n if (reverse == isGreater) { // Elements in opposite order of direction\n int iTemp = i0;\n i0 = i1;\n i1 = iTemp;\n }\n if (isFirstInPair) {\n setOutput(float(i0));\n } else {\n setOutput(float(i1));\n }\n }\n `}},Fg=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.customUniforms=[{name:\"n\",type:\"int\"},{name:\"firstPass\",type:\"int\"},{name:\"k\",type:\"int\"}],this.outputShape=t,this.userCode=`\n void main() {\n // Takes max of indices (0, k), (1, k + 1), (2, k + 2) ...\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int elemIdx = coords[1];\n\n // The output size is half of the previous size.\n // If the previous sequence is | | | | _ _ _ _ | | | | _ _ _ _ (k=4),\n // we only need to output the indices at positions |, the indices at\n // positions _ can be thrown away, see Figure5(b) After Phase 2\n // (Merge phase) in the Bitonic Top K paper referenced above.\n // For example, the paper shows we only need to output the orange bars.\n // The output sequence should look like this | | | | | | | |.\n // Because the sequence is halved, to map the output index back\n // to the previous sequence to find the corresponding value,\n // we need to double the index. When we double the index,\n // we basically interpolate a position, so 2i looks like\n // | _ | _ | _ | _ | _ | _ | _. We move the | to the first k position\n // of each 2k positions by - elemIdx % k. E.g. for output at\n // index 4,5,6,7, we want to get the corresponding element at\n // original index 8,9,10,11, for output at index 8,9,10,11,\n // we want to get the corresponding element at original index\n // 16,17,18,19, so on and so forth.\n\n int i = elemIdx < k ? elemIdx : (elemIdx * 2 - imod(elemIdx, k));\n int i0 = firstPass == 1 ? i : int(getIndices(batch, i));\n int i1 = firstPass == 1 ? i + k : int(getIndices(batch, i + k));\n\n float x0 = getX(batch, i0);\n float x1 = i1 < n ? getX(batch, i1) : x0;\n\n setOutput(x0 >= x1 ? float(i0) : float(i1));\n }\n `}};function Rp(r,t){t!==null&&r.disposeIntermediateTensorInfo(t)}function uP(r){let t=1;for(;tp){let P=e.readSync(n.dataId),[O,M]=CD(P,u,n.dtype,s,a);return[e.makeTensorInfo(O.shape,O.dtype,O.values),e.makeTensorInfo(M.shape,M.dtype,M.values)]}if(s===0)return u[u.length-1]=0,[e.makeTensorInfo(u,n.dtype,[]),e.makeTensorInfo(u,\"int32\",[])];if(c===1)return[n,Si({attrs:{shape:u,dtype:\"int32\",value:0},backend:e})];let l=e.texData.get(n.dataId),m=l!==null&&l.isPacked,d=m?e.unpackTensor(n):n,h=y.sizeFromShape(u)/c,g=te({inputs:{x:d},attrs:{shape:[h,c]},backend:e});m&&Rp(e,d);let x=uP(s),b=uP(c),C=null,S=()=>C===null?[g,g]:[g,C],k=(P,O,M)=>{let L=S(),B=new Ag(M),U=[[c],[C===null?1:0],[Number.NEGATIVE_INFINITY],[P],[O]],j=C;C=e.runWebGLProgram(B,L,\"int32\",U),Rp(e,j)};for(let P=1;P=1;M/=2)k(O,M,[h,b])}for(let P=b;P>x;P/=2){let O=S(),M=new Fg([h,P/2]),B=[[c],[C===null?1:0],[x]],z=C;C=e.runWebGLProgram(M,O,\"int32\",B),Rp(e,z);let U=x/2,j=U*2;for(let q=U;q>=1;q/=2)k(j,q,C.shape)}let _=C;C=Gs({inputs:{x:C},backend:e,attrs:{begin:0,size:[h,s]}}),Rp(e,_);let E=kv({inputs:{x:g,indices:C},backend:e,attrs:{axis:1,batchDims:1}});Rp(e,g);let R=u.slice(0,-1);R.push(s),_=C,C=te({inputs:{x:C},attrs:{shape:R},backend:e}),Rp(e,_);let D=E;return E=te({inputs:{x:E},attrs:{shape:R},backend:e}),Rp(e,D),[E,C]}var pP={kernelName:Rs,backendName:\"webgl\",kernelFunc:lre};var Pg=class{constructor(t,e,o,n,s,a){this.variableNames=[\"Image\",\"Transforms\"],this.outputShape=a;let i=o===\"nearest\"?1:2,p;switch(n){case\"constant\":p=1;break;case\"reflect\":p=2;break;case\"wrap\":p=3;break;case\"nearest\":p=4;break;default:p=1;break}this.userCode=`\n float mapCoord(float outCoord, float len) {\n float inCoord = outCoord;\n if(${p} == 2) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz2 = 2.0 * len;\n if (inCoord < sz2) {\n inCoord = sz2 * float(int(float(-inCoord / sz2))) +\n inCoord;\n }\n inCoord = inCoord < -len ? inCoord + sz2 : -inCoord - 1.0;\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz2 = 2.0 * len;\n inCoord -= sz2 * float(int(float(inCoord / sz2)));\n if (inCoord >= len) {\n inCoord = sz2 - inCoord - 1.0;\n }\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (${p} == 3) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz = len - 1.0;\n inCoord += len * (float(int(float(-inCoord / sz))) + 1.0);\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz = len - 1.0;\n inCoord -= len * float(int(float(inCoord / sz)));\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (${p} == 4) {\n return clamp(outCoord, 0.0, len - 1.0);\n } else {\n return outCoord;\n }\n }\n\n float readWithFillValue(int batch, int coordY, int coordX,\n int channel) {\n float outputValue;\n if (0 <= coordY && coordY < ${t} && 0 <= coordX && coordX < ${e}) {\n outputValue = getImage(batch, coordY, coordX, channel);\n } else {\n outputValue = float(${s});\n }\n return outputValue;\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n float outputValue;\n int batch = coords[0];\n int x = coords[2];\n int y = coords[1];\n int channel = coords[3];\n float xf = float(x);\n float yf = float(y);\n float a1 = getTransforms(batch, 0);\n float a2 = getTransforms(batch, 1);\n float a3 = getTransforms(batch, 2);\n float b1 = getTransforms(batch, 3);\n float b2 = getTransforms(batch, 4);\n float b3 = getTransforms(batch, 5);\n float c1 = getTransforms(batch, 6);\n float c2 = getTransforms(batch, 7);\n float projection = c1 * xf + c2 * yf + 1.0;\n if (projection == 0.0) {\n outputValue = float(${s});\n } else {\n float inX = (a1 * xf + a2 * yf + a3) / projection;\n float inY = (b1 * xf + b2 * yf + b3) / projection;\n float mapX = mapCoord(inX, float(${e}));\n float mapY = mapCoord(inY, float(${t}));\n\n if (${i} == 1) {\n int coordY = int(round(mapY));\n int coordX = int(round(mapX));\n outputValue = readWithFillValue(batch, coordY, coordX,\n channel);\n } else {\n float yFloor = floor(mapY);\n float xFloor = floor(mapX);\n float yCeil = yFloor + 1.0;\n float xCeil = xFloor + 1.0;\n float valueYFloor = (xCeil - mapX) *\n readWithFillValue(batch, int(yFloor), int(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, int(yFloor), int(xCeil), channel);\n float valueYCeil = (xCeil - mapX) *\n readWithFillValue(batch, int(yCeil), int(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, int(yCeil), int(xCeil), channel);\n outputValue = (yCeil - mapY) * valueYFloor +\n (mapY - yFloor) * valueYCeil;\n }\n }\n setOutput(outputValue);\n }\n `}};function mre(r){let{inputs:t,backend:e,attrs:o}=r,{image:n,transforms:s}=t,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=o,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=new Pg(l,m,a,i,p,g);return e.runWebGLProgram(x,[n,s],\"float32\")}var cP={kernelName:Ds,backendName:\"webgl\",kernelFunc:mre};function dre(r){let{inputs:t,attrs:e,backend:o}=r,{axis:n}=e,{x:s}=t;Vs(s,\"unique\"),console.warn(\"WARNING: \",\"UI might be locked temporarily as data is being downloaded\");let a=o.readSync(s.dataId),{outputValues:i,outputShape:p,indices:u}=wD(a,n,s.shape,s.dtype);return[o.makeTensorInfo(p,s.dtype,i),o.makeTensorInfo([u.length],\"int32\",u)]}var lP={kernelName:Zi,backendName:\"webgl\",kernelFunc:dre};function fre(r){let{inputs:t,backend:e,attrs:o}=r,{value:n}=t,{axis:s}=o;s<0&&(s+=n.shape.length);let a=n,i=a.shape.length,p=n.shape[s],u=new Array(i-1),c=0;for(let h=0;he.disposeIntermediateTensorInfo(h)),f}var mP={kernelName:wa,backendName:\"webgl\",kernelFunc:fre};var Og=class{constructor(t,e){this.variableNames=[\"x\",\"segmentIds\"];let o=t.windowSize,n=t.batchSize,s=t.inSize,a=t.numSegments,i=a*Math.ceil(s/o);this.outputShape=[n,i];let p=\"0.0\",u=\"sumValue\",c=Math.floor(o/4)*4,l=o%4,m=`\n sumValue += dot(values, segFilter);\n `,d=\"\";s%o>0&&(d=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return initializationValue;\n }\n `);let f=\"\";s%o>0&&(f=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return -1.0;\n }\n `),this.userCode=`\n const float initializationValue = ${p};\n\n float getValue(int batch, int inIdx) {\n ${d}\n return getX(batch, inIdx);\n }\n\n float getSegmentIdAtIndex(int inIdx) {\n ${f}\n return getSegmentIds(inIdx);\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = int(floor(float(outIdx) / float(\n ${a})) * float(${o}));\n int currentSeg = int(mod(float(outIdx), float(${a})));\n\n float sumValue = 0.0;\n\n for (int i = 0; i < ${c}; i += 4) {\n int inIdx = inOffset + i;\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n getValue(batch, inIdx + 3)\n );\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 1)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 2)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 3)) == currentSeg ? 1 : 0\n );\n\n ${m}\n }\n\n int inIdx = inOffset + ${c};\n if (${l===1}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n int inIdxSeg = int(getSegmentIdAtIndex(inIdx));\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n 0,\n 0,\n 0\n );\n\n ${m}\n } else if (${l===2}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n initializationValue,\n initializationValue\n );\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 1)) == currentSeg ? 1 : 0,\n 0,\n 0\n );\n\n ${m}\n } else if (${l===3}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n initializationValue\n );\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 1)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 2)) == currentSeg ? 1 : 0,\n 0\n );\n\n ${m}\n }\n setOutput(${u});\n }\n `}};function hre(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,segmentIds:s}=t,{numSegments:a}=o,i=n.shape.length,p=[],u=0,c=w.getAxesPermutation([u],i),l=n;c!=null&&(l=Ct({inputs:{x:n},backend:e,attrs:{perm:c}}),p.push(l),u=w.getInnerMostAxes(1,i)[0]);let m=w.segment_util.computeOutShape(l.shape,u,a),d=y.sizeFromShape([l.shape[u]]),f=te({inputs:{x:l},backend:e,attrs:{shape:[-1,d]}});p.push(f);let h=ni(n.dtype),g=(S,k,_,E,R)=>{let D=S.shape[0],P=S.shape[1],O=w.segment_util.segOpComputeOptimalWindowSize(P,R),M={windowSize:O,inSize:P,batchSize:D,numSegments:R},L=new Og(M,k),B=e.compileAndRun(L,[S,_],E);if(p.push(B),B.shape[1]===R)return B;let z=Rv({backend:e,attrs:{start:0,stop:R,step:1,dtype:\"float32\"}}),U=Dv({inputs:{x:z},backend:e,attrs:{reps:[P/O]}});return p.push(z),p.push(U),g(B,k,U,E,R)},x=g(f,\"unsortedSegmentSum\",s,h,a),b=te({inputs:{x},backend:e,attrs:{shape:m}}),C=b;if(c!=null){p.push(b);let S=w.getUndoAxesPermutation(c);C=Ct({inputs:{x:C},backend:e,attrs:{perm:S}})}return p.forEach(S=>e.disposeIntermediateTensorInfo(S)),C}var dP={kernelName:Ji,backendName:\"webgl\",kernelFunc:hre};var gre=[XD,QD,ZD,JD,tA,rA,oA,nA,iA,uA,pA,cA,lA,mA,dA,fA,hA,gA,xA,yA,bA,wA,SA,IA,vA,_A,EA,RA,BD,AA,PA,OA,MA,LA,BA,zA,VA,WA,UA,GA,qA,jA,XA,YA,QA,ZA,JA,eF,tF,rF,oF,nF,sF,aF,iF,uF,cF,lF,mF,dF,hF,gF,xF,yF,bF,CF,wF,SF,IF,LD,vF,FA,kF,NF,TF,zD,_F,$F,EF,RF,DF,AF,FF,PF,OF,MF,BF,zF,VF,WF,UF,GF,KF,jF,XF,YF,QF,ZF,o3,UD,n3,s3,a3,i3,kA,u3,l3,m3,d3,f3,VD,h3,g3,x3,y3,b3,NA,JF,C3,w3,S3,HD,I3,v3,k3,N3,T3,_3,$3,E3,R3,D3,A3,F3,P3,O3,M3,L3,CA,r3,B3,z3,V3,W3,U3,G3,H3,K3,j3,X3,Q3,Z3,J3,eP,tP,rP,oP,t3,qD,nP,sP,aP,iP,pP,cP,jD,lP,mP,dP,p3];for(let r of gre)ri(r);var we;(function(r){r[r.float32=0]=\"float32\",r[r.int32=1]=\"int32\",r[r.bool=2]=\"bool\",r[r.string=3]=\"string\",r[r.complex64=4]=\"complex64\"})(we||(we={}));var ku;(function(r){r[r.linear=0]=\"linear\",r[r.relu=1]=\"relu\",r[r.relu6=2]=\"relu6\",r[r.prelu=3]=\"prelu\",r[r.leakyrelu=4]=\"leakyrelu\",r[r.sigmoid=5]=\"sigmoid\",r[r.elu=6]=\"elu\"})(ku||(ku={}));var fP;function xre(r){fP=r.wasm.cwrap(Io,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function yre(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s,bias:a,preluActivationWeights:i}=t;if(n.dtype!==\"float32\"||s.dtype!==\"float32\")throw new Error(\"_FusedMatMul for non non-float32 tensors not yet supported.\");let{transposeA:p,transposeB:u,activation:c,leakyreluAlpha:l}=o,m=e.dataIdMap.get(n.dataId).id,d=e.dataIdMap.get(s.dataId).id,f=0;if(a!=null){let R=e.dataIdMap.get(a.dataId);if(R.shape.length!==1)throw new Error(`_FusedMatMul only supports rank-1 bias but got rank ${R.shape.length}.`);f=R.id}let h=i==null?0:e.dataIdMap.get(i.dataId).id,g=ku[c];if(g==null)throw new Error(`${c} activation not yet supported for FusedConv2D in the wasm backend.`);let x=p?n.shape[2]:n.shape[1],b=u?s.shape[1]:s.shape[2],C=Ir.assertAndGetBroadcastShape(n.shape.slice(0,-2),s.shape.slice(0,-2)),S=e.makeOutput([...C,x,b],n.dtype),k=e.dataIdMap.get(S.dataId).id,_=new Uint8Array(new Int32Array(n.shape).buffer),E=new Uint8Array(new Int32Array(s.shape).buffer);return fP(m,_,n.shape.length,d,E,s.shape.length,p,u,g,f,h,l||0,k),S}var hP={kernelName:Io,backendName:\"wasm\",setupFunc:xre,kernelFunc:yre};function he(r,t){let e;function o(s){e=s.wasm.cwrap(r,null,[\"number\",\"number\",\"number\"])}function n(s){let{backend:a,inputs:{x:i}}=s,p=a.dataIdMap.get(i.dataId).id,u=a.makeOutput(i.shape,t||i.dtype),c=a.dataIdMap.get(u.dataId).id;return y.sizeFromShape(u.shape)===0||e(p,we[i.dtype],c),u}return{kernelName:r,backendName:\"wasm\",setupFunc:o,kernelFunc:n}}var gP=he(Xs);var xP=he(Wo);var yP=he(Uo);function Ue(r,t,e){let o;function n(a){o=a.wasm.cwrap(r,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\"])}function s(a){let{backend:i,inputs:p}=a,{a:u,b:c}=p,l=i.dataIdMap.get(u.dataId).id,m=i.dataIdMap.get(c.dataId).id,d=e!=null?e:u.dtype,f=w.assertAndGetBroadcastShape(u.shape,c.shape),h=i.makeOutput(f,d);if(y.sizeFromShape(f)===0)return h;let g=new Uint8Array(new Int32Array(u.shape).buffer),x=new Uint8Array(new Int32Array(c.shape).buffer),b=i.dataIdMap.get(h.dataId).id;return(()=>o(l,g,u.shape.length,m,x,c.shape.length,we[u.dtype],b))(),h}return{kernelName:r,backendName:\"wasm\",setupFunc:n,kernelFunc:s}}var bre=!0,bP=Ue(uo,bre);var CP;function Cre(r){CP=r.wasm.cwrap(Go,null,[\"array\",\"number\",\"number\",\"number\"])}function wre(r){let{inputs:t,backend:e}=r,o=e.makeOutput(t[0].shape,t[0].dtype);if(y.sizeFromShape(o.shape)===0)return o;let n=t.map(i=>e.dataIdMap.get(i.dataId).id),s=new Uint8Array(new Int32Array(n).buffer),a=e.dataIdMap.get(o.dataId).id;return CP(s,n.length,we[o.dtype],a),o}var wP={kernelName:Go,backendName:\"wasm\",setupFunc:Cre,kernelFunc:wre};function Dp(r){let{inputs:{x:t},backend:e}=r;if(t.dtype===\"string\")return ur(e.readSync(t.dataId),t.shape,t.dtype);let o=e.makeOutput(t.shape,t.dtype),n=e.typedArrayFromHeap(t);return e.typedArrayFromHeap(o).set(n),o}var SP={kernelName:wo,backendName:\"wasm\",kernelFunc:Dp};var IP;function Sre(r){IP=r.wasm.cwrap(co,null,[\"number\",\"array\",\"number\",\"number\",\"number\",\"array\",\"number\"])}function go(r){let{inputs:t,backend:e,attrs:o}=r,[n,s]=vre(t.x.shape,o.perm),a=!0;for(let f=0;f=n&&(s===-1||o[s]>o[a])&&(s=a);o[s]=n}return[e,o]}var vP={kernelName:co,backendName:\"wasm\",kernelFunc:go,setupFunc:Sre};function _r(r,t,e){let o=r.shape,n=r.shape.length,s=y.parseAxisParam(t,o),a=s,i=w.getAxesPermutation(a,n),p=null,u=!1;if(i!=null){let c=new Array(n);for(let d=0;d`new shape: ${a}, old shape: ${o.shape}. New shape and old shape must have the same number of elements.`),r.backend.incRef(o.dataId),{dataId:o.dataId,shape:a,dtype:o.dtype}}var GP={kernelName:da,backendName:\"wasm\",kernelFunc:Vt};var HP;function Mre(r){HP=r.wasm.cwrap(Jo,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\",\"number\"])}function Lre(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;if(n.dtype!==\"float32\"||s.dtype!==\"float32\")throw new Error(\"BatchMatMul for non non-float32 tensors not yet supported.\");let p=n.shape.length,u=s.shape.length,c=a?n.shape[p-2]:n.shape[p-1],l=i?s.shape[u-1]:s.shape[u-2],m=a?n.shape[p-1]:n.shape[p-2],d=i?s.shape[u-2]:s.shape[u-1],f=n.shape.slice(0,-2),h=s.shape.slice(0,-2),g=y.sizeFromShape(f),x=y.sizeFromShape(h),C=Ir.assertAndGetBroadcastShape(n.shape.slice(0,-2),s.shape.slice(0,-2)).concat([m,d]);y.assert(c===l,()=>`Error in matMul: inner shapes (${c}) and (${l}) of Tensors with shapes ${n.shape} and ${s.shape} and transposeA=${a} and transposeB=${i} must match.`);let S=a?[g,c,m]:[g,m,c],k=i?[x,d,l]:[x,l,d],_=Vt({inputs:{x:n},backend:e,attrs:{shape:S}}),E=Vt({inputs:{x:s},backend:e,attrs:{shape:k}}),R=e.dataIdMap.get(_.dataId).id,D=e.dataIdMap.get(E.dataId).id,P=a?_.shape[2]:_.shape[1],O=i?E.shape[1]:E.shape[2],M=Math.max(g,x),L=e.makeOutput([M,P,O],_.dtype),B=e.dataIdMap.get(L.dataId).id,z=new Uint8Array(new Int32Array(_.shape).buffer),U=new Uint8Array(new Int32Array(E.shape).buffer);return HP(R,z,_.shape.length,D,U,E.shape.length,a,i,B),e.disposeData(_.dataId),e.disposeData(E.dataId),L.shape=C,L}var KP={kernelName:Jo,backendName:\"wasm\",setupFunc:Mre,kernelFunc:Lre};function Oo(r){let{inputs:{x:t},attrs:{begin:e,size:o},backend:n}=r,[s,a]=ct.parseSliceParams(t,e,o),i=ct.isSliceContinous(t.shape,s,a),p=n.readSync(t.dataId),u=n.makeOutput(a,t.dtype),c=y.computeStrides(t.shape),l=n.dataIdMap.get(u.dataId);if(i){let f=ct.computeFlatOffset(s,c);return t.dtype===\"string\"?l.stringBytes=p.slice(f,f+y.sizeFromShape(a)):n.typedArrayFromHeap(u).set(p.subarray(f,f+y.sizeFromShape(a))),u}if(t.dtype===\"string\"){let f=hp(p,s,a,t.shape,t.dtype);return l.stringBytes=f,u}let m=n.typedArrayFromHeap(u),d=t.shape.length;if(d===2)Bre(p,c[0],m,s,a);else if(d===3)zre(p,c[0],c[1],m,s,a);else if(d===4)Vre(p,c[0],c[1],c[2],m,s,a);else{let f=hp(p,s,a,t.shape,t.dtype);m.set(f)}return u}function Bre(r,t,e,o,n){let s=0,a=o[0],i=o[1],p=a+n[0];for(let u=a;ux*b),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=Vt({inputs:{x:n},backend:e,attrs:{shape:p}}),f=go({inputs:{x:d},backend:e,attrs:{perm:u}}),h=Vt({inputs:{x:f},backend:e,attrs:{shape:c}}),g=Oo({inputs:{x:h},backend:e,attrs:{begin:l,size:m}});return e.disposeData(d.dataId),e.disposeData(f.dataId),e.disposeData(h.dataId),g}var jP={kernelName:Js,backendName:\"wasm\",kernelFunc:Wre};var XP;function Ure(r){XP=r.wasm.cwrap(en,null,[\"number\",\"number\",\"boolean\",\"number\",\"number\",\"number\"])}function Gre(r){let{backend:t,inputs:e,attrs:o}=r,{x:n,weights:s}=e,{size:a}=o,i=s.shape.reduce((l,m)=>l*m,1)!==0,p=n.shape.length===1?[a]:[n.shape[0],a],u=t.makeOutput(p,s.dtype);function c(l){return t.dataIdMap.get(l.dataId).id}return XP(c(n),a,i,c(s),we[s.dtype],c(u)),u}var YP={kernelName:en,backendName:\"wasm\",setupFunc:Ure,kernelFunc:Gre};var Hre=!0,QP=Ue(ja,Hre);function Kre(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t,s=e.typedArrayFromHeap(o),a=e.typedArrayFromHeap(n),i=w.assertAndGetBroadcastShape(Array.from(s),Array.from(a));return e.makeOutput([i.length],\"int32\",void 0,new Int32Array(i))}var ZP={kernelName:ea,backendName:\"wasm\",kernelFunc:Kre};function Mr(r){let{inputs:{x:t},attrs:{dtype:e},backend:o}=r,n=o.makeOutput(t.shape,e),s=o.typedArrayFromHeap(t);return o.typedArrayFromHeap(n).set(s),n}var JP={kernelName:bo,backendName:\"wasm\",kernelFunc:Mr};var eO=he(tn);var tO;function qre(r){tO=r.wasm.cwrap(Co,null,[\"number\",\"number\",\"number\",\"number\"])}function jre(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{clipValueMin:s,clipValueMax:a}=o,i=e.dataIdMap.get(n.dataId).id,p=e.makeOutput(n.shape,n.dtype),u=e.dataIdMap.get(p.dataId).id;return tO(i,s,a,u),p}var rO={kernelName:Co,backendName:\"wasm\",setupFunc:qre,kernelFunc:jre};function Av(r){let{inputs:t,backend:e}=r,o=y.parseAxisParam(r.attrs.axis,t[0].shape)[0],n=t.map(d=>d.shape);w.assertParamsConsistent(n,o);let s=w.computeOutShape(t.map(d=>d.shape),o),a=t.filter(d=>y.sizeFromShape(d.shape)>0);if(a.length===1)return Dp({inputs:{x:a[0]},backend:e});let i=e.makeOutput(s,t[0].dtype);if(y.sizeFromShape(s)===0)return i;if(a[0].dtype===\"string\"){let d=a.map(C=>{let k=[-1,y.sizeFromShape(C.shape.slice(o))];return Vt({inputs:{x:C},backend:e,attrs:{shape:k}})}),f=d.map(C=>({vals:e.readSync(C.dataId),shape:C.shape}));s=w.computeOutShape(d.map(C=>C.shape),1);let h=d[0].shape[0]===1,g=mp(f,s,t[0].dtype,h),x=w.computeOutShape(a.map(C=>C.shape),o);i.shape=x;let b=e.dataIdMap.get(i.dataId);return b.stringBytes=w.fromStringArrayToUint8(g),d.forEach(C=>e.disposeData(C.dataId)),i}let p=y.sizeFromShape(a[0].shape.slice(0,o)),u=0,c=a.map(d=>{let f=y.sizeFromShape(d.shape.slice(o));return u+=f,f}),l=a.map(d=>e.typedArrayFromHeap(d)),m=e.typedArrayFromHeap(i);for(let d=0;d`cumprod does not support ${n.dtype} tensors in the WASM backend`);let u=w.getAxesPermutation([s],p),c=n;u!==null&&(c=go({inputs:{x:n},attrs:{perm:u},backend:e}));let l=w.getInnerMostAxes(1,p)[0];w.assertAxesAreInnerMostDims(\"cumprod\",[l],p);let m=e.makeOutput(c.shape,c.dtype),d=c.shape[l],f=e.dataIdMap.get(c.dataId).id,h=e.dataIdMap.get(m.dataId).id;yO(f,a?1:0,i?1:0,d,h,we[n.dtype]);let g=m;if(u!==null){let x=w.getUndoAxesPermutation(u);g=go({inputs:{x:m},attrs:{perm:x},backend:e}),e.disposeData(c.dataId),e.disposeData(m.dataId)}return g}var bO={kernelName:pn,backendName:\"wasm\",setupFunc:ioe,kernelFunc:uoe};var CO;function poe(r){CO=r.wasm.cwrap(cn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function coe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o,p=n.shape.length;y.assert(n.dtype===\"float32\"||n.dtype===\"int32\",()=>`cumsum does not support ${n.dtype} tensors in the WASM backend`);let u=w.getAxesPermutation([s],p),c=n;u!==null&&(c=go({inputs:{x:n},attrs:{perm:u},backend:e}));let l=w.getInnerMostAxes(1,p)[0];w.assertAxesAreInnerMostDims(\"cumsum\",[l],p);let m=e.makeOutput(c.shape,c.dtype),d=c.shape[l],f=e.dataIdMap.get(c.dataId).id,h=e.dataIdMap.get(m.dataId).id;CO(f,a?1:0,i?1:0,d,h,we[n.dtype]);let g=m;if(u!==null){let x=w.getUndoAxesPermutation(u);g=go({inputs:{x:m},attrs:{perm:x},backend:e}),e.disposeData(c.dataId),e.disposeData(m.dataId)}return g}var wO={kernelName:cn,backendName:\"wasm\",setupFunc:poe,kernelFunc:coe};var SO;function loe(r){SO=r.wasm.cwrap(\"DenseBincount\",null,[\"number\",\"array\",\"number\",\"number\",\"boolean\",\"number\",\"number\",\"boolean\",\"number\"])}function moe(r){let{backend:t,inputs:e,attrs:o}=r,{x:n,weights:s}=e,{size:a,binaryOutput:i}=o,p=s.shape.reduce((m,d)=>m*d,1)!==0,u=n.shape.length===1?[a]:[n.shape[0],a],c=t.makeOutput(u,s.dtype);function l(m){return t.dataIdMap.get(m.dataId).id}return SO(l(n),new Uint8Array(new Int32Array(n.shape).buffer),n.shape.length,a,p,l(s),we[s.dtype],i,l(c)),c}var IO={kernelName:ra,backendName:\"wasm\",setupFunc:loe,kernelFunc:moe};var vO;function doe(r){vO=r.wasm.cwrap(mn,null,[\"number\",\"number\",\"number\",\"array\",\"number\",\"array\",\"array\",\"number\",\"number\"])}function foe(r){let{backend:t,inputs:e,attrs:o}=r,{x:n}=e,{blockSize:s,dataFormat:a}=o,i=n.shape[0],p=a===\"NHWC\"?n.shape[1]:n.shape[2],u=a===\"NHWC\"?n.shape[2]:n.shape[3],c=a===\"NHWC\"?n.shape[3]:n.shape[1],l=p*s,m=u*s,d=c/(s*s),f=a===\"NHWC\"?[i,l,m,d]:[i,d,l,m],h=t.makeOutput(f,\"float32\"),x=t.dataIdMap.get(n.dataId).id,b=new Uint8Array(new Int32Array(y.computeStrides(n.shape)).buffer),C=new Uint8Array(new Int32Array(f).buffer),S=new Uint8Array(new Int32Array(y.computeStrides(f)).buffer),k=t.dataIdMap.get(h.dataId).id;return vO(x,s,a===\"NHWC\"?1:0,b,n.shape.length-1,C,S,f.length,k),h}var kO={kernelName:mn,backendName:\"wasm\",setupFunc:doe,kernelFunc:foe};var NO;function hoe(r){NO=r.wasm.cwrap(dn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function goe(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s}=t,a=o.dataIdMap.get(n.dataId).id,i=o.dataIdMap.get(s.dataId).id,{strides:p,dilations:u,pad:c,dimRoundingMode:l}=e,m=u==null?[1,1]:u,d=w.computeConv2DInfo(n.shape,s.shape,p,m,c,l,!0),f=d.filterHeight,h=d.filterWidth,g=d.padInfo.top,x=d.padInfo.right,b=d.padInfo.bottom,C=d.padInfo.left,S=d.dilationHeight,k=d.dilationWidth,_=d.strideHeight,E=d.strideWidth,R=d.inChannels,D=d.outChannels,P=d.padInfo.type===\"SAME\"?1:0;if(d.dataFormat!==\"channelsLast\")throw new Error(`wasm backend DepthwiseConv2dNative does not support dataFormat:'${d.dataFormat}'. Please use 'channelsLast'.`);let O=o.makeOutput(d.outShape,\"float32\"),M=o.dataIdMap.get(O.dataId).id;return NO(a,n.shape[0],n.shape[1],n.shape[2],i,f,h,g,x,b,C,P,S,k,_,E,R,D,M),O}var TO={kernelName:dn,backendName:\"wasm\",setupFunc:hoe,kernelFunc:goe};var _O;function xoe(r){_O=r.wasm.cwrap(\"Diag\",null,[\"number\",\"number\",\"number\",\"number\"])}function yoe(r){let{inputs:t,backend:e}=r,{x:o}=t,n=y.sizeFromShape(o.shape),s=e.makeOutput([...o.shape,...o.shape],o.dtype);return _O(e.dataIdMap.get(o.dataId).id,we[o.dtype],n,e.dataIdMap.get(s.dataId).id),s}var $O={kernelName:oa,backendName:\"wasm\",setupFunc:xoe,kernelFunc:yoe};var EO;function boe(r){EO=r.wasm.cwrap(fn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Coe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o;if(n.dtype!==s.dtype)throw new Error(`Dilation2D error: x must have the same dtype as filter. Got ${n.dtype} and ${s.dtype}`);let u=w.computeDilation2DInfo(n.shape,s.shape,a,i,\"NHWC\",p),c=e.makeOutput(u.outShape,n.dtype);return EO(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(c.dataId).id,we[n.dtype],u.batchSize,u.inChannels,u.inHeight,u.inWidth,u.outHeight,u.outWidth,u.strideHeight,u.strideWidth,u.dilationHeight,u.dilationWidth,u.filterHeight,u.filterWidth,u.padInfo.top,u.padInfo.left),c}var RO={kernelName:fn,backendName:\"wasm\",setupFunc:boe,kernelFunc:Coe};var DO;function woe(r){DO=r.wasm.cwrap(zi,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Soe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o;if(n.dtype!==s.dtype||n.dtype!==a.dtype)throw new Error(`Dilation2DBackpropFilter error: x must have the same dtype as filter and dy. Got ${n.dtype}, ${s.dtype}, and ${a.dtype}`);let c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=e.makeOutput(s.shape,s.dtype);return DO(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(a.dataId).id,e.dataIdMap.get(l.dataId).id,we[n.dtype],c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.filterHeight,c.filterWidth,c.padInfo.top,c.padInfo.left),l}var AO={kernelName:zi,backendName:\"wasm\",setupFunc:woe,kernelFunc:Soe};var FO;function Ioe(r){FO=r.wasm.cwrap(Bi,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function voe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o;if(n.dtype!==s.dtype||n.dtype!==a.dtype)throw new Error(`Dilation2DBackpropInput error: x must have the same dtype as filter and dy. Got ${n.dtype}, ${s.dtype}, and ${a.dtype}`);let c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=e.makeOutput(n.shape,n.dtype);return FO(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(a.dataId).id,e.dataIdMap.get(l.dataId).id,we[n.dtype],c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.filterHeight,c.filterWidth,c.padInfo.top,c.padInfo.left),l}var PO={kernelName:Bi,backendName:\"wasm\",setupFunc:Ioe,kernelFunc:voe};var OO=he(gn);var MO;function koe(r){MO=r.wasm.cwrap(Ya,null,[\"number\",\"number\",\"number\"])}function Noe(r){let{inputs:t,backend:e}=r,{dy:o,y:n}=t,s=e.makeOutput(n.shape,\"float32\"),a=i=>e.dataIdMap.get(i.dataId).id;return MO(a(n),a(o),a(s)),s}var LO={kernelName:Ya,backendName:\"wasm\",setupFunc:koe,kernelFunc:Noe};var Toe=!1,BO=Ue(yn,Toe,\"bool\");var zO=he(xn);var VO=he(bn,\"float32\");function Lg(r){let{inputs:t,attrs:e,backend:o}=r,{input:n}=t,{dim:s}=e,a=n.shape.length,i=n.shape.slice(),p=s;return s<0&&(y.assert(-(a+1)<=s,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+s+1),i.splice(p,0,1),Vt({inputs:{x:n},backend:o,attrs:{shape:i}})}var WO={kernelName:na,backendName:\"wasm\",kernelFunc:Lg};var UO=he(Cn,\"float32\");function Pv(r){let{attrs:{shape:t,value:e,dtype:o},backend:n}=r,s=n.makeOutput(t,o);return n.typedArrayFromHeap(s).fill(e),s}var GO={kernelName:sa,backendName:\"wasm\",kernelFunc:Pv};var HO;function _oe(r){HO=r.wasm.cwrap(wn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function $oe(r){let{inputs:t,backend:e}=r,{image:o}=t,n=e.makeOutput(o.shape,o.dtype),s=e.dataIdMap.get(o.dataId).id,a=e.dataIdMap.get(n.dataId).id,[i,p,u,c]=o.shape;return HO(s,i,p,u,c,a),n}var KO={kernelName:wn,backendName:\"wasm\",kernelFunc:$oe,setupFunc:_oe};var qO=he(Sn);var Eoe=!1,jO=Ue(In,Eoe);var XO;function Roe(r){XO=r.wasm.cwrap(vn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Doe(r){let{backend:t,inputs:e,attrs:o}=r,{varianceEpsilon:n}=o,{x:s,mean:a,variance:i,offset:p,scale:u}=e,c=t.dataIdMap.get(s.dataId).id,l=t.dataIdMap.get(a.dataId).id,m=t.dataIdMap.get(i.dataId).id,d=p!=null?t.dataIdMap.get(p.dataId).id:0,f=u!=null?t.dataIdMap.get(u.dataId).id:0,h=t.makeOutput(s.shape,s.dtype);if(y.sizeFromShape(s.shape)===0)return h;let g=t.dataIdMap.get(h.dataId).id;return XO(c,l,m,d,f,n,g),h}var YO={kernelName:vn,backendName:\"wasm\",setupFunc:Roe,kernelFunc:Doe};var QO;function Aoe(r){QO=r.wasm.cwrap(vo,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Foe(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dataFormat:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=e,h=w.computeConv2DInfo(n.shape,s.shape,p,c,u,m),g=ku[d];if(g==null)throw new Error(`${d} activation not yet supported for FusedConv2D in the wasm backend.`);let x=o.dataIdMap.get(n.dataId).id,b=o.dataIdMap.get(s.dataId).id,C=h.outChannels,S=0;if(a!=null){let ee=o.dataIdMap.get(a.dataId);if(ee.shape.length!==1)throw new Error(`FusedConv2D only supports rank-1 bias but got rank ${ee.shape.length}.`);if(ee.shape[0]!==C)throw new Error(`FusedConv2D bias shape (${ee.shape}) does not match the number of output channels (${C})`);S=ee.id}let k=h.filterHeight,_=h.filterWidth,E=h.padInfo.top,R=h.padInfo.right,D=h.padInfo.bottom,P=h.padInfo.left,O=h.dilationHeight,M=h.dilationWidth,L=h.strideHeight,B=h.strideWidth,z=h.inChannels,U=h.padInfo.type===\"SAME\"?1:0,j=h.batchSize,q=h.inHeight,Y=h.inWidth;if(l!==\"NHWC\")throw new Error(`wasm backend FusedConv2D does not support dataFormat:'${l}'. Please use 'NHWC'.`);let J=o.makeOutput(h.outShape,\"float32\"),re=o.dataIdMap.get(J.dataId).id,ne=i==null?0:o.dataIdMap.get(i.dataId).id;return QO(x,j,q,Y,b,k,_,S,E,R,D,P,U,O,M,L,B,z,C,g,ne,f||0,re),J}var ZO={kernelName:vo,backendName:\"wasm\",setupFunc:Aoe,kernelFunc:Foe};var JO;function Poe(r){JO=r.wasm.cwrap(ko,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Ooe(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dataFormat:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=e,h=w.computeConv2DInfo(n.shape,s.shape,p,c,u,m,!0),g=ku[d];if(g==null)throw new Error(`${d} activation not yet supported for FusedDepthwiseConv2D in the wasm backend.`);let x=o.dataIdMap.get(n.dataId).id,b=o.dataIdMap.get(s.dataId).id,C=h.outChannels,S=0;if(a!=null){let ee=o.dataIdMap.get(a.dataId);if(ee.shape.length!==1)throw new Error(`FusedDepthwiseConv2D only supports rank-1 bias but got rank ${ee.shape.length}.`);if(ee.shape[0]!==C)throw new Error(`FusedDepthwiseConv2D bias shape (${ee.shape}) does not match the number of output channels (${C})`);S=ee.id}let k=h.filterHeight,_=h.filterWidth,E=h.padInfo.top,R=h.padInfo.right,D=h.padInfo.bottom,P=h.padInfo.left,O=h.dilationHeight,M=h.dilationWidth,L=h.strideHeight,B=h.strideWidth,z=h.inChannels,U=h.padInfo.type===\"SAME\"?1:0,j=h.batchSize,q=h.inHeight,Y=h.inWidth;if(l!==\"NHWC\")throw new Error(`wasm backend FusedDepthwiseConv2D does not support dataFormat:'${l}'. Please use 'NHWC'.`);let J=o.makeOutput(h.outShape,\"float32\"),re=o.dataIdMap.get(J.dataId).id,ne=i==null?0:o.dataIdMap.get(i.dataId).id;return JO(x,j,q,Y,b,k,_,S,E,R,D,P,U,O,M,L,B,z,C,g,ne,f||0,re),J}var eM={kernelName:ko,backendName:\"wasm\",setupFunc:Poe,kernelFunc:Ooe};var tM;function Moe(r){tM=r.wasm.cwrap(kn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\"])}function Loe(r){let{backend:t,inputs:e}=r,{params:o,indices:n}=e,[s,a,i,p]=af.prepareAndValidate(o,n),u=t.makeOutput(s,o.dtype);if(a===0)return u;let c=n.shape,l=c[c.length-1],d=t.dataIdMap.get(o.dataId).id,h=t.dataIdMap.get(n.dataId).id,g=new Uint8Array(new Int32Array(p).buffer),x=t.dataIdMap.get(u.dataId).id;return tM(d,we[o.dtype],h,a,l,i,g,x),u}var rM={kernelName:kn,backendName:\"wasm\",setupFunc:Moe,kernelFunc:Loe};var oM;function Boe(r){oM=r.wasm.cwrap(\"Gather\",null,[\"number\",\"number\",\"array\",\"number\",\"number\",\"number\",\"array\",\"number\"])}function zoe(r){let{backend:t,inputs:e,attrs:o}=r,{x:n,indices:s}=e,{axis:a,batchDims:i}=o,p=y.parseAxisParam(a,n.shape)[0],u=t.readSync(s.dataId),c=n.shape[p];for(let D=0;D=0,()=>`GatherV2: the index value ${P} is not in [0, ${c-1}]`)}let l=w.segment_util.collectGatherOpShapeInfo(n,s,p,i),m=Vt({inputs:{x:n},attrs:{shape:[l.batchSize,l.outerSize,l.dimSize,l.sliceSize]},backend:t}),d=y.sizeFromShape(s.shape),f=Vt({inputs:{x:s},attrs:{shape:[l.batchSize,d/l.batchSize]},backend:t}),h=[l.batchSize,l.outerSize,d/l.batchSize,l.sliceSize],g=t.makeOutput(h,n.dtype);if(y.sizeFromShape(n.shape)===0)return g;let x=m.shape.length-1,C=t.dataIdMap.get(m.dataId).id,k=t.dataIdMap.get(f.dataId).id,_=t.dataIdMap.get(g.dataId).id,E=new Uint8Array(new Int32Array(y.computeStrides(m.shape)).buffer),R=new Uint8Array(new Int32Array(y.computeStrides(h)).buffer);return oM(C,we[n.dtype],E,x,k,l.batchSize,R,_),t.disposeData(m.dataId),t.disposeData(f.dataId),g.shape=l.outputShape,g}var nM={kernelName:aa,backendName:\"wasm\",setupFunc:Boe,kernelFunc:zoe};var Voe=!1,sM=Ue(Nn,Voe,\"bool\");var Woe=!1,aM=Ue(Tn,Woe,\"bool\");var iM=he(_n,\"bool\");var uM=he($n,\"bool\");var pM=he(En,\"bool\");var cM;function Uoe(r){cM=r.wasm.cwrap(Rn,null,[\"number\",\"number\",\"number\",\"number\"])}function Goe(r){let{inputs:{x:t},attrs:{alpha:e},backend:o}=r,n=o.dataIdMap.get(t.dataId).id,s=o.makeOutput(t.shape,\"float32\");if(y.sizeFromShape(t.shape)!==0){let a=o.dataIdMap.get(s.dataId).id;cM(n,we[t.dtype],e,a)}return s}var lM={kernelName:Rn,backendName:\"wasm\",setupFunc:Uoe,kernelFunc:Goe};var Hoe=!1,mM=Ue(Dn,Hoe,\"bool\");var Koe=!1,dM=Ue(An,Koe,\"bool\");var fM;function qoe(r){fM=r.wasm.cwrap(Fn,null,[\"number\",\"number\",\"number\",\"number\"])}function joe(r){let{attrs:t,backend:e}=r,{start:o,stop:n,num:s}=t,a=Math.floor(s),i=e.makeOutput([a],\"float32\");return fM(e.dataIdMap.get(i.dataId).id,o,n,a),i}var hM={kernelName:Fn,backendName:\"wasm\",setupFunc:qoe,kernelFunc:joe};var gM=he(Pn);var xM=he(On);var Xoe=!1,yM=Ue(Mn,Xoe,\"bool\");var bM=he(Ln);var Yoe=!1,CM=Ue(Bn,Yoe,\"bool\");var Qoe=!1,wM=Ue($0,Qoe,\"bool\");var SM;function Zoe(r){SM=r.wasm.cwrap(zn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Joe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o;if(n.dtype!==\"float32\")throw new Error(\"LRN error: x must have dtype float32\");let u=e.makeOutput(n.shape,n.dtype);return SM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(u.dataId).id,n.shape[3],s,a,i,p),u}var IM={kernelName:zn,backendName:\"wasm\",setupFunc:Zoe,kernelFunc:Joe};var vM;function ene(r){vM=r.wasm.cwrap(Qa,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function tne(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,y:s,dy:a}=t,{depthRadius:i,bias:p,alpha:u,beta:c}=o;if(n.dtype!==\"float32\"||s.dtype!==\"float32\"||a.dtype!==\"float32\")throw new Error(\"LRNGrad error: x, y, and dy must have dtype float32\");let l=e.makeOutput(n.shape,n.dtype);return vM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(a.dataId).id,e.dataIdMap.get(l.dataId).id,a.shape[3],i,p,u,c),l}var kM={kernelName:Qa,backendName:\"wasm\",setupFunc:ene,kernelFunc:tne};var NM;function rne(r){NM=r.wasm.cwrap(Vn,null,[\"number\",\"number\",\"number\",\"number\"])}function one(r){let{backend:t,inputs:e,attrs:o}=r,{reductionIndices:n,keepDims:s}=o,{x:a}=e,p=t.dataIdMap.get(a.dataId).id,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t);if(d){let C=t.dataIdMap.get(c.dataId).id;u=c,p=C}let f=u.shape.length;w.assertAxesAreInnerMostDims(\"max\",l,f);let[h,g]=w.computeOutAndReduceShapes(u.shape,l),x=y.sizeFromShape(g),b=t.makeOutput(h,a.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;NM(p,we[a.dtype],x,C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var TM={kernelName:Vn,backendName:\"wasm\",setupFunc:rne,kernelFunc:one};var nne=!1,_M=Ue(Wn,nne);var $M;function sne(r){$M=r.wasm.cwrap(Un,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function ane(r){let{inputs:t,attrs:e,backend:o}=r,n=t.x,s=o.dataIdMap.get(n.dataId).id;y.assert(n.dtype===\"float32\",()=>`Error in MaxPool: only float32 input is supported. Got ${n.dtype}.`);let{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=e,c=w.computePool2DInfo(n.shape,a,i,1,p,u),l=c.filterHeight,m=c.filterWidth,d=c.padInfo.top,f=c.padInfo.right,h=c.padInfo.bottom,g=c.padInfo.left,x=c.dilationHeight,b=c.dilationWidth,C=c.strideHeight,S=c.strideWidth,k=c.inChannels,_=c.outChannels;if(c.dataFormat!==\"channelsLast\")throw new Error(`wasm backend does not support dataFormat:'${c.dataFormat}'. Please use 'channelsLast'.`);let E=o.makeOutput(c.outShape,\"float32\"),R=o.dataIdMap.get(E.dataId).id;return $M(s,n.shape[0],n.shape[1],n.shape[2],l,m,d,f,h,g,x,b,C,S,k,_,R),E}var EM={kernelName:Un,backendName:\"wasm\",setupFunc:sne,kernelFunc:ane};var RM;function ine(r){RM=r.wasm.cwrap(\"MaxPool3D\",null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function une(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o,c=w.computePool3DInfo(n.shape,s,a,1,i,p,u),l=e.makeOutput(c.outShape,n.dtype);return RM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,c.batchSize,c.inChannels,c.inDepth,c.inHeight,c.inWidth,c.outDepth,c.outHeight,c.outWidth,c.strideDepth,c.strideHeight,c.strideWidth,c.dilationDepth,c.dilationHeight,c.dilationWidth,c.effectiveFilterDepth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.front,c.padInfo.top,c.padInfo.left),l}var DM={kernelName:ia,backendName:\"wasm\",setupFunc:ine,kernelFunc:une};var AM;function pne(r){AM=r.wasm.cwrap(\"MaxPool3DGrad\",null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function cne(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o,c=w.computePool3DInfo(s.shape,a,i,1,p,u),l=e.makeOutput(s.shape,s.dtype);return AM(e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,c.batchSize,c.inChannels,c.inDepth,c.inHeight,c.inWidth,c.outDepth,c.outHeight,c.outWidth,c.strideDepth,c.strideHeight,c.strideWidth,c.dilationDepth,c.dilationHeight,c.dilationWidth,c.effectiveFilterDepth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.front,c.padInfo.top,c.padInfo.left),l}var FM={kernelName:Ki,backendName:\"wasm\",setupFunc:pne,kernelFunc:cne};var PM;function lne(r){PM=r.wasm.cwrap(\"MaxPoolGrad\",null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function mne(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o,c=w.computePool2DInfo(s.shape,a,i,1,p,u),l=e.makeOutput(s.shape,s.dtype);return PM(e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.top,c.padInfo.left),l}var OM={kernelName:Hi,backendName:\"wasm\",setupFunc:lne,kernelFunc:mne};var MM;function dne(r){MM=r.wasm.cwrap(\"MaxPoolWithArgmax\",null,[\"number\",\"number\",\"number\",\"number\",\"boolean\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function fne(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,includeBatchInIndex:p}=o;y.assert(n.shape.length===4,()=>`Error in maxPool: input must be rank 4 but got rank ${n.shape.length}.`);let u=[1,1];y.assert(w.eitherStridesOrDilationsAreOne(a,u),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,[1,1],i),l=e.makeOutput(c.outShape,n.dtype),m=e.makeOutput(c.outShape,\"int32\");return MM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,e.dataIdMap.get(m.dataId).id,we[n.dtype],p,c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.top,c.padInfo.left),[l,m]}var LM={kernelName:ua,backendName:\"wasm\",setupFunc:dne,kernelFunc:fne};var BM;function hne(r){BM=r.wasm.cwrap(Gn,null,[\"number, number, number\"])}function gne(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t),f=l;if(d){let S=t.dataIdMap.get(c.dataId).id;S!==i&&(u=c,p=S,f=w.getInnerMostAxes(f.length,u.shape.length))}w.assertAxesAreInnerMostDims(\"mean\",f,u.shape.length);let[h,g]=w.computeOutAndReduceShapes(u.shape,f),x=y.sizeFromShape(g),b=u;u.dtype!==\"float32\"&&(b=Mr({backend:t,inputs:{x:u},attrs:{dtype:\"float32\"}}),p=t.dataIdMap.get(b.dataId).id);let C=t.makeOutput(h,\"float32\");if(y.sizeFromShape(u.shape)!==0){let S=t.dataIdMap.get(C.dataId).id;BM(p,x,S)}if(d&&t.disposeData(c.dataId),s){let S=w.expandShapeToKeepDim(C.shape,m);C.shape=S}return u.dtype!==\"float32\"&&t.disposeData(b.dataId),C}var zM={kernelName:Gn,backendName:\"wasm\",setupFunc:hne,kernelFunc:gne};var VM;function xne(r){VM=r.wasm.cwrap(Hn,null,[\"number\",\"number\",\"number\",\"number\"])}function yne(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t);if(d){let C=t.dataIdMap.get(c.dataId).id;C!==i&&(u=c,p=C)}let f=u.shape.length;w.assertAxesAreInnerMostDims(\"min\",l,f);let[h,g]=w.computeOutAndReduceShapes(u.shape,l),x=y.sizeFromShape(g),b=t.makeOutput(h,u.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;VM(p,we[a.dtype],x,C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var WM={kernelName:Hn,backendName:\"wasm\",setupFunc:xne,kernelFunc:yne};var bne=!1,UM=Ue(Kn,bne);var Ov;(function(r){r[r.reflect=0]=\"reflect\",r[r.symmetric=1]=\"symmetric\"})(Ov||(Ov={}));var GM;function Cne(r){GM=r.wasm.cwrap(qn,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"array\",\"number\",\"number\"])}function wne(r){let{inputs:{x:t},backend:e,attrs:{paddings:o,mode:n}}=r,s=o.map((f,h)=>f[0]+t.shape[h]+f[1]),a=e.dataIdMap.get(t.dataId).id,i=e.makeOutput(s,t.dtype),p=e.dataIdMap.get(i.dataId).id,u=new Uint8Array(new Int32Array(t.shape).buffer),c=o.map(f=>f[0]),l=o.map(f=>f[1]),m=new Uint8Array(new Int32Array(c).buffer),d=new Uint8Array(new Int32Array(l).buffer);return GM(a,u,t.shape.length,we[t.dtype],m,d,Ov[n],p),i}var HM={kernelName:qn,backendName:\"wasm\",kernelFunc:wne,setupFunc:Cne};var KM;function Sne(r){KM=r.wasm.cwrap(vs,null,[\"number\",\"number\",\"number\",\"number\"])}function Mv(r){let{backend:t,inputs:{logits:e},attrs:{dim:o}}=r,n=t.dataIdMap.get(e.dataId).id,s=t.makeOutput(e.shape,e.dtype),a=t.dataIdMap.get(s.dataId).id,i=e.shape[o],p=y.sizeFromShape(e.shape)/i;return y.sizeFromShape(s.shape)===0||KM(n,a,i,p),s}var qM={kernelName:vs,backendName:\"wasm\",setupFunc:Sne,kernelFunc:Mv};var jM;function Ine(r){jM=r.wasm.cwrap(Xn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function vne(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o;if(n.dtype!==\"float32\")throw new Error(`Tensor logits must have dtype float32, got ${n.dtype}`);let p=i?n:Mv({inputs:{logits:n},backend:e,attrs:{dim:n.shape.length-1}}),[u,c]=p.shape,l=e.makeOutput([u,s],\"int32\");return jM(e.dataIdMap.get(p.dataId).id,u,c,s,a,e.dataIdMap.get(l.dataId).id),i||e.disposeData(p.dataId),l}var XM={kernelName:Xn,backendName:\"wasm\",setupFunc:Ine,kernelFunc:vne};var YM=Ue(jn,!0);var kne=!0,QM=Ue(Yn,kne);var ZM=he(pa);function Yc(r,t){let e=new Int32Array(r.wasm.HEAPU8.buffer,t,4),o=e[0],n=e[1],s=e[2],a=e[3];return r.wasm._free(t),{pSelectedIndices:o,selectedSize:n,pSelectedScores:s,pValidOutputs:a}}var JM;function Nne(r){JM=r.wasm.cwrap(Zn,\"number\",[\"number\",\"number\",\"number\",\"number\",\"number\"])}function Tne(r){let{backend:t,inputs:e,attrs:o}=r,{iouThreshold:n,maxOutputSize:s,scoreThreshold:a}=o,{boxes:i,scores:p}=e,u=t.dataIdMap.get(i.dataId).id,c=t.dataIdMap.get(p.dataId).id,l=JM(u,c,s,n,a),{pSelectedIndices:m,selectedSize:d,pSelectedScores:f,pValidOutputs:h}=Yc(t,l);return t.wasm._free(f),t.wasm._free(h),t.makeOutput([d],\"int32\",m)}var eL={kernelName:Zn,backendName:\"wasm\",setupFunc:Nne,kernelFunc:Tne};var tL;function _ne(r){tL=r.wasm.cwrap(Za,\"number\",[\"number\",\"number\",\"number\",\"number\",\"number\",\"bool\"])}function $ne(r){let{backend:t,inputs:e,attrs:o}=r,{iouThreshold:n,maxOutputSize:s,scoreThreshold:a,padToMaxOutputSize:i}=o,{boxes:p,scores:u}=e,c=t.dataIdMap.get(p.dataId).id,l=t.dataIdMap.get(u.dataId).id,m=tL(c,l,s,n,a,i),{pSelectedIndices:d,selectedSize:f,pSelectedScores:h,pValidOutputs:g}=Yc(t,m);t.wasm._free(h);let x=t.makeOutput([f],\"int32\",d),b=t.makeOutput([],\"int32\",g);return[x,b]}var rL={kernelName:Za,backendName:\"wasm\",setupFunc:_ne,kernelFunc:$ne};var oL;function Ene(r){oL=r.wasm.cwrap(Jn,\"number\",[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Rne(r){let{backend:t,inputs:e,attrs:o}=r,{iouThreshold:n,maxOutputSize:s,scoreThreshold:a,softNmsSigma:i}=o,{boxes:p,scores:u}=e,c=t.dataIdMap.get(p.dataId).id,l=t.dataIdMap.get(u.dataId).id,m=oL(c,l,s,n,a,i),{pSelectedIndices:d,selectedSize:f,pSelectedScores:h,pValidOutputs:g}=Yc(t,m);t.wasm._free(g);let x=t.makeOutput([f],\"int32\",d),b=t.makeOutput([f],\"float32\",h);return[x,b]}var nL={kernelName:Jn,backendName:\"wasm\",setupFunc:Ene,kernelFunc:Rne};var Dne=!1,sL=Ue(Qn,Dne,\"bool\");var aL;function Ane(r){aL=r.wasm.cwrap(es,null,[\"number\",\"number\",\"number\",\"number\",\"number\"])}function Fne(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n}=t,{dtype:s,depth:a,onValue:i,offValue:p}=o,u=e.makeOutput([...n.shape,a],s),c=e.dataIdMap.get(u.dataId).id,m=e.dataIdMap.get(n.dataId).id;return aL(m,a,i,p,c),u}var iL={kernelName:es,backendName:\"wasm\",setupFunc:Ane,kernelFunc:Fne};function Pne(r){let{inputs:{x:t},backend:e}=r,o=e.makeOutput(t.shape,t.dtype);return e.typedArrayFromHeap(o).fill(1),o}var uL={kernelName:ca,backendName:\"wasm\",kernelFunc:Pne};function One(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o;if(t.length===1)return Lg({inputs:{input:t[0]},backend:e,attrs:{dim:n}});let s=t[0].shape,a=t[0].dtype;t.forEach(c=>{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=Lg({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=Av({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeData(c.dataId)),u}var pL={kernelName:la,backendName:\"wasm\",kernelFunc:One};var cL;function Mne(r){cL=r.wasm.cwrap(ts,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"array\",\"number\",\"number\"])}function Lne(r){let{inputs:{x:t},backend:e,attrs:{paddings:o,constantValue:n}}=r,s=o.map((h,g)=>h[0]+t.shape[g]+h[1]);if(y.sizeFromShape(t.shape)===0)return Pv({backend:e,attrs:{shape:s,value:n,dtype:t.dtype}});let a=e.dataIdMap.get(t.dataId).id,i=e.makeOutput(s,t.dtype),u=e.dataIdMap.get(i.dataId).id,c=new Uint8Array(new Int32Array(t.shape).buffer),l=o.map(h=>h[0]),m=o.map(h=>h[1]),d=new Uint8Array(new Int32Array(l).buffer),f=new Uint8Array(new Int32Array(m).buffer);return cL(a,c,t.shape.length,we[t.dtype],d,f,n,u),i}var Bg={kernelName:ts,backendName:\"wasm\",kernelFunc:Lne,setupFunc:Mne};var Bne=!1,lL=Ue(rs,Bne);var mL;function zne(r){mL=r.wasm.cwrap(os,null,[\"number\",\"number\",\"number\"])}function Vne(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t,s=e.dataIdMap.get(o.dataId).id,a=e.dataIdMap.get(n.dataId).id,i=s,p=o,u=p;p.dtype!==\"float32\"&&(u=Mr({backend:e,inputs:{x:o},attrs:{dtype:\"float32\"}}),i=e.dataIdMap.get(u.dataId).id);let c=e.makeOutput(o.shape,\"float32\"),l=e.dataIdMap.get(c.dataId).id;return mL(i,a,l),p.dtype!==\"float32\"&&e.disposeData(u.dataId),c}var dL={kernelName:os,backendName:\"wasm\",setupFunc:zne,kernelFunc:Vne};var fL;function Wne(r){fL=r.wasm.cwrap(ns,null,[\"number\",\"number\",\"number\",\"number\"])}function Une(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t),f=l;if(d){let C=t.dataIdMap.get(c.dataId).id;C!==i&&(u=c,p=C,f=w.getInnerMostAxes(f.length,u.shape.length))}w.assertAxesAreInnerMostDims(\"prod\",f,u.shape.length);let[h,g]=w.computeOutAndReduceShapes(u.shape,f),x=y.sizeFromShape(g),b=t.makeOutput(h,u.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;fL(p,x,we[b.dtype],C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var hL={kernelName:ns,backendName:\"wasm\",setupFunc:Wne,kernelFunc:Une};var Gne=r=>{let{backend:t,attrs:e}=r,{start:o,stop:n,step:s,dtype:a}=e,i=fp(o,n,s,a),p=t.makeOutput([i.length],a);return t.typedArrayFromHeap(p).set(i),p},gL={kernelName:ma,backendName:\"wasm\",kernelFunc:Gne};var Hne=!0,xL=Ue(hn,Hne);var yL=he(ss);var bL=he(as);var CL=he(ps);var wL;function Kne(r){wL=r.wasm.cwrap(us,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function qne(r){let{backend:t,inputs:e,attrs:o}=r,{images:n}=e,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,[c,l,m,d]=n.shape,f=[c,p,u,d],h=t.dataIdMap.get(n.dataId),g;h.dtype!==\"float32\"&&(g=Mr({backend:t,inputs:{x:n},attrs:{dtype:\"float32\"}}),h=t.dataIdMap.get(g.dataId));let x=h.id,b=t.makeOutput(f,\"float32\");if(y.sizeFromShape(n.shape)===0)return b;let C=t.dataIdMap.get(b.dataId).id;return wL(x,c,l,m,d,p,u,s?1:0,a?1:0,C),g!=null&&t.disposeData(g.dataId),b}var SL={kernelName:us,backendName:\"wasm\",setupFunc:Kne,kernelFunc:qne};var IL;function jne(r){IL=r.wasm.cwrap(ei,null,[\"number\",\"number\",\"number\",\"array\",\"array\",\"boolean\"])}function Xne(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=e.makeOutput(n.shape,\"float32\"),p=e.dataIdMap.get(n.dataId),u;return p.dtype!==\"float32\"&&(u=Mr({backend:e,inputs:{x:n},attrs:{dtype:\"float32\"}}),p=e.dataIdMap.get(u.dataId)),IL(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(i.dataId).id,new Uint8Array(new Int32Array(n.shape).buffer),new Uint8Array(new Int32Array(s.shape).buffer),a),u!=null&&e.disposeData(u.dataId),i}var vL={kernelName:ei,backendName:\"wasm\",setupFunc:jne,kernelFunc:Xne};var kL;function Yne(r){kL=r.wasm.cwrap(is,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Qne(r){let{backend:t,inputs:e,attrs:o}=r,{images:n}=e,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,[c,l,m,d]=n.shape,f=[c,p,u,d],h=t.makeOutput(f,\"float32\");if(y.sizeFromShape(n.shape)===0)return h;let g=t.dataIdMap.get(n.dataId),x;g.dtype!==\"float32\"&&(x=Mr({backend:t,inputs:{x:n},attrs:{dtype:\"float32\"}}),g=t.dataIdMap.get(x.dataId));let b=g.id,C=t.dataIdMap.get(h.dataId).id;return kL(b,c,l,m,d,p,u,s?1:0,a?1:0,C),x!=null&&t.disposeData(x.dataId),h}var NL={kernelName:is,backendName:\"wasm\",setupFunc:Yne,kernelFunc:Qne};var TL;function Zne(r){TL=r.wasm.cwrap(Ja,null,[\"number\",\"number\",\"number\",\"array\",\"array\",\"boolean\"])}function Jne(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=e.makeOutput(n.shape,\"float32\"),p=e.dataIdMap.get(n.dataId),u;return p.dtype!==\"float32\"&&(u=Mr({backend:e,inputs:{x:n},attrs:{dtype:\"float32\"}}),p=e.dataIdMap.get(u.dataId)),TL(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(i.dataId).id,new Uint8Array(new Int32Array(n.shape).buffer),new Uint8Array(new Int32Array(s.shape).buffer),a),u!=null&&e.disposeData(u.dataId),i}var _L={kernelName:Ja,backendName:\"wasm\",setupFunc:Zne,kernelFunc:Jne};var $L;function ese(r){$L=r.wasm.cwrap(cs,null,[\"number\",\"array\",\"number\",\"array\",\"number\",\"number\"])}function tse(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o,a=y.parseAxisParam(s,n.shape);if(n.shape.length===0)return Dp({inputs:{x:n},backend:e});let i=e.makeOutput(n.shape,n.dtype),p=e.dataIdMap.get(n.dataId).id,u=e.dataIdMap.get(i.dataId).id,c=new Uint8Array(new Int32Array(a).buffer),l=new Uint8Array(new Int32Array(n.shape).buffer);$L(p,c,a.length,l,n.shape.length,u);let m=Vt({inputs:{x:i},attrs:{shape:n.shape},backend:e});return e.disposeData(i.dataId),m}var EL={kernelName:cs,backendName:\"wasm\",kernelFunc:tse,setupFunc:ese};var RL;function rse(r){RL=r.wasm.cwrap(As,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\"])}function ose(r){let{inputs:t,backend:e,attrs:o}=r,{image:n}=t,{radians:s,fillValue:a,center:i}=o,p=e.makeOutput(n.shape,n.dtype),u=e.dataIdMap.get(n.dataId).id,c=e.dataIdMap.get(p.dataId).id,[l,m,d,f]=n.shape,[h,g]=w.getImageCenter(i,m,d),x=a===0,b=255,C=typeof a==\"number\"?[a,a,a,x?0:b]:[...a,b],S=new Uint8Array(new Int32Array(C).buffer);return RL(u,l,m,d,f,s,h,g,S,C.length,c),p}var DL={kernelName:As,backendName:\"wasm\",kernelFunc:ose,setupFunc:rse};var AL=he(ls);var FL=he(ms);var PL;function nse(r){PL=r.wasm.cwrap(ds,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\"])}function sse(r){let{backend:t,inputs:e,attrs:o}=r,{indices:n,updates:s}=e,{shape:a}=o,i=t.makeOutput(a,s.dtype);if(y.sizeFromShape(a)===0)return i;let{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=hu.calculateShapes(s,n,a),f=t.dataIdMap.get(n.dataId).id,g=t.dataIdMap.get(s.dataId).id,x=new Uint8Array(new Int32Array(l).buffer),b=t.dataIdMap.get(i.dataId).id;return PL(f,g,we[s.dtype],p,u,c,x,m,b),i}var OL={kernelName:ds,backendName:\"wasm\",setupFunc:nse,kernelFunc:sse};var ML;function ase(r){ML=r.wasm.cwrap(hs,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"bool\",\"number\"])}function ise(r){let{inputs:t,backend:e,attrs:o}=r,{sortedSequence:n,values:s}=t,{side:a}=o;if(n.dtype!==s.dtype)throw new Error(`SearchSorted error: sorted_sequence must have the same dtype as values. Got ${n.dtype} and ${s.dtype}`);let i=e.makeOutput(s.shape,\"int32\");function p(u){return e.dataIdMap.get(u.dataId).id}return ML(p(n),p(s),n.shape[0],n.shape[1],s.shape[1],we[n.dtype],a===\"left\",p(i)),i}var LL={kernelName:hs,backendName:\"wasm\",setupFunc:ase,kernelFunc:ise};var BL;function use(r){BL=r.wasm.cwrap(\"SelectV2\",null,[\"number\",\"number\",\"number\",\"number\",\"number\"])}function pse(r){let{inputs:t,backend:e}=r,{condition:o,t:n,e:s}=t,a=e.dataIdMap.get(o.dataId).id,i=e.dataIdMap.get(n.dataId).id,p=e.dataIdMap.get(s.dataId).id,u=e.makeOutput(n.shape,n.dtype),c=e.dataIdMap.get(u.dataId).id,l=o.shape.length,m=n.shape.length,d=l===0||l>1||m===1?1:y.sizeFromShape(n.shape.slice(1));return BL(a,i,p,d,c),u}var zL={kernelName:fa,backendName:\"wasm\",kernelFunc:pse,setupFunc:use};var VL=he(gs);var WL;function cse(r){WL=r.wasm.cwrap(Cs,null,[\"number\",\"number\"])}function lse(r){let{backend:t,inputs:{x:e}}=r,o=t.dataIdMap.get(e.dataId).id,n=t.makeOutput(e.shape,e.dtype),s=t.dataIdMap.get(n.dataId).id;return y.sizeFromShape(n.shape)===0||WL(o,s),n}var UL={kernelName:\"Sigmoid\",backendName:\"wasm\",setupFunc:cse,kernelFunc:lse};var GL=he(bs);var HL=he(xs);var KL=he(ys);var qL=he(ws);function mse(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,paddings:a}=o,i=y.sizeFromShape(s),p=[[0,0]];p.push(...a);for(let _=1+s.length;_0?p+1:0;if(c<0)throw new Error(w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage());let l=n.shape.slice();l[0]=c;let m=e.dataIdMap.get(n.dataId).id,d=e.dataIdMap.get(s.dataId).id,f=e.dataIdMap.get(a.dataId).id,h=e.makeOutput(l,n.dtype),g=e.dataIdMap.get(h.dataId).id,x=e.makeOutput([4],\"int32\"),b=e.dataIdMap.get(x.dataId).id;JL(m,we[n.dtype],n.shape[0],d,f,g,b,t,0);let C=e.readSync(x.dataId),S;switch(C[0]){case 0:{S=w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage();break}case 1:{S=w.getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage();break}case 2:S=w.getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage(C[1],C[2]);break;case 3:S=w.getSparseSegmentReductionIndicesOutOfRangeErrorMessage(C[1],C[2],C[3]);break;default:S=\"\"}if(e.disposeData(x.dataId),S)throw e.disposeData(h.dataId),new Error(S);return h}function xse(r){return Vg(r,!0)}var eB={kernelName:ya,backendName:\"wasm\",setupFunc:zg,kernelFunc:xse};function yse(r){return Vg(r,!1)}var tB={kernelName:ba,backendName:\"wasm\",setupFunc:zg,kernelFunc:yse};var rB;function bse(r){rB=r.wasm.cwrap(ks,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\"])}function Cse(r){let{backend:t,inputs:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=e,{outputShape:i}=o,p=t.makeOutput(i,a.dtype);if(y.sizeFromShape(i)===0)return p;let{sliceRank:u,numUpdates:c,sliceSize:l,strides:m,outputSize:d}=w.calculateShapes(s,n,i),f=t.dataIdMap.get(n.dataId).id,h=t.dataIdMap.get(s.dataId).id,g=t.dataIdMap.get(a.dataId).id,x=new Uint8Array(new Int32Array(m).buffer),b=t.dataIdMap.get(p.dataId).id;return rB(f,h,s.shape.length,g,we[a.dtype],u,c,l,x,d,b),p}var oB={kernelName:ks,backendName:\"wasm\",setupFunc:bse,kernelFunc:Cse};function wse(r){let{inputs:t,attrs:e,backend:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=e,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=new Array(n.shape.length).fill(0),c=n.shape.slice();return p.map(l=>{let m=[...c];m[i]=l;let d=Oo({inputs:{x:n},attrs:{begin:u,size:m},backend:o});return u[i]+=l,d})}var nB={kernelName:xa,backendName:\"wasm\",kernelFunc:wse};var sB=he(Ss);var aB=he(Xi);var Sse=!0,iB=Ue(Ns,Sse);var uB;function Ise(r){uB=r.wasm.cwrap(So,null,[\"number\",\"number\",\"number\",\"number\"])}function vse(r){let{backend:t,inputs:e,attrs:o}=r,{alpha:n}=o,{x:s}=e,a=t.dataIdMap.get(s.dataId).id,i=t.makeOutput(s.shape,s.dtype),p=t.dataIdMap.get(i.dataId).id;return uB(a,n,we[s.dtype],p),i}var pB={kernelName:So,backendName:\"wasm\",setupFunc:Ise,kernelFunc:vse};var cB;function kse(r){cB=r.wasm.cwrap(Ts,null,[\"number\",\"array\",\"number\",\"array\",\"array\",\"array\",\"array\",\"array\",\"number\",\"number\"])}function Nse(r){let{backend:t,inputs:e,attrs:o}=r,{x:n}=e,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o,{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=Vt({inputs:{x:n},backend:t,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let _=ct.computeOutShape(b,C,S),E=Oo({inputs:{x:n},backend:t,attrs:{begin:b,size:_}});k=Vt({inputs:{x:E},backend:t,attrs:{shape:f}}),t.disposeData(E.dataId)}else{let _=t.makeOutput(d,\"float32\"),E=t.dataIdMap.get(n.dataId).id,R=new Uint8Array(new Int32Array(y.computeStrides(n.shape)).buffer),D=new Uint8Array(new Int32Array(b).buffer),P=new Uint8Array(new Int32Array(C).buffer),O=new Uint8Array(new Int32Array(S).buffer),M=new Uint8Array(new Int32Array(d).buffer),L=new Uint8Array(new Int32Array(y.computeStrides(d)).buffer),B=t.dataIdMap.get(_.dataId).id;cB(E,R,n.shape.length,D,P,O,M,L,d.length,B),k=Vt({inputs:{x:_},backend:t,attrs:{shape:f}}),t.disposeData(_.dataId)}return k}var lB={kernelName:Ts,backendName:\"wasm\",setupFunc:kse,kernelFunc:Nse};function Tse(r){let{backend:t,inputs:e,attrs:o}=r,{data:n,dataSplits:s}=e,{separator:a,nGramWidths:i,leftPad:p,rightPad:u,padWidth:c,preserveShortSequences:l}=o,m=t.readSync(n.dataId),d=t.readSync(s.dataId),[f,h]=gp(m,d,a,i,p,u,c,l),g=t.makeOutput([f.length],\"string\"),x=t.dataIdMap.get(g.dataId);x.stringBytes=f;let b=t.makeOutput(s.shape,\"int32\");return t.typedArrayFromHeap(b).set(h),[g,b]}var mB={kernelName:Ca,backendName:\"wasm\",kernelFunc:Tse};function _se(r){let{backend:t,inputs:e,attrs:o}=r,{input:n,delimiter:s}=e,{skipEmpty:a}=o,i=t.readSync(n.dataId),p=t.readSync(s.dataId),[u,c,l]=xp(i,p[0],a),m=c.length,d=t.makeOutput([m,2],\"int32\");t.typedArrayFromHeap(d).set(u);let h=t.makeOutput([m],\"string\"),g=t.dataIdMap.get(h.dataId);g.stringBytes=c;let x=t.makeOutput([2],\"int32\");return t.typedArrayFromHeap(x).set(l),[d,h,x]}var dB={kernelName:Yi,backendName:\"wasm\",kernelFunc:_se};function $se(r){let{backend:t,inputs:e,attrs:o}=r,{input:n}=e,{numBuckets:s}=o,a=t.readSync(n.dataId),i=yp(a,s),p=t.makeOutput(n.shape,\"int32\");return t.typedArrayFromHeap(p).set(i),p}var fB={kernelName:Qi,backendName:\"wasm\",kernelFunc:$se};var Ese=!0,hB=Ue(_s,Ese);var gB;function Rse(r){gB=r.wasm.cwrap(Is,null,[\"number\",\"number\",\"number\",\"number\"])}function Dse(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t),f=l;if(d){let C=t.dataIdMap.get(c.dataId).id;C!==i&&(u=c,p=C,f=w.getInnerMostAxes(f.length,u.shape.length))}w.assertAxesAreInnerMostDims(\"sum\",f,u.shape.length);let[h,g]=w.computeOutAndReduceShapes(u.shape,f),x=y.sizeFromShape(g),b=t.makeOutput(h,u.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;gB(p,x,we[b.dtype],C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var xB={kernelName:Is,backendName:\"wasm\",setupFunc:Rse,kernelFunc:Dse};var yB=he($s);var bB=he(Es);var CB;function Ase(r){CB=r.wasm.cwrap(fs,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\"])}function Fse(r){let{backend:t,inputs:e,attrs:o}=r,{tensor:n,indices:s,updates:a}=e,{}=o,i=t.makeOutput(n.shape,n.dtype);if(y.sizeFromShape(n.shape)===0)return i;let{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=hu.calculateShapes(a,s,n.shape),f=t.dataIdMap.get(s.dataId).id,g=t.dataIdMap.get(a.dataId).id,b=t.dataIdMap.get(n.dataId).id,C=new Uint8Array(new Int32Array(l).buffer),S=t.dataIdMap.get(i.dataId).id;return CB(f,g,we[a.dtype],p,u,c,C,m,S,b),i}var wB={kernelName:fs,backendName:\"wasm\",setupFunc:Ase,kernelFunc:Fse};var SB;function Pse(r){SB=r.wasm.cwrap(po,null,[\"number\",\"array\",\"number\",\"array\",\"number\",\"number\"])}function Ose(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,s=e.dataIdMap.get(n.dataId).id,{reps:a}=o,i=new Array(n.shape.length);for(let m=0;m{let{x:o}=r,{k:n,sorted:s}=e,a=t.dataIdMap.get(o.dataId).id,i=new Uint8Array(new Int32Array(o.shape).buffer),p=o.shape.slice();p[p.length-1]=n;let u=t.makeOutput(p,o.dtype),c=t.dataIdMap.get(u.dataId).id,l=t.makeOutput(p,\"int32\"),m=t.dataIdMap.get(l.dataId).id;return vB(a,i,o.shape.length,we[o.dtype],n,s,c,m),[u,l]},kB={kernelName:Rs,backendName:\"wasm\",setupFunc:Mse,kernelFunc:Lse};var NB;function Bse(r){NB=r.wasm.cwrap(Ds,null,[\"number\",\"number\",\"bool\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"array\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function zse(r){let{backend:t,inputs:e,attrs:o}=r,{image:n,transforms:s}=e,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=o,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=new Uint8Array(new Int32Array(y.computeStrides(n.shape)).buffer),b=new Uint8Array(new Int32Array(y.computeStrides(g)).buffer),C=t.makeOutput(g,n.dtype),S=t.dataIdMap.get(C.dataId).id,_=t.dataIdMap.get(n.dataId).id,R=t.dataIdMap.get(s.dataId).id,D=a===\"nearest\"?1:2,P;switch(i){case\"constant\":P=1;break;case\"reflect\":P=2;break;case\"wrap\":P=3;break;case\"nearest\":P=4;break;default:P=1;break}return NB(_,R,s.shape[0]>1,c,f,h,d,m,l,x,n.shape.length-1,b,g.length-1,D,P,p,S),C}var TB={kernelName:Ds,backendName:\"wasm\",setupFunc:Bse,kernelFunc:zse};function Vse(r){let{inputs:t,attrs:e,backend:o}=r,{axis:n}=e,{x:s}=t,{outputValues:a,outputShape:i,indices:p}=bp(o.readSync(s.dataId),n,s.shape,s.dtype);return[o.makeOutput(i,s.dtype,void 0,a),o.makeOutput([p.length],\"int32\",void 0,p)]}var _B={kernelName:Zi,backendName:\"wasm\",kernelFunc:Vse};function Wse(r){let{inputs:t,backend:e,attrs:o}=r,{value:n}=t,{axis:s}=o;s<0&&(s+=n.shape.length);let a=n.shape[s],i=n.shape.length,p=new Array(i-1),u=0;for(let d=0;d({dataId:d,dtype:f,shape:p}))}var $B={kernelName:wa,backendName:\"wasm\",kernelFunc:Wse};function Use(r){let{inputs:{x:t},backend:e}=r,o=e.makeOutput(t.shape,t.dtype);return e.typedArrayFromHeap(o).fill(0),o}var EB={kernelName:Sa,backendName:\"wasm\",kernelFunc:Use};var Gse=[hP,gP,xP,yP,bP,wP,NP,_P,$P,EP,RP,DP,AP,FP,PP,MP,UP,BP,VP,KP,jP,YP,QP,ZP,JP,eO,rO,oO,sO,iO,pO,lO,dO,fO,hO,xO,bO,wO,IO,kO,TO,$O,RO,AO,PO,OO,LO,BO,zO,VO,WO,UO,GO,KO,qO,jO,YO,ZO,eM,rM,nM,sM,aM,SP,iM,uM,pM,lM,mM,dM,hM,xM,gM,yM,bM,CM,wM,IM,kM,TM,_M,EM,DM,FM,OM,LM,zM,WM,UM,HM,XM,YM,QM,ZM,eL,rL,nL,sL,iL,uL,pL,Bg,lL,dL,hL,gL,xL,yL,bL,CL,GP,SL,vL,NL,_L,EL,DL,AL,FL,OL,LL,zL,VL,UL,GL,HL,KL,qP,qM,qL,jL,YL,ZL,eB,tB,oB,nB,sB,aB,iB,pB,lB,mB,dB,fB,hB,xB,yB,bB,wB,IB,kB,TB,vP,_B,$B,EB];for(let r of Gse)ri(r);var Lv=A();Lv.registerFlag(\"WASM_HAS_SIMD_SUPPORT\",async()=>{try{return WebAssembly.validate(new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,2,1,0,10,9,1,7,0,65,0,253,15,26,11]))}catch(r){return!1}});Lv.registerFlag(\"WASM_HAS_MULTITHREAD_SUPPORT\",async()=>{if(Lv.get(\"IS_NODE\"))return!1;try{return new MessageChannel().port1.postMessage(new SharedArrayBuffer(1)),WebAssembly.validate(new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,2,1,0,5,4,1,3,1,1,10,11,1,9,0,65,0,254,16,2,0,26,11]))}catch(r){return!1}});var Kv=Kp(FB()),zB=Kp(OB()),qv=Kp(MB());var LB=Kv.default||Kv,Hse=qv.default||qv,pm=class extends ao{constructor(t){super(),this.wasm=t,this.dataIdNextNumber=1,this.wasm.tfjs.initWithThreadsCount(WB),Hv=this.wasm.tfjs.getThreadsCount(),this.dataIdMap=new zo(this,pr())}write(t,e,o){let n={id:this.dataIdNextNumber++};return this.move(n,t,e,o,1),n}numDataIds(){return this.dataIdMap.numDataIds()}async time(t){let e=y.now();return t(),{kernelMs:y.now()-e}}move(t,e,o,n,s){let a=this.dataIdNextNumber++;if(n===\"string\"){let c=e;this.dataIdMap.set(t,{id:a,stringBytes:c,shape:o,dtype:n,memoryOffset:null,refCount:s});return}let i=y.sizeFromShape(o),p=i*y.bytesPerElement(n),u=this.wasm._malloc(p)>>>0;this.dataIdMap.set(t,{id:a,memoryOffset:u,shape:o,dtype:n,refCount:s}),this.wasm.tfjs.registerTensor(a,i,u),e!=null&&this.wasm.HEAPU8.set(new Uint8Array(e.buffer,e.byteOffset,p),u)}async read(t){return this.readSync(t)}readSync(t,e,o){let{memoryOffset:n,dtype:s,shape:a,stringBytes:i}=this.dataIdMap.get(t);if(s===\"string\")return(e==null||e===0)&&(o==null||o>=i.length)?i:i.slice(e,o);e=e||0,o=o||y.sizeFromShape(a);let p=y.bytesPerElement(s),u=this.wasm.HEAPU8.slice(n+e*p,n+o*p);return qse(u.buffer,s)}disposeData(t,e=!1){if(this.dataIdMap.has(t)){let o=this.dataIdMap.get(t);if(o.refCount--,!e&&o.refCount>0)return!1;this.wasm._free(o.memoryOffset),this.wasm.tfjs.disposeData(o.id),this.dataIdMap.delete(t)}return!0}refCount(t){return this.dataIdMap.has(t)?this.dataIdMap.get(t).refCount:0}incRef(t){let e=this.dataIdMap.get(t);e!=null&&e.refCount++}floatPrecision(){return 32}getMemoryOffset(t){return this.dataIdMap.get(t).memoryOffset}dispose(){this.wasm.tfjs.dispose(),\"PThread\"in this.wasm&&this.wasm.PThread.terminateAllThreads(),this.wasm=null}memory(){return{unreliable:!1}}makeOutput(t,e,o,n){let s;if(o==null)s=this.write(n!=null?n:null,t,e);else{let a=this.dataIdNextNumber++;s={id:a},this.dataIdMap.set(s,{id:a,memoryOffset:o,shape:t,dtype:e,refCount:1});let i=y.sizeFromShape(t);this.wasm.tfjs.registerTensor(a,i,o)}return{dataId:s,shape:t,dtype:e}}typedArrayFromHeap({shape:t,dtype:e,dataId:o}){let n=this.wasm.HEAPU8.buffer,{memoryOffset:s}=this.dataIdMap.get(o),a=y.sizeFromShape(t);switch(e){case\"float32\":return new Float32Array(n,s,a);case\"int32\":return new Int32Array(n,s,a);case\"bool\":return new Uint8Array(n,s,a);default:throw new Error(`Unknown dtype ${e}`)}}};function Kse(r){return(t,e)=>(y.fetch(r,{credentials:\"same-origin\"}).then(o=>{o.ok||t.env.a(`failed to load wasm binary file at '${r}'`),o.arrayBuffer().then(n=>{WebAssembly.instantiate(n,t).then(s=>{e(s.instance,s.module)})})}),{})}function BB(r,t,e){if(Gg!=null)return Gg;let o=\"tfjs-backend-wasm.wasm\";return r&&t?o=\"tfjs-backend-wasm-threaded-simd.wasm\":r&&(o=\"tfjs-backend-wasm-simd.wasm\"),im!=null&&im[o]!=null?im[o]:e+o}async function VB(){let[r,t]=await Promise.all([A().getAsync(\"WASM_HAS_SIMD_SUPPORT\"),A().getAsync(\"WASM_HAS_MULTITHREAD_SUPPORT\")]);return new Promise((e,o)=>{let n={};n.locateFile=(i,p)=>{if(i.endsWith(\".worker.js\")){let u=zB.wasmWorkerContents.replace(/\\n/g,\"\\\\n\"),c=new Blob([u],{type:\"application/javascript\"});return URL.createObjectURL(c)}return i.endsWith(\".wasm\")?BB(r,t,am!=null?am:p):p+i},jv&&(n.instantiateWasm=Kse(BB(r,t,am!=null?am:\"\")));let s=!1;n.onAbort=()=>{if(s||um)return;um=!0,o({message:\"Make sure the server can serve the `.wasm` file relative to the bundled js file. For more details see https://github.com/tensorflow/tfjs/blob/master/tfjs-backend-wasm/README.md#using-bundlers\"})};let a;t&&r&&Gg==null?(n.mainScriptUrlOrBlob=new Blob([\"var WasmBackendModuleThreadedSimd = \"+LB.toString()],{type:\"text/javascript\"}),a=LB(n)):a=Hse(n),a.then(i=>{s=!0,um=!1;let p=null;i.tfjs={init:i.cwrap(\"init\",null,[]),initWithThreadsCount:i.cwrap(\"init_with_threads_count\",null,[\"number\"]),getThreadsCount:i.cwrap(\"get_threads_count\",\"number\",[]),registerTensor:i.cwrap(\"register_tensor\",null,[\"number\",\"number\",\"number\"]),disposeData:i.cwrap(\"dispose_data\",p,[\"number\"]),dispose:i.cwrap(\"dispose\",p,[])},e({wasm:i})}).catch(o)})}function qse(r,t){switch(t){case\"float32\":return new Float32Array(r);case\"int32\":return new Int32Array(r);case\"bool\":return new Uint8Array(r);default:throw new Error(`Unknown dtype ${t}`)}}var jse=[\"tfjs-backend-wasm.wasm\",\"tfjs-backend-wasm-simd.wasm\",\"tfjs-backend-wasm-threaded-simd.wasm\"],Gg=null,am=null,im={},um=!1,jv=!1;function Xse(r,t=!1){if(Pw(\"setWasmPath has been deprecated in favor of setWasmPaths and will be removed in a future release.\"),um)throw new Error(\"The WASM backend was already initialized. Make sure you call `setWasmPath()` before you call `tf.setBackend()` or `tf.ready()`\");Gg=r,jv=t}function Yse(r,t=!1){if(um)throw new Error(\"The WASM backend was already initialized. Make sure you call `setWasmPaths()` before you call `tf.setBackend()` or `tf.ready()`\");if(typeof r==\"string\")am=r;else{im=r;let e=jse.filter(o=>im[o]==null);if(e.length>0)throw new Error(`There were no entries found for the following binaries: ${e.join(\",\")}. Please either call setWasmPaths with a map providing a path for each binary, or with a string indicating the directory where all the binaries can be found.`)}jv=t}var WB=-1,Hv=-1;function Qse(r){WB=r}function Zse(){if(Hv===-1)throw new Error(\"WASM backend not initialized.\");return Hv}var Jse=\"4.11.0\";var eae=2;su(\"wasm\",async()=>{let{wasm:r}=await VB();return new pm(r)},eae);var xo=A();xo.registerFlag(\"WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE\",()=>15);xo.registerFlag(\"WEBGPU_CPU_FORWARD\",()=>!0);xo.registerFlag(\"WEBGPU_MATMUL_PROGRAM_TYPE\",()=>-1);xo.registerFlag(\"WEBGPU_USE_NAIVE_CONV2D_TRANSPOSE\",()=>!0);xo.registerFlag(\"WEBGPU_USE_LOW_POWER_GPU\",()=>!1);xo.registerFlag(\"WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD\",()=>1e3);xo.registerFlag(\"WEBGPU_USE_PROFILE_TOOL\",()=>!1);xo.registerFlag(\"WEBGPU_IMPORT_EXTERNAL_TEXTURE\",()=>!0);xo.registerFlag(\"WEBGPU_USE_NAIVE_CONV2D_DEBUG\",()=>!1);xo.registerFlag(\"WEBGPU_THRESHOLD_TO_INCREASE_WORKGROUPS_FOR_MATMUL\",()=>-1);xo.registerFlag(\"WEBGPU_CONV_SEPARATE_IM2COL_SHADER\",()=>!1);xo.registerFlag(\"WEBGPU_PRINT_SHADER\",()=>\"\");xo.registerFlag(\"WEBGPU_ENGINE_COMPILE_ONLY\",()=>!1);var Hg=class{constructor(t){t&&(this.vendor=t.vendor,this.architecture=t.architecture,this.intelGPUGeneration=this.getIntelGPUGeneration())}getIntelGPUGeneration(){if(this.isIntel()){if(this.architecture.startsWith(\"gen\"))return Number(this.architecture.match(/\\d+/));if(this.architecture.startsWith(\"xe\"))return 12}return 0}isIntel(){return this.vendor===\"intel\"}};var Kg=class{constructor(t){this.device=t,this.numUsedBuffers=0,this.numFreeBuffers=0,this.freeBuffers=new Map,this.usedBuffers=new Map,this.numBytesUsed=0,this.numBytesAllocated=0}acquireBuffer(t,e,o=!1,n=!0){let s,a=UB(t,e);return n?(this.freeBuffers.has(a)||this.freeBuffers.set(a,[]),this.freeBuffers.get(a).length>0?(s=this.freeBuffers.get(a).pop(),this.numFreeBuffers--):(s=this.device.createBuffer({size:t,usage:e,mappedAtCreation:o}),this.numBytesAllocated+=t)):(s=this.device.createBuffer({size:t,usage:e,mappedAtCreation:o}),this.numBytesAllocated+=t),this.usedBuffers.has(a)||this.usedBuffers.set(a,[]),this.usedBuffers.get(a).push(s),this.numUsedBuffers++,this.numBytesUsed+=t,s}releaseBuffer(t,e=!0){if(this.freeBuffers.size===0)return;let o=t.size,n=t.usage,s=UB(o,n),a=this.usedBuffers.get(s),i=a.indexOf(t);if(i<0)throw new Error(\"Cannot find the buffer in buffer manager\");a[i]=a[a.length-1],a.pop(),this.numUsedBuffers--,this.numBytesUsed-=o,e?(this.freeBuffers.get(s).push(t),this.numFreeBuffers++):(t.destroy(),this.numBytesAllocated-=o)}getNumUsedBuffers(){return this.numUsedBuffers}getNumFreeBuffers(){return this.numFreeBuffers}dispose(){this.freeBuffers.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.usedBuffers.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.freeBuffers=new Map,this.usedBuffers=new Map,this.numUsedBuffers=0,this.numFreeBuffers=0,this.numBytesUsed=0,this.numBytesAllocated=0}};function UB(r,t){return`${r}_${t}`}var qg=class{constructor(t){this.device=t,this.numUsedTextures=0,this.numFreeTextures=0,this.freeTextures=new Map,this.usedTextures=new Map,this.numBytesUsed=0,this.numBytesAllocated=0}acquireTexture(t,e,o,n){let s=HB(o),a=t*e*s,i=GB(t,e,o,n);if(this.freeTextures.has(i)||this.freeTextures.set(i,[]),this.usedTextures.has(i)||this.usedTextures.set(i,[]),this.numBytesUsed+=a,this.numUsedTextures++,this.freeTextures.get(i).length>0){this.numFreeTextures--;let u=this.freeTextures.get(i).shift();return this.usedTextures.get(i).push(u),u}this.numBytesAllocated+=a;let p=this.device.createTexture({size:[t,e],format:o,usage:n});return this.usedTextures.get(i).push(p),p}releaseTexture(t){if(this.freeTextures.size===0)return;let e=t.width,o=t.height,n=t.format,s=t.usage,a=GB(e,o,n,s);this.freeTextures.has(a)||this.freeTextures.set(a,[]),this.freeTextures.get(a).push(t),this.numFreeTextures++,this.numUsedTextures--;let i=this.usedTextures.get(a),p=i.indexOf(t);if(p<0)throw new Error(\"Cannot release a texture that was never provided by this texture manager\");i.splice(p,1);let u=HB(n),c=e*o*u;this.numBytesUsed-=c}getNumUsedTextures(){return this.numUsedTextures}getNumFreeTextures(){return this.numFreeTextures}dispose(){this.freeTextures.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.usedTextures.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.freeTextures=new Map,this.usedTextures=new Map,this.numUsedTextures=0,this.numFreeTextures=0,this.numBytesUsed=0,this.numBytesAllocated=0}};function GB(r,t,e,o){return`${r}_${t}_${e}_${o}`}function HB(r){if(r===\"rgba8unorm\")return 16;throw new Error(`${r} is not supported!`)}function KB(r,t){if(Math.max(...r)>5)throw new Error(\"Cannot symbolically compute strides for rank > 6 tensor.\");let e=r.length,o=\"xyzwuv\",n=r.map(a=>`${t}.${o[a]}`),s=new Array(e-1);s[e-2]=n[e-1];for(let a=e-3;a>=0;--a)s[a]=`(${s[a+1]} * ${n[a+1]})`;return s}var Qr=(r,t,e)=>e===\"int32\"?`atomicAdd(${r}, bitcast(${t}));`:`\n {\n var oldValue = 0;\n loop {\n let newValueF32 = bitcast(oldValue) + (${t});\n let newValue = bitcast(newValueF32);\n let res = atomicCompareExchangeWeak(${r}, oldValue, newValue);\n if res.exchanged {\n break;\n }\n oldValue = res.old_value;\n }\n }`;var Ii;(function(r){r[r.FROM_PIXELS=0]=\"FROM_PIXELS\",r[r.DRAW=1]=\"DRAW\"})(Ii||(Ii={}));var YB=(r,t,e,o,n)=>{let s={dtype:o.dtype,shape:o.shape},a=rae(e,s,t),i=r.createShaderModule({code:a,label:t.constructor.name}),p=A().get(\"WEBGPU_PRINT_SHADER\");if(p!==\"\"){p=p.toLowerCase();let u=p.split(\",\");(p===\"all\"||u.some(c=>t.shaderKey.toLowerCase().includes(c)))&&(console.group(t.shaderKey),console.debug(a),console.groupEnd())}return n?r.createComputePipelineAsync({compute:{module:i,entryPoint:\"_start\"},label:t.constructor.name,layout:\"auto\"}):r.createComputePipeline({compute:{module:i,entryPoint:\"_start\"},label:t.constructor.name,layout:\"auto\"})},Ae=(r,t=\"f32\")=>{switch(r){case 1:return`${t}`;case 2:return`vec2<${t}>`;case 3:return`vec3<${t}>`;case 4:return`vec4<${t}>`;default:throw new Error(`${r}-component ${t} is not supported.`)}};function ht(r){if(r<=1)return\"i32\";if(r===2)return\"vec2\";if(r===3)return\"vec3\";if(r===4)return\"vec4\";if(r===5)return\"vec5\";if(r===6)return\"vec6\";throw Error(`GPU for rank ${r} is not yet supported`)}function Mo(r){if(r===0)return\"x\";if(r===1)return\"y\";if(r===2)return\"z\";if(r===3)return\"w\";if(r===4)return\"u\";if(r===5)return\"v\";throw Error(`Index ${r} is not yet supported`)}function G(...r){let t;switch(r.length){case 0:t=`\n fn main()\n `;break;case 1:t=`\n fn main(${r[0]} : i32)\n `;break;default:throw Error(\"Unreachable\")}return t}function qB(r,t){let e;return e=`\n ${tae(t)}\n fn _start(@builtin(local_invocation_id) LocalId : vec3,\n @builtin(global_invocation_id) GlobalId : vec3,\n @builtin(local_invocation_index) LocalIndex: u32,\n @builtin(workgroup_id) WorkgroupId : vec3,\n @builtin(num_workgroups) NumWorkgroups : vec3) {\n localId = LocalId;\n localIndex = LocalIndex;\n globalId = GlobalId;\n numWorkgroups = NumWorkgroups;\n workgroupId = WorkgroupId;\n ${r?\"main(getGlobalIndex());\":\"main();\"};\n }\n `,e}function tae(r){return`\n @compute @workgroup_size(${r.workgroupSize[0]}, ${r.workgroupSize[1]}, ${r.workgroupSize[2]})\n`}function rae(r,t,e){let o=[],n=e.workgroupSize[0]*e.workgroupSize[1]*e.workgroupSize[2];if(e.outputComponent=e.outputComponent?e.outputComponent:1,o.push(`\n\n var localId: vec3;\n var localIndex: u32;\n var globalId: vec3;\n var numWorkgroups: vec3;\n var workgroupId: vec3;\n\n // Only used when the y/z dimension of workgroup size is 1.\n fn getGlobalIndex() -> i32 {\n ${ZB(e)?\" return i32(globalId.x);\":` return i32((workgroupId.z * numWorkgroups.x * numWorkgroups.y +\n workgroupId.y * numWorkgroups.x + workgroupId.x) * ${n}u +\n localIndex);\n `}\n }\n `),e.pixelsOpType!=null){let f=e.pixelsOpType===Ii.FROM_PIXELS?`@group(0) @binding(0) var result: array<${Nu(t.dtype,e.outputComponent)}>;`:`@group(0) @binding(1) var inBuf : array<${Nu(r[0].dtype,e.outputComponent)}>;`,h=t.shape.length===3?\"vec2\":\"i32\";o.push(`\n struct Uniform {\n outShapeStrides : ${h},\n size : i32,\n numChannels : i32,\n alpha : f32,\n };\n\n ${f}\n @group(0) @binding(2) var uniforms: Uniform;\n `);let g=XB(e);return[jB,o.join(`\n`),cm(t.shape),e.getUserCode(),qB(g,e)].join(`\n`)}let s,a,i=\"struct Uniforms { NAN : f32, INFINITY : f32, \";e.variableNames.forEach((f,h)=>{let g=ht(r[h].shape.length);i+=`${f.charAt(0).toLowerCase()+f.slice(1)}Shape : ${g}, `,s=r[h].shape.length-1,a=ht(s),i+=`${f.charAt(0).toLowerCase()+f.slice(1)}ShapeStrides: ${a}, `});let p=ht(t.shape.length);i+=`outShape : ${p}, `,s=t.shape.length-1,a=ht(s),i+=`\n outShapeStrides: ${a}, `,e.size&&(i+=\"size : i32, \"),e.uniforms&&(i+=e.uniforms),i+=\"};\",i=cae(i),o.push(i),e.atomic?o.push(`\n @group(0) @binding(0) var result: array>;\n `):o.push(`\n @group(0) @binding(0) var result: array<${Nu(t.dtype,e.outputComponent)}>;\n `),e.variableNames.forEach((f,h)=>{o.push(`\n @group(0) @binding(${1+h}) var ${f}: array<${e.variableComponents?Nu(r[h].dtype,e.variableComponents[h]):Nu(r[h].dtype,e.outputComponent)}>;\n `)}),i!==\"\"&&o.push(`\n @group(0) @binding(${1+e.variableNames.length}) var uniforms: Uniforms;\n `);let u=iae(t.shape,e.dispatchLayout),c=[jB,o.join(`\n`)+oae,cm(t.shape),u,uae(t.shape.length)];e.atomic||c.push(pae(t.shape,t.dtype,e.outputComponent)),e.variableNames.forEach((f,h)=>{c.push(`${cm(r[h].shape,f)}`)});let l=r.map((f,h)=>aae(f,t.shape,e.variableComponents?e.variableComponents[h]:e.outputComponent,e.dispatchLayout.x.length===t.shape.length)).join(`\n`);c.push(l),c.push(e.getUserCode());let m=XB(e);return c.push(qB(m,e)),c.join(`\n`)}function QB(r,t,e){let o=r.shaderKey;if(r.pixelsOpType!=null)return o;let n=[],s=[];t.forEach(c=>{n.push(c.shape),s.push(c.dtype)}),n.push(e.shape),s.push(e.dtype);let a=t.map(c=>w.getBroadcastDims(c.shape,e.shape)),i=t.map(c=>y.arraysEqual(c.shape,e.shape)).join(\"_\"),p=a.map(c=>c.join(\"_\")).join(\";\"),u=ZB(r)?\"flatDispatch\":\"\";return o+=\"_\"+(r.workgroupSize?r.workgroupSize.join(\",\"):\"\")+n.map(c=>c.length).join(\",\")+s.join(\",\")+r.variableNames.join(\",\")+p+i+u,o}var jB=`\n struct vec5 {x: i32, y: i32, z: i32, w: i32, u: i32};\n struct vec6 {x: i32, y: i32, z: i32, w: i32, u: i32, v: i32};\n\n // Checks whether coordinates lie within the bounds of the shape.\n fn coordsInBounds2D(coord : vec2, shape : vec2) -> bool {\n return all(coord >= vec2(0)) && all(coord < shape);\n }\n fn coordsInBounds3D(coord : vec3, shape : vec3) -> bool {\n return all(coord >= vec3(0)) && all(coord < shape);\n }\n fn coordsInBounds4D(coord : vec4, shape : vec4) -> bool {\n return all(coord >= vec4(0)) && all(coord < shape);\n }\n\n fn getIndexFromCoords1D(coord : i32, shape : i32) -> i32 {\n return coord;\n }\n fn getIndexFromCoords2D(coords : vec2, shape : vec2) -> i32 {\n return dot(coords, vec2(shape.y, 1));\n }\n fn getIndexFromCoords3D(coords : vec3, shape : vec3) -> i32 {\n return dot(coords, vec3(shape.y * shape.z, shape.z, 1));\n }\n fn getIndexFromCoords4D(coords : vec4, shape : vec4) -> i32 {\n return dot(coords, vec4(\n shape.y * shape.z * shape.w, shape.z * shape.w, shape.w, 1));\n }\n fn getIndexFromCoords5D(coords : vec5, shape : vec5) -> i32 {\n let shapeStrides: vec5 = vec5(shape.y * shape.z * shape.w * shape.u, shape.z * shape.w * shape.u, shape.w * shape.u, shape.u, 1);\n return coords.x*shapeStrides.x + coords.y*shapeStrides.y + coords.z*shapeStrides.z + coords.w*shapeStrides.w + coords.u*shapeStrides.u;\n }\n fn getIndexFromCoords6D(coords : vec6, shape : vec6) -> i32 {\n let shapeStrides: vec6 = vec6(shape.y * shape.z * shape.w * shape.u * shape.v, shape.z * shape.w * shape.u * shape.v, shape.w * shape.u * shape.v, shape.u * shape.v, shape.v, 1);\n return coords.x*shapeStrides.x + coords.y*shapeStrides.y + coords.z*shapeStrides.z + coords.w*shapeStrides.w + coords.u*shapeStrides.u + coords.v*shapeStrides.v;\n }\n\n // NaN defination in IEEE 754-1985 is :\n // - sign = either 0 or 1.\n // - biased exponent = all 1 bits.\n // - fraction = anything except all 0 bits (since all 0 bits represents infinity).\n // https://en.wikipedia.org/wiki/IEEE_754-1985#Representation_of_non-numbers\n fn isnan(val: f32) -> bool {\n let floatToUint: u32 = bitcast(val);\n return (floatToUint & 0x7fffffffu) > 0x7f800000u;\n }\n fn isnanVec4(val : vec4) -> vec4 {\n let floatToUint: vec4 = bitcast>(val);\n return (floatToUint & vec4(0x7fffffffu)) > vec4(0x7f800000u);\n }\n`,oae=`\n fn isinf(val: f32) -> bool {\n return abs(val) == uniforms.INFINITY;\n }\n`;function cm(r,t=\"\"){let e=r.length,o=t!==\"\"?`get${t.charAt(0).toUpperCase()+t.slice(1)}CoordsFromIndex`:\"getCoordsFromIndex\",n=t!==\"\"?`${t.charAt(0).toLowerCase()+t.slice(1)}ShapeStrides`:\"outShapeStrides\";if(e<=1)return`fn ${o}(index : i32) -> i32 { return index; }`;let s=y.computeStrides(r),a=ht(e),i=[];for(let u=0;u vec2 {\n let d0 = index / uniforms.${n}; let d1 = index - d0 * uniforms.${n};\n return vec2(d0, d1);\n }`;let p;return p=\"var index2 = index;\"+s.map((u,c)=>{let l=`let ${i[c]} = index2 / uniforms.${n}.${Mo(c)}`,m=c===s.length-1?`let ${i[c+1]} = index2 - ${i[c]} * uniforms.${n}.${Mo(c)}`:`index2 = index2 - ${i[c]} * uniforms.${n}.${Mo(c)}`;return`${l}; ${m};`}).join(\"\"),`\n fn ${o}(index : i32) -> ${a} {\n ${p}\n return ${a}(${i.join(\",\")});\n }\n `}function nae(r,t){let e=r.name,o=r.shape.length,n=ht(o),s=\"get\"+e.charAt(0).toUpperCase()+e.slice(1),a=[\"d0\",\"d1\",\"d2\",\"d3\",\"d4\",\"d5\"].slice(0,o),i=a.map(c=>`${c} : i32`).join(\", \");if(o<1)return`\n fn ${s}() -> ${Ae(t)} {\n return ${Ae(t)}(${e}[0]);\n }\n `;let p=`uniforms.${e.charAt(0).toLowerCase()+e.slice(1)}Shape`,u=`${o}D`;return o===0&&(u=\"1D\"),`\n fn ${s}(${i}) -> ${Ae(t)} {\n return ${Ae(t)}(${e}[getIndexFromCoords${u}(${n}(${a.join(\",\")}),\n ${p})${t===1?\"\":` / ${t}`}]);\n }\n `}function sae(r,t,e,o){let n=r.name,s=n.charAt(0).toUpperCase()+n.slice(1),a=\"get\"+s+\"ByOutput\",i=r.shape.length,p=t.length,u=ht(p);if(y.arraysEqual(r.shape,t)&&o)return`\n fn ${a}Index(globalIndex : i32) -> ${Ae(e)} {\n return ${Ae(e)}(${n}[globalIndex]);\n }\n\n fn ${a}Coords(coords : ${u}) -> ${Ae(e)} {\n return ${Ae(e)}(${n}[${p>1?\"getOutputIndexFromCoords(coords)\":\"coords\"}${e===1?\"\":` / ${e}`}]);\n }\n `;let c=w.getBroadcastDims(r.shape,t),l=p-i,m=\"\";if(i===0)return`\n fn ${a}Index(globalIndex : i32) -> ${Ae(e)}{\n return get${s}();\n }\n\n fn ${a}Coords(coords : ${u}) -> ${Ae(e)}{\n return get${s}();\n }\n `;p<2&&c.length>=1?m=\"coords = 0;\":m=c.map(g=>`coords.${Mo(g+l)} = 0;`).join(`\n`);let d=\"\";if(p<2&&i>0)d=\"coords\";else if(p>1){let g=ht(i),x=r.shape.map((b,C)=>`coords.${Mo(C+l)}`).join(\", \");d=`${g}(${x})`}else d=\"coords\";let f=`uniforms.${n.charAt(0).toLowerCase()+n.slice(1)}Shape`,h=`${i}D`;return`\n fn ${a}Index(globalIndex : i32) -> ${Ae(e)} {\n var coords = getCoordsFromIndex(globalIndex);\n ${m}\n return ${Ae(e)}(${n}[getIndexFromCoords${h}(${d}, ${f})${e===1?\"\":` / ${e}`}]);\n }\n\n fn ${a}Coords(coordsIn : ${u}) -> ${Ae(e)} {\n var coords = coordsIn;\n ${m}\n return ${Ae(e)}(${n}[getIndexFromCoords${h}(${d}, ${f})${e===1?\"\":` / ${e}`}]);\n }\n`}function aae(r,t,e,o){let n=nae(r,e);return r.shape.length<=t.length&&(n+=sae(r,t,e,o)),n}function iae(r,t){let{x:e,y:o=[],z:n=[]}=t,s=r.length,a=e.length+o.length+n.length;if(a!==s)return\"\";if(e.length===s)return`fn getOutputCoords() -> ${ht(s)}{\n let globalIndex = getGlobalIndex();\n return getCoordsFromIndex(globalIndex);\n }\n `;let i=\"\",p=[e,o,n];for(let m=0;m ${c} {\n ${i}\n`;return u.length===0?l+=`return ${c}(0); }`:l+=`return ${c}(${u.join(\",\")}); }`,l}function uae(r){let t=\"\";switch(r){case 0:case 1:t+=`\n fn getOutputIndexFromCoords(coords : i32) -> i32 {\n return coords;\n }\n `;break;case 2:t+=`\n fn getOutputIndexFromCoords(coords : vec2) -> i32 {\n return dot(coords, vec2(uniforms.outShapeStrides, 1));\n }\n `;break;case 3:t+=`\n fn getOutputIndexFromCoords(coords : vec3) -> i32 {\n return dot(coords, vec3(uniforms.outShapeStrides.x, uniforms.outShapeStrides.y, 1));\n }\n `;break;case 4:t+=`\n fn getOutputIndexFromCoords(coords : vec4) -> i32 {\n return dot(coords, vec4(\n uniforms.outShapeStrides.x, uniforms.outShapeStrides.y, uniforms.outShapeStrides.z, 1));\n }\n `;break;case 5:t+=`\n fn getOutputIndexFromCoords(coords : vec5) -> i32 {\n return coords.x * uniforms.outShapeStrides.x +\n coords.y * uniforms.outShapeStrides.y +\n coords.z * uniforms.outShapeStrides.z +\n coords.w * uniforms.outShapeStrides.w +\n coords.u;\n }\n `;break;case 6:t+=`\n fn getOutputIndexFromCoords(coords : vec6) -> i32 {\n return coords.x * uniforms.outShapeStrides.x +\n coords.y * uniforms.outShapeStrides.y +\n coords.z * uniforms.outShapeStrides.z +\n coords.w * uniforms.outShapeStrides.w +\n coords.u * uniforms.outShapeStrides.u +\n coords.v;\n }\n `;break;default:y.assert(!1,()=>`Unsupported ${r}D shape`);break}return t}function ZB(r){return r.dispatch[1]===1&&r.dispatch[2]===1}function Nu(r,t=1){if(r===\"float32\")return Ae(t,\"f32\");if(r===\"int32\"||r===\"bool\")return Ae(t,\"i32\");throw new Error(`type ${r} is not supported.`)}function pae(r,t,e){let o=r.length,n=Nu(t,e),s=`fn setOutputAtIndex(flatIndex : i32, value : ${Ae(e)}) {\n result[flatIndex] = ${n}(value);\n }\n\n fn setOutputAtIndexI32(flatIndex : i32, value : ${Ae(e,\"i32\")}) {\n result[flatIndex] = ${n}(value);\n }\n `;if(o>=2){let a=[\"d0\",\"d1\",\"d2\",\"d3\",\"d4\",\"d5\"].slice(0,o),i=ht(o);s+=`\n fn setOutputAtCoords(${a.map(p=>`${p} : i32`).join(\", \")}, value : ${Ae(e)}) {\n let flatIndex = getOutputIndexFromCoords(${i}(${a.join(\", \")}));\n setOutputAtIndex(flatIndex${e===1?\"\":` / ${e}`}, value);\n }\n fn setOutputAtCoordsI32(${a.map(p=>`${p} : i32`).join(\", \")}, value : ${Ae(e,\"i32\")}) {\n let flatIndex = getOutputIndexFromCoords(${i}(${a.join(\", \")}));\n setOutputAtIndexI32(flatIndex${e===1?\"\":` / ${e}`}, value);\n }\n `}return s}function cae(r){let t=/(\\w+)\\s*:\\s*vec(5|6)/g;r=r.replace(t,o=>\"@align(16) \"+o);let e=/vec(5|6)\\s*,\\s*(\\w+)/g;return r=r.replace(e,(o,n,s)=>`vec${n}, @align(16) ${s}`),r}function XB(r){return!(r.dispatchLayout.hasOwnProperty(\"y\")&&r.dispatchLayout.y.length!==0||r.dispatchLayout.hasOwnProperty(\"z\")&&r.dispatchLayout.z.length!==0)}var Yv={};qe(Yv,{GPUBytesPerElement:()=>jg,MatMulProgramType:()=>Lo,assertNotComplex:()=>fm,computeDispatch:()=>H,computeWorkPerThreadForConv2d:()=>mm,computeWorkgroupInfoForMatMul:()=>Xv,computeWorkgroupSizeForConv2d:()=>lm,flatDispatchLayout:()=>X,isWebGPUSupported:()=>dm,tilesFitEvenlyIntoShape:()=>mae});var Ap=r=>{let t=1;for(let e=0;ee%r[o]===0)}function H(r,t,e=[1,1,1],o=[1,1,1]){let[n,s,a]=[Math.ceil(Ap(r.x.map(i=>t[i]))/(e[0]*o[0])),r.y?Math.ceil(Ap(r.y.map(i=>t[i]))/(e[1]*o[1])):1,r.z?Math.ceil(Ap(r.z.map(i=>t[i]))/(e[2]*o[2])):1];return[n,s,a]}function Xv(r,t,e,o=!1){let n=[8,8,1],s=[4,4,1];return o||(r<=8&&(s[1]=1),t<=16&&e<=16&&(n[0]=4)),{workgroupSize:n,elementsPerThread:s}}function lm(r,t,e=!1){if(e)return[8,8,1];let o=Ap(r.x.map(s=>t[s])),n=Ap(r.y.map(s=>t[s]));return o<=4?[4,16,1]:n<=4?[16,4,1]:[16,16,1]}function mm(r,t,e=!1){if(e)return[4,4,1];let o=Ap(r.x.map(s=>t[s])),n=Ap(r.y.map(s=>t[s]));return o<=4?[1,2,1]:n<=4?[2,1,1]:[2,2,1]}function X(r){return{x:r.map((t,e)=>e)}}function jg(r){if(r===\"float32\"||r===\"int32\"||r===\"bool\"||r===\"string\")return 4;if(r===\"complex64\")return 8;throw new Error(`Unknown dtype ${r}`)}function dm(){return(typeof window!=\"undefined\"||typeof WorkerGlobalScope!=\"undefined\")&&!!navigator.gpu}function fm(r,t){Array.isArray(r)||(r=[r]),r.forEach(e=>{e!=null&&y.assert(e.dtype!==\"complex64\",()=>`${t} does not support complex64 tensors in the WebGPU backend.`)})}var Lo;(function(r){r[r.MatMulReduceProgram=0]=\"MatMulReduceProgram\",r[r.MatMulSplitKProgram=1]=\"MatMulSplitKProgram\",r[r.MatMulSmallOutputSizeProgram=2]=\"MatMulSmallOutputSizeProgram\",r[r.MatMulPackedProgram=3]=\"MatMulPackedProgram\",r[r.MatMulMax=4]=\"MatMulMax\"})(Lo||(Lo={}));var dae=A().getNumber(\"WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD\"),fae=(r,t)=>{let e=r.limits.maxComputeWorkgroupsPerDimension,o=t.dispatchLayout,n=t.dispatch;if(n.every(a=>a<=e))return n;y.assert(n[0]>e&&o.y===void 0&&o.z===void 0,()=>\"Dispatch size exceeds WebGPU limits in Y or Z dimension.\");let s=Math.ceil(Math.sqrt(n[0]));return s>e?(s=Math.ceil(Math.cbrt(n[0])),y.assert(s<=e,()=>\"Total dispatch size exceeds WebGPU maximum.\"),[s,s,s]):[s,s,1]},Tu=class extends ao{nextDataId(){return Tu.nextDataId++}constructor(t,e){if(super(),this.commandQueueOwnedIds=new WeakSet,this.dispatchCountInPass=0,this.disposed=!1,this.downloadWaitMs=0,this.tensorDataPendingDisposal=[],this.queryResolveBuffer=null,this.querySet=null,this.querySetCount=2,this.stagingPendingDisposal=[],this.uniformPendingDisposal=[],this.uploadWaitMs=0,this.hasReadSyncWarned=!1,this.hasTimestampQueryWarned=!1,!dm())throw new Error(\"WebGPU is not supported on this device\");this.pipelineCache={},this.device=t,this.queue=t.queue,this.commandEncoder=null,this.computePassEncoder=null,this.adapterInfo=new Hg(e),this.supportTimestampQuery=this.device.features.has(\"timestamp-query\"),this.thresholdToIncreaseWorkgroups=this.adapterInfo.intelGPUGeneration>=12?16:8,this.bufferManager=new Kg(this.device),this.textureManager=new qg(this.device),this.tensorMap=new zo(this,pr()),A().getBool(\"WEBGPU_USE_PROFILE_TOOL\")&&(this.dummyCanvas=document.createElement(\"canvas\"),this.dummyCanvas.width=1,this.dummyCanvas.height=1,this.dummyContext=this.dummyCanvas.getContext(\"webgpu\"),this.dummyContext.configure({device:t,format:\"bgra8unorm\"}),document.body.appendChild(this.dummyCanvas))}floatPrecision(){return 32}disposeData(t,e=!1){if(!this.tensorMap.has(t))return!0;let o=this.tensorMap.get(t);return e?o.refCount=0:o.refCount--,o.refCount>0?!1:(o.complexTensorInfos!=null&&(this.disposeData(o.complexTensorInfos.real.dataId),this.disposeData(o.complexTensorInfos.imag.dataId)),this.commandQueueOwnedIds.has(t)?(this.tensorDataPendingDisposal.push(t),!0):(this.releaseResource(t),this.tensorMap.delete(t),!0))}memory(){return{numBytesInGPU:this.bufferManager.numBytesUsed,numBytesAllocatedInGPU:this.bufferManager.numBytesAllocated,unreliable:!1}}releaseResource(t){let e=this.tensorMap.get(t);if(!(!e||!e.resource)){if(e.external){e.resource=null;return}e.resource instanceof GPUBuffer?this.bufferManager.releaseBuffer(e.resource):e.resource instanceof GPUTexture&&this.textureManager.releaseTexture(e.resource),e.resource=null}}refCount(t){return this.tensorMap.has(t)?this.tensorMap.get(t).refCount:0}incRef(t){let e=this.tensorMap.get(t);e.refCount++}decRef(t){if(this.tensorMap.has(t)){let e=this.tensorMap.get(t);e.refCount--}}write(t,e,o){if(o===\"complex64\"&&t!=null)throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");let n={id:this.nextDataId()};return this.tensorMap.set(n,{dtype:o,shape:e,values:t,refCount:1}),n}move(t,e,o,n,s){if(n===\"complex64\")throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");this.tensorMap.set(t,{dtype:n,shape:o,values:e,refCount:s})}submitQueue(){this.queue.submit([this.commandEncoder.finish()]),this.commandEncoder=null,this.dispatchCountInPass=0,this.commandQueueOwnedIds=new WeakSet,this.tensorDataPendingDisposal.forEach(t=>{this.releaseResource(t),this.tensorMap.delete(t)}),this.uniformPendingDisposal.forEach(t=>this.bufferManager.releaseBuffer(t)),this.stagingPendingDisposal.forEach(t=>this.bufferManager.releaseBuffer(t,!1)),this.tensorDataPendingDisposal=[],this.uniformPendingDisposal=[],this.stagingPendingDisposal=[]}ensureCommandEncoderReady(){this.commandEncoder||(this.commandEncoder=this.device.createCommandEncoder())}endComputePassEncoder(){this.computePassEncoder&&(this.computePassEncoder.end(),this.computePassEncoder=null)}async checkCompileCompletionAsync(){let t;try{t=await Promise.all(Object.values(this.pipelineCache))}catch(e){throw new Error(e.message)}Object.keys(this.pipelineCache).map((e,o)=>{this.pipelineCache[e]=t[o]})}async getBufferData(t){if(A().getBool(\"WEBGPU_ENGINE_COMPILE_ONLY\"))return console.warn(\"The data may be invalid since WEBGPU_ENGINE_COMPILE_ONLY is true, this can only be called when WEBGPU_ENGINE_COMPILE_ONLY is false\"),null;let e=t.size,o=this.bufferManager.acquireBuffer(e,GPUBufferUsage.COPY_DST|GPUBufferUsage.MAP_READ);this.ensureCommandEncoderReady(),this.endComputePassEncoder(),this.commandEncoder.copyBufferToBuffer(t,0,o,0,e),this.submitQueue(),await o.mapAsync(GPUMapMode.READ);let n=o.getMappedRange().slice(0);return o.unmap(),o!=null&&this.bufferManager.releaseBuffer(o),A().getBool(\"WEBGPU_USE_PROFILE_TOOL\")&&(y.assert(this.dummyContext!==void 0,()=>\"Fail to get context for profiling tool\"),this.dummyContext.getCurrentTexture()),n}convertAndCacheOnCPU(t,e){let o=this.tensorMap.get(t);return o.values=e,o.values}readSync(t){let e=this.tensorMap.get(t),{values:o,complexTensorInfos:n}=e;if(o!=null||e.dtype===\"string\")return o;if(e.dtype===\"complex64\"){let h=this.readSync(n.real.dataId),g=this.readSync(n.imag.dataId),x=y.convertBackendValuesAndArrayBuffer(w.mergeRealAndImagArrays(h,g).buffer,\"float32\");return this.convertAndCacheOnCPU(t,x),x}this.hasReadSyncWarned||(this.hasReadSyncWarned=!0,console.warn(\"The performance of synchronously reading data from GPU to CPU is poor on the webgpu backend, please use asynchronous APIs instead.\"));let s=[\"opaque\",\"premultiplied\"],a=e.resource,i=a.size;y.assert(i%4===0,()=>\"Because there is 4 bytes for one pixel, buffer size must be multiple of 4.\");let p=i/4,u=new ArrayBuffer(i),c=256,l=256,m=s.map(h=>new OffscreenCanvas(c,l)),d=new OffscreenCanvas(c,l);this.endComputePassEncoder(),m.map((h,g)=>{let x=h.getContext(\"webgpu\");return x.configure({device:this.device,format:\"bgra8unorm\",usage:GPUTextureUsage.COPY_DST,alphaMode:s[g]}),x.getCurrentTexture()}).map((h,g)=>{let x=c*4,b=(R,D,P)=>{this.ensureCommandEncoderReady(),this.commandEncoder.copyBufferToTexture({buffer:a,bytesPerRow:x,offset:P},{texture:h},{width:R,height:D}),this.submitQueue();let O=d.getContext(\"2d\",{willReadFrequently:!0});O.clearRect(0,0,R,D),O.drawImage(m[g],0,0);let M=O.getImageData(0,0,R,D).data,L=s[g],B=new Uint8ClampedArray(u,P,R*D*4);for(let z=0;z0&&(b(S,k,_),_+=k*(c*4)),S=E%c,S>0&&b(S,1,_)});let f=y.convertBackendValuesAndArrayBuffer(u,e.dtype);return this.convertAndCacheOnCPU(t,f),f}async read(t){if(!this.tensorMap.has(t))throw new Error(`Tensor ${t} was not registered!`);let e=this.tensorMap.get(t),{values:o}=e;if(o!=null)return o;let n;if(e.dtype===\"complex64\"){let s=await Promise.all([this.read(e.complexTensorInfos.real.dataId),this.read(e.complexTensorInfos.imag.dataId)]),a=s[0],i=s[1];n=w.mergeRealAndImagArrays(a,i)}else{let s=await this.getBufferData(e.resource);n=y.convertBackendValuesAndArrayBuffer(s,e.dtype)}return this.convertAndCacheOnCPU(t,n),n}copyBuffer(t){let e=t.size,o=t.usage,n=this.bufferManager.acquireBuffer(e,o);return this.ensureCommandEncoderReady(),this.endComputePassEncoder(),this.commandEncoder.copyBufferToBuffer(t,0,n,0,e),this.submitQueue(),n}createTensorFromGPUData(t,e,o){let n=t.buffer;if(o===\"complex64\")throw new Error(\"Cannot write to a complex64 dtype. \");let s={id:this.nextDataId()};this.tensorMap.set(s,{dtype:o,shape:e,values:null,refCount:1,external:t.zeroCopy});let a=this.tensorMap.get(s),i=jg(a.dtype)*y.sizeFromShape(a.shape);if(t.buffer.sizey.decodeString(n));return me(t.shape,t.dtype,o)}catch(o){throw new Error(\"Failed to decode encoded string bytes into utf-8\")}return me(t.shape,t.dtype,e)}async time(t){!this.supportTimestampQuery&&!this.hasTimestampQueryWarned&&(console.warn(\"This device doesn't support timestamp-query extension. Start Chrome browser with flag --disable-dawn-features=disallow_unsafe_apis to try it again. Otherwise, zero will be shown for the kernel time when profiling mode is enabled.\"),this.hasTimestampQueryWarned=!0);let e=this.activeTimers,o=[],n=!1;this.programTimersStack==null?(this.programTimersStack=o,n=!0):this.activeTimers.push(o),this.activeTimers=o,t();let s=y.flatten(this.activeTimers.map(u=>u.query)).filter(u=>u!=null),a=y.flatten(this.activeTimers.map(u=>u.name)).filter(u=>u!=null);this.activeTimers=e,n&&(this.programTimersStack=null);let i={uploadWaitMs:this.uploadWaitMs,downloadWaitMs:this.downloadWaitMs,kernelMs:null,wallMs:null},p=await Promise.all(s);return i.kernelMs=y.sum(p),i.getExtraProfileInfo=()=>p.map((u,c)=>({name:a[c],ms:u})).map(u=>`${u.name}: ${u.ms}`).join(\", \"),this.uploadWaitMs=0,this.downloadWaitMs=0,i}makeTensorInfo(t,e,o){return e===\"string\"&&o!=null&&o.length>0&&y.isString(o[0])&&(o=o.map(s=>y.encodeString(s))),{dataId:this.write(o,t,e),shape:t,dtype:e}}tensorToBinding(t){if(!t)return null;let o=this.tensorMap.get(t.dataId).resource;return o instanceof GPUBuffer?{buffer:o}:o instanceof GPUTexture?o.createView():o}uploadToGPU(t){let e=this.tensorMap.get(t);if(e.resource!=null)return;let o=jg(e.dtype)*y.sizeFromShape(e.shape),n,s=GPUBufferUsage.STORAGE|GPUBufferUsage.COPY_SRC|GPUBufferUsage.COPY_DST;if(e.values){if(n=this.bufferManager.acquireBuffer(o,s,!0),n.mapState===\"unmapped\"){let a=this.bufferManager.acquireBuffer(o,GPUBufferUsage.MAP_WRITE|GPUBufferUsage.COPY_SRC,!0,!1),i=a.getMappedRange();e.dtype===\"int32\"||e.dtype===\"bool\"?new Int32Array(i).set(e.values):new Float32Array(i).set(e.values),a.unmap(),this.ensureCommandEncoderReady(),this.endComputePassEncoder(),this.commandEncoder.copyBufferToBuffer(a,0,n,0,o),this.stagingPendingDisposal.push(a)}else{let a=n.getMappedRange();e.dtype===\"int32\"||e.dtype===\"bool\"?new Int32Array(a).set(e.values):new Float32Array(a).set(e.values),n.unmap()}e.values=null}else n=this.bufferManager.acquireBuffer(o,s);e.resource=n}makeUniforms(t){let e=0,o=0,n=[],s=1;t.forEach(p=>{p.data.length===0&&(p.data=[1]);let u;switch(p.data.length){case 1:u=4;break;case 2:u=8;break;case 3:u=16;break;case 4:u=16;break;case 5:u=16;break;case 6:u=16;break;default:y.assert(!1,()=>`Unsupported ${p.data.length}D shape`)}(o===5||o===6)&&(u=16),u>s&&(s=u),e=Math.ceil(e/u)*u,o=p.data.length,n.push(e),e+=p.data.length*4}),e=Math.ceil(e/s)*s;let a=new ArrayBuffer(e);t.forEach((p,u)=>{let c=n[u];p.type===\"int32\"?new Int32Array(a,c,p.data.length).set(p.data):p.type===\"uint32\"?new Uint32Array(a,c,p.data.length).set(p.data):new Float32Array(a,c,p.data.length).set(p.data)});let i=this.bufferManager.acquireBuffer(e,GPUBufferUsage.COPY_DST|GPUBufferUsage.UNIFORM);return this.queue.writeBuffer(i,0,a,0,e),this.uniformPendingDisposal.push(i),{offset:0,size:e,buffer:i}}runWebGPUProgram(t,e,o,n,s){if(s||(s=this.makeTensorInfo(t.outputShape,o)),y.sizeFromShape(s.shape)===0)return this.tensorMap.get(s.dataId).values=y.getTypedArrayFromDType(s.dtype,0),s;this.uploadToGPU(s.dataId),t.dispatch=fae(this.device,t);let a=e.map((p,u)=>{if(p.dtype===\"complex64\")throw new Error(\"GPGPUProgram does not support complex64 input. For complex64 dtypes, please separate the program into real and imaginary parts.\");return this.uploadToGPU(p.dataId),{dtype:this.tensorMap.get(p.dataId).dtype,shape:p.shape,name:t.variableNames[u]}});t.shaderKey=QB(t,a,s);let i=A().getBool(\"WEBGPU_ENGINE_COMPILE_ONLY\");return t.shaderKey in this.pipelineCache||(this.pipelineCache[t.shaderKey]=YB(this.device,t,a,s,i)),t.pipeline=this.pipelineCache[t.shaderKey],i||this.recordAndSubmit(t,s,e,n),s}recordAndSubmit(t,e,o,n){if(t.pipeline instanceof Promise)throw new Error(\"Please call checkCompileCompletionAsync to ensure parallel compilation is done!\");let s=[],a=[],i=\"int32\";if(t.pixelsOpType==null){s.push({type:\"float32\",data:[NaN]},{type:\"float32\",data:[1/0]}),a=o.concat(e).map(d=>d.shape);let m=\"int32\";a.map(d=>{s.push({type:m,data:d});let f=y.computeStrides(d);s.push({type:m,data:f})})}else{let m=y.computeStrides(e.shape);s.push({type:i,data:m})}if(t.size){let m=y.sizeFromShape(t.outputShape);s.push({type:i,data:[t.outputComponent?m/t.outputComponent:m]})}n&&(s=[...s,...n]);let p=[this.tensorToBinding(e),...o.map(m=>this.tensorToBinding(m)),this.makeUniforms(s)];o.forEach(m=>{this.commandQueueOwnedIds.add(m.dataId)}),this.commandQueueOwnedIds.add(e.dataId);let u=this.device.createBindGroup({layout:t.pipeline.getBindGroupLayout(0),entries:p.map((m,d)=>({binding:d,resource:m}))}),c=this.activeTimers!=null;this.ensureCommandEncoderReady();let l={};c&&this.supportTimestampQuery?(this.endComputePassEncoder(),this.querySet==null&&(this.querySet=this.device.createQuerySet({type:\"timestamp\",count:this.querySetCount})),l.timestampWrites=[{querySet:this.querySet,queryIndex:0,location:\"beginning\"},{querySet:this.querySet,queryIndex:1,location:\"end\"}],this.computePassEncoder=this.commandEncoder.beginComputePass(l)):this.computePassEncoder||(this.computePassEncoder=this.commandEncoder.beginComputePass(l)),this.computePassEncoder.setPipeline(t.pipeline),this.computePassEncoder.setBindGroup(0,u),this.computePassEncoder.dispatchWorkgroups(t.dispatch[0],t.dispatch[1],t.dispatch[2]),this.dispatchCountInPass++,(c||A().get(\"WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE\")<=this.dispatchCountInPass||t.pixelsOpType===Ii.DRAW)&&(this.endComputePassEncoder(),c?this.activeTimers.push({name:t.constructor.name,query:this.getQueryTime()}):this.submitQueue())}async getQueryTime(){if(!this.supportTimestampQuery)return 0;this.queryResolveBuffer==null&&(this.queryResolveBuffer=this.bufferManager.acquireBuffer(this.querySetCount*8,GPUBufferUsage.COPY_SRC|GPUBufferUsage.COPY_DST|GPUBufferUsage.QUERY_RESOLVE)),this.commandEncoder.resolveQuerySet(this.querySet,0,this.querySetCount,this.queryResolveBuffer,0);let t=this.bufferManager.acquireBuffer(this.querySetCount*8,GPUBufferUsage.MAP_READ|GPUBufferUsage.COPY_DST);this.commandEncoder.copyBufferToBuffer(this.queryResolveBuffer,0,t,0,this.querySetCount*8),this.submitQueue(),await t.mapAsync(GPUMapMode.READ);let e=new BigUint64Array(t.getMappedRange()),o=Number(e[1]-e[0])/1e6;return t.unmap(),this.bufferManager.releaseBuffer(t),o}shouldExecuteOnCPU(t,e=dae){return A().getBool(\"WEBGPU_CPU_FORWARD\")&&t.every(o=>this.tensorMap.get(o.dataId).resource==null&&y.sizeFromShape(o.shape){let r={powerPreference:A().get(\"WEBGPU_USE_LOW_POWER_GPU\")?\"low-power\":\"high-performance\"},t=await navigator.gpu.requestAdapter(r),e={},o=[];t.features.has(\"timestamp-query\")&&o.push(\"timestamp-query\"),t.features.has(\"bgra8unorm-storage\")&&o.push([\"bgra8unorm-storage\"]),e.requiredFeatures=o;let n=t.limits;e.requiredLimits={maxComputeWorkgroupStorageSize:n.maxComputeWorkgroupStorageSize,maxComputeWorkgroupsPerDimension:n.maxComputeWorkgroupsPerDimension,maxStorageBufferBindingSize:n.maxStorageBufferBindingSize,maxBufferSize:n.maxBufferSize,maxComputeWorkgroupSizeX:n.maxComputeWorkgroupSizeX,maxComputeInvocationsPerWorkgroup:n.maxComputeInvocationsPerWorkgroup};let s=await t.requestDevice(e),a=await t.requestAdapterInfo();return new Tu(s,a)},3);var fe;(function(r){r[r.ADD=0]=\"ADD\",r[r.ATAN2=1]=\"ATAN2\",r[r.COMPLEX_MULTIPLY_IMAG=2]=\"COMPLEX_MULTIPLY_IMAG\",r[r.COMPLEX_MULTIPLY_REAL=3]=\"COMPLEX_MULTIPLY_REAL\",r[r.DIV=4]=\"DIV\",r[r.ELU_DER=5]=\"ELU_DER\",r[r.EQUAL=6]=\"EQUAL\",r[r.FLOOR_DIV=7]=\"FLOOR_DIV\",r[r.GREATER=8]=\"GREATER\",r[r.GREATER_EQUAL=9]=\"GREATER_EQUAL\",r[r.LESS=10]=\"LESS\",r[r.LESS_EQUAL=11]=\"LESS_EQUAL\",r[r.LOGICAL_AND=12]=\"LOGICAL_AND\",r[r.LOGICAL_OR=13]=\"LOGICAL_OR\",r[r.MAX=14]=\"MAX\",r[r.MIN=15]=\"MIN\",r[r.MOD=16]=\"MOD\",r[r.MUL=17]=\"MUL\",r[r.NOT_EQUAL=18]=\"NOT_EQUAL\",r[r.POW=19]=\"POW\",r[r.PRELU=20]=\"PRELU\",r[r.SQUARED_DIFFERENCE=21]=\"SQUARED_DIFFERENCE\",r[r.SUB=22]=\"SUB\"})(fe||(fe={}));var hae=\"let resultTemp = a + b;\",gae=\"let resultTemp = atan2(a, b);\",xae=\"let resultTemp = areal * breal - aimag * bimag;\",yae=\"let resultTemp = areal * bimag + aimag * breal;\",bae=\"let resultTemp = a / b;\",Cae=\"let resultTemp = select(a * (b + 1.0), a, b >= b - b);\",wae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a == b);\n`,Sae=`\n let remainder =\n select(a % b, round(a % b), (round(a) == a) & (round(b) == b));\n let quotient = (a - remainder) / b;\n let resultTemp =\n round(select(quotient, quotient - 1, sign(remainder) == -sign(b)));\n`,Iae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a > b);\n`,vae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a >= b);\n`,kae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a < b);\n`,Nae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a <= b);\n`,Tae=\"return f32(a >= 1.0 && b >= 1.0);\",_ae=`return (vec4(a >= vec4(1.0)) *\n vec4(b >= vec4(1.0)));`,$ae=\"return f32(a >= 1.0 || b >= 1.0);\",Eae=`return min(vec4(a >= vec4(1.0)) +\n vec4(b >= vec4(1.0)), vec4(1.0));`,Rae=\"let resultTemp = max(a, b);\",Dae=\"let resultTemp = min(a, b);\",Aae=`\n let isNaN = b == 0.;\n var resultTemp = a % b;\n resultTemp = select((resultTemp + b) % b, resultTemp,\n (a < 0. && b < 0.) || (a >= 0. && b > 0.));\n`,Fae=`\n let isNaN = !vec4(b);\n var resultTemp = vec4(a % b);\n if (!((a[0] < 0. && b[0] < 0.) || (a[0] >= 0. && b[0] > 0.))) {\n resultTemp[0] = (resultTemp[0] + b[0]) % b[0];\n }\n if (!((a[1] < 0. && b[1] < 0.) || (a[1] >= 0. && b[1] > 0.))) {\n resultTemp[1] = (resultTemp[1] + b[1]) % b[1];\n }\n if (!((a[2] < 0. && b[2] < 0.) || (a[2] >= 0. && b[2] > 0.))) {\n resultTemp[2] = (resultTemp[2] + b[2]) % b[2];\n }\n if (!((a[3] < 0. && b[3] < 0.) || (a[3] >= 0. && b[3] > 0.))) {\n resultTemp[3] = (resultTemp[3] + b[3]) % b[3];\n }\n`,Pae=\"let resultTemp = a * b;\",Oae=`\n var resultTemp = f32(a != b);\n let valueForNaN = 1.0;\n`,Mae=`\n var resultTemp = vec4(a != b);\n let valueForNaN = 1.0;\n`,Lae=`\n let isNaN = a < 0.0 && floor(b) < b;\n if (b == 0.0) {\n return 1.0;\n }\n var resultTemp = select(sign(a) * pow(abs(a), b), pow(abs(a), b),\n round(abs(b) % 2.0) != 1.0);\n`,Bae=`\n let isModRound1Bool = vec4(round(abs(b) % vec4(2.0))) == vec4(1);\n let isModRound1 = vec4(isModRound1Bool);\n let multiplier = sign(a) * isModRound1 + (vec4(1.0) - isModRound1);\n var resultTemp = multiplier * pow(abs(a), b);\n\n // Ensure that a^0 = 1, including 0^0 = 1 as this correspond to TF and JS\n let isExpZero = b == vec4(0.0);\n if (isExpZero.r) {\n resultTemp.r = 1.0;\n }\n if (isExpZero.g) {\n resultTemp.g = 1.0;\n }\n if (isExpZero.b) {\n resultTemp.b = 1.0;\n }\n if (isExpZero.a) {\n resultTemp.a = 1.0;\n }\n let isNaN = (a < vec4(0.0)) & (floor(b) < b);\n`,zae=\"if (a < 0.0) { return b * a; } return a;\",Vae=`\n let aLessThanZero = vec4(a < vec4(0.0));\n return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`,Wae=\"let resultTemp = (a - b) * (a - b);\",Uae=\"let resultTemp = a - b;\";function Qc(r,t){let e;do{switch(r){case fe.ATAN2:e=gae;break;case fe.MAX:e=Rae;break;case fe.MIN:e=Dae;break;case fe.MOD:e=t?Fae:Aae;break;case fe.NOT_EQUAL:e=t?Mae:Oae;break;case fe.POW:e=t?Bae:Lae;break;default:continue}let o,n,s;return t?(o=\"isnanVec4\",n=\"vec4\",s=\"vec4\"):(o=\"isnan\",n=\"f32\",s=\"bool\"),`\n let aIsNaN = ${o}(a);\n let aPostLegalization = select(a, ${n}(42), aIsNaN);\n let bIsNaN = ${o}(b);\n let bPostLegalization = select(b, ${n}(42), bIsNaN);\n let isNaN = false;\n let valueForNaN = uniforms.NAN;\n {\n let a = aPostLegalization;\n let b = bPostLegalization;\n ${e}\n return select(\n resultTemp, ${n}(valueForNaN),\n ${s}(isNaN) | aIsNaN | bIsNaN);\n }\n `}while(!1);switch(r){case fe.ADD:e=hae;break;case fe.COMPLEX_MULTIPLY_IMAG:e=yae;break;case fe.COMPLEX_MULTIPLY_REAL:e=xae;break;case fe.DIV:e=bae;break;case fe.ELU_DER:e=Cae;break;case fe.EQUAL:e=wae;break;case fe.FLOOR_DIV:e=Sae;break;case fe.GREATER:e=Iae;break;case fe.GREATER_EQUAL:e=vae;break;case fe.LESS:e=kae;break;case fe.LESS_EQUAL:e=Nae;break;case fe.LOGICAL_AND:return t?_ae:Tae;case fe.LOGICAL_OR:return t?Eae:$ae;case fe.MUL:e=Pae;break;case fe.PRELU:return t?Vae:zae;case fe.SQUARED_DIFFERENCE:e=Wae;break;case fe.SUB:e=Uae;break;default:}return`\n ${e}\n return resultTemp;\n `}var Z;(function(r){r[r.ABS=0]=\"ABS\",r[r.ACOS=1]=\"ACOS\",r[r.ACOSH=2]=\"ACOSH\",r[r.ASIN=3]=\"ASIN\",r[r.ASINH=4]=\"ASINH\",r[r.ATAN=5]=\"ATAN\",r[r.ATANH=6]=\"ATANH\",r[r.CEIL=7]=\"CEIL\",r[r.COS=8]=\"COS\",r[r.COSH=9]=\"COSH\",r[r.ELU=10]=\"ELU\",r[r.ERF=11]=\"ERF\",r[r.EXP=12]=\"EXP\",r[r.EXPM1=13]=\"EXPM1\",r[r.FLOOR=14]=\"FLOOR\",r[r.IS_FINITE=15]=\"IS_FINITE\",r[r.IS_INF=16]=\"IS_INF\",r[r.IS_NAN=17]=\"IS_NAN\",r[r.LINEAR=18]=\"LINEAR\",r[r.LOG=19]=\"LOG\",r[r.LOG1P=20]=\"LOG1P\",r[r.LOGICAL_NOT=21]=\"LOGICAL_NOT\",r[r.NEG=22]=\"NEG\",r[r.RELU=23]=\"RELU\",r[r.RELU6=24]=\"RELU6\",r[r.LEAKYRELU=25]=\"LEAKYRELU\",r[r.RECIPROCAL=26]=\"RECIPROCAL\",r[r.ROUND=27]=\"ROUND\",r[r.RSQRT=28]=\"RSQRT\",r[r.SELU=29]=\"SELU\",r[r.SIGMOID=30]=\"SIGMOID\",r[r.SIGN=31]=\"SIGN\",r[r.SIN=32]=\"SIN\",r[r.SINH=33]=\"SINH\",r[r.SOFTPLUS=34]=\"SOFTPLUS\",r[r.SQRT=35]=\"SQRT\",r[r.SQUARE=36]=\"SQUARE\",r[r.STEP=37]=\"STEP\",r[r.TAN=38]=\"TAN\",r[r.TANH=39]=\"TANH\",r[r.TO_INT=40]=\"TO_INT\"})(Z||(Z={}));var Gae=\"return abs(a);\",Hae=`\n if (abs(a) > 1.) {\n return uniforms.NAN;\n }\n return acos(a);\n`,Kae=`\n if (a < 1.) {\n return uniforms.NAN;\n }\n return acosh(a);\n`,qae=`\n if (abs(a) > 1.) {\n return uniforms.NAN;\n }\n return asin(a);\n`,jae=\"return asinh(a);\",Xae=`\n if (isnan(a)) {\n return uniforms.NAN;\n }\n return atan(a);\n`,Yae=`\n if (abs(a) > 1.) {\n return uniforms.NAN;\n }\n if (a == 1.) {\n return uniforms.INFINITY;\n }\n if (a == -1.) {\n return -uniforms.INFINITY;\n }\n return atanh(a);\n`,Qae=\"return ceil(a);\",Zae=\"return cos(a);\",Jae=`\n let e2x = exp(-a);\n return (e2x + 1.0 / e2x) / 2.0;\n`,eie=\"return exp(a) - 1.0;\",tie=\"if (a >= 0.0) { return a; } return (exp(a) - 1.0);\",rie=`\n var resFloat = exp(a) - vec4(1.0);\n if (a.r >= 0.0) {\n resFloat.r = a.r;\n }\n if (a.g >= 0.0) {\n resFloat.g = a.g;\n }\n if (a.b >= 0.0) {\n resFloat.b = a.b;\n }\n if (a.a >= 0.0) {\n resFloat.a = a.a;\n }\n return resFloat;\n`,oie=`\n // Error function is calculated approximately with elementary function.\n // See \"Handbook of Mathematical Functions with Formulas,\n // Graphs, and Mathematical Tables\", Abramowitz and Stegun.\n let p = ${w.ERF_P};\n let a1 = ${w.ERF_A1};\n let a2 = ${w.ERF_A2};\n let a3 = ${w.ERF_A3};\n let a4 = ${w.ERF_A4};\n let a5 = ${w.ERF_A5};\n\n let sign = sign(a);\n let absA = abs(a);\n let t = 1.0 / (1.0 + p * absA);\n return sign * (1.0 - (((((a5 * t + a4) * t) + a3) * t + a2) * t + a1) * t * exp(-absA * absA));\n`,nie=\"return exp(a);\",sie=\"return floor(a);\",aie=\"return f32(!isnan(a) && !isinf(a));\",iie=\"return f32(isinf(a));\",uie=\"return f32(isnan(a));\",pie=\"return a;\",cie=`if (a < 0.0) { return uniforms.NAN; }\n return log(a);`,lie=`\n if (isnan(a)) { return a; }\n return log(1.0 + a);\n`,mie=\"return f32(!(a >= 1.0));\",die=\"return -a;\",fie=\"if (a < 0.0) { return uniforms.alpha * a; } return a;\",hie=`\n let aLessThanZero = vec4(a < vec4(0.0));\n return (aLessThanZero * (uniforms.alpha * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`,gie=\"return 1.0 / a;\",xie=\"return select(a, 0.0, a < 0.0);\",yie=\"return clamp(a, 0.0, 6.0);\",bie=\"return clamp(a, vec4(0.0, 0.0, 0.0, 0.0), vec4(6.0, 6.0, 6.0, 6.0));\",Cie=`\n return select(a, vec4(0.0), a < vec4(0.0));\n`,wie=\"return round(a);\",Sie=\"return inverseSqrt(a);\",Iie=`\n if (a >= 0.0) {\n return ${w.SELU_SCALE} * a;\n } else {\n return ${w.SELU_SCALEALPHA} * (exp(a) - 1.0);\n }\n`,vie=\"return 1.0 / (1.0 + exp(-1.0 * a));\",kie=\"return sign(a);\",Nie=\"return sin(a);\",Tie=`\n let e2x = exp(a);\n return (e2x - 1.0 / e2x) / 2.0;\n`,_ie=`\n let epsilon = 1.1920928955078125e-7;\n let threshold = log(epsilon) + 2.0;\n\n let too_large = a > -threshold;\n let too_small = a < threshold;\n let exp_a = exp(a);\n\n if (too_large) {\n return a;\n } else if (too_small) {\n return exp_a;\n } else {\n return log(exp_a + 1.0);\n }\n`,$ie=\"return sqrt(a);\",Eie=\"return a * a;\",Rie=`\n if (isnan(a)) {\n return a;\n }\n\n return select(uniforms.stepAlpha, 1.0, a > 0.0);\n`,Die=\"return tan(a);\",Aie=`\n let e2x = exp(-2.0 * abs(a));\n return sign(a) * (1.0 - e2x) / (1.0 + e2x);\n`,Fie=\"return f32(i32((a)));\";function vi(r,t){switch(r){case Z.ABS:return Gae;case Z.ACOS:return Hae;case Z.ACOSH:return Kae;case Z.ASIN:return qae;case Z.ASINH:return jae;case Z.ATAN:return Xae;case Z.ATANH:return Yae;case Z.COS:return Zae;case Z.COSH:return Jae;case Z.CEIL:return Qae;case Z.ELU:return t?rie:tie;case Z.ERF:return oie;case Z.EXP:return nie;case Z.EXPM1:return eie;case Z.FLOOR:return sie;case Z.IS_FINITE:return aie;case Z.IS_INF:return iie;case Z.IS_NAN:return uie;case Z.LINEAR:return pie;case Z.LOG:return cie;case Z.LOG1P:return lie;case Z.LOGICAL_NOT:return mie;case Z.NEG:return die;case Z.LEAKYRELU:return t?hie:fie;case Z.RECIPROCAL:return gie;case Z.RELU:return t?Cie:xie;case Z.RELU6:return t?bie:yie;case Z.ROUND:return wie;case Z.RSQRT:return Sie;case Z.SELU:return Iie;case Z.SIGMOID:return vie;case Z.SIGN:return kie;case Z.SIN:return Nie;case Z.SINH:return Tie;case Z.SOFTPLUS:return _ie;case Z.SQRT:return $ie;case Z.SQUARE:return Eie;case Z.STEP:return Rie;case Z.TAN:return Die;case Z.TANH:return Aie;case Z.TO_INT:return Fie;default:throw new Error(`BinaryType ${r} is not implemented!`)}}function fr(r,t=!1,e=!1,o=3){if(r===null)return\"\";let n=\"\";if(r===\"linear\")n=vi(Z.LINEAR);else if(r===\"relu\")n=vi(Z.RELU,e);else if(r===\"elu\")n=vi(Z.ELU,e);else if(r===\"relu6\")n=vi(Z.RELU6,e);else if(r===\"prelu\")n=Qc(fe.PRELU,e);else if(r===\"sigmoid\")n=vi(Z.SIGMOID,e);else if(r===\"leakyrelu\")n=vi(Z.LEAKYRELU,e);else throw new Error(`Activation ${r} has not been implemented for the WebGPU backend.`);let a=Ae(e?4:1),i=\"\";return t?i=`\n fn activation(a : ${a}, coords : vec${o}) -> ${a} {\n let b = getPreluActivationWeightsByOutputCoords(coords);\n ${n}\n }`:i=`\n fn activation(a : ${a}, coords : vec${o}) -> ${a} {\n ${n}\n }`,i}function Zr(r,t){return`\n ${r?\"value = value + getBiasByOutputCoords(coords);\":\"\"}\n ${t?\"value = activation(value, coords);\":\"\"}\n `}function Qv(r,t,e=!1,o=!1,n=!1,s=1){y.assert(r&&s===1||!r,()=>`transposeA ${r} is not compatible with component size ${s}`);let a=`\n ${r?\"value = getA(batch, col, row);\":\"value = getA(batch, row, col);\"}\n\n `,i=t?\"value = getB(batch, col, row);\":\"value = getB(batch, row, col);\";return`\n fn mm_readA(batch: i32, row: i32, col: i32) -> ${Ae(s)} {\n var value = ${Ae(s)}(0.0);\n ${e&&n?a:`\n ${r?\"if(row < uniforms.dimAOuter && col < uniforms.dimInner)\":\"if(row < uniforms.aShape[1] && col < uniforms.aShape[2])\"}\n {\n ${a}\n }\n `}\n return value;\n }\n\n fn mm_readB(batch: i32, row: i32, col: i32) -> ${Ae(s)} {\n var value = ${Ae(s)}(0.0);\n ${i}\n return value;\n }\n `}function hm(r,t,e,o,n=!1,s=!1,a=!1,i=1){return`\n ${Qv(e,o,n,s,a,i)}\n fn mm_write(batch: i32, row: i32, col: i32, valueIn: ${Ae(i)}) {\n ${n&&s?\"\":\"if (row < uniforms.dimAOuter && col < uniforms.dimBOuter)\"}\n {\n var value = valueIn;\n let coords = vec3(batch, row, col);\n ${Zr(r,t)}\n setOutputAtCoords(coords[0], coords[1], coords[2], value);\n }\n }\n `}var Pie=(r,t)=>r?`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n kStart + inputRow,\n globalRowStart + inputCol * ${t});\n `:`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n globalRow + innerRow,\n kStart + inputCol * ${t});\n `,Oie=(r,t,e,o)=>{if(r)return`\n for (var k = 0; k < ${o}; k++) {\n let BCached0 = mm_Bsub[k][tileCol];\n let ACached0 = mm_Asub[k][localRow];\n for (var i = 0; i < ${e}; i++) {\n acc[i] = fma(BCached0, vec4(ACached0[i]), acc[i]);\n }\n }`;{let n=\"\",s=\"\";for(let a=0;a(ACached[${a}]), acc[i]);`;return`\n for (var k = 0; k < ${o/t}; k++) {\n ${n}\n for (var i = 0; i < ${e}; i++) {\n let ACached = mm_Asub[tileRow + i][k];\n ${s}\n }\n }`}};function Fp(r,t,e=!1,o=32,n=!1,s=32,a=!1){let i=t[1]*r[1],p=t[0]*r[0],u=e?i:o,c=e?o:i,l=u/t[0],m=o/t[1],d=r[1],f=r[0];return y.assert((e&&l===4&&r[1]===4||!e&&(l===3||l===4))&&u%t[0]===0&&o%t[1]===0&&r[0]===4,()=>`If transposeA ${e} is true, innerElementSize ${l} and workPerThread[1] ${r[1]} must be 4.\n Otherwise, innerElementSize ${l} must be 3 or 4.\n tileAWidth ${u} must be divisible by workgroupSize[0]${t[0]}. tileInner ${o} must be divisible by workgroupSize[1] ${t[1]}. colPerThread ${r[0]} must be 4.`),`\n var mm_Asub : array, ${u/l}>, ${c}>;\n var mm_Bsub : array, ${p/r[0]}>, ${o}>;\n\n ${G()} {\n let localRow = i32(localId.y);\n let tileRow = localRow * ${d};\n let tileCol = i32(localId.x);\n\n let globalRow = i32(globalId.y) * ${d};\n let globalCol = i32(globalId.x) * ${f};\n let batch = ${n?\"0\":\"i32(globalId.z)\"};\n let batchA = ${n||!a?\"batch\":\"batch % uniforms.aShape[0]\"};\n let batchB = ${n||!a?\"batch\":\"batch % uniforms.bShape[0]\"};\n let globalRowStart = i32(workgroupId.y) * ${i};\n\n let numTiles = ${n?`${Math.ceil(s/o)}`:`(uniforms.dimInner - 1) / ${o} + 1`};\n var kStart = ${n?`i32(globalId.z) * ${s}`:\"0\"};\n\n var acc: array, ${d}>;\n\n // Loop over shared dimension.\n let tileRowB = localRow * ${m};\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n for (var innerRow = 0; innerRow < ${d}; innerRow++) {\n let inputRow = tileRow + innerRow;\n let inputCol = tileCol;\n ${Pie(e,l)}\n }\n\n // Load one tile of B into local memory.\n for (var innerRow = 0; innerRow < ${m}; innerRow++) {\n let inputRow = tileRowB + innerRow;\n let inputCol = tileCol;\n mm_Bsub[inputRow][inputCol] = mm_readB(batchB, kStart + inputRow, globalCol);\n }\n kStart = kStart + ${o};\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n ${Oie(e,l,d,o)}\n workgroupBarrier();\n }\n\n for (var innerRow = 0; innerRow < ${d}; innerRow++) {\n mm_write(batch, globalRow + innerRow, globalCol, acc[innerRow]);\n }\n }`}var JB=r=>r?`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n kStart + inputRow,\n globalRowStart + inputCol);\n `:`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n globalRowStart + inputRow,\n kStart + inputCol);\n `,Mie=r=>r?\"let ACached = mm_Asub[k][tileRow + innerRow];\":\"let ACached = mm_Asub[tileRow + innerRow][k];\";function Pp(r,t,e=!1,o=32,n=!1,s=32,a=!1,i=!1){let p=r[1]*t[1],u=r[0]*t[0],c=e?p:o,l=e?o:p;y.assert(l%t[1]===0&&c%t[0]===0&&o%t[1]===0,()=>`tileAHight ${l} must be divisible by workgroupSize[1]${t[1]}, tileAWidth ${c} must be divisible by workgroupSize[0]${t[0]}, tileInner ${o} must be divisible by workgroupSize[1]${t[1]}`);let m=l/t[1],d=c/t[0],f=o/t[1],h=r[1],g=r[0],x=a?`\n let localRow = i32(localId.y);\n let localCol = i32(localId.x);\n let globalRowStart = i32(workgroupId.y) * ${p};\n let globalColStart = i32(workgroupId.x) * ${u};\n\n // Loop over shared dimension.\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n for (var inputRow = localRow; inputRow < ${l}; inputRow = inputRow + ${t[1]}) {\n for (var inputCol = localCol; inputCol < ${c}; inputCol = inputCol + ${t[0]}) {\n ${JB(e)}\n }\n }\n // Load one tile of B into local memory.\n for (var inputRow = localRow; inputRow < ${o}; inputRow = inputRow + ${t[1]}) {\n for (var inputCol = localCol; inputCol < ${u}; inputCol = inputCol + ${t[0]}) {\n mm_Bsub[inputRow][inputCol] = mm_readB(batchB,\n kStart + inputRow,\n globalColStart + inputCol);\n }\n }\n kStart = kStart + ${o};\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n var BCached : array;\n for (var k = 0; k < ${o}; k++) {\n for (var inner = 0; inner < ${g}; inner++) {\n BCached[inner] = mm_Bsub[k][localCol + inner * ${t[0]}];\n }\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n let ACached = ${e?`mm_Asub[k][localRow + innerRow * ${t[1]}];`:`mm_Asub[localRow + innerRow * ${t[1]}][k];`}\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n acc[innerRow][innerCol] =\n fma(ACached, BCached[innerCol], acc[innerRow][innerCol]);\n }\n }\n }\n workgroupBarrier();\n }\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n let gRow = globalRowStart + localRow + innerRow * ${t[1]};\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n let gCol = globalColStart + localCol + innerCol * ${t[0]};\n mm_write(batch, gRow, gCol, acc[innerRow][innerCol]);\n }\n }\n `:`\n let tileRow = i32(localId.y) * ${h};\n let tileCol = i32(localId.x) * ${g};\n\n let globalRow = i32(globalId.y) * ${h};\n let globalCol = i32(globalId.x) * ${g};\n let globalRowStart = i32(workgroupId.y) * ${p};\n\n let tileRowA = i32(localId.y) * ${m};\n let tileColA = i32(localId.x) * ${d};\n let tileRowB = i32(localId.y) * ${f};\n // Loop over shared dimension.\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n for (var innerRow = 0; innerRow < ${m}; innerRow++) {\n for (var innerCol = 0; innerCol < ${d}; innerCol++) {\n let inputRow = tileRowA + innerRow;\n let inputCol = tileColA + innerCol;\n ${JB(e)}\n }\n }\n\n // Load one tile of B into local memory.\n for (var innerRow = 0; innerRow < ${f}; innerRow++) {\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n let inputRow = tileRowB + innerRow;\n let inputCol = tileCol + innerCol;\n mm_Bsub[inputRow][inputCol] = mm_readB(batchB,\n kStart + inputRow,\n globalCol + innerCol);\n }\n }\n kStart = kStart + ${o};\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n var BCached : array;\n for (var k = 0; k < ${o}; k++) {\n for (var inner = 0; inner < ${g}; inner++) {\n BCached[inner] = mm_Bsub[k][tileCol + inner];\n }\n\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n ${Mie(e)}\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n acc[innerRow][innerCol] =\n fma(ACached, BCached[innerCol], acc[innerRow][innerCol]);\n }\n }\n }\n\n workgroupBarrier();\n }\n\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n mm_write(batch, globalRow + innerRow, globalCol + innerCol,\n acc[innerRow][innerCol]);\n }\n }\n `;return`\n var mm_Asub : array, ${l}>;\n var mm_Bsub : array, ${o}>;\n\n ${G()} {\n let batch = ${n?\"0\":\"i32(globalId.z)\"};\n let batchA = ${n||!i?\"batch\":\"batch % uniforms.aShape[0]\"};\n let batchB = ${n||!i?\"batch\":\"batch % uniforms.bShape[0]\"};\n let numTiles = ${n?`${Math.ceil(s/o)}`:`(uniforms.dimInner - 1) / ${o} + 1`};\n var kStart = ${n?`i32(globalId.z) * ${s}`:\"0\"};\n\n var acc : array, ${h}>;\n\n // Without this initialization strange values show up in acc.\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n acc[innerRow][innerCol] = 0.0;\n }\n }\n ${x}\n }\n `}var Lie=r=>r?`\n mm_readA(batchA, colA, globalRow),\n mm_readA(batchA, colA + 1, globalRow),\n mm_readA(batchA, colA + 2, globalRow),\n mm_readA(batchA, colA + 3, globalRow)\n `:`\n mm_readA(batchA, globalRow, colA),\n mm_readA(batchA, globalRow, colA + 1),\n mm_readA(batchA, globalRow, colA + 2),\n mm_readA(batchA, globalRow, colA + 3)\n `;function Bie(r,t=!1){y.assert(r[1]===1&&r[2]===1,()=>`A linear work group size is required. But got ${r}.`);let e=r[0]*4;return`\n var mm_Asub : array, ${r[0]}>;\n\n ${G()} {\n let tileCol = i32(localId.x);\n let globalCol = i32(globalId.x);\n let globalRow = i32(globalId.y);\n\n let numTiles = (uniforms.dimInner - 1) / ${e} + 1;\n let batch = i32(globalId.z);\n let batchA = batch % uniforms.aShape[0];\n let batchB = batch % uniforms.bShape[0];\n // Without this initialization strange values show up in acc.\n var acc = 0.0;\n\n // Loop over shared dimension.\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n let colA = t * ${e} + tileCol * 4;\n mm_Asub[tileCol] = vec4(${Lie(t)});\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n for (var k = 0; k < ${e/4}; k++) {\n let rowB = t * ${e} + k * 4;\n let BCached = vec4(mm_readB(batchB, rowB, globalCol),\n mm_readB(batchB, rowB + 1, globalCol),\n mm_readB(batchB, rowB + 2, globalCol),\n mm_readB(batchB, rowB + 3, globalCol));\n\n let ACached = mm_Asub[k];\n acc = acc + dot(ACached, BCached);\n }\n\n workgroupBarrier();\n }\n\n mm_write(batch, globalRow, globalCol, acc);\n }\n `}var Xg=class{constructor(t,e,o=!1,n=!1,s=null,a=null,i=null,p=!1){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.outputShape=e,this.dispatchLayout={x:[2],y:[1],z:[0]};let u=o?t[1]:t[2];if(this.isVec4=(u%4===0&&!o||e[1]%4===0&&o)&&e[2]%4===0&&!n,this.outputComponent=this.isVec4?4:1,this.isVectorA=e[1]===1&&!o,!this.isVec4&&this.isVectorA)this.elementsPerThread=[1,1,1],this.workgroupSize=[32,1,1];else{let m=Xv(e[1],u,e[2],o);this.workgroupSize=m.workgroupSize,this.elementsPerThread=m.elementsPerThread}this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,this.elementsPerThread);let c=s!=null,l=i!=null;c&&this.variableNames.push(\"bias\"),l&&this.variableNames.push(\"preluActivationWeights\"),this.sequentialAccessByThreads=p,this.transposeA=o,this.transposeB=n,this.addBias=c,this.activation=a,this.hasPreluActivationWeights=l,[this.fitAOuter,this.fitBOuter,this.fitInner]=this.getShapeFit(e[1],e[2],u),this.shaderKey=`matMulPacked_${this.elementsPerThread}_${o}_${n}_${this.activation}_${this.fitAOuter}_${this.fitBOuter}_${this.fitInner}_${this.isVec4}_${this.isVectorA}_${this.sequentialAccessByThreads}`}getShapeFit(t,e,o){let n=this.workgroupSize[1]*this.elementsPerThread[1],s=this.workgroupSize[0]*this.elementsPerThread[0];!this.isVec4&&this.isVectorA?this.tileInner=this.workgroupSize[0]*4:this.tileInner=s;let a=t%n===0,i=e%s===0,p=o%this.tileInner===0;return[a,i,p]}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights,this.isVec4)}\n ${hm(this.addBias,this.activation,!1,this.transposeB,this.fitAOuter,this.fitBOuter,this.fitInner,this.isVec4?4:1)}\n ${this.isVec4?Fp(this.elementsPerThread,this.workgroupSize,this.transposeA,this.tileInner,!1,null,!0):this.isVectorA?Bie(this.workgroupSize,this.transposeA):Pp(this.elementsPerThread,this.workgroupSize,this.transposeA,this.tileInner,!1,null,this.sequentialAccessByThreads,!0)}\n `}};function zie(r){return`\n var sumValues : array;\n ${G()} {\n let coords = getOutputCoords();\n let batch = coords[0];\n let batchA = batch % uniforms.aShape[0];\n let batchB = batch % uniforms.bShape[0];\n let row = coords[1];\n let col = coords[2];\n var sum = 0.0;\n let Length = uniforms.dimInner;\n for (var k = i32(localId.x); k < Length; k = k + ${r}) {\n let dataA = mm_readA(batchA, row, k);\n let dataB = mm_readB(batchB, k, col);\n sum = sum + dataA * dataB;\n }\n sumValues[localId.x] = sum;\n workgroupBarrier();\n\n for(var currentSize = ${r/2}u; currentSize > 1u;\n currentSize = currentSize / 2u) {\n if (localId.x < currentSize)\n {\n sumValues[localId.x] = sumValues[localId.x] + sumValues[localId.x + currentSize];\n }\n workgroupBarrier();\n }\n\n if (localId.x == 0u) {\n sum = sumValues[0] + sumValues[1];\n mm_write(batch, row, col, sum);\n }\n }\n `}var Yg=class{constructor(t,e=!1,o=!1,n=null,s=null,a=null){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.workgroupSize=[256,1,1],this.outputShape=t,this.dispatchLayout={x:[],y:[1,2],z:[0]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize);let i=n!=null,p=a!=null;i&&this.variableNames.push(\"bias\"),p&&this.variableNames.push(\"preluActivationWeights\"),this.transposeA=e,this.transposeB=o,this.addBias=i,this.activation=s,this.hasPreluActivationWeights=p,this.shaderKey=`matMulReduce_${this.activation}_${e}_${o}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights)}\n ${hm(this.addBias,this.activation,this.transposeA,this.transposeB)}\n ${zie(this.workgroupSize[0])}\n `}};function Vie(r){let t=r[1],e=r[0],o=t>e?t:e;return`\n var mm_Asub : array, ${t}>;\n var mm_Bsub : array, ${o}>;\n\n // If the output size is small for matrix multiplication, avoid to use vec4\n // and handle some elements per thread to optimally utilize the ALU.\n // Read data from global memory to registers firstly, then store them into\n // shared memory, so it is instruction-Level parallelism for arithmetic\n // operations and others handle IO operations between barrier api, makes ALU\n // and load/store units work simultaneously, could improves the performance.\n ${G()} {\n let tileRow = i32(localId.y);\n let tileCol = i32(localId.x);\n let globalRow = i32(globalId.y);\n let globalCol = i32(globalId.x);\n let batch = i32(globalId.z);\n let batchA = batch % uniforms.aShape[0];\n let batchB = batch % uniforms.bShape[0];\n\n // uniforms.dimInner should be greater than 0.\n let numTiles = (uniforms.dimInner - 1) / ${o} + 1;\n var acc = 0.0;\n\n var globalColA = tileCol;\n var globalRowB = 0;\n var regA = mm_readA(batchA, globalRow, globalColA);\n var regB0 = mm_readB(batchB, globalRowB + 2 * tileRow, globalCol);\n var regB1 = mm_readB(batchB, globalRowB + 2 * tileRow + 1, globalCol);\n globalColA = globalColA + ${o};\n globalRowB = globalRowB + ${o};\n\n for (var t = 0; t < numTiles; t = t + 1) {\n mm_Asub[tileRow][tileCol] = regA;\n mm_Bsub[2 * tileRow][tileCol] = regB0;\n mm_Bsub[2 * tileRow + 1][tileCol] = regB1;\n\n workgroupBarrier();\n\n regA = mm_readA(batchA, globalRow, globalColA);\n regB0 = mm_readB(batchB, globalRowB + 2 * tileRow, globalCol);\n regB1 = mm_readB(batchB, globalRowB + 2 * tileRow + 1, globalCol);\n globalColA = globalColA + ${o};\n globalRowB = globalRowB + ${o};\n\n for (var k = 0; k < ${o}; k = k + 1) {\n acc = acc + mm_Asub[tileRow][k] * mm_Bsub[k][tileCol];\n }\n workgroupBarrier();\n }\n\n mm_write(batch, globalRow, globalCol, acc);\n }\n `}var Qg=class{constructor(t,e,o,n=!1,s=!1,a=null,i=null,p=null){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.workgroupSize=[16,8,1],this.outputShape=o,this.dispatchLayout={x:[2],y:[1],z:[0]},this.dispatch=[Math.ceil(o[2]/this.workgroupSize[0]),Math.ceil(o[1]/this.workgroupSize[1]),o[0]];let u=a!=null;u&&this.variableNames.push(\"bias\");let c=p!=null;c&&this.variableNames.push(\"preluActivationWeights\"),this.transposeA=n,this.transposeB=s,this.addBias=u,this.activation=i,this.hasPreluActivationWeights=c,this.shaderKey=`matMulSmallOutputSize_${this.activation}_${n}_${s}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights)}\n ${hm(this.addBias,this.activation,this.transposeA,this.transposeB)}\n ${Vie(this.workgroupSize)}\n `}};var Zg=class{constructor(t,e,o=!1,n=!1){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.workgroupSize=[8,8,1],this.atomic=!0,this.splitedDimInner=128,y.assert(t[0]===1,()=>\"MatMulSplitKProgram only supports batch = 1.\"),this.outputShape=t,this.dispatchLayout={x:[2],y:[1],z:[0,3]};let s=(o&&this.outputShape[1]%4===0||!o&&e%4===0)&&this.outputShape[2]%4===0;this.elementsPerThread=[4,4,this.splitedDimInner],this.outputComponent=s?4:1,s||(this.outputShape[1]<16&&(this.elementsPerThread[1]=1),this.outputShape[2]<16&&(this.elementsPerThread[0]=1)),this.dispatch=H(this.dispatchLayout,[this.outputShape[0],this.outputShape[1],this.outputShape[2],e],this.workgroupSize,this.elementsPerThread),this.transposeA=o,this.transposeB=n,this.shaderKey=`matMulSplitK_${o}_${n}_${this.elementsPerThread}_${this.outputComponent}`}getUserCode(){let t=this.outputComponent;return`\n ${Qv(!1,this.transposeB,!1,!1,!1,t)}\n fn mm_write(batch: i32, row : i32, col : i32, value : ${Ae(t)}) {\n if (row < uniforms.dimAOuter && col < uniforms.dimBOuter) {\n let coords = vec3(batch, row, col);\n let flatIndex = getOutputIndexFromCoords(coords);\n // The problem is that we should initialize output to zero before using.\n // Otherwise, the original value will be added to the result.\n for (var i = 0; i < ${t}; i = i + 1) {\n ${Qr(\"&result[flatIndex + i]\",`${t>1?\"value[i]\":\"value\"}`,\"float32\")}\n }\n }\n }\n ${t===4?Fp(this.elementsPerThread,this.workgroupSize,this.transposeA,32,!0,this.splitedDimInner):Pp(this.elementsPerThread,this.workgroupSize,this.transposeA,32,!0,this.splitedDimInner)}\n `}},Jg=class{constructor(t,e=null,o=null,n=null){this.uniforms=\"\",this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.addBias=e!=null,this.hasPreluActivationWeights=n!=null,this.activation=o,this.addBias&&this.variableNames.push(\"bias\"),this.hasPreluActivationWeights&&this.variableNames.push(\"preluActivationWeights\"),this.shaderKey=`biasActivation_${o}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights)}\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n var value = getXByOutputIndex(index);\n ${Zr(this.addBias,this.activation)}\n setOutputAtIndex(index, value);\n }\n }\n `}};var ex=class{constructor(t){this.variableNames=[],this.outputShape=[],this.uniforms=\"value : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"fill\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n setOutputAtIndex(index, uniforms.value);\n }\n }\n `}};function kt(r){let{backend:t,attrs:e}=r,{shape:o,value:n}=e,{dtype:s}=e;if(s=s||y.inferDtype(n),s===\"string\"){let a=y.getArrayFromDType(s,y.sizeFromShape(o));return a.fill(n),t.makeTensorInfo(o,s,a)}else{let a=new ex(o),i=[{type:\"float32\",data:[n]}];return t.runWebGPUProgram(a,[],s,i)}}var ez={kernelName:sa,backendName:\"webgpu\",kernelFunc:kt};function pe(r){let{inputs:t,attrs:e}=r,{x:o}=t,{shape:n}=e,s=y.sizeFromShape(o.shape),a=y.inferFromImplicitShape(n,s),i=y.sizeFromShape(a);return y.assert(s===i,()=>`The new shape (${a}) has ${i} elements and the old shape (${o.shape}) has ${s} elements. The new shape and old shape must have the same number of elements.`),r.backend.incRef(o.dataId),{dataId:o.dataId,shape:a,dtype:o.dtype}}var tz={kernelName:da,backendName:\"webgpu\",kernelFunc:pe};function Op({a:r,b:t,transposeA:e,transposeB:o,backend:n,bias:s=null,preluActivationWeights:a=null,leakyreluAlpha:i=0,activation:p=null}){let u=r.shape.length,c=t.shape.length,l=e?r.shape[u-2]:r.shape[u-1],m=o?t.shape[c-1]:t.shape[c-2],d=e?r.shape[u-1]:r.shape[u-2],f=o?t.shape[c-2]:t.shape[c-1],h=r.shape.slice(0,-2),g=t.shape.slice(0,-2),x=y.sizeFromShape(h),b=y.sizeFromShape(g),S=Ir.assertAndGetBroadcastShape(r.shape.slice(0,-2),t.shape.slice(0,-2)).concat([d,f]);y.assert(l===m,()=>`Error in matMul: inner shapes (${l}) and (${m}) of Tensors with shapes ${r.shape} and ${t.shape} and transposeA=${e} and transposeB=${o} must match.`);let k=e?[x,l,d]:[x,d,l],_=o?[b,f,m]:[b,m,f],E=pe({inputs:{x:r},backend:n,attrs:{shape:k}}),R=pe({inputs:{x:t},backend:n,attrs:{shape:_}}),D=[E,R],P=Math.max(x,b),O=[E,R],M=[{type:\"int32\",data:[d]},{type:\"int32\",data:[f]},{type:\"int32\",data:[l]}],L,B,z=[P,d,f],U=A().get(\"WEBGPU_MATMUL_PROGRAM_TYPE\");if(U<0){let q=A().getNumber(\"WEBGPU_THRESHOLD_TO_INCREASE_WORKGROUPS_FOR_MATMUL\"),Y=q>0?q:n.thresholdToIncreaseWorkgroups,J=P*Math.ceil(d/32)*Math.ceil(f/32);J<=Y||d<=8&&J<=Y*2?P*d*f<=128?U=Lo.MatMulReduceProgram:P===1&&m>=2e3?U=Lo.MatMulSplitKProgram:U=Lo.MatMulSmallOutputSizeProgram:U=Lo.MatMulPackedProgram}switch(U){case Lo.MatMulReduceProgram:L=new Yg(z,e,o,s,p,a);break;case Lo.MatMulSplitKProgram:{if(B=kt({backend:n,attrs:{shape:z,value:0,dtype:r.dtype}}),L=new Zg(z,m,e,o),s||p){B=n.runWebGPUProgram(L,O,r.dtype,M,B);let Y=new Jg(B.shape,s,p,a),J=null,re=[B];s&&re.push(s),a&&re.push(a),p===\"leakyrelu\"&&(J=[{type:\"float32\",data:[i]}],Y.uniforms+=\" alpha : f32,\");let ne=n.runWebGPUProgram(Y,re,B.dtype,J);D.push(B);let ee=pe({inputs:{x:ne},backend:n,attrs:{shape:S}});D.push(ne);for(let oe of D)n.disposeData(oe.dataId);return ee}break}case Lo.MatMulSmallOutputSizeProgram:L=new Qg(k,_,z,e,o,s,p,a);break;case Lo.MatMulPackedProgram:let q=n.adapterInfo.isIntel();L=new Xg(k,z,e,o,s,p,a,q);break;default:throw new Error(`Unsupported MatMulProgramType ${U}.`)}s&&O.push(s),a&&O.push(a),p===\"leakyrelu\"&&(M.push({type:\"float32\",data:[i]}),L.uniforms+=\" alpha : f32,\"),B=n.runWebGPUProgram(L,O,r.dtype,M,B);let j=pe({inputs:{x:B},backend:n,attrs:{shape:S}});D.push(B);for(let q of D)n.disposeData(q.dataId);return j}function Wie(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s,bias:a,preluActivationWeights:i}=t,{transposeA:p,transposeB:u,activation:c,leakyreluAlpha:l}=o;return Op({a:n,b:s,transposeA:p,transposeB:u,backend:e,bias:a,preluActivationWeights:i,leakyreluAlpha:l,activation:c})}var rz={kernelName:Io,backendName:\"webgpu\",kernelFunc:Wie};var gm=class{constructor(t,e,o){this.variableNames=[\"AReal\",\"AImag\",\"BReal\",\"BImag\"],this.workgroupSize=[128,1,1],this.size=!0,this.outputShape=w.assertAndGetBroadcastShape(e,o),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=`binaryOpComplex_${t}`,this.op=t}getUserCode(){return`\n fn binaryOpComplex(\n areal : f32, aimag : f32, breal : f32, bimag : f32) -> f32 {\n ${Qc(this.op,!1)}\n }\n\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let areal = getARealByOutputIndex(index);\n let aimag = getAImagByOutputIndex(index);\n let breal = getBRealByOutputIndex(index);\n let bimag = getBImagByOutputIndex(index);\n setOutputAtIndex(index, binaryOpComplex(areal, aimag, breal, bimag));\n }\n }\n `}};var ki=class{constructor(t,e,o){if(this.size=!0,this.variableNames=[\"A\",\"B\"],this.outputShape=w.assertAndGetBroadcastShape(e,o),this.dispatchLayout=X(this.outputShape),this.op=t,this.useSharedMemoryWithA=e.length<=1&&o.length>1&&e[0]<128,this.useSharedMemoryWithB=o.length<=1&&e.length>1&&o[0]<128,this.useSharedMemoryWithA||this.useSharedMemoryWithB)this.outputComponent=1,this.variableComponents=[1,1],this.lastDimensionSize=this.useSharedMemoryWithB?o[0]:e[0],this.shaderKey=`binary_${t}_${this.lastDimensionSize}`,this.type=\"shared\",this.workgroupSize=[256,1,1];else{let n=e.length>0&&e[e.length-1]%4===0,s=o.length>0&&o[o.length-1]%4===0;n&&s?(this.outputComponent=4,this.variableComponents=[4,4]):n&&(y.isScalarShape(o)||o[o.length-1]===1)||s&&(y.isScalarShape(e)||e[e.length-1]===1)?(this.outputComponent=4,this.variableComponents=n?[4,1]:[1,4]):(this.outputComponent=1,this.variableComponents=[1,1]),this.type=\"nonshared\",this.shaderKey=`binary_${t}_${this.variableComponents}`,this.workgroupSize=[128,1,1]}this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.outputComponent,1,1])}getUserCode(){let t,e=this.outputComponent===4?\"vec4\":\"f32\",o=`\n fn binaryOperation(a : ${e}, b : ${e}) -> ${e} {\n ${Qc(this.op,this.outputComponent===4)}\n };\n `;if(this.type===\"shared\"){let n=this.lastDimensionSize>1?`coords[${this.outputShape.length-1}]`:\"0\",s=this.useSharedMemoryWithB?`let a = getAByOutputIndex(index);\n let b = sharedBuf[${n}];`:`let a = sharedBuf[${n}];\n let b = getBByOutputIndex(index);`;t=`\n ${o}\n var sharedBuf : array;\n ${G(\"index\")} {\n // Fill in the shared memory buffer.\n let localIndex = i32(localId.x);\n if(localIndex < ${this.lastDimensionSize}) {\n sharedBuf[localIndex] = f32(${this.useSharedMemoryWithB?\"B\":\"A\"}[localIndex]);\n }\n workgroupBarrier();\n\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n ${s}\n setOutputAtIndex(index, binaryOperation(a, b));\n }\n }\n `}else t=`\n ${o}\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index * ${this.outputComponent});\n let a = ${e}(getAByOutputCoords(coords));\n let b = ${e}(getBByOutputCoords(coords));\n setOutputAtIndex(index, binaryOperation(a, b));\n }\n }\n `;return t}};function Ft(r){let{inputs:t}=r,{x:e}=t;return r.backend.incRef(e.dataId),{dataId:e.dataId,shape:e.shape,dtype:e.dtype}}var oz={kernelName:wo,backendName:\"webgpu\",kernelFunc:Ft};function yo(r){let{inputs:t,backend:e}=r,{real:o,imag:n}=t,s=e.makeTensorInfo(o.shape,\"complex64\"),a=e.tensorMap.get(s.dataId),i=Ft({inputs:{x:o},backend:e}),p=Ft({inputs:{x:n},backend:e});return a.complexTensorInfos={real:i,imag:p},s}var nz={kernelName:Fi,backendName:\"webgpu\",kernelFunc:yo};var Jr=class{constructor(t,e,o=\"\"){this.variableNames=[\"A\"],this.size=!0;let n=128;this.workgroupSize=[n,1,1],this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.op=e,o!==\"\"&&(this.uniforms=o),this.shaderKey=`unary_${e}`}getUserCode(){return`\n fn unaryOperation(a : f32) -> f32 {\n ${vi(this.op,!1)}\n }\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let a = getAByOutputIndex(index);\n setOutputAtIndex(index, unaryOperation(a));\n }\n }\n `}};function ye({opType:r,cpuKernelImpl:t,dtype:e}){return({inputs:o,backend:n})=>{let{x:s}=o,a=n,i=e||s.dtype;if(a.shouldExecuteOnCPU([s])&&t!=null){let u=a.tensorMap.get(s.dataId),c=t(u.values,i);return a.makeTensorInfo(s.shape,i,c)}let p=new Jr(s.shape,r);return a.runWebGPUProgram(p,[s],i)}}function et({opType:r,cpuKernelImpl:t,supportsComplex:e=!1,dtype:o}){return({inputs:n,backend:s})=>{let{a,b:i}=n,p=s;if(e&&a.dtype===\"complex64\"){let l=p.tensorMap.get(a.dataId),m=p.tensorMap.get(i.dataId),d,f;if(r!==fe.MUL)[d,f]=[[l.complexTensorInfos.real,m.complexTensorInfos.real],[l.complexTensorInfos.imag,m.complexTensorInfos.imag]].map(g=>{let[x,b]=g,C={dataId:x.dataId,dtype:x.dtype,shape:a.shape},S={dataId:b.dataId,dtype:b.dtype,shape:i.shape},k=new ki(r,a.shape,i.shape);return p.runWebGPUProgram(k,[C,S],dt(x.dtype,b.dtype))});else{let g=new gm(fe.COMPLEX_MULTIPLY_REAL,a.shape,i.shape),x=new gm(fe.COMPLEX_MULTIPLY_IMAG,a.shape,i.shape),b=[{dataId:l.complexTensorInfos.real.dataId,dtype:l.complexTensorInfos.real.dtype,shape:a.shape},{dataId:l.complexTensorInfos.imag.dataId,dtype:l.complexTensorInfos.imag.dtype,shape:a.shape},{dataId:m.complexTensorInfos.real.dataId,dtype:m.complexTensorInfos.real.dtype,shape:i.shape},{dataId:m.complexTensorInfos.imag.dataId,dtype:m.complexTensorInfos.imag.dtype,shape:i.shape}];d=p.runWebGPUProgram(g,b,\"float32\"),f=p.runWebGPUProgram(x,b,\"float32\")}let h=yo({inputs:{real:d,imag:f},backend:p});return p.disposeData(d.dataId),p.disposeData(f.dataId),h}let u=o||dt(a.dtype,i.dtype);if((a.dtype===\"string\"||i.dtype===\"string\"||p.shouldExecuteOnCPU([a,i]))&&t!=null){let l=p.tensorMap.get(a.dataId).values,m=p.tensorMap.get(i.dataId).values,d=a.dtype===\"string\"?w.fromUint8ToStringArray(l):l,f=a.dtype===\"string\"?w.fromUint8ToStringArray(m):m,[h,g]=t(a.shape,i.shape,d,f,u);return p.makeTensorInfo(g,u,h)}let c=new ki(r,a.shape,i.shape);return p.runWebGPUProgram(c,[a,i],u)}}var{addImpl:sz,castImpl:az,ceilImpl:iz,concatImpl:uz,equalImpl:pz,expImpl:cz,expm1Impl:lz,floorImpl:mz,floorDivImpl:dz,gatherNdImpl:fz,gatherV2Impl:hz,greaterEqualImpl:gz,greaterImpl:xz,lessEqualImpl:yz,lessImpl:bz,logImpl:Cz,maxImpl:wz,maximumImpl:Sz,minimumImpl:Iz,multiplyImpl:vz,negImpl:kz,notEqualImpl:Nz,prodImpl:Tz,rangeImpl:_z,rsqrtImpl:$z,scatterImpl:Ez,simpleAbsImpl:Rz,sliceImpl:Dz,stridedSliceImpl:Az,stringNGramsImpl:Fz,subImpl:Pz,tileImpl:Oz,topKImpl:Mz,transposeImpl:Lz,uniqueImpl:HPt}=Tc;var Uie=ye({opType:Z.ABS,cpuKernelImpl:Rz}),Bz={kernelName:Xs,backendName:\"webgpu\",kernelFunc:Uie};var Gie=ye({opType:Z.ACOS}),zz={kernelName:Wo,backendName:\"webgpu\",kernelFunc:Gie};var Hie=ye({opType:Z.ACOSH}),Vz={kernelName:Uo,backendName:\"webgpu\",kernelFunc:Hie};var Kie=et({opType:fe.ADD,cpuKernelImpl:sz,supportsComplex:!0}),Wz={kernelName:uo,backendName:\"webgpu\",kernelFunc:Kie};var tx=class{constructor(t){this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t[0],this.variableNames=t.map((e,o)=>`T${o}`),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.shaderKey=\"addN\"}getUserCode(){let t=[];this.variableNames.forEach(n=>{t.push(`let v${n} = get${n}ByOutputCoords(coords);`)});let e=this.variableNames.map(n=>`v${n}`).join(\" + \");return`\n ${G(\"index\")} {\n for (var i = 0; i < ${this.workPerThread}; i = i + 1) {\n let flatIndex = index * ${this.workPerThread} + i;\n if (flatIndex < uniforms.size) {\n let coords = getCoordsFromIndex(flatIndex);\n ${t.join(`\n `)}\n setOutputAtIndex(flatIndex, ${e});\n }\n }\n }\n `}};function qie(r){let{inputs:t,backend:e}=r,o=t;if(o.length===1)return Ft({inputs:{x:o[0]},backend:e});let n=o.map(i=>i.dtype).reduce((i,p)=>dt(i,p)),s=o.map(i=>i.shape),a=new tx(s);return e.runWebGPUProgram(a,o,n)}var Uz={kernelName:Go,backendName:\"webgpu\",kernelFunc:qie};var rx=class{constructor(t,e){this.variableNames=[\"A\"],this.workgroupSize=[16,16,1];let o=new Array(t.length);for(let n=0;n`Must be a square tile, current tile shape is ${this.workgroupSize[0]} x ${this.workgroupSize[1]}`);let t=this.workgroupSize[0];return`\n var tile : array, ${this.workgroupSize[0]}>;\n ${G()} {\n var x = i32(workgroupId.x) * ${t} + i32(localId.x);\n var y = i32(workgroupId.y) * ${t} + i32(localId.y);\n let width = uniforms.outShape[0];\n let height = uniforms.outShape[1];\n if (x < width && y < height) {\n tile[localId.y][localId.x] = f32(A[y * width + x]);\n }\n workgroupBarrier();\n\n x = i32(workgroupId.y) * ${t} + i32(localId.x);\n y = i32(workgroupId.x) * ${t} + i32(localId.y);\n if (x < height && y < width) {\n setOutputAtIndex((y * height + x), tile[localId.x]\n [localId.y]);\n }\n }\n `}};var ox=class{constructor(t,e){this.variableNames=[\"A\"],this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0;let o=new Array(t.length);for(let n=0;n6)throw Error(`Transpose for rank ${t} is not yet supported`);let e=new Array(t);for(let o=0;o=32768&&o>=512?this.workgroupSize=[512,1,1]:t.inSize>=4096?this.workgroupSize=[256,1,1]:this.workgroupSize=[64,1,1],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,[1,1,1]),this.reduceType=e,this.shaderKey=`reduce_${e}`}getUserCode(){let t=\"\",e=\"0.0\",o=this.workgroupSize[0];this.reduceType===\"min\"||this.reduceType===\"max\"?(t=`\n if (isnan(candidate)) {\n bestValue = uniforms.NAN;\n } else if (!isnan(bestValue) && candidate ${this.reduceType===\"min\"?\"<\":\">\"} bestValue)\n { bestValue = candidate; }`,e=\"f32(x[offset])\"):this.reduceType===\"sum\"||this.reduceType===\"mean\"?t=\" bestValue = bestValue + candidate; \":this.reduceType===\"prod\"?(t=\" bestValue = bestValue * candidate; \",e=\"1.0\"):this.reduceType===\"all\"?(t=\" bestValue = f32(bestValue >= 1.0 && candidate >= 1.0); \",e=\"1.0\"):this.reduceType===\"any\"&&(t=\" bestValue = f32(bestValue >= 1.0 || candidate >= 1.0); \",e=\"0.0\");let n=this.reduceType===\"mean\"?\"setOutputAtIndex(outputIndex, bestValue / f32(uniforms.reduceSize));\":\"setOutputAtIndex(outputIndex, bestValue);\";return`\n fn DIV_CEIL(a : u32, b : u32) -> u32 {\n return ((a - 1u) / b + 1u);\n }\n\n ${`\n var xBestValues : array;\n `}\n fn getOffset(outputIndex : i32) -> i32 {\n let outputCoords = getCoordsFromIndex(outputIndex);\n let offset = ${this.outputShape.length===1?\"outputCoords\":\"outputCoords[0]\"} * uniforms.reduceSize;\n return offset;\n }\n ${G(\"index\")} {\n let outputIndex = index / ${o};\n let offset = getOffset(outputIndex);\n var bestValue = ${e};\n let Length = uniforms.reduceSize;\n let WorkPerThread = DIV_CEIL(u32(Length), ${o}u);\n for (var k = i32(localId.x); k < Length && outputIndex < uniforms.size;\n k = k + ${o}) {\n let candidate = f32(x[offset + k]);\n ${t}\n }\n xBestValues[localId.x] = bestValue;\n workgroupBarrier();\n\n var reduceSize = min(u32(Length), ${o}u);\n for (var currentSize = reduceSize / 2u; reduceSize > 1u;\n currentSize = reduceSize / 2u) {\n let interval = DIV_CEIL(reduceSize, 2u);\n if (localId.x < currentSize) {\n let candidate = xBestValues[localId.x + interval];\n ${t}\n xBestValues[localId.x] = bestValue;\n }\n reduceSize = interval;\n workgroupBarrier();\n }\n\n if (localId.x == 0u && outputIndex < uniforms.size) {\n ${n}\n }\n }\n `}};var jie={mean:\"float32\",all:\"bool\",any:\"bool\"};function eo(r,t,e,o,n){let s=r.shape.length,a=[],i=y.parseAxisParam(t,r.shape),p=i,u=w.getAxesPermutation(p,s),c=r;u!=null&&(c=yr({inputs:{x:r},attrs:{perm:u},backend:n}),p=w.getInnerMostAxes(p.length,s),a.push(c)),w.assertAxesAreInnerMostDims(o,p,s);let[l,m]=w.computeOutAndReduceShapes(c.shape,p),d=l;e&&(d=w.expandShapeToKeepDim(l,i));let f;if((o===\"max\"||o===\"prod\")&&n.shouldExecuteOnCPU([c])){let h=n.tensorMap.get(c.dataId).values;switch(o){case\"max\":let g=wz(h,y.sizeFromShape(m),d,r.dtype);f=n.makeTensorInfo(d,r.dtype,g);break;case\"prod\":let{outVals:x,outShape:b,outDtype:C}=Tz(c.shape,c.dtype,h,p);f=n.makeTensorInfo(b,C,x);break;default:throw new Error(`${o} CPU implementation is not yet supported.`)}}else{let h=y.sizeFromShape(m),x=y.sizeFromShape(c.shape)/h,b={windowSize:h,inSize:h,batchSize:x,outSize:1},C=jie[o]||ni(r.dtype),S=[{type:\"int32\",data:[h]}],k=new nx(b,o,n.device.limits.maxComputeWorkgroupSizeX),_=n.runWebGPUProgram(k,[c],C,S);a.push(_),f=pe({inputs:{x:_},attrs:{shape:d},backend:n})}return a.forEach(h=>n.disposeData(h.dataId)),f}function Xie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{keepDims:s,axis:a}=o;return eo(n,a,s,\"all\",e)}var Hz={kernelName:Ho,backendName:\"webgpu\",kernelFunc:Xie};function Yie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{keepDims:s,axis:a}=o;return eo(n,a,s,\"any\",e)}var Kz={kernelName:Ko,backendName:\"webgpu\",kernelFunc:Yie};var Zc=class{constructor(t,e,o){this.workgroupSize=[64,1,1],this.variableNames=[\"x\"],this.uniforms=\"infinityValue : f32,\",this.size=!0;let n=[e];this.op=o===\"min\"?\"<\":\">\";let[s,a]=w.computeOutAndReduceShapes(t,n);this.outputShape=s.length===0?[1]:s,this.dispatchLayout=X(this.outputShape),y.sizeFromShape(a)<32?(this.type=\"plain\",this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize)):(this.type=\"shared\",this.dispatch=H(this.dispatchLayout,this.outputShape,[1,1,1])),this.inputShape=t,this.shaderKey=`argMinMax_${this.op}_${this.type}`}getUserCode(){let t=this.workgroupSize[0],e=()=>this.inputShape.length===1?\"uniforms.xShape\":`uniforms.xShape.${Mo(this.inputShape.length-1)}`,o=()=>{let n=\"\";if(this.outputShape.length===1)this.inputShape.length!==1&&(n+=\"outputCoords,\");else for(let s=0;s u32 {\n return ((a - 1u) / b + 1u);\n }\n\n ${`\n var xBestIndices : array;\n var xBestValues : array;\n `}\n\n ${G(\"index\")} {\n let outputIndex = index / ${t};\n let reduceLength = ${e()};\n\n var bestIndex = i32(localId.x);\n var bestValue = uniforms.infinityValue;\n let outputCoords = getCoordsFromIndex(outputIndex);\n for (var k = i32(localId.x); k < reduceLength && outputIndex < uniforms.size;\n k = k + ${t}) {\n let candidate = getX(${o()} k);\n if (!isnan(candidate) && candidate ${this.op} bestValue) {\n bestValue = candidate;\n bestIndex = k;\n }\n }\n xBestValues[localId.x] = bestValue;\n xBestIndices[localId.x] = bestIndex;\n workgroupBarrier();\n\n var reduceSize = min(u32(reduceLength), ${t}u);\n for (var currentSize = reduceSize / 2u; reduceSize > 1u;\n currentSize = reduceSize / 2u) {\n let interval = DIV_CEIL(reduceSize, 2u);\n if (localId.x < currentSize) {\n let candidate = xBestValues[localId.x + interval];\n if (candidate ${this.op} bestValue) {\n bestValue = candidate;\n xBestValues[localId.x] = bestValue;\n xBestIndices[localId.x] = xBestIndices[localId.x + interval];\n }\n }\n reduceSize = interval;\n workgroupBarrier();\n }\n\n if (localId.x == 0u && outputIndex < uniforms.size) {\n setOutputAtIndexI32(outputIndex, xBestIndices[localId.x]);\n }\n }\n `:`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let outputCoords = getCoordsFromIndex(index);\n var bestIndex = 0;\n var bestValue = getX(${o()} 0);\n let reduceLength = ${e()};\n for (var i = 1; i < reduceLength; i++) {\n let candidate = getX(${o()} i);\n if (candidate ${this.op} bestValue) {\n bestValue = candidate;\n bestIndex = i;\n }\n }\n setOutputAtIndexI32(index, bestIndex);\n }\n }\n `}};function Qie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=yr({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMax\",[a[0]],p.shape.length);let c=new Zc(p.shape,a[0],\"max\"),l=[{type:\"float32\",data:[Number.NEGATIVE_INFINITY]}],m=e.runWebGPUProgram(c,[p],\"int32\",l);return u.forEach(d=>e.disposeData(d.dataId)),m}var qz={kernelName:Ys,backendName:\"webgpu\",kernelFunc:Qie};function Zie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=yr({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMin\",[a[0]],p.shape.length);let c=new Zc(p.shape,a[0],\"min\"),l=[{type:\"float32\",data:[Number.POSITIVE_INFINITY]}],m=e.runWebGPUProgram(c,[p],\"int32\",l);return u.forEach(d=>e.disposeData(d.dataId)),m}var jz={kernelName:Qs,backendName:\"webgpu\",kernelFunc:Zie};var Jie=ye({opType:Z.ASIN}),Xz={kernelName:qo,backendName:\"webgpu\",kernelFunc:Jie};var eue=ye({opType:Z.ASINH}),Yz={kernelName:jo,backendName:\"webgpu\",kernelFunc:eue};var tue=ye({opType:Z.ATAN}),Qz={kernelName:Xo,backendName:\"webgpu\",kernelFunc:tue};var rue=et({opType:fe.ATAN2}),Zz={kernelName:Qo,backendName:\"webgpu\",kernelFunc:rue};var oue=ye({opType:Z.ATANH}),Jz={kernelName:Yo,backendName:\"webgpu\",kernelFunc:oue};var sx=class{constructor(t){this.variableNames=[\"x\"],this.uniforms=\"strides : vec2,\",this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"poolWithFilterSizeEqualsOne\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n\n let xRCCorner = coords.yz * uniforms.strides;\n let xRCorner = xRCCorner.x;\n let xCCorner = xRCCorner.y;\n\n let value = getX(batch, xRCorner, xCCorner, d);\n setOutputAtIndex(index, value);\n }\n }\n `}};var za=class{constructor(t,e,o=!1,n=!1,s=!1){if(this.variableNames=[\"x\"],this.uniforms=\"strides : vec2, pads : vec2, dilations : vec2, convDims : vec2, filterDims : vec2,\",this.workgroupSize=[128,1,1],this.size=!0,e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.poolType=e,this.computePositions=o,this.flattenPositions=n,this.includeBatchIndex=s,this.shaderKey=`pool2D_${e}_${o}_${n}_${s}`}getUserCode(){let t;this.poolType===\"avg\"?t=\"resultValue = resultValue + value; count = count + 1.0;\":this.computePositions?t=`let currMaxValue = mix(value, maxValue, maxValueFound);\n if (value >= currMaxValue) {\n maxValue = value;\n maxValueFound = 1.0;\n maxPosition = ${this.flattenPositions?this.includeBatchIndex?\"((batch * uniforms.xShape[1] + xR) * uniforms.xShape[2] + xC) * uniforms.xShape[3] + d\":\"(xR * uniforms.xShape[2] + xC) * uniforms.xShape[3] + d\":\"wR * uniforms.filterDims.y + wC\"};\n }`:t=\"resultValue = max(value, resultValue);\";let e=\"resultValue\";return this.poolType===\"avg\"&&(e=\"resultValue / max(count, 1.0)\"),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n let xRCCorner = vec2(coords.yz) * uniforms.strides - uniforms.pads;\n let xRCorner = xRCCorner.x;\n let xCCorner = xRCCorner.y;\n\n ${this.computePositions?`var maxValue = 0.0;\n var maxValueFound = 0.0;\n var maxPosition = 0;`:`var resultValue = ${this.poolType===\"avg\"?\"0.0\":\"-1.0 / pow(10.0, -20.0)\"};`}\n\n var count = 0.0;\n for (var wR = 0; wR < uniforms.filterDims.x; wR = wR + uniforms.dilations.x) {\n let xR = xRCorner + wR;\n\n if (xR < 0 || xR >= uniforms.convDims.x) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterDims.y; wC = wC + uniforms.dilations.y) {\n let xC = xCCorner + wC;\n if (xC < 0 || xC >= uniforms.convDims.y) {\n continue;\n }\n\n let value = getX(batch, xR, xC, d);\n ${t}\n }\n }\n\n ${this.computePositions?\"setOutputAtIndexI32(index, maxPosition);\":`setOutputAtIndex(index, ${e});`}\n }\n }\n `}},_u=class{constructor(t,e,o=!1,n=!1,s=!1){if(this.variableNames=[\"x\"],this.uniforms=\"strides : vec3, pads : vec3, convDims : vec3, filterDims : vec3,\",this.workgroupSize=[128,1,1],this.size=!0,e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.poolType=e,this.computePositions=o,this.flattenPositions=n,this.includeBatchIndex=s,this.shaderKey=`pool3D_${e}_${o}_${n}_${s}`}getUserCode(){let t;this.poolType===\"avg\"?t=\"resultValue += value; count += 1.0;\":this.computePositions?t=`let currMaxValue = mix(value, maxValue, maxValueFound);\n if (value >= currMaxValue) {\n maxValue = value;\n maxValueFound = 1.0;\n maxPosition = ${this.flattenPositions?this.includeBatchIndex?\"(((batch * uniforms.xShape.y + xD) * uniforms.xShape.z + xR) * uniforms.xShape.w + xC) * uniforms.xShape.u + ch\":\"((xD * uniforms.xShape.z + xR) * uniforms.xShape.w + xC) * uniforms.xShape.u + ch\":\"wD * uniforms.filterDims.y * uniforms.filterDims.y + wR * uniforms.filterDims.z + wC\"};\n }`:t=\"resultValue = max(value, resultValue);\";let e=\"resultValue\";return this.poolType===\"avg\"&&(e=\"resultValue / max(count, 1.0)\"),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let ch = coords.u;\n\n let xCorner = vec3(coords.y, coords.z, coords.w) * uniforms.strides - uniforms.pads;\n let xDCorner = xCorner.x;\n let xRCorner = xCorner.y;\n let xCCorner = xCorner.z;\n\n ${this.computePositions?`var maxValue = 0.0;\n var maxValueFound = 0.0;\n var maxPosition = 0;`:`var resultValue = ${this.poolType===\"avg\"?\"0.0\":\"-1.0 / pow(10.0, -20.0)\"};`}\n\n var count = 0.0;\n for (var wD = 0; wD < uniforms.filterDims.x; wD++) {\n let xD = xDCorner + wD;\n if (xD < 0 || xD >= uniforms.convDims.x) {\n continue;\n }\n\n for (var wR = 0; wR < uniforms.filterDims.y; wR++) {\n let xR = xRCorner + wR;\n if (xR < 0 || xR >= uniforms.convDims.y) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterDims.z; wC++) {\n let xC = xCCorner + wC;\n if (xC < 0 || xC >= uniforms.convDims.z) {\n continue;\n }\n\n let value = getX(batch, xD, xR, xC, ch);\n ${t}\n }\n }\n }\n\n ${this.computePositions?\"setOutputAtIndexI32(index, maxPosition);\":`setOutputAtIndex(index, ${e});`}\n }\n }\n `}};function Jv(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{reductionIndices:s,keepDims:a}=o;return eo(n,s,a,\"max\",e)}var eV={kernelName:Vn,backendName:\"webgpu\",kernelFunc:Jv};function e0(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{keepDims:s,axis:a}=o;return eo(n,a,s,\"mean\",e)}var tV={kernelName:Gn,backendName:\"webgpu\",kernelFunc:e0};function ax(r,t,e,o){if(t.filterWidth===1&&t.filterHeight===1&&y.arraysEqual(t.inShape,t.outShape))return Ft({inputs:{x:r},backend:o});if(t.filterWidth===t.inWidth&&t.filterHeight===t.inHeight&&t.batchSize===1&&t.padInfo.type===\"VALID\"){let a=r.shape.length,i=pe({inputs:{x:r},backend:o,attrs:{shape:[r.shape[a-3]*r.shape[a-2],r.shape[a-1]]}}),p;e===\"avg\"?p=e0({inputs:{x:i},backend:o,attrs:{axis:0,keepDims:!1}}):(y.assert(e===\"max\",()=>`Invalid pool type ${e}`),p=Jv({inputs:{x:i},backend:o,attrs:{reductionIndices:0,keepDims:!1}}));let u=pe({inputs:{x:p},backend:o,attrs:{shape:t.outShape}});return o.disposeData(i.dataId),o.disposeData(p.dataId),u}let n,s=[{type:\"int32\",data:[t.strideHeight,t.strideWidth]}];return t.filterHeight===1&&t.filterWidth===1?n=new sx(t):(e===\"avg\"?n=new za(t,\"avg\"):(y.assert(e===\"max\",()=>`Invalid pool type ${e}`),n=new za(t,\"max\")),s.push({type:\"int32\",data:[t.padInfo.top,t.padInfo.left]},{type:\"int32\",data:[t.dilationHeight,t.dilationWidth]},{type:\"int32\",data:[t.inHeight,t.inWidth]},{type:\"int32\",data:[t.effectiveFilterHeight,t.effectiveFilterWidth]})),o.runWebGPUProgram(n,[r],r.dtype,s)}function nue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1,c=w.computePool2DInfo(n.shape,s,a,u,i,p);return ax(n,c,\"avg\",e)}var rV={kernelName:Zo,backendName:\"webgpu\",kernelFunc:nue};function sue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dataFormat:p,dimRoundingMode:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,u,p),m=new _u(l,\"avg\"),d=[{type:\"int32\",data:[l.strideDepth,l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.padInfo.front,l.padInfo.top,l.padInfo.left]},{type:\"int32\",data:[l.inDepth,l.inHeight,l.inWidth]},{type:\"int32\",data:[l.effectiveFilterDepth,l.effectiveFilterHeight,l.effectiveFilterWidth]}];return e.runWebGPUProgram(m,[n],n.dtype,d)}var oV={kernelName:Zs,backendName:\"webgpu\",kernelFunc:sue};var ix=class{constructor(t){this.variableNames=[\"dy\"],this.uniforms=`strides : vec2, pads : vec2, dilations : vec2, filterDims : vec2,\n outHeight : i32, outWidth : i32, avgMultiplier : f32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"avgPool2DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n\n let dyRCCorner = vec2(coords.yz) - uniforms.pads;\n let dyRCorner = dyRCCorner.x;\n let dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var wR = 0; wR < uniforms.filterDims[0]; wR = wR + uniforms.dilations[0]) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[0]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[1]; wC = wC + uniforms.dilations[1]) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[1]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyR, idyC, d);\n\n dotProd = dotProd + dyValue * uniforms.avgMultiplier;\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},ux=class{constructor(t){this.variableNames=[\"dy\"],this.uniforms=`strides : vec3, pads : vec3, filterDims : vec3,\n outDepth : i32, outHeight : i32, outWidth : i32, avgMultiplier : f32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"avgPool3DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let ch = coords.u;\n\n let dyCorner = vec3(coords.y, coords.z, coords.w) - uniforms.pads;\n let dyDCorner = dyCorner.x;\n let dyRCorner = dyCorner.y;\n let dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, d) with pos mask(:, :, :, ch) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var wD = 0; wD < uniforms.filterDims[0]; wD++) {\n let dyD = f32(dyDCorner + wD) / f32(uniforms.strides[0]);\n\n if (dyD < 0.0 || dyD >= f32(uniforms.outDepth) || fract(dyD) > 0.0) {\n continue;\n }\n let idyD = i32(dyD);\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[1]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[2]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyD, idyR, idyC, ch);\n dotProd += dyValue * uniforms.avgMultiplier;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function aue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=w.computePool3DInfo(a.shape,i,p,1,u,c),m=new ux(l),d=1/(l.filterDepth*l.filterHeight*l.filterWidth),f=[{type:\"int32\",data:[l.strideDepth,l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.effectiveFilterDepth-1-l.padInfo.front,l.effectiveFilterHeight-1-l.padInfo.top,l.effectiveFilterWidth-1-l.padInfo.left]},{type:\"int32\",data:[l.effectiveFilterDepth,l.effectiveFilterHeight,l.effectiveFilterWidth]},{type:\"int32\",data:[l.outDepth]},{type:\"int32\",data:[l.outHeight]},{type:\"int32\",data:[l.outWidth]},{type:\"float32\",data:[d]}];return e.runWebGPUProgram(m,[n],a.dtype,f)}var nV={kernelName:Ai,backendName:\"webgpu\",kernelFunc:aue};function iue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s;fm([n,s],\"avgPoolGrad\");let{filterSize:i,strides:p,pad:u}=o,c=w.computePool2DInfo(a.shape,i,p,1,u),l=new ix(c),m=1/(c.filterHeight*c.filterWidth),d=[{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.effectiveFilterHeight-1-c.padInfo.top,c.effectiveFilterWidth-1-c.padInfo.left]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[c.effectiveFilterHeight,c.effectiveFilterWidth]},{type:\"int32\",data:[c.outHeight]},{type:\"int32\",data:[c.outWidth]},{type:\"float32\",data:[m]}];return e.runWebGPUProgram(l,[n],a.dtype,d)}var sV={kernelName:Di,backendName:\"webgpu\",kernelFunc:iue};function uue(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;return Op({a:n,b:s,transposeA:a,transposeB:i,backend:e})}var aV={kernelName:Jo,backendName:\"webgpu\",kernelFunc:uue};var px=class{constructor(t,e){this.variableNames=[\"source\"],this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.rank=e.length,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.start=t,this.uniforms=`start : ${ht(t.length)}, `,this.shaderKey=\"slice\"}getUserCode(){let t=ht(this.rank),e=pue(this.rank),o;return this.start.length===1?o=this.outputShape.map((s,a)=>\"sourceLoc = uniforms.start + coords;\"):o=this.outputShape.map((s,a)=>`sourceLoc.${t0[a]} = uniforms.start.${Mo(a)} + coords.${t0[a]};`),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var sourceLoc : ${t};\n let coords = getCoordsFromIndex(index);\n ${o.join(`\n`)}\n setOutputAtIndex(index, getSource(${e}));\n }\n }\n `}},t0=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"];function pue(r){if(r===1)return\"sourceLoc\";if(r<=6)return t0.slice(0,r).map(t=>`sourceLoc.${t}`).join(\",\");throw Error(`Slicing for rank ${r} is not yet supported`)}function Hs(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,size:a}=o,[i,p]=ct.parseSliceParams(n,s,a);if(ct.assertParamsValid(n,i,p),e.shouldExecuteOnCPU([n])||n.dtype===\"string\"){let l=e.tensorMap.get(n.dataId),m=Dz(l.values,i,p,n.shape,n.dtype);return e.makeTensorInfo(p,n.dtype,m)}if(y.sizeFromShape(p)===0)return e.makeTensorInfo(p,n.dtype,[]);let u=new px(i,p),c=[{type:\"int32\",data:i}];return e.runWebGPUProgram(u,[n],n.dtype,c)}var iV={kernelName:ha,backendName:\"webgpu\",kernelFunc:Hs};var cue=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,crops:a}=o;y.assert(n.shape.length<=4,()=>\"batchToSpaceND for rank > 4 with a WebGPU backend not implemented yet\");let i=s.reduce((b,C)=>b*C),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=[],f=pe({inputs:{x:n},backend:e,attrs:{shape:p}}),h=yr({inputs:{x:f},backend:e,attrs:{perm:u}}),g=pe({inputs:{x:h},backend:e,attrs:{shape:c}}),x=Hs({inputs:{x:g},backend:e,attrs:{begin:l,size:m}});return d.push(f),d.push(h),d.push(g),d.forEach(b=>e.disposeData(b.dataId)),x},uV={kernelName:Js,backendName:\"webgpu\",kernelFunc:cue};var lue=`\n fn bincount_write(index: i32, value: f32) {\n ${Qr(\"&result[index]\",\"value\",\"float32\")}\n }\n`,mue=`\n fn bincount_write(index: i32, value: f32) {\n atomicStore(&result[index], bitcast(value));\n }\n`,Jc=class{constructor(t,e,o=!1){this.outputShape=[],this.variableNames=[\"x\"],this.uniforms=\"binCountSize : i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.hasWeights=!0,this.binaryOutput=!1,this.outputShape=t,this.rank=t.length,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.binaryOutput=o,o&&(this.atomic=!1),this.hasWeights=e,this.hasWeights&&this.variableNames.push(\"w\"),this.shaderKey=`bincount_${this.hasWeights}_${this.binaryOutput}_${this.rank}`}getUserCode(){return`\n ${this.binaryOutput?mue:lue}\n ${G(\"index\")} {\n ${this.rank===1?`if (index < uniforms.xShape) {\n let indexVal = i32(getX(index));\n if (indexVal < uniforms.binCountSize) {\n let value = ${this.binaryOutput?1:this.hasWeights?\"getW(index)\":\"1.\"};\n bincount_write(indexVal, value);\n }\n }`:`let coord = getCoordsFromIndex(index);\n if (coordsInBounds2D(coord, uniforms.xShape)) {\n let indexVal = i32(getX(coord[0], coord[1]));\n if (indexVal < uniforms.binCountSize) {\n let value = ${this.binaryOutput?1:this.hasWeights?\"getW(coord[0], coord[1])\":\"1.\"};\n bincount_write(coord.x * uniforms.binCountSize + indexVal, value);\n }\n }`}\n }\n `}};function due(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a}=o,i=y.sizeFromShape(n.shape),u=y.sizeFromShape(s.shape)>0,c=[a],l=s.dtype,m=kt({backend:e,attrs:{shape:c,value:0,dtype:l}}),d=new Jc([i],u),f=[{type:\"int32\",data:[a]}],h=u?[n,s]:[n];return e.runWebGPUProgram(d,h,l,f,m)}var pV={kernelName:en,backendName:\"webgpu\",kernelFunc:due};var cx=class{constructor(t){this.outputShape=[],this.variableNames=[\"s0\",\"s1\"],this.uniforms=\"s0Size : i32, s1Size : i32, \",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"broadcastArgs\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var s0 = 1.0;\n var s1 = 1.0;\n let indexS0 = index - uniforms.size + uniforms.s0Size;\n let indexS1 = index - uniforms.size + uniforms.s1Size;\n if (indexS0 >= 0) {\n s0 = getS0(indexS0);\n }\n if (indexS1 >= 0) {\n s1 = getS1(indexS1);\n }\n\n if (s0 == 1.0) {\n setOutputAtIndex(index, s1);\n } else if (s1 == 1.0) {\n setOutputAtIndex(index, s0);\n } else if (s0 != s1) {\n setOutputAtIndex(index, uniforms.NAN);\n } else {\n setOutputAtIndex(index, s0);\n }\n }\n }\n `}};function fue(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t;if(e.shouldExecuteOnCPU([o,n])){let c=e.tensorMap.get(o.dataId),l=e.tensorMap.get(n.dataId),m=c.values,d=l.values,f=w.assertAndGetBroadcastShape(Array.from(m),Array.from(d));return e.makeTensorInfo([f.length],\"int32\",Int32Array.from(f))}let s=y.sizeFromShape(o.shape),a=y.sizeFromShape(n.shape),i=Math.max(s,a),p=new cx(i),u=[{type:\"int32\",data:[s]},{type:\"int32\",data:[a]}];return e.runWebGPUProgram(p,[o,n],\"int32\",u)}var cV={kernelName:ea,backendName:\"webgpu\",kernelFunc:fue};var r0=et({opType:fe.NOT_EQUAL,dtype:\"bool\",cpuKernelImpl:Nz}),lV={kernelName:Qn,backendName:\"webgpu\",kernelFunc:r0};function Ni(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.tensorMap.get(o.dataId);return Ft({inputs:{x:n.complexTensorInfos.real},backend:e})}var mV={kernelName:qi,backendName:\"webgpu\",kernelFunc:Ni};function dV(r,t){let e=new Jr(r.shape,Z.TO_INT),o=t.runWebGPUProgram(e,[r],\"int32\");return{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}function o0(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dtype:s}=o;if(s===\"complex64\"){if(n.dtype===\"complex64\")return Ft({inputs:{x:n},backend:e});let a=Gr(n.shape),i=o0({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}}),p=yo({inputs:{real:i,imag:a},backend:e});return a.dispose(),e.disposeData(i.dataId),p}if(n.dtype===\"complex64\"){let a=Ni({inputs:{input:n},backend:e}),i=o0({inputs:{x:a},backend:e,attrs:{dtype:s}});return e.disposeData(a.dataId),i}if(!y.hasEncodingLoss(n.dtype,s)){let a=Ft({inputs:{x:n},backend:e});return{dataId:a.dataId,shape:a.shape,dtype:s}}if(e.shouldExecuteOnCPU([n])){let a=e.tensorMap.get(n.dataId).values,[i,p,u]=az(a,n.shape,n.dtype,s);return e.makeTensorInfo(i,p,u)}if(s===\"int32\")return dV(n,e);if(s===\"bool\"){let a=e.makeTensorInfo([],\"bool\",y.getTypedArrayFromDType(\"bool\",1)),p=r0({inputs:{a:n,b:a},backend:e});return e.disposeData(a.dataId),p}throw new Error(`Error in Cast: failed to cast ${n.dtype} to ${s}`)}var fV={kernelName:bo,backendName:\"webgpu\",kernelFunc:o0};var hue=ye({opType:Z.CEIL,cpuKernelImpl:iz}),hV={kernelName:tn,backendName:\"webgpu\",kernelFunc:hue};var lx=class{constructor(t){this.variableNames=[\"A\"],this.uniforms=\"minVal : f32, maxVal : f32,\",this.workPerThread=4,this.workgroupSize=[64,1,1],this.outputComponent=4,this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.shaderKey=\"clipVec4\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let value = getAByOutputIndex(index);\n var clampedValue = clamp(\n value, vec4(uniforms.minVal), vec4(uniforms.maxVal));\n clampedValue = select(clampedValue, value, isnanVec4(value));\n setOutputAtIndex(index, clampedValue);\n }\n }\n `}};var mx=class{constructor(t){this.variableNames=[\"A\"],this.uniforms=\"minVal : f32, maxVal : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"clip\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let value = getAByOutputIndex(index);\n if (isnan(value)) {\n setOutputAtIndex(index, value);\n return;\n }\n setOutputAtIndex(index, clamp(value, uniforms.minVal, uniforms.maxVal));\n }\n }\n `}};function gue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{clipValueMin:s,clipValueMax:a}=o,i,p=[{type:\"float32\",data:[s]},{type:\"float32\",data:[a]}];return y.sizeFromShape(n.shape)%4===0?i=new lx(n.shape):i=new mx(n.shape),e.runWebGPUProgram(i,[n],n.dtype,p)}var gV={kernelName:Co,backendName:\"webgpu\",kernelFunc:gue};var dx=class{constructor(t){this.outputShape=[],this.variableNames=[\"real\",\"imag\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"complexAbs\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let re = abs(getRealByOutputIndex(index));\n let im = abs(getImagByOutputIndex(index));\n let mx = max(re, im);\n\n // The length function in wgsl may be not underflow-safe on some GPUs.\n // So the safe solution is to ensure underflow-safety in all cases.\n setOutputAtIndex(index, select(mx * length(vec2(1, min(re, im)/mx)), 0.0, mx == 0.0));\n }\n }\n `}};function xV(r,t){return{dataId:t.dataId,dtype:t.dtype,shape:r.shape}}function xue(r){let{inputs:t,backend:e}=r,{x:o}=t,n=e.tensorMap.get(o.dataId),s=new dx(o.shape),a=[xV(o,n.complexTensorInfos.real),xV(o,n.complexTensorInfos.imag)];return e.runWebGPUProgram(s,a,a[0].dtype)}var yV={kernelName:Pi,backendName:\"webgpu\",kernelFunc:xue};var fx=class{constructor(t){this.uniforms=\"\",this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=w.computeOutShape(t,1),this.variableNames=t.map((e,o)=>`T${o}`),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.offsetLength=t.length-1;for(let e=0;e0){t.push(\"if (yC < uniforms.offset0){ setOutputAtCoords(coords.x, coords.y, getT0(yR, yC)); }\");for(let s=1;sNi({inputs:{input:C},backend:e})),h=r.map(C=>Mp({inputs:{input:C},backend:e})),g=el(f,t,e),x=el(h,t,e),b=yo({inputs:{real:g,imag:x},backend:e});return f.forEach(C=>e.disposeData(C.dataId)),h.forEach(C=>e.disposeData(C.dataId)),e.disposeData(g.dataId),e.disposeData(x.dataId),b}let n=e.shouldExecuteOnCPU(r);if(o===\"string\"&&(n=!0),n){let f=r.map(k=>{let E=[-1,y.sizeFromShape(k.shape.slice(t))];return pe({inputs:{x:k},backend:e,attrs:{shape:E}})}),h=f.map(k=>({vals:e.readSync(k.dataId),shape:k.shape})),g=w.computeOutShape(f.map(k=>k.shape),1),x=f[0].shape[0]===1,b=uz(h,g,o,x),C=w.computeOutShape(r.map(k=>k.shape),t),S=e.makeTensorInfo(C,o,b);return f.forEach(k=>e.disposeData(k.dataId)),S}let s=e.device.limits.maxStorageBuffersPerShaderStage-1;if(r.length>s){let f=[];for(let g=0;gf.shape),u=new fx(p),c=[],l=new Array(p.length-1);if(l.length>0){l[0]=p[0][1],c.push({type:\"int32\",data:[l[0]]});for(let f=1;fe.disposeData(f.dataId));let d=pe({inputs:{x:m},backend:e,attrs:{shape:i}});return e.disposeData(m.dataId),d}function yue(r,t,e){let o=w.computeOutShape(r.map(s=>s.shape),t);return{tensors2D:r.map(s=>pe({inputs:{x:s},backend:e,attrs:{shape:[y.sizeFromShape(s.shape.slice(0,t)),y.sizeFromShape(s.shape.slice(t))]}})),outShape:o}}function n0(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o,s=y.parseAxisParam(n,t[0].shape)[0],a=t.map(u=>u.shape);w.assertParamsConsistent(a,s);let i=w.computeOutShape(t.map(u=>u.shape),s);if(y.sizeFromShape(i)===0)return e.makeTensorInfo(i,t[0].dtype,[]);let p=t.filter(u=>y.sizeFromShape(u.shape)>0);return p.length===1?Ft({inputs:{x:p[0]},backend:e}):el(p,s,e)}var CV={kernelName:ta,backendName:\"webgpu\",kernelFunc:n0};function bue(r,t,e,o,n=!1,s=null,a=!1,i=4,p=4,u=4){let c=D=>{switch(D){case 1:return\"resData = f32(x[xIndex]);\";case 3:return\"resData = vec3(x[xIndex], x[xIndex + 1], x[xIndex + 2]);\";case 4:return\"resData = vec4(x[xIndex / 4]);\";default:throw new Error(`innerElementSize ${D} is not supported.`)}},l=D=>{switch(D){case 1:return\"return f32(W[row * uniforms.wShape[3] + col]);\";case 4:return\"return vec4(W[(row * uniforms.wShape[3] + col) / 4]);\";default:throw new Error(`innerElementSize ${D} is not supported.`)}},m=r?`\n let coord = vec4(batch, xRow, xCol, xCh);\n `:`\n let coord = vec4(batch, xCh, xRow, xCol);\n `,d=r?`\n let coords = vec4(\n batch,\n row / outWidth,\n row % outWidth,\n col);\n `:`\n let coords = vec4(\n batch,\n row,\n col / outWidth,\n col % outWidth);\n `,f=r?\"uniforms.xShape[1]\":\"uniforms.xShape[2]\",h=r?\"uniforms.xShape[2]\":\"uniforms.xShape[3]\",g=r?\"row\":\"col\",x=r?\"col\":\"row\",b=`\n let inChannels = uniforms.wShape[2];\n let outWidth = ${r?\"uniforms.outShape[2]\":\"uniforms.outShape[3]\"};\n let outRow = ${g} / outWidth;\n let outCol = ${g} % outWidth;\n\n let WRow = ${x} / (uniforms.filterDims[1] * inChannels);\n let WCol = ${x} / inChannels % uniforms.filterDims[1];\n let xRow = outRow * uniforms.strides[0] + uniforms.dilations[0] * WRow - uniforms.pads[0];\n let xCol = outCol * uniforms.strides[1] + uniforms.dilations[1] * WCol - uniforms.pads[1];\n let xCh = ${x} % inChannels;\n var resData = ${Ae(i)}(0.0);\n // The bounds checking is always needed since we use it to pad zero for\n // the 'same' padding type.\n if (xRow >= 0 && xRow < ${f} && xCol >= 0 && xCol < ${h}) {\n ${m}\n let xIndex = getIndexFromCoords4D(coord, uniforms.xShape);\n ${c(i)}\n }\n return resData;`,C=r?t&&o?`\n ${b}`:`\n if (row < uniforms.dimAOuter && col < uniforms.dimInner) {\n ${b}\n }\n return ${Ae(i)}(0.0);`:o&&e?`\n ${b}`:`\n if (row < uniforms.dimInner && col < uniforms.dimBOuter) {\n ${b}\n }\n return ${Ae(i)}(0.0);`,S=`${l(p)}`,k=Ae(u),_=r?Ae(i):Ae(p),E=r?Ae(p):Ae(i);return`\n ${fr(s,a,u===4,4)}\n fn mm_readA(batch: i32, row : i32, col : i32) -> ${_} {\n ${r?C:S}\n }\n\n fn mm_readB(batch: i32, row : i32, col : i32) -> ${E} {\n ${r?S:C}\n }\n\n fn mm_write(batch: i32, row : i32, col : i32, valueIn : ${k}) {\n if (row < uniforms.dimAOuter && col < uniforms.dimBOuter)\n {\n var value = valueIn;\n let outWidth = ${r?\"uniforms.outShape[2]\":\"uniforms.outShape[3]\"};\n ${d}\n ${Zr(n,s)}\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], value);\n }\n }`}var hx=class{constructor(t,e,o,n,s=!1,a=null,i=!1,p=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims : vec2, pads : vec2, strides : vec2, dilations : vec2, dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.outputShape=t.outShape,this.isChannelsLast=t.dataFormat===\"channelsLast\",this.isVec4=((t.inChannels%4===0||t.inChannels%3===0)&&this.isChannelsLast||t.outWidth%4===0&&!this.isChannelsLast)&&t.outChannels%4===0,this.dispatchLayout=this.isChannelsLast?{x:[3],y:[1,2],z:[0]}:{x:[2,3],y:[1],z:[0]},this.workgroupSize=lm(this.dispatchLayout,this.outputShape,this.isVec4),this.elementsPerThread=mm(this.dispatchLayout,this.outputShape,this.isVec4),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,this.elementsPerThread),this.isVec4?(this.outputComponent=4,this.isChannelsLast&&t.inChannels%4!==0?(this.innerElementSize=3,this.variableComponents=[1,4]):(this.innerElementSize=4,this.variableComponents=[4,4]),s&&(this.variableNames.push(\"bias\"),this.variableComponents.push(4)),i&&(this.variableNames.push(\"preluActivationWeights\"),this.variableComponents.push(4))):(this.innerElementSize=this.elementsPerThread[0],s&&this.variableNames.push(\"bias\"),i&&this.variableNames.push(\"preluActivationWeights\")),this.sequentialAccessByThreads=p,this.addBias=s,this.activation=a,this.hasPreluActivationWeights=i,this.tileAOuter=this.workgroupSize[1]*this.elementsPerThread[1],this.tileBOuter=this.workgroupSize[0]*this.elementsPerThread[0],this.tileInner=Math.max(this.workgroupSize[0]*this.innerElementSize,this.workgroupSize[1]),this.fitAOuter=e%this.tileAOuter===0,this.fitBOuter=o%this.tileBOuter===0,this.fitInner=n%this.tileInner===0,this.shaderKey=`conv2DMM_${this.elementsPerThread}_${this.activation}}_${this.fitAOuter}_${this.fitBOuter}_${this.fitInner}_${this.isVec4}_${this.innerElementSize}_${this.isChannelsLast}_${this.sequentialAccessByThreads}`}getUserCode(){let t=this.isVec4?Fp(this.elementsPerThread,this.workgroupSize,!this.isChannelsLast,this.tileInner):Pp(this.elementsPerThread,this.workgroupSize,!this.isChannelsLast,this.tileInner,!1,null,this.sequentialAccessByThreads),e=this.isVec4?[this.innerElementSize,4,4]:[1,1,1];return`\n ${bue(this.isChannelsLast,this.fitAOuter,this.fitBOuter,this.fitInner,this.addBias,this.activation,this.hasPreluActivationWeights,e[0],e[1],e[2])}\n ${t}\n `}};var gx=class{constructor(t,e=!1,o=null,n=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2,\",this.workgroupSize=[4,4,8],this.outputShape=t.outShape,this.isChannelsLast=t.dataFormat===\"channelsLast\",this.dispatchLayout=this.isChannelsLast?{x:[2],y:[1],z:[0,3]}:{x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.addBias=e,this.activation=o,this.hasPreluActivationWeights=n,e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),this.shaderKey=`conv2dnaive_${this.activation}_${this.isChannelsLast}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights,!1,4)}\n fn readInp(batch : i32, row : i32, col : i32, chan : i32) -> f32{\n let coords = vec4(batch, row, col, chan);\n if (coordsInBounds4D(coords, uniforms.xShape)) {\n return getX(batch, row, col, chan);\n } else {\n return 0.0;\n }\n }\n fn readFilt(row : i32, col : i32, xChannel : i32, outChannel : i32) -> f32{\n let coords = vec4(row, col, xChannel, outChannel);\n if(coordsInBounds4D(coords, uniforms.wShape)) {\n return getW(row, col, xChannel, outChannel);\n } else {\n return 0.0;\n }\n }\n fn writeResult(batch : i32, row : i32, col : i32, chan : i32, valueIn : f32) {\n let coords = ${this.isChannelsLast?\"vec4(batch, row, col, chan);\":\"vec4(batch, chan, row, col);\"}\n if (coordsInBounds4D(coords, uniforms.outShape)) {\n var value = valueIn;\n ${Zr(this.addBias,this.activation)}\n setOutputAtCoords(coords.x, coords.y, coords.z, coords.w, value);\n }\n }\n ${G(\"index\")} {\n let coords = getOutputCoords();\n let batch = coords[0];\n let outChannel = ${this.isChannelsLast?\"coords[3];\":\"coords[1];\"}\n let outRow = ${this.isChannelsLast?\"coords[1];\":\"coords[2];\"}\n let outCol = ${this.isChannelsLast?\"coords[2];\":\"coords[3];\"}\n var acc : f32 = 0.0;\n for (var row = 0; row < uniforms.filterDims[0]; row = row + 1) {\n for (var col = 0; col < uniforms.filterDims[1]; col = col + 1) {\n let xRow = outRow * uniforms.strides[0] + uniforms.dilations[0] * row - uniforms.pads[0];\n let xCol = outCol * uniforms.strides[1] + uniforms.dilations[1] * col - uniforms.pads[1];\n for (var xChannel = 0; xChannel < ${this.isChannelsLast?\"uniforms.xShape[3];\":\"uniforms.xShape[1];\"} xChannel = xChannel + 1) {\n ${this.isChannelsLast?\"let v = readInp(batch, xRow, xCol, xChannel);\":\"let v = readInp(batch, xChannel, xRow, xCol);\"}\n let f = readFilt(row, col, xChannel, outChannel);\n acc = acc + v * f;\n }\n }\n }\n writeResult(batch, outRow, outCol, outChannel, acc);\n }\n `}};var xx=class{constructor(t,e){this.variableNames=[\"x\"],this.uniforms=`pads : vec2, strides : vec2, dilations : vec2, outWidth : i32, itemsPerBlockRow : i32,\n inChannels : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.isChannelsLast=e,this.shaderKey=`im2col_${this.isChannelsLast}`}getUserCode(){let t=this.isChannelsLast?1:2,e=this.isChannelsLast?2:3,o=this.isChannelsLast?\"coords[1]\":\"coords[2]\",n=this.isChannelsLast?\"coords[2]\":\"coords[1]\",s=this.isChannelsLast?\"getX(batch, xRow, xCol, ch)\":\"getX(batch, ch, xRow, xCol)\";return`\n ${G(\"index\")} {\n let coords = getCoordsFromIndex(index);\n if(index < uniforms.size) {\n let batch = coords[0];\n let row = ${o};\n let col = ${n};\n let offsetY = (row / uniforms.outWidth) * uniforms.strides[0] - uniforms.pads[0];\n let xRow = offsetY + uniforms.dilations[0] * (col / uniforms.itemsPerBlockRow);\n var value = 0.0;\n if(xRow < uniforms.xShape[${t}] && xRow >= 0) {\n let offsetX = (row % uniforms.outWidth) * uniforms.strides[1] -\n uniforms.pads[1];\n let xCol = offsetX + uniforms.dilations[1] * ((col %\n uniforms.itemsPerBlockRow) / uniforms.inChannels);\n let ch = col % uniforms.inChannels;\n if(xCol < uniforms.xShape[${e}] && xCol >= 0) {\n value = ${s};\n }\n }\n setOutputAtIndex(index, value);\n }\n }\n `}};function yx(r,t){let e=r.length;return e>=3?t?[...r.slice(0,-3),r[e-3]*r[e-2],r[e-1]]:[...r.slice(0,-3),r[e-3],r[e-2]*r[e-1]]:!t&&e===1&&r[0]>1?[r[0],1]:null}function Cue({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let p=e.dataFormat===\"channelsLast\",u=!p,c=!1,l=p&&e.filterHeight===e.inHeight&&e.filterWidth===e.inWidth&&e.padInfo.type===\"VALID\",m=[],d,f;if(l){let x=e.inHeight*e.inWidth*e.inChannels;d=pe({inputs:{x:r},backend:o,attrs:{shape:[1,e.batchSize,x]}}),f=pe({inputs:{x:t},backend:o,attrs:{shape:[1,x,e.outChannels]}})}else d=pe({inputs:{x:r},backend:o,attrs:{shape:p?[e.batchSize,e.inHeight*e.inWidth,e.inChannels]:[e.batchSize,e.inChannels,e.inHeight*e.inWidth]}}),f=pe({inputs:{x:t},backend:o,attrs:{shape:[1,e.inChannels,e.outChannels]}});if(m.push(d),m.push(f),s!=null){let x=yx(s.shape,p);x!=null&&(s=pe({inputs:{x:s},backend:o,attrs:{shape:x}}),m.push(s))}if(n!=null){let x=yx(n.shape,p);x!=null&&(n=pe({inputs:{x:n},backend:o,attrs:{shape:x}}),m.push(n))}let h=Op({a:p?d:f,b:p?f:d,transposeA:u,transposeB:c,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a}),g=pe({inputs:{x:h},backend:o,attrs:{shape:e.outShape}});m.push(h);for(let x of m)o.disposeData(x.dataId);return g}function wue({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let{filterWidth:p,filterHeight:u,inChannels:c,strideWidth:l,strideHeight:m,padInfo:d,outWidth:f,outHeight:h,dilationWidth:g,dilationHeight:x,dataFormat:b}=e,C=b===\"channelsLast\",S=p*u*c,k=h*f,_=C?[e.batchSize,k,S]:[e.batchSize,S,k],E=new xx(_,C),R=[{type:\"int32\",data:[d.top,d.left]},{type:\"int32\",data:[m,l]},{type:\"int32\",data:[x,g]},{type:\"int32\",data:[f]},{type:\"int32\",data:[c*p]},{type:\"int32\",data:[c]}],D=o.runWebGPUProgram(E,[r],r.dtype,R),P=[];P.push(D);let O=pe({inputs:{x:t},backend:o,attrs:{shape:[1,S,-1]}});if(P.push(O),s!=null){let U=yx(s.shape,C);U!=null&&(s=pe({inputs:{x:s},backend:o,attrs:{shape:U}}),P.push(s))}if(n!=null){let U=yx(n.shape,C);U!=null&&(n=pe({inputs:{x:n},backend:o,attrs:{shape:U}}),P.push(n))}let B=Op({a:C?D:O,b:C?O:D,transposeA:!C,transposeB:!1,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a}),z=pe({inputs:{x:B},backend:o,attrs:{shape:e.outShape}});P.push(B);for(let U of P)o.disposeData(U.dataId);return z}function bx({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let p=n!=null,u=s!=null,c=e.dataFormat===\"channelsLast\",l=c&&e.filterHeight===e.inHeight&&e.filterWidth===e.inWidth&&e.padInfo.type===\"VALID\",m=A().getBool(\"WEBGPU_USE_NAIVE_CONV2D_DEBUG\");if(!m&&(l||e.filterHeight===1&&e.filterWidth===1&&e.dilationHeight===1&&e.dilationWidth===1&&e.strideHeight===1&&e.strideWidth===1&&(e.padInfo.type===\"SAME\"||e.padInfo.type===\"VALID\")))return Cue({x:r,filter:t,convInfo:e,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a});let d=A().getNumber(\"WEBGPU_THRESHOLD_TO_INCREASE_WORKGROUPS_FOR_MATMUL\"),f=d>-1?d:o.thresholdToIncreaseWorkgroups,h=e.batchSize*Math.ceil(e.outHeight*e.outWidth/32)*Math.ceil(e.outChannels/32);if(A().getBool(\"WEBGPU_CONV_SEPARATE_IM2COL_SHADER\")||h<=f)return wue({x:r,filter:t,convInfo:e,backend:o,bias:n,preluActivationWeights:s,leakyreluAlpha:a,activation:i});let g,x=[e.padInfo.top,e.padInfo.left],b=[{type:\"int32\",data:[e.filterHeight,e.filterWidth]},{type:\"int32\",data:[...x]},{type:\"int32\",data:[e.strideHeight,e.strideWidth]},{type:\"int32\",data:[e.dilationHeight,e.dilationWidth]}];if(m)g=new gx(e,p,i,u);else{let _=c?e.outHeight*e.outWidth:e.outChannels,E=c?e.outChannels:e.outHeight*e.outWidth,R=e.filterHeight*e.filterWidth*e.inChannels;b.push({type:\"int32\",data:[_]},{type:\"int32\",data:[E]},{type:\"int32\",data:[R]});let D=o.adapterInfo.isIntel();g=new hx(e,_,E,R,p,i,u,D)}let C=[],S=[r,t];p&&(!c&&n.shape.length===1&&(n=pe({inputs:{x:n},backend:o,attrs:{shape:[n.shape[0],1,1]}}),C.push(n)),S.push(n)),u&&(!c&&s.shape.length===1&&(s=pe({inputs:{x:s},backend:o,attrs:{shape:[s.shape[0],1,1]}}),C.push(s)),S.push(s)),i===\"leakyrelu\"&&(b.push({type:\"float32\",data:[a]}),g.uniforms+=\" alpha : f32,\");let k=o.runWebGPUProgram(g,S,r.dtype,b);for(let _ of C)o.disposeData(_.dataId);return k}function Sue(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=e,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,s.shape,a,u,i,c,!1,l);return bx({x:n,filter:s,convInfo:m,backend:o})}var wV={kernelName:rn,backendName:\"webgpu\",kernelFunc:Sue};var Cx=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.uniforms=\"filterDims : vec2, pads : vec2, strides : vec2, outBackprop : vec4,\",this.workgroupSize=[64,1,1],this.size=!1,this.isVec4=!1,this.workPerThread=1,this.outputShape=t.inShape,this.isChannelsLast=t.dataFormat===\"channelsLast\",this.isVec4=this.isChannelsLast&&t.outChannels%4===0&&t.inChannels%4===0,this.isVec4?(this.workPerThread=2,this.outputComponent=4,this.workgroupSize=[4,4,4],this.dispatchLayout={x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[4,this.workPerThread,1])):(this.size=!0,this.workPerThread=1,this.workgroupSize=[64,1,1],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize)),this.shaderKey=`conv2DDerInput_${this.isChannelsLast}_${this.isVec4}_${this.workPerThread}`}getUserCode(){let t=this.isChannelsLast?1:2,e=this.isChannelsLast?2:3,o=this.isChannelsLast?3:1,n=`\n ${G()} {\n let batch = i32(globalId.z) / uniforms.outShape[1];\n let r = i32(globalId.z) % uniforms.outShape[1];\n let c = i32(globalId.y) * ${this.workPerThread};\n let d1 = i32(globalId.x) * 4;\n\n let dyCorner = vec2(r, c) - uniforms.pads;\n\n // Convolve dy(?, ?, d2) with w(:, :, d1, d2) to compute dx(xR, xC, d1).\n // ? = to be determined. : = across all values in that axis.\n var dotProd: array, ${this.workPerThread}>;\n for (var i = 0; i < ${this.workPerThread}; i++) {\n dotProd[i] = vec4(0.0);\n }\n for (var wR = 0; wR < uniforms.filterDims.x; wR = wR + 1) {\n let dyR = f32(dyCorner.x + wR) / f32(uniforms.strides.x);\n let wRPerm = uniforms.filterDims.x - 1 - wR;\n if (dyR < 0.0 || dyR >= f32(uniforms.outBackprop[1]) ||\n fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims.y; wC = wC + 1) {\n let dyC = f32(dyCorner.y + wC) / f32(uniforms.strides.y);\n let dyC2 = f32(dyCorner.y + 1 + wC) / f32(uniforms.strides.y);\n let wCPerm = uniforms.filterDims.y - 1 - wC;\n var bDyCVal = true;\n var bDyCVal2 = true;\n if (dyC < 0.0 || dyC >= f32(uniforms.outBackprop[2]) ||\n fract(dyC) > 0.0) {\n bDyCVal = false;\n }\n if (dyC2 < 0.0 || dyC2 >= f32(uniforms.outBackprop[2]) ||\n fract(dyC2) > 0.0) {\n bDyCVal2 = false;\n }\n\n let idyC = i32(dyC);\n let idyC2 = i32(dyC2);\n if (bDyCVal && bDyCVal2) {\n let d2Length = uniforms.outBackprop[3];\n for (var d2 = 0; d2 < d2Length; d2 = d2 + 4) {\n let wValue0 = getW(wRPerm, wCPerm, d1, d2);\n let wValue1 = getW(wRPerm, wCPerm, d1 + 1, d2);\n let wValue2 = getW(wRPerm, wCPerm, d1 + 2, d2);\n let wValue3 = getW(wRPerm, wCPerm, d1 + 3, d2);\n var xValue = getDy(batch, idyR, idyC, d2);\n let tmpval = vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n dotProd[0] = dotProd[0] + tmpval;\n xValue = getDy(batch, idyR, idyC2, d2);\n dotProd[1] = dotProd[1] + vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n }\n } else if (bDyCVal) {\n let d2Length = uniforms.outBackprop[3];\n for (var d2 = 0; d2 < d2Length; d2 = d2 + 4) {\n let wValue0 = getW(wRPerm, wCPerm, d1, d2);\n let wValue1 = getW(wRPerm, wCPerm, d1 + 1, d2);\n let wValue2 = getW(wRPerm, wCPerm, d1 + 2, d2);\n let wValue3 = getW(wRPerm, wCPerm, d1 + 3, d2);\n var xValue = getDy(batch, idyR, idyC, d2);\n let tmpval = vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n dotProd[0] = dotProd[0] + tmpval;\n }\n } else if (bDyCVal2) {\n let d2Length = uniforms.outBackprop[3];\n for (var d2 = 0; d2 < d2Length; d2 = d2 + 4) {\n let wValue0 = getW(wRPerm, wCPerm, d1, d2);\n let wValue1 = getW(wRPerm, wCPerm, d1 + 1, d2);\n let wValue2 = getW(wRPerm, wCPerm, d1 + 2, d2);\n let wValue3 = getW(wRPerm, wCPerm, d1 + 3, d2);\n var xValue = getDy(batch, idyR, idyC2, d2);\n let tmpval = vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n dotProd[1] = dotProd[1] + tmpval;\n }\n }\n }\n }\n\n for (var i = 0; i < ${this.workPerThread}; i = i + 1) {\n let coords = vec4(batch, r, c + i, d1);\n if (coordsInBounds4D(coords, uniforms.outShape)) {\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], dotProd[i]);\n }\n }\n }\n `;return this.isVec4?`\n ${n}\n `:`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d1 = coords[${o}];\n\n let dyCorner = vec2(coords[${t}], coords[${e}]) - uniforms.pads;\n let dyRCorner = dyCorner.x;\n let dyCCorner = dyCorner.y;\n\n // Convolve dy(?, ?, d2) with w(:, :, d1, d2) to compute dx(xR, xC, d1).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var wR = 0; wR < uniforms.filterDims.x; wR = wR + 1) {\n let dyR = (f32(dyRCorner) + f32(wR)) / f32(uniforms.strides.x);\n let wRPerm = uniforms.filterDims.x - 1 - wR;\n if (dyR < 0.0 || dyR >= f32(uniforms.outBackprop[1]) || fract(dyR) > 0.0 ||\n wRPerm < 0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims.y; wC = wC + 1) {\n let dyC = (f32(dyCCorner) + f32(wC)) / f32(uniforms.strides.y);\n let wCPerm = uniforms.filterDims.y - 1 - wC;\n if (dyC < 0.0 || dyC >= f32(uniforms.outBackprop[2]) ||\n fract(dyC) > 0.0 || wCPerm < 0) {\n continue;\n }\n let idyC = i32(dyC);\n\n for (var d2 = 0; d2 < uniforms.outBackprop[3]; d2 = d2 + 1) {\n let xValue = ${this.isChannelsLast?\"getDy(batch, idyR, idyC, d2)\":\"getDy(batch, d2, idyR, idyC)\"};\n let wValue = getW(wRPerm, wCPerm, d1, d2);\n dotProd = dotProd + xValue * wValue;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},wx=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.uniforms=\"pads : vec2, strides : vec2, batchSize : i32, outHeight : i32, outWidth : i32, inHeight : i32, inWidth : i32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.isChannelsLast=t.dataFormat===\"channelsLast\",this.shaderKey=`conv2DDerFilter_${this.isChannelsLast}`}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let wR = coords[0];\n let wC = coords[1];\n let d1 = coords[2];\n let d2 = coords[3];\n\n // Convolve x(?, ?, d1) with dy(:, :, d2) to get dw(wR, wC, d1, d2).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var b = 0; b < uniforms.batchSize; b = b + 1) {\n for (var yR = 0; yR < uniforms.outHeight; yR = yR + 1) {\n let xR = wR + yR * uniforms.strides[0] - uniforms.pads[0];\n if (xR < 0 || xR >= uniforms.inHeight) {\n continue;\n }\n\n for (var yC = 0; yC < uniforms.outWidth; yC = yC + 1) {\n let xC = wC + yC * uniforms.strides[1] - uniforms.pads[1];\n\n if (xC < 0 || xC >= uniforms.inWidth) {\n continue;\n }\n\n if (${this.isChannelsLast}) {\n let dyValue = getDy(b, yR, yC, d2);\n let xValue = getX(b, xR, xC, d1);\n dotProd = dotProd + xValue * dyValue;\n } else {\n let dyValue = getDy(b, d2, yR, yC);\n let xValue = getX(b, d1, xR, xC);\n dotProd = dotProd + xValue * dyValue;\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Sx=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.uniforms=`pads : vec3, strides : vec3, batchSize : i32, outDepth : i32,\n outHeight : i32, outWidth : i32, inDepth : i32, inHeight : i32, inWidth : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"conv3DDerFilter\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let wF = coords.x;\n let wR = coords.y;\n let wC = coords.z;\n let d1 = coords.w;\n let d2 = coords.u;\n\n var dotProd = 0.0;\n for (var b = 0; b < uniforms.batchSize; b++) {\n for (var yF = 0; yF < uniforms.outDepth; yF++) {\n let xF = wF + yF * uniforms.strides[0] - uniforms.pads[0];\n if (xF < 0 || xF >= uniforms.inDepth) {\n continue;\n }\n\n for (var yR = 0; yR < uniforms.outHeight; yR++) {\n let xR = wR + yR * uniforms.strides[1] - uniforms.pads[1];\n if (xR < 0 || xR >= uniforms.inHeight) {\n continue;\n }\n\n for (var yC = 0; yC < uniforms.outWidth; yC++) {\n let xC = wC + yC * uniforms.strides[2] - uniforms.pads[2];\n if (xC < 0 || xC >= uniforms.inWidth) {\n continue;\n }\n\n let dyValue = getDy(b, yF, yR, yC, d2);\n let xValue = getX(b, xF, xR, xC, d1);\n dotProd += xValue * dyValue;\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Ix=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.uniforms=`filterDims : vec3, pads : vec3, strides : vec3,\n outDepth : i32, outHeight : i32, outWidth : i32, outChannels : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"conv3DDerInput\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let d1 = coords.u;\n\n let dyCorner = vec3(coords.y, coords.z, coords.w) - uniforms.pads;\n let dyFCorner = dyCorner.x;\n let dyRCorner = dyCorner.y;\n let dyCCorner = dyCorner.z;\n\n var dotProd = 0.0;\n for (var wF = 0; wF < uniforms.filterDims[0]; wF++) {\n let dyF = f32(dyFCorner + wF) / f32(uniforms.strides[0]);\n if (dyF < 0.0 || dyF >= f32(uniforms.outDepth) || fract(dyF) > 0.0) {\n continue;\n }\n let idyF = i32(dyF);\n\n let wFPerm = uniforms.filterDims[0] - 1 - wF;\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[1]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n let wRPerm = uniforms.filterDims[1] - 1 - wR;\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[2]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let wCPerm = uniforms.filterDims[2] - 1 - wC;\n\n for (var d2 = 0; d2 < uniforms.outChannels; d2++) {\n let xValue = getDy(batch, idyF, idyR, idyC, d2);\n let wValue = getW(wFPerm, wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function Iue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,dataFormat:p,dimRoundingMode:u,filterShape:c}=o,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,c,a,1,i,u,!1,l),d=new wx(m),f=[{type:\"int32\",data:[m.padInfo.top,m.padInfo.left]},{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.batchSize]},{type:\"int32\",data:[m.outHeight]},{type:\"int32\",data:[m.outWidth]},{type:\"int32\",data:[m.inHeight]},{type:\"int32\",data:[m.inWidth]}];return e.runWebGPUProgram(d,[n,s],n.dtype,f)}var SV={kernelName:Oi,backendName:\"webgpu\",kernelFunc:Iue};function vue(r=4){let t=s=>{switch(s){case 1:return\"return W[getIndexFromCoords4D(coord, uniforms.wShape)];\";case 4:return`\n let coord1 = vec4(coordX, coordY, col + 1, rowInner);\n let coord2 = vec4(coordX, coordY, col + 2, rowInner);\n let coord3 = vec4(coordX, coordY, col + 3, rowInner);\n let v0 = W[getIndexFromCoords4D(coord, uniforms.wShape)];\n let v1 = W[getIndexFromCoords4D(coord1, uniforms.wShape)];\n let v2 = W[getIndexFromCoords4D(coord2, uniforms.wShape)];\n let v3 = W[getIndexFromCoords4D(coord3, uniforms.wShape)];\n return vec4(v0, v1, v2, v3);\n `;default:throw new Error(`innerElementSize ${s} is not supported.`)}},o=`if (row < uniforms.dimAOuter && col < uniforms.dimInner) {\n ${`\n let outRow = row / uniforms.outShape[2];\n let outCol = row % uniforms.outShape[2];\n\n let WRow = col / (uniforms.filterDims[1] * uniforms.outBackprop[3]);\n let WCol = col / uniforms.outBackprop[3] % uniforms.filterDims[1];\n let xR = f32(outRow - uniforms.pads[0] + WRow) / f32(uniforms.strides[0]);\n let xC = f32(outCol - uniforms.pads[1] + WCol) / f32(uniforms.strides[1]);\n if (xR < 0.0 || xR >= f32(uniforms.outBackprop[1]) || fract(xR) > 0.0) {\n return ${Ae(r)}(0.0);\n }\n if (xC < 0.0 || xC >= f32(uniforms.outBackprop[2]) || fract(xC) > 0.0) {\n return ${Ae(r)}(0.0);\n }\n let coord = vec4(\n batch,\n i32(xR),\n i32(xC),\n col % uniforms.outBackprop[3]);\n return x[getIndexFromCoords4D(coord, uniforms.xShape)/${r}];`}\n }\n return ${Ae(r)}(0.0);`;return`\n fn mm_readA(batch: i32, row : i32, col : i32) -> ${Ae(r)} {\n ${o}\n }\n\n fn mm_readB(batch: i32, row : i32, col : i32) -> ${Ae(r)} {\n let coordX = uniforms.filterDims.x - 1 -\n row / (uniforms.filterDims[1] * uniforms.outBackprop[3]);\n let coordY = uniforms.filterDims.y - 1 -\n (row / uniforms.outBackprop[3]) % uniforms.filterDims[1];\n if (row < uniforms.dimInner && col < uniforms.dimBOuter &&\n coordX >= 0 && coordY >= 0) {\n let rowInner = row % uniforms.outBackprop[3];\n let coord = vec4(coordX, coordY, col, rowInner);\n ${t(r)}\n }\n return ${Ae(r)}(0.0);\n }\n\n fn mm_write(batch: i32, row : i32, col : i32, valueInput : ${Ae(r)}) {\n if (row < uniforms.dimAOuter && col < uniforms.dimBOuter) {\n var value = valueInput;\n let outCoord = vec4(\n batch,\n row / uniforms.outShape[2],\n row % uniforms.outShape[2],\n col);\n result[getIndexFromCoords4D(outCoord, uniforms.outShape)/${r}] = value;\n }\n }`}var vx=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims : vec2, pads : vec2, strides : vec2, outBackprop : vec4, dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.outputShape=t.inShape,y.assert(t.dataFormat===\"channelsLast\",()=>\"TODO: NCHW is unimplemented\"),this.isVec4=t.inChannels%4===0&&t.outChannels%4===0,this.dispatchLayout={x:[3],y:[1,2],z:[0]},this.workgroupSize=lm(this.dispatchLayout,this.outputShape,this.isVec4),this.elementsPerThread=mm(this.dispatchLayout,this.outputShape,this.isVec4),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,this.elementsPerThread),this.isVec4&&(this.outputComponent=4,this.variableComponents=[4,1]),this.shaderKey=`conv2DDerInputMM_${this.isVec4}_${this.elementsPerThread}`}getUserCode(){let t=this.isVec4?Fp(this.elementsPerThread,this.workgroupSize):Pp(this.elementsPerThread,this.workgroupSize);return`\n ${vue(this.isVec4?4:1)}\n ${t}\n `}};function kue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{inputShape:a,strides:i,pad:p,dataFormat:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(u),m=w.computeConv2DInfo(a,s.shape,i,1,p,c,!1,l),d=[{type:\"int32\",data:[m.filterHeight,m.filterWidth]},{type:\"int32\",data:[m.filterHeight-1-m.padInfo.top,m.filterWidth-1-m.padInfo.left]},{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.batchSize,m.outHeight,m.outWidth,m.outChannels]}],f;if(A().getBool(\"WEBGPU_USE_NAIVE_CONV2D_TRANSPOSE\")||m.dataFormat!==\"channelsLast\")f=new Cx(m);else{f=new vx(m);let h=m.inHeight*m.inWidth,g=m.inChannels,x=m.filterHeight*m.filterWidth*m.outChannels;d.push({type:\"uint32\",data:[h]},{type:\"uint32\",data:[g]},{type:\"uint32\",data:[x]})}return e.runWebGPUProgram(f,[n,s],\"float32\",d)}var IV={kernelName:on,backendName:\"webgpu\",kernelFunc:kue};var kx=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims: vec3, pads: vec3, strides: vec3, dilations: vec3,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"conv3dnaive\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let batch = coords.x;\n let d2 = coords.u;\n\n let xFRCCorner = vec3(coords.y, coords.z, coords.w) * uniforms.strides - uniforms.pads;\n let xFCorner = xFRCCorner.x;\n let xRCorner = xFRCCorner.y;\n let xCCorner = xFRCCorner.z;\n\n let inputDepthNearestVec4 = (uniforms.xShape.u / 4) * 4;\n let inputDepthVec4Remainder = uniforms.xShape.u % 4;\n\n var dotProd = 0.0;\n for (var wF = 0; wF < uniforms.filterDims[0]; wF++) {\n let xF = xFCorner + wF * uniforms.dilations[0];\n if (xF < 0 || xF >= uniforms.xShape.y) {\n continue;\n }\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let xR = xRCorner + wR * uniforms.dilations[1];\n if (xR < 0 || xR >= uniforms.xShape.z) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let xC = xCCorner + wC * uniforms.dilations[2];\n if (xC < 0 || xC >= uniforms.xShape.w) {\n continue;\n }\n\n for (var d1 = 0; d1 < inputDepthNearestVec4; d1 += 4) {\n let xValues = vec4(\n getX(batch, xF, xR, xC, d1),\n getX(batch, xF, xR, xC, d1 + 1),\n getX(batch, xF, xR, xC, d1 + 2),\n getX(batch, xF, xR, xC, d1 + 3)\n );\n let wValues = vec4(\n getW(wF, wR, wC, d1, d2),\n getW(wF, wR, wC, d1 + 1, d2),\n getW(wF, wR, wC, d1 + 2, d2),\n getW(wF, wR, wC, d1 + 3, d2)\n );\n\n dotProd += dot(xValues, wValues);\n }\n\n if (inputDepthVec4Remainder == 1) {\n dotProd += getX(batch, xF, xR, xC, inputDepthNearestVec4) *\n getW(wF, wR, wC, inputDepthNearestVec4, d2);\n } else if (inputDepthVec4Remainder == 2) {\n let xValues = vec2(\n getX(batch, xF, xR, xC, inputDepthNearestVec4),\n getX(batch, xF, xR, xC, inputDepthNearestVec4 + 1)\n );\n let wValues = vec2(\n getW(wF, wR, wC, inputDepthNearestVec4, d2),\n getW(wF, wR, wC, inputDepthNearestVec4 + 1, d2)\n );\n dotProd += dot(xValues, wValues);\n } else if (inputDepthVec4Remainder == 3) {\n let xValues = vec3(\n getX(batch, xF, xR, xC, inputDepthNearestVec4),\n getX(batch, xF, xR, xC, inputDepthNearestVec4 + 1),\n getX(batch, xF, xR, xC, inputDepthNearestVec4 + 2)\n );\n let wValues = vec3(\n getW(wF, wR, wC, inputDepthNearestVec4, d2),\n getW(wF, wR, wC, inputDepthNearestVec4 + 1, d2),\n getW(wF, wR, wC, inputDepthNearestVec4 + 2, d2)\n );\n dotProd += dot(xValues, wValues);\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }`}};function Nue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeConv3DInfo(n.shape,s.shape,a,p,i),c=[u.padInfo.front,u.padInfo.top,u.padInfo.left],l=[{type:\"int32\",data:[u.filterDepth,u.filterHeight,u.filterWidth]},{type:\"int32\",data:[...c]},{type:\"int32\",data:[u.strideDepth,u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.dilationDepth,u.dilationHeight,u.dilationWidth]}],m=new kx(u),d=dt(n.dtype,s.dtype);return e.runWebGPUProgram(m,[n,s],d,l)}var vV={kernelName:nn,backendName:\"webgpu\",kernelFunc:Nue};function Tue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,filterShape:p}=o,u=w.computeConv3DInfo(n.shape,p,a,1,i),c=new Sx(u),l=[{type:\"int32\",data:[u.padInfo.front,u.padInfo.top,u.padInfo.left]},{type:\"int32\",data:[u.strideDepth,u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.batchSize]},{type:\"int32\",data:[u.outDepth]},{type:\"int32\",data:[u.outHeight]},{type:\"int32\",data:[u.outWidth]},{type:\"int32\",data:[u.inDepth]},{type:\"int32\",data:[u.inHeight]},{type:\"int32\",data:[u.inWidth]}];return e.runWebGPUProgram(c,[n,s],s.dtype,l)}var kV={kernelName:Xa,backendName:\"webgpu\",kernelFunc:Tue};function _ue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{strides:a,pad:i,inputShape:p}=o,u=w.computeConv3DInfo(p,s.shape,a,1,i),c=new Ix(u),l=[{type:\"int32\",data:[u.filterDepth,u.filterHeight,u.filterWidth]},{type:\"int32\",data:[u.filterDepth-1-u.padInfo.front,u.filterHeight-1-u.padInfo.top,u.filterWidth-1-u.padInfo.left]},{type:\"int32\",data:[u.strideDepth,u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.outDepth]},{type:\"int32\",data:[u.outHeight]},{type:\"int32\",data:[u.outWidth]},{type:\"int32\",data:[u.outChannels]}];return e.runWebGPUProgram(c,[n,s],n.dtype,l)}var NV={kernelName:sn,backendName:\"webgpu\",kernelFunc:_ue};var $ue=ye({opType:Z.COS}),TV={kernelName:an,backendName:\"webgpu\",kernelFunc:$ue};var Eue=ye({opType:Z.COSH}),_V={kernelName:un,backendName:\"webgpu\",kernelFunc:Eue};var Nx=class{constructor(t,e,o,n){this.variableNames=[\"Image\",\"Boxes\",\"BoxInd\"],this.uniforms=\"extrapolationValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0;let[s]=e;this.outputShape=[s,o[0],o[1],t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.methodId=n===\"bilinear\"?1:0,this.cropHeightBiggerThan1=this.outputShape[1]>1,this.cropWidthBiggerThan1=this.outputShape[2]>1,this.shaderKey=`cropAndResize_${this.methodId}_${this.cropHeightBiggerThan1}_${this.cropWidthBiggerThan1}`}getUserCode(){let[t,e]=[\"f32(uniforms.imageShape[1] - 1)\",\"f32(uniforms.imageShape[2] - 1)\"],[o,n,s]=this.cropHeightBiggerThan1?[`(${t} / f32(uniforms.outShape[1] - 1))`,\"(y2-y1) * height_ratio\",`y1*${t} + f32(y)*(height_scale)`]:[\"0.0\",\"0.0\",`0.5 * (y1+y2) * ${t}`],[a,i,p]=this.cropWidthBiggerThan1?[`(${e} / f32(uniforms.outShape[2] - 1))`,\"(x2-x1) * width_ratio\",`x1*${e} + f32(x)*(width_scale)`]:[\"0.0\",\"0.0\",`0.5 * (x1+x2) * ${e}`];return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let height_ratio = f32(${o});\n let width_ratio = f32(${a});\n let b = coords[0];\n let y = coords[1];\n let x = coords[2];\n let d = coords[3];\n // get box vals\n let y1 = getBoxes(b, 0);\n let x1 = getBoxes(b, 1);\n let y2 = getBoxes(b, 2);\n let x2 = getBoxes(b, 3);\n // get image in batch index\n let bInd = i32(round(getBoxInd(b)));\n if(bInd < 0 || bInd >= uniforms.outShape[0]) {\n return;\n }\n let height_scale = ${n};\n let width_scale = ${i};\n let in_y = ${s};\n if( in_y < 0.0 || in_y > ${t} ) {\n setOutputAtIndex(index, uniforms.extrapolationValue);\n return;\n }\n let in_x = ${p};\n if( in_x < 0.0 || in_x > ${e} ) {\n setOutputAtIndex(index, uniforms.extrapolationValue);\n return;\n }\n let sourceFracIndexCR = vec2(in_x,in_y);\n if(${this.methodId} == 1) {\n // Compute the four integer indices.\n let sourceFloorCR = vec2(sourceFracIndexCR);\n let sourceCeilCR = vec2(ceil(sourceFracIndexCR));\n let topLeft = getImage(bInd, sourceFloorCR.y, sourceFloorCR.x, d);\n let bottomLeft = getImage(bInd, sourceCeilCR.y, sourceFloorCR.x, d);\n let topRight = getImage(bInd, sourceFloorCR.y, sourceCeilCR.x, d);\n let bottomRight = getImage(bInd, sourceCeilCR.y, sourceCeilCR.x, d);\n let fracCR = sourceFracIndexCR - vec2(sourceFloorCR);\n let top = topLeft + (topRight - topLeft) * fracCR.x;\n let bottom = bottomLeft + (bottomRight - bottomLeft) * fracCR.x;\n let newValue = top + (bottom - top) * fracCR.y;\n setOutputAtIndex(index, newValue);\n } else {\n // Compute the coordinators of nearest neighbor point.\n let sourceNearestCR = vec2(floor(\n sourceFracIndexCR + vec2(0.5,0.5)));\n let newValue = getImage(\n bInd, sourceNearestCR.y, sourceNearestCR.x, d);\n setOutputAtIndex(index, newValue);\n }\n }\n }\n `}};var Rue=r=>{let{inputs:t,backend:e,attrs:o}=r,{image:n,boxes:s,boxInd:a}=t,{cropSize:i,method:p,extrapolationValue:u}=o,c=new Nx(n.shape[3],s.shape,i,p),l=[{type:\"float32\",data:[u]}];return e.runWebGPUProgram(c,[n,s,a],\"float32\",l)},$V={kernelName:ln,backendName:\"webgpu\",kernelFunc:Rue};var Lp;(function(r){r.Prod=\"*\",r.Sum=\"+\"})(Lp||(Lp={}));var xm=class{constructor(t,e,o,n){this.variableNames=[\"x\"],this.uniforms=\"index : f32,\",this.size=!0,this.workgroupSize=[128,1,1],this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.exclusive=o,this.reverse=n,this.op=t,this.shaderKey=`cum_${this.op}_${this.exclusive}_${this.reverse}`}getUserCode(){let t=this.outputShape.length,e=this.op===Lp.Prod?\"1.0\":\"0.0\",o=this.exclusive?e:`getX(${EV(t,\"coords\",this.op)})`,n=this.outputShape[this.outputShape.length-1],s=\"\",a=\"\";return this.exclusive?(s=this.reverse?`end != ${n-1}`:\"end != 0\",a=this.reverse?\"end + 1\":\"end - 1\"):(s=this.reverse?`end + pow2 < ${n}`:\"end >= pow2\",a=this.reverse?\"end + pow2\":\"end - pow2\"),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var coords = getCoordsFromIndex(index);\n\n let end = ${RV(t,\"coords\",this.op)};\n var val = ${o};\n let pow2 = i32(pow(2.0, uniforms.index));\n if (${s}) {\n let idx = ${a};\n ${RV(t,\"coords\",this.op)} = idx;\n val ${this.op}= getX(${EV(t,\"coords\",this.op)});\n }\n setOutputAtIndex(index, val);\n }\n }\n `}};function EV(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.x, ${t}.y`;if(r===3)return`${t}.x, ${t}.y, ${t}.z`;if(r===4)return`${t}.x, ${t}.y, ${t}.z, ${t}.w`;throw Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function RV(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.y`;if(r===3)return`${t}.z`;if(r===4)return`${t}.w`;throw Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function Tx(r,t,e,o,n,s){let a=t.shape.length,i=w.getAxesPermutation([o],a),p=t;i!=null&&(p=yr({inputs:{x:t},backend:e,attrs:{perm:i}}));let u=w.getInnerMostAxes(1,a)[0];if(u!==a-1)throw new Error(`WebGPU cumprod shader expects an inner-most axis=${t.shape.length-1} but got axis=${o}`);let c=p.shape[u],l=Ft({inputs:{x:p},backend:e});for(let m=0;m<=Math.ceil(Math.log2(c))-1;m++){let d=new xm(r,p.shape,!1,s),f=l,h=[{type:\"float32\",data:[m]}];l=e.runWebGPUProgram(d,[l],l.dtype,h),e.disposeData(f.dataId)}if(n){let m=new xm(r,p.shape,n,s),d=l,f=[{type:\"float32\",data:[0]}];l=e.runWebGPUProgram(m,[l],l.dtype,f),e.disposeData(d.dataId)}if(i!=null){let m=w.getUndoAxesPermutation(i),d=yr({inputs:{x:l},backend:e,attrs:{perm:m}});return e.disposeData(l.dataId),e.disposeData(p.dataId),d}return l}function Due(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return Tx(Lp.Prod,n,e,s,a,i)}var DV={kernelName:pn,backendName:\"webgpu\",kernelFunc:Due};function Aue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return Tx(Lp.Sum,n,e,s,a,i)}var AV={kernelName:cn,backendName:\"webgpu\",kernelFunc:Aue};function Fue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a,binaryOutput:i}=o,p=n.shape.length===1,c=y.sizeFromShape(s.shape)>0,l=s.dtype,m=p?[n.shape[0]]:[n.shape[0],n.shape[1]],d=p?[a]:[n.shape[0],a],f=kt({backend:e,attrs:{shape:d,value:0,dtype:l}}),h=new Jc(m,c,i),g=[{type:\"int32\",data:[a]}],x=c?[n,s]:[n];return e.runWebGPUProgram(h,x,l,g,f)}var FV={kernelName:ra,backendName:\"webgpu\",kernelFunc:Fue};var _x=class{constructor(t,e){this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.uniforms=\"blockSize : i32,\",this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=`depthToSpace_${e}`,this.dataFormat=e}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let b = coords[0];\n let h = ${this.getHeightCoordString()};\n let w = ${this.getWidthCoordString()};\n let d = ${this.getDepthCoordString()};\n\n let in_h = h / uniforms.blockSize;\n let offset_h = h % uniforms.blockSize;\n let in_w = w / uniforms.blockSize;\n let offset_w = w % uniforms.blockSize;\n let offset_d = (offset_h * uniforms.blockSize + offset_w) *\n ${this.getOutputDepthSize()};\n let in_d = d + offset_d;\n\n let rlt = ${this.getInputSamplingString()};\n setOutputAtIndex(index, rlt);\n }\n }`}getHeightCoordString(){return this.dataFormat===\"NHWC\"?\"coords[1]\":\"coords[2]\"}getWidthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[2]\":\"coords[3]\"}getDepthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[3]\":\"coords[1]\"}getOutputDepthSize(){return this.dataFormat===\"NHWC\"?\"uniforms.outShape[3]\":\"uniforms.outShape[1]\"}getInputSamplingString(){return this.dataFormat===\"NHWC\"?\"getX(b, in_h, in_w, in_d)\":\"getX(b, in_d, in_h, in_w)\"}};function Pue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockSize:s,dataFormat:a}=o,i=n.shape[0],p=a===\"NHWC\"?n.shape[1]:n.shape[2],u=a===\"NHWC\"?n.shape[2]:n.shape[3],c=a===\"NHWC\"?n.shape[3]:n.shape[1],l=p*s,m=u*s,d=c/(s*s),f=a===\"NHWC\"?[i,l,m,d]:[i,d,l,m],h=[{type:\"int32\",data:[s]}],g=new _x(f,a);return e.runWebGPUProgram(g,[n],n.dtype,h)}var PV={kernelName:mn,backendName:\"webgpu\",kernelFunc:Pue};var $x=class{constructor(t,e,o,n=!1,s=null,a=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=\"pads : vec2, inDims : vec2,\",this.workgroupSize=[16,16,1],this.outputShape=t,this.dispatchLayout={x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),n&&this.variableNames.push(\"bias\"),a&&this.variableNames.push(\"preluActivationWeights\"),this.addBias=n,this.activation=s,this.hasPreluActivation=a,this.filterHeight=e,this.filterWidth=o,this.shaderKey=`depthwiseNCHW_${this.activation}_${this.filterHeight}_${this.filterWidth}`}getUserCode(){let t=this.filterWidth*this.filterHeight,e=this.workgroupSize[0]*this.workgroupSize[1]*this.workgroupSize[2],o=this.workgroupSize[1]+this.filterHeight-1,n=this.workgroupSize[0]+this.filterWidth-1;return`\n ${fr(this.activation,this.hasPreluActivation,!1,4)}\n\n var mm_Asub : array, ${o}>;\n var mm_Bsub : array, ${this.filterHeight}>;\n fn readX(batch : i32, channel : i32, row : i32, col : i32) -> f32 {\n var value = 0.0;\n if (row >=0 && row < uniforms.inDims[0] && col >=0 && col < uniforms.inDims[1])\n {\n value = getX(batch, channel, row, col);\n }\n return value;\n }\n\n ${G()} {\n let coords = getOutputCoords();\n let batch = coords[0];\n let xRCCorner = vec2(coords.zw) - uniforms.pads;\n let channelMul = uniforms.wShape[3];\n let d1 = coords[1] / channelMul;\n let q = coords[1] % channelMul;\n\n let inputRowStart = xRCCorner.x;\n let inputColStart = xRCCorner.y;\n\n let localRow = i32(localId.y);\n let localCol = i32(localId.x);\n\n // Load one tile of X into local memory.\n for (var inputRow = localRow; inputRow < ${o}; inputRow = inputRow + ${this.workgroupSize[1]}) {\n for (var inputCol = localCol; inputCol < ${n}; inputCol = inputCol + ${this.workgroupSize[0]}) {\n let rowOffset = inputRow - localRow;\n let colOffset = inputCol - localCol;\n mm_Asub[inputRow][inputCol] = readX(batch, d1, inputRowStart + rowOffset, inputColStart + colOffset);\n }\n }\n\n // Load one tile of W into local memory.\n var wIndex = i32(localIndex);\n ${t, inDims : vec2, virtualWidth : i32,\",this.workgroupSize=[64,1,1],this.workPerThread=4,this.outputComponent=4,this.outputShape=t.outShape,this.virtualWidth=Math.ceil(this.outputShape[2]/this.workPerThread)*this.workPerThread;let s=[this.outputShape[0],this.outputShape[1],this.virtualWidth,this.outputShape[3]];this.dispatchLayout=X(s),this.dispatch=H(this.dispatchLayout,s,this.workgroupSize,[this.outputComponent*this.workPerThread,1,1]),y.assert(t.dataFormat===\"channelsLast\",()=>\"TODO: NCHW is unimplemented\"),e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),this.convInfo=t,this.addBias=e,this.activation=o,this.hasPreluActivation=n,this.shaderKey=`depthwiseVec4_${o}_${this.convInfo.filterHeight}_${this.convInfo.filterWidth}_${this.convInfo.strideHeight}_${this.convInfo.strideWidth}_${this.workPerThread}`}getUserCode(){let t=(this.workPerThread-1)*this.convInfo.strideWidth+this.convInfo.filterWidth,e=this.convInfo.strideHeight,o=this.convInfo.strideWidth;return`\n ${fr(this.activation,this.hasPreluActivation,!0,4)}\n fn readX(batch : i32, row : i32, col : i32, channel : i32) -> vec4 {\n var value = vec4(0.0);\n if (col >=0 && col < uniforms.inDims[1]) {\n value = getX(batch, row, col, channel);\n }\n return value;\n }\n\n ${G(\"index\")} {\n let width0 = uniforms.outShape[3] / ${this.outputComponent};\n let d1 = (index % width0) * ${this.outputComponent};\n var index1 = index / width0;\n let width1 = uniforms.virtualWidth / ${this.workPerThread};\n let c = (index1 % width1) * ${this.workPerThread};\n index1 = index1 / width1;\n let r = index1 % uniforms.outShape[1];\n let batch = index1 / uniforms.outShape[1];\n\n let xRCCorner = vec2(r, c) * vec2(${e}, ${o}) - uniforms.pads;\n\n let xRCorner = xRCCorner.x;\n let xCCorner = xRCCorner.y;\n var xVals : array, ${t}>;\n var dotProd : array, ${this.workPerThread}>;\n for (var i = 0; i < ${this.workPerThread}; i++) {\n dotProd[i] = vec4(0.0);\n }\n\n // Use constant instead of uniform can give better performance.\n for (var wR = 0; wR < ${this.convInfo.filterHeight}; wR = wR + 1) {\n let xR = xRCorner + wR;\n if (xR >=0 && xR < uniforms.inDims[0]) {\n for (var i = 0; i < ${t}; i++) {\n xVals[i] = readX(batch, xR, xCCorner + i, d1);\n }\n for (var wC = 0; wC < ${this.convInfo.filterWidth}; wC = wC + 1) {\n let wValue = getW(wR, wC, d1, 0);\n for (var i = 0; i < ${this.workPerThread}; i++) {\n dotProd[i] = fma(xVals[i * ${o} + wC], wValue, dotProd[i]);\n }\n }\n }\n }\n\n for (var i = 0; i < ${this.workPerThread}; i = i + 1) {\n let coords = vec4(batch, r, c + i, d1);\n if (coordsInBounds4D(coords, uniforms.outShape)) {\n var value = dotProd[i];\n ${Zr(this.addBias,this.activation)}\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], value);\n }\n }\n }\n `}};var rl=class{constructor(t,e=!1,o=null,n=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=`pads : vec2, inDims : vec2, filterHeight : i32,\n filterWidth : i32, strides : vec2, dilations : vec2,`,this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.isChannelsLast=t.dataFormat===\"channelsLast\",e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),this.convInfo=t,this.addBias=e,this.activation=o,this.hasPreluActivation=n,this.shaderKey=`depthwise_${this.activation}_${this.isChannelsLast}`}getUserCode(){let t=this.isChannelsLast?\"getX(batch, xR, xC, d1);\":\"getX(batch, d1, xR, xC);\";return`\n ${fr(this.activation,this.hasPreluActivation,!1,4)}\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let batch = coords[0];\n let xRCCorner = vec2(coords.${this.isChannelsLast?\"yz\":\"zw\"}) * uniforms.strides - uniforms.pads;\n let d2 = coords[${this.isChannelsLast?3:1}];\n let channelMul = uniforms.wShape[3];\n let d1 = d2 / channelMul;\n let q = d2 % channelMul;\n\n let inputRowStart = xRCCorner.x;\n let inputColStart = xRCCorner.y;\n let inputRowEnd = inputRowStart + uniforms.filterHeight *\n uniforms.dilations[0];\n let inputColEnd = inputColStart + uniforms.filterWidth *\n uniforms.dilations[1];\n\n // Convolve x(?, ?, d1)|x(d1, ?, ?) with w(:, :, d1, q) to get\n // y(yR, yC, d2)|y(d2, yR, yC). ? = to be determined. : = across all\n // values in that axis. x(?, ?, d1) and y(yR, yC, d2) is for NHWC.\n // x(d1, ?, ?) and y(d2, yR, yC) is for NCHW.\n var value = 0.0;\n\n // Extract if checking out of for loop for performance.\n if (inputRowStart >= 0 && inputColStart >= 0 &&\n inputRowEnd < uniforms.inDims[0] &&\n inputColEnd < uniforms.inDims[1]) {\n for (var wR = 0; wR < uniforms.filterHeight; wR = wR + 1) {\n let xR = inputRowStart + wR * uniforms.dilations[0];\n\n for (var wC = 0; wC < uniforms.filterWidth; wC = wC + 1) {\n let xC = inputColStart + wC * uniforms.dilations[1];\n\n let xVal = ${t};\n let wVal = getW(wR, wC, d1, q);\n value = value + xVal * wVal;\n }\n }\n } else {\n for (var wR = 0; wR < uniforms.filterHeight; wR = wR + 1) {\n let xR = inputRowStart + wR * uniforms.dilations[0];\n\n if (xR < 0 || xR >= uniforms.inDims[0]) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterWidth; wC = wC + 1) {\n let xC = inputColStart + wC * uniforms.dilations[1];\n\n if (xC < 0 || xC >= uniforms.inDims[1]) {\n continue;\n }\n\n let xVal = ${t};\n let wVal = getW(wR, wC, d1, q);\n value = value + xVal * wVal;\n }\n }\n }\n ${Zr(this.addBias,this.activation)}\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], value);\n }\n }\n `}};function Oue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(p),m=u;m==null&&(m=[1,1]);let d=w.computeConv2DInfo(n.shape,s.shape,a,m,i,c,!0,l),f=[{type:\"int32\",data:[d.padInfo.top,d.padInfo.left]},{type:\"int32\",data:[d.inHeight,d.inWidth]}],h=d.dataFormat===\"channelsLast\",g;return!h&&d.inHeight>16&&d.inWidth>16&&d.strideHeight===1&&d.strideWidth===1&&d.dilationWidth===1&&d.dilationHeight===1&&d.inChannels===d.outChannels?g=new $x(d.outShape,d.filterHeight,d.filterWidth):h&&d.outHeight>4&&d.outWidth>4&&d.strideWidth<=2&&d.inChannels===d.outChannels&&d.dilationHeight===1&&d.dilationWidth===1&&d.inChannels%4===0?(g=new tl(d),f.push({type:\"int32\",data:[g.virtualWidth]})):(g=new rl(d),f.push({type:\"int32\",data:[d.filterHeight]},{type:\"int32\",data:[d.filterWidth]},{type:\"int32\",data:[d.strideHeight,d.strideWidth]},{type:\"int32\",data:[d.dilationHeight,d.dilationWidth]})),e.runWebGPUProgram(g,[n,s],n.dtype,f)}var OV={kernelName:dn,backendName:\"webgpu\",kernelFunc:Oue};var Ex=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.uniforms=`strides : vec2, pads : vec2, filterDims : vec2, outHeight : i32,\n outWidth : i32, inHeight : i32, inWidth : i32, batchSize : i32, channelMul : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"depthwise_conv2d_backprop_filter\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let wR = coords[0];\n let wC = coords[1];\n let d1 = coords[2];\n let dm = coords[3];\n let d2 = d1 * uniforms.channelMul + dm;\n\n var dotProd = 0.0;\n for (var b = 0; b < uniforms.batchSize; b++) {\n for (var yR = 0; yR < uniforms.outHeight; yR++) {\n let xR = wR + yR * uniforms.strides[0] - uniforms.pads[0];\n\n if (xR < 0 || xR >= uniforms.inHeight) {\n continue;\n }\n\n for (var yC = 0; yC < uniforms.outWidth; yC++) {\n let xC = wC + yC * uniforms.strides[1] - uniforms.pads[1];\n\n if (xC < 0 || xC >= uniforms.inWidth) {\n continue;\n }\n\n let dyValue = getDy(b, yR, yC, d2);\n let xValue = getX(b, xR, xC, d1);\n dotProd += xValue * dyValue;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Rx=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.uniforms=`strides : vec2, pads : vec2, filterDims : vec2,\n outHeight : i32, outWidth : i32, channelMul : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"depthwise_conv2d_backprop_input\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d1 = coords[3];\n let dyCorner = coords.yz - uniforms.pads;\n let dyRCorner = dyCorner.x;\n let dyCCorner = dyCorner.y;\n\n var dotProd = 0.0;\n for (var wR = 0; wR < uniforms.filterDims[0]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[0]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n\n let idyR = i32(dyR);\n let wRPerm = uniforms.filterDims[0] - 1 - wR;\n\n for (var wC = 0; wC < uniforms.filterDims[1]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[1]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n\n let idyC = i32(dyC);\n let wCPerm = uniforms.filterDims[1] - 1 - wC;\n\n for (var dm = 0; dm < uniforms.channelMul; dm++) {\n let d2 = d1 * uniforms.channelMul + dm;\n let xValue = getDy(batch, idyR, idyC, d2);\n let wValue = getW(wRPerm, wCPerm, d1, dm);\n dotProd += xValue * wValue;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function Mue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,filterShape:c}=o,l=w.computeConv2DInfo(n.shape,c,a,i,p,u,!0),m=new Ex(l),d=[{type:\"int32\",data:[l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.padInfo.top,l.padInfo.left]},{type:\"int32\",data:[l.filterHeight,l.filterWidth]},{type:\"int32\",data:[l.outHeight]},{type:\"int32\",data:[l.outWidth]},{type:\"int32\",data:[l.inHeight]},{type:\"int32\",data:[l.inWidth]},{type:\"int32\",data:[l.batchSize]},{type:\"int32\",data:[l.outChannels/l.inChannels]}];return e.runWebGPUProgram(m,[n,s],\"float32\",d)}var MV={kernelName:Mi,backendName:\"webgpu\",kernelFunc:Mue};function Lue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,inputShape:c}=o,l=w.computeConv2DInfo(c,s.shape,a,i,p,u,!0),m=new Rx(l),d=[{type:\"int32\",data:[l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.filterHeight-1-l.padInfo.top,l.filterWidth-1-l.padInfo.left]},{type:\"int32\",data:[l.filterHeight,l.filterWidth]},{type:\"int32\",data:[l.outHeight]},{type:\"int32\",data:[l.outWidth]},{type:\"int32\",data:[l.outChannels/l.inChannels]}];return e.runWebGPUProgram(m,[n,s],n.dtype,d)}var LV={kernelName:Li,backendName:\"webgpu\",kernelFunc:Lue};var Dx=class{constructor(t){this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t,t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"diag\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let value = select(0.0, getX(coords[0]), coords[0] == coords[1]);\n setOutputAtIndex(index, value);\n }\n }\n `}};function Bue(r){let{inputs:t,backend:e}=r,{x:o}=t,n=[...o.shape,...o.shape],s=y.sizeFromShape(o.shape),a=pe({inputs:{x:o},backend:e,attrs:{shape:[s]}}),i=new Dx(s),p=e.runWebGPUProgram(i,[a],a.dtype),u=pe({inputs:{x:p},backend:e,attrs:{shape:n}});return e.disposeData(a.dataId),e.disposeData(p.dataId),u}var BV={kernelName:oa,backendName:\"webgpu\",kernelFunc:Bue};var Ax=class{constructor(t){this.variableNames=[\"x\",\"w\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"dilation2d\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let neg_infinity = -3.4e38;\n let coords = getOutputCoords();\n let batch = coords.x;\n let d1 = coords.w;\n let outTopLeftCorner = coords.yz * uniforms.strides - uniforms.pads;\n let hBeg = outTopLeftCorner.x;\n let wBeg = outTopLeftCorner.y;\n\n var curVal = neg_infinity;\n for (var h = 0; h < uniforms.filterDims[0]; h = h + 1) {\n let hIn = hBeg + h * uniforms.dilations[0];\n\n if (hIn >= 0 && hIn < uniforms.xShape[1]) {\n for (var w = 0; w < uniforms.filterDims[1]; w = w + 1) {\n let wIn = wBeg + w * uniforms.dilations[1];\n\n if (wIn >= 0 && wIn < uniforms.xShape[2]) {\n let val = getX(batch, hIn, wIn, d1) + getW(h, w, d1);\n if (val > curVal) {\n curVal = val;\n }\n }\n }\n }\n }\n\n setOutputAtIndex(index, curVal);\n }\n }\n `}};function zue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeDilation2DInfo(n.shape,s.shape,a,i,\"NHWC\",p),c=[u.padInfo.top,u.padInfo.left],l=[{type:\"int32\",data:[u.filterHeight,u.filterWidth]},{type:\"int32\",data:[...c]},{type:\"int32\",data:[u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.dilationHeight,u.dilationWidth]}],m=new Ax(u);return e.runWebGPUProgram(m,[n,s],n.dtype,l)}var zV={kernelName:fn,backendName:\"webgpu\",kernelFunc:zue};var Fx=class{constructor(t,e){if(this.variableNames=[\"x\",\"w\",\"dy\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2, dySize: i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=t.inShape,this.dispatchLayout=X(t.outShape),this.dispatch=H(this.dispatchLayout,t.outShape,this.workgroupSize),e!==\"float32\"&&e!==\"int32\")throw new Error(`Dilation2DBackpropInput only supports float32 and int32\n types, does not support ${e} type.`);this.type=e,this.shaderKey=\"dilation2DBackpropInput\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.dySize) {\n let coords = getDyCoordsFromIndex(index);\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n let d = coords[3];\n\n let dyCorner = vec2(r, c) * uniforms.strides - uniforms.pads;\n var curVal = -3.4e38; // neg_infinity\n var xRMax = 0;\n var xCMax = 0;\n\n // In the case of multiple argmax branches, we only back-propagate\n // along the last branch, i.e., the one with largest value of\n // 'wR * uniforms.filterDims[1] + wC', similarly to the max-pooling\n // backward routines.\n for (var wR = 0; wR < uniforms.filterDims[0]; wR++) {\n let xR = dyCorner.x + wR * uniforms.dilations[0];\n\n if (xR >= 0 && xR < uniforms.xShape[1]) {\n for (var wC = 0; wC < uniforms.filterDims[1]; wC++) {\n let xC = dyCorner.y + wC * uniforms.dilations[1];\n\n if (xC >= 0 && xC < uniforms.xShape[2]) {\n let val = getX(b, xR, xC, d) + getW(wR, wC, d);\n if (val > curVal) {\n curVal = val;\n xRMax = xR;\n xCMax = xC;\n }\n }\n }\n }\n }\n\n let flatIndexIn = d + uniforms.xShape[3] *\n (xCMax + uniforms.xShape[2] * (xRMax + uniforms.xShape[1] * b));\n let value = getDy(b, r, c, d);\n ${Qr(\"&result[flatIndexIn]\",\"value\",this.type)}\n }\n }\n `}},Px=class{constructor(t,e,o){if(this.variableNames=[\"x\",\"w\",\"dy\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2, dySize: i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(t.outShape),this.dispatch=H(this.dispatchLayout,t.outShape,this.workgroupSize),o!==\"float32\"&&o!==\"int32\")throw new Error(`Dilation2DBackpropFilter only supports float32 and int32\n types, does not support ${o} type.`);this.type=o,this.shaderKey=\"dilation2DBackpropFilter\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.dySize) {\n let coords = getDyCoordsFromIndex(index);\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n let d = coords[3];\n\n let dyCorner = vec2(r, c) * uniforms.strides - uniforms.pads;\n var curVal = -3.4e38; // neg_infinity\n var wRMax = 0;\n var wCMax = 0;\n\n // In the case of multiple argmax branches, we only back-propagate\n // along the last branch, i.e., the one with largest value of\n // 'wR * uniforms.filterDims[1] + wC', similarly to the max-pooling\n // backward routines.\n for (var wR = 0; wR < uniforms.filterDims[0]; wR++) {\n let xR = dyCorner.x + wR * uniforms.dilations[0];\n\n if (xR >= 0 && xR < uniforms.xShape[1]) {\n for (var wC = 0; wC < uniforms.filterDims[1]; wC++) {\n let xC = dyCorner.y + wC * uniforms.dilations[1];\n\n if (xC >= 0 && xC < uniforms.xShape[2]) {\n let val = getX(b, xR, xC, d) + getW(wR, wC, d);\n if (val > curVal) {\n curVal = val;\n wRMax = wR;\n wCMax = wC;\n }\n }\n }\n }\n }\n\n let flatIndexIn = d + uniforms.wShape[2] * (wCMax + wRMax * uniforms.wShape[1]);\n let value = getDy(b, r, c, d);\n ${Qr(\"&result[flatIndexIn]\",\"value\",this.type)}\n }\n }\n `}};function Vue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o,c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=s.dtype,m=new Px(c,s.shape,l),d=[{type:\"int32\",data:[c.filterHeight,c.filterWidth]},{type:\"int32\",data:[c.padInfo.top,c.padInfo.left]},{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[y.sizeFromShape(c.outShape)]}],f=kt({backend:e,attrs:{shape:s.shape,value:0,dtype:l}});return e.runWebGPUProgram(m,[n,s,a],l,d,f)}var VV={kernelName:zi,backendName:\"webgpu\",kernelFunc:Vue};function Wue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o,c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=n.dtype,m=new Fx(c,l),d=[{type:\"int32\",data:[c.filterHeight,c.filterWidth]},{type:\"int32\",data:[c.padInfo.top,c.padInfo.left]},{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[y.sizeFromShape(c.outShape)]}],f=kt({backend:e,attrs:{shape:c.inShape,value:0,dtype:l}});return e.runWebGPUProgram(m,[n,s,a],l,d,f)}var WV={kernelName:Bi,backendName:\"webgpu\",kernelFunc:Wue};var Ox=class{constructor(t,e,o){this.variableNames=[\"Image\"],this.uniforms=\"alpha: f32,\",this.workgroupSize=[64,1,1],this.pixelsOpType=Ii.DRAW,this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.type=e,this.textureFormat=o,this.shaderKey=`draw_${e}_${o}`}getUserCode(){let t,e=this.type===\"float32\"?\"value\":\"value / 255.0\";return t=`\n if (uniforms.numChannels == 1) {\n rgba[0] = ${e};\n rgba[1] = ${e};\n rgba[2] = ${e};\n } else {\n rgba[d] = ${e};\n }`,`\n @group(0) @binding(0) var outImage : texture_storage_2d<${this.textureFormat}, write>;\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var rgba = vec4(0.0, 0.0, 0.0, uniforms.alpha);\n for (var d = 0; d < uniforms.numChannels; d = d + 1) {\n let value = f32(inBuf[index * uniforms.numChannels + d]);\n ${t}\n }\n rgba.x = rgba.x * rgba.w;\n rgba.y = rgba.y * rgba.w;\n rgba.z = rgba.z * rgba.w;\n let coords = getCoordsFromIndex(index);\n textureStore(outImage, vec2(coords.yx), rgba);\n }\n }\n `}};function Uue(r){let{inputs:t,backend:e,attrs:o}=r,{image:n}=t,{canvas:s,options:a}=o,[i,p]=n.shape.slice(0,2),{imageOptions:u}=a||{},c=(u==null?void 0:u.alpha)||1,l=e.device.features.has(\"bgra8unorm-storage\")?\"bgra8unorm\":\"rgba8unorm\",m=[i,p],d=new Ox(m,n.dtype,l);s.width=p,s.height=i;let f=\"webgpu\",h=s.getContext(f),g;h||(g=new OffscreenCanvas(p,i),h=g.getContext(f));let x=n.shape.length===3?n.shape[2]:1;h.configure({device:e.device,format:l,usage:GPUTextureUsage.STORAGE_BINDING,alphaMode:\"premultiplied\"});let b=\"int32\",C=e.makeTensorInfo(m,b),S=e.tensorMap.get(C.dataId);S.resource=h.getCurrentTexture(),S.external=!0;let k=[{type:\"uint32\",data:[x]},{type:\"float32\",data:[c]}];if(e.runWebGPUProgram(d,[n],b,k,C),g){let _=s.getContext(\"2d\");if(!_)throw new Error(\"Please make sure this canvas has only been used for 2d or webgpu context!\");_.drawImage(g,0,0)}return e.disposeData(C.dataId),n}var UV={kernelName:Pu,backendName:\"webgpu\",kernelFunc:Uue};var s0=et({opType:fe.MUL,cpuKernelImpl:vz,supportsComplex:!0}),GV={kernelName:Yn,backendName:\"webgpu\",kernelFunc:s0};function a0(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;return eo(n,s,a,\"sum\",e)}var HV={kernelName:Is,backendName:\"webgpu\",kernelFunc:a0};function Gue(r){let{inputs:t,backend:e,attrs:o}=r,{equation:n}=o,s=t,{allDims:a,summedDims:i,idDims:p}=w.decodeEinsumEquation(n,s.length);w.checkEinsumDimSizes(a.length,p,s);let{path:u,steps:c}=w.getEinsumComputePath(i,p),l=c.length,m=null,d=a.length,f=[];for(let h=0;h=0&&(m=a0({inputs:{x:m},backend:e,attrs:{axis:u[h]-(a.length-d),keepDims:!1}}),f.push(m)),d--)}for(let h of f)h!==m&&e.disposeData(h.dataId);return m}var KV={kernelName:Vi,backendName:\"webgpu\",kernelFunc:Gue};var Hue=ye({opType:Z.ELU}),qV={kernelName:gn,backendName:\"webgpu\",kernelFunc:Hue};var Kue=r=>{let{inputs:t,backend:e}=r,{dy:o,y:n}=t,s=new ki(fe.ELU_DER,o.shape,n.shape);return e.runWebGPUProgram(s,[o,n],o.dtype)},jV={kernelName:Ya,backendName:\"webgpu\",kernelFunc:Kue};var que=et({opType:fe.EQUAL,dtype:\"bool\",cpuKernelImpl:pz}),XV={kernelName:yn,backendName:\"webgpu\",kernelFunc:que};var jue=ye({opType:Z.ERF}),YV={kernelName:xn,backendName:\"webgpu\",kernelFunc:jue};var Xue=ye({opType:Z.EXP,cpuKernelImpl:cz,dtype:\"float32\"}),QV={kernelName:bn,backendName:\"webgpu\",kernelFunc:Xue};function Mx(r){let{inputs:t,attrs:e,backend:o}=r,{dim:n}=e,{input:s}=t,a=s.shape.length,i=s.shape.slice(),p=n;return n<0&&(y.assert(-(a+1)<=n,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+n+1),i.splice(p,0,1),pe({inputs:{x:s},backend:o,attrs:{shape:i}})}var ZV={kernelName:na,backendName:\"webgpu\",kernelFunc:Mx};var Yue=ye({opType:Z.EXPM1,cpuKernelImpl:lz}),JV={kernelName:Cn,backendName:\"webgpu\",kernelFunc:Yue};var ym=class{constructor(t,e){this.variableNames=[\"real\",\"imag\"],this.outputShape=[],this.uniforms=\"exponentMultiplier : f32, denominator: f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.component=t,this.shaderKey=`fft_${t}`}getUserCode(){return`\n fn unaryOpComplex(real: f32, expR: f32, imag: f32, expI: f32) -> f32 {\n ${this.component===\"real\"?\"return real * expR - imag * expI;\":\"return real * expI + imag * expR;\"}\n }\n\n fn mulMatDFT(batch: i32, index: i32) -> f32 {\n let indexRatio = f32(index) / f32(uniforms.realShape[1]);\n let exponentMultiplierTimesIndexRatio =\n uniforms.exponentMultiplier * indexRatio;\n\n var result = 0.0;\n\n for (var i = 0; i < uniforms.realShape[1]; i = i + 1) {\n // x = (-2|2 * PI / N) * index * i;\n let x = exponentMultiplierTimesIndexRatio * f32(i);\n let expR = cos(x);\n let expI = sin(x);\n let real = getReal(batch, i);\n let imag = getImag(batch, i);\n\n result = result +\n unaryOpComplex(real, expR, imag, expI) / uniforms.denominator;\n }\n\n return result;\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n setOutputAtIndex(index, mulMatDFT(coords[0], coords[1]));\n }\n }\n `}};function Lx(r,t,e){let o=e.tensorMap.get(r.dataId),n=y.sizeFromShape(r.shape),s=r.shape[r.shape.length-1],a=n/s,i=[],p=pe({inputs:{x:r},backend:e,attrs:{shape:[a,s]}});i.push(p);let u=p.shape,c=new ym(\"real\",u),l=new ym(\"imag\",u),m=[{dataId:o.complexTensorInfos.real.dataId,dtype:o.complexTensorInfos.real.dtype,shape:u},{dataId:o.complexTensorInfos.imag.dataId,dtype:o.complexTensorInfos.imag.dtype,shape:u}],d=t?2*Math.PI:-2*Math.PI,f=t?u[1]:1,h=[{type:\"float32\",data:[d]},{type:\"float32\",data:[f]}],g=e.runWebGPUProgram(c,m,\"float32\",h);i.push(g);let x=e.runWebGPUProgram(l,m,\"float32\",h);i.push(x);let b=yo({inputs:{real:g,imag:x},backend:e});i.push(b);let C=pe({inputs:{x:b},backend:e,attrs:{shape:r.shape}});return i.forEach(S=>e.disposeData(S.dataId)),C}function Que(r){let{inputs:t,backend:e}=r,{input:o}=t;return Lx(o,!1,e)}var eW={kernelName:Wi,backendName:\"webgpu\",kernelFunc:Que};var Bx=class{constructor(t){this.outputShape=[],this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"flipLeftRight\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let coordX = uniforms.xShape[2] - coords[2] - 1;\n let outputValue = getX(coords[0], coords[1], coordX, coords[3]);\n setOutputAtIndex(index, outputValue);\n }\n }\n `}};var tW={kernelName:wn,backendName:\"webgpu\",kernelFunc:({inputs:r,backend:t})=>{let{image:e}=r,o=t,n=new Bx(e.shape);return o.runWebGPUProgram(n,[e],e.dtype)}};var Zue=ye({opType:Z.FLOOR,cpuKernelImpl:mz}),rW={kernelName:Sn,backendName:\"webgpu\",kernelFunc:Zue};var Jue=et({opType:fe.FLOOR_DIV,cpuKernelImpl:dz,dtype:\"int32\"}),oW={kernelName:In,backendName:\"webgpu\",kernelFunc:Jue};var zx=class{constructor(t,e,o=!1){this.pixelsOpType=Ii.FROM_PIXELS,this.outputShape=[0],this.variableNames=[],this.workgroupSize=[256,1,1],this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[e,1,1]),this.importVideo=o,this.shaderKey=`fromPixels_${this.importVideo}`}getUserCode(){let t=this.importVideo?\"textureLoad(src, vec2(coords.yx));\":\"textureLoad(src, vec2(coords.yx), 0)\";return`\n @binding(1) @group(0) var src: ${this.importVideo?\"texture_external\":\"texture_2d\"};\n ${G(\"index\")} {\n let flatIndex = index * uniforms.numChannels;\n if (flatIndex < uniforms.size) {\n let coords = getCoordsFromIndex(flatIndex);\n let values = ${t};\n for (var i = 0; i < uniforms.numChannels; i = i + 1) {\n result[flatIndex + i] = i32(floor(255.0 * values[i]));\n }\n }\n }\n `}};var nW={kernelName:Mu,backendName:\"webgpu\",kernelFunc:epe},ol,i0=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");function epe(r){let{inputs:t,backend:e,attrs:o}=r,{pixels:n}=t,{numChannels:s}=o;if(n==null)throw new Error(\"pixels passed to tf.browser.fromPixels() can not be null\");let a=typeof HTMLVideoElement!=\"undefined\"&&n instanceof HTMLVideoElement,i=typeof HTMLImageElement!=\"undefined\"&&n instanceof HTMLImageElement,p=typeof HTMLCanvasElement!=\"undefined\"&&n instanceof HTMLCanvasElement||typeof OffscreenCanvas!=\"undefined\"&&n instanceof OffscreenCanvas,u=typeof ImageBitmap!=\"undefined\"&&n instanceof ImageBitmap,[c,l]=a?[n.videoWidth,n.videoHeight]:[n.width,n.height],m=[l,c,s],d=!1,f=a||i;if(u||p||f){let b;if(d)b=e.device.importExternalTexture({source:n});else{if(f){let L=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");(ol==null||L!==i0)&&(i0=L,ol=document.createElement(\"canvas\").getContext(\"2d\",{willReadFrequently:i0})),ol.canvas.width=c,ol.canvas.height=l,ol.drawImage(n,0,0,c,l),n=ol.canvas}let P=GPUTextureUsage.COPY_DST|GPUTextureUsage.RENDER_ATTACHMENT|GPUTextureUsage.TEXTURE_BINDING,O=\"rgba8unorm\",M=e.textureManager.acquireTexture(m[1],m[0],O,P);e.queue.copyExternalImageToTexture({source:n},{texture:M},[m[1],m[0]]),b=M}let C=y.sizeFromShape(m),S=y.computeStrides(m),k=new zx(m,s,d),_=[{type:\"uint32\",data:[C]},{type:\"uint32\",data:[s]},{type:\"uint32\",data:[...S]}],E=e.makeTensorInfo([l,c],\"int32\"),R=e.tensorMap.get(E.dataId);R.resource=b;let D=e.runWebGPUProgram(k,[E],\"int32\",_);return e.disposeData(E.dataId),D}let h=n.data,g=h;if(s!=null&&s!==4){g=new Uint8Array(n.width*n.height*s);let b=h.length,C=0;for(let S=0;S(xValue, -meanValue, offsetValue), vec3(inv, inv, 1.0)));\n }\n }\n `}};var sW={kernelName:vn,backendName:\"webgpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o,scale:n,offset:s,mean:a,variance:i}=r,{varianceEpsilon:p}=t,u=e,c=[o,a,i],l=null;s!=null&&(l=s.shape,c.push(s));let m=null;n!=null&&(m=n.shape,c.push(n));let d=new Vx(o.shape,a.shape,i.shape,l,m),f=[{type:\"float32\",data:[p]}];return u.runWebGPUProgram(d,c,o.dtype,f)}};function tpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dataFormat:c,dilations:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=o,h=w.convertConv2DDataFormat(c),g=w.computeConv2DInfo(n.shape,s.shape,p,l,u,m,!1,h);return bx({x:n,filter:s,convInfo:g,backend:e,bias:a,preluActivationWeights:i,leakyreluAlpha:f,activation:d})}var aW={kernelName:vo,backendName:\"webgpu\",kernelFunc:tpe};function rpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dimRoundingMode:l,activation:m,leakyreluAlpha:d}=o,f=c;f==null&&(f=[1,1]),y.assert(w.eitherStridesOrDilationsAreOne(p,f),()=>`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${p} and dilations '${f}'`);let h=w.computeConv2DInfo(n.shape,s.shape,p,f,u,l,!0),g=[n,s],x=a!=null,b=i!=null;x&&g.push(a),b&&g.push(i);let C=[{type:\"int32\",data:[h.padInfo.top,h.padInfo.left]},{type:\"int32\",data:[h.inHeight,h.inWidth]}],S;return h.outHeight>4&&h.outWidth>4&&h.strideWidth<=2&&h.inChannels===h.outChannels&&h.dilationHeight===1&&h.dilationWidth===1&&h.inChannels%4===0?(S=new tl(h,x,m,b),C.push({type:\"int32\",data:[S.virtualWidth]})):(S=new rl(h,x,m,b),C.push({type:\"int32\",data:[h.filterHeight]},{type:\"int32\",data:[h.filterWidth]},{type:\"int32\",data:[h.strideHeight,h.strideWidth]},{type:\"int32\",data:[h.dilationHeight,h.dilationWidth]})),m===\"leakyrelu\"&&(C.push({type:\"float32\",data:[d]}),S.uniforms+=\" alpha : f32,\"),e.runWebGPUProgram(S,g,\"float32\",C)}var iW={kernelName:ko,backendName:\"webgpu\",kernelFunc:rpe};var Wx=class{constructor(t,e){this.variableNames=[\"A\",\"indices\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=`gathernd_${t}`,this.sliceDim=t,this.uniforms=`sliceDim : i32, strides : ${ht(t)},`}getUserCode(){let t;return this.sliceDim>1?t=\"uniforms.strides[j]\":t=\"uniforms.strides\",`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n var flattenIndex = 0;\n for (var j = 0; j < uniforms.sliceDim; j = j + 1) {\n let indexTemp = i32(round(getIndices(coords[0], j)));\n let strideNum = ${t};\n flattenIndex = flattenIndex + indexTemp * strideNum;\n }\n\n setOutputAtIndex(index, getA(flattenIndex, coords[1]));\n }\n }\n `}};function ope(r){let{inputs:t,backend:e}=r,{params:o,indices:n}=t,s=n.shape,a=s[s.length-1],i=y.sizeFromShape(o.shape),[p,u,c,l]=w.prepareAndValidate(o,n),m=pe({inputs:{x:n},backend:e,attrs:{shape:[u,a]}}),d=pe({inputs:{x:o},backend:e,attrs:{shape:[y.sizeFromShape(o.shape)/c,c]}});if(e.shouldExecuteOnCPU([o,n])||o.dtype===\"string\"){let b=e.readSync(n.dataId),C=e.bufferSync(o),S=fz(b,C,o.dtype,u,a,c,l,o.shape,i);return e.makeTensorInfo(p,o.dtype,S.values)}let f=new Wx(a,[u,c]),h=[{type:\"int32\",data:[a]},{type:\"int32\",data:l}],g=e.runWebGPUProgram(f,[d,m],d.dtype,h),x=pe({inputs:{x:g},backend:e,attrs:{shape:p}});return e.disposeData(m.dataId),e.disposeData(d.dataId),e.disposeData(g.dataId),x}var uW={kernelName:kn,backendName:\"webgpu\",kernelFunc:ope};var Ux=class{constructor(t,e){this.variableNames=[\"A\",\"indices\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.slice(),this.aShape=t,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"gather\"}getUserCode(){let t=npe(this.aShape);return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let resRC = getCoordsFromIndex(index);\n let indexZ = i32(getIndices(resRC.x, resRC.z));\n let inBounds = select(0.0, 1.0, indexZ >= 0 && indexZ < uniforms.aShape[2]);\n setOutputAtIndex(index, inBounds * getA(${t}));\n }\n }\n `}};function npe(r){let t=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],e=[];for(let o=0;oe.disposeData(D.dataId)),e.makeTensorInfo(u.outputShape,R.dtype,R.values)}let h=new Ux(m.shape,f),g=e.runWebGPUProgram(h,[m,d],m.dtype);l.push(g);let x=pe({inputs:{x:g},backend:e,attrs:{shape:u.outputShape}});return l.forEach(b=>e.disposeData(b.dataId)),x}var pW={kernelName:aa,backendName:\"webgpu\",kernelFunc:u0};var spe=et({opType:fe.GREATER,cpuKernelImpl:xz,dtype:\"bool\"}),cW={kernelName:Nn,backendName:\"webgpu\",kernelFunc:spe};var ape=et({opType:fe.GREATER_EQUAL,dtype:\"bool\",cpuKernelImpl:gz}),lW={kernelName:Tn,backendName:\"webgpu\",kernelFunc:ape};function ipe(r){let{inputs:t,backend:e}=r,{input:o}=t;return Lx(o,!0,e)}var mW={kernelName:Ui,backendName:\"webgpu\",kernelFunc:ipe};var upe=ye({opType:Z.IS_FINITE,dtype:\"bool\"}),dW={kernelName:_n,backendName:\"webgpu\",kernelFunc:upe};var ppe=ye({opType:Z.IS_INF,dtype:\"bool\"}),fW={kernelName:$n,backendName:\"webgpu\",kernelFunc:ppe};var cpe=ye({opType:Z.IS_NAN,dtype:\"bool\"}),hW={kernelName:En,backendName:\"webgpu\",kernelFunc:cpe};function lpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{alpha:s}=o,a=[{type:\"float32\",data:[s]}],i=new Jr(n.shape,Z.LEAKYRELU,\"alpha : f32,\");return e.runWebGPUProgram(i,[n],\"float32\",a)}var gW={kernelName:Rn,backendName:\"webgpu\",kernelFunc:lpe};var mpe=et({opType:fe.LESS,dtype:\"bool\",cpuKernelImpl:bz}),xW={kernelName:Dn,backendName:\"webgpu\",kernelFunc:mpe};var dpe=et({opType:fe.LESS_EQUAL,dtype:\"bool\",cpuKernelImpl:yz}),yW={kernelName:An,backendName:\"webgpu\",kernelFunc:dpe};var Gx=class{constructor(t){this.variableNames=[],this.outputShape=[],this.uniforms=\"start : f32, step : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"linSpace\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n setOutputAtIndex(index, uniforms.start + f32(index) * uniforms.step);\n }\n }\n `}};function fpe(r){let{backend:t,attrs:e}=r,{start:o,stop:n,num:s}=e,a=(n-o)/(s-1),i=new Gx(s),p=[{type:\"float32\",data:[o]},{type:\"float32\",data:[a]}];return t.runWebGPUProgram(i,[],\"float32\",p)}var bW={kernelName:Fn,backendName:\"webgpu\",kernelFunc:fpe};var hpe=ye({opType:Z.LOG,cpuKernelImpl:Cz}),CW={kernelName:Pn,backendName:\"webgpu\",kernelFunc:hpe};var gpe=ye({opType:Z.LOG1P}),wW={kernelName:On,backendName:\"webgpu\",kernelFunc:gpe};var xpe=et({opType:fe.LOGICAL_AND,dtype:\"bool\"}),SW={kernelName:Mn,backendName:\"webgpu\",kernelFunc:xpe};var ype=ye({opType:Z.LOGICAL_NOT}),IW={kernelName:Ln,backendName:\"webgpu\",kernelFunc:ype};var bpe=et({opType:fe.LOGICAL_OR}),vW={kernelName:Bn,backendName:\"webgpu\",kernelFunc:bpe};var kW=`\n var powValue = 0.0;\n let basis = uniforms.bias + uniforms.alpha * sum;\n if (uniforms.beta == 0.5) {\n powValue = inverseSqrt(basis);\n } else if (uniforms.beta == 1.0) {\n powValue = 1.0 / basis;\n } else {\n powValue = exp(log(basis) * (-uniforms.beta));\n }\n`,Hx=class{constructor(t){this.outputShape=[],this.variableNames=[\"x\"],this.uniforms=\"radius : i32, bias : f32, alpha : f32, beta : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"lrn\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n let d = coords[3];\n\n let x = getX(b, r, c, d);\n var sum = 0.0;\n for (var i = -uniforms.radius; i <= uniforms.radius; i = i + 1) {\n let idx = d + i;\n if (idx >= 0 && idx < uniforms.xShape[3]) {\n let z = getX(b, r, c, idx);\n sum = sum + z * z;\n }\n }\n ${kW}\n\n setOutputAtIndex(index, x * powValue);\n }\n }\n `}},Kx=class{constructor(t,e){this.outputShape=[],this.variableNames=[\"x\"],this.uniforms=\"radius : i32, bias : f32, alpha : f32, beta : f32,\",this.workgroupSize=[256,1,1],this.maxAllowRadius=16,y.assert(e<=this.maxAllowRadius,()=>`Radius must be less than or equal to ${this.maxAllowRadius}, current radius is ${e}`),this.outputShape=t,this.elementsPerWorkgroup=this.workgroupSize[0]-2*this.maxAllowRadius,this.dispatchLayout={x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,[this.elementsPerWorkgroup,this.workgroupSize[1],this.workgroupSize[2]]),this.shaderKey=\"lrn_shared\"}getUserCode(){return`\n var lrnSub: array;\n const elementsPerWorkgroup = ${this.elementsPerWorkgroup};\n const maxAllowRadius = ${this.maxAllowRadius};\n\n ${G()} {\n let localDepth = i32(localId.x);\n let workgroupDepth = i32(workgroupId.x) * elementsPerWorkgroup;\n let xDepth = workgroupDepth + localDepth - maxAllowRadius;\n let b = i32(globalId.z) / uniforms.xShape[1];\n let r = i32(globalId.z) - b * uniforms.xShape[1];\n let c = i32(globalId.y);\n let d = workgroupDepth + localDepth;\n\n var x = 0.0;\n if (xDepth >= 0 && xDepth < uniforms.xShape[3]) {\n x = getX(b, r, c, xDepth);\n }\n lrnSub[localDepth] = x;\n workgroupBarrier();\n\n if (localDepth < elementsPerWorkgroup && d < uniforms.outShape[3]) {\n var sum = 0.0;\n let index = localDepth + maxAllowRadius;\n for (var i = -uniforms.radius; i <= uniforms.radius; i = i + 1) {\n let z = lrnSub[index + i];\n sum = sum + z * z;\n }\n ${kW}\n\n setOutputAtCoords(b, r, c, d, lrnSub[index] * powValue);\n }\n } `}};function Cpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o,u;s>16?u=new Hx(n.shape):u=new Kx(n.shape,s);let c=[{type:\"int32\",data:[s]},{type:\"float32\",data:[a]},{type:\"float32\",data:[i]},{type:\"float32\",data:[p]}];return e.runWebGPUProgram(u,[n],n.dtype,c)}var NW={kernelName:zn,backendName:\"webgpu\",kernelFunc:Cpe};var qx=class{constructor(t){this.outputShape=[],this.variableNames=[\"inputImage\",\"outputImage\",\"dy\"],this.uniforms=\"depthRadius : i32, bias : f32, alpha : f32, beta : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"lrn_grad\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n\n let MIN_DEPTH_BEGIN = 0;\n let MAX_DEPTH_END = uniforms.outShape[3];\n var result = 0.0;\n for (var d = MIN_DEPTH_BEGIN; d < MAX_DEPTH_END; d++) {\n let depthBegin = max(MIN_DEPTH_BEGIN, d - uniforms.depthRadius);\n let depthEnd = min(MAX_DEPTH_END, d + uniforms.depthRadius + 1);\n\n var norm = 0.0;\n for (var k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; k++) {\n if (k < depthBegin) {\n continue;\n } else if (k >= depthBegin && k < depthEnd) {\n norm += getInputImage(b, r, c, k) * getInputImage(b, r, c, k);\n } else {\n break;\n }\n }\n\n norm = uniforms.alpha * norm + uniforms.bias;\n\n for (var k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; k++) {\n if (k < depthBegin) {\n continue;\n } else if (k >= depthBegin && k < depthEnd) {\n var dyi = -2.0 * uniforms.alpha * uniforms.beta\n * getInputImage(b, r, c, k) * getOutputImage(b, r, c, d) / norm;\n if (k == d) {\n dyi += pow(norm, -1.0 * uniforms.beta);\n }\n if (k == coords[3]) {\n dyi *= getDy(b, r, c, d);\n result += dyi;\n }\n } else {\n break;\n }\n }\n }\n\n setOutputAtIndex(index, result);\n }\n }\n `}};function wpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,y:s,dy:a}=t,{depthRadius:i,bias:p,alpha:u,beta:c}=o,l=new qx(n.shape),m=[{type:\"int32\",data:[i]},{type:\"float32\",data:[p]},{type:\"float32\",data:[u]},{type:\"float32\",data:[c]}];return e.runWebGPUProgram(l,[n,s,a],n.dtype,m)}var TW={kernelName:Qa,backendName:\"webgpu\",kernelFunc:wpe};var Spe=et({opType:fe.MAX,cpuKernelImpl:Sz}),_W={kernelName:Wn,backendName:\"webgpu\",kernelFunc:Spe};function Ipe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1,c=w.computePool2DInfo(n.shape,s,a,u,i,p);return ax(n,c,\"max\",e)}var $W={kernelName:Un,backendName:\"webgpu\",kernelFunc:Ipe};function vpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dataFormat:p,dimRoundingMode:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,u,p),m=new _u(l,\"max\"),d=[{type:\"int32\",data:[l.strideDepth,l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.padInfo.front,l.padInfo.top,l.padInfo.left]},{type:\"int32\",data:[l.inDepth,l.inHeight,l.inWidth]},{type:\"int32\",data:[l.effectiveFilterDepth,l.effectiveFilterHeight,l.effectiveFilterWidth]}];return e.runWebGPUProgram(m,[n],n.dtype,d)}var EW={kernelName:ia,backendName:\"webgpu\",kernelFunc:vpe};var jx=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.uniforms=`strides : vec2, pads : vec2, dilations : vec2, filterDims : vec2,\n outHeight : i32, outWidth : i32`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"maxPool2DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n\n let dyRCCorner = vec2(coords.yz) - uniforms.pads;\n let dyRCorner = dyRCCorner.x;\n let dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n let lastIndex = uniforms.filterDims[0] * uniforms.filterDims[1] - 1;\n for (var wR = 0; wR < uniforms.filterDims[0]; wR += uniforms.dilations[0]) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[0]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[1]; wC += uniforms.dilations[1]) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[1]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyR, idyC, d);\n let maxPosValue = lastIndex - i32(getMaxPos(batch, idyR, idyC, d));\n\n // Get the current value, check it against the value from the\n // position matrix.\n let curPosValue = wR * uniforms.filterDims[1] + wC;\n let mask = select(0.0, 1.0, maxPosValue == curPosValue);\n dotProd += dyValue * mask;\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Xx=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.uniforms=`strides : vec3, pads : vec3, filterDims : vec3,\n outDepth : i32, outHeight : i32, outWidth : i32`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"maxPool3DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let ch = coords.u;\n\n let dyCorner = vec3(coords.y, coords.z, coords.w) - uniforms.pads;\n let dyDCorner = dyCorner.x;\n let dyRCorner = dyCorner.y;\n let dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, ch) with pos mask(:, :, :, d) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n let lastIndex = uniforms.filterDims[0] * uniforms.filterDims[1] * uniforms.filterDims[2] - 1;\n\n for (var wD = 0; wD < uniforms.filterDims[0]; wD++) {\n let dyD = f32(dyDCorner + wD) / f32(uniforms.strides[0]);\n\n if (dyD < 0.0 || dyD >= f32(uniforms.outDepth) || fract(dyD) > 0.0) {\n continue;\n }\n let idyD = i32(dyD);\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[1]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[2]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyD, idyR, idyC, ch);\n let maxPosValue = lastIndex - i32(getMaxPos(batch, idyD, idyR, idyC, ch));\n\n // Get the current value, check it against the value from the\n // position matrix.\n let curPosValue = wD * uniforms.filterDims[1] * uniforms.filterDims[2] + wR * uniforms.filterDims[2] + wC;\n let mask = select(0.0, 1.0, maxPosValue == curPosValue);\n dotProd += dyValue * mask;\n }\n }\n }\n\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function kpe(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=[1,1,1],m=w.computePool3DInfo(a.shape,i,p,l,u,c),d=new _u(m,\"max\",!0),f=[{type:\"int32\",data:[m.strideDepth,m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.padInfo.front,m.padInfo.top,m.padInfo.left]},{type:\"int32\",data:[m.inDepth,m.inHeight,m.inWidth]},{type:\"int32\",data:[m.effectiveFilterDepth,m.effectiveFilterHeight,m.effectiveFilterWidth]}],h=e.runWebGPUProgram(d,[a],\"int32\",f),g=new Xx(m);f=[{type:\"int32\",data:[m.strideDepth,m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.effectiveFilterDepth-1-m.padInfo.front,m.effectiveFilterHeight-1-m.padInfo.top,m.effectiveFilterWidth-1-m.padInfo.left]},{type:\"int32\",data:[m.effectiveFilterDepth,m.effectiveFilterHeight,m.effectiveFilterWidth]},{type:\"int32\",data:[m.outDepth]},{type:\"int32\",data:[m.outHeight]},{type:\"int32\",data:[m.outWidth]}];let x=e.runWebGPUProgram(g,[n,h],a.dtype,f);return e.disposeData(h.dataId),x}var RW={kernelName:Ki,backendName:\"webgpu\",kernelFunc:kpe};function Npe(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s,output:a}=t,i=s;fm([s,a],\"maxPoolGrad\");let{filterSize:p,strides:u,pad:c,dimRoundingMode:l}=o,m=w.computePool2DInfo(i.shape,p,u,1,c,l),d=new za(m,\"max\",!0),f=[{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.padInfo.top,m.padInfo.left]},{type:\"int32\",data:[m.dilationHeight,m.dilationWidth]},{type:\"int32\",data:[m.inHeight,m.inWidth]},{type:\"int32\",data:[m.effectiveFilterHeight,m.effectiveFilterWidth]}],h=e.runWebGPUProgram(d,[i],\"int32\",f),g=new jx(m);f=[{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.effectiveFilterHeight-1-m.padInfo.top,m.effectiveFilterWidth-1-m.padInfo.left]},{type:\"int32\",data:[m.dilationHeight,m.dilationWidth]},{type:\"int32\",data:[m.effectiveFilterHeight,m.effectiveFilterWidth]},{type:\"int32\",data:[m.outHeight]},{type:\"int32\",data:[m.outWidth]}];let x=e.runWebGPUProgram(g,[n,h],i.dtype,f);return e.disposeData(h.dataId),x}var DW={kernelName:Hi,backendName:\"webgpu\",kernelFunc:Npe};function Tpe(r){let{inputs:t,backend:e,attrs:o}=r,{filterSize:n,strides:s,pad:a,includeBatchInIndex:i}=o,{x:p}=t;y.assert(p.shape.length===4,()=>`Error in maxPool: input must be rank 4 but got rank ${p.shape.length}.`);let u=[1,1];y.assert(w.eitherStridesOrDilationsAreOne(s,u),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${s} and dilations '${u}'`);let c=w.computePool2DInfo(p.shape,n,s,u,a),l=[{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.padInfo.top,c.padInfo.left]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[c.inHeight,c.inWidth]},{type:\"int32\",data:[c.effectiveFilterHeight,c.effectiveFilterWidth]}],m=new za(c,\"max\",!1),d=e.runWebGPUProgram(m,[p],p.dtype,l);m=new za(c,\"max\",!0,!0,i);let f=e.runWebGPUProgram(m,[p],\"int32\",l);return[d,f]}var AW={kernelName:ua,backendName:\"webgpu\",kernelFunc:Tpe};function _pe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;return eo(n,s,a,\"min\",e)}var FW={kernelName:Hn,backendName:\"webgpu\",kernelFunc:_pe};var $pe=et({opType:fe.MIN,cpuKernelImpl:Iz}),PW={kernelName:Kn,backendName:\"webgpu\",kernelFunc:$pe};var Yx=class{constructor(t,e,o){this.uniforms=\"\",this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e.map((n,s)=>n[0]+t[s]+n[1]),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.xShape=t,e.map((n,s)=>{this.uniforms+=` pad${s} : vec2,`}),this.offset=o===\"reflect\"?0:1,this.shaderKey=`mirrorPad_${o}`}getUserCode(){let t=this.xShape.length,e=this.xShape.map((u,c)=>`uniforms.pad${c}[0]`).join(\",\"),o=this.xShape.map((u,c)=>`uniforms.pad${c}[0] + uniforms.xShape${t>1?`[${c}]`:\"\"}`).join(\",\"),n=t===1?\"start\":\"start[i]\",s=t===1?\"end\":\"end[i]\",a=t===1?\"outC\":\"outC[i]\",i=ht(t),p=t>1?[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,t):\"coords\";return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let start = ${i}(${e});\n let end = ${i}(${o});\n var outC = getCoordsFromIndex(index);\n for (var i = 0; i < ${t}; i = i + 1) {\n if (${a} < ${n}) {\n ${a} = ${n} * 2 - ${a} - ${this.offset};\n } else if(${a} >= ${s}) {\n ${a} = (${s} - 1) * 2 - ${a} + ${this.offset};\n }\n }\n let coords = outC - start;\n setOutputAtIndex(index, getX(${p}));\n }\n }\n `}};var OW={kernelName:qn,backendName:\"webgpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{paddings:n,mode:s}=t,a=e,i=n.map(c=>({type:\"int32\",data:[c[0],c[1]]})),p=new Yx(o.shape,n,s);return a.runWebGPUProgram(p,[o],o.dtype,i)}};var Epe=et({opType:fe.MOD}),MW={kernelName:jn,backendName:\"webgpu\",kernelFunc:Epe};var Qx=class{constructor(t,e){this.variableNames=[\"probs\"],this.outputShape=[],this.uniforms=\"seed : f32, numOutcomes: i32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t,e],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"multinomial\"}getUserCode(){return`\n //Based on the work of Dave Hoskins\n //https://www.shadertoy.com/view/4djSRW\n fn random (seed : f32, resultUV : vec2) -> f32 {\n let HASHSCALE1 = 443.8975;\n let p = resultUV * seed;\n var p3 = fract(vec3(p.xyx) * HASHSCALE1);\n p3 = p3 + dot(p3, p3.yzx + 19.19);\n return fract((p3.x + p3.y) * p3.z);\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let batch = coords[0];\n\n let resUV = vec2(f32(coords[1]) / f32(uniforms.outShape[1]),\n f32(coords[0]) / f32(uniforms.outShape[0]));\n let r = random(uniforms.seed, resUV);\n var cdf = 0.0;\n for (var i = 0; i < uniforms.numOutcomes - 1; i = i + 1) {\n cdf = cdf + getProbs(batch, i);\n\n if (r < cdf) {\n setOutputAtIndexI32(index, i);\n return;\n }\n }\n\n // If no other event happened, last event happened.\n setOutputAtIndexI32(index, uniforms.numOutcomes - 1);\n }\n }\n `}};var Zx=class{constructor(t){this.variableNames=[\"logits\"],this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=[this.outputShape[0],1,1],this.outputShape[1]>=4096?this.workgroupSize=[256,1,1]:this.workgroupSize=[64,1,1],this.shaderKey=\"softmax\"}getUserCode(){return`\n var buf : array;\n var rowMaxShared : f32;\n var rowSumShared : f32;\n const blockSize = ${this.workgroupSize[0]};\n ${G(\"index\")} {\n let row = index / blockSize;\n let tid = i32(localId.x);\n let cols = uniforms.outShape[1];\n\n var threadMax = -3.402823e+38f;\n for (var col = tid; col < cols; col += blockSize) {\n let value = getLogits(row, col);\n threadMax = max(threadMax, value);\n }\n if (tid < cols) {\n buf[tid] = threadMax;\n }\n workgroupBarrier();\n\n var reduceSize = min(cols, blockSize);\n for (var currSize = reduceSize >> 1; currSize > 0; currSize = reduceSize >> 1) {\n reduceSize = currSize + (reduceSize & 1);\n if (tid < currSize) {\n buf[tid] = max(buf[tid], buf[tid + reduceSize]);\n }\n workgroupBarrier();\n }\n\n if (tid == 0) {\n rowMaxShared = buf[0];\n }\n workgroupBarrier();\n\n var threadSum = 0.0;\n for (var col = tid; col < cols; col += blockSize) {\n let subExp = exp(getLogits(row, col) - rowMaxShared);\n threadSum += subExp;\n }\n buf[tid] = threadSum;\n workgroupBarrier();\n\n for (var currSize = blockSize >> 1; currSize > 0; currSize = currSize >> 1) {\n if (tid < currSize) {\n buf[tid] = buf[tid] + buf[tid + currSize];\n }\n workgroupBarrier();\n }\n\n if (tid == 0) {\n rowSumShared = buf[0];\n }\n workgroupBarrier();\n\n for (var col = tid; col < cols; col += blockSize) {\n let value = exp(getLogits(row, col) - rowMaxShared) / rowSumShared;\n setOutputAtCoords(row, col, value);\n }\n }\n `}};function p0(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{dim:s}=o,a=pe({inputs:{x:n},backend:e,attrs:{shape:[y.sizeFromShape(n.shape)/n.shape[s],n.shape[s]]}}),i=new Zx(a.shape),p=e.runWebGPUProgram(i,[a],n.dtype),u=pe({inputs:{x:p},backend:e,attrs:{shape:n.shape}});return e.disposeData(a.dataId),e.disposeData(p.dataId),u}var LW={kernelName:vs,backendName:\"webgpu\",kernelFunc:p0};function Rpe(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o,p=i?n:p0({inputs:{logits:n},backend:e,attrs:{dim:n.shape.length-1}}),u=p.shape[0],c=p.shape[1],l=new Qx(u,s),m=[{type:\"float32\",data:[a]},{type:\"int32\",data:[c]}],d=e.runWebGPUProgram(l,[p],\"int32\",m);return i||e.disposeData(p.dataId),d}var BW={kernelName:Xn,backendName:\"webgpu\",kernelFunc:Rpe};function Dpe(r){let{inputs:t,backend:e}=r,{x:o}=t;if(e.shouldExecuteOnCPU([o])){let s=e.tensorMap.get(o.dataId),[a,i]=kz(s.values,o.shape,o.dtype);return e.makeTensorInfo(i,o.dtype,a)}let n=new Jr(o.shape,Z.NEG);return e.runWebGPUProgram(n,[o],o.dtype)}var zW={kernelName:pa,backendName:\"webgpu\",kernelFunc:Dpe};function Ape(r){console.warn(\"tf.nonMaxSuppression() in webgpu locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p}=o,u=e.readSync(n.dataId),c=e.readSync(s.dataId),{selectedIndices:l}=Wt.nonMaxSuppressionV3Impl(u,c,a,i,p);return e.makeTensorInfo([l.length],\"int32\",new Int32Array(l))}var VW={kernelName:Zn,backendName:\"webgpu\",kernelFunc:Ape};function Fpe(r){console.warn(\"tf.nonMaxSuppression() in webgpu locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p,softNmsSigma:u}=o,c=e.readSync(n.dataId),l=e.readSync(s.dataId),m=a,d=i,f=p,h=u,{selectedIndices:g,selectedScores:x}=Wt.nonMaxSuppressionV5Impl(c,l,m,d,f,h);return[e.makeTensorInfo([g.length],\"int32\",new Int32Array(g)),e.makeTensorInfo([x.length],\"float32\",new Float32Array(x))]}var WW={kernelName:Jn,backendName:\"webgpu\",kernelFunc:Fpe};var Jx=class{constructor(t,e){this.variableNames=[\"x\"],this.uniforms=\"onValue : f32, offValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t,e],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"onehot\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n setOutputAtIndex(index, mix(uniforms.offValue, uniforms.onValue,\n f32(i32(round(getX(coords.x))) == coords.y)));\n }\n }\n `}};function Ppe(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n}=t,{dtype:s,depth:a,onValue:i,offValue:p}=o,u=y.sizeFromShape(n.shape),c=new Jx(u,a),l=pe({inputs:{x:n},backend:e,attrs:{shape:[u]}}),m=[{type:\"float32\",data:[i]},{type:\"float32\",data:[p]}],d=e.runWebGPUProgram(c,[l],s,m);e.disposeData(l.dataId);let f=[...n.shape,a],h=pe({inputs:{x:d},backend:e,attrs:{shape:f}});return e.disposeData(d.dataId),h}var UW={kernelName:es,backendName:\"webgpu\",kernelFunc:Ppe};function bm(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"complex64\"){let n=Ni({inputs:{input:o},backend:e}),s=bm({inputs:{x:n},backend:e}),a=Mp({inputs:{input:o},backend:e}),i=bm({inputs:{x:a},backend:e}),p=yo({inputs:{real:s,imag:i},backend:e});return e.disposeData(n.dataId),e.disposeData(s.dataId),e.disposeData(a.dataId),e.disposeData(i.dataId),p}else return kt({attrs:{shape:o.shape,dtype:o.dtype,value:o.dtype===\"string\"?\"\":0},backend:e})}var GW={kernelName:Sa,backendName:\"webgpu\",kernelFunc:bm};function HW(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"string\")throw new Error(\"onesLike is not supported under string dtype\");if(o.dtype===\"complex64\"){let n=Ni({inputs:{input:o},backend:e}),s=HW({inputs:{x:n},backend:e}),a=Mp({inputs:{input:o},backend:e}),i=bm({inputs:{x:a},backend:e}),p=yo({inputs:{real:s,imag:i},backend:e});return e.disposeData(n.dataId),e.disposeData(s.dataId),e.disposeData(a.dataId),e.disposeData(i.dataId),p}else return kt({attrs:{shape:o.shape,dtype:o.dtype,value:1},backend:e})}var KW={kernelName:ca,backendName:\"webgpu\",kernelFunc:HW};function Ope(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o;if(t.length===1)return Mx({inputs:{input:t[0]},backend:e,attrs:{dim:n}});let s=t[0].shape,a=t[0].dtype;t.forEach(c=>{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=Mx({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=n0({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeData(c.dataId)),u}var qW={kernelName:la,backendName:\"webgpu\",kernelFunc:Ope};function c0(r,t=!1){let e=r.length,o=ht(e),n=r.map((l,m)=>`uniforms.pad${m}[0]`).join(\",\"),s=r.map((l,m)=>`uniforms.pad${m}[0] + uniforms.xShape${e>1?`[${m}]`:\"\"}`).join(\",\"),a=e>1?`${o}(${n})`:`${n}`,i=e>1?`${o}(${s})`:`${s}`,p=e>1?\"any(paddedCoords < start)\":\"paddedCoords < start\",u=e>1?\"any(paddedCoords >= end)\":\"paddedCoords >= end\",c=e>1?[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,e):\"coords\";return`\n let start = ${a};\n let end = ${i};\n if (${p} || ${u}) {\n setOutputAtIndex(index, ${t?0:\"uniforms.constantValue\"});\n } else {\n let coords = paddedCoords - start;\n setOutputAtIndex(index, getX(${c}));\n }\n `}var ey=class{constructor(t,e){this.variableNames=[\"x\"],this.uniforms=\"constantValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e.map((o,n)=>o[0]+t[n]+o[1]),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),e.map((o,n)=>{this.uniforms+=` pad${n} : vec2,`}),this.xShape=t,this.shaderKey=\"pad\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let paddedCoords = getCoordsFromIndex(index);\n ${c0(this.xShape)}\n }\n }\n `}};var Mpe=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{paddings:s,constantValue:a}=o;if(s.every(u=>y.arraysEqual(u,[0,0])))return Ft({inputs:{x:n},backend:e});if(y.sizeFromShape(n.shape)===0){let u=s.map((c,l)=>c[0]+n.shape[l]+c[1]);return kt({backend:e,attrs:{shape:u,value:a,dtype:n.dtype}})}let i=[{type:\"float32\",data:[a]}];s.map(u=>i.push({type:\"int32\",data:[u[0],u[1]]}));let p=new ey(n.shape,s);return e.runWebGPUProgram(p,[n],n.dtype,i)},jW={kernelName:ts,backendName:\"webgpu\",kernelFunc:Mpe};var Lpe=et({opType:fe.POW}),XW={kernelName:rs,backendName:\"webgpu\",kernelFunc:Lpe};function Bpe(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t,s=new ki(fe.PRELU,o.shape,n.shape);return e.runWebGPUProgram(s,[o,n],\"float32\")}var YW={kernelName:os,backendName:\"webgpu\",kernelFunc:Bpe};function zpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;return eo(n,s,a,\"prod\",e)}var QW={kernelName:ns,backendName:\"webgpu\",kernelFunc:zpe};var Vpe=r=>{let{backend:t,attrs:e}=r,{start:o,stop:n,step:s,dtype:a}=e,i=_z(o,n,s,a);return t.makeTensorInfo([i.length],a,i)},ZW={kernelName:ma,backendName:\"webgpu\",kernelFunc:Vpe};var Wpe=et({opType:fe.DIV}),JW={kernelName:hn,backendName:\"webgpu\",kernelFunc:Wpe};var Upe=ye({opType:Z.RECIPROCAL}),eU={kernelName:ss,backendName:\"webgpu\",kernelFunc:Upe};var Gpe=ye({opType:Z.RELU}),tU={kernelName:as,backendName:\"webgpu\",kernelFunc:Gpe};var Hpe=ye({opType:Z.RELU6}),rU={kernelName:ps,backendName:\"webgpu\",kernelFunc:Hpe};var ty=class{constructor(t,e,o){this.variableNames=[\"x\"],this.uniforms=\"adjustHeightWidth : vec2, halfPixelCenters : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t[0],e,o,t[3]],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"resizeBilinear\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let b = coords[0];\n let d = coords[3];\n let rc = coords.yz;\n\n let effectiveInSize = vec2(\n f32(uniforms.xShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.xShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveOutSize = vec2(\n f32(uniforms.outShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.outShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveInputOverOutputRatioRC =\n effectiveInSize / effectiveOutSize;\n\n // Fractional source index\n let sourceFracIndexRC =\n (vec2(rc) + vec2(uniforms.halfPixelCenters)) *\n effectiveInputOverOutputRatioRC - vec2(uniforms.halfPixelCenters);\n\n // Compute the four integer indices.\n let sourceFloorRC = vec2(sourceFracIndexRC);\n let sourceCeilRC = vec2(\n min(vec2(uniforms.xShape.yz) - vec2(1.0), ceil(sourceFracIndexRC)));\n\n let topLeft = getX(b, sourceFloorRC.x, sourceFloorRC.y, d);\n let bottomLeft = getX(b, sourceCeilRC.x, sourceFloorRC.y, d);\n let topRight = getX(b, sourceFloorRC.x, sourceCeilRC.y, d);\n let bottomRight = getX(b, sourceCeilRC.x, sourceCeilRC.y, d);\n\n let fracRC = sourceFracIndexRC - vec2(sourceFloorRC);\n\n let top = topLeft + (topRight - topLeft) * fracRC.y;\n let bottom = bottomLeft + (bottomRight - bottomLeft) * fracRC.y;\n let newValue = top + (bottom - top) * fracRC.x;\n\n setOutputAtIndex(index, newValue);\n }\n }\n `}};function Kpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,size:a,halfPixelCenters:i}=o,[p,u]=a,c=s&&p>1?1:0,l=s&&u>1?1:0,d=[{type:\"float32\",data:[c,l]},{type:\"float32\",data:[i?.5:0]}],f=new ty(n.shape,p,u);return e.runWebGPUProgram(f,[n],\"float32\",d)}var oU={kernelName:us,backendName:\"webgpu\",kernelFunc:Kpe};var ry=class{constructor(t,e){this.variableNames=[\"dy\"],this.uniforms=`effectiveXSize : vec2, effectiveYSize : vec2, heightScale : f32, widthScale : f32,\n invHeightScale : f32, invWidthScale : f32, winHeight : i32, winWidth : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.alignCorners=e,this.shaderKey=`resizeBilinearBackprop_${e}`}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let d = coords[3];\n let r = coords[1];\n let c = coords[2];\n\n var accumulator = 0.0;\n\n // Compute bounds for where in dy we will look\n let startRLerp = floor(f32(r) * uniforms.invHeightScale);\n let startDyR = i32(startRLerp - f32(uniforms.winHeight / 2));\n\n let startCLerp = floor(f32(c) * uniforms.invWidthScale);\n let startDyC = i32(startCLerp - f32(uniforms.winWidth / 2));\n\n // Loop over dy\n for (var dyROffset = 0; dyROffset < uniforms.winHeight; dyROffset++) {\n let dyR = startDyR + dyROffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= uniforms.dyShape[1]) {\n continue;\n }\n\n for (var dyCOffset = 0; dyCOffset < uniforms.winWidth; dyCOffset++) {\n let dyC = startDyC + dyCOffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= uniforms.dyShape[2]) {\n continue;\n }\n\n let dxR = f32(dyR) * uniforms.heightScale;\n let topDxRIndex = i32(floor(dxR));\n let bottomDxRIndex = i32(min(ceil(dxR), f32(uniforms.outShape[1] - 1)));\n let dxRLerp = dxR - f32(topDxRIndex);\n let inverseDxRLerp = 1.0 - dxRLerp;\n\n let dxC = f32(dyC) * uniforms.widthScale;\n let leftDxCIndex = i32(floor(dxC));\n let rightDxCIndex = i32(min(ceil(dxC), f32(uniforms.outShape[2] - 1)));\n let dxCLerp = dxC - f32(leftDxCIndex);\n let inverseDxCLerp = 1.0 - dxCLerp;\n\n if (r == topDxRIndex && c == leftDxCIndex) {\n // topLeft\n accumulator +=\n getDy(b, dyR, dyC, d) * inverseDxRLerp * inverseDxCLerp;\n }\n\n if (r == topDxRIndex && c == rightDxCIndex) {\n // topRight\n accumulator += getDy(b, dyR, dyC, d) * inverseDxRLerp * dxCLerp;\n }\n\n if (r == bottomDxRIndex && c == leftDxCIndex) {\n // bottomLeft\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * inverseDxCLerp;\n }\n\n if (r == bottomDxRIndex && c == rightDxCIndex) {\n // bottomRight\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * dxCLerp;\n }\n }\n }\n // End loop over dy\n\n setOutputAtIndex(index, accumulator);\n }\n }\n `}};function qpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,[,i,p]=n.shape,[,u,c]=s.shape,l=[a&&u>1?i-1:i,a&&c>1?p-1:p],m=[a&&u>1?u-1:u,a&&c>1?c-1:c],d=l[0]/m[0],f=l[1]/m[1],h=1/d,g=1/f,x=Math.ceil(h)*2+2,b=Math.ceil(g)*2+2,C=new ry(n.shape,a),S=[{type:\"int32\",data:l},{type:\"int32\",data:m},{type:\"float32\",data:[d]},{type:\"float32\",data:[f]},{type:\"float32\",data:[h]},{type:\"float32\",data:[g]},{type:\"int32\",data:[x]},{type:\"int32\",data:[b]}];return e.runWebGPUProgram(C,[s],s.dtype,S)}var nU={kernelName:ei,backendName:\"webgpu\",kernelFunc:qpe};var oy=class{constructor(t,e,o,n){this.variableNames=[\"x\"],this.uniforms=\"adjustHeightWidth : vec2, roundBase : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t[0],e,o,t[3]],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.halfPixelCenters=n,this.shaderKey=`resizeNearest_${n}`}getUserCode(){let t;return this.halfPixelCenters?t=\"max((vec2(rc) + vec2(0.5)) * effectiveInputOverOutputRatioRC, vec2(0.0))\":t=\"vec2(rc) * effectiveInputOverOutputRatioRC\",`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let b = coords[0];\n let d = coords[3];\n let rc = coords.yz;\n\n let effectiveInSize = vec2(\n f32(uniforms.xShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.xShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveOutSize = vec2(\n f32(uniforms.outShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.outShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveInputOverOutputRatioRC =\n effectiveInSize / effectiveOutSize;\n\n // Fractional source index\n let sourceFracIndexRC = ${t};\n\n // Compute the coordinators of nearest neighbor point.\n let inputShapeRC = vec2(f32(uniforms.xShape.y), f32(uniforms.xShape.z));\n let sourceNearestRC = vec2(\n min(inputShapeRC - 1.0, floor(sourceFracIndexRC + uniforms.roundBase)));\n let newValue = getX(b, sourceNearestRC.x, sourceNearestRC.y, d);\n\n setOutputAtIndex(index, newValue);\n }\n }\n `}};function jpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,c=s&&p>1?1:0,l=s&&u>1?1:0,d=[{type:\"float32\",data:[c,l]},{type:\"float32\",data:[s?.5:0]}],f=new oy(n.shape,p,u,a);return e.runWebGPUProgram(f,[n],n.dtype,d)}var sU={kernelName:is,backendName:\"webgpu\",kernelFunc:jpe};var ny=class{constructor(t,e){this.variableNames=[\"dy\"],this.uniforms=`effectiveXSize : vec2, effectiveYSize : vec2, invHeightScale : f32, invWidthScale : f32,\n winHeight : i32, winWidth : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.alignCorners=e,this.shaderKey=`resizeNearestNeigborBackprop_${e}`}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let d = coords[3];\n let r = coords[1];\n let c = coords[2];\n\n var accumulator = 0.0;\n\n // Compute bounds for where in dy we will look\n let startRLerp = floor(f32(r) * uniforms.invHeightScale);\n let startDyR = i32(floor(startRLerp - f32(uniforms.winHeight / 2)));\n\n let startCLerp = floor(f32(c) * uniforms.invWidthScale);\n let startDyC = i32(floor(startCLerp - f32(uniforms.winWidth / 2)));\n\n // Loop over dy\n for (var dyROffset = 0; dyROffset < uniforms.winHeight; dyROffset++) {\n let dyR = startDyR + dyROffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= uniforms.dyShape[1]) {\n continue;\n }\n\n for (var dyCOffset = 0; dyCOffset < uniforms.winWidth; dyCOffset++) {\n let dyC = startDyC + dyCOffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= uniforms.dyShape[2]) {\n continue;\n }\n\n let sourceFracRow = f32(uniforms.effectiveXSize[0]) *\n (f32(dyR) / f32(uniforms.effectiveYSize[0]));\n\n let sourceFracCol = f32(uniforms.effectiveXSize[1]) *\n (f32(dyC) / f32(uniforms.effectiveYSize[1]));\n\n let sourceNearestRow =\n i32(min(f32(uniforms.outShape[1] - 1),\n ${this.alignCorners?\"floor(sourceFracRow + 0.5)\":\"floor(sourceFracRow)\"}));\n\n let sourceNearestCol =\n i32(min(f32(uniforms.outShape[2] - 1),\n ${this.alignCorners?\"floor(sourceFracCol + 0.5)\":\"floor(sourceFracCol)\"}));\n\n if (r == sourceNearestRow && c == sourceNearestCol) {\n accumulator += getDy(b, dyR, dyC, d);\n }\n }\n }\n // End loop over dy\n\n setOutputAtIndex(index, accumulator);\n }\n }\n `}};function Xpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,[,i,p]=n.shape,[,u,c]=s.shape,l=[a&&u>1?i-1:i,a&&c>1?p-1:p],m=[a&&u>1?u-1:u,a&&c>1?c-1:c],d=l[0]/m[0],f=l[1]/m[1],h=1/d,g=1/f,x=Math.ceil(h)*2+2,b=Math.ceil(g)*2+2,C=new ny(n.shape,a),S=[{type:\"int32\",data:l},{type:\"int32\",data:m},{type:\"float32\",data:[h]},{type:\"float32\",data:[g]},{type:\"int32\",data:[x]},{type:\"int32\",data:[b]}];return e.runWebGPUProgram(C,[s],s.dtype,S)}var aU={kernelName:Ja,backendName:\"webgpu\",kernelFunc:Xpe};var sy=class{constructor(t){this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=\" axis : vec4,\",this.shaderKey=\"reverse\"}getUserCode(){return`\n \n // Using uniform variables as judging conditions, so the function has\n // coherent execution within all threads.\n fn getReverseCoords(coords : vec4) -> vec4 {\n var reverseCoords = coords;\n if (uniforms.axis[0] == 1) {\n reverseCoords[0] = uniforms.xShape[0] - coords[0] - 1;\n }\n if (uniforms.axis[1] == 1) {\n reverseCoords[1] = uniforms.xShape[1] - coords[1] - 1;\n }\n if (uniforms.axis[2] == 1) {\n reverseCoords[2] = uniforms.xShape[2] - coords[2] - 1;\n }\n if (uniforms.axis[3] == 1) {\n reverseCoords[3] = uniforms.xShape[3] - coords[3] - 1;\n }\n\n return reverseCoords;\n }\n \n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let reverseCoords = getReverseCoords(coords);\n setOutputAtIndex(index, getX(reverseCoords[0],\n reverseCoords[1], reverseCoords[2], reverseCoords[3]));\n }\n }\n `}};function Ype(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o,a=n.shape.length;if(a===0)return Ft({inputs:{x:n},backend:e});let i=n.shape,p=[1,1,1,1];i.forEach((g,x)=>{let b=x+4-a;p[b]=g});let u=y.parseAxisParam(s,n.shape),c=[0,0,0,0];u.forEach(g=>{let x=g+4-a;c[x]=1});let l=[{type:\"int32\",data:c}],m=pe({inputs:{x:n},backend:e,attrs:{shape:p}}),d=new sy(p),f=e.runWebGPUProgram(d,[m],m.dtype,l);e.disposeData(m.dataId);let h=pe({inputs:{x:f},backend:e,attrs:{shape:i}});return e.disposeData(f.dataId),h}var iU={kernelName:cs,backendName:\"webgpu\",kernelFunc:Ype};var ay=class{constructor(t,e){this.outputShape=[],this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=`centerX : f32, centerY : f32, sinRadians : f32,\n cosRadians : f32,`,this.shaderKey=\"rotate\",this.outputShape=t,typeof e==\"number\"?(this.uniforms+=\" fillValue : f32,\",this.fillSnippet=\"var outputValue = uniforms.fillValue;\",this.shaderKey+=\"_float\"):(this.uniforms+=\" fillValue : vec3,\",this.fillSnippet=\"var outputValue = uniforms.fillValue[coords[3]];\",this.shaderKey+=\"_vec3\")}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let coordXFloat = (f32(coords[2]) - uniforms.centerX) *\n uniforms.cosRadians - (f32(coords[1]) - uniforms.centerY) *\n uniforms.sinRadians;\n let coordYFloat = (f32(coords[2]) - uniforms.centerX) *\n uniforms.sinRadians + (f32(coords[1]) - uniforms.centerY) *\n uniforms.cosRadians;\n let coordX = i32(round(coordXFloat + uniforms.centerX));\n let coordY = i32(round(coordYFloat + uniforms.centerY));\n ${this.fillSnippet}\n if(coordX >= 0 && coordX < uniforms.xShape[2] && coordY >= 0 &&\n coordY < uniforms.xShape[1]) {\n outputValue = getX(coords[0], coordY, coordX, coords[3]);\n }\n setOutputAtIndex(index, outputValue);\n }\n }\n `}};var uU={kernelName:As,backendName:\"webgpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{image:o}=r,{radians:n,fillValue:s,center:a}=t,i=e,p=new ay(o.shape,s),[u,c]=w.getImageCenter(a,o.shape[1],o.shape[2]),l=[{type:\"float32\",data:[u]},{type:\"float32\",data:[c]},{type:\"float32\",data:[Math.sin(n)]},{type:\"float32\",data:[Math.cos(n)]}];return typeof s==\"number\"?l.push({type:\"float32\",data:[Number.parseFloat(s.toFixed(2))]}):l.push({type:\"float32\",data:s}),i.runWebGPUProgram(p,[o],o.dtype,l)}};var Qpe=ye({opType:Z.ROUND}),pU={kernelName:ls,backendName:\"webgpu\",kernelFunc:Qpe};var Zpe=ye({opType:Z.RSQRT,cpuKernelImpl:$z}),cU={kernelName:ms,backendName:\"webgpu\",kernelFunc:Zpe};var Va=class{constructor(t,e,o,n,s,a,i,p=!0){this.variableNames=[\"updates\",\"indices\"],this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=a,this.type=i,this.sumDupeIndices=p,this.dispatchLayout=X(t),this.dispatch=H(this.dispatchLayout,t,this.workgroupSize),this.sliceDimGreaterThanOne=e>1,this.shaderKey=`scatter_${o}_${n}_${this.sliceDimGreaterThanOne}_${i}_${p}`;let u=ht(s.length);this.uniforms=`sliceDim : i32, strides: ${u}, updatesSize: i32,`,this.updatesRank=n,this.indicesRank=o}getUserCode(){let t=\"\";this.indicesRank===1?t=\"coords[0]\":this.indicesRank===2&&(t=\"coords[0], j\");let e=`getIndices(${t})`,o=this.sliceDimGreaterThanOne?\"uniforms.strides[j]\":\"uniforms.strides\",n=\"\",s=\"\";this.dispatchLayout.x.length===1?(n=\"flattenedIndex\",s=`\n fn getUpdatesCoordsFromFlatIndex(index : i32) -> i32 {\n return index;\n }\n `):this.dispatchLayout.x.length===2&&(n=\"vec2(flattenedIndex, coords[1])\",s=`\n fn getUpdatesCoordsFromFlatIndex(index : i32) -> vec2 {\n // N.B. |updates| could be a scalar tensor, conceptually representing a\n // 2D tensor with all values equal to that. By design, its size must be\n // the same as |outShape[1]| in one dimension, and |indicesShape[0]|\n // gives the other.\n let sliceSize = uniforms.outShape[1];\n let d0 = index / sliceSize;\n let d1 = index - d0 * sliceSize;\n return vec2(d0, d1);\n }\n `);let i=`getUpdates(${Array.from({length:this.updatesRank},(u,c)=>`coords[${c}]`).join(\", \")})`;return`\n ${s}\n ${G(\"index\")} {\n if (index < uniforms.updatesSize) {\n let coords = getUpdatesCoordsFromFlatIndex(index);\n var flattenedIndex = 0;\n for (var j = 0; j < uniforms.sliceDim; j = j + 1) {\n let indexInside = i32(round(${e}));\n flattenedIndex = flattenedIndex + indexInside * ${o};\n }\n let updateValue =\n ${Nu(this.type)}(${i});\n let flatIndex = getOutputIndexFromCoords(${n});\n\n ${this.sumDupeIndices?Qr(\"&result[flatIndex]\",\"updateValue\",this.type):\"atomicStore(&result[flatIndex], bitcast(updateValue));\"}\n }\n }`}};function Jpe(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n,updates:s}=t,{shape:a}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(s,n,a),m=[l/u,u];if(l===0)return e.makeTensorInfo(a,n.dtype);let d=pe({inputs:{x:n},backend:e,attrs:{shape:[p,i]}}),f=pe({inputs:{x:s},backend:e,attrs:{shape:[p,u]}}),h=f.dtype,g=kt({backend:e,attrs:{shape:m,value:0,dtype:h}}),x=y.sizeFromShape(f.shape),b=[{type:\"int32\",data:[i]},{type:\"int32\",data:c},{type:\"int32\",data:[x]}],C=new Va(f.shape,i,d.shape.length,f.shape.length,c,m,h),S=e.runWebGPUProgram(C,[f,d],h,b,g),k=pe({inputs:{x:S},backend:e,attrs:{shape:a}});return e.disposeData(d.dataId),e.disposeData(f.dataId),e.disposeData(S.dataId),k}var lU={kernelName:ds,backendName:\"webgpu\",kernelFunc:Jpe};var iy=class{constructor(t,e){this.outputShape=[],this.variableNames=[\"sortedSequence\",\"values\"],this.uniforms=\"numInputs : i32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.side=e,this.shaderKey=`search_sorted_${e}`}getUserCode(){return`\n fn findBound(batch: i32, value: f32) -> i32 {\n var left = i32(0);\n var right = uniforms.numInputs;\n while (left < right) {\n var mid = (left + right) / 2;\n if (getSortedSequence(batch, mid) ${this.side===\"left\"?\"<\":\"<=\"} value) {\n left = mid + 1;\n } else {\n right = mid;\n }\n }\n return right;\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let value = getValuesByOutputIndex(index);\n setOutputAtIndexI32(index, findBound(coords[0], value));\n }\n }\n `}};function ece(r){let{inputs:t,backend:e,attrs:o}=r,{sortedSequence:n,values:s}=t,{side:a}=o,i=new iy([s.shape[0],s.shape[1]],a),p=[{type:\"int32\",data:[n.shape[1]]}];return e.runWebGPUProgram(i,[n,s],\"int32\",p)}var mU={kernelName:hs,backendName:\"webgpu\",kernelFunc:ece};var uy=class{constructor(t,e,o){this.variableNames=[\"c\",\"a\",\"b\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.cRank=t,this.rank=o,this.shaderKey=\"select\"}getUserCode(){let t,e;if(this.rank>4)throw Error(`Where for rank ${this.rank} is not yet supported`);if(this.rank===1)e=\"resRC\",t=\"resRC\";else{let n=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],s=[],a=[];for(let i=0;i= 1.0) {\n setOutputAtIndex(index, getA(${e}));\n } else {\n setOutputAtIndex(index, getB(${e}));\n }\n }\n }\n `}};function tce(r){let{inputs:t,backend:e}=r,{condition:o,t:n,e:s}=t,a=new uy(o.shape.length,n.shape,n.shape.length);return e.runWebGPUProgram(a,[o,n,s],dt(n.dtype,s.dtype))}var dU={kernelName:fa,backendName:\"webgpu\",kernelFunc:tce};var rce=ye({opType:Z.SELU}),fU={kernelName:gs,backendName:\"webgpu\",kernelFunc:rce};var oce=ye({opType:Z.SIGMOID}),hU={kernelName:Cs,backendName:\"webgpu\",kernelFunc:oce};var nce=ye({opType:Z.SIGN}),gU={kernelName:bs,backendName:\"webgpu\",kernelFunc:nce};var sce=ye({opType:Z.SIN}),xU={kernelName:xs,backendName:\"webgpu\",kernelFunc:sce};var ace=ye({opType:Z.SINH}),yU={kernelName:ys,backendName:\"webgpu\",kernelFunc:ace};var ice=ye({opType:Z.SOFTPLUS}),bU={kernelName:ws,backendName:\"webgpu\",kernelFunc:ice};var py=class{constructor(t,e,o,n,s,a){this.variableNames=[\"x\"],this.outputShape=[],this.uniforms=\"\",this.workgroupSize=[64,1,1],this.size=!0;let i=new Array(n.length);for(let p=0;p{this.uniforms+=` pad${u} : vec2,`}),this.shaderKey=`spaceToBatchND_${s}`}getUserCode(){let t=ht(this.outputShape.length),e=Zv(this.newDim);return`\n ${cm(this.paddedXShape,\"PaddedX\")}\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let switchedIndex = getIndexFromCoords${this.outputShape.length}D(${t}(${e}), uniforms.reshapedPaddedXShape);\n let paddedCoords = getPaddedXCoordsFromIndex(switchedIndex);\n ${c0(this.xShape,!0)}\n }\n }\n `}};var uce=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,paddings:a}=o;y.assert(n.shape.length<=4,()=>\"spaceToBatchND for rank > 4 with a WebGPU backend not implemented yet\");let i=s.reduce((b,C)=>b*C),p=[[0,0]];p.push(...a);for(let b=1+s.length;bb[0]+n.shape[C]+b[1]),c=w.getReshaped(u,s,i,!1),l=w.getPermuted(c.length,s.length,!1),m=w.getReshapedPermuted(u,s,i,!1),d=y.computeStrides(u),f=new py(n.shape,u,p,c,l,d.length),h=[{type:\"int32\",data:c},{type:\"int32\",data:d}];p.map(b=>h.push({type:\"int32\",data:[b[0],b[1]]}));let g=e.runWebGPUProgram(f,[n],n.dtype,h),x=pe({inputs:{x:g},backend:e,attrs:{shape:m}});return e.disposeData(g.dataId),x},CU={kernelName:ga,backendName:\"webgpu\",kernelFunc:uce};var cy=class{constructor(t,e,o){this.variableNames=[\"input\",\"indices\",\"segmentIds\"],this.outputShape=[],this.uniforms=\"segmentSize : i32, sparseSize : i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=t,this.type=o,this.dispatchLayout=X([e]),this.dispatch=H(this.dispatchLayout,[e],this.workgroupSize),this.shaderKey=\"sparseSegmentSum\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.sparseSize) {\n let indexInSegmentIds = index / uniforms.segmentSize;\n let indexInSegment = index % uniforms.segmentSize;\n let indexInInput = indices[indexInSegmentIds];\n let segmentId = segmentIds[indexInSegmentIds];\n\n let value = input[indexInInput * uniforms.segmentSize + indexInSegment];\n let outIndex = segmentId * uniforms.segmentSize + indexInSegment;\n ${Qr(\"&result[outIndex]\",\"value\",this.type)}\n }\n }\n `}},ly=class{constructor(t,e){this.variableNames=[\"segmentIds\"],this.outputShape=[],this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=[t],this.dispatchLayout=X(e),this.dispatch=H(this.dispatchLayout,e,this.workgroupSize),this.shaderKey=\"sparseSegmentIdCountProgram\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.segmentIdsShape) {\n let segmentId = segmentIds[index];\n ${Qr(\"&result[segmentId]\",\"1\",\"int32\")}\n }\n }\n `}},my=class{constructor(t,e){this.variableNames=[\"segmentSum\",\"sameSegmentIdCount\"],this.outputShape=[],this.uniforms=\"segmentSize : i32\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.type=e,this.dispatchLayout=X(t),this.dispatch=H(this.dispatchLayout,t,this.workgroupSize),this.shaderKey=\"sparseSegmentMean\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let segmentId = index / uniforms.segmentSize;\n let count = sameSegmentIdCount[segmentId];\n if (count != 0) {\n ${this.type===\"float32\"?\"setOutputAtIndex(index, segmentSum[index] / f32(count));\":\"setOutputAtIndexI32(index, segmentSum[index] / count);\"}\n }\n }\n }\n `}};function dy(r,t,e,o=!1,n){let a=y.sizeFromShape(r.shape)/r.shape[0],i=r.dtype,p=y.sizeFromShape(t.shape),u=n.readSync(e.dataId),l=p>0?u[p-1]+1:0,m,d=r.shape.slice();d[0]=l;let f=p*a,h=kt({backend:n,attrs:{shape:d,value:0,dtype:i}});m=new cy(d,f,i);let g=[{type:\"int32\",data:[a]},{type:\"int32\",data:[f]}],x=n.runWebGPUProgram(m,[r,t,e],i,g,h);if(o)return x;let b=kt({backend:n,attrs:{shape:[l],value:0,dtype:\"int32\"}});m=new ly(l,e.shape);let C=n.runWebGPUProgram(m,[e],\"int32\",null,b),S=kt({backend:n,attrs:{shape:d,value:0,dtype:i}});m=new my(d,i),g=[{type:\"int32\",data:[a]}];let k=n.runWebGPUProgram(m,[x,C],i,g,S);return n.disposeData(x.dataId),n.disposeData(C.dataId),k}function pce(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;return dy(o,n,s,!1,e)}var wU={kernelName:ya,backendName:\"webgpu\",kernelFunc:pce};function cce(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;return dy(o,n,s,!0,e)}var SU={kernelName:ba,backendName:\"webgpu\",kernelFunc:cce};var fy=class{constructor(t,e){this.variableNames=[\"A\"],this.workgroupSize=[64,1,1],this.size=!0;let o=new Array(t.length);for(let n=0;n=5)throw Error(`Tile for rank ${r} is not yet supported`);if(r===1)return`(resRC % ${t}aShape)`;let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],o=[];for(let n=0;n=5){let p=e.readSync(n.dataId),u=n.dtype===\"string\"?p.map(m=>y.decodeString(m)):p,c=me(n.shape,n.dtype,u),l=Oz(c,s);return e.makeTensorInfo(l.shape,l.dtype,l.values)}let a=new fy(n.shape,s);return e.runWebGPUProgram(a,[n],n.dtype)}var IU={kernelName:po,backendName:\"webgpu\",kernelFunc:Cm};function mce(r){let{inputs:t,backend:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=t,{outputShape:i}=o,{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=w.calculateShapes(s,n,i),d=!1;if(s.dtype===\"string\"){let R=e.bufferSync(n),D=e.bufferSync(s),P=y.decodeString(e.readSync(a.dataId)[0]),O=Ez(R,D,i,m,c,u,p,l,P,d);return e.makeTensorInfo(i,O.dtype,O.values)}let f=[m/c,c],h=pe({inputs:{x:n},backend:e,attrs:{shape:[u,p]}}),g=s.shape.length?pe({inputs:{x:s},backend:e,attrs:{shape:[u,c]}}):Ft({inputs:{x:s},backend:e}),x=g.dtype,b=e.makeTensorInfo([],x,y.makeZerosTypedArray(1,x)),C=pe({inputs:{x:a},backend:e,attrs:{shape:Array(f.length).fill(1)}}),S=Cm({inputs:{x:C},backend:e,attrs:{reps:f}}),k=y.sizeFromShape([u,c]),_=[{type:\"int32\",data:[p]},{type:\"int32\",data:l},{type:\"int32\",data:[k]}];switch(u){case 0:break;case 1:{let R=new Va([u,c],p,h.shape.length,g.shape.length,l,f,x,d);e.runWebGPUProgram(R,[g,h],x,_,S)}break;default:{let R=new Va([u,c],p,h.shape.length,b.shape.length,l,f,x,d);e.runWebGPUProgram(R,[b,h],x,_,S)}{let R=new Va([u,c],p,h.shape.length,g.shape.length,l,f,x);e.runWebGPUProgram(R,[g,h],x,_,S)}}let E=pe({inputs:{x:S},backend:e,attrs:{shape:i}});return e.disposeData(h.dataId),e.disposeData(g.dataId),e.disposeData(C.dataId),e.disposeData(b.dataId),e.disposeData(S.dataId),E}var vU={kernelName:ks,backendName:\"webgpu\",kernelFunc:mce};function dce(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=o,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=n.shape.length,c=new Array(u).fill(0),l=n.shape.slice();return p.map(m=>{let d=[...l];d[i]=m;let f=Hs({inputs:{x:n},backend:e,attrs:{begin:c,size:d}});return c[i]+=m,f})}var kU={kernelName:xa,backendName:\"webgpu\",kernelFunc:dce};var fce=ye({opType:Z.SQRT}),NU={kernelName:Ss,backendName:\"webgpu\",kernelFunc:fce};var TU={kernelName:Xi,backendName:\"webgpu\",kernelFunc:({inputs:r,backend:t})=>{let{x:e}=r,o=t,n=new Jr(e.shape,Z.SQUARE);return o.runWebGPUProgram(n,[e],e.dtype)}};var hce=et({opType:fe.SQUARED_DIFFERENCE}),_U={kernelName:Ns,backendName:\"webgpu\",kernelFunc:hce};function gce({inputs:r,attrs:t,backend:e}){let{x:o}=r,n=new Jr(o.shape,Z.STEP,\"stepAlpha : f32,\"),s=[{type:\"float32\",data:[t.alpha]}];return e.runWebGPUProgram(n,[o],o.dtype,s)}var $U={kernelName:So,backendName:\"webgpu\",kernelFunc:gce};var hy=class{constructor(t){this.variableNames=[\"x\"],this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]);let e=ht(this.outputShape.length);this.uniforms=`begin : ${e}, strides : ${e}, `,this.shaderKey=\"stridedSlice\"}getUserCode(){let t=this.outputShape.length,e=\"\";if(t===1)e=\"coords * uniforms.strides + uniforms.begin\";else{let n=0;e=this.outputShape.map((s,a)=>(n++,this.outputShape.length===1?`coords * uniforms.strides[${a}] + uniforms.begin[${a}]`:`coords[${n-1}] * uniforms.strides[${a}] + uniforms.begin[${a}]`)).join(\",\")}return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n setOutputAtIndex(index, getX(${e}));\n }\n }\n `}};function xce(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o,{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=pe({inputs:{x:n},backend:e,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let _=ct.computeOutShape(b,C,S),E=Hs({inputs:{x:n},backend:e,attrs:{begin:b,size:_}});k=pe({inputs:{x:E},backend:e,attrs:{shape:f}}),e.disposeData(E.dataId)}else if(e.shouldExecuteOnCPU([n])){let E=e.readSync(n.dataId),R=me(n.shape,n.dtype,E),D=Az(d,R,S,b);k=e.makeTensorInfo(f,n.dtype,D.values)}else{let E=new hy(d),R=[{type:\"int32\",data:b},{type:\"int32\",data:S}],D=e.runWebGPUProgram(E,[n],n.dtype,R);k=pe({inputs:{x:D},backend:e,attrs:{shape:f}}),e.disposeData(D.dataId)}return k}var EU={kernelName:Ts,backendName:\"webgpu\",kernelFunc:xce};function yce(r){let{inputs:t,backend:e,attrs:o}=r,{separator:n,nGramWidths:s,leftPad:a,rightPad:i,padWidth:p,preserveShortSequences:u}=o,{data:c,dataSplits:l}=t,m=e.readSync(c.dataId),d=e.readSync(l.dataId),[f,h]=Fz(m,d,n,s,a,i,p,u);return[e.makeTensorInfo([f.length],\"string\",f),e.makeTensorInfo(l.shape,\"int32\",h)]}var RU={kernelName:Ca,backendName:\"webgpu\",kernelFunc:yce};var bce=et({opType:fe.SUB,cpuKernelImpl:Pz,supportsComplex:!0}),DU={kernelName:_s,backendName:\"webgpu\",kernelFunc:bce};var Cce=ye({opType:Z.TAN}),AU={kernelName:$s,backendName:\"webgpu\",kernelFunc:Cce};var wce=ye({opType:Z.TANH}),FU={kernelName:Es,backendName:\"webgpu\",kernelFunc:wce};function Sce(r){let{inputs:t,backend:e,attrs:o}=r,{tensor:n,indices:s,updates:a}=t,{}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(a,s,n.shape),m=[l/u,u];if(l===0)return e.makeTensorInfo(n.shape,s.dtype);let d=[],f=pe({inputs:{x:s},backend:e,attrs:{shape:[p,i]}});d.push(f);let h=pe({inputs:{x:a},backend:e,attrs:{shape:[p,u]}});d.push(h);let g=pe({inputs:{x:n},backend:e,attrs:{shape:m}});d.push(g);let x=Cm({inputs:{x:g},backend:e,attrs:{reps:Array(m.length).fill(1)}}),b=new Va([p,u],i,f.shape.length,h.shape.length,c,m,n.dtype,!1),C=y.sizeFromShape([p,u]),S=[{type:\"int32\",data:[i]},{type:\"int32\",data:c},{type:\"int32\",data:[C]}],k=e.runWebGPUProgram(b,[h,f],g.dtype,S,x);d.push(k);let _=pe({inputs:{x:k},backend:e,attrs:{shape:n.shape}});return d.forEach(E=>e.disposeData(E.dataId)),_}var PU={kernelName:fs,backendName:\"webgpu\",kernelFunc:Sce};var gy=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=`inputSize : i32, firstPass : i32, negativeInf : f32,\n dir : i32, inc : i32,`,this.shaderKey=\"swap\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let outC = getCoordsFromIndex(index);\n let batch = outC[0];\n let elemIdx = outC[1];\n // We compare elements pair-wise within a group of size 2 * inc.\n // The comparing rule for each group alternates between ascending\n // and descending. Within each group, we compare each pair at\n // positions i and i+inc. To decide whether an element at position i\n // is x0 or x1, we mod it by 2 * inc, if the result is smaller than\n // inc, it is in the first half of the group, we denote it as x0,\n // otherwise we denote it as x1.\n // For example, as shown in the Bitonic top K paper referenced\n // above, Figure5(a) shows that element[1] is in the second half of\n // the group when group size is 2, but it is in the first half of\n // the group when group size is 4.\n let isFirstInPair = elemIdx % (2 * uniforms.inc) < uniforms.inc;\n var i = 0;\n if (isFirstInPair) {\n i = elemIdx;\n } else {\n i = elemIdx - uniforms.inc;\n }\n\n var i0 = 0;\n if (uniforms.firstPass == 1) {\n i0 = i;\n } else {\n i0 = i32(getIndices(batch, i));\n }\n\n var i1 = 0;\n if (uniforms.firstPass == 1) {\n i1 = i + uniforms.inc;\n } else {\n i1 = i32(getIndices(batch, i + uniforms.inc));\n }\n\n var x0 = f32(0.0);\n var x1 = f32(0.0);\n if (i0 < uniforms.inputSize) {\n x0 = getX(batch, i0);\n } else {\n x0 = uniforms.negativeInf;\n }\n if (i1 < uniforms.inputSize) {\n x1 = getX(batch, i1);\n } else {\n x1 = uniforms.negativeInf;\n }\n\n let reverse = elemIdx % (2 * uniforms.dir) >= uniforms.dir;\n let isGreater = x0 > x1 || (x0 == x1 && i1 > i0);\n if (reverse == isGreater) {\n // Elements in opposite order of direction\n let iTemp = i0;\n i0 = i1;\n i1 = iTemp;\n }\n if (isFirstInPair) {\n setOutputAtIndex(index, f32(i0));\n } else {\n setOutputAtIndex(index, f32(i1));\n }\n }\n }\n `}},xy=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=\"inputSize : i32, firstPass : i32, k : i32,\",this.shaderKey=\"merge\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let outC = getCoordsFromIndex(index);\n let batch = outC[0];\n let elemIdx = outC[1];\n // The output size is half of the previous size.\n // If the previous sequence is | | | | _ _ _ _ | | | | _ _ _ _\n // (k=4), we only need to output the indices at positions |, the\n // indices at positions _ can be thrown away, see Figure5(b) After\n // Phase 2 (Merge phase) in the Bitonic Top K paper referenced\n // above.\n // For example, the paper shows we only need to output the orange\n // bars. The output sequence should look like this | | | | | | | |.\n // Because the sequence is halved, to map the output index back to\n // the previous sequence to find the corresponding value, we need\n // to double the index. When we double the index, we basically\n // interpolate a position, so 2i looks like\n // | _ | _ | _ | _ | _ | _ | _. We move the | to the first k\n // position of each 2k positions by - elemIdx % k. E.g. for output\n // at index 4,5,6,7, we want to get the corresponding element at\n // original index 8,9,10,11, for output at index 8,9,10,11,\n // we want to get the corresponding element at original index\n // 16,17,18,19, so on and so forth.\n\n var i = 0;\n if (elemIdx < uniforms.k) {\n i = elemIdx;\n } else {\n i = elemIdx * 2 - elemIdx % uniforms.k;\n }\n var i0 = 0;\n if (uniforms.firstPass == 1) {\n i0 = i;\n } else {\n i0 = i32(getIndices(batch, i));\n }\n var i1 = 0;\n if (uniforms.firstPass == 1) {\n i1 = i + uniforms.k;\n } else {\n i1 = i32(getIndices(batch, i + uniforms.k));\n }\n\n let x0 = getX(batch, i0);\n var x1 = f32(0.0);\n if (i1 < uniforms.inputSize) {\n x1 = getX(batch, i1);\n } else {\n x1 = x0;\n }\n\n if (x0 >= x1) {\n setOutputAtIndex(index, f32(i0));\n } else {\n setOutputAtIndex(index, f32(i1));\n }\n }\n }\n `}};function nl(r,t){t!==null&&r.disposeData(t.dataId)}function OU(r){let t=1;for(;tf===null?[l,l]:[l,f],g=(k,_,E)=>{let R=h(),D=new gy(E),O=[{type:\"int32\",data:[p]},{type:\"int32\",data:[f===null?1:0]},{type:\"float32\",data:[Number.NEGATIVE_INFINITY]},{type:\"int32\",data:[k]},{type:\"int32\",data:[_]}],M=f;f=e.runWebGPUProgram(D,R,\"int32\",O),nl(e,M)};for(let k=1;k=1;E/=2)g(_,E,[c,d])}for(let k=d;k>m;k/=2){let _=h(),E=new xy([c,k/2]),D=[{type:\"int32\",data:[p]},{type:\"int32\",data:[f===null?1:0]},{type:\"int32\",data:[m]}],P=f;f=e.runWebGPUProgram(E,_,\"int32\",D),nl(e,P);let O=m/2,M=O*2;for(let L=O;L>=1;L/=2)g(M,L,f.shape)}let x=f;f=Hs({inputs:{x:f},backend:e,attrs:{begin:0,size:[c,s]}}),nl(e,x);let b=u0({inputs:{x:l,indices:f},backend:e,attrs:{axis:1,batchDims:1}});nl(e,l);let C=i.slice(0,-1);C.push(s),x=f,f=pe({inputs:{x:f},attrs:{shape:C},backend:e}),nl(e,x);let S=b;return b=pe({inputs:{x:b},attrs:{shape:C},backend:e}),nl(e,S),[b,f]}var MU={kernelName:Rs,backendName:\"webgpu\",kernelFunc:Ice};var yy=class{constructor(t){this.variableNames=[\"Image\",\"Transforms\"],this.uniforms=\"interpolationModeId : i32, fillModeId : i32, fillValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"transform\"}getUserCode(){return`\n fn mapCoord(outCoord : f32, len : f32) -> f32{\n var inCoord = outCoord;\n if(uniforms.fillModeId == 2) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz2 = 2.0 * len;\n if (inCoord < sz2) {\n inCoord = sz2 * f32(i32(f32(-inCoord / sz2))) +\n inCoord;\n }\n if (inCoord < -len) {\n inCoord = inCoord + sz2;\n } else {\n inCoord = -inCoord - 1.0;\n }\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz2 = 2.0 * len;\n inCoord = inCoord - sz2 * f32(i32(f32(inCoord / sz2)));\n if (inCoord >= len) {\n inCoord = sz2 - inCoord - 1.0;\n }\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (uniforms.fillModeId == 3) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz = len - 1.0;\n inCoord = inCoord + len * (f32(i32(f32(-inCoord / sz))) + 1.0);\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz = len - 1.0;\n inCoord = inCoord - len * f32(i32(f32(inCoord / sz)));\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (uniforms.fillModeId == 4) {\n return clamp(outCoord, 0.0, len - 1.0);\n }\n return outCoord;\n }\n fn readWithFillValue(batch : i32, coordY : i32, coordX : i32,\n channel : i32) -> f32 {\n var outputValue : f32;\n if (0 <= coordY && coordY < uniforms.imageShape[1] && 0 <= coordX && coordX < uniforms.imageShape[2]) {\n outputValue = getImage(batch, coordY, coordX, channel);\n } else {\n outputValue = uniforms.fillValue;\n }\n return outputValue;\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n var outputValue : f32;\n let batch = coords[0];\n let x = coords[2];\n let y = coords[1];\n let channel = coords[3];\n let xf = f32(x);\n let yf = f32(y);\n let a1 = getTransforms(batch, 0);\n let a2 = getTransforms(batch, 1);\n let a3 = getTransforms(batch, 2);\n let b1 = getTransforms(batch, 3);\n let b2 = getTransforms(batch, 4);\n let b3 = getTransforms(batch, 5);\n let c1 = getTransforms(batch, 6);\n let c2 = getTransforms(batch, 7);\n let projection = c1 * xf + c2 * yf + 1.0;\n if (projection == 0.0) {\n outputValue = uniforms.fillValue;\n } else {\n let inX = (a1 * xf + a2 * yf + a3) / projection;\n let inY = (b1 * xf + b2 * yf + b3) / projection;\n let mapX = mapCoord(inX, f32(uniforms.imageShape[2]));\n let mapY = mapCoord(inY, f32(uniforms.imageShape[1]));\n\n if (uniforms.interpolationModeId == 1) {\n let coordY = i32(round(mapY));\n let coordX = i32(round(mapX));\n outputValue = readWithFillValue(batch, coordY, coordX,\n channel);\n } else {\n let yFloor = floor(mapY);\n let xFloor = floor(mapX);\n let yCeil = yFloor + 1.0;\n let xCeil = xFloor + 1.0;\n let valueYFloor = (xCeil - mapX) *\n readWithFillValue(batch, i32(yFloor), i32(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, i32(yFloor), i32(xCeil), channel);\n let valueYCeil = (xCeil - mapX) *\n readWithFillValue(batch, i32(yCeil), i32(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, i32(yCeil), i32(xCeil), channel);\n outputValue = (yCeil - mapY) * valueYFloor +\n (mapY - yFloor) * valueYCeil;\n }\n }\n setOutputAtIndex(index, outputValue);\n }\n }\n `}};function vce(r){let{inputs:t,backend:e,attrs:o}=r,{image:n,transforms:s}=t,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=o,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=new yy(g),b=a===\"nearest\"?1:2,C;switch(i){case\"constant\":C=1;break;case\"reflect\":C=2;break;case\"wrap\":C=3;break;case\"nearest\":C=4;break;default:C=1;break}let S=[{type:\"int32\",data:[b]},{type:\"int32\",data:[C]},{type:\"float32\",data:[p]}];return e.runWebGPUProgram(x,[n,s],\"float32\",S)}var LU={kernelName:Ds,backendName:\"webgpu\",kernelFunc:vce};function kce(r){let{inputs:t,backend:e,attrs:o}=r,{value:n}=t,{axis:s}=o;s<0&&(s+=n.shape.length);let a=n,i=a.shape.length,p=n.shape[s],u=new Array(i-1),c=0;for(let h=0;he.disposeData(h.dataId)),f}var BU={kernelName:wa,backendName:\"webgpu\",kernelFunc:kce};var by=class{constructor(t,e,o){if(this.outputShape=[],this.variableNames=[\"x\",\"segmentIds\"],this.uniforms=\"numSegments : i32, xSize: i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=e,this.dispatchLayout=X(t),this.dispatch=H(this.dispatchLayout,t,this.workgroupSize),o!==\"float32\"&&o!==\"int32\")throw new Error(`UnsortedSegmentSum only supports float32 and int32\n types, does not support ${o} type.`);this.type=o,this.shaderKey=\"unsortedSegmentSum\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.xSize) {\n let coords = getXCoordsFromIndex(index);\n let b = coords[0];\n let inCol = coords[1];\n\n let segmentId = i32(getSegmentIds(inCol));\n if (segmentId >= 0) {\n let flatIndex = b * uniforms.numSegments + segmentId % uniforms.numSegments;\n let value = getX(b, inCol);\n\n ${Qr(\"&result[flatIndex]\",\"value\",this.type)}\n }\n }\n }\n `}};function Nce(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,segmentIds:s}=t,{numSegments:a}=o,i=n.shape.length,p=[],u=0,c=w.getAxesPermutation([u],i),l=n;c!=null&&(l=yr({inputs:{x:n},backend:e,attrs:{perm:c}}),p.push(l),u=w.getInnerMostAxes(1,i)[0]);let m=w.segment_util.computeOutShape(l.shape,u,a),d=y.sizeFromShape([l.shape[u]]),f=pe({inputs:{x:l},backend:e,attrs:{shape:[-1,d]}});p.push(f);let h=n.dtype,g=[f.shape[0],a],x=kt({backend:e,attrs:{shape:g,value:0,dtype:h}}),b=new by(f.shape,g,h),C=[{type:\"int32\",data:[a]},{type:\"int32\",data:[y.sizeFromShape(f.shape)]}],S=e.runWebGPUProgram(b,[f,s],h,C,x),k=pe({inputs:{x:S},backend:e,attrs:{shape:m}});p.push(S);let _=k;if(c!=null){p.push(k);let E=w.getUndoAxesPermutation(c);_=yr({inputs:{x:_},backend:e,attrs:{perm:E}})}return p.forEach(E=>e.disposeData(E.dataId)),_}var zU={kernelName:Ji,backendName:\"webgpu\",kernelFunc:Nce};var Tce=[rz,Bz,zz,Vz,Wz,Uz,Hz,Kz,qz,jz,Xz,Yz,Qz,Zz,Jz,rV,oV,nV,sV,aV,uV,pV,cV,fV,hV,gV,nz,yV,CV,wV,SV,IV,vV,kV,NV,TV,_V,$V,DV,AV,FV,PV,MV,LV,OV,BV,zV,VV,WV,UV,KV,qV,jV,XV,YV,QV,ZV,JV,eW,ez,tW,nW,rW,oW,sW,aW,iW,uW,pW,cW,lW,oz,mW,bV,dW,fW,hW,gW,xW,yW,bW,wW,CW,SW,IW,vW,NW,TW,eV,_W,$W,DW,EW,RW,AW,tV,FW,PW,OW,MW,BW,GV,zW,VW,WW,lV,UW,KW,qW,jW,XW,YW,QW,ZW,mV,JW,eU,tU,rU,tz,oU,nU,sU,aU,iU,uU,pU,cU,lU,mU,dU,fU,hU,gU,xU,yU,iV,$U,EU,RU,LW,bU,CU,wU,SU,vU,kU,NU,TU,_U,DU,HV,AU,FU,PU,IU,MU,LU,Gz,BU,zU,GW];for(let r of Tce)ri(r);var VU=\"4.11.0\",_ce=\"4.11.0\",$ce=\"4.11.0\",Ece=\"4.11.0\",Rce=\"4.11.0\",Dce=\"4.11.0\",Ace={tfjs:VU,\"tfjs-core\":VU,\"tfjs-converter\":_ce,\"tfjs-backend-cpu\":$ce,\"tfjs-backend-webgl\":Ece,\"tfjs-backend-wasm\":Rce,\"tfjs-backend-webgpu\":Dce};export{Xs as Abs,Wo as Acos,Uo as Acosh,np as AdadeltaOptimizer,sp as AdagradOptimizer,ap as AdamOptimizer,ip as AdamaxOptimizer,uo as Add,Go as AddN,Ho as All,Ko as Any,Ys as ArgMax,Qs as ArgMin,qo as Asin,jo as Asinh,Xo as Atan,Qo as Atan2,Yo as Atanh,Zo as AvgPool,Zs as AvgPool3D,Ai as AvgPool3DGrad,Di as AvgPoolGrad,pm as BackendWasm,Jo as BatchMatMul,Js as BatchToSpaceND,en as Bincount,ja as BitwiseAnd,ea as BroadcastArgs,Bce as BroadcastTo,bo as Cast,tn as Ceil,Co as ClipByValue,Fi as Complex,Pi as ComplexAbs,ta as Concat,rn as Conv2D,Oi as Conv2DBackpropFilter,on as Conv2DBackpropInput,nn as Conv3D,Xa as Conv3DBackpropFilterV2,sn as Conv3DBackpropInputV2,an as Cos,un as Cosh,ln as CropAndResize,pn as Cumprod,cn as Cumsum,zo as DataStorage,ra as DenseBincount,mn as DepthToSpace,dn as DepthwiseConv2dNative,Mi as DepthwiseConv2dNativeBackpropFilter,Li as DepthwiseConv2dNativeBackpropInput,oa as Diag,fn as Dilation2D,zi as Dilation2DBackpropFilter,Bi as Dilation2DBackpropInput,Pu as Draw,nw as ENV,Vi as Einsum,gn as Elu,Ya as EluGrad,hl as Environment,yn as Equal,xn as Erf,bn as Exp,na as ExpandDims,Cn as Expm1,Wi as FFT,sa as Fill,wn as FlipLeftRight,Sn as Floor,In as FloorDiv,Mu as FromPixels,vn as FusedBatchNorm,vo as FusedConv2D,ko as FusedDepthwiseConv2D,kp as GPGPUContext,kn as GatherNd,aa as GatherV2,Bl as GraphModel,Nn as Greater,Tn as GreaterEqual,Ui as IFFT,wo as Identity,Gi as Imag,_n as IsFinite,$n as IsInf,En as IsNan,ao as KernelBackend,zn as LRN,Qa as LRNGrad,Rn as LeakyRelu,Dn as Less,An as LessEqual,Fn as LinSpace,Pn as Log,On as Log1p,zce as LogSoftmax,Mn as LogicalAnd,Ln as LogicalNot,Bn as LogicalOr,$0 as LogicalXor,Vce as LowerBound,xu as MathBackendCPU,wu as MathBackendWebGL,Wce as MatrixBandPart,Vn as Max,Un as MaxPool,ia as MaxPool3D,Ki as MaxPool3DGrad,Hi as MaxPoolGrad,ua as MaxPoolWithArgmax,Wn as Maximum,Gn as Mean,Hn as Min,Kn as Minimum,qn as MirrorPad,jn as Mod,up as MomentumOptimizer,Xn as Multinomial,Yn as Multiply,pa as Neg,Zn as NonMaxSuppressionV3,Za as NonMaxSuppressionV4,Jn as NonMaxSuppressionV5,Qn as NotEqual,kw as OP_SCOPE_SUFFIX,es as OneHot,ca as OnesLike,Nr as Optimizer,Pl as OptimizerConstructors,la as Pack,ts as PadV2,Uce as Pool,rs as Pow,os as Prelu,ns as Prod,pp as RMSPropOptimizer,Qp as RaggedGather,Zp as RaggedRange,Jp as RaggedTensorToTensor,ma as Range,hw as Rank,qi as Real,hn as RealDiv,ss as Reciprocal,Rt as Reduction,as as Relu,ps as Relu6,da as Reshape,us as ResizeBilinear,ei as ResizeBilinearGrad,is as ResizeNearestNeighbor,Ja as ResizeNearestNeighborGrad,cs as Reverse,As as RotateWithOffset,ls as Round,ms as Rsqrt,mi as SGDOptimizer,ds as ScatterNd,hs as SearchSorted,fa as Select,gs as Selu,Cs as Sigmoid,bs as Sign,xs as Sin,ys as Sinh,ha as Slice,vs as Softmax,ws as Softplus,ga as SpaceToBatchND,ji as SparseFillEmptyRows,ti as SparseReshape,ya as SparseSegmentMean,ba as SparseSegmentSum,ks as SparseToDense,xa as SplitV,Ss as Sqrt,Xi as Square,Ns as SquaredDifference,Ou as StaticRegexReplace,So as Step,Ts as StridedSlice,Ca as StringNGrams,Yi as StringSplit,Qi as StringToHashBucketFast,_s as Sub,Is as Sum,$s as Tan,Es as Tanh,ut as Tensor,tt as TensorBuffer,fs as TensorScatterUpdate,po as Tile,Rs as TopK,Ds as Transform,co as Transpose,Zi as Unique,wa as Unpack,Ji as UnsortedSegmentSum,Gce as UpperBound,oi as Variable,Tu as WebGPUBackend,Sa as ZerosLike,Io as _FusedMatMul,Jt as abs,kk as acos,Nk as acosh,Ce as add,Tk as addN,_k as all,$k as any,Ek as argMax,Rk as argMin,Dk as asin,Ak as asinh,Fk as atan,Pk as atan2,Ok as atanh,fd as avgPool,Bk as avgPool3d,vde as backend,w as backend_util,zk as basicLSTMCell,au as batchNorm,Wk as batchNorm2d,Uk as batchNorm3d,Gk as batchNorm4d,hd as batchToSpaceND,gd as bincount,Hk as bitwiseAnd,E6 as booleanMaskAsync,Kk as broadcastArgs,iu as broadcastTo,Ir as broadcast_util,oT as browser,me as buffer,We as cast,qk as ceil,jk as clipByValue,Ur as clone,Er as complex,bt as concat,Xk as concat1d,Yk as concat2d,Qk as concat3d,Zk as concat4d,Jk as conv1d,uu as conv2d,e2 as conv2dTranspose,t2 as conv3d,o2 as conv3dTranspose,Zce as copyRegisteredKernels,n2 as cos,s2 as cosh,Rl as cosineWindow,a2 as cumprod,i2 as cumsum,vr as customGrad,u2 as denseBincount,Pw as deprecationWarn,p2 as depthToSpace,lc as depthwiseConv2d,A5 as deregisterOp,ou as device_util,c2 as diag,l2 as dilation2d,dde as disableDeprecationWarnings,Mt as dispose,fde as disposeVariables,je as div,d2 as divNoNan,f2 as dot,W6 as dropout,pu as einsum,Cd as elu,mde as enableDebugMode,lde as enableProdMode,Qw as enclosingPowerOfTwo,pr as engine,h2 as ensureShape,A as env,bd as equal,g2 as erf,b2 as euclideanNorm,$o as exp,Ms as expandDims,C2 as expm1,wd as eye,fc as fft,Ea as fill,Sde as findBackend,Ide as findBackendFactory,Sd as floor,dd as floorDiv,MD as forceHalfFloat,Zw as fused,Id as gather,z6 as gatherND,af as gather_util,Cde as getBackend,iw as getGradient,tc as getKernel,Ym as getKernelsForBackend,Zse as getThreadsCount,cv as gpgpu_util,AK as grad,FK as grads,qu as greater,vd as greaterEqual,Ju as ifft,lu as imag,Kj as image,G6 as inTopKAsync,fi as io,Kd as irfft,w2 as isFinite,S2 as isInf,I2 as isNaN,Rr as keep,Wt as kernel_impls,kd as leakyRelu,_l as less,mc as lessEqual,qj as linalg,v2 as linspace,$8 as loadGraphModel,E8 as loadGraphModelSync,k2 as localResponseNormalization,pi as log,Nd as log1p,N2 as logSigmoid,T2 as logSoftmax,$d as logSumExp,ju as logicalAnd,Ed as logicalNot,Rd as logicalOr,_2 as logicalXor,jj as losses,$2 as lowerBound,Ze as matMul,JN as math,Ra as max,Ad as maxPool,E2 as maxPool3d,R2 as maxPoolWithArgmax,Fd as maximum,Xu as mean,hde as memory,D2 as meshgrid,Tl as min,Yu as minimum,A2 as mirrorPad,F2 as mod,P2 as moments,A6 as movingAverage,se as mul,O2 as multiRNNCell,M2 as multinomial,cr as neg,pS as nextFrame,Ku as norm,Pd as notEqual,El as oneHot,Da as ones,L2 as onesLike,N as op,B2 as outerProduct,Aa as pad,z2 as pad1d,V2 as pad2d,W2 as pad3d,U2 as pad4d,G2 as pool,ui as pow,Md as prelu,md as print,H2 as prod,gde as profile,K2 as raggedGather,q2 as raggedRange,j2 as raggedTensorToTensor,X2 as rand,g1 as randomGamma,Ud as randomNormal,x1 as randomStandardNormal,dc as randomUniform,y1 as randomUniformInt,mu as range,bde as ready,ci as real,b1 as reciprocal,su as registerBackend,Xce as registerGradient,ri as registerKernel,D5 as registerOp,du as relu,Gd as relu6,wde as removeBackend,W as reshape,mo as reverse,C1 as reverse1d,w1 as reverse2d,S1 as reverse3d,I1 as reverse4d,hc as rfft,Hd as round,v1 as rsqrt,ke as scalar,P6 as scatterND,hu as scatter_util,$l as searchSorted,k1 as selu,N1 as separableConv2d,WN as serialization,yde as setBackend,kde as setPlatform,Qse as setThreadsCount,Xse as setWasmPath,Yse as setWasmPaths,vI as setWebGLContext,T1 as setdiff1dAsync,Tc as shared,$a as sigmoid,_1 as sign,Hj as signal,$1 as sin,E1 as sinh,Xe as slice,R1 as slice1d,D1 as slice2d,A1 as slice3d,F1 as slice4d,ct as slice_util,P1 as softmax,_d as softplus,Od as spaceToBatchND,Xj as sparse,L6 as sparseToDense,Gj as spectral,li as split,Dr as sqrt,er as square,qd as squaredDifference,gc as squeeze,kr as stack,jd as step,O1 as stridedSlice,Yj as string,Te as sub,ot as sum,ni as sumOutType,M1 as tan,Nl as tanh,ur as tensor,tr as tensor1d,fu as tensor2d,Xd as tensor3d,L1 as tensor4d,B1 as tensor5d,z1 as tensor6d,W1 as tensorScatterUpdate,ek as tensor_util,h1 as test_util,De as tidy,cu as tile,xde as time,U1 as topk,TGe as train,yc as transpose,G1 as truncatedNormal,H1 as unique,Qce as unregisterGradient,Yce as unregisterKernel,K1 as unsortedSegmentSum,fo as unstack,dt as upcastType,q1 as upperBound,y as util,PK as valueAndGrad,OK as valueAndGrads,j1 as variable,zw as variableGrads,Ace as version,D8 as version_converter,_X as version_core,cY as version_cpu,Jse as version_wasm,s9 as version_webgl,Cat as webgl,Ac as webgl_util,Yv as webgpu_util,lo as where,Qd as whereAsync,Gr as zeros,Ht as zerosLike};\n", "import type { Config } from '../exports';\n\n/**\n * Simple helper functions used accross codebase\n */\n\n// helper function: wrapper around console output\nexport function log(...msg): void {\n const dt = new Date();\n const ts = `${dt.getHours().toString().padStart(2, '0')}:${dt.getMinutes().toString().padStart(2, '0')}:${dt.getSeconds().toString().padStart(2, '0')}.${dt.getMilliseconds().toString().padStart(3, '0')}`;\n if (msg) console.log(ts, 'Human:', ...msg); // eslint-disable-line no-console\n}\n\n// helper function: join two paths\nexport function join(folder: string, file: string): string {\n const separator = folder.endsWith('/') ? '' : '/';\n const skipJoin = file.startsWith('.') || file.startsWith('/') || file.startsWith('http:') || file.startsWith('https:') || file.startsWith('file:');\n const path = skipJoin ? `${file}` : `${folder}${separator}${file}`;\n if (!path.toLocaleLowerCase().includes('.json')) throw new Error(`modelpath error: expecting json file: ${path}`);\n return path;\n}\n\n// helper function: gets elapsed time on both browser and nodejs\nexport const now = () => {\n if (typeof performance !== 'undefined') return performance.now();\n return parseInt((Number(process.hrtime.bigint()) / 1000 / 1000).toString());\n};\n\n// helper function: checks current config validity\nexport function validate(defaults: Partial, config: Partial, parent = 'config', msgs: { reason: string, where: string, expected?: string }[] = []) {\n for (const key of Object.keys(config)) {\n if (typeof config[key] === 'object') {\n validate(defaults[key], config[key], key, msgs);\n } else {\n const defined = defaults && (typeof defaults[key] !== 'undefined');\n if (!defined) msgs.push({ reason: 'unknown property', where: `${parent}.${key} = ${config[key]}` });\n const same = defaults && typeof defaults[key] === typeof config[key];\n if (defined && !same) msgs.push({ reason: 'property type mismatch', where: `${parent}.${key} = ${config[key]}`, expected: typeof defaults[key] });\n }\n // ok = ok && defined && same;\n }\n if (config.debug && parent === 'config' && msgs.length > 0) log('invalid configuration', msgs);\n return msgs;\n}\n\n// helper function: perform deep merge of multiple objects so it allows full inheritance with overrides\nexport function mergeDeep(...objects) {\n const isObject = (obj) => obj && typeof obj === 'object';\n return objects.reduce((prev, obj) => {\n Object.keys(obj || {}).forEach((key) => {\n const pVal = prev[key];\n const oVal = obj[key];\n if (Array.isArray(pVal) && Array.isArray(oVal)) prev[key] = pVal.concat(...oVal);\n else if (isObject(pVal) && isObject(oVal)) prev[key] = mergeDeep(pVal, oVal);\n else prev[key] = oVal;\n });\n return prev;\n }, {});\n}\n\n// helper function: return min and max from input array\nexport const minmax = (data: number[]) => data.reduce((acc: number[], val) => {\n acc[0] = (acc[0] === undefined || val < acc[0]) ? val : acc[0];\n acc[1] = (acc[1] === undefined || val > acc[1]) ? val : acc[1];\n return acc;\n}, []);\n\n// helper function: async wait\nexport async function wait(time: number) {\n const waiting = new Promise((resolve) => { setTimeout(() => resolve(true), time); });\n await waiting;\n}\n", "/* eslint-disable no-multi-spaces */\n\n/** Possible TensorFlow backends */\nexport type BackendEnum = '' | 'cpu' | 'wasm' | 'webgl' | 'humangl' | 'tensorflow' | 'webgpu';\n\n/** Possible values for `human.warmup` */\nexport type WarmupEnum = '' | 'none' | 'face' | 'full' | 'body';\n\n/** Possible segmentation model behavior */\nexport type SegmentationEnum = 'default' | 'alpha' | 'foreground' | 'state'\n\n/** Generic config type inherited by all module types */\nexport interface GenericConfig {\n /** is module enabled? */\n enabled: boolean,\n /** path to model json file (relative to `modelBasePath` */\n modelPath: string,\n /** how many max frames to go without re-running model if cached results are acceptable\n * for two-phase models such as face and hand caching applies to bounding boxes detection only */\n skipFrames: number,\n /** how many max milliseconds to go without re-running model if cached results are acceptable\n * for two-phase models such as face and hand caching applies to bounding boxes detection only */\n skipTime: number,\n}\n\n/** Detector part of face configuration */\nexport interface FaceDetectorConfig extends GenericConfig {\n /** is face rotation correction performed after detecting face?\n * used to correctly analyze faces under high angles\n */\n rotation: boolean,\n /** maximum number of detected faces */\n maxDetected: number,\n /** minimum confidence for a detected face before results are discarded */\n minConfidence: number,\n /** minimum size in pixels of a detected face box before resutls are discared */\n minSize: number,\n /** minimum overlap between two detected faces before one is discarded */\n iouThreshold: number,\n /** should child models perform on masked image of a face */\n mask: boolean,\n /** should face detection return processed and cropped face tensor that can with an external model for addtional processing?\n * if enabled it must be manually deallocated to avoid memory leak */\n return: boolean,\n}\n\n/** Mesh part of face configuration */\nexport interface FaceMeshConfig extends GenericConfig {\n /** Keep detected faces that cannot be verified using facemesh */\n keepInvalid: boolean\n}\n\n/** Iris part of face configuration */\nexport interface FaceIrisConfig extends GenericConfig {}\n\n/** Attention part of face configuration */\nexport interface FaceAttentionConfig extends GenericConfig {}\n\n/** Description or face embedding part of face configuration\n * - also used by age and gender detection\n */\nexport interface FaceDescriptionConfig extends GenericConfig {\n /** minimum confidence for a detected face before results are discarded */\n minConfidence: number,\n}\n\n/** Emotion part of face configuration */\nexport interface FaceEmotionConfig extends GenericConfig {\n /** minimum confidence for a detected face before results are discarded */\n minConfidence: number,\n}\n\n/** Anti-spoofing part of face configuration */\nexport interface FaceAntiSpoofConfig extends GenericConfig {}\n\n/** Liveness part of face configuration */\nexport interface FaceLivenessConfig extends GenericConfig {}\n\n/** Gear part of face configuration */\nexport interface FaceGearConfig extends GenericConfig {\n /** minimum confidence for a detected race before results are discarded */\n minConfidence: number,\n}\n\n/** Configures all face-specific options: face detection, mesh analysis, age, gender, emotion detection and face description */\nexport interface FaceConfig extends GenericConfig {\n detector: Partial,\n mesh: Partial,\n attention: Partial,\n iris: Partial,\n description: Partial,\n emotion: Partial,\n antispoof: Partial,\n liveness: Partial,\n gear: Partial,\n}\n\n/** Configures all body detection specific options */\nexport interface BodyConfig extends GenericConfig {\n /** maximum number of detected bodies */\n maxDetected: number,\n /** minimum confidence for a detected body before results are discarded */\n minConfidence: number,\n /* experimental\n /** experimental: detector used for body model before actual analysis\n detector?: {\n /** experimental: enable body detector before body landmarks\n enabled: boolean,\n /** experimental: path to optional body detector model json file\n modelPath: string,\n /** experimental: minimum confidence for a detected body before results are discarded\n minConfidence: number,\n /** experimental: minimum overlap between two detected bodies before one is discarded\n iouThreshold: number\n },\n */\n}\n\n/** Configures all hand detection specific options */\nexport interface HandConfig extends GenericConfig {\n /** should hand rotation correction be performed after hand detection? */\n rotation: boolean,\n /** minimum confidence for a detected hand before results are discarded */\n minConfidence: number,\n /** minimum overlap between two detected hands before one is discarded */\n iouThreshold: number,\n /** maximum number of detected hands */\n maxDetected: number,\n /** should hand landmarks be detected or just return detected hand box */\n landmarks: boolean,\n detector: {\n /** path to hand detector model json */\n modelPath?: string,\n },\n skeleton: {\n /** path to hand skeleton model json */\n modelPath?: string,\n },\n}\n\n/** Configures all object detection specific options */\nexport interface ObjectConfig extends GenericConfig {\n /** minimum confidence for a detected objects before results are discarded */\n minConfidence: number,\n /** minimum overlap between two detected objects before one is discarded */\n iouThreshold: number,\n /** maximum number of detected objects */\n maxDetected: number,\n}\n\n/** Configures all body segmentation module\n * removes background from input containing person\n * if segmentation is enabled it will run as preprocessing task before any other model\n * alternatively leave it disabled and use it on-demand using human.segmentation method which can\n * remove background or replace it with user-provided background\n*/\nexport interface SegmentationConfig extends GenericConfig {\n /** downsample ratio, adjust to reflect approximately how much of input is taken by body */\n ratio: number,\n /** possible rvm segmentation mode */\n mode: SegmentationEnum,\n}\n\n/** Run input through image filters before inference\n * - available only in Browser environments\n * - image filters run with near-zero latency as they are executed on the GPU using WebGL\n*/\nexport interface FilterConfig {\n /** are image filters enabled? */\n enabled: boolean,\n /** perform image histogram equalization\n * - equalization is performed on input as a whole and detected face before its passed for further analysis\n */\n equalization: boolean,\n /** resize input width\n * - if both width and height are set to 0, there is no resizing\n * - if just one is set, second one is scaled automatically\n * - if both are set, values are used as-is\n */\n width: number,\n /** resize input height\n * - if both width and height are set to 0, there is no resizing\n * - if just one is set, second one is scaled automatically\n * - if both are set, values are used as-is\n */\n height: number,\n /** return processed canvas imagedata in result */\n return: boolean,\n /** flip input as mirror image */\n flip: boolean,\n /** apply auto-brighness */\n autoBrightness: boolean,\n /** range: -1 (darken) to 1 (lighten) */\n brightness: number,\n /** range: -1 (reduce contrast) to 1 (increase contrast) */\n contrast: number,\n /** range: 0 (no sharpening) to 1 (maximum sharpening) */\n sharpness: number,\n /** range: 0 (no blur) to N (blur radius in pixels) */\n blur: number\n /** range: -1 (reduce saturation) to 1 (increase saturation) */\n saturation: number,\n /** range: 0 (no change) to 360 (hue rotation in degrees) */\n hue: number,\n /** image negative */\n negative: boolean,\n /** image sepia colors */\n sepia: boolean,\n /** image vintage colors */\n vintage: boolean,\n /** image kodachrome colors */\n kodachrome: boolean,\n /** image technicolor colors */\n technicolor: boolean,\n /** image polaroid camera effect */\n polaroid: boolean,\n /** range: 0 (no pixelate) to N (number of pixels to pixelate) */\n pixelate: number,\n}\n\n/** Controlls gesture detection */\nexport interface GestureConfig {\n /** is gesture detection enabled? */\n enabled: boolean,\n}\n/**\n * Configuration interface definition for **Human** library\n * Contains all configurable parameters\n * Defaults: [config](https://github.com/vladmandic/human/blob/main/src/config.ts#L262)\n */\nexport interface Config {\n /** Backend used for TFJS operations\n * valid build-in backends are:\n * - Browser: `cpu`, `wasm`, `webgl`, `humangl`, `webgpu`\n * - NodeJS: `cpu`, `wasm`, `tensorflow`\n * default: `webgl` for browser and `tensorflow` for nodejs\n */\n backend: BackendEnum,\n\n /** Path to *.wasm files if backend is set to `wasm`\n *\n * default: auto-detects to link to CDN `jsdelivr` when running in browser\n */\n wasmPath: string,\n\n /** Force WASM loader to use platform fetch\n *\n * default: false\n */\n wasmPlatformFetch: boolean,\n\n /** Print debug statements to console\n *\n * default: `true`\n */\n debug: boolean,\n\n /** Perform model loading and inference concurrently or sequentially\n *\n * default: `true`\n */\n async: boolean,\n\n /** What to use for `human.warmup()`\n * - warmup pre-initializes all models for faster inference but can take significant time on startup\n * - used by `webgl`, `humangl` and `webgpu` backends\n *\n * default: `full`\n */\n warmup: WarmupEnum,\n\n /** Base model path (typically starting with file://, http:// or https://) for all models\n * - individual modelPath values are relative to this path\n *\n * default: `../models/` for browsers and `file://models/` for nodejs\n */\n modelBasePath: string,\n\n /** Cache models in IndexDB on first sucessfull load\n * default: true if indexdb is available (browsers), false if its not (nodejs)\n */\n cacheModels: boolean,\n\n /** Validate kernel ops used in model during model load\n * default: true\n * any errors will be printed on console but will be treated as non-fatal\n */\n validateModels: boolean,\n\n /** Cache sensitivity\n * - values 0..1 where 0.01 means reset cache if input changed more than 1%\n * - set to 0 to disable caching\n *\n * default: 0.7\n */\n cacheSensitivity: number;\n\n /** Explicit flags passed to initialize TFJS */\n flags: Record,\n\n /** Software Kernels\n * Registers software kernel ops running on CPU when accelerated version of kernel is not found in the current backend\n */\n softwareKernels: boolean,\n\n /** Perform immediate garbage collection on deallocated tensors instead of caching them */\n deallocate: boolean;\n\n /** Internal Variable */\n skipAllowed: boolean;\n\n /** Filter config {@link FilterConfig} */\n filter: Partial,\n\n /** Gesture config {@link GestureConfig} */\n gesture: Partial;\n\n /** Face config {@link FaceConfig} */\n face: Partial,\n\n /** Body config {@link BodyConfig} */\n body: Partial,\n\n /** Hand config {@link HandConfig} */\n hand: Partial,\n\n /** Object config {@link ObjectConfig} */\n object: Partial,\n\n /** Segmentation config {@link SegmentationConfig} */\n segmentation: Partial,\n}\n\n/** - [See all default Config values...](https://github.com/vladmandic/human/blob/main/src/config.ts#L262) */\nconst config: Config = {\n backend: '',\n modelBasePath: '',\n cacheModels: true,\n validateModels: true,\n wasmPath: '',\n wasmPlatformFetch: false,\n debug: false,\n async: true,\n warmup: 'full',\n cacheSensitivity: 0.70,\n skipAllowed: false,\n deallocate: false,\n flags: {},\n softwareKernels: false,\n filter: {\n enabled: true,\n equalization: false,\n width: 0,\n height: 0,\n flip: false,\n return: true,\n autoBrightness: true,\n brightness: 0,\n contrast: 0,\n sharpness: 0,\n blur: 0,\n saturation: 0,\n hue: 0,\n negative: false,\n sepia: false,\n vintage: false,\n kodachrome: false,\n technicolor: false,\n polaroid: false,\n pixelate: 0,\n },\n gesture: {\n enabled: true,\n },\n face: {\n enabled: true,\n detector: {\n modelPath: 'blazeface.json',\n rotation: false,\n maxDetected: 1,\n skipFrames: 99,\n skipTime: 2500,\n minConfidence: 0.2,\n minSize: 0,\n iouThreshold: 0.1,\n mask: false,\n return: false,\n },\n mesh: {\n enabled: true,\n modelPath: 'facemesh.json',\n keepInvalid: false,\n },\n attention: {\n enabled: false,\n modelPath: 'facemesh-attention.json',\n },\n iris: {\n enabled: true,\n modelPath: 'iris.json',\n },\n emotion: {\n enabled: true,\n minConfidence: 0.1,\n skipFrames: 99,\n skipTime: 1500,\n modelPath: 'emotion.json',\n },\n description: {\n enabled: true,\n modelPath: 'faceres.json',\n skipFrames: 99,\n skipTime: 3000,\n minConfidence: 0.1,\n },\n antispoof: {\n enabled: false,\n skipFrames: 99,\n skipTime: 4000,\n modelPath: 'antispoof.json',\n },\n liveness: {\n enabled: false,\n skipFrames: 99,\n skipTime: 4000,\n modelPath: 'liveness.json',\n },\n },\n body: {\n enabled: true,\n modelPath: 'movenet-lightning.json',\n maxDetected: -1,\n minConfidence: 0.3,\n skipFrames: 1,\n skipTime: 200,\n },\n hand: {\n enabled: true,\n rotation: true,\n skipFrames: 99,\n skipTime: 1000,\n minConfidence: 0.50,\n iouThreshold: 0.2,\n maxDetected: -1,\n landmarks: true,\n detector: {\n modelPath: 'handtrack.json',\n },\n skeleton: {\n modelPath: 'handlandmark-lite.json',\n },\n },\n object: {\n enabled: false,\n modelPath: 'centernet.json',\n minConfidence: 0.2,\n iouThreshold: 0.4,\n maxDetected: 10,\n skipFrames: 99,\n skipTime: 2000,\n },\n segmentation: {\n enabled: false,\n modelPath: 'rvm.json',\n ratio: 0.5,\n mode: 'default',\n },\n};\n\nexport { config as defaults };\n", "export const vertexIdentity = `\n precision highp float;\n attribute vec2 pos;\n attribute vec2 uv;\n varying vec2 vUv;\n uniform float flipY;\n void main(void) {\n vUv = uv;\n gl_Position = vec4(pos.x, pos.y*flipY, 0.0, 1.);\n }\n`;\n\nexport const fragmentIdentity = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n void main(void) {\n gl_FragColor = texture2D(texture, vUv);\n }\n`;\n\nexport const colorMatrixWithAlpha = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform float m[20];\n void main(void) {\n vec4 c = texture2D(texture, vUv);\n gl_FragColor.r = m[0] * c.r + m[1] * c.g + m[2] * c.b + m[3] * c.a + m[4];\n gl_FragColor.g = m[5] * c.r + m[6] * c.g + m[7] * c.b + m[8] * c.a + m[9];\n gl_FragColor.b = m[10] * c.r + m[11] * c.g + m[12] * c.b + m[13] * c.a + m[14];\n gl_FragColor.a = m[15] * c.r + m[16] * c.g + m[17] * c.b + m[18] * c.a + m[19];\n }\n`;\n\nexport const colorMatrixWithoutAlpha = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform float m[20];\n void main(void) {\n vec4 c = texture2D(texture, vUv);\n gl_FragColor.r = m[0] * c.r + m[1] * c.g + m[2] * c.b + m[4];\n gl_FragColor.g = m[5] * c.r + m[6] * c.g + m[7] * c.b + m[9];\n gl_FragColor.b = m[10] * c.r + m[11] * c.g + m[12] * c.b + m[14];\n gl_FragColor.a = c.a;\n }\n`;\n\nexport const pixelate = `\n precision highp float;\n varying vec2 vUv;\n uniform vec2 size;\n uniform sampler2D texture;\n vec2 pixelate(vec2 coord, vec2 size) {\n return floor( coord / size ) * size;\n }\n void main(void) {\n gl_FragColor = vec4(0.0);\n vec2 coord = pixelate(vUv, size);\n gl_FragColor += texture2D(texture, coord);\n }\n`;\n\nexport const blur = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform vec2 px;\n void main(void) {\n gl_FragColor = vec4(0.0);\n gl_FragColor += texture2D(texture, vUv + vec2(-7.0*px.x, -7.0*px.y))*0.0044299121055113265;\n gl_FragColor += texture2D(texture, vUv + vec2(-6.0*px.x, -6.0*px.y))*0.00895781211794;\n gl_FragColor += texture2D(texture, vUv + vec2(-5.0*px.x, -5.0*px.y))*0.0215963866053;\n gl_FragColor += texture2D(texture, vUv + vec2(-4.0*px.x, -4.0*px.y))*0.0443683338718;\n gl_FragColor += texture2D(texture, vUv + vec2(-3.0*px.x, -3.0*px.y))*0.0776744219933;\n gl_FragColor += texture2D(texture, vUv + vec2(-2.0*px.x, -2.0*px.y))*0.115876621105;\n gl_FragColor += texture2D(texture, vUv + vec2(-1.0*px.x, -1.0*px.y))*0.147308056121;\n gl_FragColor += texture2D(texture, vUv )*0.159576912161;\n gl_FragColor += texture2D(texture, vUv + vec2( 1.0*px.x, 1.0*px.y))*0.147308056121;\n gl_FragColor += texture2D(texture, vUv + vec2( 2.0*px.x, 2.0*px.y))*0.115876621105;\n gl_FragColor += texture2D(texture, vUv + vec2( 3.0*px.x, 3.0*px.y))*0.0776744219933;\n gl_FragColor += texture2D(texture, vUv + vec2( 4.0*px.x, 4.0*px.y))*0.0443683338718;\n gl_FragColor += texture2D(texture, vUv + vec2( 5.0*px.x, 5.0*px.y))*0.0215963866053;\n gl_FragColor += texture2D(texture, vUv + vec2( 6.0*px.x, 6.0*px.y))*0.00895781211794;\n gl_FragColor += texture2D(texture, vUv + vec2( 7.0*px.x, 7.0*px.y))*0.0044299121055113265;\n }\n`;\n\nexport const convolution = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform vec2 px;\n uniform float m[9];\n void main(void) {\n vec4 c11 = texture2D(texture, vUv - px); // top left\n vec4 c12 = texture2D(texture, vec2(vUv.x, vUv.y - px.y)); // top center\n vec4 c13 = texture2D(texture, vec2(vUv.x + px.x, vUv.y - px.y)); // top right\n vec4 c21 = texture2D(texture, vec2(vUv.x - px.x, vUv.y) ); // mid left\n vec4 c22 = texture2D(texture, vUv); // mid center\n vec4 c23 = texture2D(texture, vec2(vUv.x + px.x, vUv.y) ); // mid right\n vec4 c31 = texture2D(texture, vec2(vUv.x - px.x, vUv.y + px.y) ); // bottom left\n vec4 c32 = texture2D(texture, vec2(vUv.x, vUv.y + px.y) ); // bottom center\n vec4 c33 = texture2D(texture, vUv + px ); // bottom right\n gl_FragColor = \n c11 * m[0] + c12 * m[1] + c22 * m[2] +\n c21 * m[3] + c22 * m[4] + c23 * m[5] +\n c31 * m[6] + c32 * m[7] + c33 * m[8];\n gl_FragColor.a = c22.a;\n }\n`;\n", "/**\n * Image Filters in WebGL algoritm implementation\n * Based on: [WebGLImageFilter](https://github.com/phoboslab/WebGLImageFilter)\n */\n\n/* eslint-disable func-names */\n\nimport * as shaders from './imagefxshaders';\nimport { canvas } from './image';\nimport { log } from '../util/util';\n\nconst collect = (source, prefix: string, collection) => {\n const r = new RegExp('\\\\b' + prefix + ' \\\\w+ (\\\\w+)', 'ig');\n source.replace(r, (match, name) => {\n collection[name] = 0;\n return match;\n });\n};\n\nclass GLProgram {\n uniform = {};\n attribute = {};\n gl: WebGLRenderingContext;\n id: WebGLProgram;\n\n constructor(gl, vertexSource, fragmentSource) {\n this.gl = gl;\n const vertexShader = this.compile(vertexSource, this.gl.VERTEX_SHADER);\n const fragmentShader = this.compile(fragmentSource, this.gl.FRAGMENT_SHADER);\n this.id = this.gl.createProgram() as WebGLProgram;\n if (!vertexShader || !fragmentShader) return;\n if (!this.id) {\n log('filter: could not create webgl program');\n return;\n }\n this.gl.attachShader(this.id, vertexShader);\n this.gl.attachShader(this.id, fragmentShader);\n this.gl.linkProgram(this.id);\n if (!this.gl.getProgramParameter(this.id, this.gl.LINK_STATUS)) {\n log(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id) || 'unknown'}`);\n return;\n }\n this.gl.useProgram(this.id);\n collect(vertexSource, 'attribute', this.attribute); // Collect attributes\n for (const a in this.attribute) this.attribute[a] = this.gl.getAttribLocation(this.id, a);\n collect(vertexSource, 'uniform', this.uniform); // Collect uniforms\n collect(fragmentSource, 'uniform', this.uniform);\n for (const u in this.uniform) this.uniform[u] = this.gl.getUniformLocation(this.id, u);\n }\n\n compile = (source, type): WebGLShader | null => {\n const shader = this.gl.createShader(type);\n if (!shader) {\n log('filter: could not create shader');\n return null;\n }\n this.gl.shaderSource(shader, source);\n this.gl.compileShader(shader);\n if (!this.gl.getShaderParameter(shader, this.gl.COMPILE_STATUS)) {\n log(`filter: gl compile failed: ${this.gl.getShaderInfoLog(shader) || 'unknown'}`);\n return null;\n }\n return shader;\n };\n}\n\n// function that is instantiated as class so it has private this members\n/**\n * @class GLImageFilter\n * @property {function} reset reset current filter chain\n * @property {function} add add specified filter to filter chain\n * @property {function} apply execute filter chain and draw result\n * @property {function} draw just draw input to result\n */\n\nexport function GLImageFilter() {\n let drawCount = 0;\n let sourceTexture: WebGLTexture | null = null;\n let lastInChain = false;\n let currentFramebufferIndex = -1;\n let tempFramebuffers: [null, null] | [{ fbo: WebGLFramebuffer | null, texture: WebGLTexture | null }] = [null, null];\n let filterChain: Record[] = [];\n let vertexBuffer: WebGLBuffer | null = null;\n let currentProgram: GLProgram | null = null;\n const fxcanvas = canvas(100, 100) as HTMLCanvasElement;\n const shaderProgramCache = { }; // key is the shader program source, value is the compiled program\n const DRAW = { INTERMEDIATE: 1 };\n const gl = fxcanvas.getContext('webgl') as WebGLRenderingContext;\n if (!gl) {\n log('filter: cannot get webgl context');\n return;\n }\n // @ts-ignore used for sanity checks outside of imagefx\n this.gl = gl;\n\n function resize(width, height) {\n if (width === fxcanvas.width && height === fxcanvas.height) return; // Same width/height? Nothing to do here\n fxcanvas.width = width;\n fxcanvas.height = height;\n if (!vertexBuffer) { // Create the context if we don't have it yet\n const vertices = new Float32Array([-1, -1, 0, 1, 1, -1, 1, 1, -1, 1, 0, 0, -1, 1, 0, 0, 1, -1, 1, 1, 1, 1, 1, 0]); // Create the vertex buffer for the two triangles [x, y, u, v] * 6\n vertexBuffer = gl.createBuffer();\n gl.bindBuffer(gl.ARRAY_BUFFER, vertexBuffer);\n gl.bufferData(gl.ARRAY_BUFFER, vertices, gl.STATIC_DRAW);\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, true);\n }\n gl.viewport(0, 0, fxcanvas.width, fxcanvas.height);\n tempFramebuffers = [null, null]; // Delete old temp framebuffers\n }\n\n function createFramebufferTexture(width, height) {\n const fbo = gl.createFramebuffer();\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);\n const renderbuffer = gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);\n const texture = gl.createTexture();\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, width, height, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);\n gl.bindTexture(gl.TEXTURE_2D, null);\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n return { fbo, texture };\n }\n\n function getTempFramebuffer(index): { fbo: WebGLFramebuffer | null, texture: WebGLTexture | null } {\n tempFramebuffers[index] = tempFramebuffers[index] || createFramebufferTexture(fxcanvas.width, fxcanvas.height);\n return tempFramebuffers[index] as { fbo: WebGLFramebuffer, texture: WebGLTexture };\n }\n\n function draw(flags = 0) {\n if (!currentProgram) return;\n let source: WebGLTexture | null = null;\n let target: WebGLFramebuffer | null = null;\n let flipY = false;\n if (drawCount === 0) source = sourceTexture; // First draw call - use the source texture\n else source = getTempFramebuffer(currentFramebufferIndex).texture || null; // All following draw calls use the temp buffer last drawn to\n drawCount++;\n if (lastInChain && !(flags & DRAW.INTERMEDIATE)) { // Last filter in our chain - draw directly to the WebGL Canvas. We may also have to flip the image vertically now\n target = null;\n flipY = drawCount % 2 === 0;\n } else {\n currentFramebufferIndex = (currentFramebufferIndex + 1) % 2;\n target = getTempFramebuffer(currentFramebufferIndex).fbo || null; // Intermediate draw call - get a temp buffer to draw to\n }\n gl.bindTexture(gl.TEXTURE_2D, source); // Bind the source and target and draw the two triangles\n gl.bindFramebuffer(gl.FRAMEBUFFER, target);\n gl.uniform1f(currentProgram.uniform['flipY'], (flipY ? -1 : 1));\n gl.drawArrays(gl.TRIANGLES, 0, 6);\n }\n\n function compileShader(fragmentSource): GLProgram | null {\n if (shaderProgramCache[fragmentSource]) {\n currentProgram = shaderProgramCache[fragmentSource];\n gl.useProgram((currentProgram ? currentProgram.id : null) || null);\n return currentProgram;\n }\n currentProgram = new GLProgram(gl, shaders.vertexIdentity, fragmentSource);\n if (!currentProgram) {\n log('filter: could not get webgl program');\n return null;\n }\n const floatSize = Float32Array.BYTES_PER_ELEMENT;\n const vertSize = 4 * floatSize;\n gl.enableVertexAttribArray(currentProgram.attribute['pos']);\n gl.vertexAttribPointer(currentProgram.attribute['pos'], 2, gl.FLOAT, false, vertSize, 0 * floatSize);\n gl.enableVertexAttribArray(currentProgram.attribute['uv']);\n gl.vertexAttribPointer(currentProgram.attribute['uv'], 2, gl.FLOAT, false, vertSize, 2 * floatSize);\n shaderProgramCache[fragmentSource] = currentProgram;\n return currentProgram;\n }\n\n const filter = {\n colorMatrix: (matrix: number[]) => { // general color matrix filter\n const m = new Float32Array(matrix);\n m[4] /= 255;\n m[9] /= 255;\n m[14] /= 255;\n m[19] /= 255;\n const shader = (m[18] === 1 && m[3] === 0 && m[8] === 0 && m[13] === 0 && m[15] === 0 && m[16] === 0 && m[17] === 0 && m[19] === 0) // Can we ignore the alpha value? Makes things a bit faster.\n ? shaders.colorMatrixWithoutAlpha\n : shaders.colorMatrixWithAlpha;\n const program = compileShader(shader);\n if (!program) return;\n gl.uniform1fv(program.uniform['m'], m);\n draw();\n },\n\n brightness: (brightness: number) => {\n const b = (brightness || 0) + 1;\n filter.colorMatrix([\n b, 0, 0, 0, 0,\n 0, b, 0, 0, 0,\n 0, 0, b, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n saturation: (amount: number) => {\n const x = (amount || 0) * 2 / 3 + 1;\n const y = ((x - 1) * -0.5);\n filter.colorMatrix([\n x, y, y, 0, 0,\n y, x, y, 0, 0,\n y, y, x, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n desaturate: () => {\n filter.saturation(-1);\n },\n\n contrast: (amount: number) => {\n const v = (amount || 0) + 1;\n const o = -128 * (v - 1);\n filter.colorMatrix([\n v, 0, 0, 0, o,\n 0, v, 0, 0, o,\n 0, 0, v, 0, o,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n negative: () => {\n filter.contrast(-2);\n },\n\n hue: (rotation: number) => {\n rotation = (rotation || 0) / 180 * Math.PI;\n const cos = Math.cos(rotation);\n const sin = Math.sin(rotation);\n const lumR = 0.213;\n const lumG = 0.715;\n const lumB = 0.072;\n filter.colorMatrix([\n lumR + cos * (1 - lumR) + sin * (-lumR), lumG + cos * (-lumG) + sin * (-lumG), lumB + cos * (-lumB) + sin * (1 - lumB), 0, 0,\n lumR + cos * (-lumR) + sin * (0.143), lumG + cos * (1 - lumG) + sin * (0.140), lumB + cos * (-lumB) + sin * (-0.283), 0, 0,\n lumR + cos * (-lumR) + sin * (-(1 - lumR)), lumG + cos * (-lumG) + sin * (lumG), lumB + cos * (1 - lumB) + sin * (lumB), 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n desaturateLuminance: () => {\n filter.colorMatrix([\n 0.2764723, 0.9297080, 0.0938197, 0, -37.1,\n 0.2764723, 0.9297080, 0.0938197, 0, -37.1,\n 0.2764723, 0.9297080, 0.0938197, 0, -37.1,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n sepia: () => {\n filter.colorMatrix([\n 0.393, 0.7689999, 0.18899999, 0, 0,\n 0.349, 0.6859999, 0.16799999, 0, 0,\n 0.272, 0.5339999, 0.13099999, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n brownie: () => {\n filter.colorMatrix([\n 0.5997023498159715, 0.34553243048391263, -0.2708298674538042, 0, 47.43192855600873,\n -0.037703249837783157, 0.8609577587992641, 0.15059552388459913, 0, -36.96841498319127,\n 0.24113635128153335, -0.07441037908422492, 0.44972182064877153, 0, -7.562075277591283,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n vintagePinhole: () => {\n filter.colorMatrix([\n 0.6279345635605994, 0.3202183420819367, -0.03965408211312453, 0, 9.651285835294123,\n 0.02578397704808868, 0.6441188644374771, 0.03259127616149294, 0, 7.462829176470591,\n 0.0466055556782719, -0.0851232987247891, 0.5241648018700465, 0, 5.159190588235296,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n kodachrome: () => {\n filter.colorMatrix([\n 1.1285582396593525, -0.3967382283601348, -0.03992559172921793, 0, 63.72958762196502,\n -0.16404339962244616, 1.0835251566291304, -0.05498805115633132, 0, 24.732407896706203,\n -0.16786010706155763, -0.5603416277695248, 1.6014850761964943, 0, 35.62982807460946,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n technicolor: () => {\n filter.colorMatrix([\n 1.9125277891456083, -0.8545344976951645, -0.09155508482755585, 0, 11.793603434377337,\n -0.3087833385928097, 1.7658908555458428, -0.10601743074722245, 0, -70.35205161461398,\n -0.231103377548616, -0.7501899197440212, 1.847597816108189, 0, 30.950940869491138,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n polaroid: () => {\n filter.colorMatrix([\n 1.438, -0.062, -0.062, 0, 0,\n -0.122, 1.378, -0.122, 0, 0,\n -0.016, -0.016, 1.483, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n shiftToBGR: () => {\n filter.colorMatrix([\n 0, 0, 1, 0, 0,\n 0, 1, 0, 0, 0,\n 1, 0, 0, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n convolution: (matrix: number[]) => { // general convolution Filter\n const m = new Float32Array(matrix);\n const pixelSizeX = 1 / fxcanvas.width;\n const pixelSizeY = 1 / fxcanvas.height;\n const program = compileShader(shaders.convolution);\n if (!program) return;\n gl.uniform1fv(program.uniform['m'], m);\n gl.uniform2f(program.uniform['px'], pixelSizeX, pixelSizeY);\n draw();\n },\n\n detectEdges: () => {\n // @ts-ignore this\n filter.convolution.call(this, [\n 0, 1, 0,\n 1, -4, 1,\n 0, 1, 0,\n ]);\n },\n\n sobelX: () => {\n // @ts-ignore this\n filter.convolution.call(this, [\n -1, 0, 1,\n -2, 0, 2,\n -1, 0, 1,\n ]);\n },\n\n sobelY: () => {\n // @ts-ignore this\n filter.convolution.call(this, [\n -1, -2, -1,\n 0, 0, 0,\n 1, 2, 1,\n ]);\n },\n\n sharpen: (amount) => {\n const a = amount || 1;\n // @ts-ignore this\n filter.convolution.call(this, [\n 0, -1 * a, 0,\n -1 * a, 1 + 4 * a, -1 * a,\n 0, -1 * a, 0,\n ]);\n },\n\n emboss: (size: number) => {\n const s = size || 1;\n // @ts-ignore this\n filter.convolution.call(this, [\n -2 * s, -1 * s, 0,\n -1 * s, 1, 1 * s,\n 0, 1 * s, 2 * s,\n ]);\n },\n\n blur: (size: number) => {\n const blurSizeX = (size / 7) / fxcanvas.width;\n const blurSizeY = (size / 7) / fxcanvas.height;\n const program = compileShader(shaders.blur);\n if (!program) return;\n // Vertical\n gl.uniform2f(program.uniform['px'], 0, blurSizeY);\n draw(DRAW.INTERMEDIATE);\n // Horizontal\n gl.uniform2f(program.uniform['px'], blurSizeX, 0);\n draw();\n },\n\n pixelate: (size: number) => {\n const blurSizeX = (size) / fxcanvas.width;\n const blurSizeY = (size) / fxcanvas.height;\n const program = compileShader(shaders.pixelate);\n if (!program) return;\n gl.uniform2f(program.uniform['size'], blurSizeX, blurSizeY);\n draw();\n },\n };\n\n // @ts-ignore this\n this.add = function (name) {\n const args = Array.prototype.slice.call(arguments, 1); // eslint-disable-line prefer-rest-params\n const func = filter[name];\n filterChain.push({ func, args });\n };\n\n // @ts-ignore this\n this.reset = function () {\n filterChain = [];\n };\n\n // @ts-ignore this\n this.get = function () {\n return filterChain;\n };\n\n // @ts-ignore this\n this.apply = function (image) {\n resize(image.width, image.height);\n drawCount = 0;\n if (!sourceTexture) sourceTexture = gl.createTexture(); // Create the texture for the input image if we haven't yet\n gl.bindTexture(gl.TEXTURE_2D, sourceTexture);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, image);\n for (let i = 0; i < filterChain.length; i++) {\n lastInChain = (i === filterChain.length - 1);\n const f = filterChain[i];\n // @ts-ignore function assigment\n f.func.apply(this, f.args || []);\n }\n return fxcanvas;\n };\n\n // @ts-ignore this\n this.draw = function (image) {\n this.add('brightness', 0);\n return this.apply(image);\n };\n}\n", "/**\n * Image enhancements\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Tensor } from '../tfjs/types';\n\nexport async function histogramEqualization(inputImage: Tensor): Promise {\n const squeeze = inputImage.shape.length === 4 ? tf.squeeze(inputImage) : inputImage;\n const rgb = tf.split(squeeze, 3, 2);\n const min: Tensor[] = [tf.min(rgb[0]), tf.min(rgb[1]), tf.min(rgb[2])]; // minimum pixel value per channel T[]\n const max: Tensor[] = [tf.max(rgb[0]), tf.max(rgb[1]), tf.max(rgb[2])]; // maximum pixel value per channel T[]\n // const absMin = await Promise.all(min.map((channel) => channel.data())); // minimum pixel value per channel A[]\n // const minValue = Math.min(absMax[0][0], absMin[1][0], absMin[2][0]);\n const absMax = await Promise.all(max.map((channel) => channel.data())); // maximum pixel value per channel A[]\n const maxValue = Math.max(absMax[0][0], absMax[1][0], absMax[2][0]);\n const maxRange = maxValue > 1 ? 255 : 1;\n const factor = maxRange / maxValue;\n let final: Tensor;\n if (factor > 1) {\n const sub = [tf.sub(rgb[0], min[0]), tf.sub(rgb[1], min[1]), tf.sub(rgb[2], min[2])]; // channels offset by min values\n const range = [tf.sub(max[0], min[0]), tf.sub(max[1], min[1]), tf.sub(max[2], min[2])]; // channel ranges\n // const fact = [tf.div(maxRange, absMax[0]), tf.div(maxRange, absMax[1]), tf.div(maxRange, absMax[1])]; // factors between\n const enh = [tf.mul(sub[0], factor), tf.mul(sub[1], factor), tf.mul(sub[2], factor)];\n const stack = tf.stack([enh[0], enh[1], enh[2]], 2);\n final = tf.reshape(stack, [1, squeeze.shape[0] || 0, squeeze.shape[1] || 0, 3]);\n tf.dispose([...sub, ...range, ...enh, stack]);\n } else {\n final = tf.expandDims(squeeze, 0);\n }\n tf.dispose([...rgb, ...min, ...max, rgb, squeeze, inputImage]);\n return final;\n}\n", "/**\n * Image Processing algorithm implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as fxImage from './imagefx';\nimport type { Input, AnyCanvas, Config } from '../exports';\nimport type { Tensor, Tensor3D, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\nimport { log } from '../util/util';\nimport * as enhance from './enhance';\n\nconst maxSize = 3840;\n// internal temp canvases\nlet inCanvas: AnyCanvas | null = null; // use global variable to avoid recreating canvas on each frame\nlet outCanvas: AnyCanvas | null = null; // use global variable to avoid recreating canvas on each frame\nlet tmpCanvas: AnyCanvas | null = null; // use global variable to avoid recreating canvas on each frame\n// @ts-ignore // imagefx is js module that should be converted to a class\nlet fx: fxImage.GLImageFilter | null; // eslint-disable-line @typescript-eslint/no-redundant-type-constituents\n\nconst last: { inputSum: number, cacheDiff: number, sumMethod: number, inputTensor: undefined | Tensor } = {\n inputSum: 0,\n cacheDiff: 1,\n sumMethod: 0,\n inputTensor: undefined,\n};\n\nexport function reset() {\n last.inputSum = 0;\n last.cacheDiff = 1;\n last.sumMethod = 0;\n last.inputTensor = undefined;\n}\n\nexport function canvas(width: number, height: number): AnyCanvas {\n let c: AnyCanvas;\n if (env.browser) { // browser defines canvas object\n if (env.worker) { // if runing in web worker use OffscreenCanvas\n if (typeof OffscreenCanvas === 'undefined') throw new Error('canvas error: attempted to run in web worker but OffscreenCanvas is not supported');\n c = new OffscreenCanvas(width, height);\n } else { // otherwise use DOM canvas\n if (typeof document !== 'undefined') {\n c = document.createElement('canvas');\n c.width = width;\n c.height = height;\n } else if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {\n // @ts-ignore // env.canvas is an external monkey-patch\n if (typeof env.Canvas !== 'undefined') c = new env.Canvas(width, height);\n else if (typeof globalThis.Canvas !== 'undefined') c = new globalThis.Canvas(width, height);\n else throw new Error('canvas error: attempted to use canvas in react-native without canvas support installed');\n } else {\n throw new Error('canvas error: attempted to run in browser but DOM is not defined');\n }\n }\n } else { // if not running in browser, there is no \"default\" canvas object, so we need monkey patch or fail\n // @ts-ignore // env.canvas is an external monkey-patch\n if (typeof env.Canvas !== 'undefined') c = new env.Canvas(width, height);\n else if (typeof globalThis.Canvas !== 'undefined') c = new globalThis.Canvas(width, height);\n // else throw new Error('canvas error: attempted to use canvas in nodejs without canvas support installed');\n }\n // @ts-ignore its either defined or we already threw an error\n return c;\n}\n\n// helper function to copy canvas from input to output\nexport function copy(input: AnyCanvas, output?: AnyCanvas) {\n const outputCanvas = output || canvas(input.width, input.height);\n const ctx = outputCanvas.getContext('2d') as CanvasRenderingContext2D;\n ctx.drawImage(input, 0, 0);\n return outputCanvas;\n}\n\n// process input image and return tensor\n// input can be tensor, imagedata, htmlimageelement, htmlvideoelement\n// input is resized and run through imagefx filter\nexport async function process(input: Input, config: Config, getTensor: boolean = true): Promise<{ tensor: Tensor4D | null, canvas: AnyCanvas | null }> {\n if (!input) {\n // throw new Error('input is missing');\n if (config.debug) log('input error: input is missing');\n return { tensor: null, canvas: null }; // video may become temporarily unavailable due to onresize\n }\n // sanity checks since different browsers do not implement all dom elements\n if (\n !(input instanceof tf.Tensor)\n && !(typeof Image !== 'undefined' && input instanceof Image)\n && !(typeof globalThis.Canvas !== 'undefined' && input instanceof globalThis.Canvas)\n && !(typeof ImageData !== 'undefined' && input instanceof ImageData)\n && !(typeof ImageBitmap !== 'undefined' && input instanceof ImageBitmap)\n && !(typeof HTMLImageElement !== 'undefined' && input instanceof HTMLImageElement)\n && !(typeof HTMLMediaElement !== 'undefined' && input instanceof HTMLMediaElement)\n && !(typeof HTMLVideoElement !== 'undefined' && input instanceof HTMLVideoElement)\n && !(typeof HTMLCanvasElement !== 'undefined' && input instanceof HTMLCanvasElement)\n && !(typeof OffscreenCanvas !== 'undefined' && input instanceof OffscreenCanvas)\n ) {\n throw new Error('input error: type not recognized');\n }\n if (input instanceof tf.Tensor) { // if input is tensor use as-is without filters but correct shape as needed\n let tensor: Tensor | null = null;\n if (input['isDisposedInternal']) throw new Error('input error: attempted to use tensor but it is disposed');\n if (!(input as Tensor).shape) throw new Error('input error: attempted to use tensor without a shape');\n if ((input as Tensor).shape.length === 3) { // [height, width, 3 || 4]\n if ((input as Tensor).shape[2] === 3) { // [height, width, 3] so add batch\n tensor = tf.expandDims(input, 0);\n } else if ((input as Tensor).shape[2] === 4) { // [height, width, 4] so strip alpha and add batch\n const rgb = tf.slice3d(input as Tensor3D, [0, 0, 0], [-1, -1, 3]);\n tensor = tf.expandDims(rgb, 0);\n tf.dispose(rgb);\n }\n } else if ((input as Tensor).shape.length === 4) { // [1, width, height, 3 || 4]\n if ((input as Tensor).shape[3] === 3) { // [1, width, height, 3] just clone\n tensor = tf.clone(input);\n } else if ((input as Tensor).shape[3] === 4) { // [1, width, height, 4] so strip alpha\n tensor = tf.slice4d(input as Tensor4D, [0, 0, 0, 0], [-1, -1, -1, 3]);\n }\n }\n // at the end shape must be [1, height, width, 3]\n if (tensor == null || tensor.shape.length !== 4 || tensor.shape[0] !== 1 || tensor.shape[3] !== 3) throw new Error(`input error: attempted to use tensor with unrecognized shape: ${((input as Tensor).shape).toString()}`);\n if ((tensor).dtype === 'int32') {\n const cast = tf.cast(tensor, 'float32');\n tf.dispose(tensor);\n tensor = cast;\n }\n return { tensor: tensor as Tensor4D, canvas: (config.filter.return ? outCanvas : null) };\n }\n // check if resizing will be needed\n if (typeof input['readyState'] !== 'undefined' && (input as HTMLMediaElement).readyState <= 2) {\n if (config.debug) log('input stream is not ready');\n return { tensor: null, canvas: inCanvas }; // video may become temporarily unavailable due to onresize\n }\n const originalWidth: number = input['naturalWidth'] || input['videoWidth'] || input['width'] || (input['shape'] && (input['shape'][1] > 0));\n const originalHeight: number = input['naturalHeight'] || input['videoHeight'] || input['height'] || (input['shape'] && (input['shape'][2] > 0));\n if (!originalWidth || !originalHeight) {\n if (config.debug) log('cannot determine input dimensions');\n return { tensor: null, canvas: inCanvas }; // video may become temporarily unavailable due to onresize\n }\n let targetWidth: number = originalWidth;\n let targetHeight: number = originalHeight;\n if (targetWidth > maxSize) {\n targetWidth = maxSize;\n targetHeight = Math.trunc(targetWidth * originalHeight / originalWidth);\n }\n if (targetHeight > maxSize) {\n targetHeight = maxSize;\n targetWidth = Math.trunc(targetHeight * originalWidth / originalHeight);\n }\n\n // create our canvas and resize it if needed\n if ((config.filter?.width || 0) > 0) targetWidth = config.filter.width as number;\n else if ((config.filter?.height || 0) > 0) targetWidth = originalWidth * ((config.filter.height || 0) / originalHeight);\n if ((config.filter.height || 0) > 0) targetHeight = config.filter.height as number;\n else if ((config.filter.width || 0) > 0) targetHeight = originalHeight * ((config.filter.width || 0) / originalWidth);\n if (!targetWidth || !targetHeight) throw new Error('input error: cannot determine dimension');\n if (!inCanvas || (inCanvas.width !== targetWidth) || (inCanvas.height !== targetHeight)) inCanvas = canvas(targetWidth, targetHeight);\n\n // draw input to our canvas\n const inCtx = inCanvas.getContext('2d') as CanvasRenderingContext2D;\n if ((typeof ImageData !== 'undefined') && (input instanceof ImageData)) {\n inCtx.putImageData(input, 0, 0);\n } else {\n if (config.filter.flip && typeof inCtx.translate !== 'undefined') {\n inCtx.translate(originalWidth, 0);\n inCtx.scale(-1, 1);\n inCtx.drawImage(input as AnyCanvas, 0, 0, originalWidth, originalHeight, 0, 0, inCanvas.width, inCanvas.height);\n inCtx.setTransform(1, 0, 0, 1, 0, 0); // resets transforms to defaults\n } else {\n inCtx.drawImage(input as AnyCanvas, 0, 0, originalWidth, originalHeight, 0, 0, inCanvas.width, inCanvas.height);\n }\n }\n\n if (!outCanvas || (inCanvas.width !== outCanvas.width) || (inCanvas.height !== outCanvas.height)) outCanvas = canvas(inCanvas.width, inCanvas.height); // init output canvas\n\n // imagefx transforms using gl from input canvas to output canvas\n if (config.filter.enabled && env.webgl.supported) {\n if (!fx) fx = env.browser ? new fxImage.GLImageFilter() : null; // && (typeof document !== 'undefined')\n env.filter = !!fx;\n if (!fx?.add) {\n if (config.debug) log('input process error: cannot initialize filters');\n env.webgl.supported = false;\n config.filter.enabled = false;\n copy(inCanvas, outCanvas); // filter failed to initialize\n // return { tensor: null, canvas: inCanvas };\n } else {\n fx.reset();\n if (config.filter.brightness !== 0) fx.add('brightness', config.filter.brightness);\n if (config.filter.contrast !== 0) fx.add('contrast', config.filter.contrast);\n if (config.filter.sharpness !== 0) fx.add('sharpen', config.filter.sharpness);\n if (config.filter.blur !== 0) fx.add('blur', config.filter.blur);\n if (config.filter.saturation !== 0) fx.add('saturation', config.filter.saturation);\n if (config.filter.hue !== 0) fx.add('hue', config.filter.hue);\n if (config.filter.negative) fx.add('negative');\n if (config.filter.sepia) fx.add('sepia');\n if (config.filter.vintage) fx.add('brownie');\n if (config.filter.sepia) fx.add('sepia');\n if (config.filter.kodachrome) fx.add('kodachrome');\n if (config.filter.technicolor) fx.add('technicolor');\n if (config.filter.polaroid) fx.add('polaroid');\n if (config.filter.pixelate !== 0) fx.add('pixelate', config.filter.pixelate);\n if (fx.get()?.length > 1) outCanvas = fx.apply(inCanvas);\n else outCanvas = fx.draw(inCanvas);\n }\n } else {\n copy(inCanvas, outCanvas); // if no filters applied, output canvas is input canvas\n if (fx) fx = null;\n env.filter = !!fx;\n }\n\n if (!getTensor) return { tensor: null, canvas: outCanvas }; // just canvas was requested\n if (!outCanvas) throw new Error('canvas error: cannot create output');\n\n // create tensor from image unless input was a tensor already\n let pixels;\n let depth = 3;\n if ((typeof ImageData !== 'undefined' && input instanceof ImageData) || ((input as ImageData).data && (input as ImageData).width && (input as ImageData).height)) { // if input is imagedata, just use it\n if (env.browser && tf.browser) {\n pixels = tf.browser ? tf.browser.fromPixels(input as ImageData) : null;\n } else {\n depth = (input as ImageData).data.length / (input as ImageData).height / (input as ImageData).width;\n // const arr = Uint8Array.from(input['data']);\n const arr = new Uint8Array((input as ImageData).data.buffer);\n pixels = tf.tensor(arr, [(input as ImageData).height, (input as ImageData).width, depth], 'int32');\n }\n } else {\n if (!tmpCanvas || (outCanvas.width !== tmpCanvas.width) || (outCanvas.height !== tmpCanvas.height)) tmpCanvas = canvas(outCanvas.width, outCanvas.height); // init output canvas\n if (tf.browser && env.browser) {\n if (config.backend === 'webgl' || config.backend === 'humangl' || config.backend === 'webgpu') {\n pixels = tf.browser.fromPixels(outCanvas as HTMLCanvasElement); // safe to reuse since both backend and context are gl based\n } else {\n tmpCanvas = copy(outCanvas); // cannot use output canvas as it already has gl context so we do a silly one more canvas\n pixels = tf.browser.fromPixels(tmpCanvas as HTMLCanvasElement);\n }\n } else {\n const tempCanvas = copy(outCanvas); // cannot use output canvas as it already has gl context so we do a silly one more canvas\n const tempCtx = tempCanvas.getContext('2d') as CanvasRenderingContext2D;\n const tempData = tempCtx.getImageData(0, 0, targetWidth, targetHeight);\n depth = tempData.data.length / targetWidth / targetHeight;\n const arr = new Uint8Array(tempData.data.buffer);\n pixels = tf.tensor(arr, [targetWidth, targetHeight, depth]);\n }\n }\n if (depth === 4) { // rgba to rgb\n const rgb = tf.slice3d(pixels, [0, 0, 0], [-1, -1, 3]); // strip alpha channel\n tf.dispose(pixels);\n pixels = rgb;\n }\n if (!pixels) throw new Error('input error: cannot create tensor');\n const casted: Tensor = tf.cast(pixels, 'float32');\n const tensor: Tensor = config.filter.equalization ? await enhance.histogramEqualization(casted) : tf.expandDims(casted, 0);\n tf.dispose([pixels, casted]);\n\n if (config.filter.autoBrightness) {\n const max = tf.max(tensor);\n const maxVal = await max.data();\n config.filter.brightness = maxVal[0] > 1 ? (1 - maxVal[0] / 255) : (1 - maxVal[0]);\n tf.dispose(max);\n }\n\n return { tensor: tensor as Tensor4D, canvas: (config.filter.return ? outCanvas : null) };\n}\n\n/*\nconst checksum = async (input: Tensor): Promise => { // use tf sum or js based sum loop depending on which is faster\n const resizeFact = 48;\n const reduced: Tensor = tf.image.resizeBilinear(input, [Math.trunc((input.shape[1] || 1) / resizeFact), Math.trunc((input.shape[2] || 1) / resizeFact)]);\n const tfSum = async (): Promise => {\n const sumT = tf.sum(reduced);\n const sum0 = await sumT.data();\n tf.dispose(sumT);\n return sum0[0];\n };\n const jsSum = async (): Promise => {\n const reducedData = await reduced.data(); // raw image rgb array\n let sum0 = 0;\n for (let i = 0; i < reducedData.length / 3; i++) sum0 += reducedData[3 * i + 2]; // look only at green value of each pixel\n return sum0;\n };\n if (last.sumMethod === 0) {\n const t0 = now();\n await jsSum();\n const t1 = now();\n await tfSum();\n const t2 = now();\n last.sumMethod = t1 - t0 < t2 - t1 ? 1 : 2;\n }\n const res = last.sumMethod === 1 ? await jsSum() : await tfSum();\n tf.dispose(reduced);\n return res;\n};\n*/\n\nexport async function skip(config: Partial, input: Tensor) {\n let skipFrame = false;\n if (config.cacheSensitivity === 0 || !input.shape || input.shape.length !== 4 || input.shape[1] > 3840 || input.shape[2] > 2160) return skipFrame; // cache disabled or input is invalid or too large for cache analysis\n\n /*\n const checkSum = await checksum(input);\n const diff = 100 * (Math.max(checkSum, last.inputSum) / Math.min(checkSum, last.inputSum) - 1);\n last.inputSum = checkSum;\n // if previous frame was skipped, skip this frame if changed more than cacheSensitivity\n // if previous frame was not skipped, then look for cacheSensitivity or difference larger than one in previous frame to avoid resetting cache in subsequent frames unnecessarily\n let skipFrame = diff < Math.max(config.cacheSensitivity, last.cacheDiff);\n // if difference is above 10x threshold, don't use last value to force reset cache for significant change of scenes or images\n last.cacheDiff = diff > 10 * config.cacheSensitivity ? 0 : diff;\n skipFrame = skipFrame && (last.cacheDiff > 0); // if no cached diff value then force no skip\n */\n\n if (!last.inputTensor) {\n last.inputTensor = tf.clone(input);\n } else if (last.inputTensor.shape[1] !== input.shape[1] || last.inputTensor.shape[2] !== input.shape[2]) { // input resolution changed\n tf.dispose(last.inputTensor);\n last.inputTensor = tf.clone(input);\n } else {\n const t: Record = {};\n t.diff = tf.sub(input, last.inputTensor);\n t.squared = tf.mul(t.diff, t.diff);\n t.sum = tf.sum(t.squared);\n const diffSum = await t.sum.data();\n const diffRelative = diffSum[0] / (input.shape[1] || 1) / (input.shape[2] || 1) / 255 / 3; // squared difference relative to input resolution and averaged per channel\n tf.dispose([last.inputTensor, t.diff, t.squared, t.sum]);\n last.inputTensor = tf.clone(input);\n skipFrame = diffRelative <= (config.cacheSensitivity || 0);\n }\n return skipFrame;\n}\n\nexport async function compare(config: Partial, input1: Tensor, input2: Tensor): Promise {\n const t: Record = {};\n if (!input1 || !input2 || input1.shape.length !== 4 || input1.shape.length !== input2.shape.length) {\n if (!config.debug) log('invalid input tensor or tensor shapes do not match:', input1.shape, input2.shape);\n return 0;\n }\n if (input1.shape[0] !== 1 || input2.shape[0] !== 1 || input1.shape[3] !== 3 || input2.shape[3] !== 3) {\n if (!config.debug) log('input tensors must be of shape [1, height, width, 3]:', input1.shape, input2.shape);\n return 0;\n }\n t.input1 = tf.clone(input1);\n t.input2 = (input1.shape[1] !== input2.shape[1] || input1.shape[2] !== input2.shape[2]) ? tf.image.resizeBilinear(input2 as Tensor3D, [input1.shape[1], input1.shape[2]]) : tf.clone(input2);\n t.diff = tf.sub(t.input1, t.input2);\n t.squared = tf.mul(t.diff, t.diff);\n t.sum = tf.sum(t.squared);\n const diffSum = await t.sum.data();\n const diffRelative = diffSum[0] / (input1.shape[1] || 1) / (input1.shape[2] || 1) / 255 / 3;\n tf.dispose([t.input1, t.input2, t.diff, t.squared, t.sum]);\n return diffRelative;\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport * as image from '../image/image';\n\n/** Env class that holds detected capabilities */\nexport class Env {\n /** Running in Browser */\n browser: boolean;\n /** Running in NodeJS */\n node: boolean;\n /** Running in WebWorker thread */\n worker: boolean;\n /** Detected platform */\n platform: string = '';\n /** Detected agent */\n agent: string = '';\n /** List of supported backends */\n backends: string[] = [];\n /** Has any work been performed so far */\n initial: boolean;\n /** Are image filters supported? */\n filter: boolean | undefined;\n /** TFJS instance details */\n tfjs: {\n version: undefined | string,\n };\n /** Is offscreenCanvas supported? */\n offscreen: undefined | boolean;\n /** Are performance counter instant values or additive */\n perfadd: boolean = false;\n /** If using tfjs-node get version of underlying tensorflow shared library and if gpu acceleration is enabled */\n tensorflow: {\n version: undefined | string,\n gpu: undefined | boolean,\n } = {\n version: undefined,\n gpu: undefined,\n };\n /** WASM detected capabilities */\n wasm: {\n supported: undefined | boolean,\n backend: undefined | boolean,\n simd: undefined | boolean,\n multithread: undefined | boolean,\n } = {\n supported: undefined,\n backend: undefined,\n simd: undefined,\n multithread: undefined,\n };\n /** WebGL detected capabilities */\n webgl: {\n supported: undefined | boolean,\n backend: undefined | boolean,\n version: undefined | string,\n renderer: undefined | string,\n shader: undefined | string,\n vendor: undefined | string,\n } = {\n supported: undefined,\n backend: undefined,\n version: undefined,\n renderer: undefined,\n shader: undefined,\n vendor: undefined,\n };\n /** WebGPU detected capabilities */\n webgpu: {\n supported: undefined | boolean,\n backend: undefined | boolean,\n adapter: undefined | GPUAdapterInfo,\n } = {\n supported: undefined,\n backend: undefined,\n adapter: undefined,\n };\n /** CPU info */\n cpu: {\n model: undefined | string,\n flags: string[],\n } = {\n model: undefined,\n flags: [],\n };\n /** List of supported kernels for current backend */\n kernels: string[] = [];\n\n /** MonkeyPatch for Canvas/Image/ImageData */\n #canvas: undefined;\n #image: undefined;\n #imageData: undefined;\n\n get Canvas() { return this.#canvas; }\n set Canvas(val) { this.#canvas = val; globalThis.Canvas = val; }\n get Image() { return this.#image; }\n // @ts-ignore monkey-patch;\n set Image(val) { this.#image = val; globalThis.Image = val; }\n get ImageData() { return this.#imageData; }\n // @ts-ignore monkey-patch;\n set ImageData(val) { this.#imageData = val; globalThis.ImageData = val; }\n\n constructor() {\n this.browser = typeof navigator !== 'undefined';\n this.node = (typeof process !== 'undefined') && (typeof process.versions !== 'undefined') && (typeof process.versions.node !== 'undefined');\n this.tfjs = { version: tf.version['tfjs-core'] };\n this.offscreen = typeof OffscreenCanvas !== 'undefined';\n this.initial = true;\n\n // @ts-ignore WorkerGlobalScope evaluated in browser only\n this.worker = this.browser && this.offscreen ? (typeof WorkerGlobalScope !== 'undefined') : undefined;\n if ((typeof navigator !== 'undefined') && (typeof navigator.userAgent !== 'undefined')) { // TBD replace with navigator.userAgentData once in mainline\n const agent = navigator.userAgent || '';\n const raw = agent.match(/\\(([^()]+)\\)/g);\n if (raw?.[0]) {\n const platformMatch = raw[0].match(/\\(([^()]+)\\)/g);\n this.platform = (platformMatch?.[0]) ? platformMatch[0].replace(/\\(|\\)/g, '') : '';\n this.agent = agent.replace(raw[0], '');\n if (this.platform[1]) this.agent = this.agent.replace(raw[1], '');\n this.agent = this.agent.replace(/ /g, ' ');\n }\n } else if (typeof process !== 'undefined') {\n this.platform = `${process.platform} ${process.arch}`;\n this.agent = `NodeJS ${process.version}`;\n }\n }\n\n /** update backend information */\n async updateBackend() {\n // analyze backends\n this.backends = Object.keys(tf.engine().registryFactory);\n try { // backend may not be initialized\n this.tensorflow = {\n version: (tf.backend()['binding'] ? tf.backend()['binding'].TF_Version : undefined),\n gpu: (tf.backend()['binding'] ? tf.backend()['binding'].isUsingGpuDevice() : undefined),\n };\n } catch { /**/ }\n this.wasm.supported = typeof WebAssembly !== 'undefined';\n this.wasm.backend = this.backends.includes('wasm');\n if (this.wasm.supported && this.wasm.backend) {\n this.wasm.simd = await tf.env().getAsync('WASM_HAS_SIMD_SUPPORT') as boolean;\n this.wasm.multithread = await tf.env().getAsync('WASM_HAS_MULTITHREAD_SUPPORT') as boolean;\n }\n const c = image.canvas(100, 100);\n const gl = c ? c.getContext('webgl2') as WebGL2RenderingContext : undefined; // causes too many gl contexts\n this.webgl.supported = typeof gl !== 'undefined';\n this.webgl.backend = this.backends.includes('webgl');\n if (this.webgl.supported && this.webgl.backend && gl) {\n this.webgl.version = gl.getParameter(gl.VERSION);\n this.webgl.vendor = gl.getParameter(gl.VENDOR);\n this.webgl.renderer = gl.getParameter(gl.RENDERER);\n this.webgl.shader = gl.getParameter(gl.SHADING_LANGUAGE_VERSION);\n }\n this.webgpu.supported = this.browser && typeof navigator !== 'undefined' && typeof navigator.gpu !== 'undefined';\n this.webgpu.backend = this.backends.includes('webgpu');\n try {\n if (this.webgpu.supported) {\n const adapter = await navigator.gpu.requestAdapter();\n this.webgpu.adapter = await adapter?.requestAdapterInfo();\n }\n } catch {\n this.webgpu.supported = false;\n }\n try {\n this.kernels = tf.getKernelsForBackend(tf.getBackend()).map((kernel) => kernel.kernelName.toLowerCase());\n } catch { /**/ }\n }\n\n /** update cpu information */\n updateCPU() {\n const cpu = { model: '', flags: [] };\n if (this.node && this.platform.startsWith('linux')) {\n /*\n const fs = require('fs');\n try {\n const data = fs.readFileSync('/proc/cpuinfo').toString();\n for (const line of data.split('\\n')) {\n if (line.startsWith('model name')) cpu.model = line.match(/:(.*)/g)[0].replace(':', '').trim();\n if (line.startsWith('flags')) cpu.flags = line.match(/:(.*)/g)[0].replace(':', '').trim().split(' ').sort();\n }\n } catch { }\n */\n }\n if (!this.cpu) Object.defineProperty(this, 'cpu', { value: cpu });\n else this.cpu = cpu;\n }\n}\n\nexport const env = new Env();\n", "import { log } from './util';\n\n// const log = (...msg) => console.log('webcam', ...msg); // eslint-disable-line no-console\n\n/** WebCam configuration */\nexport interface WebCamConfig {\n /**\n * element can be:\n * - string which indicates dom element id\n * - actual HTMLVideo dom element\n * - undefined in which case a new HTMLVideoElement will be created\n */\n element: string | HTMLVideoElement | undefined,\n /** print messages on console */\n debug: boolean,\n /** use front or back camera */\n mode: 'front' | 'back',\n /** camera crop mode */\n crop: boolean,\n /** desired webcam width */\n width: number,\n /** desired webcam height */\n height: number,\n /** deviceId of the video device to use */\n id?: string,\n}\n\nexport class WebCam { // eslint-disable-line @typescript-eslint/no-extraneous-class\n /** current webcam configuration */\n config: WebCamConfig;\n /** instance of dom element associated with webcam stream */\n element: HTMLVideoElement | undefined;\n /** active webcam stream */\n stream: MediaStream | undefined;\n /** enumerated video devices */\n devices: MediaDeviceInfo[] = [];\n\n constructor() {\n this.config = {\n element: undefined,\n debug: true,\n mode: 'front',\n crop: false,\n width: 0,\n height: 0,\n };\n }\n\n /** get active webcam stream track */\n public get track(): MediaStreamTrack | undefined {\n if (!this.stream) return undefined;\n return this.stream.getVideoTracks()[0];\n }\n\n /** get webcam capabilities */\n public get capabilities(): MediaTrackCapabilities | undefined {\n if (!this.track) return undefined;\n return this.track.getCapabilities ? this.track.getCapabilities() : undefined;\n }\n\n /** get webcam constraints */\n public get constraints(): MediaTrackConstraints | undefined {\n if (!this.track) return undefined;\n return this.track.getConstraints ? this.track.getConstraints() : undefined;\n }\n\n /** get webcam settings */\n public get settings(): MediaTrackSettings | undefined {\n if (!this.stream) return undefined;\n const track: MediaStreamTrack = this.stream.getVideoTracks()[0];\n return track.getSettings ? track.getSettings() : undefined;\n }\n\n /** get webcam label */\n public get label(): string {\n if (!this.track) return '';\n return this.track.label;\n }\n\n /** is webcam paused */\n public get paused(): boolean {\n return this.element?.paused || false;\n }\n\n /** webcam current width */\n public get width(): number {\n return this.element?.videoWidth || 0;\n }\n\n /** webcam current height */\n public get height(): number {\n return this.element?.videoHeight || 0;\n }\n\n public enumerate = async (): Promise => {\n try {\n const devices = await navigator.mediaDevices.enumerateDevices();\n this.devices = devices.filter((device) => device.kind === 'videoinput');\n } catch {\n this.devices = [];\n }\n return this.devices;\n };\n\n /** start method initializizes webcam stream and associates it with a dom video element */\n public start = async (webcamConfig?: Partial): Promise => {\n // set config\n if (webcamConfig?.debug) this.config.debug = webcamConfig?.debug;\n if (webcamConfig?.crop) this.config.crop = webcamConfig?.crop;\n if (webcamConfig?.mode) this.config.mode = webcamConfig?.mode;\n if (webcamConfig?.width) this.config.width = webcamConfig?.width;\n if (webcamConfig?.height) this.config.height = webcamConfig?.height;\n if (webcamConfig?.id) this.config.id = webcamConfig?.id;\n\n // use or create dom element\n if (webcamConfig?.element) {\n if (typeof webcamConfig.element === 'string') {\n const el = document.getElementById(webcamConfig.element);\n if (el && el instanceof HTMLVideoElement) {\n this.element = el;\n } else {\n if (this.config.debug) log('webcam', 'cannot get dom element', webcamConfig.element);\n return `webcam error: cannot get dom element: ${webcamConfig.element}`;\n }\n } else if (webcamConfig.element instanceof HTMLVideoElement) {\n this.element = webcamConfig.element;\n } else {\n if (this.config.debug) log('webcam', 'unknown dom element', webcamConfig.element);\n return `webcam error: unknown dom element: ${webcamConfig.element}`;\n }\n } else {\n this.element = document.createElement('video');\n }\n\n // set constraints to use\n const requestedConstraints: MediaStreamConstraints = {\n audio: false,\n video: {\n facingMode: this.config.mode === 'front' ? 'user' : 'environment',\n // @ts-ignore // resizeMode is still not defined in tslib\n resizeMode: this.config.crop ? 'crop-and-scale' : 'none',\n },\n };\n if (this.config?.width > 0) (requestedConstraints.video as MediaTrackConstraints).width = { ideal: this.config.width };\n if (this.config?.height > 0) (requestedConstraints.video as MediaTrackConstraints).height = { ideal: this.config.height };\n if (this.config.id) (requestedConstraints.video as MediaTrackConstraintSet).deviceId = this.config.id;\n\n // set default event listeners\n this.element.addEventListener('play', () => { if (this.config.debug) log('webcam', 'play'); });\n this.element.addEventListener('pause', () => { if (this.config.debug) log('webcam', 'pause'); });\n this.element.addEventListener('click', async () => { // pause when clicked on screen and resume on next click\n if (!this.element || !this.stream) return;\n if (this.element.paused) await this.element.play();\n else this.element.pause();\n });\n\n // get webcam and set it to run in dom element\n if (!navigator?.mediaDevices) {\n if (this.config.debug) log('webcam error', 'no devices');\n return 'webcam error: no devices';\n }\n try {\n this.stream = await navigator.mediaDevices.getUserMedia(requestedConstraints); // get stream that satisfies constraints\n } catch (err) {\n log('webcam', err);\n return `webcam error: ${err}`;\n }\n if (!this.stream) {\n if (this.config.debug) log('webcam error', 'no stream');\n return 'webcam error no stream';\n }\n this.element.srcObject = this.stream; // assign it to dom element\n const ready = new Promise((resolve) => { // wait until stream is ready\n if (!this.element) resolve(false);\n else this.element.onloadeddata = () => resolve(true);\n });\n await ready;\n await this.element.play(); // start playing\n\n if (this.config.debug) {\n log('webcam', {\n width: this.width,\n height: this.height,\n label: this.label,\n stream: this.stream,\n track: this.track,\n settings: this.settings,\n constraints: this.constraints,\n capabilities: this.capabilities,\n });\n }\n return `webcam: ${this.label}`;\n };\n\n /** pause webcam video method */\n public pause = (): void => {\n if (this.element) this.element.pause();\n };\n\n /** play webcam video method */\n public play = async (): Promise => {\n if (this.element) await this.element.play();\n };\n\n /** stop method stops active webcam stream track and disconnects webcam */\n public stop = (): void => {\n if (this.config.debug) log('webcam', 'stop');\n if (this.track) this.track.stop();\n };\n}\n", "{\n \"antispoof\": 853098,\n \"blazeface\": 538928,\n \"centernet\": 4030290,\n \"emotion\": 820516,\n \"facemesh\": 1477958,\n \"faceres\": 6978814,\n \"handlandmark-lite\": 2023432,\n \"handtrack\": 2964837,\n \"iris\": 2599092,\n \"liveness\": 592976,\n \"models\": 0,\n \"movenet-lightning\": 4650216,\n \"affectnet-mobilenet\": 6920630,\n \"age\": 161240,\n \"blazeface-back\": 538928,\n \"blazeface-front\": 402048,\n \"blazepose-detector\": 5928856,\n \"blazepose-full\": 6339202,\n \"blazepose-heavy\": 27502466,\n \"blazepose-lite\": 2726402,\n \"efficientpose\": 5651240,\n \"faceboxes\": 2013002,\n \"facemesh-attention-pinto\": 2387598,\n \"facemesh-attention\": 2382414,\n \"facemesh-detection-full\": 1026192,\n \"facemesh-detection-short\": 201268,\n \"faceres-deep\": 13957620,\n \"gear-e1\": 112438,\n \"gear-e2\": 112438,\n \"gear\": 1498916,\n \"gender-ssrnet-imdb\": 161236,\n \"gender\": 201808,\n \"handdetect\": 3515612,\n \"handlandmark-full\": 5431368,\n \"handlandmark-sparse\": 5286322,\n \"handskeleton\": 5502280,\n \"meet\": 372228,\n \"mobileface\": 2183192,\n \"mobilefacenet\": 5171976,\n \"movenet-multipose\": 9448838,\n \"movenet-thunder\": 12477112,\n \"nanodet\": 7574558,\n \"posenet\": 5032780,\n \"rvm\": 3739355,\n \"selfie\": 212886,\n \"anti-spoofing\": 853098,\n \"efficientpose-i-lite\": 2269064,\n \"efficientpose-ii-lite\": 5651240,\n \"efficientpose-iv\": 25643252,\n \"insightface-efficientnet-b0\": 13013224,\n \"insightface-ghostnet-strides1\": 8093408,\n \"insightface-ghostnet-strides2\": 8049584,\n \"insightface-mobilenet-emore\": 6938536,\n \"insightface-mobilenet-swish\": 12168584,\n \"nanodet-e\": 12319156,\n \"nanodet-g\": 7574558,\n \"nanodet-m\": 1887474,\n \"nanodet-t\": 5294216\n}", "import * as tf from 'dist/tfjs.esm.js';\nimport { log, join } from '../util/util';\nimport type { GraphModel } from './types';\nimport type { Config } from '../config';\nimport * as modelsDefs from '../../models/models.json';\n\nconst options = {\n cacheModels: true,\n cacheSupported: true,\n verbose: true,\n debug: false,\n modelBasePath: '',\n};\n\nexport interface ModelInfo {\n name: string,\n inCache: boolean,\n sizeDesired: number,\n sizeFromManifest: number,\n sizeLoadedWeights: number,\n url: string,\n}\n\nexport const modelStats: Record = {};\n\nasync function httpHandler(url: string, init?: RequestInit): Promise {\n if (options.debug) log('load model fetch:', url, init);\n return fetch(url, init);\n}\n\nexport function setModelLoadOptions(config: Config) {\n options.cacheModels = config.cacheModels;\n options.verbose = config.debug;\n options.modelBasePath = config.modelBasePath;\n}\n\nexport async function loadModel(modelPath: string | undefined): Promise {\n let modelUrl = join(options.modelBasePath, modelPath || '');\n if (!modelUrl.toLowerCase().endsWith('.json')) modelUrl += '.json';\n const modelPathSegments = modelUrl.includes('/') ? modelUrl.split('/') : modelUrl.split('\\\\');\n const shortModelName = modelPathSegments[modelPathSegments.length - 1].replace('.json', '');\n const cachedModelName = 'indexeddb://' + shortModelName; // generate short model name for cache\n modelStats[shortModelName] = {\n name: shortModelName,\n sizeFromManifest: 0,\n sizeLoadedWeights: 0,\n sizeDesired: modelsDefs[shortModelName],\n inCache: false,\n url: '',\n };\n options.cacheSupported = (typeof indexedDB !== 'undefined'); // check if localStorage and indexedb are available\n let cachedModels = {};\n try {\n cachedModels = (options.cacheSupported && options.cacheModels) ? await tf.io.listModels() : {}; // list all models already in cache // this fails for webview although localStorage is defined\n } catch {\n options.cacheSupported = false;\n }\n modelStats[shortModelName].inCache = (options.cacheSupported && options.cacheModels) && Object.keys(cachedModels).includes(cachedModelName); // is model found in cache\n modelStats[shortModelName].url = modelStats[shortModelName].inCache ? cachedModelName : modelUrl;\n const tfLoadOptions = typeof fetch === 'undefined' ? {} : { fetchFunc: (url: string, init?: RequestInit) => httpHandler(url, init) };\n let model: GraphModel = new tf.GraphModel(modelStats[shortModelName].url, tfLoadOptions) as unknown as GraphModel; // create model prototype and decide if load from cache or from original modelurl\n let loaded = false;\n try {\n // @ts-ignore private function\n model.findIOHandler(); // decide how to actually load a model\n if (options.debug) log('model load handler:', model['handler']);\n } catch (err) {\n log('error finding model i/o handler:', modelUrl, err);\n }\n try {\n // @ts-ignore private property\n const artifacts = await model.handler?.load() || null; // load manifest\n modelStats[shortModelName].sizeFromManifest = artifacts?.weightData?.byteLength || 0;\n if (artifacts) model.loadSync(artifacts); // load weights\n else model = await tf.loadGraphModel(modelStats[shortModelName].inCache ? cachedModelName : modelUrl, tfLoadOptions) as unknown as GraphModel;\n // @ts-ignore private property\n modelStats[shortModelName].sizeLoadedWeights = model.artifacts?.weightData?.byteLength || 0;\n if (options.verbose) log('load:', { model: shortModelName, url: model['modelUrl'], bytes: modelStats[shortModelName].sizeLoadedWeights });\n loaded = true;\n } catch (err) {\n log('error loading model:', modelUrl, err);\n }\n if (loaded && options.cacheModels && options.cacheSupported && !modelStats[shortModelName].inCache) { // save model to cache\n try {\n const saveResult = await model.save(cachedModelName);\n if (options.debug) log('model saved:', cachedModelName, saveResult);\n } catch (err) {\n log('error saving model:', modelUrl, err);\n }\n }\n return model;\n}\n", "{\n \"name\": \"@vladmandic/human\",\n \"version\": \"3.1.1\",\n \"description\": \"Human: AI-powered 3D Face Detection & Rotation Tracking, Face Description & Recognition, Body Pose Tracking, 3D Hand & Finger Tracking, Iris Analysis, Age & Gender & Emotion Prediction, Gesture Recognition\",\n \"sideEffects\": false,\n \"main\": \"dist/human.node.js\",\n \"module\": \"dist/human.esm.js\",\n \"browser\": \"dist/human.esm.js\",\n \"types\": \"types/human.d.ts\",\n \"exports\": {\n \"node\": {\n \"require\": \"./dist/human.node.js\",\n \"import\": \"./dist/human.node.js\",\n \"module\": \"./dist/human.node.js\"\n },\n \"require\": \"./dist/human.node.js\",\n \"import\": \"./dist/human.esm.js\",\n \"script\": \"./dist/human.js\",\n \"module\": \"./dist/human.esm.js\",\n \"types\": \"./types/human.d.ts\",\n \"dist/human\": \"./dist/human.js\",\n \"dist/human.js\": \"./dist/human.js\",\n \"dist/human.esm\": \"./dist/human.esm.js\",\n \"dist/human.esm.js\": \"./dist/human.esm.js\",\n \"dist/human.esm-nobundle\": \"./dist/human.esm-nobundle.js\",\n \"dist/human.esm-nobundle.js\": \"./dist/human.esm-nobundle.js\",\n \"dist/human.node\": \"./dist/human.node.js\",\n \"dist/human.node.js\": \"./dist/human.node.js\",\n \"dist/human.node-wasm\": \"./dist/human.node-wasm.js\",\n \"dist/human.node-wasm.js\": \"./dist/human.node-wasm.js\",\n \"dist/human.node-gpu\": \"./dist/human.node-gpu.js\",\n \"dist/human.node-gpu.js\": \"./dist/human.node-gpu.js\"\n },\n \"author\": \"Vladimir Mandic \",\n \"bugs\": {\n \"url\": \"https://github.com/vladmandic/human/issues\"\n },\n \"homepage\": \"https://vladmandic.github.io/human/demo/index.html\",\n \"license\": \"MIT\",\n \"engines\": {\n \"node\": \">=14.0.0\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/vladmandic/human.git\"\n },\n \"scripts\": {\n \"start\": \"node --no-warnings demo/nodejs/node.js\",\n \"dev\": \"build --profile development\",\n \"clean\": \"build --profile clean\",\n \"build\": \"rimraf test/build.log && node build.js\",\n \"test\": \"node --no-warnings --unhandled-rejections=strict --trace-uncaught test/node.js\",\n \"lint\": \"eslint *.json *.js src demo test models wiki\",\n \"scan\": \"npx auditjs@latest ossi --dev --quiet\"\n },\n \"keywords\": [\n \"human\",\n \"human-library\",\n \"face-detection\",\n \"faceid\",\n \"face-geometry\",\n \"face-embedding\",\n \"face-recognition\",\n \"face-description\",\n \"face-matching\",\n \"body-tracking\",\n \"body-segmentation\",\n \"hand-tracking\",\n \"iris-tracking\",\n \"age-estimation\",\n \"emotion-detection\",\n \"gender-prediction\",\n \"gesture-recognition\",\n \"gaze-tracking\",\n \"age-gender\",\n \"tensorflowjs\",\n \"tfjs\",\n \"tensorflow\"\n ],\n \"devDependencies\": {\n \"@html-eslint/eslint-plugin\": \"^0.19.1\",\n \"@html-eslint/parser\": \"^0.19.1\",\n \"@microsoft/api-extractor\": \"^7.37.0\",\n \"@tensorflow/tfjs-backend-cpu\": \"^4.11.0\",\n \"@tensorflow/tfjs-backend-wasm\": \"^4.11.0\",\n \"@tensorflow/tfjs-backend-webgl\": \"^4.11.0\",\n \"@tensorflow/tfjs-backend-webgpu\": \"4.11.0\",\n \"@tensorflow/tfjs-converter\": \"^4.11.0\",\n \"@tensorflow/tfjs-core\": \"^4.11.0\",\n \"@tensorflow/tfjs-data\": \"^4.11.0\",\n \"@tensorflow/tfjs-layers\": \"^4.11.0\",\n \"@tensorflow/tfjs-node\": \"^4.11.0\",\n \"@tensorflow/tfjs-node-gpu\": \"^4.11.0\",\n \"@types/node\": \"^20.6.2\",\n \"@types/offscreencanvas\": \"^2019.7.1\",\n \"@typescript-eslint/eslint-plugin\": \"^6.7.0\",\n \"@typescript-eslint/parser\": \"^6.7.0\",\n \"@vladmandic/build\": \"^0.9.2\",\n \"@vladmandic/pilogger\": \"^0.4.8\",\n \"@vladmandic/tfjs\": \"github:vladmandic/tfjs\",\n \"canvas\": \"^2.11.2\",\n \"esbuild\": \"^0.19.3\",\n \"eslint\": \"8.49.0\",\n \"eslint-config-airbnb-base\": \"^15.0.0\",\n \"eslint-plugin-html\": \"^7.1.0\",\n \"eslint-plugin-import\": \"^2.28.1\",\n \"eslint-plugin-json\": \"^3.1.0\",\n \"eslint-plugin-markdown\": \"^3.0.1\",\n \"eslint-plugin-node\": \"^11.1.0\",\n \"eslint-plugin-promise\": \"^6.1.1\",\n \"rimraf\": \"^5.0.1\",\n \"tslib\": \"^2.6.2\",\n \"typedoc\": \"0.25.1\",\n \"typescript\": \"^5.1.6\"\n }\n}\n", "/** TFJS custom backend registration */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Human } from '../human';\nimport { log } from '../util/util';\nimport * as image from '../image/image';\nimport type { AnyCanvas } from '../exports';\n\nexport const config = {\n name: 'humangl',\n priority: 999,\n canvas: null as null | AnyCanvas,\n gl: null as null | WebGL2RenderingContext,\n extensions: [] as string[] | null,\n webGLattr: { // https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.2\n alpha: false,\n antialias: false,\n premultipliedAlpha: false,\n preserveDrawingBuffer: false,\n depth: false,\n stencil: false,\n failIfMajorPerformanceCaveat: false, // default=true\n desynchronized: true, // default=undefined\n },\n};\n\nfunction extensions(): void {\n /*\n https://www.khronos.org/registry/webgl/extensions/\n https://webglreport.com/?v=2\n */\n const gl = config.gl;\n if (!gl) return;\n config.extensions = gl.getSupportedExtensions();\n // gl.getExtension('KHR_parallel_shader_compile');\n}\n\n/**\n * Registers custom WebGL2 backend to be used by Human library\n *\n * @returns void\n */\nexport function register(instance: Human): void {\n // force backend reload if gl context is not valid\n if (instance.config.backend !== 'humangl') return;\n if ((config.name in tf.engine().registry) && !config?.gl?.getParameter(config.gl.VERSION)) {\n log('humangl error: backend invalid context');\n instance.models.reset();\n /*\n log('resetting humangl backend');\n await tf.removeBackend(config.name);\n await register(instance); // re-register\n */\n }\n if (!tf.findBackend(config.name)) {\n try {\n config.canvas = image.canvas(100, 100);\n } catch (err) {\n log('humangl error: cannot create canvas:', err);\n return;\n }\n try {\n config.gl = config.canvas.getContext('webgl2', config.webGLattr) as WebGL2RenderingContext;\n if (!config.gl) {\n log('humangl error: cannot get webgl context');\n return;\n }\n const glv2 = config.gl.getParameter(config.gl.VERSION).includes('2.0');\n if (!glv2) {\n log('backend override: using fallback webgl backend as webgl 2.0 is not detected');\n instance.config.backend = 'webgl';\n return;\n }\n if (config.canvas) {\n config.canvas.addEventListener('webglcontextlost', (e) => {\n log('humangl error:', e.type);\n log('possible browser memory leak using webgl or conflict with multiple backend registrations');\n instance.emit('error');\n throw new Error('backend error: webgl context lost');\n });\n config.canvas.addEventListener('webglcontextrestored', (e) => {\n log('humangl error: context restored:', e);\n });\n config.canvas.addEventListener('webglcontextcreationerror', (e) => {\n log('humangl error: context create:', e);\n });\n }\n } catch (err) {\n log('humangl error: cannot get webgl context:', err);\n return;\n }\n try {\n tf.setWebGLContext(2, config.gl);\n } catch (err) {\n log('humangl error: cannot set webgl context:', err);\n return;\n }\n try {\n const ctx = new tf.GPGPUContext(config.gl);\n // @ts-ignore uncompatible kernelMs timing info\n tf.registerBackend(config.name, () => new tf.MathBackendWebGL(ctx), config.priority);\n } catch (err) {\n log('humangl error: cannot register webgl backend:', err);\n return;\n }\n try {\n const kernels = tf.getKernelsForBackend('webgl');\n kernels.forEach((kernelConfig) => {\n const newKernelConfig = { ...kernelConfig, backendName: config.name };\n tf.registerKernel(newKernelConfig);\n });\n } catch (err) {\n log('humangl error: cannot update webgl backend registration:', err);\n return;\n }\n try {\n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_VERSION) tf.env().set('WEBGL_VERSION', 2);\n } catch (err) {\n log('humangl error: cannot set WebGL backend flags:', err);\n return;\n }\n extensions();\n const backend = tf.backend();\n const current = typeof backend['gpgpu'] !== 'undefined' ? backend['getGPGPUContext']().gl : null;\n if (current) {\n if (instance.config.debug) log('humangl backend registered:', { webgl: current.getParameter(current.VERSION) as string, renderer: current.getParameter(current.RENDERER) as string });\n } else {\n log('humangl error: no current gl context:', current, config.gl);\n }\n }\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport type { Tensor } from './types';\n\nexport const constants: Record = {\n tf255: 255.0,\n tf1: 1.0,\n tf2: 2.0,\n tf05: 0.5,\n tf127: 127.5,\n rgb: [0.2989, 0.5870, 0.1140],\n};\n\nexport function init() {\n constants.tf255 = tf.scalar(255.0, 'float32');\n constants.tf1 = tf.scalar(1.0, 'float32');\n constants.tf2 = tf.scalar(2.0, 'float32');\n constants.tf05 = tf.scalar(0.5, 'float32');\n constants.tf127 = tf.scalar(127.5, 'float32');\n constants.rgb = tf.tensor1d([0.2989, 0.5870, 0.1140], 'float32'); // factors for red/green/blue colors when converting to grayscale\n}\n", "/** TFJS backend initialization and customization */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Human, Config, BackendEnum } from '../human';\nimport { log, now } from '../util/util';\nimport { env } from '../util/env';\nimport * as humangl from './humangl';\nimport * as constants from './constants';\nimport type { TensorInfo } from './types';\n\nexport async function getBestBackend(): Promise {\n await env.updateBackend(); // update env on backend init\n if (env.tensorflow?.version) return 'tensorflow';\n if (env.webgpu.supported && env.webgpu.backend) return 'webgpu';\n if (env.webgl.supported && env.webgl.backend) return 'webgl';\n if (env.wasm.supported && env.wasm.backend) return 'wasm';\n return 'cpu';\n}\n\nfunction registerCustomOps(config: Config) {\n const newKernels: string[] = [];\n if (!env.kernels.includes('mod')) {\n const kernelMod = {\n kernelName: 'Mod',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => tf.sub(op.inputs.a, tf.mul(tf.div(op.inputs.a, op.inputs.b), op.inputs.b))),\n };\n tf.registerKernel(kernelMod);\n env.kernels.push('mod');\n newKernels.push('mod');\n }\n if (!env.kernels.includes('floormod')) {\n const kernelFloorMod = {\n kernelName: 'FloorMod',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => tf.add(tf.mul(tf.floorDiv(op.inputs.a, op.inputs.b), op.inputs.b), tf.mod(op.inputs.a, op.inputs.b))),\n };\n tf.registerKernel(kernelFloorMod);\n env.kernels.push('floormod');\n newKernels.push('floormod');\n }\n /*\n if (!env.kernels.includes('atan2') && config.softwareKernels) {\n const kernelAtan2 = {\n kernelName: 'Atan2',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => {\n const backend = tf.getBackend();\n tf.setBackend('cpu');\n const t = tf.atan2(op.inputs.a, op.inputs.b);\n tf.setBackend(backend);\n return t;\n }),\n };\n if (config.debug) log('registered kernel:', 'atan2');\n log('registered kernel:', 'atan2');\n tf.registerKernel(kernelAtan2);\n env.kernels.push('atan2');\n newKernels.push('atan2');\n }\n */\n if (!env.kernels.includes('rotatewithoffset') && config.softwareKernels) {\n const kernelRotateWithOffset = {\n kernelName: 'RotateWithOffset',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => {\n const backend = tf.getBackend();\n tf.setBackend('cpu'); // eslint-disable-line @typescript-eslint/no-floating-promises\n const t = tf.image.rotateWithOffset(op.inputs.image, op.attrs.radians, op.attrs.fillValue, op.attrs.center);\n tf.setBackend(backend); // eslint-disable-line @typescript-eslint/no-floating-promises\n return t;\n }),\n };\n tf.registerKernel(kernelRotateWithOffset);\n env.kernels.push('rotatewithoffset');\n newKernels.push('rotatewithoffset');\n }\n if ((newKernels.length > 0) && config.debug) log('registered kernels:', newKernels);\n}\n\nlet defaultFlags: Record = {};\n\nexport async function check(instance: Human, force = false) {\n instance.state = 'backend';\n if (instance.config.backend?.length === 0) instance.config.backend = await getBestBackend();\n if (force || env.initial || (instance.config.backend && (instance.config.backend.length > 0) && (tf.getBackend() !== instance.config.backend))) {\n const timeStamp = now();\n\n if (instance.config.backend && instance.config.backend.length > 0) {\n // detect web worker\n // @ts-ignore ignore missing type for WorkerGlobalScope as that is the point\n if (typeof window === 'undefined' && typeof WorkerGlobalScope !== 'undefined' && instance.config.debug) {\n if (instance.config.debug) log('running inside web worker');\n }\n\n if (typeof navigator !== 'undefined' && navigator?.userAgent?.toLowerCase().includes('electron')) {\n if (instance.config.debug) log('running inside electron');\n }\n\n // check available backends\n let available = Object.keys(tf.engine().registryFactory as Record);\n if (instance.config.backend === 'humangl' && !available.includes('humangl')) {\n humangl.register(instance);\n available = Object.keys(tf.engine().registryFactory as Record);\n }\n if (instance.config.debug) log('available backends:', available);\n\n // force browser vs node backend\n if (env.browser && !env.node && (instance.config.backend === 'tensorflow') && available.includes('webgl')) {\n if (instance.config.debug) log('override: backend set to tensorflow while running in browser');\n instance.config.backend = 'webgl';\n }\n if (env.node && !env.browser && (instance.config.backend === 'webgl' || instance.config.backend === 'humangl') && available.includes('tensorflow')) {\n if (instance.config.debug) log(`override: backend set to ${instance.config.backend} while running in nodejs`);\n instance.config.backend = 'tensorflow';\n }\n\n // handle webgpu\n if (env.browser && instance.config.backend === 'webgpu') {\n if (typeof navigator === 'undefined' || typeof navigator.gpu === 'undefined') {\n log('override: backend set to webgpu but browser does not support webgpu');\n instance.config.backend = 'webgl';\n } else {\n const adapter = await navigator.gpu.requestAdapter();\n if (instance.config.debug) log('enumerated webgpu adapter:', adapter);\n if (!adapter) {\n log('override: backend set to webgpu but browser reports no available gpu');\n instance.config.backend = 'webgl';\n } else {\n // @ts-ignore requestAdapterInfo is not in tslib\n const adapterInfo = 'requestAdapterInfo' in adapter ? await adapter.requestAdapterInfo() : undefined;\n // if (adapter.features) adapter.features.forEach((feature) => log('webgpu features:', feature));\n log('webgpu adapter info:', adapterInfo);\n }\n }\n }\n\n if (!available.includes(instance.config.backend)) {\n log(`error: backend ${instance.config.backend} not found in registry`);\n instance.config.backend = env.node ? 'tensorflow' : 'webgl';\n if (instance.config.debug) log(`override: setting backend ${instance.config.backend}`);\n }\n\n if (instance.config.debug) log('setting backend:', [instance.config.backend]);\n\n // customize wasm\n if (instance.config.backend === 'wasm') {\n // @ts-ignore private property\n if (tf.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY) tf.env().set('CANVAS2D_WILL_READ_FREQUENTLY', true);\n if (instance.config.debug) log('wasm path:', instance.config.wasmPath);\n if (typeof tf.setWasmPaths !== 'undefined') tf.setWasmPaths(instance.config.wasmPath, instance.config.wasmPlatformFetch);\n else throw new Error('backend error: attempting to use wasm backend but wasm path is not set');\n let mt = false;\n let simd = false;\n try {\n mt = await tf.env().getAsync('WASM_HAS_MULTITHREAD_SUPPORT') as boolean;\n simd = await tf.env().getAsync('WASM_HAS_SIMD_SUPPORT') as boolean;\n if (instance.config.debug) log(`wasm execution: ${simd ? 'simd' : 'no simd'} ${mt ? 'multithreaded' : 'singlethreaded'}`);\n if (instance.config.debug && !simd) log('warning: wasm simd support is not enabled');\n } catch {\n log('wasm detection failed');\n }\n }\n\n try {\n await tf.setBackend(instance.config.backend);\n await tf.ready();\n } catch (err) {\n log('error: cannot set backend:', instance.config.backend, err);\n return false;\n }\n // @ts-ignore private property\n if (instance.config.debug) defaultFlags = JSON.parse(JSON.stringify(tf.env().flags));\n }\n\n // customize humangl\n if (tf.getBackend() === 'humangl' || tf.getBackend() === 'webgl') {\n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS) tf.env().set('WEBGL_USE_SHAPES_UNIFORMS', true); // default=false \n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_EXP_CONV) tf.env().set('WEBGL_EXP_CONV', true); // default=false \n // if (tf.env().flagRegistry['WEBGL_PACK_DEPTHWISECONV']) tf.env().set('WEBGL_PACK_DEPTHWISECONV', false); // default=true \n // if (tf.env().flagRegistry.USE_SETTIMEOUTCUSTOM) tf.env().set('USE_SETTIMEOUTCUSTOM', true); // default=false \n // if (tf.env().flagRegistry.CPU_HANDOFF_SIZE_THRESHOLD) tf.env().set('CPU_HANDOFF_SIZE_THRESHOLD', 1024); // default=1000\n // if (tf.env().flagRegistry['WEBGL_FORCE_F16_TEXTURES'] && !instance.config.object.enabled) tf.env().set('WEBGL_FORCE_F16_TEXTURES', true); // safe to use 16bit precision\n if (instance.config.debug && typeof instance.config.deallocate !== 'undefined' && instance.config.deallocate) { // hidden param\n log('changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:', true);\n tf.env().set('WEBGL_DELETE_TEXTURE_THRESHOLD', 0);\n }\n }\n\n // customize webgpu\n if (tf.getBackend() === 'webgpu') {\n // if (tf.env().flagRegistry['WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD']) tf.env().set('WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD', 512);\n // if (tf.env().flagRegistry['WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE']) tf.env().set('WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE', 0);\n // if (tf.env().flagRegistry['WEBGPU_CPU_FORWARD']) tf.env().set('WEBGPU_CPU_FORWARD', true);\n }\n\n if (instance.config.debug) {\n // @ts-ignore private property\n const newFlags = tf.env().flags;\n const updatedFlags = {};\n for (const key of Object.keys(newFlags)) {\n if (defaultFlags[key] === newFlags[key]) continue;\n updatedFlags[key] = newFlags[key];\n }\n if (instance.config.debug && Object.keys(updatedFlags).length > 0) log('backend:', tf.getBackend(), 'flags:', updatedFlags);\n }\n\n if (instance.config.flags && Object.keys(instance.config.flags).length > 0) {\n if (instance.config.debug) log('flags:', instance.config['flags']);\n for (const [key, val] of Object.entries(instance.config.flags)) {\n tf.env().set(key, val as number | boolean);\n }\n }\n\n tf.enableProdMode();\n constants.init();\n instance.performance.initBackend = Math.trunc(now() - timeStamp);\n instance.config.backend = tf.getBackend() as BackendEnum;\n await env.updateBackend(); // update env on backend init\n registerCustomOps(instance.config);\n // await env.updateBackend(); // update env on backend init\n // env.initial = false;\n }\n return true;\n}\n\n// register fake missing tfjs ops\nexport function fakeOps(kernelNames: string[], config) {\n // if (config.debug) log('registerKernel:', kernelNames);\n for (const kernelName of kernelNames) {\n const kernelConfig = {\n kernelName,\n backendName: config.backend,\n kernelFunc: (param): TensorInfo => {\n if (config.debug) log('kernelFunc', kernelName, config.backend, param);\n return param?.inputs?.info as TensorInfo;\n },\n // setupFunc: () => { if (config.debug) log('kernelFunc', kernelName, config.backend); },\n // disposeFunc: () => { if (config.debug) log('kernelFunc', kernelName, config.backend); },\n };\n tf.registerKernel(kernelConfig);\n }\n env.kernels = tf.getKernelsForBackend(tf.getBackend()).map((kernel) => kernel.kernelName.toLowerCase()); // re-scan registered ops\n}\n", "/**\n * Module that implements helper draw functions, exposed as human.draw\n */\n\nimport { mergeDeep, now } from '../util/util';\nimport { env } from '../util/env';\nimport { getCanvasContext, rect } from './primitives';\nimport { options } from './options';\nimport { face } from './face';\nimport { body } from './body';\nimport { hand } from './hand';\nimport { object } from './object';\nimport { gesture } from './gesture';\nimport { defaultLabels } from './labels';\nimport type { Result, PersonResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\nlet drawTime = 0;\n\nexport { options } from './options';\nexport { face } from './face';\nexport { body } from './body';\nexport { hand } from './hand';\nexport { object } from './object';\nexport { gesture } from './gesture';\n\n/** draw combined person results instead of individual detection result objects */\nexport function person(inCanvas: AnyCanvas, result: PersonResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n ctx.font = localOptions.font;\n\n for (let i = 0; i < result.length; i++) {\n if (localOptions.drawBoxes) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n rect(ctx, result[i].box[0], result[i].box[1], result[i].box[2], result[i].box[3], localOptions);\n if (localOptions.drawLabels) {\n const label = `person #${i}`;\n if (localOptions.shadowColor && localOptions.shadowColor !== '') {\n ctx.fillStyle = localOptions.shadowColor;\n ctx.fillText(label, result[i].box[0] + 3, 1 + result[i].box[1] + localOptions.lineHeight, result[i].box[2]);\n }\n ctx.fillStyle = localOptions.labelColor;\n ctx.fillText(label, result[i].box[0] + 2, 0 + result[i].box[1] + localOptions.lineHeight, result[i].box[2]);\n }\n ctx.stroke();\n }\n }\n}\n\n/** draw processed canvas */\nexport function canvas(input: AnyCanvas | HTMLImageElement | HTMLVideoElement, output: AnyCanvas) {\n if (!input || !output) return;\n const ctx = getCanvasContext(output) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.drawImage(input, 0, 0);\n}\n\n/** meta-function that performs draw for: canvas, face, body, hand */\nexport async function all(inCanvas: AnyCanvas, result: Result, drawOptions?: Partial) {\n if (!result?.performance || !inCanvas) return null;\n const timeStamp = now();\n const localOptions = mergeDeep(options, drawOptions);\n const promise = Promise.all([\n face(inCanvas, result.face, localOptions),\n body(inCanvas, result.body, localOptions),\n hand(inCanvas, result.hand, localOptions),\n object(inCanvas, result.object, localOptions),\n gesture(inCanvas, result.gesture, localOptions), // gestures do not have buffering\n // person(inCanvas, result.persons, localOptions); // already included above\n ]);\n drawTime = env.perfadd ? drawTime + Math.round(now() - timeStamp) : Math.round(now() - timeStamp);\n result.performance.draw = drawTime;\n return promise;\n}\n\n/** sets default label templates for face/body/hand/object/gestures */\nexport function init() {\n options.faceLabels = defaultLabels.face;\n options.bodyLabels = defaultLabels.body;\n options.bodyPartLabels = defaultLabels.bodyPart;\n options.handLabels = defaultLabels.hand;\n options.fingerLabels = defaultLabels.finger;\n options.objectLabels = defaultLabels.object;\n options.gestureLabels = defaultLabels.gesture;\n}\n", "import { log } from '../util/util';\nimport type { AnyCanvas } from '../exports';\nimport type { Point } from '../result';\nimport type { DrawOptions } from './options';\n\nexport const getCanvasContext = (input: AnyCanvas) => {\n if (!input) log('draw error: invalid canvas');\n else if (!input.getContext) log('draw error: canvas context not defined');\n else {\n const ctx = input.getContext('2d', { willReadFrequently: true });\n if (!ctx) log('draw error: cannot get canvas context');\n else return ctx;\n }\n return null;\n};\n\nexport const rad2deg = (theta: number) => Math.round((theta * 180) / Math.PI);\n\nexport const replace = (str: string, source: string, target: string | number) => str.replace(source, typeof target === 'number' ? target.toFixed(1) : target);\n\nexport const colorDepth = (z: number | undefined, opt: DrawOptions): string => { // performance optimization needed\n if (!opt.useDepth || typeof z === 'undefined') return opt.color;\n const rgb = Uint8ClampedArray.from([127 + (2 * z), 127 - (2 * z), 255]);\n return `rgba(${rgb[0]}, ${rgb[1]}, ${rgb[2]}, ${opt.alpha})`;\n};\n\nexport function labels(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, str: string, startX: number, startY: number, localOptions: DrawOptions) {\n const line: string[] = str.replace(/\\[.*\\]/g, '').split('\\n').map((l) => l.trim()); // remove unmatched templates and split into array\n const x = Math.max(0, startX);\n for (let i = line.length - 1; i >= 0; i--) {\n const y = i * localOptions.lineHeight + startY;\n if (localOptions.shadowColor && localOptions.shadowColor !== '') {\n ctx.fillStyle = localOptions.shadowColor;\n ctx.fillText(line[i], x + 5, y + 16);\n }\n ctx.fillStyle = localOptions.labelColor;\n ctx.fillText(line[i], x + 4, y + 15);\n }\n}\n\nexport function point(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, x: number, y: number, z: number | undefined, localOptions: DrawOptions) {\n ctx.fillStyle = colorDepth(z, localOptions);\n ctx.beginPath();\n ctx.arc(x, y, localOptions.pointSize, 0, 2 * Math.PI);\n ctx.fill();\n}\n\nexport function rect(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, x: number, y: number, width: number, height: number, localOptions: DrawOptions) {\n ctx.beginPath();\n ctx.lineWidth = localOptions.lineWidth;\n if (localOptions.useCurves) {\n const cx = (x + x + width) / 2;\n const cy = (y + y + height) / 2;\n ctx.ellipse(cx, cy, width / 2, height / 2, 0, 0, 2 * Math.PI);\n } else {\n ctx.moveTo(x + localOptions.roundRect, y);\n ctx.lineTo(x + width - localOptions.roundRect, y);\n ctx.quadraticCurveTo(x + width, y, x + width, y + localOptions.roundRect);\n ctx.lineTo(x + width, y + height - localOptions.roundRect);\n ctx.quadraticCurveTo(x + width, y + height, x + width - localOptions.roundRect, y + height);\n ctx.lineTo(x + localOptions.roundRect, y + height);\n ctx.quadraticCurveTo(x, y + height, x, y + height - localOptions.roundRect);\n ctx.lineTo(x, y + localOptions.roundRect);\n ctx.quadraticCurveTo(x, y, x + localOptions.roundRect, y);\n ctx.closePath();\n }\n ctx.stroke();\n}\n\nexport function lines(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, points: Point[], localOptions: DrawOptions) {\n if (points.length < 2) return;\n ctx.beginPath();\n ctx.moveTo(points[0][0], points[0][1]);\n for (const pt of points) {\n ctx.strokeStyle = colorDepth(pt[2] || 0, localOptions);\n ctx.lineTo(Math.trunc(pt[0]), Math.trunc(pt[1]));\n }\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.closePath();\n ctx.fill();\n }\n}\n\nexport function curves(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, points: Point[], localOptions: DrawOptions) {\n if (points.length < 2) return;\n ctx.lineWidth = localOptions.lineWidth;\n if (!localOptions.useCurves || points.length <= 2) {\n lines(ctx, points, localOptions);\n return;\n }\n ctx.moveTo(points[0][0], points[0][1]);\n for (let i = 0; i < points.length - 2; i++) {\n const xc = (points[i][0] + points[i + 1][0]) / 2;\n const yc = (points[i][1] + points[i + 1][1]) / 2;\n ctx.quadraticCurveTo(points[i][0], points[i][1], xc, yc);\n }\n ctx.quadraticCurveTo(points[points.length - 2][0], points[points.length - 2][1], points[points.length - 1][0], points[points.length - 1][1]);\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.closePath();\n ctx.fill();\n }\n}\n\nexport function arrow(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, from: Point, to: Point, radius = 5) {\n let angle;\n let x;\n let y;\n ctx.beginPath();\n ctx.moveTo(from[0], from[1]);\n ctx.lineTo(to[0], to[1]);\n angle = Math.atan2(to[1] - from[1], to[0] - from[0]);\n x = radius * Math.cos(angle) + to[0];\n y = radius * Math.sin(angle) + to[1];\n ctx.moveTo(x, y);\n angle += (1.0 / 3.0) * (2 * Math.PI);\n x = radius * Math.cos(angle) + to[0];\n y = radius * Math.sin(angle) + to[1];\n ctx.lineTo(x, y);\n angle += (1.0 / 3.0) * (2 * Math.PI);\n x = radius * Math.cos(angle) + to[0];\n y = radius * Math.sin(angle) + to[1];\n ctx.lineTo(x, y);\n ctx.closePath();\n ctx.stroke();\n ctx.fill();\n}\n", "/** Draw Options\n * - Accessed via `human.draw.options` or provided per each draw method as the drawOptions optional parameter\n */\n\nexport interface DrawOptions {\n /** draw line color */\n color: string,\n /** alpha value used for lines */\n alpha: number,\n /** label color */\n labelColor: string,\n /** label shadow color */\n shadowColor: string,\n /** label font */\n font: string,\n /** line spacing between labels */\n lineHeight: number,\n /** line width for drawn lines */\n lineWidth: number,\n /** size of drawn points */\n pointSize: number,\n /** draw rounded boxes by n pixels */\n roundRect: number,\n /** should points be drawn? */\n drawPoints: boolean,\n /** should labels be drawn? */\n drawLabels: boolean,\n /** should face attention keypoints be highlighted */\n drawAttention: boolean;\n /** should detected gestures be drawn? */\n drawGestures: boolean,\n /** should draw boxes around detection results? */\n drawBoxes: boolean,\n /** should draw polygons from detection points? */\n drawPolygons: boolean,\n /** should draw gaze arrows? */\n drawGaze: boolean,\n /** should fill polygons? */\n fillPolygons: boolean,\n /** use z-coordinate when available */\n useDepth: boolean,\n /** should lines be curved? */\n useCurves: boolean,\n /** string template for face labels */\n faceLabels: string,\n /** string template for body labels */\n bodyLabels: string,\n /** string template for body part labels */\n bodyPartLabels: string,\n /** string template for hand labels */\n handLabels: string,\n /** string template for hand labels */\n fingerLabels: string,\n /** string template for object labels */\n objectLabels: string,\n /** string template for gesture labels */\n gestureLabels: string,\n}\n\n/** currently set draw options {@link DrawOptions} */\nexport const options: DrawOptions = {\n color: 'rgba(173, 216, 230, 0.6)' as string, // 'lightblue' with light alpha channel\n labelColor: 'rgba(173, 216, 230, 1)' as string, // 'lightblue' with dark alpha channel\n shadowColor: 'black' as string,\n alpha: 0.5 as number,\n font: 'small-caps 16px \"Segoe UI\"' as string,\n lineHeight: 18 as number,\n lineWidth: 4 as number,\n pointSize: 2 as number,\n roundRect: 8 as number,\n drawPoints: false as boolean,\n drawLabels: true as boolean,\n drawBoxes: true as boolean,\n drawAttention: true as boolean,\n drawGestures: true as boolean,\n drawPolygons: true as boolean,\n drawGaze: true as boolean,\n fillPolygons: false as boolean,\n useDepth: true as boolean,\n useCurves: false as boolean,\n faceLabels: '' as string,\n bodyLabels: '' as string,\n bodyPartLabels: '' as string,\n objectLabels: '' as string,\n handLabels: '' as string,\n fingerLabels: '' as string,\n gestureLabels: '' as string,\n};\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n * See `facemesh.ts` for entry point\n */\n\nexport const meshAnnotations: Record = {\n silhouette: [\n 10, 338, 297, 332, 284, 251, 389, 356, 454, 323, 361, 288,\n 397, 365, 379, 378, 400, 377, 152, 148, 176, 149, 150, 136,\n 172, 58, 132, 93, 234, 127, 162, 21, 54, 103, 67, 109,\n ],\n // lipsUpperOuter: [61, 185, 40, 39, 37, 0, 267, 269, 270, 409, 291], // 11\n // lipsLowerOuter: [146, 91, 181, 84, 17, 314, 405, 321, 375, 291], // 10\n // lipsUpperInner: [78, 191, 80, 81, 82, 13, 312, 311, 310, 415, 308], // 11\n // lipsLowerInner: [78, 95, 88, 178, 87, 14, 317, 402, 318, 324, 308], // 11\n lipsUpperOuter: [185, 40, 39, 37, 0, 267, 269, 270, 409],\n lipsLowerOuter: [61, 146, 91, 181, 84, 17, 314, 405, 321, 375, 291],\n lipsUpperInner: [191, 80, 81, 82, 13, 312, 311, 310, 415],\n lipsLowerInner: [78, 95, 88, 178, 87, 14, 317, 402, 318, 324, 308],\n lipsLowerSemiOuter: [76, 77, 90, 180, 85, 16, 315, 404, 320, 307, 306],\n lipsUpperSemiOuter: [184, 74, 73, 72, 11, 302, 303, 304, 408],\n lipsLowerSemiInner: [62, 96, 89, 179, 86, 15, 316, 403, 319, 325, 292],\n lipsUpperSemiInner: [183, 42, 41, 38, 12, 268, 271, 272, 407],\n rightEyeUpper0: [246, 161, 160, 159, 158, 157, 173], // 7\n rightEyeLower0: [33, 7, 163, 144, 145, 153, 154, 155, 133], // 9\n rightEyeUpper1: [247, 30, 29, 27, 28, 56, 190], // 7\n rightEyeLower1: [130, 25, 110, 24, 23, 22, 26, 112, 243], // 9\n rightEyeUpper2: [113, 225, 224, 223, 222, 221, 189], // 7\n rightEyeLower2: [226, 31, 228, 229, 230, 231, 232, 233, 244], // 9\n rightEyeLower3: [143, 111, 117, 118, 119, 120, 121, 128, 245], // 9\n rightEyebrowUpper: [156, 70, 63, 105, 66, 107, 55, 193], // 8\n rightEyebrowLower: [35, 124, 46, 53, 52, 65], // 6\n rightEyeIris: [473, 474, 475, 476, 477], // 5\n leftEyeUpper0: [466, 388, 387, 386, 385, 384, 398],\n leftEyeLower0: [263, 249, 390, 373, 374, 380, 381, 382, 362],\n leftEyeUpper1: [467, 260, 259, 257, 258, 286, 414],\n leftEyeLower1: [359, 255, 339, 254, 253, 252, 256, 341, 463],\n leftEyeUpper2: [342, 445, 444, 443, 442, 441, 413],\n leftEyeLower2: [446, 261, 448, 449, 450, 451, 452, 453, 464],\n leftEyeLower3: [372, 340, 346, 347, 348, 349, 350, 357, 465],\n leftEyebrowUpper: [383, 300, 293, 334, 296, 336, 285, 417],\n leftEyebrowLower: [265, 353, 276, 283, 282, 295],\n leftEyeIris: [468, 469, 470, 471, 472],\n midwayBetweenEyes: [168],\n noseTip: [1],\n noseBottom: [2],\n noseRightCorner: [98],\n noseLeftCorner: [327],\n rightCheek: [205],\n leftCheek: [425],\n};\n\nexport const meshLandmarks: Record = {\n count: 468,\n mouth: 13,\n symmetryLine: [13, meshAnnotations.midwayBetweenEyes[0]],\n};\n\nexport const blazeFaceLandmarks: Record = {\n leftEye: 0,\n rightEye: 1,\n nose: 2,\n mouth: 3,\n leftEar: 4,\n rightEar: 5,\n symmetryLine: [3, 2],\n};\n\nexport const irisIndices: { key: string, indices: number[] }[] = [ // A mapping from facemesh model keypoints to iris model keypoints.\n { key: 'EyeUpper0', indices: [9, 10, 11, 12, 13, 14, 15] }, // 7 x 3d\n { key: 'EyeUpper1', indices: [25, 26, 27, 28, 29, 30, 31] }, // 7 x 3d\n { key: 'EyeUpper2', indices: [41, 42, 43, 44, 45, 46, 47] }, // 7 x 3d\n { key: 'EyeLower0', indices: [0, 1, 2, 3, 4, 5, 6, 7, 8] }, // 7 x 3d\n { key: 'EyeLower1', indices: [16, 17, 18, 19, 20, 21, 22, 23, 24] }, // 9 x 3d\n { key: 'EyeLower2', indices: [32, 33, 34, 35, 36, 37, 38, 39, 40] }, // 9 x 3d\n { key: 'EyeLower3', indices: [54, 55, 56, 57, 58, 59, 60, 61, 62] }, // 9 x 3d\n { key: 'EyebrowUpper', indices: [63, 64, 65, 66, 67, 68, 69, 70] }, // 8 x 3d\n { key: 'EyebrowLower', indices: [48, 49, 50, 51, 52, 53] }, // 6 x 3d\n];\n\nexport const UV468: [number, number][] = [\n [0.499976992607117, 0.652534008026123],\n [0.500025987625122, 0.547487020492554],\n [0.499974012374878, 0.602371990680695],\n [0.482113003730774, 0.471979022026062],\n [0.500150978565216, 0.527155995368958],\n [0.499909996986389, 0.498252987861633],\n [0.499523013830185, 0.40106201171875],\n [0.289712011814117, 0.380764007568359],\n [0.499954998493195, 0.312398016452789],\n [0.499987006187439, 0.269918978214264],\n [0.500023007392883, 0.107050001621246],\n [0.500023007392883, 0.666234016418457],\n [0.5000159740448, 0.679224014282227],\n [0.500023007392883, 0.692348003387451],\n [0.499976992607117, 0.695277988910675],\n [0.499976992607117, 0.70593398809433],\n [0.499976992607117, 0.719385027885437],\n [0.499976992607117, 0.737019002437592],\n [0.499967992305756, 0.781370997428894],\n [0.499816000461578, 0.562981009483337],\n [0.473773002624512, 0.573909997940063],\n [0.104906998574734, 0.254140973091125],\n [0.365929991006851, 0.409575998783112],\n [0.338757991790771, 0.41302502155304],\n [0.311120003461838, 0.409460008144379],\n [0.274657994508743, 0.389131009578705],\n [0.393361985683441, 0.403706014156342],\n [0.345234006643295, 0.344011008739471],\n [0.370094001293182, 0.346076011657715],\n [0.319321990013123, 0.347265005111694],\n [0.297903001308441, 0.353591024875641],\n [0.24779200553894, 0.410809993743896],\n [0.396889001131058, 0.842755019664764],\n [0.280097991228104, 0.375599980354309],\n [0.106310002505779, 0.399955987930298],\n [0.2099249958992, 0.391353011131287],\n [0.355807989835739, 0.534406006336212],\n [0.471751004457474, 0.65040397644043],\n [0.474155008792877, 0.680191993713379],\n [0.439785003662109, 0.657229006290436],\n [0.414617002010345, 0.66654098033905],\n [0.450374007225037, 0.680860996246338],\n [0.428770989179611, 0.682690978050232],\n [0.374971002340317, 0.727805018424988],\n [0.486716985702515, 0.547628998756409],\n [0.485300987958908, 0.527395009994507],\n [0.257764995098114, 0.314490020275116],\n [0.401223003864288, 0.455172002315521],\n [0.429818987846375, 0.548614978790283],\n [0.421351999044418, 0.533740997314453],\n [0.276895999908447, 0.532056987285614],\n [0.483370006084442, 0.499586999416351],\n [0.33721199631691, 0.282882988452911],\n [0.296391993761063, 0.293242990970612],\n [0.169294998049736, 0.193813979625702],\n [0.447580009698868, 0.302609980106354],\n [0.392390012741089, 0.353887975215912],\n [0.354490011930466, 0.696784019470215],\n [0.067304998636246, 0.730105042457581],\n [0.442739009857178, 0.572826027870178],\n [0.457098007202148, 0.584792017936707],\n [0.381974011659622, 0.694710969924927],\n [0.392388999462128, 0.694203019142151],\n [0.277076005935669, 0.271932005882263],\n [0.422551989555359, 0.563233017921448],\n [0.385919004678726, 0.281364023685455],\n [0.383103013038635, 0.255840003490448],\n [0.331431001424789, 0.119714021682739],\n [0.229923993349075, 0.232002973556519],\n [0.364500999450684, 0.189113974571228],\n [0.229622006416321, 0.299540996551514],\n [0.173287004232407, 0.278747975826263],\n [0.472878992557526, 0.666198015213013],\n [0.446828007698059, 0.668527007102966],\n [0.422762006521225, 0.673889994621277],\n [0.445307999849319, 0.580065965652466],\n [0.388103008270264, 0.693961024284363],\n [0.403039008378983, 0.706539988517761],\n [0.403629004955292, 0.693953037261963],\n [0.460041999816895, 0.557139039039612],\n [0.431158006191254, 0.692366003990173],\n [0.452181994915009, 0.692366003990173],\n [0.475387006998062, 0.692366003990173],\n [0.465828001499176, 0.779190003871918],\n [0.472328990697861, 0.736225962638855],\n [0.473087012767792, 0.717857003211975],\n [0.473122000694275, 0.704625964164734],\n [0.473033010959625, 0.695277988910675],\n [0.427942007780075, 0.695277988910675],\n [0.426479011774063, 0.703539967536926],\n [0.423162013292313, 0.711845993995667],\n [0.4183090031147, 0.720062971115112],\n [0.390094995498657, 0.639572978019714],\n [0.013953999616206, 0.560034036636353],\n [0.499913990497589, 0.58014702796936],\n [0.413199990987778, 0.69539999961853],\n [0.409626007080078, 0.701822996139526],\n [0.468080013990402, 0.601534962654114],\n [0.422728985548019, 0.585985004901886],\n [0.463079988956451, 0.593783974647522],\n [0.37211999297142, 0.47341400384903],\n [0.334562003612518, 0.496073007583618],\n [0.411671012639999, 0.546965003013611],\n [0.242175996303558, 0.14767599105835],\n [0.290776997804642, 0.201445996761322],\n [0.327338010072708, 0.256527006626129],\n [0.399509996175766, 0.748921036720276],\n [0.441727995872498, 0.261676013469696],\n [0.429764986038208, 0.187834024429321],\n [0.412198007106781, 0.108901023864746],\n [0.288955003023148, 0.398952007293701],\n [0.218936994671822, 0.435410976409912],\n [0.41278201341629, 0.398970007896423],\n [0.257135003805161, 0.355440020561218],\n [0.427684992551804, 0.437960982322693],\n [0.448339998722076, 0.536936044692993],\n [0.178560003638268, 0.45755398273468],\n [0.247308000922203, 0.457193970680237],\n [0.286267012357712, 0.467674970626831],\n [0.332827985286713, 0.460712015628815],\n [0.368755996227264, 0.447206974029541],\n [0.398963987827301, 0.432654976844788],\n [0.476410001516342, 0.405806005001068],\n [0.189241006970406, 0.523923993110657],\n [0.228962004184723, 0.348950982093811],\n [0.490725994110107, 0.562400996685028],\n [0.404670000076294, 0.485132992267609],\n [0.019469000399113, 0.401564002037048],\n [0.426243007183075, 0.420431017875671],\n [0.396993011236191, 0.548797011375427],\n [0.266469985246658, 0.376977026462555],\n [0.439121007919312, 0.51895797252655],\n [0.032313998788595, 0.644356966018677],\n [0.419054001569748, 0.387154996395111],\n [0.462783008813858, 0.505746960639954],\n [0.238978996872902, 0.779744982719421],\n [0.198220998048782, 0.831938028335571],\n [0.107550002634525, 0.540755033493042],\n [0.183610007166862, 0.740257024765015],\n [0.134409993886948, 0.333683013916016],\n [0.385764002799988, 0.883153975009918],\n [0.490967005491257, 0.579378008842468],\n [0.382384985685349, 0.508572995662689],\n [0.174399003386497, 0.397670984268188],\n [0.318785011768341, 0.39623498916626],\n [0.343364000320435, 0.400596976280212],\n [0.396100014448166, 0.710216999053955],\n [0.187885001301765, 0.588537991046906],\n [0.430987000465393, 0.944064974784851],\n [0.318993002176285, 0.898285031318665],\n [0.266247987747192, 0.869701027870178],\n [0.500023007392883, 0.190576016902924],\n [0.499976992607117, 0.954452991485596],\n [0.366169989109039, 0.398822009563446],\n [0.393207013607025, 0.39553701877594],\n [0.410373002290726, 0.391080021858215],\n [0.194993004202843, 0.342101991176605],\n [0.388664990663528, 0.362284004688263],\n [0.365961998701096, 0.355970978736877],\n [0.343364000320435, 0.355356991291046],\n [0.318785011768341, 0.35834002494812],\n [0.301414996385574, 0.363156020641327],\n [0.058132998645306, 0.319076001644135],\n [0.301414996385574, 0.387449026107788],\n [0.499987989664078, 0.618434011936188],\n [0.415838003158569, 0.624195992946625],\n [0.445681989192963, 0.566076993942261],\n [0.465844005346298, 0.620640993118286],\n [0.49992299079895, 0.351523995399475],\n [0.288718998432159, 0.819945991039276],\n [0.335278987884521, 0.852819979190826],\n [0.440512001514435, 0.902418971061707],\n [0.128294005990028, 0.791940987110138],\n [0.408771991729736, 0.373893976211548],\n [0.455606997013092, 0.451801002025604],\n [0.499877005815506, 0.908990025520325],\n [0.375436991453171, 0.924192011356354],\n [0.11421000212431, 0.615022003650665],\n [0.448662012815475, 0.695277988910675],\n [0.4480200111866, 0.704632043838501],\n [0.447111994028091, 0.715808033943176],\n [0.444831997156143, 0.730794012546539],\n [0.430011987686157, 0.766808986663818],\n [0.406787008047104, 0.685672998428345],\n [0.400738000869751, 0.681069016456604],\n [0.392399996519089, 0.677703022956848],\n [0.367855995893478, 0.663918972015381],\n [0.247923001646996, 0.601333022117615],\n [0.452769994735718, 0.420849978923798],\n [0.43639200925827, 0.359887003898621],\n [0.416164010763168, 0.368713974952698],\n [0.413385987281799, 0.692366003990173],\n [0.228018000721931, 0.683571994304657],\n [0.468268007040024, 0.352671027183533],\n [0.411361992359161, 0.804327011108398],\n [0.499989002943039, 0.469825029373169],\n [0.479153990745544, 0.442654013633728],\n [0.499974012374878, 0.439637005329132],\n [0.432112008333206, 0.493588984012604],\n [0.499886006116867, 0.866917014122009],\n [0.49991300702095, 0.821729004383087],\n [0.456548988819122, 0.819200992584229],\n [0.344549000263214, 0.745438992977142],\n [0.37890899181366, 0.574010014533997],\n [0.374292999505997, 0.780184984207153],\n [0.319687992334366, 0.570737957954407],\n [0.357154995203018, 0.604269981384277],\n [0.295284003019333, 0.621580958366394],\n [0.447750002145767, 0.862477004528046],\n [0.410986006259918, 0.508723020553589],\n [0.31395098567009, 0.775308012962341],\n [0.354128003120422, 0.812552988529205],\n [0.324548006057739, 0.703992962837219],\n [0.189096003770828, 0.646299958229065],\n [0.279776990413666, 0.71465802192688],\n [0.1338230073452, 0.682700991630554],\n [0.336768001317978, 0.644733011722565],\n [0.429883986711502, 0.466521978378296],\n [0.455527991056442, 0.548622965812683],\n [0.437114000320435, 0.558896005153656],\n [0.467287987470627, 0.529924988746643],\n [0.414712011814117, 0.335219979286194],\n [0.37704598903656, 0.322777986526489],\n [0.344107985496521, 0.320150971412659],\n [0.312875986099243, 0.32233202457428],\n [0.283526003360748, 0.333190023899078],\n [0.241245999932289, 0.382785975933075],\n [0.102986000478268, 0.468762993812561],\n [0.267612010240555, 0.424560010433197],\n [0.297879010438919, 0.433175981044769],\n [0.333433985710144, 0.433878004550934],\n [0.366427004337311, 0.426115989685059],\n [0.396012008190155, 0.416696012020111],\n [0.420121014118195, 0.41022801399231],\n [0.007561000064015, 0.480777025222778],\n [0.432949006557465, 0.569517970085144],\n [0.458638995885849, 0.479089021682739],\n [0.473466008901596, 0.545744001865387],\n [0.476087987422943, 0.563830018043518],\n [0.468472003936768, 0.555056989192963],\n [0.433990985155106, 0.582361996173859],\n [0.483518004417419, 0.562983989715576],\n [0.482482999563217, 0.57784903049469],\n [0.42645001411438, 0.389798998832703],\n [0.438998997211456, 0.39649498462677],\n [0.450067013502121, 0.400434017181396],\n [0.289712011814117, 0.368252992630005],\n [0.276670008897781, 0.363372981548309],\n [0.517862021923065, 0.471948027610779],\n [0.710287988185883, 0.380764007568359],\n [0.526226997375488, 0.573909997940063],\n [0.895093023777008, 0.254140973091125],\n [0.634069979190826, 0.409575998783112],\n [0.661242008209229, 0.41302502155304],\n [0.688880026340485, 0.409460008144379],\n [0.725341975688934, 0.389131009578705],\n [0.606630027294159, 0.40370500087738],\n [0.654766023159027, 0.344011008739471],\n [0.629905998706818, 0.346076011657715],\n [0.680678009986877, 0.347265005111694],\n [0.702096998691559, 0.353591024875641],\n [0.75221198797226, 0.410804986953735],\n [0.602918028831482, 0.842862963676453],\n [0.719901978969574, 0.375599980354309],\n [0.893692970275879, 0.399959981441498],\n [0.790081977844238, 0.391354024410248],\n [0.643998026847839, 0.534487962722778],\n [0.528249025344849, 0.65040397644043],\n [0.525849997997284, 0.680191040039062],\n [0.560214996337891, 0.657229006290436],\n [0.585384011268616, 0.66654098033905],\n [0.549625992774963, 0.680860996246338],\n [0.57122802734375, 0.682691991329193],\n [0.624852001667023, 0.72809898853302],\n [0.513050019741058, 0.547281980514526],\n [0.51509702205658, 0.527251958847046],\n [0.742246985435486, 0.314507007598877],\n [0.598631024360657, 0.454979002475739],\n [0.570338010787964, 0.548575043678284],\n [0.578631997108459, 0.533622980117798],\n [0.723087012767792, 0.532054007053375],\n [0.516445994377136, 0.499638974666595],\n [0.662801027297974, 0.282917976379395],\n [0.70362401008606, 0.293271005153656],\n [0.830704987049103, 0.193813979625702],\n [0.552385985851288, 0.302568018436432],\n [0.607609987258911, 0.353887975215912],\n [0.645429015159607, 0.696707010269165],\n [0.932694971561432, 0.730105042457581],\n [0.557260990142822, 0.572826027870178],\n [0.542901992797852, 0.584792017936707],\n [0.6180260181427, 0.694710969924927],\n [0.607590973377228, 0.694203019142151],\n [0.722943007946014, 0.271963000297546],\n [0.577413976192474, 0.563166975975037],\n [0.614082992076874, 0.281386971473694],\n [0.616907000541687, 0.255886018276215],\n [0.668509006500244, 0.119913995265961],\n [0.770092010498047, 0.232020974159241],\n [0.635536015033722, 0.189248979091644],\n [0.77039098739624, 0.299556016921997],\n [0.826722025871277, 0.278755009174347],\n [0.527121007442474, 0.666198015213013],\n [0.553171992301941, 0.668527007102966],\n [0.577238023281097, 0.673889994621277],\n [0.554691970348358, 0.580065965652466],\n [0.611896991729736, 0.693961024284363],\n [0.59696102142334, 0.706539988517761],\n [0.596370995044708, 0.693953037261963],\n [0.539958000183105, 0.557139039039612],\n [0.568841993808746, 0.692366003990173],\n [0.547818005084991, 0.692366003990173],\n [0.52461302280426, 0.692366003990173],\n [0.534089982509613, 0.779141008853912],\n [0.527670979499817, 0.736225962638855],\n [0.526912987232208, 0.717857003211975],\n [0.526877999305725, 0.704625964164734],\n [0.526966989040375, 0.695277988910675],\n [0.572058022022247, 0.695277988910675],\n [0.573521018028259, 0.703539967536926],\n [0.57683801651001, 0.711845993995667],\n [0.581691026687622, 0.720062971115112],\n [0.609944999217987, 0.639909982681274],\n [0.986046016216278, 0.560034036636353],\n [0.5867999792099, 0.69539999961853],\n [0.590372025966644, 0.701822996139526],\n [0.531915009021759, 0.601536989212036],\n [0.577268004417419, 0.585934996604919],\n [0.536915004253387, 0.593786001205444],\n [0.627542972564697, 0.473352015018463],\n [0.665585994720459, 0.495950996875763],\n [0.588353991508484, 0.546862006187439],\n [0.757824003696442, 0.14767599105835],\n [0.709249973297119, 0.201507985591888],\n [0.672684013843536, 0.256581008434296],\n [0.600408971309662, 0.74900496006012],\n [0.55826598405838, 0.261672019958496],\n [0.570303976535797, 0.187870979309082],\n [0.588165998458862, 0.109044015407562],\n [0.711045026779175, 0.398952007293701],\n [0.781069993972778, 0.435405015945435],\n [0.587247014045715, 0.398931980133057],\n [0.742869973182678, 0.355445981025696],\n [0.572156012058258, 0.437651991844177],\n [0.55186802148819, 0.536570012569427],\n [0.821442008018494, 0.457556009292603],\n [0.752701997756958, 0.457181990146637],\n [0.71375697851181, 0.467626988887787],\n [0.66711300611496, 0.460672974586487],\n [0.631101012229919, 0.447153985500336],\n [0.6008620262146, 0.432473003864288],\n [0.523481011390686, 0.405627012252808],\n [0.810747981071472, 0.523926019668579],\n [0.771045982837677, 0.348959028720856],\n [0.509127020835876, 0.562718033790588],\n [0.595292985439301, 0.485023975372314],\n [0.980530977249146, 0.401564002037048],\n [0.573499977588654, 0.420000016689301],\n [0.602994978427887, 0.548687994480133],\n [0.733529984951019, 0.376977026462555],\n [0.560611009597778, 0.519016981124878],\n [0.967685997486115, 0.644356966018677],\n [0.580985009670258, 0.387160003185272],\n [0.537728011608124, 0.505385041236877],\n [0.760966002941132, 0.779752969741821],\n [0.801778972148895, 0.831938028335571],\n [0.892440974712372, 0.54076099395752],\n [0.816350996494293, 0.740260004997253],\n [0.865594983100891, 0.333687007427216],\n [0.614073991775513, 0.883246004581451],\n [0.508952975273132, 0.579437971115112],\n [0.617941975593567, 0.508316040039062],\n [0.825608015060425, 0.397674977779388],\n [0.681214988231659, 0.39623498916626],\n [0.656635999679565, 0.400596976280212],\n [0.603900015354156, 0.710216999053955],\n [0.81208598613739, 0.588539004325867],\n [0.56801301240921, 0.944564998149872],\n [0.681007981300354, 0.898285031318665],\n [0.733752012252808, 0.869701027870178],\n [0.633830010890961, 0.398822009563446],\n [0.606792986392975, 0.39553701877594],\n [0.589659988880157, 0.391062021255493],\n [0.805015981197357, 0.342108011245728],\n [0.611334979534149, 0.362284004688263],\n [0.634037971496582, 0.355970978736877],\n [0.656635999679565, 0.355356991291046],\n [0.681214988231659, 0.35834002494812],\n [0.698584973812103, 0.363156020641327],\n [0.941866993904114, 0.319076001644135],\n [0.698584973812103, 0.387449026107788],\n [0.584177017211914, 0.624107003211975],\n [0.554318010807037, 0.566076993942261],\n [0.534153997898102, 0.62064003944397],\n [0.711217999458313, 0.819975018501282],\n [0.664629995822906, 0.852871000766754],\n [0.559099972248077, 0.902631998062134],\n [0.871706008911133, 0.791940987110138],\n [0.591234028339386, 0.373893976211548],\n [0.544341027736664, 0.451583981513977],\n [0.624562978744507, 0.924192011356354],\n [0.88577002286911, 0.615028977394104],\n [0.551338016986847, 0.695277988910675],\n [0.551980018615723, 0.704632043838501],\n [0.552887976169586, 0.715808033943176],\n [0.555167973041534, 0.730794012546539],\n [0.569944024085999, 0.767035007476807],\n [0.593203008174896, 0.685675978660583],\n [0.599261999130249, 0.681069016456604],\n [0.607599973678589, 0.677703022956848],\n [0.631937980651855, 0.663500010967255],\n [0.752032995223999, 0.601315021514893],\n [0.547226011753082, 0.420395016670227],\n [0.563543975353241, 0.359827995300293],\n [0.583841025829315, 0.368713974952698],\n [0.586614012718201, 0.692366003990173],\n [0.771915018558502, 0.683578014373779],\n [0.531597018241882, 0.352482974529266],\n [0.588370978832245, 0.804440975189209],\n [0.52079701423645, 0.442565023899078],\n [0.567984998226166, 0.493479013442993],\n [0.543282985687256, 0.819254994392395],\n [0.655317008495331, 0.745514988899231],\n [0.621008992195129, 0.574018001556396],\n [0.625559985637665, 0.78031200170517],\n [0.680198013782501, 0.570719003677368],\n [0.64276397228241, 0.604337990283966],\n [0.704662978649139, 0.621529996395111],\n [0.552012026309967, 0.862591981887817],\n [0.589071989059448, 0.508637011051178],\n [0.685944974422455, 0.775357007980347],\n [0.645735025405884, 0.812640011310577],\n [0.675342977046967, 0.703978002071381],\n [0.810858011245728, 0.646304965019226],\n [0.72012197971344, 0.714666962623596],\n [0.866151988506317, 0.682704985141754],\n [0.663187026977539, 0.644596993923187],\n [0.570082008838654, 0.466325998306274],\n [0.544561982154846, 0.548375964164734],\n [0.562758982181549, 0.558784961700439],\n [0.531987011432648, 0.530140042304993],\n [0.585271000862122, 0.335177004337311],\n [0.622952997684479, 0.32277899980545],\n [0.655896008014679, 0.320163011550903],\n [0.687132000923157, 0.322345972061157],\n [0.716481983661652, 0.333200991153717],\n [0.758756995201111, 0.382786989212036],\n [0.897013008594513, 0.468769013881683],\n [0.732392013072968, 0.424547016620636],\n [0.70211398601532, 0.433162987232208],\n [0.66652500629425, 0.433866024017334],\n [0.633504986763, 0.426087975502014],\n [0.603875994682312, 0.416586995124817],\n [0.579657971858978, 0.409945011138916],\n [0.992439985275269, 0.480777025222778],\n [0.567192018032074, 0.569419980049133],\n [0.54136598110199, 0.478899002075195],\n [0.526564002037048, 0.546118021011353],\n [0.523913025856018, 0.563830018043518],\n [0.531529009342194, 0.555056989192963],\n [0.566035985946655, 0.582329034805298],\n [0.51631098985672, 0.563053965568542],\n [0.5174720287323, 0.577877044677734],\n [0.573594987392426, 0.389806985855103],\n [0.560697972774506, 0.395331978797913],\n [0.549755990505219, 0.399751007556915],\n [0.710287988185883, 0.368252992630005],\n [0.723330020904541, 0.363372981548309],\n];\n\nexport const TRI468: number[] = [\n 127, 34, 139, 11, 0, 37, 232, 231, 120, 72, 37, 39, 128, 121, 47, 232, 121, 128, 104, 69, 67, 175, 171, 148, 157, 154, 155, 118, 50, 101, 73, 39, 40, 9,\n 151, 108, 48, 115, 131, 194, 204, 211, 74, 40, 185, 80, 42, 183, 40, 92, 186, 230, 229, 118, 202, 212, 214, 83, 18, 17, 76, 61, 146, 160, 29, 30, 56,\n 157, 173, 106, 204, 194, 135, 214, 192, 203, 165, 98, 21, 71, 68, 51, 45, 4, 144, 24, 23, 77, 146, 91, 205, 50, 187, 201, 200, 18, 91, 106, 182, 90, 91,\n 181, 85, 84, 17, 206, 203, 36, 148, 171, 140, 92, 40, 39, 193, 189, 244, 159, 158, 28, 247, 246, 161, 236, 3, 196, 54, 68, 104, 193, 168, 8, 117,\n 228, 31, 189, 193, 55, 98, 97, 99, 126, 47, 100, 166, 79, 218, 155, 154, 26, 209, 49, 131, 135, 136, 150, 47, 126, 217, 223, 52, 53, 45, 51, 134, 211,\n 170, 140, 67, 69, 108, 43, 106, 91, 230, 119, 120, 226, 130, 247, 63, 53, 52, 238, 20, 242, 46, 70, 156, 78, 62, 96, 46, 53, 63, 143, 34, 227, 173,\n 155, 133, 123, 117, 111, 44, 125, 19, 236, 134, 51, 216, 206, 205, 154, 153, 22, 39, 37, 167, 200, 201, 208, 36, 142, 100, 57, 212, 202, 20, 60, 99, 28,\n 158, 157, 35, 226, 113, 160, 159, 27, 204, 202, 210, 113, 225, 46, 43, 202, 204, 62, 76, 77, 137, 123, 116, 41, 38, 72, 203, 129, 142, 64, 98, 240, 49,\n 102, 64, 41, 73, 74, 212, 216, 207, 42, 74, 184, 169, 170, 211, 170, 149, 176, 105, 66, 69, 122, 6, 168, 123, 147, 187, 96, 77, 90, 65, 55, 107, 89,\n 90, 180, 101, 100, 120, 63, 105, 104, 93, 137, 227, 15, 86, 85, 129, 102, 49, 14, 87, 86, 55, 8, 9, 100, 47, 121, 145, 23, 22, 88, 89, 179, 6, 122,\n 196, 88, 95, 96, 138, 172, 136, 215, 58, 172, 115, 48, 219, 42, 80, 81, 195, 3, 51, 43, 146, 61, 171, 175, 199, 81, 82, 38, 53, 46, 225, 144, 163, 110,\n 246, 33, 7, 52, 65, 66, 229, 228, 117, 34, 127, 234, 107, 108, 69, 109, 108, 151, 48, 64, 235, 62, 78, 191, 129, 209, 126, 111, 35, 143, 163, 161, 246,\n 117, 123, 50, 222, 65, 52, 19, 125, 141, 221, 55, 65, 3, 195, 197, 25, 7, 33, 220, 237, 44, 70, 71, 139, 122, 193, 245, 247, 130, 33, 71, 21, 162,\n 153, 158, 159, 170, 169, 150, 188, 174, 196, 216, 186, 92, 144, 160, 161, 2, 97, 167, 141, 125, 241, 164, 167, 37, 72, 38, 12, 145, 159, 160, 38, 82, 13,\n 63, 68, 71, 226, 35, 111, 158, 153, 154, 101, 50, 205, 206, 92, 165, 209, 198, 217, 165, 167, 97, 220, 115, 218, 133, 112, 243, 239, 238, 241, 214,\n 135, 169, 190, 173, 133, 171, 208, 32, 125, 44, 237, 86, 87, 178, 85, 86, 179, 84, 85, 180, 83, 84, 181, 201, 83, 182, 137, 93, 132, 76, 62, 183, 61,\n 76, 184, 57, 61, 185, 212, 57, 186, 214, 207, 187, 34, 143, 156, 79, 239, 237, 123, 137, 177, 44, 1, 4, 201, 194, 32, 64, 102, 129, 213, 215, 138, 59,\n 166, 219, 242, 99, 97, 2, 94, 141, 75, 59, 235, 24, 110, 228, 25, 130, 226, 23, 24, 229, 22, 23, 230, 26, 22, 231, 112, 26, 232, 189, 190, 243, 221, 56,\n 190, 28, 56, 221, 27, 28, 222, 29, 27, 223, 30, 29, 224, 247, 30, 225, 238, 79, 20, 166, 59, 75, 60, 75, 240, 147, 177, 215, 20, 79, 166, 187, 147, 213,\n 112, 233, 244, 233, 128, 245, 128, 114, 188, 114, 217, 174, 131, 115, 220, 217, 198, 236, 198, 131, 134, 177, 132, 58, 143, 35, 124, 110, 163, 7, 228,\n 110, 25, 356, 389, 368, 11, 302, 267, 452, 350, 349, 302, 303, 269, 357, 343, 277, 452, 453, 357, 333, 332, 297, 175, 152, 377, 384, 398, 382, 347,\n 348, 330, 303, 304, 270, 9, 336, 337, 278, 279, 360, 418, 262, 431, 304, 408, 409, 310, 415, 407, 270, 409, 410, 450, 348, 347, 422, 430, 434, 313,\n 314, 17, 306, 307, 375, 387, 388, 260, 286, 414, 398, 335, 406, 418, 364, 367, 416, 423, 358, 327, 251, 284, 298, 281, 5, 4, 373, 374, 253, 307, 320,\n 321, 425, 427, 411, 421, 313, 18, 321, 405, 406, 320, 404, 405, 315, 16, 17, 426, 425, 266, 377, 400, 369, 322, 391, 269, 417, 465, 464, 386, 257, 258,\n 466, 260, 388, 456, 399, 419, 284, 332, 333, 417, 285, 8, 346, 340, 261, 413, 441, 285, 327, 460, 328, 355, 371, 329, 392, 439, 438, 382, 341, 256,\n 429, 420, 360, 364, 394, 379, 277, 343, 437, 443, 444, 283, 275, 440, 363, 431, 262, 369, 297, 338, 337, 273, 375, 321, 450, 451, 349, 446, 342, 467,\n 293, 334, 282, 458, 461, 462, 276, 353, 383, 308, 324, 325, 276, 300, 293, 372, 345, 447, 382, 398, 362, 352, 345, 340, 274, 1, 19, 456, 248, 281, 436,\n 427, 425, 381, 256, 252, 269, 391, 393, 200, 199, 428, 266, 330, 329, 287, 273, 422, 250, 462, 328, 258, 286, 384, 265, 353, 342, 387, 259, 257, 424,\n 431, 430, 342, 353, 276, 273, 335, 424, 292, 325, 307, 366, 447, 345, 271, 303, 302, 423, 266, 371, 294, 455, 460, 279, 278, 294, 271, 272, 304, 432,\n 434, 427, 272, 407, 408, 394, 430, 431, 395, 369, 400, 334, 333, 299, 351, 417, 168, 352, 280, 411, 325, 319, 320, 295, 296, 336, 319, 403, 404, 330,\n 348, 349, 293, 298, 333, 323, 454, 447, 15, 16, 315, 358, 429, 279, 14, 15, 316, 285, 336, 9, 329, 349, 350, 374, 380, 252, 318, 402, 403, 6, 197, 419,\n 318, 319, 325, 367, 364, 365, 435, 367, 397, 344, 438, 439, 272, 271, 311, 195, 5, 281, 273, 287, 291, 396, 428, 199, 311, 271, 268, 283, 444, 445,\n 373, 254, 339, 263, 466, 249, 282, 334, 296, 449, 347, 346, 264, 447, 454, 336, 296, 299, 338, 10, 151, 278, 439, 455, 292, 407, 415, 358, 371, 355,\n 340, 345, 372, 390, 249, 466, 346, 347, 280, 442, 443, 282, 19, 94, 370, 441, 442, 295, 248, 419, 197, 263, 255, 359, 440, 275, 274, 300, 383, 368,\n 351, 412, 465, 263, 467, 466, 301, 368, 389, 380, 374, 386, 395, 378, 379, 412, 351, 419, 436, 426, 322, 373, 390, 388, 2, 164, 393, 370, 462, 461,\n 164, 0, 267, 302, 11, 12, 374, 373, 387, 268, 12, 13, 293, 300, 301, 446, 261, 340, 385, 384, 381, 330, 266, 425, 426, 423, 391, 429, 355, 437, 391,\n 327, 326, 440, 457, 438, 341, 382, 362, 459, 457, 461, 434, 430, 394, 414, 463, 362, 396, 369, 262, 354, 461, 457, 316, 403, 402, 315, 404, 403, 314,\n 405, 404, 313, 406, 405, 421, 418, 406, 366, 401, 361, 306, 408, 407, 291, 409, 408, 287, 410, 409, 432, 436, 410, 434, 416, 411, 264, 368, 383, 309,\n 438, 457, 352, 376, 401, 274, 275, 4, 421, 428, 262, 294, 327, 358, 433, 416, 367, 289, 455, 439, 462, 370, 326, 2, 326, 370, 305, 460, 455, 254,\n 449, 448, 255, 261, 446, 253, 450, 449, 252, 451, 450, 256, 452, 451, 341, 453, 452, 413, 464, 463, 441, 413, 414, 258, 442, 441, 257, 443, 442, 259,\n 444, 443, 260, 445, 444, 467, 342, 445, 459, 458, 250, 289, 392, 290, 290, 328, 460, 376, 433, 435, 250, 290, 392, 411, 416, 433, 341, 463, 464, 453,\n 464, 465, 357, 465, 412, 343, 412, 399, 360, 363, 440, 437, 399, 456, 420, 456, 363, 401, 435, 288, 372, 383, 353, 339, 255, 249, 448, 261, 255, 133,\n 243, 190, 133, 155, 112, 33, 246, 247, 33, 130, 25, 398, 384, 286, 362, 398, 414, 362, 463, 341, 263, 359, 467, 263, 249, 255, 466, 467, 260, 75, 60,\n 166, 238, 239, 79, 162, 127, 139, 72, 11, 37, 121, 232, 120, 73, 72, 39, 114, 128, 47, 233, 232, 128, 103, 104, 67, 152, 175, 148, 173, 157, 155,\n 119, 118, 101, 74, 73, 40, 107, 9, 108, 49, 48, 131, 32, 194, 211, 184, 74, 185, 191, 80, 183, 185, 40, 186, 119, 230, 118, 210, 202, 214, 84, 83, 17,\n 77, 76, 146, 161, 160, 30, 190, 56, 173, 182, 106, 194, 138, 135, 192, 129, 203, 98, 54, 21, 68, 5, 51, 4, 145, 144, 23, 90, 77, 91, 207, 205, 187, 83,\n 201, 18, 181, 91, 182, 180, 90, 181, 16, 85, 17, 205, 206, 36, 176, 148, 140, 165, 92, 39, 245, 193, 244, 27, 159, 28, 30, 247, 161, 174, 236, 196,\n 103, 54, 104, 55, 193, 8, 111, 117, 31, 221, 189, 55, 240, 98, 99, 142, 126, 100, 219, 166, 218, 112, 155, 26, 198, 209, 131, 169, 135, 150, 114, 47,\n 217, 224, 223, 53, 220, 45, 134, 32, 211, 140, 109, 67, 108, 146, 43, 91, 231, 230, 120, 113, 226, 247, 105, 63, 52, 241, 238, 242, 124, 46, 156, 95,\n 78, 96, 70, 46, 63, 116, 143, 227, 116, 123, 111, 1, 44, 19, 3, 236, 51, 207, 216, 205, 26, 154, 22, 165, 39, 167, 199, 200, 208, 101, 36, 100, 43,\n 57, 202, 242, 20, 99, 56, 28, 157, 124, 35, 113, 29, 160, 27, 211, 204, 210, 124, 113, 46, 106, 43, 204, 96, 62, 77, 227, 137, 116, 73, 41, 72, 36, 203,\n 142, 235, 64, 240, 48, 49, 64, 42, 41, 74, 214, 212, 207, 183, 42, 184, 210, 169, 211, 140, 170, 176, 104, 105, 69, 193, 122, 168, 50, 123, 187, 89, 96,\n 90, 66, 65, 107, 179, 89, 180, 119, 101, 120, 68, 63, 104, 234, 93, 227, 16, 15, 85, 209, 129, 49, 15, 14, 86, 107, 55, 9, 120, 100, 121, 153, 145, 22,\n 178, 88, 179, 197, 6, 196, 89, 88, 96, 135, 138, 136, 138, 215, 172, 218, 115, 219, 41, 42, 81, 5, 195, 51, 57, 43, 61, 208, 171, 199, 41, 81, 38,\n 224, 53, 225, 24, 144, 110, 105, 52, 66, 118, 229, 117, 227, 34, 234, 66, 107, 69, 10, 109, 151, 219, 48, 235, 183, 62, 191, 142, 129, 126, 116, 111,\n 143, 7, 163, 246, 118, 117, 50, 223, 222, 52, 94, 19, 141, 222, 221, 65, 196, 3, 197, 45, 220, 44, 156, 70, 139, 188, 122, 245, 139, 71, 162, 145,\n 153, 159, 149, 170, 150, 122, 188, 196, 206, 216, 92, 163, 144, 161, 164, 2, 167, 242, 141, 241, 0, 164, 37, 11, 72, 12, 144, 145, 160, 12, 38, 13, 70,\n 63, 71, 31, 226, 111, 157, 158, 154, 36, 101, 205, 203, 206, 165, 126, 209, 217, 98, 165, 97, 237, 220, 218, 237, 239, 241, 210, 214, 169, 140, 171, 32,\n 241, 125, 237, 179, 86, 178, 180, 85, 179, 181, 84, 180, 182, 83, 181, 194, 201, 182, 177, 137, 132, 184, 76, 183, 185, 61, 184, 186, 57, 185, 216, 212,\n 186, 192, 214, 187, 139, 34, 156, 218, 79, 237, 147, 123, 177, 45, 44, 4, 208, 201, 32, 98, 64, 129, 192, 213, 138, 235, 59, 219, 141, 242, 97, 97, 2,\n 141, 240, 75, 235, 229, 24, 228, 31, 25, 226, 230, 23, 229, 231, 22, 230, 232, 26, 231, 233, 112, 232, 244, 189, 243, 189, 221, 190, 222, 28, 221,\n 223, 27, 222, 224, 29, 223, 225, 30, 224, 113, 247, 225, 99, 60, 240, 213, 147, 215, 60, 20, 166, 192, 187, 213, 243, 112, 244, 244, 233, 245, 245,\n 128, 188, 188, 114, 174, 134, 131, 220, 174, 217, 236, 236, 198, 134, 215, 177, 58, 156, 143, 124, 25, 110, 7, 31, 228, 25, 264, 356, 368, 0, 11, 267,\n 451, 452, 349, 267, 302, 269, 350, 357, 277, 350, 452, 357, 299, 333, 297, 396, 175, 377, 381, 384, 382, 280, 347, 330, 269, 303, 270, 151, 9, 337,\n 344, 278, 360, 424, 418, 431, 270, 304, 409, 272, 310, 407, 322, 270, 410, 449, 450, 347, 432, 422, 434, 18, 313, 17, 291, 306, 375, 259, 387, 260,\n 424, 335, 418, 434, 364, 416, 391, 423, 327, 301, 251, 298, 275, 281, 4, 254, 373, 253, 375, 307, 321, 280, 425, 411, 200, 421, 18, 335, 321, 406,\n 321, 320, 405, 314, 315, 17, 423, 426, 266, 396, 377, 369, 270, 322, 269, 413, 417, 464, 385, 386, 258, 248, 456, 419, 298, 284, 333, 168, 417, 8,\n 448, 346, 261, 417, 413, 285, 326, 327, 328, 277, 355, 329, 309, 392, 438, 381, 382, 256, 279, 429, 360, 365, 364, 379, 355, 277, 437, 282, 443, 283,\n 281, 275, 363, 395, 431, 369, 299, 297, 337, 335, 273, 321, 348, 450, 349, 359, 446, 467, 283, 293, 282, 250, 458, 462, 300, 276, 383, 292, 308, 325,\n 283, 276, 293, 264, 372, 447, 346, 352, 340, 354, 274, 19, 363, 456, 281, 426, 436, 425, 380, 381, 252, 267, 269, 393, 421, 200, 428, 371, 266, 329,\n 432, 287, 422, 290, 250, 328, 385, 258, 384, 446, 265, 342, 386, 387, 257, 422, 424, 430, 445, 342, 276, 422, 273, 424, 306, 292, 307, 352, 366, 345,\n 268, 271, 302, 358, 423, 371, 327, 294, 460, 331, 279, 294, 303, 271, 304, 436, 432, 427, 304, 272, 408, 395, 394, 431, 378, 395, 400, 296, 334, 299,\n 6, 351, 168, 376, 352, 411, 307, 325, 320, 285, 295, 336, 320, 319, 404, 329, 330, 349, 334, 293, 333, 366, 323, 447, 316, 15, 315, 331, 358, 279,\n 317, 14, 316, 8, 285, 9, 277, 329, 350, 253, 374, 252, 319, 318, 403, 351, 6, 419, 324, 318, 325, 397, 367, 365, 288, 435, 397, 278, 344, 439, 310,\n 272, 311, 248, 195, 281, 375, 273, 291, 175, 396, 199, 312, 311, 268, 276, 283, 445, 390, 373, 339, 295, 282, 296, 448, 449, 346, 356, 264, 454, 337,\n 336, 299, 337, 338, 151, 294, 278, 455, 308, 292, 415, 429, 358, 355, 265, 340, 372, 388, 390, 466, 352, 346, 280, 295, 442, 282, 354, 19, 370, 285,\n 441, 295, 195, 248, 197, 457, 440, 274, 301, 300, 368, 417, 351, 465, 251, 301, 389, 385, 380, 386, 394, 395, 379, 399, 412, 419, 410, 436, 322, 387,\n 373, 388, 326, 2, 393, 354, 370, 461, 393, 164, 267, 268, 302, 12, 386, 374, 387, 312, 268, 13, 298, 293, 301, 265, 446, 340, 380, 385, 381, 280, 330,\n 425, 322, 426, 391, 420, 429, 437, 393, 391, 326, 344, 440, 438, 458, 459, 461, 364, 434, 394, 428, 396, 262, 274, 354, 457, 317, 316, 402, 316, 315,\n 403, 315, 314, 404, 314, 313, 405, 313, 421, 406, 323, 366, 361, 292, 306, 407, 306, 291, 408, 291, 287, 409, 287, 432, 410, 427, 434, 411, 372, 264,\n 383, 459, 309, 457, 366, 352, 401, 1, 274, 4, 418, 421, 262, 331, 294, 358, 435, 433, 367, 392, 289, 439, 328, 462, 326, 94, 2, 370, 289, 305, 455, 339,\n 254, 448, 359, 255, 446, 254, 253, 449, 253, 252, 450, 252, 256, 451, 256, 341, 452, 414, 413, 463, 286, 441, 414, 286, 258, 441, 258, 257, 442, 257,\n 259, 443, 259, 260, 444, 260, 467, 445, 309, 459, 250, 305, 289, 290, 305, 290, 460, 401, 376, 435, 309, 250, 392, 376, 411, 433, 453, 341, 464, 357,\n 453, 465, 343, 357, 412, 437, 343, 399, 344, 360, 440, 420, 437, 456, 360, 420, 363, 361, 401, 288, 265, 372, 353, 390, 339, 249, 339, 448, 255];\n\nexport const TRI68: number[] = [0, 1, 36, 0, 36, 17, 1, 2, 41, 1, 41, 36, 2, 3, 31, 2, 31, 41, 3, 4, 48, 3, 48, 31, 4, 5, 48, 5, 6, 48, 6, 7, 59, 6, 59, 48, 7, 8, 58, 7, 58, 59,\n 8, 9, 56, 8, 56, 57, 8, 57, 58, 9, 10, 55, 9, 55, 56, 10, 11, 54, 10, 54, 55, 11, 12, 54, 12, 13, 54, 13, 14, 35, 13, 35, 54, 14, 15, 46, 14, 46, 35, 15, 16,\n 45, 15, 45, 46, 16, 26, 45, 17, 36, 18, 18, 37, 19, 18, 36, 37, 19, 38, 20, 19, 37, 38, 20, 39, 21, 20, 38, 39, 21, 39, 27, 22, 42, 23, 22, 27, 42, 23, 43, 24,\n 23, 42, 43, 24, 44, 25, 24, 43, 44, 25, 45, 26, 25, 44, 45, 27, 39, 28, 27, 28, 42, 28, 39, 29, 28, 29, 42, 29, 31, 30, 29, 30, 35, 29, 40, 31, 29, 35, 47, 29,\n 39, 40, 29, 47, 42, 30, 31, 32, 30, 32, 33, 30, 33, 34, 30, 34, 35, 31, 50, 32, 31, 40, 41, 31, 48, 49, 31, 49, 50, 32, 51, 33, 32, 50, 51, 33, 51, 34, 34, 52,\n 35, 34, 51, 52, 35, 46, 47, 35, 52, 53, 35, 53, 54, 36, 41, 37, 37, 40, 38, 37, 41, 40, 38, 40, 39, 42, 47, 43, 43, 47, 44, 44, 46, 45, 44, 47, 46, 48, 60, 49,\n 48, 59, 60, 49, 61, 50, 49, 60, 61, 50, 62, 51, 50, 61, 62, 51, 62, 52, 52, 63, 53, 52, 62, 63, 53, 64, 54, 53, 63, 64, 54, 64, 55, 55, 65, 56, 55, 64, 65, 56,\n 66, 57, 56, 65, 66, 57, 66, 58, 58, 67, 59, 58, 66, 67, 59, 67, 60, 60, 67, 61, 61, 66, 62, 61, 67, 66, 62, 66, 63, 63, 65, 64, 63, 66, 65, 21, 27, 22];\n\nexport const TRI33: number[] = [\n /* eyes */ 0, 8, 7, 7, 8, 1, 2, 10, 9, 9, 10, 3,\n /* brows */ 17, 0, 18, 18, 0, 7, 18, 7, 19, 19, 7, 1, 19, 1, 11, 19, 11, 20, 21, 3, 22, 21, 9, 3, 20, 9, 21, 20, 2, 9, 20, 11, 2,\n /* 4head */ 23, 17, 18, 25, 21, 22, 24, 19, 20, 24, 18, 19, 24, 20, 21, 24, 23, 18, 24, 21, 25,\n /* nose */ 11, 12, 4, 11, 4, 13, 1, 12, 11, 11, 13, 2, 12, 14, 4, 4, 14, 13,\n /* up-lip */ 14, 5, 15, 14, 15, 6, 12, 5, 14, 14, 6, 13,\n /* cheeks */ 8, 12, 1, 2, 13, 10, 8, 26, 12, 10, 13, 27, 26, 5, 12, 13, 6, 27, 0, 26, 8, 10, 27, 3,\n /* chin */ 5, 32, 16, 16, 32, 6, 5, 30, 32, 6, 32, 31,\n /* cont */ 26, 30, 5, 27, 6, 31, 0, 28, 26, 3, 27, 29, 17, 28, 0, 3, 29, 22, 23, 28, 17, 22, 29, 25, 28, 30, 26, 27, 31, 29,\n];\n\nexport const TRI7: number[] = [0, 4, 1, 2, 4, 3, 4, 5, 6];\n\nexport const VTX68: number[] = [\n /* cont */ 127, 234, 132, 58, 172, 150, 149, 148, 152, 377, 378, 379, 397, 288, 361, 454, 356,\n /* brows */ 70, 63, 105, 66, 107, 336, 296, 334, 293, 300,\n /* nose */ 168, 6, 195, 4, 98, 97, 2, 326, 327,\n /* eyes */ 33, 160, 158, 133, 153, 144, 362, 385, 387, 263, 373, 380,\n /* lip */ 57, 40, 37, 0, 267, 270, 287, 321, 314, 17, 84, 91,\n /* mouth */ 78, 81, 13, 311, 308, 402, 14, 178,\n];\n\nexport const VTX33: number[] = [33, 133, 362, 263, 1, 62, 308, 159, 145, 386, 374, 6, 102, 331, 2, 13, 14, 70, 105, 107, 336, 334, 300, 54, 10, 284, 50, 280, 234, 454, 58, 288, 152];\n\nexport const VTX7: number[] = [33, 133, 362, 263, 1, 78, 308];\n\nexport const UV68 = VTX68.map((x) => UV468[x]);\n\nexport const UV33 = VTX33.map((x) => UV468[x]);\n\nexport const UV7 = VTX7.map((x) => UV468[x]);\n\n// https://github.com/tensorflow/tfjs-models/blob/master/face-landmarks-detection/src/constants.ts\n// https://github.com/google/mediapipe/mediapipe/python/solutions/face_mesh_connections.py\n\ntype PairArray = [number, number][];\n\nfunction connectionsToIndices(connections: PairArray) {\n const indices = connections.map((connection) => connection[0]);\n indices.push(connections[connections.length - 1][1]);\n return indices;\n}\n\nexport const pairsLips: PairArray = [\n [61, 146], [146, 91], [91, 181], [181, 84], [84, 17], [17, 314], [314, 405], [405, 321], [321, 375], [375, 291], [61, 185], [185, 40], [40, 39], [39, 37], [37, 0], [0, 267], [267, 269], [269, 270], [270, 409], [409, 291],\n [78, 95], [95, 88], [88, 178], [178, 87], [87, 14], [14, 317], [317, 402], [402, 318], [318, 324], [324, 308], [78, 191], [191, 80], [80, 81], [81, 82], [82, 13], [13, 312], [312, 311], [311, 310], [310, 415], [415, 308],\n];\n\nexport const pairsLeftEye: PairArray = [[263, 249], [249, 390], [390, 373], [373, 374], [374, 380], [380, 381], [381, 382], [382, 362], [263, 466], [466, 388], [388, 387], [387, 386], [386, 385], [385, 384], [384, 398], [398, 362]];\n\nexport const pairsLeftEyebrow: PairArray = [[276, 283], [283, 282], [282, 295], [295, 285], [300, 293], [293, 334], [334, 296], [296, 336]];\n\nexport const pairsLeftIris: PairArray = [[474, 475], [475, 476], [476, 477], [477, 474]];\n\nexport const pairsRightEye: PairArray = [[33, 7], [7, 163], [163, 144], [144, 145], [145, 153], [153, 154], [154, 155], [155, 133], [33, 246], [246, 161], [161, 160], [160, 159], [159, 158], [158, 157], [157, 173], [173, 133]];\n\nexport const pairsRightEyebrow: PairArray = [[46, 53], [53, 52], [52, 65], [65, 55], [70, 63], [63, 105], [105, 66], [66, 107]];\n\nexport const pairsRightIris: PairArray = [[469, 470], [470, 471], [471, 472], [472, 469]];\n\nexport const pairsFaceContour: PairArray = [\n [10, 338], [338, 297], [297, 332], [332, 284], [284, 251], [251, 389],\n [389, 356], [356, 454], [454, 323], [323, 361], [361, 288], [288, 397],\n [397, 365], [365, 379], [379, 378], [378, 400], [400, 377], [377, 152],\n [152, 148], [148, 176], [176, 149], [149, 150], [150, 136], [136, 172],\n [172, 58], [58, 132], [132, 93], [93, 234], [234, 127], [127, 162],\n [162, 21], [21, 54], [54, 103], [103, 67], [67, 109], [109, 10],\n];\n\nexport const contourKeypoints = {\n lips: connectionsToIndices(pairsLips),\n leftEye: connectionsToIndices(pairsLeftEye),\n leftEyebrow: connectionsToIndices(pairsLeftEyebrow),\n leftIris: connectionsToIndices(pairsLeftIris),\n rightEye: connectionsToIndices(pairsRightEye),\n rightEyebrow: connectionsToIndices(pairsRightEyebrow),\n rightIris: connectionsToIndices(pairsRightIris),\n faceOval: connectionsToIndices(pairsFaceContour),\n};\n\nexport const pairsFaceMesh: PairArray = [\n [127, 34], [34, 139], [139, 127], [11, 0], [0, 37], [37, 11],\n [232, 231], [231, 120], [120, 232], [72, 37], [37, 39], [39, 72],\n [128, 121], [121, 47], [47, 128], [232, 121], [121, 128], [128, 232],\n [104, 69], [69, 67], [67, 104], [175, 171], [171, 148], [148, 175],\n [118, 50], [50, 101], [101, 118], [73, 39], [39, 40], [40, 73],\n [9, 151], [151, 108], [108, 9], [48, 115], [115, 131], [131, 48],\n [194, 204], [204, 211], [211, 194], [74, 40], [40, 185], [185, 74],\n [80, 42], [42, 183], [183, 80], [40, 92], [92, 186], [186, 40],\n [230, 229], [229, 118], [118, 230], [202, 212], [212, 214], [214, 202],\n [83, 18], [18, 17], [17, 83], [76, 61], [61, 146], [146, 76],\n [160, 29], [29, 30], [30, 160], [56, 157], [157, 173], [173, 56],\n [106, 204], [204, 194], [194, 106], [135, 214], [214, 192], [192, 135],\n [203, 165], [165, 98], [98, 203], [21, 71], [71, 68], [68, 21],\n [51, 45], [45, 4], [4, 51], [144, 24], [24, 23], [23, 144],\n [77, 146], [146, 91], [91, 77], [205, 50], [50, 187], [187, 205],\n [201, 200], [200, 18], [18, 201], [91, 106], [106, 182], [182, 91],\n [90, 91], [91, 181], [181, 90], [85, 84], [84, 17], [17, 85],\n [206, 203], [203, 36], [36, 206], [148, 171], [171, 140], [140, 148],\n [92, 40], [40, 39], [39, 92], [193, 189], [189, 244], [244, 193],\n [159, 158], [158, 28], [28, 159], [247, 246], [246, 161], [161, 247],\n [236, 3], [3, 196], [196, 236], [54, 68], [68, 104], [104, 54],\n [193, 168], [168, 8], [8, 193], [117, 228], [228, 31], [31, 117],\n [189, 193], [193, 55], [55, 189], [98, 97], [97, 99], [99, 98],\n [126, 47], [47, 100], [100, 126], [166, 79], [79, 218], [218, 166],\n [155, 154], [154, 26], [26, 155], [209, 49], [49, 131], [131, 209],\n [135, 136], [136, 150], [150, 135], [47, 126], [126, 217], [217, 47],\n [223, 52], [52, 53], [53, 223], [45, 51], [51, 134], [134, 45],\n [211, 170], [170, 140], [140, 211], [67, 69], [69, 108], [108, 67],\n [43, 106], [106, 91], [91, 43], [230, 119], [119, 120], [120, 230],\n [226, 130], [130, 247], [247, 226], [63, 53], [53, 52], [52, 63],\n [238, 20], [20, 242], [242, 238], [46, 70], [70, 156], [156, 46],\n [78, 62], [62, 96], [96, 78], [46, 53], [53, 63], [63, 46],\n [143, 34], [34, 227], [227, 143], [123, 117], [117, 111], [111, 123],\n [44, 125], [125, 19], [19, 44], [236, 134], [134, 51], [51, 236],\n [216, 206], [206, 205], [205, 216], [154, 153], [153, 22], [22, 154],\n [39, 37], [37, 167], [167, 39], [200, 201], [201, 208], [208, 200],\n [36, 142], [142, 100], [100, 36], [57, 212], [212, 202], [202, 57],\n [20, 60], [60, 99], [99, 20], [28, 158], [158, 157], [157, 28],\n [35, 226], [226, 113], [113, 35], [160, 159], [159, 27], [27, 160],\n [204, 202], [202, 210], [210, 204], [113, 225], [225, 46], [46, 113],\n [43, 202], [202, 204], [204, 43], [62, 76], [76, 77], [77, 62],\n [137, 123], [123, 116], [116, 137], [41, 38], [38, 72], [72, 41],\n [203, 129], [129, 142], [142, 203], [64, 98], [98, 240], [240, 64],\n [49, 102], [102, 64], [64, 49], [41, 73], [73, 74], [74, 41],\n [212, 216], [216, 207], [207, 212], [42, 74], [74, 184], [184, 42],\n [169, 170], [170, 211], [211, 169], [170, 149], [149, 176], [176, 170],\n [105, 66], [66, 69], [69, 105], [122, 6], [6, 168], [168, 122],\n [123, 147], [147, 187], [187, 123], [96, 77], [77, 90], [90, 96],\n [65, 55], [55, 107], [107, 65], [89, 90], [90, 180], [180, 89],\n [101, 100], [100, 120], [120, 101], [63, 105], [105, 104], [104, 63],\n [93, 137], [137, 227], [227, 93], [15, 86], [86, 85], [85, 15],\n [129, 102], [102, 49], [49, 129], [14, 87], [87, 86], [86, 14],\n [55, 8], [8, 9], [9, 55], [100, 47], [47, 121], [121, 100],\n [145, 23], [23, 22], [22, 145], [88, 89], [89, 179], [179, 88],\n [6, 122], [122, 196], [196, 6], [88, 95], [95, 96], [96, 88],\n [138, 172], [172, 136], [136, 138], [215, 58], [58, 172], [172, 215],\n [115, 48], [48, 219], [219, 115], [42, 80], [80, 81], [81, 42],\n [195, 3], [3, 51], [51, 195], [43, 146], [146, 61], [61, 43],\n [171, 175], [175, 199], [199, 171], [81, 82], [82, 38], [38, 81],\n [53, 46], [46, 225], [225, 53], [144, 163], [163, 110], [110, 144],\n [52, 65], [65, 66], [66, 52], [229, 228], [228, 117], [117, 229],\n [34, 127], [127, 234], [234, 34], [107, 108], [108, 69], [69, 107],\n [109, 108], [108, 151], [151, 109], [48, 64], [64, 235], [235, 48],\n [62, 78], [78, 191], [191, 62], [129, 209], [209, 126], [126, 129],\n [111, 35], [35, 143], [143, 111], [117, 123], [123, 50], [50, 117],\n [222, 65], [65, 52], [52, 222], [19, 125], [125, 141], [141, 19],\n [221, 55], [55, 65], [65, 221], [3, 195], [195, 197], [197, 3],\n [25, 7], [7, 33], [33, 25], [220, 237], [237, 44], [44, 220],\n [70, 71], [71, 139], [139, 70], [122, 193], [193, 245], [245, 122],\n [247, 130], [130, 33], [33, 247], [71, 21], [21, 162], [162, 71],\n [170, 169], [169, 150], [150, 170], [188, 174], [174, 196], [196, 188],\n [216, 186], [186, 92], [92, 216], [2, 97], [97, 167], [167, 2],\n [141, 125], [125, 241], [241, 141], [164, 167], [167, 37], [37, 164],\n [72, 38], [38, 12], [12, 72], [38, 82], [82, 13], [13, 38],\n [63, 68], [68, 71], [71, 63], [226, 35], [35, 111], [111, 226],\n [101, 50], [50, 205], [205, 101], [206, 92], [92, 165], [165, 206],\n [209, 198], [198, 217], [217, 209], [165, 167], [167, 97], [97, 165],\n [220, 115], [115, 218], [218, 220], [133, 112], [112, 243], [243, 133],\n [239, 238], [238, 241], [241, 239], [214, 135], [135, 169], [169, 214],\n [190, 173], [173, 133], [133, 190], [171, 208], [208, 32], [32, 171],\n [125, 44], [44, 237], [237, 125], [86, 87], [87, 178], [178, 86],\n [85, 86], [86, 179], [179, 85], [84, 85], [85, 180], [180, 84],\n [83, 84], [84, 181], [181, 83], [201, 83], [83, 182], [182, 201],\n [137, 93], [93, 132], [132, 137], [76, 62], [62, 183], [183, 76],\n [61, 76], [76, 184], [184, 61], [57, 61], [61, 185], [185, 57],\n [212, 57], [57, 186], [186, 212], [214, 207], [207, 187], [187, 214],\n [34, 143], [143, 156], [156, 34], [79, 239], [239, 237], [237, 79],\n [123, 137], [137, 177], [177, 123], [44, 1], [1, 4], [4, 44],\n [201, 194], [194, 32], [32, 201], [64, 102], [102, 129], [129, 64],\n [213, 215], [215, 138], [138, 213], [59, 166], [166, 219], [219, 59],\n [242, 99], [99, 97], [97, 242], [2, 94], [94, 141], [141, 2],\n [75, 59], [59, 235], [235, 75], [24, 110], [110, 228], [228, 24],\n [25, 130], [130, 226], [226, 25], [23, 24], [24, 229], [229, 23],\n [22, 23], [23, 230], [230, 22], [26, 22], [22, 231], [231, 26],\n [112, 26], [26, 232], [232, 112], [189, 190], [190, 243], [243, 189],\n [221, 56], [56, 190], [190, 221], [28, 56], [56, 221], [221, 28],\n [27, 28], [28, 222], [222, 27], [29, 27], [27, 223], [223, 29],\n [30, 29], [29, 224], [224, 30], [247, 30], [30, 225], [225, 247],\n [238, 79], [79, 20], [20, 238], [166, 59], [59, 75], [75, 166],\n [60, 75], [75, 240], [240, 60], [147, 177], [177, 215], [215, 147],\n [20, 79], [79, 166], [166, 20], [187, 147], [147, 213], [213, 187],\n [112, 233], [233, 244], [244, 112], [233, 128], [128, 245], [245, 233],\n [128, 114], [114, 188], [188, 128], [114, 217], [217, 174], [174, 114],\n [131, 115], [115, 220], [220, 131], [217, 198], [198, 236], [236, 217],\n [198, 131], [131, 134], [134, 198], [177, 132], [132, 58], [58, 177],\n [143, 35], [35, 124], [124, 143], [110, 163], [163, 7], [7, 110],\n [228, 110], [110, 25], [25, 228], [356, 389], [389, 368], [368, 356],\n [11, 302], [302, 267], [267, 11], [452, 350], [350, 349], [349, 452],\n [302, 303], [303, 269], [269, 302], [357, 343], [343, 277], [277, 357],\n [452, 453], [453, 357], [357, 452], [333, 332], [332, 297], [297, 333],\n [175, 152], [152, 377], [377, 175], [347, 348], [348, 330], [330, 347],\n [303, 304], [304, 270], [270, 303], [9, 336], [336, 337], [337, 9],\n [278, 279], [279, 360], [360, 278], [418, 262], [262, 431], [431, 418],\n [304, 408], [408, 409], [409, 304], [310, 415], [415, 407], [407, 310],\n [270, 409], [409, 410], [410, 270], [450, 348], [348, 347], [347, 450],\n [422, 430], [430, 434], [434, 422], [313, 314], [314, 17], [17, 313],\n [306, 307], [307, 375], [375, 306], [387, 388], [388, 260], [260, 387],\n [286, 414], [414, 398], [398, 286], [335, 406], [406, 418], [418, 335],\n [364, 367], [367, 416], [416, 364], [423, 358], [358, 327], [327, 423],\n [251, 284], [284, 298], [298, 251], [281, 5], [5, 4], [4, 281],\n [373, 374], [374, 253], [253, 373], [307, 320], [320, 321], [321, 307],\n [425, 427], [427, 411], [411, 425], [421, 313], [313, 18], [18, 421],\n [321, 405], [405, 406], [406, 321], [320, 404], [404, 405], [405, 320],\n [315, 16], [16, 17], [17, 315], [426, 425], [425, 266], [266, 426],\n [377, 400], [400, 369], [369, 377], [322, 391], [391, 269], [269, 322],\n [417, 465], [465, 464], [464, 417], [386, 257], [257, 258], [258, 386],\n [466, 260], [260, 388], [388, 466], [456, 399], [399, 419], [419, 456],\n [284, 332], [332, 333], [333, 284], [417, 285], [285, 8], [8, 417],\n [346, 340], [340, 261], [261, 346], [413, 441], [441, 285], [285, 413],\n [327, 460], [460, 328], [328, 327], [355, 371], [371, 329], [329, 355],\n [392, 439], [439, 438], [438, 392], [382, 341], [341, 256], [256, 382],\n [429, 420], [420, 360], [360, 429], [364, 394], [394, 379], [379, 364],\n [277, 343], [343, 437], [437, 277], [443, 444], [444, 283], [283, 443],\n [275, 440], [440, 363], [363, 275], [431, 262], [262, 369], [369, 431],\n [297, 338], [338, 337], [337, 297], [273, 375], [375, 321], [321, 273],\n [450, 451], [451, 349], [349, 450], [446, 342], [342, 467], [467, 446],\n [293, 334], [334, 282], [282, 293], [458, 461], [461, 462], [462, 458],\n [276, 353], [353, 383], [383, 276], [308, 324], [324, 325], [325, 308],\n [276, 300], [300, 293], [293, 276], [372, 345], [345, 447], [447, 372],\n [352, 345], [345, 340], [340, 352], [274, 1], [1, 19], [19, 274],\n [456, 248], [248, 281], [281, 456], [436, 427], [427, 425], [425, 436],\n [381, 256], [256, 252], [252, 381], [269, 391], [391, 393], [393, 269],\n [200, 199], [199, 428], [428, 200], [266, 330], [330, 329], [329, 266],\n [287, 273], [273, 422], [422, 287], [250, 462], [462, 328], [328, 250],\n [258, 286], [286, 384], [384, 258], [265, 353], [353, 342], [342, 265],\n [387, 259], [259, 257], [257, 387], [424, 431], [431, 430], [430, 424],\n [342, 353], [353, 276], [276, 342], [273, 335], [335, 424], [424, 273],\n [292, 325], [325, 307], [307, 292], [366, 447], [447, 345], [345, 366],\n [271, 303], [303, 302], [302, 271], [423, 266], [266, 371], [371, 423],\n [294, 455], [455, 460], [460, 294], [279, 278], [278, 294], [294, 279],\n [271, 272], [272, 304], [304, 271], [432, 434], [434, 427], [427, 432],\n [272, 407], [407, 408], [408, 272], [394, 430], [430, 431], [431, 394],\n [395, 369], [369, 400], [400, 395], [334, 333], [333, 299], [299, 334],\n [351, 417], [417, 168], [168, 351], [352, 280], [280, 411], [411, 352],\n [325, 319], [319, 320], [320, 325], [295, 296], [296, 336], [336, 295],\n [319, 403], [403, 404], [404, 319], [330, 348], [348, 349], [349, 330],\n [293, 298], [298, 333], [333, 293], [323, 454], [454, 447], [447, 323],\n [15, 16], [16, 315], [315, 15], [358, 429], [429, 279], [279, 358],\n [14, 15], [15, 316], [316, 14], [285, 336], [336, 9], [9, 285],\n [329, 349], [349, 350], [350, 329], [374, 380], [380, 252], [252, 374],\n [318, 402], [402, 403], [403, 318], [6, 197], [197, 419], [419, 6],\n [318, 319], [319, 325], [325, 318], [367, 364], [364, 365], [365, 367],\n [435, 367], [367, 397], [397, 435], [344, 438], [438, 439], [439, 344],\n [272, 271], [271, 311], [311, 272], [195, 5], [5, 281], [281, 195],\n [273, 287], [287, 291], [291, 273], [396, 428], [428, 199], [199, 396],\n [311, 271], [271, 268], [268, 311], [283, 444], [444, 445], [445, 283],\n [373, 254], [254, 339], [339, 373], [282, 334], [334, 296], [296, 282],\n [449, 347], [347, 346], [346, 449], [264, 447], [447, 454], [454, 264],\n [336, 296], [296, 299], [299, 336], [338, 10], [10, 151], [151, 338],\n [278, 439], [439, 455], [455, 278], [292, 407], [407, 415], [415, 292],\n [358, 371], [371, 355], [355, 358], [340, 345], [345, 372], [372, 340],\n [346, 347], [347, 280], [280, 346], [442, 443], [443, 282], [282, 442],\n [19, 94], [94, 370], [370, 19], [441, 442], [442, 295], [295, 441],\n [248, 419], [419, 197], [197, 248], [263, 255], [255, 359], [359, 263],\n [440, 275], [275, 274], [274, 440], [300, 383], [383, 368], [368, 300],\n [351, 412], [412, 465], [465, 351], [263, 467], [467, 466], [466, 263],\n [301, 368], [368, 389], [389, 301], [395, 378], [378, 379], [379, 395],\n [412, 351], [351, 419], [419, 412], [436, 426], [426, 322], [322, 436],\n [2, 164], [164, 393], [393, 2], [370, 462], [462, 461], [461, 370],\n [164, 0], [0, 267], [267, 164], [302, 11], [11, 12], [12, 302],\n [268, 12], [12, 13], [13, 268], [293, 300], [300, 301], [301, 293],\n [446, 261], [261, 340], [340, 446], [330, 266], [266, 425], [425, 330],\n [426, 423], [423, 391], [391, 426], [429, 355], [355, 437], [437, 429],\n [391, 327], [327, 326], [326, 391], [440, 457], [457, 438], [438, 440],\n [341, 382], [382, 362], [362, 341], [459, 457], [457, 461], [461, 459],\n [434, 430], [430, 394], [394, 434], [414, 463], [463, 362], [362, 414],\n [396, 369], [369, 262], [262, 396], [354, 461], [461, 457], [457, 354],\n [316, 403], [403, 402], [402, 316], [315, 404], [404, 403], [403, 315],\n [314, 405], [405, 404], [404, 314], [313, 406], [406, 405], [405, 313],\n [421, 418], [418, 406], [406, 421], [366, 401], [401, 361], [361, 366],\n [306, 408], [408, 407], [407, 306], [291, 409], [409, 408], [408, 291],\n [287, 410], [410, 409], [409, 287], [432, 436], [436, 410], [410, 432],\n [434, 416], [416, 411], [411, 434], [264, 368], [368, 383], [383, 264],\n [309, 438], [438, 457], [457, 309], [352, 376], [376, 401], [401, 352],\n [274, 275], [275, 4], [4, 274], [421, 428], [428, 262], [262, 421],\n [294, 327], [327, 358], [358, 294], [433, 416], [416, 367], [367, 433],\n [289, 455], [455, 439], [439, 289], [462, 370], [370, 326], [326, 462],\n [2, 326], [326, 370], [370, 2], [305, 460], [460, 455], [455, 305],\n [254, 449], [449, 448], [448, 254], [255, 261], [261, 446], [446, 255],\n [253, 450], [450, 449], [449, 253], [252, 451], [451, 450], [450, 252],\n [256, 452], [452, 451], [451, 256], [341, 453], [453, 452], [452, 341],\n [413, 464], [464, 463], [463, 413], [441, 413], [413, 414], [414, 441],\n [258, 442], [442, 441], [441, 258], [257, 443], [443, 442], [442, 257],\n [259, 444], [444, 443], [443, 259], [260, 445], [445, 444], [444, 260],\n [467, 342], [342, 445], [445, 467], [459, 458], [458, 250], [250, 459],\n [289, 392], [392, 290], [290, 289], [290, 328], [328, 460], [460, 290],\n [376, 433], [433, 435], [435, 376], [250, 290], [290, 392], [392, 250],\n [411, 416], [416, 433], [433, 411], [341, 463], [463, 464], [464, 341],\n [453, 464], [464, 465], [465, 453], [357, 465], [465, 412], [412, 357],\n [343, 412], [412, 399], [399, 343], [360, 363], [363, 440], [440, 360],\n [437, 399], [399, 456], [456, 437], [420, 456], [456, 363], [363, 420],\n [401, 435], [435, 288], [288, 401], [372, 383], [383, 353], [353, 372],\n [339, 255], [255, 249], [249, 339], [448, 261], [261, 255], [255, 448],\n [133, 243], [243, 190], [190, 133], [133, 155], [155, 112], [112, 133],\n [33, 246], [246, 247], [247, 33], [33, 130], [130, 25], [25, 33],\n [398, 384], [384, 286], [286, 398], [362, 398], [398, 414], [414, 362],\n [362, 463], [463, 341], [341, 362], [263, 359], [359, 467], [467, 263],\n [263, 249], [249, 255], [255, 263], [466, 467], [467, 260], [260, 466],\n [75, 60], [60, 166], [166, 75], [238, 239], [239, 79], [79, 238],\n [162, 127], [127, 139], [139, 162], [72, 11], [11, 37], [37, 72],\n [121, 232], [232, 120], [120, 121], [73, 72], [72, 39], [39, 73],\n [114, 128], [128, 47], [47, 114], [233, 232], [232, 128], [128, 233],\n [103, 104], [104, 67], [67, 103], [152, 175], [175, 148], [148, 152],\n [119, 118], [118, 101], [101, 119], [74, 73], [73, 40], [40, 74],\n [107, 9], [9, 108], [108, 107], [49, 48], [48, 131], [131, 49],\n [32, 194], [194, 211], [211, 32], [184, 74], [74, 185], [185, 184],\n [191, 80], [80, 183], [183, 191], [185, 40], [40, 186], [186, 185],\n [119, 230], [230, 118], [118, 119], [210, 202], [202, 214], [214, 210],\n [84, 83], [83, 17], [17, 84], [77, 76], [76, 146], [146, 77],\n [161, 160], [160, 30], [30, 161], [190, 56], [56, 173], [173, 190],\n [182, 106], [106, 194], [194, 182], [138, 135], [135, 192], [192, 138],\n [129, 203], [203, 98], [98, 129], [54, 21], [21, 68], [68, 54],\n [5, 51], [51, 4], [4, 5], [145, 144], [144, 23], [23, 145],\n [90, 77], [77, 91], [91, 90], [207, 205], [205, 187], [187, 207],\n [83, 201], [201, 18], [18, 83], [181, 91], [91, 182], [182, 181],\n [180, 90], [90, 181], [181, 180], [16, 85], [85, 17], [17, 16],\n [205, 206], [206, 36], [36, 205], [176, 148], [148, 140], [140, 176],\n [165, 92], [92, 39], [39, 165], [245, 193], [193, 244], [244, 245],\n [27, 159], [159, 28], [28, 27], [30, 247], [247, 161], [161, 30],\n [174, 236], [236, 196], [196, 174], [103, 54], [54, 104], [104, 103],\n [55, 193], [193, 8], [8, 55], [111, 117], [117, 31], [31, 111],\n [221, 189], [189, 55], [55, 221], [240, 98], [98, 99], [99, 240],\n [142, 126], [126, 100], [100, 142], [219, 166], [166, 218], [218, 219],\n [112, 155], [155, 26], [26, 112], [198, 209], [209, 131], [131, 198],\n [169, 135], [135, 150], [150, 169], [114, 47], [47, 217], [217, 114],\n [224, 223], [223, 53], [53, 224], [220, 45], [45, 134], [134, 220],\n [32, 211], [211, 140], [140, 32], [109, 67], [67, 108], [108, 109],\n [146, 43], [43, 91], [91, 146], [231, 230], [230, 120], [120, 231],\n [113, 226], [226, 247], [247, 113], [105, 63], [63, 52], [52, 105],\n [241, 238], [238, 242], [242, 241], [124, 46], [46, 156], [156, 124],\n [95, 78], [78, 96], [96, 95], [70, 46], [46, 63], [63, 70],\n [116, 143], [143, 227], [227, 116], [116, 123], [123, 111], [111, 116],\n [1, 44], [44, 19], [19, 1], [3, 236], [236, 51], [51, 3],\n [207, 216], [216, 205], [205, 207], [26, 154], [154, 22], [22, 26],\n [165, 39], [39, 167], [167, 165], [199, 200], [200, 208], [208, 199],\n [101, 36], [36, 100], [100, 101], [43, 57], [57, 202], [202, 43],\n [242, 20], [20, 99], [99, 242], [56, 28], [28, 157], [157, 56],\n [124, 35], [35, 113], [113, 124], [29, 160], [160, 27], [27, 29],\n [211, 204], [204, 210], [210, 211], [124, 113], [113, 46], [46, 124],\n [106, 43], [43, 204], [204, 106], [96, 62], [62, 77], [77, 96],\n [227, 137], [137, 116], [116, 227], [73, 41], [41, 72], [72, 73],\n [36, 203], [203, 142], [142, 36], [235, 64], [64, 240], [240, 235],\n [48, 49], [49, 64], [64, 48], [42, 41], [41, 74], [74, 42],\n [214, 212], [212, 207], [207, 214], [183, 42], [42, 184], [184, 183],\n [210, 169], [169, 211], [211, 210], [140, 170], [170, 176], [176, 140],\n [104, 105], [105, 69], [69, 104], [193, 122], [122, 168], [168, 193],\n [50, 123], [123, 187], [187, 50], [89, 96], [96, 90], [90, 89],\n [66, 65], [65, 107], [107, 66], [179, 89], [89, 180], [180, 179],\n [119, 101], [101, 120], [120, 119], [68, 63], [63, 104], [104, 68],\n [234, 93], [93, 227], [227, 234], [16, 15], [15, 85], [85, 16],\n [209, 129], [129, 49], [49, 209], [15, 14], [14, 86], [86, 15],\n [107, 55], [55, 9], [9, 107], [120, 100], [100, 121], [121, 120],\n [153, 145], [145, 22], [22, 153], [178, 88], [88, 179], [179, 178],\n [197, 6], [6, 196], [196, 197], [89, 88], [88, 96], [96, 89],\n [135, 138], [138, 136], [136, 135], [138, 215], [215, 172], [172, 138],\n [218, 115], [115, 219], [219, 218], [41, 42], [42, 81], [81, 41],\n [5, 195], [195, 51], [51, 5], [57, 43], [43, 61], [61, 57],\n [208, 171], [171, 199], [199, 208], [41, 81], [81, 38], [38, 41],\n [224, 53], [53, 225], [225, 224], [24, 144], [144, 110], [110, 24],\n [105, 52], [52, 66], [66, 105], [118, 229], [229, 117], [117, 118],\n [227, 34], [34, 234], [234, 227], [66, 107], [107, 69], [69, 66],\n [10, 109], [109, 151], [151, 10], [219, 48], [48, 235], [235, 219],\n [183, 62], [62, 191], [191, 183], [142, 129], [129, 126], [126, 142],\n [116, 111], [111, 143], [143, 116], [118, 117], [117, 50], [50, 118],\n [223, 222], [222, 52], [52, 223], [94, 19], [19, 141], [141, 94],\n [222, 221], [221, 65], [65, 222], [196, 3], [3, 197], [197, 196],\n [45, 220], [220, 44], [44, 45], [156, 70], [70, 139], [139, 156],\n [188, 122], [122, 245], [245, 188], [139, 71], [71, 162], [162, 139],\n [149, 170], [170, 150], [150, 149], [122, 188], [188, 196], [196, 122],\n [206, 216], [216, 92], [92, 206], [164, 2], [2, 167], [167, 164],\n [242, 141], [141, 241], [241, 242], [0, 164], [164, 37], [37, 0],\n [11, 72], [72, 12], [12, 11], [12, 38], [38, 13], [13, 12],\n [70, 63], [63, 71], [71, 70], [31, 226], [226, 111], [111, 31],\n [36, 101], [101, 205], [205, 36], [203, 206], [206, 165], [165, 203],\n [126, 209], [209, 217], [217, 126], [98, 165], [165, 97], [97, 98],\n [237, 220], [220, 218], [218, 237], [237, 239], [239, 241], [241, 237],\n [210, 214], [214, 169], [169, 210], [140, 171], [171, 32], [32, 140],\n [241, 125], [125, 237], [237, 241], [179, 86], [86, 178], [178, 179],\n [180, 85], [85, 179], [179, 180], [181, 84], [84, 180], [180, 181],\n [182, 83], [83, 181], [181, 182], [194, 201], [201, 182], [182, 194],\n [177, 137], [137, 132], [132, 177], [184, 76], [76, 183], [183, 184],\n [185, 61], [61, 184], [184, 185], [186, 57], [57, 185], [185, 186],\n [216, 212], [212, 186], [186, 216], [192, 214], [214, 187], [187, 192],\n [139, 34], [34, 156], [156, 139], [218, 79], [79, 237], [237, 218],\n [147, 123], [123, 177], [177, 147], [45, 44], [44, 4], [4, 45],\n [208, 201], [201, 32], [32, 208], [98, 64], [64, 129], [129, 98],\n [192, 213], [213, 138], [138, 192], [235, 59], [59, 219], [219, 235],\n [141, 242], [242, 97], [97, 141], [97, 2], [2, 141], [141, 97],\n [240, 75], [75, 235], [235, 240], [229, 24], [24, 228], [228, 229],\n [31, 25], [25, 226], [226, 31], [230, 23], [23, 229], [229, 230],\n [231, 22], [22, 230], [230, 231], [232, 26], [26, 231], [231, 232],\n [233, 112], [112, 232], [232, 233], [244, 189], [189, 243], [243, 244],\n [189, 221], [221, 190], [190, 189], [222, 28], [28, 221], [221, 222],\n [223, 27], [27, 222], [222, 223], [224, 29], [29, 223], [223, 224],\n [225, 30], [30, 224], [224, 225], [113, 247], [247, 225], [225, 113],\n [99, 60], [60, 240], [240, 99], [213, 147], [147, 215], [215, 213],\n [60, 20], [20, 166], [166, 60], [192, 187], [187, 213], [213, 192],\n [243, 112], [112, 244], [244, 243], [244, 233], [233, 245], [245, 244],\n [245, 128], [128, 188], [188, 245], [188, 114], [114, 174], [174, 188],\n [134, 131], [131, 220], [220, 134], [174, 217], [217, 236], [236, 174],\n [236, 198], [198, 134], [134, 236], [215, 177], [177, 58], [58, 215],\n [156, 143], [143, 124], [124, 156], [25, 110], [110, 7], [7, 25],\n [31, 228], [228, 25], [25, 31], [264, 356], [356, 368], [368, 264],\n [0, 11], [11, 267], [267, 0], [451, 452], [452, 349], [349, 451],\n [267, 302], [302, 269], [269, 267], [350, 357], [357, 277], [277, 350],\n [350, 452], [452, 357], [357, 350], [299, 333], [333, 297], [297, 299],\n [396, 175], [175, 377], [377, 396], [280, 347], [347, 330], [330, 280],\n [269, 303], [303, 270], [270, 269], [151, 9], [9, 337], [337, 151],\n [344, 278], [278, 360], [360, 344], [424, 418], [418, 431], [431, 424],\n [270, 304], [304, 409], [409, 270], [272, 310], [310, 407], [407, 272],\n [322, 270], [270, 410], [410, 322], [449, 450], [450, 347], [347, 449],\n [432, 422], [422, 434], [434, 432], [18, 313], [313, 17], [17, 18],\n [291, 306], [306, 375], [375, 291], [259, 387], [387, 260], [260, 259],\n [424, 335], [335, 418], [418, 424], [434, 364], [364, 416], [416, 434],\n [391, 423], [423, 327], [327, 391], [301, 251], [251, 298], [298, 301],\n [275, 281], [281, 4], [4, 275], [254, 373], [373, 253], [253, 254],\n [375, 307], [307, 321], [321, 375], [280, 425], [425, 411], [411, 280],\n [200, 421], [421, 18], [18, 200], [335, 321], [321, 406], [406, 335],\n [321, 320], [320, 405], [405, 321], [314, 315], [315, 17], [17, 314],\n [423, 426], [426, 266], [266, 423], [396, 377], [377, 369], [369, 396],\n [270, 322], [322, 269], [269, 270], [413, 417], [417, 464], [464, 413],\n [385, 386], [386, 258], [258, 385], [248, 456], [456, 419], [419, 248],\n [298, 284], [284, 333], [333, 298], [168, 417], [417, 8], [8, 168],\n [448, 346], [346, 261], [261, 448], [417, 413], [413, 285], [285, 417],\n [326, 327], [327, 328], [328, 326], [277, 355], [355, 329], [329, 277],\n [309, 392], [392, 438], [438, 309], [381, 382], [382, 256], [256, 381],\n [279, 429], [429, 360], [360, 279], [365, 364], [364, 379], [379, 365],\n [355, 277], [277, 437], [437, 355], [282, 443], [443, 283], [283, 282],\n [281, 275], [275, 363], [363, 281], [395, 431], [431, 369], [369, 395],\n [299, 297], [297, 337], [337, 299], [335, 273], [273, 321], [321, 335],\n [348, 450], [450, 349], [349, 348], [359, 446], [446, 467], [467, 359],\n [283, 293], [293, 282], [282, 283], [250, 458], [458, 462], [462, 250],\n [300, 276], [276, 383], [383, 300], [292, 308], [308, 325], [325, 292],\n [283, 276], [276, 293], [293, 283], [264, 372], [372, 447], [447, 264],\n [346, 352], [352, 340], [340, 346], [354, 274], [274, 19], [19, 354],\n [363, 456], [456, 281], [281, 363], [426, 436], [436, 425], [425, 426],\n [380, 381], [381, 252], [252, 380], [267, 269], [269, 393], [393, 267],\n [421, 200], [200, 428], [428, 421], [371, 266], [266, 329], [329, 371],\n [432, 287], [287, 422], [422, 432], [290, 250], [250, 328], [328, 290],\n [385, 258], [258, 384], [384, 385], [446, 265], [265, 342], [342, 446],\n [386, 387], [387, 257], [257, 386], [422, 424], [424, 430], [430, 422],\n [445, 342], [342, 276], [276, 445], [422, 273], [273, 424], [424, 422],\n [306, 292], [292, 307], [307, 306], [352, 366], [366, 345], [345, 352],\n [268, 271], [271, 302], [302, 268], [358, 423], [423, 371], [371, 358],\n [327, 294], [294, 460], [460, 327], [331, 279], [279, 294], [294, 331],\n [303, 271], [271, 304], [304, 303], [436, 432], [432, 427], [427, 436],\n [304, 272], [272, 408], [408, 304], [395, 394], [394, 431], [431, 395],\n [378, 395], [395, 400], [400, 378], [296, 334], [334, 299], [299, 296],\n [6, 351], [351, 168], [168, 6], [376, 352], [352, 411], [411, 376],\n [307, 325], [325, 320], [320, 307], [285, 295], [295, 336], [336, 285],\n [320, 319], [319, 404], [404, 320], [329, 330], [330, 349], [349, 329],\n [334, 293], [293, 333], [333, 334], [366, 323], [323, 447], [447, 366],\n [316, 15], [15, 315], [315, 316], [331, 358], [358, 279], [279, 331],\n [317, 14], [14, 316], [316, 317], [8, 285], [285, 9], [9, 8],\n [277, 329], [329, 350], [350, 277], [253, 374], [374, 252], [252, 253],\n [319, 318], [318, 403], [403, 319], [351, 6], [6, 419], [419, 351],\n [324, 318], [318, 325], [325, 324], [397, 367], [367, 365], [365, 397],\n [288, 435], [435, 397], [397, 288], [278, 344], [344, 439], [439, 278],\n [310, 272], [272, 311], [311, 310], [248, 195], [195, 281], [281, 248],\n [375, 273], [273, 291], [291, 375], [175, 396], [396, 199], [199, 175],\n [312, 311], [311, 268], [268, 312], [276, 283], [283, 445], [445, 276],\n [390, 373], [373, 339], [339, 390], [295, 282], [282, 296], [296, 295],\n [448, 449], [449, 346], [346, 448], [356, 264], [264, 454], [454, 356],\n [337, 336], [336, 299], [299, 337], [337, 338], [338, 151], [151, 337],\n [294, 278], [278, 455], [455, 294], [308, 292], [292, 415], [415, 308],\n [429, 358], [358, 355], [355, 429], [265, 340], [340, 372], [372, 265],\n [352, 346], [346, 280], [280, 352], [295, 442], [442, 282], [282, 295],\n [354, 19], [19, 370], [370, 354], [285, 441], [441, 295], [295, 285],\n [195, 248], [248, 197], [197, 195], [457, 440], [440, 274], [274, 457],\n [301, 300], [300, 368], [368, 301], [417, 351], [351, 465], [465, 417],\n [251, 301], [301, 389], [389, 251], [394, 395], [395, 379], [379, 394],\n [399, 412], [412, 419], [419, 399], [410, 436], [436, 322], [322, 410],\n [326, 2], [2, 393], [393, 326], [354, 370], [370, 461], [461, 354],\n [393, 164], [164, 267], [267, 393], [268, 302], [302, 12], [12, 268],\n [312, 268], [268, 13], [13, 312], [298, 293], [293, 301], [301, 298],\n [265, 446], [446, 340], [340, 265], [280, 330], [330, 425], [425, 280],\n [322, 426], [426, 391], [391, 322], [420, 429], [429, 437], [437, 420],\n [393, 391], [391, 326], [326, 393], [344, 440], [440, 438], [438, 344],\n [458, 459], [459, 461], [461, 458], [364, 434], [434, 394], [394, 364],\n [428, 396], [396, 262], [262, 428], [274, 354], [354, 457], [457, 274],\n [317, 316], [316, 402], [402, 317], [316, 315], [315, 403], [403, 316],\n [315, 314], [314, 404], [404, 315], [314, 313], [313, 405], [405, 314],\n [313, 421], [421, 406], [406, 313], [323, 366], [366, 361], [361, 323],\n [292, 306], [306, 407], [407, 292], [306, 291], [291, 408], [408, 306],\n [291, 287], [287, 409], [409, 291], [287, 432], [432, 410], [410, 287],\n [427, 434], [434, 411], [411, 427], [372, 264], [264, 383], [383, 372],\n [459, 309], [309, 457], [457, 459], [366, 352], [352, 401], [401, 366],\n [1, 274], [274, 4], [4, 1], [418, 421], [421, 262], [262, 418],\n [331, 294], [294, 358], [358, 331], [435, 433], [433, 367], [367, 435],\n [392, 289], [289, 439], [439, 392], [328, 462], [462, 326], [326, 328],\n [94, 2], [2, 370], [370, 94], [289, 305], [305, 455], [455, 289],\n [339, 254], [254, 448], [448, 339], [359, 255], [255, 446], [446, 359],\n [254, 253], [253, 449], [449, 254], [253, 252], [252, 450], [450, 253],\n [252, 256], [256, 451], [451, 252], [256, 341], [341, 452], [452, 256],\n [414, 413], [413, 463], [463, 414], [286, 441], [441, 414], [414, 286],\n [286, 258], [258, 441], [441, 286], [258, 257], [257, 442], [442, 258],\n [257, 259], [259, 443], [443, 257], [259, 260], [260, 444], [444, 259],\n [260, 467], [467, 445], [445, 260], [309, 459], [459, 250], [250, 309],\n [305, 289], [289, 290], [290, 305], [305, 290], [290, 460], [460, 305],\n [401, 376], [376, 435], [435, 401], [309, 250], [250, 392], [392, 309],\n [376, 411], [411, 433], [433, 376], [453, 341], [341, 464], [464, 453],\n [357, 453], [453, 465], [465, 357], [343, 357], [357, 412], [412, 343],\n [437, 343], [343, 399], [399, 437], [344, 360], [360, 440], [440, 344],\n [420, 437], [437, 456], [456, 420], [360, 420], [420, 363], [363, 360],\n [361, 401], [401, 288], [288, 361], [265, 372], [372, 353], [353, 265],\n [390, 339], [339, 249], [249, 390], [339, 448], [448, 255], [255, 339],\n];\n", "// @tensorflow/tfjs-models/face-landmark-detection/src/constants.ts\n// https://github.com/google/mediapipe/mediapipe/python/solutions/face_mesh_connections.py\n\ntype PairArray = [number, number][];\n\nconst LIPS_CONNECTIONS: PairArray = [\n [61, 146], [146, 91], [91, 181], [181, 84], [84, 17], [17, 314], [314, 405], [405, 321], [321, 375], [375, 291], [61, 185], [185, 40], [40, 39], [39, 37], [37, 0], [0, 267], [267, 269], [269, 270], [270, 409], [409, 291],\n [78, 95], [95, 88], [88, 178], [178, 87], [87, 14], [14, 317], [317, 402], [402, 318], [318, 324], [324, 308], [78, 191], [191, 80], [80, 81], [81, 82], [82, 13], [13, 312], [312, 311], [311, 310], [310, 415], [415, 308],\n];\n\nconst LEFT_EYE_CONNECTIONS: PairArray = [[263, 249], [249, 390], [390, 373], [373, 374], [374, 380], [380, 381], [381, 382], [382, 362], [263, 466], [466, 388], [388, 387], [387, 386], [386, 385], [385, 384], [384, 398], [398, 362]];\n\nconst LEFT_EYEBROW_CONNECTIONS: PairArray = [[276, 283], [283, 282], [282, 295], [295, 285], [300, 293], [293, 334], [334, 296], [296, 336]];\n\nconst LEFT_IRIS_CONNECTIONS: PairArray = [[474, 475], [475, 476], [476, 477], [477, 474]];\n\nconst RIGHT_EYE_CONNECTIONS: PairArray = [[33, 7], [7, 163], [163, 144], [144, 145], [145, 153], [153, 154], [154, 155], [155, 133], [33, 246], [246, 161], [161, 160], [160, 159], [159, 158], [158, 157], [157, 173], [173, 133]];\n\nconst RIGHT_EYEBROW_CONNECTIONS: PairArray = [[46, 53], [53, 52], [52, 65], [65, 55], [70, 63], [63, 105], [105, 66], [66, 107]];\n\nconst RIGHT_IRIS_CONNECTIONS: PairArray = [[469, 470], [470, 471], [471, 472], [472, 469]];\n\nconst FACE_OVAL_CONNECTIONS: PairArray = [\n [10, 338], [338, 297], [297, 332], [332, 284], [284, 251], [251, 389], [389, 356], [356, 454], [454, 323], [323, 361], [361, 288], [288, 397], [397, 365], [365, 379], [379, 378], [378, 400], [400, 377], [377, 152],\n [152, 148], [148, 176], [176, 149], [149, 150], [150, 136], [136, 172], [172, 58], [58, 132], [132, 93], [93, 234], [234, 127], [127, 162], [162, 21], [21, 54], [54, 103], [103, 67], [67, 109], [109, 10],\n];\n\nexport const MEDIAPIPE_FACE_MESH_CONNECTED_KEYPOINTS_PAIRS: PairArray = [\n [127, 34], [34, 139], [139, 127], [11, 0], [0, 37], [37, 11], [232, 231], [231, 120], [120, 232], [72, 37], [37, 39], [39, 72], [128, 121], [121, 47], [47, 128], [232, 121], [121, 128], [128, 232],\n [104, 69], [69, 67], [67, 104], [175, 171], [171, 148], [148, 175], [118, 50], [50, 101], [101, 118], [73, 39], [39, 40], [40, 73], [9, 151], [151, 108], [108, 9], [48, 115], [115, 131], [131, 48],\n [194, 204], [204, 211], [211, 194], [74, 40], [40, 185], [185, 74], [80, 42], [42, 183], [183, 80], [40, 92], [92, 186], [186, 40], [230, 229], [229, 118], [118, 230], [202, 212], [212, 214], [214, 202],\n [83, 18], [18, 17], [17, 83], [76, 61], [61, 146], [146, 76], [160, 29], [29, 30], [30, 160], [56, 157], [157, 173], [173, 56], [106, 204], [204, 194], [194, 106], [135, 214], [214, 192], [192, 135],\n [203, 165], [165, 98], [98, 203], [21, 71], [71, 68], [68, 21], [51, 45], [45, 4], [4, 51], [144, 24], [24, 23], [23, 144], [77, 146], [146, 91], [91, 77], [205, 50], [50, 187], [187, 205],\n [201, 200], [200, 18], [18, 201], [91, 106], [106, 182], [182, 91], [90, 91], [91, 181], [181, 90], [85, 84], [84, 17], [17, 85], [206, 203], [203, 36], [36, 206], [148, 171], [171, 140], [140, 148],\n [92, 40], [40, 39], [39, 92], [193, 189], [189, 244], [244, 193], [159, 158], [158, 28], [28, 159], [247, 246], [246, 161], [161, 247], [236, 3], [3, 196], [196, 236], [54, 68], [68, 104], [104, 54],\n [193, 168], [168, 8], [8, 193], [117, 228], [228, 31], [31, 117], [189, 193], [193, 55], [55, 189], [98, 97], [97, 99], [99, 98], [126, 47], [47, 100], [100, 126], [166, 79], [79, 218], [218, 166],\n [155, 154], [154, 26], [26, 155], [209, 49], [49, 131], [131, 209], [135, 136], [136, 150], [150, 135], [47, 126], [126, 217], [217, 47], [223, 52], [52, 53], [53, 223], [45, 51], [51, 134], [134, 45],\n [211, 170], [170, 140], [140, 211], [67, 69], [69, 108], [108, 67], [43, 106], [106, 91], [91, 43], [230, 119], [119, 120], [120, 230], [226, 130], [130, 247], [247, 226], [63, 53], [53, 52], [52, 63],\n [238, 20], [20, 242], [242, 238], [46, 70], [70, 156], [156, 46], [78, 62], [62, 96], [96, 78], [46, 53], [53, 63], [63, 46], [143, 34], [34, 227], [227, 143], [123, 117], [117, 111], [111, 123],\n [44, 125], [125, 19], [19, 44], [236, 134], [134, 51], [51, 236], [216, 206], [206, 205], [205, 216], [154, 153], [153, 22], [22, 154], [39, 37], [37, 167], [167, 39], [200, 201], [201, 208], [208, 200],\n [36, 142], [142, 100], [100, 36], [57, 212], [212, 202], [202, 57], [20, 60], [60, 99], [99, 20], [28, 158], [158, 157], [157, 28], [35, 226], [226, 113], [113, 35], [160, 159], [159, 27], [27, 160],\n [204, 202], [202, 210], [210, 204], [113, 225], [225, 46], [46, 113], [43, 202], [202, 204], [204, 43], [62, 76], [76, 77], [77, 62], [137, 123], [123, 116], [116, 137], [41, 38], [38, 72], [72, 41],\n [203, 129], [129, 142], [142, 203], [64, 98], [98, 240], [240, 64], [49, 102], [102, 64], [64, 49], [41, 73], [73, 74], [74, 41], [212, 216], [216, 207], [207, 212], [42, 74], [74, 184], [184, 42],\n [169, 170], [170, 211], [211, 169], [170, 149], [149, 176], [176, 170], [105, 66], [66, 69], [69, 105], [122, 6], [6, 168], [168, 122], [123, 147], [147, 187], [187, 123], [96, 77], [77, 90], [90, 96],\n [65, 55], [55, 107], [107, 65], [89, 90], [90, 180], [180, 89], [101, 100], [100, 120], [120, 101], [63, 105], [105, 104], [104, 63], [93, 137], [137, 227], [227, 93], [15, 86], [86, 85], [85, 15],\n [129, 102], [102, 49], [49, 129], [14, 87], [87, 86], [86, 14], [55, 8], [8, 9], [9, 55], [100, 47], [47, 121], [121, 100], [145, 23], [23, 22], [22, 145], [88, 89], [89, 179], [179, 88],\n [6, 122], [122, 196], [196, 6], [88, 95], [95, 96], [96, 88], [138, 172], [172, 136], [136, 138], [215, 58], [58, 172], [172, 215], [115, 48], [48, 219], [219, 115], [42, 80], [80, 81], [81, 42],\n [195, 3], [3, 51], [51, 195], [43, 146], [146, 61], [61, 43], [171, 175], [175, 199], [199, 171], [81, 82], [82, 38], [38, 81], [53, 46], [46, 225], [225, 53], [144, 163], [163, 110], [110, 144],\n [52, 65], [65, 66], [66, 52], [229, 228], [228, 117], [117, 229], [34, 127], [127, 234], [234, 34], [107, 108], [108, 69], [69, 107], [109, 108], [108, 151], [151, 109], [48, 64], [64, 235], [235, 48],\n [62, 78], [78, 191], [191, 62], [129, 209], [209, 126], [126, 129], [111, 35], [35, 143], [143, 111], [117, 123], [123, 50], [50, 117], [222, 65], [65, 52], [52, 222], [19, 125], [125, 141], [141, 19],\n [221, 55], [55, 65], [65, 221], [3, 195], [195, 197], [197, 3], [25, 7], [7, 33], [33, 25], [220, 237], [237, 44], [44, 220], [70, 71], [71, 139], [139, 70], [122, 193], [193, 245], [245, 122],\n [247, 130], [130, 33], [33, 247], [71, 21], [21, 162], [162, 71], [170, 169], [169, 150], [150, 170], [188, 174], [174, 196], [196, 188], [216, 186], [186, 92], [92, 216], [2, 97], [97, 167], [167, 2],\n [141, 125], [125, 241], [241, 141], [164, 167], [167, 37], [37, 164], [72, 38], [38, 12], [12, 72], [38, 82], [82, 13], [13, 38], [63, 68], [68, 71], [71, 63], [226, 35], [35, 111], [111, 226],\n [101, 50], [50, 205], [205, 101], [206, 92], [92, 165], [165, 206], [209, 198], [198, 217], [217, 209], [165, 167], [167, 97], [97, 165], [220, 115], [115, 218], [218, 220], [133, 112], [112, 243], [243, 133],\n [239, 238], [238, 241], [241, 239], [214, 135], [135, 169], [169, 214], [190, 173], [173, 133], [133, 190], [171, 208], [208, 32], [32, 171], [125, 44], [44, 237], [237, 125], [86, 87], [87, 178], [178, 86],\n [85, 86], [86, 179], [179, 85], [84, 85], [85, 180], [180, 84], [83, 84], [84, 181], [181, 83], [201, 83], [83, 182], [182, 201], [137, 93], [93, 132], [132, 137], [76, 62], [62, 183], [183, 76],\n [61, 76], [76, 184], [184, 61], [57, 61], [61, 185], [185, 57], [212, 57], [57, 186], [186, 212], [214, 207], [207, 187], [187, 214], [34, 143], [143, 156], [156, 34], [79, 239], [239, 237], [237, 79],\n [123, 137], [137, 177], [177, 123], [44, 1], [1, 4], [4, 44], [201, 194], [194, 32], [32, 201], [64, 102], [102, 129], [129, 64], [213, 215], [215, 138], [138, 213], [59, 166], [166, 219], [219, 59],\n [242, 99], [99, 97], [97, 242], [2, 94], [94, 141], [141, 2], [75, 59], [59, 235], [235, 75], [24, 110], [110, 228], [228, 24], [25, 130], [130, 226], [226, 25], [23, 24], [24, 229], [229, 23],\n [22, 23], [23, 230], [230, 22], [26, 22], [22, 231], [231, 26], [112, 26], [26, 232], [232, 112], [189, 190], [190, 243], [243, 189], [221, 56], [56, 190], [190, 221], [28, 56], [56, 221], [221, 28],\n [27, 28], [28, 222], [222, 27], [29, 27], [27, 223], [223, 29], [30, 29], [29, 224], [224, 30], [247, 30], [30, 225], [225, 247], [238, 79], [79, 20], [20, 238], [166, 59], [59, 75], [75, 166],\n [60, 75], [75, 240], [240, 60], [147, 177], [177, 215], [215, 147], [20, 79], [79, 166], [166, 20], [187, 147], [147, 213], [213, 187], [112, 233], [233, 244], [244, 112], [233, 128], [128, 245], [245, 233],\n [128, 114], [114, 188], [188, 128], [114, 217], [217, 174], [174, 114], [131, 115], [115, 220], [220, 131], [217, 198], [198, 236], [236, 217], [198, 131], [131, 134], [134, 198], [177, 132], [132, 58], [58, 177],\n [143, 35], [35, 124], [124, 143], [110, 163], [163, 7], [7, 110], [228, 110], [110, 25], [25, 228], [356, 389], [389, 368], [368, 356], [11, 302], [302, 267], [267, 11], [452, 350], [350, 349], [349, 452],\n [302, 303], [303, 269], [269, 302], [357, 343], [343, 277], [277, 357], [452, 453], [453, 357], [357, 452], [333, 332], [332, 297], [297, 333], [175, 152], [152, 377], [377, 175], [347, 348], [348, 330], [330, 347],\n [303, 304], [304, 270], [270, 303], [9, 336], [336, 337], [337, 9], [278, 279], [279, 360], [360, 278], [418, 262], [262, 431], [431, 418], [304, 408], [408, 409], [409, 304], [310, 415], [415, 407], [407, 310],\n [270, 409], [409, 410], [410, 270], [450, 348], [348, 347], [347, 450], [422, 430], [430, 434], [434, 422], [313, 314], [314, 17], [17, 313], [306, 307], [307, 375], [375, 306], [387, 388], [388, 260], [260, 387],\n [286, 414], [414, 398], [398, 286], [335, 406], [406, 418], [418, 335], [364, 367], [367, 416], [416, 364], [423, 358], [358, 327], [327, 423], [251, 284], [284, 298], [298, 251], [281, 5], [5, 4], [4, 281],\n [373, 374], [374, 253], [253, 373], [307, 320], [320, 321], [321, 307], [425, 427], [427, 411], [411, 425], [421, 313], [313, 18], [18, 421], [321, 405], [405, 406], [406, 321], [320, 404], [404, 405], [405, 320],\n [315, 16], [16, 17], [17, 315], [426, 425], [425, 266], [266, 426], [377, 400], [400, 369], [369, 377], [322, 391], [391, 269], [269, 322], [417, 465], [465, 464], [464, 417], [386, 257], [257, 258], [258, 386],\n [466, 260], [260, 388], [388, 466], [456, 399], [399, 419], [419, 456], [284, 332], [332, 333], [333, 284], [417, 285], [285, 8], [8, 417], [346, 340], [340, 261], [261, 346], [413, 441], [441, 285], [285, 413],\n [327, 460], [460, 328], [328, 327], [355, 371], [371, 329], [329, 355], [392, 439], [439, 438], [438, 392], [382, 341], [341, 256], [256, 382], [429, 420], [420, 360], [360, 429], [364, 394], [394, 379], [379, 364],\n [277, 343], [343, 437], [437, 277], [443, 444], [444, 283], [283, 443], [275, 440], [440, 363], [363, 275], [431, 262], [262, 369], [369, 431], [297, 338], [338, 337], [337, 297], [273, 375], [375, 321], [321, 273],\n [450, 451], [451, 349], [349, 450], [446, 342], [342, 467], [467, 446], [293, 334], [334, 282], [282, 293], [458, 461], [461, 462], [462, 458], [276, 353], [353, 383], [383, 276], [308, 324], [324, 325], [325, 308],\n [276, 300], [300, 293], [293, 276], [372, 345], [345, 447], [447, 372], [352, 345], [345, 340], [340, 352], [274, 1], [1, 19], [19, 274], [456, 248], [248, 281], [281, 456], [436, 427], [427, 425], [425, 436],\n [381, 256], [256, 252], [252, 381], [269, 391], [391, 393], [393, 269], [200, 199], [199, 428], [428, 200], [266, 330], [330, 329], [329, 266], [287, 273], [273, 422], [422, 287], [250, 462], [462, 328], [328, 250],\n [258, 286], [286, 384], [384, 258], [265, 353], [353, 342], [342, 265], [387, 259], [259, 257], [257, 387], [424, 431], [431, 430], [430, 424], [342, 353], [353, 276], [276, 342], [273, 335], [335, 424], [424, 273],\n [292, 325], [325, 307], [307, 292], [366, 447], [447, 345], [345, 366], [271, 303], [303, 302], [302, 271], [423, 266], [266, 371], [371, 423], [294, 455], [455, 460], [460, 294], [279, 278], [278, 294], [294, 279],\n [271, 272], [272, 304], [304, 271], [432, 434], [434, 427], [427, 432], [272, 407], [407, 408], [408, 272], [394, 430], [430, 431], [431, 394], [395, 369], [369, 400], [400, 395], [334, 333], [333, 299], [299, 334],\n [351, 417], [417, 168], [168, 351], [352, 280], [280, 411], [411, 352], [325, 319], [319, 320], [320, 325], [295, 296], [296, 336], [336, 295], [319, 403], [403, 404], [404, 319], [330, 348], [348, 349], [349, 330],\n [293, 298], [298, 333], [333, 293], [323, 454], [454, 447], [447, 323], [15, 16], [16, 315], [315, 15], [358, 429], [429, 279], [279, 358], [14, 15], [15, 316], [316, 14], [285, 336], [336, 9], [9, 285],\n [329, 349], [349, 350], [350, 329], [374, 380], [380, 252], [252, 374], [318, 402], [402, 403], [403, 318], [6, 197], [197, 419], [419, 6], [318, 319], [319, 325], [325, 318], [367, 364], [364, 365], [365, 367],\n [435, 367], [367, 397], [397, 435], [344, 438], [438, 439], [439, 344], [272, 271], [271, 311], [311, 272], [195, 5], [5, 281], [281, 195], [273, 287], [287, 291], [291, 273], [396, 428], [428, 199], [199, 396],\n [311, 271], [271, 268], [268, 311], [283, 444], [444, 445], [445, 283], [373, 254], [254, 339], [339, 373], [282, 334], [334, 296], [296, 282], [449, 347], [347, 346], [346, 449], [264, 447], [447, 454], [454, 264],\n [336, 296], [296, 299], [299, 336], [338, 10], [10, 151], [151, 338], [278, 439], [439, 455], [455, 278], [292, 407], [407, 415], [415, 292], [358, 371], [371, 355], [355, 358], [340, 345], [345, 372], [372, 340],\n [346, 347], [347, 280], [280, 346], [442, 443], [443, 282], [282, 442], [19, 94], [94, 370], [370, 19], [441, 442], [442, 295], [295, 441], [248, 419], [419, 197], [197, 248], [263, 255], [255, 359], [359, 263],\n [440, 275], [275, 274], [274, 440], [300, 383], [383, 368], [368, 300], [351, 412], [412, 465], [465, 351], [263, 467], [467, 466], [466, 263], [301, 368], [368, 389], [389, 301], [395, 378], [378, 379], [379, 395],\n [412, 351], [351, 419], [419, 412], [436, 426], [426, 322], [322, 436], [2, 164], [164, 393], [393, 2], [370, 462], [462, 461], [461, 370], [164, 0], [0, 267], [267, 164], [302, 11], [11, 12], [12, 302],\n [268, 12], [12, 13], [13, 268], [293, 300], [300, 301], [301, 293], [446, 261], [261, 340], [340, 446], [330, 266], [266, 425], [425, 330], [426, 423], [423, 391], [391, 426], [429, 355], [355, 437], [437, 429],\n [391, 327], [327, 326], [326, 391], [440, 457], [457, 438], [438, 440], [341, 382], [382, 362], [362, 341], [459, 457], [457, 461], [461, 459], [434, 430], [430, 394], [394, 434], [414, 463], [463, 362], [362, 414],\n [396, 369], [369, 262], [262, 396], [354, 461], [461, 457], [457, 354], [316, 403], [403, 402], [402, 316], [315, 404], [404, 403], [403, 315], [314, 405], [405, 404], [404, 314], [313, 406], [406, 405], [405, 313],\n [421, 418], [418, 406], [406, 421], [366, 401], [401, 361], [361, 366], [306, 408], [408, 407], [407, 306], [291, 409], [409, 408], [408, 291], [287, 410], [410, 409], [409, 287], [432, 436], [436, 410], [410, 432],\n [434, 416], [416, 411], [411, 434], [264, 368], [368, 383], [383, 264], [309, 438], [438, 457], [457, 309], [352, 376], [376, 401], [401, 352], [274, 275], [275, 4], [4, 274], [421, 428], [428, 262], [262, 421],\n [294, 327], [327, 358], [358, 294], [433, 416], [416, 367], [367, 433], [289, 455], [455, 439], [439, 289], [462, 370], [370, 326], [326, 462], [2, 326], [326, 370], [370, 2], [305, 460], [460, 455], [455, 305],\n [254, 449], [449, 448], [448, 254], [255, 261], [261, 446], [446, 255], [253, 450], [450, 449], [449, 253], [252, 451], [451, 450], [450, 252], [256, 452], [452, 451], [451, 256], [341, 453], [453, 452], [452, 341],\n [413, 464], [464, 463], [463, 413], [441, 413], [413, 414], [414, 441], [258, 442], [442, 441], [441, 258], [257, 443], [443, 442], [442, 257], [259, 444], [444, 443], [443, 259], [260, 445], [445, 444], [444, 260],\n [467, 342], [342, 445], [445, 467], [459, 458], [458, 250], [250, 459], [289, 392], [392, 290], [290, 289], [290, 328], [328, 460], [460, 290], [376, 433], [433, 435], [435, 376], [250, 290], [290, 392], [392, 250],\n [411, 416], [416, 433], [433, 411], [341, 463], [463, 464], [464, 341], [453, 464], [464, 465], [465, 453], [357, 465], [465, 412], [412, 357], [343, 412], [412, 399], [399, 343], [360, 363], [363, 440], [440, 360],\n [437, 399], [399, 456], [456, 437], [420, 456], [456, 363], [363, 420], [401, 435], [435, 288], [288, 401], [372, 383], [383, 353], [353, 372], [339, 255], [255, 249], [249, 339], [448, 261], [261, 255], [255, 448],\n [133, 243], [243, 190], [190, 133], [133, 155], [155, 112], [112, 133], [33, 246], [246, 247], [247, 33], [33, 130], [130, 25], [25, 33], [398, 384], [384, 286], [286, 398], [362, 398], [398, 414], [414, 362],\n [362, 463], [463, 341], [341, 362], [263, 359], [359, 467], [467, 263], [263, 249], [249, 255], [255, 263], [466, 467], [467, 260], [260, 466], [75, 60], [60, 166], [166, 75], [238, 239], [239, 79], [79, 238],\n [162, 127], [127, 139], [139, 162], [72, 11], [11, 37], [37, 72], [121, 232], [232, 120], [120, 121], [73, 72], [72, 39], [39, 73], [114, 128], [128, 47], [47, 114], [233, 232], [232, 128], [128, 233],\n [103, 104], [104, 67], [67, 103], [152, 175], [175, 148], [148, 152], [119, 118], [118, 101], [101, 119], [74, 73], [73, 40], [40, 74], [107, 9], [9, 108], [108, 107], [49, 48], [48, 131], [131, 49],\n [32, 194], [194, 211], [211, 32], [184, 74], [74, 185], [185, 184], [191, 80], [80, 183], [183, 191], [185, 40], [40, 186], [186, 185], [119, 230], [230, 118], [118, 119], [210, 202], [202, 214], [214, 210],\n [84, 83], [83, 17], [17, 84], [77, 76], [76, 146], [146, 77], [161, 160], [160, 30], [30, 161], [190, 56], [56, 173], [173, 190], [182, 106], [106, 194], [194, 182], [138, 135], [135, 192], [192, 138],\n [129, 203], [203, 98], [98, 129], [54, 21], [21, 68], [68, 54], [5, 51], [51, 4], [4, 5], [145, 144], [144, 23], [23, 145], [90, 77], [77, 91], [91, 90], [207, 205], [205, 187], [187, 207],\n [83, 201], [201, 18], [18, 83], [181, 91], [91, 182], [182, 181], [180, 90], [90, 181], [181, 180], [16, 85], [85, 17], [17, 16], [205, 206], [206, 36], [36, 205], [176, 148], [148, 140], [140, 176],\n [165, 92], [92, 39], [39, 165], [245, 193], [193, 244], [244, 245], [27, 159], [159, 28], [28, 27], [30, 247], [247, 161], [161, 30], [174, 236], [236, 196], [196, 174], [103, 54], [54, 104], [104, 103],\n [55, 193], [193, 8], [8, 55], [111, 117], [117, 31], [31, 111], [221, 189], [189, 55], [55, 221], [240, 98], [98, 99], [99, 240], [142, 126], [126, 100], [100, 142], [219, 166], [166, 218], [218, 219],\n [112, 155], [155, 26], [26, 112], [198, 209], [209, 131], [131, 198], [169, 135], [135, 150], [150, 169], [114, 47], [47, 217], [217, 114], [224, 223], [223, 53], [53, 224], [220, 45], [45, 134], [134, 220],\n [32, 211], [211, 140], [140, 32], [109, 67], [67, 108], [108, 109], [146, 43], [43, 91], [91, 146], [231, 230], [230, 120], [120, 231], [113, 226], [226, 247], [247, 113], [105, 63], [63, 52], [52, 105],\n [241, 238], [238, 242], [242, 241], [124, 46], [46, 156], [156, 124], [95, 78], [78, 96], [96, 95], [70, 46], [46, 63], [63, 70], [116, 143], [143, 227], [227, 116], [116, 123], [123, 111], [111, 116],\n [1, 44], [44, 19], [19, 1], [3, 236], [236, 51], [51, 3], [207, 216], [216, 205], [205, 207], [26, 154], [154, 22], [22, 26], [165, 39], [39, 167], [167, 165], [199, 200], [200, 208], [208, 199],\n [101, 36], [36, 100], [100, 101], [43, 57], [57, 202], [202, 43], [242, 20], [20, 99], [99, 242], [56, 28], [28, 157], [157, 56], [124, 35], [35, 113], [113, 124], [29, 160], [160, 27], [27, 29],\n [211, 204], [204, 210], [210, 211], [124, 113], [113, 46], [46, 124], [106, 43], [43, 204], [204, 106], [96, 62], [62, 77], [77, 96], [227, 137], [137, 116], [116, 227], [73, 41], [41, 72], [72, 73],\n [36, 203], [203, 142], [142, 36], [235, 64], [64, 240], [240, 235], [48, 49], [49, 64], [64, 48], [42, 41], [41, 74], [74, 42], [214, 212], [212, 207], [207, 214], [183, 42], [42, 184], [184, 183],\n [210, 169], [169, 211], [211, 210], [140, 170], [170, 176], [176, 140], [104, 105], [105, 69], [69, 104], [193, 122], [122, 168], [168, 193], [50, 123], [123, 187], [187, 50], [89, 96], [96, 90], [90, 89],\n [66, 65], [65, 107], [107, 66], [179, 89], [89, 180], [180, 179], [119, 101], [101, 120], [120, 119], [68, 63], [63, 104], [104, 68], [234, 93], [93, 227], [227, 234], [16, 15], [15, 85], [85, 16],\n [209, 129], [129, 49], [49, 209], [15, 14], [14, 86], [86, 15], [107, 55], [55, 9], [9, 107], [120, 100], [100, 121], [121, 120], [153, 145], [145, 22], [22, 153], [178, 88], [88, 179], [179, 178],\n [197, 6], [6, 196], [196, 197], [89, 88], [88, 96], [96, 89], [135, 138], [138, 136], [136, 135], [138, 215], [215, 172], [172, 138], [218, 115], [115, 219], [219, 218], [41, 42], [42, 81], [81, 41],\n [5, 195], [195, 51], [51, 5], [57, 43], [43, 61], [61, 57], [208, 171], [171, 199], [199, 208], [41, 81], [81, 38], [38, 41], [224, 53], [53, 225], [225, 224], [24, 144], [144, 110], [110, 24],\n [105, 52], [52, 66], [66, 105], [118, 229], [229, 117], [117, 118], [227, 34], [34, 234], [234, 227], [66, 107], [107, 69], [69, 66], [10, 109], [109, 151], [151, 10], [219, 48], [48, 235], [235, 219],\n [183, 62], [62, 191], [191, 183], [142, 129], [129, 126], [126, 142], [116, 111], [111, 143], [143, 116], [118, 117], [117, 50], [50, 118], [223, 222], [222, 52], [52, 223], [94, 19], [19, 141], [141, 94],\n [222, 221], [221, 65], [65, 222], [196, 3], [3, 197], [197, 196], [45, 220], [220, 44], [44, 45], [156, 70], [70, 139], [139, 156], [188, 122], [122, 245], [245, 188], [139, 71], [71, 162], [162, 139],\n [149, 170], [170, 150], [150, 149], [122, 188], [188, 196], [196, 122], [206, 216], [216, 92], [92, 206], [164, 2], [2, 167], [167, 164], [242, 141], [141, 241], [241, 242], [0, 164], [164, 37], [37, 0],\n [11, 72], [72, 12], [12, 11], [12, 38], [38, 13], [13, 12], [70, 63], [63, 71], [71, 70], [31, 226], [226, 111], [111, 31], [36, 101], [101, 205], [205, 36], [203, 206], [206, 165], [165, 203],\n [126, 209], [209, 217], [217, 126], [98, 165], [165, 97], [97, 98], [237, 220], [220, 218], [218, 237], [237, 239], [239, 241], [241, 237], [210, 214], [214, 169], [169, 210], [140, 171], [171, 32], [32, 140],\n [241, 125], [125, 237], [237, 241], [179, 86], [86, 178], [178, 179], [180, 85], [85, 179], [179, 180], [181, 84], [84, 180], [180, 181], [182, 83], [83, 181], [181, 182], [194, 201], [201, 182], [182, 194],\n [177, 137], [137, 132], [132, 177], [184, 76], [76, 183], [183, 184], [185, 61], [61, 184], [184, 185], [186, 57], [57, 185], [185, 186], [216, 212], [212, 186], [186, 216], [192, 214], [214, 187], [187, 192],\n [139, 34], [34, 156], [156, 139], [218, 79], [79, 237], [237, 218], [147, 123], [123, 177], [177, 147], [45, 44], [44, 4], [4, 45], [208, 201], [201, 32], [32, 208], [98, 64], [64, 129], [129, 98],\n [192, 213], [213, 138], [138, 192], [235, 59], [59, 219], [219, 235], [141, 242], [242, 97], [97, 141], [97, 2], [2, 141], [141, 97], [240, 75], [75, 235], [235, 240], [229, 24], [24, 228], [228, 229],\n [31, 25], [25, 226], [226, 31], [230, 23], [23, 229], [229, 230], [231, 22], [22, 230], [230, 231], [232, 26], [26, 231], [231, 232], [233, 112], [112, 232], [232, 233], [244, 189], [189, 243], [243, 244],\n [189, 221], [221, 190], [190, 189], [222, 28], [28, 221], [221, 222], [223, 27], [27, 222], [222, 223], [224, 29], [29, 223], [223, 224], [225, 30], [30, 224], [224, 225], [113, 247], [247, 225], [225, 113],\n [99, 60], [60, 240], [240, 99], [213, 147], [147, 215], [215, 213], [60, 20], [20, 166], [166, 60], [192, 187], [187, 213], [213, 192], [243, 112], [112, 244], [244, 243], [244, 233], [233, 245], [245, 244],\n [245, 128], [128, 188], [188, 245], [188, 114], [114, 174], [174, 188], [134, 131], [131, 220], [220, 134], [174, 217], [217, 236], [236, 174], [236, 198], [198, 134], [134, 236], [215, 177], [177, 58], [58, 215],\n [156, 143], [143, 124], [124, 156], [25, 110], [110, 7], [7, 25], [31, 228], [228, 25], [25, 31], [264, 356], [356, 368], [368, 264], [0, 11], [11, 267], [267, 0], [451, 452], [452, 349], [349, 451],\n [267, 302], [302, 269], [269, 267], [350, 357], [357, 277], [277, 350], [350, 452], [452, 357], [357, 350], [299, 333], [333, 297], [297, 299], [396, 175], [175, 377], [377, 396], [280, 347], [347, 330], [330, 280],\n [269, 303], [303, 270], [270, 269], [151, 9], [9, 337], [337, 151], [344, 278], [278, 360], [360, 344], [424, 418], [418, 431], [431, 424], [270, 304], [304, 409], [409, 270], [272, 310], [310, 407], [407, 272],\n [322, 270], [270, 410], [410, 322], [449, 450], [450, 347], [347, 449], [432, 422], [422, 434], [434, 432], [18, 313], [313, 17], [17, 18], [291, 306], [306, 375], [375, 291], [259, 387], [387, 260], [260, 259],\n [424, 335], [335, 418], [418, 424], [434, 364], [364, 416], [416, 434], [391, 423], [423, 327], [327, 391], [301, 251], [251, 298], [298, 301], [275, 281], [281, 4], [4, 275], [254, 373], [373, 253], [253, 254],\n [375, 307], [307, 321], [321, 375], [280, 425], [425, 411], [411, 280], [200, 421], [421, 18], [18, 200], [335, 321], [321, 406], [406, 335], [321, 320], [320, 405], [405, 321], [314, 315], [315, 17], [17, 314],\n [423, 426], [426, 266], [266, 423], [396, 377], [377, 369], [369, 396], [270, 322], [322, 269], [269, 270], [413, 417], [417, 464], [464, 413], [385, 386], [386, 258], [258, 385], [248, 456], [456, 419], [419, 248],\n [298, 284], [284, 333], [333, 298], [168, 417], [417, 8], [8, 168], [448, 346], [346, 261], [261, 448], [417, 413], [413, 285], [285, 417], [326, 327], [327, 328], [328, 326], [277, 355], [355, 329], [329, 277],\n [309, 392], [392, 438], [438, 309], [381, 382], [382, 256], [256, 381], [279, 429], [429, 360], [360, 279], [365, 364], [364, 379], [379, 365], [355, 277], [277, 437], [437, 355], [282, 443], [443, 283], [283, 282],\n [281, 275], [275, 363], [363, 281], [395, 431], [431, 369], [369, 395], [299, 297], [297, 337], [337, 299], [335, 273], [273, 321], [321, 335], [348, 450], [450, 349], [349, 348], [359, 446], [446, 467], [467, 359],\n [283, 293], [293, 282], [282, 283], [250, 458], [458, 462], [462, 250], [300, 276], [276, 383], [383, 300], [292, 308], [308, 325], [325, 292], [283, 276], [276, 293], [293, 283], [264, 372], [372, 447], [447, 264],\n [346, 352], [352, 340], [340, 346], [354, 274], [274, 19], [19, 354], [363, 456], [456, 281], [281, 363], [426, 436], [436, 425], [425, 426], [380, 381], [381, 252], [252, 380], [267, 269], [269, 393], [393, 267],\n [421, 200], [200, 428], [428, 421], [371, 266], [266, 329], [329, 371], [432, 287], [287, 422], [422, 432], [290, 250], [250, 328], [328, 290], [385, 258], [258, 384], [384, 385], [446, 265], [265, 342], [342, 446],\n [386, 387], [387, 257], [257, 386], [422, 424], [424, 430], [430, 422], [445, 342], [342, 276], [276, 445], [422, 273], [273, 424], [424, 422], [306, 292], [292, 307], [307, 306], [352, 366], [366, 345], [345, 352],\n [268, 271], [271, 302], [302, 268], [358, 423], [423, 371], [371, 358], [327, 294], [294, 460], [460, 327], [331, 279], [279, 294], [294, 331], [303, 271], [271, 304], [304, 303], [436, 432], [432, 427], [427, 436],\n [304, 272], [272, 408], [408, 304], [395, 394], [394, 431], [431, 395], [378, 395], [395, 400], [400, 378], [296, 334], [334, 299], [299, 296], [6, 351], [351, 168], [168, 6], [376, 352], [352, 411], [411, 376],\n [307, 325], [325, 320], [320, 307], [285, 295], [295, 336], [336, 285], [320, 319], [319, 404], [404, 320], [329, 330], [330, 349], [349, 329], [334, 293], [293, 333], [333, 334], [366, 323], [323, 447], [447, 366],\n [316, 15], [15, 315], [315, 316], [331, 358], [358, 279], [279, 331], [317, 14], [14, 316], [316, 317], [8, 285], [285, 9], [9, 8], [277, 329], [329, 350], [350, 277], [253, 374], [374, 252], [252, 253],\n [319, 318], [318, 403], [403, 319], [351, 6], [6, 419], [419, 351], [324, 318], [318, 325], [325, 324], [397, 367], [367, 365], [365, 397], [288, 435], [435, 397], [397, 288], [278, 344], [344, 439], [439, 278],\n [310, 272], [272, 311], [311, 310], [248, 195], [195, 281], [281, 248], [375, 273], [273, 291], [291, 375], [175, 396], [396, 199], [199, 175], [312, 311], [311, 268], [268, 312], [276, 283], [283, 445], [445, 276],\n [390, 373], [373, 339], [339, 390], [295, 282], [282, 296], [296, 295], [448, 449], [449, 346], [346, 448], [356, 264], [264, 454], [454, 356], [337, 336], [336, 299], [299, 337], [337, 338], [338, 151], [151, 337],\n [294, 278], [278, 455], [455, 294], [308, 292], [292, 415], [415, 308], [429, 358], [358, 355], [355, 429], [265, 340], [340, 372], [372, 265], [352, 346], [346, 280], [280, 352], [295, 442], [442, 282], [282, 295],\n [354, 19], [19, 370], [370, 354], [285, 441], [441, 295], [295, 285], [195, 248], [248, 197], [197, 195], [457, 440], [440, 274], [274, 457], [301, 300], [300, 368], [368, 301], [417, 351], [351, 465], [465, 417],\n [251, 301], [301, 389], [389, 251], [394, 395], [395, 379], [379, 394], [399, 412], [412, 419], [419, 399], [410, 436], [436, 322], [322, 410], [326, 2], [2, 393], [393, 326], [354, 370], [370, 461], [461, 354],\n [393, 164], [164, 267], [267, 393], [268, 302], [302, 12], [12, 268], [312, 268], [268, 13], [13, 312], [298, 293], [293, 301], [301, 298], [265, 446], [446, 340], [340, 265], [280, 330], [330, 425], [425, 280],\n [322, 426], [426, 391], [391, 322], [420, 429], [429, 437], [437, 420], [393, 391], [391, 326], [326, 393], [344, 440], [440, 438], [438, 344], [458, 459], [459, 461], [461, 458], [364, 434], [434, 394], [394, 364],\n [428, 396], [396, 262], [262, 428], [274, 354], [354, 457], [457, 274], [317, 316], [316, 402], [402, 317], [316, 315], [315, 403], [403, 316], [315, 314], [314, 404], [404, 315], [314, 313], [313, 405], [405, 314],\n [313, 421], [421, 406], [406, 313], [323, 366], [366, 361], [361, 323], [292, 306], [306, 407], [407, 292], [306, 291], [291, 408], [408, 306], [291, 287], [287, 409], [409, 291], [287, 432], [432, 410], [410, 287],\n [427, 434], [434, 411], [411, 427], [372, 264], [264, 383], [383, 372], [459, 309], [309, 457], [457, 459], [366, 352], [352, 401], [401, 366], [1, 274], [274, 4], [4, 1], [418, 421], [421, 262], [262, 418],\n [331, 294], [294, 358], [358, 331], [435, 433], [433, 367], [367, 435], [392, 289], [289, 439], [439, 392], [328, 462], [462, 326], [326, 328], [94, 2], [2, 370], [370, 94], [289, 305], [305, 455], [455, 289],\n [339, 254], [254, 448], [448, 339], [359, 255], [255, 446], [446, 359], [254, 253], [253, 449], [449, 254], [253, 252], [252, 450], [450, 253], [252, 256], [256, 451], [451, 252], [256, 341], [341, 452], [452, 256],\n [414, 413], [413, 463], [463, 414], [286, 441], [441, 414], [414, 286], [286, 258], [258, 441], [441, 286], [258, 257], [257, 442], [442, 258], [257, 259], [259, 443], [443, 257], [259, 260], [260, 444], [444, 259],\n [260, 467], [467, 445], [445, 260], [309, 459], [459, 250], [250, 309], [305, 289], [289, 290], [290, 305], [305, 290], [290, 460], [460, 305], [401, 376], [376, 435], [435, 401], [309, 250], [250, 392], [392, 309],\n [376, 411], [411, 433], [433, 376], [453, 341], [341, 464], [464, 453], [357, 453], [453, 465], [465, 357], [343, 357], [357, 412], [412, 343], [437, 343], [343, 399], [399, 437], [344, 360], [360, 440], [440, 344],\n [420, 437], [437, 456], [456, 420], [360, 420], [420, 363], [363, 360], [361, 401], [401, 288], [288, 361], [265, 372], [372, 353], [353, 265], [390, 339], [339, 249], [249, 390], [339, 448], [448, 255], [255, 339],\n];\n\nfunction connectionsToIndices(connections: PairArray) {\n const indices = connections.map((connection) => connection[0]);\n indices.push(connections[connections.length - 1][1]);\n return indices;\n}\n\nexport const MEDIAPIPE_FACE_MESH_KEYPOINTS_BY_CONTOUR = {\n lips: connectionsToIndices(LIPS_CONNECTIONS),\n leftEye: connectionsToIndices(LEFT_EYE_CONNECTIONS),\n leftEyebrow: connectionsToIndices(LEFT_EYEBROW_CONNECTIONS),\n leftIris: connectionsToIndices(LEFT_IRIS_CONNECTIONS),\n rightEye: connectionsToIndices(RIGHT_EYE_CONNECTIONS),\n rightEyebrow: connectionsToIndices(RIGHT_EYEBROW_CONNECTIONS),\n rightIris: connectionsToIndices(RIGHT_IRIS_CONNECTIONS),\n faceOval: connectionsToIndices(FACE_OVAL_CONNECTIONS),\n};\n\nconst indexLabelPairs: [number, string][] = Object.entries(MEDIAPIPE_FACE_MESH_KEYPOINTS_BY_CONTOUR)\n .map(([label, indices]) => indices.map((index) => [index, label] as [number, string]))\n .flat();\n\nexport const MEDIAPIPE_FACE_MESH_KEYPOINTS = new Map(indexLabelPairs);\n\ntype AssignAverage = number[];\nexport interface LandmarksRefinementConfig {\n indexesMapping: number[]; // Maps indexes of the given set of landmarks to indexes of the resulting set of landmarks. Should be non empty and contain the same amount of indexes as landmarks in the corresponding input\n zRefinement: 'none'|'copy'|AssignAverage; // Z refinement instructions.\n}\n\nexport const LANDMARKS_REFINEMENT_LIPS_CONFIG = [\n 61, 146, 91, 181, 84, 17, 314, 405, 321, 375, 291, // Lower outer.\n 185, 40, 39, 37, 0, 267, 269, 270, 409, // Upper outer(excluding corners).\n 78, 95, 88, 178, 87, 14, 317, 402, 318, 324, 308, // Lower inner.\n 191, 80, 81, 82, 13, 312, 311, 310, 415, // Upper inner(excluding corners).\n 76, 77, 90, 180, 85, 16, 315, 404, 320, 307, 306, // Lower semi - outer.\n 184, 74, 73, 72, 11, 302, 303, 304, 408, // Upper semi - outer(excluding corners).\n 62, 96, 89, 179, 86, 15, 316, 403, 319, 325, 292, // Lower semi - inner.\n 183, 42, 41, 38, 12, 268, 271, 272, 407, // Upper semi - inner(excluding corners).\n];\n\nexport const LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG = [\n 33, 7, 163, 144, 145, 153, 154, 155, 133, // Lower contour.\n 246, 161, 160, 159, 158, 157, 173, // upper contour (excluding corners).\n 130, 25, 110, 24, 23, 22, 26, 112, 243, // Halo x2 lower contour.\n 247, 30, 29, 27, 28, 56, 190, // Halo x2 upper contour (excluding corners).\n 226, 31, 228, 229, 230, 231, 232, 233, 244, // Halo x3 lower contour.\n 113, 225, 224, 223, 222, 221, 189, // Halo x3 upper contour (excluding corners).\n 35, 124, 46, 53, 52, 65, // Halo x4 upper contour (no lower because of mesh structure) or eyebrow inner contour.\n 143, 111, 117, 118, 119, 120, 121, 128, 245, // Halo x5 lower contour.\n 156, 70, 63, 105, 66, 107, 55, 193, // Halo x5 upper contour (excluding corners) or eyebrow outer contour.\n];\n\nexport const LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG = [\n 263, 249, 390, 373, 374, 380, 381, 382, 362, // Lower contour.\n 466, 388, 387, 386, 385, 384, 398, // Upper contour (excluding corners).\n 359, 255, 339, 254, 253, 252, 256, 341, 463, // Halo x2 lower contour.\n 467, 260, 259, 257, 258, 286, 414, // Halo x2 upper contour (excluding corners).\n 446, 261, 448, 449, 450, 451, 452, 453, 464, // Halo x3 lower contour.\n 342, 445, 444, 443, 442, 441, 413, // Halo x3 upper contour (excluding corners).\n 265, 353, 276, 283, 282, 295, // Halo x4 upper contour (no lower because of mesh structure) or/ eyebrow inner contour.\n 372, 340, 346, 347, 348, 349, 350, 357, 465, // Halo x5 lower contour.\n 383, 300, 293, 334, 296, 336, 285, 417, // Halo x5 upper contour (excluding corners) or eyebrow outer contour.\n];\n\nexport const LANDMARKS_REFINEMENT_LEFT_IRIS_CONFIG = [\n 468, // Center.\n 469, // Iris right edge.\n 470, // Iris top edge.\n 471, // Iris left edge.\n 472, // Iris bottom edge.\n];\n/*\nzRefinement: [\n 33, 7, 163, 144, 145, 153, 154, 155, 133, // Lower contour.\n 246, 161, 160, 159, 158, 157, 173, // Upper contour (excluding corners).\n];\n*/\n\nexport const LANDMARKS_REFINEMENT_RIGHT_IRIS_CONFIG = [\n 473, // Center.\n 474, // Iris right edge.\n 475, // Iris top edge.\n 476, // Iris left edge.\n 477, // Iris bottom edge.\n];\n/*\nzRefinement: [\n 263, 249, 390, 373, 374, 380, 381, 382, 362, // Lower contour.\n 466, 388, 387, 386, 385, 384, 398, // Upper contour (excluding corners).\n];\n*/\n", "import { TRI468 as triangulation } from '../face/facemeshcoords';\nimport { mergeDeep } from '../util/util';\nimport { getCanvasContext, rad2deg, rect, point, lines, arrow, labels, replace } from './primitives';\nimport { options } from './options';\nimport * as facemeshConstants from '../face/constants';\nimport type { FaceResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\nlet localOptions: DrawOptions;\n\nfunction drawLabels(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (!localOptions.drawLabels || (localOptions.faceLabels?.length === 0)) return;\n let l = localOptions.faceLabels.slice();\n l = replace(l, '[id]', f.id.toFixed(0));\n if (f.score) l = replace(l, '[score]', 100 * f.score);\n if (f.gender) l = replace(l, '[gender]', f.gender);\n if (f.genderScore) l = replace(l, '[genderScore]', 100 * f.genderScore);\n if (f.age) l = replace(l, '[age]', f.age);\n if (f.distance) l = replace(l, '[distance]', 100 * f.distance);\n if (f.real) l = replace(l, '[real]', 100 * f.real);\n if (f.live) l = replace(l, '[live]', 100 * f.live);\n if (f.emotion && f.emotion.length > 0) {\n const emotion = f.emotion.map((a) => `${Math.trunc(100 * a.score)}% ${a.emotion}`);\n if (emotion.length > 3) emotion.length = 3;\n l = replace(l, '[emotions]', emotion.join(' '));\n }\n if (f.rotation?.angle?.roll) l = replace(l, '[roll]', rad2deg(f.rotation.angle.roll));\n if (f.rotation?.angle?.yaw) l = replace(l, '[yaw]', rad2deg(f.rotation.angle.yaw));\n if (f.rotation?.angle?.pitch) l = replace(l, '[pitch]', rad2deg(f.rotation.angle.pitch));\n if (f.rotation?.gaze?.bearing) l = replace(l, '[gaze]', rad2deg(f.rotation.gaze.bearing));\n labels(ctx, l, f.box[0], f.box[1], localOptions);\n}\n\nfunction drawIrisElipse(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n // iris: array[center, left, top, right, bottom]\n if (f.annotations?.leftEyeIris && f.annotations?.leftEyeIris[0]) {\n ctx.strokeStyle = localOptions.useDepth ? 'rgba(255, 200, 255, 0.3)' : localOptions.color;\n ctx.beginPath();\n const sizeX = Math.abs(f.annotations.leftEyeIris[3][0] - f.annotations.leftEyeIris[1][0]) / 2;\n const sizeY = Math.abs(f.annotations.leftEyeIris[4][1] - f.annotations.leftEyeIris[2][1]) / 2;\n ctx.ellipse(f.annotations.leftEyeIris[0][0], f.annotations.leftEyeIris[0][1], sizeX, sizeY, 0, 0, 2 * Math.PI);\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.fillStyle = localOptions.useDepth ? 'rgba(255, 255, 200, 0.3)' : localOptions.color;\n ctx.fill();\n }\n }\n if (f.annotations?.rightEyeIris && f.annotations?.rightEyeIris[0]) {\n ctx.strokeStyle = localOptions.useDepth ? 'rgba(255, 200, 255, 0.3)' : localOptions.color;\n ctx.beginPath();\n const sizeX = Math.abs(f.annotations.rightEyeIris[3][0] - f.annotations.rightEyeIris[1][0]) / 2;\n const sizeY = Math.abs(f.annotations.rightEyeIris[4][1] - f.annotations.rightEyeIris[2][1]) / 2;\n ctx.ellipse(f.annotations.rightEyeIris[0][0], f.annotations.rightEyeIris[0][1], sizeX, sizeY, 0, 0, 2 * Math.PI);\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.fillStyle = localOptions.useDepth ? 'rgba(255, 255, 200, 0.3)' : localOptions.color;\n ctx.fill();\n }\n }\n}\n\nfunction drawGazeSpheres(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawGaze && f.rotation?.angle && typeof Path2D !== 'undefined') {\n ctx.strokeStyle = 'pink';\n const valX = (f.box[0] + f.box[2] / 2) - (f.box[3] * rad2deg(f.rotation.angle.yaw) / 90);\n const valY = (f.box[1] + f.box[3] / 2) + (f.box[2] * rad2deg(f.rotation.angle.pitch) / 90);\n const pathV = new Path2D(`\n M ${f.box[0] + f.box[2] / 2} ${f.box[1]}\n C\n ${valX} ${f.box[1]},\n ${valX} ${f.box[1] + f.box[3]},\n ${f.box[0] + f.box[2] / 2} ${f.box[1] + f.box[3]}\n `);\n const pathH = new Path2D(`\n M ${f.box[0]} ${f.box[1] + f.box[3] / 2}\n C \n ${f.box[0]} ${valY},\n ${f.box[0] + f.box[2]} ${valY},\n ${f.box[0] + f.box[2]} ${f.box[1] + f.box[3] / 2}\n `);\n ctx.stroke(pathH);\n ctx.stroke(pathV);\n }\n}\n\nfunction drawGazeArrows(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawGaze && f.rotation?.gaze.strength && f.rotation.gaze.bearing && f.annotations.leftEyeIris && f.annotations.rightEyeIris && f.annotations.leftEyeIris[0] && f.annotations.rightEyeIris[0]) {\n ctx.strokeStyle = 'pink';\n ctx.fillStyle = 'pink';\n const leftGaze = [\n f.annotations.leftEyeIris[0][0] + (Math.sin(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[3]),\n f.annotations.leftEyeIris[0][1] + (Math.cos(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[2]),\n ];\n arrow(ctx, [f.annotations.leftEyeIris[0][0], f.annotations.leftEyeIris[0][1]], [leftGaze[0], leftGaze[1]], 4);\n const rightGaze = [\n f.annotations.rightEyeIris[0][0] + (Math.sin(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[3]),\n f.annotations.rightEyeIris[0][1] + (Math.cos(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[2]),\n ];\n arrow(ctx, [f.annotations.rightEyeIris[0][0], f.annotations.rightEyeIris[0][1]], [rightGaze[0], rightGaze[1]], 4);\n }\n}\n\nfunction drawFacePolygons(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawPolygons && f.mesh.length >= 468) {\n ctx.lineWidth = 1;\n for (let i = 0; i < triangulation.length / 3; i++) {\n const points = [triangulation[i * 3 + 0], triangulation[i * 3 + 1], triangulation[i * 3 + 2]].map((index) => f.mesh[index]);\n lines(ctx, points, localOptions);\n }\n drawIrisElipse(f, ctx);\n }\n /*\n if (localOptions.drawPolygons && f.contours.length > 1) {\n ctx.lineWidth = 5;\n lines(ctx, f.contours, opt);\n }\n ctx.lineWidth = 1;\n */\n}\n\nfunction drawFacePoints(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawPoints) {\n if (f?.mesh.length >= 468) {\n for (let i = 0; i < f.mesh.length; i++) {\n point(ctx, f.mesh[i][0], f.mesh[i][1], f.mesh[i][2], localOptions);\n if (localOptions.drawAttention) {\n if (facemeshConstants.LANDMARKS_REFINEMENT_LIPS_CONFIG.includes(i)) point(ctx, f.mesh[i][0], f.mesh[i][1], (f.mesh[i][2] as number) + 127, localOptions);\n if (facemeshConstants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG.includes(i)) point(ctx, f.mesh[i][0], f.mesh[i][1], (f.mesh[i][2] as number) - 127, localOptions);\n if (facemeshConstants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG.includes(i)) point(ctx, f.mesh[i][0], f.mesh[i][1], (f.mesh[i][2] as number) - 127, localOptions);\n }\n }\n } else {\n for (const [k, v] of Object.entries(f?.annotations || {})) {\n if (!v?.[0]) continue;\n const pt = v[0];\n point(ctx, pt[0], pt[1], 0, localOptions);\n if (localOptions.drawLabels) labels(ctx, k, pt[0], pt[1], localOptions);\n }\n }\n }\n}\n\nfunction drawFaceBoxes(f: FaceResult, ctx) {\n if (localOptions.drawBoxes) {\n rect(ctx, f.box[0], f.box[1], f.box[2], f.box[3], localOptions);\n }\n}\n\n/** draw detected faces */\nexport function face(inCanvas: AnyCanvas, result: FaceResult[], drawOptions?: Partial) {\n localOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.font = localOptions.font;\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n for (const f of result) {\n drawFaceBoxes(f, ctx);\n drawLabels(f, ctx);\n if (f.mesh && f.mesh.length > 0) {\n drawFacePoints(f, ctx);\n drawFacePolygons(f, ctx);\n drawGazeSpheres(f, ctx);\n drawGazeArrows(f, ctx);\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, rect, point, curves, colorDepth, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { BodyResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\n/** draw detected bodies */\nexport function body(inCanvas: AnyCanvas, result: BodyResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n for (let i = 0; i < result.length; i++) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n ctx.lineWidth = localOptions.lineWidth;\n ctx.font = localOptions.font;\n if (localOptions.drawBoxes && result[i].box && result[i].box.length === 4) {\n rect(ctx, result[i].box[0], result[i].box[1], result[i].box[2], result[i].box[3], localOptions);\n if (localOptions.drawLabels && (localOptions.bodyLabels?.length > 0)) {\n let l = localOptions.bodyLabels.slice();\n l = replace(l, '[id]', result[i].id.toFixed(0));\n l = replace(l, '[score]', 100 * result[i].score);\n labels(ctx, l, result[i].box[0], result[i].box[1], localOptions);\n }\n }\n if (localOptions.drawPoints && result[i].keypoints) {\n for (let pt = 0; pt < result[i].keypoints.length; pt++) {\n if (!result[i].keypoints[pt].score || (result[i].keypoints[pt].score === 0)) continue;\n ctx.fillStyle = colorDepth(result[i].keypoints[pt].position[2], localOptions);\n point(ctx, result[i].keypoints[pt].position[0], result[i].keypoints[pt].position[1], 0, localOptions);\n }\n }\n if (localOptions.drawLabels && (localOptions.bodyPartLabels?.length > 0) && result[i].keypoints) {\n ctx.font = localOptions.font;\n for (const pt of result[i].keypoints) {\n if (!pt.score || (pt.score === 0)) continue;\n let l = localOptions.bodyPartLabels.slice();\n l = replace(l, '[label]', pt.part);\n l = replace(l, '[score]', 100 * pt.score);\n labels(ctx, l, pt.position[0], pt.position[1], localOptions);\n }\n }\n if (localOptions.drawPolygons && result[i].keypoints && result[i].annotations) {\n for (const part of Object.values(result[i].annotations)) {\n for (const connected of part) curves(ctx, connected, localOptions);\n }\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, rect, point, colorDepth, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { HandResult } from '../result';\nimport type { AnyCanvas, DrawOptions, Point } from '../exports';\n\n/** draw detected hands */\nexport function hand(inCanvas: AnyCanvas, result: HandResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n ctx.font = localOptions.font;\n for (const h of result) {\n if (localOptions.drawBoxes) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n rect(ctx, h.box[0], h.box[1], h.box[2], h.box[3], localOptions);\n if (localOptions.drawLabels && (localOptions.handLabels?.length > 0)) {\n let l = localOptions.handLabels.slice();\n l = replace(l, '[id]', h.id.toFixed(0));\n l = replace(l, '[label]', h.label);\n l = replace(l, '[score]', 100 * h.score);\n labels(ctx, l, h.box[0], h.box[1], localOptions);\n }\n ctx.stroke();\n }\n if (localOptions.drawPoints) {\n if (h.keypoints && h.keypoints.length > 0) {\n for (const pt of h.keypoints) {\n ctx.fillStyle = colorDepth(pt[2], localOptions);\n point(ctx, pt[0], pt[1], 0, localOptions);\n }\n }\n }\n if (localOptions.drawLabels && h.annotations && (localOptions.fingerLabels?.length > 0)) {\n for (const [part, pt] of Object.entries(h.annotations)) {\n let l = localOptions.fingerLabels.slice();\n l = replace(l, '[label]', part);\n labels(ctx, l, pt[pt.length - 1][0], pt[pt.length - 1][1], localOptions);\n }\n }\n if (localOptions.drawPolygons && h.annotations) {\n const addHandLine = (part: Point[]) => {\n if (!part || part.length === 0 || !part[0]) return;\n for (let i = 0; i < part.length; i++) {\n ctx.beginPath();\n const z = part[i][2] || 0;\n ctx.strokeStyle = colorDepth(i * z, localOptions);\n ctx.moveTo(part[i > 0 ? i - 1 : 0][0], part[i > 0 ? i - 1 : 0][1]);\n ctx.lineTo(part[i][0], part[i][1]);\n ctx.stroke();\n }\n };\n ctx.lineWidth = localOptions.lineWidth;\n addHandLine(h.annotations.index);\n addHandLine(h.annotations.middle);\n addHandLine(h.annotations.ring);\n addHandLine(h.annotations.pinky);\n addHandLine(h.annotations.thumb);\n // addPart(h.annotations.palm);\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, rect, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { ObjectResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\n/** draw detected objects */\nexport function object(inCanvas: AnyCanvas, result: ObjectResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n ctx.font = localOptions.font;\n for (const h of result) {\n if (localOptions.drawBoxes) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n rect(ctx, h.box[0], h.box[1], h.box[2], h.box[3], localOptions);\n if (localOptions.drawLabels && (localOptions.objectLabels?.length > 0)) {\n let l = localOptions.objectLabels.slice();\n l = replace(l, '[id]', h.id.toFixed(0));\n l = replace(l, '[label]', h.label);\n l = replace(l, '[score]', 100 * h.score);\n labels(ctx, l, h.box[0], h.box[1], localOptions);\n }\n ctx.stroke();\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { GestureResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\n/** draw detected gestures */\nexport function gesture(inCanvas: AnyCanvas, result: GestureResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n if (localOptions.drawGestures && (localOptions.gestureLabels?.length > 0)) {\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.font = localOptions.font;\n ctx.fillStyle = localOptions.color;\n let i = 1;\n for (let j = 0; j < result.length; j++) {\n const [where, what] = Object.entries(result[j]);\n if ((what.length > 1) && ((what[1] as string).length > 0)) {\n const who = where[1] as number > 0 ? `#${where[1]}` : '';\n let l = localOptions.gestureLabels.slice();\n l = replace(l, '[where]', where[0]);\n l = replace(l, '[who]', who);\n l = replace(l, '[what]', what[1]);\n labels(ctx, l, 8, 2 + (i * localOptions.lineHeight), localOptions);\n i += 1;\n }\n }\n }\n}\n", "export const defaultLabels = {\n face: `face\n confidence: [score]%\n [gender] [genderScore]%\n age: [age] years\n distance: [distance]cm\n real: [real]%\n live: [live]%\n [emotions]\n roll: [roll]\u00B0 yaw:[yaw]\u00B0 pitch:[pitch]\u00B0\n gaze: [gaze]\u00B0`,\n body: 'body [score]%',\n bodyPart: '[label] [score]%',\n object: '[label] [score]%',\n hand: '[label] [score]%',\n finger: '[label]',\n gesture: '[where] [who]: [what]',\n};\n", "/* eslint-disable no-multi-spaces */\n\nexport const kpt: string[] = [\n 'nose', // 0\n 'leftEyeInside', // 1\n 'leftEye', // 2\n 'leftEyeOutside', // 3\n 'rightEyeInside', // 4\n 'rightEye', // 5\n 'rightEyeOutside', // 6\n 'leftEar', // 7\n 'rightEar', // 8\n 'leftMouth', // 9\n 'rightMouth', // 10\n 'leftShoulder', // 11\n 'rightShoulder', // 12\n 'leftElbow', // 13\n 'rightElbow', // 14\n 'leftWrist', // 15\n 'rightWrist', // 16\n 'leftPinky', // 17\n 'rightPinky', // 18\n 'leftIndex', // 19\n 'rightIndex', // 20\n 'leftThumb', // 21\n 'rightThumb', // 22\n 'leftHip', // 23\n 'rightHip', // 24\n 'leftKnee', // 25\n 'rightKnee', // 26\n 'leftAnkle', // 27\n 'rightAnkle', // 28\n 'leftHeel', // 29\n 'rightHeel', // 30\n 'leftFoot', // 31\n 'rightFoot', // 32\n 'bodyCenter', // 33\n 'bodyTop', // 34\n 'leftPalm', // 35 // z-coord not ok\n 'leftHand', // 36 // similar to wrist but z-coord not ok\n 'rightPalm', // 37 // z-coord not ok\n 'rightHand', // 38 // similar to wrist but z-coord not ok\n];\n\nexport const connected: Record = {\n shoulders: ['leftShoulder', 'rightShoulder'],\n hips: ['rightHip', 'leftHip'],\n mouth: ['leftMouth', 'rightMouth'],\n leftLegUpper: ['leftHip', 'leftKnee'],\n leftLegLower: ['leftKnee', 'leftAnkle'],\n leftFoot: ['leftAnkle', 'leftHeel', 'leftFoot'],\n leftTorso: ['leftShoulder', 'leftHip'],\n leftArmUpper: ['leftShoulder', 'leftElbow'],\n leftArmLower: ['leftElbow', 'leftWrist'],\n leftHand: ['leftWrist', 'leftPalm'],\n leftHandPinky: ['leftPalm', 'leftPinky'],\n leftHandIndex: ['leftPalm', 'leftIndex'],\n leftHandThumb: ['leftPalm', 'leftThumb'],\n leftEyeOutline: ['leftEyeInside', 'leftEyeOutside'],\n rightLegUpper: ['rightHip', 'rightKnee'],\n rightLegLower: ['rightKnee', 'rightAnkle'],\n rightFoot: ['rightAnkle', 'rightHeel', 'rightFoot'],\n rightTorso: ['rightShoulder', 'rightHip'],\n rightArmUpper: ['rightShoulder', 'rightElbow'],\n rightArmLower: ['rightElbow', 'rightWrist'],\n rightHand: ['rightWrist', 'rightPalm'],\n rightHandPinky: ['rightPalm', 'rightPinky'],\n rightHandIndex: ['rightPalm', 'rightIndex'],\n rightHandThumb: ['rightPalm', 'rightThumb'],\n rightEyeOutline: ['rightEyeInside', 'rightEyeOutside'],\n};\n", "import * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { env } from '../util/env';\nimport { loadModel } from '../tfjs/load';\nimport type { Box } from '../result';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor1D, Tensor2D } from '../tfjs/types';\n\nexport interface DetectedBox { box: Box, boxRaw: Box, score: number }\n\nlet model: GraphModel | null;\nlet inputSize = 224;\nlet anchorTensor: { x, y };\nconst numLayers = 5;\nconst strides = [8, 16, 32, 32, 32];\n\nexport function createAnchors() {\n const anchors: { x: number, y: number }[] = [];\n let layerId = 0;\n while (layerId < numLayers) {\n let anchorCount = 0;\n let lastSameStrideLayer = layerId;\n while (lastSameStrideLayer < strides.length && strides[lastSameStrideLayer] === strides[layerId]) {\n anchorCount += 2;\n lastSameStrideLayer++;\n }\n const stride = strides[layerId];\n const featureMapHeight = Math.ceil(inputSize / stride);\n const featureMapWidth = Math.ceil(inputSize / stride);\n for (let y = 0; y < featureMapHeight; ++y) {\n for (let x = 0; x < featureMapWidth; ++x) {\n for (let anchorId = 0; anchorId < anchorCount; ++anchorId) {\n anchors.push({ x: (x + 0.5) / featureMapWidth, y: (y + 0.5) / featureMapHeight });\n }\n }\n }\n layerId = lastSameStrideLayer;\n }\n anchorTensor = { x: tf.tensor1d(anchors.map((a) => a.x)), y: tf.tensor1d(anchors.map((a) => a.y)) };\n}\n\nexport async function loadDetector(config: Config): Promise {\n if (env.initial) model = null;\n if (!model && config.body['detector'] && config.body['detector'].modelPath || '') {\n model = await loadModel(config.body['detector'].modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n } else if (config.debug && model) log('cached model:', model['modelUrl']);\n createAnchors();\n return model as GraphModel;\n}\n\nconst cropFactor = [5.0, 5.0];\nexport function decodeBoxes(boxesTensor, anchor) {\n return tf.tidy(() => {\n const split = tf.split(boxesTensor, 12, 1); // first 4 are box data [x,y,w,h] and 4 are keypoints data [x,y] for total of 12\n let xCenter = tf.squeeze(split[0]);\n let yCenter = tf.squeeze(split[1]);\n let width = tf.squeeze(split[2]);\n let height = tf.squeeze(split[3]);\n xCenter = tf.add(tf.div(xCenter, inputSize), anchor.x);\n yCenter = tf.add(tf.div(yCenter, inputSize), anchor.y);\n width = tf.mul(tf.div(width, inputSize), cropFactor[0]);\n height = tf.mul(tf.div(height, inputSize), cropFactor[1]);\n const xMin = tf.sub(xCenter, tf.div(width, 2));\n const yMin = tf.sub(yCenter, tf.div(height, 2));\n const xMax = tf.add(xMin, width);\n const yMax = tf.add(yMin, height);\n const boxes = tf.stack([xMin, yMin, xMax, yMax], 1);\n return boxes;\n });\n}\n\nasync function decodeResults(boxesTensor: Tensor, logitsTensor: Tensor, config: Config, outputSize: [number, number]): Promise {\n const detectedBoxes: DetectedBox[] = [];\n const t: Record = {};\n t.boxes = decodeBoxes(boxesTensor, anchorTensor);\n t.scores = tf.sigmoid(logitsTensor);\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.scores as Tensor1D, 1, config.body['detector']?.minConfidence || 0.1, config.body['detector']?.iouThreshold || 0.1);\n const nms = await t.nms.data();\n const scores = await t.scores.data();\n const boxes = await t.boxes.array();\n for (const i of Array.from(nms)) {\n const score = scores[i];\n const boxRaw: Box = boxes[i];\n const box: Box = [Math.round(boxRaw[0] * outputSize[0]), Math.round(boxRaw[1] * outputSize[1]), Math.round(boxRaw[2] * outputSize[0]), Math.round(boxRaw[3] * outputSize[1])];\n const detectedBox: DetectedBox = { score, boxRaw, box };\n detectedBoxes.push(detectedBox);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return detectedBoxes;\n}\n\nexport async function detectBoxes(input: Tensor, config: Config, outputSize: [number, number]) {\n const t: Record = {};\n t.res = model?.execute(input, ['Identity']) as Tensor; //\n t.logitsRaw = tf.slice(t.res, [0, 0, 0], [1, -1, 1]);\n t.boxesRaw = tf.slice(t.res, [0, 0, 1], [1, -1, -1]);\n t.logits = tf.squeeze(t.logitsRaw);\n t.boxes = tf.squeeze(t.boxesRaw);\n const boxes = await decodeResults(t.boxes, t.logits, config, outputSize);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return boxes;\n}\n", "import type { Point, Box } from '../result';\n\nexport function calc(keypoints: Point[], outputSize: [number, number] = [1, 1]) {\n const coords = [keypoints.map((pt) => pt[0]), keypoints.map((pt) => pt[1])]; // all x/y coords\n const min = [Math.min(...coords[0]), Math.min(...coords[1])];\n const max = [Math.max(...coords[0]), Math.max(...coords[1])];\n const box: Box = [min[0], min[1], max[0] - min[0], max[1] - min[1]];\n const boxRaw: Box = [box[0] / outputSize[0], box[1] / outputSize[1], box[2] / outputSize[0], box[3] / outputSize[1]];\n return { box, boxRaw };\n}\n\nexport function square(keypoints: Point[], outputSize: [number, number] = [1, 1]) {\n const coords = [keypoints.map((pt) => pt[0]), keypoints.map((pt) => pt[1])]; // all x/y coords\n const min = [Math.min(...coords[0]), Math.min(...coords[1])];\n const max = [Math.max(...coords[0]), Math.max(...coords[1])];\n const center = [(min[0] + max[0]) / 2, (min[1] + max[1]) / 2]; // find center x and y coord of all fingers\n const dist = Math.max(center[0] - min[0], center[1] - min[1], -center[0] + max[0], -center[1] + max[1]); // largest distance from center in any direction\n const box: Box = [Math.trunc(center[0] - dist), Math.trunc(center[1] - dist), Math.trunc(2 * dist), Math.trunc(2 * dist)];\n const boxRaw: Box = [box[0] / outputSize[0], box[1] / outputSize[1], box[2] / outputSize[0], box[3] / outputSize[1]];\n return { box, boxRaw };\n}\n\nexport function scale(box: Box, scaleFact: number) {\n const dist = [box[2] * scaleFact, box[3] * scaleFact];\n const newBox: Box = [\n box[0] - (dist[0] - box[2]) / 2,\n box[1] - (dist[1] - box[3]) / 2,\n dist[0],\n dist[1],\n ];\n return newBox;\n}\n\nexport function crop(box: Box) { // [y1, x1, y2, x2] clamped to 0..1\n const yxBox: Box = [Math.max(0, box[1]), Math.max(0, box[0]), Math.min(1, box[3] + box[1]), Math.min(1, box[2] + box[0])];\n return yxBox;\n}\n", "/**\n * BlazePose model implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport { log, now } from '../util/util';\nimport type { BodyKeypoint, BodyResult, BodyLandmark, Box, Point, BodyAnnotation } from '../result';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport * as coords from './blazeposecoords';\nimport { loadDetector, detectBoxes, DetectedBox } from './blazeposedetector';\nimport * as box from '../util/box';\nimport { env } from '../util/env';\n\n// const models: [GraphModel | null, GraphModel | null] = [null, null];\nlet model: GraphModel | null;\nlet inputSize = 256;\nlet skipped = Number.MAX_SAFE_INTEGER;\nconst outputNodes: { detector: string[], landmarks: string[] } = {\n landmarks: ['ld_3d', 'activation_segmentation', 'activation_heatmap', 'world_3d', 'output_poseflag'],\n detector: [],\n};\n\nconst cache: BodyResult[] = [];\nlet padding: [number, number][] = [[0, 0], [0, 0], [0, 0], [0, 0]];\nlet lastTime = 0;\n\nconst sigmoid = (x) => (1 - (1 / (1 + Math.exp(x))));\n\nexport const loadDetect = (config: Config): Promise => loadDetector(config);\n\nexport async function loadPose(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n model = await loadModel(config.body.modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n } else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nfunction prepareImage(input: Tensor4D, size: number, cropBox?: Box): Tensor {\n const t: Record = {};\n if (!input?.shape?.[1] || !input?.shape?.[2]) return input;\n let final: Tensor;\n if (cropBox) {\n t.cropped = tf.image.cropAndResize(input, [cropBox], [0], [input.shape[1], input.shape[2]]); // if we have cached box use it to crop input\n }\n if (input.shape[1] !== input.shape[2]) { // only pad if width different than height\n const height: [number, number] = [\n input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0,\n input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0,\n ];\n const width: [number, number] = [\n input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0,\n input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0,\n ];\n padding = [\n [0, 0], // dont touch batch\n height, // height before&after\n width, // width before&after\n [0, 0], // dont touch rbg\n ];\n t.pad = tf.pad(t.cropped || input, padding); // use cropped box if it exists\n t.resize = tf.image.resizeBilinear(t.pad as Tensor4D, [size, size]);\n final = tf.div(t.resize, constants.tf255);\n } else if (input.shape[1] !== size) { // if input needs resizing\n t.resize = tf.image.resizeBilinear(t.cropped as Tensor4D || input, [size, size]);\n final = tf.div(t.resize, constants.tf255);\n } else { // if input is already in a correct resolution just normalize it\n final = tf.div(t.cropped || input, constants.tf255);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return final;\n}\n\nfunction rescaleKeypoints(keypoints: BodyKeypoint[], outputSize: [number, number], cropBox?: Box): BodyKeypoint[] {\n for (const kpt of keypoints) { // first rescale due to padding\n kpt.position = [\n Math.trunc(kpt.position[0] * (outputSize[0] + padding[2][0] + padding[2][1]) / outputSize[0] - padding[2][0]),\n Math.trunc(kpt.position[1] * (outputSize[1] + padding[1][0] + padding[1][1]) / outputSize[1] - padding[1][0]),\n kpt.position[2] as number,\n ];\n kpt.positionRaw = [kpt.position[0] / outputSize[0], kpt.position[1] / outputSize[1], 2 * (kpt.position[2] as number) / (outputSize[0] + outputSize[1])];\n }\n if (cropBox) { // second rescale due to cropping\n const width = cropBox[2] - cropBox[0];\n const height = cropBox[3] - cropBox[1];\n for (const kpt of keypoints) {\n kpt.positionRaw = [\n kpt.positionRaw[0] / height + cropBox[1], // correct offset due to crop\n kpt.positionRaw[1] / width + cropBox[0], // correct offset due to crop\n kpt.positionRaw[2] as number,\n ];\n kpt.position = [\n Math.trunc(kpt.positionRaw[0] * outputSize[0]),\n Math.trunc(kpt.positionRaw[1] * outputSize[1]),\n kpt.positionRaw[2] as number,\n ];\n }\n }\n return keypoints;\n}\n\nfunction fixKeypoints(keypoints: BodyKeypoint[]) {\n // palm z-coord is incorrect around near-zero so we approximate it\n const leftPalm = keypoints.find((k) => k.part === 'leftPalm') as BodyKeypoint;\n const leftWrist = keypoints.find((k) => k.part === 'leftWrist') as BodyKeypoint;\n const leftIndex = keypoints.find((k) => k.part === 'leftIndex') as BodyKeypoint;\n leftPalm.position[2] = ((leftWrist.position[2] || 0) + (leftIndex.position[2] || 0)) / 2;\n const rightPalm = keypoints.find((k) => k.part === 'rightPalm') as BodyKeypoint;\n const rightWrist = keypoints.find((k) => k.part === 'rightWrist') as BodyKeypoint;\n const rightIndex = keypoints.find((k) => k.part === 'rightIndex') as BodyKeypoint;\n rightPalm.position[2] = ((rightWrist.position[2] || 0) + (rightIndex.position[2] || 0)) / 2;\n}\n\nasync function detectLandmarks(input: Tensor, config: Config, outputSize: [number, number]): Promise {\n /**\n * t.ld: 39 keypoints [x,y,z,score,presence] normalized to input size\n * t.segmentation:\n * t.heatmap:\n * t.world: 39 keypoints [x,y,z] normalized to -1..1\n * t.poseflag: body score\n */\n if (!model?.['executor']) return null;\n const t: Record = {};\n [t.ld/* 1,195(39*5) */, t.segmentation/* 1,256,256,1 */, t.heatmap/* 1,64,64,39 */, t.world/* 1,117(39*3) */, t.poseflag/* 1,1 */] = model?.execute(input, outputNodes.landmarks) as Tensor[]; // run model\n const poseScore = (await t.poseflag.data())[0];\n const points = await t.ld.data();\n const distances = await t.world.data();\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor])); // dont need tensors after this\n const keypointsRelative: BodyKeypoint[] = [];\n const depth = 5; // each points has x,y,z,visibility,presence\n for (let i = 0; i < points.length / depth; i++) {\n const score = sigmoid(points[depth * i + 3]);\n const presence = sigmoid(points[depth * i + 4]);\n const adjScore = Math.trunc(100 * score * presence * poseScore) / 100;\n const positionRaw: Point = [points[depth * i + 0] / inputSize, points[depth * i + 1] / inputSize, points[depth * i + 2] + 0];\n const position: Point = [Math.trunc(outputSize[0] * positionRaw[0]), Math.trunc(outputSize[1] * positionRaw[1]), positionRaw[2] as number];\n const distance: Point = [distances[depth * i + 0], distances[depth * i + 1], distances[depth * i + 2] + 0];\n keypointsRelative.push({ part: coords.kpt[i] as BodyLandmark, positionRaw, position, distance, score: adjScore });\n }\n if (poseScore < (config.body.minConfidence || 0)) return null;\n fixKeypoints(keypointsRelative);\n const keypoints: BodyKeypoint[] = rescaleKeypoints(keypointsRelative, outputSize); // keypoints were relative to input image which is padded\n const kpts = keypoints.map((k) => k.position);\n const boxes = box.calc(kpts, [outputSize[0], outputSize[1]]); // now find boxes based on rescaled keypoints\n const annotations: Record = {} as Record;\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = keypoints.find((kpt) => kpt.part === indexes[i]);\n const pt1 = keypoints.find((kpt) => kpt.part === indexes[i + 1]);\n if (pt0 && pt1) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n const body = { id: 0, score: Math.trunc(100 * poseScore) / 100, box: boxes.box, boxRaw: boxes.boxRaw, keypoints, annotations };\n return body;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n const outputSize: [number, number] = [input.shape[2] || 0, input.shape[1] || 0];\n const skipTime = (config.body.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.body.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && cache !== null) {\n skipped++;\n } else {\n let boxes: DetectedBox[] = [];\n if (config.body?.['detector']?.['enabled']) {\n const preparedImage = prepareImage(input, 224);\n boxes = await detectBoxes(preparedImage, config, outputSize);\n tf.dispose(preparedImage);\n } else {\n boxes = [{ box: [0, 0, 0, 0] as Box, boxRaw: [0, 0, 1, 1], score: 0 }]; // running without detector\n }\n for (let i = 0; i < boxes.length; i++) {\n const preparedBox = prepareImage(input, 256, boxes[i]?.boxRaw); // padded and resized\n cache.length = 0;\n const bodyResult = await detectLandmarks(preparedBox, config, outputSize);\n tf.dispose(preparedBox);\n if (!bodyResult) continue;\n bodyResult.id = i;\n // bodyResult.score = 0; // TBD\n cache.push(bodyResult);\n }\n /*\n cropBox = [0, 0, 1, 1]; // reset crop coordinates\n if (cache?.boxRaw && config.skipAllowed) {\n const cx = (2.0 * cache.boxRaw[0] + cache.boxRaw[2]) / 2;\n const cy = (2.0 * cache.boxRaw[1] + cache.boxRaw[3]) / 2;\n let size = cache.boxRaw[2] > cache.boxRaw[3] ? cache.boxRaw[2] : cache.boxRaw[3];\n size = (size * 1.0) / 2; // enlarge and half it\n if (cx > 0.1 && cx < 0.9 && cy > 0.1 && cy < 0.9 && size > 0.1) { // only update if box is sane\n const y = 0; // cy - size;\n const x = cx - size;\n cropBox = [y, x, y + 1, x + 1]; // [y0,x0,y1,x1] used for cropping but width/height are not yet implemented so we only reposition image to center of body\n }\n }\n */\n lastTime = now();\n skipped = 0;\n }\n return cache;\n}\n", "/**\n * CoCo Labels used by object detection implementations\n */\nexport const labels = [\n { class: 1, label: 'person' },\n { class: 2, label: 'bicycle' },\n { class: 3, label: 'car' },\n { class: 4, label: 'motorcycle' },\n { class: 5, label: 'airplane' },\n { class: 6, label: 'bus' },\n { class: 7, label: 'train' },\n { class: 8, label: 'truck' },\n { class: 9, label: 'boat' },\n { class: 10, label: 'traffic light' },\n { class: 11, label: 'fire hydrant' },\n { class: 12, label: 'stop sign' },\n { class: 13, label: 'parking meter' },\n { class: 14, label: 'bench' },\n { class: 15, label: 'bird' },\n { class: 16, label: 'cat' },\n { class: 17, label: 'dog' },\n { class: 18, label: 'horse' },\n { class: 19, label: 'sheep' },\n { class: 20, label: 'cow' },\n { class: 21, label: 'elephant' },\n { class: 22, label: 'bear' },\n { class: 23, label: 'zebra' },\n { class: 24, label: 'giraffe' },\n { class: 25, label: 'backpack' },\n { class: 26, label: 'umbrella' },\n { class: 27, label: 'handbag' },\n { class: 28, label: 'tie' },\n { class: 29, label: 'suitcase' },\n { class: 30, label: 'frisbee' },\n { class: 31, label: 'skis' },\n { class: 32, label: 'snowboard' },\n { class: 33, label: 'sports ball' },\n { class: 34, label: 'kite' },\n { class: 35, label: 'baseball bat' },\n { class: 36, label: 'baseball glove' },\n { class: 37, label: 'skateboard' },\n { class: 38, label: 'surfboard' },\n { class: 39, label: 'tennis racket' },\n { class: 40, label: 'bottle' },\n { class: 41, label: 'wine glass' },\n { class: 42, label: 'cup' },\n { class: 43, label: 'fork' },\n { class: 44, label: 'knife' },\n { class: 45, label: 'spoon' },\n { class: 46, label: 'bowl' },\n { class: 47, label: 'banana' },\n { class: 48, label: 'apple' },\n { class: 49, label: 'sandwich' },\n { class: 50, label: 'orange' },\n { class: 51, label: 'broccoli' },\n { class: 52, label: 'carrot' },\n { class: 53, label: 'hot dog' },\n { class: 54, label: 'pizza' },\n { class: 55, label: 'donut' },\n { class: 56, label: 'cake' },\n { class: 57, label: 'chair' },\n { class: 58, label: 'couch' },\n { class: 59, label: 'potted plant' },\n { class: 60, label: 'bed' },\n { class: 61, label: 'dining table' },\n { class: 62, label: 'toilet' },\n { class: 63, label: 'tv' },\n { class: 64, label: 'laptop' },\n { class: 65, label: 'mouse' },\n { class: 66, label: 'remote' },\n { class: 67, label: 'keyboard' },\n { class: 68, label: 'cell phone' },\n { class: 69, label: 'microwave' },\n { class: 70, label: 'oven' },\n { class: 71, label: 'toaster' },\n { class: 72, label: 'sink' },\n { class: 73, label: 'refrigerator' },\n { class: 74, label: 'book' },\n { class: 75, label: 'clock' },\n { class: 76, label: 'vase' },\n { class: 77, label: 'scissors' },\n { class: 78, label: 'teddy bear' },\n { class: 79, label: 'hair drier' },\n { class: 80, label: 'toothbrush' },\n];\n", "/**\n * CenterNet object detection model implementation\n *\n * Based on: [**MB3-CenterNet**](https://github.com/610265158/mobilenetv3_centernet)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { labels } from './labels';\nimport type { ObjectResult, ObjectType, Box } from '../result';\nimport type { GraphModel, Tensor, Tensor1D, Tensor2D, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nlet inputSize = 0;\nlet last: ObjectResult[] = [];\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n // fakeOps(['floormod'], config);\n model = await loadModel(config.object.modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 0;\n } else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nasync function process(res: Tensor | null, outputShape: [number, number], config: Config) {\n if (!res) return [];\n const t: Record = {};\n const results: ObjectResult[] = [];\n const detections = await res.array() as number[][][];\n t.squeeze = tf.squeeze(res);\n const arr = tf.split(t.squeeze, 6, 1); // x1, y1, x2, y2, score, class\n t.stack = tf.stack([arr[1], arr[0], arr[3], arr[2]], 1); // reorder dims as tf.nms expects y, x\n t.boxes = tf.squeeze(t.stack);\n t.scores = tf.squeeze(arr[4]);\n t.classes = tf.squeeze(arr[5]);\n tf.dispose([res, ...arr]);\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.scores as Tensor1D, config.object.maxDetected || 0, config.object.iouThreshold, (config.object.minConfidence || 0));\n const nms = await t.nms.data();\n let i = 0;\n for (const id of Array.from(nms)) {\n const score = Math.trunc(100 * detections[0][id][4]) / 100;\n const classVal = detections[0][id][5];\n if (Number.isNaN(classVal)) continue;\n const label = labels[classVal].label as ObjectType;\n const [x, y] = [\n detections[0][id][0] / inputSize,\n detections[0][id][1] / inputSize,\n ];\n const boxRaw: Box = [\n x,\n y,\n detections[0][id][2] / inputSize - x,\n detections[0][id][3] / inputSize - y,\n ];\n const box: Box = [\n Math.trunc(boxRaw[0] * outputShape[0]),\n Math.trunc(boxRaw[1] * outputShape[1]),\n Math.trunc(boxRaw[2] * outputShape[0]),\n Math.trunc(boxRaw[3] * outputShape[1]),\n ];\n results.push({ id: i++, score, class: classVal, label, box, boxRaw });\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return results;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model?.['executor']) return [];\n const skipTime = (config.object.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.object.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (last.length > 0)) {\n skipped++;\n return last;\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const outputSize = [input.shape[2] || 0, input.shape[1] || 0] as [number, number];\n const resize = tf.image.resizeBilinear(input, [inputSize, inputSize]);\n const objectT = config.object.enabled ? model?.execute(resize, ['tower_0/detections']) as Tensor : null;\n lastTime = now();\n tf.dispose(resize);\n\n const obj = await process(objectT, outputSize, config);\n last = obj;\n\n resolve(obj);\n });\n}\n", "export const kpt: string[] = [\n 'head',\n 'neck',\n 'rightShoulder',\n 'rightElbow',\n 'rightWrist',\n 'chest',\n 'leftShoulder',\n 'leftElbow',\n 'leftWrist',\n 'bodyCenter',\n 'rightHip',\n 'rightKnee',\n 'rightAnkle',\n 'leftHip',\n 'leftKnee',\n 'leftAnkle',\n];\n\nexport const connected: Record = {\n leftLeg: ['leftHip', 'leftKnee', 'leftAnkle'],\n rightLeg: ['rightHip', 'rightKnee', 'rightAnkle'],\n torso: ['leftShoulder', 'rightShoulder', 'rightHip', 'leftHip', 'leftShoulder'],\n leftArm: ['leftShoulder', 'leftElbow', 'leftWrist'],\n rightArm: ['rightShoulder', 'rightElbow', 'rightWrist'],\n head: [],\n};\n", "/**\n * EfficientPose model implementation\n *\n * Based on: [**EfficientPose**](https://github.com/daniegr/EfficientPose)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport * as coords from './efficientposecoords';\nimport { constants } from '../tfjs/constants';\nimport type { BodyResult, Point, BodyLandmark, BodyAnnotation } from '../result';\nimport type { GraphModel, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nlet lastTime = 0;\nconst cache: BodyResult = { id: 0, keypoints: [], box: [0, 0, 0, 0], boxRaw: [0, 0, 0, 0], score: 0, annotations: {} as Record };\n\n// const keypoints: Array = [];\n// let box: Box = [0, 0, 0, 0];\n// let boxRaw: Box = [0, 0, 0, 0];\n// let score = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.body.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\n// performs argmax and max functions on a 2d tensor\nasync function max2d(inputs, minScore): Promise<[number, number, number]> {\n const [width, height] = inputs.shape;\n const reshaped = tf.reshape(inputs, [height * width]); // combine all data\n const max = tf.max(reshaped, 0);\n const newScore: number = (await max.data())[0]; // get highest score\n if (newScore > minScore) { // skip coordinate calculation is score is too low\n const coordinates = tf.argMax(reshaped, 0);\n const mod = tf.mod(coordinates, width);\n const x = (await mod.data())[0];\n const div = tf.div(coordinates, width);\n const y: number = (await div.data())[0];\n tf.dispose([reshaped, max, coordinates, mod, div]);\n return [x, y, newScore];\n }\n tf.dispose([reshaped, max]);\n return [0, 0, newScore];\n}\n\nexport async function predict(image: Tensor4D, config: Config): Promise {\n if (!model?.['executor'] || !model?.inputs[0].shape) return [];\n const skipTime = (config.body.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.body.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && Object.keys(cache.keypoints).length > 0) {\n skipped++;\n return [cache];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const tensor = tf.tidy(() => {\n const resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape?.[2] || 0, model?.inputs[0].shape?.[1] || 0], false);\n const enhance = tf.mul(resize, constants.tf2);\n const norm = tf.sub(enhance, constants.tf1);\n return norm;\n });\n let resT;\n if (config.body.enabled) resT = model?.execute(tensor);\n lastTime = now();\n tf.dispose(tensor);\n\n if (resT) {\n cache.keypoints.length = 0;\n const squeeze = tf.squeeze(resT);\n tf.dispose(resT);\n // body parts are basically just a stack of 2d tensors\n const stack = tf.unstack(squeeze, 2);\n tf.dispose(squeeze);\n\n // process each unstacked tensor as a separate body part\n for (let id = 0; id < stack.length; id++) {\n // actual processing to get coordinates and score\n const [x, y, partScore] = await max2d(stack[id], config.body.minConfidence);\n if (partScore > (config.body.minConfidence || 0)) {\n cache.keypoints.push({\n score: Math.round(100 * partScore) / 100,\n part: coords.kpt[id] as BodyLandmark,\n positionRaw: [ // normalized to 0..1\n // @ts-ignore model is not undefined here\n x / model.inputs[0].shape[2], y / model.inputs[0].shape[1],\n ],\n position: [ // normalized to input image size\n // @ts-ignore model is not undefined here\n Math.round(image.shape[2] * x / model.inputs[0].shape[2]), Math.round(image.shape[1] * y / model.inputs[0].shape[1]),\n ],\n });\n }\n }\n stack.forEach((s) => tf.dispose(s));\n }\n cache.score = cache.keypoints.reduce((prev, curr) => (curr.score > prev ? curr.score : prev), 0);\n const x = cache.keypoints.map((a) => a.position[0]);\n const y = cache.keypoints.map((a) => a.position[1]);\n cache.box = [\n Math.min(...x),\n Math.min(...y),\n Math.max(...x) - Math.min(...x),\n Math.max(...y) - Math.min(...y),\n ];\n const xRaw = cache.keypoints.map((a) => a.positionRaw[0]);\n const yRaw = cache.keypoints.map((a) => a.positionRaw[1]);\n cache.boxRaw = [\n Math.min(...xRaw),\n Math.min(...yRaw),\n Math.max(...xRaw) - Math.min(...xRaw),\n Math.max(...yRaw) - Math.min(...yRaw),\n ];\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = cache.keypoints.find((kpt) => kpt.part === indexes[i]);\n const pt1 = cache.keypoints.find((kpt) => kpt.part === indexes[i + 1]);\n if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n }\n cache.annotations[name] = pt;\n }\n resolve([cache]);\n });\n}\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n * See `facemesh.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as coords from './facemeshcoords';\nimport { constants } from '../tfjs/constants';\nimport type { Box, Point } from '../result';\nimport { env } from '../util/env';\n\nexport const createBox = (startEndTensor) => ({ startPoint: tf.slice(startEndTensor, [0, 0], [-1, 2]), endPoint: tf.slice(startEndTensor, [0, 2], [-1, 2]) });\n\nexport const disposeBox = (t) => tf.dispose([t.startPoint, t.endPoint]);\n\nexport const getBoxSize = (box): [number, number] => [Math.abs(box.endPoint[0] - box.startPoint[0]), Math.abs(box.endPoint[1] - box.startPoint[1])];\n\nexport const getBoxCenter = (box): [number, number, number] => [box.startPoint[0] + (box.endPoint[0] - box.startPoint[0]) / 2, box.startPoint[1] + (box.endPoint[1] - box.startPoint[1]) / 2, 1];\n\nexport const clampBox = (box, input): Box => (box ? [\n Math.trunc(Math.max(0, box.startPoint[0])),\n Math.trunc(Math.max(0, box.startPoint[1])),\n Math.trunc(Math.min((input.shape[2] || 0), box.endPoint[0]) - Math.max(0, box.startPoint[0])),\n Math.trunc(Math.min((input.shape[1] || 0), box.endPoint[1]) - Math.max(0, box.startPoint[1])),\n] : [0, 0, 0, 0]);\n\nexport const getRawBox = (box, input): Box => (box ? [\n box.startPoint[0] / (input.shape[2] || 0),\n box.startPoint[1] / (input.shape[1] || 0),\n (box.endPoint[0] - box.startPoint[0]) / (input.shape[2] || 0),\n (box.endPoint[1] - box.startPoint[1]) / (input.shape[1] || 0),\n] : [0, 0, 0, 0]);\n\nexport const scaleBoxCoordinates = (box, factor, anchor) => {\n const startPoint: Point = [box.startPoint[0] * factor[0], box.startPoint[1] * factor[1]];\n const endPoint: Point = [box.endPoint[0] * factor[0], box.endPoint[1] * factor[1]];\n // const centerPoint = [(startPoint[0] + endPoint[0]) / 2, (startPoint[1] + endPoint[1]) / 2];\n const landmarks = box.landmarks.map((pt) => [(pt[0] + anchor[0]) * factor[0], (pt[1] + anchor[1]) * factor[1]]);\n /**\n face.mesh = box.landmarks.map((pt) => [\n ((box.startPoint[0] + box.endPoint[0]) / 2) + (pt[0] * input.shape[2] / blazeface.size()),\n ((box.startPoint[1] + box.endPoint[1]) / 2) + (pt[1] * input.shape[1] / blazeface.size()),\n ]);\n */\n\n return { startPoint, endPoint, landmarks, confidence: box.confidence };\n};\n\nexport const cutAndResize = (box, image, cropSize) => {\n const h = image.shape[1];\n const w = image.shape[2];\n const cutBox = [box.startPoint[1] / h, box.startPoint[0] / w, box.endPoint[1] / h, box.endPoint[0] / w];\n const crop = tf.image.cropAndResize(image, [cutBox], [0], cropSize);\n const norm = tf.div(crop, constants.tf255);\n tf.dispose(crop);\n return norm;\n};\n\nexport const enlargeBox = (box, factor) => {\n const center = getBoxCenter(box);\n const size = getBoxSize(box);\n const halfSize: [number, number] = [factor * size[0] / 2, factor * size[1] / 2];\n return {\n startPoint: [center[0] - halfSize[0], center[1] - halfSize[1]] as Point,\n endPoint: [center[0] + halfSize[0], center[1] + halfSize[1]] as Point,\n landmarks: box.landmarks,\n confidence: box.confidence,\n size,\n };\n};\n\nexport const squarifyBox = (box) => {\n const centers = getBoxCenter(box);\n const size = getBoxSize(box);\n const halfSize = Math.max(...size) / 2;\n return {\n startPoint: [Math.round(centers[0] - halfSize), Math.round(centers[1] - halfSize)] as Point,\n endPoint: [Math.round(centers[0] + halfSize), Math.round(centers[1] + halfSize)] as Point,\n landmarks: box.landmarks,\n confidence: box.confidence,\n size: [Math.round(size[0]), Math.round(size[1])] as [number, number],\n };\n};\n\nexport const calculateLandmarksBoundingBox = (landmarks) => {\n const x = landmarks.map((d) => d[0]);\n const y = landmarks.map((d) => d[1]);\n return {\n startPoint: [Math.min(...x), Math.min(...y)] as Point,\n endPoint: [Math.max(...x), Math.max(...y)] as Point,\n landmarks,\n };\n};\n\nexport const fixedRotationMatrix = [[1, 0, 0], [0, 1, 0], [0, 0, 1]];\n\nexport const normalizeRadians = (angle: number) => angle - 2 * Math.PI * Math.floor((angle + Math.PI) / (2 * Math.PI));\n\nexport const computeRotation = (point1, point2) => normalizeRadians(Math.PI / 2 - Math.atan2(-(point2[1] - point1[1]), point2[0] - point1[0]));\n\nexport const radToDegrees = (rad) => rad * 180 / Math.PI;\n\nexport const buildTranslationMatrix = (x, y) => [[1, 0, x], [0, 1, y], [0, 0, 1]];\n\nexport const dot = (v1: number[], v2: number[]) => {\n let product = 0;\n for (let i = 0; i < v1.length; i++) product += v1[i] * v2[i];\n return product;\n};\n\nexport const getColumnFrom2DArr = (arr, columnIndex) => {\n const column: number[] = [];\n for (let i = 0; i < arr.length; i++) column.push(arr[i][columnIndex]);\n return column;\n};\n\nexport const multiplyTransformMatrices = (mat1, mat2) => {\n const product: number[][] = [];\n const size = mat1.length;\n for (let row = 0; row < size; row++) {\n product.push([]);\n for (let col = 0; col < size; col++) product[row].push(dot(mat1[row], getColumnFrom2DArr(mat2, col)));\n }\n return product;\n};\n\nexport const buildRotationMatrix = (rotation, center) => {\n const cosA = Math.cos(rotation);\n const sinA = Math.sin(rotation);\n const rotationMatrix = [[cosA, -sinA, 0], [sinA, cosA, 0], [0, 0, 1]];\n const translationMatrix = buildTranslationMatrix(center[0], center[1]);\n const translationTimesRotation = multiplyTransformMatrices(translationMatrix, rotationMatrix);\n const negativeTranslationMatrix = buildTranslationMatrix(-center[0], -center[1]);\n return multiplyTransformMatrices(translationTimesRotation, negativeTranslationMatrix);\n};\n\nexport const invertTransformMatrix = (matrix) => {\n const rotationComponent = [[matrix[0][0], matrix[1][0]], [matrix[0][1], matrix[1][1]]];\n const translationComponent = [matrix[0][2], matrix[1][2]];\n const invertedTranslation = [-dot(rotationComponent[0], translationComponent), -dot(rotationComponent[1], translationComponent)];\n return [rotationComponent[0].concat(invertedTranslation[0]), rotationComponent[1].concat(invertedTranslation[1]), [0, 0, 1]];\n};\n\nexport const rotatePoint = (homogeneousCoordinate, rotationMatrix) => [dot(homogeneousCoordinate, rotationMatrix[0]), dot(homogeneousCoordinate, rotationMatrix[1])];\n\nexport const xyDistanceBetweenPoints = (a, b) => Math.sqrt(((a[0] - b[0]) ** 2) + ((a[1] - b[1]) ** 2));\n\nexport function generateAnchors(inputSize: number) {\n const spec = inputSize === 192\n ? { strides: [4], anchors: [1] } // facemesh-detector\n : { strides: [inputSize / 16, inputSize / 8], anchors: [2, 6] }; // blazeface\n const anchors: [number, number][] = [];\n for (let i = 0; i < spec.strides.length; i++) {\n const stride = spec.strides[i];\n const gridRows = Math.floor((inputSize + stride - 1) / stride);\n const gridCols = Math.floor((inputSize + stride - 1) / stride);\n const anchorsNum = spec.anchors[i];\n for (let gridY = 0; gridY < gridRows; gridY++) {\n const anchorY = stride * (gridY + 0.5);\n for (let gridX = 0; gridX < gridCols; gridX++) {\n const anchorX = stride * (gridX + 0.5);\n for (let n = 0; n < anchorsNum; n++) anchors.push([anchorX, anchorY]);\n }\n }\n }\n return anchors;\n}\n\nexport function transformRawCoords(coordsRaw, box, angle, rotationMatrix, inputSize) {\n const boxSize = getBoxSize(box);\n const coordsScaled = coordsRaw.map((coord) => ([ // scaled around zero-point\n (boxSize[0] / inputSize) * (coord[0] - (inputSize / 2)),\n (boxSize[1] / inputSize) * (coord[1] - (inputSize / 2)),\n (coord[2] || 0),\n ]));\n const largeAngle = angle && (angle !== 0) && (Math.abs(angle) > 0.2);\n const coordsRotationMatrix = largeAngle ? buildRotationMatrix(angle, [0, 0]) : fixedRotationMatrix;\n const coordsRotated = largeAngle ? coordsScaled.map((coord) => ([...rotatePoint(coord, coordsRotationMatrix), coord[2]])) : coordsScaled;\n const inverseRotationMatrix = largeAngle ? invertTransformMatrix(rotationMatrix) : fixedRotationMatrix;\n const boxCenter = getBoxCenter(box);\n const offsets = [dot(boxCenter, inverseRotationMatrix[0]), dot(boxCenter, inverseRotationMatrix[1])];\n return coordsRotated.map((coord) => ([\n Math.trunc(coord[0] + offsets[0]),\n Math.trunc(coord[1] + offsets[1]),\n Math.trunc(coord[2] || 0),\n ]));\n}\n\nexport function correctFaceRotation(rotate, box, input, inputSize) {\n const symmetryLine = (box.landmarks.length >= coords.meshLandmarks.count)\n ? coords.meshLandmarks.symmetryLine\n : coords.blazeFaceLandmarks.symmetryLine;\n let angle = 0; // default\n let rotationMatrix = fixedRotationMatrix; // default\n let face; // default\n\n if (rotate && env.kernels.includes('rotatewithoffset')) {\n angle = computeRotation(box.landmarks[symmetryLine[0]], box.landmarks[symmetryLine[1]]);\n const largeAngle = angle && (angle !== 0) && (Math.abs(angle) > 0.2);\n if (largeAngle) { // perform rotation only if angle is sufficiently high\n const center: Point = getBoxCenter(box);\n const centerRaw: Point = [center[0] / input.shape[2], center[1] / input.shape[1]];\n const rotated = tf.image.rotateWithOffset(input, angle, 0, [centerRaw[0], centerRaw[1]]);\n rotationMatrix = buildRotationMatrix(-angle, center);\n face = cutAndResize(box, rotated, [inputSize, inputSize]);\n tf.dispose(rotated);\n } else {\n face = cutAndResize(box, input, [inputSize, inputSize]);\n }\n } else {\n face = cutAndResize(box, input, [inputSize, inputSize]);\n }\n return [angle, rotationMatrix, face];\n}\n\nexport const findFaceCenter = (mesh) => {\n const x = mesh.map((m) => m[0]);\n const y = mesh.map((m) => m[1]);\n // weighted center\n /*\n const sum = (arr: number[]) => arr.reduce((prev, curr) => prev + curr, 0);\n return [sum(x) / mesh.length, sum(y) / mesh.length];\n */\n // absolute center\n return [Math.min(...x) + (Math.max(...x) - Math.min(...x)) / 2, Math.min(...y) + (Math.max(...y) - Math.min(...y)) / 2];\n};\n\nexport const calculateFaceBox = (mesh, previousBox) => {\n const center = findFaceCenter(mesh);\n const boxSize = getBoxSize(previousBox);\n const calculatedBox = {\n startPoint: [center[0] - boxSize[0] / 2, center[1] - boxSize[1] / 2] as Point,\n endPoint: [center[0] + boxSize[0] / 2, center[1] + boxSize[1] / 2] as Point,\n };\n return calculatedBox;\n};\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n * See `facemesh.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport * as util from './facemeshutil';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { Config } from '../config';\nimport type { Tensor, GraphModel, Tensor1D, Tensor2D, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\nimport type { Point } from '../result';\n\nconst keypointsCount = 6;\nconst faceBoxScaleFactor = 1.4;\nlet model: GraphModel | null;\nlet anchors: Tensor | null = null;\nlet inputSize = 0;\nlet inputSizeT: Tensor | null = null;\n\nexport interface DetectBox { startPoint: Point, endPoint: Point, landmarks: Point[], confidence: number, size: [number, number] }\n\nexport const size = () => inputSize;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.detector?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n inputSize = (model['executor'] && model.inputs[0].shape) ? model.inputs[0].shape[2] : 256;\n inputSizeT = tf.scalar(inputSize, 'int32') as Tensor;\n anchors = tf.tensor2d(util.generateAnchors(inputSize)) as Tensor;\n return model;\n}\n\nfunction decodeBoxes(boxOutputs: Tensor) {\n if (!anchors || !inputSizeT) return tf.zeros([0, 0]);\n const t: Record = {};\n t.boxStarts = tf.slice(boxOutputs, [0, 1], [-1, 2]);\n t.centers = tf.add(t.boxStarts, anchors);\n t.boxSizes = tf.slice(boxOutputs, [0, 3], [-1, 2]);\n t.boxSizesNormalized = tf.div(t.boxSizes, inputSizeT);\n t.centersNormalized = tf.div(t.centers, inputSizeT);\n t.halfBoxSize = tf.div(t.boxSizesNormalized, constants.tf2);\n t.starts = tf.sub(t.centersNormalized, t.halfBoxSize);\n t.ends = tf.add(t.centersNormalized, t.halfBoxSize);\n t.startNormalized = tf.mul(t.starts, inputSizeT);\n t.endNormalized = tf.mul(t.ends, inputSizeT);\n const boxes = tf.concat2d([t.startNormalized as Tensor2D, t.endNormalized as Tensor2D], 1);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return boxes;\n}\n\nexport async function getBoxes(inputImage: Tensor4D, config: Config): Promise {\n // sanity check on input\n if ((!inputImage) || (inputImage['isDisposedInternal']) || (inputImage.shape.length !== 4) || (inputImage.shape[1] < 1) || (inputImage.shape[2] < 1)) return [];\n const t: Record = {};\n t.resized = tf.image.resizeBilinear(inputImage, [inputSize, inputSize]);\n t.div = tf.div(t.resized, constants.tf127);\n t.normalized = tf.sub(t.div, constants.tf05);\n const res = model?.execute(t.normalized) as Tensor[];\n if (Array.isArray(res) && res.length > 2) { // pinto converted model?\n const sorted = res.sort((a, b) => a.size - b.size);\n t.concat384 = tf.concat([sorted[0], sorted[2]], 2); // dim: 384, 1 + 16\n t.concat512 = tf.concat([sorted[1], sorted[3]], 2); // dim: 512, 1 + 16\n t.concat = tf.concat([t.concat512, t.concat384], 1);\n t.batch = tf.squeeze(t.concat, [0]);\n } else if (Array.isArray(res)) { // new facemesh-detection tfhub model\n t.batch = tf.squeeze(res[0]);\n } else { // original blazeface tfhub model\n t.batch = tf.squeeze(res);\n }\n tf.dispose(res);\n t.boxes = decodeBoxes(t.batch);\n t.logits = tf.slice(t.batch, [0, 0], [-1, 1]);\n t.sigmoid = tf.sigmoid(t.logits);\n t.scores = tf.squeeze(t.sigmoid);\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.scores as Tensor1D, (config.face.detector?.maxDetected || 0), (config.face.detector?.iouThreshold || 0), (config.face.detector?.minConfidence || 0));\n const nms = await t.nms.array() as number[];\n const boxes: DetectBox[] = [];\n const scores = await t.scores.data();\n for (let i = 0; i < nms.length; i++) {\n const confidence = scores[nms[i]];\n\n if (confidence > (config.face.detector?.minConfidence || 0)) {\n const b: Record = {};\n b.bbox = tf.slice(t.boxes, [nms[i], 0], [1, -1]);\n b.slice = tf.slice(t.batch, [nms[i], keypointsCount - 1], [1, -1]);\n b.squeeze = tf.squeeze(b.slice);\n b.landmarks = tf.reshape(b.squeeze, [keypointsCount, -1]);\n const points = await b.bbox.data();\n const rawBox = {\n startPoint: [points[0], points[1]] as Point,\n endPoint: [points[2], points[3]] as Point,\n landmarks: (await b.landmarks.array()) as Point[],\n confidence,\n };\n b.anchor = tf.slice(anchors as Tensor, [nms[i], 0], [1, 2]);\n const anchor = await b.anchor.data();\n const scaledBox = util.scaleBoxCoordinates(rawBox, [(inputImage.shape[2] || 0) / inputSize, (inputImage.shape[1] || 0) / inputSize], anchor);\n const enlargedBox = util.enlargeBox(scaledBox, config.face['scale'] || faceBoxScaleFactor);\n const squaredBox = util.squarifyBox(enlargedBox);\n if (squaredBox.size[0] > (config.face.detector?.['minSize'] || 0) && squaredBox.size[1] > (config.face.detector?.['minSize'] || 0)) boxes.push(squaredBox);\n Object.keys(b).forEach((tensor) => tf.dispose(b[tensor]));\n }\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return boxes;\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport * as coords from './facemeshcoords';\nimport * as util from './facemeshutil';\nimport type { Tensor, GraphModel } from '../tfjs/types';\nimport { env } from '../util/env';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Config } from '../config';\nimport type { Point } from '../result';\n\nlet model: GraphModel | null;\nlet inputSize = 0;\n\nconst irisEnlarge = 2.3;\n\nconst leftOutline = coords.meshAnnotations.leftEyeLower0;\nconst rightOutline = coords.meshAnnotations.rightEyeLower0;\n\nconst eyeLandmarks = {\n leftBounds: [leftOutline[0], leftOutline[leftOutline.length - 1]],\n rightBounds: [rightOutline[0], rightOutline[rightOutline.length - 1]],\n};\n\nconst irisLandmarks = {\n upperCenter: 3,\n lowerCenter: 4,\n index: 71,\n numCoordinates: 76,\n};\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.iris?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n inputSize = (model?.['executor'] && model.inputs?.[0].shape) ? model.inputs[0].shape[2] : 0;\n if (inputSize === -1) inputSize = 64;\n return model;\n}\n\n// Replace the raw coordinates returned by facemesh with refined iris model coordinates and update the z coordinate to be an average of the original and the new.\nexport function replaceIrisCoords(rawCoords, newCoords, prefix, keys) {\n for (let i = 0; i < coords.irisIndices.length; i++) {\n const { key, indices } = coords.irisIndices[i];\n const originalIndices = coords.meshAnnotations[`${prefix}${key}`];\n if (!keys || keys.includes(key)) {\n for (let j = 0; j < indices.length; j++) {\n const index = indices[j];\n rawCoords[originalIndices[j]] = [\n newCoords[index][0],\n newCoords[index][1],\n (newCoords[index][2] + rawCoords[originalIndices[j]][2]) / 2,\n ];\n }\n }\n }\n}\n\nexport const getLeftToRightEyeDepthDifference = (rawCoords) => {\n const leftEyeZ = rawCoords[eyeLandmarks.leftBounds[0]][2];\n const rightEyeZ = rawCoords[eyeLandmarks.rightBounds[0]][2];\n return leftEyeZ - rightEyeZ;\n};\n\n// Returns a box describing a cropped region around the eye fit for passing to the iris model.\nexport const getEyeBox = (rawCoords, face, eyeInnerCornerIndex, eyeOuterCornerIndex, meshSize, flip = false) => {\n const box = util.squarifyBox(util.enlargeBox(util.calculateLandmarksBoundingBox([rawCoords[eyeInnerCornerIndex], rawCoords[eyeOuterCornerIndex]]), irisEnlarge));\n const boxSize = util.getBoxSize(box);\n let crop = tf.image.cropAndResize(face, [[\n box.startPoint[1] / meshSize,\n box.startPoint[0] / meshSize, box.endPoint[1] / meshSize,\n box.endPoint[0] / meshSize,\n ]], [0], [inputSize, inputSize]);\n if (flip && env.kernels.includes('flipleftright')) {\n const flipped = tf.image.flipLeftRight(crop); // flipLeftRight is not defined for tfjs-node\n tf.dispose(crop);\n crop = flipped;\n }\n return { box, boxSize, crop };\n};\n\n// Given a cropped image of an eye, returns the coordinates of the contours surrounding the eye and the iris.\nexport const getEyeCoords = (eyeData, eyeBox, eyeBoxSize, flip = false) => {\n const eyeRawCoords: Point[] = [];\n for (let i = 0; i < irisLandmarks.numCoordinates; i++) {\n const x = eyeData[i * 3];\n const y = eyeData[i * 3 + 1];\n const z = eyeData[i * 3 + 2];\n eyeRawCoords.push([\n (flip ? (1 - (x / inputSize)) : (x / inputSize)) * eyeBoxSize[0] + eyeBox.startPoint[0],\n (y / inputSize) * eyeBoxSize[1] + eyeBox.startPoint[1], z,\n ]);\n }\n return { rawCoords: eyeRawCoords, iris: eyeRawCoords.slice(irisLandmarks.index) };\n};\n\n// The z-coordinates returned for the iris are unreliable, so we take the z values from the surrounding keypoints.\nexport const getAdjustedIrisCoords = (rawCoords, irisCoords, direction) => {\n const upperCenterZ = rawCoords[coords.meshAnnotations[`${direction}EyeUpper0`][irisLandmarks.upperCenter]][2];\n const lowerCenterZ = rawCoords[coords.meshAnnotations[`${direction}EyeLower0`][irisLandmarks.lowerCenter]][2];\n const averageZ = (upperCenterZ + lowerCenterZ) / 2;\n // Iris indices: 0: center | 1: right | 2: above | 3: left | 4: below\n return irisCoords.map((coord, i) => {\n let z = averageZ;\n if (i === 2) {\n z = upperCenterZ;\n } else if (i === 4) {\n z = lowerCenterZ;\n }\n return [coord[0], coord[1], z];\n });\n};\n\nexport async function augmentIris(rawCoords, face, meshSize) {\n if (!model?.['executor']) return rawCoords;\n const { box: leftEyeBox, boxSize: leftEyeBoxSize, crop: leftEyeCrop } = getEyeBox(rawCoords, face, eyeLandmarks.leftBounds[0], eyeLandmarks.leftBounds[1], meshSize, true);\n const { box: rightEyeBox, boxSize: rightEyeBoxSize, crop: rightEyeCrop } = getEyeBox(rawCoords, face, eyeLandmarks.rightBounds[0], eyeLandmarks.rightBounds[1], meshSize, true);\n const combined = tf.concat([leftEyeCrop, rightEyeCrop]);\n tf.dispose(leftEyeCrop);\n tf.dispose(rightEyeCrop);\n const eyePredictions = model.execute(combined) as Tensor;\n tf.dispose(combined);\n const eyePredictionsData = await eyePredictions.data();\n tf.dispose(eyePredictions);\n const leftEyeData = eyePredictionsData.slice(0, irisLandmarks.numCoordinates * 3);\n const { rawCoords: leftEyeRawCoords, iris: leftIrisRawCoords } = getEyeCoords(leftEyeData, leftEyeBox, leftEyeBoxSize, true);\n const rightEyeData = eyePredictionsData.slice(irisLandmarks.numCoordinates * 3);\n const { rawCoords: rightEyeRawCoords, iris: rightIrisRawCoords } = getEyeCoords(rightEyeData, rightEyeBox, rightEyeBoxSize, false);\n const leftToRightEyeDepthDifference = getLeftToRightEyeDepthDifference(rawCoords);\n if (Math.abs(leftToRightEyeDepthDifference) < 30) { // User is looking straight ahead.\n replaceIrisCoords(rawCoords, leftEyeRawCoords, 'left', null);\n replaceIrisCoords(rawCoords, rightEyeRawCoords, 'right', null);\n // If the user is looking to the left or to the right, the iris coordinates tend to diverge too much from the mesh coordinates for them to be merged so we only update a single contour line above and below the eye.\n } else if (leftToRightEyeDepthDifference < 1) { // User is looking towards the right.\n replaceIrisCoords(rawCoords, leftEyeRawCoords, 'left', ['EyeUpper0', 'EyeLower0']);\n } else { // User is looking towards the left.\n replaceIrisCoords(rawCoords, rightEyeRawCoords, 'right', ['EyeUpper0', 'EyeLower0']);\n }\n const adjustedLeftIrisCoords = getAdjustedIrisCoords(rawCoords, leftIrisRawCoords, 'left');\n const adjustedRightIrisCoords = getAdjustedIrisCoords(rawCoords, rightIrisRawCoords, 'right');\n const newCoords = rawCoords.concat(adjustedLeftIrisCoords).concat(adjustedRightIrisCoords);\n return newCoords;\n}\n", "import * as constants from './constants';\nimport type { Tensor } from '../tfjs/types';\n\nexport async function augment(rawCoords, results: Tensor[]) {\n const t: Record = { // all attention models produce 2d results so it needs to be later augmented with correct z-coords\n // mesh: results[0], // already have it in rawCoords // output_mesh_identity\n // flag: results[1], // already processed in parent // conv_faceflag\n lips: await results.filter((r) => r.size === 160)?.[0]?.data() as Float32Array, // 80 x 2d = 160 // output_lips\n irisL: await results.filter((r) => r.size === 10)?.[0]?.data() as Float32Array, // 5 x 2d = 10 // output_right_iris\n eyeL: await results.filter((r) => r.size === 142)?.[0]?.data() as Float32Array, // 71 x 2d = 142 // output_right_eye\n irisR: await results.filter((r) => r.size === 10)?.[1]?.data() as Float32Array, // 5 x 2d = 10 // output_left_iris\n eyeR: await results.filter((r) => r.size === 142)?.[1]?.data() as Float32Array, // 71 x 2d = 142// output_left_eye\n };\n for (const val of Object.values(t)) {\n if (!val) return rawCoords; // could not find tensor\n }\n\n // augment iris: adds additional 5 keypoints per eye\n const irisLDepth = constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG.reduce((prev, curr) => prev += rawCoords[curr][2], 0) / constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG.length; // get average z-coord for iris\n for (let i = 0; i < t.irisL.length / 2; i++) rawCoords.push([t.irisL[2 * i + 0], t.irisL[2 * i + 1], irisLDepth]);\n const irisRDepth = constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG.reduce((prev, curr) => prev += rawCoords[curr][2], 0) / constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG.length; // get average z-coord for iris\n for (let i = 0; i < t.irisR.length / 2; i++) rawCoords.push([t.irisR[2 * i + 0], t.irisR[2 * i + 1], irisRDepth]);\n\n // augment eyes: replaces eye keypoints based on heuristic mapping\n for (let i = 0; i < t.eyeL.length / 2; i++) rawCoords[constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG[i]] = [t.eyeL[2 * i + 0], t.eyeL[2 * i + 1], rawCoords[constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG[i]][2]];\n for (let i = 0; i < t.eyeR.length / 2; i++) rawCoords[constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG[i]] = [t.eyeR[2 * i + 0], t.eyeR[2 * i + 1], rawCoords[constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG[i]][2]];\n\n // augment lips: replaces eye keypoints based on heuristic mapping\n for (let i = 0; i < t.lips.length / 2; i++) rawCoords[constants.LANDMARKS_REFINEMENT_LIPS_CONFIG[i]] = [t.lips[2 * i + 0], t.lips[2 * i + 1], rawCoords[constants.LANDMARKS_REFINEMENT_LIPS_CONFIG[i]][2]];\n\n return rawCoords;\n}\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n *\n * Based on:\n * - [**MediaPipe BlazeFace**](https://drive.google.com/file/d/1f39lSzU5Oq-j_OXgS67KfN5wNsoeAZ4V/view)\n * - Facial Spacial Geometry: [**MediaPipe FaceMesh**](https://drive.google.com/file/d/1VFC_wIpw4O7xBOiTgUldl79d9LA-LsnA/view)\n * - Eye Iris Details: [**MediaPipe Iris**](https://drive.google.com/file/d/1bsWbokp9AklH2ANjCfmjqEzzxO1CNbMu/view)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport * as blazeface from './blazeface';\nimport * as util from './facemeshutil';\nimport * as coords from './facemeshcoords';\nimport * as iris from './iris';\nimport * as attention from './attention';\nimport { histogramEqualization } from '../image/enhance';\nimport { env } from '../util/env';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { FaceResult, FaceLandmark, Point } from '../result';\nimport type { Config } from '../config';\nimport type { DetectBox } from './blazeface';\n\nconst cache = {\n boxes: [] as DetectBox[],\n skipped: Number.MAX_SAFE_INTEGER,\n timestamp: 0,\n};\n\nlet model: GraphModel | null = null;\nlet inputSize = 0;\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n // reset cached boxes\n const skipTime = (config.face.detector?.skipTime || 0) > (now() - cache.timestamp);\n const skipFrame = cache.skipped < (config.face.detector?.skipFrames || 0);\n if (!config.skipAllowed || !skipTime || !skipFrame || cache.boxes.length === 0) {\n cache.boxes = await blazeface.getBoxes(input, config); // get results from blazeface detector\n cache.timestamp = now();\n cache.skipped = 0;\n } else {\n cache.skipped++;\n }\n const faces: FaceResult[] = [];\n const newCache: DetectBox[] = [];\n let id = 0;\n const size = inputSize;\n for (let i = 0; i < cache.boxes.length; i++) {\n const box = cache.boxes[i];\n let angle = 0;\n let rotationMatrix;\n const face: FaceResult = { // init face result\n id: id++,\n mesh: [],\n meshRaw: [],\n box: [0, 0, 0, 0],\n boxRaw: [0, 0, 0, 0],\n score: 0,\n boxScore: 0,\n faceScore: 0,\n size: [0, 0],\n // contoursRaw: [],\n // contours: [],\n annotations: {} as Record,\n };\n\n // optional rotation correction based on detector data only if mesh is disabled otherwise perform it later when we have more accurate mesh data. if no rotation correction this function performs crop\n [angle, rotationMatrix, face.tensor] = util.correctFaceRotation(config.face.detector?.rotation, box, input, config.face.mesh?.enabled ? inputSize : blazeface.size());\n if (config.filter.equalization) {\n const equilized = face.tensor ? await histogramEqualization(face.tensor) : undefined;\n tf.dispose(face.tensor);\n if (equilized) face.tensor = equilized;\n }\n face.boxScore = Math.round(100 * box.confidence) / 100;\n if (!config.face.mesh?.enabled || !model?.['executor']) { // mesh not enabled or not loaded, return resuts from detector only\n face.box = util.clampBox(box, input);\n face.boxRaw = util.getRawBox(box, input);\n face.score = face.boxScore;\n face.size = box.size;\n face.mesh = box.landmarks;\n face.meshRaw = face.mesh.map((pt) => [pt[0] / (input.shape[2] || 0), pt[1] / (input.shape[1] || 0), (pt[2] || 0) / size]);\n for (const key of Object.keys(coords.blazeFaceLandmarks)) face.annotations[key] = [face.mesh[coords.blazeFaceLandmarks[key] as number]]; // add annotations\n } else if (!model) { // mesh enabled, but not loaded\n if (config.debug) log('face mesh detection requested, but model is not loaded');\n } else { // mesh enabled\n if (config.face.attention?.enabled && !env.kernels.includes('atan2')) {\n config.face.attention.enabled = false;\n tf.dispose(face.tensor);\n return faces;\n }\n const results = model.execute(face.tensor as Tensor) as Tensor[];\n const confidenceT = results.find((t) => t.shape[t.shape.length - 1] === 1) as Tensor;\n const faceConfidence = await confidenceT.data();\n face.faceScore = Math.round(100 * faceConfidence[0]) / 100;\n if (face.faceScore < (config.face.detector?.minConfidence || 1)) { // low confidence in detected mesh\n box.confidence = face.faceScore; // reset confidence of cached box\n if (config.face.mesh['keepInvalid']) {\n face.box = util.clampBox(box, input);\n face.boxRaw = util.getRawBox(box, input);\n face.size = box.size;\n face.score = face.boxScore;\n face.mesh = box.landmarks;\n face.meshRaw = face.mesh.map((pt) => [pt[0] / (input.shape[2] || 1), pt[1] / (input.shape[1] || 1), (pt[2] || 0) / size]);\n for (const key of Object.keys(coords.blazeFaceLandmarks)) {\n face.annotations[key] = [face.mesh[coords.blazeFaceLandmarks[key] as number]]; // add annotations\n }\n }\n } else {\n const meshT = results.find((t) => t.shape[t.shape.length - 1] === 1404) as Tensor;\n const coordsReshaped = tf.reshape(meshT, [-1, 3]);\n let rawCoords = await coordsReshaped.array();\n tf.dispose(coordsReshaped);\n if (config.face.attention?.enabled) {\n rawCoords = await attention.augment(rawCoords, results); // augment iris results using attention model results\n } else if (config.face.iris?.enabled) {\n rawCoords = await iris.augmentIris(rawCoords, face.tensor, inputSize); // run iris model and augment results\n }\n face.mesh = util.transformRawCoords(rawCoords, box, angle, rotationMatrix, inputSize); // get processed mesh\n face.meshRaw = face.mesh.map((pt) => [pt[0] / (input.shape[2] || 0), pt[1] / (input.shape[1] || 0), (pt[2] || 0) / size]);\n for (const key of Object.keys(coords.meshAnnotations)) face.annotations[key] = coords.meshAnnotations[key].map((index) => face.mesh[index]); // add annotations\n face.score = face.faceScore;\n const calculatedBox = {\n ...util.calculateFaceBox(face.mesh, box),\n confidence: box.confidence,\n landmarks: box.landmarks,\n size: box.size,\n };\n face.box = util.clampBox(calculatedBox, input);\n face.boxRaw = util.getRawBox(calculatedBox, input);\n face.size = calculatedBox.size;\n /*\n const contoursT = results.find((t) => t.shape[t.shape.length - 1] === 266) as Tensor;\n const contoursData = contoursT && await contoursT.data(); // 133 x 2d points\n face.contoursRaw = [];\n for (let j = 0; j < contoursData.length / 2; j++) face.contoursRaw.push([contoursData[2 * j + 0] / inputSize, contoursData[2 * j + 1] / inputSize]);\n face.contours = face.contoursRaw.map((c) => [Math.trunc((input.shape[2] || 1) * c[0]), Math.trunc((input.shape[1] || 1) * c[1])]);\n */\n newCache.push(calculatedBox);\n }\n tf.dispose(results);\n }\n if (face.score > (config.face.detector?.minConfidence || 1)) faces.push(face);\n else tf.dispose(face.tensor);\n }\n cache.boxes = newCache; // reset cache\n return faces;\n}\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (config.face.attention?.enabled && model?.['signature']) {\n if (Object.keys(model?.['signature']?.outputs || {}).length < 6) model = null;\n }\n if (!model) {\n if (config.face.attention?.enabled) model = await loadModel(config.face.attention.modelPath);\n else model = await loadModel(config.face.mesh?.modelPath);\n } else if (config.debug) {\n log('cached model:', model['modelUrl']);\n }\n inputSize = (model['executor'] && model?.inputs?.[0].shape) ? model?.inputs?.[0].shape[2] : 256;\n return model;\n}\n\nexport const triangulation = coords.TRI468;\nexport const uvmap = coords.UV468;\n", "/**\n * Emotion model implementation\n *\n * [**Oarriaga**](https://github.com/oarriaga/face_classification)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Emotion } from '../result';\nimport { log, now } from '../util/util';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { loadModel } from '../tfjs/load';\nimport { env } from '../util/env';\nimport { constants } from '../tfjs/constants';\n\nlet annotations: string[] = [];\nlet model: GraphModel | null;\nconst last: { score: number, emotion: Emotion }[][] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet rgb = false;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n model = await loadModel(config.face.emotion?.modelPath);\n rgb = model?.inputs?.[0].shape?.[3] === 3;\n if (!rgb) annotations = ['angry', 'disgust', 'fear', 'happy', 'sad', 'surprise', 'neutral']; // oarriaga and gear\n else annotations = ['angry', 'disgust', 'fear', 'happy', 'neutral', 'sad', 'surprise']; // affectnet\n } else if (config.debug) {\n log('cached model:', model['modelUrl']);\n }\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise<{ score: number, emotion: Emotion }[]> {\n if (!model) return [];\n const skipFrame = skipped < (config.face.emotion?.skipFrames || 0);\n const skipTime = (config.face.emotion?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx] && (last[idx].length > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const obj: { score: number, emotion: Emotion }[] = [];\n if (config.face.emotion?.enabled) {\n const t: Record = {};\n const inputSize = model?.inputs[0].shape ? model.inputs[0].shape[2] : 0;\n if (config.face.emotion?.['crop'] > 0) { // optional crop\n const crop = config.face.emotion?.['crop'];\n const box = [[crop, crop, 1 - crop, 1 - crop]];\n t.resize = tf.image.cropAndResize(image, box, [0], [inputSize, inputSize]);\n } else {\n t.resize = tf.image.resizeBilinear(image, [inputSize, inputSize], false);\n }\n if (rgb) {\n t.mul = tf.mul(t.resize, 255);\n t.normalize = tf.sub(t.mul, [103.939, 116.779, 123.68]); // affectnet uses specific norm values\n t.emotion = model?.execute(t.normalize) as Tensor; // result is already in range 0..1, no need for additional activation\n } else {\n // [t.red, t.green, t.blue] = tf.split(t.resize, 3, 3);\n // weighted rgb to grayscale: https://www.mathworks.com/help/matlab/ref/rgb2gray.html\n // t.redNorm = tf.mul(t.red, rgb[0]);\n // t.greenNorm = tf.mul(t.green, rgb[1]);\n // t.blueNorm = tf.mul(t.blue, rgb[2]);\n // t.grayscale = tf.addN([t.redNorm, t.greenNorm, t.blueNorm]);\n t.channels = tf.mul(t.resize, constants.rgb);\n t.grayscale = tf.sum(t.channels, 3, true);\n t.grayscaleSub = tf.sub(t.grayscale, constants.tf05);\n t.grayscaleMul = tf.mul(t.grayscaleSub, constants.tf2);\n t.emotion = model?.execute(t.grayscaleMul) as Tensor; // result is already in range 0..1, no need for additional activation\n }\n lastTime = now();\n const data = await t.emotion.data();\n for (let i = 0; i < data.length; i++) {\n if (data[i] > (config.face.emotion.minConfidence || 0)) obj.push({ score: Math.min(0.99, Math.trunc(100 * data[i]) / 100), emotion: annotations[i] as Emotion });\n }\n obj.sort((a, b) => b.score - a.score);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n last[idx] = obj;\n lastCount = count;\n resolve(obj);\n });\n}\n", "/**\n * FaceRes model implementation\n *\n * Returns Age, Gender, Descriptor\n * Implements Face similarity function\n *\n * Based on: [**HSE-FaceRes**](https://github.com/HSE-asavchenko/HSE_FaceRec_tf)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { env } from '../util/env';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { Tensor, GraphModel, Tensor4D, Tensor1D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport type { Gender, Race } from '../result';\n\nexport interface FaceRes { age: number, gender: Gender, genderScore: number, descriptor: number[], race?: { score: number, race: Race }[] }\n\nlet model: GraphModel | null;\nconst last: FaceRes[] = [];\n\nlet lastTime = 0;\nlet lastCount = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.description?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport function enhance(input, config: Config): Tensor {\n const tensor = (input.image || input.tensor || input) as Tensor4D; // input received from detector is already normalized to 0..1, input is also assumed to be straightened\n if (!model?.inputs[0].shape) return tensor; // model has no shape so no point continuing\n let crop: Tensor;\n if (config.face.description?.['crop'] > 0) { // optional crop\n const cropval = config.face.description?.['crop'];\n const box = [[cropval, cropval, 1 - cropval, 1 - cropval]];\n crop = tf.image.cropAndResize(tensor, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n } else {\n crop = tf.image.resizeBilinear(tensor, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false);\n }\n const norm: Tensor = tf.mul(crop, constants.tf255);\n tf.dispose(crop);\n return norm;\n /*\n // do a tight crop of image and resize it to fit the model\n const box = [[0.05, 0.15, 0.85, 0.85]]; // empyrical values for top, left, bottom, right\n const crop = (tensor.shape.length === 3)\n ? tf.image.cropAndResize(tf.expandDims(tensor, 0), box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]) // add batch dimension if missing\n : tf.image.cropAndResize(tensor, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n */\n /*\n // convert to black&white to avoid colorization impact\n const rgb = [0.2989, 0.5870, 0.1140]; // factors for red/green/blue colors when converting to grayscale: https://www.mathworks.com/help/matlab/ref/rgb2gray.html\n const [red, green, blue] = tf.split(crop, 3, 3);\n const redNorm = tf.mul(red, rgb[0]);\n const greenNorm = tf.mul(green, rgb[1]);\n const blueNorm = tf.mul(blue, rgb[2]);\n const grayscale = tf.addN([redNorm, greenNorm, blueNorm]);\n const merge = tf.stack([grayscale, grayscale, grayscale], 3).squeeze(4);\n */\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n const obj: FaceRes = {\n age: 0 as number,\n gender: 'unknown' as Gender,\n genderScore: 0 as number,\n descriptor: [] as number[],\n };\n if (!model?.['executor']) return obj;\n const skipFrame = skipped < (config.face.description?.skipFrames || 0);\n const skipTime = (config.face.description?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipFrame && skipTime && (lastCount === count) && (last?.[idx]?.age > 0) && (last?.[idx]?.genderScore > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (config.face.description?.enabled) {\n const enhanced = enhance(image, config);\n const resT = model?.execute(enhanced) as Tensor[];\n lastTime = now();\n tf.dispose(enhanced);\n const genderT = resT.find((t) => t.shape[1] === 1) as Tensor;\n const gender = await genderT.data();\n const confidence = Math.trunc(200 * Math.abs((gender[0] - 0.5))) / 100;\n if (confidence > (config.face.description.minConfidence || 0)) {\n obj.gender = gender[0] <= 0.5 ? 'female' : 'male';\n obj.genderScore = Math.min(0.99, confidence);\n }\n const argmax = tf.argMax(resT.find((t) => t.shape[1] === 100) as Tensor1D, 1);\n const ageIdx: number = (await argmax.data())[0];\n tf.dispose(argmax);\n const ageT = resT.find((t) => t.shape[1] === 100) as Tensor;\n const all = await ageT.data();\n obj.age = Math.round(all[ageIdx - 1] > all[ageIdx + 1] ? 10 * ageIdx - 100 * all[ageIdx - 1] : 10 * ageIdx + 100 * all[ageIdx + 1]) / 10;\n\n if (Number.isNaN(gender[0]) || Number.isNaN(all[0])) log('faceres error:', { model, result: resT });\n\n const desc = resT.find((t) => t.shape[1] === 1024);\n // const reshape = desc.reshape([128, 8]); // reshape large 1024-element descriptor to 128 x 8\n // const reduce = reshape.logSumExp(1); // reduce 2nd dimension by calculating logSumExp on it which leaves us with 128-element descriptor\n const descriptor = desc ? await desc.data() : [] as number[];\n obj.descriptor = Array.from(descriptor);\n resT.forEach((t) => tf.dispose(t));\n }\n last[idx] = obj;\n lastCount = count;\n resolve(obj);\n });\n}\n", "import type { Tensor } from '../tfjs/types';\nimport type { FaceResult } from '../result';\n// import * as tf from 'dist/tfjs.esm.js';\nimport { meshAnnotations } from './facemeshcoords';\n\nconst expandFact = 0.1;\nconst alpha = 0.5;\n\n// point inclusion in polygon based on https://wrf.ecse.rpi.edu/Research/Short_Notes/pnpoly.html\nfunction insidePoly(x: number, y: number, polygon: { x: number, y: number }[]): boolean {\n let inside = false;\n let j = polygon.length - 1;\n for (let i = 0; i < polygon.length; j = i++) {\n if (((polygon[i].y > y) !== (polygon[j].y > y)) && (x < (polygon[j].x - polygon[i].x) * (y - polygon[i].y) / (polygon[j].y - polygon[i].y) + polygon[i].x)) inside = !inside;\n }\n return inside;\n}\n\nexport async function mask(face: FaceResult): Promise {\n if (!face.tensor) return face.tensor;\n if (!face.mesh || face.mesh.length < 100) return face.tensor;\n const width = face.tensor.shape[2] || 0;\n const height = face.tensor.shape[1] || 0;\n const buffer = await face.tensor.buffer();\n let silhouette: { x: number, y: number }[] = [];\n for (const pt of meshAnnotations.silhouette) silhouette.push({ x: (face.mesh[pt][0] - face.box[0]) / face.box[2], y: (face.mesh[pt][1] - face.box[1]) / face.box[3] }); // add all silhouette points scaled to local box\n if (expandFact && expandFact > 0) silhouette = silhouette.map((pt) => ({ x: pt.x > 0.5 ? pt.x + expandFact : pt.x - expandFact, y: pt.y > 0.5 ? pt.y + expandFact : pt.y - expandFact })); // expand silhouette\n for (let x = 0; x < width; x++) {\n for (let y = 0; y < height; y++) {\n const inside = insidePoly(x / width, y / width, silhouette);\n if (!inside) {\n buffer.set(alpha * buffer.get(0, y, x, 0), 0, y, x, 0);\n buffer.set(alpha * buffer.get(0, y, x, 1), 0, y, x, 1);\n buffer.set(alpha * buffer.get(0, y, x, 2), 0, y, x, 2);\n }\n }\n }\n const output = buffer.toTensor();\n // tf.dispose(buffer);\n return output;\n}\n", "/**\n * Anti-spoofing model implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { loadModel } from '../tfjs/load';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst cached: number[] = [];\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet lastCount = 0;\nlet lastTime = 0;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.antispoof?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n if (!model?.['executor']) return 0;\n const skipTime = (config.face.antispoof?.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.face.antispoof?.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && cached[idx]) {\n skipped++;\n return cached[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape ? model.inputs[0].shape[2] : 0, model?.inputs[0].shape ? model.inputs[0].shape[1] : 0], false);\n const res = model?.execute(resize) as Tensor;\n const num = (await res.data())[0];\n cached[idx] = Math.round(100 * num) / 100;\n lastCount = count;\n lastTime = now();\n tf.dispose([resize, res]);\n resolve(cached[idx]);\n });\n}\n", "/**\n * Anti-spoofing model implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst cached: number[] = [];\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet lastCount = 0;\nlet lastTime = 0;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.liveness?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n if (!model?.['executor']) return 0;\n const skipTime = (config.face.liveness?.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.face.liveness?.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && cached[idx]) {\n skipped++;\n return cached[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape ? model.inputs[0].shape[2] : 0, model?.inputs[0].shape ? model.inputs[0].shape[1] : 0], false);\n const res = model?.execute(resize) as Tensor;\n const num = (await res.data())[0];\n cached[idx] = Math.round(100 * num) / 100;\n lastCount = count;\n lastTime = now();\n tf.dispose([resize, res]);\n resolve(cached[idx]);\n });\n}\n", "/**\n * GEAR [gender/emotion/age/race] model implementation\n *\n * Based on: [**GEAR Predictor**](https://github.com/Udolf15/GEAR-Predictor)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Gender, Race } from '../result';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\n\nexport interface GearType { age: number, gender: Gender, genderScore: number, race: { score: number, race: Race }[] }\nlet model: GraphModel | null;\nconst last: GearType[] = [];\nconst raceNames = ['white', 'black', 'asian', 'indian', 'other'];\nconst ageWeights = [15, 23, 28, 35.5, 45.5, 55.5, 65];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config) {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.gear?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n if (!model) return { age: 0, gender: 'unknown', genderScore: 0, race: [] };\n const skipFrame = skipped < (config.face.gear?.skipFrames || 0);\n const skipTime = (config.face.gear?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx]) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (!model?.inputs[0].shape) return;\n const t: Record = {};\n // t.resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape[2], model?.inputs[0].shape[1]], false);\n let box = [[0.0, 0.10, 0.90, 0.90]]; // empyrical values for top, left, bottom, right\n if (config.face.gear?.['crop'] > 0) { // optional crop config value\n const crop = config.face.gear?.['crop'];\n box = [[crop, crop, 1 - crop, 1 - crop]];\n }\n t.resize = tf.image.cropAndResize(image, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n const obj: GearType = { age: 0, gender: 'unknown', genderScore: 0, race: [] };\n if (config.face.gear?.enabled) [t.age, t.gender, t.race] = model.execute(t.resize, ['age_output', 'gender_output', 'race_output']) as Tensor[];\n const gender = await t.gender.data();\n obj.gender = gender[0] > gender[1] ? 'male' : 'female';\n obj.genderScore = Math.round(100 * (gender[0] > gender[1] ? gender[0] : gender[1])) / 100;\n const race = await t.race.data();\n for (let i = 0; i < race.length; i++) {\n if (race[i] > (config.face.gear?.minConfidence || 0.2)) obj.race.push({ score: Math.round(100 * race[i]) / 100, race: raceNames[i] as Race });\n }\n obj.race.sort((a, b) => b.score - a.score);\n // {0: 'Below20', 1: '21-25', 2: '26-30', 3: '31-40',4: '41-50', 5: '51-60', 6: 'Above60'}\n const ageDistribution = Array.from(await t.age.data());\n const ageSorted = ageDistribution.map((a, i) => [ageWeights[i], a]).sort((a, b) => b[1] - a[1]);\n let age = ageSorted[0][0]; // pick best starting point\n for (let i = 1; i < ageSorted.length; i++) age += ageSorted[i][1] * (ageSorted[i][0] - age); // adjust with each other choice by weight\n obj.age = Math.round(10 * age) / 10;\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n last[idx] = obj;\n lastCount = count;\n lastTime = now();\n resolve(obj);\n });\n}\n", "/**\n * Age model implementation\n *\n * Based on: [**SSR-Net**](https://github.com/shamangary/SSR-Net)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { env } from '../util/env';\nimport { constants } from '../tfjs/constants';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\n\nlet model: GraphModel | null;\nconst last: { age: number }[] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config) {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['ssrnet'].modelPathAge);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise<{ age: number }> {\n if (!model) return { age: 0 };\n const skipFrame = skipped < (config.face['ssrnet']?.skipFrames || 0);\n const skipTime = (config.face['ssrnet']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipFrame && skipTime && (lastCount === count) && last[idx]?.age && (last[idx]?.age > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (!model?.inputs || !model.inputs[0] || !model.inputs[0].shape) return;\n const t: Record = {};\n if (config.face['ssrnet']?.['crop'] > 0) { // optional crop\n const crop = config.face['ssrnet']?.['crop'];\n const box = [[crop, crop, 1 - crop, 1 - crop]];\n t.resize = tf.image.cropAndResize(image, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n } else {\n t.resize = tf.image.resizeBilinear(image, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false);\n }\n t.enhance = tf.mul(t.resize, constants.tf255);\n const obj = { age: 0 };\n if (config.face['ssrnet']?.enabled) t.age = model.execute(t.enhance) as Tensor;\n if (t.age) {\n const data = await t.age.data();\n obj.age = Math.trunc(10 * data[0]) / 10;\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n last[idx] = obj;\n lastCount = count;\n lastTime = now();\n resolve(obj);\n });\n}\n", "/**\n * Gender model implementation\n *\n * Based on: [**SSR-Net**](https://github.com/shamangary/SSR-Net)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { Gender } from '../result';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst last: { gender: Gender, genderScore: number }[] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\n// tuning values\nconst rgb = [0.2989, 0.5870, 0.1140]; // factors for red/green/blue colors when converting to grayscale\n\nexport async function load(config: Config) {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['ssrnet']?.modelPathGender);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx, count): Promise<{ gender: Gender, genderScore: number }> {\n if (!model) return { gender: 'unknown', genderScore: 0 };\n const skipFrame = skipped < (config.face['ssrnet']?.skipFrames || 0);\n const skipTime = (config.face['ssrnet']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipFrame && skipTime && (lastCount === count) && last[idx]?.gender && (last[idx]?.genderScore > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (!model?.inputs[0].shape) return;\n const t: Record = {};\n if (config.face['ssrnet']?.['crop'] > 0) { // optional crop\n const crop = config.face['ssrnet']?.['crop'];\n const box = [[crop, crop, 1 - crop, 1 - crop]];\n t.resize = tf.image.cropAndResize(image, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n } else {\n t.resize = tf.image.resizeBilinear(image, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false);\n }\n t.enhance = tf.tidy(() => {\n let normalize: Tensor;\n if (model?.inputs?.[0].shape?.[3] === 1) {\n const [red, green, blue] = tf.split(t.resize, 3, 3);\n const redNorm = tf.mul(red, rgb[0]);\n const greenNorm = tf.mul(green, rgb[1]);\n const blueNorm = tf.mul(blue, rgb[2]);\n const grayscale = tf.addN([redNorm, greenNorm, blueNorm]);\n normalize = tf.mul(tf.sub(grayscale, constants.tf05), 2); // range grayscale:-1..1\n } else {\n normalize = tf.mul(tf.sub(t.resize, constants.tf05), 2); // range rgb:-1..1\n }\n return normalize;\n });\n const obj: { gender: Gender, genderScore: number } = { gender: 'unknown', genderScore: 0 };\n if (config.face['ssrnet']?.enabled) t.gender = model.execute(t.enhance) as Tensor;\n const data = await t.gender.data();\n obj.gender = data[0] > data[1] ? 'female' : 'male'; // returns two values 0..1, bigger one is prediction\n obj.genderScore = data[0] > data[1] ? (Math.trunc(100 * data[0]) / 100) : (Math.trunc(100 * data[1]) / 100);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n last[idx] = obj;\n lastCount = count;\n lastTime = now();\n resolve(obj);\n });\n}\n", "/**\n * MobileFaceNet model implementation\n *\n * Based on: [**BecauseofAI MobileFace**](https://github.com/becauseofAI/MobileFace)\n *\n * Obsolete and replaced by `faceres` that performs age/gender/descriptor analysis\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Tensor, Tensor4D, GraphModel } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst last: number[][] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['mobilefacenet']?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\n/*\n// convert to black&white to avoid colorization impact\nconst rgb = [0.2989, 0.5870, 0.1140]; // factors for red/green/blue colors when converting to grayscale: https://www.mathworks.com/help/matlab/ref/rgb2gray.html\nconst [red, green, blue] = tf.split(crop, 3, 3);\nconst redNorm = tf.mul(red, rgb[0]);\nconst greenNorm = tf.mul(green, rgb[1]);\nconst blueNorm = tf.mul(blue, rgb[2]);\nconst grayscale = tf.addN([redNorm, greenNorm, blueNorm]);\nconst merge = tf.stack([grayscale, grayscale, grayscale], 3).squeeze(4);\n\n// optional increase image contrast\n// or do it per-channel so mean is done on each channel\n// or do it based on histogram\nconst mean = merge.mean();\nconst factor = 5;\nconst contrast = merge.sub(mean).mul(factor).add(mean);\n*/\n\nexport async function predict(input: Tensor4D, config: Config, idx, count): Promise {\n if (!model?.['executor']) return [];\n const skipFrame = skipped < (config.face['mobilefacenet']?.skipFrames || 0);\n const skipTime = (config.face['mobilefacenet']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx]) {\n skipped++;\n return last[idx];\n }\n return new Promise(async (resolve) => {\n let data: number[] = [];\n if (config.face['mobilefacenet']?.enabled && model?.inputs[0].shape) {\n const t: Record = {};\n t.crop = tf.image.resizeBilinear(input, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false); // just resize to fit the embedding model\n // do a tight crop of image and resize it to fit the model\n // const box = [[0.05, 0.15, 0.85, 0.85]]; // empyrical values for top, left, bottom, right\n // t.crop = tf.image.cropAndResize(input, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n t.data = model.execute(t.crop) as Tensor;\n /*\n // optional normalize outputs with l2 normalization\n const scaled = tf.tidy(() => {\n const l2 = res.norm('euclidean');\n const scale = res.div(l2);\n return scale;\n });\n\n // optional reduce feature vector complexity\n const reshape = tf.reshape(res, [128, 2]); // split 256 vectors into 128 x 2\n const reduce = reshape.logSumExp(1); // reduce 2nd dimension by calculating logSumExp on it\n */\n const output = await t.data.data();\n data = Array.from(output); // convert typed array to simple array\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n last[idx] = data;\n lastCount = count;\n lastTime = now();\n resolve(data);\n });\n}\n", "/**\n * InsightFace model implementation\n *\n * Based on: [**DeepInsight InsightFace**](https://github.com/deepinsight/insightface)\n *\n * Alternative face embedding detection\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Tensor, Tensor4D, GraphModel } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst last: number[][] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['insightface'].modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(input: Tensor4D, config: Config, idx, count): Promise {\n if (!model?.['executor']) return [];\n const skipFrame = skipped < (config.face['insightface']?.skipFrames || 0);\n const skipTime = (config.face['insightface']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx]) {\n skipped++;\n return last[idx];\n }\n return new Promise(async (resolve) => {\n let data: number[] = [];\n if (config.face['insightface']?.enabled && model?.inputs[0].shape) {\n const t: Record = {};\n t.crop = tf.image.resizeBilinear(input, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false); // just resize to fit the embedding model\n // do a tight crop of image and resize it to fit the model\n // const box = [[0.05, 0.15, 0.85, 0.85]]; // empyrical values for top, left, bottom, right\n // t.crop = tf.image.cropAndResize(input, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n t.data = model.execute(t.crop) as Tensor;\n const output = await t.data.data();\n data = Array.from(output); // convert typed array to simple array\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n last[idx] = data;\n lastCount = count;\n lastTime = now();\n resolve(data);\n });\n}\n", "import type { Point, FaceResult } from '../result';\n\ntype Vector = [number, number, number];\n\nconst calculateGaze = (face: FaceResult): { bearing: number, strength: number } => {\n const radians = (pt1: Point, pt2: Point) => Math.atan2(pt1[1] - pt2[1], pt1[0] - pt2[0]); // function to calculate angle between any two points\n if (!face.annotations.rightEyeIris || !face.annotations.leftEyeIris) return { bearing: 0, strength: 0 };\n\n const offsetIris = [0, -0.1]; // iris center may not align with average of eye extremes\n const eyeRatio = 1; // factor to normalize changes x vs y\n\n const left = (face.mesh[33][2] || 0) > (face.mesh[263][2] || 0); // pick left or right eye depending which one is closer bazed on outsize point z axis\n const irisCenter = left ? face.mesh[473] : face.mesh[468];\n const eyeCenter = left // eye center is average of extreme points on x axis for both x and y, ignoring y extreme points as eyelids naturally open/close more when gazing up/down so relative point is less precise\n ? [(face.mesh[133][0] + face.mesh[33][0]) / 2, (face.mesh[133][1] + face.mesh[33][1]) / 2]\n : [(face.mesh[263][0] + face.mesh[362][0]) / 2, (face.mesh[263][1] + face.mesh[362][1]) / 2];\n const eyeSize = left // eye size is difference between extreme points for both x and y, used to normalize & squarify eye dimensions\n ? [face.mesh[133][0] - face.mesh[33][0], face.mesh[23][1] - face.mesh[27][1]]\n : [face.mesh[263][0] - face.mesh[362][0], face.mesh[253][1] - face.mesh[257][1]];\n const eyeDiff: Point = [ // x distance between extreme point and center point normalized with eye size\n (eyeCenter[0] - irisCenter[0]) / eyeSize[0] - offsetIris[0],\n eyeRatio * (irisCenter[1] - eyeCenter[1]) / eyeSize[1] - offsetIris[1],\n ];\n let strength = Math.sqrt((eyeDiff[0] * eyeDiff[0]) + (eyeDiff[1] * eyeDiff[1])); // vector length is a diagonal between two differences\n strength = Math.min(strength, face.boxRaw[2] / 2, face.boxRaw[3] / 2); // limit strength to half of box size to avoid clipping due to low precision\n const bearing = (radians([0, 0], eyeDiff) + (Math.PI / 2)) % Math.PI; // using eyeDiff instead eyeCenter/irisCenter combo due to manual adjustments and rotate clockwise 90degrees\n return { bearing, strength };\n};\n\nexport const calculateFaceAngle = (face: FaceResult, imageSize: [number, number]): {\n angle: { pitch: number, yaw: number, roll: number },\n matrix: [number, number, number, number, number, number, number, number, number],\n gaze: { bearing: number, strength: number },\n} => {\n // const degrees = (theta) => Math.abs(((theta * 180) / Math.PI) % 360);\n const normalize = (v: Vector): Vector => { // normalize vector\n const length = Math.sqrt(v[0] * v[0] + v[1] * v[1] + v[2] * v[2]);\n v[0] /= length;\n v[1] /= length;\n v[2] /= length;\n return v;\n };\n const subVectors = (a: Vector, b: Vector): Vector => { // vector subtraction (a - b)\n const x = a[0] - b[0];\n const y = a[1] - b[1];\n const z = a[2] - b[2];\n return [x, y, z];\n };\n const crossVectors = (a: Vector, b: Vector): Vector => { // vector cross product (a x b)\n const x = a[1] * b[2] - a[2] * b[1];\n const y = a[2] * b[0] - a[0] * b[2];\n const z = a[0] * b[1] - a[1] * b[0];\n return [x, y, z];\n };\n // 3x3 rotation matrix to Euler angles based on https://www.geometrictools.com/Documentation/EulerAngles.pdf\n const rotationMatrixToEulerAngle = (r: number[]): { pitch: number, yaw: number, roll: number } => {\n const [r00, _r01, _r02, r10, r11, r12, r20, r21, r22] = r; // eslint-disable-line @typescript-eslint/no-unused-vars\n let thetaX: number;\n let thetaY: number;\n let thetaZ: number;\n if (r10 < 1) { // YZX calculation\n if (r10 > -1) {\n thetaZ = Math.asin(r10);\n thetaY = Math.atan2(-r20, r00);\n thetaX = Math.atan2(-r12, r11);\n } else {\n thetaZ = -Math.PI / 2;\n thetaY = -Math.atan2(r21, r22);\n thetaX = 0;\n }\n } else {\n thetaZ = Math.PI / 2;\n thetaY = Math.atan2(r21, r22);\n thetaX = 0;\n }\n if (Number.isNaN(thetaX)) thetaX = 0;\n if (Number.isNaN(thetaY)) thetaY = 0;\n if (Number.isNaN(thetaZ)) thetaZ = 0;\n return { pitch: 2 * -thetaX, yaw: 2 * -thetaY, roll: 2 * -thetaZ };\n };\n\n /*\n const meshToEulerAngle = (mesh) => { // simple Euler angle calculation based existing 3D mesh\n const radians = (a1, a2, b1, b2) => Math.atan2(b2 - a2, b1 - a1);\n return { // values are in radians in range of -pi/2 to pi/2 which is -90 to +90 degrees, value of 0 means center\n pitch: radians(mesh[10][1], mesh[10][2], mesh[152][1], mesh[152][2]), // looking at y,z of top and bottom points of the face // pitch is face move up/down\n yaw: radians(mesh[33][0], mesh[33][2], mesh[263][0], mesh[263][2]), // looking at x,z of outside corners of leftEye and rightEye // yaw is face turn left/right\n roll: radians(mesh[33][0], mesh[33][1], mesh[263][0], mesh[263][1]), // looking at x,y of outside corners of leftEye and rightEye // roll is face lean left/right\n };\n };\n */\n\n // initialize gaze and mesh\n const mesh = face.meshRaw;\n if (!mesh || mesh.length < 300) return { angle: { pitch: 0, yaw: 0, roll: 0 }, matrix: [1, 0, 0, 0, 1, 0, 0, 0, 1], gaze: { bearing: 0, strength: 0 } };\n\n const size = Math.max(face.boxRaw[2] * imageSize[0], face.boxRaw[3] * imageSize[1]) / 1.5;\n // top, bottom, left, right\n const pts: Point[] = [mesh[10], mesh[152], mesh[234], mesh[454]].map((pt) => [pt[0] * imageSize[0] / size, pt[1] * imageSize[1] / size, pt[2]] as Point); // make the xyz coordinates proportional, independent of the image/box size\n\n const yAxis = normalize(subVectors(pts[1] as Vector, pts[0] as Vector));\n let xAxis = normalize(subVectors(pts[3] as Vector, pts[2] as Vector));\n const zAxis = normalize(crossVectors(xAxis, yAxis));\n // adjust xAxis to make sure that all axes are perpendicular to each other\n xAxis = crossVectors(yAxis, zAxis);\n\n // Rotation Matrix from Axis Vectors - http://renderdan.blogspot.com/2006/05/rotation-matrix-from-axis-vectors.html\n // 3x3 rotation matrix is flatten to array in row-major order. Note that the rotation represented by this matrix is inverted.\n const matrix: [number, number, number, number, number, number, number, number, number] = [\n xAxis[0], xAxis[1], xAxis[2],\n yAxis[0], yAxis[1], yAxis[2],\n zAxis[0], zAxis[1], zAxis[2],\n ];\n const angle = rotationMatrixToEulerAngle(matrix);\n // const angle = meshToEulerAngle(mesh);\n\n // we have iris keypoints so we can calculate gaze direction\n const gaze = mesh.length === 478 ? calculateGaze(face) : { bearing: 0, strength: 0 };\n\n return { angle, matrix, gaze };\n};\n", "import type { FaceResult } from '../result';\n\nexport function calculateCameraDistance(face: FaceResult, width: number): number {\n // iris points are [center, left, top, right, bottom]\n // average size of human iris is 11.7mm - fairly constant for all ages/genders/races\n const f = face?.annotations;\n if (!f?.leftEyeIris || !f?.rightEyeIris) return 0;\n // get size of left and right iris in pixels, pick larger one as its likely to be more accurate and normalize to 0..1 range instead of pixels\n const irisSize = Math.max(Math.abs(f.leftEyeIris[3][0] - f.leftEyeIris[1][0]), Math.abs(f.rightEyeIris[3][0] - f.rightEyeIris[1][0])) / width;\n // distance of eye from camera in meters\n const cameraDistance = Math.round(1.17 / irisSize) / 100;\n return cameraDistance;\n}\n\nexport function calculateEyesDistance(face: FaceResult, width: number): number {\n // average distance between eyes is 65mm - fairly constant for typical adult male, but varies otherwise\n const f = face?.annotations;\n if (!f?.leftEyeIris || !f?.rightEyeIris) return 0;\n // get size of left and right iris in pixels, pick larger one as its likely to be more accurate and normalize to 0..1 range instead of pixels\n const irisSize = Math.max(Math.abs(f.leftEyeIris[3][0] - f.leftEyeIris[1][0]), Math.abs(f.rightEyeIris[3][0] - f.rightEyeIris[1][0])) / width;\n // pixel x and y distance of centers of left and right iris, you can use edges instead\n const irisDistanceXY = [f.leftEyeIris[0][0] - f.rightEyeIris[0][0], f.leftEyeIris[0][1] - f.rightEyeIris[0][1]];\n // absolute distance bewtween eyes in 0..1 range to account for head pitch (we can ignore yaw)\n const irisDistance = Math.sqrt((irisDistanceXY[0] * irisDistanceXY[0]) + (irisDistanceXY[1] * irisDistanceXY[1])) / width;\n // distance between eyes in meters\n const eyesDistance = Math.round(1.17 * irisDistance / irisSize) / 100;\n return eyesDistance;\n}\n", "/**\n * Face algorithm implementation\n * Uses FaceMesh, Emotion and FaceRes models to create a unified pipeline\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { env } from '../util/env';\nimport * as facemesh from './facemesh';\nimport * as emotion from '../gear/emotion';\nimport * as faceres from './faceres';\nimport * as mask from './mask';\nimport * as antispoof from './antispoof';\nimport * as liveness from './liveness';\nimport * as gear from '../gear/gear';\nimport * as ssrnetAge from '../gear/ssrnet-age';\nimport * as ssrnetGender from '../gear/ssrnet-gender';\nimport * as mobilefacenet from './mobilefacenet';\nimport * as insightface from './insightface';\nimport type { FaceResult, Emotion, Gender, Race } from '../result';\nimport type { Tensor4D } from '../tfjs/types';\nimport type { Human } from '../human';\nimport { calculateFaceAngle } from './angles';\nimport { calculateCameraDistance } from './anthropometry';\n\ninterface DescRes { age: number, gender: Gender, genderScore: number, descriptor: number[], race?: { score: number, race: Race }[] }\n\nexport const detectFace = async (instance: Human /* instance of human */, input: Tensor4D): Promise => {\n // run facemesh, includes blazeface and iris\n let timeStamp: number = now();\n let ageRes: { age: number } | Promise<{ age: number }> | null;\n let gearRes: gear.GearType | Promise | null;\n let genderRes: { gender: string, genderScore: number } | Promise<{ gender: string, genderScore: number }> | null;\n let emotionRes: { score: number, emotion: Emotion }[] | Promise<{ score: number, emotion: Emotion }[]>;\n let mobilefacenetRes: number[] | Promise | null;\n let insightfaceRes: number[] | Promise | null;\n let antispoofRes: number | Promise | null;\n let livenessRes: number | Promise | null;\n let descRes: DescRes | Promise | null;\n\n const faceRes: FaceResult[] = [];\n instance.state = 'run:face';\n const faces: FaceResult[] = await facemesh.predict(input, instance.config);\n instance.performance.face = env.perfadd ? (instance.performance.face || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n if (!input.shape || input.shape.length !== 4) return [];\n if (!faces) return [];\n // for (const face of faces) {\n for (let i = 0; i < faces.length; i++) {\n instance.analyze('Get Face');\n\n // is something went wrong, skip the face\n // @ts-ignore possibly undefied\n if (!faces[i].tensor || faces[i].tensor.isDisposedInternal) {\n log('Face object is disposed:', faces[i].tensor);\n continue;\n }\n\n // optional face mask\n if (instance.config.face.detector?.mask) {\n const masked = await mask.mask(faces[i]);\n tf.dispose(faces[i].tensor);\n if (masked) faces[i].tensor = masked;\n }\n\n // calculate face angles\n const rotation = faces[i].mesh && (faces[i].mesh.length > 200) ? calculateFaceAngle(faces[i], [input.shape[2], input.shape[1]]) : null;\n\n // run emotion, inherits face from blazeface\n instance.analyze('Start Emotion:');\n if (instance.config.async) {\n emotionRes = instance.config.face.emotion?.enabled ? emotion.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : [];\n } else {\n instance.state = 'run:emotion';\n timeStamp = now();\n emotionRes = instance.config.face.emotion?.enabled ? await emotion.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : [];\n instance.performance.emotion = env.perfadd ? (instance.performance.emotion || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End Emotion:');\n\n // run antispoof, inherits face from blazeface\n instance.analyze('Start AntiSpoof:');\n if (instance.config.async) {\n antispoofRes = instance.config.face.antispoof?.enabled ? antispoof.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n } else {\n instance.state = 'run:antispoof';\n timeStamp = now();\n antispoofRes = instance.config.face.antispoof?.enabled ? await antispoof.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n instance.performance.antispoof = env.perfadd ? (instance.performance.antispoof || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End AntiSpoof:');\n\n // run liveness, inherits face from blazeface\n instance.analyze('Start Liveness:');\n if (instance.config.async) {\n livenessRes = instance.config.face.liveness?.enabled ? liveness.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n } else {\n instance.state = 'run:liveness';\n timeStamp = now();\n livenessRes = instance.config.face.liveness?.enabled ? await liveness.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n instance.performance.liveness = env.perfadd ? (instance.performance.antispoof || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End Liveness:');\n\n // run gear, inherits face from blazeface\n instance.analyze('Start GEAR:');\n if (instance.config.async) {\n gearRes = instance.config.face.gear?.enabled ? gear.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:gear';\n timeStamp = now();\n gearRes = instance.config.face.gear?.enabled ? await gear.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.gear = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End GEAR:');\n\n // run gear, inherits face from blazeface\n instance.analyze('Start SSRNet:');\n if (instance.config.async) {\n ageRes = instance.config.face['ssrnet']?.enabled ? ssrnetAge.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n genderRes = instance.config.face['ssrnet']?.enabled ? ssrnetGender.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:ssrnet';\n timeStamp = now();\n ageRes = instance.config.face['ssrnet']?.enabled ? await ssrnetAge.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n genderRes = instance.config.face['ssrnet']?.enabled ? await ssrnetGender.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.ssrnet = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End SSRNet:');\n\n // run mobilefacenet alternative, inherits face from blazeface\n instance.analyze('Start MobileFaceNet:');\n if (instance.config.async) {\n mobilefacenetRes = instance.config.face['mobilefacenet']?.enabled ? mobilefacenet.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:mobilefacenet';\n timeStamp = now();\n mobilefacenetRes = instance.config.face['mobilefacenet']?.enabled ? await mobilefacenet.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.mobilefacenet = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End MobileFaceNet:');\n\n // run insightface alternative, inherits face from blazeface\n instance.analyze('Start InsightFace:');\n if (instance.config.async) {\n insightfaceRes = instance.config.face['insightface']?.enabled ? insightface.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:mobilefacenet';\n timeStamp = now();\n insightfaceRes = instance.config.face['insightface']?.enabled ? await insightface.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.mobilefacenet = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End InsightFace:');\n\n // run faceres, inherits face from blazeface\n instance.analyze('Start Description:');\n if (instance.config.async) {\n descRes = faceres.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length);\n } else {\n instance.state = 'run:description';\n timeStamp = now();\n descRes = await faceres.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length);\n instance.performance.description = env.perfadd ? (instance.performance.description || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End Description:');\n\n // if async wait for results\n if (instance.config.async) {\n [ageRes, genderRes, emotionRes, mobilefacenetRes, insightfaceRes, descRes, gearRes, antispoofRes, livenessRes] = await Promise.all([ageRes, genderRes, emotionRes, mobilefacenetRes, insightfaceRes, descRes, gearRes, antispoofRes, livenessRes]);\n }\n instance.analyze('Finish Face:');\n\n if (instance.config.face['ssrnet']?.enabled && ageRes && genderRes) { // override age/gender if ssrnet model is used\n descRes = {\n ...(descRes as DescRes),\n age: (ageRes as { age: number}).age,\n gender: (genderRes as { gender: Gender, genderScore: number }).gender,\n genderScore: (genderRes as { gender: Gender, genderScore: number }).genderScore,\n };\n }\n if (instance.config.face.gear?.enabled && gearRes) { // override age/gender/race if gear model is used\n descRes = {\n ...(descRes as DescRes),\n age: (gearRes as gear.GearType).age,\n gender: (gearRes as gear.GearType).gender,\n genderScore: (gearRes as gear.GearType).genderScore,\n race: (gearRes as gear.GearType).race,\n };\n }\n if (instance.config.face['mobilefacenet']?.enabled && mobilefacenetRes) { // override descriptor if mobilefacenet model is used\n (descRes as DescRes).descriptor = mobilefacenetRes as number[];\n }\n\n if (instance.config.face['insightface']?.enabled && insightfaceRes) { // override descriptor if insightface model is used\n (descRes as DescRes).descriptor = insightfaceRes as number[];\n }\n\n const irisSize = instance.config.face.iris?.enabled ? calculateCameraDistance(faces[i], input.shape[2]) : 0;\n\n // optionally return tensor\n const tensor = instance.config.face.detector?.return ? tf.squeeze(faces[i].tensor as Tensor4D) : null;\n // dispose original face tensor\n tf.dispose(faces[i].tensor);\n // delete temp face image\n if (faces[i].tensor) delete faces[i].tensor;\n // combine results\n const res: FaceResult = {\n ...faces[i],\n id: i,\n };\n if ((descRes as DescRes).age) res.age = (descRes as DescRes).age;\n if ((descRes as DescRes).gender) res.gender = (descRes as DescRes).gender;\n if ((descRes as DescRes).genderScore) res.genderScore = (descRes as DescRes).genderScore;\n if ((descRes as DescRes).descriptor) res.embedding = (descRes as DescRes).descriptor;\n if ((descRes as DescRes).race) res.race = (descRes as DescRes).race as { score: number, race: Race }[];\n if (emotionRes) res.emotion = emotionRes as { score: number, emotion: Emotion }[];\n if (antispoofRes) res.real = antispoofRes as number;\n if (livenessRes) res.live = livenessRes as number;\n if (irisSize > 0) res.distance = irisSize;\n if (rotation) res.rotation = rotation;\n if (tensor) res.tensor = tensor;\n faceRes.push(res);\n instance.analyze('End Face');\n }\n instance.analyze('End FaceMesh:');\n if (instance.config.async) {\n if (instance.performance.face) delete instance.performance.face;\n if (instance.performance.age) delete instance.performance.age;\n if (instance.performance.gender) delete instance.performance.gender;\n if (instance.performance.emotion) delete instance.performance.emotion;\n }\n return faceRes;\n};\n", "/**\n * FingerPose algorithm implementation\n * See `fingerpose.ts` for entry point\n */\n\nexport const Finger = {\n thumb: 0,\n index: 1,\n middle: 2,\n ring: 3,\n pinky: 4,\n all: [0, 1, 2, 3, 4], // just for convenience\n nameMapping: { 0: 'thumb', 1: 'index', 2: 'middle', 3: 'ring', 4: 'pinky' },\n // Describes mapping of joints based on the 21 points returned by handpose.\n // [0] Palm\n // [1-4] Thumb\n // [5-8] Index\n // [9-12] Middle\n // [13-16] Ring\n // [17-20] Pinky\n pointsMapping: {\n 0: [[0, 1], [1, 2], [2, 3], [3, 4]],\n 1: [[0, 5], [5, 6], [6, 7], [7, 8]],\n 2: [[0, 9], [9, 10], [10, 11], [11, 12]],\n 3: [[0, 13], [13, 14], [14, 15], [15, 16]],\n 4: [[0, 17], [17, 18], [18, 19], [19, 20]],\n },\n getName: (value) => Finger.nameMapping[value],\n getPoints: (value) => Finger.pointsMapping[value],\n};\n\nexport const FingerCurl = {\n none: 0,\n half: 1,\n full: 2,\n nameMapping: { 0: 'none', 1: 'half', 2: 'full' },\n getName: (value) => FingerCurl.nameMapping[value],\n};\n\nexport const FingerDirection = {\n verticalUp: 0,\n verticalDown: 1,\n horizontalLeft: 2,\n horizontalRight: 3,\n diagonalUpRight: 4,\n diagonalUpLeft: 5,\n diagonalDownRight: 6,\n diagonalDownLeft: 7,\n nameMapping: { 0: 'verticalUp', 1: 'verticalDown', 2: 'horizontalLeft', 3: 'horizontalRight', 4: 'diagonalUpRight', 5: 'diagonalUpLeft', 6: 'diagonalDownRight', 7: 'diagonalDownLeft' },\n getName: (value) => FingerDirection.nameMapping[value],\n};\n\nexport class FingerGesture {\n name;\n curls;\n directions;\n weights;\n weightsRelative;\n\n constructor(name) {\n // name (should be unique)\n this.name = name;\n this.curls = {};\n this.directions = {};\n this.weights = [1.0, 1.0, 1.0, 1.0, 1.0];\n this.weightsRelative = [1.0, 1.0, 1.0, 1.0, 1.0];\n }\n\n curl(finger, curl, confidence) {\n if (typeof this.curls[finger] === 'undefined') this.curls[finger] = [];\n this.curls[finger].push([curl, confidence]);\n }\n\n direction(finger, position, confidence) {\n if (!this.directions[finger]) this.directions[finger] = [];\n this.directions[finger].push([position, confidence]);\n }\n\n weight(finger, weight) {\n this.weights[finger] = weight;\n // recalculate relative weights\n const total = this.weights.reduce((a, b) => a + b, 0);\n this.weightsRelative = this.weights.map((el) => el * 5 / total);\n }\n\n matchAgainst(detectedCurls, detectedDirections) {\n let confidence = 0.0;\n // look at the detected curl of each finger and compare with\n // the expected curl of this finger inside current gesture\n for (const fingerIdx in detectedCurls) {\n const detectedCurl = detectedCurls[fingerIdx];\n const expectedCurls = this.curls[fingerIdx];\n if (typeof expectedCurls === 'undefined') {\n // no curl description available for this finger\n // add default confidence of \"1\"\n confidence += this.weightsRelative[fingerIdx];\n continue;\n }\n // compare to each possible curl of this specific finger\n for (const [expectedCurl, score] of expectedCurls) {\n if (detectedCurl === expectedCurl) {\n confidence += score * this.weightsRelative[fingerIdx];\n break;\n }\n }\n }\n // same for detected direction of each finger\n for (const fingerIdx in detectedDirections) {\n const detectedDirection = detectedDirections[fingerIdx];\n const expectedDirections = this.directions[fingerIdx];\n if (typeof expectedDirections === 'undefined') {\n // no direction description available for this finger\n // add default confidence of \"1\"\n confidence += this.weightsRelative[fingerIdx];\n continue;\n }\n // compare to each possible direction of this specific finger\n for (const [expectedDirection, score] of expectedDirections) {\n if (detectedDirection === expectedDirection) {\n confidence += score * this.weightsRelative[fingerIdx];\n break;\n }\n }\n }\n return confidence / 10;\n }\n}\n", "/**\n * FingerPose algorithm implementation\n * See `fingerpose.ts` for entry point\n */\n\nimport { Finger, FingerCurl, FingerDirection, FingerGesture } from './fingerdef';\n\nexport const { thumb, index, middle, ring, pinky } = Finger;\nexport const { none, half, full } = FingerCurl;\nexport const { verticalUp, verticalDown, horizontalLeft, horizontalRight, diagonalUpRight, diagonalUpLeft, diagonalDownRight, diagonalDownLeft } = FingerDirection;\n\n// describe thumbs up gesture \uD83D\uDC4D\nconst ThumbsUp = new FingerGesture('thumbs up');\nThumbsUp.curl(thumb, none, 1.0);\nThumbsUp.direction(thumb, verticalUp, 1.0);\nThumbsUp.direction(thumb, diagonalUpLeft, 0.25);\nThumbsUp.direction(thumb, diagonalUpRight, 0.25);\nfor (const finger of [Finger.index, Finger.middle, Finger.ring, Finger.pinky]) {\n ThumbsUp.curl(finger, full, 1.0);\n ThumbsUp.direction(finger, horizontalLeft, 1.0);\n ThumbsUp.direction(finger, horizontalRight, 1.0);\n}\n\n// describe Victory gesture \u270C\uFE0F\nconst Victory = new FingerGesture('victory');\nVictory.curl(thumb, half, 0.5);\nVictory.curl(thumb, none, 0.5);\nVictory.direction(thumb, verticalUp, 1.0);\nVictory.direction(thumb, diagonalUpLeft, 1.0);\nVictory.curl(index, none, 1.0);\nVictory.direction(index, verticalUp, 0.75);\nVictory.direction(index, diagonalUpLeft, 1.0);\nVictory.curl(middle, none, 1.0);\nVictory.direction(middle, verticalUp, 1.0);\nVictory.direction(middle, diagonalUpLeft, 0.75);\nVictory.curl(ring, full, 1.0);\nVictory.direction(ring, verticalUp, 0.2);\nVictory.direction(ring, diagonalUpLeft, 1.0);\nVictory.direction(ring, horizontalLeft, 0.2);\nVictory.curl(pinky, full, 1.0);\nVictory.direction(pinky, verticalUp, 0.2);\nVictory.direction(pinky, diagonalUpLeft, 1.0);\nVictory.direction(pinky, horizontalLeft, 0.2);\nVictory.weight(index, 2);\nVictory.weight(middle, 2);\n\n// describe Point gesture \u270C\uFE0F\nconst Point = new FingerGesture('point');\nPoint.curl(thumb, full, 1.0);\nPoint.curl(index, none, 0.5);\nPoint.curl(middle, full, 0.5);\nPoint.curl(ring, full, 0.5);\nPoint.curl(pinky, full, 0.5);\nPoint.weight(index, 2);\nPoint.weight(middle, 2);\n\n// describe Point gesture \u270C\uFE0F\nconst MiddleFinger = new FingerGesture('middle finger');\nMiddleFinger.curl(thumb, none, 1.0);\nMiddleFinger.curl(index, full, 0.5);\nMiddleFinger.curl(middle, full, 0.5);\nMiddleFinger.curl(ring, full, 0.5);\nMiddleFinger.curl(pinky, full, 0.5);\nMiddleFinger.weight(index, 2);\nMiddleFinger.weight(middle, 2);\n\n// describe Open Palm gesture \u270C\uFE0F\nconst OpenPalm = new FingerGesture('open palm');\nOpenPalm.curl(thumb, none, 0.75);\nOpenPalm.curl(index, none, 0.75);\nOpenPalm.curl(middle, none, 0.75);\nOpenPalm.curl(ring, none, 0.75);\nOpenPalm.curl(pinky, none, 0.75);\n\nexport default [ThumbsUp, Victory, Point, MiddleFinger, OpenPalm];\n", "/**\n * FingerPose algorithm implementation constants\n *\n * Based on: [**FingerPose***](https://github.com/andypotato/fingerpose)\n */\n\n/* eslint-disable camelcase */\n\nimport { Finger, FingerCurl, FingerDirection } from './fingerdef';\nimport Gestures from '../hand/fingergesture';\n\nconst minConfidence = 0.7;\nconst options = {\n // curl estimation\n HALF_CURL_START_LIMIT: 60.0,\n NO_CURL_START_LIMIT: 130.0,\n // direction estimation\n DISTANCE_VOTE_POWER: 1.1,\n SINGLE_ANGLE_VOTE_POWER: 0.9,\n TOTAL_ANGLE_VOTE_POWER: 1.6,\n};\n\nfunction calculateSlope(point1x, point1y, point2x, point2y) {\n const value = (point1y - point2y) / (point1x - point2x);\n let slope = Math.atan(value) * 180 / Math.PI;\n if (slope <= 0) slope = -slope;\n else if (slope > 0) slope = 180 - slope;\n return slope;\n}\n\n// point1, point2 are 2d or 3d point arrays (xy[z])\n// returns either a single scalar (2d) or array of two slopes (3d)\nfunction getSlopes(point1, point2) {\n if (!point1 || !point2) return [0, 0];\n const slopeXY = calculateSlope(point1[0], point1[1], point2[0], point2[1]);\n if (point1.length === 2) return slopeXY;\n const slopeYZ = calculateSlope(point1[1], point1[2], point2[1], point2[2]);\n return [slopeXY, slopeYZ];\n}\n\nfunction angleOrientationAt(angle, weightageAt = 1.0) {\n let isVertical = 0;\n let isDiagonal = 0;\n let isHorizontal = 0;\n if (angle >= 75.0 && angle <= 105.0) isVertical = 1 * weightageAt;\n else if (angle >= 25.0 && angle <= 155.0) isDiagonal = 1 * weightageAt;\n else isHorizontal = 1 * weightageAt;\n return [isVertical, isDiagonal, isHorizontal];\n}\n\nfunction estimateFingerCurl(startPoint, midPoint, endPoint) {\n const start_mid_x_dist = startPoint[0] - midPoint[0];\n const start_end_x_dist = startPoint[0] - endPoint[0];\n const mid_end_x_dist = midPoint[0] - endPoint[0];\n const start_mid_y_dist = startPoint[1] - midPoint[1];\n const start_end_y_dist = startPoint[1] - endPoint[1];\n const mid_end_y_dist = midPoint[1] - endPoint[1];\n const start_mid_z_dist = startPoint[2] - midPoint[2];\n const start_end_z_dist = startPoint[2] - endPoint[2];\n const mid_end_z_dist = midPoint[2] - endPoint[2];\n const start_mid_dist = Math.sqrt(start_mid_x_dist * start_mid_x_dist + start_mid_y_dist * start_mid_y_dist + start_mid_z_dist * start_mid_z_dist);\n const start_end_dist = Math.sqrt(start_end_x_dist * start_end_x_dist + start_end_y_dist * start_end_y_dist + start_end_z_dist * start_end_z_dist);\n const mid_end_dist = Math.sqrt(mid_end_x_dist * mid_end_x_dist + mid_end_y_dist * mid_end_y_dist + mid_end_z_dist * mid_end_z_dist);\n let cos_in = (mid_end_dist * mid_end_dist + start_mid_dist * start_mid_dist - start_end_dist * start_end_dist) / (2 * mid_end_dist * start_mid_dist);\n if (cos_in > 1.0) cos_in = 1.0;\n else if (cos_in < -1.0) cos_in = -1.0;\n let angleOfCurve = Math.acos(cos_in);\n angleOfCurve = (57.2958 * angleOfCurve) % 180;\n let fingerCurl;\n if (angleOfCurve > options.NO_CURL_START_LIMIT) fingerCurl = FingerCurl.none;\n else if (angleOfCurve > options.HALF_CURL_START_LIMIT) fingerCurl = FingerCurl.half;\n else fingerCurl = FingerCurl.full;\n return fingerCurl;\n}\n\nfunction estimateHorizontalDirection(start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x) {\n let estimatedDirection;\n if (max_dist_x === Math.abs(start_end_x_dist)) {\n if (start_end_x_dist > 0) estimatedDirection = FingerDirection.horizontalLeft;\n else estimatedDirection = FingerDirection.horizontalRight;\n } else if (max_dist_x === Math.abs(start_mid_x_dist)) {\n if (start_mid_x_dist > 0) estimatedDirection = FingerDirection.horizontalLeft;\n else estimatedDirection = FingerDirection.horizontalRight;\n } else {\n if (mid_end_x_dist > 0) estimatedDirection = FingerDirection.horizontalLeft;\n else estimatedDirection = FingerDirection.horizontalRight;\n }\n return estimatedDirection;\n}\n\nfunction estimateVerticalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y) {\n let estimatedDirection;\n if (max_dist_y === Math.abs(start_end_y_dist)) {\n if (start_end_y_dist < 0) estimatedDirection = FingerDirection.verticalDown;\n else estimatedDirection = FingerDirection.verticalUp;\n } else if (max_dist_y === Math.abs(start_mid_y_dist)) {\n if (start_mid_y_dist < 0) estimatedDirection = FingerDirection.verticalDown;\n else estimatedDirection = FingerDirection.verticalUp;\n } else {\n if (mid_end_y_dist < 0) estimatedDirection = FingerDirection.verticalDown;\n else estimatedDirection = FingerDirection.verticalUp;\n }\n return estimatedDirection;\n}\n\nfunction estimateDiagonalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y, start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x) {\n let estimatedDirection;\n const reqd_vertical_direction = estimateVerticalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y);\n const reqd_horizontal_direction = estimateHorizontalDirection(start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x);\n if (reqd_vertical_direction === FingerDirection.verticalUp) {\n if (reqd_horizontal_direction === FingerDirection.horizontalLeft) estimatedDirection = FingerDirection.diagonalUpLeft;\n else estimatedDirection = FingerDirection.diagonalUpRight;\n } else {\n if (reqd_horizontal_direction === FingerDirection.horizontalLeft) estimatedDirection = FingerDirection.diagonalDownLeft;\n else estimatedDirection = FingerDirection.diagonalDownRight;\n }\n return estimatedDirection;\n}\n\nfunction calculateFingerDirection(startPoint, midPoint, endPoint, fingerSlopes) {\n const start_mid_x_dist = startPoint[0] - midPoint[0];\n const start_end_x_dist = startPoint[0] - endPoint[0];\n const mid_end_x_dist = midPoint[0] - endPoint[0];\n const start_mid_y_dist = startPoint[1] - midPoint[1];\n const start_end_y_dist = startPoint[1] - endPoint[1];\n const mid_end_y_dist = midPoint[1] - endPoint[1];\n const max_dist_x = Math.max(Math.abs(start_mid_x_dist), Math.abs(start_end_x_dist), Math.abs(mid_end_x_dist));\n const max_dist_y = Math.max(Math.abs(start_mid_y_dist), Math.abs(start_end_y_dist), Math.abs(mid_end_y_dist));\n let voteVertical = 0.0;\n let voteDiagonal = 0.0;\n let voteHorizontal = 0.0;\n const start_end_x_y_dist_ratio = max_dist_y / (max_dist_x + 0.00001);\n if (start_end_x_y_dist_ratio > 1.5) voteVertical += options.DISTANCE_VOTE_POWER;\n else if (start_end_x_y_dist_ratio > 0.66) voteDiagonal += options.DISTANCE_VOTE_POWER;\n else voteHorizontal += options.DISTANCE_VOTE_POWER;\n const start_mid_dist = Math.sqrt(start_mid_x_dist * start_mid_x_dist + start_mid_y_dist * start_mid_y_dist);\n const start_end_dist = Math.sqrt(start_end_x_dist * start_end_x_dist + start_end_y_dist * start_end_y_dist);\n const mid_end_dist = Math.sqrt(mid_end_x_dist * mid_end_x_dist + mid_end_y_dist * mid_end_y_dist);\n const max_dist = Math.max(start_mid_dist, start_end_dist, mid_end_dist);\n let calc_start_point_x = startPoint[0];\n let calc_start_point_y = startPoint[1];\n let calc_end_point_x = endPoint[0];\n let calc_end_point_y = endPoint[1];\n if (max_dist === start_mid_dist) {\n calc_end_point_x = endPoint[0];\n calc_end_point_y = endPoint[1];\n } else if (max_dist === mid_end_dist) {\n calc_start_point_x = midPoint[0];\n calc_start_point_y = midPoint[1];\n }\n const calcStartPoint = [calc_start_point_x, calc_start_point_y];\n const calcEndPoint = [calc_end_point_x, calc_end_point_y];\n const totalAngle = getSlopes(calcStartPoint, calcEndPoint);\n const votes = angleOrientationAt(totalAngle, options.TOTAL_ANGLE_VOTE_POWER);\n voteVertical += votes[0];\n voteDiagonal += votes[1];\n voteHorizontal += votes[2];\n for (const fingerSlope of fingerSlopes) {\n const fingerVotes = angleOrientationAt(fingerSlope, options.SINGLE_ANGLE_VOTE_POWER);\n voteVertical += fingerVotes[0];\n voteDiagonal += fingerVotes[1];\n voteHorizontal += fingerVotes[2];\n }\n // in case of tie, highest preference goes to Vertical,\n // followed by horizontal and then diagonal\n let estimatedDirection;\n if (voteVertical === Math.max(voteVertical, voteDiagonal, voteHorizontal)) {\n estimatedDirection = estimateVerticalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y);\n } else if (voteHorizontal === Math.max(voteDiagonal, voteHorizontal)) {\n estimatedDirection = estimateHorizontalDirection(start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x);\n } else {\n estimatedDirection = estimateDiagonalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y, start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x);\n }\n return estimatedDirection;\n}\n\nfunction estimate(landmarks) {\n // step 1: calculate slopes\n const slopesXY: number[][] = [];\n const slopesYZ: number[][] = [];\n const fingerCurls: number[] = [];\n const fingerDirections: number[] = [];\n if (!landmarks) return { curls: fingerCurls, directions: fingerDirections };\n\n // step 1: calculate slopes\n for (const finger of Finger.all) {\n const points = Finger.getPoints(finger);\n const slopeAtXY: number[] = [];\n const slopeAtYZ: number[] = [];\n for (const point of points) {\n const point1 = landmarks[point[0]];\n const point2 = landmarks[point[1]];\n // calculate single slope\n const slopes = getSlopes(point1, point2);\n const slopeXY = slopes[0];\n const slopeYZ = slopes[1];\n slopeAtXY.push(slopeXY);\n slopeAtYZ.push(slopeYZ);\n }\n slopesXY.push(slopeAtXY);\n slopesYZ.push(slopeAtYZ);\n }\n\n // step 2: calculate orientations\n for (const finger of Finger.all) {\n // start finger predictions from palm - except for thumb\n const pointIndexAt = (finger === Finger.thumb) ? 1 : 0;\n const fingerPointsAt = Finger.getPoints(finger);\n const startPoint = landmarks[fingerPointsAt[pointIndexAt][0]];\n const midPoint = landmarks[fingerPointsAt[pointIndexAt + 1][1]];\n const endPoint = landmarks[fingerPointsAt[3][1]];\n // check if finger is curled\n const fingerCurled = estimateFingerCurl(startPoint, midPoint, endPoint);\n const fingerPosition = calculateFingerDirection(startPoint, midPoint, endPoint, slopesXY[finger].slice(pointIndexAt));\n fingerCurls[finger] = fingerCurled;\n fingerDirections[finger] = fingerPosition;\n }\n return { curls: fingerCurls, directions: fingerDirections };\n}\n\nexport function analyze(keypoints) { // get estimations of curl / direction for each finger\n if (!keypoints || keypoints.length === 0) return null;\n const estimatorRes = estimate(keypoints);\n const landmarks = {};\n for (const fingerIdx of Finger.all) {\n landmarks[Finger.getName(fingerIdx)] = {\n curl: FingerCurl.getName(estimatorRes.curls[fingerIdx]),\n direction: FingerDirection.getName(estimatorRes.directions[fingerIdx]),\n };\n }\n return landmarks;\n}\n\nexport function match(keypoints) { // compare gesture description to each known gesture\n const poses: { name: string, confidence: number }[] = [];\n if (!keypoints || keypoints.length === 0) return poses;\n const estimatorRes = estimate(keypoints);\n for (const gesture of Gestures) {\n const confidence = gesture.matchAgainst(estimatorRes.curls, estimatorRes.directions);\n if (confidence >= minConfidence) poses.push({ name: gesture.name, confidence });\n }\n return poses;\n}\n", "/**\n * Gesture detection algorithm\n */\n\nimport type { GestureResult, BodyResult, FaceResult, HandResult, Point } from '../result';\nimport * as fingerPose from '../hand/fingerpose';\n\n/** face gesture type */\nexport type FaceGesture =\n `facing ${'left' | 'center' | 'right'}`\n | `blink ${'left' | 'right'} eye`\n | `mouth ${number}% open`\n | `head ${'up' | 'down'}`;\n\n/** iris gesture type */\nexport type IrisGesture =\n 'facing center'\n | `looking ${'left' | 'right' | 'up' | 'down'}`\n | 'looking center';\n\n/** body gesture type */\nexport type BodyGesture =\n `leaning ${'left' | 'right'}`\n | `raise ${'left' | 'right'} hand`\n | 'i give up';\n\n/** hand gesture type */\nexport type HandGesture =\n `${'thumb' | 'index' | 'middle' | 'ring' | 'pinky'} forward`\n | `${'thumb' | 'index' | 'middle' | 'ring' | 'pinky'} up`\n | 'victory'\n | 'thumbs up';\n\nexport const body = (res: BodyResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { body: number, gesture: BodyGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n // raising hands\n const leftWrist = res[i].keypoints.find((a) => (a.part === 'leftWrist'));\n const rightWrist = res[i].keypoints.find((a) => (a.part === 'rightWrist'));\n const nose = res[i].keypoints.find((a) => (a.part === 'nose'));\n if (nose && leftWrist && rightWrist && (leftWrist.position[1] < nose.position[1]) && (rightWrist.position[1] < nose.position[1])) gestures.push({ body: i, gesture: 'i give up' });\n else if (nose && leftWrist && (leftWrist.position[1] < nose.position[1])) gestures.push({ body: i, gesture: 'raise left hand' });\n else if (nose && rightWrist && (rightWrist.position[1] < nose.position[1])) gestures.push({ body: i, gesture: 'raise right hand' });\n\n // leaning\n const leftShoulder = res[i].keypoints.find((a) => (a.part === 'leftShoulder'));\n const rightShoulder = res[i].keypoints.find((a) => (a.part === 'rightShoulder'));\n if (leftShoulder && rightShoulder && Math.abs(leftShoulder.positionRaw[1] - rightShoulder.positionRaw[1]) > 0.1) {\n gestures.push({ body: i, gesture: `leaning ${(leftShoulder.position[1] > rightShoulder.position[1]) ? 'left' : 'right'}` });\n }\n }\n return gestures;\n};\n\nexport const face = (res: FaceResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { face: number, gesture: FaceGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n if (res[i].mesh && res[i].mesh.length > 450) {\n const zDiff = (res[i].mesh[33][2] || 0) - (res[i].mesh[263][2] || 0);\n const xDiff = res[i].mesh[33][0] - res[i].mesh[263][0];\n if (Math.abs(zDiff / xDiff) <= 0.15) gestures.push({ face: i, gesture: 'facing center' });\n else gestures.push({ face: i, gesture: `facing ${zDiff < 0 ? 'left' : 'right'}` });\n const openLeft = Math.abs(res[i].mesh[374][1] - res[i].mesh[386][1]) / Math.abs(res[i].mesh[443][1] - res[i].mesh[450][1]); // center of eye inner lid y coord div center of wider eye border y coord\n if (openLeft < 0.2) gestures.push({ face: i, gesture: 'blink left eye' });\n const openRight = Math.abs(res[i].mesh[145][1] - res[i].mesh[159][1]) / Math.abs(res[i].mesh[223][1] - res[i].mesh[230][1]); // center of eye inner lid y coord div center of wider eye border y coord\n if (openRight < 0.2) gestures.push({ face: i, gesture: 'blink right eye' });\n const mouthOpen = Math.min(100, 500 * Math.abs(res[i].mesh[13][1] - res[i].mesh[14][1]) / Math.abs(res[i].mesh[10][1] - res[i].mesh[152][1]));\n if (mouthOpen > 10) gestures.push({ face: i, gesture: `mouth ${Math.trunc(mouthOpen)}% open` });\n const chinDepth = res[i].mesh[152][2] || 0;\n if (Math.abs(chinDepth) > 10) gestures.push({ face: i, gesture: `head ${chinDepth < 0 ? 'up' : 'down'}` });\n }\n }\n return gestures;\n};\n\nexport const iris = (res: FaceResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { iris: number, gesture: IrisGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n if (!res[i].annotations?.leftEyeIris?.[0] || !res[i].annotations?.rightEyeIris?.[0]) continue;\n const sizeXLeft = res[i].annotations.leftEyeIris[3][0] - res[i].annotations.leftEyeIris[1][0];\n const sizeYLeft = res[i].annotations.leftEyeIris[4][1] - res[i].annotations.leftEyeIris[2][1];\n const areaLeft = Math.abs(sizeXLeft * sizeYLeft);\n\n const sizeXRight = res[i].annotations.rightEyeIris[3][0] - res[i].annotations.rightEyeIris[1][0];\n const sizeYRight = res[i].annotations.rightEyeIris[4][1] - res[i].annotations.rightEyeIris[2][1];\n const areaRight = Math.abs(sizeXRight * sizeYRight);\n\n let center = false;\n const difference = Math.abs(areaLeft - areaRight) / Math.max(areaLeft, areaRight);\n if (difference < 0.25) {\n center = true;\n gestures.push({ iris: i, gesture: 'facing center' });\n }\n\n const leftIrisCenterX = Math.abs(res[i].mesh[263][0] - res[i].annotations.leftEyeIris[0][0]) / res[i].box[2];\n const rightIrisCenterX = Math.abs(res[i].mesh[33][0] - res[i].annotations.rightEyeIris[0][0]) / res[i].box[2];\n if (leftIrisCenterX > 0.06 || rightIrisCenterX > 0.06) center = false;\n if (leftIrisCenterX > rightIrisCenterX) { // check eye with bigger offset\n if (rightIrisCenterX > 0.04) gestures.push({ iris: i, gesture: 'looking right' });\n } else {\n if (leftIrisCenterX > 0.04) gestures.push({ iris: i, gesture: 'looking left' });\n }\n\n const rightIrisCenterY = Math.abs(res[i].mesh[145][1] - res[i].annotations.rightEyeIris[0][1]) / res[i].box[3];\n const leftIrisCenterY = Math.abs(res[i].mesh[374][1] - res[i].annotations.leftEyeIris[0][1]) / res[i].box[3];\n if (leftIrisCenterY < 0.01 || rightIrisCenterY < 0.01 || leftIrisCenterY > 0.022 || rightIrisCenterY > 0.022) center = false;\n if (leftIrisCenterY < 0.01 || rightIrisCenterY < 0.01) gestures.push({ iris: i, gesture: 'looking down' });\n if (leftIrisCenterY > 0.022 || rightIrisCenterY > 0.022) gestures.push({ iris: i, gesture: 'looking up' });\n\n // still center;\n if (center) gestures.push({ iris: i, gesture: 'looking center' });\n }\n return gestures;\n};\n\nexport const hand = (res: HandResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { hand: number, gesture: HandGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n const fingers: { name: string, position: Point }[] = [];\n if (res[i].annotations) {\n for (const [finger, pos] of Object.entries(res[i].annotations)) {\n if (finger !== 'palmBase' && Array.isArray(pos) && pos[0]) fingers.push({ name: finger.toLowerCase(), position: pos[0] }); // get tip of each finger\n }\n }\n if (fingers && fingers.length > 0) {\n const closest = fingers.reduce((best, a) => ((best.position[2] || 0) < (a.position[2] || 0) ? best : a));\n gestures.push({ hand: i, gesture: `${closest.name} forward` as HandGesture });\n const highest = fingers.reduce((best, a) => (best.position[1] < a.position[1] ? best : a));\n gestures.push({ hand: i, gesture: `${highest.name} up` as HandGesture });\n }\n if (res[i].keypoints) {\n const poses = fingerPose.match(res[i].keypoints);\n for (const pose of poses) gestures.push({ hand: i, gesture: pose.name as HandGesture });\n }\n }\n return gestures;\n};\n", "import * as tf from 'dist/tfjs.esm.js';\nimport type { Point } from '../result';\n\nexport function getBoxSize(box) {\n return [\n Math.abs(box.endPoint[0] - box.startPoint[0]),\n Math.abs(box.endPoint[1] - box.startPoint[1]),\n ];\n}\n\nexport function getBoxCenter(box) {\n return [\n box.startPoint[0] + (box.endPoint[0] - box.startPoint[0]) / 2,\n box.startPoint[1] + (box.endPoint[1] - box.startPoint[1]) / 2,\n ];\n}\n\nexport function cutBoxFromImageAndResize(box, image, cropSize) {\n const h = image.shape[1];\n const w = image.shape[2];\n const boxes = [[\n box.startPoint[1] / h,\n box.startPoint[0] / w,\n box.endPoint[1] / h,\n box.endPoint[0] / w,\n ]];\n return tf.image.cropAndResize(image, boxes, [0], cropSize);\n}\n\nexport function scaleBoxCoordinates(box, factor) {\n const startPoint = [box.startPoint[0] * factor[0], box.startPoint[1] * factor[1]] as Point;\n const endPoint = [box.endPoint[0] * factor[0], box.endPoint[1] * factor[1]] as Point;\n const palmLandmarks = box.palmLandmarks.map((coord) => {\n const scaledCoord = [coord[0] * factor[0], coord[1] * factor[1]];\n return scaledCoord;\n });\n return { startPoint, endPoint, palmLandmarks, confidence: box.confidence };\n}\n\nexport function enlargeBox(box, factor = 1.5) {\n const center = getBoxCenter(box);\n const size = getBoxSize(box);\n const newHalfSize = [factor * size[0] / 2, factor * size[1] / 2];\n const startPoint = [center[0] - newHalfSize[0], center[1] - newHalfSize[1]] as Point;\n const endPoint = [center[0] + newHalfSize[0], center[1] + newHalfSize[1]] as Point;\n return { startPoint, endPoint, palmLandmarks: box.palmLandmarks };\n}\n\nexport function squarifyBox(box) {\n const centers = getBoxCenter(box);\n const size = getBoxSize(box);\n const maxEdge = Math.max(...size);\n const halfSize = maxEdge / 2;\n const startPoint = [centers[0] - halfSize, centers[1] - halfSize] as Point;\n const endPoint = [centers[0] + halfSize, centers[1] + halfSize] as Point;\n return { startPoint, endPoint, palmLandmarks: box.palmLandmarks };\n}\n\nexport function shiftBox(box, shiftFactor) {\n const boxSize = [\n box.endPoint[0] - box.startPoint[0],\n box.endPoint[1] - box.startPoint[1],\n ];\n const shiftVector = [boxSize[0] * shiftFactor[0], boxSize[1] * shiftFactor[1]];\n const startPoint = [box.startPoint[0] + shiftVector[0], box.startPoint[1] + shiftVector[1]] as Point;\n const endPoint = [box.endPoint[0] + shiftVector[0], box.endPoint[1] + shiftVector[1]] as Point;\n return { startPoint, endPoint, palmLandmarks: box.palmLandmarks };\n}\n\nexport function normalizeRadians(angle) {\n return angle - 2 * Math.PI * Math.floor((angle + Math.PI) / (2 * Math.PI));\n}\n\nexport function computeRotation(point1, point2) {\n const radians = Math.PI / 2 - Math.atan2(-(point2[1] - point1[1]), point2[0] - point1[0]);\n return normalizeRadians(radians);\n}\n\nexport const buildTranslationMatrix = (x, y) => [[1, 0, x], [0, 1, y], [0, 0, 1]];\n\nexport function dot(v1, v2) {\n let product = 0;\n for (let i = 0; i < v1.length; i++) {\n product += v1[i] * v2[i];\n }\n return product;\n}\n\nexport function getColumnFrom2DArr(arr, columnIndex) {\n const column: number[] = [];\n for (let i = 0; i < arr.length; i++) {\n column.push(arr[i][columnIndex]);\n }\n return column;\n}\n\nexport function multiplyTransformMatrices(mat1, mat2) {\n const product: number[][] = [];\n const size = mat1.length;\n for (let row = 0; row < size; row++) {\n product.push([]);\n for (let col = 0; col < size; col++) {\n product[row].push(dot(mat1[row], getColumnFrom2DArr(mat2, col)));\n }\n }\n return product;\n}\n\nexport function buildRotationMatrix(rotation, center) {\n const cosA = Math.cos(rotation);\n const sinA = Math.sin(rotation);\n const rotationMatrix = [[cosA, -sinA, 0], [sinA, cosA, 0], [0, 0, 1]];\n const translationMatrix = buildTranslationMatrix(center[0], center[1]);\n const translationTimesRotation = multiplyTransformMatrices(translationMatrix, rotationMatrix);\n const negativeTranslationMatrix = buildTranslationMatrix(-center[0], -center[1]);\n return multiplyTransformMatrices(translationTimesRotation, negativeTranslationMatrix);\n}\n\nexport function invertTransformMatrix(matrix) {\n const rotationComponent = [[matrix[0][0], matrix[1][0]], [matrix[0][1], matrix[1][1]]];\n const translationComponent = [matrix[0][2], matrix[1][2]];\n const invertedTranslation = [\n -dot(rotationComponent[0], translationComponent),\n -dot(rotationComponent[1], translationComponent),\n ];\n return [\n rotationComponent[0].concat(invertedTranslation[0]),\n rotationComponent[1].concat(invertedTranslation[1]),\n [0, 0, 1],\n ];\n}\n\nexport function rotatePoint(homogeneousCoordinate, rotationMatrix) {\n return [\n dot(homogeneousCoordinate, rotationMatrix[0]),\n dot(homogeneousCoordinate, rotationMatrix[1]),\n ];\n}\n", "/**\n * HandPose model implementation constants\n * See `handpose.ts` for entry point\n */\n\nexport const anchors = [\n { x: 0.015625, y: 0.015625 },\n { x: 0.015625, y: 0.015625 },\n { x: 0.046875, y: 0.015625 },\n { x: 0.046875, y: 0.015625 },\n { x: 0.078125, y: 0.015625 },\n { x: 0.078125, y: 0.015625 },\n { x: 0.109375, y: 0.015625 },\n { x: 0.109375, y: 0.015625 },\n { x: 0.140625, y: 0.015625 },\n { x: 0.140625, y: 0.015625 },\n { x: 0.171875, y: 0.015625 },\n { x: 0.171875, y: 0.015625 },\n { x: 0.203125, y: 0.015625 },\n { x: 0.203125, y: 0.015625 },\n { x: 0.234375, y: 0.015625 },\n { x: 0.234375, y: 0.015625 },\n { x: 0.265625, y: 0.015625 },\n { x: 0.265625, y: 0.015625 },\n { x: 0.296875, y: 0.015625 },\n { x: 0.296875, y: 0.015625 },\n { x: 0.328125, y: 0.015625 },\n { x: 0.328125, y: 0.015625 },\n { x: 0.359375, y: 0.015625 },\n { x: 0.359375, y: 0.015625 },\n { x: 0.390625, y: 0.015625 },\n { x: 0.390625, y: 0.015625 },\n { x: 0.421875, y: 0.015625 },\n { x: 0.421875, y: 0.015625 },\n { x: 0.453125, y: 0.015625 },\n { x: 0.453125, y: 0.015625 },\n { x: 0.484375, y: 0.015625 },\n { x: 0.484375, y: 0.015625 },\n { x: 0.515625, y: 0.015625 },\n { x: 0.515625, y: 0.015625 },\n { x: 0.546875, y: 0.015625 },\n { x: 0.546875, y: 0.015625 },\n { x: 0.578125, y: 0.015625 },\n { x: 0.578125, y: 0.015625 },\n { x: 0.609375, y: 0.015625 },\n { x: 0.609375, y: 0.015625 },\n { x: 0.640625, y: 0.015625 },\n { x: 0.640625, y: 0.015625 },\n { x: 0.671875, y: 0.015625 },\n { x: 0.671875, y: 0.015625 },\n { x: 0.703125, y: 0.015625 },\n { x: 0.703125, y: 0.015625 },\n { x: 0.734375, y: 0.015625 },\n { x: 0.734375, y: 0.015625 },\n { x: 0.765625, y: 0.015625 },\n { x: 0.765625, y: 0.015625 },\n { x: 0.796875, y: 0.015625 },\n { x: 0.796875, y: 0.015625 },\n { x: 0.828125, y: 0.015625 },\n { x: 0.828125, y: 0.015625 },\n { x: 0.859375, y: 0.015625 },\n { x: 0.859375, y: 0.015625 },\n { x: 0.890625, y: 0.015625 },\n { x: 0.890625, y: 0.015625 },\n { x: 0.921875, y: 0.015625 },\n { x: 0.921875, y: 0.015625 },\n { x: 0.953125, y: 0.015625 },\n { x: 0.953125, y: 0.015625 },\n { x: 0.984375, y: 0.015625 },\n { x: 0.984375, y: 0.015625 },\n { x: 0.015625, y: 0.046875 },\n { x: 0.015625, y: 0.046875 },\n { x: 0.046875, y: 0.046875 },\n { x: 0.046875, y: 0.046875 },\n { x: 0.078125, y: 0.046875 },\n { x: 0.078125, y: 0.046875 },\n { x: 0.109375, y: 0.046875 },\n { x: 0.109375, y: 0.046875 },\n { x: 0.140625, y: 0.046875 },\n { x: 0.140625, y: 0.046875 },\n { x: 0.171875, y: 0.046875 },\n { x: 0.171875, y: 0.046875 },\n { x: 0.203125, y: 0.046875 },\n { x: 0.203125, y: 0.046875 },\n { x: 0.234375, y: 0.046875 },\n { x: 0.234375, y: 0.046875 },\n { x: 0.265625, y: 0.046875 },\n { x: 0.265625, y: 0.046875 },\n { x: 0.296875, y: 0.046875 },\n { x: 0.296875, y: 0.046875 },\n { x: 0.328125, y: 0.046875 },\n { x: 0.328125, y: 0.046875 },\n { x: 0.359375, y: 0.046875 },\n { x: 0.359375, y: 0.046875 },\n { x: 0.390625, y: 0.046875 },\n { x: 0.390625, y: 0.046875 },\n { x: 0.421875, y: 0.046875 },\n { x: 0.421875, y: 0.046875 },\n { x: 0.453125, y: 0.046875 },\n { x: 0.453125, y: 0.046875 },\n { x: 0.484375, y: 0.046875 },\n { x: 0.484375, y: 0.046875 },\n { x: 0.515625, y: 0.046875 },\n { x: 0.515625, y: 0.046875 },\n { x: 0.546875, y: 0.046875 },\n { x: 0.546875, y: 0.046875 },\n { x: 0.578125, y: 0.046875 },\n { x: 0.578125, y: 0.046875 },\n { x: 0.609375, y: 0.046875 },\n { x: 0.609375, y: 0.046875 },\n { x: 0.640625, y: 0.046875 },\n { x: 0.640625, y: 0.046875 },\n { x: 0.671875, y: 0.046875 },\n { x: 0.671875, y: 0.046875 },\n { x: 0.703125, y: 0.046875 },\n { x: 0.703125, y: 0.046875 },\n { x: 0.734375, y: 0.046875 },\n { x: 0.734375, y: 0.046875 },\n { x: 0.765625, y: 0.046875 },\n { x: 0.765625, y: 0.046875 },\n { x: 0.796875, y: 0.046875 },\n { x: 0.796875, y: 0.046875 },\n { x: 0.828125, y: 0.046875 },\n { x: 0.828125, y: 0.046875 },\n { x: 0.859375, y: 0.046875 },\n { x: 0.859375, y: 0.046875 },\n { x: 0.890625, y: 0.046875 },\n { x: 0.890625, y: 0.046875 },\n { x: 0.921875, y: 0.046875 },\n { x: 0.921875, y: 0.046875 },\n { x: 0.953125, y: 0.046875 },\n { x: 0.953125, y: 0.046875 },\n { x: 0.984375, y: 0.046875 },\n { x: 0.984375, y: 0.046875 },\n { x: 0.015625, y: 0.078125 },\n { x: 0.015625, y: 0.078125 },\n { x: 0.046875, y: 0.078125 },\n { x: 0.046875, y: 0.078125 },\n { x: 0.078125, y: 0.078125 },\n { x: 0.078125, y: 0.078125 },\n { x: 0.109375, y: 0.078125 },\n { x: 0.109375, y: 0.078125 },\n { x: 0.140625, y: 0.078125 },\n { x: 0.140625, y: 0.078125 },\n { x: 0.171875, y: 0.078125 },\n { x: 0.171875, y: 0.078125 },\n { x: 0.203125, y: 0.078125 },\n { x: 0.203125, y: 0.078125 },\n { x: 0.234375, y: 0.078125 },\n { x: 0.234375, y: 0.078125 },\n { x: 0.265625, y: 0.078125 },\n { x: 0.265625, y: 0.078125 },\n { x: 0.296875, y: 0.078125 },\n { x: 0.296875, y: 0.078125 },\n { x: 0.328125, y: 0.078125 },\n { x: 0.328125, y: 0.078125 },\n { x: 0.359375, y: 0.078125 },\n { x: 0.359375, y: 0.078125 },\n { x: 0.390625, y: 0.078125 },\n { x: 0.390625, y: 0.078125 },\n { x: 0.421875, y: 0.078125 },\n { x: 0.421875, y: 0.078125 },\n { x: 0.453125, y: 0.078125 },\n { x: 0.453125, y: 0.078125 },\n { x: 0.484375, y: 0.078125 },\n { x: 0.484375, y: 0.078125 },\n { x: 0.515625, y: 0.078125 },\n { x: 0.515625, y: 0.078125 },\n { x: 0.546875, y: 0.078125 },\n { x: 0.546875, y: 0.078125 },\n { x: 0.578125, y: 0.078125 },\n { x: 0.578125, y: 0.078125 },\n { x: 0.609375, y: 0.078125 },\n { x: 0.609375, y: 0.078125 },\n { x: 0.640625, y: 0.078125 },\n { x: 0.640625, y: 0.078125 },\n { x: 0.671875, y: 0.078125 },\n { x: 0.671875, y: 0.078125 },\n { x: 0.703125, y: 0.078125 },\n { x: 0.703125, y: 0.078125 },\n { x: 0.734375, y: 0.078125 },\n { x: 0.734375, y: 0.078125 },\n { x: 0.765625, y: 0.078125 },\n { x: 0.765625, y: 0.078125 },\n { x: 0.796875, y: 0.078125 },\n { x: 0.796875, y: 0.078125 },\n { x: 0.828125, y: 0.078125 },\n { x: 0.828125, y: 0.078125 },\n { x: 0.859375, y: 0.078125 },\n { x: 0.859375, y: 0.078125 },\n { x: 0.890625, y: 0.078125 },\n { x: 0.890625, y: 0.078125 },\n { x: 0.921875, y: 0.078125 },\n { x: 0.921875, y: 0.078125 },\n { x: 0.953125, y: 0.078125 },\n { x: 0.953125, y: 0.078125 },\n { x: 0.984375, y: 0.078125 },\n { x: 0.984375, y: 0.078125 },\n { x: 0.015625, y: 0.109375 },\n { x: 0.015625, y: 0.109375 },\n { x: 0.046875, y: 0.109375 },\n { x: 0.046875, y: 0.109375 },\n { x: 0.078125, y: 0.109375 },\n { x: 0.078125, y: 0.109375 },\n { x: 0.109375, y: 0.109375 },\n { x: 0.109375, y: 0.109375 },\n { x: 0.140625, y: 0.109375 },\n { x: 0.140625, y: 0.109375 },\n { x: 0.171875, y: 0.109375 },\n { x: 0.171875, y: 0.109375 },\n { x: 0.203125, y: 0.109375 },\n { x: 0.203125, y: 0.109375 },\n { x: 0.234375, y: 0.109375 },\n { x: 0.234375, y: 0.109375 },\n { x: 0.265625, y: 0.109375 },\n { x: 0.265625, y: 0.109375 },\n { x: 0.296875, y: 0.109375 },\n { x: 0.296875, y: 0.109375 },\n { x: 0.328125, y: 0.109375 },\n { x: 0.328125, y: 0.109375 },\n { x: 0.359375, y: 0.109375 },\n { x: 0.359375, y: 0.109375 },\n { x: 0.390625, y: 0.109375 },\n { x: 0.390625, y: 0.109375 },\n { x: 0.421875, y: 0.109375 },\n { x: 0.421875, y: 0.109375 },\n { x: 0.453125, y: 0.109375 },\n { x: 0.453125, y: 0.109375 },\n { x: 0.484375, y: 0.109375 },\n { x: 0.484375, y: 0.109375 },\n { x: 0.515625, y: 0.109375 },\n { x: 0.515625, y: 0.109375 },\n { x: 0.546875, y: 0.109375 },\n { x: 0.546875, y: 0.109375 },\n { x: 0.578125, y: 0.109375 },\n { x: 0.578125, y: 0.109375 },\n { x: 0.609375, y: 0.109375 },\n { x: 0.609375, y: 0.109375 },\n { x: 0.640625, y: 0.109375 },\n { x: 0.640625, y: 0.109375 },\n { x: 0.671875, y: 0.109375 },\n { x: 0.671875, y: 0.109375 },\n { x: 0.703125, y: 0.109375 },\n { x: 0.703125, y: 0.109375 },\n { x: 0.734375, y: 0.109375 },\n { x: 0.734375, y: 0.109375 },\n { x: 0.765625, y: 0.109375 },\n { x: 0.765625, y: 0.109375 },\n { x: 0.796875, y: 0.109375 },\n { x: 0.796875, y: 0.109375 },\n { x: 0.828125, y: 0.109375 },\n { x: 0.828125, y: 0.109375 },\n { x: 0.859375, y: 0.109375 },\n { x: 0.859375, y: 0.109375 },\n { x: 0.890625, y: 0.109375 },\n { x: 0.890625, y: 0.109375 },\n { x: 0.921875, y: 0.109375 },\n { x: 0.921875, y: 0.109375 },\n { x: 0.953125, y: 0.109375 },\n { x: 0.953125, y: 0.109375 },\n { x: 0.984375, y: 0.109375 },\n { x: 0.984375, y: 0.109375 },\n { x: 0.015625, y: 0.140625 },\n { x: 0.015625, y: 0.140625 },\n { x: 0.046875, y: 0.140625 },\n { x: 0.046875, y: 0.140625 },\n { x: 0.078125, y: 0.140625 },\n { x: 0.078125, y: 0.140625 },\n { x: 0.109375, y: 0.140625 },\n { x: 0.109375, y: 0.140625 },\n { x: 0.140625, y: 0.140625 },\n { x: 0.140625, y: 0.140625 },\n { x: 0.171875, y: 0.140625 },\n { x: 0.171875, y: 0.140625 },\n { x: 0.203125, y: 0.140625 },\n { x: 0.203125, y: 0.140625 },\n { x: 0.234375, y: 0.140625 },\n { x: 0.234375, y: 0.140625 },\n { x: 0.265625, y: 0.140625 },\n { x: 0.265625, y: 0.140625 },\n { x: 0.296875, y: 0.140625 },\n { x: 0.296875, y: 0.140625 },\n { x: 0.328125, y: 0.140625 },\n { x: 0.328125, y: 0.140625 },\n { x: 0.359375, y: 0.140625 },\n { x: 0.359375, y: 0.140625 },\n { x: 0.390625, y: 0.140625 },\n { x: 0.390625, y: 0.140625 },\n { x: 0.421875, y: 0.140625 },\n { x: 0.421875, y: 0.140625 },\n { x: 0.453125, y: 0.140625 },\n { x: 0.453125, y: 0.140625 },\n { x: 0.484375, y: 0.140625 },\n { x: 0.484375, y: 0.140625 },\n { x: 0.515625, y: 0.140625 },\n { x: 0.515625, y: 0.140625 },\n { x: 0.546875, y: 0.140625 },\n { x: 0.546875, y: 0.140625 },\n { x: 0.578125, y: 0.140625 },\n { x: 0.578125, y: 0.140625 },\n { x: 0.609375, y: 0.140625 },\n { x: 0.609375, y: 0.140625 },\n { x: 0.640625, y: 0.140625 },\n { x: 0.640625, y: 0.140625 },\n { x: 0.671875, y: 0.140625 },\n { x: 0.671875, y: 0.140625 },\n { x: 0.703125, y: 0.140625 },\n { x: 0.703125, y: 0.140625 },\n { x: 0.734375, y: 0.140625 },\n { x: 0.734375, y: 0.140625 },\n { x: 0.765625, y: 0.140625 },\n { x: 0.765625, y: 0.140625 },\n { x: 0.796875, y: 0.140625 },\n { x: 0.796875, y: 0.140625 },\n { x: 0.828125, y: 0.140625 },\n { x: 0.828125, y: 0.140625 },\n { x: 0.859375, y: 0.140625 },\n { x: 0.859375, y: 0.140625 },\n { x: 0.890625, y: 0.140625 },\n { x: 0.890625, y: 0.140625 },\n { x: 0.921875, y: 0.140625 },\n { x: 0.921875, y: 0.140625 },\n { x: 0.953125, y: 0.140625 },\n { x: 0.953125, y: 0.140625 },\n { x: 0.984375, y: 0.140625 },\n { x: 0.984375, y: 0.140625 },\n { x: 0.015625, y: 0.171875 },\n { x: 0.015625, y: 0.171875 },\n { x: 0.046875, y: 0.171875 },\n { x: 0.046875, y: 0.171875 },\n { x: 0.078125, y: 0.171875 },\n { x: 0.078125, y: 0.171875 },\n { x: 0.109375, y: 0.171875 },\n { x: 0.109375, y: 0.171875 },\n { x: 0.140625, y: 0.171875 },\n { x: 0.140625, y: 0.171875 },\n { x: 0.171875, y: 0.171875 },\n { x: 0.171875, y: 0.171875 },\n { x: 0.203125, y: 0.171875 },\n { x: 0.203125, y: 0.171875 },\n { x: 0.234375, y: 0.171875 },\n { x: 0.234375, y: 0.171875 },\n { x: 0.265625, y: 0.171875 },\n { x: 0.265625, y: 0.171875 },\n { x: 0.296875, y: 0.171875 },\n { x: 0.296875, y: 0.171875 },\n { x: 0.328125, y: 0.171875 },\n { x: 0.328125, y: 0.171875 },\n { x: 0.359375, y: 0.171875 },\n { x: 0.359375, y: 0.171875 },\n { x: 0.390625, y: 0.171875 },\n { x: 0.390625, y: 0.171875 },\n { x: 0.421875, y: 0.171875 },\n { x: 0.421875, y: 0.171875 },\n { x: 0.453125, y: 0.171875 },\n { x: 0.453125, y: 0.171875 },\n { x: 0.484375, y: 0.171875 },\n { x: 0.484375, y: 0.171875 },\n { x: 0.515625, y: 0.171875 },\n { x: 0.515625, y: 0.171875 },\n { x: 0.546875, y: 0.171875 },\n { x: 0.546875, y: 0.171875 },\n { x: 0.578125, y: 0.171875 },\n { x: 0.578125, y: 0.171875 },\n { x: 0.609375, y: 0.171875 },\n { x: 0.609375, y: 0.171875 },\n { x: 0.640625, y: 0.171875 },\n { x: 0.640625, y: 0.171875 },\n { x: 0.671875, y: 0.171875 },\n { x: 0.671875, y: 0.171875 },\n { x: 0.703125, y: 0.171875 },\n { x: 0.703125, y: 0.171875 },\n { x: 0.734375, y: 0.171875 },\n { x: 0.734375, y: 0.171875 },\n { x: 0.765625, y: 0.171875 },\n { x: 0.765625, y: 0.171875 },\n { x: 0.796875, y: 0.171875 },\n { x: 0.796875, y: 0.171875 },\n { x: 0.828125, y: 0.171875 },\n { x: 0.828125, y: 0.171875 },\n { x: 0.859375, y: 0.171875 },\n { x: 0.859375, y: 0.171875 },\n { x: 0.890625, y: 0.171875 },\n { x: 0.890625, y: 0.171875 },\n { x: 0.921875, y: 0.171875 },\n { x: 0.921875, y: 0.171875 },\n { x: 0.953125, y: 0.171875 },\n { x: 0.953125, y: 0.171875 },\n { x: 0.984375, y: 0.171875 },\n { x: 0.984375, y: 0.171875 },\n { x: 0.015625, y: 0.203125 },\n { x: 0.015625, y: 0.203125 },\n { x: 0.046875, y: 0.203125 },\n { x: 0.046875, y: 0.203125 },\n { x: 0.078125, y: 0.203125 },\n { x: 0.078125, y: 0.203125 },\n { x: 0.109375, y: 0.203125 },\n { x: 0.109375, y: 0.203125 },\n { x: 0.140625, y: 0.203125 },\n { x: 0.140625, y: 0.203125 },\n { x: 0.171875, y: 0.203125 },\n { x: 0.171875, y: 0.203125 },\n { x: 0.203125, y: 0.203125 },\n { x: 0.203125, y: 0.203125 },\n { x: 0.234375, y: 0.203125 },\n { x: 0.234375, y: 0.203125 },\n { x: 0.265625, y: 0.203125 },\n { x: 0.265625, y: 0.203125 },\n { x: 0.296875, y: 0.203125 },\n { x: 0.296875, y: 0.203125 },\n { x: 0.328125, y: 0.203125 },\n { x: 0.328125, y: 0.203125 },\n { x: 0.359375, y: 0.203125 },\n { x: 0.359375, y: 0.203125 },\n { x: 0.390625, y: 0.203125 },\n { x: 0.390625, y: 0.203125 },\n { x: 0.421875, y: 0.203125 },\n { x: 0.421875, y: 0.203125 },\n { x: 0.453125, y: 0.203125 },\n { x: 0.453125, y: 0.203125 },\n { x: 0.484375, y: 0.203125 },\n { x: 0.484375, y: 0.203125 },\n { x: 0.515625, y: 0.203125 },\n { x: 0.515625, y: 0.203125 },\n { x: 0.546875, y: 0.203125 },\n { x: 0.546875, y: 0.203125 },\n { x: 0.578125, y: 0.203125 },\n { x: 0.578125, y: 0.203125 },\n { x: 0.609375, y: 0.203125 },\n { x: 0.609375, y: 0.203125 },\n { x: 0.640625, y: 0.203125 },\n { x: 0.640625, y: 0.203125 },\n { x: 0.671875, y: 0.203125 },\n { x: 0.671875, y: 0.203125 },\n { x: 0.703125, y: 0.203125 },\n { x: 0.703125, y: 0.203125 },\n { x: 0.734375, y: 0.203125 },\n { x: 0.734375, y: 0.203125 },\n { x: 0.765625, y: 0.203125 },\n { x: 0.765625, y: 0.203125 },\n { x: 0.796875, y: 0.203125 },\n { x: 0.796875, y: 0.203125 },\n { x: 0.828125, y: 0.203125 },\n { x: 0.828125, y: 0.203125 },\n { x: 0.859375, y: 0.203125 },\n { x: 0.859375, y: 0.203125 },\n { x: 0.890625, y: 0.203125 },\n { x: 0.890625, y: 0.203125 },\n { x: 0.921875, y: 0.203125 },\n { x: 0.921875, y: 0.203125 },\n { x: 0.953125, y: 0.203125 },\n { x: 0.953125, y: 0.203125 },\n { x: 0.984375, y: 0.203125 },\n { x: 0.984375, y: 0.203125 },\n { x: 0.015625, y: 0.234375 },\n { x: 0.015625, y: 0.234375 },\n { x: 0.046875, y: 0.234375 },\n { x: 0.046875, y: 0.234375 },\n { x: 0.078125, y: 0.234375 },\n { x: 0.078125, y: 0.234375 },\n { x: 0.109375, y: 0.234375 },\n { x: 0.109375, y: 0.234375 },\n { x: 0.140625, y: 0.234375 },\n { x: 0.140625, y: 0.234375 },\n { x: 0.171875, y: 0.234375 },\n { x: 0.171875, y: 0.234375 },\n { x: 0.203125, y: 0.234375 },\n { x: 0.203125, y: 0.234375 },\n { x: 0.234375, y: 0.234375 },\n { x: 0.234375, y: 0.234375 },\n { x: 0.265625, y: 0.234375 },\n { x: 0.265625, y: 0.234375 },\n { x: 0.296875, y: 0.234375 },\n { x: 0.296875, y: 0.234375 },\n { x: 0.328125, y: 0.234375 },\n { x: 0.328125, y: 0.234375 },\n { x: 0.359375, y: 0.234375 },\n { x: 0.359375, y: 0.234375 },\n { x: 0.390625, y: 0.234375 },\n { x: 0.390625, y: 0.234375 },\n { x: 0.421875, y: 0.234375 },\n { x: 0.421875, y: 0.234375 },\n { x: 0.453125, y: 0.234375 },\n { x: 0.453125, y: 0.234375 },\n { x: 0.484375, y: 0.234375 },\n { x: 0.484375, y: 0.234375 },\n { x: 0.515625, y: 0.234375 },\n { x: 0.515625, y: 0.234375 },\n { x: 0.546875, y: 0.234375 },\n { x: 0.546875, y: 0.234375 },\n { x: 0.578125, y: 0.234375 },\n { x: 0.578125, y: 0.234375 },\n { x: 0.609375, y: 0.234375 },\n { x: 0.609375, y: 0.234375 },\n { x: 0.640625, y: 0.234375 },\n { x: 0.640625, y: 0.234375 },\n { x: 0.671875, y: 0.234375 },\n { x: 0.671875, y: 0.234375 },\n { x: 0.703125, y: 0.234375 },\n { x: 0.703125, y: 0.234375 },\n { x: 0.734375, y: 0.234375 },\n { x: 0.734375, y: 0.234375 },\n { x: 0.765625, y: 0.234375 },\n { x: 0.765625, y: 0.234375 },\n { x: 0.796875, y: 0.234375 },\n { x: 0.796875, y: 0.234375 },\n { x: 0.828125, y: 0.234375 },\n { x: 0.828125, y: 0.234375 },\n { x: 0.859375, y: 0.234375 },\n { x: 0.859375, y: 0.234375 },\n { x: 0.890625, y: 0.234375 },\n { x: 0.890625, y: 0.234375 },\n { x: 0.921875, y: 0.234375 },\n { x: 0.921875, y: 0.234375 },\n { x: 0.953125, y: 0.234375 },\n { x: 0.953125, y: 0.234375 },\n { x: 0.984375, y: 0.234375 },\n { x: 0.984375, y: 0.234375 },\n { x: 0.015625, y: 0.265625 },\n { x: 0.015625, y: 0.265625 },\n { x: 0.046875, y: 0.265625 },\n { x: 0.046875, y: 0.265625 },\n { x: 0.078125, y: 0.265625 },\n { x: 0.078125, y: 0.265625 },\n { x: 0.109375, y: 0.265625 },\n { x: 0.109375, y: 0.265625 },\n { x: 0.140625, y: 0.265625 },\n { x: 0.140625, y: 0.265625 },\n { x: 0.171875, y: 0.265625 },\n { x: 0.171875, y: 0.265625 },\n { x: 0.203125, y: 0.265625 },\n { x: 0.203125, y: 0.265625 },\n { x: 0.234375, y: 0.265625 },\n { x: 0.234375, y: 0.265625 },\n { x: 0.265625, y: 0.265625 },\n { x: 0.265625, y: 0.265625 },\n { x: 0.296875, y: 0.265625 },\n { x: 0.296875, y: 0.265625 },\n { x: 0.328125, y: 0.265625 },\n { x: 0.328125, y: 0.265625 },\n { x: 0.359375, y: 0.265625 },\n { x: 0.359375, y: 0.265625 },\n { x: 0.390625, y: 0.265625 },\n { x: 0.390625, y: 0.265625 },\n { x: 0.421875, y: 0.265625 },\n { x: 0.421875, y: 0.265625 },\n { x: 0.453125, y: 0.265625 },\n { x: 0.453125, y: 0.265625 },\n { x: 0.484375, y: 0.265625 },\n { x: 0.484375, y: 0.265625 },\n { x: 0.515625, y: 0.265625 },\n { x: 0.515625, y: 0.265625 },\n { x: 0.546875, y: 0.265625 },\n { x: 0.546875, y: 0.265625 },\n { x: 0.578125, y: 0.265625 },\n { x: 0.578125, y: 0.265625 },\n { x: 0.609375, y: 0.265625 },\n { x: 0.609375, y: 0.265625 },\n { x: 0.640625, y: 0.265625 },\n { x: 0.640625, y: 0.265625 },\n { x: 0.671875, y: 0.265625 },\n { x: 0.671875, y: 0.265625 },\n { x: 0.703125, y: 0.265625 },\n { x: 0.703125, y: 0.265625 },\n { x: 0.734375, y: 0.265625 },\n { x: 0.734375, y: 0.265625 },\n { x: 0.765625, y: 0.265625 },\n { x: 0.765625, y: 0.265625 },\n { x: 0.796875, y: 0.265625 },\n { x: 0.796875, y: 0.265625 },\n { x: 0.828125, y: 0.265625 },\n { x: 0.828125, y: 0.265625 },\n { x: 0.859375, y: 0.265625 },\n { x: 0.859375, y: 0.265625 },\n { x: 0.890625, y: 0.265625 },\n { x: 0.890625, y: 0.265625 },\n { x: 0.921875, y: 0.265625 },\n { x: 0.921875, y: 0.265625 },\n { x: 0.953125, y: 0.265625 },\n { x: 0.953125, y: 0.265625 },\n { x: 0.984375, y: 0.265625 },\n { x: 0.984375, y: 0.265625 },\n { x: 0.015625, y: 0.296875 },\n { x: 0.015625, y: 0.296875 },\n { x: 0.046875, y: 0.296875 },\n { x: 0.046875, y: 0.296875 },\n { x: 0.078125, y: 0.296875 },\n { x: 0.078125, y: 0.296875 },\n { x: 0.109375, y: 0.296875 },\n { x: 0.109375, y: 0.296875 },\n { x: 0.140625, y: 0.296875 },\n { x: 0.140625, y: 0.296875 },\n { x: 0.171875, y: 0.296875 },\n { x: 0.171875, y: 0.296875 },\n { x: 0.203125, y: 0.296875 },\n { x: 0.203125, y: 0.296875 },\n { x: 0.234375, y: 0.296875 },\n { x: 0.234375, y: 0.296875 },\n { x: 0.265625, y: 0.296875 },\n { x: 0.265625, y: 0.296875 },\n { x: 0.296875, y: 0.296875 },\n { x: 0.296875, y: 0.296875 },\n { x: 0.328125, y: 0.296875 },\n { x: 0.328125, y: 0.296875 },\n { x: 0.359375, y: 0.296875 },\n { x: 0.359375, y: 0.296875 },\n { x: 0.390625, y: 0.296875 },\n { x: 0.390625, y: 0.296875 },\n { x: 0.421875, y: 0.296875 },\n { x: 0.421875, y: 0.296875 },\n { x: 0.453125, y: 0.296875 },\n { x: 0.453125, y: 0.296875 },\n { x: 0.484375, y: 0.296875 },\n { x: 0.484375, y: 0.296875 },\n { x: 0.515625, y: 0.296875 },\n { x: 0.515625, y: 0.296875 },\n { x: 0.546875, y: 0.296875 },\n { x: 0.546875, y: 0.296875 },\n { x: 0.578125, y: 0.296875 },\n { x: 0.578125, y: 0.296875 },\n { x: 0.609375, y: 0.296875 },\n { x: 0.609375, y: 0.296875 },\n { x: 0.640625, y: 0.296875 },\n { x: 0.640625, y: 0.296875 },\n { x: 0.671875, y: 0.296875 },\n { x: 0.671875, y: 0.296875 },\n { x: 0.703125, y: 0.296875 },\n { x: 0.703125, y: 0.296875 },\n { x: 0.734375, y: 0.296875 },\n { x: 0.734375, y: 0.296875 },\n { x: 0.765625, y: 0.296875 },\n { x: 0.765625, y: 0.296875 },\n { x: 0.796875, y: 0.296875 },\n { x: 0.796875, y: 0.296875 },\n { x: 0.828125, y: 0.296875 },\n { x: 0.828125, y: 0.296875 },\n { x: 0.859375, y: 0.296875 },\n { x: 0.859375, y: 0.296875 },\n { x: 0.890625, y: 0.296875 },\n { x: 0.890625, y: 0.296875 },\n { x: 0.921875, y: 0.296875 },\n { x: 0.921875, y: 0.296875 },\n { x: 0.953125, y: 0.296875 },\n { x: 0.953125, y: 0.296875 },\n { x: 0.984375, y: 0.296875 },\n { x: 0.984375, y: 0.296875 },\n { x: 0.015625, y: 0.328125 },\n { x: 0.015625, y: 0.328125 },\n { x: 0.046875, y: 0.328125 },\n { x: 0.046875, y: 0.328125 },\n { x: 0.078125, y: 0.328125 },\n { x: 0.078125, y: 0.328125 },\n { x: 0.109375, y: 0.328125 },\n { x: 0.109375, y: 0.328125 },\n { x: 0.140625, y: 0.328125 },\n { x: 0.140625, y: 0.328125 },\n { x: 0.171875, y: 0.328125 },\n { x: 0.171875, y: 0.328125 },\n { x: 0.203125, y: 0.328125 },\n { x: 0.203125, y: 0.328125 },\n { x: 0.234375, y: 0.328125 },\n { x: 0.234375, y: 0.328125 },\n { x: 0.265625, y: 0.328125 },\n { x: 0.265625, y: 0.328125 },\n { x: 0.296875, y: 0.328125 },\n { x: 0.296875, y: 0.328125 },\n { x: 0.328125, y: 0.328125 },\n { x: 0.328125, y: 0.328125 },\n { x: 0.359375, y: 0.328125 },\n { x: 0.359375, y: 0.328125 },\n { x: 0.390625, y: 0.328125 },\n { x: 0.390625, y: 0.328125 },\n { x: 0.421875, y: 0.328125 },\n { x: 0.421875, y: 0.328125 },\n { x: 0.453125, y: 0.328125 },\n { x: 0.453125, y: 0.328125 },\n { x: 0.484375, y: 0.328125 },\n { x: 0.484375, y: 0.328125 },\n { x: 0.515625, y: 0.328125 },\n { x: 0.515625, y: 0.328125 },\n { x: 0.546875, y: 0.328125 },\n { x: 0.546875, y: 0.328125 },\n { x: 0.578125, y: 0.328125 },\n { x: 0.578125, y: 0.328125 },\n { x: 0.609375, y: 0.328125 },\n { x: 0.609375, y: 0.328125 },\n { x: 0.640625, y: 0.328125 },\n { x: 0.640625, y: 0.328125 },\n { x: 0.671875, y: 0.328125 },\n { x: 0.671875, y: 0.328125 },\n { x: 0.703125, y: 0.328125 },\n { x: 0.703125, y: 0.328125 },\n { x: 0.734375, y: 0.328125 },\n { x: 0.734375, y: 0.328125 },\n { x: 0.765625, y: 0.328125 },\n { x: 0.765625, y: 0.328125 },\n { x: 0.796875, y: 0.328125 },\n { x: 0.796875, y: 0.328125 },\n { x: 0.828125, y: 0.328125 },\n { x: 0.828125, y: 0.328125 },\n { x: 0.859375, y: 0.328125 },\n { x: 0.859375, y: 0.328125 },\n { x: 0.890625, y: 0.328125 },\n { x: 0.890625, y: 0.328125 },\n { x: 0.921875, y: 0.328125 },\n { x: 0.921875, y: 0.328125 },\n { x: 0.953125, y: 0.328125 },\n { x: 0.953125, y: 0.328125 },\n { x: 0.984375, y: 0.328125 },\n { x: 0.984375, y: 0.328125 },\n { x: 0.015625, y: 0.359375 },\n { x: 0.015625, y: 0.359375 },\n { x: 0.046875, y: 0.359375 },\n { x: 0.046875, y: 0.359375 },\n { x: 0.078125, y: 0.359375 },\n { x: 0.078125, y: 0.359375 },\n { x: 0.109375, y: 0.359375 },\n { x: 0.109375, y: 0.359375 },\n { x: 0.140625, y: 0.359375 },\n { x: 0.140625, y: 0.359375 },\n { x: 0.171875, y: 0.359375 },\n { x: 0.171875, y: 0.359375 },\n { x: 0.203125, y: 0.359375 },\n { x: 0.203125, y: 0.359375 },\n { x: 0.234375, y: 0.359375 },\n { x: 0.234375, y: 0.359375 },\n { x: 0.265625, y: 0.359375 },\n { x: 0.265625, y: 0.359375 },\n { x: 0.296875, y: 0.359375 },\n { x: 0.296875, y: 0.359375 },\n { x: 0.328125, y: 0.359375 },\n { x: 0.328125, y: 0.359375 },\n { x: 0.359375, y: 0.359375 },\n { x: 0.359375, y: 0.359375 },\n { x: 0.390625, y: 0.359375 },\n { x: 0.390625, y: 0.359375 },\n { x: 0.421875, y: 0.359375 },\n { x: 0.421875, y: 0.359375 },\n { x: 0.453125, y: 0.359375 },\n { x: 0.453125, y: 0.359375 },\n { x: 0.484375, y: 0.359375 },\n { x: 0.484375, y: 0.359375 },\n { x: 0.515625, y: 0.359375 },\n { x: 0.515625, y: 0.359375 },\n { x: 0.546875, y: 0.359375 },\n { x: 0.546875, y: 0.359375 },\n { x: 0.578125, y: 0.359375 },\n { x: 0.578125, y: 0.359375 },\n { x: 0.609375, y: 0.359375 },\n { x: 0.609375, y: 0.359375 },\n { x: 0.640625, y: 0.359375 },\n { x: 0.640625, y: 0.359375 },\n { x: 0.671875, y: 0.359375 },\n { x: 0.671875, y: 0.359375 },\n { x: 0.703125, y: 0.359375 },\n { x: 0.703125, y: 0.359375 },\n { x: 0.734375, y: 0.359375 },\n { x: 0.734375, y: 0.359375 },\n { x: 0.765625, y: 0.359375 },\n { x: 0.765625, y: 0.359375 },\n { x: 0.796875, y: 0.359375 },\n { x: 0.796875, y: 0.359375 },\n { x: 0.828125, y: 0.359375 },\n { x: 0.828125, y: 0.359375 },\n { x: 0.859375, y: 0.359375 },\n { x: 0.859375, y: 0.359375 },\n { x: 0.890625, y: 0.359375 },\n { x: 0.890625, y: 0.359375 },\n { x: 0.921875, y: 0.359375 },\n { x: 0.921875, y: 0.359375 },\n { x: 0.953125, y: 0.359375 },\n { x: 0.953125, y: 0.359375 },\n { x: 0.984375, y: 0.359375 },\n { x: 0.984375, y: 0.359375 },\n { x: 0.015625, y: 0.390625 },\n { x: 0.015625, y: 0.390625 },\n { x: 0.046875, y: 0.390625 },\n { x: 0.046875, y: 0.390625 },\n { x: 0.078125, y: 0.390625 },\n { x: 0.078125, y: 0.390625 },\n { x: 0.109375, y: 0.390625 },\n { x: 0.109375, y: 0.390625 },\n { x: 0.140625, y: 0.390625 },\n { x: 0.140625, y: 0.390625 },\n { x: 0.171875, y: 0.390625 },\n { x: 0.171875, y: 0.390625 },\n { x: 0.203125, y: 0.390625 },\n { x: 0.203125, y: 0.390625 },\n { x: 0.234375, y: 0.390625 },\n { x: 0.234375, y: 0.390625 },\n { x: 0.265625, y: 0.390625 },\n { x: 0.265625, y: 0.390625 },\n { x: 0.296875, y: 0.390625 },\n { x: 0.296875, y: 0.390625 },\n { x: 0.328125, y: 0.390625 },\n { x: 0.328125, y: 0.390625 },\n { x: 0.359375, y: 0.390625 },\n { x: 0.359375, y: 0.390625 },\n { x: 0.390625, y: 0.390625 },\n { x: 0.390625, y: 0.390625 },\n { x: 0.421875, y: 0.390625 },\n { x: 0.421875, y: 0.390625 },\n { x: 0.453125, y: 0.390625 },\n { x: 0.453125, y: 0.390625 },\n { x: 0.484375, y: 0.390625 },\n { x: 0.484375, y: 0.390625 },\n { x: 0.515625, y: 0.390625 },\n { x: 0.515625, y: 0.390625 },\n { x: 0.546875, y: 0.390625 },\n { x: 0.546875, y: 0.390625 },\n { x: 0.578125, y: 0.390625 },\n { x: 0.578125, y: 0.390625 },\n { x: 0.609375, y: 0.390625 },\n { x: 0.609375, y: 0.390625 },\n { x: 0.640625, y: 0.390625 },\n { x: 0.640625, y: 0.390625 },\n { x: 0.671875, y: 0.390625 },\n { x: 0.671875, y: 0.390625 },\n { x: 0.703125, y: 0.390625 },\n { x: 0.703125, y: 0.390625 },\n { x: 0.734375, y: 0.390625 },\n { x: 0.734375, y: 0.390625 },\n { x: 0.765625, y: 0.390625 },\n { x: 0.765625, y: 0.390625 },\n { x: 0.796875, y: 0.390625 },\n { x: 0.796875, y: 0.390625 },\n { x: 0.828125, y: 0.390625 },\n { x: 0.828125, y: 0.390625 },\n { x: 0.859375, y: 0.390625 },\n { x: 0.859375, y: 0.390625 },\n { x: 0.890625, y: 0.390625 },\n { x: 0.890625, y: 0.390625 },\n { x: 0.921875, y: 0.390625 },\n { x: 0.921875, y: 0.390625 },\n { x: 0.953125, y: 0.390625 },\n { x: 0.953125, y: 0.390625 },\n { x: 0.984375, y: 0.390625 },\n { x: 0.984375, y: 0.390625 },\n { x: 0.015625, y: 0.421875 },\n { x: 0.015625, y: 0.421875 },\n { x: 0.046875, y: 0.421875 },\n { x: 0.046875, y: 0.421875 },\n { x: 0.078125, y: 0.421875 },\n { x: 0.078125, y: 0.421875 },\n { x: 0.109375, y: 0.421875 },\n { x: 0.109375, y: 0.421875 },\n { x: 0.140625, y: 0.421875 },\n { x: 0.140625, y: 0.421875 },\n { x: 0.171875, y: 0.421875 },\n { x: 0.171875, y: 0.421875 },\n { x: 0.203125, y: 0.421875 },\n { x: 0.203125, y: 0.421875 },\n { x: 0.234375, y: 0.421875 },\n { x: 0.234375, y: 0.421875 },\n { x: 0.265625, y: 0.421875 },\n { x: 0.265625, y: 0.421875 },\n { x: 0.296875, y: 0.421875 },\n { x: 0.296875, y: 0.421875 },\n { x: 0.328125, y: 0.421875 },\n { x: 0.328125, y: 0.421875 },\n { x: 0.359375, y: 0.421875 },\n { x: 0.359375, y: 0.421875 },\n { x: 0.390625, y: 0.421875 },\n { x: 0.390625, y: 0.421875 },\n { x: 0.421875, y: 0.421875 },\n { x: 0.421875, y: 0.421875 },\n { x: 0.453125, y: 0.421875 },\n { x: 0.453125, y: 0.421875 },\n { x: 0.484375, y: 0.421875 },\n { x: 0.484375, y: 0.421875 },\n { x: 0.515625, y: 0.421875 },\n { x: 0.515625, y: 0.421875 },\n { x: 0.546875, y: 0.421875 },\n { x: 0.546875, y: 0.421875 },\n { x: 0.578125, y: 0.421875 },\n { x: 0.578125, y: 0.421875 },\n { x: 0.609375, y: 0.421875 },\n { x: 0.609375, y: 0.421875 },\n { x: 0.640625, y: 0.421875 },\n { x: 0.640625, y: 0.421875 },\n { x: 0.671875, y: 0.421875 },\n { x: 0.671875, y: 0.421875 },\n { x: 0.703125, y: 0.421875 },\n { x: 0.703125, y: 0.421875 },\n { x: 0.734375, y: 0.421875 },\n { x: 0.734375, y: 0.421875 },\n { x: 0.765625, y: 0.421875 },\n { x: 0.765625, y: 0.421875 },\n { x: 0.796875, y: 0.421875 },\n { x: 0.796875, y: 0.421875 },\n { x: 0.828125, y: 0.421875 },\n { x: 0.828125, y: 0.421875 },\n { x: 0.859375, y: 0.421875 },\n { x: 0.859375, y: 0.421875 },\n { x: 0.890625, y: 0.421875 },\n { x: 0.890625, y: 0.421875 },\n { x: 0.921875, y: 0.421875 },\n { x: 0.921875, y: 0.421875 },\n { x: 0.953125, y: 0.421875 },\n { x: 0.953125, y: 0.421875 },\n { x: 0.984375, y: 0.421875 },\n { x: 0.984375, y: 0.421875 },\n { x: 0.015625, y: 0.453125 },\n { x: 0.015625, y: 0.453125 },\n { x: 0.046875, y: 0.453125 },\n { x: 0.046875, y: 0.453125 },\n { x: 0.078125, y: 0.453125 },\n { x: 0.078125, y: 0.453125 },\n { x: 0.109375, y: 0.453125 },\n { x: 0.109375, y: 0.453125 },\n { x: 0.140625, y: 0.453125 },\n { x: 0.140625, y: 0.453125 },\n { x: 0.171875, y: 0.453125 },\n { x: 0.171875, y: 0.453125 },\n { x: 0.203125, y: 0.453125 },\n { x: 0.203125, y: 0.453125 },\n { x: 0.234375, y: 0.453125 },\n { x: 0.234375, y: 0.453125 },\n { x: 0.265625, y: 0.453125 },\n { x: 0.265625, y: 0.453125 },\n { x: 0.296875, y: 0.453125 },\n { x: 0.296875, y: 0.453125 },\n { x: 0.328125, y: 0.453125 },\n { x: 0.328125, y: 0.453125 },\n { x: 0.359375, y: 0.453125 },\n { x: 0.359375, y: 0.453125 },\n { x: 0.390625, y: 0.453125 },\n { x: 0.390625, y: 0.453125 },\n { x: 0.421875, y: 0.453125 },\n { x: 0.421875, y: 0.453125 },\n { x: 0.453125, y: 0.453125 },\n { x: 0.453125, y: 0.453125 },\n { x: 0.484375, y: 0.453125 },\n { x: 0.484375, y: 0.453125 },\n { x: 0.515625, y: 0.453125 },\n { x: 0.515625, y: 0.453125 },\n { x: 0.546875, y: 0.453125 },\n { x: 0.546875, y: 0.453125 },\n { x: 0.578125, y: 0.453125 },\n { x: 0.578125, y: 0.453125 },\n { x: 0.609375, y: 0.453125 },\n { x: 0.609375, y: 0.453125 },\n { x: 0.640625, y: 0.453125 },\n { x: 0.640625, y: 0.453125 },\n { x: 0.671875, y: 0.453125 },\n { x: 0.671875, y: 0.453125 },\n { x: 0.703125, y: 0.453125 },\n { x: 0.703125, y: 0.453125 },\n { x: 0.734375, y: 0.453125 },\n { x: 0.734375, y: 0.453125 },\n { x: 0.765625, y: 0.453125 },\n { x: 0.765625, y: 0.453125 },\n { x: 0.796875, y: 0.453125 },\n { x: 0.796875, y: 0.453125 },\n { x: 0.828125, y: 0.453125 },\n { x: 0.828125, y: 0.453125 },\n { x: 0.859375, y: 0.453125 },\n { x: 0.859375, y: 0.453125 },\n { x: 0.890625, y: 0.453125 },\n { x: 0.890625, y: 0.453125 },\n { x: 0.921875, y: 0.453125 },\n { x: 0.921875, y: 0.453125 },\n { x: 0.953125, y: 0.453125 },\n { x: 0.953125, y: 0.453125 },\n { x: 0.984375, y: 0.453125 },\n { x: 0.984375, y: 0.453125 },\n { x: 0.015625, y: 0.484375 },\n { x: 0.015625, y: 0.484375 },\n { x: 0.046875, y: 0.484375 },\n { x: 0.046875, y: 0.484375 },\n { x: 0.078125, y: 0.484375 },\n { x: 0.078125, y: 0.484375 },\n { x: 0.109375, y: 0.484375 },\n { x: 0.109375, y: 0.484375 },\n { x: 0.140625, y: 0.484375 },\n { x: 0.140625, y: 0.484375 },\n { x: 0.171875, y: 0.484375 },\n { x: 0.171875, y: 0.484375 },\n { x: 0.203125, y: 0.484375 },\n { x: 0.203125, y: 0.484375 },\n { x: 0.234375, y: 0.484375 },\n { x: 0.234375, y: 0.484375 },\n { x: 0.265625, y: 0.484375 },\n { x: 0.265625, y: 0.484375 },\n { x: 0.296875, y: 0.484375 },\n { x: 0.296875, y: 0.484375 },\n { x: 0.328125, y: 0.484375 },\n { x: 0.328125, y: 0.484375 },\n { x: 0.359375, y: 0.484375 },\n { x: 0.359375, y: 0.484375 },\n { x: 0.390625, y: 0.484375 },\n { x: 0.390625, y: 0.484375 },\n { x: 0.421875, y: 0.484375 },\n { x: 0.421875, y: 0.484375 },\n { x: 0.453125, y: 0.484375 },\n { x: 0.453125, y: 0.484375 },\n { x: 0.484375, y: 0.484375 },\n { x: 0.484375, y: 0.484375 },\n { x: 0.515625, y: 0.484375 },\n { x: 0.515625, y: 0.484375 },\n { x: 0.546875, y: 0.484375 },\n { x: 0.546875, y: 0.484375 },\n { x: 0.578125, y: 0.484375 },\n { x: 0.578125, y: 0.484375 },\n { x: 0.609375, y: 0.484375 },\n { x: 0.609375, y: 0.484375 },\n { x: 0.640625, y: 0.484375 },\n { x: 0.640625, y: 0.484375 },\n { x: 0.671875, y: 0.484375 },\n { x: 0.671875, y: 0.484375 },\n { x: 0.703125, y: 0.484375 },\n { x: 0.703125, y: 0.484375 },\n { x: 0.734375, y: 0.484375 },\n { x: 0.734375, y: 0.484375 },\n { x: 0.765625, y: 0.484375 },\n { x: 0.765625, y: 0.484375 },\n { x: 0.796875, y: 0.484375 },\n { x: 0.796875, y: 0.484375 },\n { x: 0.828125, y: 0.484375 },\n { x: 0.828125, y: 0.484375 },\n { x: 0.859375, y: 0.484375 },\n { x: 0.859375, y: 0.484375 },\n { x: 0.890625, y: 0.484375 },\n { x: 0.890625, y: 0.484375 },\n { x: 0.921875, y: 0.484375 },\n { x: 0.921875, y: 0.484375 },\n { x: 0.953125, y: 0.484375 },\n { x: 0.953125, y: 0.484375 },\n { x: 0.984375, y: 0.484375 },\n { x: 0.984375, y: 0.484375 },\n { x: 0.015625, y: 0.515625 },\n { x: 0.015625, y: 0.515625 },\n { x: 0.046875, y: 0.515625 },\n { x: 0.046875, y: 0.515625 },\n { x: 0.078125, y: 0.515625 },\n { x: 0.078125, y: 0.515625 },\n { x: 0.109375, y: 0.515625 },\n { x: 0.109375, y: 0.515625 },\n { x: 0.140625, y: 0.515625 },\n { x: 0.140625, y: 0.515625 },\n { x: 0.171875, y: 0.515625 },\n { x: 0.171875, y: 0.515625 },\n { x: 0.203125, y: 0.515625 },\n { x: 0.203125, y: 0.515625 },\n { x: 0.234375, y: 0.515625 },\n { x: 0.234375, y: 0.515625 },\n { x: 0.265625, y: 0.515625 },\n { x: 0.265625, y: 0.515625 },\n { x: 0.296875, y: 0.515625 },\n { x: 0.296875, y: 0.515625 },\n { x: 0.328125, y: 0.515625 },\n { x: 0.328125, y: 0.515625 },\n { x: 0.359375, y: 0.515625 },\n { x: 0.359375, y: 0.515625 },\n { x: 0.390625, y: 0.515625 },\n { x: 0.390625, y: 0.515625 },\n { x: 0.421875, y: 0.515625 },\n { x: 0.421875, y: 0.515625 },\n { x: 0.453125, y: 0.515625 },\n { x: 0.453125, y: 0.515625 },\n { x: 0.484375, y: 0.515625 },\n { x: 0.484375, y: 0.515625 },\n { x: 0.515625, y: 0.515625 },\n { x: 0.515625, y: 0.515625 },\n { x: 0.546875, y: 0.515625 },\n { x: 0.546875, y: 0.515625 },\n { x: 0.578125, y: 0.515625 },\n { x: 0.578125, y: 0.515625 },\n { x: 0.609375, y: 0.515625 },\n { x: 0.609375, y: 0.515625 },\n { x: 0.640625, y: 0.515625 },\n { x: 0.640625, y: 0.515625 },\n { x: 0.671875, y: 0.515625 },\n { x: 0.671875, y: 0.515625 },\n { x: 0.703125, y: 0.515625 },\n { x: 0.703125, y: 0.515625 },\n { x: 0.734375, y: 0.515625 },\n { x: 0.734375, y: 0.515625 },\n { x: 0.765625, y: 0.515625 },\n { x: 0.765625, y: 0.515625 },\n { x: 0.796875, y: 0.515625 },\n { x: 0.796875, y: 0.515625 },\n { x: 0.828125, y: 0.515625 },\n { x: 0.828125, y: 0.515625 },\n { x: 0.859375, y: 0.515625 },\n { x: 0.859375, y: 0.515625 },\n { x: 0.890625, y: 0.515625 },\n { x: 0.890625, y: 0.515625 },\n { x: 0.921875, y: 0.515625 },\n { x: 0.921875, y: 0.515625 },\n { x: 0.953125, y: 0.515625 },\n { x: 0.953125, y: 0.515625 },\n { x: 0.984375, y: 0.515625 },\n { x: 0.984375, y: 0.515625 },\n { x: 0.015625, y: 0.546875 },\n { x: 0.015625, y: 0.546875 },\n { x: 0.046875, y: 0.546875 },\n { x: 0.046875, y: 0.546875 },\n { x: 0.078125, y: 0.546875 },\n { x: 0.078125, y: 0.546875 },\n { x: 0.109375, y: 0.546875 },\n { x: 0.109375, y: 0.546875 },\n { x: 0.140625, y: 0.546875 },\n { x: 0.140625, y: 0.546875 },\n { x: 0.171875, y: 0.546875 },\n { x: 0.171875, y: 0.546875 },\n { x: 0.203125, y: 0.546875 },\n { x: 0.203125, y: 0.546875 },\n { x: 0.234375, y: 0.546875 },\n { x: 0.234375, y: 0.546875 },\n { x: 0.265625, y: 0.546875 },\n { x: 0.265625, y: 0.546875 },\n { x: 0.296875, y: 0.546875 },\n { x: 0.296875, y: 0.546875 },\n { x: 0.328125, y: 0.546875 },\n { x: 0.328125, y: 0.546875 },\n { x: 0.359375, y: 0.546875 },\n { x: 0.359375, y: 0.546875 },\n { x: 0.390625, y: 0.546875 },\n { x: 0.390625, y: 0.546875 },\n { x: 0.421875, y: 0.546875 },\n { x: 0.421875, y: 0.546875 },\n { x: 0.453125, y: 0.546875 },\n { x: 0.453125, y: 0.546875 },\n { x: 0.484375, y: 0.546875 },\n { x: 0.484375, y: 0.546875 },\n { x: 0.515625, y: 0.546875 },\n { x: 0.515625, y: 0.546875 },\n { x: 0.546875, y: 0.546875 },\n { x: 0.546875, y: 0.546875 },\n { x: 0.578125, y: 0.546875 },\n { x: 0.578125, y: 0.546875 },\n { x: 0.609375, y: 0.546875 },\n { x: 0.609375, y: 0.546875 },\n { x: 0.640625, y: 0.546875 },\n { x: 0.640625, y: 0.546875 },\n { x: 0.671875, y: 0.546875 },\n { x: 0.671875, y: 0.546875 },\n { x: 0.703125, y: 0.546875 },\n { x: 0.703125, y: 0.546875 },\n { x: 0.734375, y: 0.546875 },\n { x: 0.734375, y: 0.546875 },\n { x: 0.765625, y: 0.546875 },\n { x: 0.765625, y: 0.546875 },\n { x: 0.796875, y: 0.546875 },\n { x: 0.796875, y: 0.546875 },\n { x: 0.828125, y: 0.546875 },\n { x: 0.828125, y: 0.546875 },\n { x: 0.859375, y: 0.546875 },\n { x: 0.859375, y: 0.546875 },\n { x: 0.890625, y: 0.546875 },\n { x: 0.890625, y: 0.546875 },\n { x: 0.921875, y: 0.546875 },\n { x: 0.921875, y: 0.546875 },\n { x: 0.953125, y: 0.546875 },\n { x: 0.953125, y: 0.546875 },\n { x: 0.984375, y: 0.546875 },\n { x: 0.984375, y: 0.546875 },\n { x: 0.015625, y: 0.578125 },\n { x: 0.015625, y: 0.578125 },\n { x: 0.046875, y: 0.578125 },\n { x: 0.046875, y: 0.578125 },\n { x: 0.078125, y: 0.578125 },\n { x: 0.078125, y: 0.578125 },\n { x: 0.109375, y: 0.578125 },\n { x: 0.109375, y: 0.578125 },\n { x: 0.140625, y: 0.578125 },\n { x: 0.140625, y: 0.578125 },\n { x: 0.171875, y: 0.578125 },\n { x: 0.171875, y: 0.578125 },\n { x: 0.203125, y: 0.578125 },\n { x: 0.203125, y: 0.578125 },\n { x: 0.234375, y: 0.578125 },\n { x: 0.234375, y: 0.578125 },\n { x: 0.265625, y: 0.578125 },\n { x: 0.265625, y: 0.578125 },\n { x: 0.296875, y: 0.578125 },\n { x: 0.296875, y: 0.578125 },\n { x: 0.328125, y: 0.578125 },\n { x: 0.328125, y: 0.578125 },\n { x: 0.359375, y: 0.578125 },\n { x: 0.359375, y: 0.578125 },\n { x: 0.390625, y: 0.578125 },\n { x: 0.390625, y: 0.578125 },\n { x: 0.421875, y: 0.578125 },\n { x: 0.421875, y: 0.578125 },\n { x: 0.453125, y: 0.578125 },\n { x: 0.453125, y: 0.578125 },\n { x: 0.484375, y: 0.578125 },\n { x: 0.484375, y: 0.578125 },\n { x: 0.515625, y: 0.578125 },\n { x: 0.515625, y: 0.578125 },\n { x: 0.546875, y: 0.578125 },\n { x: 0.546875, y: 0.578125 },\n { x: 0.578125, y: 0.578125 },\n { x: 0.578125, y: 0.578125 },\n { x: 0.609375, y: 0.578125 },\n { x: 0.609375, y: 0.578125 },\n { x: 0.640625, y: 0.578125 },\n { x: 0.640625, y: 0.578125 },\n { x: 0.671875, y: 0.578125 },\n { x: 0.671875, y: 0.578125 },\n { x: 0.703125, y: 0.578125 },\n { x: 0.703125, y: 0.578125 },\n { x: 0.734375, y: 0.578125 },\n { x: 0.734375, y: 0.578125 },\n { x: 0.765625, y: 0.578125 },\n { x: 0.765625, y: 0.578125 },\n { x: 0.796875, y: 0.578125 },\n { x: 0.796875, y: 0.578125 },\n { x: 0.828125, y: 0.578125 },\n { x: 0.828125, y: 0.578125 },\n { x: 0.859375, y: 0.578125 },\n { x: 0.859375, y: 0.578125 },\n { x: 0.890625, y: 0.578125 },\n { x: 0.890625, y: 0.578125 },\n { x: 0.921875, y: 0.578125 },\n { x: 0.921875, y: 0.578125 },\n { x: 0.953125, y: 0.578125 },\n { x: 0.953125, y: 0.578125 },\n { x: 0.984375, y: 0.578125 },\n { x: 0.984375, y: 0.578125 },\n { x: 0.015625, y: 0.609375 },\n { x: 0.015625, y: 0.609375 },\n { x: 0.046875, y: 0.609375 },\n { x: 0.046875, y: 0.609375 },\n { x: 0.078125, y: 0.609375 },\n { x: 0.078125, y: 0.609375 },\n { x: 0.109375, y: 0.609375 },\n { x: 0.109375, y: 0.609375 },\n { x: 0.140625, y: 0.609375 },\n { x: 0.140625, y: 0.609375 },\n { x: 0.171875, y: 0.609375 },\n { x: 0.171875, y: 0.609375 },\n { x: 0.203125, y: 0.609375 },\n { x: 0.203125, y: 0.609375 },\n { x: 0.234375, y: 0.609375 },\n { x: 0.234375, y: 0.609375 },\n { x: 0.265625, y: 0.609375 },\n { x: 0.265625, y: 0.609375 },\n { x: 0.296875, y: 0.609375 },\n { x: 0.296875, y: 0.609375 },\n { x: 0.328125, y: 0.609375 },\n { x: 0.328125, y: 0.609375 },\n { x: 0.359375, y: 0.609375 },\n { x: 0.359375, y: 0.609375 },\n { x: 0.390625, y: 0.609375 },\n { x: 0.390625, y: 0.609375 },\n { x: 0.421875, y: 0.609375 },\n { x: 0.421875, y: 0.609375 },\n { x: 0.453125, y: 0.609375 },\n { x: 0.453125, y: 0.609375 },\n { x: 0.484375, y: 0.609375 },\n { x: 0.484375, y: 0.609375 },\n { x: 0.515625, y: 0.609375 },\n { x: 0.515625, y: 0.609375 },\n { x: 0.546875, y: 0.609375 },\n { x: 0.546875, y: 0.609375 },\n { x: 0.578125, y: 0.609375 },\n { x: 0.578125, y: 0.609375 },\n { x: 0.609375, y: 0.609375 },\n { x: 0.609375, y: 0.609375 },\n { x: 0.640625, y: 0.609375 },\n { x: 0.640625, y: 0.609375 },\n { x: 0.671875, y: 0.609375 },\n { x: 0.671875, y: 0.609375 },\n { x: 0.703125, y: 0.609375 },\n { x: 0.703125, y: 0.609375 },\n { x: 0.734375, y: 0.609375 },\n { x: 0.734375, y: 0.609375 },\n { x: 0.765625, y: 0.609375 },\n { x: 0.765625, y: 0.609375 },\n { x: 0.796875, y: 0.609375 },\n { x: 0.796875, y: 0.609375 },\n { x: 0.828125, y: 0.609375 },\n { x: 0.828125, y: 0.609375 },\n { x: 0.859375, y: 0.609375 },\n { x: 0.859375, y: 0.609375 },\n { x: 0.890625, y: 0.609375 },\n { x: 0.890625, y: 0.609375 },\n { x: 0.921875, y: 0.609375 },\n { x: 0.921875, y: 0.609375 },\n { x: 0.953125, y: 0.609375 },\n { x: 0.953125, y: 0.609375 },\n { x: 0.984375, y: 0.609375 },\n { x: 0.984375, y: 0.609375 },\n { x: 0.015625, y: 0.640625 },\n { x: 0.015625, y: 0.640625 },\n { x: 0.046875, y: 0.640625 },\n { x: 0.046875, y: 0.640625 },\n { x: 0.078125, y: 0.640625 },\n { x: 0.078125, y: 0.640625 },\n { x: 0.109375, y: 0.640625 },\n { x: 0.109375, y: 0.640625 },\n { x: 0.140625, y: 0.640625 },\n { x: 0.140625, y: 0.640625 },\n { x: 0.171875, y: 0.640625 },\n { x: 0.171875, y: 0.640625 },\n { x: 0.203125, y: 0.640625 },\n { x: 0.203125, y: 0.640625 },\n { x: 0.234375, y: 0.640625 },\n { x: 0.234375, y: 0.640625 },\n { x: 0.265625, y: 0.640625 },\n { x: 0.265625, y: 0.640625 },\n { x: 0.296875, y: 0.640625 },\n { x: 0.296875, y: 0.640625 },\n { x: 0.328125, y: 0.640625 },\n { x: 0.328125, y: 0.640625 },\n { x: 0.359375, y: 0.640625 },\n { x: 0.359375, y: 0.640625 },\n { x: 0.390625, y: 0.640625 },\n { x: 0.390625, y: 0.640625 },\n { x: 0.421875, y: 0.640625 },\n { x: 0.421875, y: 0.640625 },\n { x: 0.453125, y: 0.640625 },\n { x: 0.453125, y: 0.640625 },\n { x: 0.484375, y: 0.640625 },\n { x: 0.484375, y: 0.640625 },\n { x: 0.515625, y: 0.640625 },\n { x: 0.515625, y: 0.640625 },\n { x: 0.546875, y: 0.640625 },\n { x: 0.546875, y: 0.640625 },\n { x: 0.578125, y: 0.640625 },\n { x: 0.578125, y: 0.640625 },\n { x: 0.609375, y: 0.640625 },\n { x: 0.609375, y: 0.640625 },\n { x: 0.640625, y: 0.640625 },\n { x: 0.640625, y: 0.640625 },\n { x: 0.671875, y: 0.640625 },\n { x: 0.671875, y: 0.640625 },\n { x: 0.703125, y: 0.640625 },\n { x: 0.703125, y: 0.640625 },\n { x: 0.734375, y: 0.640625 },\n { x: 0.734375, y: 0.640625 },\n { x: 0.765625, y: 0.640625 },\n { x: 0.765625, y: 0.640625 },\n { x: 0.796875, y: 0.640625 },\n { x: 0.796875, y: 0.640625 },\n { x: 0.828125, y: 0.640625 },\n { x: 0.828125, y: 0.640625 },\n { x: 0.859375, y: 0.640625 },\n { x: 0.859375, y: 0.640625 },\n { x: 0.890625, y: 0.640625 },\n { x: 0.890625, y: 0.640625 },\n { x: 0.921875, y: 0.640625 },\n { x: 0.921875, y: 0.640625 },\n { x: 0.953125, y: 0.640625 },\n { x: 0.953125, y: 0.640625 },\n { x: 0.984375, y: 0.640625 },\n { x: 0.984375, y: 0.640625 },\n { x: 0.015625, y: 0.671875 },\n { x: 0.015625, y: 0.671875 },\n { x: 0.046875, y: 0.671875 },\n { x: 0.046875, y: 0.671875 },\n { x: 0.078125, y: 0.671875 },\n { x: 0.078125, y: 0.671875 },\n { x: 0.109375, y: 0.671875 },\n { x: 0.109375, y: 0.671875 },\n { x: 0.140625, y: 0.671875 },\n { x: 0.140625, y: 0.671875 },\n { x: 0.171875, y: 0.671875 },\n { x: 0.171875, y: 0.671875 },\n { x: 0.203125, y: 0.671875 },\n { x: 0.203125, y: 0.671875 },\n { x: 0.234375, y: 0.671875 },\n { x: 0.234375, y: 0.671875 },\n { x: 0.265625, y: 0.671875 },\n { x: 0.265625, y: 0.671875 },\n { x: 0.296875, y: 0.671875 },\n { x: 0.296875, y: 0.671875 },\n { x: 0.328125, y: 0.671875 },\n { x: 0.328125, y: 0.671875 },\n { x: 0.359375, y: 0.671875 },\n { x: 0.359375, y: 0.671875 },\n { x: 0.390625, y: 0.671875 },\n { x: 0.390625, y: 0.671875 },\n { x: 0.421875, y: 0.671875 },\n { x: 0.421875, y: 0.671875 },\n { x: 0.453125, y: 0.671875 },\n { x: 0.453125, y: 0.671875 },\n { x: 0.484375, y: 0.671875 },\n { x: 0.484375, y: 0.671875 },\n { x: 0.515625, y: 0.671875 },\n { x: 0.515625, y: 0.671875 },\n { x: 0.546875, y: 0.671875 },\n { x: 0.546875, y: 0.671875 },\n { x: 0.578125, y: 0.671875 },\n { x: 0.578125, y: 0.671875 },\n { x: 0.609375, y: 0.671875 },\n { x: 0.609375, y: 0.671875 },\n { x: 0.640625, y: 0.671875 },\n { x: 0.640625, y: 0.671875 },\n { x: 0.671875, y: 0.671875 },\n { x: 0.671875, y: 0.671875 },\n { x: 0.703125, y: 0.671875 },\n { x: 0.703125, y: 0.671875 },\n { x: 0.734375, y: 0.671875 },\n { x: 0.734375, y: 0.671875 },\n { x: 0.765625, y: 0.671875 },\n { x: 0.765625, y: 0.671875 },\n { x: 0.796875, y: 0.671875 },\n { x: 0.796875, y: 0.671875 },\n { x: 0.828125, y: 0.671875 },\n { x: 0.828125, y: 0.671875 },\n { x: 0.859375, y: 0.671875 },\n { x: 0.859375, y: 0.671875 },\n { x: 0.890625, y: 0.671875 },\n { x: 0.890625, y: 0.671875 },\n { x: 0.921875, y: 0.671875 },\n { x: 0.921875, y: 0.671875 },\n { x: 0.953125, y: 0.671875 },\n { x: 0.953125, y: 0.671875 },\n { x: 0.984375, y: 0.671875 },\n { x: 0.984375, y: 0.671875 },\n { x: 0.015625, y: 0.703125 },\n { x: 0.015625, y: 0.703125 },\n { x: 0.046875, y: 0.703125 },\n { x: 0.046875, y: 0.703125 },\n { x: 0.078125, y: 0.703125 },\n { x: 0.078125, y: 0.703125 },\n { x: 0.109375, y: 0.703125 },\n { x: 0.109375, y: 0.703125 },\n { x: 0.140625, y: 0.703125 },\n { x: 0.140625, y: 0.703125 },\n { x: 0.171875, y: 0.703125 },\n { x: 0.171875, y: 0.703125 },\n { x: 0.203125, y: 0.703125 },\n { x: 0.203125, y: 0.703125 },\n { x: 0.234375, y: 0.703125 },\n { x: 0.234375, y: 0.703125 },\n { x: 0.265625, y: 0.703125 },\n { x: 0.265625, y: 0.703125 },\n { x: 0.296875, y: 0.703125 },\n { x: 0.296875, y: 0.703125 },\n { x: 0.328125, y: 0.703125 },\n { x: 0.328125, y: 0.703125 },\n { x: 0.359375, y: 0.703125 },\n { x: 0.359375, y: 0.703125 },\n { x: 0.390625, y: 0.703125 },\n { x: 0.390625, y: 0.703125 },\n { x: 0.421875, y: 0.703125 },\n { x: 0.421875, y: 0.703125 },\n { x: 0.453125, y: 0.703125 },\n { x: 0.453125, y: 0.703125 },\n { x: 0.484375, y: 0.703125 },\n { x: 0.484375, y: 0.703125 },\n { x: 0.515625, y: 0.703125 },\n { x: 0.515625, y: 0.703125 },\n { x: 0.546875, y: 0.703125 },\n { x: 0.546875, y: 0.703125 },\n { x: 0.578125, y: 0.703125 },\n { x: 0.578125, y: 0.703125 },\n { x: 0.609375, y: 0.703125 },\n { x: 0.609375, y: 0.703125 },\n { x: 0.640625, y: 0.703125 },\n { x: 0.640625, y: 0.703125 },\n { x: 0.671875, y: 0.703125 },\n { x: 0.671875, y: 0.703125 },\n { x: 0.703125, y: 0.703125 },\n { x: 0.703125, y: 0.703125 },\n { x: 0.734375, y: 0.703125 },\n { x: 0.734375, y: 0.703125 },\n { x: 0.765625, y: 0.703125 },\n { x: 0.765625, y: 0.703125 },\n { x: 0.796875, y: 0.703125 },\n { x: 0.796875, y: 0.703125 },\n { x: 0.828125, y: 0.703125 },\n { x: 0.828125, y: 0.703125 },\n { x: 0.859375, y: 0.703125 },\n { x: 0.859375, y: 0.703125 },\n { x: 0.890625, y: 0.703125 },\n { x: 0.890625, y: 0.703125 },\n { x: 0.921875, y: 0.703125 },\n { x: 0.921875, y: 0.703125 },\n { x: 0.953125, y: 0.703125 },\n { x: 0.953125, y: 0.703125 },\n { x: 0.984375, y: 0.703125 },\n { x: 0.984375, y: 0.703125 },\n { x: 0.015625, y: 0.734375 },\n { x: 0.015625, y: 0.734375 },\n { x: 0.046875, y: 0.734375 },\n { x: 0.046875, y: 0.734375 },\n { x: 0.078125, y: 0.734375 },\n { x: 0.078125, y: 0.734375 },\n { x: 0.109375, y: 0.734375 },\n { x: 0.109375, y: 0.734375 },\n { x: 0.140625, y: 0.734375 },\n { x: 0.140625, y: 0.734375 },\n { x: 0.171875, y: 0.734375 },\n { x: 0.171875, y: 0.734375 },\n { x: 0.203125, y: 0.734375 },\n { x: 0.203125, y: 0.734375 },\n { x: 0.234375, y: 0.734375 },\n { x: 0.234375, y: 0.734375 },\n { x: 0.265625, y: 0.734375 },\n { x: 0.265625, y: 0.734375 },\n { x: 0.296875, y: 0.734375 },\n { x: 0.296875, y: 0.734375 },\n { x: 0.328125, y: 0.734375 },\n { x: 0.328125, y: 0.734375 },\n { x: 0.359375, y: 0.734375 },\n { x: 0.359375, y: 0.734375 },\n { x: 0.390625, y: 0.734375 },\n { x: 0.390625, y: 0.734375 },\n { x: 0.421875, y: 0.734375 },\n { x: 0.421875, y: 0.734375 },\n { x: 0.453125, y: 0.734375 },\n { x: 0.453125, y: 0.734375 },\n { x: 0.484375, y: 0.734375 },\n { x: 0.484375, y: 0.734375 },\n { x: 0.515625, y: 0.734375 },\n { x: 0.515625, y: 0.734375 },\n { x: 0.546875, y: 0.734375 },\n { x: 0.546875, y: 0.734375 },\n { x: 0.578125, y: 0.734375 },\n { x: 0.578125, y: 0.734375 },\n { x: 0.609375, y: 0.734375 },\n { x: 0.609375, y: 0.734375 },\n { x: 0.640625, y: 0.734375 },\n { x: 0.640625, y: 0.734375 },\n { x: 0.671875, y: 0.734375 },\n { x: 0.671875, y: 0.734375 },\n { x: 0.703125, y: 0.734375 },\n { x: 0.703125, y: 0.734375 },\n { x: 0.734375, y: 0.734375 },\n { x: 0.734375, y: 0.734375 },\n { x: 0.765625, y: 0.734375 },\n { x: 0.765625, y: 0.734375 },\n { x: 0.796875, y: 0.734375 },\n { x: 0.796875, y: 0.734375 },\n { x: 0.828125, y: 0.734375 },\n { x: 0.828125, y: 0.734375 },\n { x: 0.859375, y: 0.734375 },\n { x: 0.859375, y: 0.734375 },\n { x: 0.890625, y: 0.734375 },\n { x: 0.890625, y: 0.734375 },\n { x: 0.921875, y: 0.734375 },\n { x: 0.921875, y: 0.734375 },\n { x: 0.953125, y: 0.734375 },\n { x: 0.953125, y: 0.734375 },\n { x: 0.984375, y: 0.734375 },\n { x: 0.984375, y: 0.734375 },\n { x: 0.015625, y: 0.765625 },\n { x: 0.015625, y: 0.765625 },\n { x: 0.046875, y: 0.765625 },\n { x: 0.046875, y: 0.765625 },\n { x: 0.078125, y: 0.765625 },\n { x: 0.078125, y: 0.765625 },\n { x: 0.109375, y: 0.765625 },\n { x: 0.109375, y: 0.765625 },\n { x: 0.140625, y: 0.765625 },\n { x: 0.140625, y: 0.765625 },\n { x: 0.171875, y: 0.765625 },\n { x: 0.171875, y: 0.765625 },\n { x: 0.203125, y: 0.765625 },\n { x: 0.203125, y: 0.765625 },\n { x: 0.234375, y: 0.765625 },\n { x: 0.234375, y: 0.765625 },\n { x: 0.265625, y: 0.765625 },\n { x: 0.265625, y: 0.765625 },\n { x: 0.296875, y: 0.765625 },\n { x: 0.296875, y: 0.765625 },\n { x: 0.328125, y: 0.765625 },\n { x: 0.328125, y: 0.765625 },\n { x: 0.359375, y: 0.765625 },\n { x: 0.359375, y: 0.765625 },\n { x: 0.390625, y: 0.765625 },\n { x: 0.390625, y: 0.765625 },\n { x: 0.421875, y: 0.765625 },\n { x: 0.421875, y: 0.765625 },\n { x: 0.453125, y: 0.765625 },\n { x: 0.453125, y: 0.765625 },\n { x: 0.484375, y: 0.765625 },\n { x: 0.484375, y: 0.765625 },\n { x: 0.515625, y: 0.765625 },\n { x: 0.515625, y: 0.765625 },\n { x: 0.546875, y: 0.765625 },\n { x: 0.546875, y: 0.765625 },\n { x: 0.578125, y: 0.765625 },\n { x: 0.578125, y: 0.765625 },\n { x: 0.609375, y: 0.765625 },\n { x: 0.609375, y: 0.765625 },\n { x: 0.640625, y: 0.765625 },\n { x: 0.640625, y: 0.765625 },\n { x: 0.671875, y: 0.765625 },\n { x: 0.671875, y: 0.765625 },\n { x: 0.703125, y: 0.765625 },\n { x: 0.703125, y: 0.765625 },\n { x: 0.734375, y: 0.765625 },\n { x: 0.734375, y: 0.765625 },\n { x: 0.765625, y: 0.765625 },\n { x: 0.765625, y: 0.765625 },\n { x: 0.796875, y: 0.765625 },\n { x: 0.796875, y: 0.765625 },\n { x: 0.828125, y: 0.765625 },\n { x: 0.828125, y: 0.765625 },\n { x: 0.859375, y: 0.765625 },\n { x: 0.859375, y: 0.765625 },\n { x: 0.890625, y: 0.765625 },\n { x: 0.890625, y: 0.765625 },\n { x: 0.921875, y: 0.765625 },\n { x: 0.921875, y: 0.765625 },\n { x: 0.953125, y: 0.765625 },\n { x: 0.953125, y: 0.765625 },\n { x: 0.984375, y: 0.765625 },\n { x: 0.984375, y: 0.765625 },\n { x: 0.015625, y: 0.796875 },\n { x: 0.015625, y: 0.796875 },\n { x: 0.046875, y: 0.796875 },\n { x: 0.046875, y: 0.796875 },\n { x: 0.078125, y: 0.796875 },\n { x: 0.078125, y: 0.796875 },\n { x: 0.109375, y: 0.796875 },\n { x: 0.109375, y: 0.796875 },\n { x: 0.140625, y: 0.796875 },\n { x: 0.140625, y: 0.796875 },\n { x: 0.171875, y: 0.796875 },\n { x: 0.171875, y: 0.796875 },\n { x: 0.203125, y: 0.796875 },\n { x: 0.203125, y: 0.796875 },\n { x: 0.234375, y: 0.796875 },\n { x: 0.234375, y: 0.796875 },\n { x: 0.265625, y: 0.796875 },\n { x: 0.265625, y: 0.796875 },\n { x: 0.296875, y: 0.796875 },\n { x: 0.296875, y: 0.796875 },\n { x: 0.328125, y: 0.796875 },\n { x: 0.328125, y: 0.796875 },\n { x: 0.359375, y: 0.796875 },\n { x: 0.359375, y: 0.796875 },\n { x: 0.390625, y: 0.796875 },\n { x: 0.390625, y: 0.796875 },\n { x: 0.421875, y: 0.796875 },\n { x: 0.421875, y: 0.796875 },\n { x: 0.453125, y: 0.796875 },\n { x: 0.453125, y: 0.796875 },\n { x: 0.484375, y: 0.796875 },\n { x: 0.484375, y: 0.796875 },\n { x: 0.515625, y: 0.796875 },\n { x: 0.515625, y: 0.796875 },\n { x: 0.546875, y: 0.796875 },\n { x: 0.546875, y: 0.796875 },\n { x: 0.578125, y: 0.796875 },\n { x: 0.578125, y: 0.796875 },\n { x: 0.609375, y: 0.796875 },\n { x: 0.609375, y: 0.796875 },\n { x: 0.640625, y: 0.796875 },\n { x: 0.640625, y: 0.796875 },\n { x: 0.671875, y: 0.796875 },\n { x: 0.671875, y: 0.796875 },\n { x: 0.703125, y: 0.796875 },\n { x: 0.703125, y: 0.796875 },\n { x: 0.734375, y: 0.796875 },\n { x: 0.734375, y: 0.796875 },\n { x: 0.765625, y: 0.796875 },\n { x: 0.765625, y: 0.796875 },\n { x: 0.796875, y: 0.796875 },\n { x: 0.796875, y: 0.796875 },\n { x: 0.828125, y: 0.796875 },\n { x: 0.828125, y: 0.796875 },\n { x: 0.859375, y: 0.796875 },\n { x: 0.859375, y: 0.796875 },\n { x: 0.890625, y: 0.796875 },\n { x: 0.890625, y: 0.796875 },\n { x: 0.921875, y: 0.796875 },\n { x: 0.921875, y: 0.796875 },\n { x: 0.953125, y: 0.796875 },\n { x: 0.953125, y: 0.796875 },\n { x: 0.984375, y: 0.796875 },\n { x: 0.984375, y: 0.796875 },\n { x: 0.015625, y: 0.828125 },\n { x: 0.015625, y: 0.828125 },\n { x: 0.046875, y: 0.828125 },\n { x: 0.046875, y: 0.828125 },\n { x: 0.078125, y: 0.828125 },\n { x: 0.078125, y: 0.828125 },\n { x: 0.109375, y: 0.828125 },\n { x: 0.109375, y: 0.828125 },\n { x: 0.140625, y: 0.828125 },\n { x: 0.140625, y: 0.828125 },\n { x: 0.171875, y: 0.828125 },\n { x: 0.171875, y: 0.828125 },\n { x: 0.203125, y: 0.828125 },\n { x: 0.203125, y: 0.828125 },\n { x: 0.234375, y: 0.828125 },\n { x: 0.234375, y: 0.828125 },\n { x: 0.265625, y: 0.828125 },\n { x: 0.265625, y: 0.828125 },\n { x: 0.296875, y: 0.828125 },\n { x: 0.296875, y: 0.828125 },\n { x: 0.328125, y: 0.828125 },\n { x: 0.328125, y: 0.828125 },\n { x: 0.359375, y: 0.828125 },\n { x: 0.359375, y: 0.828125 },\n { x: 0.390625, y: 0.828125 },\n { x: 0.390625, y: 0.828125 },\n { x: 0.421875, y: 0.828125 },\n { x: 0.421875, y: 0.828125 },\n { x: 0.453125, y: 0.828125 },\n { x: 0.453125, y: 0.828125 },\n { x: 0.484375, y: 0.828125 },\n { x: 0.484375, y: 0.828125 },\n { x: 0.515625, y: 0.828125 },\n { x: 0.515625, y: 0.828125 },\n { x: 0.546875, y: 0.828125 },\n { x: 0.546875, y: 0.828125 },\n { x: 0.578125, y: 0.828125 },\n { x: 0.578125, y: 0.828125 },\n { x: 0.609375, y: 0.828125 },\n { x: 0.609375, y: 0.828125 },\n { x: 0.640625, y: 0.828125 },\n { x: 0.640625, y: 0.828125 },\n { x: 0.671875, y: 0.828125 },\n { x: 0.671875, y: 0.828125 },\n { x: 0.703125, y: 0.828125 },\n { x: 0.703125, y: 0.828125 },\n { x: 0.734375, y: 0.828125 },\n { x: 0.734375, y: 0.828125 },\n { x: 0.765625, y: 0.828125 },\n { x: 0.765625, y: 0.828125 },\n { x: 0.796875, y: 0.828125 },\n { x: 0.796875, y: 0.828125 },\n { x: 0.828125, y: 0.828125 },\n { x: 0.828125, y: 0.828125 },\n { x: 0.859375, y: 0.828125 },\n { x: 0.859375, y: 0.828125 },\n { x: 0.890625, y: 0.828125 },\n { x: 0.890625, y: 0.828125 },\n { x: 0.921875, y: 0.828125 },\n { x: 0.921875, y: 0.828125 },\n { x: 0.953125, y: 0.828125 },\n { x: 0.953125, y: 0.828125 },\n { x: 0.984375, y: 0.828125 },\n { x: 0.984375, y: 0.828125 },\n { x: 0.015625, y: 0.859375 },\n { x: 0.015625, y: 0.859375 },\n { x: 0.046875, y: 0.859375 },\n { x: 0.046875, y: 0.859375 },\n { x: 0.078125, y: 0.859375 },\n { x: 0.078125, y: 0.859375 },\n { x: 0.109375, y: 0.859375 },\n { x: 0.109375, y: 0.859375 },\n { x: 0.140625, y: 0.859375 },\n { x: 0.140625, y: 0.859375 },\n { x: 0.171875, y: 0.859375 },\n { x: 0.171875, y: 0.859375 },\n { x: 0.203125, y: 0.859375 },\n { x: 0.203125, y: 0.859375 },\n { x: 0.234375, y: 0.859375 },\n { x: 0.234375, y: 0.859375 },\n { x: 0.265625, y: 0.859375 },\n { x: 0.265625, y: 0.859375 },\n { x: 0.296875, y: 0.859375 },\n { x: 0.296875, y: 0.859375 },\n { x: 0.328125, y: 0.859375 },\n { x: 0.328125, y: 0.859375 },\n { x: 0.359375, y: 0.859375 },\n { x: 0.359375, y: 0.859375 },\n { x: 0.390625, y: 0.859375 },\n { x: 0.390625, y: 0.859375 },\n { x: 0.421875, y: 0.859375 },\n { x: 0.421875, y: 0.859375 },\n { x: 0.453125, y: 0.859375 },\n { x: 0.453125, y: 0.859375 },\n { x: 0.484375, y: 0.859375 },\n { x: 0.484375, y: 0.859375 },\n { x: 0.515625, y: 0.859375 },\n { x: 0.515625, y: 0.859375 },\n { x: 0.546875, y: 0.859375 },\n { x: 0.546875, y: 0.859375 },\n { x: 0.578125, y: 0.859375 },\n { x: 0.578125, y: 0.859375 },\n { x: 0.609375, y: 0.859375 },\n { x: 0.609375, y: 0.859375 },\n { x: 0.640625, y: 0.859375 },\n { x: 0.640625, y: 0.859375 },\n { x: 0.671875, y: 0.859375 },\n { x: 0.671875, y: 0.859375 },\n { x: 0.703125, y: 0.859375 },\n { x: 0.703125, y: 0.859375 },\n { x: 0.734375, y: 0.859375 },\n { x: 0.734375, y: 0.859375 },\n { x: 0.765625, y: 0.859375 },\n { x: 0.765625, y: 0.859375 },\n { x: 0.796875, y: 0.859375 },\n { x: 0.796875, y: 0.859375 },\n { x: 0.828125, y: 0.859375 },\n { x: 0.828125, y: 0.859375 },\n { x: 0.859375, y: 0.859375 },\n { x: 0.859375, y: 0.859375 },\n { x: 0.890625, y: 0.859375 },\n { x: 0.890625, y: 0.859375 },\n { x: 0.921875, y: 0.859375 },\n { x: 0.921875, y: 0.859375 },\n { x: 0.953125, y: 0.859375 },\n { x: 0.953125, y: 0.859375 },\n { x: 0.984375, y: 0.859375 },\n { x: 0.984375, y: 0.859375 },\n { x: 0.015625, y: 0.890625 },\n { x: 0.015625, y: 0.890625 },\n { x: 0.046875, y: 0.890625 },\n { x: 0.046875, y: 0.890625 },\n { x: 0.078125, y: 0.890625 },\n { x: 0.078125, y: 0.890625 },\n { x: 0.109375, y: 0.890625 },\n { x: 0.109375, y: 0.890625 },\n { x: 0.140625, y: 0.890625 },\n { x: 0.140625, y: 0.890625 },\n { x: 0.171875, y: 0.890625 },\n { x: 0.171875, y: 0.890625 },\n { x: 0.203125, y: 0.890625 },\n { x: 0.203125, y: 0.890625 },\n { x: 0.234375, y: 0.890625 },\n { x: 0.234375, y: 0.890625 },\n { x: 0.265625, y: 0.890625 },\n { x: 0.265625, y: 0.890625 },\n { x: 0.296875, y: 0.890625 },\n { x: 0.296875, y: 0.890625 },\n { x: 0.328125, y: 0.890625 },\n { x: 0.328125, y: 0.890625 },\n { x: 0.359375, y: 0.890625 },\n { x: 0.359375, y: 0.890625 },\n { x: 0.390625, y: 0.890625 },\n { x: 0.390625, y: 0.890625 },\n { x: 0.421875, y: 0.890625 },\n { x: 0.421875, y: 0.890625 },\n { x: 0.453125, y: 0.890625 },\n { x: 0.453125, y: 0.890625 },\n { x: 0.484375, y: 0.890625 },\n { x: 0.484375, y: 0.890625 },\n { x: 0.515625, y: 0.890625 },\n { x: 0.515625, y: 0.890625 },\n { x: 0.546875, y: 0.890625 },\n { x: 0.546875, y: 0.890625 },\n { x: 0.578125, y: 0.890625 },\n { x: 0.578125, y: 0.890625 },\n { x: 0.609375, y: 0.890625 },\n { x: 0.609375, y: 0.890625 },\n { x: 0.640625, y: 0.890625 },\n { x: 0.640625, y: 0.890625 },\n { x: 0.671875, y: 0.890625 },\n { x: 0.671875, y: 0.890625 },\n { x: 0.703125, y: 0.890625 },\n { x: 0.703125, y: 0.890625 },\n { x: 0.734375, y: 0.890625 },\n { x: 0.734375, y: 0.890625 },\n { x: 0.765625, y: 0.890625 },\n { x: 0.765625, y: 0.890625 },\n { x: 0.796875, y: 0.890625 },\n { x: 0.796875, y: 0.890625 },\n { x: 0.828125, y: 0.890625 },\n { x: 0.828125, y: 0.890625 },\n { x: 0.859375, y: 0.890625 },\n { x: 0.859375, y: 0.890625 },\n { x: 0.890625, y: 0.890625 },\n { x: 0.890625, y: 0.890625 },\n { x: 0.921875, y: 0.890625 },\n { x: 0.921875, y: 0.890625 },\n { x: 0.953125, y: 0.890625 },\n { x: 0.953125, y: 0.890625 },\n { x: 0.984375, y: 0.890625 },\n { x: 0.984375, y: 0.890625 },\n { x: 0.015625, y: 0.921875 },\n { x: 0.015625, y: 0.921875 },\n { x: 0.046875, y: 0.921875 },\n { x: 0.046875, y: 0.921875 },\n { x: 0.078125, y: 0.921875 },\n { x: 0.078125, y: 0.921875 },\n { x: 0.109375, y: 0.921875 },\n { x: 0.109375, y: 0.921875 },\n { x: 0.140625, y: 0.921875 },\n { x: 0.140625, y: 0.921875 },\n { x: 0.171875, y: 0.921875 },\n { x: 0.171875, y: 0.921875 },\n { x: 0.203125, y: 0.921875 },\n { x: 0.203125, y: 0.921875 },\n { x: 0.234375, y: 0.921875 },\n { x: 0.234375, y: 0.921875 },\n { x: 0.265625, y: 0.921875 },\n { x: 0.265625, y: 0.921875 },\n { x: 0.296875, y: 0.921875 },\n { x: 0.296875, y: 0.921875 },\n { x: 0.328125, y: 0.921875 },\n { x: 0.328125, y: 0.921875 },\n { x: 0.359375, y: 0.921875 },\n { x: 0.359375, y: 0.921875 },\n { x: 0.390625, y: 0.921875 },\n { x: 0.390625, y: 0.921875 },\n { x: 0.421875, y: 0.921875 },\n { x: 0.421875, y: 0.921875 },\n { x: 0.453125, y: 0.921875 },\n { x: 0.453125, y: 0.921875 },\n { x: 0.484375, y: 0.921875 },\n { x: 0.484375, y: 0.921875 },\n { x: 0.515625, y: 0.921875 },\n { x: 0.515625, y: 0.921875 },\n { x: 0.546875, y: 0.921875 },\n { x: 0.546875, y: 0.921875 },\n { x: 0.578125, y: 0.921875 },\n { x: 0.578125, y: 0.921875 },\n { x: 0.609375, y: 0.921875 },\n { x: 0.609375, y: 0.921875 },\n { x: 0.640625, y: 0.921875 },\n { x: 0.640625, y: 0.921875 },\n { x: 0.671875, y: 0.921875 },\n { x: 0.671875, y: 0.921875 },\n { x: 0.703125, y: 0.921875 },\n { x: 0.703125, y: 0.921875 },\n { x: 0.734375, y: 0.921875 },\n { x: 0.734375, y: 0.921875 },\n { x: 0.765625, y: 0.921875 },\n { x: 0.765625, y: 0.921875 },\n { x: 0.796875, y: 0.921875 },\n { x: 0.796875, y: 0.921875 },\n { x: 0.828125, y: 0.921875 },\n { x: 0.828125, y: 0.921875 },\n { x: 0.859375, y: 0.921875 },\n { x: 0.859375, y: 0.921875 },\n { x: 0.890625, y: 0.921875 },\n { x: 0.890625, y: 0.921875 },\n { x: 0.921875, y: 0.921875 },\n { x: 0.921875, y: 0.921875 },\n { x: 0.953125, y: 0.921875 },\n { x: 0.953125, y: 0.921875 },\n { x: 0.984375, y: 0.921875 },\n { x: 0.984375, y: 0.921875 },\n { x: 0.015625, y: 0.953125 },\n { x: 0.015625, y: 0.953125 },\n { x: 0.046875, y: 0.953125 },\n { x: 0.046875, y: 0.953125 },\n { x: 0.078125, y: 0.953125 },\n { x: 0.078125, y: 0.953125 },\n { x: 0.109375, y: 0.953125 },\n { x: 0.109375, y: 0.953125 },\n { x: 0.140625, y: 0.953125 },\n { x: 0.140625, y: 0.953125 },\n { x: 0.171875, y: 0.953125 },\n { x: 0.171875, y: 0.953125 },\n { x: 0.203125, y: 0.953125 },\n { x: 0.203125, y: 0.953125 },\n { x: 0.234375, y: 0.953125 },\n { x: 0.234375, y: 0.953125 },\n { x: 0.265625, y: 0.953125 },\n { x: 0.265625, y: 0.953125 },\n { x: 0.296875, y: 0.953125 },\n { x: 0.296875, y: 0.953125 },\n { x: 0.328125, y: 0.953125 },\n { x: 0.328125, y: 0.953125 },\n { x: 0.359375, y: 0.953125 },\n { x: 0.359375, y: 0.953125 },\n { x: 0.390625, y: 0.953125 },\n { x: 0.390625, y: 0.953125 },\n { x: 0.421875, y: 0.953125 },\n { x: 0.421875, y: 0.953125 },\n { x: 0.453125, y: 0.953125 },\n { x: 0.453125, y: 0.953125 },\n { x: 0.484375, y: 0.953125 },\n { x: 0.484375, y: 0.953125 },\n { x: 0.515625, y: 0.953125 },\n { x: 0.515625, y: 0.953125 },\n { x: 0.546875, y: 0.953125 },\n { x: 0.546875, y: 0.953125 },\n { x: 0.578125, y: 0.953125 },\n { x: 0.578125, y: 0.953125 },\n { x: 0.609375, y: 0.953125 },\n { x: 0.609375, y: 0.953125 },\n { x: 0.640625, y: 0.953125 },\n { x: 0.640625, y: 0.953125 },\n { x: 0.671875, y: 0.953125 },\n { x: 0.671875, y: 0.953125 },\n { x: 0.703125, y: 0.953125 },\n { x: 0.703125, y: 0.953125 },\n { x: 0.734375, y: 0.953125 },\n { x: 0.734375, y: 0.953125 },\n { x: 0.765625, y: 0.953125 },\n { x: 0.765625, y: 0.953125 },\n { x: 0.796875, y: 0.953125 },\n { x: 0.796875, y: 0.953125 },\n { x: 0.828125, y: 0.953125 },\n { x: 0.828125, y: 0.953125 },\n { x: 0.859375, y: 0.953125 },\n { x: 0.859375, y: 0.953125 },\n { x: 0.890625, y: 0.953125 },\n { x: 0.890625, y: 0.953125 },\n { x: 0.921875, y: 0.953125 },\n { x: 0.921875, y: 0.953125 },\n { x: 0.953125, y: 0.953125 },\n { x: 0.953125, y: 0.953125 },\n { x: 0.984375, y: 0.953125 },\n { x: 0.984375, y: 0.953125 },\n { x: 0.015625, y: 0.984375 },\n { x: 0.015625, y: 0.984375 },\n { x: 0.046875, y: 0.984375 },\n { x: 0.046875, y: 0.984375 },\n { x: 0.078125, y: 0.984375 },\n { x: 0.078125, y: 0.984375 },\n { x: 0.109375, y: 0.984375 },\n { x: 0.109375, y: 0.984375 },\n { x: 0.140625, y: 0.984375 },\n { x: 0.140625, y: 0.984375 },\n { x: 0.171875, y: 0.984375 },\n { x: 0.171875, y: 0.984375 },\n { x: 0.203125, y: 0.984375 },\n { x: 0.203125, y: 0.984375 },\n { x: 0.234375, y: 0.984375 },\n { x: 0.234375, y: 0.984375 },\n { x: 0.265625, y: 0.984375 },\n { x: 0.265625, y: 0.984375 },\n { x: 0.296875, y: 0.984375 },\n { x: 0.296875, y: 0.984375 },\n { x: 0.328125, y: 0.984375 },\n { x: 0.328125, y: 0.984375 },\n { x: 0.359375, y: 0.984375 },\n { x: 0.359375, y: 0.984375 },\n { x: 0.390625, y: 0.984375 },\n { x: 0.390625, y: 0.984375 },\n { x: 0.421875, y: 0.984375 },\n { x: 0.421875, y: 0.984375 },\n { x: 0.453125, y: 0.984375 },\n { x: 0.453125, y: 0.984375 },\n { x: 0.484375, y: 0.984375 },\n { x: 0.484375, y: 0.984375 },\n { x: 0.515625, y: 0.984375 },\n { x: 0.515625, y: 0.984375 },\n { x: 0.546875, y: 0.984375 },\n { x: 0.546875, y: 0.984375 },\n { x: 0.578125, y: 0.984375 },\n { x: 0.578125, y: 0.984375 },\n { x: 0.609375, y: 0.984375 },\n { x: 0.609375, y: 0.984375 },\n { x: 0.640625, y: 0.984375 },\n { x: 0.640625, y: 0.984375 },\n { x: 0.671875, y: 0.984375 },\n { x: 0.671875, y: 0.984375 },\n { x: 0.703125, y: 0.984375 },\n { x: 0.703125, y: 0.984375 },\n { x: 0.734375, y: 0.984375 },\n { x: 0.734375, y: 0.984375 },\n { x: 0.765625, y: 0.984375 },\n { x: 0.765625, y: 0.984375 },\n { x: 0.796875, y: 0.984375 },\n { x: 0.796875, y: 0.984375 },\n { x: 0.828125, y: 0.984375 },\n { x: 0.828125, y: 0.984375 },\n { x: 0.859375, y: 0.984375 },\n { x: 0.859375, y: 0.984375 },\n { x: 0.890625, y: 0.984375 },\n { x: 0.890625, y: 0.984375 },\n { x: 0.921875, y: 0.984375 },\n { x: 0.921875, y: 0.984375 },\n { x: 0.953125, y: 0.984375 },\n { x: 0.953125, y: 0.984375 },\n { x: 0.984375, y: 0.984375 },\n { x: 0.984375, y: 0.984375 },\n { x: 0.03125, y: 0.03125 },\n { x: 0.03125, y: 0.03125 },\n { x: 0.09375, y: 0.03125 },\n { x: 0.09375, y: 0.03125 },\n { x: 0.15625, y: 0.03125 },\n { x: 0.15625, y: 0.03125 },\n { x: 0.21875, y: 0.03125 },\n { x: 0.21875, y: 0.03125 },\n { x: 0.28125, y: 0.03125 },\n { x: 0.28125, y: 0.03125 },\n { x: 0.34375, y: 0.03125 },\n { x: 0.34375, y: 0.03125 },\n { x: 0.40625, y: 0.03125 },\n { x: 0.40625, y: 0.03125 },\n { x: 0.46875, y: 0.03125 },\n { x: 0.46875, y: 0.03125 },\n { x: 0.53125, y: 0.03125 },\n { x: 0.53125, y: 0.03125 },\n { x: 0.59375, y: 0.03125 },\n { x: 0.59375, y: 0.03125 },\n { x: 0.65625, y: 0.03125 },\n { x: 0.65625, y: 0.03125 },\n { x: 0.71875, y: 0.03125 },\n { x: 0.71875, y: 0.03125 },\n { x: 0.78125, y: 0.03125 },\n { x: 0.78125, y: 0.03125 },\n { x: 0.84375, y: 0.03125 },\n { x: 0.84375, y: 0.03125 },\n { x: 0.90625, y: 0.03125 },\n { x: 0.90625, y: 0.03125 },\n { x: 0.96875, y: 0.03125 },\n { x: 0.96875, y: 0.03125 },\n { x: 0.03125, y: 0.09375 },\n { x: 0.03125, y: 0.09375 },\n { x: 0.09375, y: 0.09375 },\n { x: 0.09375, y: 0.09375 },\n { x: 0.15625, y: 0.09375 },\n { x: 0.15625, y: 0.09375 },\n { x: 0.21875, y: 0.09375 },\n { x: 0.21875, y: 0.09375 },\n { x: 0.28125, y: 0.09375 },\n { x: 0.28125, y: 0.09375 },\n { x: 0.34375, y: 0.09375 },\n { x: 0.34375, y: 0.09375 },\n { x: 0.40625, y: 0.09375 },\n { x: 0.40625, y: 0.09375 },\n { x: 0.46875, y: 0.09375 },\n { x: 0.46875, y: 0.09375 },\n { x: 0.53125, y: 0.09375 },\n { x: 0.53125, y: 0.09375 },\n { x: 0.59375, y: 0.09375 },\n { x: 0.59375, y: 0.09375 },\n { x: 0.65625, y: 0.09375 },\n { x: 0.65625, y: 0.09375 },\n { x: 0.71875, y: 0.09375 },\n { x: 0.71875, y: 0.09375 },\n { x: 0.78125, y: 0.09375 },\n { x: 0.78125, y: 0.09375 },\n { x: 0.84375, y: 0.09375 },\n { x: 0.84375, y: 0.09375 },\n { x: 0.90625, y: 0.09375 },\n { x: 0.90625, y: 0.09375 },\n { x: 0.96875, y: 0.09375 },\n { x: 0.96875, y: 0.09375 },\n { x: 0.03125, y: 0.15625 },\n { x: 0.03125, y: 0.15625 },\n { x: 0.09375, y: 0.15625 },\n { x: 0.09375, y: 0.15625 },\n { x: 0.15625, y: 0.15625 },\n { x: 0.15625, y: 0.15625 },\n { x: 0.21875, y: 0.15625 },\n { x: 0.21875, y: 0.15625 },\n { x: 0.28125, y: 0.15625 },\n { x: 0.28125, y: 0.15625 },\n { x: 0.34375, y: 0.15625 },\n { x: 0.34375, y: 0.15625 },\n { x: 0.40625, y: 0.15625 },\n { x: 0.40625, y: 0.15625 },\n { x: 0.46875, y: 0.15625 },\n { x: 0.46875, y: 0.15625 },\n { x: 0.53125, y: 0.15625 },\n { x: 0.53125, y: 0.15625 },\n { x: 0.59375, y: 0.15625 },\n { x: 0.59375, y: 0.15625 },\n { x: 0.65625, y: 0.15625 },\n { x: 0.65625, y: 0.15625 },\n { x: 0.71875, y: 0.15625 },\n { x: 0.71875, y: 0.15625 },\n { x: 0.78125, y: 0.15625 },\n { x: 0.78125, y: 0.15625 },\n { x: 0.84375, y: 0.15625 },\n { x: 0.84375, y: 0.15625 },\n { x: 0.90625, y: 0.15625 },\n { x: 0.90625, y: 0.15625 },\n { x: 0.96875, y: 0.15625 },\n { x: 0.96875, y: 0.15625 },\n { x: 0.03125, y: 0.21875 },\n { x: 0.03125, y: 0.21875 },\n { x: 0.09375, y: 0.21875 },\n { x: 0.09375, y: 0.21875 },\n { x: 0.15625, y: 0.21875 },\n { x: 0.15625, y: 0.21875 },\n { x: 0.21875, y: 0.21875 },\n { x: 0.21875, y: 0.21875 },\n { x: 0.28125, y: 0.21875 },\n { x: 0.28125, y: 0.21875 },\n { x: 0.34375, y: 0.21875 },\n { x: 0.34375, y: 0.21875 },\n { x: 0.40625, y: 0.21875 },\n { x: 0.40625, y: 0.21875 },\n { x: 0.46875, y: 0.21875 },\n { x: 0.46875, y: 0.21875 },\n { x: 0.53125, y: 0.21875 },\n { x: 0.53125, y: 0.21875 },\n { x: 0.59375, y: 0.21875 },\n { x: 0.59375, y: 0.21875 },\n { x: 0.65625, y: 0.21875 },\n { x: 0.65625, y: 0.21875 },\n { x: 0.71875, y: 0.21875 },\n { x: 0.71875, y: 0.21875 },\n { x: 0.78125, y: 0.21875 },\n { x: 0.78125, y: 0.21875 },\n { x: 0.84375, y: 0.21875 },\n { x: 0.84375, y: 0.21875 },\n { x: 0.90625, y: 0.21875 },\n { x: 0.90625, y: 0.21875 },\n { x: 0.96875, y: 0.21875 },\n { x: 0.96875, y: 0.21875 },\n { x: 0.03125, y: 0.28125 },\n { x: 0.03125, y: 0.28125 },\n { x: 0.09375, y: 0.28125 },\n { x: 0.09375, y: 0.28125 },\n { x: 0.15625, y: 0.28125 },\n { x: 0.15625, y: 0.28125 },\n { x: 0.21875, y: 0.28125 },\n { x: 0.21875, y: 0.28125 },\n { x: 0.28125, y: 0.28125 },\n { x: 0.28125, y: 0.28125 },\n { x: 0.34375, y: 0.28125 },\n { x: 0.34375, y: 0.28125 },\n { x: 0.40625, y: 0.28125 },\n { x: 0.40625, y: 0.28125 },\n { x: 0.46875, y: 0.28125 },\n { x: 0.46875, y: 0.28125 },\n { x: 0.53125, y: 0.28125 },\n { x: 0.53125, y: 0.28125 },\n { x: 0.59375, y: 0.28125 },\n { x: 0.59375, y: 0.28125 },\n { x: 0.65625, y: 0.28125 },\n { x: 0.65625, y: 0.28125 },\n { x: 0.71875, y: 0.28125 },\n { x: 0.71875, y: 0.28125 },\n { x: 0.78125, y: 0.28125 },\n { x: 0.78125, y: 0.28125 },\n { x: 0.84375, y: 0.28125 },\n { x: 0.84375, y: 0.28125 },\n { x: 0.90625, y: 0.28125 },\n { x: 0.90625, y: 0.28125 },\n { x: 0.96875, y: 0.28125 },\n { x: 0.96875, y: 0.28125 },\n { x: 0.03125, y: 0.34375 },\n { x: 0.03125, y: 0.34375 },\n { x: 0.09375, y: 0.34375 },\n { x: 0.09375, y: 0.34375 },\n { x: 0.15625, y: 0.34375 },\n { x: 0.15625, y: 0.34375 },\n { x: 0.21875, y: 0.34375 },\n { x: 0.21875, y: 0.34375 },\n { x: 0.28125, y: 0.34375 },\n { x: 0.28125, y: 0.34375 },\n { x: 0.34375, y: 0.34375 },\n { x: 0.34375, y: 0.34375 },\n { x: 0.40625, y: 0.34375 },\n { x: 0.40625, y: 0.34375 },\n { x: 0.46875, y: 0.34375 },\n { x: 0.46875, y: 0.34375 },\n { x: 0.53125, y: 0.34375 },\n { x: 0.53125, y: 0.34375 },\n { x: 0.59375, y: 0.34375 },\n { x: 0.59375, y: 0.34375 },\n { x: 0.65625, y: 0.34375 },\n { x: 0.65625, y: 0.34375 },\n { x: 0.71875, y: 0.34375 },\n { x: 0.71875, y: 0.34375 },\n { x: 0.78125, y: 0.34375 },\n { x: 0.78125, y: 0.34375 },\n { x: 0.84375, y: 0.34375 },\n { x: 0.84375, y: 0.34375 },\n { x: 0.90625, y: 0.34375 },\n { x: 0.90625, y: 0.34375 },\n { x: 0.96875, y: 0.34375 },\n { x: 0.96875, y: 0.34375 },\n { x: 0.03125, y: 0.40625 },\n { x: 0.03125, y: 0.40625 },\n { x: 0.09375, y: 0.40625 },\n { x: 0.09375, y: 0.40625 },\n { x: 0.15625, y: 0.40625 },\n { x: 0.15625, y: 0.40625 },\n { x: 0.21875, y: 0.40625 },\n { x: 0.21875, y: 0.40625 },\n { x: 0.28125, y: 0.40625 },\n { x: 0.28125, y: 0.40625 },\n { x: 0.34375, y: 0.40625 },\n { x: 0.34375, y: 0.40625 },\n { x: 0.40625, y: 0.40625 },\n { x: 0.40625, y: 0.40625 },\n { x: 0.46875, y: 0.40625 },\n { x: 0.46875, y: 0.40625 },\n { x: 0.53125, y: 0.40625 },\n { x: 0.53125, y: 0.40625 },\n { x: 0.59375, y: 0.40625 },\n { x: 0.59375, y: 0.40625 },\n { x: 0.65625, y: 0.40625 },\n { x: 0.65625, y: 0.40625 },\n { x: 0.71875, y: 0.40625 },\n { x: 0.71875, y: 0.40625 },\n { x: 0.78125, y: 0.40625 },\n { x: 0.78125, y: 0.40625 },\n { x: 0.84375, y: 0.40625 },\n { x: 0.84375, y: 0.40625 },\n { x: 0.90625, y: 0.40625 },\n { x: 0.90625, y: 0.40625 },\n { x: 0.96875, y: 0.40625 },\n { x: 0.96875, y: 0.40625 },\n { x: 0.03125, y: 0.46875 },\n { x: 0.03125, y: 0.46875 },\n { x: 0.09375, y: 0.46875 },\n { x: 0.09375, y: 0.46875 },\n { x: 0.15625, y: 0.46875 },\n { x: 0.15625, y: 0.46875 },\n { x: 0.21875, y: 0.46875 },\n { x: 0.21875, y: 0.46875 },\n { x: 0.28125, y: 0.46875 },\n { x: 0.28125, y: 0.46875 },\n { x: 0.34375, y: 0.46875 },\n { x: 0.34375, y: 0.46875 },\n { x: 0.40625, y: 0.46875 },\n { x: 0.40625, y: 0.46875 },\n { x: 0.46875, y: 0.46875 },\n { x: 0.46875, y: 0.46875 },\n { x: 0.53125, y: 0.46875 },\n { x: 0.53125, y: 0.46875 },\n { x: 0.59375, y: 0.46875 },\n { x: 0.59375, y: 0.46875 },\n { x: 0.65625, y: 0.46875 },\n { x: 0.65625, y: 0.46875 },\n { x: 0.71875, y: 0.46875 },\n { x: 0.71875, y: 0.46875 },\n { x: 0.78125, y: 0.46875 },\n { x: 0.78125, y: 0.46875 },\n { x: 0.84375, y: 0.46875 },\n { x: 0.84375, y: 0.46875 },\n { x: 0.90625, y: 0.46875 },\n { x: 0.90625, y: 0.46875 },\n { x: 0.96875, y: 0.46875 },\n { x: 0.96875, y: 0.46875 },\n { x: 0.03125, y: 0.53125 },\n { x: 0.03125, y: 0.53125 },\n { x: 0.09375, y: 0.53125 },\n { x: 0.09375, y: 0.53125 },\n { x: 0.15625, y: 0.53125 },\n { x: 0.15625, y: 0.53125 },\n { x: 0.21875, y: 0.53125 },\n { x: 0.21875, y: 0.53125 },\n { x: 0.28125, y: 0.53125 },\n { x: 0.28125, y: 0.53125 },\n { x: 0.34375, y: 0.53125 },\n { x: 0.34375, y: 0.53125 },\n { x: 0.40625, y: 0.53125 },\n { x: 0.40625, y: 0.53125 },\n { x: 0.46875, y: 0.53125 },\n { x: 0.46875, y: 0.53125 },\n { x: 0.53125, y: 0.53125 },\n { x: 0.53125, y: 0.53125 },\n { x: 0.59375, y: 0.53125 },\n { x: 0.59375, y: 0.53125 },\n { x: 0.65625, y: 0.53125 },\n { x: 0.65625, y: 0.53125 },\n { x: 0.71875, y: 0.53125 },\n { x: 0.71875, y: 0.53125 },\n { x: 0.78125, y: 0.53125 },\n { x: 0.78125, y: 0.53125 },\n { x: 0.84375, y: 0.53125 },\n { x: 0.84375, y: 0.53125 },\n { x: 0.90625, y: 0.53125 },\n { x: 0.90625, y: 0.53125 },\n { x: 0.96875, y: 0.53125 },\n { x: 0.96875, y: 0.53125 },\n { x: 0.03125, y: 0.59375 },\n { x: 0.03125, y: 0.59375 },\n { x: 0.09375, y: 0.59375 },\n { x: 0.09375, y: 0.59375 },\n { x: 0.15625, y: 0.59375 },\n { x: 0.15625, y: 0.59375 },\n { x: 0.21875, y: 0.59375 },\n { x: 0.21875, y: 0.59375 },\n { x: 0.28125, y: 0.59375 },\n { x: 0.28125, y: 0.59375 },\n { x: 0.34375, y: 0.59375 },\n { x: 0.34375, y: 0.59375 },\n { x: 0.40625, y: 0.59375 },\n { x: 0.40625, y: 0.59375 },\n { x: 0.46875, y: 0.59375 },\n { x: 0.46875, y: 0.59375 },\n { x: 0.53125, y: 0.59375 },\n { x: 0.53125, y: 0.59375 },\n { x: 0.59375, y: 0.59375 },\n { x: 0.59375, y: 0.59375 },\n { x: 0.65625, y: 0.59375 },\n { x: 0.65625, y: 0.59375 },\n { x: 0.71875, y: 0.59375 },\n { x: 0.71875, y: 0.59375 },\n { x: 0.78125, y: 0.59375 },\n { x: 0.78125, y: 0.59375 },\n { x: 0.84375, y: 0.59375 },\n { x: 0.84375, y: 0.59375 },\n { x: 0.90625, y: 0.59375 },\n { x: 0.90625, y: 0.59375 },\n { x: 0.96875, y: 0.59375 },\n { x: 0.96875, y: 0.59375 },\n { x: 0.03125, y: 0.65625 },\n { x: 0.03125, y: 0.65625 },\n { x: 0.09375, y: 0.65625 },\n { x: 0.09375, y: 0.65625 },\n { x: 0.15625, y: 0.65625 },\n { x: 0.15625, y: 0.65625 },\n { x: 0.21875, y: 0.65625 },\n { x: 0.21875, y: 0.65625 },\n { x: 0.28125, y: 0.65625 },\n { x: 0.28125, y: 0.65625 },\n { x: 0.34375, y: 0.65625 },\n { x: 0.34375, y: 0.65625 },\n { x: 0.40625, y: 0.65625 },\n { x: 0.40625, y: 0.65625 },\n { x: 0.46875, y: 0.65625 },\n { x: 0.46875, y: 0.65625 },\n { x: 0.53125, y: 0.65625 },\n { x: 0.53125, y: 0.65625 },\n { x: 0.59375, y: 0.65625 },\n { x: 0.59375, y: 0.65625 },\n { x: 0.65625, y: 0.65625 },\n { x: 0.65625, y: 0.65625 },\n { x: 0.71875, y: 0.65625 },\n { x: 0.71875, y: 0.65625 },\n { x: 0.78125, y: 0.65625 },\n { x: 0.78125, y: 0.65625 },\n { x: 0.84375, y: 0.65625 },\n { x: 0.84375, y: 0.65625 },\n { x: 0.90625, y: 0.65625 },\n { x: 0.90625, y: 0.65625 },\n { x: 0.96875, y: 0.65625 },\n { x: 0.96875, y: 0.65625 },\n { x: 0.03125, y: 0.71875 },\n { x: 0.03125, y: 0.71875 },\n { x: 0.09375, y: 0.71875 },\n { x: 0.09375, y: 0.71875 },\n { x: 0.15625, y: 0.71875 },\n { x: 0.15625, y: 0.71875 },\n { x: 0.21875, y: 0.71875 },\n { x: 0.21875, y: 0.71875 },\n { x: 0.28125, y: 0.71875 },\n { x: 0.28125, y: 0.71875 },\n { x: 0.34375, y: 0.71875 },\n { x: 0.34375, y: 0.71875 },\n { x: 0.40625, y: 0.71875 },\n { x: 0.40625, y: 0.71875 },\n { x: 0.46875, y: 0.71875 },\n { x: 0.46875, y: 0.71875 },\n { x: 0.53125, y: 0.71875 },\n { x: 0.53125, y: 0.71875 },\n { x: 0.59375, y: 0.71875 },\n { x: 0.59375, y: 0.71875 },\n { x: 0.65625, y: 0.71875 },\n { x: 0.65625, y: 0.71875 },\n { x: 0.71875, y: 0.71875 },\n { x: 0.71875, y: 0.71875 },\n { x: 0.78125, y: 0.71875 },\n { x: 0.78125, y: 0.71875 },\n { x: 0.84375, y: 0.71875 },\n { x: 0.84375, y: 0.71875 },\n { x: 0.90625, y: 0.71875 },\n { x: 0.90625, y: 0.71875 },\n { x: 0.96875, y: 0.71875 },\n { x: 0.96875, y: 0.71875 },\n { x: 0.03125, y: 0.78125 },\n { x: 0.03125, y: 0.78125 },\n { x: 0.09375, y: 0.78125 },\n { x: 0.09375, y: 0.78125 },\n { x: 0.15625, y: 0.78125 },\n { x: 0.15625, y: 0.78125 },\n { x: 0.21875, y: 0.78125 },\n { x: 0.21875, y: 0.78125 },\n { x: 0.28125, y: 0.78125 },\n { x: 0.28125, y: 0.78125 },\n { x: 0.34375, y: 0.78125 },\n { x: 0.34375, y: 0.78125 },\n { x: 0.40625, y: 0.78125 },\n { x: 0.40625, y: 0.78125 },\n { x: 0.46875, y: 0.78125 },\n { x: 0.46875, y: 0.78125 },\n { x: 0.53125, y: 0.78125 },\n { x: 0.53125, y: 0.78125 },\n { x: 0.59375, y: 0.78125 },\n { x: 0.59375, y: 0.78125 },\n { x: 0.65625, y: 0.78125 },\n { x: 0.65625, y: 0.78125 },\n { x: 0.71875, y: 0.78125 },\n { x: 0.71875, y: 0.78125 },\n { x: 0.78125, y: 0.78125 },\n { x: 0.78125, y: 0.78125 },\n { x: 0.84375, y: 0.78125 },\n { x: 0.84375, y: 0.78125 },\n { x: 0.90625, y: 0.78125 },\n { x: 0.90625, y: 0.78125 },\n { x: 0.96875, y: 0.78125 },\n { x: 0.96875, y: 0.78125 },\n { x: 0.03125, y: 0.84375 },\n { x: 0.03125, y: 0.84375 },\n { x: 0.09375, y: 0.84375 },\n { x: 0.09375, y: 0.84375 },\n { x: 0.15625, y: 0.84375 },\n { x: 0.15625, y: 0.84375 },\n { x: 0.21875, y: 0.84375 },\n { x: 0.21875, y: 0.84375 },\n { x: 0.28125, y: 0.84375 },\n { x: 0.28125, y: 0.84375 },\n { x: 0.34375, y: 0.84375 },\n { x: 0.34375, y: 0.84375 },\n { x: 0.40625, y: 0.84375 },\n { x: 0.40625, y: 0.84375 },\n { x: 0.46875, y: 0.84375 },\n { x: 0.46875, y: 0.84375 },\n { x: 0.53125, y: 0.84375 },\n { x: 0.53125, y: 0.84375 },\n { x: 0.59375, y: 0.84375 },\n { x: 0.59375, y: 0.84375 },\n { x: 0.65625, y: 0.84375 },\n { x: 0.65625, y: 0.84375 },\n { x: 0.71875, y: 0.84375 },\n { x: 0.71875, y: 0.84375 },\n { x: 0.78125, y: 0.84375 },\n { x: 0.78125, y: 0.84375 },\n { x: 0.84375, y: 0.84375 },\n { x: 0.84375, y: 0.84375 },\n { x: 0.90625, y: 0.84375 },\n { x: 0.90625, y: 0.84375 },\n { x: 0.96875, y: 0.84375 },\n { x: 0.96875, y: 0.84375 },\n { x: 0.03125, y: 0.90625 },\n { x: 0.03125, y: 0.90625 },\n { x: 0.09375, y: 0.90625 },\n { x: 0.09375, y: 0.90625 },\n { x: 0.15625, y: 0.90625 },\n { x: 0.15625, y: 0.90625 },\n { x: 0.21875, y: 0.90625 },\n { x: 0.21875, y: 0.90625 },\n { x: 0.28125, y: 0.90625 },\n { x: 0.28125, y: 0.90625 },\n { x: 0.34375, y: 0.90625 },\n { x: 0.34375, y: 0.90625 },\n { x: 0.40625, y: 0.90625 },\n { x: 0.40625, y: 0.90625 },\n { x: 0.46875, y: 0.90625 },\n { x: 0.46875, y: 0.90625 },\n { x: 0.53125, y: 0.90625 },\n { x: 0.53125, y: 0.90625 },\n { x: 0.59375, y: 0.90625 },\n { x: 0.59375, y: 0.90625 },\n { x: 0.65625, y: 0.90625 },\n { x: 0.65625, y: 0.90625 },\n { x: 0.71875, y: 0.90625 },\n { x: 0.71875, y: 0.90625 },\n { x: 0.78125, y: 0.90625 },\n { x: 0.78125, y: 0.90625 },\n { x: 0.84375, y: 0.90625 },\n { x: 0.84375, y: 0.90625 },\n { x: 0.90625, y: 0.90625 },\n { x: 0.90625, y: 0.90625 },\n { x: 0.96875, y: 0.90625 },\n { x: 0.96875, y: 0.90625 },\n { x: 0.03125, y: 0.96875 },\n { x: 0.03125, y: 0.96875 },\n { x: 0.09375, y: 0.96875 },\n { x: 0.09375, y: 0.96875 },\n { x: 0.15625, y: 0.96875 },\n { x: 0.15625, y: 0.96875 },\n { x: 0.21875, y: 0.96875 },\n { x: 0.21875, y: 0.96875 },\n { x: 0.28125, y: 0.96875 },\n { x: 0.28125, y: 0.96875 },\n { x: 0.34375, y: 0.96875 },\n { x: 0.34375, y: 0.96875 },\n { x: 0.40625, y: 0.96875 },\n { x: 0.40625, y: 0.96875 },\n { x: 0.46875, y: 0.96875 },\n { x: 0.46875, y: 0.96875 },\n { x: 0.53125, y: 0.96875 },\n { x: 0.53125, y: 0.96875 },\n { x: 0.59375, y: 0.96875 },\n { x: 0.59375, y: 0.96875 },\n { x: 0.65625, y: 0.96875 },\n { x: 0.65625, y: 0.96875 },\n { x: 0.71875, y: 0.96875 },\n { x: 0.71875, y: 0.96875 },\n { x: 0.78125, y: 0.96875 },\n { x: 0.78125, y: 0.96875 },\n { x: 0.84375, y: 0.96875 },\n { x: 0.84375, y: 0.96875 },\n { x: 0.90625, y: 0.96875 },\n { x: 0.90625, y: 0.96875 },\n { x: 0.96875, y: 0.96875 },\n { x: 0.96875, y: 0.96875 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n];\n", "/**\n * HandPose model implementation\n * See `handpose.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as util from './handposeutil';\nimport * as anchors from './handposeanchors';\nimport { constants } from '../tfjs/constants';\nimport type { Tensor, Tensor1D, Tensor2D, Tensor4D, GraphModel } from '../tfjs/types';\nimport type { Point } from '../result';\nimport type { Config } from '../config';\n\nexport class HandDetector {\n model: GraphModel;\n anchors: number[][];\n anchorsTensor: Tensor;\n inputSize: number;\n inputSizeTensor: Tensor;\n doubleInputSizeTensor: Tensor;\n\n constructor(model: GraphModel) {\n this.model = model;\n this.anchors = anchors.anchors.map((anchor) => [anchor.x, anchor.y]);\n this.anchorsTensor = tf.tensor2d(this.anchors);\n this.inputSize = this?.model?.inputs?.[0]?.shape?.[2] || 0;\n this.inputSizeTensor = tf.tensor1d([this.inputSize, this.inputSize]);\n this.doubleInputSizeTensor = tf.tensor1d([this.inputSize * 2, this.inputSize * 2]);\n }\n\n normalizeBoxes(boxes) {\n const t: Record = {};\n t.boxOffsets = tf.slice(boxes, [0, 0], [-1, 2]);\n t.boxSizes = tf.slice(boxes, [0, 2], [-1, 2]);\n t.div = tf.div(t.boxOffsets, this.inputSizeTensor);\n t.boxCenterPoints = tf.add(t.div, this.anchorsTensor);\n t.halfBoxSizes = tf.div(t.boxSizes, this.doubleInputSizeTensor);\n t.sub = tf.sub(t.boxCenterPoints, t.halfBoxSizes);\n t.startPoints = tf.mul(t.sub, this.inputSizeTensor);\n t.add = tf.add(t.boxCenterPoints, t.halfBoxSizes);\n t.endPoints = tf.mul(t.add, this.inputSizeTensor);\n const res = tf.concat2d([t.startPoints as Tensor2D, t.endPoints as Tensor2D], 1);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return res as Tensor;\n }\n\n normalizeLandmarks(rawPalmLandmarks, index: number): Tensor {\n const t: Record = {};\n t.reshape = tf.reshape(rawPalmLandmarks, [-1, 7, 2]);\n t.div = tf.div(t.reshape, this.inputSizeTensor);\n t.landmarks = tf.add(t.div, this.anchors[index] ? this.anchors[index] : 0);\n const res = tf.mul(t.landmarks, this.inputSizeTensor);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return res;\n }\n\n async predict(input: Tensor4D, config: Config): Promise<{ startPoint: Point; endPoint: Point, palmLandmarks: Point[]; confidence: number }[]> {\n const t: Record = {};\n t.resize = tf.image.resizeBilinear(input, [this.inputSize, this.inputSize]);\n t.div = tf.div(t.resize, constants.tf127);\n t.image = tf.sub(t.div, constants.tf1);\n t.batched = this.model.execute(t.image) as Tensor;\n t.predictions = tf.squeeze(t.batched);\n t.slice = tf.slice(t.predictions, [0, 0], [-1, 1]);\n t.sigmoid = tf.sigmoid(t.slice);\n t.scores = tf.squeeze(t.sigmoid);\n const scores = await t.scores.data();\n t.boxes = tf.slice(t.predictions, [0, 1], [-1, 4]);\n t.norm = this.normalizeBoxes(t.boxes);\n // box detection is flaky so we look for 3x boxes than we need results\n t.nms = await tf.image.nonMaxSuppressionAsync(t.norm as Tensor2D, t.scores as Tensor1D, 3 * (config.hand?.maxDetected || 1), config.hand.iouThreshold, config.hand.minConfidence);\n const nms = await t.nms.array() as number[];\n const hands: { startPoint: Point; endPoint: Point; palmLandmarks: Point[]; confidence: number }[] = [];\n for (const index of nms) {\n const p: Record = {};\n p.box = tf.slice(t.norm, [index, 0], [1, -1]);\n p.slice = tf.slice(t.predictions, [index, 5], [1, 14]);\n p.norm = this.normalizeLandmarks(p.slice, index);\n p.palmLandmarks = tf.reshape(p.norm, [-1, 2]);\n const box = await p.box.data();\n const startPoint = box.slice(0, 2) as unknown as Point;\n const endPoint = box.slice(2, 4) as unknown as Point;\n const palmLandmarks = await p.palmLandmarks.array();\n const hand = { startPoint, endPoint, palmLandmarks, confidence: scores[index] };\n const scaled = util.scaleBoxCoordinates(hand, [(input.shape[2] || 1) / this.inputSize, (input.shape[1] || 0) / this.inputSize]);\n hands.push(scaled);\n Object.keys(p).forEach((tensor) => tf.dispose(p[tensor]));\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return hands;\n }\n}\n", "/**\n * HandPose model implementation\n * See `handpose.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as util from './handposeutil';\nimport type * as detector from './handposedetector';\nimport { constants } from '../tfjs/constants';\nimport type { Tensor, GraphModel } from '../tfjs/types';\nimport { env } from '../util/env';\nimport { now } from '../util/util';\nimport type { Point } from '../result';\n\nconst palmBoxEnlargeFactor = 5; // default 3\nconst handBoxEnlargeFactor = 1.65; // default 1.65\nconst palmLandmarkIds = [0, 5, 9, 13, 17, 1, 2];\nconst palmLandmarksPalmBase = 0;\nconst palmLandmarksMiddleFingerBase = 2;\nlet lastTime = 0;\n\nexport class HandPipeline {\n handDetector: detector.HandDetector;\n handPoseModel: GraphModel;\n inputSize: number;\n storedBoxes: ({ startPoint: Point; endPoint: Point; palmLandmarks: Point[]; confidence: number } | null)[];\n skipped: number;\n detectedHands: number;\n\n constructor(handDetector, handPoseModel) {\n this.handDetector = handDetector;\n this.handPoseModel = handPoseModel;\n this.inputSize = this.handPoseModel?.inputs?.[0].shape?.[2] || 0;\n this.storedBoxes = [];\n this.skipped = Number.MAX_SAFE_INTEGER;\n this.detectedHands = 0;\n }\n\n calculateLandmarksBoundingBox(landmarks) { // eslint-disable-line class-methods-use-this\n const xs = landmarks.map((d) => d[0]);\n const ys = landmarks.map((d) => d[1]);\n const startPoint = [Math.min(...xs), Math.min(...ys)];\n const endPoint = [Math.max(...xs), Math.max(...ys)];\n return { startPoint, endPoint };\n }\n\n getBoxForPalmLandmarks(palmLandmarks, rotationMatrix) {\n const rotatedPalmLandmarks = palmLandmarks.map((coord) => util.rotatePoint([...coord, 1], rotationMatrix));\n const boxAroundPalm = this.calculateLandmarksBoundingBox(rotatedPalmLandmarks);\n return util.enlargeBox(util.squarifyBox(boxAroundPalm), palmBoxEnlargeFactor);\n }\n\n getBoxForHandLandmarks(landmarks) {\n const boundingBox = this.calculateLandmarksBoundingBox(landmarks);\n const boxAroundHand = util.enlargeBox(util.squarifyBox(boundingBox), handBoxEnlargeFactor);\n boxAroundHand.palmLandmarks = [];\n for (let i = 0; i < palmLandmarkIds.length; i++) {\n boxAroundHand.palmLandmarks.push(landmarks[palmLandmarkIds[i]].slice(0, 2));\n }\n return boxAroundHand;\n }\n\n transformRawCoords(rawCoords, box2, angle, rotationMatrix) {\n const boxSize = util.getBoxSize(box2);\n const scaleFactor = [boxSize[0] / this.inputSize, boxSize[1] / this.inputSize, (boxSize[0] + boxSize[1]) / this.inputSize / 2];\n const coordsScaled = rawCoords.map((coord) => [\n scaleFactor[0] * (coord[0] - this.inputSize / 2),\n scaleFactor[1] * (coord[1] - this.inputSize / 2),\n scaleFactor[2] * coord[2],\n ]);\n const coordsRotationMatrix = util.buildRotationMatrix(angle, [0, 0]);\n const coordsRotated = coordsScaled.map((coord) => {\n const rotated = util.rotatePoint(coord, coordsRotationMatrix);\n return [...rotated, coord[2]];\n });\n const inverseRotationMatrix = util.invertTransformMatrix(rotationMatrix);\n const boxCenter = [...util.getBoxCenter(box2), 1];\n const originalBoxCenter = [\n util.dot(boxCenter, inverseRotationMatrix[0]),\n util.dot(boxCenter, inverseRotationMatrix[1]),\n ];\n return coordsRotated.map((coord) => [\n Math.trunc(coord[0] + originalBoxCenter[0]),\n Math.trunc(coord[1] + originalBoxCenter[1]),\n Math.trunc(coord[2]),\n ]);\n }\n\n async estimateHands(image, config) {\n let useFreshBox = false;\n\n // run new detector every skipFrames\n let boxes;\n const skipTime = (config.hand.skipTime || 0) > (now() - lastTime);\n const skipFrame = this.skipped < (config.hand.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame) {\n this.skipped++;\n } else {\n boxes = await this.handDetector.predict(image, config);\n this.skipped = 0;\n }\n\n // if detector result count doesn't match current working set, use it to reset current working set\n if (boxes && (boxes.length > 0) && ((boxes.length !== this.detectedHands) && (this.detectedHands !== config.hand.maxDetected) || !config.hand.landmarks)) {\n this.detectedHands = 0;\n this.storedBoxes = [...boxes];\n // for (const possible of boxes) this.storedBoxes.push(possible);\n if (this.storedBoxes.length > 0) useFreshBox = true;\n }\n const hands: { landmarks: Point[], confidence: number, boxConfidence: number, fingerConfidence: number, box: { topLeft: Point, bottomRight: Point } }[] = [];\n\n // go through working set of boxes\n for (let i = 0; i < this.storedBoxes.length; i++) {\n const currentBox = this.storedBoxes[i];\n if (!currentBox) continue;\n if (config.hand.landmarks) {\n const angle = config.hand.rotation ? util.computeRotation(currentBox.palmLandmarks[palmLandmarksPalmBase], currentBox.palmLandmarks[palmLandmarksMiddleFingerBase]) : 0;\n const palmCenter = util.getBoxCenter(currentBox);\n const palmCenterNormalized: [number, number] = [palmCenter[0] / image.shape[2], palmCenter[1] / image.shape[1]];\n const rotatedImage = config.hand.rotation && env.kernels.includes('rotatewithoffset') ? tf.image.rotateWithOffset(image, angle, 0, palmCenterNormalized) : image.clone();\n const rotationMatrix = util.buildRotationMatrix(-angle, palmCenter);\n const newBox = useFreshBox ? this.getBoxForPalmLandmarks(currentBox.palmLandmarks, rotationMatrix) : currentBox;\n const croppedInput = util.cutBoxFromImageAndResize(newBox, rotatedImage, [this.inputSize, this.inputSize]);\n const handImage = tf.div(croppedInput, constants.tf255);\n tf.dispose(croppedInput);\n tf.dispose(rotatedImage);\n const [confidenceT, keypoints] = this.handPoseModel.execute(handImage) as Tensor[];\n lastTime = now();\n tf.dispose(handImage);\n const confidence = (await confidenceT.data())[0];\n tf.dispose(confidenceT);\n if (confidence >= config.hand.minConfidence / 4) {\n const keypointsReshaped = tf.reshape(keypoints, [-1, 3]);\n const rawCoords = await keypointsReshaped.array();\n tf.dispose(keypoints);\n tf.dispose(keypointsReshaped);\n const coords = this.transformRawCoords(rawCoords, newBox, angle, rotationMatrix);\n const nextBoundingBox = this.getBoxForHandLandmarks(coords);\n this.storedBoxes[i] = { ...nextBoundingBox, confidence };\n const result = {\n landmarks: coords,\n confidence,\n boxConfidence: currentBox.confidence,\n fingerConfidence: confidence,\n box: { topLeft: nextBoundingBox.startPoint, bottomRight: nextBoundingBox.endPoint },\n };\n hands.push(result);\n } else {\n this.storedBoxes[i] = null;\n }\n tf.dispose(keypoints);\n } else {\n // const enlarged = box.enlargeBox(box.squarifyBox(box.shiftBox(currentBox, HAND_BOX_SHIFT_VECTOR)), handBoxEnlargeFactor);\n const enlarged = util.enlargeBox(util.squarifyBox(currentBox), handBoxEnlargeFactor);\n const result = {\n confidence: currentBox.confidence,\n boxConfidence: currentBox.confidence,\n fingerConfidence: 0,\n box: { topLeft: enlarged.startPoint, bottomRight: enlarged.endPoint },\n landmarks: [],\n };\n hands.push(result);\n }\n }\n this.storedBoxes = this.storedBoxes.filter((a) => a !== null);\n this.detectedHands = hands.length;\n if (hands.length > config.hand.maxDetected) hands.length = config.hand.maxDetected;\n return hands;\n }\n}\n", "/**\n * HandPose model implementation\n *\n * Based on: [**MediaPipe HandPose**](https://drive.google.com/file/d/1sv4sSb9BSNVZhLzxXJ0jBv9DqD-4jnAz/view)\n */\n\nimport { log } from '../util/util';\nimport * as handdetector from './handposedetector';\nimport * as handpipeline from './handposepipeline';\nimport * as fingerPose from './fingerpose';\nimport { loadModel } from '../tfjs/load';\nimport type { HandResult, Box, Point } from '../result';\nimport type { Tensor, GraphModel } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nconst meshAnnotations = {\n thumb: [1, 2, 3, 4],\n index: [5, 6, 7, 8],\n middle: [9, 10, 11, 12],\n ring: [13, 14, 15, 16],\n pinky: [17, 18, 19, 20],\n palm: [0],\n};\n\nlet handDetectorModel: GraphModel | null;\nlet handPoseModel: GraphModel | null;\nlet handPipeline: handpipeline.HandPipeline;\n\nexport function initPipeline() {\n const handDetector = handDetectorModel ? new handdetector.HandDetector(handDetectorModel) : undefined;\n if (handDetector && handPoseModel) handPipeline = new handpipeline.HandPipeline(handDetector, handPoseModel);\n}\n\nexport async function predict(input: Tensor, config: Config): Promise {\n if (!handPipeline) initPipeline();\n const predictions = await handPipeline.estimateHands(input, config);\n if (!predictions) return [];\n const hands: HandResult[] = [];\n for (let i = 0; i < predictions.length; i++) {\n const annotations = {};\n if (predictions[i].landmarks) {\n for (const key of Object.keys(meshAnnotations)) {\n annotations[key] = meshAnnotations[key].map((index) => predictions[i].landmarks[index]);\n }\n }\n const keypoints = predictions[i].landmarks as unknown as Point[];\n let box: Box = [Number.MAX_SAFE_INTEGER, Number.MAX_SAFE_INTEGER, 0, 0]; // maximums so conditionals work\n let boxRaw: Box = [0, 0, 0, 0];\n if (keypoints && keypoints.length > 0) { // if we have landmarks, calculate box based on landmarks\n for (const pt of keypoints) {\n if (pt[0] < box[0]) box[0] = pt[0];\n if (pt[1] < box[1]) box[1] = pt[1];\n if (pt[0] > box[2]) box[2] = pt[0];\n if (pt[1] > box[3]) box[3] = pt[1];\n }\n box[2] -= box[0];\n box[3] -= box[1];\n boxRaw = [box[0] / (input.shape[2] || 0), box[1] / (input.shape[1] || 0), box[2] / (input.shape[2] || 0), box[3] / (input.shape[1] || 0)];\n } else { // otherwise use box from prediction\n box = predictions[i].box ? [\n Math.trunc(Math.max(0, predictions[i].box.topLeft[0])),\n Math.trunc(Math.max(0, predictions[i].box.topLeft[1])),\n Math.trunc(Math.min((input.shape[2] || 0), predictions[i].box.bottomRight[0]) - Math.max(0, predictions[i].box.topLeft[0])),\n Math.trunc(Math.min((input.shape[1] || 0), predictions[i].box.bottomRight[1]) - Math.max(0, predictions[i].box.topLeft[1])),\n ] : [0, 0, 0, 0];\n boxRaw = [\n (predictions[i].box.topLeft[0]) / (input.shape[2] || 0),\n (predictions[i].box.topLeft[1]) / (input.shape[1] || 0),\n (predictions[i].box.bottomRight[0] - predictions[i].box.topLeft[0]) / (input.shape[2] || 0),\n (predictions[i].box.bottomRight[1] - predictions[i].box.topLeft[1]) / (input.shape[1] || 0),\n ];\n }\n const landmarks = fingerPose.analyze(keypoints);\n hands.push({\n id: i,\n score: Math.round(100 * predictions[i].confidence) / 100,\n boxScore: Math.round(100 * predictions[i].boxConfidence) / 100,\n fingerScore: Math.round(100 * predictions[i].fingerConfidence) / 100,\n label: 'hand',\n box,\n boxRaw,\n keypoints,\n annotations: annotations as HandResult['annotations'],\n landmarks: landmarks as HandResult['landmarks'],\n });\n }\n return hands;\n}\n\nexport async function loadDetect(config: Config): Promise {\n if (env.initial) handDetectorModel = null;\n if (!handDetectorModel) handDetectorModel = await loadModel(config.hand.detector?.modelPath);\n else if (config.debug) log('cached model:', handDetectorModel['modelUrl']);\n return handDetectorModel;\n}\n\nexport async function loadSkeleton(config: Config): Promise {\n if (env.initial) handPoseModel = null;\n if (!handPoseModel) handPoseModel = await loadModel(config.hand.skeleton?.modelPath);\n else if (config.debug) log('cached model:', handPoseModel['modelUrl']);\n return handPoseModel;\n}\n", "/**\n * HandTrack model implementation\n *\n * Based on:\n * - Hand Detection & Skeleton: [**MediaPipe HandPose**](https://drive.google.com/file/d/1sv4sSb9BSNVZhLzxXJ0jBv9DqD-4jnAz/view)\n * - Hand Tracking: [**HandTracking**](https://github.com/victordibia/handtracking)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport * as box from '../util/box';\nimport { loadModel } from '../tfjs/load';\nimport type { HandResult, HandType, Box, Point } from '../result';\nimport type { GraphModel, Tensor, Tensor1D, Tensor2D, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\nimport * as fingerPose from './fingerpose';\nimport { fakeOps } from '../tfjs/backend';\nimport { constants } from '../tfjs/constants';\n\nconst models: [GraphModel | null, GraphModel | null] = [null, null];\nconst modelOutputNodes = ['StatefulPartitionedCall/Postprocessor/Slice', 'StatefulPartitionedCall/Postprocessor/ExpandDims_1'];\n\nconst inputSize = [[0, 0], [0, 0]];\n\nconst classes = ['hand', 'fist', 'pinch', 'point', 'face', 'tip', 'pinchtip'];\nconst faceIndex = 4;\n\nconst boxExpandFact = 1.6;\nconst maxDetectorResolution = 512;\nconst detectorExpandFact = 1.4;\n\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet lastTime = 0;\nlet outputSize: [number, number] = [0, 0];\n\ninterface HandDetectResult {\n id: number,\n score: number,\n box: Box,\n boxRaw: Box,\n label: HandType,\n}\n\nconst cache: {\n boxes: HandDetectResult[],\n hands: HandResult[];\n} = {\n boxes: [],\n hands: [],\n};\n\nconst fingerMap = {\n /*\n thumb: [0, 1, 2, 3, 4],\n index: [0, 5, 6, 7, 8],\n middle: [0, 9, 10, 11, 12],\n ring: [0, 13, 14, 15, 16],\n pinky: [0, 17, 18, 19, 20],\n palm: [0],\n */\n thumb: [1, 2, 3, 4],\n index: [5, 6, 7, 8],\n middle: [9, 10, 11, 12],\n ring: [13, 14, 15, 16],\n pinky: [17, 18, 19, 20],\n base: [0],\n palm: [0, 17, 13, 9, 5, 1, 0],\n};\n\nexport async function loadDetect(config: Config): Promise {\n // HandTrack Model: Original: TFJS Port: \n if (env.initial) models[0] = null;\n if (!models[0]) {\n // handtrack model has some kernel ops defined in model but those are never referenced and non-existent in tfjs\n // ideally need to prune the model itself\n fakeOps(['tensorlistreserve', 'enter', 'tensorlistfromtensor', 'merge', 'loopcond', 'switch', 'exit', 'tensorliststack', 'nextiteration', 'tensorlistsetitem', 'tensorlistgetitem', 'reciprocal', 'shape', 'split', 'where'], config);\n models[0] = await loadModel(config.hand.detector?.modelPath);\n const inputs = models[0]['executor'] ? Object.values(models[0].modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[0][0] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[0][1] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 0;\n } else if (config.debug) log('cached model:', models[0]['modelUrl']);\n return models[0];\n}\n\nexport async function loadSkeleton(config: Config): Promise {\n if (env.initial) models[1] = null;\n if (!models[1]) {\n models[1] = await loadModel(config.hand.skeleton?.modelPath);\n const inputs = models[1]['executor'] ? Object.values(models[1].modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[1][0] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[1][1] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 0;\n } else if (config.debug) log('cached model:', models[1]['modelUrl']);\n return models[1];\n}\n\nexport async function load(config: Config): Promise<[GraphModel | null, GraphModel | null]> {\n if (!models[0]) await loadDetect(config);\n if (!models[1]) await loadSkeleton(config);\n return models;\n}\n\nasync function detectHands(input: Tensor4D, config: Config): Promise {\n const hands: HandDetectResult[] = [];\n if (!input || !models[0]) return hands;\n const t: Record = {};\n const ratio = (input.shape[2] || 1) / (input.shape[1] || 1);\n const height = Math.min(Math.round((input.shape[1] || 0) / 8) * 8, maxDetectorResolution); // use dynamic input size but cap at 512\n const width = Math.round(height * ratio / 8) * 8;\n t.resize = tf.image.resizeBilinear(input, [height, width]); // todo: resize with padding\n t.cast = tf.cast(t.resize, 'int32');\n [t.rawScores, t.rawBoxes] = await models[0].executeAsync(t.cast, modelOutputNodes) as Tensor[];\n t.boxes = tf.squeeze(t.rawBoxes, [0, 2]);\n t.scores = tf.squeeze(t.rawScores, [0]);\n const classScores: Tensor[] = tf.unstack(t.scores, 1); // unstack scores based on classes\n tf.dispose(classScores[faceIndex]);\n classScores.splice(faceIndex, 1); // remove faces\n t.filtered = tf.stack(classScores, 1); // restack\n tf.dispose(classScores);\n // t.filtered = t.scores;\n t.max = tf.max(t.filtered, 1); // max overall score\n t.argmax = tf.argMax(t.filtered, 1); // class index of max overall score\n let id = 0;\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.max as Tensor1D, (config.hand.maxDetected || 0) + 1, config.hand.iouThreshold || 0, config.hand.minConfidence || 1);\n const nms = await t.nms.data();\n const scores = await t.max.data();\n const classNum = await t.argmax.data();\n for (const nmsIndex of Array.from(nms)) { // generates results for each class\n const boxSlice = tf.slice(t.boxes, nmsIndex, 1);\n const boxYX = await boxSlice.data();\n tf.dispose(boxSlice);\n const boxData: Box = [boxYX[1], boxYX[0], boxYX[3] - boxYX[1], boxYX[2] - boxYX[0]]; // yx box reshaped to standard box\n const boxRaw: Box = box.scale(boxData, detectorExpandFact);\n const boxFull: Box = [Math.trunc(boxData[0] * outputSize[0]), Math.trunc(boxData[1] * outputSize[1]), Math.trunc(boxData[2] * outputSize[0]), Math.trunc(boxData[3] * outputSize[1])];\n const score = scores[nmsIndex];\n const label = classes[classNum[nmsIndex]] as HandType;\n const hand: HandDetectResult = { id: id++, score, box: boxFull, boxRaw, label };\n hands.push(hand);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n hands.sort((a, b) => b.score - a.score);\n if (hands.length > (config.hand.maxDetected || 1)) hands.length = (config.hand.maxDetected || 1);\n return hands;\n}\n\nasync function detectFingers(input: Tensor4D, h: HandDetectResult, config: Config): Promise {\n const hand: HandResult = { // initial values inherited from hand detect\n id: h.id,\n score: Math.round(100 * h.score) / 100,\n boxScore: Math.round(100 * h.score) / 100,\n fingerScore: 0,\n box: h.box,\n boxRaw: h.boxRaw,\n label: h.label,\n keypoints: [],\n landmarks: {} as HandResult['landmarks'],\n annotations: {} as HandResult['annotations'],\n };\n if (input && models[1] && config.hand.landmarks && h.score > (config.hand.minConfidence || 0)) {\n const t: Record = {};\n const boxCrop = [h.boxRaw[1], h.boxRaw[0], h.boxRaw[3] + h.boxRaw[1], h.boxRaw[2] + h.boxRaw[0]] as Box;\n t.crop = tf.image.cropAndResize(input, [boxCrop], [0], [inputSize[1][0], inputSize[1][1]], 'bilinear');\n t.div = tf.div(t.crop, constants.tf255);\n [t.score, t.keypoints] = models[1].execute(t.div, ['Identity_1', 'Identity']) as Tensor[];\n const rawScore = (await t.score.data())[0];\n const score = (100 - Math.trunc(100 / (1 + Math.exp(rawScore)))) / 100; // reverse sigmoid value\n if (score >= (config.hand.minConfidence || 0)) {\n hand.fingerScore = score;\n t.reshaped = tf.reshape(t.keypoints, [-1, 3]);\n const coordsData: Point[] = await t.reshaped.array() as Point[];\n const coordsRaw: Point[] = coordsData.map((kpt) => [kpt[0] / inputSize[1][1], kpt[1] / inputSize[1][0], (kpt[2] || 0)]);\n const coordsNorm: Point[] = coordsRaw.map((kpt) => [kpt[0] * h.boxRaw[2], kpt[1] * h.boxRaw[3], (kpt[2] || 0)]);\n hand.keypoints = (coordsNorm).map((kpt) => [outputSize[0] * (kpt[0] + h.boxRaw[0]), outputSize[1] * (kpt[1] + h.boxRaw[1]), (kpt[2] || 0)]);\n hand.landmarks = fingerPose.analyze(hand.keypoints) as HandResult['landmarks']; // calculate finger gestures\n for (const key of Object.keys(fingerMap)) { // map keypoints to per-finger annotations\n hand.annotations[key] = fingerMap[key].map((index: number) => (hand.landmarks && hand.keypoints[index] ? hand.keypoints[index] : null));\n }\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n return hand;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!models[0]?.['executor'] || !models[1]?.['executor'] || !models[0].inputs[0].shape || !models[1].inputs[0].shape) return []; // something is wrong with the model\n outputSize = [input.shape[2] || 0, input.shape[1] || 0];\n skipped++; // increment skip frames\n const skipTime = (config.hand.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.hand.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame) {\n return cache.hands; // return cached results without running anything\n }\n return new Promise(async (resolve) => {\n const skipTimeExtended = 3 * (config.hand.skipTime || 0) > (now() - lastTime);\n const skipFrameExtended = skipped < 3 * (config.hand.skipFrames || 0);\n if (config.skipAllowed && cache.hands.length === config.hand.maxDetected) { // we have all detected hands so we're definitely skipping\n cache.hands = await Promise.all(cache.boxes.map((handBox) => detectFingers(input, handBox, config)));\n } else if (config.skipAllowed && skipTimeExtended && skipFrameExtended && cache.hands.length > 0) { // we have some cached results: maybe not enough but anyhow continue for bit longer\n cache.hands = await Promise.all(cache.boxes.map((handBox) => detectFingers(input, handBox, config)));\n } else { // finally rerun detector\n cache.boxes = await detectHands(input, config);\n lastTime = now();\n cache.hands = await Promise.all(cache.boxes.map((handBox) => detectFingers(input, handBox, config)));\n skipped = 0;\n }\n\n const oldCache = [...cache.boxes];\n cache.boxes.length = 0; // reset cache\n if (config.cacheSensitivity > 0) {\n for (let i = 0; i < cache.hands.length; i++) {\n const boxKpt = box.square(cache.hands[i].keypoints, outputSize);\n if (boxKpt.box[2] / (input.shape[2] || 1) > 0.05 && boxKpt.box[3] / (input.shape[1] || 1) > 0.05 && cache.hands[i].fingerScore && cache.hands[i].fingerScore > (config.hand.minConfidence || 0)) {\n const boxScale = box.scale(boxKpt.box, boxExpandFact);\n const boxScaleRaw = box.scale(boxKpt.boxRaw, boxExpandFact);\n // const boxCrop = box.crop(boxScaleRaw);\n cache.boxes.push({ ...oldCache[i], box: boxScale, boxRaw: boxScaleRaw });\n }\n }\n }\n for (let i = 0; i < cache.hands.length; i++) { // replace detected boxes with calculated boxes in final output\n const bbox = box.calc(cache.hands[i].keypoints, outputSize);\n cache.hands[i].box = bbox.box;\n cache.hands[i].boxRaw = bbox.boxRaw;\n }\n resolve(cache.hands);\n });\n}\n", "/**\n * Type definitions for Human result object\n */\n\nimport type { Tensor } from './tfjs/types';\nimport type { FaceGesture, BodyGesture, HandGesture, IrisGesture } from './gesture/gesture';\nimport type { AnyCanvas } from './exports';\n\n/** generic box as [x, y, width, height] */\nexport type Box = [number, number, number, number];\n/** generic point as [x, y, z?] */\nexport type Point = [number, number, number?];\n\nexport type Emotion = 'angry' | 'disgust' | 'fear' | 'happy' | 'sad' | 'surprise' | 'neutral';\nexport type Gender = 'male' | 'female' | 'unknown';\nexport type Race = 'white' | 'black' | 'asian' | 'indian' | 'other';\nexport type FaceLandmark = 'leftEye' | 'rightEye' | 'nose' | 'mouth' | 'leftEar' | 'rightEar' | 'symmetryLine' | 'silhouette'\n | 'lipsUpperOuter' | 'lipsLowerOuter' | 'lipsUpperInner' | 'lipsLowerInner'\n | 'rightEyeUpper0' | 'rightEyeLower0' | 'rightEyeUpper1' | 'rightEyeLower1' | 'rightEyeUpper2' | 'rightEyeLower2' | 'rightEyeLower3' | 'rightEyebrowUpper' | 'rightEyebrowLower' | 'rightEyeIris'\n | 'leftEyeUpper0' | 'leftEyeLower0' | 'leftEyeUpper1' | 'leftEyeLower1' | 'leftEyeUpper2' | 'leftEyeLower2' | 'leftEyeLower3' | 'leftEyebrowUpper' | 'leftEyebrowLower' | 'leftEyeIris'\n | 'midwayBetweenEyes' | 'noseTip' | 'noseBottom' | 'noseRightCorner' | 'noseLeftCorner' | 'rightCheek' | 'leftCheek';\n\n/** Face results\n * - Combined results of face detector, face mesh, age, gender, emotion, embedding, iris models\n * - Some values may be null if specific model is not enabled\n */\nexport interface FaceResult {\n /** face id */\n id: number\n /** overall face score */\n score: number,\n /** detection score */\n boxScore: number,\n /** mesh score */\n faceScore: number,\n /** detected face box */\n box: Box,\n /** detected face box normalized to 0..1 */\n boxRaw: Box,\n /** detected face box size */\n size: [number, number],\n /** detected face mesh */\n mesh: Point[]\n /** detected face mesh normalized to 0..1 */\n meshRaw: Point[],\n /** face contours as array of 2d points normalized to 0..1 */\n // contoursRaw: Array<[number, number]>,\n /** face contours as array of 2d points */\n // contours: Array<[number, number]>,\n /** mesh keypoints combined into annotated results */\n annotations: Record,\n /** detected age */\n age?: number,\n /** detected gender */\n gender?: Gender,\n /** gender detection score */\n genderScore?: number,\n /** detected emotions */\n emotion?: { score: number, emotion: Emotion }[],\n /** detected race */\n race?: { score: number, race: Race }[],\n /** face descriptor */\n embedding?: number[],\n /** face distance from camera */\n distance?: number,\n /** face anti-spoofing result confidence */\n real?: number,\n /** face liveness result confidence */\n live?: number,\n /** face rotation details */\n rotation?: {\n angle: { roll: number, yaw: number, pitch: number },\n matrix: [number, number, number, number, number, number, number, number, number],\n gaze: { bearing: number, strength: number },\n } | null,\n /** detected face as tensor that can be used in further pipelines */\n tensor?: Tensor,\n}\n\nexport type BodyLandmarkPoseNet = 'nose' | 'leftEye' | 'rightEye' | 'leftEar' | 'rightEar' | 'leftShoulder' | 'rightShoulder' | 'leftElbow' | 'rightElbow' | 'leftWrist' | 'rightWrist' | 'leftHip' | 'rightHip' | 'leftKnee' | 'rightKnee' | 'leftAnkle' | 'rightAnkle';\nexport type BodyLandmarkMoveNet = 'nose' | 'leftEye' | 'rightEye' | 'leftEar' | 'rightEar' | 'leftShoulder' | 'rightShoulder' | 'leftElbow' | 'rightElbow' | 'leftWrist' | 'rightWrist' | 'leftHip' | 'rightHip' | 'leftKnee' | 'rightKnee' | 'leftAnkle' | 'rightAnkle';\nexport type BodyLandmarkEfficientNet = 'head' | 'neck' | 'rightShoulder' | 'rightElbow' | 'rightWrist' | 'chest' | 'leftShoulder' | 'leftElbow' | 'leftWrist' | 'bodyCenter' | 'rightHip' | 'rightKnee' | 'rightAnkle' | 'leftHip' | 'leftKnee' | 'leftAnkle';\nexport type BodyLandmarkBlazePose = 'nose' | 'leftEyeInside' | 'leftEye' | 'leftEyeOutside' | 'rightEyeInside' | 'rightEye' | 'rightEyeOutside' | 'leftEar' | 'rightEar' | 'leftMouth' | 'rightMouth' | 'leftShoulder' | 'rightShoulder'\n | 'leftElbow' | 'rightElbow' | 'leftWrist' | 'rightWrist' | 'leftPinky' | 'rightPinky' | 'leftIndex' | 'rightIndex' | 'leftThumb' | 'rightThumb' | 'leftHip' | 'rightHip' | 'leftKnee' | 'rightKnee' | 'leftAnkle' | 'rightAnkle'\n | 'leftHeel' | 'rightHeel' | 'leftFoot' | 'rightFoot' | 'bodyCenter' | 'bodyTop' | 'leftPalm' | 'leftHand' | 'rightPalm' | 'rightHand';\nexport type BodyLandmark = BodyLandmarkPoseNet | BodyLandmarkMoveNet | BodyLandmarkEfficientNet | BodyLandmarkBlazePose;\nexport type BodyAnnotationBlazePose = 'leftLeg' | 'rightLeg' | 'torso' | 'leftArm' | 'rightArm' | 'leftEye' | 'rightEye' | 'mouth';\nexport type BodyAnnotationEfficientPose = 'leftLeg' | 'rightLeg' | 'torso' | 'leftArm' | 'rightArm' | 'head';\nexport type BodyAnnotation = BodyAnnotationBlazePose | BodyAnnotationEfficientPose;\n\n/** Body Result keypoints */\nexport interface BodyKeypoint {\n /** body part name */\n part: BodyLandmark,\n /** body part position */\n position: Point,\n /** body part position normalized to 0..1 */\n positionRaw: Point,\n /** body part position relative to body center in meters */\n distance?: Point,\n /** body part detection score */\n score: number,\n}\n\n/** Body results */\nexport interface BodyResult {\n /** body id */\n id: number,\n /** body detection score */\n score: number,\n /** detected body box */\n box: Box,\n /** detected body box normalized to 0..1 */\n boxRaw: Box,\n /** detected body keypoints */\n keypoints: BodyKeypoint[]\n /** detected body keypoints combined into annotated parts */\n annotations: Record,\n}\n\nexport type HandType = 'hand' | 'fist' | 'pinch' | 'point' | 'face' | 'tip' | 'pinchtip';\nexport type Finger = 'index' | 'middle' | 'pinky' | 'ring' | 'thumb' | 'palm';\nexport type FingerCurl = 'none' | 'half' | 'full';\nexport type FingerDirection = 'verticalUp' | 'verticalDown' | 'horizontalLeft' | 'horizontalRight' | 'diagonalUpRight' | 'diagonalUpLeft' | 'diagonalDownRight' | 'diagonalDownLeft';\n\n/** Hand results */\nexport interface HandResult {\n /** hand id */\n id: number,\n /** hand overal score */\n score: number,\n /** hand detection score */\n boxScore: number,\n /** hand skelton score */\n fingerScore: number,\n /** detected hand box */\n box: Box,\n /** detected hand box normalized to 0..1 */\n boxRaw: Box,\n /** detected hand keypoints */\n keypoints: Point[],\n /** detected hand class */\n label: HandType,\n /** detected hand keypoints combined into annotated parts */\n annotations: Record,\n /** detected hand parts annotated with part gestures */\n landmarks: Record,\n}\n\nexport type ObjectType = 'person' | 'bicycle' | 'car' | 'motorcycle' | 'airplane' | 'bus' | 'train' | 'truck' | 'boat' | 'traffic light' | 'fire hydrant' | 'stop sign' | 'parking meter'\n | 'bench' | 'bird' | 'cat' | 'dog' | 'horse' | 'sheep' | 'cow' | 'elephant' | 'bear' | 'zebra' | 'giraffe' | 'backpack' | 'umbrella' | 'handbag' | 'tie' | 'suitcase' | 'frisbee'\n | 'skis' | 'snowboard' | 'sports ball' | 'kite' | 'baseball bat' | 'baseball glove' | 'skateboard' | 'surfboard' | 'tennis racket' | 'bottle' | 'wine glass' | 'cup' | 'fork'\n | 'knife' | 'spoon' | 'bowl' | 'banana' | 'apple' | 'sandwich' | 'orange' | 'broccoli' | 'carrot' | 'hot dog' | 'pizza' | 'donut' | 'cake' | 'chair' | 'couch' | 'potted plant'\n | 'bed' | 'dining table' | 'toilet' | 'tv' | 'laptop' | 'mouse' | 'remote' | 'keyboard' | 'cell phone' | 'microwave' | 'oven' | 'toaster' | 'sink' | 'refrigerator' | 'book'\n | 'clock' | 'vase' | 'scissors' | 'teddy bear' | 'hair drier' | 'toothbrush';\n\n/** Object results */\nexport interface ObjectResult {\n /** object id */\n id: number,\n /** object detection score */\n score: number,\n /** detected object class id */\n class: number,\n /** detected object class name */\n label: ObjectType,\n /** detected object box */\n box: Box,\n /** detected object box normalized to 0..1 */\n boxRaw: Box,\n}\n\n/** Gesture combined results\n * Each result has:\n * - part: part name and number where gesture was detected: `face`, `iris`, `body`, `hand`\n * - gesture: gesture detected\n */\nexport type GestureResult =\n { 'face': number, gesture: FaceGesture }\n | { 'iris': number, gesture: IrisGesture }\n | { 'body': number, gesture: BodyGesture }\n | { 'hand': number, gesture: HandGesture }\n\n/** Person getter\n* - Triggers combining all individual results into a virtual person object\n*/\nexport interface PersonResult {\n /** person id */\n id: number,\n /** face result that belongs to this person */\n face: FaceResult,\n /** body result that belongs to this person */\n body: BodyResult | null,\n /** left and right hand results that belong to this person */\n hands: { left: HandResult | null, right: HandResult | null },\n /** detected gestures specific to this person */\n gestures: GestureResult[],\n /** box that defines the person */\n box: Box,\n /** box that defines the person normalized to 0..1 */\n boxRaw?: Box,\n}\n\n/**\n * Result interface definition for **Human** library\n *\n * Contains all possible detection results\n */\nexport interface Result {\n /** {@link FaceResult}: detection & analysis results */\n face: FaceResult[],\n /** {@link BodyResult}: detection & analysis results */\n body: BodyResult[],\n /** {@link HandResult}: detection & analysis results */\n hand: HandResult[],\n /** {@link GestureResult}: detection & analysis results */\n gesture: GestureResult[],\n /** {@link ObjectResult}: detection & analysis results */\n object: ObjectResult[]\n /** global performance object with timing values for each operation */\n performance: Record,\n /** optional processed canvas that can be used to draw input on screen */\n canvas?: AnyCanvas | null,\n /** timestamp of detection representing the milliseconds elapsed since the UNIX epoch */\n readonly timestamp: number,\n /** getter property that returns unified persons object */\n persons: PersonResult[],\n /** Last known error message */\n error: string | null;\n /** Resolution width */\n width: number,\n /** Resolution height */\n height: number,\n}\n\nexport const empty = (error: string | null = null): Result => ({ face: [], body: [], hand: [], gesture: [], object: [], persons: [], performance: {}, timestamp: 0, width: 0, height: 0, error });\n", "export const kpt: string[] = [ // used to create part labels\n 'nose',\n 'leftEye',\n 'rightEye',\n 'leftEar',\n 'rightEar',\n 'leftShoulder',\n 'rightShoulder',\n 'leftElbow',\n 'rightElbow',\n 'leftWrist',\n 'rightWrist',\n 'leftHip',\n 'rightHip',\n 'leftKnee',\n 'rightKnee',\n 'leftAnkle',\n 'rightAnkle',\n];\n\nexport const horizontal: string[][] = [ // used to fix left vs right\n ['leftEye', 'rightEye'],\n ['leftEar', 'rightEar'],\n ['leftShoulder', 'rightShoulder'],\n ['leftElbow', 'rightElbow'],\n ['leftWrist', 'rightWrist'],\n ['leftHip', 'rightHip'],\n ['leftKnee', 'rightKnee'],\n ['leftAnkle', 'rightAnkle'],\n];\n\nexport const vertical: string[][] = [ // used to remove unlikely keypoint positions\n ['leftKnee', 'leftShoulder'],\n ['rightKnee', 'rightShoulder'],\n ['leftAnkle', 'leftKnee'],\n ['rightAnkle', 'rightKnee'],\n];\n\nexport const relative: string[][][] = [ // used to match relative body parts\n [['leftHip', 'rightHip'], ['leftShoulder', 'rightShoulder']],\n [['leftElbow', 'rightElbow'], ['leftShoulder', 'rightShoulder']],\n];\n\nexport const connected: Record = { // used to create body outline in annotations\n leftLeg: ['leftHip', 'leftKnee', 'leftAnkle'],\n rightLeg: ['rightHip', 'rightKnee', 'rightAnkle'],\n torso: ['leftShoulder', 'rightShoulder', 'rightHip', 'leftHip', 'leftShoulder'],\n leftArm: ['leftShoulder', 'leftElbow', 'leftWrist'],\n rightArm: ['rightShoulder', 'rightElbow', 'rightWrist'],\n head: [],\n};\n", "/**\n * Results interpolation for smoothening of video detection results inbetween detected frames\n */\n\nimport { Result, FaceResult, BodyResult, HandResult, ObjectResult, PersonResult, Box, Point, BodyLandmark, BodyAnnotation, empty, FaceLandmark } from '../result';\nimport type { Config } from '../config';\n\nimport * as moveNetCoords from '../body/movenetcoords';\nimport * as blazePoseCoords from '../body/blazeposecoords';\nimport * as efficientPoseCoords from '../body/efficientposecoords';\nimport { now } from './util';\nimport { env } from './env';\n\nconst bufferedResult: Result = empty();\nlet interpolateTime = 0;\n\nexport function calc(newResult: Result, config: Config): Result {\n const t0 = now();\n if (!newResult) return empty();\n // each record is only updated using deep clone when number of detected record changes, otherwise it will converge by itself\n // otherwise bufferedResult is a shallow clone of result plus updated local calculated values\n // thus mixing by-reference and by-value assignments to minimize memory operations\n\n const elapsed = Date.now() - newResult.timestamp;\n\n /* curve fitted: buffer = 8 - ln(delay)\n interpolation formula: current = ((buffer - 1) * previous + live) / buffer\n - at 50ms delay buffer = ~4.1 => 28% towards live data\n - at 250ms delay buffer = ~2.5 => 40% towards live data\n - at 500ms delay buffer = ~1.8 => 55% towards live data\n - at 750ms delay buffer = ~1.4 => 71% towards live data\n - at 1sec delay buffer = 1 which means live data is used\n */\n const bufferedFactor = elapsed < 1000 ? 8 - Math.log(elapsed + 1) : 1;\n\n if (newResult.canvas) bufferedResult.canvas = newResult.canvas;\n if (newResult.error) bufferedResult.error = newResult.error;\n\n // interpolate body results\n if (!bufferedResult.body || (newResult.body.length !== bufferedResult.body.length)) {\n bufferedResult.body = JSON.parse(JSON.stringify(newResult.body)) as BodyResult[]; // deep clone once\n } else {\n for (let i = 0; i < newResult.body.length; i++) {\n const box = newResult.body[i].box // update box\n .map((newBoxCoord, j) => ((bufferedFactor - 1) * bufferedResult.body[i].box[j] + newBoxCoord) / bufferedFactor) as Box;\n const boxRaw = newResult.body[i].boxRaw // update boxRaw\n .map((newBoxCoord, j) => ((bufferedFactor - 1) * bufferedResult.body[i].boxRaw[j] + newBoxCoord) / bufferedFactor) as Box;\n const keypoints = (newResult.body[i].keypoints // update keypoints\n .map((newKpt, j) => ({\n score: newKpt.score,\n part: newKpt.part,\n position: [\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].position[0] || 0) + (newKpt.position[0] || 0)) / bufferedFactor : newKpt.position[0],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].position[1] || 0) + (newKpt.position[1] || 0)) / bufferedFactor : newKpt.position[1],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].position[2] || 0) + (newKpt.position[2] || 0)) / bufferedFactor : newKpt.position[2],\n ],\n positionRaw: [\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].positionRaw[0] || 0) + (newKpt.positionRaw[0] || 0)) / bufferedFactor : newKpt.positionRaw[0],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].positionRaw[1] || 0) + (newKpt.positionRaw[1] || 0)) / bufferedFactor : newKpt.positionRaw[1],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].positionRaw[2] || 0) + (newKpt.positionRaw[2] || 0)) / bufferedFactor : newKpt.positionRaw[2],\n ],\n distance: [\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].distance?.[0] || 0) + (newKpt.distance?.[0] || 0)) / bufferedFactor : newKpt.distance?.[0],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].distance?.[1] || 0) + (newKpt.distance?.[1] || 0)) / bufferedFactor : newKpt.distance?.[1],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].distance?.[2] || 0) + (newKpt.distance?.[2] || 0)) / bufferedFactor : newKpt.distance?.[2],\n ],\n }))) as { score: number, part: BodyLandmark, position: [number, number, number?], positionRaw: [number, number, number?] }[];\n\n const annotations: Record = {} as Record; // recreate annotations\n let coords = { connected: {} };\n if (config.body.modelPath?.includes('efficientpose')) coords = efficientPoseCoords;\n else if (config.body.modelPath?.includes('blazepose')) coords = blazePoseCoords;\n else if (config.body.modelPath?.includes('movenet')) coords = moveNetCoords;\n for (const [name, indexes] of Object.entries(coords.connected as Record)) {\n const pt: Point[][] = [];\n for (let j = 0; j < indexes.length - 1; j++) {\n const pt0 = keypoints.find((kp) => kp.part === indexes[j]);\n const pt1 = keypoints.find((kp) => kp.part === indexes[j + 1]);\n // if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n if (pt0 && pt1) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n bufferedResult.body[i] = { ...newResult.body[i], box, boxRaw, keypoints, annotations }; // shallow clone plus updated values\n }\n }\n\n // interpolate hand results\n if (!bufferedResult.hand || (newResult.hand.length !== bufferedResult.hand.length)) {\n bufferedResult.hand = JSON.parse(JSON.stringify(newResult.hand)); // deep clone once\n } else {\n for (let i = 0; i < newResult.hand.length; i++) {\n const box = (newResult.hand[i].box// update box\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.hand[i].box[j] + b) / bufferedFactor)) as Box;\n const boxRaw = (newResult.hand[i].boxRaw // update boxRaw\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.hand[i].boxRaw[j] + b) / bufferedFactor)) as Box;\n if (bufferedResult.hand[i].keypoints.length !== newResult.hand[i].keypoints.length) bufferedResult.hand[i].keypoints = newResult.hand[i].keypoints; // reset keypoints as previous frame did not have them\n const keypoints = newResult.hand[i].keypoints && newResult.hand[i].keypoints.length > 0 ? newResult.hand[i].keypoints // update landmarks\n .map((landmark, j) => landmark\n .map((coord, k) => (((bufferedFactor - 1) * (bufferedResult.hand[i].keypoints[j][k] || 1) + (coord || 0)) / bufferedFactor)) as Point)\n : [];\n let annotations = {};\n if (Object.keys(bufferedResult.hand[i].annotations).length !== Object.keys(newResult.hand[i].annotations).length) {\n bufferedResult.hand[i].annotations = newResult.hand[i].annotations; // reset annotations as previous frame did not have them\n annotations = bufferedResult.hand[i].annotations;\n } else if (newResult.hand[i].annotations) {\n for (const key of Object.keys(newResult.hand[i].annotations)) { // update annotations\n annotations[key] = newResult.hand[i]?.annotations?.[key]?.[0]\n ? newResult.hand[i].annotations[key]\n .map((val, j: number) => val\n .map((coord: number, k: number) => ((bufferedFactor - 1) * bufferedResult.hand[i].annotations[key][j][k] + coord) / bufferedFactor))\n : null;\n }\n }\n bufferedResult.hand[i] = { ...newResult.hand[i], box, boxRaw, keypoints, annotations: annotations as HandResult['annotations'] }; // shallow clone plus updated values\n }\n }\n\n // interpolate face results\n if (!bufferedResult.face || (newResult.face.length !== bufferedResult.face.length)) {\n bufferedResult.face = JSON.parse(JSON.stringify(newResult.face)) as FaceResult[]; // deep clone once\n } else {\n for (let i = 0; i < newResult.face.length; i++) {\n const box = (newResult.face[i].box // update box\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.face[i].box[j] + b) / bufferedFactor)) as Box;\n const boxRaw = (newResult.face[i].boxRaw // update boxRaw\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.face[i].boxRaw[j] + b) / bufferedFactor)) as Box;\n let annotations: Record = newResult.face[i].annotations;\n if (Object.keys(bufferedResult.face[i].annotations).length !== Object.keys(newResult.face[i].annotations).length) {\n bufferedResult.face[i].annotations = newResult.face[i].annotations; // reset annotations as previous frame did not have them\n annotations = bufferedResult.face[i].annotations;\n } else if (newResult.face[i].annotations) {\n for (const key of Object.keys(newResult.face[i].annotations)) { // update annotations\n annotations[key] = newResult.face[i]?.annotations?.[key]?.[0]\n ? newResult.face[i].annotations[key]\n .map((val, j: number) => val\n .map((coord: number, k: number) => ((bufferedFactor - 1) * bufferedResult.face[i].annotations[key][j][k] + coord) / bufferedFactor))\n : null;\n }\n }\n if (newResult.face[i].rotation) {\n const rotation: {\n matrix: [number, number, number, number, number, number, number, number, number],\n angle: { roll: number, yaw: number, pitch: number },\n gaze: { bearing: number, strength: number }\n } = { matrix: [0, 0, 0, 0, 0, 0, 0, 0, 0], angle: { roll: 0, yaw: 0, pitch: 0 }, gaze: { bearing: 0, strength: 0 } };\n rotation.matrix = newResult.face[i].rotation?.matrix as [number, number, number, number, number, number, number, number, number];\n rotation.angle = {\n roll: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.angle?.roll || 0) + (newResult.face[i].rotation?.angle?.roll || 0)) / bufferedFactor,\n yaw: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.angle?.yaw || 0) + (newResult.face[i].rotation?.angle?.yaw || 0)) / bufferedFactor,\n pitch: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.angle?.pitch || 0) + (newResult.face[i].rotation?.angle?.pitch || 0)) / bufferedFactor,\n };\n rotation.gaze = {\n // not fully correct due projection on circle, also causes wrap-around draw on jump from negative to positive\n bearing: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.gaze.bearing || 0) + (newResult.face[i].rotation?.gaze.bearing || 0)) / bufferedFactor,\n strength: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.gaze.strength || 0) + (newResult.face[i].rotation?.gaze.strength || 0)) / bufferedFactor,\n };\n bufferedResult.face[i] = { ...newResult.face[i], rotation, box, boxRaw, annotations }; // shallow clone plus updated values\n } else {\n bufferedResult.face[i] = { ...newResult.face[i], box, boxRaw, annotations }; // shallow clone plus updated values\n }\n }\n }\n\n // interpolate object detection results\n if (!bufferedResult.object || (newResult.object.length !== bufferedResult.object.length)) {\n bufferedResult.object = JSON.parse(JSON.stringify(newResult.object)) as ObjectResult[]; // deep clone once\n } else {\n for (let i = 0; i < newResult.object.length; i++) {\n const box = (newResult.object[i].box // update box\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.object[i].box[j] + b) / bufferedFactor)) as Box;\n const boxRaw = (newResult.object[i].boxRaw // update boxRaw\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.object[i].boxRaw[j] + b) / bufferedFactor)) as Box;\n bufferedResult.object[i] = { ...newResult.object[i], box, boxRaw }; // shallow clone plus updated values\n }\n }\n\n // interpolate person results\n if (newResult.persons) {\n const newPersons = newResult.persons; // trigger getter function\n if (!bufferedResult.persons || (newPersons.length !== bufferedResult.persons.length)) {\n bufferedResult.persons = JSON.parse(JSON.stringify(newPersons)) as PersonResult[];\n } else {\n for (let i = 0; i < newPersons.length; i++) { // update person box, we don't update the rest as it's updated as reference anyhow\n bufferedResult.persons[i].box = (newPersons[i].box\n .map((box, j) => ((bufferedFactor - 1) * bufferedResult.persons[i].box[j] + box) / bufferedFactor)) as Box;\n }\n }\n }\n\n // copy latest gestures without interpolation\n if (newResult.gesture) bufferedResult.gesture = newResult.gesture;\n\n // copy resolution info\n bufferedResult.width = newResult.width;\n bufferedResult.height = newResult.height;\n\n // append interpolation performance data\n const t1 = now();\n interpolateTime = env.perfadd ? interpolateTime + Math.round(t1 - t0) : Math.round(t1 - t0);\n if (newResult.performance) bufferedResult.performance = { ...newResult.performance, interpolate: interpolateTime };\n\n return bufferedResult;\n}\n", "/**\n * Image segmentation for body detection model\n *\n * Based on:\n * - [**MediaPipe Meet**](https://drive.google.com/file/d/1lnP1bRi9CSqQQXUHa13159vLELYDgDu0/preview)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.segmentation.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model) model = await load(config);\n if (!model?.['executor'] || !model?.inputs?.[0].shape) return null; // something is wrong with the model\n const t: Record = {};\n t.resize = tf.image.resizeBilinear(input, [model.inputs[0].shape ? model.inputs[0].shape[1] : 0, model.inputs[0].shape ? model.inputs[0].shape[2] : 0], false);\n t.norm = tf.div(t.resize, constants.tf255);\n t.res = model.execute(t.norm) as Tensor;\n t.squeeze = tf.squeeze(t.res, [0]);\n // t.softmax = tf.softmax(t.squeeze); // model meet has two channels for fg and bg\n [t.bgRaw, t.fgRaw] = tf.unstack(t.squeeze, 2);\n // t.bg = tf.softmax(t.bgRaw); // we can ignore bg channel\n t.fg = tf.softmax(t.fgRaw);\n t.mul = tf.mul(t.fg, constants.tf255);\n t.expand = tf.expandDims(t.mul, 2);\n t.output = tf.image.resizeBilinear(t.expand as Tensor4D, [input.shape[1] || 0, input.shape[2] || 0]);\n let rgba: Tensor;\n switch (config.segmentation.mode || 'default') {\n case 'default':\n t.input = tf.squeeze(input);\n t.concat = tf.concat([t.input, t.output], -1);\n rgba = tf.cast(t.concat, 'int32'); // combined original with alpha\n break;\n case 'alpha':\n rgba = tf.cast(t.output, 'int32'); // just get alpha value from model\n break;\n default:\n rgba = tf.tensor(0);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return rgba;\n}\n", "/** Face descriptor type as number array */\nexport type Descriptor = number[]\nexport type MatchOptions = { order?: number, threshold?: number, multiplier?: number, min?: number, max?: number } | undefined;\n\n/** Calculates distance between two descriptors\n * @param options - calculation options\n * - order - algorithm to use\n * Euclidean distance if `order` is 2 (default), Minkowski distance algorithm of nth order if `order` is higher than 2\n * - multiplier - by how much to enhance difference analysis in range of 1..100\n * default is 20 which normalizes results to similarity above 0.5 can be considered a match\n */\nexport function distance(descriptor1: Descriptor, descriptor2: Descriptor, options: MatchOptions = { order: 2, multiplier: 25 }) {\n // general minkowski distance, euclidean distance is limited case where order is 2\n if (!descriptor1 || !descriptor1) return Number.MAX_SAFE_INTEGER;\n let sum = 0;\n for (let i = 0; i < descriptor1.length; i++) {\n const diff = (!options.order || options.order === 2) ? (descriptor1[i] - descriptor2[i]) : (Math.abs(descriptor1[i] - descriptor2[i]));\n sum += (!options.order || options.order === 2) ? (diff * diff) : (diff ** options.order);\n }\n return (options.multiplier || 20) * sum;\n}\n\n// invert distance to similarity, normalize to given range and clamp\nconst normalizeDistance = (dist, order, min, max) => {\n if (dist === 0) return 1; // short circuit for identical inputs\n const root = order === 2 ? Math.sqrt(dist) : dist ** (1 / order); // take root of distance\n const norm = (1 - (root / 100) - min) / (max - min); // normalize to range\n const clamp = Math.max(Math.min(norm, 1), 0); // clamp to 0..1\n return clamp;\n};\n\n/** Calculates normalized similarity between two face descriptors based on their `distance`\n * @param options - calculation options\n * - order - algorithm to use\n * Euclidean distance if `order` is 2 (default), Minkowski distance algorithm of nth order if `order` is higher than 2\n * - multiplier - by how much to enhance difference analysis in range of 1..100\n * default is 20 which normalizes results to similarity above 0.5 can be considered a match\n * - min - normalize similarity result to a given range\n * - max - normalzie similarity resutl to a given range\n * default is 0.2...0.8\n * Returns similarity between two face descriptors normalized to 0..1 range where 0 is no similarity and 1 is perfect similarity\n */\nexport function similarity(descriptor1: Descriptor, descriptor2: Descriptor, options: MatchOptions = { order: 2, multiplier: 25, min: 0.2, max: 0.8 }) {\n const dist = distance(descriptor1, descriptor2, options);\n return normalizeDistance(dist, options.order || 2, options.min || 0, options.max || 1);\n}\n\n/** Matches given descriptor to a closest entry in array of descriptors\n * @param descriptor - face descriptor\n * @param descriptors - array of face descriptors to commpare given descriptor to\n * @param options - see `similarity` method for options description\n * Returns\n * - `index` index array index where best match was found or -1 if no matches\n * - `distance` calculated `distance` of given descriptor to the best match\n * - `similarity` calculated normalized `similarity` of given descriptor to the best match\n*/\nexport function find(descriptor: Descriptor, descriptors: Descriptor[], options: MatchOptions = { order: 2, multiplier: 25, threshold: 0, min: 0.2, max: 0.8 }) {\n if (!Array.isArray(descriptor) || !Array.isArray(descriptors) || descriptor.length < 64 || descriptors.length === 0) { // validate input\n return { index: -1, distance: Number.POSITIVE_INFINITY, similarity: 0 };\n }\n let lowestDistance = Number.MAX_SAFE_INTEGER;\n let index = -1;\n for (let i = 0; i < descriptors.length; i++) {\n const res = descriptors[i].length === descriptor.length ? distance(descriptor, descriptors[i], options) : Number.MAX_SAFE_INTEGER;\n if (res < lowestDistance) {\n lowestDistance = res;\n index = i;\n }\n if (lowestDistance < (options.threshold || 0)) break;\n }\n const normalizedSimilarity = normalizeDistance(lowestDistance, options.order || 2, options.min || 0, options.max || 1);\n return { index, distance: lowestDistance, similarity: normalizedSimilarity };\n}\n", "/**\n * Loader and Validator for all models used by Human\n */\n\nimport { env } from './util/env';\nimport { log } from './util/util';\nimport * as antispoof from './face/antispoof';\nimport * as blazeface from './face/blazeface';\nimport * as blazepose from './body/blazepose';\nimport * as centernet from './object/centernet';\nimport * as efficientpose from './body/efficientpose';\nimport * as emotion from './gear/emotion';\nimport * as facemesh from './face/facemesh';\nimport * as faceres from './face/faceres';\nimport * as gear from './gear/gear';\nimport * as handpose from './hand/handpose';\nimport * as handtrack from './hand/handtrack';\nimport * as insightface from './face/insightface';\nimport * as iris from './face/iris';\nimport * as liveness from './face/liveness';\nimport * as meet from './segmentation/meet';\nimport * as mobilefacenet from './face/mobilefacenet';\nimport * as movenet from './body/movenet';\nimport * as nanodet from './object/nanodet';\nimport * as posenet from './body/posenet';\nimport * as rvm from './segmentation/rvm';\nimport * as selfie from './segmentation/selfie';\nimport * as ssrnetAge from './gear/ssrnet-age';\nimport * as ssrnetGender from './gear/ssrnet-gender';\nimport { modelStats, ModelInfo } from './tfjs/load';\nimport type { GraphModel } from './tfjs/types';\nimport type { Human } from './human';\n\nexport interface KernelOps { name: string, url: string, missing: string[], ops: string[] }\n\nexport function validateModel(instance: Human | null, model: GraphModel | null, name: string): KernelOps | null {\n if (!model) return null;\n if (!instance?.config?.validateModels) return null;\n const simpleOps = ['const', 'placeholder', 'noop', 'pad', 'squeeze', 'add', 'sub', 'mul', 'div'];\n const ignoreOps = ['biasadd', 'fusedbatchnormv3', 'matmul', 'switch', 'shape', 'merge', 'split', 'broadcastto'];\n const ops: string[] = [];\n const missing: string[] = [];\n interface Op { name: string, category: string, op: string }\n const url = model['modelUrl'] as string;\n const executor = model['executor'];\n if (executor?.graph?.nodes) {\n for (const kernel of Object.values(executor.graph.nodes)) {\n const op = (kernel as Op).op.toLowerCase();\n if (!ops.includes(op)) ops.push(op);\n }\n } else {\n if (!executor && instance.config.debug) {\n log('model not loaded', name);\n }\n }\n for (const op of ops) {\n if (!simpleOps.includes(op) // exclude simple ops\n && !ignoreOps.includes(op) // exclude specific ops\n && !instance.env.kernels.includes(op) // check actual kernel ops\n && !instance.env.kernels.includes(op.replace('_', '')) // check variation without _\n && !instance.env.kernels.includes(op.replace('native', '')) // check standard variation\n && !instance.env.kernels.includes(op.replace('v2', ''))) { // check non-versioned variation\n missing.push(op);\n }\n }\n if (instance.config.debug && missing.length > 0) log('model validation failed:', name, missing);\n return missing.length > 0 ? { name, missing, ops, url } : null;\n}\n\n/** structure that holds global stats for currently loaded models */\nexport interface ModelStats {\n numLoadedModels: number,\n numDefinedModels: number,\n percentageLoaded: number,\n totalSizeFromManifest: number,\n totalSizeWeights: number,\n totalSizeLoading: number,\n modelStats: ModelInfo[],\n}\n\n/** Models class used by Human\n * - models: record of all GraphModels\n * - list: returns list of configured models with their stats\n * - loaded: returns array of loaded models\n * - reset: unloads all models\n * - validate: checks loaded models for valid kernel ops vs current backend\n * - stats: live detailed model stats that can be checked during model load phase\n */\nexport class Models {\n private instance: Human;\n models: Record = {};\n\n constructor(currentInstance: Human) {\n this.models = {};\n this.instance = currentInstance;\n }\n\n stats(): ModelStats {\n let totalSizeFromManifest = 0;\n let totalSizeWeights = 0;\n let totalSizeLoading = 0;\n for (const m of Object.values(modelStats)) {\n totalSizeFromManifest += m.sizeFromManifest;\n totalSizeWeights += m.sizeLoadedWeights;\n totalSizeLoading += m.sizeDesired;\n }\n const percentageLoaded = totalSizeLoading > 0 ? totalSizeWeights / totalSizeLoading : 0;\n return {\n numLoadedModels: Object.values(modelStats).length,\n numDefinedModels: Object.keys(this.models).length,\n percentageLoaded,\n totalSizeFromManifest,\n totalSizeWeights,\n totalSizeLoading,\n modelStats: Object.values(modelStats),\n };\n }\n\n reset(): void {\n for (const model of Object.keys(this.models)) this.models[model] = null;\n }\n\n async load(instance?: Human): Promise {\n if (env.initial) this.reset();\n if (instance) this.instance = instance;\n const m: Record> = {};\n // face main models\n m.blazeface = (this.instance.config.face.enabled && !this.models.blazeface) ? blazeface.load(this.instance.config) : null;\n m.antispoof = (this.instance.config.face.enabled && this.instance.config.face.antispoof?.enabled && !this.models.antispoof) ? antispoof.load(this.instance.config) : null;\n m.liveness = (this.instance.config.face.enabled && this.instance.config.face.liveness?.enabled && !this.models.liveness) ? liveness.load(this.instance.config) : null;\n m.faceres = (this.instance.config.face.enabled && this.instance.config.face.description?.enabled && !this.models.faceres) ? faceres.load(this.instance.config) : null;\n m.emotion = (this.instance.config.face.enabled && this.instance.config.face.emotion?.enabled && !this.models.emotion) ? emotion.load(this.instance.config) : null;\n m.iris = (this.instance.config.face.enabled && this.instance.config.face.iris?.enabled && !this.instance.config.face.attention?.enabled && !this.models.iris) ? iris.load(this.instance.config) : null;\n m.facemesh = (this.instance.config.face.enabled && this.instance.config.face.mesh?.enabled && (!this.models.facemesh)) ? facemesh.load(this.instance.config) : null;\n // face alternatives\n m.gear = (this.instance.config.face.enabled && this.instance.config.face['gear']?.enabled && !this.models.gear) ? gear.load(this.instance.config) : null;\n m.ssrnetage = (this.instance.config.face.enabled && this.instance.config.face['ssrnet']?.enabled && !this.models.ssrnetage) ? ssrnetAge.load(this.instance.config) : null;\n m.ssrnetgender = (this.instance.config.face.enabled && this.instance.config.face['ssrnet']?.enabled && !this.models.ssrnetgender) ? ssrnetGender.load(this.instance.config) : null;\n m.mobilefacenet = (this.instance.config.face.enabled && this.instance.config.face['mobilefacenet']?.enabled && !this.models.mobilefacenet) ? mobilefacenet.load(this.instance.config) : null;\n m.insightface = (this.instance.config.face.enabled && this.instance.config.face['insightface']?.enabled && !this.models.insightface) ? insightface.load(this.instance.config) : null;\n // body alterinatives\n m.blazepose = (this.instance.config.body.enabled && !this.models.blazepose && this.instance.config.body.modelPath?.includes('blazepose')) ? blazepose.loadPose(this.instance.config) : null;\n m.blazeposedetect = (this.instance.config.body.enabled && !this.models.blazeposedetect && this.instance.config.body['detector'] && this.instance.config.body['detector'].modelPath) ? blazepose.loadDetect(this.instance.config) : null;\n m.efficientpose = (this.instance.config.body.enabled && !this.models.efficientpose && this.instance.config.body.modelPath?.includes('efficientpose')) ? efficientpose.load(this.instance.config) : null;\n m.movenet = (this.instance.config.body.enabled && !this.models.movenet && this.instance.config.body.modelPath?.includes('movenet')) ? movenet.load(this.instance.config) : null;\n m.posenet = (this.instance.config.body.enabled && !this.models.posenet && this.instance.config.body.modelPath?.includes('posenet')) ? posenet.load(this.instance.config) : null;\n // hand alternatives\n m.handtrack = (this.instance.config.hand.enabled && !this.models.handtrack && this.instance.config.hand.detector?.modelPath?.includes('handtrack')) ? handtrack.loadDetect(this.instance.config) : null;\n m.handskeleton = (this.instance.config.hand.enabled && this.instance.config.hand.landmarks && !this.models.handskeleton && this.instance.config.hand.detector?.modelPath?.includes('handtrack')) ? handtrack.loadSkeleton(this.instance.config) : null;\n // if (this.instance.config.hand.detector?.modelPath?.includes('handdetect')) [m.handpose, m.handskeleton] = (!this.models.handpose) ? await handpose.load(this.instance.config) : [null, null];\n if (this.instance.config.hand.enabled && !this.models.handdetect && this.instance.config.hand.detector?.modelPath?.includes('handdetect')) {\n m.handdetect = handpose.loadDetect(this.instance.config);\n m.handskeleton = handpose.loadSkeleton(this.instance.config);\n }\n // object detection alternatives\n m.centernet = (this.instance.config.object.enabled && !this.models.centernet && this.instance.config.object.modelPath?.includes('centernet')) ? centernet.load(this.instance.config) : null;\n m.nanodet = (this.instance.config.object.enabled && !this.models.nanodet && this.instance.config.object.modelPath?.includes('nanodet')) ? nanodet.load(this.instance.config) : null;\n // segmentation alternatives\n m.selfie = (this.instance.config.segmentation.enabled && !this.models.selfie && this.instance.config.segmentation.modelPath?.includes('selfie')) ? selfie.load(this.instance.config) : null;\n m.meet = (this.instance.config.segmentation.enabled && !this.models.meet && this.instance.config.segmentation.modelPath?.includes('meet')) ? meet.load(this.instance.config) : null;\n m.rvm = (this.instance.config.segmentation.enabled && !this.models.rvm && this.instance.config.segmentation.modelPath?.includes('rvm')) ? rvm.load(this.instance.config) : null;\n\n // models are loaded in parallel asynchronously so lets wait until they are actually loaded\n for (const [model, promise] of Object.entries(m)) {\n if (promise?.['then']) promise['then']((val) => this.models[model] = val);\n }\n await Promise.all(Object.values(m)); // wait so this function does not resolve prematurely\n }\n\n list() {\n const models = Object.keys(this.models).map((model) => ({ name: model, loaded: (this.models[model] !== null), size: 0, url: this.models[model] ? this.models[model]?.['modelUrl'] : null }));\n for (const m of models) {\n const stats = Object.keys(modelStats).find((s) => s.startsWith(m.name));\n if (!stats) continue;\n m.size = modelStats[stats].sizeLoadedWeights;\n m.url = modelStats[stats].url;\n }\n return models;\n }\n\n loaded() {\n const list = this.list();\n const loaded = list.filter((model) => model.loaded).map((model) => model.name);\n return loaded;\n }\n\n validate(): { name: string, missing: string[] }[] {\n const missing: KernelOps[] = [];\n for (const defined of Object.keys(this.models)) {\n const model: GraphModel | null = this.models[defined as keyof Models];\n if (!model) continue;\n const res = validateModel(this.instance, model, defined);\n if (res) missing.push(res);\n }\n return missing;\n }\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport type { BodyKeypoint, BodyResult } from '../result';\nimport * as box from '../util/box';\nimport * as coords from './movenetcoords';\nimport type { Tensor, Tensor3D } from '../tfjs/types';\n\nconst maxJitter = 0.005; // default allowed jitter is within 0.5%\n\nconst cache: {\n keypoints: BodyKeypoint[],\n padding: [number, number][];\n} = {\n keypoints: [],\n padding: [[0, 0], [0, 0], [0, 0], [0, 0]],\n};\n\nexport function bodyParts(body: BodyResult) { // model sometimes mixes up left vs right keypoints so we fix them\n for (const pair of coords.horizontal) { // fix body parts left vs right\n const left = body.keypoints.findIndex((kp) => kp.part === pair[0]);\n const right = body.keypoints.findIndex((kp) => kp.part === pair[1]);\n if (body.keypoints[left] && body.keypoints[right]) {\n if (body.keypoints[left].position[0] < body.keypoints[right].position[0]) {\n const tmp = body.keypoints[left];\n body.keypoints[left] = body.keypoints[right];\n body.keypoints[right] = tmp;\n }\n }\n }\n for (const pair of coords.vertical) { // remove body parts with improbable vertical position\n const lower = body.keypoints.findIndex((kp) => (kp && kp.part === pair[0]));\n const higher = body.keypoints.findIndex((kp) => (kp && kp.part === pair[1]));\n if (body.keypoints[lower] && body.keypoints[higher]) {\n if (body.keypoints[lower].position[1] < body.keypoints[higher].position[1]) {\n body.keypoints.splice(lower, 1);\n }\n }\n }\n for (const [pair, compare] of coords.relative) { // rearrange body parts according to their relative position\n const left = body.keypoints.findIndex((kp) => (kp && kp.part === pair[0]));\n const right = body.keypoints.findIndex((kp) => (kp && kp.part === pair[1]));\n const leftTo = body.keypoints.findIndex((kp) => (kp && kp.part === compare[0]));\n const rightTo = body.keypoints.findIndex((kp) => (kp && kp.part === compare[1]));\n if (!body.keypoints[leftTo] || !body.keypoints[rightTo]) continue; // only if we have both compare points\n const distanceLeft = body.keypoints[left] ? [\n Math.abs(body.keypoints[leftTo].position[0] - body.keypoints[left].position[0]),\n Math.abs(body.keypoints[rightTo].position[0] - body.keypoints[left].position[0]),\n ] : [0, 0];\n const distanceRight = body.keypoints[right] ? [\n Math.abs(body.keypoints[rightTo].position[0] - body.keypoints[right].position[0]),\n Math.abs(body.keypoints[leftTo].position[0] - body.keypoints[right].position[0]),\n ] : [0, 0];\n if (distanceLeft[0] > distanceLeft[1] || distanceRight[0] > distanceRight[1]) { // should flip keypoints\n const tmp = body.keypoints[left];\n body.keypoints[left] = body.keypoints[right];\n body.keypoints[right] = tmp;\n }\n }\n}\n\nexport function jitter(keypoints: BodyKeypoint[]): BodyKeypoint[] {\n for (let i = 0; i < keypoints.length; i++) {\n if (keypoints[i] && cache.keypoints[i]) {\n const diff = [Math.abs(keypoints[i].positionRaw[0] - cache.keypoints[i].positionRaw[0]), Math.abs(keypoints[i].positionRaw[1] - cache.keypoints[i].positionRaw[1])];\n if (diff[0] < maxJitter && diff[1] < maxJitter) {\n keypoints[i] = cache.keypoints[i]; // below jitter so replace keypoint\n } else {\n cache.keypoints[i] = keypoints[i]; // above jitter so update cache\n }\n } else {\n cache.keypoints[i] = keypoints[i]; // cache for keypoint doesnt exist so create it here\n }\n }\n return keypoints;\n}\n\nexport function padInput(input: Tensor, inputSize: number): Tensor {\n const t: Record = {};\n if (!input?.shape?.[1] || !input?.shape?.[2]) return input;\n cache.padding = [\n [0, 0], // dont touch batch\n [input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0, input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0], // height before&after\n [input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0, input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0], // width before&after\n [0, 0], // dont touch rbg\n ];\n t.pad = tf.pad(input, cache.padding);\n t.resize = tf.image.resizeBilinear(t.pad as Tensor3D, [inputSize, inputSize]);\n const final = tf.cast(t.resize, 'int32');\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return final;\n}\n\nexport function rescaleBody(body: BodyResult, outputSize: [number, number]): BodyResult {\n body.keypoints = body.keypoints.filter((kpt) => kpt?.position); // filter invalid keypoints\n for (const kpt of body.keypoints) {\n kpt.position = [\n kpt.position[0] * (outputSize[0] + cache.padding[2][0] + cache.padding[2][1]) / outputSize[0] - cache.padding[2][0],\n kpt.position[1] * (outputSize[1] + cache.padding[1][0] + cache.padding[1][1]) / outputSize[1] - cache.padding[1][0],\n ];\n kpt.positionRaw = [\n kpt.position[0] / outputSize[0], kpt.position[1] / outputSize[1],\n ];\n }\n const rescaledBoxes = box.calc(body.keypoints.map((pt) => pt.position), outputSize);\n body.box = rescaledBoxes.box;\n body.boxRaw = rescaledBoxes.boxRaw;\n return body;\n}\n", "/**\n * MoveNet model implementation\n *\n * Based on: [**MoveNet**](https://blog.tensorflow.org/2021/05/next-generation-pose-detection-with-movenet-and-tensorflowjs.html)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport * as box from '../util/box';\nimport * as coords from './movenetcoords';\nimport * as fix from './movenetfix';\nimport { loadModel } from '../tfjs/load';\nimport type { BodyKeypoint, BodyResult, BodyLandmark, BodyAnnotation, Box, Point } from '../result';\nimport type { GraphModel, Tensor } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { fakeOps } from '../tfjs/backend';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nlet inputSize = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n// const boxExpandFact = 1.5; // increase to 150%\n\nconst cache: {\n boxes: Box[], // unused\n bodies: BodyResult[];\n last: number,\n} = {\n boxes: [],\n bodies: [],\n last: 0,\n};\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n fakeOps(['size'], config);\n model = await loadModel(config.body.modelPath);\n } else if (config.debug) log('cached model:', model['modelUrl']);\n inputSize = (model?.['executor'] && model?.inputs?.[0].shape) ? model.inputs[0].shape[2] : 0;\n if (inputSize < 64) inputSize = 256;\n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS) tf.env().set('WEBGL_USE_SHAPES_UNIFORMS', false); // default=false \n return model;\n}\n\nfunction parseSinglePose(res, config, image) {\n const kpt = res[0][0];\n const keypoints: BodyKeypoint[] = [];\n let score = 0;\n for (let id = 0; id < kpt.length; id++) {\n score = kpt[id][2];\n if (score > config.body.minConfidence) {\n const positionRaw: Point = [kpt[id][1], kpt[id][0]];\n keypoints.push({\n score: Math.round(100 * score) / 100,\n part: coords.kpt[id] as BodyLandmark,\n positionRaw,\n position: [ // normalized to input image size\n Math.round((image.shape[2] || 0) * positionRaw[0]),\n Math.round((image.shape[1] || 0) * positionRaw[1]),\n ],\n });\n }\n }\n score = keypoints.reduce((prev, curr) => (curr.score > prev ? curr.score : prev), 0);\n const bodies: BodyResult[] = [];\n const newBox = box.calc(keypoints.map((pt) => pt.position), [image.shape[2], image.shape[1]]);\n const annotations: Record = {};\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = keypoints.find((kp) => kp.part === indexes[i]);\n const pt1 = keypoints.find((kp) => kp.part === indexes[i + 1]);\n if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n const body: BodyResult = { id: 0, score, box: newBox.box, boxRaw: newBox.boxRaw, keypoints, annotations };\n fix.bodyParts(body);\n bodies.push(body);\n return bodies;\n}\n\nfunction parseMultiPose(res, config, image) {\n const bodies: BodyResult[] = [];\n for (let id = 0; id < res[0].length; id++) {\n const kpt = res[0][id];\n const boxScore = Math.round(100 * kpt[51 + 4]) / 100;\n if (boxScore > config.body.minConfidence) {\n const keypoints: BodyKeypoint[] = [];\n for (let i = 0; i < 17; i++) {\n const score = kpt[3 * i + 2];\n if (score > config.body.minConfidence) {\n const positionRaw: Point = [kpt[3 * i + 1], kpt[3 * i + 0]];\n keypoints.push({\n part: coords.kpt[i] as BodyLandmark,\n score: Math.round(100 * score) / 100,\n positionRaw,\n position: [Math.round((image.shape[2] || 0) * positionRaw[0]), Math.round((image.shape[1] || 0) * positionRaw[1])],\n });\n }\n }\n // const newBox = box.calc(keypoints.map((pt) => pt.position), [image.shape[2], image.shape[1]]);\n // movenet-multipose has built-in box details\n const boxRaw: Box = [kpt[51 + 1], kpt[51 + 0], kpt[51 + 3] - kpt[51 + 1], kpt[51 + 2] - kpt[51 + 0]];\n const boxNorm: Box = [Math.trunc(boxRaw[0] * (image.shape[2] || 0)), Math.trunc(boxRaw[1] * (image.shape[1] || 0)), Math.trunc(boxRaw[2] * (image.shape[2] || 0)), Math.trunc(boxRaw[3] * (image.shape[1] || 0))];\n const annotations: Record = {} as Record;\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = keypoints.find((kp) => kp.part === indexes[i]);\n const pt1 = keypoints.find((kp) => kp.part === indexes[i + 1]);\n if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n // const body: BodyResult = { id, score: totalScore, box: newBox.box, boxRaw: newBox.boxRaw, keypoints: [...keypoints], annotations };\n const body: BodyResult = { id, score: boxScore, box: boxNorm, boxRaw, keypoints: [...keypoints], annotations };\n fix.bodyParts(body);\n bodies.push(body);\n }\n }\n bodies.sort((a, b) => b.score - a.score);\n if (bodies.length > config.body.maxDetected) bodies.length = config.body.maxDetected;\n return bodies;\n}\n\nexport async function predict(input: Tensor, config: Config): Promise {\n if (!model?.['executor'] || !model?.inputs?.[0].shape) return []; // something is wrong with the model\n if (!config.skipAllowed) cache.boxes.length = 0; // allowed to use cache or not\n skipped++; // increment skip frames\n const skipTime = (config.body.skipTime || 0) > (now() - cache.last);\n const skipFrame = skipped < (config.body.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame) {\n return cache.bodies; // return cached results without running anything\n }\n return new Promise(async (resolve) => {\n const t: Record = {};\n skipped = 0;\n // run detection on squared input and no cached boxes\n t.input = fix.padInput(input, inputSize);\n t.res = model?.execute(t.input) as Tensor;\n cache.last = now();\n const res = await t.res.array();\n cache.bodies = (t.res.shape[2] === 17)\n ? parseSinglePose(res, config, input)\n : parseMultiPose(res, config, input);\n for (const body of cache.bodies) {\n fix.rescaleBody(body, [input.shape[2] || 1, input.shape[1] || 1]);\n fix.jitter(body.keypoints);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n\n resolve(cache.bodies);\n });\n}\n", "/**\n * NanoDet object detection model implementation\n *\n * Based on: [**NanoDet**](https://github.com/RangiLyu/nanodet)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport { labels } from './labels';\nimport type { ObjectResult, ObjectType, Box } from '../result';\nimport type { GraphModel, Tensor, Tensor2D, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\nlet last: ObjectResult[] = [];\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet inputSize = 0;\n\nconst scaleBox = 2.5; // increase box size\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) {\n model = await loadModel(config.object.modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 416;\n } else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nasync function process(res: Tensor[], outputShape: [number, number], config: Config) {\n let id = 0;\n let results: ObjectResult[] = [];\n const size = inputSize;\n for (const strideSize of [1, 2, 4]) { // try each stride size as it detects large/medium/small objects\n // find scores, boxes, classes\n const baseSize = strideSize * 13; // 13x13=169, 26x26=676, 52x52=2704\n // find boxes and scores output depending on stride\n const scoresT = tf.squeeze(res.find((a) => (a.shape[1] === (baseSize ** 2) && (a.shape[2] || 0) === labels.length)) as Tensor2D);\n const scores = await scoresT.array(); // optionally use exponential scores or just as-is\n const featuresT = tf.squeeze(res.find((a) => (a.shape[1] === (baseSize ** 2) && (a.shape[2] || 0) < labels.length)) as Tensor2D);\n const boxesMaxT = tf.reshape(featuresT, [-1, 4, (featuresT.shape?.[1] || 0) / 4]); // reshape [output] to [4, output / 4] where number is number of different features inside each stride\n const boxIdxT = tf.argMax(boxesMaxT, 2); // what we need is indexes of features with highest scores, not values itself\n const boxIdx = await boxIdxT.array(); // what we need is indexes of features with highest scores, not values itself\n for (let i = 0; i < scoresT.shape[0]; i++) { // total strides (x * y matrix)\n for (let j = 0; j < (scoresT.shape?.[1] || 0); j++) { // one score for each class\n const score = scores[i][j]; // get score for current position\n if (score > (config.object.minConfidence || 0) && j !== 61) {\n const cx = (0.5 + Math.trunc(i % baseSize)) / baseSize; // center.x normalized to range 0..1\n const cy = (0.5 + Math.trunc(i / baseSize)) / baseSize; // center.y normalized to range 0..1\n const boxOffset = boxIdx[i].map((a: number) => a * (baseSize / strideSize / (size))); // just grab indexes of features with highest scores\n const [x, y] = [\n cx - (scaleBox / strideSize * boxOffset[0]),\n cy - (scaleBox / strideSize * boxOffset[1]),\n ];\n const [w, h] = [\n cx + (scaleBox / strideSize * boxOffset[2]) - x,\n cy + (scaleBox / strideSize * boxOffset[3]) - y,\n ];\n let boxRaw: Box = [x, y, w, h]; // results normalized to range 0..1\n boxRaw = boxRaw.map((a) => Math.max(0, Math.min(a, 1))) as Box; // fix out-of-bounds coords\n const box = [ // results normalized to input image pixels\n boxRaw[0] * outputShape[0],\n boxRaw[1] * outputShape[1],\n boxRaw[2] * outputShape[0],\n boxRaw[3] * outputShape[1],\n ];\n const result = {\n id: id++,\n // strideSize,\n score: Math.round(100 * score) / 100,\n class: j + 1,\n label: labels[j].label as ObjectType,\n // center: [Math.trunc(outputShape[0] * cx), Math.trunc(outputShape[1] * cy)],\n // centerRaw: [cx, cy],\n box: box.map((a) => Math.trunc(a)) as Box,\n boxRaw,\n };\n results.push(result);\n }\n }\n }\n tf.dispose([scoresT, featuresT, boxesMaxT, boxIdxT]);\n }\n\n // normally nms is run on raw results, but since boxes need to be calculated this way we skip calulcation of\n // unnecessary boxes and run nms only on good candidates (basically it just does IOU analysis as scores are already filtered)\n const nmsBoxes = results.map((a) => [a.boxRaw[1], a.boxRaw[0], a.boxRaw[3], a.boxRaw[2]]); // switches coordinates from x,y to y,x as expected by tf.nms\n const nmsScores = results.map((a) => a.score);\n let nmsIdx: number[] = [];\n if (nmsBoxes && nmsBoxes.length > 0) {\n const nms = await tf.image.nonMaxSuppressionAsync(nmsBoxes, nmsScores, config.object.maxDetected || 0, config.object.iouThreshold, config.object.minConfidence);\n nmsIdx = Array.from(await nms.data());\n tf.dispose(nms);\n }\n\n // filter & sort results\n results = results\n .filter((_val, idx) => nmsIdx.includes(idx))\n .sort((a, b) => (b.score - a.score));\n\n return results;\n}\n\nexport async function predict(image: Tensor4D, config: Config): Promise {\n if (!model?.['executor']) return [];\n const skipTime = (config.object.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.object.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (last.length > 0)) {\n skipped++;\n return last;\n }\n skipped = 0;\n if (!env.kernels.includes('mod') || !env.kernels.includes('sparsetodense')) return last;\n return new Promise(async (resolve) => {\n const outputSize = [image.shape[2] || 0, image.shape[1] || 0];\n const resizeT = tf.image.resizeBilinear(image, [inputSize, inputSize], false);\n const normT = tf.div(resizeT, constants.tf255);\n const transposeT = tf.transpose(normT, [0, 3, 1, 2]);\n\n let objectT;\n if (config.object.enabled) objectT = model.execute(transposeT);\n lastTime = now();\n\n const obj = await process(objectT as Tensor[], outputSize as [number, number], config);\n last = obj;\n tf.dispose([resizeT, normT, transposeT, ...objectT]);\n resolve(obj);\n });\n}\n", "/**\n * PoseNet body detection model implementation constants\n * See `posenet.ts` for entry point\n */\n\nimport type { Point, BodyResult, BodyAnnotation, BodyLandmark } from '../result';\n\nexport const partNames = [\n 'nose', 'leftEye', 'rightEye', 'leftEar', 'rightEar', 'leftShoulder',\n 'rightShoulder', 'leftElbow', 'rightElbow', 'leftWrist', 'rightWrist',\n 'leftHip', 'rightHip', 'leftKnee', 'rightKnee', 'leftAnkle', 'rightAnkle',\n];\n\nexport const count = partNames.length; // 17 keypoints\n\nexport const partIds = partNames.reduce((result, jointName, i) => {\n result[jointName] = i;\n return result;\n}, {});\n\nconst connectedPartNames = [\n ['leftHip', 'leftShoulder'], ['leftElbow', 'leftShoulder'],\n ['leftElbow', 'leftWrist'], ['leftHip', 'leftKnee'],\n ['leftKnee', 'leftAnkle'], ['rightHip', 'rightShoulder'],\n ['rightElbow', 'rightShoulder'], ['rightElbow', 'rightWrist'],\n ['rightHip', 'rightKnee'], ['rightKnee', 'rightAnkle'],\n ['leftShoulder', 'rightShoulder'], ['leftHip', 'rightHip'],\n];\nexport const connectedPartIndices = connectedPartNames.map(([jointNameA, jointNameB]) => ([partIds[jointNameA], partIds[jointNameB]]));\n\nexport const poseChain = [\n ['nose', 'leftEye'], ['leftEye', 'leftEar'], ['nose', 'rightEye'],\n ['rightEye', 'rightEar'], ['nose', 'leftShoulder'],\n ['leftShoulder', 'leftElbow'], ['leftElbow', 'leftWrist'],\n ['leftShoulder', 'leftHip'], ['leftHip', 'leftKnee'],\n ['leftKnee', 'leftAnkle'], ['nose', 'rightShoulder'],\n ['rightShoulder', 'rightElbow'], ['rightElbow', 'rightWrist'],\n ['rightShoulder', 'rightHip'], ['rightHip', 'rightKnee'],\n ['rightKnee', 'rightAnkle'],\n];\n\nexport function eitherPointDoesntMeetConfidence(a: number, b: number, minConfidence: number) {\n return (a < minConfidence || b < minConfidence);\n}\n\nexport function getAdjacentKeyPoints(keypoints, minConfidence: number) {\n return connectedPartIndices.reduce((result, [leftJoint, rightJoint]) => {\n if (eitherPointDoesntMeetConfidence(keypoints[leftJoint].score, keypoints[rightJoint].score, minConfidence)) {\n return result;\n }\n result.push([keypoints[leftJoint], keypoints[rightJoint]]);\n return result;\n }, []);\n}\n\nexport function getBoundingBox(keypoints): [number, number, number, number] {\n const coord = keypoints.reduce(({ maxX, maxY, minX, minY }, { position: { x, y } }) => ({\n maxX: Math.max(maxX, x),\n maxY: Math.max(maxY, y),\n minX: Math.min(minX, x),\n minY: Math.min(minY, y),\n }), {\n maxX: Number.NEGATIVE_INFINITY,\n maxY: Number.NEGATIVE_INFINITY,\n minX: Number.POSITIVE_INFINITY,\n minY: Number.POSITIVE_INFINITY,\n });\n return [coord.minX, coord.minY, coord.maxX - coord.minX, coord.maxY - coord.minY];\n}\n\nexport function scalePoses(poses, [height, width], [inputResolutionHeight, inputResolutionWidth]): BodyResult[] {\n const scaleY = height / inputResolutionHeight;\n const scaleX = width / inputResolutionWidth;\n const scalePose = (pose, i): BodyResult => ({\n id: i,\n score: pose.score,\n boxRaw: [pose.box[0] / inputResolutionWidth, pose.box[1] / inputResolutionHeight, pose.box[2] / inputResolutionWidth, pose.box[3] / inputResolutionHeight],\n box: [Math.trunc(pose.box[0] * scaleX), Math.trunc(pose.box[1] * scaleY), Math.trunc(pose.box[2] * scaleX), Math.trunc(pose.box[3] * scaleY)],\n keypoints: pose.keypoints.map(({ score, part, position }) => ({\n score: score as number,\n part: part as BodyLandmark,\n position: [Math.trunc(position.x * scaleX), Math.trunc(position.y * scaleY)] as Point,\n positionRaw: [position.x / inputResolutionHeight, position.y / inputResolutionHeight] as Point,\n })),\n annotations: {} as Record,\n });\n const scaledPoses = poses.map((pose, i) => scalePose(pose, i));\n return scaledPoses;\n}\n\n// algorithm based on Coursera Lecture from Algorithms, Part 1: https://www.coursera.org/learn/algorithms-part1/lecture/ZjoSM/heapsort\nexport class MaxHeap {\n priorityQueue: unknown[]; // don't touch\n numberOfElements: number;\n getElementValue: unknown; // function call\n\n constructor(maxSize, getElementValue) {\n this.priorityQueue = new Array(maxSize);\n this.numberOfElements = -1;\n this.getElementValue = getElementValue;\n }\n\n enqueue(x) {\n this.priorityQueue[++this.numberOfElements] = x;\n this.swim(this.numberOfElements);\n }\n\n dequeue() {\n const max = this.priorityQueue[0];\n this.exchange(0, this.numberOfElements--);\n this.sink(0);\n this.priorityQueue[this.numberOfElements + 1] = null;\n return max;\n }\n\n empty() { return this.numberOfElements === -1; }\n\n size() { return this.numberOfElements + 1; }\n\n all() { return this.priorityQueue.slice(0, this.numberOfElements + 1); }\n\n max() { return this.priorityQueue[0]; }\n\n swim(k) {\n while (k > 0 && this.less(Math.floor(k / 2), k)) {\n this.exchange(k, Math.floor(k / 2));\n k = Math.floor(k / 2);\n }\n }\n\n sink(k) {\n while (2 * k <= this.numberOfElements) {\n let j = 2 * k;\n if (j < this.numberOfElements && this.less(j, j + 1)) j++;\n if (!this.less(k, j)) break;\n this.exchange(k, j);\n k = j;\n }\n }\n\n getValueAt(i) {\n // @ts-ignore getter is of unknown type\n return this.getElementValue(this.priorityQueue[i]);\n }\n\n less(i, j) {\n return this.getValueAt(i) < this.getValueAt(j);\n }\n\n exchange(i, j) {\n const t = this.priorityQueue[i];\n this.priorityQueue[i] = this.priorityQueue[j];\n this.priorityQueue[j] = t;\n }\n}\n\nexport function getOffsetPoint(y, x, keypoint: number, offsets) {\n return {\n y: offsets.get(y, x, keypoint),\n x: offsets.get(y, x, keypoint + count),\n };\n}\n\nexport function getImageCoords(part, outputStride: number, offsets) {\n const { heatmapY, heatmapX, id: keypoint } = part;\n const { y, x } = getOffsetPoint(heatmapY, heatmapX, keypoint, offsets);\n return {\n x: part.heatmapX * outputStride + x,\n y: part.heatmapY * outputStride + y,\n };\n}\n\nexport function fillArray(element, size) {\n const result = new Array(size);\n for (let i = 0; i < size; i++) {\n result[i] = element;\n }\n return result;\n}\n\nexport function clamp(a, min, max) {\n if (a < min) return min;\n if (a > max) return max;\n return a;\n}\n\nexport function squaredDistance(y1, x1, y2, x2) {\n const dy = y2 - y1;\n const dx = x2 - x1;\n return dy * dy + dx * dx;\n}\n\nexport function addVectors(a: { x: number, y: number }, b: { x: number, y: number }) {\n return { x: a.x + b.x, y: a.y + b.y };\n}\n\nexport function clampVector(a, min, max) {\n return { y: clamp(a.y, min, max), x: clamp(a.x, min, max) };\n}\n", "/**\n * PoseNet body detection model implementation\n *\n * Based on: [**PoseNet**](https://medium.com/tensorflow/real-time-human-pose-estimation-in-the-browser-with-tensorflow-js-7dd0bc881cd5)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { BodyResult, BodyLandmark, Box } from '../result';\nimport type { Tensor, GraphModel, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\nimport * as utils from './posenetutils';\n\nlet model: GraphModel;\nconst poseNetOutputs = ['MobilenetV1/offset_2/BiasAdd'/* offsets */, 'MobilenetV1/heatmap_2/BiasAdd'/* heatmapScores */, 'MobilenetV1/displacement_fwd_2/BiasAdd'/* displacementFwd */, 'MobilenetV1/displacement_bwd_2/BiasAdd'/* displacementBwd */];\nconst localMaximumRadius = 1;\nconst outputStride = 16;\nconst squaredNmsRadius = 50 ** 2;\n\nfunction traverse(edgeId: number, sourceKeypoint, targetId, scores, offsets, displacements, offsetRefineStep = 2) {\n const getDisplacement = (point) => ({\n y: displacements.get(point.y, point.x, edgeId),\n x: displacements.get(point.y, point.x, (displacements.shape[2] / 2) + edgeId),\n });\n const getStridedIndexNearPoint = (point, height, width) => ({\n y: utils.clamp(Math.round(point.y / outputStride), 0, height - 1),\n x: utils.clamp(Math.round(point.x / outputStride), 0, width - 1),\n });\n\n const [height, width] = scores.shape;\n // Nearest neighbor interpolation for the source->target displacements.\n const sourceKeypointIndices = getStridedIndexNearPoint(sourceKeypoint.position, height, width);\n const displacement = getDisplacement(sourceKeypointIndices);\n const displacedPoint = utils.addVectors(sourceKeypoint.position, displacement);\n let targetKeypoint = displacedPoint;\n for (let i = 0; i < offsetRefineStep; i++) {\n const targetKeypointIndices = getStridedIndexNearPoint(targetKeypoint, height, width);\n const offsetPoint = utils.getOffsetPoint(targetKeypointIndices.y, targetKeypointIndices.x, targetId, offsets);\n targetKeypoint = utils.addVectors(\n { x: targetKeypointIndices.x * outputStride, y: targetKeypointIndices.y * outputStride },\n { x: offsetPoint.x, y: offsetPoint.y },\n );\n }\n const targetKeyPointIndices = getStridedIndexNearPoint(targetKeypoint, height, width);\n const score = scores.get(targetKeyPointIndices.y, targetKeyPointIndices.x, targetId);\n return { position: targetKeypoint, part: utils.partNames[targetId], score };\n}\n\nexport function decodePose(root, scores, offsets, displacementsFwd, displacementsBwd) {\n const tuples = utils.poseChain.map(([parentJoinName, childJoinName]) => ([utils.partIds[parentJoinName], utils.partIds[childJoinName]]));\n const edgesFwd = tuples.map(([, childJointId]) => childJointId);\n const edgesBwd = tuples.map(([parentJointId]) => parentJointId);\n const numParts = scores.shape[2]; // [21,21,17]\n const numEdges = edgesFwd.length;\n const keypoints = new Array(numParts);\n // Start a new detection instance at the position of the root.\n const rootPoint = utils.getImageCoords(root.part, outputStride, offsets);\n keypoints[root.part.id] = {\n score: root.score,\n part: utils.partNames[root.part.id] as BodyLandmark,\n position: rootPoint,\n };\n // Decode the part positions upwards in the tree, following the backward displacements.\n for (let edge = numEdges - 1; edge >= 0; --edge) {\n const sourceId = edgesFwd[edge];\n const targetId = edgesBwd[edge];\n if (keypoints[sourceId] && !keypoints[targetId]) {\n keypoints[targetId] = traverse(edge, keypoints[sourceId], targetId, scores, offsets, displacementsBwd);\n }\n }\n // Decode the part positions downwards in the tree, following the forward displacements.\n for (let edge = 0; edge < numEdges; ++edge) {\n const sourceId = edgesBwd[edge];\n const targetId = edgesFwd[edge];\n if (keypoints[sourceId] && !keypoints[targetId]) {\n keypoints[targetId] = traverse(edge, keypoints[sourceId], targetId, scores, offsets, displacementsFwd);\n }\n }\n return keypoints;\n}\n\nfunction scoreIsMaximumInLocalWindow(keypointId, score: number, heatmapY: number, heatmapX: number, scores) {\n const [height, width]: [number, number] = scores.shape;\n let localMaximum = true;\n const yStart = Math.max(heatmapY - localMaximumRadius, 0);\n const yEnd = Math.min(heatmapY + localMaximumRadius + 1, height);\n for (let yCurrent = yStart; yCurrent < yEnd; ++yCurrent) {\n const xStart = Math.max(heatmapX - localMaximumRadius, 0);\n const xEnd = Math.min(heatmapX + localMaximumRadius + 1, width);\n for (let xCurrent = xStart; xCurrent < xEnd; ++xCurrent) {\n if (scores.get(yCurrent, xCurrent, keypointId) > score) {\n localMaximum = false;\n break;\n }\n }\n if (!localMaximum) break;\n }\n return localMaximum;\n}\n\nexport function buildPartWithScoreQueue(minConfidence, scores) {\n const [height, width, numKeypoints] = scores.shape;\n const queue = new utils.MaxHeap(height * width * numKeypoints, ({ score }) => score);\n for (let heatmapY = 0; heatmapY < height; ++heatmapY) {\n for (let heatmapX = 0; heatmapX < width; ++heatmapX) {\n for (let keypointId = 0; keypointId < numKeypoints; ++keypointId) {\n const score = scores.get(heatmapY, heatmapX, keypointId);\n // Only consider parts with score greater or equal to threshold as root candidates.\n if (score < minConfidence) continue;\n // Only consider keypoints whose score is maximum in a local window.\n if (scoreIsMaximumInLocalWindow(keypointId, score, heatmapY, heatmapX, scores)) queue.enqueue({ score, part: { heatmapY, heatmapX, id: keypointId } });\n }\n }\n }\n return queue;\n}\n\nfunction withinRadius(poses, { x, y }, keypointId) {\n return poses.some(({ keypoints }) => {\n const correspondingKeypoint = keypoints[keypointId]?.position;\n if (!correspondingKeypoint) return false;\n return utils.squaredDistance(y, x, correspondingKeypoint.y, correspondingKeypoint.x) <= squaredNmsRadius;\n });\n}\n\nfunction getInstanceScore(existingPoses, keypoints) {\n const notOverlappedKeypointScores = keypoints.reduce((result, { position, score }, keypointId) => {\n if (!withinRadius(existingPoses, position, keypointId)) result += score;\n return result;\n }, 0.0);\n return notOverlappedKeypointScores / keypoints.length;\n}\n\nexport function decode(offsets, scores, displacementsFwd, displacementsBwd, maxDetected, minConfidence) {\n const poses: { keypoints, box: Box, score: number }[] = [];\n const queue = buildPartWithScoreQueue(minConfidence, scores);\n // Generate at most maxDetected object instances per image in decreasing root part score order.\n while (poses.length < maxDetected && !queue.empty()) {\n // The top element in the queue is the next root candidate.\n const root = queue.dequeue();\n // Part-based non-maximum suppression: We reject a root candidate if it is within a disk of `nmsRadius` pixels from the corresponding part of a previously detected instance.\n // @ts-ignore this one is tree walk\n const rootImageCoords = utils.getImageCoords(root.part, outputStride, offsets);\n // @ts-ignore this one is tree walk\n if (withinRadius(poses, rootImageCoords, root.part.id)) continue;\n // Else start a new detection instance at the position of the root.\n let keypoints = decodePose(root, scores, offsets, displacementsFwd, displacementsBwd);\n keypoints = keypoints.filter((a) => a.score > minConfidence);\n const score = getInstanceScore(poses, keypoints);\n const box = utils.getBoundingBox(keypoints);\n if (score > minConfidence) poses.push({ keypoints, box, score: Math.round(100 * score) / 100 });\n }\n return poses;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n /** posenet is mostly obsolete\n * caching is not implemented\n */\n if (!model?.['executor']) return [];\n const res = tf.tidy(() => {\n if (!model.inputs[0].shape) return [];\n const resized = tf.image.resizeBilinear(input, [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n const normalized = tf.sub(tf.div(tf.cast(resized, 'float32'), 127.5), 1.0);\n const results: Tensor[] = model.execute(normalized, poseNetOutputs) as Tensor[];\n const results3d = results.map((y) => tf.squeeze(y, [0]));\n results3d[1] = tf.sigmoid(results3d[1]); // apply sigmoid on scores\n return results3d;\n });\n\n const buffers = await Promise.all(res.map((tensor: Tensor) => tensor.buffer()));\n for (const t of res) tf.dispose(t);\n\n const decoded = decode(buffers[0], buffers[1], buffers[2], buffers[3], config.body.maxDetected, config.body.minConfidence);\n if (!model.inputs[0].shape) return [];\n const scaled = utils.scalePoses(decoded, [input.shape[1], input.shape[2]], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n return scaled;\n}\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.body.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n", "/**\n * Image segmentation for body detection model\n *\n * Based on:\n * - [**Robust Video Matting**](https://github.com/PeterL1n/RobustVideoMatting)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\n\n// internal state varaibles\nconst outputNodes = ['fgr', 'pha', 'r1o', 'r2o', 'r3o', 'r4o'];\nconst t: Record = {}; // contains input tensor and recurrent states\nlet ratio = 0;\n\nfunction init(config: Config) {\n tf.dispose([t.r1i, t.r2i, t.r3i, t.r4i, t.downsample_ratio]);\n t.r1i = tf.tensor(0.0);\n t.r2i = tf.tensor(0.0);\n t.r3i = tf.tensor(0.0);\n t.r4i = tf.tensor(0.0);\n ratio = config.segmentation.ratio || 0.5;\n t.downsample_ratio = tf.tensor(ratio); // initialize downsample ratio\n}\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.segmentation.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n init(config);\n return model;\n}\n\nconst normalize = (r: Tensor): Tensor => tf.tidy(() => {\n const squeeze = tf.squeeze(r, ([0]));\n const mul = tf.mul(squeeze, constants.tf255);\n const cast = tf.cast(mul, 'int32');\n return cast;\n});\n\nfunction getRGBA(fgr: Tensor | null, pha: Tensor | null): Tensor { // gets rgba // either fgr or pha must be present\n const rgb = fgr\n ? normalize(fgr) // normalize and use value\n : tf.fill([pha!.shape[1] || 0, pha!.shape[2] || 0, 3], 255, 'int32'); // eslint-disable-line @typescript-eslint/no-non-null-assertion\n const a = pha\n ? normalize(pha) // normalize and use value\n : tf.fill([fgr!.shape[1] || 0, fgr!.shape[2] || 0, 1], 255, 'int32'); // eslint-disable-line @typescript-eslint/no-non-null-assertion\n const rgba = tf.concat([rgb, a], -1);\n tf.dispose([rgb, a]);\n return rgba;\n}\n\nfunction getState(state: Tensor): Tensor { // gets internal recurrent states\n return tf.tidy(() => {\n const r: Record = {};\n r.unstack = tf.unstack(state, -1);\n r.concat = tf.concat(r.unstack, 1);\n r.split = tf.split(r.concat, 4, 1);\n r.stack = tf.concat(r.split, 2);\n r.squeeze = tf.squeeze(r.stack, [0]);\n r.expand = tf.expandDims(r.squeeze, -1);\n r.add = tf.add(r.expand, 1);\n r.mul = tf.mul(r.add, 127.5);\n r.cast = tf.cast(r.mul, 'int32');\n r.tile = tf.tile(r.cast, [1, 1, 3]);\n r.alpha = tf.fill([(r.tile as Tensor).shape[0] || 0, (r.tile as Tensor).shape[1] || 0, 1], 255, 'int32'); // eslint-disable-line @typescript-eslint/no-unnecessary-type-assertion\n return tf.concat([r.tile, r.alpha], -1);\n });\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model) model = await load(config);\n if (!model?.['executor']) return null;\n // const expand = tf.expandDims(input, 0);\n t.src = tf.div(input, 255);\n if (ratio !== config.segmentation.ratio) init(config); // reinitialize recurrent states if requested downsample ratio changed\n const [fgr, pha, r1o, r2o, r3o, r4o] = await model.executeAsync(t, outputNodes) as Tensor[]; // execute model\n let rgba: Tensor;\n switch (config.segmentation.mode || 'default') {\n case 'default':\n rgba = getRGBA(fgr, pha);\n break;\n case 'alpha':\n rgba = getRGBA(null, pha);\n break;\n case 'foreground':\n rgba = getRGBA(fgr, null);\n break;\n case 'state':\n rgba = getState(r1o); // can view any internal recurrent state r10, r20, r3o, r4o\n break;\n default:\n rgba = tf.tensor(0);\n }\n tf.dispose([t.src, fgr, pha, t.r1i, t.r2i, t.r3i, t.r4i]);\n [t.r1i, t.r2i, t.r3i, t.r4i] = [r1o, r2o, r3o, r4o]; // update recurrent states\n return rgba;\n}\n", "/**\n * Image segmentation for body detection model\n *\n * Based on:\n * - [**MediaPipe Selfie**](https://drive.google.com/file/d/1dCfozqknMa068vVsO2j_1FgZkW_e3VWv/preview)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.segmentation.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model) model = await load(config);\n if (!model?.['executor'] || !model?.inputs?.[0].shape) return null; // something is wrong with the model\n const t: Record = {};\n t.resize = tf.image.resizeBilinear(input, [model.inputs[0].shape ? model.inputs[0].shape[1] : 0, model.inputs[0].shape ? model.inputs[0].shape[2] : 0], false);\n t.norm = tf.div(t.resize, constants.tf255);\n t.res = model.execute(t.norm) as Tensor;\n t.squeeze = tf.squeeze(t.res, [0]); // meet.shape:[1,256,256,1], selfie.shape:[1,144,256,2]\n t.alpha = tf.image.resizeBilinear(t.squeeze as Tensor4D, [input.shape[1] || 0, input.shape[2] || 0]); // model selfie has a single channel that we can use directly\n t.mul = tf.mul(t.alpha, constants.tf255);\n let rgba: Tensor;\n switch (config.segmentation.mode || 'default') {\n case 'default':\n t.input = tf.squeeze(input);\n t.concat = tf.concat([t.input, t.mul], -1);\n rgba = tf.cast(t.concat, 'int32'); // combined original with alpha\n break;\n case 'alpha':\n rgba = tf.cast(t.mul, 'int32'); // just get alpha value from model\n break;\n default:\n rgba = tf.tensor(0);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return rgba;\n}\n", "/**\n * Analyze detection Results and sort&combine them into per-person view\n */\n\nimport type { FaceResult, BodyResult, HandResult, GestureResult, PersonResult, Box } from '../result';\n\nexport function join(faces: FaceResult[], bodies: BodyResult[], hands: HandResult[], gestures: GestureResult[], shape: number[] | undefined): PersonResult[] {\n let id = 0;\n const persons: PersonResult[] = [];\n for (const face of faces) { // person is defined primarily by face and then we append other objects as found\n const person: PersonResult = { id: id++, face, body: null, hands: { left: null, right: null }, gestures: [], box: [0, 0, 0, 0] };\n for (const body of bodies) {\n if (face.box[0] > body.box[0] // x within body\n && face.box[0] < body.box[0] + body.box[2]\n && face.box[1] + face.box[3] > body.box[1] // y within body\n && face.box[1] + face.box[3] < body.box[1] + body.box[3]) {\n person.body = body;\n }\n }\n if (person.body) { // only try to join hands if body is found\n for (const hand of hands) {\n if (hand.box[0] + hand.box[2] > person.body.box[0] // x within body for left hand\n && hand.box[0] + hand.box[2] < person.body.box[0] + person.body.box[2]\n && hand.box[1] + hand.box[3] > person.body.box[1] // x within body for left hand\n && hand.box[1] + hand.box[3] < person.body.box[1] + person.body.box[3]) {\n if (person.hands) person.hands.left = hand;\n }\n if (hand.box[0] < person.body.box[0] + person.body.box[2] // x within body for right hand\n && hand.box[0] > person.body.box[0]\n && hand.box[1] + hand.box[3] > person.body.box[1] // x within body for right hand\n && hand.box[1] + hand.box[3] < person.body.box[1] + person.body.box[3]) {\n if (person.hands) person.hands.right = hand;\n }\n }\n }\n for (const gesture of gestures) { // append all gestures according to ids\n if (gesture['face'] !== undefined && gesture['face'] === face.id) person.gestures.push(gesture);\n else if (gesture['iris'] !== undefined && gesture['iris'] === face.id) person.gestures.push(gesture);\n else if (gesture['body'] !== undefined && gesture['body'] === person.body?.id) person.gestures.push(gesture);\n else if (gesture['hand'] !== undefined && gesture['hand'] === person.hands.left?.id) person.gestures.push(gesture);\n else if (gesture['hand'] !== undefined && gesture['hand'] === person.hands.right?.id) person.gestures.push(gesture);\n }\n\n // create new overarching box from all boxes belonging to person\n const x: number[] = [];\n const y: number[] = [];\n const extractXY = (box: Box | undefined) => { // extract all [x, y] coordinates from boxes [x, y, width, height]\n if (box && box.length === 4) {\n x.push(box[0], box[0] + box[2]);\n y.push(box[1], box[1] + box[3]);\n }\n };\n extractXY(person.face.box);\n extractXY(person.body?.box);\n extractXY(person.hands.left?.box);\n extractXY(person.hands.right?.box);\n const minX = Math.min(...x);\n const minY = Math.min(...y);\n person.box = [minX, minY, Math.max(...x) - minX, Math.max(...y) - minY]; // create new overarching box\n\n // shape is known so we calculate boxRaw as well\n if (shape?.[1] && shape?.[2]) person.boxRaw = [person.box[0] / shape[2], person.box[1] / shape[1], person.box[2] / shape[2], person.box[3] / shape[1]];\n\n persons.push(person);\n }\n return persons;\n}\n", "/**\n * Embedded sample images used during warmup in dataURL format\n */\n\n// data:image/jpeg;base64,\nexport const face = `\n/9j/4AAQSkZJRgABAQEAYABgAAD/4QBoRXhpZgAATU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUA\nAAABAAAARgEoAAMAAAABAAIAAAExAAIAAAARAAAATgAAAAAAAABgAAAAAQAAAGAAAAABcGFpbnQu\nbmV0IDQuMi4xMwAA/9sAQwAGBAUGBQQGBgUGBwcGCAoQCgoJCQoUDg8MEBcUGBgXFBYWGh0lHxob\nIxwWFiAsICMmJykqKRkfLTAtKDAlKCko/9sAQwEHBwcKCAoTCgoTK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LUf5PC+bfttS0q8q3p9W/wBrRMdpUZuKdN99nzvFqPbTVz7nD8OKs+do2/mW3h4D7Xaq\nZnPrtNpqz35aRaYOHY9Zk4pNt9rR+rl6zi+OnS+WN57Rv1lXp/YrNaYtruL6zNPnGO3hxP6O5w/2\nf0HDuun09Yv55Le9afznqcOvO4tBreMTHu30unnva0bWt8on+70nDuE4OHYYx4Kbesz3tPrMuhGO\nIjpDOKrK9YVpsyiGUQnYGOyUgI2SlAIEmwMWMs9kTAMJYzDOYRMArmGErZhhMArlHmzmGMwDE3Ts\nbAbs4swj5pgFkSziVcM4BZEsolXDKAZwyhjCYBkACQhIAAAAAAAJAAAAAAAAAAAAAAAAAAAShIAA\nAAAAAAJAAAAAAAAAAAAAABAJEAAAAAAAAAAAAAAAIEoBKAAAAAAAAAAAAAAABAlAAAAAAAIAAAAA\nBAkBAkBAkBAlACEgMZjdjbFW8bWrEx8YWANb6Fp+bfwab+vLDKMFK9qxH5L0bAr8OPRPKz2AY7J2\nSbAjYZAI2E7AIEgIEgIEgMdkSy2NgY7MdlmyNoBXsxmFuyNgVTVjNV3KjlBRNTlXTVHKCrlIqt5T\nlBhEMohlFerLlBjEMohMVTEARDKCITsAk2AEgAAAkAAAAAAAAAAAAAAAAAAAAAAAASAAAAAAAAD/\n2Q==`;\n", "/**\n * Warmup algorithm that uses embedded images to exercise loaded models for faster future inference\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now, mergeDeep } from './util/util';\nimport * as sample from './sample';\nimport * as image from './image/image';\nimport * as backend from './tfjs/backend';\nimport { env } from './util/env';\nimport { empty, Result } from './result';\nimport type { Config } from './config';\nimport type { Human } from './human';\nimport type { Tensor, DataType } from './tfjs/types';\n\nasync function warmupBitmap(instance: Human): Promise {\n const b64toBlob = (base64: string, type = 'application/octet-stream') => fetch(`data:${type};base64,${base64}`).then((res) => res.blob());\n let blob: Blob | null;\n let res: Result | undefined;\n switch (instance.config.warmup) {\n case 'face': blob = await b64toBlob(sample.face); break;\n case 'body':\n case 'full': blob = await b64toBlob(sample.body); break;\n default: blob = null;\n }\n if (blob) {\n const bitmap = await createImageBitmap(blob);\n res = await instance.detect(bitmap, instance.config);\n bitmap.close();\n }\n return res;\n}\n\nasync function warmupCanvas(instance: Human): Promise {\n return new Promise((resolve) => {\n let src: string;\n // let size = 0;\n switch (instance.config.warmup) {\n case 'face':\n // size = 256;\n src = 'data:image/jpeg;base64,' + sample.face;\n break;\n case 'full':\n case 'body':\n // size = 1200;\n src = 'data:image/jpeg;base64,' + sample.body;\n break;\n default:\n src = '';\n }\n // src = encodeURI('../assets/human-sample-upper.jpg');\n let img: HTMLImageElement;\n if (typeof Image !== 'undefined') img = new Image();\n // @ts-ignore env.image is an external monkey-patch\n else if (env.Image) img = new env.Image();\n else {\n resolve(undefined);\n return;\n }\n img.onload = async () => {\n const canvas = image.canvas(img.naturalWidth, img.naturalHeight);\n if (!canvas) {\n log('Warmup: Canvas not found');\n resolve(undefined);\n } else {\n const ctx = canvas.getContext('2d') as CanvasRenderingContext2D;\n if (ctx) ctx.drawImage(img, 0, 0);\n // const data = ctx?.getImageData(0, 0, canvas.height, canvas.width);\n const tensor = await instance.image(canvas, true);\n const res = tensor.tensor ? await instance.detect(tensor.tensor, instance.config) : undefined;\n resolve(res);\n }\n };\n if (src) img.src = src;\n else resolve(undefined);\n });\n}\n\nasync function warmupNode(instance: Human): Promise {\n const atob = (str: string) => Buffer.from(str, 'base64');\n let img;\n if (instance.config.warmup === 'face') img = atob(sample.face);\n else img = atob(sample.body);\n let res: Result;\n if (('node' in tf) && (tf.getBackend() === 'tensorflow')) {\n // @ts-ignore\n const data: Tensor = tf['node'].decodeJpeg(img); // eslint-disable-line import/namespace\n const expanded: Tensor = tf.expandDims(data, 0);\n instance.tf.dispose(data);\n // log('Input:', expanded);\n res = await instance.detect(expanded, instance.config);\n instance.tf.dispose(expanded);\n } else {\n if (instance.config.debug) log('Warmup tfjs-node not loaded');\n /*\n const input = await canvasJS.loadImage(img);\n const canvas = canvasJS.createCanvas(input.width, input.height);\n const ctx = canvas.getContext('2d');\n ctx.drawImage(img, 0, 0, input.width, input.height);\n res = await instance.detect(input, instance.config);\n */\n }\n // @ts-ignore\n return res;\n}\n\nasync function runInference(instance: Human) {\n let res: Result | undefined;\n if (typeof createImageBitmap === 'function') res = await warmupBitmap(instance);\n else if ((typeof Image !== 'undefined') || (env.Canvas !== undefined)) res = await warmupCanvas(instance);\n else res = await warmupNode(instance);\n return res;\n}\n\n/** Runs pre-compile on all loaded models */\nexport async function runCompile(instance: Human) {\n // @ts-ignore private property\n if (!tf.env().flagRegistry.ENGINE_COMPILE_ONLY) return; // tfjs does not support compile-only inference\n const backendType = tf.getBackend();\n const webGLBackend = tf.backend();\n if ((backendType !== 'webgl' && backendType !== 'humangl') || !webGLBackend?.['checkCompileCompletion']) {\n // log('compile pass: skip');\n return;\n }\n tf.env().set('ENGINE_COMPILE_ONLY', true);\n const numTensorsStart = tf.engine().state.numTensors;\n const compiledModels: string[] = [];\n for (const [modelName, model] of Object.entries(instance.models.models)) {\n if (!model) continue;\n const shape = (model?.modelSignature && model?.inputs?.[0]?.shape) ? [...model.inputs[0].shape] : [1, 64, 64, 3];\n const dtype: DataType = (model?.modelSignature && model?.inputs?.[0]?.dtype) ? model.inputs[0].dtype : 'float32';\n for (let dim = 0; dim < shape.length; dim++) {\n if (shape[dim] === -1) shape[dim] = dim === 0 ? 1 : 64; // override batch number and any dynamic dimensions\n }\n const tensor = tf.zeros(shape, dtype);\n try {\n const res = model.execute(tensor);\n compiledModels.push(modelName);\n if (Array.isArray(res)) res.forEach((t) => tf.dispose(t));\n else tf.dispose(res);\n } catch {\n if (instance.config.debug) log('compile fail model:', modelName);\n }\n tf.dispose(tensor);\n }\n const kernels = await webGLBackend['checkCompileCompletionAsync']();\n webGLBackend['getUniformLocations']();\n if (instance.config.debug) log('compile pass:', { models: compiledModels, kernels: kernels.length });\n tf.env().set('ENGINE_COMPILE_ONLY', false);\n const numTensorsEnd = tf.engine().state.numTensors;\n if ((numTensorsEnd - numTensorsStart) > 0) log('tensor leak:', numTensorsEnd - numTensorsStart);\n}\n\n/** Warmup method pre-initializes all configured models for faster inference\n * - can take significant time on startup\n * - only used in browser environments for `webgl` and `humangl` backends\n * @param userConfig?: Config\n*/\nexport async function warmup(instance: Human, userConfig?: Partial): Promise {\n await backend.check(instance, false);\n const t0 = now();\n instance.state = 'warmup';\n if (userConfig) instance.config = mergeDeep(instance.config, userConfig) as Config;\n if (!instance.config.warmup || instance.config.warmup.length === 0 || instance.config.warmup === 'none') {\n return empty();\n }\n return new Promise(async (resolve) => {\n await instance.models.load();\n await runCompile(instance);\n const res = await runInference(instance);\n const t1 = now();\n if (instance.config.debug) log('warmup', instance.config.warmup, Math.round(t1 - t0), 'ms');\n instance.emit('warmup');\n resolve(res);\n });\n}\n", "/**\n * Human main module\n * @default Human Library\n * @summary \n * @author \n * @copyright \n * @license MIT\n */\n\n// module imports\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now, mergeDeep, validate } from './util/util';\nimport { defaults } from './config';\nimport { env, Env } from './util/env';\nimport { WebCam } from './util/webcam';\nimport { setModelLoadOptions } from './tfjs/load';\nimport * as app from '../package.json';\nimport * as backend from './tfjs/backend';\nimport * as draw from './draw/draw';\nimport * as blazepose from './body/blazepose';\nimport * as centernet from './object/centernet';\nimport * as efficientpose from './body/efficientpose';\nimport * as face from './face/face';\nimport * as facemesh from './face/facemesh';\nimport * as gesture from './gesture/gesture';\nimport * as handpose from './hand/handpose';\nimport * as handtrack from './hand/handtrack';\nimport * as image from './image/image';\nimport * as interpolate from './util/interpolate';\nimport * as meet from './segmentation/meet';\nimport * as match from './face/match';\nimport * as models from './models';\nimport * as movenet from './body/movenet';\nimport * as nanodet from './object/nanodet';\nimport * as persons from './util/persons';\nimport * as posenet from './body/posenet';\nimport * as rvm from './segmentation/rvm';\nimport * as selfie from './segmentation/selfie';\nimport * as warmups from './warmup';\n\n// type definitions\nimport { Input, Config, Result, FaceResult, HandResult, BodyResult, ObjectResult, GestureResult, AnyCanvas, empty } from './exports';\nimport type { Tensor, Tensor4D } from './tfjs/types';\n// type exports\nexport * from './exports';\n\n/** **Human** library main class\n *\n * All methods and properties are available only as members of Human class\n *\n * - Configuration object definition: {@link Config}\n * - Results object definition: {@link Result}\n * - Possible inputs: {@link Input}\n *\n * @param userConfig - {@link Config}\n * @returns instance of {@link Human}\n */\nexport class Human {\n /** Current version of Human library in *semver* format */\n version: string;\n\n /** Current configuration\n * - Defaults: [config](https://github.com/vladmandic/human/blob/main/src/config.ts#L262)\n */\n config: Config;\n\n /** Last known result of detect run\n * - Can be accessed anytime after initial detection\n */\n result: Result;\n\n /** Current state of Human library\n * - Can be polled to determine operations that are currently executed\n * - Progresses through: 'config', 'check', 'backend', 'load', 'run:', 'idle'\n */\n state: string;\n\n /** currenty processed image tensor and canvas */\n process: { tensor: Tensor | null, canvas: AnyCanvas | null };\n\n /** Instance of TensorFlow/JS used by Human\n * - Can be embedded or externally provided\n * [TFJS API](https://js.tensorflow.org/api/latest/)\n */\n tf;\n\n /** Object containing environment information used for diagnostics */\n env: Env = env;\n\n /** Draw helper classes that can draw detected objects on canvas using specified draw\n * - canvas: draws input to canvas\n * - options: are global settings for all draw operations, can be overriden for each draw method {@link DrawOptions}\n * - face, body, hand, gesture, object, person: draws detected results as overlays on canvas\n */\n // draw: { canvas: typeof draw.canvas, face: typeof draw.face, body: typeof draw.body, hand: typeof draw.hand, gesture: typeof draw.gesture, object: typeof draw.object, person: typeof draw.person, all: typeof draw.all, options: DrawOptions };\n draw: typeof draw = draw;\n\n /** Face Matching\n * - similarity: compare two face descriptors and return similarity index\n * - distance: compare two face descriptors and return raw calculated differences\n * - find: compare face descriptor to array of face descriptors and return best match\n */\n match: typeof match = match;\n\n /** Currently loaded models\n * @internal\n * {@link models#Models}\n */\n models: models.Models;\n\n /** Container for events dispatched by Human\n * Possible events:\n * - `create`: triggered when Human object is instantiated\n * - `load`: triggered when models are loaded (explicitly or on-demand)\n * - `image`: triggered when input image is processed\n * - `result`: triggered when detection is complete\n * - `warmup`: triggered when warmup is complete\n * - `error`: triggered on some errors\n */\n events: EventTarget | undefined;\n /** Reference face triangualtion array of 468 points, used for triangle references between points */\n faceTriangulation: number[];\n /** Refernce UV map of 468 values, used for 3D mapping of the face mesh */\n faceUVMap: [number, number][];\n /** Performance object that contains values for all recently performed operations */\n performance: Record; // perf members are dynamically defined as needed\n #numTensors: number;\n #analyzeMemoryLeaks: boolean;\n #checkSanity: boolean;\n // definition end\n\n /** Constructor for **Human** library that is futher used for all operations\n * @param userConfig - user configuration object {@link Config}\n */\n constructor(userConfig?: Partial) {\n /*\n defaults.wasmPath = tf.version['tfjs-core'].includes('-') // custom build or official build\n ? 'https://vladmandic.github.io/tfjs/dist/'\n : `https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@${tf.version_core}/dist/`;\n */\n const tfVersion = (tf.version.tfjs || tf.version_core).replace(/-(.*)/, '');\n defaults.wasmPath = `https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@${tfVersion}/dist/`;\n defaults.modelBasePath = env.browser ? '../models/' : 'file://models/';\n this.version = app.version; // expose version property on instance of class\n Object.defineProperty(this, 'version', { value: app.version }); // expose version property directly on class itself\n this.config = JSON.parse(JSON.stringify(defaults));\n Object.seal(this.config);\n this.config.cacheModels = typeof indexedDB !== 'undefined';\n if (userConfig) this.config = mergeDeep(this.config, userConfig);\n setModelLoadOptions(this.config);\n this.tf = tf;\n this.state = 'idle';\n this.#numTensors = 0;\n this.#analyzeMemoryLeaks = false;\n this.#checkSanity = false;\n this.performance = {};\n this.events = (typeof EventTarget !== 'undefined') ? new EventTarget() : undefined;\n // object that contains all initialized models\n this.models = new models.Models(this);\n // reexport draw methods\n draw.init();\n this.result = empty();\n // export access to image processing\n this.process = { tensor: null, canvas: null };\n // export raw access to underlying models\n this.faceTriangulation = facemesh.triangulation;\n this.faceUVMap = facemesh.uvmap;\n // init model validation\n models.validateModel(this, null, '');\n // include platform info\n this.emit('create');\n if (this.config.debug || this.env.browser) log(`version: ${this.version}`);\n if (this.config.debug) log(`tfjs version: ${this.tf.version['tfjs-core']}`);\n const envTemp = JSON.parse(JSON.stringify(this.env));\n delete envTemp.kernels;\n delete envTemp.initial;\n delete envTemp.perfadd;\n if (this.config.debug) log('environment:', envTemp);\n }\n\n /** internal function to measure tensor leaks */\n analyze = (...msg: string[]) => {\n if (!this.#analyzeMemoryLeaks) return;\n const currentTensors = this.tf.engine().state.numTensors;\n const previousTensors = this.#numTensors;\n this.#numTensors = currentTensors;\n const leaked = currentTensors - previousTensors;\n if (leaked !== 0) log(...msg, leaked);\n };\n\n /** internal function for quick sanity check on inputs @hidden */\n #sanity = (input: Input): null | string => {\n if (!this.#checkSanity) return null;\n if (!input) return 'input is not defined';\n if (this.env.node && !(input instanceof tf.Tensor)) return 'input must be a tensor';\n try {\n this.tf.getBackend();\n } catch {\n return 'backend not loaded';\n }\n return null;\n };\n\n /** Reset configuration to default values */\n reset(): void {\n const currentBackend = this.config.backend; // save backend;\n this.config = JSON.parse(JSON.stringify(defaults));\n this.config.backend = currentBackend;\n image.reset();\n env.initial = true;\n }\n\n /** Validate current configuration schema */\n validate(userConfig?: Partial) {\n const msgs = validate(defaults, userConfig || this.config);\n if (msgs.length === 0) this.config = mergeDeep(this.config, userConfig) as Config;\n return msgs;\n }\n\n /** Utility wrapper for performance.now() */\n now(): number { // eslint-disable-line class-methods-use-this\n return now();\n }\n\n /** Process input as return canvas and tensor\n *\n * @param input - any input {@link Input}\n * @param getTensor - should image processing also return tensor or just canvas\n * Returns object with `tensor` and `canvas`\n */\n image(input: Input, getTensor: boolean = false) {\n return image.process(input, this.config, getTensor);\n }\n\n /** Segmentation method takes any input and returns RGBA tensor\n * Note: Segmentation is not triggered as part of detect process\n *\n * @param input - {@link Input}\n * Returns tensor which contains image data in RGBA format\n */\n async segmentation(input: Input, userConfig?: Partial): Promise {\n if (userConfig) this.config = mergeDeep(this.config, userConfig) as Config;\n if (!this.config.segmentation.enabled) return null;\n const processed = await image.process(input, this.config);\n if (!processed.tensor) return null;\n let tensor: Tensor | null = null;\n if (this.config.segmentation.modelPath?.includes('rvm')) tensor = await rvm.predict(processed.tensor, this.config);\n if (this.config.segmentation.modelPath?.includes('meet')) tensor = await meet.predict(processed.tensor, this.config);\n if (this.config.segmentation.modelPath?.includes('selfie')) tensor = await selfie.predict(processed.tensor, this.config);\n tf.dispose(processed.tensor);\n return tensor;\n }\n\n /** Compare two input tensors for pixel similarity\n * - use `human.image` to process any valid input and get a tensor that can be used for compare\n * - when passing manually generated tensors:\n * - both input tensors must be in format [1, height, width, 3]\n * - if resolution of tensors does not match, second tensor will be resized to match resolution of the first tensor\n * - return value is pixel similarity score normalized by input resolution and rgb channels\n */\n compare(firstImageTensor: Tensor, secondImageTensor: Tensor): Promise {\n return image.compare(this.config, firstImageTensor, secondImageTensor);\n }\n\n /** Explicit backend initialization\n * - Normally done implicitly during initial load phase\n * - Call to explictly register and initialize TFJS backend without any other operations\n * - Use when changing backend during runtime\n */\n async init(): Promise {\n await backend.check(this, true);\n await this.tf.ready();\n image.reset();\n }\n\n /** WebCam helper methods\n *\n */\n public webcam = new WebCam();\n\n /** Load method preloads all configured models on-demand\n * - Not explicitly required as any required model is load implicitly on it's first run\n *\n * @param userConfig - {@link Config}\n */\n async load(userConfig?: Partial): Promise {\n this.state = 'load';\n const timeStamp = now();\n const count = Object.values(this.models.models).filter((model) => model).length;\n if (userConfig) this.config = mergeDeep(this.config, userConfig) as Config;\n if (this.env.initial) { // print version info on first run and check for correct backend setup\n if (!await backend.check(this, false)) log('error: backend check failed');\n await tf.ready();\n if (this.env.browser) {\n if (this.config.debug) log('configuration:', this.config);\n if (this.config.debug) log('tf flags:', this.tf.ENV.flags);\n }\n }\n\n await this.models.load(this); // actually loads models\n if (this.env.initial && this.config.debug) log('tf engine state:', this.tf.engine().state.numBytes, 'bytes', this.tf.engine().state.numTensors, 'tensors'); // print memory stats on first run\n this.env.initial = false;\n\n const loaded = Object.values(this.models.models).filter((model) => model).length;\n if (loaded !== count) { // number of loaded models changed\n this.models.validate(); // validate kernel ops used by model against current backend\n this.emit('load');\n }\n\n const current = Math.trunc(now() - timeStamp);\n if (current > (this.performance.loadModels || 0)) this.performance.loadModels = this.env.perfadd ? (this.performance.loadModels || 0) + current : current;\n }\n\n /** emit event */\n emit = (event: string) => {\n if (this.events?.dispatchEvent) this.events.dispatchEvent(new Event(event));\n };\n\n /** Runs interpolation using last known result and returns smoothened result\n * Interpolation is based on time since last known result so can be called independently\n *\n * @param result - {@link Result} optional use specific result set to run interpolation on\n * @returns result - {@link Result}\n */\n next(result: Result = this.result): Result {\n return interpolate.calc(result, this.config);\n }\n\n /** Warmup method pre-initializes all configured models for faster inference\n * - can take significant time on startup\n * - only used for `webgl` and `humangl` backends\n * @param userConfig - {@link Config}\n * @returns result - {@link Result}\n */\n async warmup(userConfig?: Partial) {\n const t0 = now();\n const res = await warmups.warmup(this, userConfig);\n const t1 = now();\n this.performance.warmup = Math.trunc(t1 - t0);\n return res;\n }\n\n /** Run detect with tensorflow profiling\n * - result object will contain total exeuction time information for top-20 kernels\n * - actual detection object can be accessed via `human.result`\n */\n async profile(input: Input, userConfig?: Partial): Promise<{ kernel: string, time: number, perc: number }[]> {\n // @ts-ignore profile wraps method return values\n const profile = await this.tf.profile(() => this.detect(input, userConfig));\n const kernels: Record = {};\n let total = 0;\n for (const kernel of profile.kernels) { // sum kernel time values per kernel\n const ms = Number(kernel.kernelTimeMs) || 0;\n if (kernels[kernel.name]) kernels[kernel.name] += ms;\n else kernels[kernel.name] = ms;\n total += ms;\n }\n const kernelArr: { kernel: string, time: number, perc: number }[] = [];\n Object.entries(kernels).forEach((key) => kernelArr.push({ kernel: key[0], time: key[1] as unknown as number, perc: 0 })); // convert to array\n for (const kernel of kernelArr) {\n kernel.perc = Math.round(1000 * kernel.time / total) / 1000;\n kernel.time = Math.round(1000 * kernel.time) / 1000;\n }\n kernelArr.sort((a, b) => b.time - a.time); // sort\n kernelArr.length = 20; // crop\n return kernelArr;\n }\n\n /** Main detection method\n * - Analyze configuration: {@link Config}\n * - Pre-process input: {@link Input}\n * - Run inference for all configured models\n * - Process and return result: {@link Result}\n *\n * @param input - {@link Input}\n * @param userConfig - {@link Config}\n * @returns result - {@link Result}\n */\n async detect(input: Input, userConfig?: Partial): Promise {\n // detection happens inside a promise\n this.state = 'detect';\n return new Promise(async (resolve) => {\n this.state = 'config';\n let timeStamp;\n\n // update configuration\n this.config = mergeDeep(this.config, userConfig) as Config;\n\n // sanity checks\n this.state = 'check';\n const error = this.#sanity(input);\n if (error) {\n log(error, input);\n this.emit('error');\n resolve(empty(error));\n }\n\n const timeStart = now();\n\n // load models if enabled\n await this.load();\n\n timeStamp = now();\n this.state = 'image';\n const img = await image.process(input, this.config) as { canvas: AnyCanvas, tensor: Tensor4D };\n this.process = img;\n this.performance.inputProcess = this.env.perfadd ? (this.performance.inputProcess || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n this.analyze('Get Image:');\n\n if (!img.tensor) {\n if (this.config.debug) log('could not convert input to tensor');\n this.emit('error');\n resolve(empty('could not convert input to tensor'));\n return;\n }\n this.emit('image');\n\n timeStamp = now();\n this.config.skipAllowed = await image.skip(this.config, img.tensor);\n this.config.filter.autoBrightness = (this.config.filter.autoBrightness || false) && this.config.skipAllowed; // disable autoBrightness on scene change\n if (!this.performance.totalFrames) this.performance.totalFrames = 0;\n if (!this.performance.cachedFrames) this.performance.cachedFrames = 0;\n (this.performance.totalFrames)++;\n if (this.config.skipAllowed) this.performance.cachedFrames++;\n this.performance.cacheCheck = this.env.perfadd ? (this.performance.cacheCheck || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n this.analyze('Check Changed:');\n\n // prepare where to store model results\n // keep them with weak typing as it can be promise or not\n let faceRes: FaceResult[] | Promise | never[] = [];\n let bodyRes: BodyResult[] | Promise | never[] = [];\n let handRes: HandResult[] | Promise | never[] = [];\n let objectRes: ObjectResult[] | Promise | never[] = [];\n\n // run face detection followed by all models that rely on face bounding box: face mesh, age, gender, emotion\n this.state = 'detect:face';\n if (this.config.async) {\n faceRes = this.config.face.enabled ? face.detectFace(this, img.tensor) : [];\n if (this.performance.face) delete this.performance.face;\n } else {\n timeStamp = now();\n faceRes = this.config.face.enabled ? await face.detectFace(this, img.tensor) : [];\n this.performance.face = this.env.perfadd ? (this.performance.face || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n\n if (this.config.async && (this.config.body.maxDetected === -1 || this.config.hand.maxDetected === -1)) faceRes = await faceRes; // need face result for auto-detect number of hands or bodies\n\n // run body: can be posenet, blazepose, efficientpose, movenet\n this.analyze('Start Body:');\n this.state = 'detect:body';\n const bodyConfig = this.config.body.maxDetected === -1 ? mergeDeep(this.config, { body: { maxDetected: this.config.face.enabled ? 1 * (faceRes as FaceResult[]).length : 1 } }) : this.config; // autodetect number of bodies\n if (this.config.async) {\n if (this.config.body.modelPath?.includes('posenet')) bodyRes = this.config.body.enabled ? posenet.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('blazepose')) bodyRes = this.config.body.enabled ? blazepose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('efficientpose')) bodyRes = this.config.body.enabled ? efficientpose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('movenet')) bodyRes = this.config.body.enabled ? movenet.predict(img.tensor, bodyConfig) : [];\n if (this.performance.body) delete this.performance.body;\n } else {\n timeStamp = now();\n if (this.config.body.modelPath?.includes('posenet')) bodyRes = this.config.body.enabled ? await posenet.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('blazepose')) bodyRes = this.config.body.enabled ? await blazepose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('efficientpose')) bodyRes = this.config.body.enabled ? await efficientpose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('movenet')) bodyRes = this.config.body.enabled ? await movenet.predict(img.tensor, bodyConfig) : [];\n this.performance.body = this.env.perfadd ? (this.performance.body || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n this.analyze('End Body:');\n\n // run handpose\n this.analyze('Start Hand:');\n this.state = 'detect:hand';\n const handConfig = this.config.hand.maxDetected === -1 ? mergeDeep(this.config, { hand: { maxDetected: this.config.face.enabled ? 2 * (faceRes as FaceResult[]).length : 1 } }) : this.config; // autodetect number of hands\n if (this.config.async) {\n if (this.config.hand.detector?.modelPath?.includes('handdetect')) handRes = this.config.hand.enabled ? handpose.predict(img.tensor, handConfig) : [];\n else if (this.config.hand.detector?.modelPath?.includes('handtrack')) handRes = this.config.hand.enabled ? handtrack.predict(img.tensor, handConfig) : [];\n if (this.performance.hand) delete this.performance.hand;\n } else {\n timeStamp = now();\n if (this.config.hand.detector?.modelPath?.includes('handdetect')) handRes = this.config.hand.enabled ? await handpose.predict(img.tensor, handConfig) : [];\n else if (this.config.hand.detector?.modelPath?.includes('handtrack')) handRes = this.config.hand.enabled ? await handtrack.predict(img.tensor, handConfig) : [];\n this.performance.hand = this.env.perfadd ? (this.performance.hand || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n this.analyze('End Hand:');\n\n // run object detection\n this.analyze('Start Object:');\n this.state = 'detect:object';\n if (this.config.async) {\n if (this.config.object.modelPath?.includes('nanodet')) objectRes = this.config.object.enabled ? nanodet.predict(img.tensor, this.config) : [];\n else if (this.config.object.modelPath?.includes('centernet')) objectRes = this.config.object.enabled ? centernet.predict(img.tensor, this.config) : [];\n if (this.performance.object) delete this.performance.object;\n } else {\n timeStamp = now();\n if (this.config.object.modelPath?.includes('nanodet')) objectRes = this.config.object.enabled ? await nanodet.predict(img.tensor, this.config) : [];\n else if (this.config.object.modelPath?.includes('centernet')) objectRes = this.config.object.enabled ? await centernet.predict(img.tensor, this.config) : [];\n this.performance.object = this.env.perfadd ? (this.performance.object || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n this.analyze('End Object:');\n\n // if async wait for results\n this.state = 'detect:await';\n if (this.config.async) [faceRes, bodyRes, handRes, objectRes] = await Promise.all([faceRes, bodyRes, handRes, objectRes]);\n\n // run gesture analysis last\n this.state = 'detect:gesture';\n let gestureRes: GestureResult[] = [];\n if (this.config.gesture.enabled) {\n timeStamp = now();\n gestureRes = [...gesture.face(faceRes as FaceResult[]), ...gesture.body(bodyRes as BodyResult[]), ...gesture.hand(handRes as HandResult[]), ...gesture.iris(faceRes as FaceResult[])];\n if (!this.config.async) this.performance.gesture = this.env.perfadd ? (this.performance.gesture || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n else if (this.performance.gesture) delete this.performance.gesture;\n }\n\n this.performance.total = this.env.perfadd ? (this.performance.total || 0) + Math.trunc(now() - timeStart) : Math.trunc(now() - timeStart);\n const shape = this.process.tensor?.shape || [0, 0, 0, 0];\n this.result = {\n face: faceRes as FaceResult[],\n body: bodyRes as BodyResult[],\n hand: handRes as HandResult[],\n gesture: gestureRes,\n object: objectRes as ObjectResult[],\n performance: this.performance,\n canvas: this.process.canvas,\n timestamp: Date.now(),\n error: null,\n width: shape[2],\n height: shape[1],\n get persons() { return persons.join(faceRes as FaceResult[], bodyRes as BodyResult[], handRes as HandResult[], gestureRes, shape); },\n };\n\n // finally dispose input tensor\n tf.dispose(img.tensor);\n\n // log('Result:', result);\n this.emit('detect');\n this.state = 'idle';\n resolve(this.result);\n });\n }\n\n /** Helper function\n * @param ms - sleep time in miliseconds\n */\n async sleep(ms: number): Promise { // eslint-disable-line class-methods-use-this\n return new Promise((resolve) => { setTimeout(resolve, ms); });\n }\n\n /** internal structure that keeps track of processed videos @hidden */\n #loops: Record = {};\n /** Continously detect video frames\n * @param element - HTMLVideoElement input\n * @param run - boolean run continously or stop if already running, default true\n * @param delay - number delay detection between frames for number of miliseconds, default 0\n */\n async video(element: HTMLVideoElement, run: boolean = true, delay: number = 0) {\n if (run) {\n if (!this.#loops[element.id]) {\n if (this.config.debug) log('video start', element.id);\n this.#loops[element.id] = true;\n }\n if (!element.paused && this.#loops[element.id] && (element.readyState >= 2)) await this.detect(element);\n if (delay > 0) await this.sleep(delay);\n if (this.#loops[element.id]) requestAnimationFrame(() => this.video(element, run, delay));\n } else {\n if (this.config.debug) log('video stop', element.id);\n this.#loops[element.id] = false;\n }\n }\n}\n\n/** Class Human as default export */\n/* eslint no-restricted-exports: [\"off\", { \"restrictedNamedExports\": [\"default\"] }] */\nexport { Human as default, match, draw, models };\n"], + "sourcesContent": ["/*\n Human\n homepage: \n author: '\n*/\n\nvar wG=Object.create;var QC=Object.defineProperty;var SG=Object.getOwnPropertyDescriptor;var IG=Object.getOwnPropertyNames;var vG=Object.getPrototypeOf,kG=Object.prototype.hasOwnProperty;var qt=(r,t)=>()=>(t||r((t={exports:{}}).exports,t),t.exports),qe=(r,t)=>{for(var e in t)QC(r,e,{get:t[e],enumerable:!0})},NG=(r,t,e,o)=>{if(t&&typeof t==\"object\"||typeof t==\"function\")for(let n of IG(t))!kG.call(r,n)&&n!==e&&QC(r,n,{get:()=>t[n],enumerable:!(o=SG(t,n))||o.enumerable});return r};var Kp=(r,t,e)=>(e=r!=null?wG(vG(r)):{},NG(t||!r||!r.__esModule?QC(e,\"default\",{value:r,enumerable:!0}):e,r));var V0=qt((tle,z0)=>{z0.exports=Nt;var No=null;try{No=new WebAssembly.Instance(new WebAssembly.Module(new Uint8Array([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(r){}function Nt(r,t,e){this.low=r|0,this.high=t|0,this.unsigned=!!e}Nt.prototype.__isLong__;Object.defineProperty(Nt.prototype,\"__isLong__\",{value:!0});function Wr(r){return(r&&r.__isLong__)===!0}Nt.isLong=Wr;var R0={},D0={};function Bu(r,t){var e,o,n;return t?(r>>>=0,(n=0<=r&&r<256)&&(o=D0[r],o)?o:(e=Tt(r,(r|0)<0?-1:0,!0),n&&(D0[r]=e),e)):(r|=0,(n=-128<=r&&r<128)&&(o=R0[r],o)?o:(e=Tt(r,r<0?-1:0,!1),n&&(R0[r]=e),e))}Nt.fromInt=Bu;function To(r,t){if(isNaN(r))return t?Lu:_o;if(t){if(r<0)return Lu;if(r>=O0)return B0}else{if(r<=-F0)return Vr;if(r+1>=F0)return L0}return r<0?To(-r,t).neg():Tt(r%oc|0,r/oc|0,t)}Nt.fromNumber=To;function Tt(r,t,e){return new Nt(r,t,e)}Nt.fromBits=Tt;var Zm=Math.pow;function cw(r,t,e){if(r.length===0)throw Error(\"empty string\");if(r===\"NaN\"||r===\"Infinity\"||r===\"+Infinity\"||r===\"-Infinity\")return _o;if(typeof t==\"number\"?(e=t,t=!1):t=!!t,e=e||10,e<2||360)throw Error(\"interior hyphen\");if(o===0)return cw(r.substring(1),t,e).neg();for(var n=To(Zm(e,8)),s=_o,a=0;a>>0:this.low};de.toNumber=function(){return this.unsigned?(this.high>>>0)*oc+(this.low>>>0):this.high*oc+(this.low>>>0)};de.toString=function(t){if(t=t||10,t<2||36>>0,c=u.toString(t);if(a=p,a.isZero())return c+i;for(;c.length<6;)c=\"0\"+c;i=\"\"+c+i}};de.getHighBits=function(){return this.high};de.getHighBitsUnsigned=function(){return this.high>>>0};de.getLowBits=function(){return this.low};de.getLowBitsUnsigned=function(){return this.low>>>0};de.getNumBitsAbs=function(){if(this.isNegative())return this.eq(Vr)?64:this.neg().getNumBitsAbs();for(var t=this.high!=0?this.high:this.low,e=31;e>0&&!(t&1<=0};de.isOdd=function(){return(this.low&1)===1};de.isEven=function(){return(this.low&1)===0};de.equals=function(t){return Wr(t)||(t=Fs(t)),this.unsigned!==t.unsigned&&this.high>>>31===1&&t.high>>>31===1?!1:this.high===t.high&&this.low===t.low};de.eq=de.equals;de.notEquals=function(t){return!this.eq(t)};de.neq=de.notEquals;de.ne=de.notEquals;de.lessThan=function(t){return this.comp(t)<0};de.lt=de.lessThan;de.lessThanOrEqual=function(t){return this.comp(t)<=0};de.lte=de.lessThanOrEqual;de.le=de.lessThanOrEqual;de.greaterThan=function(t){return this.comp(t)>0};de.gt=de.greaterThan;de.greaterThanOrEqual=function(t){return this.comp(t)>=0};de.gte=de.greaterThanOrEqual;de.ge=de.greaterThanOrEqual;de.compare=function(t){if(Wr(t)||(t=Fs(t)),this.eq(t))return 0;var e=this.isNegative(),o=t.isNegative();return e&&!o?-1:!e&&o?1:this.unsigned?t.high>>>0>this.high>>>0||t.high===this.high&&t.low>>>0>this.low>>>0?-1:1:this.sub(t).isNegative()?-1:1};de.comp=de.compare;de.negate=function(){return!this.unsigned&&this.eq(Vr)?Vr:this.not().add(rc)};de.neg=de.negate;de.add=function(t){Wr(t)||(t=Fs(t));var e=this.high>>>16,o=this.high&65535,n=this.low>>>16,s=this.low&65535,a=t.high>>>16,i=t.high&65535,p=t.low>>>16,u=t.low&65535,c=0,l=0,m=0,d=0;return d+=s+u,m+=d>>>16,d&=65535,m+=n+p,l+=m>>>16,m&=65535,l+=o+i,c+=l>>>16,l&=65535,c+=e+a,c&=65535,Tt(m<<16|d,c<<16|l,this.unsigned)};de.subtract=function(t){return Wr(t)||(t=Fs(t)),this.add(t.neg())};de.sub=de.subtract;de.multiply=function(t){if(this.isZero())return _o;if(Wr(t)||(t=Fs(t)),No){var e=No.mul(this.low,this.high,t.low,t.high);return Tt(e,No.get_high(),this.unsigned)}if(t.isZero())return _o;if(this.eq(Vr))return t.isOdd()?Vr:_o;if(t.eq(Vr))return this.isOdd()?Vr:_o;if(this.isNegative())return t.isNegative()?this.neg().mul(t.neg()):this.neg().mul(t).neg();if(t.isNegative())return this.mul(t.neg()).neg();if(this.lt(P0)&&t.lt(P0))return To(this.toNumber()*t.toNumber(),this.unsigned);var o=this.high>>>16,n=this.high&65535,s=this.low>>>16,a=this.low&65535,i=t.high>>>16,p=t.high&65535,u=t.low>>>16,c=t.low&65535,l=0,m=0,d=0,f=0;return f+=a*c,d+=f>>>16,f&=65535,d+=s*c,m+=d>>>16,d&=65535,d+=a*u,m+=d>>>16,d&=65535,m+=n*c,l+=m>>>16,m&=65535,m+=s*u,l+=m>>>16,m&=65535,m+=a*p,l+=m>>>16,m&=65535,l+=o*c+n*u+s*p+a*i,l&=65535,Tt(d<<16|f,l<<16|m,this.unsigned)};de.mul=de.multiply;de.divide=function(t){if(Wr(t)||(t=Fs(t)),t.isZero())throw Error(\"division by zero\");if(No){if(!this.unsigned&&this.high===-2147483648&&t.low===-1&&t.high===-1)return this;var e=(this.unsigned?No.div_u:No.div_s)(this.low,this.high,t.low,t.high);return Tt(e,No.get_high(),this.unsigned)}if(this.isZero())return this.unsigned?Lu:_o;var o,n,s;if(this.unsigned){if(t.unsigned||(t=t.toUnsigned()),t.gt(this))return Lu;if(t.gt(this.shru(1)))return M0;s=Lu}else{if(this.eq(Vr)){if(t.eq(rc)||t.eq(pw))return Vr;if(t.eq(Vr))return rc;var a=this.shr(1);return o=a.div(t).shl(1),o.eq(_o)?t.isNegative()?rc:pw:(n=this.sub(t.mul(o)),s=o.add(n.div(t)),s)}else if(t.eq(Vr))return this.unsigned?Lu:_o;if(this.isNegative())return t.isNegative()?this.neg().div(t.neg()):this.neg().div(t).neg();if(t.isNegative())return this.div(t.neg()).neg();s=_o}for(n=this;n.gte(t);){o=Math.max(1,Math.floor(n.toNumber()/t.toNumber()));for(var i=Math.ceil(Math.log(o)/Math.LN2),p=i<=48?1:Zm(2,i-48),u=To(o),c=u.mul(t);c.isNegative()||c.gt(n);)o-=p,u=To(o,this.unsigned),c=u.mul(t);u.isZero()&&(u=rc),s=s.add(u),n=n.sub(c)}return s};de.div=de.divide;de.modulo=function(t){if(Wr(t)||(t=Fs(t)),No){var e=(this.unsigned?No.rem_u:No.rem_s)(this.low,this.high,t.low,t.high);return Tt(e,No.get_high(),this.unsigned)}return this.sub(this.div(t).mul(t))};de.mod=de.modulo;de.rem=de.modulo;de.not=function(){return Tt(~this.low,~this.high,this.unsigned)};de.and=function(t){return Wr(t)||(t=Fs(t)),Tt(this.low&t.low,this.high&t.high,this.unsigned)};de.or=function(t){return Wr(t)||(t=Fs(t)),Tt(this.low|t.low,this.high|t.high,this.unsigned)};de.xor=function(t){return Wr(t)||(t=Fs(t)),Tt(this.low^t.low,this.high^t.high,this.unsigned)};de.shiftLeft=function(t){return Wr(t)&&(t=t.toInt()),(t&=63)===0?this:t<32?Tt(this.low<>>32-t,this.unsigned):Tt(0,this.low<>>t|this.high<<32-t,this.high>>t,this.unsigned):Tt(this.high>>t-32,this.high>=0?0:-1,this.unsigned)};de.shr=de.shiftRight;de.shiftRightUnsigned=function(t){if(Wr(t)&&(t=t.toInt()),t&=63,t===0)return this;var e=this.high;if(t<32){var o=this.low;return Tt(o>>>t|e<<32-t,e>>>t,this.unsigned)}else return t===32?Tt(e,0,this.unsigned):Tt(e>>>t-32,0,this.unsigned)};de.shru=de.shiftRightUnsigned;de.shr_u=de.shiftRightUnsigned;de.toSigned=function(){return this.unsigned?Tt(this.low,this.high,!1):this};de.toUnsigned=function(){return this.unsigned?this:Tt(this.low,this.high,!0)};de.toBytes=function(t){return t?this.toBytesLE():this.toBytesBE()};de.toBytesLE=function(){var t=this.high,e=this.low;return[e&255,e>>>8&255,e>>>16&255,e>>>24,t&255,t>>>8&255,t>>>16&255,t>>>24]};de.toBytesBE=function(){var t=this.high,e=this.low;return[t>>>24,t>>>16&255,t>>>8&255,t&255,e>>>24,e>>>16&255,e>>>8&255,e&255]};Nt.fromBytes=function(t,e,o){return o?Nt.fromBytesLE(t,e):Nt.fromBytesBE(t,e)};Nt.fromBytesLE=function(t,e){return new Nt(t[0]|t[1]<<8|t[2]<<16|t[3]<<24,t[4]|t[5]<<8|t[6]<<16|t[7]<<24,e)};Nt.fromBytesBE=function(t,e){return new Nt(t[4]<<24|t[5]<<16|t[6]<<8|t[7],t[0]<<24|t[1]<<16|t[2]<<8|t[3],e)}});var Ik=qt(()=>{});var vk=qt(()=>{});var Q2=qt((Y2,Vw)=>{(function(r,t,e){function o(i){var p=this,u=a();p.next=function(){var c=2091639*p.s0+p.c*23283064365386963e-26;return p.s0=p.s1,p.s1=p.s2,p.s2=c-(p.c=c|0)},p.c=1,p.s0=u(\" \"),p.s1=u(\" \"),p.s2=u(\" \"),p.s0-=u(i),p.s0<0&&(p.s0+=1),p.s1-=u(i),p.s1<0&&(p.s1+=1),p.s2-=u(i),p.s2<0&&(p.s2+=1),u=null}function n(i,p){return p.c=i.c,p.s0=i.s0,p.s1=i.s1,p.s2=i.s2,p}function s(i,p){var u=new o(i),c=p&&p.state,l=u.next;return l.int32=function(){return u.next()*4294967296|0},l.double=function(){return l()+(l()*2097152|0)*11102230246251565e-32},l.quick=l,c&&(typeof c==\"object\"&&n(c,u),l.state=function(){return n(u,{})}),l}function a(){var i=4022871197,p=function(u){u=String(u);for(var c=0;c>>0,l-=i,l*=i,i=l>>>0,l-=i,i+=l*4294967296}return(i>>>0)*23283064365386963e-26};return p}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.alea=s})(Y2,typeof Vw==\"object\"&&Vw,typeof define==\"function\"&&define)});var J2=qt((Z2,Ww)=>{(function(r,t,e){function o(a){var i=this,p=\"\";i.x=0,i.y=0,i.z=0,i.w=0,i.next=function(){var c=i.x^i.x<<11;return i.x=i.y,i.y=i.z,i.z=i.w,i.w^=i.w>>>19^c^c>>>8},a===(a|0)?i.x=a:p+=a;for(var u=0;u>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(typeof u==\"object\"&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xor128=s})(Z2,typeof Ww==\"object\"&&Ww,typeof define==\"function\"&&define)});var t1=qt((e1,Uw)=>{(function(r,t,e){function o(a){var i=this,p=\"\";i.next=function(){var c=i.x^i.x>>>2;return i.x=i.y,i.y=i.z,i.z=i.w,i.w=i.v,(i.d=i.d+362437|0)+(i.v=i.v^i.v<<4^(c^c<<1))|0},i.x=0,i.y=0,i.z=0,i.w=0,i.v=0,a===(a|0)?i.x=a:p+=a;for(var u=0;u>>4),i.next()}function n(a,i){return i.x=a.x,i.y=a.y,i.z=a.z,i.w=a.w,i.v=a.v,i.d=a.d,i}function s(a,i){var p=new o(a),u=i&&i.state,c=function(){return(p.next()>>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(typeof u==\"object\"&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xorwow=s})(e1,typeof Uw==\"object\"&&Uw,typeof define==\"function\"&&define)});var o1=qt((r1,Gw)=>{(function(r,t,e){function o(a){var i=this;i.next=function(){var u=i.x,c=i.i,l,m,d;return l=u[c],l^=l>>>7,m=l^l<<24,l=u[c+1&7],m^=l^l>>>10,l=u[c+3&7],m^=l^l>>>3,l=u[c+4&7],m^=l^l<<7,l=u[c+7&7],l=l^l<<13,m^=l^l<<9,u[c]=m,i.i=c+1&7,m};function p(u,c){var l,m,d=[];if(c===(c|0))m=d[0]=c;else for(c=\"\"+c,l=0;l0;--l)u.next()}p(i,a)}function n(a,i){return i.x=a.x.slice(),i.i=a.i,i}function s(a,i){a==null&&(a=+new Date);var p=new o(a),u=i&&i.state,c=function(){return(p.next()>>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(u.x&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xorshift7=s})(r1,typeof Gw==\"object\"&&Gw,typeof define==\"function\"&&define)});var s1=qt((n1,Hw)=>{(function(r,t,e){function o(a){var i=this;i.next=function(){var u=i.w,c=i.X,l=i.i,m,d;return i.w=u=u+1640531527|0,d=c[l+34&127],m=c[l=l+1&127],d^=d<<13,m^=m<<17,d^=d>>>15,m^=m>>>12,d=c[l]=d^m,i.i=l,d+(u^u>>>16)|0};function p(u,c){var l,m,d,f,h,g=[],x=128;for(c===(c|0)?(m=c,c=null):(c=c+\"\\0\",m=0,x=Math.max(x,c.length)),d=0,f=-32;f>>15,m^=m<<4,m^=m>>>13,f>=0&&(h=h+1640531527|0,l=g[f&127]^=m+h,d=l==0?d+1:0);for(d>=128&&(g[(c&&c.length||0)&127]=-1),d=127,f=4*128;f>0;--f)m=g[d+34&127],l=g[d=d+1&127],m^=m<<13,l^=l<<17,m^=m>>>15,l^=l>>>12,g[d]=m^l;u.w=h,u.X=g,u.i=d}p(i,a)}function n(a,i){return i.i=a.i,i.w=a.w,i.X=a.X.slice(),i}function s(a,i){a==null&&(a=+new Date);var p=new o(a),u=i&&i.state,c=function(){return(p.next()>>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(u.X&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.xor4096=s})(n1,typeof Hw==\"object\"&&Hw,typeof define==\"function\"&&define)});var i1=qt((a1,Kw)=>{(function(r,t,e){function o(a){var i=this,p=\"\";i.next=function(){var c=i.b,l=i.c,m=i.d,d=i.a;return c=c<<25^c>>>7^l,l=l-m|0,m=m<<24^m>>>8^d,d=d-c|0,i.b=c=c<<20^c>>>12^l,i.c=l=l-m|0,i.d=m<<16^l>>>16^d,i.a=d-c|0},i.a=0,i.b=0,i.c=-1640531527,i.d=1367130551,a===Math.floor(a)?(i.a=a/4294967296|0,i.b=a|0):p+=a;for(var u=0;u>>0)/4294967296};return c.double=function(){do var l=p.next()>>>11,m=(p.next()>>>0)/4294967296,d=(l+m)/(1<<21);while(d===0);return d},c.int32=p.next,c.quick=c,u&&(typeof u==\"object\"&&n(u,p),c.state=function(){return n(p,{})}),c}t&&t.exports?t.exports=s:e&&e.amd?e(function(){return s}):this.tychei=s})(a1,typeof Kw==\"object\"&&Kw,typeof define==\"function\"&&define)});var u1=qt(()=>{});var c1=qt((p1,Ld)=>{(function(r,t,e){var o=256,n=6,s=52,a=\"random\",i=e.pow(o,n),p=e.pow(2,s),u=p*2,c=o-1,l;function m(C,S,k){var _=[];S=S==!0?{entropy:!0}:S||{};var E=g(h(S.entropy?[C,b(t)]:C==null?x():C,3),_),R=new d(_),D=function(){for(var P=R.g(n),O=i,M=0;P=u;)P/=2,O/=2,M>>>=1;return(P+M)/O};return D.int32=function(){return R.g(4)|0},D.quick=function(){return R.g(4)/4294967296},D.double=D,g(b(R.S),t),(S.pass||k||function(P,O,M,L){return L&&(L.S&&f(L,R),P.state=function(){return f(R,{})}),M?(e[a]=P,O):P})(D,E,\"global\"in S?S.global:this==e,S.state)}function d(C){var S,k=C.length,_=this,E=0,R=_.i=_.j=0,D=_.S=[];for(k||(C=[k++]);E{var vq=Q2(),kq=J2(),Nq=t1(),Tq=o1(),_q=s1(),$q=i1(),Qu=c1();Qu.alea=vq;Qu.xor128=kq;Qu.xorwow=Nq;Qu.xorshift7=Tq;Qu.xor4096=_q;Qu.tychei=$q;l1.exports=Qu});var Bv=qt(()=>{});var zv=qt(()=>{});var RB=qt(()=>{});var DB=qt(()=>{});var AB=qt(()=>{});var FB=qt((Wg,Wv)=>{var Vv=(()=>{var r=typeof document!=\"undefined\"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename!=\"undefined\"&&(r=r||__filename),function(t){t=t||{};function e(){return oe.buffer!=Ge&&_t(oe.buffer),mt}function o(){return oe.buffer!=Ge&&_t(oe.buffer),it}function n(){return oe.buffer!=Ge&&_t(oe.buffer),gt}function s(){return oe.buffer!=Ge&&_t(oe.buffer),Lr}function a(){return oe.buffer!=Ge&&_t(oe.buffer),Lt}function i(){return oe.buffer!=Ge&&_t(oe.buffer),to}function p(){return oe.buffer!=Ge&&_t(oe.buffer),nr}var u=typeof t!=\"undefined\"?t:{},c,l;u.ready=new Promise(function(F,V){c=F,l=V});var m;typeof process!=\"undefined\"&&process.listeners&&(m={uncaughtException:process.listeners(\"uncaughtException\"),unhandledRejection:process.listeners(\"unhandledRejection\")});var d=Object.assign({},u),f=[],h=\"./this.program\",g=(F,V)=>{throw V},x=typeof window==\"object\",b=typeof importScripts==\"function\",C=typeof process==\"object\"&&typeof process.versions==\"object\"&&typeof process.versions.node==\"string\",S=u.ENVIRONMENT_IS_PTHREAD||!1,k=\"\";function _(F){return u.locateFile?u.locateFile(F,k):k+F}var E,R,D,P;function O(F){if(F instanceof Eu)return;j(\"exiting due to exception: \"+F)}if(C){var M=Bv(),L=zv();b?k=L.dirname(k)+\"/\":k=__dirname+\"/\",E=(V,ue)=>(V=zp(V)?new URL(V):L.normalize(V),M.readFileSync(V,ue?void 0:\"utf8\")),D=V=>{var ue=E(V,!0);return ue.buffer||(ue=new Uint8Array(ue)),ue},R=(V,ue,Ee)=>{V=zp(V)?new URL(V):L.normalize(V),M.readFile(V,function(Be,Le){Be?Ee(Be):ue(Le.buffer)})},process.argv.length>1&&(h=process.argv[1].replace(/\\\\/g,\"/\")),f=process.argv.slice(2),process.on(\"uncaughtException\",function(V){if(!(V instanceof Eu))throw V}),process.on(\"unhandledRejection\",function(V){throw V}),g=(V,ue)=>{if(Bo())throw process.exitCode=V,ue;O(ue),process.exit(V)},u.inspect=function(){return\"[Emscripten Module object]\"};let F;try{F=RB()}catch(V){throw console.error('The \"worker_threads\" module is not supported in this node.js build - perhaps a newer version is needed?'),V}global.Worker=F.Worker}else(x||b)&&(b?k=self.location.href:typeof document!=\"undefined\"&&document.currentScript&&(k=document.currentScript.src),typeof r!=\"undefined\"&&r&&(k=r),k.indexOf(\"blob:\")!==0?k=k.substr(0,k.replace(/[?#].*/,\"\").lastIndexOf(\"/\")+1):k=\"\",C||(E=F=>{var V=new XMLHttpRequest;return V.open(\"GET\",F,!1),V.send(null),V.responseText},b&&(D=F=>{var V=new XMLHttpRequest;return V.open(\"GET\",F,!1),V.responseType=\"arraybuffer\",V.send(null),new Uint8Array(V.response)}),R=(F,V,ue)=>{var Ee=new XMLHttpRequest;Ee.open(\"GET\",F,!0),Ee.responseType=\"arraybuffer\",Ee.onload=()=>{if(Ee.status==200||Ee.status==0&&Ee.response){V(Ee.response);return}ue()},Ee.onerror=ue,Ee.send(null)}),P=F=>document.title=F);C&&typeof performance==\"undefined\"&&(global.performance=DB().performance);var B=console.log.bind(console),z=console.warn.bind(console);C&&(B=F=>M.writeSync(1,F+`\n`),z=F=>M.writeSync(2,F+`\n`));var U=u.print||B,j=u.printErr||z;Object.assign(u,d),d=null,u.arguments&&(f=u.arguments),u.thisProgram&&(h=u.thisProgram),u.quit&&(g=u.quit);var q=4,Y=Atomics.load,J=Atomics.store,re=Atomics.compareExchange,ne;u.wasmBinary&&(ne=u.wasmBinary);var ee=u.noExitRuntime||!0;typeof WebAssembly!=\"object\"&&$u(\"no native wasm support detected\");var oe,ie,le=!1,be;function _e(F,V){F||$u(V)}var ve=typeof TextDecoder!=\"undefined\"?new TextDecoder(\"utf8\"):void 0;function Fe(F,V,ue){V>>>=0;for(var Ee=V+ue,Be=V;F[Be]&&!(Be>=Ee);)++Be;if(Be-V>16&&F.buffer&&ve)return ve.decode(F.buffer instanceof SharedArrayBuffer?F.slice(V,Be):F.subarray(V,Be));for(var Le=\"\";V>10,56320|so&1023)}}return Le}function Pe(F,V){return F>>>=0,F?Fe(o(),F,V):\"\"}function st(F,V,ue,Ee){if(ue>>>=0,!(Ee>0))return 0;for(var Be=ue,Le=ue+Ee-1,ge=0;ge=55296&&Ne<=57343){var Pt=F.charCodeAt(++ge);Ne=65536+((Ne&1023)<<10)|Pt&1023}if(Ne<=127){if(ue>=Le)break;V[ue++>>>0]=Ne}else if(Ne<=2047){if(ue+1>=Le)break;V[ue++>>>0]=192|Ne>>6,V[ue++>>>0]=128|Ne&63}else if(Ne<=65535){if(ue+2>=Le)break;V[ue++>>>0]=224|Ne>>12,V[ue++>>>0]=128|Ne>>6&63,V[ue++>>>0]=128|Ne&63}else{if(ue+3>=Le)break;V[ue++>>>0]=240|Ne>>18,V[ue++>>>0]=128|Ne>>12&63,V[ue++>>>0]=128|Ne>>6&63,V[ue++>>>0]=128|Ne&63}}return V[ue>>>0]=0,ue-Be}function lt(F,V,ue){return st(F,o(),V,ue)}var Ge,mt,it,gt,xt,Lr,Lt,to,nr;S&&(Ge=u.buffer);function _t(F){Ge=F,u.HEAP8=mt=new Int8Array(F),u.HEAP16=gt=new Int16Array(F),u.HEAP32=Lr=new Int32Array(F),u.HEAPU8=it=new Uint8Array(F),u.HEAPU16=xt=new Uint16Array(F),u.HEAPU32=Lt=new Uint32Array(F),u.HEAPF32=to=new Float32Array(F),u.HEAPF64=nr=new Float64Array(F)}var sr=u.INITIAL_MEMORY||16777216;if(S)oe=u.wasmMemory,Ge=u.buffer;else if(u.wasmMemory)oe=u.wasmMemory;else if(oe=new WebAssembly.Memory({initial:sr/65536,maximum:65536,shared:!0}),!(oe.buffer instanceof SharedArrayBuffer))throw j(\"requested a shared WebAssembly.Memory but the returned buffer is not a SharedArrayBuffer, indicating that while the browser has SharedArrayBuffer it does not have WebAssembly threads support - you may need to set a flag\"),C&&j(\"(on node you may need: --experimental-wasm-threads --experimental-wasm-bulk-memory and/or recent version)\"),Error(\"bad memory\");oe&&(Ge=oe.buffer),sr=Ge.byteLength,_t(Ge);var ar,ro=[],oo=[],hr=[],Wa=!1;function Bo(){return ee}function Ks(){if(u.preRun)for(typeof u.preRun==\"function\"&&(u.preRun=[u.preRun]);u.preRun.length;)sl(u.preRun.shift());ul(ro)}function Yt(){Wa=!0,!S&&ul(oo)}function Ua(){if(!S){if(u.postRun)for(typeof u.postRun==\"function\"&&(u.postRun=[u.postRun]);u.postRun.length;)l0(u.postRun.shift());ul(hr)}}function sl(F){ro.unshift(F)}function al(F){oo.unshift(F)}function l0(F){hr.unshift(F)}var Ti=0,Bp=null,Ga=null;function Cy(F){Ti++,u.monitorRunDependencies&&u.monitorRunDependencies(Ti)}function wm(F){if(Ti--,u.monitorRunDependencies&&u.monitorRunDependencies(Ti),Ti==0&&(Bp!==null&&(clearInterval(Bp),Bp=null),Ga)){var V=Ga;Ga=null,V()}}function $u(F){u.onAbort&&u.onAbort(F),F=\"Aborted(\"+F+\")\",j(F),le=!0,be=1,F+=\". Build with -sASSERTIONS for more info.\";var V=new WebAssembly.RuntimeError(F);throw l(V),V}var wy=\"data:application/octet-stream;base64,\";function Sm(F){return F.startsWith(wy)}function zp(F){return F.startsWith(\"file://\")}var gr;gr=\"tfjs-backend-wasm-threaded-simd.wasm\",Sm(gr)||(gr=_(gr));function Im(F){try{if(F==gr&&ne)return new Uint8Array(ne);if(D)return D(F);throw\"both async and sync fetching of the wasm failed\"}catch(V){$u(V)}}function Sy(){if(!ne&&(x||b)){if(typeof fetch==\"function\"&&!zp(gr))return fetch(gr,{credentials:\"same-origin\"}).then(function(F){if(!F.ok)throw\"failed to load wasm binary file at '\"+gr+\"'\";return F.arrayBuffer()}).catch(function(){return Im(gr)});if(R)return new Promise(function(F,V){R(gr,function(ue){F(new Uint8Array(ue))},V)})}return Promise.resolve().then(function(){return Im(gr)})}function Iy(){var F={env:Om,wasi_snapshot_preview1:Om};function V(ge,Ne){var Pt=ge.exports;if(u.asm=Pt,Dy(u.asm._emscripten_tls_init),ar=u.asm.__indirect_function_table,al(u.asm.__wasm_call_ctors),ie=Ne,!S){var so=Me.unusedWorkers.length;Me.unusedWorkers.forEach(function(Ka){Me.loadWasmModuleToWorker(Ka,function(){--so||wm(\"wasm-instantiate\")})})}}S||Cy(\"wasm-instantiate\");function ue(ge){V(ge.instance,ge.module)}function Ee(ge){return Sy().then(function(Ne){return WebAssembly.instantiate(Ne,F)}).then(function(Ne){return Ne}).then(ge,function(Ne){j(\"failed to asynchronously prepare wasm: \"+Ne),$u(Ne)})}function Be(){return!ne&&typeof WebAssembly.instantiateStreaming==\"function\"&&!Sm(gr)&&!zp(gr)&&!C&&typeof fetch==\"function\"?fetch(gr,{credentials:\"same-origin\"}).then(function(ge){var Ne=WebAssembly.instantiateStreaming(ge,F);return Ne.then(ue,function(Pt){return j(\"wasm streaming compile failed: \"+Pt),j(\"falling back to ArrayBuffer instantiation\"),Ee(ue)})}):Ee(ue)}if(u.instantiateWasm)try{var Le=u.instantiateWasm(F,V);return Le}catch(ge){j(\"Module.instantiateWasm callback failed with error: \"+ge),l(ge)}return Be().catch(l),{}}var m0,d0,vm={};function Eu(F){this.name=\"ExitStatus\",this.message=\"Program terminated with exit(\"+F+\")\",this.status=F}function vy(F){var V=Me.pthreads[F];delete Me.pthreads[F],V.terminate(),jC(F),Me.runningWorkers.splice(Me.runningWorkers.indexOf(V),1),V.pthread_ptr=0}function ky(F){var V=Me.pthreads[F];V.postMessage({cmd:\"cancel\"})}function il(F){var V=Me.pthreads[F];_e(V),Me.returnWorkerToPool(V)}function Ny(F){var V=Me.getNewWorker();if(!V)return 6;Me.runningWorkers.push(V),Me.pthreads[F.pthread_ptr]=V,V.pthread_ptr=F.pthread_ptr;var ue={cmd:\"run\",start_routine:F.startRoutine,arg:F.arg,pthread_ptr:F.pthread_ptr};return V.runPthread=()=>{C&&V.ref(),V.postMessage(ue,F.transferList),delete V.runPthread},V.loaded&&V.runPthread(),0}var km={varargs:void 0,get:function(){km.varargs+=4;var F=s()[km.varargs-4>>>2];return F},getStr:function(F){var V=Pe(F);return V}};function Nm(F){if(S)return _i(1,1,F);be=F,Bo()||(Me.terminateAllThreads(),u.onExit&&u.onExit(F),le=!0),g(F,new Eu(F))}function Ty(F,V){if(be=F,!V&&S)throw _m(F),\"unwind\";Nm(F)}var Tm=Ty;function _y(F){if(F instanceof Eu||F==\"unwind\")return be;g(1,F)}var Me={unusedWorkers:[],runningWorkers:[],tlsInitFunctions:[],pthreads:{},init:function(){S?Me.initWorker():Me.initMainThread()},initMainThread:function(){for(var F=8;F--;)Me.allocateUnusedWorker()},initWorker:function(){ee=!1},setExitStatus:function(F){be=F},terminateAllThreads:function(){for(var F of Object.values(Me.pthreads))Me.returnWorkerToPool(F);for(var F of Me.unusedWorkers)F.terminate();Me.unusedWorkers=[]},returnWorkerToPool:function(F){var V=F.pthread_ptr;delete Me.pthreads[V],Me.unusedWorkers.push(F),Me.runningWorkers.splice(Me.runningWorkers.indexOf(F),1),F.pthread_ptr=0,C&&F.unref(),jC(V)},receiveObjectTransfer:function(F){},threadInitTLS:function(){Me.tlsInitFunctions.forEach(F=>F())},loadWasmModuleToWorker:function(F,V){F.onmessage=Le=>{var ge=Le.data,Ne=ge.cmd;if(F.pthread_ptr&&(Me.currentProxiedOperationCallerThread=F.pthread_ptr),ge.targetThread&&ge.targetThread!=Wm()){var Pt=Me.pthreads[ge.targetThread];Pt?Pt.postMessage(ge,ge.transferList):j('Internal error! Worker sent a message \"'+Ne+'\" to target pthread '+ge.targetThread+\", but that thread no longer exists!\"),Me.currentProxiedOperationCallerThread=void 0;return}Ne===\"processProxyingQueue\"?pl(ge.queue):Ne===\"spawnThread\"?Ny(ge):Ne===\"cleanupThread\"?il(ge.thread):Ne===\"killThread\"?vy(ge.thread):Ne===\"cancelThread\"?ky(ge.thread):Ne===\"loaded\"?(F.loaded=!0,C&&F.unref(),V&&V(F),F.runPthread&&F.runPthread()):Ne===\"print\"?U(\"Thread \"+ge.threadId+\": \"+ge.text):Ne===\"printErr\"?j(\"Thread \"+ge.threadId+\": \"+ge.text):Ne===\"alert\"?alert(\"Thread \"+ge.threadId+\": \"+ge.text):ge.target===\"setimmediate\"?F.postMessage(ge):Ne===\"callHandler\"?u[ge.handler](...ge.args):Ne&&j(\"worker sent an unknown command \"+Ne),Me.currentProxiedOperationCallerThread=void 0},F.onerror=Le=>{var ge=\"worker sent an error!\";throw j(ge+\" \"+Le.filename+\":\"+Le.lineno+\": \"+Le.message),Le},C&&(F.on(\"message\",function(Le){F.onmessage({data:Le})}),F.on(\"error\",function(Le){F.onerror(Le)}),F.on(\"detachedExit\",function(){}));var ue=[],Ee=[\"onExit\",\"onAbort\",\"print\",\"printErr\"];for(var Be of Ee)u.hasOwnProperty(Be)&&ue.push(Be);F.postMessage({cmd:\"load\",handlers:ue,urlOrBlob:u.mainScriptUrlOrBlob||r,wasmMemory:oe,wasmModule:ie})},allocateUnusedWorker:function(){var F,V=_(\"tfjs-backend-wasm-threaded-simd.worker.js\");F=new Worker(V),Me.unusedWorkers.push(F)},getNewWorker:function(){return Me.unusedWorkers.length==0&&(Me.allocateUnusedWorker(),Me.loadWasmModuleToWorker(Me.unusedWorkers[0])),Me.unusedWorkers.pop()}};u.PThread=Me;function ul(F){for(;F.length>0;)F.shift()(u)}function $y(){var F=Wm(),V=s()[F+52>>>2],ue=s()[F+56>>>2],Ee=V-ue;b0(V,Ee),Um(V)}u.establishStackSpace=$y;function _m(F){if(S)return _i(2,0,F);try{Tm(F)}catch(V){_y(V)}}var Vp=[];function Ey(F){var V=Vp[F];return V||(F>=Vp.length&&(Vp.length=F+1),Vp[F]=V=ar.get(F)),V}function Ry(F,V){var ue=Ey(F)(V);Bo()?Me.setExitStatus(ue):y0(ue)}u.invokeEntryPoint=Ry;function Dy(F){Me.tlsInitFunctions.push(F)}function Ay(F){h0(F,!b,1,!x),Me.threadInitTLS()}function Fy(F){S?postMessage({cmd:\"cleanupThread\",thread:F}):il(F)}function $m(F,V,ue,Ee){return S?_i(3,1,F,V,ue,Ee):Em(F,V,ue,Ee)}function Em(F,V,ue,Ee){if(typeof SharedArrayBuffer==\"undefined\")return j(\"Current environment does not support SharedArrayBuffer, pthreads are not available!\"),6;var Be=[],Le=0;if(S&&(Be.length===0||Le))return $m(F,V,ue,Ee);if(Le)return Le;var ge={startRoutine:ue,pthread_ptr:F,arg:Ee,transferList:Be};return S?(ge.cmd=\"spawnThread\",postMessage(ge,Be),0):Ny(ge)}function Py(){return 65536}var Oy=!0;function My(){return Oy}function pl(F){Atomics.store(s(),F>>2,1),Wm()&&x0(F),Atomics.compareExchange(s(),F>>2,1,0)}u.executeNotifiedProxyingQueue=pl;function Ly(F,V,ue,Ee){if(F==V)setTimeout(()=>pl(Ee));else if(S)postMessage({targetThread:F,cmd:\"processProxyingQueue\",queue:Ee});else{var Be=Me.pthreads[F];if(!Be)return;Be.postMessage({cmd:\"processProxyingQueue\",queue:Ee})}return 1}function By(F,V,ue){return-1}function zy(){$u(\"\")}function Ru(F){Ru.shown||(Ru.shown={}),Ru.shown[F]||(Ru.shown[F]=1,C&&(F=\"warning: \"+F),j(F))}function Vy(){C||b||Ru(\"Blocking on the main thread is very dangerous, see https://emscripten.org/docs/porting/pthreads.html#blocking-on-the-main-browser-thread\")}function Wy(){return Date.now()}function Rm(){return 4294901760}function Uy(){return Rm()}var cl;C?cl=()=>{var F=process.hrtime();return F[0]*1e3+F[1]/1e6}:cl=()=>performance.timeOrigin+performance.now();function Gy(F,V,ue){o().copyWithin(F>>>0,V>>>0,V+ue>>>0)}function Hy(){return C?AB().cpus().length:navigator.hardwareConcurrency}function Ky(F){var V=XC(),ue=F();return Um(V),ue}function _i(F,V){var ue=arguments.length-2,Ee=arguments;return Ky(()=>{for(var Be=ue,Le=Gm(Be*8),ge=Le>>3,Ne=0;Ne>>0]=Pt}return g0(F,Be,Le,V)})}var ll=[];function qy(F,V,ue){ll.length=V;for(var Ee=ue>>3,Be=0;Be>>0];var Le=F<0,ge=Le?vm[-F-1]:rb[F];return ge.apply(null,ll)}function jy(F){try{return oe.grow(F-Ge.byteLength+65535>>>16),_t(oe.buffer),1}catch(V){}}function Xy(F){var V=o().length;if(F=F>>>0,F<=V)return!1;var ue=Rm();if(F>ue)return!1;let Ee=(Pt,so)=>Pt+(so-Pt%so)%so;for(var Be=1;Be<=4;Be*=2){var Le=V*(1+.2/Be);Le=Math.min(Le,F+100663296);var ge=Math.min(ue,Ee(Math.max(F,Le),65536)),Ne=jy(ge);if(Ne)return!0}return!1}function Yy(){throw\"unwind\"}function Dm(F){return S?_i(4,1,F):52}function Am(F,V,ue,Ee,Be){return S?_i(5,1,F,V,ue,Ee,Be):70}var Qy=[null,[],[]];function Zy(F,V){var ue=Qy[F];V===0||V===10?((F===1?U:j)(Fe(ue,0)),ue.length=0):ue.push(V)}function Fm(F,V,ue,Ee){if(S)return _i(6,1,F,V,ue,Ee);for(var Be=0,Le=0;Le>>2],Ne=a()[V+4>>>2];V+=8;for(var Pt=0;Pt>>0]);Be+=Ne}return a()[Ee>>>2]=Be,0}function Pm(F){var V=u[\"_\"+F];return V}function Jy(F,V){e().set(F,V>>>0)}function eb(F,V,ue,Ee,Be){var Le={string:Br=>{var Hp=0;if(Br!=null&&Br!==0){var S0=(Br.length<<2)+1;Hp=Gm(S0),lt(Br,Hp,S0)}return Hp},array:Br=>{var Hp=Gm(Br.length);return Jy(Br,Hp),Hp}};function ge(Br){return V===\"string\"?Pe(Br):V===\"boolean\"?!!Br:Br}var Ne=Pm(F),Pt=[],so=0;if(Ee)for(var Ka=0;Kage===\"number\"||ge===\"boolean\"),Le=V!==\"string\";return Le&&Be&&!Ee?Pm(F):function(){return eb(F,V,ue,arguments,Ee)}}Me.init();var rb=[null,Nm,_m,$m,Dm,Am,Fm],Om={__emscripten_init_main_thread_js:Ay,__emscripten_thread_cleanup:Fy,__pthread_create_js:Em,_emscripten_default_pthread_stack_size:Py,_emscripten_get_now_is_monotonic:My,_emscripten_notify_task_queue:Ly,_emscripten_set_offscreencanvas_size:By,abort:zy,emscripten_check_blocking_allowed:Vy,emscripten_date_now:Wy,emscripten_get_heap_max:Uy,emscripten_get_now:cl,emscripten_memcpy_big:Gy,emscripten_num_logical_cores:Hy,emscripten_receive_on_main_thread_js:qy,emscripten_resize_heap:Xy,emscripten_unwind_to_js_event_loop:Yy,exit:Tm,fd_close:Dm,fd_seek:Am,fd_write:Fm,memory:oe||u.wasmMemory},f0=Iy(),ob=u.___wasm_call_ctors=function(){return(ob=u.___wasm_call_ctors=u.asm.__wasm_call_ctors).apply(null,arguments)},nb=u._init=function(){return(nb=u._init=u.asm.init).apply(null,arguments)},sb=u._init_with_threads_count=function(){return(sb=u._init_with_threads_count=u.asm.init_with_threads_count).apply(null,arguments)},ab=u._get_threads_count=function(){return(ab=u._get_threads_count=u.asm.get_threads_count).apply(null,arguments)},ib=u._register_tensor=function(){return(ib=u._register_tensor=u.asm.register_tensor).apply(null,arguments)},ub=u._dispose_data=function(){return(ub=u._dispose_data=u.asm.dispose_data).apply(null,arguments)},pb=u._dispose=function(){return(pb=u._dispose=u.asm.dispose).apply(null,arguments)},cb=u._Abs=function(){return(cb=u._Abs=u.asm.Abs).apply(null,arguments)},lb=u._Acos=function(){return(lb=u._Acos=u.asm.Acos).apply(null,arguments)},mb=u._Acosh=function(){return(mb=u._Acosh=u.asm.Acosh).apply(null,arguments)},db=u._Add=function(){return(db=u._Add=u.asm.Add).apply(null,arguments)},fb=u._AddN=function(){return(fb=u._AddN=u.asm.AddN).apply(null,arguments)},hb=u._All=function(){return(hb=u._All=u.asm.All).apply(null,arguments)},gb=u._Any=function(){return(gb=u._Any=u.asm.Any).apply(null,arguments)},xb=u._ArgMax=function(){return(xb=u._ArgMax=u.asm.ArgMax).apply(null,arguments)},yb=u._ArgMin=function(){return(yb=u._ArgMin=u.asm.ArgMin).apply(null,arguments)},bb=u._Asin=function(){return(bb=u._Asin=u.asm.Asin).apply(null,arguments)},Cb=u._Asinh=function(){return(Cb=u._Asinh=u.asm.Asinh).apply(null,arguments)},wb=u._Atan=function(){return(wb=u._Atan=u.asm.Atan).apply(null,arguments)},Sb=u._Atan2=function(){return(Sb=u._Atan2=u.asm.Atan2).apply(null,arguments)},Ib=u._Atanh=function(){return(Ib=u._Atanh=u.asm.Atanh).apply(null,arguments)},vb=u._AvgPool=function(){return(vb=u._AvgPool=u.asm.AvgPool).apply(null,arguments)},kb=u._AvgPool3D=function(){return(kb=u._AvgPool3D=u.asm.AvgPool3D).apply(null,arguments)},Nb=u._AvgPool3DGrad=function(){return(Nb=u._AvgPool3DGrad=u.asm.AvgPool3DGrad).apply(null,arguments)},Tb=u._AvgPoolGrad=function(){return(Tb=u._AvgPoolGrad=u.asm.AvgPoolGrad).apply(null,arguments)},_b=u._BatchMatMul=function(){return(_b=u._BatchMatMul=u.asm.BatchMatMul).apply(null,arguments)},$b=u._Bincount=function(){return($b=u._Bincount=u.asm.Bincount).apply(null,arguments)},Eb=u._BitwiseAnd=function(){return(Eb=u._BitwiseAnd=u.asm.BitwiseAnd).apply(null,arguments)},Rb=u._Ceil=function(){return(Rb=u._Ceil=u.asm.Ceil).apply(null,arguments)},Db=u._ClipByValue=function(){return(Db=u._ClipByValue=u.asm.ClipByValue).apply(null,arguments)},Ab=u._Conv2D=function(){return(Ab=u._Conv2D=u.asm.Conv2D).apply(null,arguments)},Fb=u._Conv2DBackpropInput=function(){return(Fb=u._Conv2DBackpropInput=u.asm.Conv2DBackpropInput).apply(null,arguments)},Pb=u._Conv3D=function(){return(Pb=u._Conv3D=u.asm.Conv3D).apply(null,arguments)},Ob=u._Conv3DBackpropFilterV2=function(){return(Ob=u._Conv3DBackpropFilterV2=u.asm.Conv3DBackpropFilterV2).apply(null,arguments)},Mb=u._Conv3DBackpropInputV2=function(){return(Mb=u._Conv3DBackpropInputV2=u.asm.Conv3DBackpropInputV2).apply(null,arguments)},Lb=u._Cos=function(){return(Lb=u._Cos=u.asm.Cos).apply(null,arguments)},Bb=u._Cosh=function(){return(Bb=u._Cosh=u.asm.Cosh).apply(null,arguments)},zb=u._CropAndResize=function(){return(zb=u._CropAndResize=u.asm.CropAndResize).apply(null,arguments)},Vb=u._Cumprod=function(){return(Vb=u._Cumprod=u.asm.Cumprod).apply(null,arguments)},Wb=u._Cumsum=function(){return(Wb=u._Cumsum=u.asm.Cumsum).apply(null,arguments)},Ub=u._DenseBincount=function(){return(Ub=u._DenseBincount=u.asm.DenseBincount).apply(null,arguments)},Gb=u._DepthToSpace=function(){return(Gb=u._DepthToSpace=u.asm.DepthToSpace).apply(null,arguments)},Hb=u._DepthwiseConv2dNative=function(){return(Hb=u._DepthwiseConv2dNative=u.asm.DepthwiseConv2dNative).apply(null,arguments)},Kb=u._Diag=function(){return(Kb=u._Diag=u.asm.Diag).apply(null,arguments)},qb=u._Dilation2D=function(){return(qb=u._Dilation2D=u.asm.Dilation2D).apply(null,arguments)},jb=u._Dilation2DBackpropFilter=function(){return(jb=u._Dilation2DBackpropFilter=u.asm.Dilation2DBackpropFilter).apply(null,arguments)},Xb=u._Dilation2DBackpropInput=function(){return(Xb=u._Dilation2DBackpropInput=u.asm.Dilation2DBackpropInput).apply(null,arguments)},Yb=u._Elu=function(){return(Yb=u._Elu=u.asm.Elu).apply(null,arguments)},Qb=u._EluGrad=function(){return(Qb=u._EluGrad=u.asm.EluGrad).apply(null,arguments)},Zb=u._Equal=function(){return(Zb=u._Equal=u.asm.Equal).apply(null,arguments)},Jb=u._Erf=function(){return(Jb=u._Erf=u.asm.Erf).apply(null,arguments)},eC=u._Exp=function(){return(eC=u._Exp=u.asm.Exp).apply(null,arguments)},tC=u._Expm1=function(){return(tC=u._Expm1=u.asm.Expm1).apply(null,arguments)},rC=u._FlipLeftRight=function(){return(rC=u._FlipLeftRight=u.asm.FlipLeftRight).apply(null,arguments)},oC=u._Floor=function(){return(oC=u._Floor=u.asm.Floor).apply(null,arguments)},nC=u._FloorDiv=function(){return(nC=u._FloorDiv=u.asm.FloorDiv).apply(null,arguments)},sC=u._FusedBatchNorm=function(){return(sC=u._FusedBatchNorm=u.asm.FusedBatchNorm).apply(null,arguments)},aC=u._FusedConv2D=function(){return(aC=u._FusedConv2D=u.asm.FusedConv2D).apply(null,arguments)},iC=u._FusedDepthwiseConv2D=function(){return(iC=u._FusedDepthwiseConv2D=u.asm.FusedDepthwiseConv2D).apply(null,arguments)},uC=u._Gather=function(){return(uC=u._Gather=u.asm.Gather).apply(null,arguments)},pC=u._GatherNd=function(){return(pC=u._GatherNd=u.asm.GatherNd).apply(null,arguments)},cC=u._Greater=function(){return(cC=u._Greater=u.asm.Greater).apply(null,arguments)},lC=u._GreaterEqual=function(){return(lC=u._GreaterEqual=u.asm.GreaterEqual).apply(null,arguments)},mC=u._IsFinite=function(){return(mC=u._IsFinite=u.asm.IsFinite).apply(null,arguments)},dC=u._IsInf=function(){return(dC=u._IsInf=u.asm.IsInf).apply(null,arguments)},fC=u._IsNan=function(){return(fC=u._IsNan=u.asm.IsNan).apply(null,arguments)},hC=u._LRN=function(){return(hC=u._LRN=u.asm.LRN).apply(null,arguments)},gC=u._LRNGrad=function(){return(gC=u._LRNGrad=u.asm.LRNGrad).apply(null,arguments)},xC=u._LeakyRelu=function(){return(xC=u._LeakyRelu=u.asm.LeakyRelu).apply(null,arguments)},yC=u._Less=function(){return(yC=u._Less=u.asm.Less).apply(null,arguments)},bC=u._LessEqual=function(){return(bC=u._LessEqual=u.asm.LessEqual).apply(null,arguments)},CC=u._LinSpace=function(){return(CC=u._LinSpace=u.asm.LinSpace).apply(null,arguments)},wC=u._Log=function(){return(wC=u._Log=u.asm.Log).apply(null,arguments)},SC=u._Log1p=function(){return(SC=u._Log1p=u.asm.Log1p).apply(null,arguments)},IC=u._LogicalAnd=function(){return(IC=u._LogicalAnd=u.asm.LogicalAnd).apply(null,arguments)},vC=u._LogicalNot=function(){return(vC=u._LogicalNot=u.asm.LogicalNot).apply(null,arguments)},kC=u._LogicalOr=function(){return(kC=u._LogicalOr=u.asm.LogicalOr).apply(null,arguments)},NC=u._LogicalXor=function(){return(NC=u._LogicalXor=u.asm.LogicalXor).apply(null,arguments)},TC=u._Max=function(){return(TC=u._Max=u.asm.Max).apply(null,arguments)},_C=u._MaxPool=function(){return(_C=u._MaxPool=u.asm.MaxPool).apply(null,arguments)},$C=u._MaxPool3D=function(){return($C=u._MaxPool3D=u.asm.MaxPool3D).apply(null,arguments)},EC=u._MaxPool3DGrad=function(){return(EC=u._MaxPool3DGrad=u.asm.MaxPool3DGrad).apply(null,arguments)},RC=u._MaxPoolGrad=function(){return(RC=u._MaxPoolGrad=u.asm.MaxPoolGrad).apply(null,arguments)},DC=u._MaxPoolWithArgmax=function(){return(DC=u._MaxPoolWithArgmax=u.asm.MaxPoolWithArgmax).apply(null,arguments)},AC=u._Maximum=function(){return(AC=u._Maximum=u.asm.Maximum).apply(null,arguments)},FC=u._Mean=function(){return(FC=u._Mean=u.asm.Mean).apply(null,arguments)},PC=u._Min=function(){return(PC=u._Min=u.asm.Min).apply(null,arguments)},OC=u._Minimum=function(){return(OC=u._Minimum=u.asm.Minimum).apply(null,arguments)},MC=u._MirrorPad=function(){return(MC=u._MirrorPad=u.asm.MirrorPad).apply(null,arguments)},LC=u._Mod=function(){return(LC=u._Mod=u.asm.Mod).apply(null,arguments)},BC=u._Multinomial=function(){return(BC=u._Multinomial=u.asm.Multinomial).apply(null,arguments)},zC=u._Multiply=function(){return(zC=u._Multiply=u.asm.Multiply).apply(null,arguments)},VC=u._Neg=function(){return(VC=u._Neg=u.asm.Neg).apply(null,arguments)},WC=u._NonMaxSuppressionV3=function(){return(WC=u._NonMaxSuppressionV3=u.asm.NonMaxSuppressionV3).apply(null,arguments)},UC=u._NonMaxSuppressionV4=function(){return(UC=u._NonMaxSuppressionV4=u.asm.NonMaxSuppressionV4).apply(null,arguments)},Mm=u._NonMaxSuppressionV5=function(){return(Mm=u._NonMaxSuppressionV5=u.asm.NonMaxSuppressionV5).apply(null,arguments)},Lm=u._NotEqual=function(){return(Lm=u._NotEqual=u.asm.NotEqual).apply(null,arguments)},ml=u._OneHot=function(){return(ml=u._OneHot=u.asm.OneHot).apply(null,arguments)},GC=u._PadV2=function(){return(GC=u._PadV2=u.asm.PadV2).apply(null,arguments)},HC=u._Pow=function(){return(HC=u._Pow=u.asm.Pow).apply(null,arguments)},Wp=u._Prelu=function(){return(Wp=u._Prelu=u.asm.Prelu).apply(null,arguments)},Bm=u._Prod=function(){return(Bm=u._Prod=u.asm.Prod).apply(null,arguments)},Up=u._RealDiv=function(){return(Up=u._RealDiv=u.asm.RealDiv).apply(null,arguments)},Gp=u._Reciprocal=function(){return(Gp=u._Reciprocal=u.asm.Reciprocal).apply(null,arguments)},KC=u._Relu=function(){return(KC=u._Relu=u.asm.Relu).apply(null,arguments)},K=u._Relu6=function(){return(K=u._Relu6=u.asm.Relu6).apply(null,arguments)},ae=u._ResizeBilinear=function(){return(ae=u._ResizeBilinear=u.asm.ResizeBilinear).apply(null,arguments)},$e=u._ResizeBilinearGrad=function(){return($e=u._ResizeBilinearGrad=u.asm.ResizeBilinearGrad).apply(null,arguments)},at=u._ResizeNearestNeighbor=function(){return(at=u._ResizeNearestNeighbor=u.asm.ResizeNearestNeighbor).apply(null,arguments)},$t=u._ResizeNearestNeighborGrad=function(){return($t=u._ResizeNearestNeighborGrad=u.asm.ResizeNearestNeighborGrad).apply(null,arguments)},Et=u._Reverse=function(){return(Et=u._Reverse=u.asm.Reverse).apply(null,arguments)},Qe=u._RotateWithOffset=function(){return(Qe=u._RotateWithOffset=u.asm.RotateWithOffset).apply(null,arguments)},Ke=u._Round=function(){return(Ke=u._Round=u.asm.Round).apply(null,arguments)},Gt=u._Rsqrt=function(){return(Gt=u._Rsqrt=u.asm.Rsqrt).apply(null,arguments)},no=u._ScatterNd=function(){return(no=u._ScatterNd=u.asm.ScatterNd).apply(null,arguments)},Ha=u._SearchSorted=function(){return(Ha=u._SearchSorted=u.asm.SearchSorted).apply(null,arguments)},zm=u._SelectV2=function(){return(zm=u._SelectV2=u.asm.SelectV2).apply(null,arguments)},dl=u._Selu=function(){return(dl=u._Selu=u.asm.Selu).apply(null,arguments)},qC=u._Sigmoid=function(){return(qC=u._Sigmoid=u.asm.Sigmoid).apply(null,arguments)},br=u._Sign=function(){return(br=u._Sign=u.asm.Sign).apply(null,arguments)},$i=u._Sin=function(){return($i=u._Sin=u.asm.Sin).apply(null,arguments)},Vm=u._Sinh=function(){return(Vm=u._Sinh=u.asm.Sinh).apply(null,arguments)},WU=u._Softmax=function(){return(WU=u._Softmax=u.asm.Softmax).apply(null,arguments)},UU=u._Softplus=function(){return(UU=u._Softplus=u.asm.Softplus).apply(null,arguments)},GU=u._SparseFillEmptyRows=function(){return(GU=u._SparseFillEmptyRows=u.asm.SparseFillEmptyRows).apply(null,arguments)},HU=u._SparseReshape=function(){return(HU=u._SparseReshape=u.asm.SparseReshape).apply(null,arguments)},KU=u._SparseSegmentReduction=function(){return(KU=u._SparseSegmentReduction=u.asm.SparseSegmentReduction).apply(null,arguments)},qU=u._SparseToDense=function(){return(qU=u._SparseToDense=u.asm.SparseToDense).apply(null,arguments)},jU=u._Sqrt=function(){return(jU=u._Sqrt=u.asm.Sqrt).apply(null,arguments)},XU=u._Square=function(){return(XU=u._Square=u.asm.Square).apply(null,arguments)},YU=u._SquaredDifference=function(){return(YU=u._SquaredDifference=u.asm.SquaredDifference).apply(null,arguments)},QU=u._Step=function(){return(QU=u._Step=u.asm.Step).apply(null,arguments)},ZU=u._StridedSlice=function(){return(ZU=u._StridedSlice=u.asm.StridedSlice).apply(null,arguments)},JU=u._Sub=function(){return(JU=u._Sub=u.asm.Sub).apply(null,arguments)},eG=u._Sum=function(){return(eG=u._Sum=u.asm.Sum).apply(null,arguments)},tG=u._Tan=function(){return(tG=u._Tan=u.asm.Tan).apply(null,arguments)},rG=u._Tanh=function(){return(rG=u._Tanh=u.asm.Tanh).apply(null,arguments)},oG=u._TensorScatterUpdate=function(){return(oG=u._TensorScatterUpdate=u.asm.TensorScatterUpdate).apply(null,arguments)},nG=u._Tile=function(){return(nG=u._Tile=u.asm.Tile).apply(null,arguments)},sG=u._TopK=function(){return(sG=u._TopK=u.asm.TopK).apply(null,arguments)},aG=u._Transform=function(){return(aG=u._Transform=u.asm.Transform).apply(null,arguments)},iG=u._Transpose=function(){return(iG=u._Transpose=u.asm.Transpose).apply(null,arguments)},uG=u.__FusedMatMul=function(){return(uG=u.__FusedMatMul=u.asm._FusedMatMul).apply(null,arguments)},pG=u._malloc=function(){return(pG=u._malloc=u.asm.malloc).apply(null,arguments)},cG=u._free=function(){return(cG=u._free=u.asm.free).apply(null,arguments)},lG=u.__emscripten_tls_init=function(){return(lG=u.__emscripten_tls_init=u.asm._emscripten_tls_init).apply(null,arguments)},Wm=u._pthread_self=function(){return(Wm=u._pthread_self=u.asm.pthread_self).apply(null,arguments)},mG=u.___errno_location=function(){return(mG=u.___errno_location=u.asm.__errno_location).apply(null,arguments)},h0=u.__emscripten_thread_init=function(){return(h0=u.__emscripten_thread_init=u.asm._emscripten_thread_init).apply(null,arguments)},dG=u.__emscripten_thread_crashed=function(){return(dG=u.__emscripten_thread_crashed=u.asm._emscripten_thread_crashed).apply(null,arguments)},fG=u._emscripten_main_thread_process_queued_calls=function(){return(fG=u._emscripten_main_thread_process_queued_calls=u.asm.emscripten_main_thread_process_queued_calls).apply(null,arguments)},hG=u._emscripten_main_browser_thread_id=function(){return(hG=u._emscripten_main_browser_thread_id=u.asm.emscripten_main_browser_thread_id).apply(null,arguments)},g0=u._emscripten_run_in_main_runtime_thread_js=function(){return(g0=u._emscripten_run_in_main_runtime_thread_js=u.asm.emscripten_run_in_main_runtime_thread_js).apply(null,arguments)},gG=u._emscripten_dispatch_to_thread_=function(){return(gG=u._emscripten_dispatch_to_thread_=u.asm.emscripten_dispatch_to_thread_).apply(null,arguments)},x0=u.__emscripten_proxy_execute_task_queue=function(){return(x0=u.__emscripten_proxy_execute_task_queue=u.asm._emscripten_proxy_execute_task_queue).apply(null,arguments)},jC=u.__emscripten_thread_free_data=function(){return(jC=u.__emscripten_thread_free_data=u.asm._emscripten_thread_free_data).apply(null,arguments)},y0=u.__emscripten_thread_exit=function(){return(y0=u.__emscripten_thread_exit=u.asm._emscripten_thread_exit).apply(null,arguments)},b0=u._emscripten_stack_set_limits=function(){return(b0=u._emscripten_stack_set_limits=u.asm.emscripten_stack_set_limits).apply(null,arguments)},XC=u.stackSave=function(){return(XC=u.stackSave=u.asm.stackSave).apply(null,arguments)},Um=u.stackRestore=function(){return(Um=u.stackRestore=u.asm.stackRestore).apply(null,arguments)},Gm=u.stackAlloc=function(){return(Gm=u.stackAlloc=u.asm.stackAlloc).apply(null,arguments)},xG=u.dynCall_iijjiiii=function(){return(xG=u.dynCall_iijjiiii=u.asm.dynCall_iijjiiii).apply(null,arguments)},yG=u.dynCall_jiji=function(){return(yG=u.dynCall_jiji=u.asm.dynCall_jiji).apply(null,arguments)};u.keepRuntimeAlive=Bo,u.wasmMemory=oe,u.cwrap=tb,u.ExitStatus=Eu,u.PThread=Me;var Hm;Ga=function F(){Hm||C0(),Hm||(Ga=F)};function C0(F){if(F=F||f,Ti>0)return;if(S){c(u),Yt(),startWorker(u);return}if(Ks(),Ti>0)return;function V(){Hm||(Hm=!0,u.calledRun=!0,!le&&(Yt(),c(u),u.onRuntimeInitialized&&u.onRuntimeInitialized(),Ua()))}u.setStatus?(u.setStatus(\"Running...\"),setTimeout(function(){setTimeout(function(){u.setStatus(\"\")},1),V()},1)):V()}if(u.preInit)for(typeof u.preInit==\"function\"&&(u.preInit=[u.preInit]);u.preInit.length>0;)u.preInit.pop()();C0();var Km;m&&(Km={uncaughtException:process.listeners(\"uncaughtException\").filter(function(F){return!m.uncaughtException.indexOf(F)>-1}),unhandledRejection:process.listeners(\"unhandledRejection\").filter(function(F){return!m.unhandledRejection.indexOf(F)>-1})});var qm;if(typeof WasmBackendModule!=\"undefined\")qm=WasmBackendModule;else if(typeof t!=\"undefined\")qm=t;else throw new Error(\"Could not find wasm module in post.js\");if(Km){var bG=qm._dispose;qm._dispose=function(){bG(),Km.uncaughtException.forEach(function(F){process.removeListener(\"uncaughtException\",F)}),Km.unhandledRejection.forEach(function(F){process.removeListener(\"unhandledRejection\",F)})}}return t.ready}})();typeof Wg==\"object\"&&typeof Wv==\"object\"?Wv.exports=Vv:typeof define==\"function\"&&define.amd?define([],function(){return Vv}):typeof Wg==\"object\"&&(Wg.WasmBackendModuleThreadedSimd=Vv)});var OB=qt((UFt,PB)=>{PB.exports.wasmWorkerContents=`\"use strict\";var Module={};var ENVIRONMENT_IS_NODE=typeof process==\"object\"&&typeof process.versions==\"object\"&&typeof process.versions.node==\"string\";if(ENVIRONMENT_IS_NODE){var nodeWorkerThreads=require(\"worker_threads\");var parentPort=nodeWorkerThreads.parentPort;parentPort.on(\"message\",data=>onmessage({data:data}));var fs=require(\"fs\");Object.assign(global,{self:global,require:require,Module:Module,location:{href:__filename},Worker:nodeWorkerThreads.Worker,importScripts:function(f){(0,eval)(fs.readFileSync(f,\"utf8\")+\"//# sourceURL=\"+f)},postMessage:function(msg){parentPort.postMessage(msg)},performance:global.performance||{now:function(){return Date.now()}}})}var initializedJS=false;var pendingNotifiedProxyingQueues=[];function threadPrintErr(){var text=Array.prototype.slice.call(arguments).join(\" \");if(ENVIRONMENT_IS_NODE){fs.writeSync(2,text+\"\n\");return}console.error(text)}function threadAlert(){var text=Array.prototype.slice.call(arguments).join(\" \");postMessage({cmd:\"alert\",text:text,threadId:Module[\"_pthread_self\"]()})}var err=threadPrintErr;self.alert=threadAlert;Module[\"instantiateWasm\"]=(info,receiveInstance)=>{var instance=new WebAssembly.Instance(Module[\"wasmModule\"],info);receiveInstance(instance);Module[\"wasmModule\"]=null;return instance.exports};self.onunhandledrejection=e=>{throw e.reason??e};self.startWorker=instance=>{Module=instance;postMessage({\"cmd\":\"loaded\"})};self.onmessage=e=>{try{if(e.data.cmd===\"load\"){Module[\"wasmModule\"]=e.data.wasmModule;for(const handler of e.data.handlers){Module[handler]=function(){postMessage({cmd:\"callHandler\",handler:handler,args:[...arguments]})}}Module[\"wasmMemory\"]=e.data.wasmMemory;Module[\"buffer\"]=Module[\"wasmMemory\"].buffer;Module[\"ENVIRONMENT_IS_PTHREAD\"]=true;if(typeof e.data.urlOrBlob==\"string\"){importScripts(e.data.urlOrBlob)}else{var objectUrl=URL.createObjectURL(e.data.urlOrBlob);importScripts(objectUrl);URL.revokeObjectURL(objectUrl)}WasmBackendModuleThreadedSimd(Module)}else if(e.data.cmd===\"run\"){Module[\"__emscripten_thread_init\"](e.data.pthread_ptr,0,0,1);Module[\"establishStackSpace\"]();Module[\"PThread\"].receiveObjectTransfer(e.data);Module[\"PThread\"].threadInitTLS();if(!initializedJS){pendingNotifiedProxyingQueues.forEach(queue=>{Module[\"executeNotifiedProxyingQueue\"](queue)});pendingNotifiedProxyingQueues=[];initializedJS=true}try{Module[\"invokeEntryPoint\"](e.data.start_routine,e.data.arg)}catch(ex){if(ex!=\"unwind\"){if(ex instanceof Module[\"ExitStatus\"]){if(Module[\"keepRuntimeAlive\"]()){}else{Module[\"__emscripten_thread_exit\"](ex.status)}}else{throw ex}}}}else if(e.data.cmd===\"cancel\"){if(Module[\"_pthread_self\"]()){Module[\"__emscripten_thread_exit\"](-1)}}else if(e.data.target===\"setimmediate\"){}else if(e.data.cmd===\"processProxyingQueue\"){if(initializedJS){Module[\"executeNotifiedProxyingQueue\"](e.data.queue)}else{pendingNotifiedProxyingQueues.push(e.data.queue)}}else if(e.data.cmd){err(\"worker.js received unknown command \"+e.data.cmd);err(e.data)}}catch(ex){if(Module[\"__emscripten_thread_crashed\"]){Module[\"__emscripten_thread_crashed\"]()}throw ex}};`});var MB=qt((Ug,Gv)=>{var Uv=(()=>{var r=typeof document!=\"undefined\"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename!=\"undefined\"&&(r=r||__filename),function(t){t=t||{};var e=typeof t!=\"undefined\"?t:{},o,n;e.ready=new Promise(function(K,ae){o=K,n=ae});var s;typeof process!=\"undefined\"&&process.listeners&&(s={uncaughtException:process.listeners(\"uncaughtException\"),unhandledRejection:process.listeners(\"unhandledRejection\")});var a=Object.assign({},e),i=[],p=\"./this.program\",u=(K,ae)=>{throw ae},c=typeof window==\"object\",l=typeof importScripts==\"function\",m=typeof process==\"object\"&&typeof process.versions==\"object\"&&typeof process.versions.node==\"string\",d=\"\";function f(K){return e.locateFile?e.locateFile(K,d):d+K}var h,g,x,b;function C(K){if(K instanceof Bp)return;E(\"exiting due to exception: \"+K)}if(m){var S=Bv(),k=zv();l?d=k.dirname(d)+\"/\":d=__dirname+\"/\",h=(K,ae)=>(K=Ks(K)?new URL(K):k.normalize(K),S.readFileSync(K,ae?void 0:\"utf8\")),x=K=>{var ae=h(K,!0);return ae.buffer||(ae=new Uint8Array(ae)),ae},g=(K,ae,$e)=>{K=Ks(K)?new URL(K):k.normalize(K),S.readFile(K,function(at,$t){at?$e(at):ae($t.buffer)})},process.argv.length>1&&(p=process.argv[1].replace(/\\\\/g,\"/\")),i=process.argv.slice(2),process.on(\"uncaughtException\",function(K){if(!(K instanceof Bp))throw K}),process.on(\"unhandledRejection\",function(K){throw K}),u=(K,ae)=>{if(it())throw process.exitCode=K,ae;C(ae),process.exit(K)},e.inspect=function(){return\"[Emscripten Module object]\"}}else(c||l)&&(l?d=self.location.href:typeof document!=\"undefined\"&&document.currentScript&&(d=document.currentScript.src),r&&(d=r),d.indexOf(\"blob:\")!==0?d=d.substr(0,d.replace(/[?#].*/,\"\").lastIndexOf(\"/\")+1):d=\"\",h=K=>{var ae=new XMLHttpRequest;return ae.open(\"GET\",K,!1),ae.send(null),ae.responseText},l&&(x=K=>{var ae=new XMLHttpRequest;return ae.open(\"GET\",K,!1),ae.responseType=\"arraybuffer\",ae.send(null),new Uint8Array(ae.response)}),g=(K,ae,$e)=>{var at=new XMLHttpRequest;at.open(\"GET\",K,!0),at.responseType=\"arraybuffer\",at.onload=()=>{if(at.status==200||at.status==0&&at.response){ae(at.response);return}$e()},at.onerror=$e,at.send(null)},b=K=>document.title=K);var _=e.print||console.log.bind(console),E=e.printErr||console.warn.bind(console);Object.assign(e,a),a=null,e.arguments&&(i=e.arguments),e.thisProgram&&(p=e.thisProgram),e.quit&&(u=e.quit);var R=4,D;e.wasmBinary&&(D=e.wasmBinary);var P=e.noExitRuntime||!0;typeof WebAssembly!=\"object\"&&hr(\"no native wasm support detected\");var O,M=!1,L;function B(K,ae){K||hr(ae)}var z=typeof TextDecoder!=\"undefined\"?new TextDecoder(\"utf8\"):void 0;function U(K,ae,$e){ae>>>=0;for(var at=ae+$e,$t=ae;K[$t]&&!($t>=at);)++$t;if($t-ae>16&&K.buffer&&z)return z.decode(K.subarray(ae,$t));for(var Et=\"\";ae<$t;){var Qe=K[ae++];if(!(Qe&128)){Et+=String.fromCharCode(Qe);continue}var Ke=K[ae++]&63;if((Qe&224)==192){Et+=String.fromCharCode((Qe&31)<<6|Ke);continue}var Gt=K[ae++]&63;if((Qe&240)==224?Qe=(Qe&15)<<12|Ke<<6|Gt:Qe=(Qe&7)<<18|Ke<<12|Gt<<6|K[ae++]&63,Qe<65536)Et+=String.fromCharCode(Qe);else{var no=Qe-65536;Et+=String.fromCharCode(55296|no>>10,56320|no&1023)}}return Et}function j(K,ae){return K>>>=0,K?U(ne,K,ae):\"\"}function q(K,ae,$e,at){if($e>>>=0,!(at>0))return 0;for(var $t=$e,Et=$e+at-1,Qe=0;Qe=55296&&Ke<=57343){var Gt=K.charCodeAt(++Qe);Ke=65536+((Ke&1023)<<10)|Gt&1023}if(Ke<=127){if($e>=Et)break;ae[$e++>>>0]=Ke}else if(Ke<=2047){if($e+1>=Et)break;ae[$e++>>>0]=192|Ke>>6,ae[$e++>>>0]=128|Ke&63}else if(Ke<=65535){if($e+2>=Et)break;ae[$e++>>>0]=224|Ke>>12,ae[$e++>>>0]=128|Ke>>6&63,ae[$e++>>>0]=128|Ke&63}else{if($e+3>=Et)break;ae[$e++>>>0]=240|Ke>>18,ae[$e++>>>0]=128|Ke>>12&63,ae[$e++>>>0]=128|Ke>>6&63,ae[$e++>>>0]=128|Ke&63}}return ae[$e>>>0]=0,$e-$t}function Y(K,ae,$e){return q(K,ne,ae,$e)}var J,re,ne,ee,oe,ie,le,be,_e;function ve(K){J=K,e.HEAP8=re=new Int8Array(K),e.HEAP16=ee=new Int16Array(K),e.HEAP32=ie=new Int32Array(K),e.HEAPU8=ne=new Uint8Array(K),e.HEAPU16=oe=new Uint16Array(K),e.HEAPU32=le=new Uint32Array(K),e.HEAPF32=be=new Float32Array(K),e.HEAPF64=_e=new Float64Array(K)}var Fe=e.INITIAL_MEMORY||16777216,Pe,st=[],lt=[],Ge=[],mt=!1;function it(){return P}function gt(){if(e.preRun)for(typeof e.preRun==\"function\"&&(e.preRun=[e.preRun]);e.preRun.length;)Lt(e.preRun.shift());Ga(st)}function xt(){mt=!0,Ga(lt)}function Lr(){if(e.postRun)for(typeof e.postRun==\"function\"&&(e.postRun=[e.postRun]);e.postRun.length;)nr(e.postRun.shift());Ga(Ge)}function Lt(K){st.unshift(K)}function to(K){lt.unshift(K)}function nr(K){Ge.unshift(K)}var _t=0,sr=null,ar=null;function ro(K){_t++,e.monitorRunDependencies&&e.monitorRunDependencies(_t)}function oo(K){if(_t--,e.monitorRunDependencies&&e.monitorRunDependencies(_t),_t==0&&(sr!==null&&(clearInterval(sr),sr=null),ar)){var ae=ar;ar=null,ae()}}function hr(K){e.onAbort&&e.onAbort(K),K=\"Aborted(\"+K+\")\",E(K),M=!0,L=1,K+=\". Build with -sASSERTIONS for more info.\";var ae=new WebAssembly.RuntimeError(K);throw n(ae),ae}var Wa=\"data:application/octet-stream;base64,\";function Bo(K){return K.startsWith(Wa)}function Ks(K){return K.startsWith(\"file://\")}var Yt;Yt=\"tfjs-backend-wasm.wasm\",Bo(Yt)||(Yt=f(Yt));function Ua(K){try{if(K==Yt&&D)return new Uint8Array(D);if(x)return x(K);throw\"both async and sync fetching of the wasm failed\"}catch(ae){hr(ae)}}function sl(){if(!D&&(c||l)){if(typeof fetch==\"function\"&&!Ks(Yt))return fetch(Yt,{credentials:\"same-origin\"}).then(function(K){if(!K.ok)throw\"failed to load wasm binary file at '\"+Yt+\"'\";return K.arrayBuffer()}).catch(function(){return Ua(Yt)});if(g)return new Promise(function(K,ae){g(Yt,function($e){K(new Uint8Array($e))},ae)})}return Promise.resolve().then(function(){return Ua(Yt)})}function al(){var K={env:il,wasi_snapshot_preview1:il};function ae(Qe,Ke){var Gt=Qe.exports;e.asm=Gt,O=e.asm.memory,ve(O.buffer),Pe=e.asm.__indirect_function_table,to(e.asm.__wasm_call_ctors),oo(\"wasm-instantiate\")}ro(\"wasm-instantiate\");function $e(Qe){ae(Qe.instance)}function at(Qe){return sl().then(function(Ke){return WebAssembly.instantiate(Ke,K)}).then(function(Ke){return Ke}).then(Qe,function(Ke){E(\"failed to asynchronously prepare wasm: \"+Ke),hr(Ke)})}function $t(){return!D&&typeof WebAssembly.instantiateStreaming==\"function\"&&!Bo(Yt)&&!Ks(Yt)&&!m&&typeof fetch==\"function\"?fetch(Yt,{credentials:\"same-origin\"}).then(function(Qe){var Ke=WebAssembly.instantiateStreaming(Qe,K);return Ke.then($e,function(Gt){return E(\"wasm streaming compile failed: \"+Gt),E(\"falling back to ArrayBuffer instantiation\"),at($e)})}):at($e)}if(e.instantiateWasm)try{var Et=e.instantiateWasm(K,ae);return Et}catch(Qe){E(\"Module.instantiateWasm callback failed with error: \"+Qe),n(Qe)}return $t().catch(n),{}}var l0,Ti;function Bp(K){this.name=\"ExitStatus\",this.message=\"Program terminated with exit(\"+K+\")\",this.status=K}function Ga(K){for(;K.length>0;)K.shift()(e)}function Cy(){hr(\"\")}function wm(){return 4294901760}function $u(){return wm()}function wy(K,ae,$e){ne.copyWithin(K>>>0,ae>>>0,ae+$e>>>0)}function Sm(K){try{return O.grow(K-J.byteLength+65535>>>16),ve(O.buffer),1}catch(ae){}}function zp(K){var ae=ne.length;K=K>>>0;var $e=wm();if(K>$e)return!1;let at=(Gt,no)=>Gt+(no-Gt%no)%no;for(var $t=1;$t<=4;$t*=2){var Et=ae*(1+.2/$t);Et=Math.min(Et,K+100663296);var Qe=Math.min($e,at(Math.max(K,Et),65536)),Ke=Sm(Qe);if(Ke)return!0}return!1}var gr={varargs:void 0,get:function(){gr.varargs+=4;var K=ie[gr.varargs-4>>>2];return K},getStr:function(K){var ae=j(K);return ae}};function Im(K){return 52}function Sy(K,ae,$e,at,$t){return 70}var Iy=[null,[],[]];function m0(K,ae){var $e=Iy[K];ae===0||ae===10?((K===1?_:E)(U($e,0)),$e.length=0):$e.push(ae)}function d0(K,ae,$e,at){for(var $t=0,Et=0;Et<$e;Et++){var Qe=le[ae>>>2],Ke=le[ae+4>>>2];ae+=8;for(var Gt=0;Gt>>0]);$t+=Ke}return le[at>>>2]=$t,0}function vm(K){var ae=e[\"_\"+K];return ae}function Eu(K,ae){re.set(K,ae>>>0)}function vy(K,ae,$e,at,$t){var Et={string:br=>{var $i=0;if(br!=null&&br!==0){var Vm=(br.length<<2)+1;$i=ml(Vm),Y(br,$i,Vm)}return $i},array:br=>{var $i=ml(br.length);return Eu(br,$i),$i}};function Qe(br){return ae===\"string\"?j(br):ae===\"boolean\"?!!br:br}var Ke=vm(K),Gt=[],no=0;if(at)for(var Ha=0;HaQe===\"number\"||Qe===\"boolean\"),Et=ae!==\"string\";return Et&&$t&&!at?vm(K):function(){return vy(K,ae,$e,arguments,at)}}var il={abort:Cy,emscripten_get_heap_max:$u,emscripten_memcpy_big:wy,emscripten_resize_heap:zp,fd_close:Im,fd_seek:Sy,fd_write:d0},Ny=al(),km=e.___wasm_call_ctors=function(){return(km=e.___wasm_call_ctors=e.asm.__wasm_call_ctors).apply(null,arguments)},Nm=e._init=function(){return(Nm=e._init=e.asm.init).apply(null,arguments)},Ty=e._init_with_threads_count=function(){return(Ty=e._init_with_threads_count=e.asm.init_with_threads_count).apply(null,arguments)},Tm=e._get_threads_count=function(){return(Tm=e._get_threads_count=e.asm.get_threads_count).apply(null,arguments)},_y=e._register_tensor=function(){return(_y=e._register_tensor=e.asm.register_tensor).apply(null,arguments)},Me=e._dispose_data=function(){return(Me=e._dispose_data=e.asm.dispose_data).apply(null,arguments)},ul=e._dispose=function(){return(ul=e._dispose=e.asm.dispose).apply(null,arguments)},$y=e._Abs=function(){return($y=e._Abs=e.asm.Abs).apply(null,arguments)},_m=e._Acos=function(){return(_m=e._Acos=e.asm.Acos).apply(null,arguments)},Vp=e._Acosh=function(){return(Vp=e._Acosh=e.asm.Acosh).apply(null,arguments)},Ey=e._Add=function(){return(Ey=e._Add=e.asm.Add).apply(null,arguments)},Ry=e._AddN=function(){return(Ry=e._AddN=e.asm.AddN).apply(null,arguments)},Dy=e._All=function(){return(Dy=e._All=e.asm.All).apply(null,arguments)},Ay=e._Any=function(){return(Ay=e._Any=e.asm.Any).apply(null,arguments)},Fy=e._ArgMax=function(){return(Fy=e._ArgMax=e.asm.ArgMax).apply(null,arguments)},$m=e._ArgMin=function(){return($m=e._ArgMin=e.asm.ArgMin).apply(null,arguments)},Em=e._Asin=function(){return(Em=e._Asin=e.asm.Asin).apply(null,arguments)},Py=e._Asinh=function(){return(Py=e._Asinh=e.asm.Asinh).apply(null,arguments)},Oy=e._Atan=function(){return(Oy=e._Atan=e.asm.Atan).apply(null,arguments)},My=e._Atan2=function(){return(My=e._Atan2=e.asm.Atan2).apply(null,arguments)},pl=e._Atanh=function(){return(pl=e._Atanh=e.asm.Atanh).apply(null,arguments)},Ly=e._AvgPool=function(){return(Ly=e._AvgPool=e.asm.AvgPool).apply(null,arguments)},By=e._AvgPool3D=function(){return(By=e._AvgPool3D=e.asm.AvgPool3D).apply(null,arguments)},zy=e._AvgPool3DGrad=function(){return(zy=e._AvgPool3DGrad=e.asm.AvgPool3DGrad).apply(null,arguments)},Ru=e._AvgPoolGrad=function(){return(Ru=e._AvgPoolGrad=e.asm.AvgPoolGrad).apply(null,arguments)},Vy=e._BatchMatMul=function(){return(Vy=e._BatchMatMul=e.asm.BatchMatMul).apply(null,arguments)},Wy=e._Bincount=function(){return(Wy=e._Bincount=e.asm.Bincount).apply(null,arguments)},Rm=e._BitwiseAnd=function(){return(Rm=e._BitwiseAnd=e.asm.BitwiseAnd).apply(null,arguments)},Uy=e._Ceil=function(){return(Uy=e._Ceil=e.asm.Ceil).apply(null,arguments)},cl=e._ClipByValue=function(){return(cl=e._ClipByValue=e.asm.ClipByValue).apply(null,arguments)},Gy=e._Conv2D=function(){return(Gy=e._Conv2D=e.asm.Conv2D).apply(null,arguments)},Hy=e._Conv2DBackpropInput=function(){return(Hy=e._Conv2DBackpropInput=e.asm.Conv2DBackpropInput).apply(null,arguments)},Ky=e._Conv3D=function(){return(Ky=e._Conv3D=e.asm.Conv3D).apply(null,arguments)},_i=e._Conv3DBackpropFilterV2=function(){return(_i=e._Conv3DBackpropFilterV2=e.asm.Conv3DBackpropFilterV2).apply(null,arguments)},ll=e._Conv3DBackpropInputV2=function(){return(ll=e._Conv3DBackpropInputV2=e.asm.Conv3DBackpropInputV2).apply(null,arguments)},qy=e._Cos=function(){return(qy=e._Cos=e.asm.Cos).apply(null,arguments)},jy=e._Cosh=function(){return(jy=e._Cosh=e.asm.Cosh).apply(null,arguments)},Xy=e._CropAndResize=function(){return(Xy=e._CropAndResize=e.asm.CropAndResize).apply(null,arguments)},Yy=e._Cumprod=function(){return(Yy=e._Cumprod=e.asm.Cumprod).apply(null,arguments)},Dm=e._Cumsum=function(){return(Dm=e._Cumsum=e.asm.Cumsum).apply(null,arguments)},Am=e._DenseBincount=function(){return(Am=e._DenseBincount=e.asm.DenseBincount).apply(null,arguments)},Qy=e._DepthToSpace=function(){return(Qy=e._DepthToSpace=e.asm.DepthToSpace).apply(null,arguments)},Zy=e._DepthwiseConv2dNative=function(){return(Zy=e._DepthwiseConv2dNative=e.asm.DepthwiseConv2dNative).apply(null,arguments)},Fm=e._Diag=function(){return(Fm=e._Diag=e.asm.Diag).apply(null,arguments)},Pm=e._Dilation2D=function(){return(Pm=e._Dilation2D=e.asm.Dilation2D).apply(null,arguments)},Jy=e._Dilation2DBackpropFilter=function(){return(Jy=e._Dilation2DBackpropFilter=e.asm.Dilation2DBackpropFilter).apply(null,arguments)},eb=e._Dilation2DBackpropInput=function(){return(eb=e._Dilation2DBackpropInput=e.asm.Dilation2DBackpropInput).apply(null,arguments)},tb=e._Elu=function(){return(tb=e._Elu=e.asm.Elu).apply(null,arguments)},rb=e._EluGrad=function(){return(rb=e._EluGrad=e.asm.EluGrad).apply(null,arguments)},Om=e._Equal=function(){return(Om=e._Equal=e.asm.Equal).apply(null,arguments)},f0=e._Erf=function(){return(f0=e._Erf=e.asm.Erf).apply(null,arguments)},ob=e._Exp=function(){return(ob=e._Exp=e.asm.Exp).apply(null,arguments)},nb=e._Expm1=function(){return(nb=e._Expm1=e.asm.Expm1).apply(null,arguments)},sb=e._FlipLeftRight=function(){return(sb=e._FlipLeftRight=e.asm.FlipLeftRight).apply(null,arguments)},ab=e._Floor=function(){return(ab=e._Floor=e.asm.Floor).apply(null,arguments)},ib=e._FloorDiv=function(){return(ib=e._FloorDiv=e.asm.FloorDiv).apply(null,arguments)},ub=e._FusedBatchNorm=function(){return(ub=e._FusedBatchNorm=e.asm.FusedBatchNorm).apply(null,arguments)},pb=e._FusedConv2D=function(){return(pb=e._FusedConv2D=e.asm.FusedConv2D).apply(null,arguments)},cb=e._FusedDepthwiseConv2D=function(){return(cb=e._FusedDepthwiseConv2D=e.asm.FusedDepthwiseConv2D).apply(null,arguments)},lb=e._Gather=function(){return(lb=e._Gather=e.asm.Gather).apply(null,arguments)},mb=e._GatherNd=function(){return(mb=e._GatherNd=e.asm.GatherNd).apply(null,arguments)},db=e._Greater=function(){return(db=e._Greater=e.asm.Greater).apply(null,arguments)},fb=e._GreaterEqual=function(){return(fb=e._GreaterEqual=e.asm.GreaterEqual).apply(null,arguments)},hb=e._IsFinite=function(){return(hb=e._IsFinite=e.asm.IsFinite).apply(null,arguments)},gb=e._IsInf=function(){return(gb=e._IsInf=e.asm.IsInf).apply(null,arguments)},xb=e._IsNan=function(){return(xb=e._IsNan=e.asm.IsNan).apply(null,arguments)},yb=e._LRN=function(){return(yb=e._LRN=e.asm.LRN).apply(null,arguments)},bb=e._LRNGrad=function(){return(bb=e._LRNGrad=e.asm.LRNGrad).apply(null,arguments)},Cb=e._LeakyRelu=function(){return(Cb=e._LeakyRelu=e.asm.LeakyRelu).apply(null,arguments)},wb=e._Less=function(){return(wb=e._Less=e.asm.Less).apply(null,arguments)},Sb=e._LessEqual=function(){return(Sb=e._LessEqual=e.asm.LessEqual).apply(null,arguments)},Ib=e._LinSpace=function(){return(Ib=e._LinSpace=e.asm.LinSpace).apply(null,arguments)},vb=e._Log=function(){return(vb=e._Log=e.asm.Log).apply(null,arguments)},kb=e._Log1p=function(){return(kb=e._Log1p=e.asm.Log1p).apply(null,arguments)},Nb=e._LogicalAnd=function(){return(Nb=e._LogicalAnd=e.asm.LogicalAnd).apply(null,arguments)},Tb=e._LogicalNot=function(){return(Tb=e._LogicalNot=e.asm.LogicalNot).apply(null,arguments)},_b=e._LogicalOr=function(){return(_b=e._LogicalOr=e.asm.LogicalOr).apply(null,arguments)},$b=e._LogicalXor=function(){return($b=e._LogicalXor=e.asm.LogicalXor).apply(null,arguments)},Eb=e._Max=function(){return(Eb=e._Max=e.asm.Max).apply(null,arguments)},Rb=e._MaxPool=function(){return(Rb=e._MaxPool=e.asm.MaxPool).apply(null,arguments)},Db=e._MaxPool3D=function(){return(Db=e._MaxPool3D=e.asm.MaxPool3D).apply(null,arguments)},Ab=e._MaxPool3DGrad=function(){return(Ab=e._MaxPool3DGrad=e.asm.MaxPool3DGrad).apply(null,arguments)},Fb=e._MaxPoolGrad=function(){return(Fb=e._MaxPoolGrad=e.asm.MaxPoolGrad).apply(null,arguments)},Pb=e._MaxPoolWithArgmax=function(){return(Pb=e._MaxPoolWithArgmax=e.asm.MaxPoolWithArgmax).apply(null,arguments)},Ob=e._Maximum=function(){return(Ob=e._Maximum=e.asm.Maximum).apply(null,arguments)},Mb=e._Mean=function(){return(Mb=e._Mean=e.asm.Mean).apply(null,arguments)},Lb=e._Min=function(){return(Lb=e._Min=e.asm.Min).apply(null,arguments)},Bb=e._Minimum=function(){return(Bb=e._Minimum=e.asm.Minimum).apply(null,arguments)},zb=e._MirrorPad=function(){return(zb=e._MirrorPad=e.asm.MirrorPad).apply(null,arguments)},Vb=e._Mod=function(){return(Vb=e._Mod=e.asm.Mod).apply(null,arguments)},Wb=e._Multinomial=function(){return(Wb=e._Multinomial=e.asm.Multinomial).apply(null,arguments)},Ub=e._Multiply=function(){return(Ub=e._Multiply=e.asm.Multiply).apply(null,arguments)},Gb=e._Neg=function(){return(Gb=e._Neg=e.asm.Neg).apply(null,arguments)},Hb=e._NonMaxSuppressionV3=function(){return(Hb=e._NonMaxSuppressionV3=e.asm.NonMaxSuppressionV3).apply(null,arguments)},Kb=e._NonMaxSuppressionV4=function(){return(Kb=e._NonMaxSuppressionV4=e.asm.NonMaxSuppressionV4).apply(null,arguments)},qb=e._NonMaxSuppressionV5=function(){return(qb=e._NonMaxSuppressionV5=e.asm.NonMaxSuppressionV5).apply(null,arguments)},jb=e._NotEqual=function(){return(jb=e._NotEqual=e.asm.NotEqual).apply(null,arguments)},Xb=e._OneHot=function(){return(Xb=e._OneHot=e.asm.OneHot).apply(null,arguments)},Yb=e._PadV2=function(){return(Yb=e._PadV2=e.asm.PadV2).apply(null,arguments)},Qb=e._Pow=function(){return(Qb=e._Pow=e.asm.Pow).apply(null,arguments)},Zb=e._Prelu=function(){return(Zb=e._Prelu=e.asm.Prelu).apply(null,arguments)},Jb=e._Prod=function(){return(Jb=e._Prod=e.asm.Prod).apply(null,arguments)},eC=e._RealDiv=function(){return(eC=e._RealDiv=e.asm.RealDiv).apply(null,arguments)},tC=e._Reciprocal=function(){return(tC=e._Reciprocal=e.asm.Reciprocal).apply(null,arguments)},rC=e._Relu=function(){return(rC=e._Relu=e.asm.Relu).apply(null,arguments)},oC=e._Relu6=function(){return(oC=e._Relu6=e.asm.Relu6).apply(null,arguments)},nC=e._ResizeBilinear=function(){return(nC=e._ResizeBilinear=e.asm.ResizeBilinear).apply(null,arguments)},sC=e._ResizeBilinearGrad=function(){return(sC=e._ResizeBilinearGrad=e.asm.ResizeBilinearGrad).apply(null,arguments)},aC=e._ResizeNearestNeighbor=function(){return(aC=e._ResizeNearestNeighbor=e.asm.ResizeNearestNeighbor).apply(null,arguments)},iC=e._ResizeNearestNeighborGrad=function(){return(iC=e._ResizeNearestNeighborGrad=e.asm.ResizeNearestNeighborGrad).apply(null,arguments)},uC=e._Reverse=function(){return(uC=e._Reverse=e.asm.Reverse).apply(null,arguments)},pC=e._RotateWithOffset=function(){return(pC=e._RotateWithOffset=e.asm.RotateWithOffset).apply(null,arguments)},cC=e._Round=function(){return(cC=e._Round=e.asm.Round).apply(null,arguments)},lC=e._Rsqrt=function(){return(lC=e._Rsqrt=e.asm.Rsqrt).apply(null,arguments)},mC=e._ScatterNd=function(){return(mC=e._ScatterNd=e.asm.ScatterNd).apply(null,arguments)},dC=e._SearchSorted=function(){return(dC=e._SearchSorted=e.asm.SearchSorted).apply(null,arguments)},fC=e._SelectV2=function(){return(fC=e._SelectV2=e.asm.SelectV2).apply(null,arguments)},hC=e._Selu=function(){return(hC=e._Selu=e.asm.Selu).apply(null,arguments)},gC=e._Sigmoid=function(){return(gC=e._Sigmoid=e.asm.Sigmoid).apply(null,arguments)},xC=e._Sign=function(){return(xC=e._Sign=e.asm.Sign).apply(null,arguments)},yC=e._Sin=function(){return(yC=e._Sin=e.asm.Sin).apply(null,arguments)},bC=e._Sinh=function(){return(bC=e._Sinh=e.asm.Sinh).apply(null,arguments)},CC=e._Softmax=function(){return(CC=e._Softmax=e.asm.Softmax).apply(null,arguments)},wC=e._Softplus=function(){return(wC=e._Softplus=e.asm.Softplus).apply(null,arguments)},SC=e._SparseFillEmptyRows=function(){return(SC=e._SparseFillEmptyRows=e.asm.SparseFillEmptyRows).apply(null,arguments)},IC=e._SparseReshape=function(){return(IC=e._SparseReshape=e.asm.SparseReshape).apply(null,arguments)},vC=e._SparseSegmentReduction=function(){return(vC=e._SparseSegmentReduction=e.asm.SparseSegmentReduction).apply(null,arguments)},kC=e._SparseToDense=function(){return(kC=e._SparseToDense=e.asm.SparseToDense).apply(null,arguments)},NC=e._Sqrt=function(){return(NC=e._Sqrt=e.asm.Sqrt).apply(null,arguments)},TC=e._Square=function(){return(TC=e._Square=e.asm.Square).apply(null,arguments)},_C=e._SquaredDifference=function(){return(_C=e._SquaredDifference=e.asm.SquaredDifference).apply(null,arguments)},$C=e._Step=function(){return($C=e._Step=e.asm.Step).apply(null,arguments)},EC=e._StridedSlice=function(){return(EC=e._StridedSlice=e.asm.StridedSlice).apply(null,arguments)},RC=e._Sub=function(){return(RC=e._Sub=e.asm.Sub).apply(null,arguments)},DC=e._Sum=function(){return(DC=e._Sum=e.asm.Sum).apply(null,arguments)},AC=e._Tan=function(){return(AC=e._Tan=e.asm.Tan).apply(null,arguments)},FC=e._Tanh=function(){return(FC=e._Tanh=e.asm.Tanh).apply(null,arguments)},PC=e._TensorScatterUpdate=function(){return(PC=e._TensorScatterUpdate=e.asm.TensorScatterUpdate).apply(null,arguments)},OC=e._Tile=function(){return(OC=e._Tile=e.asm.Tile).apply(null,arguments)},MC=e._TopK=function(){return(MC=e._TopK=e.asm.TopK).apply(null,arguments)},LC=e._Transform=function(){return(LC=e._Transform=e.asm.Transform).apply(null,arguments)},BC=e._Transpose=function(){return(BC=e._Transpose=e.asm.Transpose).apply(null,arguments)},zC=e.__FusedMatMul=function(){return(zC=e.__FusedMatMul=e.asm._FusedMatMul).apply(null,arguments)},VC=e._malloc=function(){return(VC=e._malloc=e.asm.malloc).apply(null,arguments)},WC=e._free=function(){return(WC=e._free=e.asm.free).apply(null,arguments)},UC=e.___errno_location=function(){return(UC=e.___errno_location=e.asm.__errno_location).apply(null,arguments)},Mm=e.stackSave=function(){return(Mm=e.stackSave=e.asm.stackSave).apply(null,arguments)},Lm=e.stackRestore=function(){return(Lm=e.stackRestore=e.asm.stackRestore).apply(null,arguments)},ml=e.stackAlloc=function(){return(ml=e.stackAlloc=e.asm.stackAlloc).apply(null,arguments)},GC=e.dynCall_iijjiiii=function(){return(GC=e.dynCall_iijjiiii=e.asm.dynCall_iijjiiii).apply(null,arguments)},HC=e.dynCall_jiji=function(){return(HC=e.dynCall_jiji=e.asm.dynCall_jiji).apply(null,arguments)};e.cwrap=ky;var Wp;ar=function K(){Wp||Bm(),Wp||(ar=K)};function Bm(K){if(K=K||i,_t>0||(gt(),_t>0))return;function ae(){Wp||(Wp=!0,e.calledRun=!0,!M&&(xt(),o(e),e.onRuntimeInitialized&&e.onRuntimeInitialized(),Lr()))}e.setStatus?(e.setStatus(\"Running...\"),setTimeout(function(){setTimeout(function(){e.setStatus(\"\")},1),ae()},1)):ae()}if(e.preInit)for(typeof e.preInit==\"function\"&&(e.preInit=[e.preInit]);e.preInit.length>0;)e.preInit.pop()();Bm();var Up;s&&(Up={uncaughtException:process.listeners(\"uncaughtException\").filter(function(K){return!s.uncaughtException.indexOf(K)>-1}),unhandledRejection:process.listeners(\"unhandledRejection\").filter(function(K){return!s.unhandledRejection.indexOf(K)>-1})});var Gp;if(typeof t!=\"undefined\")Gp=t;else if(typeof WasmBackendModuleThreadedSimd!=\"undefined\")Gp=WasmBackendModuleThreadedSimd;else throw new Error(\"Could not find wasm module in post.js\");if(Up){var KC=Gp._dispose;Gp._dispose=function(){KC(),Up.uncaughtException.forEach(function(K){process.removeListener(\"uncaughtException\",K)}),Up.unhandledRejection.forEach(function(K){process.removeListener(\"unhandledRejection\",K)})}}return t.ready}})();typeof Ug==\"object\"&&typeof Gv==\"object\"?Gv.exports=Uv:typeof define==\"function\"&&define.amd?define([],function(){return Uv}):typeof Ug==\"object\"&&(Ug.WasmBackendModule=Uv)});var zo=class{constructor(t,e){this.backend=t,this.dataMover=e,this.data=new WeakMap,this.dataIdsCount=0}get(t){return this.data.has(t)||this.dataMover.moveData(this.backend,t),this.data.get(t)}set(t,e){this.dataIdsCount++,this.data.set(t,e)}has(t){return this.data.has(t)}delete(t){return this.dataIdsCount--,this.data.delete(t)}numDataIds(){return this.dataIdsCount}},ao=class{refCount(t){return zr(\"refCount\")}incRef(t){return zr(\"incRef\")}timerAvailable(){return!0}time(t){return zr(\"time\")}read(t){return zr(\"read\")}readSync(t){return zr(\"readSync\")}readToGPU(t,e){return zr(\"readToGPU\")}numDataIds(){return zr(\"numDataIds\")}disposeData(t,e){return zr(\"disposeData\")}write(t,e,o){return zr(\"write\")}move(t,e,o,n,s){return zr(\"move\")}createTensorFromGPUData(t,e,o){return zr(\"createTensorFromGPUData\")}memory(){return zr(\"memory\")}floatPrecision(){return zr(\"floatPrecision\")}epsilon(){return this.floatPrecision()===32?1e-7:1e-4}dispose(){return zr(\"dispose\")}};function zr(r){throw new Error(`'${r}' not yet implemented or not found in the registry. This kernel may not be supported by the tfjs backend you have chosen`)}function I0(r){let t=r.length,e=0;for(;t>0;)e=Math.random()*t|0,t--,jm(r,t,e)}function TG(r,t){if(r.length!==t.length)throw new Error(`Array sizes must match to be shuffled together First array length was ${r.length}Second array length was ${t.length}`);let e=r.length,o=0;for(;e>0;)o=Math.random()*e|0,e--,jm(r,e,o),jm(t,e,o)}function qp(r,t,e){return Math.max(r,Math.min(t,e))}function _G(r){return r%2===0?r:r+1}function jm(r,t,e){let o=r[t];r[t]=r[e],r[e]=o}function $G(r){let t=0;for(let e=0;ee+` Shapes ${r} and ${t} must match`)}function io(r){$(r!=null,()=>\"The input to the tensor constructor must be a non-null value.\")}function He(r){if(r.length===0)return 1;let t=r[0];for(let e=1;e0,e,o){return new Promise((n,s)=>{let a=0,i=()=>{if(r()){n();return}a++;let p=t(a);if(e!=null&&a>=e){s();return}o!=null?o(i,p):setTimeout(i,p)};i()})}function MG(r,t){let e=1,o=-1;for(let s=0;s=0)e*=r[s];else if(r[s]===-1){if(o!==-1)throw Error(`Shapes can only have 1 implicit size. Found -1 at dim ${o} and dim ${s}`);o=s}else if(r[s]<0)throw Error(`Shapes can not be < 0. Found ${r[s]} at dim ${s}`);if(o===-1){if(t>0&&t!==e)throw Error(`Size(${t}) must match the product of shape ${r}`);return r}if(e===0)throw Error(`Cannot infer the missing size in [${r}] when there are 0 elements`);if(t%e!==0)throw Error(`The implicit shape can't be a fractional number. Got ${t} / ${e}`);let n=r.slice();return n[o]=t/e,n}function Ei(r,t){let e=t.length;return r=r==null?t.map((o,n)=>n):[].concat(r),$(r.every(o=>o>=-e&&o`All values in axis param must be in range [-${e}, ${e}) but got axis ${r}`),$(r.every(o=>qa(o)),()=>`All values in axis param must be integers but got axis ${r}`),r.map(o=>o<0?e+o:o)}function JC(r,t){let e=[],o=[],n=t!=null&&Array.isArray(t)&&t.length===0,s=t==null||n?null:Ei(t,r).sort(),a=0;for(let i=0;ii)&&r[i]===1&&(e.push(r[i]),o.push(i)),s[a]<=i&&a++}r[i]!==1&&(e.push(r[i]),o.push(i))}return{newShape:e,keptDims:o}}function ew(r,t){return Xm(r,t)}function Xm(r,t){let e=null;if(r==null||r===\"float32\")e=new Float32Array(t);else if(r===\"int32\")e=new Int32Array(t);else if(r===\"bool\")e=new Uint8Array(t);else if(r===\"string\")e=new Array(t);else throw new Error(`Unknown data type ${r}`);return e}function tw(r,t){for(let e=0;et+=e.length),t}function Vo(r){return typeof r==\"string\"||r instanceof String}function v0(r){return typeof r==\"boolean\"}function k0(r){return typeof r==\"number\"}function Ri(r){return Array.isArray(r)?Ri(r[0]):r instanceof Float32Array?\"float32\":r instanceof Int32Array||r instanceof Uint8Array||r instanceof Uint8ClampedArray?\"int32\":k0(r)?\"float32\":Vo(r)?\"string\":v0(r)?\"bool\":\"float32\"}function qs(r){return!!(r&&r.constructor&&r.call&&r.apply)}function Xp(r,t){for(let e=t;e=0;--o)e[o]=e[o+1]*r[o+1];return e}function N0(r,t,e,o=!1){let n=new Array;if(t.length===1){let s=t[0]*(o?2:1);for(let a=0;ap*u)*(o?2:1);for(let p=0;pn*s)*(e?2:1);if(o===0)return[];if(o!==t.length)throw new Error(`[${r}] does not match the input size ${t.length}${e?\" for a complex tensor\":\"\"}.`);return N0(0,r,t,e)}function BG(r,t){if(Array.isArray(r))return r;if(t===\"float32\")return r instanceof Float32Array?r:new Float32Array(r);if(t===\"int32\")return r instanceof Int32Array?r:new Int32Array(r);if(t===\"bool\"||t===\"string\")return Uint8Array.from(new Int32Array(r));throw new Error(`Unknown dtype ${t}`)}function fl(r,t){let e=Yp(r,t);for(let o=0;oo*n,1);if(t==null||t===\"float32\")return Du(r,new Float32Array(e));if(t===\"int32\")return Du(r,new Int32Array(e));if(t===\"bool\")return Du(r,new Uint8Array(e));throw new Error(`Unknown data type ${t}`)}function wt(r){r.forEach(t=>{$(Number.isInteger(t)&&t>=0,()=>`Tensor must have a shape comprised of positive integers but got shape [${r}].`)})}function VG(r,t,e){if(t===0)return 0;if(t===1)return r[0];let o=r[r.length-1];for(let n=0;n{let[n,s]=o.split(\":\");this.urlFlags[n]=KG(n,s)})}};function GG(r){let t={};return r.replace(/[?&]([^=?&]+)(?:=([^&]*))?/g,(e,...o)=>(HG(t,o[0],o[1]),o.join(\"=\"))),t}function HG(r,t,e){r[decodeURIComponent(t)]=decodeURIComponent(e||\"\")}function KG(r,t){let e=t.toLowerCase();return e===\"true\"||e===\"false\"?e===\"true\":`${+e}`===e?+e:t}function A(){return nw}var nw=null;function _0(r){nw=r}var sw;function aw(){if(sw==null){let r;if(typeof window!=\"undefined\")r=window;else if(typeof global!=\"undefined\")r=global;else if(typeof process!=\"undefined\")r=process;else if(typeof self!=\"undefined\")r=self;else throw new Error(\"Could not find a global object\");sw=r}return sw}function qG(){let r=aw();return r._tfGlobals==null&&(r._tfGlobals=new Map),r._tfGlobals}function gl(r,t){let e=qG();if(e.has(r))return e.get(r);{let o=t();return e.set(r,o),e.get(r)}}var Xs=\"Abs\",Wo=\"Acos\",Uo=\"Acosh\",uo=\"Add\",Go=\"AddN\",Ho=\"All\",Ko=\"Any\",Ys=\"ArgMax\",Qs=\"ArgMin\",qo=\"Asin\",jo=\"Asinh\",Xo=\"Atan\",Yo=\"Atanh\",Qo=\"Atan2\",Zo=\"AvgPool\",Di=\"AvgPoolGrad\",Zs=\"AvgPool3D\",Ai=\"AvgPool3DGrad\",Jo=\"BatchMatMul\",Js=\"BatchToSpaceND\",en=\"Bincount\",ja=\"BitwiseAnd\",Bce=\"BroadcastTo\",ea=\"BroadcastArgs\",bo=\"Cast\",tn=\"Ceil\",Co=\"ClipByValue\",Fi=\"Complex\",Pi=\"ComplexAbs\",ta=\"Concat\",rn=\"Conv2D\",Oi=\"Conv2DBackpropFilter\",on=\"Conv2DBackpropInput\",nn=\"Conv3D\",Xa=\"Conv3DBackpropFilterV2\",sn=\"Conv3DBackpropInputV2\",an=\"Cos\",un=\"Cosh\",pn=\"Cumprod\",cn=\"Cumsum\",ln=\"CropAndResize\",ra=\"DenseBincount\",mn=\"DepthToSpace\",dn=\"DepthwiseConv2dNative\",Mi=\"DepthwiseConv2dNativeBackpropFilter\",Li=\"DepthwiseConv2dNativeBackpropInput\",oa=\"Diag\",fn=\"Dilation2D\",Bi=\"Dilation2DBackpropInput\",zi=\"Dilation2DBackpropFilter\",Pu=\"Draw\",hn=\"RealDiv\",Vi=\"Einsum\",gn=\"Elu\",Ya=\"EluGrad\",xn=\"Erf\",yn=\"Equal\",bn=\"Exp\",na=\"ExpandDims\",Cn=\"Expm1\",Wi=\"FFT\",sa=\"Fill\",wn=\"FlipLeftRight\",Sn=\"Floor\",In=\"FloorDiv\",vn=\"FusedBatchNorm\",aa=\"GatherV2\",kn=\"GatherNd\",Nn=\"Greater\",Tn=\"GreaterEqual\",wo=\"Identity\",Ui=\"IFFT\",Gi=\"Imag\",_n=\"IsFinite\",$n=\"IsInf\",En=\"IsNan\",Rn=\"LeakyRelu\",Dn=\"Less\",An=\"LessEqual\",Fn=\"LinSpace\",Pn=\"Log\",On=\"Log1p\",Mn=\"LogicalAnd\",Ln=\"LogicalNot\",Bn=\"LogicalOr\",$0=\"LogicalXor\",zce=\"LogSoftmax\",Vce=\"LowerBound\",zn=\"LRN\",Qa=\"LRNGrad\",Wce=\"MatrixBandPart\",Vn=\"Max\",Wn=\"Maximum\",Un=\"MaxPool\",Hi=\"MaxPoolGrad\",ia=\"MaxPool3D\",Ki=\"MaxPool3DGrad\",ua=\"MaxPoolWithArgmax\",Gn=\"Mean\",Hn=\"Min\",Kn=\"Minimum\",qn=\"MirrorPad\",jn=\"Mod\",Xn=\"Multinomial\",Yn=\"Multiply\",pa=\"Neg\",Qn=\"NotEqual\",Zn=\"NonMaxSuppressionV3\",Za=\"NonMaxSuppressionV4\",Jn=\"NonMaxSuppressionV5\",ca=\"OnesLike\",es=\"OneHot\",la=\"Pack\",ts=\"PadV2\",Uce=\"Pool\",rs=\"Pow\",os=\"Prelu\",ns=\"Prod\",Qp=\"RaggedGather\",Zp=\"RaggedRange\",Jp=\"RaggedTensorToTensor\",ma=\"Range\",qi=\"Real\",ss=\"Reciprocal\",as=\"Relu\",da=\"Reshape\",is=\"ResizeNearestNeighbor\",Ja=\"ResizeNearestNeighborGrad\",us=\"ResizeBilinear\",ei=\"ResizeBilinearGrad\",ps=\"Relu6\",cs=\"Reverse\",ls=\"Round\",ms=\"Rsqrt\",ds=\"ScatterNd\",fs=\"TensorScatterUpdate\",hs=\"SearchSorted\",fa=\"Select\",gs=\"Selu\",ha=\"Slice\",xs=\"Sin\",ys=\"Sinh\",bs=\"Sign\",Cs=\"Sigmoid\",ws=\"Softplus\",Ss=\"Sqrt\",Is=\"Sum\",ga=\"SpaceToBatchND\",xa=\"SplitV\",vs=\"Softmax\",ji=\"SparseFillEmptyRows\",ti=\"SparseReshape\",ya=\"SparseSegmentMean\",ba=\"SparseSegmentSum\",ks=\"SparseToDense\",Ns=\"SquaredDifference\",Xi=\"Square\",Ou=\"StaticRegexReplace\",Ts=\"StridedSlice\",Ca=\"StringNGrams\",Yi=\"StringSplit\",Qi=\"StringToHashBucketFast\",_s=\"Sub\",$s=\"Tan\",Es=\"Tanh\",po=\"Tile\",Rs=\"TopK\",Ds=\"Transform\",co=\"Transpose\",Zi=\"Unique\",wa=\"Unpack\",Ji=\"UnsortedSegmentSum\",Gce=\"UpperBound\",Sa=\"ZerosLike\",So=\"Step\",Mu=\"FromPixels\",As=\"RotateWithOffset\",Io=\"_FusedMatMul\",vo=\"FusedConv2D\",ko=\"FusedDepthwiseConv2D\";function Ia(...r){A().getBool(\"IS_TEST\")||A().getBool(\"PROD\")||console.warn(...r)}function jG(...r){A().getBool(\"IS_TEST\")||A().getBool(\"PROD\")||console.log(...r)}var ec=gl(\"kernelRegistry\",()=>new Map),xl=gl(\"gradRegistry\",()=>new Map);function tc(r,t){let e=uw(r,t);return ec.get(e)}function iw(r){return xl.get(r)}function Ym(r){let t=ec.entries(),e=[];for(;;){let{done:o,value:n}=t.next();if(o)break;let[s,a]=n,[i]=s.split(\"_\");i===r&&e.push(a)}return e}function ri(r){let{kernelName:t,backendName:e}=r,o=uw(t,e);ec.has(o)&&Ia(`The kernel '${t}' for backend '${e}' is already registered`),ec.set(o,r)}function Xce(r){let{kernelName:t}=r;xl.has(t)&&A().getBool(\"DEBUG\")&&Ia(`Overriding the gradient for '${t}'`),xl.set(t,r)}function Yce(r,t){let e=uw(r,t);if(!ec.has(e))throw new Error(`The kernel '${r}' for backend '${t}' is not registered`);ec.delete(e)}function Qce(r){if(!xl.has(r))throw new Error(`The gradient '${r}' for backend is not registered`);xl.delete(r)}function Zce(r,t){Ym(r).forEach(o=>{let n=Object.assign({},o,{backendName:t});ri(n)})}function uw(r,t){return`${t}_${r}`}var y={};qe(y,{arraysEqual:()=>Cr,arraysEqualWithNull:()=>ZC,assert:()=>$,assertNonNegativeIntegerDimensions:()=>wt,assertNonNull:()=>io,assertShapesMatch:()=>yt,bytesFromStringArray:()=>ow,bytesPerElement:()=>jp,checkConversionForErrors:()=>tw,clamp:()=>qp,computeStrides:()=>js,convertBackendValuesAndArrayBuffer:()=>BG,createScalarValue:()=>t4,createShuffledIndices:()=>PG,decodeString:()=>sc,distSquared:()=>RG,encodeString:()=>tu,fetch:()=>o4,fingerPrint64:()=>e4,flatten:()=>Ps,getArrayFromDType:()=>Xm,getTypedArrayFromDType:()=>ew,hasEncodingLoss:()=>LG,hexToLong:()=>yl,indexToLoc:()=>WG,inferDtype:()=>Ri,inferFromImplicitShape:()=>MG,isBoolean:()=>v0,isFunction:()=>qs,isInt:()=>qa,isNumber:()=>k0,isPromise:()=>Fu,isScalarShape:()=>DG,isString:()=>Vo,isTypedArray:()=>Ot,isValidDtype:()=>rw,locToIndex:()=>VG,makeOnesTypedArray:()=>fl,makeZerosNestedTypedArray:()=>zG,makeZerosTypedArray:()=>Yp,nearestDivisor:()=>Xp,nearestLargerEven:()=>_G,now:()=>Wu,parseAxisParam:()=>Ei,randUniform:()=>EG,repeatedTry:()=>OG,rightPad:()=>Au,shuffle:()=>I0,shuffleCombo:()=>TG,sizeFromShape:()=>He,sizeToSquarishShape:()=>FG,squeezeShape:()=>JC,sum:()=>$G,swap:()=>jm,tanh:()=>AG,toNestedArray:()=>Du,toTypedArray:()=>nc});function Qm(r){return r instanceof Float32Array||r instanceof Int32Array||r instanceof Uint8Array||r instanceof Uint8ClampedArray}var mw=Kp(V0());var Vu=mw.default||mw;function yl(r){return Vu.fromString(r,!0,16)}var U0=yl(\"c3a5c85c97cb3127\"),zu=yl(\"b492b66fbe98f273\"),wr=yl(\"9ae16a3b2f90404f\");function lw(r){return r.xor(r.shru(47))}function G0(r,t,e){let o=r.slice(t,t+e);return Vu.fromBytes(Array.from(o),!0,!0)}function St(r,t){return G0(r,t,8)}function W0(r,t){return G0(r,t,4)}function Qt(r,t){return t===0?r:r.shru(t).or(r.shl(64-t))}function eu(r,t,e=yl(\"9ddfea08eb382d69\")){let o=r.xor(t).mul(e);o=o.xor(o.shru(47));let n=t.xor(o).mul(e);return n=n.xor(n.shru(47)),n=n.mul(e),n}function YG(r,t,e,o,n,s){n=n.add(r),s=Qt(s.add(n).add(o),21);let a=n;return n=n.add(t),n=n.add(e),s=s.add(Qt(n,44)),[n.add(o),s.add(a)]}function Jm(r,t,e,o){return YG(St(r,t),St(r,t+8),St(r,t+16),St(r,t+24),e,o)}function QG(r,t=r.length){if(t>=8){let e=wr.add(t*2),o=St(r,0).add(wr),n=St(r,t-8),s=Qt(n,37).mul(e).add(o),a=Qt(o,25).add(n).mul(e);return eu(s,a,e)}if(t>=4){let e=wr.add(t*2),o=W0(r,0);return eu(o.shl(3).add(t),W0(r,t-4),e)}if(t>0){let e=r[0],o=r[t>>1],n=r[t-1],s=e+(o<<8),a=t+(n<<2);return lw(wr.mul(s).xor(U0.mul(a))).mul(wr)}return wr}function ZG(r,t=r.length){let e=wr.add(t*2),o=St(r,0).mul(zu),n=St(r,8),s=St(r,t-8).mul(e),a=St(r,t-16).mul(wr);return eu(Qt(o.add(n),43).add(Qt(s,30)).add(a),o.add(Qt(n.add(wr),18)).add(s),e)}function JG(r,t=r.length){let e=wr.add(t*2),o=St(r,0).mul(wr),n=St(r,8),s=St(r,t-8).mul(e),a=St(r,t-16).mul(wr),i=Qt(o.add(n),43).add(Qt(s,30)).add(a),p=eu(i,o.add(Qt(n.add(wr),18)).add(s),e),u=St(r,16).mul(e),c=St(r,24),l=i.add(St(r,t-32)).mul(e),m=p.add(St(r,t-24)).mul(e);return eu(Qt(u.add(c),43).add(Qt(l,30)).add(m),u.add(Qt(c.add(o),18)).add(l),e)}function e4(r,t=r.length){let e=Vu.fromNumber(81,!0);if(t<=32)return t<=16?QG(r,t):ZG(r,t);if(t<=64)return JG(r,t);let o=e,n=e.mul(zu).add(113),s=lw(n.mul(wr).add(113)).mul(wr),a=[Vu.UZERO,Vu.UZERO],i=[Vu.UZERO,Vu.UZERO];o=o.mul(wr).add(St(r,0));let p=0,u=(t-1>>6)*64,c=u+(t-1&63)-63;do o=Qt(o.add(n).add(a[0]).add(St(r,p+8)),37).mul(zu),n=Qt(n.add(a[1]).add(St(r,p+48)),42).mul(zu),o=o.xor(i[1]),n=n.add(a[0]).add(St(r,p+40)),s=Qt(s.add(i[0]),33).mul(zu),a=Jm(r,p,a[1].mul(zu),o.add(i[0])),i=Jm(r,p+32,s.add(i[1]),n.add(St(r,p+16))),[s,o]=[o,s],p+=64;while(p!==u);let l=zu.add(s.and(255).shl(1));return p=c,i[0]=i[0].add(t-1&63),a[0]=a[0].add(i[0]),i[0]=i[0].add(a[0]),o=Qt(o.add(n).add(a[0]).add(St(r,p+8)),37).mul(l),n=Qt(n.add(a[1]).add(St(r,p+48)),42).mul(l),o=o.xor(i[1].mul(9)),n=n.add(a[0].mul(9).add(St(r,p+40))),s=Qt(s.add(i[0]),33).mul(l),a=Jm(r,p,a[1].mul(l),o.add(i[0])),i=Jm(r,p+32,s.add(i[1]),n.add(St(r,p+16))),[s,o]=[o,s],eu(eu(a[0],i[0],l).add(lw(n).mul(U0)).add(s),eu(a[1],i[1],l).add(o),l)}function t4(r,t){return t===\"string\"?tu(r):nc([r],t)}function r4(r,t){return r instanceof Float32Array&&t===\"float32\"||r instanceof Int32Array&&t===\"int32\"||r instanceof Uint8Array&&t===\"bool\"}function nc(r,t){if(t===\"string\")throw new Error(\"Cannot convert a string[] to a TypedArray\");if(Array.isArray(r)&&(r=Ps(r)),A().getBool(\"DEBUG\")&&tw(r,t),r4(r,t))return r;if(t==null||t===\"float32\"||t===\"complex64\")return new Float32Array(r);if(t===\"int32\")return new Int32Array(r);if(t===\"bool\"){let e=new Uint8Array(r.length);for(let o=0;o{n=o()},a,i=Wu();if(this.backendTimer.timerAvailable())a=this.backendTimer.time(s);else{s();for(let u of n)u.dataSync();a=Promise.resolve({kernelMs:Wu()-i})}if(A().getBool(\"CHECK_COMPUTATION_FOR_ERRORS\"))for(let u=0;u{n4(l,c.dtype,t)})}return{kernelName:t,outputs:n,inputs:e,timeMs:a.then(u=>u.kernelMs),extraInfo:a.then(u=>u.getExtraProfileInfo!=null?u.getExtraProfileInfo():\"\")}}logKernelProfile(t){let{kernelName:e,outputs:o,timeMs:n,inputs:s,extraInfo:a}=t;o.forEach(i=>{Promise.all([i.data(),n,a]).then(p=>{this.logger.logKernelProfile(e,i,p[0],p[1],s,p[2])})})}};function n4(r,t,e){if(t!==\"float32\")return!1;for(let o=0;o0?h:\"\"} `}}console.log(`%c${p}\t%c${i}\t%c${u}D ${l}\t%c${c}\t%c${m}\t%c${a}`,\"font-weight:bold\",\"color:red\",\"color:blue\",\"color: orange\",\"color: green\",\"color: steelblue\")}};function H0(r,t,e){let o={},n={};for(let p=0;po[h.id]=!0),d=!0,n[u.id]=!0;break}if(d)break}}let s={};s[e.id]=!0;let a={};for(let p=r.length-1;p>=0;p--){let u=r[p],c=u.inputs;for(let l=0;l=0;n--){let s=t[n],a=[];if(s.outputs.forEach(p=>{let u=r[p.id];u!=null?a.push(u):a.push(null)}),s.gradient==null)throw new Error(`Cannot compute gradient: gradient function not found for ${s.kernelName}.`);let i=s.gradient(a);for(let p in s.inputs){if(!(p in i))throw new Error(`Cannot backprop through input ${p}. Available gradients found: ${Object.keys(i)}.`);let u=e(()=>i[p]());if(u.dtype!==\"float32\")throw new Error(`Error in gradient for op ${s.kernelName}. The gradient of input ${p} must have 'float32' dtype, but has '${u.dtype}'`);let c=s.inputs[p];if(!Cr(u.shape,c.shape))throw new Error(`Error in gradient for op ${s.kernelName}. The gradient of input '${p}' has shape '${u.shape}', which does not match the shape of the input '${c.shape}'`);if(r[c.id]==null)r[c.id]=u;else{let l=r[c.id];r[c.id]=o(l,u),l.dispose()}}}}var q0=20,bl=3,fw=7;function j0(r,t,e,o){let n=js(t),s=s4(r,t,e,n),a=t.length,i=td(r,t,e,n,s),p=[\"Tensor\"];return o&&(p.push(` dtype: ${e}`),p.push(` rank: ${a}`),p.push(` shape: [${t}]`),p.push(\" values:\")),p.push(i.map(u=>\" \"+u).join(`\n`)),p.join(`\n`)}function s4(r,t,e,o){let n=He(t),s=o[o.length-1],a=new Array(s).fill(0),i=t.length,p=e===\"complex64\"?wl(r):r;if(i>1)for(let u=0;uq0){let g=bl*a,x=Array.from(r.slice(0,g)),b=Array.from(r.slice((i-bl)*a,i*a));return e===\"complex64\"&&(x=wl(x),b=wl(b)),[\"[\"+x.map((C,S)=>Cl(C,n[S],e)).join(\", \")+\", ..., \"+b.map((C,S)=>Cl(C,n[i-bl+S],e)).join(\", \")+\"]\"]}return[\"[\"+(e===\"complex64\"?wl(r):Array.from(r)).map((g,x)=>Cl(g,n[x],e)).join(\", \")+\"]\"]}let u=t.slice(1),c=o.slice(1),l=o[0]*a,m=[];if(i>q0){for(let h=0;h0?m[0]+d:\"\");for(let h=1;h`Length of values '${n}' does not match the size inferred by the shape '${this.size}'.`)}if(e===\"complex64\")throw new Error(\"complex64 dtype TensorBuffers are not supported. Please create a TensorBuffer for the real and imaginary parts separately and call tf.complex(real, imag).\");this.values=o||Xm(e,this.size),this.strides=js(t)}set(t,...e){e.length===0&&(e=[0]),$(e.length===this.rank,()=>`The number of provided coordinates (${e.length}) must match the rank (${this.rank})`);let o=this.locToIndex(e);this.values[o]=t}get(...t){t.length===0&&(t=[0]);let e=0;for(let n of t){if(n<0||n>=this.shape[e]){let s=`Requested out of range element at ${t}. Buffer shape=${this.shape}`;throw new Error(s)}e++}let o=t[t.length-1];for(let n=0;nsc(o))}catch(o){throw new Error(\"Failed to decode the string bytes into utf-8. To get the original bytes, call tensor.bytes().\")}}return t}dataToGPU(t){return this.throwIfDisposed(),Os().readToGPU(this.dataId,t)}dataSync(){this.throwIfDisposed();let t=Os().readSync(this.dataId);if(this.dtype===\"string\")try{return t.map(e=>sc(e))}catch(e){throw new Error(\"Failed to decode the string bytes into utf-8. To get the original bytes, call tensor.bytes().\")}return t}async bytes(){this.throwIfDisposed();let t=await Os().read(this.dataId);return this.dtype===\"string\"?t:new Uint8Array(t.buffer)}dispose(){this.isDisposed||(this.kerasMask&&this.kerasMask.dispose(),Os().disposeTensor(this),this.isDisposedInternal=!0)}get isDisposed(){return this.isDisposedInternal}throwIfDisposed(){if(this.isDisposed)throw new Error(\"Tensor is disposed.\")}print(t=!1){return ac.print(this,t)}clone(){return this.throwIfDisposed(),ac.clone(this)}toString(t=!1){let e=this.dataSync();return j0(e,this.shape,this.dtype,t)}cast(t){return this.throwIfDisposed(),ac.cast(this,t)}variable(t=!0,e,o){return this.throwIfDisposed(),Os().makeVariable(this,t,e,o)}};Object.defineProperty(ut,Symbol.hasInstance,{value:r=>!!r&&r.data!=null&&r.dataSync!=null&&r.throwIfDisposed!=null});function i4(){return gl(\"Tensor\",()=>ut)}i4();var oi=class extends ut{constructor(t,e,o,n){super(t.shape,t.dtype,t.dataId,n),this.trainable=e,this.name=o}assign(t){if(t.dtype!==this.dtype)throw new Error(`dtype of the new value (${t.dtype}) and previous value (${this.dtype}) must match`);if(!Cr(t.shape,this.shape))throw new Error(`shape of the new value (${t.shape}) and previous value (${this.shape}) must match`);Os().disposeTensor(this),this.dataId=t.dataId,Os().incRef(this,null)}dispose(){Os().disposeVariable(this),this.isDisposedInternal=!0}};Object.defineProperty(oi,Symbol.hasInstance,{value:r=>r instanceof ut&&r.assign!=null&&r.assign instanceof Function});var ek={};qe(ek,{assertTypesMatch:()=>Cw,getTensorsInContainer:()=>Sl,isTensorInList:()=>p4,makeTypesMatch:()=>Oe});var hw;(function(r){r.R0=\"R0\",r.R1=\"R1\",r.R2=\"R2\",r.R3=\"R3\",r.R4=\"R4\",r.R5=\"R5\",r.R6=\"R6\"})(hw||(hw={}));var gw;(function(r){r.float32=\"float32\",r.int32=\"int32\",r.bool=\"int32\",r.complex64=\"complex64\"})(gw||(gw={}));var xw;(function(r){r.float32=\"float32\",r.int32=\"int32\",r.bool=\"bool\",r.complex64=\"complex64\"})(xw||(xw={}));var yw;(function(r){r.float32=\"float32\",r.int32=\"float32\",r.bool=\"float32\",r.complex64=\"complex64\"})(yw||(yw={}));var bw;(function(r){r.float32=\"complex64\",r.int32=\"complex64\",r.bool=\"complex64\",r.complex64=\"complex64\"})(bw||(bw={}));var u4={float32:yw,int32:gw,bool:xw,complex64:bw};function dt(r,t){if(r===\"string\"||t===\"string\"){if(r===\"string\"&&t===\"string\")return\"string\";throw new Error(`Can not upcast ${r} with ${t}`)}return u4[r][t]}function ni(r){return dt(r,\"int32\")}function rd(r){return r!=null&&typeof r==\"object\"&&\"texture\"in r&&r.texture instanceof WebGLTexture}function od(r){return typeof GPUBuffer!=\"undefined\"&&r!=null&&typeof r==\"object\"&&\"buffer\"in r&&r.buffer instanceof GPUBuffer}function Oe(r,t){if(r.dtype===t.dtype)return[r,t];let e=dt(r.dtype,t.dtype);return[r.cast(e),t.cast(e)]}function Cw(r,t){$(r.dtype===t.dtype,()=>`The dtypes of the first(${r.dtype}) and second(${t.dtype}) input must match`)}function p4(r,t){return t.some(e=>e.id===r.id)}function Sl(r){let t=[];return J0(r,t,new Set),t}function J0(r,t,e){if(r==null)return;if(r instanceof ut){t.push(r);return}if(!c4(r))return;let o=r;for(let n in o){let s=o[n];e.has(s)||(e.add(s),J0(s,t,e))}}function c4(r){return Array.isArray(r)||typeof r==\"object\"}function ww(r){return r.kernelName!=null}var nd=class{constructor(){this.registeredVariables={},this.nextTapeNodeId=0,this.numBytes=0,this.numTensors=0,this.numStringTensors=0,this.numDataBuffers=0,this.gradientDepth=0,this.kernelDepth=0,this.scopeStack=[],this.numDataMovesStack=[],this.nextScopeId=0,this.tensorInfo=new WeakMap,this.profiling=!1,this.activeProfile={newBytes:0,newTensors:0,peakBytes:0,kernels:[],result:null,get kernelNames(){return Array.from(new Set(this.kernels.map(t=>t.name)))}}}dispose(){for(let t in this.registeredVariables)this.registeredVariables[t].dispose()}},ru=class{constructor(t){this.ENV=t,this.registry={},this.registryFactory={},this.pendingBackendInitId=0,this.state=new nd}async ready(){if(this.pendingBackendInit!=null)return this.pendingBackendInit.then(()=>{});if(this.backendInstance!=null)return;let t=this.getSortedBackends();for(let e=0;e{e.setupFunc!=null&&e.setupFunc(this.backendInstance)})}disposeRegisteredKernels(t){Ym(t).forEach(o=>{o.disposeFunc!=null&&o.disposeFunc(this.registry[t])})}initializeBackend(t){let e=this.registryFactory[t];if(e==null)throw new Error(`Cannot initialize backend ${t}, no registration found.`);try{let o=e.factory();if(o&&!(o instanceof ao)&&typeof o.then==\"function\"){let n=++this.pendingBackendInitId,s=o.then(a=>n(nthis.registryFactory[e].priority-this.registryFactory[t].priority)}initializeBackendsAndReturnBest(){let t=this.getSortedBackends();for(let e=0;ethis.startScope(o),()=>this.endScope(n),()=>(n=e(),n instanceof Promise&&console.error(\"Cannot return a Promise inside of tidy.\"),n))}scopedRun(t,e,o){t();try{let n=o();return e(),n}catch(n){throw e(),n}}nextTensorId(){return ru.nextTensorId++}nextVariableId(){return ru.nextVariableId++}clone(t){let e=T.runKernel(wo,{x:t}),o={x:t},n=a=>({x:()=>{let i=\"float32\",p={x:a},u={dtype:i};return T.runKernel(bo,p,u)}}),s=[];return this.addTapeNode(this.state.activeScope.name,o,[e],n,s,{}),e}runKernel(t,e,o){if(this.backendName==null&&this.backend,!(tc(t,this.backendName)!=null))throw new Error(`Kernel '${t}' not registered for backend '${this.backendName}'`);return this.runKernelFunc({kernelName:t,inputs:e,attrs:o})}shouldCheckForMemLeaks(){return this.ENV.getBool(\"IS_TEST\")}checkKernelForMemLeak(t,e,o){let n=this.backend.numDataIds(),s=0;o.forEach(p=>{s+=p.dtype===\"complex64\"?3:1});let a=this.state.numDataMovesStack[this.state.numDataMovesStack.length-1],i=n-e-s-a;if(i>0)throw new Error(`Backend '${this.backendName}' has an internal memory leak (${i} data ids) after running '${t}'`)}runKernelFunc(t){let e,o=[],n=this.isTapeOn(),s=this.state.numBytes,a=this.state.numTensors;this.shouldCheckForMemLeaks()&&this.state.numDataMovesStack.push(0);let i;this.backendName==null&&this.backend;let p,u=ww(t)?t.kernelName:this.state.activeScope!=null?this.state.activeScope.name:\"\";if(ww(t)){let{kernelName:f,inputs:h,attrs:g}=t;this.backendName==null&&this.backend;let x=tc(f,this.backendName);$(x!=null,()=>`Cannot find registered kernel '${f}' for backend '${this.backendName}'`),i=()=>{let b=this.backend.numDataIds();p=x.kernelFunc({inputs:h,attrs:g,backend:this.backend});let C=Array.isArray(p)?p:[p];this.shouldCheckForMemLeaks()&&this.checkKernelForMemLeak(f,b,C);let S=C.map(k=>k.rank!=null?k:this.makeTensorFromTensorInfo(k));if(n){let k=this.getTensorsForGradient(f,h,S);o=this.saveTensorsForBackwardMode(k)}return S}}else{let{forwardFunc:f}=t,h=g=>{n&&(o=g.map(x=>this.keep(this.clone(x))))};i=()=>{let g=this.backend.numDataIds();p=this.tidy(()=>f(this.backend,h));let x=Array.isArray(p)?p:[p];return this.shouldCheckForMemLeaks()&&this.checkKernelForMemLeak(u,g,x),x}}let{inputs:c,attrs:l}=t,m=ww(t)?null:t.backwardsFunc,d;return this.scopedRun(()=>this.state.kernelDepth++,()=>this.state.kernelDepth--,()=>{!this.ENV.getBool(\"DEBUG\")&&!this.state.profiling?e=i():(d=this.profiler.profileKernel(u,c,()=>i()),this.ENV.getBool(\"DEBUG\")&&this.profiler.logKernelProfile(d),e=d.outputs)}),n&&this.addTapeNode(u,c,e,m,o,l),this.state.profiling&&this.state.activeProfile.kernels.push({name:u,bytesAdded:this.state.numBytes-s,totalBytesSnapshot:this.state.numBytes,tensorsAdded:this.state.numTensors-a,totalTensorsSnapshot:this.state.numTensors,inputShapes:Object.keys(c).map(f=>c[f]!=null?c[f].shape:null),outputShapes:e.map(f=>f.shape),kernelTimeMs:d.timeMs,extraInfo:d.extraInfo}),Array.isArray(p)?e:e[0]}saveTensorsForBackwardMode(t){return t.map(o=>this.keep(this.clone(o)))}getTensorsForGradient(t,e,o){let n=iw(t);if(n!=null){let s=n.inputsToSave||[],a=n.outputsToSave||[],i;n.saveAllInputs?($(Array.isArray(e),()=>\"saveAllInputs is true, expected inputs to be an array.\"),i=Object.keys(e).map(u=>e[u])):i=s.map(u=>e[u]);let p=o.filter((u,c)=>a[c]);return i.concat(p)}return[]}makeTensor(t,e,o,n){if(t==null)throw new Error(\"Values passed to engine.makeTensor() are null\");o=o||\"float32\",n=n||this.backend;let s=t;o===\"string\"&&Vo(t[0])&&(s=t.map(p=>tu(p)));let a=n.write(s,e,o),i=new ut(e,o,a,this.nextTensorId());if(this.trackTensor(i,n),o===\"string\"){let p=this.state.tensorInfo.get(a),u=ow(s);this.state.numBytes+=u-p.bytes,p.bytes=u}return i}makeTensorFromDataId(t,e,o,n){o=o||\"float32\";let s={dataId:t,shape:e,dtype:o};return this.makeTensorFromTensorInfo(s,n)}makeTensorFromTensorInfo(t,e){let{dataId:o,shape:n,dtype:s}=t,a=new ut(n,s,o,this.nextTensorId());return this.trackTensor(a,e),a}makeVariable(t,e=!0,o,n){o=o||this.nextVariableId().toString(),n!=null&&n!==t.dtype&&(t=t.cast(n));let s=new oi(t,e,o,this.nextTensorId());if(this.state.registeredVariables[s.name]!=null)throw new Error(`Variable with name ${s.name} was already registered`);return this.state.registeredVariables[s.name]=s,this.incRef(s,this.backend),s}trackTensor(t,e){this.state.numTensors++,t.dtype===\"string\"&&this.state.numStringTensors++;let o=0;t.dtype!==\"complex64\"&&t.dtype!==\"string\"&&(o=t.size*jp(t.dtype)),this.state.numBytes+=o,this.state.tensorInfo.has(t.dataId)||(this.state.numDataBuffers++,this.state.tensorInfo.set(t.dataId,{backend:e||this.backend,dtype:t.dtype,shape:t.shape,bytes:o})),t instanceof oi||this.track(t)}incRef(t,e){this.trackTensor(t,e),this.backend.incRef(t.dataId)}removeDataId(t,e){this.state.tensorInfo.has(t)&&this.state.tensorInfo.get(t).backend===e&&(this.state.tensorInfo.delete(t),this.state.numDataBuffers--)}disposeTensor(t){if(!this.state.tensorInfo.has(t.dataId))return;let e=this.state.tensorInfo.get(t.dataId);if(this.state.numTensors--,t.dtype===\"string\"&&(this.state.numStringTensors--,this.state.numBytes-=e.bytes),t.dtype!==\"complex64\"&&t.dtype!==\"string\"){let o=t.size*jp(t.dtype);this.state.numBytes-=o}e.backend.disposeData(t.dataId)&&this.removeDataId(t.dataId,e.backend)}disposeVariables(){for(let t in this.state.registeredVariables){let e=this.state.registeredVariables[t];this.disposeVariable(e)}}disposeVariable(t){this.disposeTensor(t),this.state.registeredVariables[t.name]!=null&&delete this.state.registeredVariables[t.name]}memory(){let t=this.backend.memory();return t.numTensors=this.state.numTensors,t.numDataBuffers=this.state.numDataBuffers,t.numBytes=this.state.numBytes,this.state.numStringTensors>0&&(t.unreliable=!0,t.reasons==null&&(t.reasons=[]),t.reasons.push(\"Memory usage by string tensors is approximate (2 bytes per character)\")),t}async profile(t){this.state.profiling=!0;let e=this.state.numBytes,o=this.state.numTensors;this.state.activeProfile.kernels=[],this.state.activeProfile.result=await t(),this.state.profiling=!1,this.state.activeProfile.peakBytes=Math.max(...this.state.activeProfile.kernels.map(n=>n.totalBytesSnapshot)),this.state.activeProfile.newBytes=this.state.numBytes-e,this.state.activeProfile.newTensors=this.state.numTensors-o;for(let n of this.state.activeProfile.kernels)n.kernelTimeMs=await n.kernelTimeMs,n.extraInfo=await n.extraInfo;return this.state.activeProfile}isTapeOn(){return this.state.gradientDepth>0&&this.state.kernelDepth===0}addTapeNode(t,e,o,n,s,a){let i={id:this.state.nextTapeNodeId++,kernelName:t,inputs:e,outputs:o,saved:s},p=iw(t);p!=null&&(n=p.gradFunc),n!=null&&(i.gradient=u=>(u=u.map((c,l)=>{if(c==null){let m=o[l],d=Yp(m.size,m.dtype);return this.makeTensor(d,m.shape,m.dtype)}return c}),n(u.length>1?u:u[0],s,a))),this.state.activeTape.push(i)}keep(t){return t.kept=!0,t}startTape(){this.state.gradientDepth===0&&(this.state.activeTape=[]),this.state.gradientDepth++}endTape(){this.state.gradientDepth--}startScope(t){let e={track:[],name:\"unnamed scope\",id:this.state.nextScopeId++};t&&(e.name=t),this.state.scopeStack.push(e),this.state.activeScope=e}endScope(t){let e=Sl(t),o=new Set(e.map(s=>s.id));for(let s=0;s{!s.kept&&s.scopeId===n.id&&this.track(s)})}gradients(t,e,o,n=!1){if($(e.length>0,()=>\"gradients() received an empty list of xs.\"),o!=null&&o.dtype!==\"float32\")throw new Error(`dy must have 'float32' dtype, but has '${o.dtype}'`);let s=this.scopedRun(()=>this.startTape(),()=>this.endTape(),()=>this.tidy(\"forward\",t));$(s instanceof ut,()=>\"The result y returned by f() must be a tensor.\");let a=H0(this.state.activeTape,e,s);if(!n&&a.length===0&&e.length>0)throw new Error(\"Cannot compute gradient of y=f(x) with respect to x. Make sure that the f you passed encloses all operations that lead from x to y.\");return this.tidy(\"backward\",()=>{let i={};i[s.id]=o==null?l4(s.shape):o,K0(i,a,u=>this.tidy(u),m4);let p=e.map(u=>i[u.id]);return this.state.gradientDepth===0&&(this.state.activeTape.forEach(u=>{for(let c of u.saved)c.dispose()}),this.state.activeTape=null),{value:s,grads:p}})}customGrad(t){return $(qs(t),()=>\"The f passed in customGrad(f) must be a function.\"),(...e)=>{$(e.every(i=>i instanceof ut),()=>\"The args passed in customGrad(f)(x1, x2,...) must all be tensors\");let o,n={};e.forEach((i,p)=>{n[p]=i});let s=(i,p)=>(o=t(...e,p),$(o.value instanceof ut,()=>\"The function f passed in customGrad(f) must return an object where `obj.value` is a tensor\"),$(qs(o.gradFunc),()=>\"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function.\"),o.value),a=(i,p)=>{let u=o.gradFunc(i,p),c=Array.isArray(u)?u:[u];$(c.length===e.length,()=>\"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function that returns the same number of tensors as inputs passed to f(...).\"),$(c.every(m=>m instanceof ut),()=>\"The function f passed in customGrad(f) must return an object where `obj.gradFunc` is a function that returns a list of only tensors.\");let l={};return c.forEach((m,d)=>{l[d]=()=>m}),l};return this.runKernelFunc({forwardFunc:s,backwardsFunc:a,inputs:n})}}readSync(t){return this.state.tensorInfo.get(t).backend.readSync(t)}read(t){return this.state.tensorInfo.get(t).backend.read(t)}readToGPU(t,e){return this.state.tensorInfo.get(t).backend.readToGPU(t,e)}async time(t){let e=Wu(),o=await this.backend.time(t);return o.wallMs=Wu()-e,o}track(t){return this.state.activeScope!=null&&(t.scopeId=this.state.activeScope.id,this.state.activeScope.track.push(t)),t}get registeredVariables(){return this.state.registeredVariables}reset(){this.pendingBackendInitId++,this.state.dispose(),this.ENV.reset(),this.state=new nd;for(let t in this.registry)this.disposeRegisteredKernels(t),this.registry[t].dispose(),delete this.registry[t];this.backendName=null,this.backendInstance=null,this.pendingBackendInit=null}};ru.nextTensorId=0;ru.nextVariableId=0;function l4(r){let t=fl(He(r),\"float32\");return T.makeTensor(t,r,\"float32\")}function Sw(){let r=aw();if(r._tfengine==null){let t=new hl(r);r._tfengine=new ru(t)}return _0(r._tfengine.ENV),Y0(()=>r._tfengine),r._tfengine}var T=Sw();function m4(r,t){let e={a:r,b:t};return T.runKernel(uo,e)}var ou={};qe(ou,{isBrowser:()=>vw,isMobile:()=>h4,mockIsMobile:()=>f4});function d4(){return typeof navigator!=\"undefined\"&&navigator!=null}var Iw;function f4(r){Iw=r}function h4(r){if(Iw!==void 0)return Iw;if(r||d4()){if(r||(r=navigator),r.product===\"ReactNative\")return!0;let t=r.userAgent||r.vendor||(typeof window!=\"undefined\"?window.opera:\"\");if(!t){let e=r;return e.userAgentData&&e.userAgentData.mobile}return/(android|bb\\d+|meego).+mobile|avantgo|bada\\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(t)||/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\\-(n|u)|c55\\/|capi|ccwa|cdm\\-|cell|chtm|cldc|cmd\\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\\-s|devi|dica|dmob|do(c|p)o|ds(12|\\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\\-|_)|g1 u|g560|gene|gf\\-5|g\\-mo|go(\\.w|od)|gr(ad|un)|haie|hcit|hd\\-(m|p|t)|hei\\-|hi(pt|ta)|hp( i|ip)|hs\\-c|ht(c(\\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\\-(20|go|ma)|i230|iac( |\\-|\\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\\/)|klon|kpt |kwc\\-|kyo(c|k)|le(no|xi)|lg( g|\\/(k|l|u)|50|54|\\-[a-w])|libw|lynx|m1\\-w|m3ga|m50\\/|ma(te|ui|xo)|mc(01|21|ca)|m\\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\\-2|po(ck|rt|se)|prox|psio|pt\\-g|qa\\-a|qc(07|12|21|32|60|\\-[2-7]|i\\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\\-|oo|p\\-)|sdk\\/|se(c(\\-|0|1)|47|mc|nd|ri)|sgh\\-|shar|sie(\\-|m)|sk\\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\\-|v\\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\\-|tdg\\-|tel(i|m)|tim\\-|t\\-mo|to(pl|sh)|ts(70|m\\-|m3|m5)|tx\\-9|up(\\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\\-|your|zeto|zte\\-/i.test(t.substr(0,4))}return!1}function vw(){return typeof window!=\"undefined\"&&window.document!=null||typeof WorkerGlobalScope!=\"undefined\"}var $r=A();$r.registerFlag(\"DEBUG\",()=>!1,r=>{r&&console.warn(\"Debugging mode is ON. The output of every math call will be downloaded to CPU and checked for NaNs. This significantly impacts performance.\")});$r.registerFlag(\"IS_BROWSER\",()=>vw());$r.registerFlag(\"IS_NODE\",()=>typeof process!=\"undefined\"&&typeof process.versions!=\"undefined\"&&typeof process.versions.node!=\"undefined\");$r.registerFlag(\"IS_CHROME\",()=>typeof navigator!=\"undefined\"&&navigator!=null&&navigator.userAgent!=null&&/Chrome/.test(navigator.userAgent)&&/Google Inc/.test(navigator.vendor));$r.registerFlag(\"IS_SAFARI\",()=>typeof navigator!=\"undefined\"&&navigator!=null&&navigator.userAgent!=null&&/Safari/.test(navigator.userAgent)&&/Apple/.test(navigator.vendor));$r.registerFlag(\"PROD\",()=>!1);$r.registerFlag(\"TENSORLIKE_CHECK_SHAPE_CONSISTENCY\",()=>$r.getBool(\"DEBUG\"));$r.registerFlag(\"DEPRECATION_WARNINGS_ENABLED\",()=>!0);$r.registerFlag(\"IS_TEST\",()=>!1);$r.registerFlag(\"CHECK_COMPUTATION_FOR_ERRORS\",()=>$r.getBool(\"DEBUG\"));$r.registerFlag(\"WRAP_TO_IMAGEBITMAP\",()=>!1);$r.registerFlag(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\",()=>!1);$r.registerFlag(\"USE_SETTIMEOUTCUSTOM\",()=>!1);function ir(r,t){let e=r;if(Ot(r))return t===\"string\"?[]:[r.length];if(rd(r)){let n=r.channels||\"RGBA\";return[r.height,r.width*n.length]}else if(od(r))return[r.buffer.size/(t==null?4:jp(t))];if(!Array.isArray(r))return[];let o=[];for(;Array.isArray(e)||Ot(e)&&t!==\"string\";)o.push(e.length),e=e[0];return Array.isArray(r)&&A().getBool(\"TENSORLIKE_CHECK_SHAPE_CONSISTENCY\")&&rk(r,o,[]),o}function rk(r,t,e){if(e=e||[],!Array.isArray(r)&&!Ot(r)){$(t.length===0,()=>`Element arr[${e.join(\"][\")}] is a primitive, but should be an array/TypedArray of ${t[0]} elements`);return}$(t.length>0,()=>`Element arr[${e.join(\"][\")}] should be a primitive, but is an array of ${r.length} elements`),$(r.length===t[0],()=>`Element arr[${e.join(\"][\")}] should have ${t[0]} elements, but has ${r.length} elements`);let o=t.slice(1);for(let n=0;n=0&&(n=o),tk(o,n,t,e),r==null||!Ot(r)&&!Array.isArray(r)&&typeof r!=\"number\"&&typeof r!=\"boolean\"&&typeof r!=\"string\"){let p=r==null?\"null\":r.constructor.name;throw new Error(`Argument '${t}' passed to '${e}' must be a Tensor or TensorLike, but got '${p}'`)}let s=ir(r,n);!Ot(r)&&!Array.isArray(r)&&(r=[r]);let i=n!==\"string\"?nc(r,n):Ps(r,[],!0);return T.makeTensor(i,s,n)}function si(r,t,e,o=\"numeric\"){if(!Array.isArray(r))throw new Error(`Argument ${t} passed to ${e} must be a \\`Tensor[]\\` or \\`TensorLike[]\\``);return r.map((s,a)=>v(s,`${t}[${a}]`,e,o))}var kw=\"__op\";function N(r){let t=Object.keys(r);if(t.length!==1)throw new Error(`Please provide an object with a single key (operation name) mapping to a function. Got an object with ${t.length} keys.`);let e=t[0],o=r[e];e.endsWith(\"_\")&&(e=e.substring(0,e.length-1)),e=e+kw;let n=(...s)=>{T.startScope(e);try{let a=o(...s);return Fu(a)&&console.error(\"Cannot return a Promise inside of tidy.\"),T.endScope(a),a}catch(a){throw T.endScope(null),a}};return Object.defineProperty(n,\"name\",{value:e,configurable:!0}),n}function g4(r,t){let e=v(r,\"real\",\"complex\"),o=v(t,\"imag\",\"complex\");yt(e.shape,o.shape,`real and imag shapes, ${e.shape} and ${o.shape}, must match in call to tf.complex().`);let n={real:e,imag:o};return T.runKernel(Fi,n)}var Er=N({complex_:g4});function Sr(r,t,e,o){if(o==null)o=Ri(r);else if(o===\"complex64\")throw new Error(\"Cannot construct a complex64 tensor directly. Please use tf.complex(real, imag).\");if(od(r)||rd(r)){if(o!==\"float32\"&&o!==\"int32\")throw new Error(`Creating tensor from GPU data only supports 'float32'|'int32' dtype, while the dtype is ${o}.`);return T.backend.createTensorFromGPUData(r,t||e,o)}if(!Ot(r)&&!Array.isArray(r)&&typeof r!=\"number\"&&typeof r!=\"boolean\"&&typeof r!=\"string\")throw new Error(\"values passed to tensor(values) must be a number/boolean/string or an array of numbers/booleans/strings, or a TypedArray\");if(t!=null){wt(t);let n=He(t),s=He(e);$(n===s,()=>`Based on the provided shape, [${t}], the tensor should have ${n} values but has ${s}`);for(let a=0;a`Error creating a new Tensor. Inferred shape (${e}) does not match the provided shape (${t}). `)}}return!Ot(r)&&!Array.isArray(r)&&(r=[r]),t=t||e,r=o!==\"string\"?nc(r,o):Ps(r,[],!0),T.makeTensor(r,t,o)}function ur(r,t,e){let o=ir(r,e);return Sr(r,t,o,e)}var Il={float32:4,float16:2,int32:4,uint16:2,uint8:1,bool:1,complex64:8};var jt=class{static join(t){return new jt(t).slice()}constructor(t){if(this.shards=[],this.previousShardIndex=0,t==null||(t instanceof Array||(t=[t]),t=t.map(o=>Ot(o)?o.buffer:o),t.length===0))return;this.bufferUniformSize=t[0].byteLength;let e=0;for(let o=0;o=this.byteLength)return-1;if(this.bufferUniformSize!=null)return this.previousShardIndex=Math.floor(t/this.bufferUniformSize),this.previousShardIndex;function e(n){return t=n.end?1:0}if(e(this.shards[this.previousShardIndex])===0)return this.previousShardIndex;let o=x4(this.shards,e);return o===-1?-1:(this.previousShardIndex=o,this.previousShardIndex)}};function x4(r,t){let e=0,o=r.length;for(;e<=o;){let n=Math.floor((o-e)/2)+e,s=t(r[n]);if(s===0)return n;s<0?o=n:e=n+1}return-1}var sd=4;async function nk(r,t){let e=[],o=[],n=Array.isArray(r)?r.map(a=>a.name):Object.keys(r);for(let a=0;a{let m=await p.bytes(),d=m.reduce((g,x)=>g+x.length,0)+sd*m.length,f=new Uint8Array(d),h=0;for(let g=0;g{if(t+=s.byteLength,e.push(s.byteLength===s.buffer.byteLength?s:new s.constructor(s)),!(s instanceof Float32Array||s instanceof Int32Array||s instanceof Uint8Array))throw new Error(`Unsupported TypedArray subtype: ${s.constructor.name}`)});let o=new Uint8Array(t),n=0;return e.forEach(s=>{o.set(new Uint8Array(s.buffer),n),n+=s.byteLength}),o.buffer}var Nw=typeof Buffer!=\"undefined\"&&(typeof Blob==\"undefined\"||typeof atob==\"undefined\"||typeof btoa==\"undefined\");function ok(r){return Nw?Buffer.byteLength(r,\"utf8\"):new Blob([r]).size}function sk(r){if(Nw)return Buffer.from(r).toString(\"base64\");let t=new Uint8Array(r),e=\"\";for(let o=0,n=t.length;o{let o=e<<13,n=0;for(;!(o&8388608);)n-=8388608,o<<=1;return o&=-8388609,n+=947912704,o|n},t=new Uint32Array(2048);t[0]=0;for(let e=1;e<1024;e++)t[e]=r(e);for(let e=1024;e<2048;e++)t[e]=939524096+(e-1024<<13);return t}function C4(){let r=new Uint32Array(64);r[0]=0,r[31]=1199570944,r[32]=2147483648,r[63]=3347054592;for(let t=1;t<31;t++)r[t]=t<<23;for(let t=33;t<63;t++)r[t]=2147483648+(t-32<<23);return r}function w4(){let r=new Uint32Array(64);for(let t=0;t<64;t++)r[t]=1024;return r[0]=r[32]=0,r}function S4(){let r=b4(),t=C4(),e=w4();return o=>{let n=new ArrayBuffer(4*o.length),s=new Uint32Array(n);for(let a=0;a>10]+(i&1023)]+t[i>>10];s[a]=p}return new Float32Array(n)}}var ft=class{constructor(){this.saveRouters=[],this.loadRouters=[]}static getInstance(){return ft.instance==null&&(ft.instance=new ft),ft.instance}static registerSaveRouter(t){ft.getInstance().saveRouters.push(t)}static registerLoadRouter(t){ft.getInstance().loadRouters.push(t)}static getSaveHandlers(t){return ft.getHandlers(t,\"save\")}static getLoadHandlers(t,e){return ft.getHandlers(t,\"load\",e)}static getHandlers(t,e,o){let n=[];return(e===\"load\"?ft.getInstance().loadRouters:ft.getInstance().saveRouters).forEach(a=>{let i=a(t,o);i!==null&&n.push(i)}),n}},uk=r=>ft.registerSaveRouter(r),pk=r=>ft.registerLoadRouter(r),ck=r=>ft.getSaveHandlers(r),lk=(r,t)=>ft.getLoadHandlers(r,t);var $w=\"tensorflowjs\",Ew=1,Uu=\"models_store\",nu=\"model_info_store\";function mk(){if(!A().getBool(\"IS_BROWSER\"))throw new Error(\"Failed to obtain IndexedDB factory because the current environmentis not a web browser.\");let r=typeof window==\"undefined\"?self:window,t=r.indexedDB||r.mozIndexedDB||r.webkitIndexedDB||r.msIndexedDB||r.shimIndexedDB;if(t==null)throw new Error(\"The current browser does not appear to support IndexedDB.\");return t}function Rw(r){let t=r.result;t.createObjectStore(Uu,{keyPath:\"modelPath\"}),t.createObjectStore(nu,{keyPath:\"modelPath\"})}var ka=class{constructor(t){if(this.indexedDB=mk(),t==null||!t)throw new Error(\"For IndexedDB, modelPath must not be null, undefined or empty.\");this.modelPath=t}async save(t){if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserLocalStorage.save() does not support saving model topology in binary formats yet.\");return this.databaseAction(this.modelPath,t)}async load(){return this.databaseAction(this.modelPath)}databaseAction(t,e){return new Promise((o,n)=>{let s=this.indexedDB.open($w,Ew);s.onupgradeneeded=()=>Rw(s),s.onsuccess=()=>{let a=s.result;if(e==null){let i=a.transaction(Uu,\"readonly\"),u=i.objectStore(Uu).get(this.modelPath);u.onsuccess=()=>{if(u.result==null)return a.close(),n(new Error(`Cannot find model with path '${this.modelPath}' in IndexedDB.`));o(u.result.modelArtifacts)},u.onerror=c=>(a.close(),n(u.error)),i.oncomplete=()=>a.close()}else{e.weightData=jt.join(e.weightData);let i=va(e),p=a.transaction(nu,\"readwrite\"),u=p.objectStore(nu),c;try{c=u.put({modelPath:this.modelPath,modelArtifactsInfo:i})}catch(m){return n(m)}let l;c.onsuccess=()=>{l=a.transaction(Uu,\"readwrite\");let m=l.objectStore(Uu),d;try{d=m.put({modelPath:this.modelPath,modelArtifacts:e,modelArtifactsInfo:i})}catch(f){return n(f)}d.onsuccess=()=>o({modelArtifactsInfo:i}),d.onerror=f=>{u=p.objectStore(nu);let h=u.delete(this.modelPath);h.onsuccess=()=>(a.close(),n(d.error)),h.onerror=g=>(a.close(),n(d.error))}},c.onerror=m=>(a.close(),n(c.error)),p.oncomplete=()=>{l==null?a.close():l.oncomplete=()=>a.close()}}},s.onerror=a=>n(s.error)})}};ka.URL_SCHEME=\"indexeddb://\";var dk=r=>A().getBool(\"IS_BROWSER\")&&!Array.isArray(r)&&r.startsWith(ka.URL_SCHEME)?I4(r.slice(ka.URL_SCHEME.length)):null;ft.registerSaveRouter(dk);ft.registerLoadRouter(dk);function I4(r){return new ka(r)}function v4(r){return r.startsWith(ka.URL_SCHEME)?r.slice(ka.URL_SCHEME.length):r}var pd=class{constructor(){this.indexedDB=mk()}async listModels(){return new Promise((t,e)=>{let o=this.indexedDB.open($w,Ew);o.onupgradeneeded=()=>Rw(o),o.onsuccess=()=>{let n=o.result,s=n.transaction(nu,\"readonly\"),i=s.objectStore(nu).getAll();i.onsuccess=()=>{let p={};for(let u of i.result)p[u.modelPath]=u.modelArtifactsInfo;t(p)},i.onerror=p=>(n.close(),e(i.error)),s.oncomplete=()=>n.close()},o.onerror=n=>e(o.error)})}async removeModel(t){return t=v4(t),new Promise((e,o)=>{let n=this.indexedDB.open($w,Ew);n.onupgradeneeded=()=>Rw(n),n.onsuccess=()=>{let s=n.result,a=s.transaction(nu,\"readwrite\"),i=a.objectStore(nu),p=i.get(t),u;p.onsuccess=()=>{if(p.result==null)return s.close(),o(new Error(`Cannot find model with path '${t}' in IndexedDB.`));{let c=i.delete(t),l=()=>{u=s.transaction(Uu,\"readwrite\");let d=u.objectStore(Uu).delete(t);d.onsuccess=()=>e(p.result.modelArtifactsInfo),d.onerror=f=>o(p.error)};c.onsuccess=l,c.onerror=m=>(l(),s.close(),o(p.error))}},p.onerror=c=>(s.close(),o(p.error)),a.oncomplete=()=>{u==null?s.close():u.oncomplete=()=>s.close()}},n.onerror=s=>o(n.error)})}};var ai=\"/\",uc=\"tensorflowjs_models\",fk=\"info\",k4=\"model_topology\",N4=\"weight_specs\",T4=\"weight_data\",_4=\"model_metadata\";function hk(r){return{info:[uc,r,fk].join(ai),topology:[uc,r,k4].join(ai),weightSpecs:[uc,r,N4].join(ai),weightData:[uc,r,T4].join(ai),modelMetadata:[uc,r,_4].join(ai)}}function gk(r){for(let t of Object.values(r))window.localStorage.removeItem(t)}function $4(r){let t=r.split(ai);if(t.length<3)throw new Error(`Invalid key format: ${r}`);return t.slice(1,t.length-1).join(ai)}function E4(r){return r.startsWith(Na.URL_SCHEME)?r.slice(Na.URL_SCHEME.length):r}var Na=class{constructor(t){if(!A().getBool(\"IS_BROWSER\")||typeof window==\"undefined\"||typeof window.localStorage==\"undefined\")throw new Error(\"The current environment does not support local storage.\");if(this.LS=window.localStorage,t==null||!t)throw new Error(\"For local storage, modelPath must not be null, undefined or empty.\");this.modelPath=t,this.keys=hk(this.modelPath)}async save(t){if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserLocalStorage.save() does not support saving model topology in binary formats yet.\");{let e=JSON.stringify(t.modelTopology),o=JSON.stringify(t.weightSpecs),n=va(t),s=jt.join(t.weightData);try{this.LS.setItem(this.keys.info,JSON.stringify(n)),this.LS.setItem(this.keys.topology,e),this.LS.setItem(this.keys.weightSpecs,o),this.LS.setItem(this.keys.weightData,sk(s));let a={format:t.format,generatedBy:t.generatedBy,convertedBy:t.convertedBy,signature:t.signature!=null?t.signature:void 0,userDefinedMetadata:t.userDefinedMetadata!=null?t.userDefinedMetadata:void 0,modelInitializer:t.modelInitializer!=null?t.modelInitializer:void 0,initializerSignature:t.initializerSignature!=null?t.initializerSignature:void 0,trainingConfig:t.trainingConfig!=null?t.trainingConfig:void 0};return this.LS.setItem(this.keys.modelMetadata,JSON.stringify(a)),{modelArtifactsInfo:n}}catch(a){throw gk(this.keys),new Error(`Failed to save model '${this.modelPath}' to local storage: size quota being exceeded is a possible cause of this failure: modelTopologyBytes=${n.modelTopologyBytes}, weightSpecsBytes=${n.weightSpecsBytes}, weightDataBytes=${n.weightDataBytes}.`)}}}async load(){let t=JSON.parse(this.LS.getItem(this.keys.info));if(t==null)throw new Error(`In local storage, there is no model with name '${this.modelPath}'`);if(t.modelTopologyType!==\"JSON\")throw new Error(\"BrowserLocalStorage does not support loading non-JSON model topology yet.\");let e={},o=JSON.parse(this.LS.getItem(this.keys.topology));if(o==null)throw new Error(`In local storage, the topology of model '${this.modelPath}' is missing.`);e.modelTopology=o;let n=JSON.parse(this.LS.getItem(this.keys.weightSpecs));if(n==null)throw new Error(`In local storage, the weight specs of model '${this.modelPath}' are missing.`);e.weightSpecs=n;let s=this.LS.getItem(this.keys.modelMetadata);if(s!=null){let i=JSON.parse(s);e.format=i.format,e.generatedBy=i.generatedBy,e.convertedBy=i.convertedBy,i.signature!=null&&(e.signature=i.signature),i.userDefinedMetadata!=null&&(e.userDefinedMetadata=i.userDefinedMetadata),i.modelInitializer!=null&&(e.modelInitializer=i.modelInitializer),i.initializerSignature!=null&&(e.initializerSignature=i.initializerSignature),i.trainingConfig!=null&&(e.trainingConfig=i.trainingConfig)}let a=this.LS.getItem(this.keys.weightData);if(a==null)throw new Error(`In local storage, the binary weight values of model '${this.modelPath}' are missing.`);return e.weightData=ak(a),e}};Na.URL_SCHEME=\"localstorage://\";var xk=r=>A().getBool(\"IS_BROWSER\")&&!Array.isArray(r)&&r.startsWith(Na.URL_SCHEME)?R4(r.slice(Na.URL_SCHEME.length)):null;ft.registerSaveRouter(xk);ft.registerLoadRouter(xk);function R4(r){return new Na(r)}var cd=class{constructor(){$(A().getBool(\"IS_BROWSER\"),()=>\"Current environment is not a web browser\"),$(typeof window==\"undefined\"||typeof window.localStorage!=\"undefined\",()=>\"Current browser does not appear to support localStorage\"),this.LS=window.localStorage}async listModels(){let t={},e=uc+ai,o=ai+fk;for(let n=0;n\"scheme must not be undefined or null.\"),t.endsWith(pc)&&(t=t.slice(0,t.indexOf(pc))),$(t.length>0,()=>\"scheme must not be an empty string.\");let o=Zt.getInstance();$(o.managers[t]==null,()=>`A model store manager is already registered for scheme '${t}'.`),o.managers[t]=e}static getManager(t){let e=Zt.getInstance().managers[t];if(e==null)throw new Error(`Cannot find model manager for scheme '${t}'`);return e}static getSchemes(){return Object.keys(Zt.getInstance().managers)}};function ld(r){if(r.indexOf(pc)===-1)throw new Error(`The url string provided does not contain a scheme. Supported schemes are: ${Zt.getSchemes().join(\",\")}`);return{scheme:r.split(pc)[0],path:r.split(pc)[1]}}async function yk(r,t,e=!1){$(r!==t,()=>`Old path and new path are the same: '${r}'`);let o=ft.getLoadHandlers(r);$(o.length>0,()=>`Copying failed because no load handler is found for source URL ${r}.`),$(o.length<2,()=>`Copying failed because more than one (${o.length}) load handlers for source URL ${r}.`);let n=o[0],s=ft.getSaveHandlers(t);$(s.length>0,()=>`Copying failed because no save handler is found for destination URL ${t}.`),$(s.length<2,()=>`Copying failed because more than one (${o.length}) save handlers for destination URL ${t}.`);let a=s[0],i=ld(r).scheme,p=ld(r).path,u=i===ld(r).scheme,c=await n.load();e&&u&&await Zt.getManager(i).removeModel(p);let l=await a.save(c);return e&&!u&&await Zt.getManager(i).removeModel(p),l.modelArtifactsInfo}async function bk(){let r=Zt.getSchemes(),t={};for(let e of r){let o=await Zt.getManager(e).listModels();for(let n in o){let s=e+pc+n;t[s]=o[n]}}return t}async function Ck(r){let t=ld(r);return Zt.getManager(t.scheme).removeModel(t.path)}async function wk(r,t){return yk(r,t,!1)}async function Sk(r,t){return yk(r,t,!0)}var Dw=class{constructor(){this.messageName=\"setTimeoutCustom\",this.functionRefs=[],this.handledMessageCount=0,this.hasEventListener=!1}fetch(t,e){return fetch(t,e)}now(){return performance.now()}encode(t,e){if(e!==\"utf-8\"&&e!==\"utf8\")throw new Error(`Browser's encoder only supports utf-8, but got ${e}`);return this.textEncoder==null&&(this.textEncoder=new TextEncoder),this.textEncoder.encode(t)}decode(t,e){return new TextDecoder(e).decode(t)}setTimeoutCustom(t,e){if(typeof window==\"undefined\"||!A().getBool(\"USE_SETTIMEOUTCUSTOM\")){setTimeout(t,e);return}this.functionRefs.push(t),setTimeout(()=>{window.postMessage({name:this.messageName,index:this.functionRefs.length-1},\"*\")},e),this.hasEventListener||(this.hasEventListener=!0,window.addEventListener(\"message\",o=>{if(o.source===window&&o.data.name===this.messageName){o.stopPropagation();let n=this.functionRefs[o.data.index];n(),this.handledMessageCount++,this.handledMessageCount===this.functionRefs.length&&(this.functionRefs=[],this.handledMessageCount=0)}},!0))}isTypedArray(t){return Qm(t)}};if(A().get(\"IS_BROWSER\")){A().setPlatform(\"browser\",new Dw);try{Zt.registerManager(Na.URL_SCHEME,new cd)}catch(r){}try{Zt.registerManager(ka.URL_SCHEME,new pd)}catch(r){}}var D4={importFetch:()=>Ik()},Aw;var Fw=class{constructor(){this.util=vk(),this.textEncoder=new this.util.TextEncoder}fetch(t,e){return A().global.fetch!=null?A().global.fetch(t,e):(Aw==null&&(Aw=D4.importFetch()),Aw(t,e))}now(){let t=process.hrtime();return t[0]*1e3+t[1]/1e6}encode(t,e){if(e!==\"utf-8\"&&e!==\"utf8\")throw new Error(`Node built-in encoder only supports utf-8, but got ${e}`);return this.textEncoder.encode(t)}decode(t,e){return t.length===0?\"\":new this.util.TextDecoder(e).decode(t)}isTypedArray(t){return this.util.types.isFloat32Array(t)||this.util.types.isInt32Array(t)||this.util.types.isUint8Array(t)||this.util.types.isUint8ClampedArray(t)}};A().get(\"IS_NODE\")&&!A().get(\"IS_BROWSER\")&&A().setPlatform(\"node\",new Fw);function me(r,t=\"float32\",e){return t=t||\"float32\",wt(r),new tt(r,t,e)}function A4(r,t){let e=v(r,\"x\",\"cast\");if(!rw(t))throw new Error(`Failed to cast to unknown dtype ${t}`);if(t===\"string\"&&e.dtype!==\"string\"||t!==\"string\"&&e.dtype===\"string\")throw new Error(\"Only strings can be casted to strings\");let o={x:e},n={dtype:t};return T.runKernel(bo,o,n)}var We=N({cast_:A4});function F4(r){let e={x:v(r,\"x\",\"clone\",\"string_or_numeric\")};return T.runKernel(wo,e)}var Ur=N({clone_:F4});function md(r,t=!1){console.log(r.toString(t))}Sw();var P4={buffer:me,cast:We,clone:Ur,print:md};Q0(P4);function lde(){A().set(\"PROD\",!0)}function mde(){A().set(\"DEBUG\",!0)}function dde(){A().set(\"DEPRECATION_WARNINGS_ENABLED\",!1),console.warn(\"TensorFlow.js deprecation warnings have been disabled.\")}function Pw(r){A().getBool(\"DEPRECATION_WARNINGS_ENABLED\")&&console.warn(r+\" You can disable deprecation warnings with tf.disableDeprecationWarnings().\")}Z0(Pw);function fde(){T.disposeVariables()}function pr(){return T}function hde(){return T.memory()}function gde(r){return T.profile(r)}function De(r,t){return T.tidy(r,t)}function Mt(r){Sl(r).forEach(e=>e.dispose())}function Rr(r){return T.keep(r)}function xde(r){return T.time(r)}function yde(r){return T.setBackend(r)}function bde(){return T.ready()}function Cde(){return T.backendName}function wde(r){T.removeBackend(r)}function Sde(r){return T.findBackend(r)}function Ide(r){return T.findBackendFactory(r)}function su(r,t,e=1){return T.registerBackend(r,t,e)}function vde(){return T.backend}function kde(r,t){A().setPlatform(r,t)}function O4(r,t){let e=v(r,\"a\",\"add\"),o=v(t,\"b\",\"add\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(uo,n)}var Ce=N({add_:O4});function M4(r,t){let e=v(r,\"a\",\"floorDiv\"),o=v(t,\"b\",\"floorDiv\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(In,n)}var dd=N({floorDiv_:M4});function L4(r,t){let e=v(r,\"a\",\"div\"),o=v(t,\"b\",\"div\");if([e,o]=Oe(e,o),e.dtype===\"int32\"&&o.dtype===\"int32\")return dd(e,o);let n={a:e,b:o},s={};return T.runKernel(hn,n,s)}var je=N({div_:L4});function B4(r,t){let e=v(r,\"a\",\"mul\"),o=v(t,\"b\",\"mul\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(Yn,n)}var se=N({mul_:B4});function z4(r){let t=v(r,\"x\",\"abs\");if(t.dtype===\"complex64\"){let e={x:t};return T.runKernel(Pi,e)}else{let e={x:t};return T.runKernel(Xs,e)}}var Jt=N({abs_:z4});function V4(r){let e={x:v(r,\"x\",\"acos\")};return T.runKernel(Wo,e)}var kk=N({acos_:V4});function W4(r){let e={x:v(r,\"x\",\"acosh\")};return T.runKernel(Uo,e)}var Nk=N({acosh_:W4});function U4(r){$(Array.isArray(r),()=>\"The argument passed to tf.addN() must be a list of tensors\"),$(r.length>=1,()=>`Must pass at least one tensor to tf.addN(), but got ${r.length}`);let t=r.map((n,s)=>v(n,`tensors${s}`,\"addN\")),e=t[0];t.forEach(n=>{if(n.dtype!==e.dtype)throw new Error(\"All tensors passed to tf.addN() must have the same dtype\")}),t.forEach(n=>{if(!Cr(n.shape,e.shape))throw new Error(\"All tensors passed to tf.addN() must have the same shape\")});let o=t;return T.runKernel(Go,o)}var Tk=N({addN_:U4});function G4(r,t=null,e=!1){let n={x:v(r,\"x\",\"all\",\"bool\")},s={axis:t,keepDims:e};return T.runKernel(Ho,n,s)}var _k=N({all_:G4});function H4(r,t=null,e=!1){let n={x:v(r,\"x\",\"any\",\"bool\")},s={axis:t,keepDims:e};return T.runKernel(Ko,n,s)}var $k=N({any_:H4});function K4(r,t=0){let o={x:v(r,\"x\",\"argMax\")},n={axis:t};return T.runKernel(Ys,o,n)}var Ek=N({argMax_:K4});function q4(r,t=0){let o={x:v(r,\"x\",\"argMin\")},n={axis:t};return T.runKernel(Qs,o,n)}var Rk=N({argMin_:q4});function j4(r){let e={x:v(r,\"x\",\"asin\")};return T.runKernel(qo,e)}var Dk=N({asin_:j4});function X4(r){let e={x:v(r,\"x\",\"asinh\")};return T.runKernel(jo,e)}var Ak=N({asinh_:X4});function Y4(r){let e={x:v(r,\"x\",\"atan\")};return T.runKernel(Xo,e)}var Fk=N({atan_:Y4});function Q4(r,t){let e=v(r,\"a\",\"atan2\"),o=v(t,\"b\",\"atan2\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(Qo,n)}var Pk=N({atan2_:Q4});function Z4(r){let e={x:v(r,\"x\",\"atanh\")};return T.runKernel(Yo,e)}var Ok=N({atanh_:Z4});function J4(r,t,e,o,n=\"NHWC\",s){let a=r[3],i=[...t,a],p=Lk(n);return Hu(r,i,e,s,o,null,null,p)}function Mw(r,t,e,o,n,s,a=\"channelsLast\"){let[i,p]=vl(t),u;if(a===\"channelsLast\")u=[i,p,r[3],r[3]];else if(a===\"channelsFirst\")u=[i,p,r[1],r[1]];else throw new Error(`Unknown dataFormat ${a}`);return Hu(r,u,e,o,n,s,!1,a)}function eH(r,t,e,o,n,s,a=\"NDHWC\"){let[i,p,u]=Ow(t),c,l;if(a===\"NDHWC\")l=\"channelsLast\",c=[i,p,u,r[4],r[4]];else if(a===\"NCDHW\")l=\"channelsFirst\",c=[i,p,u,r[1],r[1]];else throw new Error(`Unknown dataFormat ${a}`);return Mk(r,c,e,o,n,!1,l,s)}function Hu(r,t,e,o,n,s,a=!1,i=\"channelsLast\"){let[p,u,c,l]=[-1,-1,-1,-1];if(i===\"channelsLast\")[p,u,c,l]=r;else if(i===\"channelsFirst\")[p,l,u,c]=r;else throw new Error(`Unknown dataFormat ${i}`);let[m,d,,f]=t,[h,g]=vl(e),[x,b]=vl(o),C=cc(m,x),S=cc(d,b),{padInfo:k,outHeight:_,outWidth:E}=oH(n,u,c,h,g,C,S,s,i),R=a?f*l:f,D;return i===\"channelsFirst\"?D=[p,R,_,E]:i===\"channelsLast\"&&(D=[p,_,E,R]),{batchSize:p,dataFormat:i,inHeight:u,inWidth:c,inChannels:l,outHeight:_,outWidth:E,outChannels:R,padInfo:k,strideHeight:h,strideWidth:g,filterHeight:m,filterWidth:d,effectiveFilterHeight:C,effectiveFilterWidth:S,dilationHeight:x,dilationWidth:b,inShape:r,outShape:D,filterShape:t}}function Mk(r,t,e,o,n,s=!1,a=\"channelsLast\",i){let[p,u,c,l,m]=[-1,-1,-1,-1,-1];if(a===\"channelsLast\")[p,u,c,l,m]=r;else if(a===\"channelsFirst\")[p,m,u,c,l]=r;else throw new Error(`Unknown dataFormat ${a}`);let[d,f,h,,g]=t,[x,b,C]=Ow(e),[S,k,_]=Ow(o),E=cc(d,S),R=cc(f,k),D=cc(h,_),{padInfo:P,outDepth:O,outHeight:M,outWidth:L}=nH(n,u,c,l,x,b,C,E,R,D,i),B=s?g*m:g,z;return a===\"channelsFirst\"?z=[p,B,O,M,L]:a===\"channelsLast\"&&(z=[p,O,M,L,B]),{batchSize:p,dataFormat:a,inDepth:u,inHeight:c,inWidth:l,inChannels:m,outDepth:O,outHeight:M,outWidth:L,outChannels:B,padInfo:P,strideDepth:x,strideHeight:b,strideWidth:C,filterDepth:d,filterHeight:f,filterWidth:h,effectiveFilterDepth:E,effectiveFilterHeight:R,effectiveFilterWidth:D,dilationDepth:S,dilationHeight:k,dilationWidth:_,inShape:r,outShape:z,filterShape:t}}function tH(r,t,e,o,n){o==null&&(o=Lw(r,t,e));let s=r[0],a=r[1],i=kl((s-t+2*o)/e+1,n),p=kl((a-t+2*o)/e+1,n);return[i,p]}function rH(r,t,e,o,n,s){n==null&&(n=Lw(r,t[0],o[0]));let a=[0,0,0,e];for(let i=0;i<3;i++)r[i]+2*n>=t[i]&&(a[i]=kl((r[i]-t[i]+2*n)/o[i]+1,s));return a}function Lw(r,t,e,o=1){let n=cc(t,o);return Math.floor((r[0]*(e-1)-e+n)/2)}function vl(r){return typeof r==\"number\"?[r,r,r]:r.length===2?[r[0],r[1],1]:r}function Ow(r){return typeof r==\"number\"?[r,r,r]:r}function cc(r,t){return t<=1?r:r+(r-1)*(t-1)}function oH(r,t,e,o,n,s,a,i,p){let u,c,l;if(typeof r==\"number\"){u={top:r,bottom:r,left:r,right:r,type:r===0?\"VALID\":\"NUMBER\"};let d=tH([t,e],s,o,r,i);c=d[0],l=d[1]}else if(r===\"same\"){c=Math.ceil(t/o),l=Math.ceil(e/n);let m=Math.max(0,(c-1)*o+s-t),d=Math.max(0,(l-1)*n+a-e),f=Math.floor(m/2),h=m-f,g=Math.floor(d/2),x=d-g;u={top:f,bottom:h,left:g,right:x,type:\"SAME\"}}else if(r===\"valid\")u={top:0,bottom:0,left:0,right:0,type:\"VALID\"},c=Math.ceil((t-s+1)/o),l=Math.ceil((e-a+1)/n);else if(typeof r==\"object\"){let m=p===\"channelsLast\"?r[1][0]:r[2][0],d=p===\"channelsLast\"?r[1][1]:r[2][1],f=p===\"channelsLast\"?r[2][0]:r[3][0],h=p===\"channelsLast\"?r[2][1]:r[3][1];u={top:m,bottom:d,left:f,right:h,type:m===0&&d===0&&f===0&&h===0?\"VALID\":\"EXPLICIT\"},c=kl((t-s+m+d)/o+1,i),l=kl((e-a+f+h)/n+1,i)}else throw Error(`Unknown padding parameter: ${r}`);return{padInfo:u,outHeight:c,outWidth:l}}function nH(r,t,e,o,n,s,a,i,p,u,c){let l,m,d,f;if(r===\"valid\"&&(r=0),typeof r==\"number\"){l={top:r,bottom:r,left:r,right:r,front:r,back:r,type:r===0?\"VALID\":\"NUMBER\"};let g=rH([t,e,o,1],[i,p,u],1,[n,s,a],r,c);m=g[0],d=g[1],f=g[2]}else if(r===\"same\"){m=Math.ceil(t/n),d=Math.ceil(e/s),f=Math.ceil(o/a);let h=(m-1)*n+i-t,g=(d-1)*s+p-e,x=(f-1)*a+u-o,b=Math.floor(h/2),C=h-b,S=Math.floor(g/2),k=g-S,_=Math.floor(x/2),E=x-_;l={top:S,bottom:k,left:_,right:E,front:b,back:C,type:\"SAME\"}}else throw Error(`Unknown padding parameter: ${r}`);return{padInfo:l,outDepth:m,outHeight:d,outWidth:f}}function kl(r,t){if(!t)return Math.trunc(r);switch(t){case\"round\":return Math.round(r);case\"ceil\":return Math.ceil(r);case\"floor\":return Math.floor(r);default:throw new Error(`Unknown roundingMode ${t}`)}}function Gu(r){let[t,e,o]=vl(r);return t===1&&e===1&&o===1}function xr(r,t){return Gu(r)||Gu(t)}function Ta(r){return vl(r).every(t=>t>0)}function Lk(r){if(r===\"NHWC\")return\"channelsLast\";if(r===\"NCHW\")return\"channelsFirst\";throw new Error(`Unknown dataFormat ${r}`)}function Bt(r,t,e){if(e!=null){if(typeof t==\"string\")throw Error(`Error in ${r}: pad must be an integer when using dimRoundingMode ${e} but got pad ${t}.`);if(typeof t==\"number\")$(qa(t),()=>`Error in ${r}: pad must be an integer when using dimRoundingMode ${e} but got pad ${t}.`);else if(typeof t==\"object\")t.forEach(o=>{o.forEach(n=>{$(qa(n),()=>`Error in ${r}: pad must be an integer when using dimRoundingMode ${e} but got pad ${n}.`)})});else throw Error(`Error in ${r}: Unknown padding parameter: ${t}`)}}function sH(r,t){let o={x:v(r,\"x\",\"reshape\",\"string_or_numeric\")},n={shape:t};return T.runKernel(da,o,n)}var W=N({reshape_:sH});function aH(r,t,e,o,n){let s=v(r,\"x\",\"avgPool\",\"float32\"),a=1;$(xr(e,a),()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${e} and dilations '${a}'`);let i=s,p=!1;s.rank===3&&(p=!0,i=W(s,[1,s.shape[0],s.shape[1],s.shape[2]])),$(i.rank===4,()=>`Error in avgPool: x must be rank 4 but got rank ${i.rank}.`),Bt(\"avgPool\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n},l=T.runKernel(Zo,u,c);return l=We(l,s.dtype),p?W(l,[l.shape[1],l.shape[2],l.shape[3]]):l}var fd=N({avgPool_:aH});function iH(r,t,e,o,n,s=\"NDHWC\"){let a=v(r,\"x\",\"avgPool3d\",\"float32\"),i=a,p=!1;a.rank===4&&(p=!0,i=W(a,[1,a.shape[0],a.shape[1],a.shape[2],a.shape[3]])),$(i.rank===5,()=>`Error in avgPool3d: x must be rank 5 but got rank ${i.rank}.`),$(s===\"NDHWC\",()=>`Error in avgPool3d: Only NDHWC is currently supported, but got dataFormat of ${s}`),$(typeof e==\"number\"&&e>0||Array.isArray(e)&&e[0]>0&&e[1]>0&&e[2]>0,()=>`Error in avgPool3d: Stride must be > 0, but got '${e}'`),Bt(\"avgPool3d\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n,dataFormat:s},l=T.runKernel(Zs,u,c);return l=We(l,i.dtype),p?W(l,[l.shape[1],l.shape[2],l.shape[3],l.shape[4]]):l}var Bk=N({avgPool3d_:iH});function uH(r,t=0){$(r.length>=1,()=>\"Pass at least one tensor to concat\");let e=si(r,\"tensors\",\"concat\",\"string_or_numeric\");if(e[0].dtype===\"complex64\"&&e.forEach(s=>{if(s.dtype!==\"complex64\")throw new Error(`Cannot concatenate complex64 tensors with a tensor\n with dtype ${s.dtype}. `)}),e.length===1)return Ur(e[0]);let o=e,n={axis:t};return T.runKernel(ta,o,n)}var bt=N({concat_:uH});function pH(r,t,e=!1,o=!1){let n=v(r,\"a\",\"matMul\"),s=v(t,\"b\",\"matMul\");[n,s]=Oe(n,s);let a={a:n,b:s},i={transposeA:e,transposeB:o};return T.runKernel(Jo,a,i)}var Ze=N({matMul_:pH});function cH(r){let e={x:v(r,\"x\",\"sigmoid\",\"float32\")};return T.runKernel(Cs,e)}var $a=N({sigmoid_:cH});function lH(r,t,e){let o=v(r,\"x\",\"slice\",\"string_or_numeric\");if(o.rank===0)throw new Error(\"Slicing scalar is not possible\");let n={x:o},s={begin:t,size:e};return T.runKernel(ha,n,s)}var Xe=N({slice_:lH});function mH(r){let e={x:v(r,\"x\",\"tanh\",\"float32\")};return T.runKernel(Es,e)}var Nl=N({tanh_:mH});function dH(r,t,e,o,n,s){let a=v(r,\"forgetBias\",\"basicLSTMCell\"),i=v(t,\"lstmKernel\",\"basicLSTMCell\"),p=v(e,\"lstmBias\",\"basicLSTMCell\"),u=v(o,\"data\",\"basicLSTMCell\"),c=v(n,\"c\",\"basicLSTMCell\"),l=v(s,\"h\",\"basicLSTMCell\"),m=bt([u,l],1),d=Ze(m,i),f=Ce(d,p),h=f.shape[0],g=f.shape[1]/4,x=[h,g],b=Xe(f,[0,0],x),C=Xe(f,[0,g],x),S=Xe(f,[0,g*2],x),k=Xe(f,[0,g*3],x),_=Ce(se($a(b),Nl(C)),se(c,$a(Ce(a,S)))),E=se(Nl(_),$a(k));return[_,E]}var zk=N({basicLSTMCell_:dH});function fH(r,t,e){let o=v(r,\"x\",\"batchToSpaceND\"),n=t.reduce((i,p)=>i*p);$(o.rank>=1+t.length,()=>`input rank is ${o.rank} but should be > than blockShape.length ${t.length}`),$(e.length===t.length,()=>`crops.length is ${e.length} but should be equal to blockShape.length ${t.length}`),$(o.shape[0]%n===0,()=>`input tensor batch is ${o.shape[0]} but is not divisible by the product of the elements of blockShape ${t.join(\" * \")} === ${n}`);let s={x:o},a={blockShape:t,crops:e};return T.runKernel(Js,s,a)}var hd=N({batchToSpaceND_:fH});function Vk(r){let t;return r.rank===0||r.rank===1?t=W(r,[1,1,1,r.size]):r.rank===2?t=W(r,[1,1,r.shape[0],r.shape[1]]):r.rank===3?t=W(r,[1,r.shape[0],r.shape[1],r.shape[2]]):t=r,t}function hH(r,t,e,o,n,s){s==null&&(s=.001);let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(i.rank===p.rank,()=>\"Batch normalization gradient requires mean and variance to have equal ranks.\"),$(c==null||i.rank===c.rank,()=>\"Batch normalization gradient requires mean and offset to have equal ranks.\"),$(u==null||i.rank===u.rank,()=>\"Batch normalization gradient requires mean and scale to have equal ranks.\");let m={x:Vk(a),scale:u,offset:c,mean:i,variance:p},d={varianceEpsilon:s},f=T.runKernel(vn,m,d);return W(f,a.shape)}var au=N({batchNorm_:hH});function gH(r,t,e,o,n,s){let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;return o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(a.rank===2,()=>`Error in batchNorm2D: x must be rank 2 but got rank ${a.rank}.`),$(i.rank===2||i.rank===1,()=>`Error in batchNorm2D: mean must be rank 2 or rank 1 but got rank ${i.rank}.`),$(p.rank===2||p.rank===1,()=>`Error in batchNorm2D: variance must be rank 2 or rank 1 but got rank ${p.rank}.`),u!=null&&$(u.rank===2||u.rank===1,()=>`Error in batchNorm2D: scale must be rank 2 or rank 1 but got rank ${u.rank}.`),c!=null&&$(c.rank===2||c.rank===1,()=>`Error in batchNorm2D: offset must be rank 2 or rank 1 but got rank ${c.rank}.`),au(a,i,p,c,u,s)}var Wk=N({batchNorm2d_:gH});function xH(r,t,e,o,n,s){let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;return o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(a.rank===3,()=>`Error in batchNorm3D: x must be rank 3 but got rank ${a.rank}.`),$(i.rank===3||i.rank===1,()=>`Error in batchNorm3D: mean must be rank 3 or rank 1 but got rank ${i.rank}.`),$(p.rank===3||p.rank===1,()=>`Error in batchNorm3D: variance must be rank 3 or rank 1 but got rank ${p.rank}.`),u!=null&&$(u.rank===3||u.rank===1,()=>`Error in batchNorm3D: scale must be rank 3 or rank 1 but got rank ${u.rank}.`),c!=null&&$(c.rank===3||c.rank===1,()=>`Error in batchNorm3D: offset must be rank 3 or rank 1 but got rank ${c.rank}.`),au(a,i,p,c,u,s)}var Uk=N({batchNorm3d_:xH});function yH(r,t,e,o,n,s){let a=v(r,\"x\",\"batchNorm\"),i=v(t,\"mean\",\"batchNorm\"),p=v(e,\"variance\",\"batchNorm\"),u;n!=null&&(u=v(n,\"scale\",\"batchNorm\"));let c;return o!=null&&(c=v(o,\"offset\",\"batchNorm\")),$(a.rank===4,()=>`Error in batchNorm4D: x must be rank 4 but got rank ${a.rank}.`),$(i.rank===4||i.rank===1,()=>`Error in batchNorm4D: mean must be rank 4 or rank 1 but got rank ${i.rank}.`),$(p.rank===4||p.rank===1,()=>`Error in batchNorm4D: variance must be rank 4 or rank 1 but got rank ${p.rank}.`),u!=null&&$(u.rank===4||u.rank===1,()=>`Error in batchNorm4D: scale must be rank 4 or rank 1 but got rank ${u.rank}.`),c!=null&&$(c.rank===4||c.rank===1,()=>`Error in batchNorm4D: offset must be rank 4 or rank 1 but got rank ${c.rank}.`),au(a,i,p,c,u,s)}var Gk=N({batchNorm4d_:yH});function bH(r,t,e){let o=v(r,\"x\",\"bincount\"),n=v(t,\"weights\",\"bincount\");$(o.dtype===\"int32\",()=>`Error in bincount: input dtype must be int32, but got ${o.dtype}`),$(e>=0,()=>`size must be non-negative, but got ${e}.`),$(n.size===o.size||n.size===0,()=>`Error in bincount: weights must have the same size as input or0-length, but got input shape: ${o.shape}, weights shape: ${n.shape}.`);let s={x:o,weights:n},a={size:e};return T.runKernel(en,s,a)}var gd=N({bincount_:bH});function CH(r,t){let e=v(r,\"x\",\"bitwiseAnd\"),o=v(t,\"y\",\"bitwiseAnd\");if(!Cr(e.shape,o.shape))throw new Error(`BitwiseAnd: Tensors must have the same shape. x: ${e.shape}, y: ${o.shape}`);if(e.dtype!==\"int32\"||o.dtype!==\"int32\")throw new Error(`BitwiseAnd: Only supports 'int32' values in tensor, found type of x: ${e.dtype} and type of y: ${o.dtype}`);let n={a:e,b:o};return T.runKernel(ja,n)}var Hk=N({bitwiseAnd_:CH});function wH(r,t){let e=v(r,\"s0\",\"broadcastArgs\",\"int32\"),o=v(t,\"s1\",\"broadcastArgs\",\"int32\");if(e.rank!==1)throw new Error(`broadcastArgs(): first input must be a vector (rank=1). Has rank ${e.rank}`);if(o.rank!==1)throw new Error(`broadcastArgs(): second input must be a vector (rank=1). Has rank ${o.rank}`);let n={s0:e,s1:o};return T.runKernel(ea,n)}var Kk=N({broadcastArgs_:wH});function SH(r,t){let e=v(r,\"broadcastTo\",\"x\"),o=e.shape;if(wt(t),t.lengthe.rank){let u=e.shape.slice();for(;u.length=0;u--)if(n[u]===t[u])s[u]=1;else if(e.shape[u]!==1)throw new Error(`broadcastTo(): [${o}] cannot be broadcast to [${t}].`);if(s.map((u,c)=>u>1?c:-1).filter(u=>u>=0).length===0)return Ur(e);let i={x:e},p={reps:s};return T.runKernel(po,i,p)}var iu=N({broadcastTo_:SH});function IH(r){let e={x:v(r,\"x\",\"ceil\",\"float32\")};return T.runKernel(tn,e)}var qk=N({ceil_:IH});function Ea(r,t,e){wt(r),e=e||Ri(t);let o={shape:r,value:t,dtype:e};return T.runKernel(sa,{},o)}function vH(r,t,e){let o=v(r,\"x\",\"clipByValue\");if($(t<=e,()=>`Error in clip: min (${t}) must be less than or equal to max (${e}).`),t===e)return Ea(o.shape,t,o.dtype);let n={x:o},s={clipValueMin:t,clipValueMax:e};return T.runKernel(Co,n,s)}var jk=N({clipByValue_:vH});function kH(r){return bt(r,0)}var Xk=N({concat1d_:kH});function NH(r,t){return bt(r,t)}var Yk=N({concat2d_:NH});function TH(r,t){return bt(r,t)}var Qk=N({concat3d_:TH});function _H(r,t){return bt(r,t)}var Zk=N({concat4d_:_H});function $H(r,t,e,o,n=\"NHWC\",s=[1,1],a){let i=v(r,\"x\",\"conv2d\",\"float32\"),p=v(t,\"filter\",\"conv2d\",\"float32\"),u=i,c=!1;i.rank===3&&(c=!0,u=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),$(u.rank===4,()=>`Error in conv2d: input must be rank 4, but got rank ${u.rank}.`),$(p.rank===4,()=>`Error in conv2d: filter must be rank 4, but got rank ${p.rank}.`),Bt(\"conv2d\",o,a);let l=n===\"NHWC\"?u.shape[3]:u.shape[1];$(l===p.shape[2],()=>`Error in conv2d: depth of input (${l}) must match input depth for filter ${p.shape[2]}.`),$(xr(e,s),()=>`Error in conv2D: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`),$(Ta(s),()=>\"Error in conv2D: Dilated rates should be larger than 0.\"),$(Ta(e),()=>\"Error in conv2D: Strides should be larger than 0.\");let m={x:u,filter:p},d={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a},f=T.runKernel(rn,m,d);return c?W(f,[f.shape[1],f.shape[2],f.shape[3]]):f}var uu=N({conv2d_:$H});function EH(r,t,e,o,n=\"NWC\",s=1,a){let i=v(r,\"x\",\"conv1d\"),p=v(t,\"filter\",\"conv1d\"),u=i,c=!1;i.rank===2&&(c=!0,u=W(i,[1,i.shape[0],i.shape[1]])),$(u.rank===3,()=>`Error in conv1d: input must be rank 3, but got rank ${u.rank}.`),$(p.rank===3,()=>`Error in conv1d: filter must be rank 3, but got rank ${p.rank}.`),Bt(\"conv1d\",o,a),$(u.shape[2]===p.shape[1],()=>`Error in conv1d: depth of input (${u.shape[2]}) must match input depth for filter ${p.shape[1]}.`),$(xr(e,s),()=>`Error in conv1D: Either stride or dilation must be 1. Got stride ${e} and dilation '${s}'`),$(Ta(s),()=>\"Error in conv1D: Dilated rates should be larger than 0.\"),$(Ta(e),()=>\"Error in conv1D: Stride should be larger than 0.\"),$(n===\"NWC\",()=>`Error in conv1d: got dataFormat of ${n} but only NWC is currently supported.`);let l=W(p,[1,p.shape[0],p.shape[1],p.shape[2]]),m=W(u,[u.shape[0],1,u.shape[1],u.shape[2]]),g=uu(m,l,[1,e],o,\"NHWC\",[1,s],a);return c?W(g,[g.shape[2],g.shape[3]]):W(g,[g.shape[0],g.shape[2],g.shape[3]])}var Jk=N({conv1d_:EH});function RH(r,t,e,o,n,s=\"NHWC\",a){$(r.length===t.rank,()=>`Length of inShape (${r.length}) and rank of dy (${t.rank}) must match`);let i=r,p=t,u=!1;t.rank===3&&(u=!0,p=W(t,[1,t.shape[0],t.shape[1],t.shape[2]]),i=[1,r[0],r[1],r[2]]),$(i.length===4,()=>`Error in conv2dDerInput: inShape must be length 4, but got length ${i.length}.`),$(p.rank===4,()=>`Error in conv2dDerInput: dy must be rank 4, but got rank ${p.rank}`),$(e.rank===4,()=>`Error in conv2dDerInput: filter must be rank 4, but got rank ${e.rank}`);let c=s===\"NHWC\"?i[3]:i[1],l=s===\"NHWC\"?p.shape[3]:p.shape[1];$(c===e.shape[2],()=>`Error in conv2dDerInput: depth of input (${c}) must match input depth for filter ${e.shape[2]}.`),$(l===e.shape[3],()=>`Error in conv2dDerInput: depth of output (${l}) must match output depth for filter ${e.shape[3]}.`),Bt(\"conv2dDerInput\",n,a);let m={dy:p,filter:e},d={strides:o,pad:n,dataFormat:s,dimRoundingMode:a,inputShape:i},f=T.runKernel(on,m,d);return u?W(f,[f.shape[1],f.shape[2],f.shape[3]]):f}var xd=N({conv2DBackpropInput_:RH});function DH(r,t,e,o,n,s){let a=v(r,\"x\",\"conv2dTranspose\"),i=v(t,\"filter\",\"conv2dTranspose\");return xd(e,a,i,o,n,\"NHWC\",s)}var e2=N({conv2dTranspose_:DH});function AH(r,t,e,o,n=\"NDHWC\",s=[1,1,1]){let a=v(r,\"x\",\"conv3d\"),i=v(t,\"filter\",\"conv3d\"),p=a,u=!1;a.rank===4&&(u=!0,p=W(a,[1,a.shape[0],a.shape[1],a.shape[2],a.shape[3]])),$(p.rank===5,()=>`Error in conv3d: input must be rank 5, but got rank ${p.rank}.`),$(i.rank===5,()=>`Error in conv3d: filter must be rank 5, but got rank ${i.rank}.`),$(p.shape[4]===i.shape[3],()=>`Error in conv3d: depth of input (${p.shape[4]}) must match input depth for filter ${i.shape[3]}.`),$(xr(e,s),()=>`Error in conv3D: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`),$(n===\"NDHWC\",()=>`Error in conv3d: got dataFormat of ${n} but only NDHWC is currently supported.`),$(Ta(s),()=>\"Error in conv3D: Dilated rates should be larger than 0.\"),$(Ta(e),()=>\"Error in conv3D: Strides should be larger than 0.\");let c={x:p,filter:i},l={strides:e,pad:o,dataFormat:n,dilations:s},m=T.runKernel(nn,c,l);return u?W(m,[m.shape[1],m.shape[2],m.shape[3],m.shape[4]]):m}var t2=N({conv3d_:AH});function FH(r,t,e,o,n){$(r.length===t.rank,()=>`Length of inShape (${r.length}) and rank of dy (${t.rank}) must match`);let s=r,a=t,i=!1;t.rank===4&&(i=!0,a=W(t,[1,t.shape[0],t.shape[1],t.shape[2],t.shape[3]]),s=[1,r[0],r[1],r[2],r[3]]);let p=s[4],u=a.shape[4];$(s.length===5,()=>`Error in conv3dDerInput: inShape must be length 5, but got length ${s.length}.`),$(a.rank===5,()=>`Error in conv3dDerInput: dy must be rank 5, but got rank ${a.rank}`),$(e.rank===5,()=>`Error in conv3dDerInput: filter must be rank 5, but got rank ${e.rank}`),$(p===e.shape[3],()=>`Error in conv3dDerInput: depth of input (${p}) must match input depth for filter ${e.shape[3]}.`),$(u===e.shape[4],()=>`Error in conv3dDerInput: depth of output (${u}) must match output depth for filter ${e.shape[4]}.`);let c={dy:a,filter:e},l={pad:n,strides:o,inputShape:s},m=T.runKernel(sn,c,l);return i?W(m,[m.shape[1],m.shape[2],m.shape[3],m.shape[4]]):m}var r2=N({conv3DBackpropInput_:FH});function PH(r,t,e,o,n){let s=v(r,\"x\",\"conv3dTranspose\"),a=v(t,\"filter\",\"conv3dTranspose\");return r2(e,s,a,o,n)}var o2=N({conv3dTranspose_:PH});function OH(r){let e={x:v(r,\"x\",\"cos\",\"float32\")};return T.runKernel(an,e)}var n2=N({cos_:OH});function MH(r){let e={x:v(r,\"x\",\"cosh\",\"float32\")};return T.runKernel(un,e)}var s2=N({cosh_:MH});function LH(r,t=0,e=!1,o=!1){let s={x:v(r,\"x\",\"cumprod\")},a={axis:t,exclusive:e,reverse:o};return T.runKernel(pn,s,a)}var a2=N({cumprod_:LH});function BH(r,t=0,e=!1,o=!1){let s={x:v(r,\"x\",\"cumsum\")},a={axis:t,exclusive:e,reverse:o};return T.runKernel(cn,s,a)}var i2=N({cumsum_:BH});function zH(r,t,e,o=!1){let n=v(r,\"x\",\"denseBincount\"),s=v(t,\"weights\",\"denseBincount\");$(n.dtype===\"int32\",()=>`Error in denseBincount: input dtype must be int32, but got ${n.dtype}`),$(n.rank<=2,()=>`Error in denseBincount: input must be at most rank 2, but got rank ${n.rank}.`),$(e>=0,()=>`size must be non-negative, but got ${e}.`),$(s.size===n.size||s.size===0,()=>`Error in denseBincount: weights must have the same shape as x or 0-length, but got x shape: ${n.shape}, weights shape: ${s.shape}.`);let a={x:n,weights:s},i={size:e,binaryOutput:o};return T.runKernel(ra,a,i)}var u2=N({denseBincount_:zH});function VH(r,t,e=\"NHWC\"){let o=v(r,\"x\",\"depthToSpace\",\"float32\"),n=e===\"NHWC\"?o.shape[1]:o.shape[2],s=e===\"NHWC\"?o.shape[2]:o.shape[3],a=e===\"NHWC\"?o.shape[3]:o.shape[1];$(t>1,()=>`blockSize should be > 1 for depthToSpace, but was: ${t}`),$(n*t>=0,()=>`Negative dimension size caused by overflow when multiplying\n ${n} and ${t} for depthToSpace with input shape\n ${o.shape}`),$(s*t>=0,()=>`Negative dimension size caused by overflow when multiplying\n ${s} and ${t} for depthToSpace with input shape\n ${o.shape}`),$(a%(t*t)===0,()=>`Dimension size must be evenly divisible by ${t*t} but is ${a} for depthToSpace with input shape ${o.shape}`);let i={x:o},p={blockSize:t,dataFormat:e};return T.runKernel(mn,i,p)}var p2=N({depthToSpace_:VH});function WH(r,t,e,o,n=\"NHWC\",s=[1,1],a){let i=v(r,\"x\",\"depthwiseConv2d\",\"float32\"),p=v(t,\"filter\",\"depthwiseConv2d\",\"float32\"),u=i,c=!1;i.rank===3&&(c=!0,u=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),$(u.rank===4,()=>`Error in depthwiseConv2d: input must be rank 4, but got rank ${u.rank}.`),$(p.rank===4,()=>`Error in depthwiseConv2d: filter must be rank 4, but got rank ${p.rank}.`);let l=n===\"NHWC\"?u.shape[3]:u.shape[1];$(l===p.shape[2],()=>`Error in depthwiseConv2d: number of input channels (${l}) must match the inChannels dimension in filter ${p.shape[2]}.`),Bt(\"depthwiseConv2d\",o,a);let m={x:u,filter:p},d={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a},f=T.runKernel(dn,m,d);return c?W(f,[f.shape[1],f.shape[2],f.shape[3]]):f}var lc=N({depthwiseConv2d_:WH});function UH(r){let e={x:v(r,\"x\",\"diag\")};return T.runKernel(oa,e)}var c2=N({diag_:UH});function GH(r,t,e,o,n=[1,1],s=\"NHWC\"){let a=v(r,\"x\",\"dilation2d\"),i=v(t,\"filter\",\"dilation2d\");$(a.rank===3||a.rank===4,()=>`Error in dilation2d: input must be rank 3 or 4, but got rank ${a.rank}.`),$(i.rank===3,()=>`Error in dilation2d: filter must be rank 3, but got rank ${i.rank}.`),$(s===\"NHWC\",()=>`Error in dilation2d: Only NHWC is currently supported, but got dataFormat of ${s}`);let p=a,u=!1;a.rank===3&&(p=W(a,[1,a.shape[0],a.shape[1],a.shape[2]]),u=!0),$(p.shape[3]===i.shape[2],()=>`Error in dilation2d: input and filter must have the same depth: ${p.shape[3]} vs ${i.shape[2]}`);let c={x:p,filter:i},l={strides:e,pad:o,dilations:n},m=T.runKernel(fn,c,l);return u?W(m,[m.shape[1],m.shape[2],m.shape[3]]):m}var l2=N({dilation2d_:GH});var Ir={};qe(Ir,{assertAndGetBroadcastShape:()=>rt,getBroadcastDims:()=>m2,getReductionAxes:()=>yd});function m2(r,t){let e=r.length,o=[];for(let n=0;n1&&a===1&&o.unshift(s)}return o}function yd(r,t){let e=[];for(let o=0;o1)&&e.unshift(s)}return e}function rt(r,t){let e=Math.max(r.length,t.length),o=new Array(e);for(let n=0;n`Error in dot: inputs must all be rank 1 or 2, but got ranks ${e.rank} and ${o.rank}.`);let n=e.rank===1?e.size:e.shape[1],s=o.rank===1?o.size:o.shape[0];if($(n===s,()=>`Error in dot: inner dimensions of inputs must match, but got ${n} and ${s}.`),e.rank===1&&o.rank===1){let a=W(e,[1,-1]),i=W(o,[-1,1]),p=Ze(a,i);return W(p,[])}else if(e.rank===1&&o.rank===2){let a=W(e,[1,-1]),i=W(o,[o.shape[0],o.shape[1]]),p=Ze(a,i);return W(p,[p.size])}else if(e.rank===2&&o.rank===1){let a=W(o,[-1,1]),i=Ze(e,a);return W(i,[i.size])}else{let a=W(o,[o.shape[0],o.shape[1]]);return Ze(e,a)}}var f2=N({dot_:XH});function YH(r,...t){let e=t.map((n,s)=>v(n,`tensors${s}`,\"einsum\")),o={equation:r};return T.runKernel(Vi,e,o)}var pu=N({einsum_:YH});function QH(r){let e={x:v(r,\"x\",\"elu\",\"float32\")};return T.runKernel(gn,e)}var Cd=N({elu_:QH});function ZH(r,t){let e=v(r,\"x\",\"ensureShape\",\"string_or_numeric\");if(!ZC(e.shape,t))throw new Error(`EnsureShape: Shape of tensor ${e.shape} is not compatible with expected shape ${t}`);return r}var h2=N({ensureShape_:ZH});function JH(r){let t=v(r,\"x\",\"erf\");$(t.dtype===\"int32\"||t.dtype===\"float32\",()=>\"Input dtype must be `int32` or `float32`.\"),t.dtype===\"int32\"&&(t=We(t,\"float32\"));let e={x:t};return T.runKernel(xn,e)}var g2=N({erf_:JH});function Bw(r,t){for(let e=0;er[s]);return[e,n]}function ii(r,t){let e=t.map(o=>1);return x2(r,e,t)}function tK(r,t,e){$(Bw(t,e),()=>`${r} supports only inner-most axes for now. Got axes ${t} and rank-${e} input.`)}function rK(r,t){if(Bw(r,t))return null;let e=[];for(let o=0;oe.push(o)),e}function oK(r){return r.map((t,e)=>[e,t]).sort((t,e)=>t[1]-e[1]).map(t=>t[0])}function nK(r,t){let e=[];for(let o=t-r;o\"Axis must be <= rank of the tensor\");let o={input:e},n={dim:t};return T.runKernel(na,o,n)}var Ms=N({expandDims_:hK});function gK(r){let e={x:v(r,\"x\",\"expm1\")};return T.runKernel(Cn,e)}var C2=N({expm1_:gK});function xK(r,t){let e=v(r,\"x\",\"tile\",\"string_or_numeric\");$(e.rank===t.length,()=>`Error in transpose: rank of input ${e.rank} must match length of reps ${t}.`);let o={x:e},n={reps:t};return T.runKernel(po,o,n)}var cu=N({tile_:xK});function yK(r,t,e,o=\"float32\"){t==null&&(t=r);let n=me([r,t],o),s=r<=t?r:t;for(let i=0;i`Error in localResponseNormalization: x must be rank 3 or 4 but got\n rank ${s.rank}.`),$(qa(t),()=>`Error in localResponseNormalization: depthRadius must be an integer but got depthRadius ${t}.`);let a=s,i=!1;s.rank===3&&(i=!0,a=W(s,[1,s.shape[0],s.shape[1],s.shape[2]]));let p={x:a},u={depthRadius:t,bias:e,alpha:o,beta:n},c=T.runKernel(zn,p,u);return i?W(c,[c.shape[1],c.shape[2],c.shape[3]]):c}var k2=N({localResponseNormalization_:EK});function RK(r){let e={x:v(r,\"x\",\"log\",\"float32\")};return T.runKernel(Pn,e)}var pi=N({log_:RK});function DK(r){let e={x:v(r,\"x\",\"log1p\")};return T.runKernel(On,e)}var Nd=N({log1p_:DK});function AK(r){return $(qs(r),()=>\"The f passed in grad(f) must be a function\"),(t,e)=>{let o=v(t,\"x\",\"tf.grad\",\"string_or_numeric\"),n=e!=null?v(e,\"dy\",\"tf.grad\"):null;return T.tidy(()=>{let{value:s,grads:a}=T.gradients(()=>r(o),[o],n);return n!=null&&yt(s.shape,n.shape,\"The shape of dy passed in grad(f)(x, dy) must match the shape returned by f(x)\"),Td(a),a[0]})}}function FK(r){return $(qs(r),()=>\"The f passed in grads(f) must be a function\"),(t,e)=>{$(Array.isArray(t),()=>\"The args passed in grads(f)(args) must be an array of `Tensor`s or `TensorLike`s\");let o=si(t,\"args\",\"tf.grads\",\"string_or_numeric\"),n=e!=null?v(e,\"dy\",\"tf.grads\"):null;return T.tidy(()=>{let{value:s,grads:a}=T.gradients(()=>r(...o),o,n);return n!=null&&yt(s.shape,n.shape,\"The shape of dy passed in grads(f)([x1,...], dy) must match the shape returned by f([x1,...])\"),Td(a),a})}}function PK(r){return $(qs(r),()=>\"The f passed in valueAndGrad(f) must be a function\"),(t,e)=>{$(t instanceof ut,()=>\"The x passed in valueAndGrad(f)(x) must be a tensor\"),$(e==null||e instanceof ut,()=>\"The dy passed in valueAndGrad(f)(x, dy) must be a tensor\");let{grads:o,value:n}=T.gradients(()=>r(t),[t],e);return Td(o),{grad:o[0],value:n}}}function OK(r){return $(qs(r),()=>\"The f passed in valueAndGrads(f) must be a function\"),(t,e)=>{$(Array.isArray(t)&&t.every(n=>n instanceof ut),()=>\"The args passed in valueAndGrads(f)(args) must be array of tensors\"),$(e==null||e instanceof ut,()=>\"The dy passed in valueAndGrads(f)(args, dy) must be a tensor\");let o=T.gradients(()=>r(...t),t,e);return e!=null&&yt(o.value.shape,e.shape,\"The shape of dy passed in valueAndGrads(f)([x1,...], dy) must match the shape returned by f([x1,...])\"),Td(o.grads),o}}function zw(r,t){$(qs(r),()=>\"The f passed in variableGrads(f) must be a function\"),$(t==null||Array.isArray(t)&&t.every(u=>u instanceof oi),()=>\"The varList passed in variableGrads(f, varList) must be an array of variables\");let e=t!=null;if(!e){t=[];for(let u in T.registeredVariables)t.push(T.registeredVariables[u])}let o=e?t.filter(u=>!u.trainable):null,n=t.length;t=t.filter(u=>u.trainable),$(t.length>0,()=>`variableGrads() expects at least one of the input variables to be trainable, but none of the ${n} variables is trainable.`);let s=!0,{value:a,grads:i}=T.gradients(r,t,null,s);$(i.some(u=>u!=null),()=>\"Cannot find a connection between any variable and the result of the loss function y=f(x). Please make sure the operations that use variables are inside the function f passed to minimize().\"),$(a.rank===0,()=>`The f passed in variableGrads(f) must return a scalar, but it returned a rank-${a.rank} tensor`);let p={};return t.forEach((u,c)=>{i[c]!=null&&(p[u.name]=i[c])}),o!=null&&o.forEach(u=>p[u.name]=null),{value:a,grads:p}}function vr(r){return T.customGrad(r)}function Td(r){if(r.filter(e=>e==null).length>0)throw new Error(`Cannot compute gradient of y=f(x) with respect to x. Make sure that\n the f you passed encloses all operations that lead from x to y.`)}function MK(r){let e={x:v(r,\"x\",\"neg\")};return T.runKernel(pa,e)}var cr=N({neg_:MK});function LK(r){let e={x:v(r,\"x\",\"softplus\")};return T.runKernel(ws,e)}var _d=N({softplus_:LK});function BK(r){let t=v(r,\"x\",\"logSigmoid\");return vr(o=>({value:cr(_d(cr(o))),gradFunc:a=>se(a,$a(cr(o)))}))(t)}var N2=N({logSigmoid_:BK});function zK(r,t){let e=v(r,\"a\",\"sub\"),o=v(t,\"b\",\"sub\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(_s,n)}var Te=N({sub_:zK});function VK(r,t=-1){let e=v(r,\"logits\",\"logSoftmax\");if(t===-1&&(t=e.rank-1),t!==e.rank-1)throw Error(`Log Softmax along a non-last dimension is not yet supported. Logits was rank ${e.rank} and axis was ${t}`);return vr((n,s)=>{let i=Ra(n,t,!0),p=Te(n,i),u=Te(We(p,\"float32\"),pi(ot($o(p),t,!0)));return s([u]),{value:u,gradFunc:(l,m)=>{let[d]=m,f=!0,h=$o(d);return Te(l,se(ot(l,t,f),h))}}})(e)}var T2=N({logSoftmax_:VK});function WK(r,t=null,e=!1){let o=v(r,\"x\",\"logSumExp\"),n=Ei(t,o.shape),s=Ra(o,n,!0),a=Te(o,s),i=$o(a),p=ot(i,n),u=pi(p),c=Ce(W(s,u.shape),u);if(e){let l=ii(c.shape,n);return W(c,l)}return c}var $d=N({logSumExp_:WK});function UK(r,t){let e=v(r,\"a\",\"logicalAnd\",\"bool\"),o=v(t,\"b\",\"logicalAnd\",\"bool\");rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Mn,n)}var ju=N({logicalAnd_:UK});function GK(r){let e={x:v(r,\"x\",\"logicalNot\",\"bool\")};return T.runKernel(Ln,e)}var Ed=N({logicalNot_:GK});function HK(r,t){let e=v(r,\"a\",\"logicalOr\",\"bool\"),o=v(t,\"b\",\"logicalOr\",\"bool\");rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Bn,n)}var Rd=N({logicalOr_:HK});function KK(r,t){let e=v(r,\"a\",\"logicalXor\",\"bool\"),o=v(t,\"b\",\"logicalXor\",\"bool\");return rt(e.shape,o.shape),ju(Rd(r,t),Ed(ju(r,t)))}var _2=N({logicalXor_:KK});var Dd=2147483648;function qK(r,t,e=\"left\"){let o=v(r,\"sortedSequence\",\"searchSorted\"),n=v(t,\"values\",\"searchSorted\"),s=o.shape[o.shape.length-1],a=n.shape[n.shape.length-1],i=W(o,[-1,s]),p=W(n,[-1,a]);if(i.rank<2)throw new Error(\"Sorted input argument must be at least 2-dimensional\");if(i.shape[0]!==p.shape[0])throw new Error(\"Leading dimension of 'sortedSequence' and 'values' must match.\");if(He(p.shape)>=Dd)throw new Error(`values tensor size must less than ${Dd}`);if(i.shape[1]>=Dd)throw new Error(`trailing dim_size must less than ${Dd} for int32 output type, was ${i.shape[1]}`);let u={sortedSequence:i,values:p},c={side:e};return T.runKernel(hs,u,c)}var $l=N({searchSorted_:qK});function $2(r,t){return $l(r,t,\"left\")}function jK(r,t,e,o,n){let s=v(r,\"x\",\"maxPool\"),a=1,i=s,p=!1;s.rank===3&&(p=!0,i=W(s,[1,s.shape[0],s.shape[1],s.shape[2]])),$(i.rank===4,()=>`Error in maxPool: input must be rank 4 but got rank ${i.rank}.`),$(xr(e,a),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${e} and dilations '${a}'`),Bt(\"maxPool\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n},l=T.runKernel(Un,u,c);return p?W(l,[l.shape[1],l.shape[2],l.shape[3]]):l}var Ad=N({maxPool_:jK});function XK(r,t=[1,1,1],e,o,n,s=\"NDHWC\"){let a=v(r,\"x\",\"maxPool3d\"),i=a,p=!1;a.rank===4&&(p=!0,i=W(a,[1,a.shape[0],a.shape[1],a.shape[2],a.shape[3]])),$(i.rank===5,()=>`Error in maxPool3d: x must be rank 5 but got rank ${i.rank}.`),$(s===\"NDHWC\",()=>`Error in maxPool3d: Only NDHWC is currently supported, but got dataFormat of ${s}`),Bt(\"maxPool3d\",o,n);let u={x:i},c={filterSize:t,strides:e,pad:o,dimRoundingMode:n,dataFormat:s},l=T.runKernel(ia,u,c);return p?W(l,[l.shape[1],l.shape[2],l.shape[3],l.shape[4]]):l}var E2=N({maxPool3d_:XK});function YK(r,t,e,o,n=!1){let a={x:v(r,\"x\",\"maxPoolWithArgmax\")},i={filterSize:t,strides:e,pad:o,includeBatchInIndex:n},p=T.runKernel(ua,a,i);return{result:p[0],indexes:p[1]}}var R2=N({maxPoolWithArgmax_:YK});function QK(r,t){let e=v(r,\"a\",\"maximum\"),o=v(t,\"b\",\"maximum\");[e,o]=Oe(e,o),e.dtype===\"bool\"&&(e=We(e,\"int32\"),o=We(o,\"int32\")),rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Wn,n)}var Fd=N({maximum_:QK});function ZK(r,t=null,e=!1){let n={x:v(r,\"x\",\"mean\")},s={axis:t,keepDims:e};return T.runKernel(Gn,n,s)}var Xu=N({mean_:ZK});function Gr(r,t=\"float32\"){if(wt(r),t===\"complex64\"){let o=Gr(r,\"float32\"),n=Gr(r,\"float32\");return Er(o,n)}let e=Yp(He(r),t);return T.makeTensor(e,r,t)}function Da(r,t=\"float32\"){if(wt(r),t===\"complex64\"){let o=Da(r,\"float32\"),n=Gr(r,\"float32\");return Er(o,n)}let e=fl(He(r),t);return T.makeTensor(e,r,t)}function D2(r,t,{indexing:e=\"xy\"}={}){if(e!==\"xy\"&&e!==\"ij\")throw new TypeError(`${e} is not a valid third argument to meshgrid`);if(r===void 0)return[];let o=v(r,\"x\",\"meshgrid\",r instanceof ut?r.dtype:\"float32\");if(t===void 0)return[o];let n=v(t,\"y\",\"meshgrid\",t instanceof ut?t.dtype:\"float32\"),s=He(o.shape),a=He(n.shape);return e===\"xy\"?(o=W(o,[1,-1]),n=W(n,[-1,1]),[Ze(Da([a,1],o.dtype),o),Ze(n,Da([1,s],n.dtype))]):(o=W(o,[-1,1]),n=W(n,[1,-1]),[Ze(o,Da([1,a],o.dtype)),Ze(Da([s,1],n.dtype),n)])}function JK(r,t){let e=v(r,\"a\",\"minimum\"),o=v(t,\"b\",\"minimum\");[e,o]=Oe(e,o),e.dtype===\"bool\"&&(e=We(e,\"int32\"),o=We(o,\"int32\")),rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Kn,n)}var Yu=N({minimum_:JK});function eq(r,t,e){$(e===\"reflect\"||e===\"symmetric\",()=>`Invalid mode. Mode must be either reflect or symmetric. Got ${e}.`);let o=v(r,\"x\",\"mirrorPad\");if(o.rank===0)throw new Error(\"mirrorPad(scalar) is not defined. Pass non-scalar to mirrorPad\");$(t.length===o.rank,()=>`Padding doesn't match input. Must be ${o.rank}. Got ${t.length}.`);let n=e===\"reflect\"?1:0;for(let i=0;i\"Invalid number of paddings. Must be length of 2 each.\"),$(t[i][0]>=0&&t[i][0]<=o.shape[i]-n&&t[i][1]>=0&&t[i][1]<=o.shape[i]-n,()=>`Padding in dimension ${i} cannot be greater than or equal to ${o.shape[i]-n} or less than 0 for input of shape ${o.shape}`);let s={paddings:t,mode:e},a={x:o};return T.runKernel(qn,a,s)}var A2=N({mirrorPad_:eq});function tq(r,t){let e=v(r,\"a\",\"mod\"),o=v(t,\"b\",\"mod\");[e,o]=Oe(e,o);let n={a:e,b:o};return T.runKernel(jn,n)}var F2=N({mod_:tq});function rq(r,t=null,e=!1){r=v(r,\"x\",\"moments\");let o=Ei(t,r.shape),n=Xu(r,o,e),s=n.shape;e||(s=ii(n.shape,o));let a=er(Te(We(r,\"float32\"),W(n,s))),i=Xu(a,o,e);return{mean:n,variance:i}}var P2=N({moments_:rq});function oq(r,t,e,o){let n=v(t,\"data\",\"multiRNNCell\"),s=si(e,\"c\",\"multiRNNCell\"),a=si(o,\"h\",\"multiRNNCell\"),i=n,p=[];for(let l=0;l2)throw new Error(`Rank of probabilities must be 1 or 2, but is ${a}`);e=e||Math.random();let p={logits:a===1?W(n,[1,-1]):n},u={numSamples:t,seed:e,normalized:o},c=T.runKernel(Xn,p,u);return a===1?W(c,[c.size]):c}var M2=N({multinomial_:nq});function sq(r,t){let e=v(r,\"a\",\"notEqual\",\"string_or_numeric\"),o=v(t,\"b\",\"notEqual\",\"string_or_numeric\");[e,o]=Oe(e,o),rt(e.shape,o.shape);let n={a:e,b:o};return T.runKernel(Qn,n)}var Pd=N({notEqual_:sq});function aq(r,t,e=1,o=0,n=\"int32\"){if(t<2)throw new Error(`Error in oneHot: depth must be >=2, but it is ${t}`);let a={indices:v(r,\"indices\",\"oneHot\",\"int32\")},i={dtype:n,depth:t,onValue:e,offValue:o};return T.runKernel(es,a,i)}var El=N({oneHot_:aq});function iq(r){let e={x:v(r,\"x\",\"onesLike\")};return T.runKernel(ca,e)}var L2=N({onesLike_:iq});function uq(r,t){let e=v(r,\"v1\",\"outerProduct\"),o=v(t,\"v2\",\"outerProduct\");$(e.rank===1&&o.rank===1,()=>`Error in outerProduct: inputs must be rank 1, but got ranks ${e.rank} and ${o.rank}.`);let n=W(e,[-1,1]),s=W(o,[1,-1]);return Ze(n,s)}var B2=N({outerProduct_:uq});function pq(r,t,e=0){let o=v(r,\"x\",\"pad\");if(o.rank===0)throw new Error(\"pad(scalar) is not defined. Pass non-scalar to pad\");let n={paddings:t,constantValue:e},s={x:o};return T.runKernel(ts,s,n)}var Aa=N({pad_:pq});function cq(r,t,e=0){return $(t.length===2,()=>\"Invalid number of paddings. Must be length of 2.\"),Aa(r,[t],e)}var z2=N({pad1d_:cq});function lq(r,t,e=0){return $(t.length===2&&t[0].length===2&&t[1].length===2,()=>\"Invalid number of paddings. Must be length of 2 each.\"),Aa(r,t,e)}var V2=N({pad2d_:lq});function mq(r,t,e=0){return $(t.length===3&&t[0].length===2&&t[1].length===2&&t[2].length===2,()=>\"Invalid number of paddings. Must be length of 2 each.\"),Aa(r,t,e)}var W2=N({pad3d_:mq});function dq(r,t,e=0){return $(t.length===4&&t[0].length===2&&t[1].length===2&&t[2].length===2&&t[3].length===2,()=>\"Invalid number of paddings. Must be length of 2 each.\"),Aa(r,t,e)}var U2=N({pad4d_:dq});function fq(r,t,e){let o=v(r,\"x\",\"spaceToBatchND\");$(o.rank>=1+t.length,()=>`input rank ${o.rank} should be > than [blockShape] ${t.length}`),$(e.length===t.length,()=>`paddings.shape[0] ${e.length} must be equal to [blockShape] ${t.length}`),$(o.shape.reduce((a,i,p)=>p>0&&p<=t.length?a&&(i+e[p-1][0]+e[p-1][1])%t[p-1]===0:a,!0),()=>`input spatial dimensions ${o.shape.slice(1)} with paddings ${e.toString()} must be divisible by blockShapes ${t.toString()}`);let n={x:o},s={blockShape:t,paddings:e};return T.runKernel(ga,n,s)}var Od=N({spaceToBatchND_:fq});function hq(r,t,e,o,n,s,a){n==null&&(n=[1,1]),s==null&&(s=1),o===0&&(o=\"valid\");let i=v(r,\"x\",\"maxPool\"),p=i,u=!1;i.rank===3&&(u=!0,p=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),$(xr(s,n),()=>`Error in pool: Either strides or dilations must be 1. Got strides ${s} and dilations '${n}'`);let c=Mw(p.shape,t,s,n,o),l=[c.dilationHeight,c.dilationWidth],m;o===\"same\"?m=xq([c.filterHeight,c.filterWidth],l):m=[[0,0],[0,0]];let d=l[0]===1&&l[1]===1,[f,h]=gq([c.inHeight,c.inWidth],l,m),g=d?o:\"valid\",x=d?p:Od(p,l,f),C=(e===\"avg\"?()=>fd(x,t,s,g,a):()=>Ad(x,t,s,g,a))(),S=d?C:hd(C,l,h);return u?W(S,[S.shape[1],S.shape[2],S.shape[3]]):S}function gq(r,t,e){let o=e.map(c=>c[0]),n=e.map(c=>c[1]),s=r.concat(o,n),a=t.map((c,l)=>(c-s[l]%c)%c),i=n.map((c,l)=>c+a[l]),p=t.map((c,l)=>[o[l],i[l]]),u=t.map((c,l)=>[0,a[l]]);return[p,u]}function xq(r,t){let o=r.map((a,i)=>a+(a-1)*(t[i]-1)).map(a=>a-1),n=o.map(a=>Math.floor(a/2)),s=o.map((a,i)=>a-n[i]);return o.map((a,i)=>[n[i],s[i]])}var G2=N({pool_:hq});function yq(r,t){let e=v(r,\"x\",\"prelu\"),o=v(t,\"alpha\",\"prelu\"),n={x:e,alpha:o};return T.runKernel(os,n)}var Md=N({prelu_:yq});function bq(r,t=null,e=!1){let o=v(r,\"x\",\"prod\");o.dtype===\"bool\"&&(o=We(o,\"int32\"));let n={x:o},s={axis:t,keepDims:e};return T.runKernel(ns,n,s)}var H2=N({prod_:bq});function Cq(r,t,e,o){let n=r.map((c,l)=>v(c,`tensors${l}`,\"raggedGather\",\"int32\")),s=v(t,\"paramsDenseValues\",\"raggedGather\"),a=v(e,\"indices\",\"raggedGather\",\"int32\"),i={paramsNestedSplits:n,paramsDenseValues:s,indices:a},p={outputRaggedRank:o},u=T.runKernel(Qp,i,p);return{outputNestedSplits:u.slice(0,u.length-1),outputDenseValues:u[u.length-1]}}var K2=N({raggedGather_:Cq});function wq(r,t,e){let o=v(r,\"starts\",\"raggedRange\"),n=v(t,\"limits\",\"raggedRange\",o.dtype),s=v(e,\"deltas\",\"raggedRange\",o.dtype),a={starts:o,limits:n,deltas:s},i=T.runKernel(Zp,a);return{rtNestedSplits:i[0],rtDenseValues:i[1]}}var q2=N({raggedRange_:wq});function Sq(r,t,e,o,n){let s=v(r,\"shape\",\"raggedTensorToTensor\",\"int32\"),a=v(t,\"values\",\"raggedTensorToTensor\"),i=v(e,\"defaultValue\",\"raggedTensorToTensor\",a.dtype),p=o.map((l,m)=>v(l,`tensors${m}`,\"raggedTensorToTensor\",\"int32\")),u={shape:s,values:a,defaultValue:i,rowPartitionTensors:p},c={rowPartitionTypes:n};return T.runKernel(Jp,u,c)}var j2=N({raggedTensorToTensor_:Sq});function Iq(r,t,e){wt(r);let o=He(r),n=null;if(e==null||e===\"float32\")n=new Float32Array(o);else if(e===\"int32\")n=new Int32Array(o);else if(e===\"bool\")n=new Uint8Array(o);else throw new Error(`Unknown data type ${e}`);for(let s=0;sm1,createVideoElement:()=>Oq,encodeStrings:()=>f1,expectArrayBuffersEqual:()=>Pq,expectArraysClose:()=>Rq,expectArraysEqual:()=>Aq,expectNumbersClose:()=>d1,expectPromiseToFail:()=>Dq,expectValuesInRange:()=>Fq,play:()=>Mq,testEpsilon:()=>Bd});var Eq=.001,m1=.1;function Rq(r,t,e){return e==null&&(e=Bd()),jw(r,t,(o,n)=>Xw(o,n,e))}function Bd(){return T.backend.floatPrecision()===32?Eq:m1}function jw(r,t,e){let o=!0;if((Ot(r)||Ot(t))&&(o=!1),Ot(r)&&Ot(t)&&(o=!0),o){let a=r.constructor.name,i=t.constructor.name;if(a!==i)throw new Error(`Arrays are of different type. Actual: ${a}. Expected: ${i}`)}if(Array.isArray(r)&&Array.isArray(t)){let a=ir(r),i=ir(t);if(!Cr(a,i))throw new Error(`Arrays have different shapes. Actual: [${a}]. Expected: [${i}]`)}let n=Ot(r)?r:Ps(r),s=Ot(t)?t:Ps(t);if(n.length!==s.length)throw new Error(`Arrays have different lengths actual: ${n.length} vs expected: ${s.length}.\nActual: ${n}.\nExpected: ${s}.`);for(let a=0;at.fail(),()=>t()),typeof expect!=\"undefined\"&&expect().nothing()}function Aq(r,t){let e=typeof t==\"string\"||typeof t==\"number\"||typeof t==\"boolean\"?[t]:t;return Vo(r)||Vo(r[0])||Vo(t)||Vo(t[0])?jw(r,e,(o,n)=>o==n):jw(r,t,(o,n)=>Xw(o,n,0))}function d1(r,t,e){if(e==null&&(e=Bd()),!Xw(r,t,e))throw new Error(`Numbers differ: actual === ${r}, expected === ${t}`);typeof expect!=\"undefined\"&&expect().nothing()}function Xw(r,t,e){return!isFinite(r)&&!isFinite(t)?!0:!(isNaN(r)||isNaN(t)||Math.abs(r-t)>e)}function Fq(r,t,e){for(let o=0;oe)throw new Error(`Value out of range:${r[o]} low: ${t}, high: ${e}`)}function Pq(r,t){let e=new Float32Array(r),o=new Float32Array(t);if(e.length!==o.length)throw new Error(`Expected ArrayBuffer to be of length ${o.length}, but it was ${e.length}`);for(let n=0;n{t.addEventListener(\"loadeddata\",o=>e(t)),t.load()})}async function Mq(r){await r.play(),\"requestVideoFrameCallback\"in r&&await new Promise(t=>{r.requestVideoFrameCallback(t)})}var Zu=class{constructor(t,e,o,n,s){this.mean=t,this.stdDev=e,this.dtype=o,this.nextVal=NaN,this.truncated=n,this.truncated&&(this.upper=this.mean+this.stdDev*2,this.lower=this.mean-this.stdDev*2);let a=s||Math.random();this.random=Wd.alea(a.toString())}nextValue(){if(!isNaN(this.nextVal)){let n=this.nextVal;return this.nextVal=NaN,n}let t,e,o=!1;for(;!o;){let n,s,a;do n=2*this.random()-1,s=2*this.random()-1,a=n*n+s*s;while(a>=1||a===0);let i=Math.sqrt(-2*Math.log(a)/a);t=this.mean+this.stdDev*n*i,e=this.mean+this.stdDev*s*i,(!this.truncated||this.isValidTruncated(t))&&(o=!0)}return(!this.truncated||this.isValidTruncated(e))&&(this.nextVal=this.convertValue(e)),this.convertValue(t)}convertValue(t){return this.dtype==null||this.dtype===\"float32\"?t:Math.round(t)}isValidTruncated(t){return t<=this.upper&&t>=this.lower}},zd=class{constructor(t,e,o,n){this.alpha=t,this.beta=1/e,this.dtype=o;let s=n||Math.random();this.randu=Wd.alea(s.toString()),this.randn=new Zu(0,1,o,!1,this.randu()),t<1?this.d=t+2/3:this.d=t-1/3,this.c=1/Math.sqrt(9*this.d)}nextValue(){let t,e,o,n,s,a;for(;;){do n=this.randn.nextValue(),a=1+this.c*n;while(a<=0);if(a*=a*a,t=n*n,e=1-.331*t*t,o=.5*t+this.d*(1-a+Math.log(a)),s=this.randu(),sthis.dtype==null||this.dtype===\"float32\",this.min=t,this.range=e-t,this.dtype=o,n==null&&(n=Math.random()),typeof n==\"number\"&&(n=n.toString()),!this.canReturnFloat()&&this.range<=1)throw new Error(`The difference between ${t} - ${e} <= 1 and dtype is not float`);this.random=Wd.alea(n)}convertValue(t){return this.canReturnFloat()?t:Math.round(t)}nextValue(){return this.convertValue(this.min+this.range*this.random())}};function Lq(r,t,e=1,o=\"float32\",n){if(wt(r),e==null&&(e=1),o==null&&(o=\"float32\"),o!==\"float32\"&&o!==\"int32\")throw new Error(`Unsupported data type ${o}`);let s=new zd(t,e,o,n),a=me(r,o);for(let i=0;i`Error in reverse1D: x must be rank 1 but got rank ${t.rank}.`),mo(t,0)}var C1=N({reverse1d_:jq});function Xq(r,t){let e=v(r,\"x\",\"reverse\");return $(e.rank===2,()=>`Error in reverse2D: x must be rank 2 but got rank ${e.rank}.`),mo(e,t)}var w1=N({reverse2d_:Xq});function Yq(r,t){let e=v(r,\"x\",\"reverse\");return $(e.rank===3,()=>`Error in reverse3D: x must be rank 3 but got rank ${e.rank}.`),mo(e,t)}var S1=N({reverse3d_:Yq});function Qq(r,t){let e=v(r,\"x\",\"reverse\");return $(e.rank===4,()=>`Error in reverse4D: x must be rank 4 but got rank ${e.rank}.`),mo(e,t)}var I1=N({reverse4d_:Qq});function Zq(r){let e={x:v(r,\"x\",\"round\")};return T.runKernel(ls,e)}var Hd=N({round_:Zq});function Jq(r){let e={x:v(r,\"x\",\"rsqrt\",\"float32\")};return T.runKernel(ms,e)}var v1=N({rsqrt_:Jq});function e6(r){let e={x:v(r,\"x\",\"selu\")};return T.runKernel(gs,e)}var k1=N({selu_:e6});function t6(r,t,e,o,n,s=[1,1],a=\"NHWC\"){let i=v(r,\"x\",\"separableConv2d\"),p=v(t,\"depthwiseFilter\",\"separableConv2d\"),u=v(e,\"pointwiseFilter\",\"separableConv2d\"),c=i,l=!1;if(i.rank===3&&(l=!0,c=W(i,[1,i.shape[0],i.shape[1],i.shape[2]])),a===\"NCHW\")throw new Error(\"separableConv2d currently does not support dataFormat NCHW; only NHWC is supported\");$(c.rank===4,()=>`Error in separableConv2d: input must be rank 4, but got rank ${c.rank}.`),$(p.rank===4,()=>`Error in separableConv2d: depthwise filter must be rank 4, but got rank ${p.rank}.`),$(u.rank===4,()=>`Error in separableConv2d: pointwise filter must be rank 4, but got rank ${p.rank}.`),$(u.shape[0]===1,()=>`Error in separableConv2d: the first dimension of pointwise filter must be 1, but got ${u.shape[0]}.`),$(u.shape[1]===1,()=>`Error in separableConv2d: the second dimension of pointwise filter must be 1, but got ${u.shape[1]}.`);let m=p.shape[2],d=p.shape[3];$(u.shape[2]===m*d,()=>`Error in separableConv2d: the third dimension of pointwise filter must be ${m*d}, but got ${u.shape[2]}.`);let f=lc(c,p,o,n,a,s),g=uu(f,u,1,\"valid\",a);return l?W(g,[g.shape[1],g.shape[2],g.shape[3]]):g}var N1=N({separableConv2d_:t6});async function r6(r,t){let e=v(r,\"x\",\"setdiff1d\"),o=v(t,\"y\",\"setdiff1d\");$(e.dtype===o.dtype,()=>`x and y should have the same dtype, but got x (${e.dtype}) and y (${o.dtype}).`),$(e.rank===1,()=>`x should be 1D tensor, but got x (${e.shape}).`),$(o.rank===1,()=>`y should be 1D tensor, but got y (${o.shape}).`);let n=await e.data(),s=await o.data(),a=new Set(s),i=0;for(let c=0;c`slice1d expects a rank-1 tensor, but got a rank-${o.rank} tensor`),Xe(o,[t],[e])}var R1=N({slice1d_:a6});function i6(r,t,e){let o=v(r,\"x\",\"slice2d\");return $(o.rank===2,()=>`slice2d expects a rank-2 tensor, but got a rank-${o.rank} tensor`),Xe(o,t,e)}var D1=N({slice2d_:i6});function u6(r,t,e){let o=v(r,\"x\",\"slice3d\");return $(o.rank===3,()=>`slice3d expects a rank-3 tensor, but got a rank-${o.rank} tensor`),Xe(o,t,e)}var A1=N({slice3d_:u6});function p6(r,t,e){let o=v(r,\"x\",\"slice4d\");return $(o.rank===4,()=>`slice4d expects a rank-4 tensor, but got a rank-${o.rank} tensor`),Xe(o,t,e)}var F1=N({slice4d_:p6});function c6(r,t=-1){let e=v(r,\"logits\",\"softmax\",\"float32\");if(t===-1&&(t=e.rank-1),t!==e.rank-1)throw Error(`Softmax along a non-last dimension is not yet supported. Logits was rank ${e.rank} and dim was ${t}`);let o={logits:e},n={dim:t};return T.runKernel(vs,o,n)}var P1=N({softmax_:c6});function l6(r){$(r.dtype===\"complex64\",()=>`The dtype for tf.spectral.fft() must be complex64 but got ${r.dtype}.`);let t={input:r};return T.runKernel(Wi,t)}var fc=N({fft_:l6});function m6(r){$(r.dtype===\"complex64\",()=>`The dtype for tf.spectral.ifft() must be complex64 but got ${r.dtype}.`);let t={input:r};return T.runKernel(Ui,t)}var Ju=N({ifft_:m6});function d6(r){let t=r.shape[r.shape.length-1],e=r.size/t,o;if(t<=2){let n=W(r,[e,t]);o=Ju(n)}else{let n=[e,2*(t-1)],s=W(ci(r),[e,t]),a=W(lu(r),[e,t]),i=mo(Xe(s,[0,1],[e,t-2]),1),p=se(mo(Xe(a,[0,1],[e,t-2]),1),ke(-1)),u=bt([s,i],1),c=bt([a,p],1),l=W(Er(u,c),[n[0],n[1]]);o=Ju(l)}if(o=ci(o),r.rank===3&&r.shape[0]!==0){let n=o,s=r.shape[0];o=W(o,[s,o.shape[0]/s,o.shape[1]]),n.dispose()}return o}var Kd=N({irfft_:d6});function f6(r,t,e=0){let n={x:v(r,\"x\",\"split\")},s={numOrSizeSplits:t,axis:e};return T.runKernel(xa,n,s)}var li=N({split_:f6});function h6(r,t){$(r.dtype===\"float32\",()=>`The dtype for rfft() must be real value but got ${r.dtype}`);let e=r.shape[r.shape.length-1],o=r.size/e,n;if(t!=null&&t0),h=r.shape.map(g=>g);h[r.shape.length-1]=t,n=Xe(r,f,h),e=t}else if(t!=null&&t>e){let f=r.shape.map(h=>h);f[r.shape.length-1]=t-e,n=bt([r,Gr(f)],r.shape.length-1),e=t}else n=r;let s=Ht(n),a=W(Er(n,s),[o,e]),i=fc(a),p=Math.floor(e/2)+1,u=ci(i),c=lu(i),l=li(u,[p,e-p],u.shape.length-1),m=li(c,[p,e-p],c.shape.length-1),d=n.shape.slice();return d[n.shape.length-1]=p,W(Er(l[0],m[0]),d)}var hc=N({rfft_:h6});function g6(r,t){let e=v(r,\"a\",\"squaredDifference\"),o=v(t,\"b\",\"squaredDifference\");[e,o]=Oe(e,o),rt(e.shape,o.shape);let n={a:e,b:o},s={};return T.runKernel(Ns,n,s)}var qd=N({squaredDifference_:g6});function x6(r,t){let e=v(r,\"x\",\"squeeze\",\"string_or_numeric\");return W(e,JC(e.shape,t).newShape)}var gc=N({squeeze_:x6});function y6(r,t=0){let e=si(r,\"tensors\",\"stack\",\"string_or_numeric\");$(e.length>=1,()=>\"Pass at least one tensor to tf.stack\"),e.length>0&&$(t<=e[0].rank,()=>\"Axis must be <= rank of the tensor\");let o=e,n={axis:t};return T.runKernel(la,o,n)}var kr=N({stack_:y6});function b6(r,t=0){let o={x:v(r,\"x\",\"step\")},n={alpha:t};return T.runKernel(So,o,n)}var jd=N({step_:b6});function C6(r,t,e,o,n=0,s=0,a=0,i=0,p=0){let c={x:v(r,\"x\",\"stridedSlice\",\"string_or_numeric\")},l={begin:t,end:e,strides:o,beginMask:n,endMask:s,ellipsisMask:a,newAxisMask:i,shrinkAxisMask:p};return T.runKernel(Ts,c,l)}var O1=N({stridedSlice_:C6});function w6(r){let e={x:v(r,\"x\",\"tan\",\"float32\")};return T.runKernel($s,e)}var M1=N({tan_:w6});function tr(r,t){io(r);let e=ir(r,t);if(e.length!==1)throw new Error(\"tensor1d() requires values to be a flat/TypedArray\");return Sr(r,null,e,t)}function fu(r,t,e){if(io(r),t!=null&&t.length!==2)throw new Error(\"tensor2d() requires shape to have two numbers\");let o=ir(r,e);if(o.length!==2&&o.length!==1)throw new Error(\"tensor2d() requires values to be number[][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor2d() requires shape to be provided when `values` are a flat/TypedArray\");return Sr(r,t,o,e)}function Xd(r,t,e){if(io(r),t!=null&&t.length!==3)throw new Error(\"tensor3d() requires shape to have three numbers\");let o=ir(r,e);if(o.length!==3&&o.length!==1)throw new Error(\"tensor3d() requires values to be number[][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor3d() requires shape to be provided when `values` are a flat array\");return Sr(r,t,o,e)}function L1(r,t,e){if(io(r),t!=null&&t.length!==4)throw new Error(\"tensor4d() requires shape to have four numbers\");let o=ir(r,e);if(o.length!==4&&o.length!==1)throw new Error(\"tensor4d() requires values to be number[][][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor4d() requires shape to be provided when `values` are a flat array\");return Sr(r,t,o,e)}function B1(r,t,e){if(io(r),t!=null&&t.length!==5)throw new Error(\"tensor5d() requires shape to have five numbers\");let o=ir(r,e);if(o.length!==5&&o.length!==1)throw new Error(\"tensor5d() requires values to be number[][][][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor5d() requires shape to be provided when `values` are a flat array\");return Sr(r,t,o,e)}function z1(r,t,e){if(io(r),t!=null&&t.length!==6)throw new Error(\"tensor6d() requires shape to have six numbers\");let o=ir(r,e);if(o.length!==6&&o.length!==1)throw new Error(\"tensor6d() requires values to be number[][][][][][] or flat/TypedArray\");if(o.length===1&&t==null)throw new Error(\"tensor6d() requires shape to be provided when `values` are a flat array\");return t=t||o,Sr(r,t,o,e)}var hu={};qe(hu,{calculateShapes:()=>V1,validateInput:()=>xc,validateUpdateShape:()=>Yw});function Yw(r,t,e){let o=t.rank>1?t.shape[t.rank-1]:1,n=t.rank>1?t.rank-1:1,s=`Must have updates.shape = indices.shape[:batchDim] + shape[sliceDim:], got updates.shape: ${e.shape}, indices.shape: ${t.shape}, shape: ${r}, sliceDim: ${o}, and batchDim: ${n}.`;if(e.rank1?t.shape[o-1]:1,s=e.length,a=1;for(let l=n;l= 0 but got ${t}`);if(t>n)throw new Error(`'k' passed to topk() must be <= the last dimension (${n}) but got ${t}`);let s={x:o},a={k:t,sorted:e},[i,p]=T.runKernel(Rs,s,a);return{values:i,indices:p}}var U1=N({topk_:I6});function v6(r,t=0,e=1,o,n){if(wt(r),o!=null&&o===\"bool\")throw new Error(\"Unsupported data type $ { dtype }\");let s=new Zu(t,e,o,!0,n),a=me(r,o);for(let i=0;i0,()=>\"The input tensor must be at least 1D\");let o={x:e},n={axis:t},[s,a]=T.runKernel(Zi,o,n);return{values:s,indices:a}}var H1=N({unique_:k6});function N6(r,t,e){let o=v(r,\"x\",\"unsortedSegmentSum\"),n=v(t,\"segmentIds\",\"unsortedSegmentSum\",\"int32\");$(qa(e),()=>\"numSegments must be of dtype int\");let s={x:o,segmentIds:n},a={numSegments:e};return T.runKernel(Ji,s,a)}var K1=N({unsortedSegmentSum_:N6});function T6(r,t=0){let e=v(r,\"x\",\"unstack\",\"string_or_numeric\");$(t>=-e.shape.length&&t`Axis = ${t} is not in [-${e.shape.length}, ${e.shape.length})`);let o={value:e},n={axis:t};return T.runKernel(wa,o,n)}var fo=N({unstack_:T6});function q1(r,t){return $l(r,t,\"right\")}function j1(r,t=!0,e,o){return T.makeVariable(r,t,e,o)}function Yd(r,t){let e=[];for(let s=0;s0,()=>\"mask cannot be scalar\"),yt(i.slice(s,s+a),n.shape,\"mask's shape must match the first K dimensions of tensor's shape,\");let p=1;for(let h=s;hi).reverse()),$(o.rank===t.length,()=>`Error in transpose: rank of input ${o.rank} must match length of perm ${t}.`),t.forEach(a=>{$(a>=0&&a`All entries in 'perm' must be between 0 and ${o.rank-1} but got ${t}`)}),o.rank<=1)return o.clone();let n={x:o},s={perm:t};return o.dtype===\"complex64\"?De(()=>{let a=ci(o),i=lu(o);return a=T.runKernel(co,{x:a},s),i=T.runKernel(co,{x:i},s),e&&(i=cr(i)),Er(a,i)}):T.runKernel(co,n,s)}var yc=N({transpose_:R6});function D6(r,t,e,o,n=!0){let s=v(r,\"v\",\"movingAverage\"),a=v(t,\"x\",\"movingAverage\"),i=v(e,\"decay\",\"movingAverage\");Cw(s,a),$(Cr(s.shape,a.shape),()=>\"Shape mismatch in v and x\");let p=ke(1),u=Te(p,i),c=se(Te(a,s),u);if(n){$(o!=null,()=>\"When using zeroDebias: true, step is required.\");let l=v(o,\"step\",\"movingAverage\");c=je(c,Te(p,ui(i,l)))}return Ce(s,c)}var A6=N({movingAverage_:D6});function F6(r,t,e){wt(e);let o=v(r,\"indices\",\"scatterND\",\"int32\"),n=v(t,\"updates\",\"scatterND\");xc(n,o,e);let s={indices:o,updates:n},a={shape:e};return T.runKernel(ds,s,a)}var P6=N({scatterND_:F6});function X1(r,t,e,o){if(r.dtype!==\"int32\")throw new Error(`tf.sparseToDense() expects the indices to be int32 type, but the dtype was ${r.dtype}.`);if(r.rank>2)throw new Error(`sparseIndices should be a scalar, vector, or matrix, but got shape ${r.shape}.`);let n=r.rank>0?r.shape[0]:1,s=r.rank>1?r.shape[1]:1;if(e.length!==s)throw new Error(`outputShape has incorrect number of elements:, ${e.length}, should be: ${s}.`);let a=t.size;if(!(t.rank===0||t.rank===1&&a===n))throw new Error(`sparseValues has incorrect shape ${t.shape}, should be [] or [${n}]`);if(t.dtype!==o.dtype)throw new Error(\"sparseValues.dtype must match defaultValues.dtype\")}function M6(r,t,e,o=0){wt(e);let n=v(r,\"sparseIndices\",\"sparseToDense\",\"int32\"),s=v(t,\"sparseValues\",\"sparseToDense\",\"string_or_numeric\"),a=v(o,\"defaultValue\",\"sparseToDense\",s.dtype);X1(n,s,e,a);let i={sparseIndices:n,sparseValues:s,defaultValue:a},p={outputShape:e};return T.runKernel(ks,i,p)}var L6=N({sparseToDense_:M6});function B6(r,t){let e=v(t,\"indices\",\"gatherND\",\"int32\"),n={params:v(r,\"x\",\"gatherND\",\"string_or_numeric\"),indices:e};return T.runKernel(kn,n)}var z6=N({gatherND_:B6});function Y1(r,t){if(t==null)return r.shape.slice();if(Cr(r.shape,t))return t;if(r.shape.length===t.length){let e=[];for(let o=0;o`x has to be a floating point tensor since it's going to be scaled, but got a ${n.dtype} tensor instead.`),$(t>=0&&t<1,()=>`rate must be a float in the range [0, 1), but got ${t}.`),t===0)return r instanceof ut?n.clone():n;let s=Y1(n,e),a=1-t,i=je(Sd(Ce(dc(s,0,1,\"float32\",o),a)),a);return se(n,i)}var W6=N({dropout_:V6});function Qw(r){return Math.floor(Math.pow(2,Math.ceil(Math.log(r)/Math.log(2))))}function Rl(r,t,e){let o=1-r%2,n=new Float32Array(r);for(let s=0;s1,()=>`inTopK() expects the predictions to be of rank 2 or higher, but got ${o.rank}`),$(o.rank-1===n.rank,()=>`predictions rank should be 1 larger than targets rank, but got predictions rank ${o.rank} and targets rank ${n.rank}`),yt(o.shape.slice(0,o.shape.length-1),n.shape,\"predictions's shape should be align with the targets' shape, except the last dimension.\");let s=o.shape[o.shape.length-1];$(e>0&&e<=s,()=>`'k' passed to inTopK() must be > 0 && <= the predictions last dimension (${s}), but got ${e}`);let a=await o.data(),i=await n.data(),[p,u]=[a.length/s,s],c=ew(\"bool\",p);for(let l=0;lg.value-h.value),c[l]=0;for(let h=0;hZ1,depthwiseConv2d:()=>tN,matMul:()=>rN});function H6(r,t,e,o,n,s=\"NHWC\",a){let i=r;r.rank===3&&(i=W(r,[1,r.shape[0],r.shape[1],r.shape[2]]));let p=t;p.rank===3&&(p=W(t,[1,t.shape[0],t.shape[1],t.shape[2]])),$(i.rank===4,()=>`Error in conv2dDerFilter: input must be rank 4, but got shape ${i.shape}.`),$(p.rank===4,()=>`Error in conv2dDerFilter: dy must be rank 4, but got shape ${p.shape}.`),$(e.length===4,()=>`Error in conv2dDerFilter: filterShape must be length 4, but got ${e}.`);let u=s===\"NHWC\"?i.shape[3]:i.shape[1],c=s===\"NHWC\"?p.shape[3]:p.shape[1];$(u===e[2],()=>`Error in conv2dDerFilter: depth of input ${u}) must match input depth in filter (${e[2]}.`),$(c===e[3],()=>`Error in conv2dDerFilter: depth of dy (${c}) must match output depth for filter (${e[3]}).`),Bt(\"conv2dDerFilter\",n,a);let l={x:i,dy:p},m={strides:o,pad:n,dataFormat:s,dimRoundingMode:a,filterShape:e};return T.runKernel(Oi,l,m)}var Q1=N({conv2DBackpropFilter_:H6});function ep(r,t,e){if(e==null||e===\"linear\")return r;if(e===\"relu\")return se(r,jd(t));throw new Error(`Cannot compute gradient for fused activation ${e}.`)}function tp(r,t){let e=t,o=yd(r.shape,t.shape);return o.length>0&&(e=ot(e,o)),W(e,r.shape)}function rp(r,t,e,o){if(t===\"linear\")return r;if(t===\"relu\")return du(r);if(t===\"elu\")return Cd(r);if(t===\"relu6\")return Gd(r);if(t===\"prelu\")return Md(r,e);if(t===\"leakyrelu\")return kd(r,o);if(t===\"sigmoid\")return $a(r);throw new Error(`Unknown fused activation ${t}.`)}var op=(r,t)=>!(r>0)||t===\"linear\";function K6({x:r,filter:t,strides:e,pad:o,dataFormat:n=\"NHWC\",dilations:s=[1,1],dimRoundingMode:a,bias:i,activation:p=\"linear\",preluActivationWeights:u,leakyreluAlpha:c}){if(p=p||\"linear\",op(T.state.gradientDepth,p)===!1){$(n===\"NHWC\",()=>`Error in fused conv2d: got dataFormat of ${n} but only NHWC is currently supported for the case of gradient depth is 0 and the activation is not linear.`);let _=uu(r,t,e,o,n,s,a);return i!=null&&(_=Ce(_,i)),rp(_,p,u,c)}let l=v(r,\"x\",\"conv2d\",\"float32\"),m=v(t,\"filter\",\"conv2d\",\"float32\"),d=l,f=!1;l.rank===3&&(f=!0,d=W(l,[1,l.shape[0],l.shape[1],l.shape[2]])),$(d.rank===4,()=>`Error in fused conv2d: input must be rank 4, but got rank ${d.rank}.`),$(m.rank===4,()=>`Error in fused conv2d: filter must be rank 4, but got rank ${m.rank}.`),Bt(\"fused conv2d\",o,a);let h=n===\"NHWC\"?d.shape[3]:d.shape[1];$(m.shape[2]===h,()=>`Error in conv2d: depth of input (${h}) must match input depth for filter ${m.shape[2]}.`),$(xr(e,s),()=>`Error in conv2D: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`);let g=Hu(d.shape,m.shape,e,s,o,a),x;i!=null&&(x=v(i,\"bias\",\"fused conv2d\"),[x]=Oe(x,l),n===\"NHWC\"?rt(g.outShape,x.shape):($(x.shape.length<=1,()=>`Error in fused conv2d: only supports scalar or 1-D Tensor bias for NCHW format but got the bias of rank-${x.shape.length}.`),$(x.shape.length===0||x.shape[0]===g.outChannels||x.shape[0]===1,()=>`Error in fused conv2d: bias shape (${x.shape}) is not compatible with the number of output channels (${g.outChannels})`)));let b;if(u!=null){let _=u.shape;if($(_.length<=1||_.length===3,()=>`Error in fused conv2d: only supports scalar, 1-D Tensor or 3-D Tensor PReLU activation weights but got a tensor of rank-${_.length}.`),_.length===1)$(_[0]===1||_[0]===g.outChannels,()=>`Error in fused conv2d: PReLU activation weights (${_}) is not compatible with the number of output channels (${g.outChannels}).`);else if(_.length===3)try{rt(_,g.outShape)}catch(E){let R=`Error in fused conv2d: PReLU activation weights (${_}) is not compatible with the output shape of the conv2d (${g.outShape}).`;throw Error(R)}b=v(u,\"prelu weights\",\"fused conv2d\")}let C=(_,E)=>{$(n===\"NHWC\",()=>`Error in gradient of fused conv2D: got dataFormat of ${n} but only NHWC is currently supported.`);let[R,D,P,O]=E,M=ep(_,P,p);$(Gu(s),()=>`Error in gradient of fused conv2D: dilation rates greater than 1 are not yet supported in gradients. Got dilations '${s}'`);let L=xd(D.shape,M,R,e,o),B=Q1(D,M,R.shape,e,o),z=[L,B];if(O!=null){let U=tp(O,M);z.push(U)}return z},S={x:d,filter:m,bias:x,preluActivationWeights:b},k={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a,activation:p,leakyreluAlpha:c};return i==null?vr((E,R,D)=>{let P=T.runKernel(vo,S,k);return D([R,E,P]),f&&(P=W(P,[P.shape[1],P.shape[2],P.shape[3]])),{value:P,gradFunc:C}})(d,m):vr((E,R,D,P)=>{let O=T.runKernel(vo,S,k);return P([R,E,O,D]),f&&(O=W(O,[O.shape[1],O.shape[2],O.shape[3]])),{value:O,gradFunc:C}})(d,m,x)}var Z1=N({fusedConv2d_:K6});function q6(r,t,e,o,n,s=[1,1],a){let i=r;r.rank===3&&(i=W(r,[1,r.shape[0],r.shape[1],r.shape[2]]));let p=t;p.rank===3&&(p=W(t,[1,t.shape[0],t.shape[1],t.shape[2]]));let u={x:i,dy:p},c={strides:o,pad:n,dimRoundingMode:a,dilations:s,filterShape:e};return T.runKernel(Mi,u,c)}var J1=N({depthwiseConv2dNativeBackpropFilter_:q6});function j6(r,t,e,o,n,s=[1,1],a){let i=t,p=!1;t.rank===3&&(p=!0,i=W(t,[1,t.shape[0],t.shape[1],t.shape[2]]));let u={dy:i,filter:e},c={strides:o,pad:n,dimRoundingMode:a,dilations:s,inputShape:r},l=T.runKernel(Li,u,c);return p?W(l,[l.shape[1],l.shape[2],l.shape[3]]):l}var eN=N({depthwiseConv2dNativeBackpropInput_:j6});function X6({x:r,filter:t,strides:e,pad:o,dataFormat:n=\"NHWC\",dilations:s=[1,1],dimRoundingMode:a,bias:i,activation:p=\"linear\",preluActivationWeights:u,leakyreluAlpha:c}){if(op(T.state.gradientDepth,p)===!1){let k=lc(r,t,e,o,n,s,a);return i!=null&&(k=Ce(k,i)),rp(k,p,u,c)}let l=v(r,\"x\",\"depthwiseConv2d\",\"float32\"),m=v(t,\"filter\",\"depthwiseConv2d\",\"float32\"),d=l,f=!1;l.rank===3&&(f=!0,d=W(l,[1,l.shape[0],l.shape[1],l.shape[2]])),$(d.rank===4,()=>`Error in fused depthwiseConv2d: input must be rank 4, but got rank ${d.rank}.`),$(m.rank===4,()=>`Error in fused depthwiseConv2d: filter must be rank 4, but got rank ${m.rank}.`),$(d.shape[3]===m.shape[2],()=>`Error in fused depthwiseConv2d: number of input channels (${d.shape[3]}) must match the inChannels dimension in filter ${m.shape[2]}.`),s==null&&(s=[1,1]),$(xr(e,s),()=>`Error in fused depthwiseConv2d: Either strides or dilations must be 1. Got strides ${e} and dilations '${s}'`),Bt(\"fused depthwiseConv2d\",o,a);let h=Hu(d.shape,m.shape,e,s,o,a,!0),g;i!=null&&(g=v(i,\"bias\",\"fused conv2d\"),[g]=Oe(g,l),rt(h.outShape,g.shape));let x;u!=null&&(x=v(u,\"prelu weights\",\"fused depthwiseConv2d\"));let b=(k,_)=>{$(Gu(s),()=>`Error in gradient of fused depthwiseConv2d: dilation rates greater than 1 are not yet supported. Got dilations '${s}'`);let[E,R,D,P]=_,O=ep(k,D,p),M=eN(R.shape,O,E,e,o,s,a),L=J1(R,O,E.shape,e,o,s,a);if(P!=null){let B=tp(g,O);return[M,L,B]}return[M,L]},C={x:d,filter:m,bias:g,preluActivationWeights:x},S={strides:e,pad:o,dataFormat:n,dilations:s,dimRoundingMode:a,activation:p,leakyreluAlpha:c};return i==null?vr((_,E,R)=>{let D=T.runKernel(ko,C,S);return R([E,_,D]),f&&(D=W(D,[D.shape[1],D.shape[2],D.shape[3]])),{value:D,gradFunc:b}})(d,m):vr((_,E,R,D)=>{let P=T.runKernel(ko,C,S);return D([E,_,P,R]),f&&(P=W(P,[P.shape[1],P.shape[2],P.shape[3]])),{value:P,gradFunc:b}})(d,m,g)}var tN=N({fusedDepthwiseConv2d_:X6});function Y6({a:r,b:t,transposeA:e=!1,transposeB:o=!1,bias:n,activation:s=\"linear\",preluActivationWeights:a,leakyreluAlpha:i=.2}){if(op(T.state.gradientDepth,s)===!1){let O=Ze(r,t,e,o);return n!=null&&(O=Ce(O,n)),rp(O,s,a,i)}let p=v(r,\"a\",\"fused matMul\"),u=v(t,\"b\",\"fused matMul\");[p,u]=Oe(p,u);let c=e?p.shape[p.rank-2]:p.shape[p.rank-1],l=o?u.shape[u.rank-1]:u.shape[u.rank-2],m=e?p.shape[p.rank-1]:p.shape[p.rank-2],d=o?u.shape[u.rank-2]:u.shape[u.rank-1],f=p.shape.slice(0,-2),h=u.shape.slice(0,-2),g=He(f),x=He(h);$(c===l,()=>`Error in fused matMul: inner shapes (${c}) and (${l}) of Tensors with shapes ${p.shape} and ${u.shape} and transposeA=${e} and transposeB=${o} must match.`);let C=rt(p.shape.slice(0,-2),u.shape.slice(0,-2)).concat([m,d]),S=e?W(p,[g,c,m]):W(p,[g,m,c]),k=o?W(u,[x,d,l]):W(u,[x,l,d]),_;n!=null&&(_=v(n,\"bias\",\"fused matMul\"),[_]=Oe(_,p),rt(C,_.shape));let E;a!=null&&(E=v(a,\"prelu weights\",\"fused matMul\"));let R=(O,M)=>{let[L,B,z,U]=M,j=ep(W(O,z.shape),z,s),q,Y;if(!e&&!o?(q=Ze(j,B,!1,!0),Y=Ze(L,j,!0,!1)):!e&&o?(q=Ze(j,B,!1,!1),Y=Ze(j,L,!0,!1)):e&&!o?(q=Ze(B,j,!1,!0),Y=Ze(L,j,!1,!1)):(q=Ze(B,j,!0,!0),Y=Ze(j,L,!0,!0)),n!=null){let J=tp(U,j);return[q,Y,J]}else return[q,Y]},D={a:S,b:k,bias:_,preluActivationWeights:E},P={transposeA:e,transposeB:o,activation:s,leakyreluAlpha:i};return n==null?vr((M,L,B)=>{let z=T.runKernel(Io,D,P);return B([M,L,z]),{value:W(z,C),gradFunc:R}})(S,k):vr((M,L,B,z)=>{let U=T.runKernel(Io,D,P);return z([M,L,U,B]),{value:W(U,C),gradFunc:R}})(S,k,_)}var rN=N({fusedMatMul_:Y6});function Q6(r){return Rl(r,.54,.46)}var oN=N({hammingWindow_:Q6});function Z6(r){return Rl(r,.5,.5)}var Zd=N({hannWindow_:Z6});function J6(r,t,e,o=!1,n=0){let s=0,a=[];for(;s+t<=r.size;)a.push(Xe(r,s,t)),s+=e;if(o)for(;s`Error in cropAndResize: image must be rank 4,but got rank ${a.rank}.`),$(i.rank===2&&i.shape[1]===4,()=>`Error in cropAndResize: boxes must be have size [${u},4] but had shape ${i.shape}.`),$(p.rank===1&&p.shape[0]===u,()=>`Error in cropAndResize: boxInd must be have size [${u}] but had shape ${i.shape}.`),$(o.length===2,()=>`Error in cropAndResize: cropSize must be of length 2, but got length ${o.length}.`),$(o[0]>=1&&o[1]>=1,()=>`cropSize must be atleast [1,1], but was ${o}`),$(n===\"bilinear\"||n===\"nearest\",()=>`method must be bilinear or nearest, but was ${n}`);let c={image:a,boxes:i,boxInd:p},l={method:n,extrapolationValue:s,cropSize:o};return T.runKernel(ln,c,l)}var sN=N({cropAndResize_:tj});function rj(r){let t=v(r,\"image\",\"flipLeftRight\",\"float32\");$(t.rank===4,()=>`Error in flipLeftRight: image must be rank 4,but got rank ${t.rank}.`);let e={image:t};return T.runKernel(wn,e,{})}var aN=N({flipLeftRight_:rj});function oj(r){let t=v(r,\"image\",\"grayscaleToRGB\"),e=t.rank-1,o=t.shape[e];$(t.rank>=2,()=>`Error in grayscaleToRGB: images must be at least rank 2, but got rank ${t.rank}.`),$(o===1,()=>`Error in grayscaleToRGB: last dimension of a grayscale image should be size 1, but got size ${o}.`);let n=new Array(t.rank);return n.fill(1,0,e),n[e]=3,cu(t,n)}var iN=N({grayscaleToRGB_:oj});function nj(r){let t=v(r,\"image\",\"RGBToGrayscale\"),e=t.rank-1,o=t.shape[e];$(t.rank>=2,()=>`Error in RGBToGrayscale: images must be at least rank 2, but got rank ${t.rank}.`),$(o===3,()=>`Error in RGBToGrayscale: last dimension of an RGB image should be size 3, but got size ${o}.`);let n=t.dtype,s=We(t,\"float32\"),a=tr([.2989,.587,.114]),i;switch(t.rank){case 2:i=pu(\"ij,j->i\",s,a);break;case 3:i=pu(\"ijk,k->ij\",s,a);break;case 4:i=pu(\"ijkl,l->ijk\",s,a);break;case 5:i=pu(\"ijklm,m->ijkl\",s,a);break;case 6:i=pu(\"ijklmn,n->ijklm\",s,a);break;default:throw new Error(\"Not a valid tensor rank.\")}return i=Ms(i,-1),We(i,n)}var uN=N({rgbToGrayscale_:nj});function sj(r,t,e=0,o=.5){let n=v(r,\"image\",\"rotateWithOffset\",\"float32\");$(n.rank===4,()=>`Error in rotateWithOffset: image must be rank 4,but got rank ${n.rank}.`);let s={image:n},a={radians:t,fillValue:e,center:o};return T.runKernel(As,s,a)}var pN=N({rotateWithOffset_:sj});function Eo(r,t,e,o,n,s){o==null&&(o=.5),n==null&&(n=Number.NEGATIVE_INFINITY),s==null&&(s=0);let a=r.shape[0];return e=Math.min(e,a),$(0<=o&&o<=1,()=>`iouThreshold must be in [0, 1], but was '${o}'`),$(r.rank===2,()=>`boxes must be a 2D tensor, but was of rank '${r.rank}'`),$(r.shape[1]===4,()=>`boxes must have 4 columns, but 2nd dimension was ${r.shape[1]}`),$(t.rank===1,()=>\"scores must be a 1D tensor\"),$(t.shape[0]===a,()=>`scores has incompatible shape with boxes. Expected ${a}, but was ${t.shape[0]}`),$(0<=s&&s<=1,()=>`softNmsSigma must be in [0, 1], but was '${s}'`),{maxOutputSize:e,iouThreshold:o,scoreThreshold:n,softNmsSigma:s}}function aj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY){let s=v(r,\"boxes\",\"nonMaxSuppression\",\"float32\"),a=v(t,\"scores\",\"nonMaxSuppression\",\"float32\"),i=Eo(s,a,e,o,n);e=i.maxOutputSize,o=i.iouThreshold,n=i.scoreThreshold;let p={maxOutputSize:e,iouThreshold:o,scoreThreshold:n};return T.runKernel(Zn,{boxes:s,scores:a},p)}var cN=N({nonMaxSuppression_:aj});function lN(r,t,e){let o=ij(r,t,e),n=o<0?-(o+1):o;r.splice(n,0,t)}function ij(r,t,e){return pj(r,t,e||uj)}function uj(r,t){return r>t?1:r>>1);let i=e(t,r[s]);i>0?o=s+1:(n=s,a=!i)}return a?o:-o-1}function ef(r,t,e,o,n){return Jw(r,t,e,o,n,0)}function tf(r,t,e,o,n,s){return Jw(r,t,e,o,n,0,!1,s,!0)}function rf(r,t,e,o,n,s){return Jw(r,t,e,o,n,s,!0)}function Jw(r,t,e,o,n,s,a=!1,i=!1,p=!1){let u=[];for(let g=0;gn&&u.push({score:t[g],boxIndex:g,suppressBeginIndex:0});u.sort(mN);let c=s>0?-.5/s:0,l=[],m=[];for(;l.length0;){let g=u.pop(),{score:x,boxIndex:b,suppressBeginIndex:C}=g;if(x=C;--k){let _=cj(r,b,l[k]);if(_>=o){S=!0;break}if(g.score=g.score*lj(o,c,_),g.score<=n)break}g.suppressBeginIndex=l.length,S||(g.score===x?(l.push(b),m.push(g.score)):g.score>n&&lN(u,g,mN))}let d=l.length,f=e-d;i&&f>0&&(l.push(...new Array(f).fill(0)),m.push(...new Array(f).fill(0)));let h={selectedIndices:l};return a&&(h.selectedScores=m),p&&(h.validOutputs=d),h}function cj(r,t,e){let o=r.subarray(t*4,t*4+4),n=r.subarray(e*4,e*4+4),s=Math.min(o[0],o[2]),a=Math.min(o[1],o[3]),i=Math.max(o[0],o[2]),p=Math.max(o[1],o[3]),u=Math.min(n[0],n[2]),c=Math.min(n[1],n[3]),l=Math.max(n[0],n[2]),m=Math.max(n[1],n[3]),d=(i-s)*(p-a),f=(l-u)*(m-c);if(d<=0||f<=0)return 0;let h=Math.max(s,u),g=Math.max(a,c),x=Math.min(i,l),b=Math.min(p,m),C=Math.max(x-h,0)*Math.max(b-g,0);return C/(d+f-C)}function lj(r,t,e){let o=Math.exp(t*e*e);return e<=r?o:0}function mN(r,t){return r.score-t.score||r.score===t.score&&t.boxIndex-r.boxIndex}async function mj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY){let s=v(r,\"boxes\",\"nonMaxSuppressionAsync\"),a=v(t,\"scores\",\"nonMaxSuppressionAsync\"),i=Eo(s,a,e,o,n);e=i.maxOutputSize,o=i.iouThreshold,n=i.scoreThreshold;let p=await Promise.all([s.data(),a.data()]),u=p[0],c=p[1],{selectedIndices:l}=ef(u,c,e,o,n);return s!==r&&s.dispose(),a!==t&&a.dispose(),tr(l,\"int32\")}var dN=mj;function dj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=0){let a=v(r,\"boxes\",\"nonMaxSuppression\"),i=v(t,\"scores\",\"nonMaxSuppression\"),p=Eo(a,i,e,o,n,s);e=p.maxOutputSize,o=p.iouThreshold,n=p.scoreThreshold,s=p.softNmsSigma;let u={boxes:a,scores:i},c={maxOutputSize:e,iouThreshold:o,scoreThreshold:n,softNmsSigma:s},l=T.runKernel(Jn,u,c);return{selectedIndices:l[0],selectedScores:l[1]}}var fN=N({nonMaxSuppressionWithScore_:dj});async function fj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=0){let a=v(r,\"boxes\",\"nonMaxSuppressionAsync\"),i=v(t,\"scores\",\"nonMaxSuppressionAsync\"),p=Eo(a,i,e,o,n,s);e=p.maxOutputSize,o=p.iouThreshold,n=p.scoreThreshold,s=p.softNmsSigma;let u=await Promise.all([a.data(),i.data()]),c=u[0],l=u[1],{selectedIndices:m,selectedScores:d}=rf(c,l,e,o,n,s);return a!==r&&a.dispose(),i!==t&&i.dispose(),{selectedIndices:tr(m,\"int32\"),selectedScores:tr(d)}}var hN=fj;function hj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=!1){let a=v(r,\"boxes\",\"nonMaxSuppression\"),i=v(t,\"scores\",\"nonMaxSuppression\"),p=Eo(a,i,e,o,n,null),u=p.maxOutputSize,c=p.iouThreshold,l=p.scoreThreshold,m={boxes:a,scores:i},d={maxOutputSize:u,iouThreshold:c,scoreThreshold:l,padToMaxOutputSize:s},f=T.runKernel(Za,m,d);return{selectedIndices:f[0],validOutputs:f[1]}}var gN=N({nonMaxSuppressionPadded_:hj});async function gj(r,t,e,o=.5,n=Number.NEGATIVE_INFINITY,s=!1){let a=v(r,\"boxes\",\"nonMaxSuppressionAsync\"),i=v(t,\"scores\",\"nonMaxSuppressionAsync\"),p=Eo(a,i,e,o,n,null),u=p.maxOutputSize,c=p.iouThreshold,l=p.scoreThreshold,[m,d]=await Promise.all([a.data(),i.data()]),{selectedIndices:f,validOutputs:h}=tf(m,d,u,c,l,s);return a!==r&&a.dispose(),i!==t&&i.dispose(),{selectedIndices:tr(f,\"int32\"),validOutputs:ke(h,\"int32\")}}var xN=gj;function xj(r,t,e=!1,o=!1){let n=v(r,\"images\",\"resizeBilinear\");$(n.rank===3||n.rank===4,()=>`Error in resizeBilinear: x must be rank 3 or 4, but got rank ${n.rank}.`),$(t.length===2,()=>`Error in resizeBilinear: new shape must 2D, but got shape ${t}.`),$(o===!1||e===!1,()=>\"Error in resizeBilinear: If halfPixelCenters is true, alignCorners must be false.\");let s=n,a=!1;n.rank===3&&(a=!0,s=W(n,[1,n.shape[0],n.shape[1],n.shape[2]]));let[]=t,i={images:s},p={alignCorners:e,halfPixelCenters:o,size:t},u=T.runKernel(us,i,p);return a?W(u,[u.shape[1],u.shape[2],u.shape[3]]):u}var yN=N({resizeBilinear_:xj});function yj(r,t,e=!1,o=!1){let n=v(r,\"images\",\"resizeNearestNeighbor\");$(n.rank===3||n.rank===4,()=>`Error in resizeNearestNeighbor: x must be rank 3 or 4, but got rank ${n.rank}.`),$(t.length===2,()=>`Error in resizeNearestNeighbor: new shape must 2D, but got shape ${t}.`),$(n.dtype===\"float32\"||n.dtype===\"int32\",()=>\"`images` must have `int32` or `float32` as dtype\"),$(o===!1||e===!1,()=>\"Error in resizeNearestNeighbor: If halfPixelCenters is true, alignCorners must be false.\");let s=n,a=!1;n.rank===3&&(a=!0,s=W(n,[1,n.shape[0],n.shape[1],n.shape[2]]));let[]=t,i={images:s},p={alignCorners:e,halfPixelCenters:o,size:t},u=T.runKernel(is,i,p);return a?W(u,[u.shape[1],u.shape[2],u.shape[3]]):u}var bN=N({resizeNearestNeighbor_:yj});function bj(r,t=\"binary\",e=!1,o=.5){let n=v(r,\"image\",\"threshold\"),s=.2989,a=.587,i=.114,p=n.shape[0]*n.shape[1],u=se(tr([o]),255),c,l,m,d;if($(n.rank===3,()=>`Error in threshold: image must be rank 3,but got rank ${n.rank}.`),$(n.shape[2]===3||n.shape[2]===1,()=>`Error in threshold: image color channel must be equal to 3 or 1but got ${n.shape[2]}.`),$(n.dtype===\"int32\"||n.dtype===\"float32\",()=>`Error in dtype: image dtype must be int32 or float32,but got dtype ${n.dtype}.`),$(t===\"otsu\"||t===\"binary\",()=>`Method must be binary or otsu, but was ${t}`),n.shape[2]===3){[c,l,m]=li(n,[1,1,1],-1);let g=se(c,s),x=se(l,a),b=se(m,i);d=Ce(Ce(g,x),b)}else d=r;if(t===\"otsu\"){let g=gd(We(Hd(d),\"int32\"),ur([]),256);u=Cj(g,p)}let f=e?mc(d,u):qu(d,u);return We(se(f,255),\"int32\")}function Cj(r,t){let e=tr([-1]),o=tr([0]),n=tr([0]),s,a,i,p,u,c;for(let l=0;l`Error in transform: image must be rank 4,but got rank ${a.rank}.`),$(i.rank===2&&(i.shape[0]===a.shape[0]||i.shape[0]===1)&&i.shape[1]===8,()=>\"Error in transform: Input transform should be batch x 8 or 1 x 8\"),$(s==null||s.length===2,()=>`Error in transform: outputShape must be [height, width] or null, but got ${s}.`);let p={image:a,transforms:i},u={interpolation:e,fillMode:o,fillValue:n,outputShape:s};return T.runKernel(Ds,p,u)}var wN=N({transform_:wj});function Sj(r,t,e){let o=v(r,\"a\",\"bandPart\");$(o.rank>=2,()=>`bandPart(): Rank must be at least 2, got ${o.rank}.`);let n=o.shape,[s,a]=o.shape.slice(-2),i,p;typeof t==\"number\"?($(t%1===0,()=>`bandPart(): numLower must be an integer, got ${t}.`),$(t<=s,()=>`bandPart(): numLower (${t}) must not be greater than the number of rows (${s}).`),i=v(t<0?s:t,\"numLower\",\"bandPart\")):($(t.dtype===\"int32\",()=>\"bandPart(): numLower's dtype must be an int32.\"),i=lo(_l(t,0),s,Yu(t,s))),typeof e==\"number\"?($(e%1===0,()=>`bandPart(): numUpper must be an integer, got ${e}.`),$(e<=a,()=>`bandPart(): numUpper (${e}) must not be greater than the number of columns (${a}).`),p=v(e<0?a:e,\"numUpper\",\"bandPart\")):($(e.dtype===\"int32\",()=>\"bandPart(): numUpper's dtype must be an int32.\"),p=lo(_l(e,0),a,Yu(e,a)));let u=W(mu(0,s,1,\"int32\"),[-1,1]),c=mu(0,a,1,\"int32\"),l=Te(u,c),m=ju(mc(l,i),vd(l,cr(p))),d=Gr([s,a],o.dtype);return W(kr(fo(W(o,[-1,s,a])).map(f=>lo(m,f,d))),n)}var SN=N({bandPart_:Sj});function Ij(r){let t;if(Array.isArray(r)){t=!1,$(r!=null&&r.length>0,()=>\"Gram-Schmidt process: input must not be null, undefined, or empty\");let n=r[0].shape[0];for(let s=1;s`Gram-Schmidt: Non-unique lengths found in the input vectors: (${r[s].shape[0]} vs. ${n})`)}else t=!0,r=li(r,r.shape[0],0).map(n=>gc(n,[0]));$(r.length<=r[0].shape[0],()=>`Gram-Schmidt: Number of vectors (${r.length}) exceeds number of dimensions (${r[0].shape[0]}).`);let e=[],o=r;for(let n=0;n{let s=o[n];if(n>0)for(let a=0;a=2,()=>`qr() requires input tensor to have a rank >= 2, but got rank ${r.rank}`),r.rank===2)return vN(r,t);{let e=r.shape.slice(0,r.shape.length-2).reduce((p,u)=>p*u),o=fo(W(r,[e,r.shape[r.shape.length-2],r.shape[r.shape.length-1]]),0),n=[],s=[];o.forEach(p=>{let[u,c]=vN(p,t);n.push(u),s.push(c)});let a=W(kr(n,0),r.shape),i=W(kr(s,0),r.shape);return[a,i]}}function vN(r,t=!1){return T.tidy(()=>{$(r.shape.length===2,()=>`qr2d() requires a 2D Tensor, but got a ${r.shape.length}D Tensor.`);let e=r.shape[0],o=r.shape[1],n=wd(e),s=Ur(r),a=fu([[1]],[1,1]),i=Ur(a),p=e>=o?o:e;for(let u=0;u{let d=Xe(s,[u,u],[e-u,1]),f=Ku(d),h=Xe(s,[u,u],[1,1]),g=lo(qu(h,0),fu([[-1]]),fu([[1]])),x=Te(h,se(g,f)),b=je(d,x);b.shape[0]===1?i=Ur(a):i=bt([a,Xe(b,[1,0],[b.shape[0]-1,b.shape[1]])],0);let C=cr(je(Ze(g,x),f)),S=Xe(s,[u,0],[e-u,o]),k=se(C,i),_=yc(i);if(u===0)s=Te(S,Ze(k,Ze(_,S)));else{let D=Te(S,Ze(k,Ze(_,S)));s=bt([Xe(s,[0,0],[u,o]),D],0)}let E=yc(k),R=Xe(n,[0,u],[e,n.shape[1]-u]);if(u===0)n=Te(R,Ze(Ze(R,i),E));else{let D=Te(R,Ze(Ze(R,i),E));n=bt([Xe(n,[0,0],[e,u]),D],1)}return[i,s,n]}),Mt([c,l,m])}return!t&&e>o&&(n=Xe(n,[0,0],[e,o]),s=Xe(s,[0,0],[o,o])),[n,s]})}var kN=N({qr_:vj});var Rt;(function(r){r[r.NONE=0]=\"NONE\",r[r.MEAN=1]=\"MEAN\",r[r.SUM=2]=\"SUM\",r[r.SUM_BY_NONZERO_WEIGHTS=3]=\"SUM_BY_NONZERO_WEIGHTS\"})(Rt||(Rt={}));function kj(r,t,e=Rt.SUM_BY_NONZERO_WEIGHTS){let o=v(r,\"losses\",\"computeWeightedLoss\"),n=null;t!=null&&(n=v(t,\"weights\",\"computeWeightedLoss\"));let s=n==null?o:se(o,n);if(e===Rt.NONE)return s;if(e===Rt.SUM)return ot(s);if(e===Rt.MEAN){if(n==null)return Xu(s);{let a=o.size/n.size,i=je(ot(s),ot(n));return a>1?je(i,ke(a)):i}}if(e===Rt.SUM_BY_NONZERO_WEIGHTS){if(n==null)return je(ot(s),ke(o.size));{let a=se(n,Da(o.shape)),i=We(ot(Pd(a,ke(0))),\"float32\");return je(ot(s),i)}}throw Error(`Unknown reduction: ${e}`)}var lr=N({computeWeightedLoss_:kj});function Nj(r,t,e,o=Rt.SUM_BY_NONZERO_WEIGHTS){let n=v(r,\"labels\",\"absoluteDifference\"),s=v(t,\"predictions\",\"absoluteDifference\"),a=null;e!=null&&(a=v(e,\"weights\",\"absoluteDifference\")),yt(n.shape,s.shape,\"Error in absoluteDifference: \");let i=Jt(Te(n,s));return lr(i,a,o)}var NN=N({absoluteDifference_:Nj});function Tj(r,t,e,o,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"labels\",\"cosineDistance\"),a=v(t,\"predictions\",\"cosineDistance\"),i=null;o!=null&&(i=v(o,\"weights\",\"cosineDistance\")),yt(s.shape,a.shape,\"Error in cosineDistance: \");let p=ke(1),u=Te(p,ot(se(s,a),e,!0));return lr(u,i,n)}var TN=N({cosineDistance_:Tj});function _j(r,t,e,o=Rt.SUM_BY_NONZERO_WEIGHTS){let n=v(r,\"labels\",\"hingeLoss\"),s=v(t,\"predictions\",\"hingeLoss\"),a=null;e!=null&&(a=v(e,\"weights\",\"hingeLoss\")),yt(n.shape,s.shape,\"Error in hingeLoss: \");let i=ke(1);n=Te(se(ke(2),n),i);let p=du(Te(i,se(n,s)));return lr(p,a,o)}var _N=N({hingeLoss_:_j});function $j(r,t,e,o=1,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"labels\",\"huberLoss\"),a=v(t,\"predictions\",\"huberLoss\"),i=null;e!=null&&(i=v(e,\"weights\",\"huberLoss\")),yt(s.shape,a.shape,\"Error in huberLoss: \");let p=ke(o),u=Jt(Te(a,s)),c=Yu(u,p),l=Te(u,c),m=Ce(se(ke(.5),er(c)),se(p,l));return lr(m,i,n)}var $N=N({huberLoss_:$j});function Ej(r,t,e,o=1e-7,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"labels\",\"logLoss\"),a=v(t,\"predictions\",\"logLoss\"),i=null;e!=null&&(i=v(e,\"weights\",\"logLoss\")),yt(s.shape,a.shape,\"Error in logLoss: \");let p=ke(1),u=ke(o),c=cr(se(s,pi(Ce(a,u)))),l=se(Te(p,s),pi(Ce(Te(p,a),u))),m=Te(c,l);return lr(m,i,n)}var EN=N({logLoss_:Ej});function Rj(r,t,e,o=Rt.SUM_BY_NONZERO_WEIGHTS){let n=v(r,\"labels\",\"meanSquaredError\"),s=v(t,\"predictions\",\"meanSquaredError\"),a=null;e!=null&&(a=v(e,\"weights\",\"meanSquaredError\")),yt(n.shape,s.shape,\"Error in meanSquaredError: \");let i=qd(n,s);return lr(i,a,o)}var RN=N({meanSquaredError_:Rj});function Dj(r,t){let e=v(r,\"labels\",\"sigmoidCrossEntropyWithLogits\"),o=v(t,\"logits\",\"sigmoidCrossEntropyWithLogits\");yt(e.shape,o.shape,\"Error in sigmoidCrossEntropyWithLogits: \");let n=du(o),s=se(o,e),a=Nd($o(cr(Jt(o))));return Ce(Te(n,s),a)}function Aj(r,t,e,o=0,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"multiClassLabels\",\"sigmoidCrossEntropy\"),a=v(t,\"logits\",\"sigmoidCrossEntropy\"),i=null;if(e!=null&&(i=v(e,\"weights\",\"sigmoidCrossEntropy\")),yt(s.shape,a.shape,\"Error in sigmoidCrossEntropy: \"),o>0){let u=ke(o),c=ke(1),l=ke(.5);s=Ce(se(s,Te(c,u)),se(l,u))}let p=Dj(s,a);return lr(p,i,n)}var DN=N({sigmoidCrossEntropy_:Aj});function Fj(r,t,e=-1){if(e===-1&&(e=t.rank-1),e!==t.rank-1)throw Error(`Softmax cross entropy along a non-last dimension is not yet supported. Labels / logits was rank ${t.rank} and dim was ${e}`);return vr((n,s,a)=>{let p=$d(s,[e],!0),u=Te(We(s,\"float32\"),p);a([n,u]);let c=cr(se(u,n));return{value:ot(c,[e]),gradFunc:(d,f)=>{let[h,g]=f,x=ii(d.shape,[e]);return[se(W(d,x),Te(We(h,\"float32\"),$o(g))),se(W(d,x),Te($o(g),We(h,\"float32\")))]}}})(r,t)}function Pj(r,t,e,o=0,n=Rt.SUM_BY_NONZERO_WEIGHTS){let s=v(r,\"onehotLabels\",\"softmaxCrossEntropy\"),a=v(t,\"logits\",\"softmaxCrossEntropy\"),i=null;if(e!=null&&(i=v(e,\"weights\",\"softmaxCrossEntropy\")),yt(s.shape,a.shape,\"Error in softmaxCrossEntropy: \"),o>0){let u=ke(o),c=ke(1),l=ke(s.shape[1]);s=Ce(se(s,Te(c,u)),je(u,l))}let p=Fj(s,a);return lr(p,i,n)}var AN=N({softmaxCrossEntropy_:Pj});function Oj(r,t,e,o){let n=v(r,\"indices\",\"sparseFillEmptyRows\",\"int32\"),s=v(t,\"values\",\"sparseFillEmptyRows\"),a=v(e,\"denseShape\",\"sparseFillEmptyRows\",\"int32\"),i=v(o,\"defaultValue\",\"sparseFillEmptyRows\",s.dtype);if(n.rank!==2)throw new Error(`Indices should be Tensor2D but received shape\n ${n.shape}`);if(s.rank!==1)throw new Error(`Values should be Tensor1D but received shape ${s.shape}`);if(a.rank!==1)throw new Error(`Dense shape should be Tensor1D but received shape ${a.shape}`);if(i.rank!==0)throw new Error(`Default value should be a scalar but received shape ${i.shape}`);let p={indices:n,values:s,denseShape:a,defaultValue:i},u=T.runKernel(ji,p);return{outputIndices:u[0],outputValues:u[1],emptyRowIndicator:u[2],reverseIndexMap:u[3]}}var FN=N({sparseFillEmptyRows_:Oj});function Mj(r,t,e){let o=v(r,\"inputIndices\",\"sparseReshape\",\"int32\"),n=v(t,\"inputShape\",\"sparseReshape\",\"int32\"),s=v(e,\"newShape\",\"sparseReshape\",\"int32\");if(o.rank!==2)throw new Error(`Input indices should be Tensor2D but received shape\n ${o.shape}`);if(n.rank!==1)throw new Error(`Input shape should be Tensor1D but received shape ${n.shape}`);if(s.rank!==1)throw new Error(`New shape should be Tensor1D but received shape ${s.shape}`);let a={inputIndices:o,inputShape:n,newShape:s},i=T.runKernel(ti,a);return{outputIndices:i[0],outputShape:i[1]}}var PN=N({sparseReshape_:Mj});function Lj(r,t,e){let o=v(r,\"data\",\"sparseSegmentMean\"),n=v(t,\"indices\",\"sparseSegmentMean\",\"int32\"),s=v(e,\"segmentIds\",\"sparseSegmentMean\",\"int32\");if(o.rank<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.rank!==1)throw new Error(`Indices should be Tensor1D but received shape\n ${n.shape}`);if(s.rank!==1)throw new Error(`Segment ids should be Tensor1D but received shape\n ${s.shape}`);let a={data:o,indices:n,segmentIds:s};return T.runKernel(ya,a)}var ON=N({sparseSegmentMean_:Lj});function Bj(r,t,e){let o=v(r,\"data\",\"sparseSegmentSum\"),n=v(t,\"indices\",\"sparseSegmentSum\",\"int32\"),s=v(e,\"segmentIds\",\"sparseSegmentSum\",\"int32\");if(o.rank<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.rank!==1)throw new Error(`Indices should be Tensor1D but received shape\n ${n.shape}`);if(s.rank!==1)throw new Error(`Segment ids should be Tensor1D but received shape\n ${s.shape}`);let a={data:o,indices:n,segmentIds:s};return T.runKernel(ba,a)}var MN=N({sparseSegmentSum_:Bj});function zj(r,t,e,o,n,s,a,i){let p=v(r,\"data\",\"stringNGrams\",\"string\");if(p.dtype!==\"string\")throw new Error(\"Data must be of datatype string\");if(p.shape.length!==1)throw new Error(`Data must be a vector, saw: ${p.shape}`);let u=v(t,\"dataSplits\",\"stringNGrams\");if(u.dtype!==\"int32\")throw new Error(\"Data splits must be of datatype int32\");let c={separator:e,nGramWidths:o,leftPad:n,rightPad:s,padWidth:a,preserveShortSequences:i},l={data:p,dataSplits:u},m=T.runKernel(Ca,l,c);return{nGrams:m[0],nGramsSplits:m[1]}}var LN=N({stringNGrams_:zj});function Vj(r,t,e=!0){let o=v(r,\"input\",\"stringSplit\",\"string\"),n=v(t,\"delimiter\",\"stringSplit\",\"string\");if(o.rank!==1)throw new Error(`Input should be Tensor1D but received shape ${o.shape}`);if(n.rank!==0)throw new Error(`Delimiter should be a scalar but received shape ${n.shape}`);let s={skipEmpty:e},a={input:o,delimiter:n},i=T.runKernel(Yi,a,s);return{indices:i[0],values:i[1],shape:i[2]}}var BN=N({stringSplit_:Vj});function Wj(r,t){let e=v(r,\"input\",\"stringToHashBucketFast\",\"string\"),o={numBuckets:t};if(t<=0)throw new Error(\"Number of buckets must be at least 1\");let n={input:e};return T.runKernel(Qi,n,o)}var zN=N({stringToHashBucketFast_:Wj});function Uj(r,t,e,o=!0){let n=v(r,\"input\",\"staticRegexReplace\",\"string\"),s={pattern:t,rewrite:e,replaceGlobal:o};return T.runKernel(Ou,{x:n},s)}var VN=N({staticRegexReplace_:Uj});var Gj={fft:fc,ifft:Ju,rfft:hc,irfft:Kd},Hj={hammingWindow:oN,hannWindow:Zd,frame:Jd,stft:nN},Kj={flipLeftRight:aN,grayscaleToRGB:iN,resizeNearestNeighbor:bN,resizeBilinear:yN,rgbToGrayscale:uN,rotateWithOffset:pN,cropAndResize:sN,nonMaxSuppression:cN,nonMaxSuppressionAsync:dN,nonMaxSuppressionWithScore:fN,nonMaxSuppressionWithScoreAsync:hN,nonMaxSuppressionPadded:gN,nonMaxSuppressionPaddedAsync:xN,threshold:CN,transform:wN},qj={bandPart:SN,gramSchmidt:IN,qr:kN},jj={absoluteDifference:NN,computeWeightedLoss:lr,cosineDistance:TN,hingeLoss:_N,huberLoss:$N,logLoss:EN,meanSquaredError:RN,sigmoidCrossEntropy:DN,softmaxCrossEntropy:AN},Xj={sparseFillEmptyRows:FN,sparseReshape:PN,sparseSegmentMean:ON,sparseSegmentSum:MN},Yj={stringNGrams:LN,stringSplit:BN,stringToHashBucketFast:zN,staticRegexReplace:VN};var WN={};qe(WN,{Serializable:()=>Dl,SerializationMap:()=>Fa,getRegisteredName:()=>Zj,registerClass:()=>tS});var Qj=new Map,eS=new Map,Dl=class{getClassName(){return this.constructor.className}static fromConfig(t,e){return new t(e)}},Fa=class{constructor(){this.classNameMap={}}static getMap(){return Fa.instance==null&&(Fa.instance=new Fa),Fa.instance}static register(t){Fa.getMap().classNameMap[t.className]=[t,t.fromConfig]}};function tS(r,t,e){$(r.className!=null,()=>\"Class being registered does not have the static className property defined.\"),$(typeof r.className==\"string\",()=>\"className is required to be a string, but got type \"+typeof r.className),$(r.className.length>0,()=>\"Class being registered has an empty-string as its className, which is disallowed.\"),typeof t==\"undefined\"&&(t=\"Custom\"),typeof e==\"undefined\"&&(e=r.className);let o=e,n=t+\">\"+o;return Fa.register(r),Qj.set(n,r),eS.set(r,n),r}function Zj(r){return eS.has(r)?eS.get(r):r.className}var Nr=class extends Dl{minimize(t,e=!1,o){let{value:n,grads:s}=this.computeGradients(t,o);if(o!=null){let a=o.map(i=>({name:i.name,tensor:s[i.name]}));this.applyGradients(a)}else this.applyGradients(s);return Mt(s),e?n:(n.dispose(),null)}get iterations(){return this.iterations_==null&&(this.iterations_=0),this.iterations_}incrementIterations(){this.iterations_=this.iterations+1}computeGradients(t,e){return zw(t,e)}dispose(){this.iterations_!=null&&Mt(this.iterations_)}async saveIterations(){return this.iterations_==null&&(this.iterations_=0),{name:\"iter\",tensor:ke(this.iterations_,\"int32\")}}async getWeights(){throw new Error(\"getWeights() is not implemented for this optimizer yet.\")}async setWeights(t){throw new Error(`setWeights() is not implemented for this optimizer class ${this.getClassName()}`)}async extractIterations(t){return this.iterations_=(await t[0].tensor.data())[0],t.slice(1)}};Object.defineProperty(Nr,Symbol.hasInstance,{value:r=>r.minimize!=null&&r.computeGradients!=null&&r.applyGradients!=null});var np=class extends Nr{static get className(){return\"Adadelta\"}constructor(t,e,o=null){super(),this.learningRate=t,this.rho=e,this.epsilon=o,this.accumulatedGrads=[],this.accumulatedUpdates=[],o==null&&(this.epsilon=T.backend.epsilon())}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o],a=!1;this.accumulatedGrads[n]==null&&(this.accumulatedGrads[n]={originalName:`${o}/accum_grad`,variable:De(()=>Ht(s).variable(a))}),this.accumulatedUpdates[n]==null&&(this.accumulatedUpdates[n]={originalName:`${o}/accum_var`,variable:De(()=>Ht(s).variable(a))});let i=Array.isArray(t)?t[n].tensor:t[o];if(i==null)return;let p=this.accumulatedGrads[n].variable,u=this.accumulatedUpdates[n].variable;De(()=>{let c=Ce(se(p,this.rho),se(er(i),1-this.rho)),l=se(je(Dr(Ce(u,this.epsilon)),Dr(Ce(p,this.epsilon))),i),m=Ce(se(u,this.rho),se(er(l),1-this.rho));p.assign(c),u.assign(m);let d=Ce(se(l,-this.learningRate),s);s.assign(d)})}),this.incrementIterations()}dispose(){this.accumulatedUpdates!=null&&(Mt(this.accumulatedGrads.map(t=>t.variable)),Mt(this.accumulatedUpdates.map(t=>t.variable)))}async getWeights(){let t=[...this.accumulatedGrads,...this.accumulatedUpdates];return[await this.saveIterations()].concat(t.map(e=>({name:e.originalName,tensor:e.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=t.length/2,o=!1;this.accumulatedGrads=t.slice(0,e).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.accumulatedUpdates=t.slice(e,e*2).map(n=>({originalName:n.name,variable:n.tensor.variable(o)}))}getConfig(){return{learningRate:this.learningRate,rho:this.rho,epsilon:this.epsilon}}static fromConfig(t,e){return new t(e.learningRate,e.rho,e.epsilon)}};var sp=class extends Nr{static get className(){return\"Adagrad\"}constructor(t,e=.1){super(),this.learningRate=t,this.initialAccumulatorValue=e,this.accumulatedGrads=[]}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o];this.accumulatedGrads[n]==null&&(this.accumulatedGrads[n]={originalName:`${o}/accumulator`,variable:De(()=>Ea(s.shape,this.initialAccumulatorValue).variable(!1))});let a=Array.isArray(t)?t[n].tensor:t[o];if(a==null)return;let i=this.accumulatedGrads[n].variable;De(()=>{let p=Ce(i,er(a));i.assign(p);let u=Ce(se(je(a,Dr(Ce(p,T.backend.epsilon()))),-this.learningRate),s);s.assign(u)})}),this.incrementIterations()}dispose(){this.accumulatedGrads!=null&&Mt(this.accumulatedGrads.map(t=>t.variable))}async getWeights(){return[await this.saveIterations()].concat(this.accumulatedGrads.map(t=>({name:t.originalName,tensor:t.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=!1;this.accumulatedGrads=t.map(o=>({originalName:o.name,variable:o.tensor.variable(e)}))}getConfig(){return{learningRate:this.learningRate,initialAccumulatorValue:this.initialAccumulatorValue}}static fromConfig(t,e){return new t(e.learningRate,e.initialAccumulatorValue)}};var ap=class extends Nr{static get className(){return\"Adam\"}constructor(t,e,o,n=null){super(),this.learningRate=t,this.beta1=e,this.beta2=o,this.epsilon=n,this.accumulatedFirstMoment=[],this.accumulatedSecondMoment=[],De(()=>{this.accBeta1=ke(e).variable(),this.accBeta2=ke(o).variable()}),n==null&&(this.epsilon=T.backend.epsilon())}applyGradients(t){let e=Array.isArray(t)?t.map(o=>o.name):Object.keys(t);De(()=>{let o=Te(1,this.accBeta1),n=Te(1,this.accBeta2);e.forEach((s,a)=>{let i=T.registeredVariables[s],p=!1;this.accumulatedFirstMoment[a]==null&&(this.accumulatedFirstMoment[a]={originalName:`${s}/m`,variable:De(()=>Ht(i).variable(p))}),this.accumulatedSecondMoment[a]==null&&(this.accumulatedSecondMoment[a]={originalName:`${s}/v`,variable:De(()=>Ht(i).variable(p))});let u=Array.isArray(t)?t[a].tensor:t[s];if(u==null)return;let c=this.accumulatedFirstMoment[a].variable,l=this.accumulatedSecondMoment[a].variable,m=Ce(se(c,this.beta1),se(u,1-this.beta1)),d=Ce(se(l,this.beta2),se(er(u),1-this.beta2)),f=je(m,o),h=je(d,n);c.assign(m),l.assign(d);let g=Ce(se(je(f,Ce(Dr(h),this.epsilon)),-this.learningRate),i);i.assign(g)}),this.accBeta1.assign(se(this.accBeta1,this.beta1)),this.accBeta2.assign(se(this.accBeta2,this.beta2))}),this.incrementIterations()}dispose(){this.accBeta1.dispose(),this.accBeta2.dispose(),this.accumulatedFirstMoment!=null&&Mt(this.accumulatedFirstMoment.map(t=>t.variable)),this.accumulatedSecondMoment!=null&&Mt(this.accumulatedSecondMoment.map(t=>t.variable))}async getWeights(){let t=[...this.accumulatedFirstMoment,...this.accumulatedSecondMoment];return[await this.saveIterations()].concat(t.map(e=>({name:e.originalName,tensor:e.variable})))}async setWeights(t){t=await this.extractIterations(t),De(()=>{this.accBeta1.assign(ui(this.beta1,this.iterations_+1)),this.accBeta2.assign(ui(this.beta2,this.iterations_+1))});let e=t.length/2,o=!1;this.accumulatedFirstMoment=t.slice(0,e).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.accumulatedSecondMoment=t.slice(e,e*2).map(n=>({originalName:n.name,variable:n.tensor.variable(o)}))}getConfig(){return{learningRate:this.learningRate,beta1:this.beta1,beta2:this.beta2,epsilon:this.epsilon}}static fromConfig(t,e){return new t(e.learningRate,e.beta1,e.beta2,e.epsilon)}};var ip=class extends Nr{static get className(){return\"Adamax\"}constructor(t,e,o,n=null,s=0){super(),this.learningRate=t,this.beta1=e,this.beta2=o,this.epsilon=n,this.decay=s,this.accumulatedFirstMoment=[],this.accumulatedWeightedInfNorm=[],De(()=>{this.iteration=ke(0).variable(),this.accBeta1=ke(e).variable()}),n==null&&(this.epsilon=T.backend.epsilon())}applyGradients(t){let e=Array.isArray(t)?t.map(o=>o.name):Object.keys(t);De(()=>{let o=Te(1,this.accBeta1),n=je(-this.learningRate,Ce(se(this.iteration,this.decay),1));e.forEach((s,a)=>{let i=T.registeredVariables[s],p=!1;this.accumulatedFirstMoment[a]==null&&(this.accumulatedFirstMoment[a]={originalName:`${s}/m`,variable:Ht(i).variable(p)}),this.accumulatedWeightedInfNorm[a]==null&&(this.accumulatedWeightedInfNorm[a]={originalName:`${s}/v`,variable:Ht(i).variable(p)});let u=Array.isArray(t)?t[a].tensor:t[s];if(u==null)return;let c=this.accumulatedFirstMoment[a].variable,l=this.accumulatedWeightedInfNorm[a].variable,m=Ce(se(c,this.beta1),se(u,1-this.beta1)),d=se(l,this.beta2),f=Jt(u),h=Fd(d,f);c.assign(m),l.assign(h);let g=Ce(se(je(n,o),je(m,Ce(h,this.epsilon))),i);i.assign(g)}),this.iteration.assign(Ce(this.iteration,1)),this.accBeta1.assign(se(this.accBeta1,this.beta1))}),this.incrementIterations()}dispose(){this.accBeta1.dispose(),this.iteration.dispose(),this.accumulatedFirstMoment!=null&&Mt(this.accumulatedFirstMoment.map(t=>t.variable)),this.accumulatedWeightedInfNorm!=null&&Mt(this.accumulatedWeightedInfNorm.map(t=>t.variable))}async getWeights(){throw new Error(\"getWeights() is not implemented for Adamax yet.\")}async setWeights(t){throw new Error(\"setWeights() is not implemented for Adamax yet.\")}getConfig(){return{learningRate:this.learningRate,beta1:this.beta1,beta2:this.beta2,epsilon:this.epsilon,decay:this.decay}}static fromConfig(t,e){return new t(e.learningRate,e.beta1,e.beta2,e.epsilon,e.decay)}};var mi=class extends Nr{static get className(){return\"SGD\"}constructor(t){super(),this.learningRate=t,this.setLearningRate(t)}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=Array.isArray(t)?t[n].tensor:t[o];if(s==null)return;let a=T.registeredVariables[o];De(()=>{let i=Ce(se(this.c,s),a);a.assign(i)})}),this.incrementIterations()}setLearningRate(t){this.learningRate=t,this.c!=null&&this.c.dispose(),this.c=Rr(ke(-t))}dispose(){this.c.dispose()}async getWeights(){return[await this.saveIterations()]}async setWeights(t){if(t=await this.extractIterations(t),t.length!==0)throw new Error(\"SGD optimizer does not have settable weights.\")}getConfig(){return{learningRate:this.learningRate}}static fromConfig(t,e){return new t(e.learningRate)}};var up=class extends mi{static get className(){return\"Momentum\"}constructor(t,e,o=!1){super(t),this.learningRate=t,this.momentum=e,this.useNesterov=o,this.accumulations=[],this.m=ke(this.momentum)}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o];this.accumulations[n]==null&&(this.accumulations[n]={originalName:`${o}/momentum`,variable:De(()=>Ht(s).variable(!1))});let a=this.accumulations[n].variable,i=Array.isArray(t)?t[n].tensor:t[o];i!=null&&De(()=>{let p,u=Ce(se(this.m,a),i);this.useNesterov?p=Ce(se(this.c,Ce(i,se(u,this.m))),s):p=Ce(se(this.c,u),s),a.assign(u),s.assign(p)})}),this.incrementIterations()}dispose(){this.m.dispose(),this.accumulations!=null&&Mt(this.accumulations.map(t=>t.variable))}setMomentum(t){this.momentum=t}async getWeights(){return[await this.saveIterations()].concat(this.accumulations.map(t=>({name:t.originalName,tensor:t.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=!1;this.accumulations=t.map(o=>({originalName:o.name,variable:o.tensor.variable(e)}))}getConfig(){return{learningRate:this.learningRate,momentum:this.momentum,useNesterov:this.useNesterov}}static fromConfig(t,e){return new t(e.learningRate,e.momentum,e.useNesterov)}};var pp=class extends Nr{static get className(){return\"RMSProp\"}constructor(t,e=.9,o=0,n=null,s=!1){if(super(),this.learningRate=t,this.decay=e,this.momentum=o,this.epsilon=n,this.accumulatedMeanSquares=[],this.accumulatedMoments=[],this.accumulatedMeanGrads=[],this.centered=s,n==null&&(this.epsilon=T.backend.epsilon()),t==null)throw new Error(\"learningRate for RMSPropOptimizer must be defined.\")}applyGradients(t){(Array.isArray(t)?t.map(o=>o.name):Object.keys(t)).forEach((o,n)=>{let s=T.registeredVariables[o],a=!1;this.accumulatedMeanSquares[n]==null&&(this.accumulatedMeanSquares[n]={originalName:`${o}/rms`,variable:De(()=>Ht(s).variable(a))}),this.accumulatedMoments[n]==null&&(this.accumulatedMoments[n]={originalName:`${o}/momentum`,variable:De(()=>Ht(s).variable(a))}),this.accumulatedMeanGrads[n]==null&&this.centered&&(this.accumulatedMeanGrads[n]={originalName:`${o}/mg`,variable:De(()=>Ht(s).variable(a))});let i=Array.isArray(t)?t[n].tensor:t[o];if(i==null)return;let p=this.accumulatedMeanSquares[n].variable,u=this.accumulatedMoments[n].variable;De(()=>{let c=Ce(se(p,this.decay),se(er(i),1-this.decay));if(this.centered){let l=this.accumulatedMeanGrads[n].variable,m=Ce(se(l,this.decay),se(i,1-this.decay)),d=je(se(i,this.learningRate),Dr(Te(c,Ce(er(m),this.epsilon)))),f=Ce(se(u,this.momentum),d);p.assign(c),l.assign(m),u.assign(f);let h=Te(s,f);s.assign(h)}else{let l=Ce(se(p,this.decay),se(er(i),1-this.decay)),m=Ce(se(u,this.momentum),je(se(i,this.learningRate),Dr(Ce(l,this.epsilon))));p.assign(l),u.assign(m);let d=Te(s,m);s.assign(d)}})}),this.incrementIterations()}dispose(){this.accumulatedMeanSquares!=null&&Mt(this.accumulatedMeanSquares.map(t=>t.variable)),this.accumulatedMeanGrads!=null&&this.centered&&Mt(this.accumulatedMeanGrads.map(t=>t.variable)),this.accumulatedMoments!=null&&Mt(this.accumulatedMoments.map(t=>t.variable))}async getWeights(){let t=[...this.accumulatedMeanSquares,...this.accumulatedMoments];return this.centered&&t.push(...this.accumulatedMeanGrads),[await this.saveIterations()].concat(t.map(e=>({name:e.originalName,tensor:e.variable})))}async setWeights(t){t=await this.extractIterations(t);let e=this.centered?t.length/3:t.length/2,o=!1;this.accumulatedMeanSquares=t.slice(0,e).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.accumulatedMoments=t.slice(e,e*2).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})),this.centered&&(this.accumulatedMeanGrads=t.slice(e*2,e*3).map(n=>({originalName:n.name,variable:n.tensor.variable(o)})))}getConfig(){return{learningRate:this.learningRate,decay:this.decay,momentum:this.momentum,epsilon:this.epsilon,centered:this.centered}}static fromConfig(t,e){return new t(e.learningRate,e.decay,e.momentum,e.epsilon,e.centered)}};var Jj=[np,sp,ap,ip,up,pp,mi];function UN(){for(let r of Jj)tS(r)}var fi={};qe(fi,{CompositeArrayBuffer:()=>jt,browserFiles:()=>HN,browserHTTPRequest:()=>jN,concatenateArrayBuffers:()=>ik,copyModel:()=>wk,decodeWeights:()=>ad,encodeWeights:()=>nk,fromMemory:()=>XN,fromMemorySync:()=>iS,getLoadHandlers:()=>lk,getModelArtifactsForJSON:()=>ic,getModelArtifactsForJSONSync:()=>_w,getModelArtifactsInfoForJSON:()=>va,getSaveHandlers:()=>ck,getWeightSpecs:()=>ud,http:()=>nf,isHTTPScheme:()=>of,listModels:()=>bk,loadWeights:()=>KN,moveModel:()=>Sk,registerLoadRouter:()=>pk,registerSaveRouter:()=>uk,removeModel:()=>Ck,weightsLoaderFactory:()=>sS,withSaveHandler:()=>YN,withSaveHandlerSync:()=>QN});var eX=\"model\",tX=\".json\",rX=\".weights.bin\";function GN(r){return new Promise(t=>setTimeout(t)).then(r)}var di=class{constructor(t){if(!A().getBool(\"IS_BROWSER\"))throw new Error(\"browserDownloads() cannot proceed because the current environment is not a browser.\");t.startsWith(di.URL_SCHEME)&&(t=t.slice(di.URL_SCHEME.length)),(t==null||t.length===0)&&(t=eX),this.modelJsonFileName=t+tX,this.weightDataFileName=t+rX}async save(t){if(typeof document==\"undefined\")throw new Error(\"Browser downloads are not supported in this environment since `document` is not present\");let e=jt.join(t.weightData),o=window.URL.createObjectURL(new Blob([e],{type:\"application/octet-stream\"}));if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserDownloads.save() does not support saving model topology in binary formats yet.\");{let n=[{paths:[\"./\"+this.weightDataFileName],weights:t.weightSpecs}],s=id(t,n),a=window.URL.createObjectURL(new Blob([JSON.stringify(s)],{type:\"application/json\"})),i=this.modelJsonAnchor==null?document.createElement(\"a\"):this.modelJsonAnchor;if(i.download=this.modelJsonFileName,i.href=a,await GN(()=>i.dispatchEvent(new MouseEvent(\"click\"))),t.weightData!=null){let p=this.weightDataAnchor==null?document.createElement(\"a\"):this.weightDataAnchor;p.download=this.weightDataFileName,p.href=o,await GN(()=>p.dispatchEvent(new MouseEvent(\"click\")))}return{modelArtifactsInfo:va(t)}}}};di.URL_SCHEME=\"downloads://\";var rS=class{constructor(t){if(t==null||t.length<1)throw new Error(`When calling browserFiles, at least 1 file is required, but received ${t}`);this.jsonFile=t[0],this.weightsFiles=t.slice(1)}async load(){return new Promise((t,e)=>{let o=new FileReader;o.onload=n=>{let s=JSON.parse(n.target.result),a=s.modelTopology;if(a==null){e(new Error(`modelTopology field is missing from file ${this.jsonFile.name}`));return}if(s.weightsManifest==null){e(new Error(`weightManifest field is missing from file ${this.jsonFile.name}`));return}if(this.weightsFiles.length===0){t({modelTopology:a});return}let p=ic(s,u=>this.loadWeights(u));t(p)},o.onerror=n=>e(`Failed to read model topology and weights manifest JSON from file '${this.jsonFile.name}'. BrowserFiles supports loading Keras-style tf.Model artifacts only.`),o.readAsText(this.jsonFile)})}loadWeights(t){let e=[],o=[];for(let a of t)e.push(...a.weights),o.push(...a.paths);let n=this.checkManifestAndWeightFiles(t),s=o.map(a=>this.loadWeightsFile(a,n[a]));return Promise.all(s).then(a=>[e,a])}loadWeightsFile(t,e){return new Promise((o,n)=>{let s=new FileReader;s.onload=a=>{let i=a.target.result;o(i)},s.onerror=a=>n(`Failed to weights data from file of path '${t}'.`),s.readAsArrayBuffer(e)})}checkManifestAndWeightFiles(t){let e=[],o=this.weightsFiles.map(s=>Tw(s.name)),n={};for(let s of t)s.paths.forEach(a=>{let i=Tw(a);if(e.indexOf(i)!==-1)throw new Error(`Duplicate file basename found in weights manifest: '${i}'`);if(e.push(i),o.indexOf(i)===-1)throw new Error(`Weight file with basename '${i}' is not provided.`);n[a]=this.weightsFiles[o.indexOf(i)]});if(e.length!==this.weightsFiles.length)throw new Error(`Mismatch in the number of files in weights manifest (${e.length}) and the number of weight files provided (${this.weightsFiles.length}).`);return n}},oX=r=>A().getBool(\"IS_BROWSER\")&&!Array.isArray(r)&&r.startsWith(di.URL_SCHEME)?nX(r.slice(di.URL_SCHEME.length)):null;ft.registerSaveRouter(oX);function nX(r=\"model\"){return new di(r)}function HN(r){return new rS(r)}function oS(r,t,e,o){a(r),e=e==null?0:e,o=o==null?1:o,i(e,o);let n=0,s=p=>(p.then(u=>{let c=e+ ++n/r.length*(o-e);return t(c),u}),p);function a(p){$(p!=null&&Array.isArray(p)&&p.length>0,()=>\"promises must be a none empty array\")}function i(p,u){$(p>=0&&p<=1,()=>`Progress fraction must be in range [0, 1], but got startFraction ${p}`),$(u>=0&&u<=1,()=>`Progress fraction must be in range [0, 1], but got endFraction ${u}`),$(u>=p,()=>`startFraction must be no more than endFraction, but got startFraction ${p} and endFraction ${u}`)}return Promise.all(r.map(s))}async function nS(r,t){t==null&&(t={});let e=t.fetchFunc==null?A().platform.fetch:t.fetchFunc,o=r.map(l=>e(l,t.requestInit,{isBinary:!0})),n=0,s=.5,i=(t.onProgress==null?await Promise.all(o):await oS(o,t.onProgress,n,s)).map(l=>l.arrayBuffer()),p=.5,u=1;return t.onProgress==null?await Promise.all(i):await oS(i,t.onProgress,p,u)}async function KN(r,t=\"\",e,o){return sS(a=>nS(a,{requestInit:o}))(r,t,e)}function sS(r){return async(t,e=\"\",o)=>{let n=t.map(()=>!1),s={},a=o!=null?o.map(()=>!1):[],i=[];if(t.forEach((d,f)=>{let h=0;d.weights.forEach(g=>{let x=\"quantization\"in g?g.quantization.dtype:g.dtype,b=Il[x]*He(g.shape),C=()=>{n[f]=!0,s[f]==null&&(s[f]=[]),s[f].push({manifestEntry:g,groupOffset:h,sizeBytes:b})};o!=null?o.forEach((S,k)=>{S===g.name&&(C(),a[k]=!0)}):C(),i.push(g.name),h+=b})}),!a.every(d=>d)){let d=o.filter((f,h)=>!a[h]);throw new Error(`Could not find weights in manifest with names: ${d.join(\", \")}. \nManifest JSON has weights with names: ${i.join(\", \")}.`)}let p=n.reduce((d,f,h)=>(f&&d.push(h),d),[]),u=[];p.forEach(d=>{t[d].paths.forEach(f=>{let h=e+(e.endsWith(\"/\")?\"\":\"/\")+f;u.push(h)})});let c=await r(u),l={},m=0;return p.forEach(d=>{let f=t[d].paths.length,h=new jt(c.slice(m,m+f));s[d].forEach(x=>{let b=h.slice(x.groupOffset,x.groupOffset+x.sizeBytes),C=ad(b,[x.manifestEntry]);for(let S in C)l[S]=C[S]}),m+=f}),l}}var sX=\"application/octet-stream\",aX=\"application/json\",Al=class{constructor(t,e){if(this.DEFAULT_METHOD=\"POST\",e==null&&(e={}),this.weightPathPrefix=e.weightPathPrefix,this.onProgress=e.onProgress,this.weightUrlConverter=e.weightUrlConverter,e.fetchFunc!=null?($(typeof e.fetchFunc==\"function\",()=>\"Must pass a function that matches the signature of `fetch` (see https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API)\"),this.fetch=e.fetchFunc):this.fetch=A().platform.fetch,$(t!=null&&t.length>0,()=>\"URL path for http must not be null, undefined or empty.\"),Array.isArray(t)&&$(t.length===2,()=>`URL paths for http must have a length of 2, (actual length is ${t.length}).`),this.path=t,e.requestInit!=null&&e.requestInit.body!=null)throw new Error(\"requestInit is expected to have no pre-existing body, but has one.\");this.requestInit=e.requestInit||{}}async save(t){if(t.modelTopology instanceof ArrayBuffer)throw new Error(\"BrowserHTTPRequest.save() does not support saving model topology in binary formats yet.\");let e=Object.assign({method:this.DEFAULT_METHOD},this.requestInit);e.body=new FormData;let o=[{paths:[\"./model.weights.bin\"],weights:t.weightSpecs}],n=id(t,o);if(e.body.append(\"model.json\",new Blob([JSON.stringify(n)],{type:aX}),\"model.json\"),t.weightData!=null){let a=jt.join(t.weightData);e.body.append(\"model.weights.bin\",new Blob([a],{type:sX}),\"model.weights.bin\")}let s=await this.fetch(this.path,e);if(s.ok)return{modelArtifactsInfo:va(t),responses:[s]};throw new Error(`BrowserHTTPRequest.save() failed due to HTTP response status ${s.status}.`)}async load(){let t=await this.fetch(this.path,this.requestInit);if(!t.ok)throw new Error(`Request to ${this.path} failed with status code ${t.status}. Please verify this URL points to the model JSON of the model to load.`);let e;try{e=await t.json()}catch(s){let a=`Failed to parse model JSON of response from ${this.path}.`;throw this.path.endsWith(\".pb\")?a+=\" Your path contains a .pb file extension. Support for .pb models have been removed in TensorFlow.js 1.0 in favor of .json models. You can re-convert your Python TensorFlow model using the TensorFlow.js 1.0 conversion scripts or you can convert your.pb models with the 'pb2json'NPM script in the tensorflow/tfjs-converter repository.\":a+=\" Please make sure the server is serving valid JSON for this request.\",new Error(a)}let o=e.modelTopology,n=e.weightsManifest;if(o==null&&n==null)throw new Error(`The JSON from HTTP path ${this.path} contains neither model topology or manifest for weights.`);return ic(e,s=>this.loadWeights(s))}async loadWeights(t){let e=Array.isArray(this.path)?this.path[1]:this.path,[o,n]=iX(e),s=this.weightPathPrefix||o,a=ud(t),i=[],p=[];for(let c of t)for(let l of c.paths)this.weightUrlConverter!=null?p.push(this.weightUrlConverter(l)):i.push(s+l+n);this.weightUrlConverter&&i.push(...await Promise.all(p));let u=await nS(i,{requestInit:this.requestInit,fetchFunc:this.fetch,onProgress:this.onProgress});return[a,u]}};Al.URL_SCHEME_REGEX=/^https?:\\/\\//;function iX(r){let t=r.lastIndexOf(\"/\"),e=r.lastIndexOf(\"?\"),o=r.substring(0,t),n=e>t?r.substring(e):\"\";return[o+\"/\",n]}function of(r){return r.match(Al.URL_SCHEME_REGEX)!=null}var qN=(r,t)=>{if(typeof fetch==\"undefined\"&&(t==null||t.fetchFunc==null))return null;{let e=!0;if(Array.isArray(r)?e=r.every(o=>of(o)):e=of(r),e)return nf(r,t)}return null};ft.registerSaveRouter(qN);ft.registerLoadRouter(qN);function nf(r,t){return new Al(r,t)}function jN(r,t){return nf(r,t)}var Fl=class{constructor(t){this.modelArtifacts=t}load(){return this.modelArtifacts}},sf=class{constructor(t){this.saveHandler=t}save(t){return this.saveHandler(t)}},aS=class{constructor(t){t.load&&(this.load=()=>Promise.resolve(t.load())),t.save&&(this.save=e=>Promise.resolve(t.save(e)))}};function XN(r,t,e,o){let n=arguments;return new aS(iS(...n))}function iS(r,t,e,o){return arguments.length===1?r.modelTopology!=null||r.weightSpecs!=null?new Fl(r):(console.warn(\"Please call tf.io.fromMemory() with only one argument. The argument should be of type ModelArtifacts. The multi-argument signature of tf.io.fromMemory() has been deprecated and will be removed in a future release.\"),new Fl({modelTopology:r})):(console.warn(\"Please call tf.io.fromMemory() with only one argument. The argument should be of type ModelArtifacts. The multi-argument signature of tf.io.fromMemory() has been deprecated and will be removed in a future release.\"),new Fl({modelTopology:r,weightSpecs:t,weightData:e,trainingConfig:o}))}function YN(r){return new sf(r)}function QN(r){return new sf(r)}var JN={};qe(JN,{confusionMatrix:()=>ZN});function uX(r,t,e){let o=v(r,\"labels\",\"confusionMatrix\"),n=v(t,\"predictions\",\"confusionMatrix\");$(e==null||e>0&&Number.isInteger(e),()=>`If provided, numClasses must be a positive integer, but got ${e}`),$(o.rank===1,()=>`Expected the rank of labels to be 1, but got ${o.rank}`),$(n.rank===1,()=>`Expected the rank of predictions to be 1, but got ${n.rank}`),$(o.shape[0]===n.shape[0],()=>`Mismatch in the number of examples: ${o.shape[0]} vs. ${n.shape[0]}. Labels and predictions should have the same number of elements.`),$(e>0&&Number.isInteger(e),()=>`numClasses is required to be a positive integer, but got ${e}`);let s=El(We(o,\"int32\"),e),a=El(We(n,\"int32\"),e),i=yc(s),p=Ze(i,a);return We(p,\"int32\")}var ZN=N({confusionMatrix_:uX});var oT={};qe(oT,{draw:()=>gX,fromPixels:()=>xX,fromPixelsAsync:()=>dX,toPixels:()=>hX});var cp,eT=!1;function tT(r,t=3){if(t>4)throw new Error(\"Cannot construct Tensor with more than 4 channels from pixels.\");if(r==null)throw new Error(\"pixels passed to tf.browser.fromPixels() can not be null\");let e=!1,o=!1,n=!1,s=!1,a=!1,i=!1;if(r.data instanceof Uint8Array)e=!0;else if(typeof ImageData!=\"undefined\"&&r instanceof ImageData)o=!0;else if(typeof HTMLVideoElement!=\"undefined\"&&r instanceof HTMLVideoElement)n=!0;else if(typeof HTMLImageElement!=\"undefined\"&&r instanceof HTMLImageElement)s=!0;else if(r.getContext!=null)a=!0;else if(typeof ImageBitmap!=\"undefined\"&&r instanceof ImageBitmap)i=!0;else throw new Error(`pixels passed to tf.browser.fromPixels() must be either an HTMLVideoElement, HTMLImageElement, HTMLCanvasElement, ImageData in browser, or OffscreenCanvas, ImageData in webworker or {data: Uint32Array, width: number, height: number}, but was ${r.constructor.name}`);if(tc(Mu,T.backendName)!=null){let f={pixels:r},h={numChannels:t};return T.runKernel(Mu,f,h)}let[u,c]=n?[r.videoWidth,r.videoHeight]:[r.width,r.height],l;if(a)l=r.getContext(\"2d\").getImageData(0,0,u,c).data;else if(o||e)l=r.data;else if(s||n||i){if(cp==null)if(typeof document==\"undefined\")if(typeof OffscreenCanvas!=\"undefined\"&&typeof OffscreenCanvasRenderingContext2D!=\"undefined\")cp=new OffscreenCanvas(1,1).getContext(\"2d\");else throw new Error(\"Cannot parse input in current context. Reason: OffscreenCanvas Context2D rendering is not supported.\");else cp=document.createElement(\"canvas\").getContext(\"2d\",{willReadFrequently:!0});cp.canvas.width=u,cp.canvas.height=c,cp.drawImage(r,0,0,u,c),l=cp.getImageData(0,0,u,c).data}let m;if(t===4)m=new Int32Array(l);else{let f=u*c;m=new Int32Array(f*t);for(let h=0;h4||t===2)throw new Error(`toPixels only supports depth of size 1, 3 or 4 but got ${t}`);if(r.dtype!==\"float32\"&&r.dtype!==\"int32\")throw new Error(`Unsupported type for toPixels: ${r.dtype}. Please use float32 or int32 tensors.`)}function fX(r){let t=(r==null?void 0:r.alpha)||1;if(t>1||t<0)throw new Error(`Alpha value ${t} is suppoed to be in range [0 - 1].`)}async function hX(r,t){let e=v(r,\"img\",\"toPixels\");if(!(r instanceof ut)){let u=e;e=We(u,\"int32\"),u.dispose()}rT(e);let[o,n]=e.shape.slice(0,2),s=e.rank===2?1:e.shape[2],a=await e.data(),i=e.dtype===\"float32\"?255:1,p=new Uint8ClampedArray(n*o*4);for(let u=0;u1)throw new Error(`Tensor values for a float32 Tensor must be in the range [0 - 1] but encountered ${d}.`)}else if(e.dtype===\"int32\"&&(d<0||d>255))throw new Error(`Tensor values for a int32 Tensor must be in the range [0 - 255] but encountered ${d}.`);s===1?(c[0]=d*i,c[1]=d*i,c[2]=d*i):c[m]=d*i}let l=u*4;p[l+0]=Math.round(c[0]),p[l+1]=Math.round(c[1]),p[l+2]=Math.round(c[2]),p[l+3]=Math.round(c[3])}if(t!=null){eT||tc(Pu,T.backendName)!=null&&(console.warn(\"tf.browser.toPixels is not efficient to draw tensor on canvas. Please try tf.browser.draw instead.\"),eT=!0),t.width=n,t.height=o;let u=t.getContext(\"2d\"),c=new ImageData(p,n,o);u.putImageData(c,0,0)}return e!==r&&e.dispose(),p}function gX(r,t,e){let o=v(r,\"img\",\"draw\");if(!(r instanceof ut)){let a=o;o=We(a,\"int32\"),a.dispose()}rT(o),fX(e==null?void 0:e.imageOptions);let n={image:o},s={canvas:t,options:e};T.runKernel(Pu,n,s)}var xX=N({fromPixels_:tT});var af={};qe(af,{prepareAndValidate:()=>nT});function nT(r,t){let e=r.shape.length,o=t.shape.length;if(e<1)throw new Error(`tf.gatherND() expects the input to be rank 1 or higher, but the rank was ${e}.`);if(o<1)throw new Error(`tf.gatherND() expects the indices to be rank 1 or higher, but the rank was ${o}.`);if(t.dtype!==\"int32\")throw new Error(`tf.gatherND() expects the indices to be int32 type, but the dtype was ${t.dtype}.`);if(t.shape[o-1]>e)throw new Error(`index innermost dimension length must be <= tensor rank; saw: ${t.shape[o-1]} vs. ${e}`);if(He(r.shape)===0)throw new Error(`Requested more than 0 entries, but input is empty. Input shape: ${r.shape}.`);let n=t.shape,s=n[n.length-1],a=1;for(let l=0;ll/u),1].slice(0,s);return[p,a,u,c]}var ct={};qe(ct,{assertParamsValid:()=>bX,computeFlatOffset:()=>vX,computeOutShape:()=>wX,getNormalizedAxes:()=>SX,isSliceContinous:()=>IX,maskToAxes:()=>CX,parseSliceParams:()=>kX,sliceInfo:()=>NX,startForAxis:()=>mT,startIndicesWithElidedDims:()=>pT,stopForAxis:()=>dT,stopIndicesWithElidedDims:()=>cT,stridesForAxis:()=>lT,stridesWithElidedDims:()=>aT});var uS=-2,yX=-1;function bX(r,t,e){let o=r.shape.length;$(o===t.length,()=>`Error in slice${o}D: Length of begin ${t} must match the rank of the array (${o}).`),$(o===e.length,()=>`Error in slice${o}D: Length of size ${e} must match the rank of the array (${o}).`);for(let n=0;n`Error in slice${o}D: begin[${n}] + size[${n}] (${t[n]+e[n]}) would overflow input.shape[${n}] (${r.shape[n]})`)}function CX(r){let t=[],e=0;for(;r>0;)r&1&&t.push(e),r/=2,e++;return t}function wX(r,t,e){let o=[];for(let n=0;n0){let d=t[0],f=e+1;c=pT(a,d,f,o,r),l=cT(i,d,f,n,r),m=aT(s,d,f,r)}else for(let d=0;d-1)s[i]=0;else{let p=iT(t,e,i),u=o[p];r&1<-1)s[i]=Number.MAX_SAFE_INTEGER;else{let p=iT(t,e,i),u=o[p];r&1<0?a=Number.MIN_SAFE_INTEGER:a=Number.MAX_SAFE_INTEGER);let p=o[n];return a<0&&(a+=p),a=qp(0,a,p-1),a}function dT(r,t,e,o,n,s){let a=t[n],i=e[n]||1;(r&1<0?a=Number.MAX_SAFE_INTEGER:a=Number.MIN_SAFE_INTEGER);let p=o[n];return a<0&&(a+=p),i>0?a=qp(0,a,p):a=qp(-1,a,p-1),a}function IX(r,t,e){let o=e.length;for(let n=0;n1){o=n;break}for(let n=o+1;n0||e[n]!==r[n])return!1;return!0}function vX(r,t){let e=r.length>0?r[r.length-1]:1;for(let o=0;o{$(a!==-1,()=>\"slice() does not support negative begin indexing.\")});let s;return e==null?s=new Array(n).fill(-1):typeof e==\"number\"?s=[e,...new Array(n-1).fill(-1)]:e.lengtha>=0?a:($(a===-1,()=>`Negative size values should be exactly -1 but got ${a} for the slice() size at index ${i}.`),r.shape[i]-o[i])),[o,s]}function NX(r,t,e,o,n,s,a,i,p){let u;if(o==null?(u=new Array(t.length),u.fill(1)):u=o,a!=null&&a&a-1)throw new Error(\"Multiple ellipses in slice is not allowed.\");let c=!1,l={dims:u.length,numAddAxisAfterEllipsis:0,begin:t.slice(),end:e.slice(),strides:u.slice(),beginMask:n,endMask:s,ellipsisMask:a,newAxisMask:i,shrinkAxisMask:p};for(let C=0;C0?0:-1,m.strides[C]>0?k:k-1];if(S&&m.strides[C]<=0)throw Error(\"only stride 1 allowed on non-range indexing.\");h=h&&m.strides[C]===1;let R=!!(m.beginMask&1<=k)throw Error(`slice index ${m.begin[C]} of dimension ${C} out of bounds.`)}else m.begin[C]=sT(m.begin[C],0,m.strides[C],k,_,E),m.end[C]=sT(m.end[C],1,m.strides[C],k,_,E);let O=m.strides[C]===1&&m.begin[C]===0&&m.end[C]===k;d=d&&O,f=f&&(C===0&&m.strides[C]===1||O)}else d=d&&m.strides[C]===1&&R,f=f&&(C===0&&m.strides[C]===1||R);let D,P=!1;if(m.beginValid&&m.endValid?(D=m.end[C]-m.begin[C],P=!0):S?(D=1,P=!0):R&&k>=0&&(m.strides[C]<0?D=-k:D=k,P=!0),P){let O;D===0||D<0!=m.strides[C]<0?O=0:O=Math.trunc(D/m.strides[C])+(D%m.strides[C]!==0?1:0),g.push(O)}else g.push(-1)}for(let C=0;C=0?x.push(g[S]):S===uS&&x.push(1)}return{finalShapeSparse:x.filter((C,S)=>m.finalShapeGatherIndices[S]!==uS),finalShape:x,isIdentity:d,sliceDim0:f,isSimpleSlice:h,begin:m.begin,end:m.end,strides:m.strides}}function TX(r,t){t.beginMask=0,t.endMask=0,t.shrinkAxisMask=0;let e=0;t.beginValid=r.begin!=null,t.endValid=r.end!=null,t.begin=new Array(t.dims),t.end=new Array(t.dims),t.strides=new Array(t.dims),t.finalShapeGatherIndices=[],t.finalShapeGatherIndicesSparse=[],t.inputShapeGatherIndicesSparse=new Array(t.dims);for(let o=0;o0?s[t]:s[t+1&1];{let a=r<0?o+r:r;return as[1]?s[1]:a}}var _X=\"4.11.0\";var Pl=class{static sgd(t){return new mi(t)}static momentum(t,e,o=!1){return new up(t,e,o)}static rmsprop(t,e=.9,o=0,n=null,s=!1){return new pp(t,e,o,n,s)}static adam(t=.001,e=.9,o=.999,n=null){return new ap(t,e,o,n)}static adadelta(t=.001,e=.95,o=null){return new np(t,e,o)}static adamax(t=.002,e=.9,o=.999,n=null,s=0){return new ip(t,e,o,n,s)}static adagrad(t,e=.1){return new sp(t,e)}};var TGe=Pl;var $X=(()=>typeof requestAnimationFrame!=\"undefined\"?requestAnimationFrame:typeof setImmediate!=\"undefined\"?setImmediate:r=>r())();function pS(){return new Promise(r=>$X(()=>r()))}var w={};qe(w,{ERF_A1:()=>KX,ERF_A2:()=>qX,ERF_A3:()=>jX,ERF_A4:()=>XX,ERF_A5:()=>YX,ERF_P:()=>HX,PARALLELIZE_THRESHOLD:()=>uf,RowPartitionType:()=>Pa,SELU_SCALE:()=>GX,SELU_SCALEALPHA:()=>UX,applyActivation:()=>rp,assertAndGetBroadcastShape:()=>rt,assertAxesAreInnerMostDims:()=>tK,assertParamsConsistent:()=>EX,assignToTypedArray:()=>r5,axesAreInnerMostDims:()=>Bw,calculateShapes:()=>V1,checkEinsumDimSizes:()=>u5,checkPadOnDimRoundingMode:()=>Bt,combineLocations:()=>x2,combineRaggedTensorToTensorShapes:()=>DX,complexWithEvenIndex:()=>JX,complexWithOddIndex:()=>e5,computeConv2DInfo:()=>Hu,computeConv3DInfo:()=>Mk,computeDefaultPad:()=>Lw,computeDilation2DInfo:()=>J4,computeOptimalWindowSize:()=>OX,computeOutAndReduceShapes:()=>eK,computeOutShape:()=>RX,computePool2DInfo:()=>Mw,computePool3DInfo:()=>eH,convertConv2DDataFormat:()=>Lk,decodeEinsumEquation:()=>a5,eitherStridesOrDilationsAreOne:()=>xr,expandShapeToKeepDim:()=>ii,exponent:()=>n5,exponents:()=>o5,fromStringArrayToUint8:()=>$5,fromUint8ToStringArray:()=>_5,getAxesPermutation:()=>rK,getBroadcastDims:()=>m2,getComplexWithIndex:()=>t5,getEinsumComputePath:()=>p5,getEinsumPermutation:()=>i5,getFusedBiasGradient:()=>tp,getFusedDyActivation:()=>ep,getImageCenter:()=>MX,getInnerMostAxes:()=>nK,getPermuted:()=>BX,getRaggedRank:()=>FX,getReductionAxes:()=>yd,getReshaped:()=>LX,getReshapedPermuted:()=>zX,getRowPartitionTypesHelper:()=>AX,getSliceBeginCoords:()=>VX,getSliceSize:()=>WX,getSparseFillEmptyRowsIndicesDenseShapeMismatch:()=>d5,getSparseFillEmptyRowsNegativeIndexErrorMessage:()=>f5,getSparseFillEmptyRowsOutOfRangeIndexErrorMessage:()=>h5,getSparseReshapeEmptyTensorZeroOutputDimErrorMessage:()=>y5,getSparseReshapeInputOutputMismatchErrorMessage:()=>C5,getSparseReshapeInputOutputMultipleErrorMessage:()=>b5,getSparseReshapeMultipleNegativeOneOutputDimErrorMessage:()=>g5,getSparseReshapeNegativeOutputDimErrorMessage:()=>x5,getSparseSegmentReductionIndicesOutOfRangeErrorMessage:()=>v5,getSparseSegmentReductionNegativeSegmentIdsErrorMessage:()=>w5,getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage:()=>S5,getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage:()=>I5,getUndoAxesPermutation:()=>oK,isIdentityPermutation:()=>c5,log:()=>jG,mergeRealAndImagArrays:()=>QX,prepareAndValidate:()=>nT,prepareSplitSize:()=>m5,segment_util:()=>lS,shouldFuse:()=>op,slice_util:()=>ct,splitRealAndImagArrays:()=>ZX,stridesOrDilationsArePositive:()=>Ta,tupleValuesAreOne:()=>Gu,upcastType:()=>dt,validateDefaultValueShape:()=>PX,validateInput:()=>xc,validateUpdateShape:()=>Yw,warn:()=>Ia});function EX(r,t){let e=r[0].length;r.forEach((n,s)=>{$(n.length===e,()=>`Error in concat${e}D: rank of tensors[${s}] must be the same as the rank of the rest (${e})`)}),$(t>=0&&t`Error in concat${e}D: axis must be between 0 and ${e-1}.`);let o=r[0];r.forEach((n,s)=>{for(let a=0;a`Error in concat${e}D: Shape of tensors[${s}] (${n}) does not match the shape of the rest (${o}) along the non-concatenated axis ${s}.`)})}function RX(r,t){let e=r[0].slice();for(let o=1;o=0)if(i>=0){if(i!==s)throw new Error(`rt input.shape and shape=${t} are incompatible: rt input.shape[${n+r}] = ${s} but shape[${n+r}] = ${i}`)}else o[a]=s}return o}function AX(r){let t={FIRST_DIM_SIZE:Pa.FIRST_DIM_SIZE,VALUE_ROWIDS:Pa.VALUE_ROWIDS,ROW_LENGTHS:Pa.ROW_LENGTHS,ROW_SPLITS:Pa.ROW_SPLITS,ROW_LIMITS:Pa.ROW_LIMITS,ROW_STARTS:Pa.ROW_STARTS},e=[];for(let o of r)if(o in t)e.push(t[o]);else break;return e}function FX(r){return r.length===0?0:r[0]===Pa.FIRST_DIM_SIZE?r.length-1:r.length}function PX(r,t){if(r==null||t==null)return;let e=r.length,o=t.length;if(e>=o)throw new Error(`defaultValue.shape=${r} and ragged tensor flatValues.shape=${t}, are incompatible: defaultValue.rank = ${e} must be less than ragged tensor input flatValues.rank = ${o})`);for(let n=0;n=0&&a>=0&&s!==1&&s!==a)throw new Error(`defaultValue.shape=${r}, and ragged tensor input flatValues.shape=${t} are incompatible: defaultValue.shape[${n-r.length}] = ${s} but ragged tensor input.flatValues.shape[${n-r.length}] = ${a}`)}}var uf=30;function OX(r){return r<=uf?r:Xp(r,Math.floor(Math.sqrt(r)))}function MX(r,t,e){let o=e*(typeof r==\"number\"?r:r[0]),n=t*(typeof r==\"number\"?r:r[1]);return[o,n]}function LX(r,t,e,o=!0){let n=[];if(o)n=n.concat(t.slice(0)),n.push(r[0]/e),n=n.concat(r.slice(1));else{n=n.concat(r[0]);let s=t.length;for(let a=0;a=t*2+1||a%2===1?s.push(a):n.push(a);o.push(...n),o.push(0),o.push(...s)}return o}function zX(r,t,e,o=!0){let n=[];o?n.push(r[0]/e):n.push(r[0]*e);for(let s=1;s\",s5=/->/g,fT=\",\",hT=\"...\";function a5(r,t){r=r.replace(/\\s/g,\"\");let e=(r.length-r.replace(s5,\"\").length)/cS.length;if(e<1)throw new Error(\"Equations without an arrow are not supported.\");if(e>1)throw new Error(`Equation must contain exactly one arrow (\"${cS}\").`);let[o,n]=r.split(cS);$(o.indexOf(hT)===-1,()=>`The ellipsis notation (\"${hT}\") is not supported yet.`);let s=o.split(fT),a=s.length;if(t!==a)throw new Error(`Expected ${a} input tensors, received ${t}`);if(a>2)throw new Error(\"Support for more than 2 input tensors is not implemented yet.\");let i=[];for(let m=0;mf.indexOf(d)!==-1))throw new Error(`Output subscripts contain the label ${d} not present in the input subscripts.`);i.indexOf(d)===-1&&i.push(d)}for(let m=0;mn!==-1),{permutationIndices:e,expandDims:o}}function u5(r,t,e){let o=new Array(r);for(let n=0;n`Expected dimension ${o[t[n][a]]} at axis ${a} of input shaped ${JSON.stringify(s)}, but got dimension ${s[a]}`)}}function p5(r,t){let e=r,o=[],n=0;r.length===0&&e.push(-1),n=r.length+1;for(let a=0;at===e)}function l5(r,t){let e=[];for(let o=0;o\"Number of splits must evenly divide the axis.\"),o=new Array(t).fill(r.shape[e]/t);else{let n=t.reduce((a,i)=>(i===-1&&(a+=1),a),0);$(n<=1,()=>\"There should be only one negative value in split array.\");let s=t.indexOf(-1);if(s!==-1){let a=t.reduce((i,p)=>p>0?i+p:i);t[s]=r.shape[e]-a}$(r.shape[e]===t.reduce((a,i)=>a+i),()=>\"The sum of sizes must match the size of the axis dimension.\"),o=t}return o}function d5(r){return`Received SparseTensor with denseShape[0] = 0 but\n indices.shape[0] = ${r}`}function f5(r,t){return`indices(${r}, 0) is invalid: ${t} < 0`}function h5(r,t,e){return`indices(${r}, 0) is invalid: ${t} >= ${e}`}function g5(r,t){return`only one output dimension may be -1, not both ${r} and ${t}`}function x5(r,t){return`size ${r} must be non-negative, not ${t}`}function y5(){return\"reshape cannot infer the missing input size for an empty tensor unless all specified input sizes are non-zero\"}function b5(r,t){let e=He(r),o=He(t);return`Input to reshape is a SparseTensor with ${e}\n dense values, but the requested shape requires a multiple of ${o}. inputShape=${r} outputShape= ${t}`}function C5(r,t){let e=He(r),o=He(t);return`Input to reshape is a tensor with ${e} dense values, but the requested shape has ${o}. inputShape=${r} outputShape=${t}`}function w5(){return\"segment ids must be >= 0\"}function S5(){return\"segment ids are not increasing\"}function I5(r,t){return`Segment id ${r} out of range [0, ${t}), possibly because segmentIds input is not sorted.`}function v5(r,t,e){return`Bad: indices[${r}] == ${t} out of range [0, ${e})`}var lS={};qe(lS,{collectGatherOpShapeInfo:()=>T5,computeOutShape:()=>N5,segOpComputeOptimalWindowSize:()=>k5});function k5(r,t){let e=!1,o;for(r<=uf?(o=r,e=!0):o=Xp(r,Math.floor(Math.sqrt(r)));!e;)o>t||o===r?e=!0:o=Xp(r,o+1);return o}function N5(r,t,e){let o=[],n=r.length;for(let s=0;sn))throw new Error(`Expect batchDims in the range of [-${n}, ${n}], but got ${o}`);if(o<0&&(o+=n),o>s)throw new Error(`batchDims (${o}) must be less than rank(x) (\n ${s}).`);if(esc(t))}catch(t){throw new Error(`Failed to decode encoded string bytes into utf-8, error: ${t}`)}}function $5(r){return r.map(t=>tu(t))}var Wt={};qe(Wt,{nonMaxSuppressionV3Impl:()=>ef,nonMaxSuppressionV4Impl:()=>tf,nonMaxSuppressionV5Impl:()=>rf,whereImpl:()=>Yd});UN();var E5=A();E5.registerFlag(\"KEEP_INTERMEDIATE_TENSORS\",()=>!1,r=>{r&&console.warn(\"Keep intermediate tensors is ON. This will print the values of all intermediate tensors during model inference. Not all models support this mode. For details, check e2e/benchmarks/ model_config.js. This significantly impacts performance.\")});var ho;(function(r){r[r.DT_INVALID=0]=\"DT_INVALID\",r[r.DT_FLOAT=1]=\"DT_FLOAT\",r[r.DT_DOUBLE=2]=\"DT_DOUBLE\",r[r.DT_INT32=3]=\"DT_INT32\",r[r.DT_UINT8=4]=\"DT_UINT8\",r[r.DT_INT16=5]=\"DT_INT16\",r[r.DT_INT8=6]=\"DT_INT8\",r[r.DT_STRING=7]=\"DT_STRING\",r[r.DT_COMPLEX64=8]=\"DT_COMPLEX64\",r[r.DT_INT64=9]=\"DT_INT64\",r[r.DT_BOOL=10]=\"DT_BOOL\",r[r.DT_QINT8=11]=\"DT_QINT8\",r[r.DT_QUINT8=12]=\"DT_QUINT8\",r[r.DT_QINT32=13]=\"DT_QINT32\",r[r.DT_BFLOAT16=14]=\"DT_BFLOAT16\",r[r.DT_QINT16=15]=\"DT_QINT16\",r[r.DT_QUINT16=16]=\"DT_QUINT16\",r[r.DT_UINT16=17]=\"DT_UINT16\",r[r.DT_COMPLEX128=18]=\"DT_COMPLEX128\",r[r.DT_HALF=19]=\"DT_HALF\",r[r.DT_RESOURCE=20]=\"DT_RESOURCE\",r[r.DT_VARIANT=21]=\"DT_VARIANT\",r[r.DT_UINT32=22]=\"DT_UINT32\",r[r.DT_UINT64=23]=\"DT_UINT64\",r[r.DT_FLOAT_REF=101]=\"DT_FLOAT_REF\",r[r.DT_DOUBLE_REF=102]=\"DT_DOUBLE_REF\",r[r.DT_INT32_REF=103]=\"DT_INT32_REF\",r[r.DT_UINT8_REF=104]=\"DT_UINT8_REF\",r[r.DT_INT16_REF=105]=\"DT_INT16_REF\",r[r.DT_INT8_REF=106]=\"DT_INT8_REF\",r[r.DT_STRING_REF=107]=\"DT_STRING_REF\",r[r.DT_COMPLEX64_REF=108]=\"DT_COMPLEX64_REF\",r[r.DT_INT64_REF=109]=\"DT_INT64_REF\",r[r.DT_BOOL_REF=110]=\"DT_BOOL_REF\",r[r.DT_QINT8_REF=111]=\"DT_QINT8_REF\",r[r.DT_QUINT8_REF=112]=\"DT_QUINT8_REF\",r[r.DT_QINT32_REF=113]=\"DT_QINT32_REF\",r[r.DT_BFLOAT16_REF=114]=\"DT_BFLOAT16_REF\",r[r.DT_QINT16_REF=115]=\"DT_QINT16_REF\",r[r.DT_QUINT16_REF=116]=\"DT_QUINT16_REF\",r[r.DT_UINT16_REF=117]=\"DT_UINT16_REF\",r[r.DT_COMPLEX128_REF=118]=\"DT_COMPLEX128_REF\",r[r.DT_HALF_REF=119]=\"DT_HALF_REF\",r[r.DT_RESOURCE_REF=120]=\"DT_RESOURCE_REF\",r[r.DT_VARIANT_REF=121]=\"DT_VARIANT_REF\",r[r.DT_UINT32_REF=122]=\"DT_UINT32_REF\",r[r.DT_UINT64_REF=123]=\"DT_UINT64_REF\"})(ho||(ho={}));var gT;(function(r){let t;(function(e){e[e.LEGACY=0]=\"LEGACY\",e[e.V1=1]=\"V1\",e[e.V2=2]=\"V2\"})(t=r.CheckpointFormatVersion||(r.CheckpointFormatVersion={}))})(gT||(gT={}));var dS={};function D5(r,t){let e={tfOpName:r,category:\"custom\",inputs:[],attrs:[],customExecutor:t};dS[r]=e}function pf(r){return dS[r]}function A5(r){delete dS[r]}function I(r,t,e,o,n){let s=t.inputParams[r];if(s&&s.inputIndexStart!==void 0){let i=s.inputIndexStart,p=s.inputIndexEnd===0?void 0:s.inputIndexEnd===void 0?i+1:s.inputIndexEnd,u=i<0?t.inputNames.length+i:i;if(s.type===\"tensor\")return zt(t.inputNames[u],e,o,n);if(s.type===\"tensors\"){let m=t.inputs.slice(i,p);return t.inputNames.slice(i,p).filter((f,h)=>{var g;return((g=m[h])===null||g===void 0?void 0:g.op)!==\"NoOp\"}).map(f=>zt(f,e,o,n))}let c=zt(t.inputNames[u],e,o,n),l=c.dataSync();return s.type===\"number\"?l[0]:y.toNestedArray(c.shape,l)}let a=t.attrParams[r];return a&&a.value}function zt(r,t,e,o){let[n,s]=Tr(r,e);if(o!=null){let i=o.getHashTableHandleByName(n);if(i!=null)return i}let a=e.currentContextIds.find(i=>!!t[cf(n,i)]);return a!==void 0?t[cf(n,a)][s]:void 0}function fS(r,t,e){return t[cf(r,e.currentContextId)]}function Ls(r,t){let[e,o,n]=Tr(r,t);return[cf(e,t&&t.currentContextId),o,n]}function cf(r,t){return t?`${r}-${t}`:r}function Tr(r,t){if(r===\"\")return[\"\",0,void 0];let e=t!=null&&t.parseNodeNameCache!=null;if(e){let s=t.parseNodeNameCache.get(r);if(s!=null)return s}let o=r.split(\":\"),n;if(o.length===1)n=[r,0,void 0];else{let s=o[0],a=o.length===3?o[1]:void 0,i=Number(o[o.length-1]);n=[s,i,a]}return e&&t.parseNodeNameCache.set(r,n),n}function Ol(r,t,e){let o=I(\"pad\",r,t,e);if(o===\"explicit\"){o=I(\"explicitPaddings\",r,t,e);let n=[[0,0],[0,0],[0,0],[0,0]];for(let s=0;s<4;s++)n[s][0]=o[s*2],n[s][1]=o[s*2+1];return n}return o}function Bs(r){return r.kept?r:Ur(r)}var hS={};qe(hS,{json:()=>F5});var F5=[{tfOpName:\"Add\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"AddV2\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"AddN\",category:\"arithmetic\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}]},{tfOpName:\"BiasAdd\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"Sub\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"RealDiv\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Div\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"DivNoNan\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"FloorDiv\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Mul\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Maximum\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Minimum\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Pow\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"SquaredDifference\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Mod\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"FloorMod\",category:\"arithmetic\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]}];var gS={};qe(gS,{json:()=>P5});var P5=[{tfOpName:\"Abs\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Acos\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Asin\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Atan\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Atan2\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"y\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Ceil\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ClipByValue\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"clipValueMin\",type:\"number\"},{start:2,name:\"clipValueMax\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Complex\",category:\"basic_math\",inputs:[{start:0,name:\"real\",type:\"tensor\"},{start:1,name:\"imag\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ComplexAbs\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Cos\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Cosh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Elu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Exp\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Floor\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Log\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Imag\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"outputType\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Neg\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Real\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"outputType\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Prelu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"alpha\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Relu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Relu6\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Selu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sigmoid\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sin\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sinh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sqrt\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Rsqrt\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Square\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Tan\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Tanh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Sign\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Round\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Expm1\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Log1p\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Reciprocal\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Softplus\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Asinh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Acosh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Atanh\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Erf\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LeakyRelu\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"alpha\",name:\"alpha\",type:\"number\",defaultValue:.2},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"IsNan\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"IsFinite\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"IsInf\",category:\"basic_math\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]}];var xS={};qe(xS,{json:()=>O5});var O5=[{tfOpName:\"EmptyTensorList\",category:\"control\",inputs:[{start:0,name:\"elementShape\",type:\"shape\"},{start:1,name:\"maxNumElements\",type:\"number\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"LoopCond\",category:\"control\",inputs:[{start:0,name:\"pred\",type:\"tensor\"}]},{tfOpName:\"Switch\",category:\"control\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"pred\",type:\"tensor\"}]},{tfOpName:\"Merge\",category:\"control\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}]},{tfOpName:\"Enter\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"frame_name\",name:\"frameName\",type:\"string\"},{tfName:\"is_constant\",name:\"isConstant\",type:\"bool\"}]},{tfOpName:\"Exit\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"NextIteration\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"TensorArrayV3\",category:\"control\",inputs:[{start:0,name:\"size\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"},{tfName:\"dynamic_size\",name:\"dynamicSize\",type:\"bool\"},{tfName:\"clear_after_read\",name:\"clearAfterRead\",type:\"bool\"},{tfName:\"identical_element_shapes\",name:\"identicalElementShapes\",type:\"bool\"},{tfName:\"tensor_array_name\",name:\"name\",type:\"string\"}]},{tfOpName:\"TensorArrayWriteV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"tensor\",type:\"tensor\"},{start:3,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"TensorArrayReadV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"TensorArrayGatherV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"}]},{tfOpName:\"TensorArrayScatterV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"tensor\",type:\"tensor\"},{start:3,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"TensorArrayConcatV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"element_shape_except0\",name:\"elementShapeExcept0\",type:\"shape\",notSupported:!0}]},{tfOpName:\"TensorArraySplitV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"tensor\",type:\"tensor\"},{start:2,name:\"lengths\",type:\"number[]\"},{start:3,name:\"flowIn\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"TensorArraySizeV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"},{start:1,name:\"flowIn\",type:\"number\"}]},{tfOpName:\"TensorArrayCloseV3\",category:\"control\",inputs:[{start:0,name:\"tensorArrayId\",type:\"tensor\"}]},{tfOpName:\"StatelessIf\",category:\"control\",inputs:[{start:0,name:\"cond\",type:\"tensor\"},{start:1,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"then_branch\",name:\"thenBranch\",type:\"func\"},{tfName:\"else_branch\",name:\"elseBranch\",type:\"func\"}]},{tfOpName:\"If\",category:\"control\",inputs:[{start:0,name:\"cond\",type:\"tensor\"},{start:1,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"then_branch\",name:\"thenBranch\",type:\"func\"},{tfName:\"else_branch\",name:\"elseBranch\",type:\"func\"}]},{tfOpName:\"StatelessWhile\",category:\"control\",inputs:[{start:0,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"cond\",name:\"cond\",type:\"func\"},{tfName:\"body\",name:\"body\",type:\"func\"}]},{tfOpName:\"While\",category:\"control\",inputs:[{start:0,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"cond\",name:\"cond\",type:\"func\"},{tfName:\"body\",name:\"body\",type:\"func\"}]},{tfOpName:\"TensorListScatter\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListScatterV2\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"elementShape\",type:\"shape\"},{start:3,name:\"numElements\",type:\"number\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListGather\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"indices\",type:\"number[]\"},{start:2,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListGetItem\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListSetItem\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"index\",type:\"number\"},{start:2,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListReserve\",category:\"control\",inputs:[{start:0,name:\"elementShape\",type:\"shape\"},{start:1,name:\"numElements\",type:\"number\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListFromTensor\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListStack\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"},{tfName:\"num_elements\",name:\"numElements\",type:\"dtype\"}]},{tfOpName:\"TensorListSplit\",category:\"control\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"},{start:2,name:\"lengths\",type:\"number[]\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListConcat\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"}],attrs:[{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"},{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListConcatV2\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"}],attrs:[{tfName:\"element_shape\",name:\"elementShape\",type:\"shape\"},{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListPopBack\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"elementShape\",type:\"shape\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListPushBack\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"element_dtype\",name:\"elementDType\",type:\"dtype\"}]},{tfOpName:\"TensorListLength\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"}]},{tfOpName:\"TensorListResize\",category:\"control\",inputs:[{start:0,name:\"tensorListId\",type:\"tensor\"},{start:1,name:\"size\",type:\"number\"}]}];var yS={};qe(yS,{json:()=>M5});var M5=[{tfOpName:\"AvgPool\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MaxPool\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[],notSupported:!0},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MaxPoolWithArgmax\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"include_batch_in_index\",name:\"includeBatchInIndex\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"AvgPool3D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MaxPool3D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"ksize\",name:\"kernelSize\",type:\"number[]\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Conv1D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"stride\",name:\"stride\",type:\"number\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NWC\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"dilation\",name:\"dilation\",type:\"number\",defaultValue:1}]},{tfOpName:\"Conv2D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"useCudnnOnGpu\",name:\"useCudnnOnGpu\",type:\"bool\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"_FusedConv2D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"},{start:2,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"num_args\",name:\"numArgs\",type:\"number\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"use_cudnn_on_gpu\",name:\"useCudnnOnGpu\",type:\"bool\",defaultValue:!0},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\",defaultValue:[1,1,1,1]},{tfName:\"fused_ops\",name:\"fusedOps\",type:\"string[]\",defaultValue:[]},{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:1e-4},{tfName:\"leakyrelu_alpha\",name:\"leakyreluAlpha\",type:\"number\",defaultValue:.2}]},{tfOpName:\"Conv2DBackpropInput\",category:\"convolution\",inputs:[{start:2,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"},{start:0,name:\"outputShape\",type:\"number[]\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\",notSupported:!0}]},{tfOpName:\"DepthwiseConv2d\",category:\"convolution\",inputs:[{start:0,name:\"input\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"DepthwiseConv2dNative\",category:\"convolution\",inputs:[{start:0,name:\"input\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"FusedDepthwiseConv2dNative\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"},{start:2,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"num_args\",name:\"numArgs\",type:\"number\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\",defaultValue:[1,1,1,1]},{tfName:\"fused_ops\",name:\"fusedOps\",type:\"string[]\",defaultValue:[]},{tfName:\"explicit_paddings\",name:\"explicitPaddings\",type:\"number[]\",defaultValue:[]}]},{tfOpName:\"Conv3D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",defaultValue:\"NHWC\"},{tfName:\"dilations\",name:\"dilations\",type:\"number[]\"}]},{tfOpName:\"Dilation2D\",category:\"convolution\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"filter\",type:\"tensor\"}],attrs:[{tfName:\"strides\",name:\"strides\",type:\"number[]\"},{tfName:\"rates\",name:\"dilations\",type:\"number[]\"},{tfName:\"padding\",name:\"pad\",type:\"string\"}]}];var bS={};qe(bS,{json:()=>L5});var L5=[{tfOpName:\"Fill\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"},{start:1,name:\"value\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"LinSpace\",category:\"creation\",inputs:[{start:0,name:\"start\",type:\"number\"},{start:1,name:\"stop\",type:\"number\"},{start:2,name:\"num\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"OneHot\",category:\"creation\",inputs:[{start:0,name:\"indices\",type:\"tensor\"},{start:1,name:\"depth\",type:\"number\"},{start:2,name:\"onValue\",type:\"number\",defaultValue:1},{start:3,name:\"offValue\",type:\"number\",defaultValue:0}],attrs:[{tfName:\"axis\",name:\"axis\",type:\"number\",notSupported:!0},{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Ones\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"OnesLike\",category:\"creation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"RandomStandardNormal\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"seed\",name:\"seed\",type:\"number\",defaultValue:0},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"T\",name:\"T\",type:\"number\",notSupported:!0}]},{tfOpName:\"RandomUniform\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"minval\",name:\"minval\",type:\"number\",defaultValue:0},{tfName:\"maxval\",name:\"maxval\",type:\"number\",defaultValue:1},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"seed\",name:\"seed\",type:\"number\",defaultValue:0},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0},{tfName:\"T\",name:\"T\",type:\"number\",notSupported:!0}]},{tfOpName:\"RandomUniformInt\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"minval\",name:\"minval\",type:\"number\"},{tfName:\"maxval\",name:\"maxval\",type:\"number\"},{tfName:\"seed\",name:\"seed\",type:\"number\",defaultValue:0},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0}]},{tfOpName:\"Range\",category:\"creation\",inputs:[{start:0,name:\"start\",type:\"number\"},{start:1,name:\"stop\",type:\"number\"},{start:2,name:\"step\",type:\"number\",defaultValue:0}],attrs:[{tfName:\"Tidx\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"TruncatedNormal\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"means\",name:\"mean\",type:\"number\",defaultValue:0},{tfName:\"stddev\",name:\"stdDev\",type:\"number\",defaultValue:1},{tfName:\"seed\",name:\"seed\",type:\"number\"},{tfName:\"seed2\",name:\"seed2\",type:\"number\",defaultValue:0,notSupported:!0},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"},{tfName:\"T\",name:\"T\",type:\"number\",notSupported:!0}]},{tfOpName:\"Zeros\",category:\"creation\",inputs:[{start:0,name:\"shape\",type:\"number[]\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"ZerosLike\",category:\"creation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Multinomial\",category:\"creation\",inputs:[{start:0,name:\"logits\",type:\"tensor\"},{start:1,name:\"numSamples\",type:\"number\"}],attrs:[{tfName:\"seed\",name:\"seed\",type:\"number\"},{tfName:\"seed2\",name:\"seed2\",type:\"number\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\"},{tfName:\"output_dtype\",name:\"output_dtype\",type:\"dtype\"}]}];var CS={};qe(CS,{json:()=>B5});var B5=[{tfOpName:\"NonMaxSuppressionV2\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"}]},{tfOpName:\"NonMaxSuppressionV3\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"},{start:4,name:\"scoreThreshold\",type:\"number\"}]},{tfOpName:\"NonMaxSuppressionV4\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"},{start:4,name:\"scoreThreshold\",type:\"number\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0},{tfName:\"T_threshold\",name:\"threshold\",type:\"dtype\",notSupported:!0},{tfName:\"pad_to_max_output_size\",name:\"padToMaxOutputSize\",type:\"bool\"}]},{tfOpName:\"NonMaxSuppressionV5\",category:\"dynamic\",inputs:[{start:0,name:\"boxes\",type:\"tensor\"},{start:1,name:\"scores\",type:\"tensor\"},{start:2,name:\"maxOutputSize\",type:\"number\"},{start:3,name:\"iouThreshold\",type:\"number\"},{start:4,name:\"scoreThreshold\",type:\"number\"},{start:5,name:\"softNmsSigma\",type:\"number\"}]},{tfOpName:\"Where\",category:\"dynamic\",inputs:[{start:0,name:\"condition\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ListDiff\",category:\"dynamic\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"y\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]}];var wS={};qe(wS,{json:()=>z5});var z5=[{tfOpName:\"LowerBound\",category:\"evaluation\",inputs:[{start:0,name:\"sortedSequence\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"}]},{tfOpName:\"TopKV2\",category:\"evaluation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"k\",type:\"number\"}],attrs:[{tfName:\"sorted\",name:\"sorted\",type:\"bool\"}]},{tfOpName:\"UpperBound\",category:\"evaluation\",inputs:[{start:0,name:\"sortedSequence\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"}]},{tfOpName:\"Unique\",category:\"evaluation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"UniqueV2\",category:\"evaluation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]}];var SS={};qe(SS,{json:()=>V5});var V5=[{tfOpName:\"PlaceholderWithDefault\",category:\"graph\",inputs:[{start:0,name:\"default\",type:\"tensor\"}],attrs:[{tfName:\"shape\",name:\"shape\",type:\"shape\"},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Placeholder\",category:\"graph\",attrs:[{tfName:\"shape\",name:\"shape\",type:\"shape\"},{tfName:\"dtype\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"Const\",category:\"graph\"},{tfOpName:\"Identity\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"IdentityN\",category:\"graph\",inputs:[{start:0,end:0,name:\"x\",type:\"tensors\"}]},{tfOpName:\"Snapshot\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"Rank\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"Size\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"Shape\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"ShapeN\",category:\"graph\",inputs:[{start:0,end:0,name:\"x\",type:\"tensors\"}]},{tfOpName:\"Print\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"data\",type:\"tensors\"}],attrs:[{tfName:\"message\",name:\"message\",type:\"string\"},{tfName:\"first_n\",name:\"firstN\",type:\"number\",notSupported:!0},{tfName:\"summarize\",name:\"summarize\",type:\"number\",defaultValue:3}]},{tfOpName:\"NoOp\",category:\"graph\",inputs:[]},{tfOpName:\"StopGradient\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"FakeQuantWithMinMaxVars\",category:\"graph\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"min\",name:\"min\",type:\"number\"},{tfName:\"max\",name:\"max\",type:\"number\"}]}];var IS={};qe(IS,{json:()=>W5});var W5=[{tfOpName:\"HashTable\",category:\"hash_table\",inputs:[],attrs:[{tfName:\"shared_name\",name:\"sharedName\",type:\"string\"},{tfName:\"use_node_name_sharing\",name:\"useNodeNameSharing\",type:\"bool\"},{tfName:\"key_dtype\",name:\"keyDType\",type:\"dtype\"},{tfName:\"value_dtype\",name:\"valueDType\",type:\"dtype\"}]},{tfOpName:\"HashTableV2\",category:\"hash_table\",inputs:[],attrs:[{tfName:\"shared_name\",name:\"sharedName\",type:\"string\"},{tfName:\"use_node_name_sharing\",name:\"useNodeNameSharing\",type:\"bool\"},{tfName:\"key_dtype\",name:\"keyDType\",type:\"dtype\"},{tfName:\"value_dtype\",name:\"valueDType\",type:\"dtype\"}]},{tfOpName:\"LookupTableImport\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableImportV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableFind\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"defaultValue\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableFindV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"defaultValue\",type:\"tensor\"}],attrs:[{tfName:\"Tin\",name:\"tIn\",type:\"dtype\",notSupported:!0},{tfName:\"Tout\",name:\"tOut\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LookupTableSize\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"}]},{tfOpName:\"LookupTableSizeV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"}]},{tfOpName:\"InitializeTable\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}]},{tfOpName:\"InitializeTableV2\",category:\"hash_table\",inputs:[{start:0,name:\"tableHandle\",type:\"tensor\"},{start:1,name:\"keys\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}]}];var vS={};qe(vS,{json:()=>U5});var U5=[{tfOpName:\"ResizeBilinear\",category:\"image\",inputs:[{start:0,name:\"images\",type:\"tensor\"},{start:1,name:\"size\",type:\"number[]\"}],attrs:[{tfName:\"align_corners\",name:\"alignCorners\",type:\"bool\"},{tfName:\"half_pixel_centers\",name:\"halfPixelCenters\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"ResizeNearestNeighbor\",category:\"image\",inputs:[{start:0,name:\"images\",type:\"tensor\"},{start:1,name:\"size\",type:\"number[]\"}],attrs:[{tfName:\"align_corners\",name:\"alignCorners\",type:\"bool\"},{tfName:\"half_pixel_centers\",name:\"halfPixelCenters\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"CropAndResize\",category:\"image\",inputs:[{start:0,name:\"image\",type:\"tensor\"},{start:1,name:\"boxes\",type:\"tensor\"},{start:2,name:\"boxInd\",type:\"tensor\"},{start:3,name:\"cropSize\",type:\"number[]\"}],attrs:[{tfName:\"method\",name:\"method\",type:\"string\"},{tfName:\"extrapolation_value\",name:\"extrapolationValue\",type:\"number\"}]},{tfOpName:\"ImageProjectiveTransformV3\",category:\"image\",inputs:[{start:0,name:\"images\",type:\"tensor\"},{start:1,name:\"transforms\",type:\"tensor\"},{start:2,name:\"outputShape\",type:\"number[]\"},{start:3,name:\"fillValue\",type:\"number\"}],attrs:[{tfName:\"interpolation\",name:\"interpolation\",type:\"string\"},{tfName:\"fill_mode\",name:\"fillMode\",type:\"string\"}]}];var kS={};qe(kS,{json:()=>G5});var G5=[{tfOpName:\"Equal\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"NotEqual\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Greater\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"GreaterEqual\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Less\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LessEqual\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LogicalAnd\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LogicalNot\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"LogicalOr\",category:\"logical\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Select\",category:\"logical\",inputs:[{start:0,name:\"condition\",type:\"tensor\"},{start:1,name:\"a\",type:\"tensor\"},{start:2,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"SelectV2\",category:\"logical\",inputs:[{start:0,name:\"condition\",type:\"tensor\"},{start:1,name:\"a\",type:\"tensor\"},{start:2,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"BitwiseAnd\",category:\"logical\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"y\",type:\"tensor\"}]}];var NS={};qe(NS,{json:()=>H5});var H5=[{tfOpName:\"_FusedMatMul\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"},{start:2,end:0,name:\"args\",type:\"tensors\"}],attrs:[{tfName:\"num_args\",name:\"numArgs\",type:\"number\"},{tfName:\"fused_ops\",name:\"fusedOps\",type:\"string[]\",defaultValue:[]},{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:1e-4},{tfName:\"transpose_a\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"transpose_b\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"leakyrelu_alpha\",name:\"leakyreluAlpha\",type:\"number\",defaultValue:.2},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"MatMul\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"transpose_a\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"transpose_b\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"BatchMatMul\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"adj_x\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"adj_y\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"BatchMatMulV2\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"b\",type:\"tensor\"}],attrs:[{tfName:\"adj_x\",name:\"transposeA\",type:\"bool\",defaultValue:!1},{tfName:\"adj_y\",name:\"transposeB\",type:\"bool\",defaultValue:!1},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Transpose\",category:\"matrices\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"perm\",type:\"number[]\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Einsum\",category:\"matrices\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}],attrs:[{tfName:\"equation\",name:\"equation\",type:\"string\"},{tfName:\"N\",name:\"n\",type:\"number\",defaultValue:2},{tfName:\"T\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"MatrixBandPart\",category:\"matrices\",inputs:[{start:0,name:\"a\",type:\"tensor\"},{start:1,name:\"numLower\",type:\"tensor\"},{start:1,name:\"numUpper\",type:\"tensor\"}]}];var TS={};qe(TS,{json:()=>K5});var K5=[{tfOpName:\"EuclideanNorm\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\",defaultValue:!1}]},{tfOpName:\"FusedBatchNorm\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"scale\",type:\"tensor\"},{start:2,name:\"offset\",type:\"tensor\"},{start:3,name:\"mean\",type:\"tensor\"},{start:4,name:\"variance\",type:\"tensor\"}],attrs:[{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:.001},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"FusedBatchNormV2\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"scale\",type:\"tensor\"},{start:2,name:\"offset\",type:\"tensor\"},{start:3,name:\"mean\",type:\"tensor\"},{start:4,name:\"variance\",type:\"tensor\"}],attrs:[{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:.001},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"FusedBatchNormV3\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"scale\",type:\"tensor\"},{start:2,name:\"offset\",type:\"tensor\"},{start:3,name:\"mean\",type:\"tensor\"},{start:4,name:\"variance\",type:\"tensor\"}],attrs:[{tfName:\"epsilon\",name:\"epsilon\",type:\"number\",defaultValue:.001},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\",notSupported:!0}]},{tfOpName:\"LRN\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"depth_radius\",name:\"radius\",type:\"number\",defaultValue:5},{tfName:\"bias\",name:\"bias\",type:\"number\",defaultValue:1},{tfName:\"alpha\",name:\"alpha\",type:\"number\",defaultValue:1},{tfName:\"beta\",name:\"beta\",type:\"number\",defaultValue:.5}]},{tfOpName:\"Softmax\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"LogSoftmax\",category:\"normalization\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]}];var _S={};qe(_S,{json:()=>q5});var q5=[{tfOpName:\"Bincount\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"size\",type:\"number\"},{start:2,name:\"weights\",type:\"tensor\"}]},{tfOpName:\"DenseBincount\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"size\",type:\"number\"},{start:2,name:\"weights\",type:\"tensor\"}],attrs:[{tfName:\"binary_output\",name:\"binaryOutput\",type:\"bool\"}]},{tfOpName:\"Max\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Mean\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Min\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Sum\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"All\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"Any\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"}]},{tfOpName:\"ArgMax\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]},{tfOpName:\"ArgMin\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]},{tfOpName:\"Prod\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}],attrs:[{tfName:\"keep_dims\",name:\"keepDims\",type:\"bool\"},{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"Cumprod\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"exclusive\",name:\"exclusive\",type:\"bool\"},{tfName:\"reverse\",name:\"reverse\",type:\"bool\"}]},{tfOpName:\"Cumsum\",category:\"reduction\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"exclusive\",name:\"exclusive\",type:\"bool\"},{tfName:\"reverse\",name:\"reverse\",type:\"bool\"}]}];var $S={};qe($S,{json:()=>j5});var j5=[{tfOpName:\"ConcatV2\",category:\"slice_join\",inputs:[{start:0,end:-1,name:\"tensors\",type:\"tensors\"},{start:-1,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"N\",name:\"n\",type:\"number\",defaultValue:2}]},{tfOpName:\"Concat\",category:\"slice_join\",inputs:[{start:1,end:0,name:\"tensors\",type:\"tensors\"},{start:0,name:\"axis\",type:\"number\"}],attrs:[{tfName:\"N\",name:\"n\",type:\"number\",defaultValue:2}]},{tfOpName:\"GatherV2\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"axis\",type:\"number\",defaultValue:0}],attrs:[{tfName:\"batch_dims\",name:\"batchDims\",type:\"number\",defaultValue:0}]},{tfOpName:\"Gather\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"}],attrs:[{tfName:\"validate_indices\",name:\"validateIndices\",type:\"bool\",notSupported:!0}]},{tfOpName:\"Reverse\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"dims\",type:\"bool[]\"}]},{tfOpName:\"ReverseV2\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number[]\"}]},{tfOpName:\"Slice\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"begin\",type:\"number[]\"},{start:2,name:\"size\",type:\"number[]\"}]},{tfOpName:\"StridedSlice\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"begin\",type:\"number[]\"},{start:2,name:\"end\",type:\"number[]\"},{start:3,name:\"strides\",type:\"number[]\"}],attrs:[{tfName:\"begin_mask\",name:\"beginMask\",type:\"number\",defaultValue:0},{tfName:\"end_mask\",name:\"endMask\",type:\"number\",defaultValue:0},{tfName:\"new_axis_mask\",name:\"newAxisMask\",type:\"number\",defaultValue:0},{tfName:\"ellipsis_mask\",name:\"ellipsisMask\",type:\"number\",defaultValue:0},{tfName:\"shrink_axis_mask\",name:\"shrinkAxisMask\",type:\"number\",defaultValue:0}]},{tfOpName:\"Pack\",category:\"slice_join\",inputs:[{start:0,end:0,name:\"tensors\",type:\"tensors\"}],attrs:[{tfName:\"axis\",name:\"axis\",type:\"number\",defaultValue:0}]},{tfOpName:\"Unpack\",category:\"slice_join\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"}],attrs:[{tfName:\"axis\",name:\"axis\",type:\"number\",defaultValue:0},{tfName:\"num\",name:\"num\",type:\"number\",defaultValue:0,notSupported:!0}]},{tfOpName:\"Tile\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"reps\",type:\"number[]\"}]},{tfOpName:\"Split\",category:\"slice_join\",inputs:[{start:0,name:\"axis\",type:\"number\",defaultValue:0},{start:1,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"num_split\",name:\"numOrSizeSplits\",type:\"number\",defaultValue:1}]},{tfOpName:\"SplitV\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"numOrSizeSplits\",type:\"number[]\"},{start:2,name:\"axis\",type:\"number\",defaultValue:0}]},{tfOpName:\"ScatterNd\",category:\"slice_join\",inputs:[{start:0,name:\"indices\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"},{start:2,name:\"shape\",type:\"number[]\"}]},{tfOpName:\"GatherNd\",category:\"slice_join\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"}]},{tfOpName:\"SparseToDense\",category:\"slice_join\",inputs:[{start:0,name:\"sparseIndices\",type:\"tensor\"},{start:1,name:\"outputShape\",type:\"number[]\"},{start:2,name:\"sparseValues\",type:\"tensor\"},{start:3,name:\"defaultValue\",type:\"tensor\"}],attrs:[{tfName:\"validate_indices\",name:\"validateIndices\",type:\"bool\",defaultValue:!1,notSupported:!0}]},{tfOpName:\"TensorScatterUpdate\",category:\"slice_join\",inputs:[{start:0,name:\"tensor\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"values\",type:\"tensor\"}]}];var ES={};qe(ES,{json:()=>X5});var X5=[{tfOpName:\"SparseFillEmptyRows\",category:\"sparse\",inputs:[{start:0,name:\"indices\",type:\"tensor\"},{start:1,name:\"values\",type:\"tensor\"},{start:2,name:\"denseShape\",type:\"tensor\"},{start:3,name:\"defaultValue\",type:\"tensor\"}]},{tfOpName:\"SparseReshape\",category:\"sparse\",inputs:[{start:0,name:\"inputIndices\",type:\"tensor\"},{start:1,name:\"inputShape\",type:\"tensor\"},{start:2,name:\"newShape\",type:\"tensor\"}],attrs:[{tfName:\"T\",name:\"dtype\",type:\"dtype\",notSupported:!0}]},{tfOpName:\"SparseSegmentMean\",category:\"sparse\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"segmentIds\",type:\"tensor\"}]},{tfOpName:\"SparseSegmentSum\",category:\"sparse\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"indices\",type:\"tensor\"},{start:2,name:\"segmentIds\",type:\"tensor\"}]}];var RS={};qe(RS,{json:()=>Y5});var Y5=[{tfOpName:\"FFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"IFFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"}]},{tfOpName:\"RFFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"fft_length\",type:\"number\",notSupported:!0}]},{tfOpName:\"IRFFT\",category:\"spectral\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"fft_length\",type:\"number\",notSupported:!0}]}];var DS={};qe(DS,{json:()=>Q5});var Q5=[{tfOpName:\"StaticRegexReplace\",category:\"string\",inputs:[{start:0,name:\"input\",type:\"tensor\"}],attrs:[{tfName:\"pattern\",name:\"pattern\",type:\"string\"},{tfName:\"rewrite\",name:\"rewrite\",type:\"string\"},{tfName:\"replace_global\",name:\"replaceGlobal\",type:\"bool\"}]},{tfOpName:\"StringNGrams\",category:\"string\",inputs:[{start:0,name:\"data\",type:\"tensor\"},{start:1,name:\"dataSplits\",type:\"tensor\"}],attrs:[{tfName:\"separator\",name:\"separator\",type:\"string\"},{tfName:\"ngram_widths\",name:\"nGramWidths\",type:\"number[]\"},{tfName:\"left_pad\",name:\"leftPad\",type:\"string\"},{tfName:\"right_pad\",name:\"rightPad\",type:\"string\"},{tfName:\"pad_width\",name:\"padWidth\",type:\"number\"},{tfName:\"preserve_short_sequences\",name:\"preserveShortSequences\",type:\"bool\"}],outputs:[\"ngrams\",\"ngrams_splits\"]},{tfOpName:\"StringSplit\",category:\"string\",inputs:[{start:0,name:\"input\",type:\"tensor\"},{start:1,name:\"delimiter\",type:\"tensor\"}],attrs:[{tfName:\"skip_empty\",name:\"skipEmpty\",type:\"bool\"}],outputs:[\"indices\",\"values\",\"shape\"]},{tfOpName:\"StringToHashBucketFast\",category:\"string\",inputs:[{start:0,name:\"input\",type:\"tensor\"}],attrs:[{tfName:\"num_buckets\",name:\"numBuckets\",type:\"number\"}]}];var AS={};qe(AS,{json:()=>Z5});var Z5=[{tfOpName:\"Cast\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"SrcT\",name:\"sdtype\",type:\"dtype\",notSupported:!0},{tfName:\"DstT\",name:\"dtype\",type:\"dtype\"}]},{tfOpName:\"ExpandDims\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"axis\",type:\"number\"}]},{tfOpName:\"MirrorPad\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"padding\",type:\"number[]\"}],attrs:[{tfName:\"mode\",name:\"mode\",type:\"string\"}]},{tfOpName:\"Pad\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"padding\",type:\"number[]\"}],attrs:[{tfName:\"constant_value\",name:\"constantValue\",type:\"number\",defaultValue:0}]},{tfOpName:\"PadV2\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"padding\",type:\"number[]\"},{start:2,name:\"constantValue\",type:\"number\",defaultValue:0}]},{tfOpName:\"Reshape\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"shape\",type:\"number[]\"}]},{tfOpName:\"EnsureShape\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"shape\",type:\"number[]\"}]},{tfOpName:\"Squeeze\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"axis\",tfDeprecatedName:\"squeeze_dims\",name:\"axis\",type:\"number[]\"}]},{tfOpName:\"SpaceToBatchND\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"blockShape\",type:\"number[]\"},{start:2,name:\"paddings\",type:\"number[]\"}]},{tfOpName:\"BatchToSpaceND\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"blockShape\",type:\"number[]\"},{start:2,name:\"crops\",type:\"number[]\"}]},{tfOpName:\"DepthToSpace\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"}],attrs:[{tfName:\"block_size\",name:\"blockSize\",type:\"number\"},{tfName:\"data_format\",name:\"dataFormat\",type:\"string\"}]},{tfOpName:\"BroadcastTo\",category:\"transformation\",inputs:[{start:0,name:\"x\",type:\"tensor\"},{start:1,name:\"shape\",type:\"number[]\"}],attrs:[]},{tfOpName:\"BroadcastArgs\",category:\"transformation\",inputs:[{start:0,name:\"s0\",type:\"tensor\"},{start:1,name:\"s1\",type:\"tensor\"}],attrs:[]}];var Ml=class{static get Instance(){return this._instance||(this._instance=new this)}constructor(){let t=[hS,gS,xS,yS,bS,CS,wS,SS,IS,vS,kS,NS,TS,_S,$S,ES,RS,DS,AS],e=[].concat(...t.map(o=>o.json));this.opMappers=e.reduce((o,n)=>(o[n.tfOpName]=n,o),{})}transformGraph(t,e={}){let o=t.node,n=[],s=[],a=[],i=o.reduce((h,g)=>(h[g.name]=this.mapNode(g),g.op.startsWith(\"Placeholder\")?n.push(h[g.name]):g.op===\"Const\"?s.push(h[g.name]):(g.input==null||g.input.length===0)&&a.push(h[g.name]),h),{}),p=[],u=[],c={},l={};e!=null&&(c=this.mapSignatureEntries(e.inputs),l=this.mapSignatureEntries(e.outputs));let m=Object.keys(i);m.forEach(h=>{let g=i[h];g.inputNames.forEach((x,b)=>{let[C,,S]=Ls(x),k=i[C];if(k.outputs!=null){let _=k.outputs.indexOf(S);if(_!==-1){let E=`${C}:${_}`;g.inputNames[b]=E}}g.inputs.push(k),k.children.push(g)})}),Object.keys(l).length===0?m.forEach(h=>{let g=i[h];g.children.length===0&&u.push(g)}):Object.keys(l).forEach(h=>{let[g]=Ls(h),x=i[g];x!=null&&(x.signatureKey=l[h],u.push(x))}),Object.keys(c).length>0?Object.keys(c).forEach(h=>{let[g]=Ls(h),x=i[g];x&&(x.signatureKey=c[h],p.push(x))}):p=n;let d={};t.library!=null&&t.library.function!=null&&(d=t.library.function.reduce((h,g)=>(h[g.signature.name]=this.mapFunction(g),h),{}));let f={nodes:i,inputs:p,outputs:u,weights:s,placeholders:n,signature:e,functions:d};return a.length>0&&(f.initNodes=a),f}mapSignatureEntries(t){return Object.keys(t||{}).reduce((e,o)=>(e[t[o].name]=o,e),{})}mapNode(t){let e=pf(t.op)||this.opMappers[t.op]||{};t.attr==null&&(t.attr={});let o={name:t.name,op:t.op,category:e.category,inputNames:(t.input||[]).map(n=>n.startsWith(\"^\")?n.slice(1):n),inputs:[],children:[],inputParams:{},attrParams:{},rawAttrs:t.attr,outputs:e.outputs};return e.inputs!=null&&(o.inputParams=e.inputs.reduce((n,s)=>(n[s.name]={type:s.type,inputIndexStart:s.start,inputIndexEnd:s.end},n),{})),e.attrs!=null&&(o.attrParams=e.attrs.reduce((n,s)=>{let a=s.type,i;switch(s.type){case\"string\":i=lf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=lf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"string[]\":i=yf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=yf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"number\":i=df(t.attr,s.tfName,s.defaultValue||0),i===void 0&&s.tfDeprecatedName&&(i=df(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"number[]\":i=xf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=xf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"bool\":i=mf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=mf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"bool[]\":i=Cf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=Cf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"shape\":i=gf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=gf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"shape[]\":i=bf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=bf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"dtype\":i=ff(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=ff(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"dtype[]\":i=hf(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=hf(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"func\":i=xT(t.attr,s.tfName,s.defaultValue),i===void 0&&s.tfDeprecatedName&&(i=xT(t.attr,s.tfDeprecatedName,s.defaultValue));break;case\"tensor\":case\"tensors\":break;default:throw new Error(`Unsupported param type: ${s.type} for op: ${t.op}`)}return n[s.name]={value:i,type:a},n},{})),o}mapFunction(t){let e=t.nodeDef,o=[],n=[],s={};e!=null&&(s=e.reduce((l,m)=>(l[m.name]=this.mapNode(m),m.op===\"Const\"&&n.push(l[m.name]),l),{}));let a=[],i=[];t.signature.inputArg.forEach(l=>{let[m]=Ls(l.name),d={name:m,op:\"Placeholder\",inputs:[],inputNames:[],category:\"graph\",inputParams:{},attrParams:{dtype:{value:FS(l.type),type:\"dtype\"}},children:[]};d.signatureKey=l.name,a.push(d),s[m]=d}),Object.keys(s).forEach(l=>{let m=s[l];m.inputNames.forEach((d,f)=>{let[h,,g]=Ls(d),x=s[h];if(x.outputs!=null){let b=x.outputs.indexOf(g);if(b!==-1){let C=`${h}:${b}`;m.inputNames[f]=C}}m.inputs.push(x),x.children.push(m)})});let u=t.ret;t.signature.outputArg.forEach(l=>{let[m,d]=Ls(u[l.name]),f=s[m];f!=null&&(f.defaultOutput=d,i.push(f))});let c=this.mapArgsToSignature(t);return{nodes:s,inputs:a,outputs:i,weights:n,placeholders:o,signature:c}}mapArgsToSignature(t){return{methodName:t.signature.name,inputs:t.signature.inputArg.reduce((e,o)=>(e[o.name]=this.mapArgToTensorInfo(o),e),{}),outputs:t.signature.outputArg.reduce((e,o)=>(e[o.name]=this.mapArgToTensorInfo(o,t.ret),e),{})}}mapArgToTensorInfo(t,e){let o=t.name;return e!=null&&(o=e[o]),{name:o,dtype:t.type}}};function J5(r){let t=A().global;if(typeof t.atob!=\"undefined\")return t.atob(r);if(typeof Buffer!=\"undefined\")return new Buffer(r,\"base64\").toString();throw new Error(\"Unable to decode base64 in this environment. Missing built-in atob() or Buffer()\")}function yT(r,t){let e=Array.isArray(r)?String.fromCharCode.apply(null,r):J5(r);return t?e:e.toLowerCase()}function lf(r,t,e,o=!1){let n=r[t];return n!=null?yT(n.s,o):e}function mf(r,t,e){let o=r[t];return o?o.b:e}function df(r,t,e){let o=r[t]||{},n=o.i!=null?o.i:o.f!=null?o.f:e;return typeof n==\"number\"?n:parseInt(n,10)}function FS(r){switch(typeof r==\"string\"&&(r=ho[r]),r){case ho.DT_FLOAT:case ho.DT_HALF:return\"float32\";case ho.DT_INT32:case ho.DT_INT64:case ho.DT_INT8:case ho.DT_UINT8:return\"int32\";case ho.DT_BOOL:return\"bool\";case ho.DT_DOUBLE:return\"float32\";case ho.DT_STRING:return\"string\";default:return null}}function xT(r,t,e){let o=r[t];return o&&o.func?o.func.name:e}function ff(r,t,e){let o=r[t];return o&&o.type?FS(o.type):e}function hf(r,t,e){let o=r[t];return o&&o.list&&o.list.type?o.list.type.map(n=>FS(n)):e}function bT(r){if(!r.unknownRank)return r.dim!=null?r.dim.map(t=>typeof t.size==\"number\"?t.size:parseInt(t.size,10)):[]}function gf(r,t,e){let o=r[t];return o&&o.shape?bT(o.shape):e}function xf(r,t,e){let o=r[t];return o?((o.list.f&&o.list.f.length?o.list.f:o.list.i)||[]).map(n=>typeof n==\"number\"?n:parseInt(n,10)):e}function yf(r,t,e,o=!1){let n=r[t];return n&&n.list&&n.list.s?n.list.s.map(s=>yT(s,o)):e}function bf(r,t,e){let o=r[t];return o&&o.list&&o.list.shape?o.list.shape.map(n=>bT(n)):e}function Cf(r,t,e){let o=r[t];return o&&o.list&&o.list.b?o.list.b:e}var wf=class{constructor(t,e,o){this.node=t,this.tensorMap=e,this.context=o,this.inputs=[],this.attrs={},this.inputs=t.inputNames.map(n=>this.getInput(n)),t.rawAttrs!=null&&(this.attrs=Object.keys(t.rawAttrs).reduce((n,s)=>(n[s]=this.getAttr(s),n),{}))}getInput(t){return zt(t,this.tensorMap,this.context)}getAttr(t,e){let o=this.node.rawAttrs[t];if(o.tensor!=null)return zt(t,this.tensorMap,this.context);if(o.i!=null||o.f!=null)return df(this.node.rawAttrs,t,e);if(o.s!=null)return lf(this.node.rawAttrs,t,e);if(o.b!=null)return mf(this.node.rawAttrs,t,e);if(o.shape!=null)return gf(this.node.rawAttrs,t,e);if(o.type!=null)return ff(this.node.rawAttrs,t,e);if(o.list!=null){if(o.list.i!=null||o.list.f!=null)return xf(this.node.rawAttrs,t,e);if(o.list.s!=null)return yf(this.node.rawAttrs,t,e);if(o.list.shape!=null)return bf(this.node.rawAttrs,t,e);if(o.list.b!=null)return Cf(this.node.rawAttrs,t,e);if(o.list.type!=null)return hf(this.node.rawAttrs,t,e)}return e}};var Je={};qe(Je,{OP_SCOPE_SUFFIX:()=>kw,abs:()=>Jt,acos:()=>kk,acosh:()=>Nk,add:()=>Ce,addN:()=>Tk,all:()=>_k,any:()=>$k,argMax:()=>Ek,argMin:()=>Rk,asin:()=>Dk,asinh:()=>Ak,atan:()=>Fk,atan2:()=>Pk,atanh:()=>Ok,avgPool:()=>fd,avgPool3d:()=>Bk,basicLSTMCell:()=>zk,batchNorm:()=>au,batchNorm2d:()=>Wk,batchNorm3d:()=>Uk,batchNorm4d:()=>Gk,batchToSpaceND:()=>hd,bincount:()=>gd,bitwiseAnd:()=>Hk,booleanMaskAsync:()=>E6,broadcastArgs:()=>Kk,broadcastTo:()=>iu,buffer:()=>me,cast:()=>We,ceil:()=>qk,clipByValue:()=>jk,clone:()=>Ur,complex:()=>Er,concat:()=>bt,concat1d:()=>Xk,concat2d:()=>Yk,concat3d:()=>Qk,concat4d:()=>Zk,conv1d:()=>Jk,conv2d:()=>uu,conv2dTranspose:()=>e2,conv3d:()=>t2,conv3dTranspose:()=>o2,cos:()=>n2,cosh:()=>s2,cosineWindow:()=>Rl,cumprod:()=>a2,cumsum:()=>i2,denseBincount:()=>u2,depthToSpace:()=>p2,depthwiseConv2d:()=>lc,diag:()=>c2,dilation2d:()=>l2,div:()=>je,divNoNan:()=>d2,dot:()=>f2,dropout:()=>W6,einsum:()=>pu,elu:()=>Cd,enclosingPowerOfTwo:()=>Qw,ensureShape:()=>h2,equal:()=>bd,erf:()=>g2,euclideanNorm:()=>b2,exp:()=>$o,expandDims:()=>Ms,expm1:()=>C2,eye:()=>wd,fft:()=>fc,fill:()=>Ea,floor:()=>Sd,floorDiv:()=>dd,fused:()=>Zw,gather:()=>Id,gatherND:()=>z6,greater:()=>qu,greaterEqual:()=>vd,ifft:()=>Ju,imag:()=>lu,image:()=>Kj,inTopKAsync:()=>G6,irfft:()=>Kd,isFinite:()=>w2,isInf:()=>S2,isNaN:()=>I2,leakyRelu:()=>kd,less:()=>_l,lessEqual:()=>mc,linalg:()=>qj,linspace:()=>v2,localResponseNormalization:()=>k2,log:()=>pi,log1p:()=>Nd,logSigmoid:()=>N2,logSoftmax:()=>T2,logSumExp:()=>$d,logicalAnd:()=>ju,logicalNot:()=>Ed,logicalOr:()=>Rd,logicalXor:()=>_2,losses:()=>jj,lowerBound:()=>$2,matMul:()=>Ze,max:()=>Ra,maxPool:()=>Ad,maxPool3d:()=>E2,maxPoolWithArgmax:()=>R2,maximum:()=>Fd,mean:()=>Xu,meshgrid:()=>D2,min:()=>Tl,minimum:()=>Yu,mirrorPad:()=>A2,mod:()=>F2,moments:()=>P2,movingAverage:()=>A6,mul:()=>se,multiRNNCell:()=>O2,multinomial:()=>M2,neg:()=>cr,norm:()=>Ku,notEqual:()=>Pd,oneHot:()=>El,ones:()=>Da,onesLike:()=>L2,op:()=>N,outerProduct:()=>B2,pad:()=>Aa,pad1d:()=>z2,pad2d:()=>V2,pad3d:()=>W2,pad4d:()=>U2,pool:()=>G2,pow:()=>ui,prelu:()=>Md,print:()=>md,prod:()=>H2,raggedGather:()=>K2,raggedRange:()=>q2,raggedTensorToTensor:()=>j2,rand:()=>X2,randomGamma:()=>g1,randomNormal:()=>Ud,randomStandardNormal:()=>x1,randomUniform:()=>dc,randomUniformInt:()=>y1,range:()=>mu,real:()=>ci,reciprocal:()=>b1,relu:()=>du,relu6:()=>Gd,reshape:()=>W,reverse:()=>mo,reverse1d:()=>C1,reverse2d:()=>w1,reverse3d:()=>S1,reverse4d:()=>I1,rfft:()=>hc,round:()=>Hd,rsqrt:()=>v1,scalar:()=>ke,scatterND:()=>P6,searchSorted:()=>$l,selu:()=>k1,separableConv2d:()=>N1,setdiff1dAsync:()=>T1,sigmoid:()=>$a,sign:()=>_1,signal:()=>Hj,sin:()=>$1,sinh:()=>E1,slice:()=>Xe,slice1d:()=>R1,slice2d:()=>D1,slice3d:()=>A1,slice4d:()=>F1,softmax:()=>P1,softplus:()=>_d,spaceToBatchND:()=>Od,sparse:()=>Xj,sparseToDense:()=>L6,spectral:()=>Gj,split:()=>li,sqrt:()=>Dr,square:()=>er,squaredDifference:()=>qd,squeeze:()=>gc,stack:()=>kr,step:()=>jd,stridedSlice:()=>O1,string:()=>Yj,sub:()=>Te,sum:()=>ot,tan:()=>M1,tanh:()=>Nl,tensor:()=>ur,tensor1d:()=>tr,tensor2d:()=>fu,tensor3d:()=>Xd,tensor4d:()=>L1,tensor5d:()=>B1,tensor6d:()=>z1,tensorScatterUpdate:()=>W1,tile:()=>cu,topk:()=>U1,transpose:()=>yc,truncatedNormal:()=>G1,unique:()=>H1,unsortedSegmentSum:()=>K1,unstack:()=>fo,upperBound:()=>q1,variable:()=>j1,where:()=>lo,whereAsync:()=>Qd,zeros:()=>Gr,zerosLike:()=>Ht});var CT=(r,t,e,o=Je)=>{switch(r.op){case\"BiasAdd\":case\"AddV2\":case\"Add\":return[o.add(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"AddN\":return[o.addN(I(\"tensors\",r,t,e))];case\"FloorMod\":case\"Mod\":return[o.mod(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Mul\":return[o.mul(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"RealDiv\":case\"Div\":return[o.div(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"DivNoNan\":return[o.divNoNan(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"FloorDiv\":return[o.floorDiv(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Sub\":return[o.sub(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Minimum\":return[o.minimum(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Maximum\":return[o.maximum(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Pow\":return[o.pow(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"SquaredDifference\":return[o.squaredDifference(I(\"a\",r,t,e),I(\"b\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var wT=(r,t,e,o=Je)=>{switch(r.op){case\"Abs\":case\"ComplexAbs\":return[o.abs(I(\"x\",r,t,e))];case\"Acos\":return[o.acos(I(\"x\",r,t,e))];case\"Acosh\":return[o.acosh(I(\"x\",r,t,e))];case\"Asin\":return[o.asin(I(\"x\",r,t,e))];case\"Asinh\":return[o.asinh(I(\"x\",r,t,e))];case\"Atan\":return[o.atan(I(\"x\",r,t,e))];case\"Atan2\":return[o.atan2(I(\"x\",r,t,e),I(\"y\",r,t,e))];case\"Atanh\":return[o.atanh(I(\"x\",r,t,e))];case\"Ceil\":return[o.ceil(I(\"x\",r,t,e))];case\"Complex\":return[o.complex(I(\"real\",r,t,e),I(\"imag\",r,t,e))];case\"Cos\":return[o.cos(I(\"x\",r,t,e))];case\"Cosh\":return[o.cosh(I(\"x\",r,t,e))];case\"Elu\":return[o.elu(I(\"x\",r,t,e))];case\"Erf\":return[o.erf(I(\"x\",r,t,e))];case\"Exp\":return[o.exp(I(\"x\",r,t,e))];case\"Expm1\":return[o.expm1(I(\"x\",r,t,e))];case\"Floor\":return[o.floor(I(\"x\",r,t,e))];case\"Log\":return[o.log(I(\"x\",r,t,e))];case\"Log1p\":return[o.log1p(I(\"x\",r,t,e))];case\"Imag\":return[o.imag(I(\"x\",r,t,e))];case\"Neg\":return[o.neg(I(\"x\",r,t,e))];case\"Reciprocal\":return[o.reciprocal(I(\"x\",r,t,e))];case\"Real\":return[o.real(I(\"x\",r,t,e))];case\"Relu\":return[o.relu(I(\"x\",r,t,e))];case\"Round\":return[o.round(I(\"x\",r,t,e))];case\"Selu\":return[o.selu(I(\"x\",r,t,e))];case\"Sigmoid\":return[o.sigmoid(I(\"x\",r,t,e))];case\"Sin\":return[o.sin(I(\"x\",r,t,e))];case\"Sign\":return[o.sign(I(\"x\",r,t,e))];case\"Sinh\":return[o.sinh(I(\"x\",r,t,e))];case\"Softplus\":return[o.softplus(I(\"x\",r,t,e))];case\"Sqrt\":return[o.sqrt(I(\"x\",r,t,e))];case\"Square\":return[o.square(I(\"x\",r,t,e))];case\"Tanh\":return[o.tanh(I(\"x\",r,t,e))];case\"Tan\":return[o.tan(I(\"x\",r,t,e))];case\"ClipByValue\":return[o.clipByValue(I(\"x\",r,t,e),I(\"clipValueMin\",r,t,e),I(\"clipValueMax\",r,t,e))];case\"Relu6\":return[o.relu6(I(\"x\",r,t,e))];case\"Rsqrt\":return[o.rsqrt(zt(r.inputNames[0],t,e))];case\"LeakyRelu\":return[o.leakyRelu(I(\"x\",r,t,e),I(\"alpha\",r,t,e))];case\"Prelu\":return[o.prelu(I(\"x\",r,t,e),I(\"alpha\",r,t,e))];case\"IsNan\":return[o.isNaN(zt(r.inputNames[0],t,e))];case\"IsInf\":return[o.isInf(zt(r.inputNames[0],t,e))];case\"IsFinite\":return[o.isFinite(zt(r.inputNames[0],t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};function Hr(r,t,e=\"\"){if(!(typeof r==\"number\"||typeof t==\"number\")){y.assert(r.length===t.length,()=>e+` Shapes ${r} and ${t} must match`);for(let o=0;oe+` Shapes ${r} and ${t} must match`)}}}function ST(r){return!(typeof r==\"number\"||r.some(t=>t<0))}function bc(r,t,e){let o=Sf(r,e),n=!ST(o);if(n&&t.length===0)throw new Error(`Tried to calculate elements of an empty list with non-fully-defined elementShape: ${o}`);if(n&&t.forEach(s=>{o=Sf(s.shape,o)}),!ST(o))throw new Error(`Non-fully-defined elementShape: ${o}`);return o}function Sf(r,t){if(typeof r==\"number\")return t;if(typeof t==\"number\")return r;if(r.length!==t.length)throw new Error(`Incompatible ranks during merge: ${r} vs. ${t}`);let e=[];for(let o=0;o=0&&s>=0&&n!==s)throw new Error(`Incompatible shape during merge: ${r} vs. ${t}`);e[o]=n>=0?n:s}return e}var If=class{constructor(t,e,o,n,s,a,i){this.name=t,this.dtype=e,this.maxSize=o,this.elementShape=n,this.identicalElementShapes=s,this.dynamicSize=a,this.clearAfterRead=i,this.tensors=[],this.closed_=!1,this.idTensor=ke(0),Rr(this.idTensor)}get id(){return this.idTensor.id}get closed(){return this.closed_}clearAndClose(t){this.tensors.forEach(e=>{(t==null||!t.has(e.tensor.id))&&e.tensor.dispose()}),this.tensors=[],this.closed_=!0,this.idTensor.dispose()}size(){return this.tensors.length}read(t){if(this.closed_)throw new Error(`TensorArray ${this.name} has already been closed.`);if(t<0||t>=this.size())throw new Error(`Tried to read from index ${t}, but array size is: ${this.size()}`);let e=this.tensors[t];if(e.cleared)throw new Error(`TensorArray ${this.name}: Could not read index ${t} twice because it was cleared after a previous read (perhaps try setting clear_after_read = false?).`);return this.clearAfterRead&&(e.cleared=!0),e.read=!0,e.tensor}readMany(t){return t.map(e=>this.read(e))}write(t,e){if(this.closed_)throw new Error(`TensorArray ${this.name} has already been closed.`);if(t<0||!this.dynamicSize&&t>=this.maxSize)throw new Error(`Tried to write to index ${t}, but array is not resizeable and size is: ${this.maxSize}`);let o=this.tensors[t]||{};if(e.dtype!==this.dtype)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${t},\n because the value dtype is ${e.dtype}, but TensorArray dtype is ${this.dtype}.`);if(this.size()===0&&(this.elementShape==null||this.elementShape.length===0)&&(this.elementShape=e.shape),Hr(this.elementShape,e.shape,`TensorArray ${this.name}: Could not write to TensorArray index ${t}.`),o.read)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${t}, because it has already been read.`);if(o.written)throw new Error(`TensorArray ${this.name}: Could not write to TensorArray index ${t}, because it has already been written.`);o.tensor=e,Rr(e),o.written=!0,this.tensors[t]=o}writeMany(t,e){if(t.length!==e.length)throw new Error(`TensorArray ${this.name}: could not write multiple tensors,because the index size: ${t.length} is not the same as tensors size: ${e.length}.`);t.forEach((o,n)=>this.write(o,e[n]))}gather(t,e){if(e&&e!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but gather requested dtype ${e}`);if(t)t=t.slice(0,this.size());else{t=[];for(let n=0;n=this.maxSize)throw new Error(`Max index must be < array size (${o} vs. ${this.maxSize})`);this.writeMany(t,fo(e,0))}split(t,e){if(e.dtype!==this.dtype)throw new Error(`TensorArray dtype is ${this.dtype} but tensor has dtype ${e.dtype}`);let o=0,n=t.map(p=>(o+=p,o));if(o!==e.shape[0])throw new Error(`Expected sum of lengths to be equal to\n tensor.shape[0], but sum of lengths is\n ${o}, and tensor's shape is: ${e.shape}`);if(!this.dynamicSize&&t.length!==this.maxSize)throw new Error(`TensorArray's size is not equal to the size of lengths (${this.maxSize} vs. ${t.length}), and the TensorArray is not marked as dynamically resizeable`);let s=o===0?0:e.size/o,a=[];De(()=>{e=W(e,[1,o,s]);for(let p=0;p{if(o!==s.dtype)throw new Error(`Invalid data types; op elements ${o}, but list elements ${s.dtype}`);Hr(e,s.shape,\"TensorList shape mismatch: \"),Rr(s)}),this.idTensor=ke(0),this.maxNumElements=n,Rr(this.idTensor)}copy(){return new hi([...this.tensors],this.elementShape,this.elementDtype)}clearAndClose(t){this.tensors.forEach(e=>{(t==null||!t.has(e.id))&&e.dispose()}),this.tensors.length=0,this.idTensor.dispose()}size(){return this.tensors.length}stack(t,e,o=-1){if(e!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e}, but list elements ${this.elementDtype}`);if(o!==-1&&this.tensors.length!==o)throw new Error(`Operation expected a list with ${o} elements but got a list with ${this.tensors.length} elements.`);Hr(t,this.elementShape,\"TensorList shape mismatch: \");let n=bc(this.elementShape,this.tensors,t);return De(()=>{let s=this.tensors.map(a=>W(a,n));return kr(s,0)})}popBack(t,e){if(e!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e}, but list elements ${this.elementDtype}`);if(this.size()===0)throw new Error(\"Trying to pop from an empty list.\");let o=bc(this.elementShape,this.tensors,t),n=this.tensors.pop();return n.kept=!1,Hr(n.shape,t,\"TensorList shape mismatch: \"),W(n,o)}pushBack(t){if(t.dtype!==this.elementDtype)throw new Error(`Invalid data types; op elements ${t.dtype}, but list elements ${this.elementDtype}`);if(Hr(t.shape,this.elementShape,\"TensorList shape mismatch: \"),this.maxNumElements===this.size())throw new Error(\"Trying to push element into a full list.\");Rr(t),this.tensors.push(t)}resize(t){if(t<0)throw new Error(`TensorListResize expects size to be non-negative. Got: ${t}`);if(this.maxNumElements!==-1&&t>this.maxNumElements)throw new Error(`TensorListResize input size ${t} is greater maxNumElement ${this.maxNumElements}.`);let e=new hi([],this.elementShape,this.elementDtype,this.maxNumElements);e.tensors.length=t;for(let o=0;othis.tensors.length)throw new Error(`Trying to access element ${t} in a list with ${this.tensors.length} elements.`);if(this.tensors[t]==null)throw new Error(`element at index ${t} is null.`);Hr(this.tensors[t].shape,e,\"TensorList shape mismatch: \");let n=bc(this.elementShape,this.tensors,e);return W(this.tensors[t],n)}setItem(t,e){if(e.dtype!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e.dtype}, but list elements ${this.elementDtype}`);if(t<0||this.maxNumElements!==-1&&t>=this.maxNumElements)throw new Error(`Trying to set element ${t} in a list with max ${this.maxNumElements} elements.`);Hr(this.elementShape,e.shape,\"TensorList shape mismatch: \"),Rr(e),this.tensors[t]!=null&&(this.tensors[t].kept=!1),this.tensors[t]=e}gather(t,e,o){if(e!==this.elementDtype)throw new Error(`Invalid data types; op elements ${e}, but list elements ${this.elementDtype}`);Hr(this.elementShape,o,\"TensorList shape mismatch: \"),t=t.slice(0,this.size());let n=bc(this.elementShape,this.tensors,o);return t.length===0?ur([],[0].concat(n)):De(()=>{let s=t.map(a=>W(this.tensors[a],n));return kr(s,0)})}concat(t,e){if(t&&t!==this.elementDtype)throw new Error(`TensorList dtype is ${this.elementDtype} but concat requested dtype ${t}`);Hr(this.elementShape,e,\"TensorList shape mismatch: \");let o=bc(this.elementShape,this.tensors,e);return this.size()===0?ur([],[0].concat(o)):De(()=>{let n=this.tensors.map(s=>W(s,o));return bt(n,0)})}};function IT(r,t,e){let o=r.dtype;if(r.shape.length<1)throw new Error(`Tensor must be at least a vector, but saw shape: ${r.shape}`);if(r.dtype!==e)throw new Error(`Invalid data types; op elements ${r.dtype}, but list elements ${e}`);let n=r.shape.slice(1);Hr(n,t,\"TensorList shape mismatch: \");let s=fo(r);return new hi(s,t,o)}function vT(r,t,e,o){return new hi([],r,t,o)}function kT(r,t,e,o){if(t.length!==r.shape[0])throw new Error(`Expected len(indices) == tensor.shape[0], but saw: ${t.length} vs. ${r.shape[0]}`);let n=Math.max(...t);if(o!=null&&o!==-1&&n>=o)throw new Error(`Max index must be < array size (${n} vs. ${o})`);let s=new hi([],e,r.dtype,o),a=fo(r,0);return t.forEach((i,p)=>{s.setItem(i,a[p])}),s}function NT(r,t,e){let o=0,n=t.map(c=>(o+=c,o));if(o!==r.shape[0])throw new Error(`Expected sum of lengths to be equal to\n tensor.shape[0], but sum of lengths is\n ${o}, and tensor's shape is: ${r.shape}`);let s=r.shape.slice(1),a=Sf(s,e),i=o===0?0:r.size/o,p=De(()=>{let c=[];r=W(r,[1,o,i]);for(let l=0;l{switch(r.op){case\"If\":case\"StatelessIf\":{let o=I(\"thenBranch\",r,t,e),n=I(\"elseBranch\",r,t,e),s=I(\"cond\",r,t,e),a=I(\"args\",r,t,e);return(await s.data())[0]?e.functionMap[o].executeFunctionAsync(a,e.tensorArrayMap,e.tensorListMap):e.functionMap[n].executeFunctionAsync(a,e.tensorArrayMap,e.tensorListMap)}case\"While\":case\"StatelessWhile\":{let o=I(\"body\",r,t,e),n=I(\"cond\",r,t,e),s=I(\"args\",r,t,e),a=await e.functionMap[n].executeFunctionAsync(s,e.tensorArrayMap,e.tensorListMap),i=s.map(c=>c.id),p=await a[0].data();a.forEach(c=>{!c.kept&&i.indexOf(c.id)===-1&&c.dispose()});let u=s;for(;p[0];){let c=u;u=await e.functionMap[o].executeFunctionAsync(u,e.tensorArrayMap,e.tensorListMap);let l=u.map(d=>d.id);c.forEach(d=>{!d.kept&&i.indexOf(d.id)===-1&&l.indexOf(d.id)===-1&&d.dispose()});let m=await e.functionMap[n].executeFunctionAsync(u,e.tensorArrayMap,e.tensorListMap);p=await m[0].data(),m.forEach(d=>{!d.kept&&i.indexOf(d.id)===-1&&l.indexOf(d.id)===-1&&d.dispose()})}return u}case\"LoopCond\":{let o=I(\"pred\",r,t,e);return[Bs(o)]}case\"Switch\":{let o=I(\"pred\",r,t,e),n=I(\"data\",r,t,e);return n.kept||(n=Bs(n)),(await o.data())[0]?[void 0,n]:[n,void 0]}case\"Merge\":{let o=r.inputNames.find(n=>zt(n,t,e)!==void 0);if(o){let n=zt(o,t,e);return[Bs(n)]}return}case\"Enter\":{let o=I(\"frameName\",r,t,e),n=I(\"tensor\",r,t,e);return e.enterFrame(o),[Bs(n)]}case\"Exit\":{let o=I(\"tensor\",r,t,e);return e.exitFrame(),[Bs(o)]}case\"NextIteration\":{let o=I(\"tensor\",r,t,e);return e.nextIteration(),[Bs(o)]}case\"TensorArrayV3\":{let o=I(\"size\",r,t,e),n=I(\"dtype\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"dynamicSize\",r,t,e),i=I(\"clearAfterRead\",r,t,e),p=I(\"identicalElementShapes\",r,t,e),u=I(\"name\",r,t,e),c=new If(u,n,o,s,p,a,i);return e.addTensorArray(c),[c.idTensor,ke(1)]}case\"TensorArrayWriteV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"index\",r,t,e),s=I(\"tensor\",r,t,e),a=e.getTensorArray(o.id);return a.write(n,s),[a.idTensor]}case\"TensorArrayReadV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"index\",r,t,e);return[e.getTensorArray(o.id).read(n)]}case\"TensorArrayGatherV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"indices\",r,t,e),s=I(\"dtype\",r,t,e);return[e.getTensorArray(o.id).gather(n,s)]}case\"TensorArrayScatterV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"indices\",r,t,e),s=I(\"tensor\",r,t,e),a=e.getTensorArray(o.id);return a.scatter(n,s),[a.idTensor]}case\"TensorArrayConcatV3\":{let o=I(\"tensorArrayId\",r,t,e),n=e.getTensorArray(o.id),s=I(\"dtype\",r,t,e);return[n.concat(s)]}case\"TensorArraySplitV3\":{let o=I(\"tensorArrayId\",r,t,e),n=I(\"tensor\",r,t,e),s=I(\"lengths\",r,t,e),a=e.getTensorArray(o.id);return a.split(s,n),[a.idTensor]}case\"TensorArraySizeV3\":{let o=I(\"tensorArrayId\",r,t,e),n=e.getTensorArray(o.id);return[ke(n.size(),\"int32\")]}case\"TensorArrayCloseV3\":{let o=I(\"tensorArrayId\",r,t,e),n=e.getTensorArray(o.id);return n.clearAndClose(),[n.idTensor]}case\"TensorListSetItem\":{let o=I(\"tensorListId\",r,t,e),n=I(\"index\",r,t,e),s=I(\"tensor\",r,t,e),a=e.getTensorList(o.id);return a.setItem(n,s),[a.idTensor]}case\"TensorListGetItem\":{let o=I(\"tensorListId\",r,t,e),n=I(\"index\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"elementDType\",r,t,e);return[e.getTensorList(o.id).getItem(n,s,a)]}case\"TensorListScatterV2\":case\"TensorListScatter\":{let o=I(\"indices\",r,t,e),n=I(\"tensor\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"numElements\",r,t,e),i=kT(n,o,s,a);return e.addTensorList(i),[i.idTensor]}case\"TensorListReserve\":case\"EmptyTensorList\":{let o=I(\"elementShape\",r,t,e),n=I(\"elementDType\",r,t,e),s;r.op===\"TensorListReserve\"?s=\"numElements\":s=\"maxNumElements\";let a=I(s,r,t,e),i=r.op===\"TensorListReserve\"?-1:a,p=vT(o,n,a,i);return e.addTensorList(p),[p.idTensor]}case\"TensorListGather\":{let o=I(\"tensorListId\",r,t,e),n=I(\"indices\",r,t,e),s=I(\"elementShape\",r,t,e),a=I(\"elementDType\",r,t,e);return[e.getTensorList(o.id).gather(n,a,s)]}case\"TensorListStack\":{let o=I(\"tensorListId\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"elementDType\",r,t,e),a=I(\"numElements\",r,t,e);return[e.getTensorList(o.id).stack(n,s,a)]}case\"TensorListFromTensor\":{let o=I(\"tensor\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"elementDType\",r,t,e),a=IT(o,n,s);return e.addTensorList(a),[a.idTensor]}case\"TensorListConcat\":case\"TensorListConcatV2\":{let o=I(\"tensorListId\",r,t,e),n=e.getTensorList(o.id),s=I(\"dtype\",r,t,e),a=I(\"elementShape\",r,t,e);return[n.concat(s,a)]}case\"TensorListPushBack\":{let o=I(\"tensorListId\",r,t,e),n=I(\"tensor\",r,t,e),s=e.getTensorList(o.id);return s.pushBack(n),[s.idTensor]}case\"TensorListPopBack\":{let o=I(\"tensorListId\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"elementDType\",r,t,e);return[e.getTensorList(o.id).popBack(n,s)]}case\"TensorListSplit\":{let o=I(\"tensor\",r,t,e),n=I(\"elementShape\",r,t,e),s=I(\"lengths\",r,t,e),a=NT(o,s,n);return e.addTensorList(a),[a.idTensor]}case\"TensorListLength\":{let o=I(\"tensorListId\",r,t,e),n=e.getTensorList(o.id);return[ke(n.size(),\"int32\")]}case\"TensorListResize\":{let o=I(\"tensorListId\",r,t,e),n=I(\"size\",r,t,e),a=e.getTensorList(o.id).resize(n);return e.addTensorList(a),[a.idTensor]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};function _T(r,t,e){let[o,n]=I(\"fusedOps\",r,t,e),s=o===\"biasadd\",a=!s,i=n===\"prelu\",p=o===\"fusedbatchnorm\",u=I(\"numArgs\",r,t,e);if(s){if(i&&u!==2)throw new Error(\"FusedConv2d and DepthwiseConv2d with BiasAdd and Prelu must have two extra arguments: bias and alpha.\");if(!i&&s&&u!==1)throw new Error(\"FusedConv2d and DepthwiseConv2d with BiasAdd must have one extra argument: bias.\")}if(p)throw new Error(\"FusedConv2d and DepthwiseConv2d with FusedBatchNorm is not supported\");let c=I(\"strides\",r,t,e),l=Ol(r,t,e),m=I(\"dataFormat\",r,t,e).toUpperCase(),d=I(\"dilations\",r,t,e),[f,h]=I(\"args\",r,t,e);a&&(h=f,f=void 0);let g=I(\"leakyreluAlpha\",r,t,e);return{stride:c,pad:l,dataFormat:m,dilations:d,biasArg:f,preluArg:h,activationFunc:n,leakyreluAlpha:g}}var $T=(r,t,e,o=Je)=>{switch(r.op){case\"Conv1D\":{let n=I(\"stride\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"dataFormat\",r,t,e).toUpperCase(),i=I(\"dilation\",r,t,e);return[o.conv1d(I(\"x\",r,t,e),I(\"filter\",r,t,e),n,s,a,i)]}case\"Conv2D\":{let n=I(\"strides\",r,t,e),s=Ol(r,t,e),a=I(\"dataFormat\",r,t,e).toUpperCase(),i=I(\"dilations\",r,t,e);return[o.conv2d(I(\"x\",r,t,e),I(\"filter\",r,t,e),[n[1],n[2]],s,a,[i[1],i[2]])]}case\"_FusedConv2D\":{let{stride:n,pad:s,dataFormat:a,dilations:i,biasArg:p,preluArg:u,activationFunc:c,leakyreluAlpha:l}=_T(r,t,e);return[o.fused.conv2d({x:I(\"x\",r,t,e),filter:I(\"filter\",r,t,e),strides:[n[1],n[2]],pad:s,dataFormat:a,dilations:[i[1],i[2]],bias:p,activation:c,preluActivationWeights:u,leakyreluAlpha:l})]}case\"FusedDepthwiseConv2dNative\":{let{stride:n,pad:s,dataFormat:a,dilations:i,biasArg:p,preluArg:u,activationFunc:c,leakyreluAlpha:l}=_T(r,t,e);return[o.fused.depthwiseConv2d({x:I(\"x\",r,t,e),filter:I(\"filter\",r,t,e),strides:[n[1],n[2]],pad:s,dataFormat:a,dilations:[i[1],i[2]],bias:p,activation:c,preluActivationWeights:u,leakyreluAlpha:l})]}case\"Conv2DBackpropInput\":case\"Conv2dTranspose\":{let n=I(\"outputShape\",r,t,e),s=I(\"strides\",r,t,e),a=Ol(r,t,e);return[o.conv2dTranspose(I(\"x\",r,t,e),I(\"filter\",r,t,e),n,[s[1],s[2]],a)]}case\"DepthwiseConv2dNative\":case\"DepthwiseConv2d\":{let n=I(\"strides\",r,t,e),s=Ol(r,t,e),a=I(\"dilations\",r,t,e),i=I(\"dataFormat\",r,t,e).toUpperCase();return[o.depthwiseConv2d(I(\"input\",r,t,e),I(\"filter\",r,t,e),[n[1],n[2]],s,i,[a[1],a[2]])]}case\"Conv3D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"dataFormat\",r,t,e).toUpperCase(),i=I(\"dilations\",r,t,e);return[o.conv3d(I(\"x\",r,t,e),I(\"filter\",r,t,e),[n[1],n[2],n[3]],s,a,[i[1],i[2],i[3]])]}case\"AvgPool\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.avgPool(I(\"x\",r,t,e),[a[1],a[2]],[n[1],n[2]],s)]}case\"MaxPool\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.maxPool(I(\"x\",r,t,e),[a[1],a[2]],[n[1],n[2]],s)]}case\"MaxPoolWithArgmax\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e),i=I(\"includeBatchInIndex\",r,t,e),{result:p,indexes:u}=o.maxPoolWithArgmax(I(\"x\",r,t,e),[a[1],a[2]],[n[1],n[2]],s,i);return[p,u]}case\"AvgPool3D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.avgPool3d(I(\"x\",r,t,e),[a[1],a[2],a[3]],[n[1],n[2],n[3]],s)]}case\"MaxPool3D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"kernelSize\",r,t,e);return[o.maxPool3d(I(\"x\",r,t,e),[a[1],a[2],a[3]],[n[1],n[2],n[3]],s)]}case\"Dilation2D\":{let n=I(\"strides\",r,t,e),s=I(\"pad\",r,t,e),a=I(\"dilations\",r,t,e),i=n[1],p=n[2],u=a[1],c=a[2];return[o.dilation2d(I(\"x\",r,t,e),I(\"filter\",r,t,e),[i,p],s,[u,c],\"NHWC\")]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var ET=(r,t,e,o=Je)=>{switch(r.op){case\"Fill\":{let n=I(\"shape\",r,t,e),s=I(\"dtype\",r,t,e),a=I(\"value\",r,t,e);return[o.fill(n,a,s)]}case\"LinSpace\":{let n=I(\"start\",r,t,e),s=I(\"stop\",r,t,e),a=I(\"num\",r,t,e);return[o.linspace(n,s,a)]}case\"Multinomial\":{let n=I(\"logits\",r,t,e),s=I(\"numSamples\",r,t,e),a=I(\"seed\",r,t,e);return[o.multinomial(n,s,a)]}case\"OneHot\":{let n=I(\"indices\",r,t,e),s=I(\"depth\",r,t,e),a=I(\"onValue\",r,t,e),i=I(\"offValue\",r,t,e),p=I(\"dtype\",r,t,e);return[o.oneHot(n,s,a,i,p)]}case\"Ones\":return[o.ones(I(\"shape\",r,t,e),I(\"dtype\",r,t,e))];case\"OnesLike\":return[o.onesLike(I(\"x\",r,t,e))];case\"RandomStandardNormal\":return[o.randomStandardNormal(I(\"shape\",r,t,e),I(\"dtype\",r,t,e),I(\"seed\",r,t,e))];case\"RandomUniform\":return[o.randomUniform(I(\"shape\",r,t,e),I(\"minval\",r,t,e),I(\"maxval\",r,t,e),I(\"dtype\",r,t,e))];case\"RandomUniformInt\":return[o.randomUniformInt(I(\"shape\",r,t,e),I(\"minval\",r,t,e),I(\"maxval\",r,t,e),I(\"seed\",r,t,e))];case\"Range\":{let n=I(\"start\",r,t,e),s=I(\"stop\",r,t,e),a=I(\"step\",r,t,e);return[o.range(n,s,a,I(\"dtype\",r,t,e))]}case\"TruncatedNormal\":{let n=I(\"shape\",r,t,e),s=I(\"mean\",r,t,e),a=I(\"stdDev\",r,t,e),i=I(\"seed\",r,t,e);return[o.truncatedNormal(n,s,a,I(\"dtype\",r,t,e),i)]}case\"Zeros\":return[o.zeros(I(\"shape\",r,t,e),I(\"dtype\",r,t,e))];case\"ZerosLike\":return[o.zerosLike(I(\"x\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};function PS(r,t,e){let o=I(\"boxes\",r,t,e),n=I(\"scores\",r,t,e),s=I(\"maxOutputSize\",r,t,e),a=I(\"iouThreshold\",r,t,e),i=I(\"scoreThreshold\",r,t,e),p=I(\"softNmsSigma\",r,t,e);return{boxes:o,scores:n,maxOutputSize:s,iouThreshold:a,scoreThreshold:i,softNmsSigma:p}}var RT=async(r,t,e,o,n=Je)=>{switch(r.op){case\"NonMaxSuppressionV5\":{let{boxes:s,scores:a,maxOutputSize:i,iouThreshold:p,scoreThreshold:u,softNmsSigma:c}=PS(r,t,e),l=await n.image.nonMaxSuppressionWithScoreAsync(s,a,i,p,u,c);return[l.selectedIndices,l.selectedScores]}case\"NonMaxSuppressionV4\":{let{boxes:s,scores:a,maxOutputSize:i,iouThreshold:p,scoreThreshold:u}=PS(r,t,e),c=I(\"padToMaxOutputSize\",r,t,e),l=await n.image.nonMaxSuppressionPaddedAsync(s,a,i,p,u,c);return[l.selectedIndices,l.validOutputs]}case\"NonMaxSuppressionV3\":case\"NonMaxSuppressionV2\":{let{boxes:s,scores:a,maxOutputSize:i,iouThreshold:p,scoreThreshold:u}=PS(r,t,e);return[await n.image.nonMaxSuppressionAsync(s,a,i,p,u)]}case\"Where\":{let s=n.cast(I(\"condition\",r,t,e),\"bool\"),a=[await n.whereAsync(s)];return s.dispose(),a}case\"ListDiff\":return n.setdiff1dAsync(I(\"x\",r,t,e),I(\"y\",r,t,e));default:throw TypeError(`Node type ${r.op} is not implemented`)}};var DT=(r,t,e,o=Je)=>{switch(r.op){case\"LowerBound\":{let n=I(\"sortedSequence\",r,t,e),s=I(\"values\",r,t,e);return[o.lowerBound(n,s)]}case\"TopKV2\":{let n=I(\"x\",r,t,e),s=I(\"k\",r,t,e),a=I(\"sorted\",r,t,e),i=o.topk(n,s,a);return[i.values,i.indices]}case\"UpperBound\":{let n=I(\"sortedSequence\",r,t,e),s=I(\"values\",r,t,e);return[o.upperBound(n,s)]}case\"Unique\":{let n=I(\"x\",r,t,e),s=o.unique(n);return[s.values,s.indices]}case\"UniqueV2\":{let n=I(\"x\",r,t,e),s=I(\"axis\",r,t,e),a=o.unique(n,s);return[a.values,a.indices]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var AT=(r,t,e,o=Je)=>{switch(r.op){case\"Const\":return t[r.name];case\"PlaceholderWithDefault\":let n=I(\"default\",r,t,e);return[zt(r.name,t,e)||n];case\"Placeholder\":return[zt(r.name,t,e)];case\"Identity\":case\"StopGradient\":case\"FakeQuantWithMinMaxVars\":{let c=I(\"x\",r,t,e);return[Bs(c)]}case\"IdentityN\":return I(\"x\",r,t,e).map(c=>Bs(c));case\"Snapshot\":let s=I(\"x\",r,t,e);return[Bs(s)];case\"Shape\":return[o.tensor1d(I(\"x\",r,t,e).shape,\"int32\")];case\"ShapeN\":return I(\"x\",r,t,e).map(c=>o.tensor1d(c.shape));case\"Size\":return[o.scalar(I(\"x\",r,t,e).size,\"int32\")];case\"Rank\":return[o.scalar(I(\"x\",r,t,e).rank,\"int32\")];case\"NoOp\":return[o.scalar(1)];case\"Print\":let a=I(\"x\",r,t,e),i=I(\"data\",r,t,e),p=I(\"message\",r,t,e),u=I(\"summarize\",r,t,e);console.warn(\"The graph has a tf.print() operation,usually used for debugging, which slows down performance.\"),console.log(p);for(let c=0;ct.dispose()),this.tensorMap.clear(),this.handle.dispose()}size(){return this.tensorMap.size}tensorSize(){return ke(this.size(),\"int32\")}async import(t,e){this.checkKeyAndValueTensor(t,e);let o=await t.data();return this.tensorMap.forEach(n=>n.dispose()),this.tensorMap.clear(),De(()=>{let n=fo(e),s=o.length,a=n.length;y.assert(s===a,()=>`The number of elements doesn't match, keys has ${s} elements, the values has ${a} elements.`);for(let i=0;i{let n=[];for(let s=0;s{switch(r.op){case\"HashTable\":case\"HashTableV2\":{let n=o.getHashTableHandleByName(r.name);if(n!=null)return[n];{let s=I(\"keyDType\",r,t,e),a=I(\"valueDType\",r,t,e),i=new vf(s,a);return o.addHashTable(r.name,i),[i.handle]}}case\"InitializeTable\":case\"InitializeTableV2\":case\"LookupTableImport\":case\"LookupTableImportV2\":{let n=I(\"tableHandle\",r,t,e,o),s=I(\"keys\",r,t,e),a=I(\"values\",r,t,e);return[await o.getHashTableById(n.id).import(s,a)]}case\"LookupTableFind\":case\"LookupTableFindV2\":{let n=I(\"tableHandle\",r,t,e,o),s=I(\"keys\",r,t,e),a=I(\"defaultValue\",r,t,e);return[await o.getHashTableById(n.id).find(s,a)]}case\"LookupTableSize\":case\"LookupTableSizeV2\":{let n=I(\"tableHandle\",r,t,e,o);return[o.getHashTableById(n.id).tensorSize()]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var PT=(r,t,e,o=Je)=>{switch(r.op){case\"ResizeBilinear\":{let n=I(\"images\",r,t,e),s=I(\"size\",r,t,e),a=I(\"alignCorners\",r,t,e),i=I(\"halfPixelCenters\",r,t,e);return[o.image.resizeBilinear(n,[s[0],s[1]],a,i)]}case\"ResizeNearestNeighbor\":{let n=I(\"images\",r,t,e),s=I(\"size\",r,t,e),a=I(\"alignCorners\",r,t,e),i=I(\"halfPixelCenters\",r,t,e);return[o.image.resizeNearestNeighbor(n,[s[0],s[1]],a,i)]}case\"CropAndResize\":{let n=I(\"image\",r,t,e),s=I(\"boxes\",r,t,e),a=I(\"boxInd\",r,t,e),i=I(\"cropSize\",r,t,e),p=I(\"method\",r,t,e),u=I(\"extrapolationValue\",r,t,e);return[o.image.cropAndResize(n,s,a,i,p,u)]}case\"ImageProjectiveTransformV3\":{let n=I(\"images\",r,t,e),s=I(\"transforms\",r,t,e),a=I(\"outputShape\",r,t,e),i=I(\"fillValue\",r,t,e),p=I(\"interpolation\",r,t,e),u=I(\"fillMode\",r,t,e);return[o.image.transform(n,s,p.toLowerCase(),u.toLowerCase(),i,a)]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var OT=(r,t,e,o=Je)=>{switch(r.op){case\"Equal\":return[o.equal(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"NotEqual\":return[o.notEqual(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Greater\":return[o.greater(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"GreaterEqual\":return[o.greaterEqual(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Less\":return[o.less(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"LessEqual\":return[o.lessEqual(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"LogicalAnd\":return[o.logicalAnd(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"LogicalNot\":return[o.logicalNot(I(\"a\",r,t,e))];case\"LogicalOr\":return[o.logicalOr(I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"Select\":case\"SelectV2\":return[o.where(I(\"condition\",r,t,e),I(\"a\",r,t,e),I(\"b\",r,t,e))];case\"BitwiseAnd\":return[o.bitwiseAnd(I(\"a\",r,t,e),I(\"b\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var MT=(r,t,e,o=Je)=>{switch(r.op){case\"BatchMatMul\":case\"BatchMatMulV2\":case\"MatMul\":return[o.matMul(I(\"a\",r,t,e),I(\"b\",r,t,e),I(\"transposeA\",r,t,e),I(\"transposeB\",r,t,e))];case\"Einsum\":return[o.einsum(I(\"equation\",r,t,e),...I(\"tensors\",r,t,e))];case\"Transpose\":return[o.transpose(I(\"x\",r,t,e),I(\"perm\",r,t,e))];case\"_FusedMatMul\":let[n,s]=I(\"fusedOps\",r,t,e),a=n===\"biasadd\",i=s===\"prelu\",p=I(\"numArgs\",r,t,e),u=I(\"leakyreluAlpha\",r,t,e);if(a){if(i&&p!==2)throw new Error(\"Fused MatMul with BiasAdd and Prelu must have two extra arguments: bias and alpha.\");if(!i&&p!==1)throw new Error(\"Fused MatMul with BiasAdd must have one extra argument: bias.\")}let[c,l]=I(\"args\",r,t,e);return[o.fused.matMul({a:I(\"a\",r,t,e),b:I(\"b\",r,t,e),transposeA:I(\"transposeA\",r,t,e),transposeB:I(\"transposeB\",r,t,e),bias:c,activation:s,preluActivationWeights:l,leakyreluAlpha:u})];case\"MatrixBandPart\":return[o.linalg.bandPart(I(\"a\",r,t,e),I(\"numLower\",r,t,e),I(\"numUpper\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var LT=(r,t,e,o=Je)=>{switch(r.op){case\"EuclideanNorm\":return[o.euclideanNorm(I(\"x\",r,t,e),I(\"axis\",r,t,e),I(\"keepDims\",r,t,e))];case\"FusedBatchNorm\":case\"FusedBatchNormV2\":return[o.batchNorm(I(\"x\",r,t,e),I(\"mean\",r,t,e),I(\"variance\",r,t,e),I(\"offset\",r,t,e),I(\"scale\",r,t,e),I(\"epsilon\",r,t,e))];case\"FusedBatchNormV3\":return[o.batchNorm(I(\"x\",r,t,e),I(\"mean\",r,t,e),I(\"variance\",r,t,e),I(\"offset\",r,t,e),I(\"scale\",r,t,e),I(\"epsilon\",r,t,e))];case\"LRN\":return[o.localResponseNormalization(I(\"x\",r,t,e),I(\"radius\",r,t,e),I(\"bias\",r,t,e),I(\"alpha\",r,t,e),I(\"beta\",r,t,e))];case\"Softmax\":return[o.softmax(I(\"x\",r,t,e))];case\"LogSoftmax\":return[o.logSoftmax(I(\"x\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var BT=(r,t,e,o=Je)=>{switch(r.op){case\"RaggedGather\":{let{outputNestedSplits:n,outputDenseValues:s}=o.raggedGather(I(\"paramsNestedSplits\",r,t,e),I(\"paramsDenseValues\",r,t,e),I(\"indices\",r,t,e),I(\"outputRaggedRank\",r,t,e));return n.concat(s)}case\"RaggedRange\":{let{rtNestedSplits:n,rtDenseValues:s}=o.raggedRange(I(\"starts\",r,t,e),I(\"limits\",r,t,e),I(\"splits\",r,t,e));return[n,s]}case\"RaggedTensorToTensor\":return[o.raggedTensorToTensor(I(\"shape\",r,t,e),I(\"values\",r,t,e),I(\"defaultValue\",r,t,e),I(\"rowPartitionTensors\",r,t,e),I(\"rowPartitionTypes\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var zT=(r,t,e,o=Je)=>{switch(r.op){case\"Max\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.max(I(\"x\",r,t,e),i,p)]}case\"Mean\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.mean(I(\"x\",r,t,e),i,p)]}case\"Min\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.min(I(\"x\",r,t,e),i,p)]}case\"Sum\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.sum(I(\"x\",r,t,e),i,p)]}case\"All\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.all(I(\"x\",r,t,e),i,p)]}case\"Any\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.any(I(\"x\",r,t,e),i,p)]}case\"ArgMax\":{let i=I(\"axis\",r,t,e);return[o.argMax(I(\"x\",r,t,e),i)]}case\"ArgMin\":{let i=I(\"axis\",r,t,e);return[o.argMin(I(\"x\",r,t,e),i)]}case\"Prod\":{let i=I(\"axis\",r,t,e),p=I(\"keepDims\",r,t,e);return[o.prod(I(\"x\",r,t,e),i,p)]}case\"Cumprod\":{let i=I(\"axis\",r,t,e),p=I(\"exclusive\",r,t,e),u=I(\"reverse\",r,t,e);return[o.cumprod(I(\"x\",r,t,e),i,p,u)]}case\"Cumsum\":{let i=I(\"axis\",r,t,e),p=I(\"exclusive\",r,t,e),u=I(\"reverse\",r,t,e);return[o.cumsum(I(\"x\",r,t,e),i,p,u)]}case\"Bincount\":let n=I(\"x\",r,t,e),s=I(\"weights\",r,t,e),a=I(\"size\",r,t,e);return[o.bincount(n,s,a)];case\"DenseBincount\":{let i=I(\"x\",r,t,e),p=I(\"weights\",r,t,e),u=I(\"size\",r,t,e),c=I(\"binaryOutput\",r,t,e);return[o.denseBincount(i,p,u,c)]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var VT=(r,t,e,o=Je)=>{switch(r.op){case\"ConcatV2\":case\"Concat\":{let n=I(\"n\",r,t,e),s=I(\"axis\",r,t,e),a=I(\"tensors\",r,t,e);return a=a.slice(0,n),[o.concat(a,s)]}case\"Gather\":{let n=I(\"x\",r,t,e),s=I(\"indices\",r,t,e);return[o.gather(n,o.cast(s,\"int32\"),0)]}case\"GatherV2\":{let n=I(\"axis\",r,t,e),s=I(\"batchDims\",r,t,e),a=I(\"x\",r,t,e),i=I(\"indices\",r,t,e);return[o.gather(a,o.cast(i,\"int32\"),n,s)]}case\"Reverse\":{let n=I(\"dims\",r,t,e),s=[];for(let i=0;i{let n=I(\"axis\",r,t,e),s=I(\"tensors\",r,t,e),a=s[0].shape,i=o.squeeze(s[0]).shape,p=s.map(u=>{let c=y.arraysEqual(u.shape,a);if(!c&&!y.arraysEqual(o.squeeze(u).shape,i))throw new Error(\"the input tensors shape does not match\");return c?u:o.reshape(u,a)});return[o.stack(p,n)]});case\"Unpack\":{let n=I(\"axis\",r,t,e),s=I(\"tensor\",r,t,e);return o.unstack(s,n)}case\"Tile\":{let n=I(\"reps\",r,t,e);return[o.tile(I(\"x\",r,t,e),n)]}case\"Split\":case\"SplitV\":{let n=I(\"axis\",r,t,e),s=I(\"numOrSizeSplits\",r,t,e),a=I(\"x\",r,t,e);return o.split(a,s,n)}case\"ScatterNd\":{let n=I(\"indices\",r,t,e),s=I(\"values\",r,t,e),a=I(\"shape\",r,t,e);return[o.scatterND(n,s,a)]}case\"GatherNd\":{let n=I(\"x\",r,t,e),s=I(\"indices\",r,t,e);return[o.gatherND(n,s)]}case\"SparseToDense\":{let n=I(\"sparseIndices\",r,t,e),s=I(\"outputShape\",r,t,e),a=I(\"sparseValues\",r,t,e),i=I(\"defaultValue\",r,t,e);return[o.sparseToDense(n,a,s,a.dtype===i.dtype?i:o.cast(i,a.dtype))]}case\"TensorScatterUpdate\":{let n=I(\"indices\",r,t,e),s=I(\"values\",r,t,e),a=I(\"tensor\",r,t,e);return[o.tensorScatterUpdate(a,n,s)]}default:throw TypeError(`Node type ${r.op} is not implemented`)}};var WT=(r,t,e,o=Je)=>{switch(r.op){case\"SparseFillEmptyRows\":{let{outputIndices:n,outputValues:s,emptyRowIndicator:a,reverseIndexMap:i}=o.sparse.sparseFillEmptyRows(I(\"indices\",r,t,e),I(\"values\",r,t,e),I(\"denseShape\",r,t,e),I(\"defaultValue\",r,t,e));return[n,s,a,i]}case\"SparseReshape\":{let{outputIndices:n,outputShape:s}=o.sparse.sparseReshape(I(\"inputIndices\",r,t,e),I(\"inputShape\",r,t,e),I(\"newShape\",r,t,e));return[n,s]}case\"SparseSegmentMean\":return[o.sparse.sparseSegmentMean(I(\"data\",r,t,e),I(\"indices\",r,t,e),I(\"segmentIds\",r,t,e))];case\"SparseSegmentSum\":return[o.sparse.sparseSegmentSum(I(\"data\",r,t,e),I(\"indices\",r,t,e),I(\"segmentIds\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var UT=(r,t,e,o=Je)=>{switch(r.op){case\"FFT\":return[o.fft(I(\"x\",r,t,e))];case\"IFFT\":return[o.ifft(I(\"x\",r,t,e))];case\"RFFT\":return[o.rfft(I(\"x\",r,t,e))];case\"IRFFT\":return[o.irfft(I(\"x\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var GT=(r,t,e,o=Je)=>{switch(r.op){case\"StaticRegexReplace\":return[o.string.staticRegexReplace(I(\"input\",r,t,e),I(\"pattern\",r,t,e),I(\"rewrite\",r,t,e),I(\"replaceGlobal\",r,t,e))];case\"StringNGrams\":{let{nGrams:n,nGramsSplits:s}=o.string.stringNGrams(I(\"data\",r,t,e),I(\"dataSplits\",r,t,e),I(\"separator\",r,t,e),I(\"nGramWidths\",r,t,e),I(\"leftPad\",r,t,e),I(\"rightPad\",r,t,e),I(\"padWidth\",r,t,e),I(\"preserveShortSequences\",r,t,e));return[n,s]}case\"StringSplit\":{let{indices:n,values:s,shape:a}=o.string.stringSplit(I(\"input\",r,t,e),I(\"delimiter\",r,t,e),I(\"skipEmpty\",r,t,e));return[n,s,a]}case\"StringToHashBucketFast\":return[o.string.stringToHashBucketFast(I(\"input\",r,t,e),I(\"numBuckets\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};var HT=(r,t,e,o=Je)=>{switch(r.op){case\"Cast\":return[o.cast(I(\"x\",r,t,e),I(\"dtype\",r,t,e))];case\"ExpandDims\":{let n=I(\"axis\",r,t,e);return[o.expandDims(I(\"x\",r,t,e),n)]}case\"Squeeze\":{let n=I(\"axis\",r,t,e);return[o.squeeze(I(\"x\",r,t,e),n)]}case\"Reshape\":return[o.reshape(I(\"x\",r,t,e),I(\"shape\",r,t,e))];case\"EnsureShape\":return[o.ensureShape(I(\"x\",r,t,e),I(\"shape\",r,t,e))];case\"MirrorPad\":return[o.mirrorPad(I(\"x\",r,t,e),I(\"padding\",r,t,e),I(\"mode\",r,t,e))];case\"PadV2\":case\"Pad\":return[o.pad(I(\"x\",r,t,e),I(\"padding\",r,t,e),I(\"constantValue\",r,t,e))];case\"SpaceToBatchND\":{let n=I(\"blockShape\",r,t,e),s=I(\"paddings\",r,t,e);return[o.spaceToBatchND(I(\"x\",r,t,e),n,s)]}case\"BatchToSpaceND\":{let n=I(\"blockShape\",r,t,e),s=I(\"crops\",r,t,e);return[o.batchToSpaceND(I(\"x\",r,t,e),n,s)]}case\"DepthToSpace\":{let n=I(\"blockSize\",r,t,e),s=I(\"dataFormat\",r,t,e).toUpperCase();return[o.depthToSpace(I(\"x\",r,t,e),n,s)]}case\"BroadcastTo\":return[o.broadcastTo(I(\"x\",r,t,e),I(\"shape\",r,t,e))];case\"BroadcastArgs\":return[o.broadcastArgs(I(\"s0\",r,t,e),I(\"s1\",r,t,e))];default:throw TypeError(`Node type ${r.op} is not implemented`)}};function OS(r,t,e,o,n=De){let s=((a,i,p)=>{switch(a.category){case\"arithmetic\":return n(()=>CT(a,i,p));case\"basic_math\":return n(()=>wT(a,i,p));case\"control\":return TT(a,i,p);case\"convolution\":return n(()=>$T(a,i,p));case\"creation\":return n(()=>ET(a,i,p));case\"dynamic\":return RT(a,i,p);case\"evaluation\":return n(()=>DT(a,i,p));case\"image\":return n(()=>PT(a,i,p));case\"graph\":return n(()=>AT(a,i,p));case\"logical\":return n(()=>OT(a,i,p));case\"matrices\":return n(()=>MT(a,i,p));case\"normalization\":return n(()=>LT(a,i,p));case\"ragged\":return n(()=>BT(a,i,p));case\"reduction\":return n(()=>zT(a,i,p));case\"slice_join\":return n(()=>VT(a,i,p));case\"sparse\":return n(()=>WT(a,i,p));case\"spectral\":return n(()=>UT(a,i,p));case\"string\":return n(()=>GT(a,i,p));case\"transformation\":return n(()=>HT(a,i,p));case\"hash_table\":return FT(a,i,p,o);case\"custom\":let u=pf(a.op);if(u&&u.customExecutor)return u.customExecutor(new wf(a,i,p));throw TypeError(`Custom op ${a.op} is not registered.`);default:throw TypeError(`Unknown op '${a.op}'. File an issue at https://github.com/tensorflow/tfjs/issues so we can add it, or register a custom execution with tf.registerOp()`)}})(r,t,e);return y.isPromise(s)?s.then(a=>[].concat(a)):[].concat(s)}var Ll=class{constructor(t={},e={},o={},n={},s){this.weightMap=t,this.tensorArrayMap=e,this.tensorListMap=o,this.functionMap=n,this.parseNodeNameCache=s,this.rootContext={id:0,frameName:\"\",iterationId:0},this.contexts=[this.rootContext],this.lastId=0,this.generateCurrentContextIds()}newFrame(t,e){return{id:t,frameName:e,iterationId:0}}set currentContext(t){this.contexts!==t&&(this.contexts=t,this.generateCurrentContextIds())}get currentContext(){return this.contexts}get currentContextId(){return this._currentContextIds[0]}get currentContextIds(){return this._currentContextIds}generateCurrentContextIds(){let t=[];for(let e=0;ee.id===0&&e.iterationId===0?\"\":`${e.frameName}-${e.iterationId}`).join(\"/\"):\"\"}enterFrame(t){this.contexts&&(this.lastId++,this.contexts=this.contexts.slice(),this.contexts.push(this.newFrame(this.lastId,t)),this._currentContextIds.unshift(this.contextIdforContexts(this.contexts)))}exitFrame(){if(this.contexts&&this.contexts.length>1)this.contexts=this.contexts.slice(),this.contexts.splice(-1),this.currentContextIds.shift();else throw new Error(\"Cannot exit frame, the context is empty\")}nextIteration(){if(this.contexts&&this.contexts.length>0){this.contexts=this.contexts.slice(),this.lastId++;let t=Object.assign({},this.contexts[this.contexts.length-1]);t.iterationId+=1,t.id=this.lastId,this.contexts.splice(-1,1,t),this._currentContextIds.splice(0,1,this.contextIdforContexts(this.contexts))}else throw new Error(\"Cannot increase frame iteration, the context is empty\")}getWeight(t){return this.weightMap[t]}addTensorArray(t){this.tensorArrayMap[t.id]=t}getTensorArray(t){return this.tensorArrayMap[t]}addTensorList(t){this.tensorListMap[t.id]=t}getTensorList(t){return this.tensorListMap[t]}dispose(t){for(let e in this.tensorArrayMap)this.tensorArrayMap[e].clearAndClose(t);for(let e in this.tensorListMap)this.tensorListMap[e].clearAndClose(t)}};function MS(r,t,e,o){let n=new Set,s=[],a=null,i=null,p=new Set,u=new Set(Object.keys(r).map(m=>Tr(m)[0]));o=o||[];let c=new Set(o.map(m=>Tr(m.name)[0])),l=[...t];for(;l.length>0;){let m=l.pop();if((gu(m)||k8(m)||N8(m))&&a==null&&(a=m,i=a.children.map(d=>d.name).filter(d=>n.has(d))),n.add(m.name),e[m.name]==null&&!u.has(m.name)&&!c.has(m.name)){if(m.inputs.length===0){s.push(m.name);continue}m.inputs.forEach(d=>{p.has(d.name)||(p.add(d.name),l.push(d))})}}return{inputs:r,outputs:t,usedNodes:n,missingInputs:s,dynamicNode:a,syncInputs:i}}function KT(r,t){let{usedNodes:e,inputs:o}=t,n=Object.keys(o).map(g=>Tr(g)[0]).map(g=>r.nodes[g]),s=r.initNodes||[],a=g=>e.has(typeof g==\"string\"?g:g.name);function i(g){return[...new Map(g.map(x=>[x.name,x])).values()]}let p=i([...n,...r.weights,...s]).filter(a),u=i([...p,...Object.values(r.nodes)]).filter(a),c=new Map(u.map(g=>[g.name,g])),l={};for(let g of u){l[g.name]=l[g.name]||0;for(let x of g.children)a(x)||(l[x.name]=Number.POSITIVE_INFINITY),l[x.name]=(l[x.name]||0)+1}let m=Object.entries(l).filter(([,g])=>g===0).map(([g])=>g),d=[...m];for(;m.length>0;){let g=m.pop(),x=c.get(g);for(let b of x.children.filter(a))--l[b.name]===0&&(d.push(b.name),m.push(b.name))}let f=d.map(g=>c.get(g)),h=C8(f,p);return w8(h,p),h}function C8(r,t){let e=new Map(r.map(a=>[a.name,a])),o=t.map(a=>a.name),n=new Set(o);for(;o.length>0;){let a=o.pop(),i=e.get(a);for(let p of i.children)!e.has(p.name)||n.has(p.name)||(n.add(p.name),o.push(p.name))}return r.filter(a=>n.has(a.name))}var Cc=class extends Error{constructor(t){super(`NodesExecutionOrderError: ${t}`)}};function w8(r,t){let e=new Map(r.map((i,p)=>[i.name,p])),o=new Set(t.map(i=>i.name)),n=i=>o.has(typeof i==\"string\"?i:i.name),s=new Set(r.map(i=>i.name)),a=i=>s.has(typeof i==\"string\"?i:i.name);for(let i of r){for(let p of i.children.filter(a)){if(!e.has(p.name))throw new Cc(`Child ${p.name} of node ${i.name} is unreachable.`);if(e.get(i.name)>e.get(p.name))throw new Cc(`Node ${i.name} is scheduled to run after its child ${p.name}.`)}if(!n(i))for(let p of i.inputs){if(!e.has(p.name))throw new Cc(`Input ${p.name} of node ${i.name} is unreachable.`);if(e.get(p.name)>e.get(i.name))throw new Cc(`Node ${i.name} is scheduled to run before its input ${p.name}.`)}}}function qT(r){let t=new Map(r.map((i,p)=>[i.name,p])),e=Number.MAX_SAFE_INTEGER,o=r.map((i,p)=>gu(i)?e:p),n=i=>{let p=o[t.get(i.name)];return p==null?-1:p},s=r.map((i,p)=>i.children.map(n).reduce((u,c)=>Math.max(u,c),o[p])),a=new Map;for(let i=0;it[o].map(n=>n.id));this._weightIds=[].concat(...e),this._weightMap=t}set resourceManager(t){this._resourceManager=t}get inputs(){return this._inputs.map(t=>({name:t.name,shape:t.attrParams.shape?t.attrParams.shape.value:void 0,dtype:t.attrParams.dtype?t.attrParams.dtype.value:void 0}))}get outputs(){return this._outputs.map(t=>({name:t.name,shape:t.attrParams.shape?t.attrParams.shape.value:void 0,dtype:t.attrParams.dtype?t.attrParams.dtype.value:void 0}))}get inputNodes(){return this._inputs.map(t=>t.signatureKey||t.name)}get outputNodes(){return this._outputs.map(t=>{let e=t.signatureKey||t.name;return t.defaultOutput?`${e}:${t.defaultOutput}`:e})}get functions(){return Object.keys(this._functions).reduce((t,e)=>(t[e]=this._functions[e].signature,t),{})}constructor(t,e){this.graph=t,this.parent=e,this.compiledMap=new Map,this.parseNodeNameCache=new Map,this._weightMap={},this.SEPARATOR=\",\",this._functions={},this._functionExecutorMap={},this.keepIntermediateTensors=!1,this._outputs=t.outputs,this._inputs=t.inputs,this._initNodes=t.initNodes,this._signature=t.signature,this._functions=t.functions,t.functions!=null&&Object.keys(t.functions).forEach(o=>{this._functionExecutorMap[o]=new lp(t.functions[o],this)})}getCompilationKey(t,e){let o=t.map(s=>s.name).sort(),n=e.map(s=>s.name).sort();return o.join(this.SEPARATOR)+\"--\"+n.join(this.SEPARATOR)}compile(t,e){let o=MS(t,e,this.weightMap,this._initNodes),{missingInputs:n,dynamicNode:s,syncInputs:a}=o;if(s!=null)throw new Error(`This execution contains the node '${s.name}', which has the dynamic op '${s.op}'. Please use model.executeAsync() instead. Alternatively, to avoid the dynamic ops, specify the inputs [${a}]`);if(n.length>0){let u=e.map(l=>l.name),c=Object.keys(t);throw new Error(`Cannot compute the outputs [${u}] from the provided inputs [${c}]. Missing the following inputs: [${n}]`)}let i=KT(this.graph,o),p=qT(i);return{orderedNodes:i,nodeLiveUntilMap:p}}cloneAndKeepTensor(t){if(t==null)return null;let e=t.clone();return Rr(e),e}cloneTensorList(t){return t?t.map(o=>this.cloneAndKeepTensor(o)):null}cloneTensorMap(t){return Object.fromEntries(Object.entries(t).map(([e,o])=>[e,this.cloneTensorList(o)]))}execute(t,e){this.disposeIntermediateTensors(),t=this.mapInputs(t);let o=Object.keys(t).sort();this.checkInputs(t),this.checkInputShapeAndType(t),e=this.mapOutputs(e),this.checkOutputs(e);let n=o.map(m=>this.graph.nodes[Tr(m)[0]]),s=e.map(m=>Tr(m)[0]),a=new Set(s),i=s.map(m=>this.graph.nodes[m]);i.length===0&&(i=this._outputs);let p=this.getCompilationKey(n,i),u=this.compiledMap.get(p);u==null&&(u=this.compile(t,i),this.compiledMap.set(p,u));try{this.keepIntermediateTensors=A().getBool(\"KEEP_INTERMEDIATE_TENSORS\")}catch(m){this.keepIntermediateTensors=!1,console.warn(m.message)}let c={},l={};return De(()=>{let m=new Ll(this.weightMap,c,l,this.functionExecutorMap,this.parseNodeNameCache),d=Object.assign({},this.weightMap);this.keepIntermediateTensors&&(this.clonedTensorsMap=this.cloneTensorMap(this.weightMap)),Object.keys(t).forEach(x=>{let[b,C]=Tr(x,m),S=[];S[C]=t[x],d[b]=S,this.keepIntermediateTensors&&(this.clonedTensorsMap[b]=this.cloneTensorList(S))});let f=this.getFrozenTensorIds(d),{orderedNodes:h,nodeLiveUntilMap:g}=u;for(let x of h){if(d[x.name])continue;let b=OS(x,d,m,this._resourceManager);if(y.isPromise(b))throw new Error(`The execution of the op '${x.op}' returned a promise. Please use model.executeAsync() instead.`);d[x.name]=b,this.keepIntermediateTensors&&(this.clonedTensorsMap[x.name]=this.cloneTensorList(b)),this.checkTensorForDisposalWithNodeLiveUntilInfo(x,d,m,f,a,g.get(x.name))}return this.parent==null&&m.dispose(f),e.map(x=>zt(x,d,m))})}getFrozenTensorIds(t){let e=[].concat.apply([],Object.keys(t).map(o=>t[o]).map(o=>o.map(n=>n.id)));return new Set(e)}checkTensorForDisposal(t,e,o,n,s,a,i){if(!(gu(e)||a.has(t))){for(let p of o[t])p!=null&&(i[p.id]=(i[p.id]||0)+e.children.length);for(let p of e.inputs){if(gu(p))continue;let u=fS(p.name,o,n);if(u!=null)for(let c of u){if(!c||c.kept||s.has(c.id))continue;let l=i[c.id];l===1?(c.dispose(),delete i[c.id]):l!=null&&i[c.id]--}}}}checkTensorForDisposalWithNodeLiveUntilInfo(t,e,o,n,s,a){function i(p){return gu(p)||s.has(p.name)}if(!(gu(t)||a==null))for(let p of a){if(i(p))continue;let u=fS(p.name,e,o);for(let c of u)!c||c.kept||n.has(c.id)||c.dispose()}}async executeAsync(t,e){return this._executeAsync(t,e)}disposeIntermediateTensors(){this.clonedTensorsMap&&(Object.values(this.clonedTensorsMap).forEach(t=>{for(let e of t)e&&!e.isDisposed&&e.dispose()}),this.clonedTensorsMap=null)}getIntermediateTensors(){return this.clonedTensorsMap}async _executeAsync(t,e,o=!1,n={},s={}){this.disposeIntermediateTensors(),o||(t=this.mapInputs(t),this.checkInputs(t),this.checkInputShapeAndType(t),e=this.mapOutputs(e),this.checkOutputs(e));try{this.keepIntermediateTensors=A().getBool(\"KEEP_INTERMEDIATE_TENSORS\")}catch(m){this.keepIntermediateTensors=!1,console.warn(m.message)}let a=new Ll(this.weightMap,n,s,this.functionExecutorMap,this.parseNodeNameCache);this.keepIntermediateTensors&&(this.clonedTensorsMap=this.cloneTensorMap(this.weightMap));let i=await this.executeWithControlFlow(t,a,e,o),p=e.map(m=>zt(m,i,a)),u=p.map(m=>m.id),c=Object.keys(t).map(m=>t[m].id),l=new Set([...u,...c,...this.weightIds]);return Object.values(i).forEach(m=>{m.forEach(d=>{d&&!d.isDisposed&&!l.has(d.id)&&d.dispose()})}),this.parent==null&&a.dispose(l),p}async executeFunctionAsync(t,e,o){let n=t.reduce((s,a,i)=>(s[this.inputs[i].name]=a,s),{});return this._executeAsync(n,this.outputNodes,!0,e,o)}async executeWithControlFlow(t,e,o,n){let s=Object.keys(t),a=s.map(S=>this.graph.nodes[Tr(S)[0]]),i=o.map(S=>Tr(S)[0]),p=new Set(i),u=i.map(S=>this.graph.nodes[S]);u.length===0&&(u=this._outputs);let{usedNodes:c,missingInputs:l,dynamicNode:m,syncInputs:d}=MS(t,u,this.weightMap,this._initNodes),f=[...a,...this.graph.weights,...this._initNodes||[]].map(S=>({node:S,contexts:e.currentContext})),h=Object.assign({},this.weightMap);Object.keys(t).forEach(S=>{let[k,_]=Tr(S),E=[];E[_]=t[S],h[k]=E});let g={},x=this.getFrozenTensorIds(h),b={};for(;f.length>0;){let S=this.processStack(a,f,e,h,b,x,p,g,c);await Promise.all(S)}m==null&&!n&&console.warn(\"This model execution did not contain any nodes with control flow or dynamic output shapes. You can use model.execute() instead.\");let C=u.filter(S=>!gu(S)&&!zt(S.name,h,e)).map(S=>S.name);if(C.length>0){let S=\"\";throw m!=null&&(S=`Alternatively, to avoid the dynamic ops, use model.execute() and specify the inputs [${d}]`),new Error(`Cannot compute the outputs [${C}] from the provided inputs [${s}]. Consider providing the following inputs: [${l}]. ${S}`)}return h}processStack(t,e,o,n,s,a,i,p,u){let c=[];for(;e.length>0;){let l=e.pop();o.currentContext=l.contexts;let m=\"\";if(l.node.op===\"Enter\"&&I(\"isConstant\",l.node,n,o)&&([m]=Ls(l.node.name,o)),n[l.node.name]==null){let d=OS(l.node,n,o,this._resourceManager);m||([m]=Ls(l.node.name,o));let f=o.currentContext;y.isPromise(d)?c.push(d.then(h=>(n[m]=h,this.keepIntermediateTensors&&(this.clonedTensorsMap[m]=this.cloneTensorList(h)),o.currentContext=f,this.checkTensorForDisposal(m,l.node,n,o,a,i,p),this.processChildNodes(l.node,e,o,n,s,u),h))):(n[m]=d,this.keepIntermediateTensors&&(this.clonedTensorsMap[m]=this.cloneTensorList(d)),this.checkTensorForDisposal(m,l.node,n,o,a,i,p),this.processChildNodes(l.node,e,o,n,s,u))}else this.processChildNodes(l.node,e,o,n,s,u)}return c}processChildNodes(t,e,o,n,s,a){t.children.forEach(i=>{let[p]=Ls(i.name,o);s[p]||!a.has(i.name)||(i.op===\"Merge\"?i.inputNames.some(u=>!!zt(u,n,o))&&(s[p]=!0,e.push({contexts:o.currentContext,node:i})):i.inputNames.every(u=>!!zt(u,n,o))&&(s[p]=!0,e.push({contexts:o.currentContext,node:i})))})}dispose(){Object.keys(this.weightMap).forEach(t=>this.weightMap[t].forEach(e=>e.dispose()))}checkInputShapeAndType(t){Object.keys(t).forEach(e=>{let o=t[e],[n]=Tr(e),s=this.graph.nodes[n];if(s.attrParams.shape&&s.attrParams.shape.value){let a=s.attrParams.shape.value,i=a.length===o.shape.length&&o.shape.every((p,u)=>a[u]===-1||a[u]===p);y.assert(i,()=>`The shape of dict['${s.name}'] provided in model.execute(dict) must be [${a}], but was [${o.shape}]`)}s.attrParams.dtype&&s.attrParams.dtype.value&&y.assert(o.dtype===s.attrParams.dtype.value,()=>`The dtype of dict['${s.name}'] provided in model.execute(dict) must be ${s.attrParams.dtype.value}, but was ${o.dtype}`)})}mapInputs(t){var e,o;let n={};for(let s in t){let a=(o=(e=this._signature)===null||e===void 0?void 0:e.inputs)===null||o===void 0?void 0:o[s];a!=null?n[a.name]=t[s]:n[s]=t[s]}return n}checkInputs(t){let e=Object.keys(t).filter(o=>{let[n]=Tr(o);return this.graph.nodes[n]==null});if(e.length>0)throw new Error(`The dict provided in model.execute(dict) has keys: [${e}] that are not part of graph`)}mapOutputs(t){return t.map(e=>{var o,n;let s=(n=(o=this._signature)===null||o===void 0?void 0:o.outputs)===null||n===void 0?void 0:n[e];return s!=null?s.name:e},{})}checkOutputs(t){t.forEach(e=>{let[o]=Tr(e);if(!this.graph.nodes[o])throw new Error(`The output '${e}' is not found in the graph`)})}};var kf=class{constructor(t={},e={}){this.hashTableNameToHandle=t,this.hashTableMap=e}addHashTable(t,e){this.hashTableNameToHandle[t]=e.handle,this.hashTableMap[e.id]=e}getHashTableHandleByName(t){return this.hashTableNameToHandle[t]}getHashTableById(t){return this.hashTableMap[t]}dispose(){for(let t in this.hashTableMap)this.hashTableMap[t].clearAndClose(),delete this.hashTableMap[t];for(let t in this.hashTableNameToHandle)this.hashTableNameToHandle[t].dispose(),delete this.hashTableNameToHandle[t]}};var T8=\"?tfjs-format=file\",_8=\"model.json\",Bl=class{get modelVersion(){return this.version}get inputNodes(){return this.executor.inputNodes}get outputNodes(){return this.executor.outputNodes}get inputs(){return this.executor.inputs}get outputs(){return this.executor.outputs}get weights(){return this.executor.weightMap}get metadata(){return this.artifacts.userDefinedMetadata}get modelSignature(){return this.signature}get modelStructuredOutputKeys(){return this.structuredOutputKeys}constructor(t,e={},o=fi){this.modelUrl=t,this.loadOptions=e,this.version=\"n/a\",this.io=o,e==null&&(this.loadOptions={}),this.resourceManager=new kf}findIOHandler(){let t=this.modelUrl;if(t.load!=null)this.handler=t;else if(this.loadOptions.requestInit!=null)this.handler=this.io.browserHTTPRequest(t,this.loadOptions);else{let e=this.io.getLoadHandlers(t,this.loadOptions);if(e.length===0)e.push(this.io.browserHTTPRequest(t,this.loadOptions));else if(e.length>1)throw new Error(`Found more than one (${e.length}) load handlers for URL '${[t]}'`);this.handler=e[0]}}load(){if(this.findIOHandler(),this.handler.load==null)throw new Error(\"Cannot proceed with model loading because the IOHandler provided does not have the `load` method implemented.\");let t=this.handler.load();return y.isPromise(t)?t.then(e=>this.loadSync(e)):this.loadSync(t)}loadSync(t){this.artifacts=t;let e=this.artifacts.modelTopology,o=this.artifacts.signature;if(this.artifacts.userDefinedMetadata!=null){let s=this.artifacts.userDefinedMetadata;s.signature!=null&&(o=s.signature),s.structuredOutputKeys!=null&&(this.structuredOutputKeys=s.structuredOutputKeys)}this.signature=o,this.version=`${e.versions.producer}.${e.versions.minConsumer}`;let n=this.io.decodeWeights(this.artifacts.weightData,this.artifacts.weightSpecs);if(this.executor=new lp(Ml.Instance.transformGraph(e,this.signature)),this.executor.weightMap=this.convertTensorMapToTensorsMap(n),this.executor.resourceManager=this.resourceManager,t.modelInitializer!=null&&t.modelInitializer.node!=null){let s=Ml.Instance.transformGraph(t.modelInitializer);this.initializer=new lp(s),this.initializer.weightMap=this.executor.weightMap,this.initializer.resourceManager=this.resourceManager,this.initializerSignature=t.initializerSignature}return!0}async save(t,e){if(typeof t==\"string\"){let o=this.io.getSaveHandlers(t);if(o.length===0)throw new Error(`Cannot find any save handlers for URL '${t}'`);if(o.length>1)throw new Error(`Found more than one (${o.length}) save handlers for URL '${t}'`);t=o[0]}if(t.save==null)throw new Error(\"GraphModel.save() cannot proceed because the IOHandler provided does not have the `save` attribute defined.\");return t.save(this.artifacts)}addStructuredOutputNames(t){if(this.structuredOutputKeys){let e=t instanceof ut?[t]:t,o={};return e.forEach((n,s)=>o[this.structuredOutputKeys[s]]=n),o}return t}predict(t,e){let o=this.execute(t,this.outputNodes);return this.addStructuredOutputNames(o)}async predictAsync(t,e){let o=await this.executeAsync(t,this.outputNodes);return this.addStructuredOutputNames(o)}normalizeInputs(t){var e;if(!(t instanceof ut)&&!Array.isArray(t)){let s=(e=this.signature)===null||e===void 0?void 0:e.inputs;if(s!=null)for(let a in s){let i=s[a];i.resourceId!=null&&(t[a]=this.resourceIdToCapturedInput[i.resourceId])}return t}t=Array.isArray(t)?t:[t];let o=Object.keys(this.resourceIdToCapturedInput).length;if(t.length+o!==this.inputNodes.length)throw new Error(`Input tensor count mismatch, the graph model has ${this.inputNodes.length-o} non-resource placeholders, while there are ${t.length} input tensors provided.`);let n=0;return this.inputNodes.reduce((s,a)=>{var i,p,u;let c=(u=(p=(i=this.signature)===null||i===void 0?void 0:i.inputs)===null||p===void 0?void 0:p[a])===null||u===void 0?void 0:u.resourceId;return c!=null?s[a]=this.resourceIdToCapturedInput[c]:s[a]=t[n++],s},{})}normalizeOutputs(t){return t=t||this.outputNodes,Array.isArray(t)?t:[t]}executeInitializerGraph(){return this.initializer==null?[]:this.initializerSignature==null?this.initializer.execute({},[]):this.initializer.execute({},Object.keys(this.initializerSignature.outputs))}async executeInitializerGraphAsync(){return this.initializer==null?[]:this.initializerSignature==null?this.initializer.executeAsync({},[]):this.initializer.executeAsync({},Object.keys(this.initializerSignature.outputs))}setResourceIdToCapturedInput(t){if(this.resourceIdToCapturedInput={},this.initializerSignature){let e=this.initializerSignature.outputs,o=Object.keys(e);for(let n=0;n1?o:o[0]}async executeAsync(t,e){this.resourceIdToCapturedInput==null&&this.setResourceIdToCapturedInput(await this.executeInitializerGraphAsync()),t=this.normalizeInputs(t),e=this.normalizeOutputs(e);let o=await this.executor.executeAsync(t,e);return o.length>1?o:o[0]}getIntermediateTensors(){return this.executor.getIntermediateTensors()}disposeIntermediateTensors(){this.executor.disposeIntermediateTensors()}convertTensorMapToTensorsMap(t){return Object.keys(t).reduce((e,o)=>(e[o]=[t[o]],e),{})}dispose(){this.executor.dispose(),this.initializer&&(this.initializer.dispose(),this.resourceIdToCapturedInput&&Mt(this.resourceIdToCapturedInput)),this.resourceManager.dispose()}};async function $8(r,t={},e=fi){if(r==null)throw new Error(\"modelUrl in loadGraphModel() cannot be null. Please provide a url or an IOHandler that loads the model\");t==null&&(t={}),t.fromTFHub&&typeof r==\"string\"&&(r=R8(r));let o=new Bl(r,t,e);return await o.load(),o}function E8(r){if(r==null)throw new Error(\"modelUrl in loadGraphModelSync() cannot be null. Please provide model artifacts or an IOHandler that loads the model\");let t;if(r instanceof Array){let[o,n]=r;if(!o)throw new Error(\"modelJSON must be the first element of the array\");if(!n||!(n instanceof ArrayBuffer))throw new Error(\"An ArrayBuffer of weights must be the second element of the array\");if(!(\"modelTopology\"in o))throw new Error(\"Model JSON is missing 'modelTopology'\");if(!(\"weightsManifest\"in o))throw new Error(\"Model JSON is missing 'weightsManifest'\");let s=fi.getWeightSpecs(o.weightsManifest),a=fi.getModelArtifactsForJSONSync(o,s,n);t=fi.fromMemorySync(a)}else if(\"load\"in r)t=r;else if(\"modelTopology\"in r&&\"weightSpecs\"in r&&\"weightData\"in r)t=fi.fromMemorySync(r);else throw new Error(\"Unknown model format\");let e=new Bl(t);return e.load(),e}function R8(r){return r.endsWith(\"/\")||(r=r+\"/\"),`${r}${_8}${T8}`}var D8=\"4.11.0\";function Q(r,t){Array.isArray(r)||(r=[r]),r.forEach(e=>{e!=null&&y.assert(e.dtype!==\"complex64\",()=>`${t} does not support complex64 tensors in the CPU backend.`)})}var A8=Wt.whereImpl,xu=class extends ao{nextDataId(){return xu.nextDataId++}constructor(){super(),this.blockSize=48,this.firstUse=!0,this.data=new zo(this,pr())}write(t,e,o){this.firstUse&&(this.firstUse=!1,A().get(\"IS_NODE\")&&w.warn(`\n============================\nHi, looks like you are running TensorFlow.js in Node.js. To speed things up dramatically, install our node backend, visit https://github.com/tensorflow/tfjs-node for more details. \n============================`));let n={id:this.nextDataId()};return this.data.set(n,{values:t,dtype:o,refCount:1}),n}makeTensorInfo(t,e,o){let n;if(e===\"string\"&&o!=null&&o.length>0&&y.isString(o[0])){let s=o.map(a=>y.encodeString(a));n=this.write(s,t,e)}else n=this.write(o,t,e);return{dataId:n,shape:t,dtype:e}}refCount(t){return this.data.has(t)?this.data.get(t).refCount:0}incRef(t){let e=this.data.get(t);e.refCount++}decRef(t){if(this.data.has(t)){let e=this.data.get(t);e.refCount--}}move(t,e,o,n,s){this.data.set(t,{values:e,dtype:n,refCount:s})}numDataIds(){return this.data.numDataIds()}async read(t){return this.readSync(t)}readSync(t){let{dtype:e,complexTensorInfos:o}=this.data.get(t);if(e===\"complex64\"){let n=this.readSync(o.real.dataId),s=this.readSync(o.imag.dataId);return w.mergeRealAndImagArrays(n,s)}return y.convertBackendValuesAndArrayBuffer(this.data.get(t).values,e)}bufferSync(t){let e=this.readSync(t.dataId);if(t.dtype===\"string\")try{let o=e.map(n=>y.decodeString(n));return me(t.shape,t.dtype,o)}catch(o){throw new Error(\"Failed to decode encoded string bytes into utf-8\")}return me(t.shape,t.dtype,e)}makeOutput(t,e,o){return pr().makeTensorFromTensorInfo(this.makeTensorInfo(e,o,t),this)}disposeData(t,e=!1){if(this.data.has(t)){if(this.data.get(t).refCount--,!e&&this.data.get(t).refCount>0)return!1;let{complexTensorInfos:o}=this.data.get(t);o!=null&&(this.disposeData(o.real.dataId,!0),this.disposeData(o.imag.dataId,!0)),this.data.delete(t)}return!0}disposeIntermediateTensorInfo(t){this.disposeData(t.dataId)}async time(t){let e=y.now();return t(),{kernelMs:y.now()-e}}memory(){return{unreliable:!0,reasons:[\"The reported memory is an upper bound. Due to automatic garbage collection, the true allocated memory may be less.\"]}}where(t){Q([t],\"where\");let e=this.readSync(t.dataId);return A8(t.shape,e)}dispose(){}floatPrecision(){return 32}epsilon(){return super.epsilon()}};xu.nextDataId=0;var Tc={};qe(Tc,{addImpl:()=>zS,bincountImpl:()=>Ic,bincountReduceImpl:()=>Nf,bitwiseAndImpl:()=>VS,castImpl:()=>BS,ceilImpl:()=>WS,concatImpl:()=>mp,equalImpl:()=>US,expImpl:()=>HS,expm1Impl:()=>qS,floorDivImpl:()=>XS,floorImpl:()=>jS,gatherNdImpl:()=>Tf,gatherV2Impl:()=>_f,greaterEqualImpl:()=>QS,greaterImpl:()=>YS,lessEqualImpl:()=>JS,lessImpl:()=>ZS,linSpaceImpl:()=>$f,logImpl:()=>eI,maxImpl:()=>Ef,maximumImpl:()=>tI,minimumImpl:()=>rI,multiplyImpl:()=>zl,negImpl:()=>oI,notEqualImpl:()=>nI,prodImpl:()=>sI,raggedGatherImpl:()=>Rf,raggedRangeImpl:()=>Df,raggedTensorToTensorImpl:()=>Af,rangeImpl:()=>fp,rsqrtImpl:()=>aI,scatterImpl:()=>zs,sigmoidImpl:()=>v_,simpleAbsImpl:()=>LS,sliceImpl:()=>hp,sparseFillEmptyRowsImpl:()=>Ff,sparseReshapeImpl:()=>Pf,sparseSegmentReductionImpl:()=>Nc,sqrtImpl:()=>T_,squaredDifferenceImpl:()=>uI,staticRegexReplaceImpl:()=>pI,stridedSliceImpl:()=>Of,stringNGramsImpl:()=>gp,stringSplitImpl:()=>xp,stringToHashBucketFastImpl:()=>yp,subImpl:()=>lI,tileImpl:()=>Mf,topKImpl:()=>Lf,transposeImpl:()=>vc,uniqueImpl:()=>bp});function LS(r){let t=new Float32Array(r.length);for(let e=0;e{let{x:t}=r.inputs,e=r.backend;Q(t,\"abs\");let o=new Float32Array(y.sizeFromShape(t.shape)),n=e.data.get(t.dataId).values;return o=LS(n),e.makeOutput(o,t.shape,t.dtype)},jT={kernelName:Xs,backendName:\"cpu\",kernelFunc:F8};function ze(r){return(t,e,o,n,s)=>{let a=w.assertAndGetBroadcastShape(t,e),i=a.length,p=y.computeStrides(a),u=y.sizeFromShape(a),c=y.getTypedArrayFromDType(s,u),l=t.length,m=e.length,d=y.computeStrides(t),f=y.computeStrides(e),h=w.getBroadcastDims(t,a),g=w.getBroadcastDims(e,a);if(h.length+g.length===0)for(let x=0;xC[E]=0);let S=y.locToIndex(C,l,d),k=b.slice(-m);g.forEach(E=>k[E]=0);let _=y.locToIndex(k,m,f);c[x]=r(o[S],n[_])}return[c,a]}}function Kt(r){let{inputs:t,backend:e}=r,{real:o,imag:n}=t,s=e.data.get(o.dataId).values,a=e.data.get(n.dataId).values,i=e.makeTensorInfo(o.shape,\"complex64\"),p=e.data.get(i.dataId);return p.complexTensorInfos={real:e.makeTensorInfo(o.shape,\"float32\",s),imag:e.makeTensorInfo(n.shape,\"float32\",a)},i}var XT={kernelName:Fi,backendName:\"cpu\",kernelFunc:Kt};function wc(r,t,e=\"float32\"){if(e===\"complex64\"){let n=wc(r,t,\"float32\"),s=wc(r,t,\"float32\");return Kt({inputs:{real:n,imag:s},backend:r})}let o=y.makeZerosTypedArray(y.sizeFromShape(t),e);return r.makeTensorInfo(t,e,o)}function mr(r){let{inputs:t,backend:e}=r,{x:o}=t;return e.incRef(o.dataId),{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}var YT={kernelName:wo,backendName:\"cpu\",kernelFunc:mr};function Ro(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.data.get(o.dataId).complexTensorInfos.real,s=e.data.get(n.dataId).values;return e.makeTensorInfo(n.shape,n.dtype,s)}var QT={kernelName:qi,backendName:\"cpu\",kernelFunc:Ro};function BS(r,t,e,o){if(o===\"int32\"){let n=Int32Array.from(r);return[t,\"int32\",n]}if(o===\"bool\"){let n=y.toTypedArray([0],e),[s,a]=ze((i,p)=>i!==p?1:0)(t,[],r,n,\"bool\");return[a,\"bool\",s]}throw new Error(`Error in Cast: failed to cast ${e} to ${o}`)}function Do(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dtype:s}=o;if(s===\"complex64\"){if(n.dtype===\"complex64\")return mr({inputs:{x:n},backend:e});let c=wc(e,n.shape,n.dtype),l=Do({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}}),m=Kt({inputs:{real:l,imag:c},backend:e});return e.disposeIntermediateTensorInfo(c),e.disposeIntermediateTensorInfo(l),m}if(n.dtype===\"complex64\"){let c=Ro({inputs:{input:n},backend:e}),l=Do({inputs:{x:c},backend:e,attrs:{dtype:s}});return e.disposeIntermediateTensorInfo(c),l}if(!y.hasEncodingLoss(n.dtype,s)){let c=mr({inputs:{x:n},backend:e});return{dataId:c.dataId,shape:c.shape,dtype:s}}let a=e.data.get(n.dataId).values,[i,p,u]=BS(a,n.shape,n.dtype,s);return e.makeTensorInfo(i,p,u)}var ZT={kernelName:bo,backendName:\"cpu\",kernelFunc:Do};function Ye(r,t,e,o){return e==null?({inputs:n,backend:s})=>{let{a,b:i}=n,p=s;Q([a,i],r);let u=p.data.get(a.dataId).values,c=p.data.get(i.dataId).values,l=a.dtype===\"string\"?w.fromUint8ToStringArray(u):u,m=a.dtype===\"string\"?w.fromUint8ToStringArray(c):c,d=o||a.dtype,[f,h]=t(a.shape,i.shape,l,m,d);return p.makeTensorInfo(h,d,f)}:({inputs:n,backend:s})=>{let{a,b:i}=n,p=s;if(a.dtype===\"complex64\"||i.dtype===\"complex64\"){let u=Do({inputs:{x:a},backend:p,attrs:{dtype:\"complex64\"}}),c=p.data.get(u.dataId),l=c.complexTensorInfos.real,m=c.complexTensorInfos.imag,d=p.data.get(l.dataId).values,f=p.data.get(m.dataId).values,h=Do({inputs:{x:i},backend:p,attrs:{dtype:\"complex64\"}}),g=p.data.get(h.dataId),x=g.complexTensorInfos.real,b=g.complexTensorInfos.imag,C=p.data.get(x.dataId).values,S=p.data.get(b.dataId).values,[k,_,E]=e(a.shape,i.shape,d,f,C,S),R=p.makeTensorInfo(E,\"float32\",k),D=p.makeTensorInfo(E,\"float32\",_),P=Kt({inputs:{real:R,imag:D},backend:p});return p.disposeIntermediateTensorInfo(u),p.disposeIntermediateTensorInfo(h),p.disposeIntermediateTensorInfo(R),p.disposeIntermediateTensorInfo(D),P}else{let u=p.data.get(a.dataId).values,c=p.data.get(i.dataId).values,l=o||a.dtype,[m,d]=t(a.shape,i.shape,u,c,l);return p.makeTensorInfo(d,l,m)}}}function Sc(r){return(t,e,o,n,s,a)=>{let i=w.assertAndGetBroadcastShape(t,e),p=y.sizeFromShape(i),u=i.length,c=y.computeStrides(i),l=y.getTypedArrayFromDType(\"float32\",p),m=y.getTypedArrayFromDType(\"float32\",p),d=w.getBroadcastDims(t,i),f=w.getBroadcastDims(e,i),h=w.mergeRealAndImagArrays(o,n),g=w.mergeRealAndImagArrays(s,a),x=t.length,b=y.computeStrides(t),C=e.length,S=y.computeStrides(e);if(d.length+f.length===0)for(let k=0;kE[M]=0);let R=y.locToIndex(E,x,b),D=_.slice(-C);f.forEach(M=>D[M]=0);let P=y.locToIndex(D,C,S),O=r(h[R*2],h[R*2+1],g[P*2],g[P*2+1]);l[k]=O.real,m[k]=O.imag}return[l,m,i]}}var zS=ze((r,t)=>r+t),P8=Sc((r,t,e,o)=>({real:r+e,imag:t+o})),Oa=Ye(uo,zS,P8),JT={kernelName:uo,backendName:\"cpu\",kernelFunc:Oa};function Ic(r,t,e,o,n){let s=y.sizeFromShape(o),a=y.makeZerosTypedArray(n,e);for(let i=0;i=n||(s>0?a[p]+=t[i]:a[p]+=1)}return a}function Nf(r,t,e,o=!1){let n=r.shape[0],s=r.shape[1],a=me([n,e],t.dtype);for(let i=0;i=e||(o?a.set(1,i,u):t.size>0?a.set(a.get(i,u)+t.get(i,p),i,u):a.set(a.get(i,u)+1,i,u))}return a}var VS=ze((r,t)=>r&t),O8=Ye(ja,VS),e_={kernelName:ja,backendName:\"cpu\",kernelFunc:O8};function Xt(r){return(t,e,o)=>{let n=y.getArrayFromDType(e,t.length);for(let s=0;s{let{x:a}=o;Q(a,r);let i=s,p=i.data.get(a.dataId).values,u;if(a.dtype===\"string\"){if(!Array.isArray(p))throw new Error(\"String tensor's value was not an instance of Array\");u=w.fromUint8ToStringArray(p)}else u=p;let c=e||a.dtype,l=t(u,c,n);return i.makeTensorInfo(a.shape,c,l)}}var WS=Xt(r=>Math.ceil(r)),M8=Ar(tn,WS),t_={kernelName:tn,backendName:\"cpu\",kernelFunc:M8};function mp(r,t,e,o){let n=y.getArrayFromDType(e,y.sizeFromShape(t));if(o&&e!==\"string\"){let s=0;r.forEach(a=>{let i=y.sizeFromShape(a.shape);n.set(a.vals,s),s+=i})}else{let s=0;r.forEach(a=>{let i=e===\"string\"?w.fromUint8ToStringArray(a.vals):a.vals,p=0;for(let u=0;ur===t?1:0),GS=Ye(yn,US,null,\"bool\"),r_={kernelName:yn,backendName:\"cpu\",kernelFunc:GS};var HS=Xt(r=>Math.exp(r)),KS=Ar(bn,HS,\"float32\"),o_={kernelName:bn,backendName:\"cpu\",kernelFunc:KS};var qS=Xt(r=>Math.expm1(r)),L8=Ar(Cn,qS),n_={kernelName:Cn,backendName:\"cpu\",kernelFunc:L8};var jS=Xt(r=>Math.floor(r)),B8=Ar(Sn,jS),s_={kernelName:Sn,backendName:\"cpu\",kernelFunc:B8};var XS=ze((r,t)=>Math.floor(r/t)),z8=Ye(In,XS,null,\"int32\"),a_={kernelName:In,backendName:\"cpu\",kernelFunc:z8};function Tf(r,t,e,o,n,s,a,i,p){let u=me([o,s],e);for(let c=0;c=p/s)throw new Error(`Invalid indices: ${l} does not index into ${i}`);for(let d=0;dr>t?1:0),V8=Ye(Nn,YS,null,\"bool\"),i_={kernelName:Nn,backendName:\"cpu\",kernelFunc:V8};var QS=ze((r,t)=>r>=t?1:0),W8=Ye(Tn,QS,null,\"bool\"),u_={kernelName:Tn,backendName:\"cpu\",kernelFunc:W8};var ZS=ze((r,t)=>rr<=t?1:0),G8=Ye(An,JS,null,\"bool\"),c_={kernelName:An,backendName:\"cpu\",kernelFunc:G8};function $f(r,t,e){let o=(t-r)/(e-1),n=y.makeZerosTypedArray(e,\"float32\");n[0]=r;for(let s=1;sMath.log(r)),H8=Ar(Pn,eI),l_={kernelName:Pn,backendName:\"cpu\",kernelFunc:H8};function Ef(r,t,e,o){let n=y.getTypedArrayFromDType(o,y.sizeFromShape(e));for(let s=0;si)&&(i=u)}n[s]=i}return n}var tI=ze((r,t)=>Math.max(r,t)),K8=Ye(Wn,tI),m_={kernelName:Wn,backendName:\"cpu\",kernelFunc:K8};var rI=ze((r,t)=>Math.min(r,t)),q8=Ye(Kn,rI),d_={kernelName:Kn,backendName:\"cpu\",kernelFunc:q8};var zl=ze((r,t)=>r*t),j8=Sc((r,t,e,o)=>({real:r*e-t*o,imag:r*o+t*e})),dp=Ye(Yn,zl,j8),f_={kernelName:Yn,backendName:\"cpu\",kernelFunc:dp};function oI(r,t,e){let o=y.createScalarValue(-1,e);return zl([],t,o,r,e)}function X8(r){let{inputs:t,backend:e}=r,{x:o}=t;Q(o,\"neg\");let n=e.data.get(o.dataId).values,[s,a]=oI(n,o.shape,o.dtype);return e.makeTensorInfo(a,o.dtype,s)}var h_={kernelName:pa,backendName:\"cpu\",kernelFunc:X8};var nI=ze((r,t)=>r!==t?1:0),Y8=Ye(Qn,nI,null,\"bool\"),g_={kernelName:Qn,backendName:\"cpu\",kernelFunc:Y8};function vc(r,t,e,o,n){let s=t.length,a=y.sizeFromShape(t),i=y.computeStrides(t),p=y.computeStrides(n),u=y.getTypedArrayFromDType(e,y.sizeFromShape(n));for(let c=0;ce.disposeIntermediateTensorInfo(b)),e.makeTensorInfo(x,g,f)}var y_={kernelName:ns,backendName:\"cpu\",kernelFunc:Q8};function Z8(r,t,e){r.forEach((o,n)=>{if(o<0||o>=e){let s=y.indexToLoc(n,t.length,y.computeStrides(t)).join(\",\");throw new Error(`indices[${s}] = ${o} is not in [0, ${e})`)}})}function J8(r,t){for(let e=0;en)throw new Error(\"Ragged splits must not point past values\");for(let s=1;so[s])throw new Error(\"Ragged splits must be sorted in ascending order\")}}function eY(r,t,e,o){let n=[],s=0,a=t.length-1+e.length,i=new Array(a).fill(null).map(()=>[0]);J8(e,o);let p=1;for(let u=0;u=0){let h=i[f],g=h[h.length-1]-d[c];for(let x=c;xn[a]=s)}return t}function b_(r,t){let e=r.slice(0,t);for(;e.length1)throw new Error(\"starts must be a scalar or vector\");if(n.length>1)throw new Error(\"limits must be a scalar or vector\");if(a.length>1)throw new Error(\"deltas must be a scalar or vector\");let i=t.length===0,p=n.length===0,u=a.length===0,c=[];i||c.push(t[0]),p||c.push(n[0]),u||c.push(a[0]);for(let g=1;g0&&bx)S=0;else if(S=Math.ceil(Math.abs((b-x)/C)),S>C_)throw new Error(`Requires ((limit - start) / delta) <= ${C_}`);m[g+1]=m[g]+S}let d=m[l],f=y.getArrayFromDType(e,d),h=0;for(let g=0;go&&(o=s)}return o}static getMaxWidthValueRowID(t){let e=t.length;if(e===0)return 0;let o=0,n=t[0],s=0;for(let a=1;a\"Final length of result must be equal to firstDimension.\"),s}calculateOutputIndexRowSplit(t,e,o,n){let s=t.length,a=[];for(let i=0;i0&&a.length!==t[s-1])throw new Error(\"Invalid row split size.\");return a}calculateOutputIndexValueRowID(t,e,o,n){let s=t.length,a=[];if(s===0)return[];let i=0,p=t[0];if(p>=e.length)throw new Error(`Got currentValueRowId=${p}, which is not less than ${e.length}`);let u=e[p];a.push(u);for(let c=1;c=0&&(++i,i=e.length)throw new Error(`Got nextValueRowId=${l} which is not less than ${e.length}`);u=e[l]}a.push(u)}if(a.length!==t.length)throw new Error(\"Invalid row ids.\");return a}calculateOutputIndex(t,e,o,n){let s=this.getRowPartitionTensor(t),a=this.getRowPartitionTypeByDimension(t);switch(a){case Ao.VALUE_ROWIDS:return this.calculateOutputIndexValueRowID(s,e,o,n);case Ao.ROW_SPLITS:if(s.length-1>e.length)throw new Error(`Row partition size is greater than output size: ${s.length-1} > ${e.length}`);return this.calculateOutputIndexRowSplit(s,e,o,n);default:throw new Error(`Unsupported partition type: ${Ao[a]}`)}}getFirstDimensionSize(){let t=this.rowPartitionValues[0];if(this.rowPartitionTypes.length===0)throw new Error(\"No row_partition_types given.\");let e=this.rowPartitionTypes[0];switch(e){case Ao.FIRST_DIM_SIZE:return t[0];case Ao.VALUE_ROWIDS:throw new Error(\"Cannot handle VALUE_ROWIDS in first dimension.\");case Ao.ROW_SPLITS:return this.rowPartitionValuesShapes[0][0]-1;default:throw new Error(`Cannot handle type ${Ao[e]}`)}}compute(){if(this.rowPartitionValues[0].length<=0)throw new Error(\"Invalid first partition input. Tensor requires at least one element.\");let e=this.getFirstDimensionSize(),o=this.calculateOutputSize(e),n=new Array(this.raggedRank+1);n[n.length-1]=1;for(let p=n.length-2;p>=0;--p)n[p]=n[p+1]*o[p+1];let s=S_(o,!1),a=y.getArrayFromDType(this.valuesDType,y.sizeFromShape(s));if(n[0]*o[0]>0){let p=this.calculateFirstParentOutputIndex(e,n[0],o[0]);for(let u=1;u<=this.raggedRank;++u)p=this.calculateOutputIndex(u-1,p,n[u],o[u]);this.setOutput(this.raggedRank,p,a,s)}return[s,a]}setOutput(t,e,o,n){if(o.length===0)return;let s=this.values,a=o,i=n.slice();i=i.slice(t+1);let p=y.sizeFromShape(i),u=e.length,c=this.defaultValue;if(c.length!==p&&c.length!==1){let f=this.defaultValueShape;De(()=>{let h=W(c,f);c=iu(h,i).dataSync()})}let l=0,m=0,d=0;for(let f=0;f<=u;++f){let h=f=u){let g=o.length;h=Math.floor(g/p)}if(h>d)if(this.defaultValue.length===1)a.subarray(d*p,h*p).fill(this.defaultValue[0]),d=h;else for(;h>d;){let g=a.slice(d*p);w_(g,c,p),++d}h<0?(l=f+1,m=d):(l=f,m=d,d=m+1)}}};function w_(r,t,e){for(let o=0;o= 0`);if(o<-1)throw new Error(`Dimension ${o} must be >= -1`);o=-1}e.push(o)}return e}function Af(r,t,e,o,n,s,a,i,p,u){return new kc(r,t,e,o,n,s,a,i,p,u).compute()}function fp(r,t,e,o){let n=r===t,s=r1;if(n||s||a)return y.makeZerosTypedArray(0,o);let i=Math.abs(Math.ceil((t-r)/e)),p=y.makeZerosTypedArray(i,o);t1/Math.sqrt(r)),nY=Ar(ms,aI),I_={kernelName:ms,backendName:\"cpu\",kernelFunc:nY};function zs(r,t,e,o,n,s,a,i,p,u){let c=[o/n,n],l=r.values,m=t.values;if(o===0)return me(e,t.dtype);let d=p instanceof tt?p:me(c,t.dtype);typeof p==\"string\"||typeof p==\"number\"?d.values.fill(p):typeof p==\"boolean\"&&d.values.fill(+p);for(let f=0;f=o/n)throw new Error(`Invalid indices: ${h} does not index into ${e}`);for(let x=0;x1/(1+Math.exp(-r))),iI=Ie(Cs,r=>1/(1+Math.exp(-r))),k_={kernelName:Cs,backendName:\"cpu\",kernelFunc:iI};function hp(r,t,e,o,n){let s=ct.isSliceContinous(o,t,e),a=y.sizeFromShape(e),i=y.computeStrides(o);if(s){let l=ct.computeFlatOffset(t,i);return n===\"string\"?r.slice(l,l+a):r.subarray(l,l+a)}let p=n===\"string\"?w.fromUint8ToStringArray(r):r,u=me(o,n,p),c=me(e,n);for(let l=0;lf+t[h]);c.set(u.get(...d),...m)}return n===\"string\"?w.fromStringArrayToUint8(c.values):c.values}function Fo(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,size:a}=o;Q(n,\"slice\");let[i,p]=ct.parseSliceParams(n,s,a);ct.assertParamsValid(n,i,p);let u=e.data.get(n.dataId).values,c=hp(u,i,p,n.shape,n.dtype);return e.makeTensorInfo(p,n.dtype,c)}var N_={kernelName:ha,backendName:\"cpu\",kernelFunc:Fo};function Ff(r,t,e,o,n,s,a){let i=t[0],p=s[0],u=new Array(p),c=new Array(i),l=t[1];if(p===0){if(i!==0)throw new Error(w.getSparseFillEmptyRowsIndicesDenseShapeMismatch(i));let g=y.getArrayFromDType(e,0),x=y.getArrayFromDType(n,0);return[g,[0,l],x,u,c]}let m=!0,d=0,f=new Array(p).fill(0);for(let g=0;g=p)throw new Error(w.getSparseFillEmptyRowsOutOfRangeIndexErrorMessage(g,x,p));++f[x],m=m&&x>=d,d=x}let h=!0;for(let g=0;g0&&(f[g]+=f[g-1])}if(h&&m){let g=r,x=o;for(let b=0;b0){d[m-1]=1;for(let g=m-2;g>=0;--g)d[g]=d[g+1]*o[g+1]}let f=[];if(i>0){f[i-1]=1;for(let g=i-2;g>=0;--g)f[g]=f[g+1]*p[g+1]}let h=y.getArrayFromDType(e,a*i);for(let g=0;g0?n[i-1]+1:0;if(l<0)throw new Error(w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage());let m=t.slice();m[0]=l;let d=m.reduce((C,S)=>C*S,1),f=y.getArrayFromDType(e,d);if(i===0)return l>0&&f.fill(a),[f,m];if(l<=0)throw new Error(w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage());let h=0,g=1,x=0,b=n[h];for(;;){let C=0;if(g=C)throw new Error(w.getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage())}if(b<0||b>=l)throw new Error(w.getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage(b,l));b>x&&f.fill(a,x*u,b*u);for(let S=h;S=p[0])throw new Error(w.getSparseSegmentReductionIndicesOutOfRangeErrorMessage(S,o[S],p[0]));for(let _=0;_i)break}return xMath.sqrt(r)),sY=Ie(Ss,r=>Math.sqrt(r)),__={kernelName:Ss,backendName:\"cpu\",kernelFunc:sY};var uI=ze((r,t)=>{let e=r-t;return e*e}),aY=Ye(Ns,uI),$_={kernelName:Ns,backendName:\"cpu\",kernelFunc:aY};var pI=Xt((r,t)=>{let{pattern:e,replaceGlobal:o,rewrite:n}=t;return r.replace(new RegExp(e,o?\"g\":\"\"),n)}),iY=Ar(Ou,pI),E_={kernelName:Ou,backendName:\"cpu\",kernelFunc:iY};function Of(r,t,e,o){let n=me(r,t.dtype);for(let s=0;s0?0:i-p),d=0;d+=u*this.leftPad.length;for(let b=0;bb.forEach(C=>h[g++]=C);for(let b=0;b0){x(t[m+l-1]);for(let b=0;b0){let p=e[0];if(p!==0)throw new Error(`First split value must be 0, got ${p}`);for(let u=1;u=p;if(c=c&&e[u]<=o,!c)throw new Error(`Invalid split value ${e[u]}, must be in [${p}, ${o}]`);p=e[u]}if(p!==o)throw new Error(`Last split value must be data size. Expected ${o}, got ${p}`)}let s=n-1,a=y.getArrayFromDType(\"int32\",n);if(o===0||n===0){let p=new Array(o);for(let u=0;u<=s;++u)a[u]=0;return[p,a]}a[0]=0;for(let p=1;p<=s;++p){let u=e[p]-e[p-1],c=0;this.nGramWidths.forEach(l=>{c+=this.getNumNGrams(u,l)}),this.preserveShort&&u>0&&c===0&&(c=1),a[p]=a[p-1]+c}let i=new Array(a[s]);for(let p=0;p{let m=e[p+1]-e[p],d=this.getNumNGrams(m,l);this.createNGrams(t,u,i,c,d,l),c+=d}),this.preserveShort&&c===a[p]){let l=e[p+1]-e[p];if(l===0)continue;let m=l+2*this.padWidth,d=1;this.createNGrams(t,u,i,c,d,m)}}return[i,a]}};function gp(r,t,e,o,n,s,a,i){return new cI(e,o,n,s,a,i).compute(r,t)}function uY(r,t,e,o){if(!r.length)return;if(t.length===0){for(let s=0;sr-t),pY=Sc((r,t,e,o)=>({real:r-e,imag:t-o})),Vl=Ye(_s,lI,pY),R_={kernelName:_s,backendName:\"cpu\",kernelFunc:Vl};function Mf(r,t){let e=new Array(r.rank);for(let n=0;n{let e=t.value-r.value;return e===0?r.index-t.index:e};function D_(r,t,e=0,o=r.length-1){for(;o>e;){if(o-e>600){let i=o-e+1,p=t-e+1,u=Math.log(i),c=.5*Math.exp(2*u/3),l=.5*Math.sqrt(u*c*(i-c)/i)*Math.sign(p-i/2),m=Math.max(e,Math.floor(t-p*c/i+l)),d=Math.min(o,Math.floor(t+(i-p)*c/i+l));D_(r,t,m,d)}let n=r[t],s=e,a=o;for(y.swap(r,e,t),Wl(r[o],n)>0&&y.swap(r,e,o);s0;)a=a-1}Wl(r[e],n)===0?y.swap(r,e,a):(a=a+1,y.swap(r,a,o)),a<=t&&(e=a+1),t<=a&&(o=a-1)}}function Lf(r,t,e,o,n){let s=t[t.length-1],[a,i]=[r.length/s,s],p=y.getTypedArrayFromDType(e,a*o),u=y.getTypedArrayFromDType(\"int32\",a*o);for(let l=0;lf[C]={value:b,index:C}),o{for(let g=0;gnew xu,1);var mI=Ie(gn,r=>r>=0?r:Math.exp(r)-1),A_={kernelName:gn,backendName:\"cpu\",kernelFunc:mI};function dI(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{alpha:s}=o;Q([n],\"leakyRelu\");let a=y.sizeFromShape(n.shape),i=e.data.get(n.dataId).values,p=y.getTypedArrayFromDType(\"float32\",a);for(let u=0;ur<0?t*r:r);function fI(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t;Q([o,n],\"prelu\");let s=e.data.get(o.dataId).values,a=e.data.get(n.dataId).values,[i,p]=lY(o.shape,n.shape,s,a,\"float32\");return e.makeTensorInfo(p,\"float32\",i)}var P_={kernelName:os,backendName:\"cpu\",kernelFunc:fI};var hI=Ie(as,r=>Math.max(0,r)),O_={kernelName:as,backendName:\"cpu\",kernelFunc:hI};var gI=Ie(ps,r=>Math.min(Math.max(0,r),6)),M_={kernelName:ps,backendName:\"cpu\",kernelFunc:gI};function Cp(r,t,e,o,n){if(e===\"linear\")return mr({inputs:{x:t},backend:r});if(e===\"relu\")return hI({inputs:{x:t},backend:r});if(e===\"elu\")return mI({inputs:{x:t},backend:r});if(e===\"relu6\")return gI({inputs:{x:t},backend:r});if(e===\"prelu\")return fI({inputs:{x:t,alpha:o},backend:r});if(e===\"leakyrelu\")return dI({inputs:{x:t},backend:r,attrs:{alpha:n}});if(e===\"sigmoid\")return iI({inputs:{x:t},backend:r});throw new Error(`Activation ${e} has not been implemented for the CPU backend.`)}function Ve(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{shape:s}=o,a=y.sizeFromShape(n.shape),i=y.inferFromImplicitShape(s,a),p=y.sizeFromShape(i);y.assert(a===p,()=>`The new shape (${i}) has ${p} elements and the old shape (${n.shape}) has ${a} elements. The new shape and old shape must have the same number of elements.`),e.incRef(n.dataId);let u=e.data.get(n.dataId);if(u.complexTensorInfos!=null){let c=u.complexTensorInfos.real,l=u.complexTensorInfos.imag;c.shape=i,l.shape=i}return{dataId:n.dataId,shape:i,dtype:n.dtype}}var L_={kernelName:da,backendName:\"cpu\",kernelFunc:Ve};function xI(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;Q([n,s],\"matMul\");let p=n.shape.length,u=s.shape.length,c=a?n.shape[p-2]:n.shape[p-1],l=i?s.shape[u-1]:s.shape[u-2],m=a?n.shape[p-1]:n.shape[p-2],d=i?s.shape[u-2]:s.shape[u-1],f=n.shape.slice(0,-2),h=s.shape.slice(0,-2),g=y.sizeFromShape(f),x=y.sizeFromShape(h),C=Ir.assertAndGetBroadcastShape(n.shape.slice(0,-2),s.shape.slice(0,-2)).concat([m,d]);y.assert(c===l,()=>`Error in matMul: inner shapes (${c}) and (${l}) of Tensors with shapes ${n.shape} and ${s.shape} and transposeA=${a} and transposeB=${i} must match.`);let S=a?[g,c,m]:[g,m,c],k=i?[x,d,l]:[x,l,d],_=Ve({inputs:{x:n},backend:e,attrs:{shape:S}}),E=Ve({inputs:{x:s},backend:e,attrs:{shape:k}}),R=a?_.shape[1]:_.shape[2],D=a?_.shape[2]:_.shape[1],P=i?E.shape[1]:E.shape[2],O=Math.max(g,x),M=e.data.get(_.dataId).values,L=e.data.get(E.dataId).values,B=y.computeStrides(_.shape),z=y.computeStrides(E.shape),[U,j,q]=a?[B[0],1,B[1]]:[B[0],B[1],1],[Y,J,re]=i?[1,z[1],z[0]]:[z[1],1,z[0]],ne=D*P,ee=me([O,D,P],_.dtype),oe=ee.values,ie=e.blockSize;for(let le=0;leMath.acos(r)),V_={kernelName:Wo,backendName:\"cpu\",kernelFunc:dY};var fY=Ie(Uo,r=>Math.acosh(r)),W_={kernelName:Uo,backendName:\"cpu\",kernelFunc:fY};function hY(r){let{inputs:t,backend:e}=r,o=t;Q(t,\"addN\");let n=o.map(i=>e.data.get(i.dataId).values),s=me(o[0].shape,o[0].dtype),a=s.values;for(let i=0;ib&&(b=k,C=S)}d[g]=C}return u.forEach(g=>e.disposeIntermediateTensorInfo(g)),e.makeTensorInfo(c,\"int32\",d)}var K_={kernelName:Ys,backendName:\"cpu\",kernelFunc:yY};function bY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o;Q(n,\"argMin\");let a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=It({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),a=[a[0]],w.assertAxesAreInnerMostDims(\"argMin\",a,p.shape.length);let[c,l]=w.computeOutAndReduceShapes(p.shape,a),m=y.sizeFromShape(c),d=y.makeZerosTypedArray(m,\"int32\"),f=y.sizeFromShape(l),h=e.data.get(p.dataId).values;for(let g=0;ge.disposeIntermediateTensorInfo(g)),e.makeTensorInfo(c,\"int32\",d)}var q_={kernelName:Qs,backendName:\"cpu\",kernelFunc:bY};var CY=Ie(qo,r=>Math.asin(r)),j_={kernelName:qo,backendName:\"cpu\",kernelFunc:CY};var wY=Ie(jo,r=>Math.asinh(r)),X_={kernelName:jo,backendName:\"cpu\",kernelFunc:wY};var SY=Ie(Xo,r=>Math.atan(r)),Y_={kernelName:Xo,backendName:\"cpu\",kernelFunc:SY};var IY=ze((r,t)=>Math.atan2(r,t)),vY=Ye(Qo,IY),Q_={kernelName:Qo,backendName:\"cpu\",kernelFunc:vY};var kY=Ie(Yo,r=>Math.atanh(r)),Z_={kernelName:Yo,backendName:\"cpu\",kernelFunc:kY};function _c(r,t,e,o,n,s){let a=n.strideHeight,i=n.strideWidth,p=n.dilationHeight,u=n.dilationWidth,c=n.effectiveFilterHeight,l=n.effectiveFilterWidth,m=n.padInfo.top,d=n.padInfo.left,f=s===\"max\"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,h=me(n.outShape,e),g=h.values,x=n.outShape[1]*n.outShape[2]*n.outShape[3],b=n.outShape[2]*n.outShape[3],C=n.outShape[3];for(let S=0;Sj?j=ie:s===\"avg\"&&(q+=ie,Y++)}if(isNaN(j))break}let J=M+L*C+E;g[J]=s===\"avg\"?q/Y:j}}}return h}function Bf(r,t,e,o,n=!1,s=!1){let a=me(o.outShape,\"int32\"),i=o.strideHeight,p=o.strideWidth,u=o.dilationHeight,c=o.dilationWidth,l=o.effectiveFilterHeight,m=o.effectiveFilterWidth,d=o.padInfo.top,f=o.padInfo.left,h=me(t,e,r);for(let g=0;gP&&(P=U,n?O=s?((g*o.inHeight+M)*o.inWidth+B)*o.inChannels+x:(M*o.inWidth+B)*o.inChannels+x:O=L*m+z)}}a.set(O,g,b,_,x)}}return a}function zf(r,t,e,o,n,s){let a=n.strideDepth,i=n.strideHeight,p=n.strideWidth,u=n.dilationDepth,c=n.dilationHeight,l=n.dilationWidth,m=n.effectiveFilterDepth,d=n.effectiveFilterHeight,f=n.effectiveFilterWidth,h=n.padInfo.front,g=n.padInfo.top,x=n.padInfo.left,b=s===\"max\"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,C=me(n.outShape,e),S=C.values,k=n.outShape[1]*n.outShape[2]*n.outShape[3]*n.outShape[4],_=n.outShape[2]*n.outShape[3]*n.outShape[4],E=n.outShape[3]*n.outShape[4],R=n.outShape[4];for(let D=0;D_e?_e=xt:s===\"avg\"&&(ve+=xt,Fe++),isNaN(_e))break}if(isNaN(_e))break}if(isNaN(_e))break}let Pe=be+M;S[Pe]=s===\"avg\"?ve/Math.max(Fe,1):_e}}}}return C}function J_(r,t){let e=me(t.outShape,\"int32\"),o=t.strideDepth,n=t.strideHeight,s=t.strideWidth,a=t.dilationDepth,i=t.dilationHeight,p=t.dilationWidth,u=t.effectiveFilterDepth,c=t.effectiveFilterHeight,l=t.effectiveFilterWidth,m=t.padInfo.front,d=t.padInfo.top,f=t.padInfo.left;for(let h=0;h=L&&(L=re,B=U*c*l+q*c+J)}}}e.set(B,h,x,k,D,g)}}}return e}function NY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t;Q(n,\"avgPool\");let{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1;y.assert(w.eitherStridesOrDilationsAreOne(a,u),()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p),l;if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))l=mr({inputs:{x:n},backend:e});else{let m=e.data.get(n.dataId).values,d=y.computeStrides(n.shape),f=_c(m,n.shape,n.dtype,d,c,\"avg\");l=e.makeTensorInfo(c.outShape,n.dtype,f.values)}return l}var e$={kernelName:Zo,backendName:\"cpu\",kernelFunc:NY};function TY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o;Q(n,\"avgPool3d\");let c=w.computePool3DInfo(n.shape,s,a,1,i,p,u),l=e.data.get(n.dataId).values,m=zf(l,n.shape,n.dtype,y.computeStrides(n.shape),c,\"avg\");return e.makeTensorInfo(m.shape,\"float32\",m.values)}var t$={kernelName:Zs,backendName:\"cpu\",kernelFunc:TY};function _Y(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o;Q([n,s],\"avgPool3DGrad\");let c=w.computePool3DInfo(s.shape,a,i,1,p,u),l=c.strideDepth,m=c.strideHeight,d=c.strideWidth,f=c.filterDepth,h=c.filterHeight,g=c.filterWidth,x=c.dilationDepth,b=c.dilationHeight,C=c.dilationWidth,S=c.effectiveFilterDepth,k=c.effectiveFilterHeight,_=c.effectiveFilterWidth,E=S-1-c.padInfo.front,R=_-1-c.padInfo.left,D=k-1-c.padInfo.top,P=me(s.shape,\"float32\"),O=1/(f*h*g),M=e.bufferSync(n);for(let L=0;L=c.outDepth||Math.floor(ee)!==ee))for(let oe=0;oe=c.outHeight||Math.floor(ie)!==ie))for(let le=0;le<_;le+=C){let be=(J+le)/d;if(be<0||be>=c.outWidth||Math.floor(be)!==be)continue;let _e=M.get(L,ee,ie,be,B);re+=_e}}}P.set(re*O,L,z,U,j,B)}return e.makeTensorInfo(P.shape,P.dtype,P.values)}var r$={kernelName:Ai,backendName:\"cpu\",kernelFunc:_Y};function $Y(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s;Q([n,s],\"avgPoolGrad\");let{filterSize:i,strides:p,pad:u}=o,c=w.computePool2DInfo(a.shape,i,p,1,u),l=c.strideHeight,m=c.strideWidth,d=c.filterHeight,f=c.filterWidth,h=c.dilationHeight,g=c.dilationWidth,x=c.effectiveFilterHeight,b=c.effectiveFilterWidth,C=b-1-c.padInfo.left,S=x-1-c.padInfo.top,k=me(a.shape,\"float32\"),_=1/(d*f),E=e.data.get(n.dataId).values,R=me(n.shape,\"float32\",E);for(let D=0;D=c.outHeight||Math.floor(j)!==j))for(let q=0;q=c.outWidth||Math.floor(Y)!==Y)continue;let J=R.get(D,j,Y,P);z+=J}}k.set(z*_,D,O,M,P)}return e.makeTensorInfo(k.shape,k.dtype,k.values)}var o$={kernelName:Di,backendName:\"cpu\",kernelFunc:$Y};function EY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,scale:s,offset:a,mean:i,variance:p}=t;y.assert(i.shape.length===p.shape.length,()=>\"Batch normalization gradient requires mean and variance to have equal ranks.\"),y.assert(a==null||i.shape.length===a.shape.length,()=>\"Batch normalization gradient requires mean and offset to have equal ranks.\"),y.assert(s==null||i.shape.length===s.shape.length,()=>\"Batch normalization gradient requires mean and scale to have equal ranks.\"),Q([n,i,p,s,a],\"batchNorm\");let{varianceEpsilon:u}=o;u==null&&(u=.001);let c=e.data.get(n.dataId).values,l=e.data.get(i.dataId).values,m=e.data.get(p.dataId).values,d=s?e.data.get(s.dataId).values:new Float32Array([1]),f=a?e.data.get(a.dataId).values:new Float32Array([0]),h=new Float32Array(c.length),g=f.length,x=d.length,b=m.length,C=l.length,S=0,k=0,_=0,E=0;for(let R=0;R=g&&(S=0),k>=C&&(k=0),_>=x&&(_=0),E>=b&&(E=0);return e.makeTensorInfo(n.shape,n.dtype,h)}var n$={kernelName:vn,backendName:\"cpu\",kernelFunc:EY};function RY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,crops:a}=o;Q([n],\"batchToSpaceND\");let i=s.reduce((x,b)=>x*b),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=Ve({inputs:{x:n},backend:e,attrs:{shape:p}}),f=It({inputs:{x:d},backend:e,attrs:{perm:u}}),h=Ve({inputs:{x:f},backend:e,attrs:{shape:c}}),g=Fo({inputs:{x:h},backend:e,attrs:{begin:l,size:m}});return e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),g}var s$={kernelName:Js,backendName:\"cpu\",kernelFunc:RY};function DY(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a}=o,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,u=Ic(i,p,s.dtype,s.shape,a);return e.makeTensorInfo([a],s.dtype,u)}var a$={kernelName:en,backendName:\"cpu\",kernelFunc:DY};function AY(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t,s=e.data.get(o.dataId).values,a=e.data.get(n.dataId).values,i=w.assertAndGetBroadcastShape(Array.from(s),Array.from(a));return e.makeTensorInfo([i.length],\"int32\",Int32Array.from(i))}var i$={kernelName:ea,backendName:\"cpu\",kernelFunc:AY};var FY=Ie(Co,(r,t)=>{let e=t;return r>e.clipValueMax?e.clipValueMax:r{let{x:t}=r.inputs,e=r.backend,o=new Float32Array(y.sizeFromShape(t.shape)),n=e.data.get(t.dataId),s=n.complexTensorInfos.real,a=n.complexTensorInfos.imag,i=e.data.get(s.dataId).values,p=e.data.get(a.dataId).values;for(let u=0;uh.shape);w.assertParamsConsistent(a,s);let i=w.computeOutShape(t.map(h=>h.shape),s);if(y.sizeFromShape(i)===0)return e.makeTensorInfo(i,t[0].dtype,[]);let p=t.filter(h=>y.sizeFromShape(h.shape)>0);if(p.length===1)return mr({inputs:{x:p[0]},backend:e});if(p[0].dtype===\"complex64\"){let h=p.map(S=>Ro({inputs:{input:S},backend:e})),g=p.map(S=>Ma({inputs:{input:S},backend:e})),x=yu({inputs:h,backend:e,attrs:{axis:s}}),b=yu({inputs:g,backend:e,attrs:{axis:s}}),C=Kt({inputs:{real:x,imag:b},backend:e});return h.forEach(S=>e.disposeIntermediateTensorInfo(S)),g.forEach(S=>e.disposeIntermediateTensorInfo(S)),e.disposeIntermediateTensorInfo(x),e.disposeIntermediateTensorInfo(b),C}let u=p.map(h=>{let x=[-1,y.sizeFromShape(h.shape.slice(s))];return Ve({inputs:{x:h},backend:e,attrs:{shape:x}})}),c=u.map(h=>({vals:e.data.get(h.dataId).values,shape:h.shape}));i=w.computeOutShape(u.map(h=>h.shape),1);let l=u[0].shape[0]===1,m=mp(c,i,t[0].dtype,l),d=w.computeOutShape(p.map(h=>h.shape),s),f=e.makeTensorInfo(d,t[0].dtype,m);return u.forEach(h=>e.disposeIntermediateTensorInfo(h)),f}var l$={kernelName:ta,backendName:\"cpu\",kernelFunc:yu};function yI(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=o;Q([n,s],\"conv2d\");let l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,s.shape,a,u,i,c,!1,l),d=m.filterHeight,f=m.filterWidth,h=m.dilationHeight,g=m.dilationWidth,x=m.padInfo.left,b=m.padInfo.top,C=m.dataFormat===\"channelsLast\",S=new tt(m.outShape,n.dtype),k=y.computeStrides(n.shape),_=y.computeStrides(s.shape),E=k[0],R=C?k[1]:k[2],D=C?k[2]:1,P=C?1:k[1],O=S.strides[0],M=C?S.strides[1]:S.strides[2],L=C?S.strides[2]:1,B=C?1:S.strides[1],z=e.data.get(n.dataId).values,U=e.data.get(s.dataId).values,j=S.values;for(let q=0;q=m.inHeight)continue;let le=oe*_[0],be=Y+ie*R;for(let _e=0;_e=m.inWidth)continue;let lt=le+Pe*_[1],Ge=be+st*D,mt=lt;for(let it=0;it=u.inDepth)continue;let q=U*D[0],Y=O+j*R[1];for(let J=0;J=u.inHeight)continue;let ie=q+ee*D[1],le=Y+oe*R[2];for(let be=0;be=u.inWidth)continue;let st=ie+Fe*D[2],lt=le+Pe*u.inChannels,Ge=st;for(let mt=0;mtMath.cos(r)),y$={kernelName:an,backendName:\"cpu\",kernelFunc:VY};var WY=Ie(un,r=>Math.cosh(r)),b$={kernelName:un,backendName:\"cpu\",kernelFunc:WY};function UY(r){let{inputs:t,backend:e,attrs:o}=r,{image:n,boxes:s,boxInd:a}=t,{cropSize:i,method:p,extrapolationValue:u}=o,[c,l,m,d]=n.shape,f=s.shape[0],[h,g]=i,x=me([f,h,g,d],\"float32\"),b=e.data.get(s.dataId).values,C=e.data.get(a.dataId).values,S=e.data.get(n.dataId).values,k=y.computeStrides(n.shape),_=y.computeStrides(x.shape);for(let E=0;E=c)continue;let B=h>1?(O-D)*(l-1)/(h-1):0,z=g>1?(M-P)*(m-1)/(g-1):0;for(let U=0;U1?D*(l-1)+U*B:.5*(D+O)*(l-1);if(j<0||j>l-1){for(let q=0;q1?P*(m-1)+re*z:.5*(P+M)*(m-1);if(ne<0||ne>m-1){for(let le=0;le1?P*(m-1)+q*z:.5*(P+M)*(m-1);if(Y<0||Y>m-1){for(let ne=0;nex+f-b-1:(x,b)=>x+b;for(let x=0;xx+f-b-1:(x,b)=>x+b;for(let x=0;x`Only NHWC dataFormat supported on CPU for depthToSpace. Got ${a}`);let i=n.shape[0],p=n.shape[1],u=n.shape[2],c=n.shape[3],l=p*s,m=u*s,d=c/(s*s),f=e.data.get(n.dataId).values,h=new Float32Array(i*l*m*d),g=0;for(let x=0;x`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${a} and dilations '${m}'`);let d=w.computeConv2DInfo(n.shape,s.shape,a,m,i,u,!0),{filterHeight:f,filterWidth:h,dilationHeight:g,dilationWidth:x,padInfo:b}=d,C=b.left,S=b.top,k=d.outChannels/d.inChannels,_=new tt(d.outShape,n.dtype),E=e.data.get(n.dataId).values,R=e.data.get(s.dataId).values,D=_.values;for(let P=0;P=d.inHeight)continue;let q=U*l[0],Y=O+j*c[1];for(let J=0;J=d.inWidth)continue;let ie=q+ee*l[1],le=Y+oe*d.inChannels,be=re,_e=ie;for(let ve=0;ve{let{x:o,filter:n}=r,{strides:s,pad:a,dilations:i}=e,p=t,u=p.data.get(o.dataId).values,c=o.shape.length,l=p.data.get(n.dataId).values,m=n.shape.length,{batchSize:d,inHeight:f,inWidth:h,inChannels:g,outHeight:x,outWidth:b,padInfo:C,strideHeight:S,strideWidth:k,filterHeight:_,filterWidth:E,dilationHeight:R,dilationWidth:D,outShape:P}=w.computeDilation2DInfo(o.shape,n.shape,s,a,\"NHWC\",i),O=y.sizeFromShape(P),M=P.length,L=y.getArrayFromDType(o.dtype,O);for(let z=0;z=0&&oe=0&&lere&&(re=ve)}}}let ne=y.locToIndex([z,U,q,J],M,y.computeStrides(P));L[ne]=re}}}return{dataId:p.write(y.toTypedArray(L,o.dtype),P,o.dtype),shape:P,dtype:o.dtype}}};var E$={kernelName:zi,backendName:\"cpu\",kernelFunc:({inputs:r,backend:t,attrs:e})=>{let{x:o,filter:n,dy:s}=r,{strides:a,pad:i,dilations:p}=e,u=t,c=y.toNestedArray(o.shape,u.data.get(o.dataId).values),l=y.toNestedArray(n.shape,u.data.get(n.dataId).values),{batchSize:m,inHeight:d,inWidth:f,inChannels:h,outHeight:g,outWidth:x,padInfo:b,strideHeight:C,strideWidth:S,filterHeight:k,filterWidth:_,dilationHeight:E,dilationWidth:R,outShape:D}=w.computeDilation2DInfo(o.shape,n.shape,a,i,\"NHWC\",p);y.assert(s.rank===D.length,()=>`Error in ${zi}, dy must have the same rank as output ${D.length}, but got ${s.rank}`);let P=y.toNestedArray(D,u.data.get(s.dataId).values),O=y.makeZerosNestedTypedArray(n.shape,n.dtype);for(let L=0;L=0&&ee=0&&ieY&&(Y=le,J=ne,re=oe)}}}O[J][re][q]+=P[L][B][U][q]}}}return{dataId:u.write(y.toTypedArray(O,o.dtype),n.shape,n.dtype),shape:n.shape,dtype:n.dtype}}};var R$={kernelName:Bi,backendName:\"cpu\",kernelFunc:({inputs:r,backend:t,attrs:e})=>{let{x:o,filter:n,dy:s}=r,{strides:a,pad:i,dilations:p}=e,u=t,c=y.toNestedArray(o.shape,u.data.get(o.dataId).values),l=y.toNestedArray(n.shape,u.data.get(n.dataId).values),{batchSize:m,inHeight:d,inWidth:f,inChannels:h,outHeight:g,outWidth:x,padInfo:b,strideHeight:C,strideWidth:S,filterHeight:k,filterWidth:_,dilationHeight:E,dilationWidth:R,outShape:D}=w.computeDilation2DInfo(o.shape,n.shape,a,i,\"NHWC\",p);y.assert(s.rank===D.length,()=>`Error in ${Bi}, dy must have the same rank as output ${D.length}, but got ${s.rank}`);let P=y.toNestedArray(D,u.data.get(s.dataId).values),O=y.makeZerosNestedTypedArray(o.shape,o.dtype);for(let L=0;L=0&&ee=0&&ieY&&(Y=le,J=ee,re=ie)}}}O[L][J][re][q]+=P[L][B][U][q]}}}return{dataId:u.write(y.toTypedArray(O,o.dtype),o.shape,o.dtype),shape:o.shape,dtype:o.dtype}}};function QY(r){let{inputs:t,backend:e,attrs:o}=r,{image:n}=t,{canvas:s,options:a}=o,{contextOptions:i,imageOptions:p}=a||{},u=(p==null?void 0:p.alpha)||1,c=(i==null?void 0:i.contextType)||\"2d\";if(c!==\"2d\")throw new Error(`Context type ${i.contextType} is not supported by the CPU backend.`);let l=s.getContext(c,(i==null?void 0:i.contextAttributes)||{});if(l==null)throw new Error(`Could not get the context with ${c} type.`);let[m,d]=n.shape.slice(0,2),f=n.shape.length===2?1:n.shape[2],h=e.data.get(n.dataId).values,g=n.dtype===\"float32\"?255:1,x=new Uint8ClampedArray(d*m*4);for(let C=0;C1)throw new Error(`Tensor values for a float32 Tensor must be in the range [0 - 1] but encountered ${E}.`)}else if(n.dtype===\"int32\"&&(E<0||E>255))throw new Error(`Tensor values for a int32 Tensor must be in the range [0 - 255] but encountered ${E}.`);f===1?(S[0]=E*g,S[1]=E*g,S[2]=E*g):S[_]=E*g}let k=C*4;x[k+0]=Math.round(S[0]),x[k+1]=Math.round(S[1]),x[k+2]=Math.round(S[2]),x[k+3]=Math.round(S[3])}s.width=d,s.height=m;let b=new ImageData(x,d,m);return l.putImageData(b,0,0),n}var D$={kernelName:Pu,backendName:\"cpu\",kernelFunc:QY};function gi(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;Q(n,\"sum\");let i;n.dtype===\"bool\"?i=Do({inputs:{x:n},backend:e,attrs:{dtype:\"int32\"}}):i=mr({inputs:{x:n},backend:e});let p=i.shape.length,u=y.parseAxisParam(s,i.shape),c=w.getAxesPermutation(u,p),l=u,m=i;c!=null&&(m=It({inputs:{x:i},backend:e,attrs:{perm:c}}),l=w.getInnerMostAxes(l.length,p)),w.assertAxesAreInnerMostDims(\"sum\",l,m.shape.length);let[d,f]=w.computeOutAndReduceShapes(m.shape,l),h=w.upcastType(m.dtype,\"int32\"),g=wc(e,d,h),x=y.sizeFromShape(f),b=e.data.get(g.dataId).values,C=e.data.get(m.dataId).values;for(let S=0;S=0&&(m=gi({inputs:{x:m},backend:e,attrs:{axis:u[h]-(a.length-d),keepDims:!1}}),f.push(m)),d--)}for(let h of f)h!==m&&e.disposeIntermediateTensorInfo(h);return m}var F$={kernelName:Vi,backendName:\"cpu\",kernelFunc:ZY};function JY(r){let{inputs:t,backend:e}=r,{dy:o,y:n}=t;Q([o,n],\"eluGrad\");let s=new Float32Array(y.sizeFromShape(n.shape)),a=e.data.get(n.dataId).values,i=e.data.get(o.dataId).values;for(let p=0;p=0?s[p]=i[p]:s[p]=i[p]*(u+1)}return e.makeTensorInfo(n.shape,\"float32\",s)}var P$={kernelName:Ya,backendName:\"cpu\",kernelFunc:JY};var eQ=w.ERF_P,tQ=w.ERF_A1,rQ=w.ERF_A2,oQ=w.ERF_A3,nQ=w.ERF_A4,sQ=w.ERF_A5,aQ=Ie(xn,r=>{let t=Math.sign(r),e=Math.abs(r),o=1/(1+eQ*e);return t*(1-((((sQ*o+nQ)*o+oQ)*o+rQ)*o+tQ)*o*Math.exp(-e*e))}),O$={kernelName:xn,backendName:\"cpu\",kernelFunc:aQ};function $c(r){let{inputs:t,backend:e,attrs:o}=r,{input:n}=t,{dim:s}=o,a=n.shape.length,i=n.shape.slice(),p=s;return s<0&&(y.assert(-(a+1)<=s,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+s+1),i.splice(p,0,1),Ve({inputs:{x:n},backend:e,attrs:{shape:i}})}var M$={kernelName:na,backendName:\"cpu\",kernelFunc:$c};var iQ=ze((r,t)=>r/t),Ul=Ye(hn,iQ),Gl={kernelName:hn,backendName:\"cpu\",kernelFunc:Ul};function Vf(r,t,e){let o=r.shape,n=o[0],s=o[1],a=e.data.get(r.dataId),i=a.complexTensorInfos.real,p=a.complexTensorInfos.imag,u=[n,s],c=y.sizeFromShape(u),l=y.getTypedArrayFromDType(\"float32\",c),m=y.getTypedArrayFromDType(\"float32\",c);for(let g=0;g{let{image:o}=r,n=e,s=y.getTypedArrayFromDType(o.dtype,y.sizeFromShape(o.shape)),[a,i,p,u]=o.shape,c=n.data.get(o.dataId).values;for(let m=0;m=0&&C=0,()=>`GatherV2: the index value ${k} is not in [0, ${c-1}]`)}let l=i;i==null&&(l=0);let m=y.sizeFromShape(s.shape),d=w.segment_util.collectGatherOpShapeInfo(n,s,p,l),f=Ve({inputs:{x:n},backend:e,attrs:{shape:[d.batchSize,d.outerSize,d.dimSize,d.sliceSize]}}),h=Ve({inputs:{x:s},backend:e,attrs:{shape:[d.batchSize,m/d.batchSize]}}),g=[d.batchSize,d.outerSize,m/d.batchSize,d.sliceSize],x=e.bufferSync(h),b=e.bufferSync(f),C=_f(b,x,g);return e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),e.makeTensorInfo(d.outputShape,C.dtype,C.values)}var G$={kernelName:aa,backendName:\"cpu\",kernelFunc:gQ};function xQ(r){let{inputs:t,backend:e}=r,{input:o}=t,n=y.sizeFromShape(o.shape),s=o.shape[o.shape.length-1],a=n/s,i=Ve({inputs:{x:o},backend:e,attrs:{shape:[a,s]}}),p=Vf(i,!0,e),u=Ve({inputs:{x:p},backend:e,attrs:{shape:o.shape}});return e.disposeIntermediateTensorInfo(i),e.disposeIntermediateTensorInfo(p),u}var H$={kernelName:Ui,backendName:\"cpu\",kernelFunc:xQ};var yQ=Ie(_n,r=>Number.isFinite(r)?1:0,\"bool\"),K$={kernelName:_n,backendName:\"cpu\",kernelFunc:yQ};var bQ=Ie($n,r=>Math.abs(r)===1/0?1:0,\"bool\"),q$={kernelName:$n,backendName:\"cpu\",kernelFunc:bQ};var CQ=Ie(En,r=>Number.isNaN(r)?1:0,\"bool\"),j$={kernelName:En,backendName:\"cpu\",kernelFunc:CQ};function wQ(r){let{backend:t,attrs:e}=r,{start:o,stop:n,num:s}=e,a=$f(o,n,s);return t.makeTensorInfo([a.length],\"float32\",a)}var X$={kernelName:Fn,backendName:\"cpu\",kernelFunc:wQ};var SQ=Ie(On,r=>Math.log1p(r)),Y$={kernelName:On,backendName:\"cpu\",kernelFunc:SQ};var IQ=ze((r,t)=>r&&t),vQ=Ye(Mn,IQ,null,\"bool\"),Q$={kernelName:Mn,backendName:\"cpu\",kernelFunc:vQ};var kQ=Ie(Ln,r=>r?0:1,\"bool\"),Z$={kernelName:Ln,backendName:\"cpu\",kernelFunc:kQ};var NQ=ze((r,t)=>r||t),TQ=Ye(Bn,NQ,null,\"bool\"),J$={kernelName:Bn,backendName:\"cpu\",kernelFunc:TQ};function _Q(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o;Q(n,\"LRN\");let u=n.shape[3],c=u-1,l=e.data.get(n.dataId).values,m=y.sizeFromShape(n.shape),d=new Float32Array(m);function f(h){let g=h%u,x=h-g+Math.max(0,g-s),b=h-g+Math.min(g+s,c),C=0;for(;x<=b;x++){let S=l[x];C+=S*S}return C}for(let h=0;h`Error in maxPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p),l;if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))l=mr({inputs:{x:n},backend:e});else{let m=e.data.get(n.dataId).values,d=y.computeStrides(n.shape),f=_c(m,n.shape,n.dtype,d,c,\"max\");l=e.makeTensorInfo(c.outShape,n.dtype,f.values)}return l}var oE={kernelName:Un,backendName:\"cpu\",kernelFunc:EQ};function RQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o;Q(n,\"maxPool3d\");let c=w.computePool3DInfo(n.shape,s,a,1,i,p,u),l=e.data.get(n.dataId).values,m=zf(l,n.shape,n.dtype,y.computeStrides(n.shape),c,\"max\");return e.makeTensorInfo(m.shape,\"float32\",m.values)}var nE={kernelName:ia,backendName:\"cpu\",kernelFunc:RQ};function DQ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o;Q([n,s],\"maxPool3DGrad\");let c=w.computePool3DInfo(s.shape,a,i,1,p,u),l=e.bufferSync(s),m=J_(l,c),d=c.strideDepth,f=c.strideHeight,h=c.strideWidth,g=c.dilationDepth,x=c.dilationHeight,b=c.dilationWidth,C=c.effectiveFilterDepth,S=c.effectiveFilterHeight,k=c.effectiveFilterWidth,_=C-1-c.padInfo.front,E=k-1-c.padInfo.left,R=S-1-c.padInfo.top,D=me(s.shape,\"float32\"),P=e.bufferSync(n);for(let O=0;O=c.outDepth||Math.floor(re)!==re))for(let ne=0;ne=c.outHeight||Math.floor(ee)!==ee))for(let oe=0;oe=c.outWidth||Math.floor(ie)!==ie)continue;let le=C*S*k-1-m.get(O,re,ee,ie,M),be=J*S*k+ne*k+oe,_e=le===be?1:0;if(_e===0)continue;let ve=P.get(O,re,ee,ie,M);Y+=ve*_e}}}D.set(Y,O,L,B,z,M)}return e.makeTensorInfo(D.shape,D.dtype,D.values)}var sE={kernelName:Ki,backendName:\"cpu\",kernelFunc:DQ};function AQ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s,output:a}=t,i=s;Q([s,a],\"maxPoolGrad\");let{filterSize:p,strides:u,pad:c,dimRoundingMode:l}=o,m=w.computePool2DInfo(i.shape,p,u,1,c,l),d=e.data.get(i.dataId).values,f=me(m.outShape,i.dtype,Bf(d,i.shape,i.dtype,m).values),h=m.strideHeight,g=m.strideWidth,x=m.dilationHeight,b=m.dilationWidth,C=m.effectiveFilterHeight,S=m.effectiveFilterWidth,k=S-1-m.padInfo.left,_=C-1-m.padInfo.top,E=me(i.shape,\"float32\"),R=e.data.get(n.dataId).values,D=me(n.shape,\"float32\",R);for(let P=0;P=m.outHeight||Math.floor(q)!==q))for(let Y=0;Y=m.outWidth||Math.floor(J)!==J)continue;let re=C*S-1-f.get(P,q,J,O),ne=j*S+Y,ee=re===ne?1:0;if(ee===0)continue;let oe=D.get(P,q,J,O);U+=oe*ee}}E.set(U,P,M,L,O)}return e.makeTensorInfo(E.shape,E.dtype,E.values)}var aE={kernelName:Hi,backendName:\"cpu\",kernelFunc:AQ};function iE(r,t,e,o,n){let s=y.computeStrides(t),a=_c(r,t,e,s,n,\"max\"),i=Bf(r,t,e,n,!0,o);return[a.values,i.values]}var uE={kernelName:ua,backendName:\"cpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{filterSize:n,strides:s,pad:a,includeBatchInIndex:i}=t,p=e;Q(o,\"MaxPoolWithArgmax\");let u=p.data.get(o.dataId).values,c=w.computePool2DInfo(o.shape,n,s,[1,1],a),[l,m]=iE(u,o.shape,o.dtype,i,c),d=p.write(l,c.outShape,o.dtype),f=p.write(m,c.outShape,o.dtype);return[{dataId:d,shape:c.outShape,dtype:o.dtype},{dataId:f,shape:c.outShape,dtype:\"int32\"}]}};function FQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=y.parseAxisParam(s,n.shape),u=w.computeOutAndReduceShapes(n.shape,i)[1],c=y.sizeFromShape(u),l=[],m=e.makeTensorInfo([],\"float32\",new Float32Array([c]));l.push(m);let d=Do({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}});l.push(d);let f=Ul({inputs:{a:d,b:m},backend:e});l.push(f);let h=gi({inputs:{x:f},backend:e,attrs:{axis:s,keepDims:a}});return l.forEach(g=>e.disposeIntermediateTensorInfo(g)),h}var pE={kernelName:Gn,backendName:\"cpu\",kernelFunc:FQ};function PQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;Q(n,\"min\");let i=y.parseAxisParam(s,n.shape),p=i,u=w.getAxesPermutation(p,n.shape.length),c=n;u!=null&&(c=It({inputs:{x:n},backend:e,attrs:{perm:u}}),p=w.getInnerMostAxes(p.length,n.shape.length)),w.assertAxesAreInnerMostDims(\"min\",p,c.shape.length);let[l,m]=w.computeOutAndReduceShapes(c.shape,p),d=y.sizeFromShape(m),f=y.makeZerosTypedArray(y.sizeFromShape(l),c.dtype),h=e.data.get(c.dataId).values;for(let x=0;xC[0]+n.shape[S]+C[1]),p=s.map(C=>C[0]),u=s.map((C,S)=>C[0]+n.shape[S]),c=a===\"reflect\"?0:1,l=e.data.get(n.dataId).values,m=n.shape.length,d=y.computeStrides(n.shape),f=y.sizeFromShape(i),h=i.length,g=y.computeStrides(i),x=y.getTypedArrayFromDType(n.dtype,f);for(let C=0;C=u[_]&&(S[_]=(u[_]-1)*2-S[_]+c);S=S.map((_,E)=>_-p[E]);let k=y.locToIndex(S,m,d);x[C]=l[k]}return{dataId:e.write(x,i,n.dtype),shape:i,dtype:n.dtype}}var lE={kernelName:qn,backendName:\"cpu\",kernelFunc:OQ};var MQ=ze((r,t)=>{let e=r%t;return r<0&&t<0||r>=0&&t>=0?e:(e+t)%t}),LQ=Ye(jn,MQ),mE={kernelName:jn,backendName:\"cpu\",kernelFunc:LQ};var fE=Kp(qw());function SI(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{dim:s}=o,a=n.shape.length,i=s;if(i===-1&&(i=a-1),i!==a-1)throw Error(`Softmax along a non-last dimension is not yet supported. Logits was rank ${a} and dim was ${i}`);let p=y.parseAxisParam([i],n.shape),u=wI({inputs:{x:n},backend:e,attrs:{reductionIndices:p,keepDims:!1}}),c=w.expandShapeToKeepDim(u.shape,p),l=Ve({inputs:{x:u},backend:e,attrs:{shape:c}}),m=Vl({inputs:{a:n,b:l},backend:e}),d=KS({inputs:{x:m},backend:e}),f=gi({inputs:{x:d},backend:e,attrs:{axis:p,keepDims:!1}}),h=Ve({inputs:{x:f},backend:e,attrs:{shape:c}}),g=Ul({inputs:{a:d,b:h},backend:e});return e.disposeIntermediateTensorInfo(u),e.disposeIntermediateTensorInfo(l),e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),g}var dE={kernelName:vs,backendName:\"cpu\",kernelFunc:SI};function BQ(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o;Q(n,\"multinomial\");let p=i?n:SI({inputs:{logits:n},backend:e,attrs:{dim:-1}}),u=p.shape[0],c=p.shape[1],l=e.data.get(p.dataId).values,m=[u,s],d=y.makeZerosTypedArray(y.sizeFromShape(m),\"int32\");for(let f=0;f=0&&l[m]{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=$c({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=yu({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeIntermediateTensorInfo(c)),u}var IE={kernelName:la,backendName:\"cpu\",kernelFunc:II};function qQ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{paddings:s,constantValue:a}=o;Q(n,\"pad\");let i=s.map((b,C)=>b[0]+n.shape[C]+b[1]),p=s.map(b=>b[0]),u=e.data.get(n.dataId).values,c=y.sizeFromShape(n.shape),l=n.shape.length,m=y.computeStrides(n.shape),d=y.sizeFromShape(i),f=i.length,h=y.computeStrides(i),g=y.getTypedArrayFromDType(n.dtype,d);a!==0&&g.fill(a);for(let b=0;b_+p[E]),k=y.locToIndex(S,f,h);g[k]=u[b]}return{dataId:e.write(g,i,n.dtype),shape:i,dtype:n.dtype}}var Wf={kernelName:ts,backendName:\"cpu\",kernelFunc:qQ};var jQ=ze((r,t)=>Math.pow(r,t)),XQ=Ye(rs,jQ),vE={kernelName:rs,backendName:\"cpu\",kernelFunc:XQ};function YQ(r){let{inputs:t,backend:e,attrs:o}=r,{paramsNestedSplits:n,paramsDenseValues:s,indices:a}=t,{outputRaggedRank:i}=o,p=n.map(x=>e.data.get(x.dataId).values),u=n.map(x=>x.shape),c=e.data.get(s.dataId).values,l=e.data.get(a.dataId).values,[m,d,f]=Rf(p,u,c,s.shape,s.dtype,l,a.shape,i),h=m.map(x=>e.makeTensorInfo([x.length],\"int32\",x)),g=e.makeTensorInfo(f,s.dtype,d);return h.concat([g])}var kE={kernelName:Qp,backendName:\"cpu\",kernelFunc:YQ};function QQ(r){let{inputs:t,backend:e}=r,{starts:o,limits:n,deltas:s}=t,a=e.data.get(o.dataId).values,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,[u,c]=Df(a,o.shape,o.dtype,i,n.shape,p,s.shape),l=e.makeTensorInfo([u.length],\"int32\",u),m=e.makeTensorInfo([c.length],o.dtype,c);return[l,m]}var NE={kernelName:Zp,backendName:\"cpu\",kernelFunc:QQ};function ZQ(r){let{inputs:t,backend:e,attrs:o}=r,{shape:n,values:s,defaultValue:a,rowPartitionTensors:i}=t,{rowPartitionTypes:p}=o,u=e.data.get(n.dataId).values,c=e.data.get(s.dataId).values,l=e.data.get(a.dataId).values,m=i.map(g=>e.data.get(g.dataId).values),d=i.map(g=>g.shape),[f,h]=Af(u,n.shape,c,s.shape,s.dtype,l,a.shape,m,d,p);return e.makeTensorInfo(f,s.dtype,h)}var TE={kernelName:Jp,backendName:\"cpu\",kernelFunc:ZQ};function JQ(r){let{backend:t,attrs:e}=r,{start:o,stop:n,dtype:s,step:a}=e,i=fp(o,n,a,s);return t.makeTensorInfo([i.length],s,i)}var _E={kernelName:ma,backendName:\"cpu\",kernelFunc:JQ};var e7=Ie(ss,r=>1/r),$E={kernelName:ss,backendName:\"cpu\",kernelFunc:e7};function t7(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o;Q(n,\"resizeBilinear\");let p=y.computeStrides(n.shape),[u,c]=i,[l,m,d,f]=n.shape,h=e.data.get(n.dataId).values,g=new Float32Array(y.sizeFromShape([l,u,c,f])),x=[s&&u>1?m-1:m,s&&c>1?d-1:d],b=[s&&u>1?u-1:u,s&&c>1?c-1:c],C=0,S=x[0]/b[0],k=x[1]/b[1];for(let _=0;_1?u-1:u,a&&d>1?c-1:c],g=[a&&m>1?m-1:m,a&&d>1?d-1:d],x=h[0]/g[0],b=h[1]/g[1],C=e.data.get(s.dataId).values,S=0;for(let k=0;k1?m-1:m,s&&c>1?d-1:d],b=[s&&u>1?u-1:u,s&&c>1?c-1:c],C=x[0]/b[0],S=x[1]/b[1],k=0;for(let _=0;_1?c-1:c,a&&f>1?l-1:l],b=[a&&d>1?d-1:d,a&&f>1?f-1:f],C=x[0]/b[0],S=x[1]/b[1],k=1/C,_=1/S,E=Math.ceil(k)*2+2,R=Math.ceil(_)*2+2;for(let D=0;D=d)continue;let ee=P+ne*p[1],oe=ne*C,ie=Math.min(c-1,a?Math.round(oe):Math.floor(oe));if(O===ie)for(let le=0;le=f)continue;let _e=ee+be*p[2],ve=be*S,Fe=Math.min(l-1,a?Math.round(ve):Math.floor(ve));z===Fe&&(J+=g[_e+Y])}}h[U+Y]=J}}}}return e.makeTensorInfo(n.shape,n.dtype,h)}var AE={kernelName:Ja,backendName:\"cpu\",kernelFunc:n7};function s7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o;Q(n,\"reverse\");let a=n.shape.length,i=y.parseAxisParam(s,n.shape);if(a===0)return mr({inputs:{x:n},backend:e});let p=new tt(n.shape,n.dtype),u=e.bufferSync(n);for(let c=0;cm[d]=n.shape[d]-1-m[d]),p.set(u.get(...m),...l)}return e.makeTensorInfo(p.shape,p.dtype,p.values)}var FE={kernelName:cs,backendName:\"cpu\",kernelFunc:s7};var PE={kernelName:As,backendName:\"cpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{image:o}=r,{radians:n,fillValue:s,center:a}=t,i=e,p=y.getTypedArrayFromDType(o.dtype,y.sizeFromShape(o.shape)),[u,c,l,m]=o.shape,[d,f]=w.getImageCenter(a,c,l),h=255,g=Math.sin(n),x=Math.cos(n),b=i.data.get(o.dataId).values;for(let S=0;S=0&&B=0&&z{let t=Math.floor(r);return r-t<.5?Math.floor(r):r-t>.5?Math.ceil(r):t%2===0?t:t+1}),OE={kernelName:ls,backendName:\"cpu\",kernelFunc:a7};function i7(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n,updates:s}=t,{shape:a}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(s,n,a),m=!0,d=e.bufferSync(n),f=e.bufferSync(s),h=zs(d,f,a,l,u,p,i,c,0,m);return e.makeTensorInfo(a,h.dtype,h.values)}var ME={kernelName:ds,backendName:\"cpu\",kernelFunc:i7};function u7(r,t){let e=0,o=r.length,n=0;for(;e1||n.shape.length===1?1:y.sizeFromShape(n.shape.slice(1));for(let f=0;fr>=0?d7*r:m7*(Math.exp(r)-1)),VE={kernelName:gs,backendName:\"cpu\",kernelFunc:f7};var h7=Ie(bs,r=>r<0?-1:r>0?1:0),WE={kernelName:bs,backendName:\"cpu\",kernelFunc:h7};var g7=Ie(xs,r=>Math.sin(r)),UE={kernelName:xs,backendName:\"cpu\",kernelFunc:g7};var x7=Ie(ys,r=>Math.sinh(r)),GE={kernelName:ys,backendName:\"cpu\",kernelFunc:x7};var y7=11920928955078125e-23,HE=Math.log(y7)+2,b7=Ie(ws,r=>{let t=r>-HE,e=rNumber(g)))),e.makeTensorInfo([h.length],o.dtype,new Int32Array(h))]}var jE={kernelName:ji,backendName:\"cpu\",kernelFunc:w7};function S7(r){let{inputs:t,backend:e}=r,{inputIndices:o,inputShape:n,newShape:s}=t;if(o.shape.length!==2)throw new Error(`Input indices should be a matrix but received shape\n ${o.shape}`);if(n.shape.length!==1)throw new Error(`Input shape should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Target shape should be a vector but received shape ${s.shape}`);let a=Array.from(e.data.get(n.dataId).values),i=e.data.get(o.dataId).values,p=Array.from(e.data.get(s.dataId).values),[u,c,l]=Pf(i,o.shape,o.dtype,a,p);return[e.makeTensorInfo(c,o.dtype,u),e.makeTensorInfo([l.length],s.dtype,new Int32Array(l))]}var XE={kernelName:ti,backendName:\"cpu\",kernelFunc:S7};function I7(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);if(n.shape[0]!==s.shape[0])throw new Error(\"segmentIds and indices should have same size.\");let a=e.data.get(o.dataId).values,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,[u,c]=Nc(a,o.shape,o.dtype,i,p,!0);return e.makeTensorInfo(c,o.dtype,u)}var YE={kernelName:ya,backendName:\"cpu\",kernelFunc:I7};function v7(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);if(n.shape[0]!==s.shape[0])throw new Error(\"segmentIds and indices should have same size.\");let a=e.data.get(o.dataId).values,i=e.data.get(n.dataId).values,p=e.data.get(s.dataId).values,[u,c]=Nc(a,o.shape,o.dtype,i,p);return e.makeTensorInfo(c,o.dtype,u)}var QE={kernelName:ba,backendName:\"cpu\",kernelFunc:v7};function k7(r){let{inputs:t,backend:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=t,{outputShape:i}=o,{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=w.calculateShapes(s,n,i),d=!1,f=e.bufferSync(n),h;switch(s.dtype){case\"bool\":{let g=e.bufferSync(s),x=!!e.data.get(a.dataId).values[0];h=zs(f,g,i,m,c,u,p,l,x,d);break}case\"float32\":{let g=e.bufferSync(s),x=e.data.get(a.dataId).values[0];h=zs(f,g,i,m,c,u,p,l,x,d);break}case\"int32\":{let g=e.bufferSync(s),x=e.data.get(a.dataId).values[0];h=zs(f,g,i,m,c,u,p,l,x,d);break}case\"string\":{let g=e.bufferSync(s),x=y.decodeString(e.data.get(a.dataId).values[0]);h=zs(f,g,i,m,c,u,p,l,x,d);break}default:throw new Error(`Unsupported type ${s.dtype}`)}return e.makeTensorInfo(i,h.dtype,h.values)}var ZE={kernelName:ks,backendName:\"cpu\",kernelFunc:k7};function N7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=o,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=new Array(n.shape.length).fill(0),c=n.shape.slice();return p.map(l=>{let m=[...c];m[i]=l;let d=Fo({inputs:{x:n},backend:e,attrs:{begin:u,size:m}});return u[i]+=l,d})}var JE={kernelName:xa,backendName:\"cpu\",kernelFunc:N7};var eR={kernelName:Xi,backendName:\"cpu\",kernelFunc:({inputs:r,backend:t})=>{let{x:e}=r,o=t;Q(e,\"square\");let n=o.data.get(e.dataId).values,s=new Float32Array(n.length);for(let i=0;i{let e=t;return isNaN(r)?NaN:r>0?1:e.alpha}),tR={kernelName:So,backendName:\"cpu\",kernelFunc:T7};function _7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o;Q(n,\"stridedSlice\");let{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=Ve({inputs:{x:n},backend:e,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let _=ct.computeOutShape(b,C,S),E=Fo({inputs:{x:n},backend:e,attrs:{begin:b,size:_}});k=Ve({inputs:{x:E},backend:e,attrs:{shape:f}}),e.disposeIntermediateTensorInfo(E)}else{let _=e.bufferSync(n),E=Of(d,_,S,b);k=e.makeTensorInfo(f,E.dtype,E.values)}return k}var rR={kernelName:Ts,backendName:\"cpu\",kernelFunc:_7};function $7(r){let{inputs:t,backend:e,attrs:o}=r,{separator:n,nGramWidths:s,leftPad:a,rightPad:i,padWidth:p,preserveShortSequences:u}=o,{data:c,dataSplits:l}=t,m=e.data.get(c.dataId).values,d=e.data.get(l.dataId).values,[f,h]=gp(m,d,n,s,a,i,p,u);return[e.makeTensorInfo([f.length],\"string\",f),e.makeTensorInfo(l.shape,\"int32\",h)]}var oR={kernelName:Ca,backendName:\"cpu\",kernelFunc:$7};function E7(r){let{inputs:t,backend:e,attrs:o}=r,{skipEmpty:n}=o,{input:s,delimiter:a}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(s.shape.length!==1)throw new Error(`Input must be a vector, got shape: ${s.shape}`);if(a.shape.length!==0)throw new Error(`Delimiter must be a scalar, got shape: ${a.shape}`);let i=e.data.get(s.dataId).values,p=e.data.get(a.dataId).values[0],[u,c,l]=xp(i,p,n),m=c.length;return[e.makeTensorInfo([m,2],\"int32\",u),e.makeTensorInfo([m],\"string\",c),e.makeTensorInfo([2],\"int32\",new Int32Array(l))]}var nR={kernelName:Yi,backendName:\"cpu\",kernelFunc:E7};function R7(r){let{inputs:t,backend:e,attrs:o}=r,{numBuckets:n}=o,{input:s}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(n<=0)throw new Error(\"Number of buckets must be at least 1\");let a=e.data.get(s.dataId).values,i=yp(a,n);return e.makeTensorInfo(s.shape,\"int32\",i)}var sR={kernelName:Qi,backendName:\"cpu\",kernelFunc:R7};var D7=Ie($s,r=>Math.tan(r)),aR={kernelName:$s,backendName:\"cpu\",kernelFunc:D7};var A7=Ie(Es,r=>Math.tanh(r)),iR={kernelName:Es,backendName:\"cpu\",kernelFunc:A7};function F7(r){let{inputs:t,backend:e}=r,{tensor:o,indices:n,updates:s}=t,{sliceRank:a,numUpdates:i,sliceSize:p,strides:u,outputSize:c}=w.calculateShapes(s,n,o.shape),l=!1,m=e.bufferSync(n),d=e.bufferSync(s),f=e.bufferSync(o),h=zs(m,d,o.shape,c,p,i,a,u,f,l);return e.makeTensorInfo(o.shape,h.dtype,h.values)}var uR={kernelName:fs,backendName:\"cpu\",kernelFunc:F7};function P7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{reps:s}=o;Q(n,\"tile\");let a=Mf(e.bufferSync(n),s);return e.makeTensorInfo(a.shape,a.dtype,a.values)}var pR={kernelName:po,backendName:\"cpu\",kernelFunc:P7};function O7(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{k:s,sorted:a}=o;Q(n,\"topk\");let i=e.data.get(n.dataId).values,[p,u]=Lf(i,n.shape,n.dtype,s,a);return[e.makeTensorInfo(p.shape,p.dtype,p.values),e.makeTensorInfo(u.shape,u.dtype,u.values)]}var cR={kernelName:Rs,backendName:\"cpu\",kernelFunc:O7};function M7(r){let{inputs:t,attrs:e,backend:o}=r,{image:n,transforms:s}=t,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=e,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=y.computeStrides(n.shape),b=x[0],C=x[1],S=x[2],k=y.computeStrides(g),_=k[0],E=k[1],R=k[2],D=y.getTypedArrayFromDType(n.dtype,y.sizeFromShape(g));D.fill(p);let P=o.data.get(n.dataId).values,O=o.data.get(s.dataId).values;for(let L=0;Lt-1)if(t<=1)e=0;else{let o=2*t;e-=o*Math.trunc(e/o),e>=t&&(e=o-e-1)}return y.clamp(0,e,t-1)}function B7(r,t){let e=r;if(e<0)if(t<=1)e=0;else{let o=t-1;e+=t*(Math.trunc(-e/o)+1)}else if(e>t-1)if(t<=1)e=0;else{let o=t-1;e-=t*Math.trunc(e/o)}return y.clamp(0,e,t-1)}function z7(r,t){return r}function V7(r,t){return y.clamp(0,r,t-1)}function ql(r,t,e,o,n,s,a,i,p,u,c){let l=a*o+i*n+p*s+u;return 0<=i&&ie.disposeIntermediateTensorInfo(f)),d}var hR={kernelName:Ji,backendName:\"cpu\",kernelFunc:K7};var q7=[z_,jT,V_,W_,JT,U_,G_,H_,K_,q_,j_,X_,Y_,Q_,Z_,e$,t$,r$,o$,B_,n$,s$,a$,e_,i$,ZT,t_,u$,XT,p$,l$,m$,d$,f$,h$,g$,x$,y$,b$,C$,w$,S$,I$,v$,k$,N$,T$,_$,$$,E$,R$,D$,F$,A_,P$,r_,O$,o_,M$,n_,L$,B$,z$,s_,a_,V$,W$,U$,G$,i_,u_,YT,H$,c$,K$,q$,j$,F_,p_,c_,X$,l_,Y$,Q$,Z$,J$,eE,tE,rE,m_,oE,nE,sE,aE,uE,pE,cE,d_,lE,mE,hE,f_,h_,gE,xE,yE,g_,bE,SE,IE,Wf,vE,P_,y_,kE,NE,TE,_E,QT,Gl,$E,O_,M_,L_,EE,RE,DE,AE,FE,PE,OE,I_,ME,BE,zE,VE,k_,WE,UE,GE,N_,dE,KE,qE,jE,XE,YE,QE,ZE,JE,__,eR,$_,E_,tR,rR,oR,nR,sR,R_,A$,aR,iR,uR,pR,cR,mR,x_,dR,fR,hR,CE];for(let r of q7)ri(r);var Ac={};qe(Ac,{assertNotComplex:()=>Vs,bindCanvasToFramebuffer:()=>rZ,bindColorTextureToFramebuffer:()=>Ql,bindTextureToProgramUniformSampler:()=>BI,bindTextureUnit:()=>bR,bindVertexBufferToProgramAttribute:()=>jf,callAndCheck:()=>ce,canBeRepresented:()=>TI,createFragmentShader:()=>$I,createFramebuffer:()=>OI,createProgram:()=>EI,createStaticIndexBuffer:()=>AI,createStaticVertexBuffer:()=>DI,createTexture:()=>FI,createVertexShader:()=>_I,getBatchDim:()=>yi,getExtensionOrThrow:()=>Ec,getFramebufferErrorMessage:()=>CR,getMaxTexturesInShader:()=>WI,getNumChannels:()=>eZ,getProgramUniformLocation:()=>LI,getProgramUniformLocationOrThrow:()=>MI,getRowsCols:()=>bi,getShapeAs3D:()=>Dc,getTextureShapeFromLogicalShape:()=>zI,getWebGLDisjointQueryTimerVersion:()=>UI,getWebGLErrorMessage:()=>yR,getWebGLMaxTextureSize:()=>VI,hasExtension:()=>qr,isCapableOfRenderingToFloatTexture:()=>GI,isDownloadFloatTextureEnabled:()=>HI,isReshapeFree:()=>Cu,isWebGLFenceEnabled:()=>KI,isWebGLVersionEnabled:()=>Yf,linkProgram:()=>RI,logShaderSourceAndInfoLog:()=>qf,resetMaxTextureSize:()=>oZ,resetMaxTexturesInShader:()=>nZ,unbindColorTextureFromFramebuffer:()=>Xf,unbindTextureUnit:()=>tZ,validateFramebuffer:()=>Rc,validateProgram:()=>Yl,validateTextureSize:()=>PI});var wp={},Uf={alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!0};function vI(r,t){wp[r]=t}function Kr(r,t){if(!(r in wp)||t!=null){let o=X7(r,t);if(o!==null)wp[r]=o;else return console.log(\"Could not get context for WebGL version\",r),null}let e=wp[r];return e==null||e.isContextLost()?(delete wp[r],Kr(r)):(e.disable(e.DEPTH_TEST),e.disable(e.STENCIL_TEST),e.disable(e.BLEND),e.disable(e.DITHER),e.disable(e.POLYGON_OFFSET_FILL),e.disable(e.SAMPLE_COVERAGE),e.enable(e.SCISSOR_TEST),e.enable(e.CULL_FACE),e.cullFace(e.BACK),wp[r])}function j7(r){if(!A().getBool(\"IS_SAFARI\")&&typeof OffscreenCanvas!=\"undefined\"&&r===2)return new OffscreenCanvas(300,150);if(typeof document!=\"undefined\")return document.createElement(\"canvas\");throw new Error(\"Cannot create a canvas in this context\")}function X7(r,t){if(r!==1&&r!==2)throw new Error(\"Cannot get WebGL rendering context, WebGL is disabled.\");let e=t==null?j7(r):t;return e.addEventListener(\"webglcontextlost\",o=>{o.preventDefault(),delete wp[r]},!1),A().getBool(\"SOFTWARE_WEBGL_ENABLED\")&&(Uf.failIfMajorPerformanceCaveat=!1),r===1?e.getContext(\"webgl\",Uf)||e.getContext(\"experimental-webgl\",Uf):e.getContext(\"webgl2\",Uf)}var bu;(function(r){r[r.DENSE=0]=\"DENSE\",r[r.SHARED_BATCH=1]=\"SHARED_BATCH\"})(bu||(bu={}));var dr;(function(r){r[r.RENDER=0]=\"RENDER\",r[r.UPLOAD=1]=\"UPLOAD\",r[r.PIXELS=2]=\"PIXELS\",r[r.DOWNLOAD=3]=\"DOWNLOAD\"})(dr||(dr={}));var rr;(function(r){r[r.UNPACKED_FLOAT16=0]=\"UNPACKED_FLOAT16\",r[r.UNPACKED_FLOAT32=1]=\"UNPACKED_FLOAT32\",r[r.PACKED_4X1_UNSIGNED_BYTE=2]=\"PACKED_4X1_UNSIGNED_BYTE\",r[r.PACKED_2X2_FLOAT32=3]=\"PACKED_2X2_FLOAT32\",r[r.PACKED_2X2_FLOAT16=4]=\"PACKED_2X2_FLOAT16\"})(rr||(rr={}));function Sp(r,t){return[t,r]}function gR(r,t){return r*t}function jl(r){let t=y.sizeFromShape(r),e=Math.ceil(t/4);return y.sizeToSquarishShape(e)}function La(r,t){return[Math.max(1,Math.ceil(t/2)),Math.max(1,Math.ceil(r/2))]}function xR(r,t){let[e,o]=La(r,t);return e*o*4}function Xl(r,t){let e=r,o,n,s,a,i,p,u,c,l,m;return A().getNumber(\"WEBGL_VERSION\")===2?(o=e.R32F,n=e.R16F,s=e.RGBA16F,a=e.RGBA32F,i=e.RED,u=4,c=1,l=e.HALF_FLOAT,m=e.FLOAT,p=e.RGBA8):(o=r.RGBA,n=r.RGBA,s=r.RGBA,a=e.RGBA,i=r.RGBA,u=4,c=4,l=t!=null?t.HALF_FLOAT_OES:null,m=r.FLOAT,p=r.RGBA),{internalFormatFloat:o,internalFormatHalfFloat:n,internalFormatPackedHalfFloat:s,internalFormatPackedFloat:a,textureFormatFloat:i,downloadTextureFormat:p,downloadUnpackNumChannels:u,defaultNumChannels:c,textureTypeHalfFloat:l,textureTypeFloat:m}}function ce(r,t){let e=t();return A().getBool(\"DEBUG\")&&Y7(r),e}function Y7(r){let t=r.getError();if(t!==r.NO_ERROR)throw new Error(\"WebGL Error: \"+yR(r,t))}var Q7=596e-10,Z7=65504;function TI(r){return!!(A().getBool(\"WEBGL_RENDER_FLOAT32_ENABLED\")||r===0||Q7r.getExtension(t),'Extension \"'+t+'\" not supported on this browser.')}function _I(r,t){let e=xi(r,()=>r.createShader(r.VERTEX_SHADER),\"Unable to create vertex WebGLShader.\");if(ce(r,()=>r.shaderSource(e,t)),ce(r,()=>r.compileShader(e)),r.getShaderParameter(e,r.COMPILE_STATUS)===!1)throw console.log(r.getShaderInfoLog(e)),new Error(\"Failed to compile vertex shader.\");return e}function $I(r,t){let e=xi(r,()=>r.createShader(r.FRAGMENT_SHADER),\"Unable to create fragment WebGLShader.\");if(ce(r,()=>r.shaderSource(e,t)),ce(r,()=>r.compileShader(e)),A().get(\"ENGINE_COMPILE_ONLY\"))return e;if(r.getShaderParameter(e,r.COMPILE_STATUS)===!1)throw qf(t,r.getShaderInfoLog(e)),new Error(\"Failed to compile fragment shader.\");return e}var J7=/ERROR: [0-9]+:([0-9]+):/g;function qf(r,t){let e=J7.exec(t);if(e==null){console.log(`Couldn't parse line number in error: ${t}`),console.log(r);return}let o=+e[1],n=r.split(`\n`),s=n.length.toString().length+2,a=n.map((l,m)=>y.rightPad((m+1).toString(),s)+l),i=0;for(let l=0;lr.createProgram(),\"Unable to create WebGLProgram.\")}function RI(r,t){if(ce(r,()=>r.linkProgram(t)),!A().get(\"ENGINE_COMPILE_ONLY\")&&r.getProgramParameter(t,r.LINK_STATUS)===!1)throw console.log(r.getProgramInfoLog(t)),new Error(\"Failed to link vertex and fragment shaders.\")}function Yl(r,t){if(ce(r,()=>r.validateProgram(t)),r.getProgramParameter(t,r.VALIDATE_STATUS)===!1)throw console.log(r.getProgramInfoLog(t)),new Error(\"Shader program validation failed.\")}function DI(r,t){let e=xi(r,()=>r.createBuffer(),\"Unable to create WebGLBuffer\");return ce(r,()=>r.bindBuffer(r.ARRAY_BUFFER,e)),ce(r,()=>r.bufferData(r.ARRAY_BUFFER,t,r.STATIC_DRAW)),e}function AI(r,t){let e=xi(r,()=>r.createBuffer(),\"Unable to create WebGLBuffer\");return ce(r,()=>r.bindBuffer(r.ELEMENT_ARRAY_BUFFER,e)),ce(r,()=>r.bufferData(r.ELEMENT_ARRAY_BUFFER,t,r.STATIC_DRAW)),e}function eZ(){return A().getNumber(\"WEBGL_VERSION\")===2?1:4}function FI(r){return xi(r,()=>r.createTexture(),\"Unable to create WebGLTexture.\")}function PI(r,t){let e=A().getNumber(\"WEBGL_MAX_TEXTURE_SIZE\");if(r<=0||t<=0){let o=`[${r}x${t}]`;throw new Error(\"Requested texture size \"+o+\" is invalid.\")}if(r>e||t>e){let o=`[${r}x${t}]`,n=`[${e}x${e}]`;throw new Error(\"Requested texture size \"+o+\" greater than WebGL maximum on this browser / GPU \"+n+\".\")}}function OI(r){return xi(r,()=>r.createFramebuffer(),\"Unable to create WebGLFramebuffer.\")}function jf(r,t,e,o,n,s,a){let i=r.getAttribLocation(t,e);return i===-1?!1:(ce(r,()=>r.bindBuffer(r.ARRAY_BUFFER,o)),ce(r,()=>r.vertexAttribPointer(i,n,r.FLOAT,!1,s,a)),ce(r,()=>r.enableVertexAttribArray(i)),!0)}function bR(r,t,e){wR(r,e),ce(r,()=>r.activeTexture(r.TEXTURE0+e)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,t))}function tZ(r,t){wR(r,t),ce(r,()=>r.activeTexture(r.TEXTURE0+t)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null))}function MI(r,t,e){return xi(r,()=>r.getUniformLocation(t,e),'uniform \"'+e+'\" not present in program.')}function LI(r,t,e){return r.getUniformLocation(t,e)}function BI(r,t,e,o){ce(r,()=>bR(r,t,o)),ce(r,()=>r.uniform1i(e,o))}function rZ(r){ce(r,()=>r.bindFramebuffer(r.FRAMEBUFFER,null)),ce(r,()=>r.viewport(0,0,r.canvas.width,r.canvas.height)),ce(r,()=>r.scissor(0,0,r.canvas.width,r.canvas.height))}function Ql(r,t,e){ce(r,()=>r.bindFramebuffer(r.FRAMEBUFFER,e)),ce(r,()=>r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,t,0))}function Xf(r,t){ce(r,()=>r.bindFramebuffer(r.FRAMEBUFFER,t)),ce(r,()=>r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,null,0))}function Rc(r){let t=r.checkFramebufferStatus(r.FRAMEBUFFER);if(t!==r.FRAMEBUFFER_COMPLETE)throw new Error(\"Error binding framebuffer: \"+CR(r,t))}function CR(r,t){switch(t){case r.FRAMEBUFFER_INCOMPLETE_ATTACHMENT:return\"FRAMEBUFFER_INCOMPLETE_ATTACHMENT\";case r.FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT:return\"FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT\";case r.FRAMEBUFFER_INCOMPLETE_DIMENSIONS:return\"FRAMEBUFFER_INCOMPLETE_DIMENSIONS\";case r.FRAMEBUFFER_UNSUPPORTED:return\"FRAMEBUFFER_UNSUPPORTED\";default:return`unknown error ${t}`}}function xi(r,t,e){let o=ce(r,()=>t());if(o==null)throw new Error(e);return o}function wR(r,t){let e=r.MAX_COMBINED_TEXTURE_IMAGE_UNITS-1,o=t+r.TEXTURE0;if(oe){let n=`[gl.TEXTURE0, gl.TEXTURE${e}]`;throw new Error(`textureUnit must be in ${n}.`)}}function yi(r,t=2){return y.sizeFromShape(r.slice(0,r.length-t))}function bi(r){if(r.length===0)throw Error(\"Cannot get rows and columns of an empty shape array.\");return[r.length>1?r[r.length-2]:1,r[r.length-1]]}function Dc(r){let t=[1,1,1];return r.length===0||r.length===1&&r[0]===1||(t=[yi(r),...bi(r)]),t}function zI(r,t=!1){let e=A().getNumber(\"WEBGL_MAX_TEXTURE_SIZE\"),o=A().getNumber(\"WEBGL_MAX_SIZE_FOR_NARROW_TEXTURE\");o===1/0&&A().getBool(\"WEBGL_AUTO_SQUARIFY_NARROW_TEXTURE_SHAPE\")&&(o=e/2),t&&(e=e*2,o=o*2,r=r.map((i,p)=>p>=r.length-2?y.nearestLargerEven(r[p]):r[p]),r.length===1&&(r=[2,r[0]])),r.length!==2&&(r=y.squeezeShape(r).newShape);let n=y.sizeFromShape(r),s=null;r.length<=1&&n<=e?s=[1,n]:r.length===2&&r[0]<=e&&r[1]<=e?s=r:r.length===3&&r[0]*r[1]<=e&&r[2]<=e?s=[r[0]*r[1],r[2]]:r.length===3&&r[0]<=e&&r[1]*r[2]<=e?s=[r[0],r[1]*r[2]]:r.length===4&&r[0]*r[1]*r[2]<=e&&r[3]<=e?s=[r[0]*r[1]*r[2],r[3]]:r.length===4&&r[0]<=e&&r[1]*r[2]*r[3]<=e&&(s=[r[0],r[1]*r[2]*r[3]]);let a=s!=null&&Math.max(...s)>o&&Math.min(...s)<=(t?2:1)&&Math.min(...s)>0;if(s==null||a)if(t){let i=yi(r),p=2,u=2;r.length&&([p,u]=bi(r)),n=i*(p/2)*(u/2),s=y.sizeToSquarishShape(n).map(c=>c*2)}else s=y.sizeToSquarishShape(n);return s}function Gf(r){return r%2===0}function Cu(r,t){if(r=r.slice(-2),t=t.slice(-2),y.arraysEqual(r,t)||!r.length||!t.length||r[0]===0||r[1]===0||t[0]===0||t[1]===0)return!0;if(r.length!==t.length){let e=r[r.length-1],o=t[t.length-1];if(e===o||Gf(e)&&Gf(o)&&(r[0]===1||t[0]===1))return!0}return r[1]===t[1]&&Gf(r[0])&&Gf(t[0])}var Hf,Kf;function VI(r){if(Hf==null){let t=Kr(r);Hf=t.getParameter(t.MAX_TEXTURE_SIZE)}return Hf}function oZ(){Hf=null}function nZ(){Kf=null}function WI(r){if(Kf==null){let t=Kr(r);Kf=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS)}return Math.min(16,Kf)}function UI(r){if(r===0)return 0;let t,e=Kr(r);return qr(e,\"EXT_disjoint_timer_query_webgl2\")&&r===2?t=2:qr(e,\"EXT_disjoint_timer_query\")?t=1:t=0,t}function qr(r,t){return r.getExtension(t)!=null}function Yf(r){try{if(Kr(r)!=null)return!0}catch(t){return console.log(\"Error when getting WebGL context: \",t),!1}return!1}function GI(r){if(r===0)return!1;let t=Kr(r);if(r===1){if(!qr(t,\"OES_texture_float\"))return!1}else if(!qr(t,\"EXT_color_buffer_float\"))return!1;return NI(t)}function HI(r){if(r===0)return!1;let t=Kr(r);if(r===1){if(!qr(t,\"OES_texture_float\")||!qr(t,\"WEBGL_color_buffer_float\"))return!1}else{if(qr(t,\"EXT_color_buffer_float\"))return NI(t);let o=\"EXT_color_buffer_half_float\";if(qr(t,o)){let n=t.getExtension(o);return sZ(t,n)}return!1}return NI(t)}function NI(r){let t=Xl(r),e=r.createTexture();r.bindTexture(r.TEXTURE_2D,e);let o=1,n=1;r.texImage2D(r.TEXTURE_2D,0,t.internalFormatFloat,o,n,0,t.textureFormatFloat,t.textureTypeFloat,null);let s=r.createFramebuffer();r.bindFramebuffer(r.FRAMEBUFFER,s),r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,e,0);let a=r.checkFramebufferStatus(r.FRAMEBUFFER)===r.FRAMEBUFFER_COMPLETE;return r.bindTexture(r.TEXTURE_2D,null),r.bindFramebuffer(r.FRAMEBUFFER,null),r.deleteTexture(e),r.deleteFramebuffer(s),a}function sZ(r,t){let e=Xl(r,t),o=r.createTexture();r.bindTexture(r.TEXTURE_2D,o);let n=1,s=1;r.texImage2D(r.TEXTURE_2D,0,e.internalFormatHalfFloat,n,s,0,e.textureFormatFloat,e.textureTypeHalfFloat,null);let a=r.createFramebuffer();r.bindFramebuffer(r.FRAMEBUFFER,a),r.framebufferTexture2D(r.FRAMEBUFFER,r.COLOR_ATTACHMENT0,r.TEXTURE_2D,o,0);let i=r.checkFramebufferStatus(r.FRAMEBUFFER)===r.FRAMEBUFFER_COMPLETE;return r.bindTexture(r.TEXTURE_2D,null),r.bindFramebuffer(r.FRAMEBUFFER,null),r.deleteTexture(o),r.deleteFramebuffer(a),i}function KI(r){return r!==2?!1:Kr(r).fenceSync!=null}function Vs(r,t){Array.isArray(r)||(r=[r]),r.forEach(e=>{e!=null&&y.assert(e.dtype!==\"complex64\",()=>`${t} does not support complex64 tensors in the WebGL backend.`)})}var Se=A();Se.registerFlag(\"HAS_WEBGL\",()=>Se.getNumber(\"WEBGL_VERSION\")>0);Se.registerFlag(\"WEBGL_VERSION\",()=>Yf(2)?2:Yf(1)?1:0);Se.registerFlag(\"WEBGL_CHECK_NUMERICAL_PROBLEMS\",()=>!1);Se.registerFlag(\"WEBGL_BUFFER_SUPPORTED\",()=>Se.get(\"WEBGL_VERSION\")===2);Se.registerFlag(\"WEBGL_CPU_FORWARD\",()=>!0);Se.registerFlag(\"WEBGL_FORCE_F16_TEXTURES\",()=>!1);Se.registerFlag(\"WEBGL_PACK\",()=>Se.getBool(\"HAS_WEBGL\"));Se.registerFlag(\"WEBGL_PACK_NORMALIZATION\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_CLIP\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_DEPTHWISECONV\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_BINARY_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_UNARY_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_ARRAY_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_IMAGE_OPERATIONS\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_REDUCE\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_LAZILY_UNPACK\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_CONV_IM2COL\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_PACK_CONV2DTRANSPOSE\",()=>Se.getBool(\"WEBGL_PACK\"));Se.registerFlag(\"WEBGL_MAX_TEXTURE_SIZE\",()=>VI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_MAX_TEXTURES_IN_SHADER\",()=>WI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\",()=>{let r=Se.getNumber(\"WEBGL_VERSION\");return r===0?0:UI(r)});Se.registerFlag(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\",()=>Se.getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")>0&&!ou.isMobile());Se.registerFlag(\"WEBGL_RENDER_FLOAT32_CAPABLE\",()=>GI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_RENDER_FLOAT32_ENABLED\",()=>Se.getBool(\"WEBGL_FORCE_F16_TEXTURES\")?!1:Se.getBool(\"WEBGL_RENDER_FLOAT32_CAPABLE\"));Se.registerFlag(\"WEBGL_DOWNLOAD_FLOAT_ENABLED\",()=>HI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_FENCE_API_ENABLED\",()=>KI(Se.getNumber(\"WEBGL_VERSION\")));Se.registerFlag(\"WEBGL_SIZE_UPLOAD_UNIFORM\",()=>Se.getBool(\"WEBGL_RENDER_FLOAT32_ENABLED\")?4:0);Se.registerFlag(\"WEBGL_DELETE_TEXTURE_THRESHOLD\",()=>-1,r=>{if(typeof r!=\"number\")throw new Error(`WEBGL_DELETE_TEXTURE_THRESHOLD must be a number but got ${r}.`);if(r<0&&r!==-1)throw new Error(`WEBGL_DELETE_TEXTURE_THRESHOLD must be -1 (indicating never delete) or at least 0, but got ${r}.`)});Se.registerFlag(\"WEBGL_FLUSH_THRESHOLD\",()=>ou.isMobile()?1:-1,r=>{if(typeof r!=\"number\")throw new Error(`WEBGL_FLUSH_THRESHOLD must be a number but got ${r}.`);if(r<0&&r!==-1)throw new Error(`WEBGL_FLUSH_THRESHOLD must be -1 (indicating never manual flush) or at least 0, but got ${r}.`)});Se.registerFlag(\"CPU_HANDOFF_SIZE_THRESHOLD\",()=>128);Se.registerFlag(\"WEBGL_USE_SHAPES_UNIFORMS\",()=>!1);Se.registerFlag(\"TOPK_LAST_DIM_CPU_HANDOFF_SIZE_THRESHOLD\",()=>1e5);Se.registerFlag(\"TOPK_K_CPU_HANDOFF_THRESHOLD\",()=>128);Se.registerFlag(\"WEBGL_EXP_CONV\",()=>!1);Se.registerFlag(\"SOFTWARE_WEBGL_ENABLED\",()=>Se.getBool(\"IS_TEST\"));Se.registerFlag(\"WEBGL_MAX_SIZE_FOR_NARROW_TEXTURE\",()=>1/0);Se.registerFlag(\"WEBGL_AUTO_SQUARIFY_NARROW_TEXTURE_SHAPE\",()=>!1);Se.registerFlag(\"WEBGL2_ISNAN_CUSTOM\",()=>!1);Se.registerFlag(\"ENGINE_COMPILE_ONLY\",()=>!1);function vt(){let r,t,e,o,n,s,a,i,p,u;return A().getNumber(\"WEBGL_VERSION\")===2?(r=\"#version 300 es\",t=\"in\",e=\"out\",o=\"in\",n=\"texture\",s=\"outputColor\",a=\"out vec4 outputColor;\",i=A().getBool(\"WEBGL2_ISNAN_CUSTOM\")?`\n bool isnan_custom(float val) {\n uint floatToUint = floatBitsToUint(val);\n return (floatToUint & 0x7fffffffu) > 0x7f800000u;\n }\n\n bvec4 isnan_custom(vec4 val) {\n return bvec4(isnan_custom(val.x),\n isnan_custom(val.y), isnan_custom(val.z), isnan_custom(val.w));\n }\n\n #define isnan(value) isnan_custom(value)\n `:\"\",p=\"\",u=`\n #define round(value) newRound(value)\n int newRound(float value) {\n return int(floor(value + 0.5));\n }\n\n ivec4 newRound(vec4 value) {\n return ivec4(floor(value + vec4(0.5)));\n }\n `):(r=\"\",t=\"attribute\",e=\"varying\",o=\"varying\",n=\"texture2D\",s=\"gl_FragColor\",a=\"\",i=`\n #define isnan(value) isnan_custom(value)\n bool isnan_custom(float val) {\n return (val > 0. || val < 1. || val == 0.) ? false : true;\n }\n bvec4 isnan_custom(vec4 val) {\n return bvec4(isnan(val.x), isnan(val.y), isnan(val.z), isnan(val.w));\n }\n `,p=`\n uniform float INFINITY;\n\n bool isinf(float val) {\n return abs(val) == INFINITY;\n }\n bvec4 isinf(vec4 val) {\n return equal(abs(val), vec4(INFINITY));\n }\n `,u=`\n int round(float value) {\n return int(floor(value + 0.5));\n }\n\n ivec4 round(vec4 value) {\n return ivec4(floor(value + vec4(0.5)));\n }\n `),{version:r,attribute:t,varyingVs:e,varyingFs:o,texture2D:n,output:s,defineOutput:a,defineSpecialNaN:i,defineSpecialInf:p,defineRound:u}}function Ws(r,t,e=\"index\"){let o=y.computeStrides(t);return o.map((n,s)=>{let a=`int ${r[s]} = ${e} / ${n}`,i=s===o.length-1?`int ${r[s+1]} = ${e} - ${r[s]} * ${n}`:`index -= ${r[s]} * ${n}`;return`${a}; ${i};`}).join(\"\")}function Ip(r,t,e=\"index\"){let o=y.computeStrides(t);return o.map((n,s)=>{let a=`int ${r[s]} = ${e} / outShapeStrides[${s}]`,i=s===o.length-1?`int ${r[s+1]} = ${e} - ${r[s]} * outShapeStrides[${s}]`:`index -= ${r[s]} * outShapeStrides[${s}]`;return`${a}; ${i};`}).join(\"\")}function aZ(r,t){let e=r.length,o=r.map(s=>`${t}[${s}]`),n=new Array(e-1);n[e-2]=o[e-1];for(let s=e-3;s>=0;--s)n[s]=`(${n[s+1]} * ${o[s+1]})`;return n}function SR(r,t,e=\"index\"){let o=r.map((s,a)=>a),n=aZ(o,t);return n.map((s,a)=>{let i=`int ${r[a]} = ${e} / ${n[a]}`,p=a===n.length-1?`int ${r[a+1]} = ${e} - ${r[a]} * ${n[a]}`:`index -= ${r[a]} * ${n[a]}`;return`${i}; ${p};`}).join(\"\")}function Fc(r){let t=y.computeStrides(r).map(e=>e.toString());return`\n int getFlatIndex(ivec3 coords) {\n return coords.x * ${t[0]} + coords.y * ${t[1]} + coords.z;\n }\n`}function Pc(){return`\n int getFlatIndex(ivec3 coords) {\n return coords.x * outShapeStrides[0] + coords.y * outShapeStrides[1] + coords.z;\n }\n`}var Qf=`\n const float FLOAT_MAX = 1.70141184e38;\n const float FLOAT_MIN = 1.17549435e-38;\n\n lowp vec4 encode_float(highp float v) {\n if (isnan(v)) {\n return vec4(255, 255, 255, 255);\n }\n\n highp float av = abs(v);\n\n if(av < FLOAT_MIN) {\n return vec4(0.0, 0.0, 0.0, 0.0);\n } else if(v > FLOAT_MAX) {\n return vec4(0.0, 0.0, 128.0, 127.0) / 255.0;\n } else if(v < -FLOAT_MAX) {\n return vec4(0.0, 0.0, 128.0, 255.0) / 255.0;\n }\n\n highp vec4 c = vec4(0,0,0,0);\n\n highp float e = floor(log2(av));\n highp float m = exp2(fract(log2(av))) - 1.0;\n\n c[2] = floor(128.0 * m);\n m -= c[2] / 128.0;\n c[1] = floor(32768.0 * m);\n m -= c[1] / 32768.0;\n c[0] = floor(8388608.0 * m);\n\n highp float ebias = e + 127.0;\n c[3] = floor(ebias / 2.0);\n ebias -= c[3] * 2.0;\n c[2] += floor(ebias) * 128.0;\n\n c[3] += 128.0 * step(0.0, -v);\n\n return c / 255.0;\n }\n`;var{getBroadcastDims:IR}=w;function vR(r,t,e){let o=[];if(r.forEach(d=>{let f=y.sizeFromShape(d.shapeInfo.logicalShape);if(d.shapeInfo.isUniform?o.push(`uniform float ${d.name}${f>1?`[${f}]`:\"\"};`):(o.push(`uniform sampler2D ${d.name};`),o.push(`uniform int offset${d.name};`)),e.enableShapeUniforms){let{uniformShape:h}=Zf(e.packedInputs,d.shapeInfo.logicalShape,d.shapeInfo.texShape);switch(h.length){case 1:o.push(`uniform int ${d.name}Shape;`);break;case 2:o.push(`uniform ivec2 ${d.name}Shape;`);break;case 3:o.push(`uniform ivec3 ${d.name}Shape;`);break;case 4:o.push(`uniform ivec4 ${d.name}Shape;`);break;default:break}o.push(`uniform ivec2 ${d.name}TexShape;`)}}),e.enableShapeUniforms){switch(t.logicalShape.length){case 1:o.push(\"uniform int outShape;\");break;case 2:o.push(\"uniform ivec2 outShape;\"),o.push(\"uniform int outShapeStrides;\");break;case 3:o.push(\"uniform ivec3 outShape;\"),o.push(\"uniform ivec2 outShapeStrides;\");break;case 4:o.push(\"uniform ivec4 outShape;\"),o.push(\"uniform ivec3 outShapeStrides;\");break;default:break}o.push(\"uniform ivec2 outTexShape;\")}e.customUniforms&&e.customUniforms.forEach(d=>{o.push(`uniform ${d.type} ${d.name}${d.arrayIndex?`[${d.arrayIndex}]`:\"\"};`)});let n=o.join(`\n`),s=r.map(d=>iZ(d,t,e.packedInputs,e.enableShapeUniforms)).join(`\n`),a=t.texShape,i=vt(),p=cZ(i),u,c,l=dZ(i);return t.isPacked?(u=uZ(t.logicalShape,a,e.enableShapeUniforms),c=mZ(i)):(u=pZ(t.logicalShape,a,e.enableShapeUniforms),c=lZ(i)),e.packedInputs&&(l+=xZ),[l,p,c,n,u,s,e.userCode].join(`\n`)}function Mc(r,t=!1){let e=r.shapeInfo.logicalShape;switch(e.length){case 0:return $Z(r,t);case 1:return RZ(r,t);case 2:return AZ(r,t);case 3:return PZ(r,t);case 4:return MZ(r,t);case 5:return LZ(r);case 6:return BZ(r);default:throw new Error(`${e.length}-D input sampling is not yet supported`)}}function kR(r,t){switch(r.shapeInfo.logicalShape.length){case 0:return _Z(r);case 1:return EZ(r,t);case 2:return DZ(r,t);case 3:return FZ(r,t);default:return OZ(r,t)}}function iZ(r,t,e=!1,o){let n=\"\";e?n+=kR(r,o):n+=Mc(r,o);let s=r.shapeInfo.logicalShape,a=t.logicalShape;return s.length<=a.length&&(e?n+=zZ(r,t):n+=VZ(r,t)),n}function uZ(r,t,e){switch(r.length){case 0:return NR();case 1:return yZ(r,t,e);case 2:return NZ(r,t,e);case 3:return CZ(r,t,e);default:return SZ(r,t,e)}}function pZ(r,t,e){switch(r.length){case 0:return NR();case 1:return bZ(r,t,e);case 2:return TZ(r,t,e);case 3:return wZ(r,t,e);case 4:return IZ(r,t,e);case 5:return vZ(r,t);case 6:return kZ(r,t);default:throw new Error(`${r.length}-D output sampling is not yet supported`)}}function cZ(r){return`\n float sampleTexture(sampler2D textureSampler, vec2 uv) {\n return ${r.texture2D}(textureSampler, uv).r;\n }\n `}function lZ(r){return`\n void setOutput(float val) {\n ${r.output} = vec4(val, 0, 0, 0);\n }\n `}function mZ(r){return`\n void setOutput(vec4 val) {\n ${r.output} = val;\n }\n `}function dZ(r){return`${r.version}\n precision highp float;\n precision highp int;\n precision highp sampler2D;\n ${r.varyingFs} vec2 resultUV;\n ${r.defineOutput}\n const vec2 halfCR = vec2(0.5, 0.5);\n\n struct ivec5\n {\n int x;\n int y;\n int z;\n int w;\n int u;\n };\n\n struct ivec6\n {\n int x;\n int y;\n int z;\n int w;\n int u;\n int v;\n };\n\n uniform float NAN;\n ${r.defineSpecialNaN}\n ${r.defineSpecialInf}\n ${r.defineRound}\n\n int imod(int x, int y) {\n return x - y * (x / y);\n }\n\n int idiv(int a, int b, float sign) {\n int res = a / b;\n int mod = imod(a, b);\n if (sign < 0. && mod != 0) {\n res -= 1;\n }\n return res;\n }\n\n //Based on the work of Dave Hoskins\n //https://www.shadertoy.com/view/4djSRW\n #define HASHSCALE1 443.8975\n float random(float seed){\n vec2 p = resultUV * seed;\n vec3 p3 = fract(vec3(p.xyx) * HASHSCALE1);\n p3 += dot(p3, p3.yzx + 19.19);\n return fract((p3.x + p3.y) * p3.z);\n }\n\n ${fZ}\n ${hZ}\n ${gZ}\n `}var fZ=`\nvec2 uvFromFlat(int texNumR, int texNumC, int index) {\n int texR = index / texNumC;\n int texC = index - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\nvec2 packedUVfrom1D(int texNumR, int texNumC, int index) {\n int texelIndex = index / 2;\n int texR = texelIndex / texNumC;\n int texC = texelIndex - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n`,hZ=`\nvec2 packedUVfrom2D(int texelsInLogicalRow, int texNumR,\n int texNumC, int row, int col) {\n int texelIndex = (row / 2) * texelsInLogicalRow + (col / 2);\n int texR = texelIndex / texNumC;\n int texC = texelIndex - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n`,gZ=`\nvec2 packedUVfrom3D(int texNumR, int texNumC,\n int texelsInBatch, int texelsInLogicalRow, int b,\n int row, int col) {\n int index = b * texelsInBatch + (row / 2) * texelsInLogicalRow + (col / 2);\n int texR = index / texNumC;\n int texC = index - texR * texNumC;\n return (vec2(texC, texR) + halfCR) / vec2(texNumC, texNumR);\n}\n`,xZ=`\n float getChannel(vec4 frag, vec2 innerDims) {\n vec2 modCoord = mod(innerDims, 2.);\n return modCoord.x == 0. ?\n (modCoord.y == 0. ? frag.r : frag.g) :\n (modCoord.y == 0. ? frag.b : frag.a);\n }\n float getChannel(vec4 frag, int dim) {\n float modCoord = mod(float(dim), 2.);\n return modCoord == 0. ? frag.r : frag.g;\n }\n`;function NR(){return`\n int getOutputCoords() {\n return 0;\n }\n `}function yZ(r,t,e){let o=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)];return o[0]===1?e?`\n int getOutputCoords() {\n return 2 * int(resultUV.x * ceil(float(outTexShape[1]) / 2.0));\n }\n `:`\n int getOutputCoords() {\n return 2 * int(resultUV.x * ${o[1]}.0);\n }\n `:o[1]===1?e?`\n int getOutputCoords() {\n return 2 * int(resultUV.y * ceil(float(outTexShape[0]) / 2.0));\n }\n `:`\n int getOutputCoords() {\n return 2 * int(resultUV.y * ${o[0]}.0);\n }\n `:e?`\n int getOutputCoords() {\n ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(packedTexShape[0], packedTexShape[1]));\n return 2 * (resTexRC.x * packedTexShape[1] + resTexRC.y);\n }\n `:`\n int getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${o[0]}, ${o[1]}));\n return 2 * (resTexRC.x * ${o[1]} + resTexRC.y);\n }\n `}function bZ(r,t,e){return t[0]===1?e?`\n int getOutputCoords() {\n return int(resultUV.x * float(outTexShape[1]));\n }\n `:`\n int getOutputCoords() {\n return int(resultUV.x * ${t[1]}.0);\n }\n `:t[1]===1?e?`\n int getOutputCoords() {\n return int(resultUV.y * float(outTexShape[0]));\n }\n `:`\n int getOutputCoords() {\n return int(resultUV.y * ${t[0]}.0);\n }\n `:e?`\n int getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(outTexShape[0], outTexShape[1]));\n return resTexRC.x * outTexShape[1] + resTexRC.y;\n }\n `:`\n int getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${t[0]}, ${t[1]}));\n return resTexRC.x * ${t[1]} + resTexRC.y;\n }\n `}function CZ(r,t,e){if(e)return`\n ivec3 getOutputCoords() {\n ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n int texelsInLogicalRow = int(ceil(float(outShape[2]) / 2.0));\n int texelsInBatch = texelsInLogicalRow * int(ceil(float(outShape[1]) / 2.0));\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(packedTexShape[0], packedTexShape[1]));\n int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n\n int b = index / texelsInBatch;\n index -= b * texelsInBatch;\n\n int r = 2 * (index / texelsInLogicalRow);\n int c = imod(index, texelsInLogicalRow) * 2;\n\n return ivec3(b, r, c);\n }\n `;let o=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)],n=Math.ceil(r[2]/2),s=n*Math.ceil(r[1]/2);return`\n ivec3 getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${o[0]}, ${o[1]}));\n int index = resTexRC.x * ${o[1]} + resTexRC.y;\n\n int b = index / ${s};\n index -= b * ${s};\n\n int r = 2 * (index / ${n});\n int c = imod(index, ${n}) * 2;\n\n return ivec3(b, r, c);\n }\n `}function wZ(r,t,e){if(e)return`\n ivec3 getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(outTexShape[0], outTexShape[1]));\n int index = resTexRC.x * outTexShape[1] + resTexRC.y;\n ${Ip([\"r\",\"c\",\"d\"],r)}\n return ivec3(r, c, d);\n }\n`;let o=Ws([\"r\",\"c\",\"d\"],r);return`\n ivec3 getOutputCoords() {\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(${t[0]}, ${t[1]}));\n int index = resTexRC.x * ${t[1]} + resTexRC.y;\n ${o}\n return ivec3(r, c, d);\n }\n `}function SZ(r,t,e){if(e)return`\n ivec4 getOutputCoords() {\n ivec2 packedTexShape = ivec2(ceil(float(outTexShape[0]) / 2.0), ceil(float(outTexShape[1]) / 2.0));\n ivec2 resTexRC = ivec2(resultUV.yx *\n vec2(packedTexShape[0], packedTexShape[1]));\n int index = resTexRC.x * packedTexShape[1] + resTexRC.y;\n\n int texelsInLogicalRow = int(ceil(float(outShape[3]) / 2.0));\n int texelsInBatch = texelsInLogicalRow * int(ceil(float(outShape[2]) / 2.0));\n int texelsInBatchN = texelsInBatch * outShape[1];\n\n int b2 = index / texelsInBatchN;\n index -= b2 * texelsInBatchN;\n\n int b = index / texelsInBatch;\n index -= b * texelsInBatch;\n\n int r = 2 * (index / texelsInLogicalRow);\n int c = imod(index, texelsInLogicalRow) * 2;\n\n return ivec4(b2, b, r, c);\n }\n `;let o=[Math.ceil(t[0]/2),Math.ceil(t[1]/2)],n=Math.ceil(r[r.length-1]/2),s=n*Math.ceil(r[r.length-2]/2),a=s,i=\"\",p=\"b, r, c\";for(let u=2;u=1?c=\"coords = 0;\":c=i.map(b=>`coords.${l[b+u]} = 0;`).join(`\n`);let m=\"\";a<2&&s>0?m=\"coords\":m=r.shapeInfo.logicalShape.map((b,C)=>`coords.${l[C+u]}`).join(\", \");let d=\"return outputValue;\",h=y.sizeFromShape(r.shapeInfo.logicalShape)===1,x=y.sizeFromShape(t.logicalShape)===1;if(s===1&&!h&&!x)d=`\n return vec4(outputValue.xy, outputValue.xy);\n `;else if(h&&!x)a===1?d=`\n return vec4(outputValue.x, outputValue.x, 0., 0.);\n `:d=`\n return vec4(outputValue.x);\n `;else if(i.length){let b=s-2,C=s-1;i.indexOf(b)>-1&&i.indexOf(C)>-1?d=\"return vec4(outputValue.x);\":i.indexOf(b)>-1?d=\"return vec4(outputValue.x, outputValue.y, outputValue.x, outputValue.y);\":i.indexOf(C)>-1&&(d=\"return vec4(outputValue.xx, outputValue.zz);\")}return`\n vec4 ${n}() {\n ${p} coords = getOutputCoords();\n ${c}\n vec4 outputValue = get${o}(${m});\n ${d}\n }\n `}function VZ(r,t){let e=r.name,o=e.charAt(0).toUpperCase()+e.slice(1),n=\"get\"+o+\"AtOutCoords\",s=t.texShape,a=r.shapeInfo.texShape,i=r.shapeInfo.logicalShape.length,p=t.logicalShape.length;if(!r.shapeInfo.isUniform&&i===p&&r.shapeInfo.flatOffset==null&&y.arraysEqual(a,s))return`\n float ${n}() {\n return sampleTexture(${e}, resultUV);\n }\n `;let u=Re(p),c=IR(r.shapeInfo.logicalShape,t.logicalShape),l=p-i,m,d=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"];i===0?m=\"\":p<2&&c.length>=1?m=\"coords = 0;\":m=c.map(h=>`coords.${d[h+l]} = 0;`).join(`\n`);let f=\"\";return p<2&&i>0?f=\"coords\":f=r.shapeInfo.logicalShape.map((h,g)=>`coords.${d[g+l]}`).join(\", \"),`\n float ${n}() {\n ${u} coords = getOutputCoords();\n ${m}\n return get${o}(${f});\n }\n `}function Re(r){if(r<=1)return\"int\";if(r===2)return\"ivec2\";if(r===3)return\"ivec3\";if(r===4)return\"ivec4\";if(r===5)return\"ivec5\";if(r===6)return\"ivec6\";throw Error(`GPU for rank ${r} is not yet supported`)}function Zf(r,t,e){let{newShape:o,keptDims:n}=y.squeezeShape(t),s=t.length,a=r&&s===3&&t[0]===1,i=a?t.slice(1):o,p=!r&&s>1&&!y.arraysEqual(t,e)&&o.lengthr[e]).join(\", \")}function _R(r,t,e,o){let n=e.map((c,l)=>{let m={logicalShape:c.shape,texShape:c.isUniform?null:c.texData.texShape,isUniform:c.isUniform,isPacked:c.isUniform?!1:c.texData.isPacked,flatOffset:null};return c.texData!=null&&c.texData.slice!=null&&c.texData.slice.flatOffset>0&&(m.flatOffset=c.texData.slice.flatOffset),{name:t.variableNames[l],shapeInfo:m}}),s=n.map(c=>c.shapeInfo),a={logicalShape:o.shape,texShape:o.texData.texShape,isUniform:!1,isPacked:o.texData.isPacked,flatOffset:null},i=vR(n,a,t),p=$I(r.gl,i),u=r.createProgram(p);return A().get(\"ENGINE_COMPILE_ONLY\")?{program:t,fragmentShader:p,source:i,webGLProgram:u,inShapeInfos:s,outShapeInfo:a,variablesLocations:null,customUniformLocations:null,infLoc:null,nanLoc:null,outShapeLocation:null,outShapeStridesLocation:null,outTexShapeLocation:null}:(r.buildVao(u),Object.assign({program:t,fragmentShader:p,source:i,webGLProgram:u,inShapeInfos:s,outShapeInfo:a},qI(r,t,u)))}function qI(r,t,e){let o=[],n=[],s,a,i,p=null,u=null;u=r.getUniformLocation(e,\"NAN\",!1),A().getNumber(\"WEBGL_VERSION\")===1&&(p=r.getUniformLocation(e,\"INFINITY\",!1));let c=!1;for(let l of t.variableNames){let m={name:l,uniform:r.getUniformLocation(e,l,c),offset:r.getUniformLocation(e,`offset${l}`,c)};t.enableShapeUniforms&&(m.shape=r.getUniformLocation(e,`${l}Shape`,c),m.texShape=r.getUniformLocation(e,`${l}TexShape`,c)),o.push(m)}if(t.enableShapeUniforms&&(s=r.getUniformLocation(e,\"outShape\",c),i=r.getUniformLocation(e,\"outShapeStrides\",c),a=r.getUniformLocation(e,\"outTexShape\",c)),t.customUniforms)for(let l of t.customUniforms)n.push(r.getUniformLocation(e,l.name,c));return{variablesLocations:o,customUniformLocations:n,infLoc:p,nanLoc:u,outShapeLocation:s,outShapeStridesLocation:i,outTexShapeLocation:a}}function TR(r,t){if(r.length!==t.length)throw Error(`Binary was compiled with ${r.length} inputs, but was executed with ${t.length} inputs`);r.forEach((e,o)=>{let n=e.logicalShape,s=t[o],a=s.shape;if(!y.arraysEqual(n,a))throw Error(`Binary was compiled with different shapes than the current args. Shapes ${n} and ${a} must match`);if(e.isUniform&&s.isUniform)return;let i=e.texShape,p=s.isUniform?null:s.texData.texShape;if(!y.arraysEqual(i,p))throw Error(`Binary was compiled with different texture shapes than the current args. Shape ${i} and ${p} must match`)})}function $R(r,t,e,o,n){t.program.enableShapeUniforms||(TR(t.inShapeInfos,e),TR([t.outShapeInfo],[o]));let s=o.texData.texture,a=o.texData.texShape;o.texData.isPacked?r.setOutputPackedMatrixTexture(s.texture,a[0],a[1]):r.setOutputMatrixTexture(s.texture,a[0],a[1]),r.setProgram(t.webGLProgram),r.bindVertexArray(t.webGLProgram.vao),A().getNumber(\"WEBGL_VERSION\")===1&&t.infLoc!==null&&r.gl.uniform1f(t.infLoc,1/0),t.nanLoc!==null&&r.gl.uniform1f(t.nanLoc,NaN);for(let p=0;p{let i=a.texData!=null&&a.texData.slice!=null&&a.texData.slice.flatOffset>0;if(r.enableShapeUniforms&&!a.isUniform){let p=a.texData.texShape,{useSqueezeShape:u,uniformShape:c,keptDims:l}=Zf(r.packedInputs,a.shape,p),m=\"\",d=\"\",f=\"\";if(c.length===1&&r.packedInputs){let k=[Math.ceil(p[0]/2),Math.ceil(p[1]/2)];m=`${k[0]>1}_${k[1]>1}`}else if(c.length===2&&!r.packedInputs)d=`${c[0]>1}_${c[1]>1}`;else if(c.length>2&&!r.packedInputs){let k=y.computeStrides(c);f=`${k[0]===p[1]}_${k[k.length-1]===p[1]}`}let h=a.shape.length,g=c.length===2&&y.arraysEqual(a.shape,p),x=y.sizeFromShape(a.shape)===1,b=w.getBroadcastDims(a.shape,e.shape),C=!r.packedInputs&&h===e.shape.length&&y.arraysEqual(p,e.texData.texShape),S=r.packedInputs||c.length>2?\"\":`${p[0]>1}_${p[1]>1}`;o+=`${h}_${C}_${u?l:\"\"}_${c.length}_${x}_${b}_${g}_${m}_${d}_${f}_${S}_${i}`}else{let p=a.isUniform?\"uniform\":a.texData.texShape;o+=`${a.shape}_${p}_${i}`}});let n=r.userCode,s=r.constructor.name;return s+=\"_\"+o+\"_\"+n+`${A().getNumber(\"WEBGL_VERSION\")}`,s}function pt(r){return A().getBool(\"WEBGL_USE_SHAPES_UNIFORMS\")&&r<=4}var Jf=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!1,this.packedOutput=!0,this.outPackingScheme=bu.DENSE,this.customUniforms=[{name:\"texShape\",type:\"ivec2\"}];let e=vt();this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n ivec3 outCoordsFromFlatIndex(int index) {\n ${this.enableShapeUniforms?Ip([\"r\",\"c\",\"d\"],t):Ws([\"r\",\"c\",\"d\"],t)}\n return ivec3(r, c, d);\n }\n\n void main() {\n ivec2 resTexRC = ivec2(resultUV.yx * vec2(texShape[0], texShape[1]));\n int index = 4 * (resTexRC.x * texShape[1] + resTexRC.y);\n\n vec4 result = vec4(0.);\n\n for (int i=0; i<4; i++) {\n int flatIndex = index + i;\n ivec3 rc = outCoordsFromFlatIndex(flatIndex);\n result[i] = getA(rc.x, rc.y, rc.z);\n }\n\n ${e.output} = result;\n }\n `}};var eh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outPackingScheme=bu.DENSE,this.customUniforms=[{name:\"texShape\",type:\"ivec2\"}];let e=vt();this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n ivec3 outCoordsFromFlatIndex(int index) {\n ${this.enableShapeUniforms?Ip([\"r\",\"c\",\"d\"],t):Ws([\"r\",\"c\",\"d\"],t)}\n return ivec3(r, c, d);\n }\n\n void main() {\n ivec2 resTexRC = ivec2(resultUV.yx * vec2(texShape[0], texShape[1]));\n int index = 4 * (resTexRC.x * texShape[1] + resTexRC.y);\n\n vec4 result = vec4(0.);\n\n for (int i=0; i<4; i++) {\n int flatIndex = index + i;\n ivec3 rc = outCoordsFromFlatIndex(flatIndex);\n result[i] = getChannel(getA(rc.x, rc.y, rc.z), vec2(rc.y, rc.z));\n }\n\n ${e.output} = result;\n }\n `}};var th=class{constructor(t){this.variableNames=[\"A\"],this.outTexUsage=dr.DOWNLOAD;let e=vt();this.outputShape=t,this.userCode=`\n ${Qf}\n\n void main() {\n float x = getAAtOutCoords();\n ${e.output} = encode_float(x);\n }\n `}};var rh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!1,this.outTexUsage=dr.DOWNLOAD;let e=vt();this.outputShape=t,this.userCode=`\n ${Qf}\n\n void main() {\n ivec3 coords = getOutputCoords();\n float x = getChannel(getAAtOutCoords(), vec2(coords.y, coords.z));\n ${e.output} = encode_float(x);\n }\n `}};var GZ={R:0,G:1,B:2,A:3},Zl=class{constructor(t,e=!1,o=\"RGBA\"){this.variableNames=[\"A\"],this.customUniforms=[{name:\"texShape\",type:\"ivec2\"}];let n=vt();this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length);let s=\"result\";e&&(s=\"floor(result * 255. + 0.5)\");let a=\"\";for(let i=0;irv,createBufferFromOutputTexture:()=>sv,createFloat16MatrixTexture:()=>ZI,createFloat16PackedMatrixTexture:()=>tv,createFloat32MatrixTexture:()=>QI,createIndexBuffer:()=>YI,createPackedMatrixTexture:()=>ev,createUnsignedBytesMatrixTexture:()=>JI,createVertexBuffer:()=>XI,createVertexShader:()=>jI,downloadByteEncodedFloatMatrixFromOutputTexture:()=>iv,downloadFloat32MatrixFromBuffer:()=>av,downloadMatrixFromPackedOutputTexture:()=>pv,downloadPackedMatrixFromBuffer:()=>uv,getInternalFormatForFloat16MatrixTexture:()=>sh,getInternalFormatForFloat16PackedMatrixTexture:()=>uh,getInternalFormatForFloat32MatrixTexture:()=>nh,getInternalFormatForPackedMatrixTexture:()=>ih,getInternalFormatForUnsignedBytesMatrixTexture:()=>ah,uploadDenseMatrixToTexture:()=>ov,uploadPixelDataToTexture:()=>nv});function jI(r){let t=vt(),e=`${t.version}\n precision highp float;\n ${t.attribute} vec3 clipSpacePos;\n ${t.attribute} vec2 uv;\n ${t.varyingVs} vec2 resultUV;\n\n void main() {\n gl_Position = vec4(clipSpacePos, 1);\n resultUV = uv;\n }`;return _I(r,e)}function XI(r){let t=new Float32Array([-1,1,0,0,1,-1,-1,0,0,0,1,1,0,1,1,1,-1,0,1,0]);return DI(r,t)}function YI(r){let t=new Uint16Array([0,1,2,2,1,3]);return AI(r,t)}function Jl(r,t,e,o,n,s){PI(t,e);let a=FI(r),i=r.TEXTURE_2D;return ce(r,()=>r.bindTexture(i,a)),ce(r,()=>r.texParameteri(i,r.TEXTURE_WRAP_S,r.CLAMP_TO_EDGE)),ce(r,()=>r.texParameteri(i,r.TEXTURE_WRAP_T,r.CLAMP_TO_EDGE)),ce(r,()=>r.texParameteri(i,r.TEXTURE_MIN_FILTER,r.NEAREST)),ce(r,()=>r.texParameteri(i,r.TEXTURE_MAG_FILTER,r.NEAREST)),A().getNumber(\"WEBGL_VERSION\")===1?ce(r,()=>r.texImage2D(i,0,o,t,e,0,n,s,null)):ce(r,()=>r.texStorage2D(i,1,o,t,e)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null)),{texture:a,texShape:[e,t]}}function nh(r){return r.internalFormatFloat}function QI(r,t,e,o){let[n,s]=Sp(t,e);return Jl(r,n,s,nh(o),o.textureFormatFloat,r.FLOAT)}function sh(r){return r.internalFormatHalfFloat}function ZI(r,t,e,o){let[n,s]=Sp(t,e);return Jl(r,n,s,sh(o),o.textureFormatFloat,o.textureTypeHalfFloat)}function ah(r){return r.downloadTextureFormat}function JI(r,t,e,o){let[n,s]=Sp(t,e);return Jl(r,n,s,ah(o),r.RGBA,r.UNSIGNED_BYTE)}function ih(r){return r.internalFormatPackedFloat}function ev(r,t,e,o){let[n,s]=La(t,e);return Jl(r,n,s,ih(o),r.RGBA,r.FLOAT)}function uh(r){return r.internalFormatPackedHalfFloat}function tv(r,t,e,o){let[n,s]=La(t,e);return Jl(r,n,s,uh(o),r.RGBA,o.textureTypeHalfFloat)}function rv(r,t,e){return ce(r,()=>r.bindBuffer(r.ARRAY_BUFFER,e)),jf(r,t,\"clipSpacePos\",e,3,20,0)&&jf(r,t,\"uv\",e,2,20,12)}function ov(r,t,e,o,n,s){ce(r,()=>r.bindTexture(r.TEXTURE_2D,t));let a,i,p;n instanceof Uint8Array?(a=new Uint8Array(e*o*4),i=r.UNSIGNED_BYTE,p=r.RGBA):(a=new Float32Array(e*o*4),i=r.FLOAT,p=s.internalFormatPackedFloat),a.set(n),A().getNumber(\"WEBGL_VERSION\")===2?ce(r,()=>r.texSubImage2D(r.TEXTURE_2D,0,0,0,e,o,r.RGBA,i,a)):ce(r,()=>r.texImage2D(r.TEXTURE_2D,0,p,e,o,0,r.RGBA,i,a)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null))}function nv(r,t,e){ce(r,()=>r.bindTexture(r.TEXTURE_2D,t)),e.data instanceof Uint8Array?A().getNumber(\"WEBGL_VERSION\")===2?ce(r,()=>r.texSubImage2D(r.TEXTURE_2D,0,0,0,e.width,e.height,r.RGBA,r.UNSIGNED_BYTE,e.data)):ce(r,()=>r.texImage2D(r.TEXTURE_2D,0,r.RGBA,e.width,e.height,0,r.RGBA,r.UNSIGNED_BYTE,e.data)):A().getNumber(\"WEBGL_VERSION\")===2?ce(r,()=>r.texSubImage2D(r.TEXTURE_2D,0,0,0,r.RGBA,r.UNSIGNED_BYTE,e)):ce(r,()=>r.texImage2D(r.TEXTURE_2D,0,r.RGBA,r.RGBA,r.UNSIGNED_BYTE,e)),ce(r,()=>r.bindTexture(r.TEXTURE_2D,null))}function sv(r,t,e,o){let n=r.createBuffer();ce(r,()=>r.bindBuffer(r.PIXEL_PACK_BUFFER,n));let i=4*4*t*e;return ce(r,()=>r.bufferData(r.PIXEL_PACK_BUFFER,i,r.STREAM_READ)),ce(r,()=>r.readPixels(0,0,e,t,r.RGBA,r.FLOAT,0)),ce(r,()=>r.bindBuffer(r.PIXEL_PACK_BUFFER,null)),n}function av(r,t,e){let o=r,n=new Float32Array(e);return o.bindBuffer(o.PIXEL_PACK_BUFFER,t),o.getBufferSubData(o.PIXEL_PACK_BUFFER,0,n),o.bindBuffer(o.PIXEL_PACK_BUFFER,null),n}function iv(r,t,e,o){let[n,s]=Sp(t,e),a=4,i=new Uint8Array(gR(t*e,a));return ce(r,()=>r.readPixels(0,0,n,s,o.downloadTextureFormat,r.UNSIGNED_BYTE,i)),new Float32Array(i.buffer)}function uv(r,t,e,o,n,s,a,i){let p=r,u=new Float32Array(xR(s,a));return p.bindBuffer(p.PIXEL_PACK_BUFFER,t),p.getBufferSubData(p.PIXEL_PACK_BUFFER,0,u),p.bindBuffer(p.PIXEL_PACK_BUFFER,null),u}function pv(r,t,e){let o=new Float32Array(t*e*4);return ce(r,()=>r.readPixels(0,0,e,t,r.RGBA,r.FLOAT,o)),o}var kp=class{constructor(t){this.outputTexture=null,this.program=null,this.disposed=!1,this.itemsToPoll=[];let e=A().getNumber(\"WEBGL_VERSION\");if(t!=null?(this.gl=t,vI(e,t)):this.gl=Kr(e),t=this.gl,A().getNumber(\"WEBGL_VERSION\")===2){let s=t;this.createVertexArray=()=>ce(s,()=>s.createVertexArray()),this.bindVertexArray=a=>ce(s,()=>s.bindVertexArray(a)),this.deleteVertexArray=a=>ce(s,()=>s.deleteVertexArray(a)),this.getVertexArray=()=>ce(s,()=>s.getParameter(s.VERTEX_ARRAY_BINDING))}else if(t!=null){let s=t.getExtension(\"OES_vertex_array_object\");if(s==null)throw new Error(\"All WebGL1 implementations are expected to offer OES_vertex_array_object.\");this.createVertexArray=()=>ce(t,()=>s.createVertexArrayOES()),this.bindVertexArray=a=>ce(t,()=>s.bindVertexArrayOES(a)),this.deleteVertexArray=a=>ce(t,()=>s.deleteVertexArrayOES(a)),this.getVertexArray=()=>ce(t,()=>t.getParameter(s.VERTEX_ARRAY_BINDING_OES))}let o=\"WEBGL_color_buffer_float\",n=\"EXT_color_buffer_half_float\";if(this.parallelCompilationExtension=this.gl.getExtension(\"KHR_parallel_shader_compile\"),A().getNumber(\"WEBGL_VERSION\")===1){let s=\"OES_texture_float\",a=\"OES_texture_half_float\";if(this.textureFloatExtension=Ec(this.gl,s),qr(this.gl,a))this.textureHalfFloatExtension=Ec(this.gl,a);else if(A().get(\"WEBGL_FORCE_F16_TEXTURES\"))throw new Error(\"GL context does not support half float textures, yet the environment flag WEBGL_FORCE_F16_TEXTURES is set to true.\");if(this.colorBufferFloatExtension=this.gl.getExtension(o),qr(this.gl,n))this.colorBufferHalfFloatExtension=Ec(this.gl,n);else if(A().get(\"WEBGL_FORCE_F16_TEXTURES\"))throw new Error(\"GL context does not support color renderable half floats, yet the environment flag WEBGL_FORCE_F16_TEXTURES is set to true.\")}else if(o=\"EXT_color_buffer_float\",qr(this.gl,o))this.colorBufferFloatExtension=this.gl.getExtension(o);else if(qr(this.gl,n))this.colorBufferHalfFloatExtension=this.gl.getExtension(n);else throw new Error(\"GL context does not support color renderable floats\");this.vertexBuffer=XI(this.gl),this.indexBuffer=YI(this.gl),this.framebuffer=OI(this.gl),this.textureConfig=Xl(this.gl,this.textureHalfFloatExtension)}get debug(){return A().getBool(\"DEBUG\")}dispose(){if(this.disposed)return;this.program!=null&&console.warn(\"Disposing a GPGPUContext that still has a bound WebGLProgram. This is probably a resource leak, delete the program with GPGPUContext.deleteProgram before disposing.\"),this.outputTexture!=null&&console.warn(\"Disposing a GPGPUContext that still has a bound output matrix texture. This is probably a resource leak, delete the output matrix texture with GPGPUContext.deleteMatrixTexture before disposing.\");let t=this.gl;ce(t,()=>t.finish()),ce(t,()=>t.bindFramebuffer(t.FRAMEBUFFER,null)),ce(t,()=>t.deleteFramebuffer(this.framebuffer)),ce(t,()=>t.bindBuffer(t.ARRAY_BUFFER,null)),ce(t,()=>t.bindBuffer(t.ELEMENT_ARRAY_BUFFER,null)),ce(t,()=>t.deleteBuffer(this.indexBuffer)),this.disposed=!0}createFloat32MatrixTexture(t,e){return this.throwIfDisposed(),QI(this.gl,t,e,this.textureConfig)}createFloat16MatrixTexture(t,e){return this.throwIfDisposed(),ZI(this.gl,t,e,this.textureConfig)}createUnsignedBytesMatrixTexture(t,e){return this.throwIfDisposed(),JI(this.gl,t,e,this.textureConfig)}uploadPixelDataToTexture(t,e){this.throwIfDisposed(),nv(this.gl,t,e)}uploadDenseMatrixToTexture(t,e,o,n){this.throwIfDisposed(),ov(this.gl,t,e,o,n,this.textureConfig)}createFloat16PackedMatrixTexture(t,e){return this.throwIfDisposed(),tv(this.gl,t,e,this.textureConfig)}createPackedMatrixTexture(t,e){return this.throwIfDisposed(),ev(this.gl,t,e,this.textureConfig)}deleteMatrixTexture(t){this.throwIfDisposed(),this.outputTexture===t&&(Xf(this.gl,this.framebuffer),this.outputTexture=null),ce(this.gl,()=>this.gl.deleteTexture(t))}downloadByteEncodedFloatMatrixFromOutputTexture(t,e,o){return this.downloadMatrixDriver(t,()=>iv(this.gl,e,o,this.textureConfig))}downloadPackedMatrixFromBuffer(t,e,o,n,s,a){return uv(this.gl,t,e,o,n,s,a,this.textureConfig)}downloadFloat32MatrixFromBuffer(t,e){return av(this.gl,t,e)}createBufferFromTexture(t,e,o){this.bindTextureToFrameBuffer(t);let n=sv(this.gl,e,o,this.textureConfig);return this.unbindTextureToFrameBuffer(),n}createAndWaitForFence(){let t=this.createFence(this.gl);return this.pollFence(t)}createFence(t){let e,o;if(A().getBool(\"WEBGL_FENCE_API_ENABLED\")){let n=t,s=n.fenceSync(n.SYNC_GPU_COMMANDS_COMPLETE,0);t.flush(),o=()=>{let a=n.clientWaitSync(s,0,0);return a===n.ALREADY_SIGNALED||a===n.CONDITION_SATISFIED},e=s}else A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")>0?(e=this.beginQuery(),this.endQuery(),o=()=>this.isQueryAvailable(e,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\"))):o=()=>!0;return{query:e,isFencePassed:o}}downloadMatrixFromPackedTexture(t,e,o){return this.downloadMatrixDriver(t,()=>pv(this.gl,e,o))}createProgram(t){this.throwIfDisposed();let e=this.gl;this.vertexShader==null&&(this.vertexShader=jI(e));let o=EI(e);ce(e,()=>e.attachShader(o,this.vertexShader)),ce(e,()=>e.attachShader(o,t)),RI(e,o);let n=Object.assign(o,{vao:this.createVertexArray()});return this.debug&&Yl(e,n),n}buildVao(t){this.setProgram(t),this.bindVertexArray(t.vao);let e=this.gl;ce(e,()=>e.bindBuffer(e.ELEMENT_ARRAY_BUFFER,this.indexBuffer)),rv(e,t,this.vertexBuffer)}deleteProgram(t){this.throwIfDisposed(),t===this.program&&(this.program=null),t!=null&&(ce(this.gl,()=>this.gl.deleteProgram(t)),this.deleteVertexArray(t.vao))}setProgram(t){this.throwIfDisposed(),this.program=t,this.program!=null&&this.debug&&Yl(this.gl,this.program),ce(this.gl,()=>this.gl.useProgram(t))}getUniformLocation(t,e,o=!0){return this.throwIfDisposed(),o?MI(this.gl,t,e):LI(this.gl,t,e)}getAttributeLocation(t,e){return this.throwIfDisposed(),ce(this.gl,()=>this.gl.getAttribLocation(t,e))}getUniformLocationNoThrow(t,e){return this.throwIfDisposed(),this.gl.getUniformLocation(t,e)}setInputMatrixTexture(t,e,o){this.throwIfDisposed(),this.throwIfNoProgram(),BI(this.gl,t,e,o)}setOutputMatrixTexture(t,e,o){this.setOutputMatrixTextureDriver(t,o,e)}setOutputPackedMatrixTexture(t,e,o){this.throwIfDisposed();let[n,s]=La(e,o);this.setOutputMatrixTextureDriver(t,n,s)}setOutputMatrixWriteRegion(t,e,o,n){this.setOutputMatrixWriteRegionDriver(o,t,n,e)}setOutputPackedMatrixWriteRegion(t,e,o,n){throw new Error(\"setOutputPackedMatrixWriteRegion not implemented.\")}debugValidate(){this.program!=null&&Yl(this.gl,this.program),Rc(this.gl)}executeProgram(){this.throwIfDisposed(),this.throwIfNoProgram();let t=this.gl;if(this.debug){let e=this.getVertexArray();console.assert(e===this.program.vao,\"VAO changed between setProgram and executeProgram!\"),this.debugValidate()}ce(t,()=>t.drawElements(t.TRIANGLES,6,t.UNSIGNED_SHORT,0))}blockUntilAllProgramsCompleted(){this.throwIfDisposed(),ce(this.gl,()=>this.gl.finish())}getQueryTimerExtension(){return this.disjointQueryTimerExtension==null&&(this.disjointQueryTimerExtension=Ec(this.gl,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")===2?\"EXT_disjoint_timer_query_webgl2\":\"EXT_disjoint_timer_query\")),this.disjointQueryTimerExtension}getQueryTimerExtensionWebGL2(){return this.getQueryTimerExtension()}getQueryTimerExtensionWebGL1(){return this.getQueryTimerExtension()}beginQuery(){if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")===2){let o=this.gl,n=this.getQueryTimerExtensionWebGL2(),s=o.createQuery();return o.beginQuery(n.TIME_ELAPSED_EXT,s),s}let t=this.getQueryTimerExtensionWebGL1(),e=t.createQueryEXT();return t.beginQueryEXT(t.TIME_ELAPSED_EXT,e),e}endQuery(){if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\")===2){let e=this.gl,o=this.getQueryTimerExtensionWebGL2();e.endQuery(o.TIME_ELAPSED_EXT);return}let t=this.getQueryTimerExtensionWebGL1();t.endQueryEXT(t.TIME_ELAPSED_EXT)}async waitForQueryAndGetTime(t){return await y.repeatedTry(()=>this.disposed||this.isQueryAvailable(t,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\"))),this.getQueryTime(t,A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_VERSION\"))}getQueryTime(t,e){if(e===0)return null;if(e===2){let o=this.gl;return o.getQueryParameter(t,o.QUERY_RESULT)/1e6}else{let o=this.getQueryTimerExtensionWebGL1();return o.getQueryObjectEXT(t,o.QUERY_RESULT_EXT)/1e6}}isQueryAvailable(t,e){if(e===0)return!0;if(e===2){let o=this.gl,n=this.getQueryTimerExtensionWebGL2(),s=o.getQueryParameter(t,o.QUERY_RESULT_AVAILABLE);return this.disjoint==null&&(this.disjoint=this.gl.getParameter(n.GPU_DISJOINT_EXT)),s&&!this.disjoint}else{let o=this.getQueryTimerExtensionWebGL1(),n=o.getQueryObjectEXT(t,o.QUERY_RESULT_AVAILABLE_EXT);return this.disjoint==null&&(this.disjoint=this.gl.getParameter(o.GPU_DISJOINT_EXT)),n&&!this.disjoint}}pollFence(t){return new Promise(e=>{this.addItemToPoll(()=>t.isFencePassed(),()=>e())})}pollItems(){let t=HZ(this.itemsToPoll.map(e=>e.isDoneFn));for(let e=0;e<=t;++e){let{resolveFn:o}=this.itemsToPoll[e];o()}this.itemsToPoll=this.itemsToPoll.slice(t+1)}addItemToPoll(t,e){if(this.itemsToPoll.push({isDoneFn:t,resolveFn:e}),this.itemsToPoll.length>1)return;let o;\"setTimeoutCustom\"in A().platform&&(o=A().platform.setTimeoutCustom.bind(A().platform)),y.repeatedTry(()=>(this.pollItems(),this.itemsToPoll.length===0),()=>0,null,o)}bindTextureToFrameBuffer(t){this.throwIfDisposed(),Ql(this.gl,t,this.framebuffer),this.debug&&Rc(this.gl)}unbindTextureToFrameBuffer(){this.outputTexture!=null?(Ql(this.gl,this.outputTexture,this.framebuffer),this.debug&&Rc(this.gl)):Xf(this.gl,this.framebuffer)}downloadMatrixDriver(t,e){this.bindTextureToFrameBuffer(t);let o=e();return this.unbindTextureToFrameBuffer(),o}setOutputMatrixTextureDriver(t,e,o){this.throwIfDisposed();let n=this.gl;Ql(n,t,this.framebuffer),this.debug&&Rc(n),this.outputTexture=t,ce(n,()=>n.viewport(0,0,e,o)),ce(n,()=>n.scissor(0,0,e,o))}setOutputMatrixWriteRegionDriver(t,e,o,n){this.throwIfDisposed(),ce(this.gl,()=>this.gl.scissor(t,e,o,n))}throwIfDisposed(){if(this.disposed)throw new Error(\"Attempted to use disposed GPGPUContext.\")}throwIfNoProgram(){if(this.program==null)throw new Error(\"No GPU program is currently set.\")}};function HZ(r){let t=0;for(;t`${r}.${e}`)}function Dt(r,t){return t===1?[r]:lv(r,t)}function SD(r,t){if(r===1)return\"rc\";let e=\"\";for(let o=0;o ${this.enableShapeUniforms?\"outShape\":this.outputShape[0]}`;let e=\"\";for(let o=this.rank-2;o= ${this.enableShapeUniforms?`outShape[${o}]`:this.outputShape[o]}`,o= ${o};\n bool rEdge = rp1 >= ${n};\n `}getOutput(t){let e=this.getSourceCoordsArr(t);return this.rank===1?`getA(rc), (rc + 1 >= ${this.enableShapeUniforms?\"outShape\":this.outputShape[0]} ? 0. : getA(rc + 1)), 0, 0`:`getA(${e[0]}),\n cEdge ? 0. : getA(${e[1]}),\n rEdge ? 0. : getA(${e[2]}),\n rEdge || cEdge ? 0. : getA(${e[3]})`}};var Vc=class{constructor(t,e){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"inputShape\",type:\"ivec3\"}],this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length);let o=\"\";for(let n=0;n<4;n++){let s=\"thisRC = rc;\";n%2===1&&(s+=\"thisRC.z += 1;\"),n>1&&(s+=\"thisRC.y += 1;\"),o+=`\n ${s}\n ${n>0?\"if(thisRC.y < rows && thisRC.z < cols){\":\"\"}\n int flatIndex = getFlatIndex(thisRC);\n\n ivec3 inputRC = inputCoordsFromReshapedOutCoords(flatIndex);\n vec2 inputRCInnerDims = vec2(float(inputRC.y),float(inputRC.z));\n\n result[${n}] =\n getChannel(getA(inputRC.x, inputRC.y, inputRC.z), inputRCInnerDims);\n ${n>0?\"}\":\"\"}\n `}this.userCode=`\n ${KZ(e,this.enableShapeUniforms)}\n ${this.enableShapeUniforms?Pc():Fc(t)}\n\n void main() {\n ivec3 rc = getOutputCoords();\n\n vec4 result = vec4(0.);\n\n ivec3 thisRC;\n int rows = ${this.enableShapeUniforms?\"outShape[1]\":t[1]};\n int cols = ${this.enableShapeUniforms?\"outShape[2]\":t[2]};\n\n ${o}\n\n setOutput(result);\n }\n `}};function KZ(r,t){return`\n ivec3 inputCoordsFromReshapedOutCoords(int index) {\n ${t?SR([\"r\",\"c\",\"d\"],\"inputShape\"):Ws([\"r\",\"c\",\"d\"],r)}\n return ivec3(r, c, d);\n }\n `}var dh=class{constructor(t){this.gpgpu=t,this.numUsedTextures=0,this.numFreeTextures=0,this._numBytesAllocated=0,this._numBytesFree=0,this.freeTextures={},this.usedTextures={},this.logEnabled=!1}acquireTexture(t,e,o){let n=vD(e,o),s=kD(t,n,o);s in this.freeTextures||(this.freeTextures[s]=[]),s in this.usedTextures||(this.usedTextures[s]=[]);let a=ID(t,n,this.gpgpu.gl,this.gpgpu.textureConfig,o);if(this.freeTextures[s].length>0){this.numFreeTextures--,this.numUsedTextures++,this._numBytesFree-=a,this.log();let p=this.freeTextures[s].pop();return this.usedTextures[s].push(p),p}let i;return n===rr.PACKED_2X2_FLOAT32?i=this.gpgpu.createPackedMatrixTexture(t[0],t[1]):n===rr.PACKED_2X2_FLOAT16?i=this.gpgpu.createFloat16PackedMatrixTexture(t[0],t[1]):n===rr.UNPACKED_FLOAT32?i=this.gpgpu.createFloat32MatrixTexture(t[0],t[1]):n===rr.UNPACKED_FLOAT16?i=this.gpgpu.createFloat16MatrixTexture(t[0],t[1]):n===rr.PACKED_4X1_UNSIGNED_BYTE&&(i=this.gpgpu.createUnsignedBytesMatrixTexture(t[0],t[1])),this.usedTextures[s].push(i),this.numUsedTextures++,this._numBytesAllocated+=a,this.log(),i}releaseTexture(t,e,o,n){if(this.freeTextures==null)return;let s=vD(o,n),a=kD(e,s,n);a in this.freeTextures||(this.freeTextures[a]=[]);let i=ID(e,s,this.gpgpu.gl,this.gpgpu.textureConfig,n),p=A().getNumber(\"WEBGL_DELETE_TEXTURE_THRESHOLD\");p!==-1&&this._numBytesAllocated>p?(this.gpgpu.deleteMatrixTexture(t.texture),this._numBytesAllocated-=i):(this.freeTextures[a].push(t),this.numFreeTextures++,this._numBytesFree+=i),this.numUsedTextures--;let u=this.usedTextures[a],c=u&&u.indexOf(t);if(c==null||c<0)throw new Error(\"Cannot release a texture that was never provided by this texture manager\");u[c]=u[u.length-1],u.pop(),this.log()}log(){if(!this.logEnabled)return;let t=this.numFreeTextures+this.numUsedTextures;console.log(\"Free/Used\",`${this.numFreeTextures} / ${this.numUsedTextures}`,`(${t})`);let e=this._numBytesFree/this._numBytesAllocated;console.log(`Bytes allocated: ${this._numBytesAllocated}`),console.log(`Bytes unused: ${this._numBytesFree} (${Math.round(100*e)}%)`)}get numBytesAllocated(){return this._numBytesAllocated}get numBytesFree(){return this._numBytesFree}getNumUsedTextures(){return this.numUsedTextures}getNumFreeTextures(){return this.numFreeTextures}dispose(){if(this.freeTextures!=null){for(let t in this.freeTextures)this.freeTextures[t].forEach(e=>{this.gpgpu.deleteMatrixTexture(e.texture)});for(let t in this.usedTextures)this.usedTextures[t].forEach(e=>{this.gpgpu.deleteMatrixTexture(e.texture)});this.freeTextures=null,this.usedTextures=null,this.numUsedTextures=0,this.numFreeTextures=0,this._numBytesAllocated=0,this._numBytesFree=0}}};function qZ(r,t){let e=r;if(t===e.R32F)return 4;if(t===e.R16F)return 2;if(t===e.RGBA32F)return 16;if(t===r.RGBA)return 16;if(t===e.RGBA16F)return 8;if(t===e.RGBA8)return 4;throw new Error(`Unknown internal format ${t}`)}function ID(r,t,e,o,n){let s=jZ(t,o),a;if(n){let[p,u]=La(r[0],r[1]);a=p*u}else{let[p,u]=Sp(r[0],r[1]);a=p*u}let i=qZ(e,s);return a*i}function jZ(r,t){switch(r){case rr.PACKED_2X2_FLOAT32:return ih(t);case rr.PACKED_2X2_FLOAT16:return uh(t);case rr.UNPACKED_FLOAT32:return nh(t);case rr.UNPACKED_FLOAT16:return sh(t);case rr.PACKED_4X1_UNSIGNED_BYTE:return ah(t);default:throw new Error(`Unknown physical texture type ${r}`)}}function XZ(r){return A().getBool(\"WEBGL_RENDER_FLOAT32_ENABLED\")?r?rr.PACKED_2X2_FLOAT32:rr.UNPACKED_FLOAT32:r?rr.PACKED_2X2_FLOAT16:rr.UNPACKED_FLOAT16}function vD(r,t){if(r===dr.UPLOAD)return rr.PACKED_2X2_FLOAT32;if(r===dr.RENDER||r==null)return XZ(t);if(r===dr.DOWNLOAD||r===dr.PIXELS)return rr.PACKED_4X1_UNSIGNED_BYTE;throw new Error(`Unknown logical texture type ${r}`)}function kD(r,t,e){return`${r[0]}_${r[1]}_${t}_${e}`}var or=class{constructor(t,e){this.variableNames=[\"A\"],this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n float unaryOperation(float x) {\n ${e}\n }\n\n void main() {\n float x = getAAtOutCoords();\n float y = unaryOperation(x);\n\n setOutput(y);\n }\n `}},Ut=\"if (isnan(x)) return x;\",ND=\"return x;\",mv=\"return abs(x);\";var TD=\"return (x >= 0.0) ? x : (exp(x) - 1.0);\",_D=Ut+`\n return (x < 0.0) ? 0.0 : x;\n`,$D=Ut+`\n return (x < 0.0) ? 0.0 : min(6.0, x);\n`,Ba=\"return x;\",ED=\"return 1.0 / (1.0 + exp(-1.0 * x));\";var DD=\"return x;\",AD=`\n vec4 result;\n\n result.r = (x.r >= 0.0) ? x.r : (exp(x.r) - 1.0);\n result.g = (x.g >= 0.0) ? x.g : (exp(x.g) - 1.0);\n result.b = (x.b >= 0.0) ? x.b : (exp(x.b) - 1.0);\n result.a = (x.a >= 0.0) ? x.a : (exp(x.a) - 1.0);\n\n return result;\n`,FD=`\n vec4 result = x * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,PD=`\n vec4 result = min(x, vec4(6.)) * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,OD=\"return 1.0 / (1.0 + exp(-1.0 * x));\",Fr=class{constructor(t,e){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n vec4 unaryOperation(vec4 x) {\n ${e}\n }\n\n void main() {\n vec4 x = getAAtOutCoords();\n vec4 y = unaryOperation(x);\n\n setOutput(y);\n }\n `}};var fh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!1,this.outputShape=t,this.enableShapeUniforms=pt(this.outputShape.length);let e=t.length,o=Dt(\"rc\",e),n=Re(e),s=SD(e,o),a=o.slice(-2),i=e<=1?\"rc\":`vec2(${a.join(\",\")})`;this.userCode=`\n void main() {\n ${n} rc = getOutputCoords();\n vec4 packedInput = getA(${s});\n\n setOutput(getChannel(packedInput, ${i}));\n }\n `}};var QZ=Wt.whereImpl,ZZ=1e-7,JZ=1e-4,hh={};function e9(r){return r in hh||(hh[r]={}),hh[r]}var t9=A().getNumber(\"CPU_HANDOFF_SIZE_THRESHOLD\"),r9=600;function o9(){return A().global.screen==null?1024:A().global.screen.height*A().global.screen.width*window.devicePixelRatio*r9/1024/1024}var wu=class extends ao{nextDataId(){return wu.nextDataId++}constructor(t){if(super(),this.pendingRead=new WeakMap,this.pendingDisposal=new WeakSet,this.dataRefCount=new WeakMap,this.numBytesInGPU=0,this.uploadWaitMs=0,this.downloadWaitMs=0,this.lastGlFlushTime=0,this.warnedAboutMemory=!1,this.pendingDeletes=0,this.disposed=!1,!A().getBool(\"HAS_WEBGL\"))throw new Error(\"WebGL is not supported on this device\");let e;if(t!=null){if(t instanceof kp)e=t;else{let o=Kr(A().getNumber(\"WEBGL_VERSION\"),t);e=new kp(o)}this.binaryCache={},this.gpgpuCreatedLocally=!1}else{let o=Kr(A().getNumber(\"WEBGL_VERSION\"));e=new kp(o),this.binaryCache=e9(A().getNumber(\"WEBGL_VERSION\")),this.gpgpuCreatedLocally=!0}this.gpgpu=e,this.canvas=this.gpgpu.gl.canvas,this.textureManager=new dh(this.gpgpu),this.numMBBeforeWarning=o9(),this.texData=new zo(this,pr())}numDataIds(){return this.texData.numDataIds()-this.pendingDeletes}writeTexture(t,e,o,n,s,a){let i=this.makeTensorInfo(e,o),p=this.texData.get(i.dataId);p.isPacked=!1,p.texture={texture:t,texShape:[n,s]},p.texShape=[n,s];let u=Dc(e),c=new Zl(u,!1,a),l=this.runWebGLProgram(c,[i],o,[[n,s]]);return l.shape=e,p.texture=null,this.disposeIntermediateTensorInfo(i),l.dataId}write(t,e,o){if((A().getBool(\"WEBGL_CHECK_NUMERICAL_PROBLEMS\")||A().getBool(\"DEBUG\"))&&this.checkNumericalProblems(t),o===\"complex64\"&&t!=null)throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");let n={id:this.nextDataId()};return this.texData.set(n,{shape:e,dtype:o,values:t,usage:dr.UPLOAD,refCount:1}),n}refCount(t){return this.texData.has(t)?this.texData.get(t).refCount:0}incRef(t){let e=this.texData.get(t);e.refCount++}decRef(t){if(this.texData.has(t)){let e=this.texData.get(t);e.refCount--}}move(t,e,o,n,s){if(A().getBool(\"DEBUG\")&&this.checkNumericalProblems(e),n===\"complex64\")throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");this.texData.set(t,{shape:o,dtype:n,values:e,usage:dr.UPLOAD,refCount:s})}disposeIntermediateTensorInfo(t){this.disposeData(t.dataId)}readSync(t){let e=this.texData.get(t),{values:o,dtype:n,complexTensorInfos:s,slice:a,shape:i,isPacked:p}=e;if(a!=null){let m;p?m=new Fr(i,Ba):m=new or(i,Ba);let d=this.runWebGLProgram(m,[{dataId:t,shape:i,dtype:n}],n),f=this.readSync(d.dataId);return this.disposeIntermediateTensorInfo(d),f}if(o!=null)return this.convertAndCacheOnCPU(t);if(n===\"string\")return o;let u=this.activeTimers!=null,c;u&&(c=y.now());let l;if(n===\"complex64\"){let m=this.readSync(s.real.dataId),d=this.readSync(s.imag.dataId);l=w.mergeRealAndImagArrays(m,d)}else l=this.getValuesFromTexture(t);return u&&(this.downloadWaitMs+=y.now()-c),this.convertAndCacheOnCPU(t,l)}async read(t){if(this.pendingRead.has(t)){let f=this.pendingRead.get(t);return new Promise(h=>f.push(h))}let e=this.texData.get(t),{values:o,shape:n,slice:s,dtype:a,complexTensorInfos:i,isPacked:p}=e;if(s!=null){let f;p?f=new Fr(n,Ba):f=new or(n,Ba);let h=this.runWebGLProgram(f,[{dataId:t,shape:n,dtype:a}],a),g=this.read(h.dataId);return this.disposeIntermediateTensorInfo(h),g}if(o!=null)return this.convertAndCacheOnCPU(t);if(A().getBool(\"DEBUG\")&&!A().getBool(\"WEBGL_DOWNLOAD_FLOAT_ENABLED\")&&A().getNumber(\"WEBGL_VERSION\")===2)throw new Error(\"tensor.data() with WEBGL_DOWNLOAD_FLOAT_ENABLED=false and WEBGL_VERSION=2 not yet supported.\");let u=null,c;if(a!==\"complex64\"&&A().get(\"WEBGL_BUFFER_SUPPORTED\")){c=this.decode(t);let f=this.texData.get(c.dataId);u=this.gpgpu.createBufferFromTexture(f.texture.texture,...jl(n))}this.pendingRead.set(t,[]),a!==\"complex64\"&&await this.gpgpu.createAndWaitForFence();let l;if(a===\"complex64\"){let f=await Promise.all([this.read(i.real.dataId),this.read(i.imag.dataId)]),h=f[0],g=f[1];l=w.mergeRealAndImagArrays(h,g)}else if(u==null)l=this.getValuesFromTexture(t);else{let f=y.sizeFromShape(n);l=this.gpgpu.downloadFloat32MatrixFromBuffer(u,f)}if(c!=null&&this.disposeIntermediateTensorInfo(c),u!=null){let f=this.gpgpu.gl;ce(f,()=>f.deleteBuffer(u))}let m=this.convertAndCacheOnCPU(t,l),d=this.pendingRead.get(t);return this.pendingRead.delete(t),d.forEach(f=>f(m)),this.pendingDisposal.has(t)&&(this.pendingDisposal.delete(t),this.disposeData(t)&&pr().removeDataId(t,this),this.pendingDeletes--),m}readToGPU(t,e={}){let o=this.texData.get(t),{values:n,shape:s,slice:a,dtype:i,isPacked:p,texture:u}=o;if(i===\"complex64\")throw new Error(\"Does not support reading texture for complex64 dtype.\");if(a!=null){let d;p?d=new Fr(s,Ba):d=new or(s,Ba);let f=this.runWebGLProgram(d,[{dataId:t,shape:s,dtype:i}],i),h=this.readToGPU(f,e);return this.disposeIntermediateTensorInfo(f),h}if(u==null)throw n!=null?new Error(\"Data is not on GPU but on CPU.\"):new Error(\"There is no data on GPU or CPU.\");let c=this.decode(t,e.customTexShape),l=pr().makeTensorFromTensorInfo(c),m=this.texData.get(c.dataId);return Object.assign({tensorRef:l},m.texture)}bufferSync(t){let e=this.readSync(t.dataId);if(t.dtype===\"string\")try{let o=e.map(n=>y.decodeString(n));return me(t.shape,t.dtype,o)}catch(o){throw new Error(\"Failed to decode encoded string bytes into utf-8\")}return me(t.shape,t.dtype,e)}checkNumericalProblems(t){if(t!=null)for(let e=0;e0}time(t){let e=this.activeTimers,o=[],n=!1;this.programTimersStack==null?(this.programTimersStack=o,n=!0):this.activeTimers.push(o),this.activeTimers=o,t();let s=y.flatten(this.activeTimers.map(p=>p.query)).filter(p=>p!=null),a=y.flatten(this.activeTimers.map(p=>p.name)).filter(p=>p!=null);this.activeTimers=e,n&&(this.programTimersStack=null);let i={uploadWaitMs:this.uploadWaitMs,downloadWaitMs:this.downloadWaitMs,kernelMs:null,wallMs:null};return(async()=>{if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0){let p=await Promise.all(s);i.kernelMs=y.sum(p),i.getExtraProfileInfo=()=>p.map((u,c)=>({name:a[c],ms:u})).map(u=>`${u.name}: ${u.ms}`).join(\", \")}else i.kernelMs={error:\"WebGL query timers are not supported in this environment.\"};return this.uploadWaitMs=0,this.downloadWaitMs=0,i})()}memory(){return{unreliable:!1,numBytesInGPU:this.numBytesInGPU,numBytesInGPUAllocated:this.textureManager.numBytesAllocated,numBytesInGPUFree:this.textureManager.numBytesFree}}startTimer(){return A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0?this.gpgpu.beginQuery():{startMs:y.now(),endMs:null}}endTimer(t){return A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0?(this.gpgpu.endQuery(),t):(t.endMs=y.now(),t)}async getQueryTime(t){if(A().getNumber(\"WEBGL_DISJOINT_QUERY_TIMER_EXTENSION_RELIABLE\")>0)return this.gpgpu.waitForQueryAndGetTime(t);let e=t;return e.endMs-e.startMs}disposeData(t,e=!1){if(this.pendingDisposal.has(t))return!1;if(!this.texData.has(t))return!0;if(e?this.texData.get(t).refCount=0:this.texData.get(t).refCount--,!e&&this.texData.get(t).refCount>0)return!1;if(this.pendingRead.has(t))return this.pendingDisposal.add(t),this.pendingDeletes++,!1;this.releaseGPUData(t);let{complexTensorInfos:o}=this.texData.get(t);return o!=null&&(this.disposeData(o.real.dataId,e),this.disposeData(o.imag.dataId,e)),this.texData.delete(t),!0}releaseGPUData(t){let{texture:e,dtype:o,texShape:n,usage:s,isPacked:a,slice:i}=this.texData.get(t),p=i&&i.origDataId||t,u=this.dataRefCount.get(p);u>1?this.dataRefCount.set(p,u-1):(this.dataRefCount.delete(p),e!=null&&(this.numBytesInGPU-=this.computeBytes(n,o),this.textureManager.releaseTexture(e,n,s,a)));let c=this.texData.get(t);c.texture=null,c.texShape=null,c.isPacked=!1,c.slice=null}getTexture(t){return this.uploadToGPU(t),this.texData.get(t).texture.texture}getDataInfo(t){return this.texData.get(t)}shouldExecuteOnCPU(t,e=t9){return A().getBool(\"WEBGL_CPU_FORWARD\")&&t.every(o=>this.texData.get(o.dataId).texture==null&&y.sizeFromShape(o.shape)0&&y.isString(o[0])){let s=o.map(a=>y.encodeString(a));n=this.write(s,t,e)}else n=this.write(o,t,e);return this.texData.get(n).usage=null,{dataId:n,shape:t,dtype:e}}makeOutput(t,e,o){return pr().makeTensorFromTensorInfo(this.makeTensorInfo(t,e,o),this)}unpackTensor(t){let e=new fh(t.shape);return this.runWebGLProgram(e,[t],t.dtype)}packTensor(t){let e=new mh(t.shape),o=!0;return this.runWebGLProgram(e,[t],t.dtype,null,o)}packedReshape(t,e){let o=[yi(t.shape),...bi(t.shape)],n={dtype:t.dtype,shape:o,dataId:t.dataId},s=[yi(e),...bi(e)],a=new Vc(s,o),i=!0,p=[o],u=this.runWebGLProgram(a,[n],t.dtype,p,i);return{dataId:u.dataId,shape:e,dtype:u.dtype}}decode(t,e){let o=this.texData.get(t),{isPacked:n,shape:s,dtype:a}=o;if(e!=null){let m=y.sizeFromShape(s),d=e[0]*e[1]*4;y.assert(m<=d,()=>\"customTexShape is too small. Row * Column * 4 should be equal or larger than the size of the tensor data.\")}let i=Dc(s),p;n?p=new eh(i):p=new Jf(i);let u=!0,c=[e!=null?e:jl(i)],l=this.runWebGLProgram(p,[{shape:i,dtype:a,dataId:t}],a,c,u,e);return{dtype:a,shape:s,dataId:l.dataId}}runWebGLProgram(t,e,o,n,s=!1,a){let i=this.makeTensorInfo(t.outputShape,o),p=this.texData.get(i.dataId);if(t.packedOutput&&(p.isPacked=!0),t.outPackingScheme===bu.DENSE){let x=a!=null?a:jl(t.outputShape);p.texShape=x.map(b=>b*2)}if(t.outTexUsage!=null&&(p.usage=t.outTexUsage),y.sizeFromShape(i.shape)===0)return p.values=y.getTypedArrayFromDType(i.dtype,0),i;let u=[],c=e.map(x=>{if(x.dtype===\"complex64\")throw new Error(\"GPGPUProgram does not support complex64 input. For complex64 dtypes, please separate the program into real and imaginary parts.\");let b=this.texData.get(x.dataId);if(b.texture==null){if(!t.packedInputs&&y.sizeFromShape(x.shape)<=A().getNumber(\"WEBGL_SIZE_UPLOAD_UNIFORM\"))return{shape:x.shape,texData:null,isUniform:!0,uniformValues:b.values};t.packedInputs&&(b.isPacked=!0,b.shape=x.shape)}if(this.uploadToGPU(x.dataId),!!b.isPacked!=!!t.packedInputs)x=b.isPacked?this.unpackTensor(x):this.packTensor(x),u.push(x),b=this.texData.get(x.dataId);else if(b.isPacked&&!Cu(b.shape,x.shape)){let C=x,S=x.shape;x.shape=b.shape,x=this.packedReshape(x,S),u.push(x),b=this.texData.get(x.dataId),C.shape=S}return{shape:x.shape,texData:b,isUniform:!1}});this.uploadToGPU(i.dataId);let l={shape:i.shape,texData:p,isUniform:!1},m=ER(t,c,l),d=this.getAndSaveBinary(m,()=>_R(this.gpgpu,t,c,l)),f=this.activeTimers!=null,h;f&&(h=this.startTimer()),A().get(\"ENGINE_COMPILE_ONLY\")||$R(this.gpgpu,d,c,l,n),u.forEach(x=>this.disposeIntermediateTensorInfo(x)),f&&(h=this.endTimer(h),this.activeTimers.push({name:t.constructor.name,query:this.getQueryTime(h)}));let g=A().getNumber(\"WEBGL_FLUSH_THRESHOLD\");if(g>0){let x=y.now();x-this.lastGlFlushTime>g&&(this.gpgpu.gl.flush(),this.lastGlFlushTime=x)}if(!A().getBool(\"WEBGL_LAZILY_UNPACK\")&&p.isPacked&&s===!1){let x=this.unpackTensor(i);return this.disposeIntermediateTensorInfo(i),x}return i}compileAndRun(t,e,o,n,s=!1){return o=o||e[0].dtype,this.runWebGLProgram(t,e,o,n,s)}getAndSaveBinary(t,e){return t in this.binaryCache||(this.binaryCache[t]=e()),this.binaryCache[t]}getTextureManager(){return this.textureManager}dispose(){this.disposed||(A().getBool(\"IS_TEST\")||Object.keys(this.binaryCache).forEach(e=>{this.gpgpu.deleteProgram(this.binaryCache[e].webGLProgram),delete this.binaryCache[e]}),this.textureManager.dispose(),this.canvas!=null&&typeof HTMLCanvasElement!=\"undefined\"&&this.canvas instanceof HTMLCanvasElement?this.canvas.remove():this.canvas=null,this.gpgpuCreatedLocally&&(this.gpgpu.program=null,this.gpgpu.dispose()),this.disposed=!0)}floatPrecision(){return this.floatPrecisionValue==null&&(this.floatPrecisionValue=De(()=>{if(!A().get(\"WEBGL_RENDER_FLOAT32_ENABLED\")){let t=A().getBool(\"DEBUG\");A().set(\"DEBUG\",!1);let e=this.abs(ke(1e-8)).dataSync()[0];if(A().set(\"DEBUG\",t),e>0)return 32}return 16})),this.floatPrecisionValue}epsilon(){return this.floatPrecision()===32?ZZ:JZ}uploadToGPU(t){let e=this.texData.get(t),{shape:o,dtype:n,values:s,texture:a,usage:i,isPacked:p}=e;if(a!=null)return;let u=this.activeTimers!=null,c;u&&(c=y.now());let l=e.texShape;if(l==null&&(l=zI(o,p),e.texShape=l),s!=null){let m=Dc(o),d,f=l[1],h=l[0],g=s instanceof Uint8Array||s instanceof Uint8ClampedArray;(p||!g)&&([f,h]=La(l[0],l[1])),p?d=new oh(m,g):d=new Zl(m,g);let x=g?[h,f]:l,b=this.makeTensorInfo(x,n),C=this.texData.get(b.dataId);g?C.usage=dr.PIXELS:C.usage=dr.UPLOAD,C.texShape=x,this.gpgpu.uploadDenseMatrixToTexture(this.getTexture(b.dataId),f,h,s);let S=[[h,f]],k=!0,_=this.runWebGLProgram(d,[b],n,S,k),E=this.texData.get(_.dataId);e.texShape=E.texShape,e.isPacked=E.isPacked,e.usage=E.usage,A().get(\"ENGINE_COMPILE_ONLY\")?this.disposeData(_.dataId):(e.texture=E.texture,e.values=null,this.texData.delete(_.dataId)),this.disposeIntermediateTensorInfo(b),u&&(this.uploadWaitMs+=y.now()-c)}else{let m=this.acquireTexture(l,i,n,p);e.texture=m}}convertAndCacheOnCPU(t,e){let o=this.texData.get(t),{dtype:n}=o;return e!=null&&(o.values=n9(e,n)),o.values}acquireTexture(t,e,o,n){if(this.numBytesInGPU+=this.computeBytes(t,o),!this.warnedAboutMemory&&this.numBytesInGPU>this.numMBBeforeWarning*1024*1024){let s=(this.numBytesInGPU/1024/1024).toFixed(2);this.warnedAboutMemory=!0,console.warn(`High memory usage in GPU: ${s} MB, most likely due to a memory leak`)}return this.textureManager.acquireTexture(t,e,n)}computeBytes(t,e){return t[0]*t[1]*y.bytesPerElement(e)}checkCompileCompletion(){for(let[,t]of Object.entries(this.binaryCache))this.checkCompletion_(t)}async checkCompileCompletionAsync(){let t=[];if(this.gpgpu.parallelCompilationExtension){for(let[,e]of Object.entries(this.binaryCache))t.push(this.checkCompletionAsync_(e));return Promise.all(t)}else{for(let[,e]of Object.entries(this.binaryCache)){let o=new Promise(n=>{try{this.checkCompletion_(e),n(!0)}catch(s){throw s}});t.push(o)}return Promise.all(t)}}async checkCompletionAsync_(t){return this.gpgpu.gl.getProgramParameter(t.webGLProgram,this.gpgpu.parallelCompilationExtension.COMPLETION_STATUS_KHR)?this.checkCompletion_(t):(await pS(),this.checkCompletionAsync_(t))}checkCompletion_(t){if(this.gpgpu.gl.getProgramParameter(t.webGLProgram,this.gpgpu.gl.LINK_STATUS)===!1)throw console.log(this.gpgpu.gl.getProgramInfoLog(t.webGLProgram)),this.gpgpu.gl.getShaderParameter(t.fragmentShader,this.gpgpu.gl.COMPILE_STATUS)===!1?(qf(t.source,this.gpgpu.gl.getShaderInfoLog(t.fragmentShader)),new Error(\"Failed to compile fragment shader.\")):new Error(\"Failed to link vertex and fragment shaders.\");return!0}getUniformLocations(){for(let t of Object.values(this.binaryCache)){this.gpgpu.buildVao(t.webGLProgram);let{variablesLocations:e,customUniformLocations:o,infLoc:n,nanLoc:s,outShapeLocation:a,outShapeStridesLocation:i,outTexShapeLocation:p}=qI(this.gpgpu,t.program,t.webGLProgram);t.variablesLocations=e,t.customUniformLocations=o,t.infLoc=n,t.nanLoc=s,t.outShapeLocation=a,t.outShapeStridesLocation=i,t.outTexShapeLocation=p}}createTensorFromGPUData(t,e,o){t.channels=t.channels||\"RGBA\";let{texture:n,height:s,width:a,channels:i}=t,p=pr().backend;if(!p.gpgpu.gl.isTexture(n))throw new Error(\"The texture is invalid. Also, please make sure the texture and the TFJS WebGL backend are using the same canvas. If you want to use your own custom canvas, you have to create and use the custom TFJS WebGL backend created from the canvas through 'new tf.MathBackendWebGL(customCanvas)'.\");let u=p.writeTexture(n,e,o,s,a,i);return pr().makeTensorFromDataId(u,e,o,p)}};wu.nextDataId=0;function n9(r,t){if(t===\"float32\"||t===\"complex64\")return r;if(t===\"int32\"||t===\"bool\"){let e=t===\"int32\"?new Int32Array(r.length):new Uint8Array(r.length);for(let o=0;onew wu,2);var Cat={forceHalfFloat:MD};var Wc=`\n if (isnan(a)) return a;\n if (isnan(b)) return b;\n`;var Pr=class{constructor(t,e,o){this.variableNames=[\"A\",\"B\"],this.outputShape=w.assertAndGetBroadcastShape(e,o),this.enableShapeUniforms=pt(this.outputShape.length),this.userCode=`\n float binaryOperation(float a, float b) {\n ${t}\n }\n\n void main() {\n float a = getAAtOutCoords();\n float b = getBAtOutCoords();\n setOutput(binaryOperation(a, b));\n }\n `}};var Xr=`\n result.r = isNaN.r ? NAN : result.r;\n result.g = isNaN.g ? NAN : result.g;\n result.b = isNaN.b ? NAN : result.b;\n result.a = isNaN.a ? NAN : result.a;\n`;var jr=class{constructor(t,e,o,n=!1){this.variableNames=[\"A\",\"B\"],this.supportsBroadcasting=!0,this.packedInputs=!0,this.packedOutput=!0,this.outputShape=w.assertAndGetBroadcastShape(e,o);let s=this.outputShape.length;this.enableShapeUniforms=pt(s);let a=\"\";if(n)if(s===0||y.sizeFromShape(this.outputShape)===1)a=`\n result.y = 0.;\n result.z = 0.;\n result.w = 0.;\n `;else if(a=`\n ${Re(s)} coords = getOutputCoords();\n `,s===1)this.enableShapeUniforms?a+=`\n result.y = (coords + 1) >= outShape ? 0. : result.y;\n result.z = 0.;\n result.w = 0.;\n `:a+=`\n result.y = (coords + 1) >= ${this.outputShape[0]} ? 0. : result.y;\n result.z = 0.;\n result.w = 0.;\n `;else{let p=Dt(\"coords\",s);this.enableShapeUniforms?a+=`\n bool nextRowOutOfBounds =\n (${p[s-2]} + 1) >= outShape[${s} - 2];\n bool nextColOutOfBounds =\n (${p[s-1]} + 1) >= outShape[${s} - 1];\n result.y = nextColOutOfBounds ? 0. : result.y;\n result.z = nextRowOutOfBounds ? 0. : result.z;\n result.w = nextColOutOfBounds || nextRowOutOfBounds ? 0. : result.w;\n `:a+=`\n bool nextRowOutOfBounds =\n (${p[s-2]} + 1) >= ${this.outputShape[s-2]};\n bool nextColOutOfBounds =\n (${p[s-1]} + 1) >= ${this.outputShape[s-1]};\n result.y = nextColOutOfBounds ? 0. : result.y;\n result.z = nextRowOutOfBounds ? 0. : result.z;\n result.w = nextColOutOfBounds || nextRowOutOfBounds ? 0. : result.w;\n `}this.userCode=`\n vec4 binaryOperation(vec4 a, vec4 b) {\n ${t}\n }\n\n void main() {\n vec4 a = getAAtOutCoords();\n vec4 b = getBAtOutCoords();\n\n vec4 result = binaryOperation(a, b);\n ${a}\n\n setOutput(result);\n }\n `}};function At(r){let{inputs:t,backend:e}=r,{x:o}=t;return e.incRef(o.dataId),{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}var LD={kernelName:wo,backendName:\"webgl\",kernelFunc:At};function Or(r){let{inputs:t,backend:e}=r,{real:o,imag:n}=t,s=e.makeTensorInfo(o.shape,\"complex64\"),a=e.texData.get(s.dataId),i=At({inputs:{x:o},backend:e}),p=At({inputs:{x:n},backend:e});return a.complexTensorInfos={real:i,imag:p},s}var BD={kernelName:Fi,backendName:\"webgl\",kernelFunc:Or};var dv=\"return (a < 0.) ? b * a : a;\",fv=`\n vec4 aLessThanZero = vec4(lessThan(a, vec4(0.)));\n return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`;function a9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{alpha:s}=o,a=e.makeTensorInfo([],\"float32\",y.createScalarValue(s,\"float32\")),i=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")?new jr(fv,n.shape,a.shape):new Pr(dv,n.shape,a.shape),p=e.runWebGLProgram(i,[n,a],\"float32\");return e.disposeIntermediateTensorInfo(a),p}var zD={kernelName:Rn,backendName:\"webgl\",kernelFunc:a9};var hv=\"return (a < 0.) ? b * a : a;\",gv=`\n vec4 aLessThanZero = vec4(lessThan(a, vec4(0.)));\n return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`;function i9(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t,s=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")?new jr(gv,o.shape,n.shape):new Pr(hv,o.shape,n.shape);return e.runWebGLProgram(s,[o,n],\"float32\")}var VD={kernelName:os,backendName:\"webgl\",kernelFunc:i9};var Po=\"if (isnan(x)) return x;\";function xe({opSnippet:r,packedOpSnippet:t,cpuKernelImpl:e,dtype:o}){return({inputs:n,backend:s})=>{let{x:a}=n,i=s,p=o||a.dtype;if(i.shouldExecuteOnCPU([a])&&e!=null){let l=i.texData.get(a.dataId),m=e(l.values,p);return i.makeTensorInfo(a.shape,p,m)}let u=A().getBool(\"WEBGL_PACK_UNARY_OPERATIONS\")&&t!=null,c;return u?c=new Fr(a.shape,t):c=new or(a.shape,r),i.runWebGLProgram(c,[a],p)}}function nt({opSnippet:r,packedOpSnippet:t,checkOutOfBounds:e=!1,supportsComplex:o=!1,cpuKernelImpl:n,dtype:s}){return({inputs:a,backend:i})=>{let{a:p,b:u}=a,c=i;if(o&&p.dtype===\"complex64\"){let f=c.texData.get(p.dataId),h=c.texData.get(u.dataId),[g,x]=[[f.complexTensorInfos.real,h.complexTensorInfos.real],[f.complexTensorInfos.imag,h.complexTensorInfos.imag]].map(C=>{let[S,k]=C,_={dataId:S.dataId,dtype:S.dtype,shape:p.shape},E={dataId:k.dataId,dtype:k.dtype,shape:u.shape},R=new Pr(r,p.shape,u.shape);return c.runWebGLProgram(R,[_,E],dt(S.dtype,k.dtype))}),b=Or({inputs:{real:g,imag:x},backend:c});return c.disposeIntermediateTensorInfo(g),c.disposeIntermediateTensorInfo(x),b}let l=s||dt(p.dtype,u.dtype);if((p.dtype===\"string\"||u.dtype===\"string\"||c.shouldExecuteOnCPU([p,u]))&&n!=null){let f=c.texData.get(p.dataId).values,h=c.texData.get(u.dataId).values,g=p.dtype===\"string\"?w.fromUint8ToStringArray(f):f,x=p.dtype===\"string\"?w.fromUint8ToStringArray(h):h,[b,C]=n(p.shape,u.shape,g,x,l),S=c.makeTensorInfo(C,l),k=c.texData.get(S.dataId);return k.values=b,S}let m=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")&&t!=null,d;return m?d=new jr(t,p.shape,u.shape,e):d=new Pr(r,p.shape,u.shape),c.runWebGLProgram(d,[p,u],l)}}function Ci(r,t=!1){if(r===\"linear\")return t?DD:ND;if(r===\"relu\")return t?FD:_D;if(r===\"elu\")return t?AD:TD;if(r===\"relu6\")return t?PD:$D;if(r===\"prelu\")return t?gv:hv;if(r===\"leakyrelu\")return t?fv:dv;if(r===\"sigmoid\")return t?OD:ED;throw new Error(`Activation ${r} has not been implemented for the WebGL backend.`)}var Uc=class{constructor(t,e,o,n=!1,s=!1,a=!1,i=null,p=!1,u=!1){this.variableNames=[\"matrixA\",\"matrixB\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=o,this.enableShapeUniforms=pt(this.outputShape.length);let c=n?t[1]:t[2],l=Math.ceil(c/2),m=n?\"i * 2, rc.y\":\"rc.y, i * 2\",d=s?\"rc.z, i * 2\":\"i * 2, rc.z\",f=n?[\"a.xxyy\",\"a.zzww\"]:[\"a.xxzz\",\"a.yyww\"],h=s?[\"b.xzxz\",\"b.ywyw\"]:[\"b.xyxy\",\"b.zwzw\"],g=\"\",x=\"\";i&&(p?g=`vec4 activation(vec4 a) {\n vec4 b = getPreluActivationWeightsAtOutCoords();\n ${i}\n }`:u?g=`vec4 activation(vec4 a) {\n vec4 b = getLeakyreluAlphaAtOutCoords();\n ${i}\n }`:g=`vec4 activation(vec4 x) {\n ${i}\n }`,x=\"result = activation(result);\");let b=a?\"result += getBiasAtOutCoords();\":\"\";a&&this.variableNames.push(\"bias\"),p&&this.variableNames.push(\"preluActivationWeights\"),u&&this.variableNames.push(\"leakyreluAlpha\");let C=\"rc.x\",S=\"rc.x\";t[0]`The new shape (${p}) has ${u} elements and the old shape (${n.shape}) has ${i} elements. The new shape and old shape must have the same number of elements.`);let c=a.texData.get(n.dataId);return c.isPacked&&!Cu(n.shape,p)&&!(c.texture!==null&&Cu(c.shape,p))?GD(n,p,a):(a.incRef(n.dataId),{dataId:n.dataId,shape:p,dtype:n.dtype})}var HD={kernelName:da,backendName:\"webgl\",kernelFunc:te};var rm=class{constructor(t,e){this.variableNames=[\"x\"];let{windowSize:o,batchSize:n,inSize:s,outSize:a}=t;this.outputShape=[n,a];let i=Math.floor(o/4)*4,p=o%4,u=\"sumValue += dot(values, ones);\";if(e!=null){let l=1/e;u=`sumValue += dot(values * ${y.isInt(l)?l.toPrecision(2):l}, ones);`}let c=\"\";s%o>0&&(c=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return 0.0;\n }\n `),this.userCode=`\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float getValue(int batch, int inIdx) {\n ${c}\n return getX(batch, inIdx);\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = outIdx * ${o};\n\n float sumValue = 0.0;\n\n for (int i = 0; i < ${i}; i += 4) {\n int inIdx = inOffset + i;\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n getValue(batch, inIdx + 3)\n );\n\n ${u}\n }\n\n int inIdx = inOffset + ${i};\n if (${p===1}) {\n vec4 values = vec4(getValue(batch, inIdx), 0.0, 0.0, 0.0);\n\n ${u}\n } else if (${p===2}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1), 0.0, 0.0);\n\n ${u}\n } else if (${p===3}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2), 0.0);\n\n ${u}\n }\n setOutput(sumValue);\n }\n `}};var gh=class{constructor(t,e){this.variableNames=[\"x\"];let{windowSize:o,batchSize:n,inSize:s,outSize:a}=t;this.outputShape=[n,a];let i=\"0.0\",p=\"\";e===\"prod\"?i=\"1.0\":e===\"min\"?(i=\"1.0 / 1e-20\",p=\"min\"):e===\"max\"&&(i=\"-1.0 / 1e-20\",p=\"max\");let u=`${e}(${e}(${e}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;e===\"sum\"?u=\"sumValue\":e===\"prod\"?u=\"prodValue\":e===\"all\"?u=\"allValue\":e===\"any\"&&(u=\"anyValue\");let c=Math.floor(o/4)*4,l=o%4,m=`\n if (${e===\"sum\"}) {\n sumValue += dot(values, ones);\n } else if (${e===\"prod\"}) {\n vec2 tmp = vec2(values[0], values[1]) * vec2(values[2], values[3]);\n prodValue *= tmp[0] * tmp[1];\n } else {\n minMaxValue = ${p}(values, minMaxValue);\n if (${e===\"min\"} || ${e===\"max\"}) {\n minMaxValue = ${p}(values, minMaxValue);\n bvec4 isNaN = isnan(values);\n if (isNaN.r || isNaN.g || isNaN.b || isNaN.a) {\n minMaxValue = vec4(NAN);\n }\n }\n }\n `,d=\"vec4\";e===\"all\"?(i=\"1.0\",m=`\n bool reducedAllValue = all(values);\n float floatedReducedAllValue = float(reducedAllValue);\n allValue = float(allValue >= 1.0 && floatedReducedAllValue >= 1.0);\n `,d=\"bvec4\"):e===\"any\"&&(i=\"0.0\",m=`\n bool reducedAnyValue = any(values);\n float floatedReducedAnyValue = float(reducedAnyValue);\n anyValue = float(anyValue >= 1.0 || floatedReducedAnyValue >= 1.0);\n `,d=\"bvec4\");let f=\"\";s%o>0&&(f=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return initializationValue;\n }\n `),this.userCode=`\n const float initializationValue = ${i};\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float getValue(int batch, int inIdx) {\n ${f}\n return getX(batch, inIdx);\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = outIdx * ${o};\n\n vec4 minMaxValue = vec4(${i});\n float prodValue = 1.0;\n float sumValue = 0.0;\n float allValue = 1.0;\n float anyValue = 0.0;\n\n for (int i = 0; i < ${c}; i += 4) {\n int inIdx = inOffset + i;\n ${d} values = ${d}(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n getValue(batch, inIdx + 3)\n );\n\n ${m}\n }\n\n int inIdx = inOffset + ${c};\n if (${l===1}) {\n ${d} values = ${d}(\n getValue(batch, inIdx),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n ${m}\n } else if (${l===2}) {\n ${d} values = ${d}(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n initializationValue,\n initializationValue\n );\n\n ${m}\n } else if (${l===3}) {\n ${d} values = ${d}(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n initializationValue\n );\n\n ${m}\n }\n setOutput(${u});\n }\n `}};function p9(r){let t=[];for(;t.length===0||t[t.length-1].outSize!==1;){let e=t.length?t[t.length-1].outSize:r[1],o=w.computeOptimalWindowSize(e);t.push({inSize:e,windowSize:o,outSize:Math.ceil(e/o)})}return t}function Yr(r,t,e,o){let n=p9(r.shape),s=r;for(let a=0;a6)throw Error(`Transpose for rank ${t} is not yet supported`);let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\",\"resRC.u\",\"resRC.v\"],o=new Array(t);for(let n=0;n6)throw Error(`Packed transpose for rank ${this.rank} is not yet supported.`);let n=Re(this.rank),s=lv(\"rc\",this.rank),a=new Array(this.rank);for(let c=0;c`Error in matMul: inner shapes (${l}) and (${m}) of Tensors with shapes ${r.shape} and ${t.shape} and transposeA=${e} and transposeB=${o} must match.`);let k=e?[x,l,d]:[x,d,l],_=o?[b,f,m]:[b,m,f],E=te({inputs:{x:r},backend:n,attrs:{shape:k}}),R=te({inputs:{x:t},backend:n,attrs:{shape:_}}),D=[E,R],P=Math.max(x,b),O=e?E.shape[1]:E.shape[2],M=s!=null,L=a!=null,B=p===\"leakyrelu\",z=p!=null?Ci(p,!0):null,U=M||L||B||z!=null,j;if((d===1||f===1)&&O>yv&&U===!1){let Y=E,J=R;e&&(Y=Ct({inputs:{x:E},backend:n,attrs:{perm:[0,2,1]}}),D.push(Y)),o&&(J=Ct({inputs:{x:R},backend:n,attrs:{perm:[0,2,1]}}),D.push(J));let re=f!==1,ne=f===1,ee=Y;re&&(ee=te({inputs:{x:Y},backend:n,attrs:{shape:[P,O,1]}}),D.push(ee));let oe=f===1?2:1,ie=J;ne&&(ie=te({inputs:{x:J},backend:n,attrs:{shape:[P,1,O]}}),D.push(ie));let le=tm({inputs:{a:ee,b:ie},backend:n});j=Tp({inputs:{x:le},backend:n,attrs:{axis:oe,keepDims:!0}}),D.push(le)}else{let Y=dt(r.dtype,t.dtype),J=new Uc(k,_,[P,d,f],e,o,M,z,L,B),re=[E,R];if(s!=null&&re.push(s),L&&re.push(a),B){let ne=n.makeTensorInfo([],\"float32\",y.createScalarValue(i,\"float32\"));re.push(ne),D.push(ne)}j=n.runWebGLProgram(J,re,Y)}let q=te({inputs:{x:j},backend:n,attrs:{shape:S}});D.push(j);for(let Y of D)n.disposeIntermediateTensorInfo(Y);return q}function l9(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s,bias:a,preluActivationWeights:i}=t,{transposeA:p,transposeB:u,activation:c,leakyreluAlpha:l}=o;return _p({a:n,b:s,transposeA:p,transposeB:u,backend:e,bias:a,preluActivationWeights:i,leakyreluAlpha:l,activation:c})}var XD={kernelName:Io,backendName:\"webgl\",kernelFunc:l9};var YD=\"return abs(x);\";function m9(r){let{inputs:t,backend:e}=r,{x:o}=t;if(e.shouldExecuteOnCPU([o])&&o.dtype!==\"complex64\"){let s=e.texData.get(o.dataId),a=ch(s.values);return e.makeTensorInfo(o.shape,o.dtype,a)}let n;return A().getBool(\"WEBGL_PACK_UNARY_OPERATIONS\")?n=new Fr(o.shape,YD):n=new or(o.shape,YD),e.runWebGLProgram(n,[o],o.dtype)}var QD={kernelName:Xs,backendName:\"webgl\",kernelFunc:m9};var d9=Ut+`\n if (abs(x) > 1.) {\n return NAN;\n }\n return acos(x);\n`,f9=xe({opSnippet:d9}),ZD={kernelName:Wo,backendName:\"webgl\",kernelFunc:f9};var h9=Ut+`\n if (x < 1.0) return NAN;\nreturn log(x + sqrt(x * x - 1.0));`,g9=xe({opSnippet:h9}),JD={kernelName:Uo,backendName:\"webgl\",kernelFunc:g9};var eA=\"return a + b;\",x9=nt({opSnippet:eA,packedOpSnippet:eA,supportsComplex:!0,cpuKernelImpl:RR}),tA={kernelName:uo,backendName:\"webgl\",kernelFunc:x9};var bh=class{constructor(t,e){this.outputShape=[],this.outputShape=t,this.variableNames=e.map((s,a)=>`T${a}`);let o=[];this.variableNames.forEach(s=>{o.push(`float v${s} = get${s}AtOutCoords();`)});let n=this.variableNames.map(s=>`v${s}`).join(\" + \");this.userCode=`\n void main() {\n ${o.join(`\n `)}\n\n float result = ${n};\n setOutput(result);\n }\n `}};var Ch=class{constructor(t,e){this.outputShape=[],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=t,this.variableNames=e.map((s,a)=>`T${a}`);let o=[];this.variableNames.forEach(s=>{o.push(`vec4 v${s} = get${s}AtOutCoords();`)});let n=this.variableNames.map(s=>`v${s}`).join(\" + \");this.userCode=`\n void main() {\n ${o.join(`\n `)}\n\n vec4 result = ${n};\n setOutput(result);\n }\n `}};function wh(r){let{inputs:t,backend:e}=r,o=t;if(o.length===1)return At({inputs:{x:o[0]},backend:e});if(o.length>A().getNumber(\"WEBGL_MAX_TEXTURES_IN_SHADER\")){let p=Math.floor(o.length/2),u=wh({inputs:o.slice(0,p),backend:e}),c=wh({inputs:o.slice(p),backend:e});return wh({inputs:[u,c],backend:e})}let n=o.map(p=>p.dtype).reduce((p,u)=>dt(p,u)),s=o.map(p=>p.shape),i=A().getBool(\"WEBGL_PACK\")?new Ch(o[0].shape,s):new bh(o[0].shape,s);return e.runWebGLProgram(i,o,n)}var rA={kernelName:Go,backendName:\"webgl\",kernelFunc:wh};function y9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=n.shape.length,p=y.parseAxisParam(s,n.shape),u=p,c=w.getAxesPermutation(u,i),l=n;c!=null&&(l=Ct({inputs:{x:n},backend:e,attrs:{perm:c}}),u=w.getInnerMostAxes(u.length,i)),w.assertAxesAreInnerMostDims(\"all\",u,i);let[m,d]=w.computeOutAndReduceShapes(l.shape,u),f=y.sizeFromShape(d),h=te({inputs:{x:l},backend:e,attrs:{shape:[-1,f]}}),g=Yr(h,h.dtype,\"all\",e),x;if(a){let b=w.expandShapeToKeepDim(m,p);x=te({inputs:{x:g},backend:e,attrs:{shape:b}})}else x=te({inputs:{x:g},backend:e,attrs:{shape:m}});return e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(g),c!=null&&e.disposeIntermediateTensorInfo(l),x}var oA={kernelName:Ho,backendName:\"webgl\",kernelFunc:y9};function b9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=n.shape.length,p=y.parseAxisParam(s,n.shape),u=p,c=w.getAxesPermutation(u,i),l=n;c!=null&&(l=Ct({inputs:{x:n},backend:e,attrs:{perm:c}}),u=w.getInnerMostAxes(u.length,i)),w.assertAxesAreInnerMostDims(\"any\",u,i);let[m,d]=w.computeOutAndReduceShapes(l.shape,u),f=y.sizeFromShape(d),h=te({inputs:{x:l},backend:e,attrs:{shape:[-1,f]}}),g=Yr(h,h.dtype,\"any\",e),x;if(a){let b=w.expandShapeToKeepDim(m,p);x=te({inputs:{x:g},backend:e,attrs:{shape:b}})}else x=te({inputs:{x:g},backend:e,attrs:{shape:m}});return e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(g),c!=null&&e.disposeIntermediateTensorInfo(l),x}var nA={kernelName:Ko,backendName:\"webgl\",kernelFunc:b9};var Sh=class{constructor(t,e,o){this.variableNames=[\"A\"];let{windowSize:n,batchSize:s,outSize:a}=t;o||this.variableNames.push(\"bestIndicesA\"),this.outputShape=[s,a];let i=e===\"max\"?\">\":\"<\",p=o?\"inOffset + i;\":\"round(getBestIndicesA(batch, inOffset + i));\";this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = outIdx * ${n};\n\n int bestIndex = inOffset;\n float bestValue = getA(batch, bestIndex);\n\n for (int i = 0; i < ${n}; i++) {\n int inIdx = ${p};\n float candidate = getA(batch, inIdx);\n if (candidate ${i} bestValue) {\n bestValue = candidate;\n bestIndex = inIdx;\n }\n }\n setOutput(float(bestIndex));\n }\n `}};var Ih=class{constructor(t,e,o,n){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,y.assert(t.length>2,()=>`Packed arg${o.charAt(0).toUpperCase()+o.slice(1)} supports only inputs with rank above 2.`);let s=t[t.length-1],a=Math.ceil(s/e);this.outputShape=t.slice(0,-1),a>1&&this.outputShape.push(a),n||this.variableNames.push(\"bestIndicesA\");let i=this.outputShape,p=i.length,u=Re(p),c=Dt(\"coords\",p),l,m;if(a===1){m=p+1;let R=Re(m);l=`\n ${R} sourceLocR = ${R}(${c.join()}, 0);\n ++${c[p-1]};\n ${R} sourceLocG = ${R}(${c.join()}, 0);\n ++${c[p-2]};\n ${R} sourceLocA = ${R}(${c.join()}, 0);\n --${c[p-1]};\n ${R} sourceLocB = ${R}(${c.join()}, 0);\n --${c[p-2]};`}else m=p,l=`\n ${u} sourceLocR = coords;\n ++${c[p-1]};\n ${u} sourceLocG = coords;\n ++${c[p-2]};\n ${u} sourceLocA = coords;\n --${c[p-1]};\n ${u} sourceLocB = coords;\n --${c[p-2]};`;let d=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"].slice(0,m),f=\".\"+d[m-1],h=d.map(R=>\"int \"+R),g=Dt(\"sourceLocR\",m-1).concat(\"inIdx.r\"),x=Dt(\"sourceLocG\",m-1).concat(\"inIdx.g\"),b=Dt(\"sourceLocB\",m-1).concat(\"inIdx.b\"),C=Dt(\"sourceLocA\",m-1).concat(\"inIdx.a\"),S=o===\"max\"?\"greaterThan\":\"lessThan\",k=n?\"\":`\n inIdx = round(vec4(getBestIndicesAChannel(${g.join()}),\n getBestIndicesAChannel(${x.join()}),\n getBestIndicesAChannel(${b.join()}),\n getBestIndicesAChannel(${C.join()})));`,_=`vec4(\n getAChannel(${g.join()}),\n hasNextCol ? getAChannel(${x.join()}) : 0.,\n hasNextRow ? getAChannel(${b.join()}) : 0.,\n hasNextRow && hasNextCol ? getAChannel(${C.join()}) : 0.)`,E=n?\"\":`\n float getBestIndicesAChannel(${h.join()}) {\n return getChannel(getBestIndicesA(${d.join()}),\n vec2(${d.slice(-2).join()}));\n }`;this.userCode=`\n float getAChannel(${h.join()}) {\n return getChannel(getA(${d.join()}),\n vec2(${d.slice(-2).join()}));\n }\n ${E}\n void main() {\n ${u} coords = getOutputCoords();\n bool hasNextCol = ${c[p-1]} < ${i[p-1]-1};\n bool hasNextRow = ${c[p-2]} < ${i[p-2]-1};\n ${l}\n ivec4 srcIdx = ivec4(sourceLocR${f}, sourceLocG${f},\n sourceLocB${f}, sourceLocA${f}) * ${e};\n ivec4 inIdx = srcIdx;\n vec4 bestIndex = vec4(inIdx);\n vec4 bestValue = ${_};\n\n for (int i = 0; i < ${e}; i++) {\n inIdx = srcIdx;\n ${k}\n vec4 candidate = ${_};\n bvec4 nan = isnan(candidate);\n bvec4 replace = bvec4(\n vec4(${S}(candidate, bestValue)) * (vec4(1.0) - vec4(nan)));\n\n bestValue = vec4(replace.x ? candidate.x : bestValue.x,\n replace.y ? candidate.y : bestValue.y,\n replace.z ? candidate.z : bestValue.z,\n replace.w ? candidate.w : bestValue.w);\n bestIndex = mix(bestIndex, vec4(inIdx), vec4(replace));\n srcIdx++;\n }\n setOutput(bestIndex);\n }\n `}};function sA(r,t,e,o=null){let n=t.shape[0],s=t.shape[1];o!=null&&(n=o.shape[0],s=o.shape[1]);let a=w.computeOptimalWindowSize(s),i={windowSize:a,inSize:s,batchSize:n,outSize:Math.ceil(s/a)},p=new Sh(i,e,o==null),u=[t];o!=null&&u.push(o);let c=r.runWebGLProgram(p,u,\"int32\");if(c.shape[1]===1)return c;let l=sA(r,t,e,c);return r.disposeIntermediateTensorInfo(c),l}function aA(r,t,e,o=null){let n=o!=null?o.shape:t.shape,s=n[n.length-1],a=w.computeOptimalWindowSize(s),i=new Ih(n,a,e,o==null),p=o==null?[t]:[t,o],u=r.runWebGLProgram(i,p,\"int32\");if(u.shape.length===t.shape.length){let c=aA(r,t,e,u);return r.disposeIntermediateTensorInfo(u),c}return u}function vh(r,t,e,o){let n=[e];if(w.assertAxesAreInnerMostDims(\"arg\"+o.charAt(0).toUpperCase()+o.slice(1),n,t.shape.length),!A().getBool(\"WEBGL_PACK_REDUCE\")||t.shape.length<=2){let s=[],a=r.texData.get(t.dataId),i=a!==null&&a.isPacked,p=t;i&&(p=r.unpackTensor(t),s.push(p));let[u,c]=w.computeOutAndReduceShapes(p.shape,n),l=y.sizeFromShape(c),m=te({inputs:{x:p},backend:r,attrs:{shape:[-1,l]}});s.push(m);let d=sA(r,m,o);s.push(d);let f=te({inputs:{x:d},backend:r,attrs:{shape:u}});return s.forEach(h=>r.disposeIntermediateTensorInfo(h)),f}return aA(r,t,o)}function C9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=Ct({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMax\",[a[0]],p.shape.length);let c=vh(e,p,a[0],\"max\");return u.forEach(l=>e.disposeIntermediateTensorInfo(l)),c}var iA={kernelName:Ys,backendName:\"webgl\",kernelFunc:C9};function w9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=Ct({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMin\",[a[0]],p.shape.length);let c=vh(e,p,a[0],\"min\");return u.forEach(l=>e.disposeIntermediateTensorInfo(l)),c}var uA={kernelName:Qs,backendName:\"webgl\",kernelFunc:w9};var S9=Ut+`\n if (abs(x) > 1.) {\n return NAN;\n }\n return asin(x);\n`,I9=xe({opSnippet:S9}),pA={kernelName:qo,backendName:\"webgl\",kernelFunc:I9};var v9=Ut+\"return log(x + sqrt(x * x + 1.0));\",k9=xe({opSnippet:v9}),cA={kernelName:jo,backendName:\"webgl\",kernelFunc:k9};var N9=Ut+`\n return atan(x);\n`,T9=xe({opSnippet:N9}),lA={kernelName:Xo,backendName:\"webgl\",kernelFunc:T9};var _9=Wc+`\n return atan(a, b);\n`,$9=`\n vec4 result = atan(a, b);\n bvec4 isNaNA = isnan(a);\n bvec4 isNaNB = isnan(b);\n bvec4 isNaN = bvec4(isNaNA.x || isNaNB.x, isNaNA.y || isNaNB.y, isNaNA.z || isNaNB.z, isNaNA.w || isNaNB.w);\n `+Xr+`\n return result;\n`,E9=nt({opSnippet:_9,packedOpSnippet:$9}),mA={kernelName:Qo,backendName:\"webgl\",kernelFunc:E9};var R9=Ut+`\n if ((x < -1.0) || (x > 1.0)) return NAN;\nreturn (log(1.0 + x) - log(1.0 - x)) / 2.0;`,D9=xe({opSnippet:R9}),dA={kernelName:Yo,backendName:\"webgl\",kernelFunc:D9};var Us=class{constructor(t,e,o,n=!1,s=!1){if(this.variableNames=[\"x\"],e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");let a=t.filterWidth,i=t.strideHeight,p=t.strideWidth,u=t.dilationHeight,c=t.dilationWidth,l=t.effectiveFilterHeight,m=t.effectiveFilterWidth,d=t.padInfo.top,f=t.padInfo.left;this.outputShape=t.outShape;let h=e===\"avg\",g=`((batch * ${t.inHeight} + xR) * ${t.inWidth} + xC) * ${t.inChannels} + d`,x=`(xR * ${t.inWidth} + xC) * ${t.inChannels} + d`,b=\"0.0\";if(h||(b=\"-1.0 / 1e-20\"),o){let R=\">=\";this.userCode=`\n const ivec2 strides = ivec2(${i}, ${p});\n const ivec2 pads = ivec2(${d}, ${f});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d = coords[3];\n\n ivec2 xRCCorner = coords.yz * strides - pads;\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // max/min x(?, ?, d) to get y(yR, yC, d).\n // ? = to be determined\n float minMaxValue = 0.0;\n float minMaxValueFound = 0.0;\n int minMaxPosition = 0;\n float avgValue = 0.0;\n\n for (int wR = 0; wR < ${l};\n wR += ${u}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${m};\n wC += ${c}) {\n int xC = xCCorner + wC;\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float value = getX(batch, xR, xC, d);\n\n // If a min / max value has already been found, use it. If not,\n // use the current value.\n float currMinMaxValue = mix(\n value, minMaxValue, minMaxValueFound);\n if (value ${R} currMinMaxValue) {\n minMaxValue = value;\n minMaxValueFound = 1.0;\n minMaxPosition = ${n?s?g:x:`wR * ${m} + wC`};\n }\n }\n }\n setOutput(float(minMaxPosition));\n }\n `;return}let C=\"max\",S=`${e}(${e}(${e}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;e===\"avg\"&&(S=\"avgValue / max(count, 1.0)\");let k=Math.floor(a/4)*4,_=a%4,E=`\n if (${h}) {\n avgValue += dot(values, ones);\n } else {\n minMaxValue = ${C}(values, minMaxValue);\n }\n `;this.userCode=`\n const ivec2 strides = ivec2(${i}, ${p});\n const ivec2 pads = ivec2(${d}, ${f});\n const float initializationValue = ${b};\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float count = 0.0;\n\n float getValue(int batch, int xR, int xC, int d) {\n if (xC < 0 || xC >= ${t.inWidth}) {\n return initializationValue;\n }\n count += 1.0;\n return getX(batch, xR, xC, d);\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d = coords[3];\n\n ivec2 xRCCorner = coords.yz * strides - pads;\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // max/min x(?, ?, d) to get y(yR, yC, d).\n // ? = to be determined\n vec4 minMaxValue = vec4(${b});\n float avgValue = 0.0;\n count = 0.0;\n\n for (int wR = 0; wR < ${l};\n wR += ${u}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${k}; wC += 4) {\n int xC = xCCorner + wC * ${c};\n\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n getValue(batch, xR, xC + ${c}, d),\n getValue(batch, xR, xC + 2 * ${c}, d),\n getValue(batch, xR, xC + 3 * ${c}, d)\n );\n\n ${E}\n }\n\n int xC = xCCorner + ${k};\n if (${_===1}) {\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n ${E}\n } else if (${_===2}) {\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n getValue(batch, xR, xC + ${c}, d),\n initializationValue,\n initializationValue\n );\n\n ${E}\n } else if (${_===3}) {\n vec4 values = vec4(\n getValue(batch, xR, xC, d),\n getValue(batch, xR, xC + ${c}, d),\n getValue(batch, xR, xC + 2 * ${c}, d),\n initializationValue\n );\n\n ${E}\n }\n }\n setOutput(${S});\n }\n `}},Iu=class{constructor(t,e,o,n=!1,s=!1){if(this.variableNames=[\"x\"],e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");let a=t.filterWidth,i=t.strideDepth,p=t.strideHeight,u=t.strideWidth,c=t.dilationDepth,l=t.dilationHeight,m=t.dilationWidth,d=t.effectiveFilterDepth,f=t.effectiveFilterHeight,h=t.effectiveFilterWidth,g=t.padInfo.front,x=t.padInfo.top,b=t.padInfo.left;this.outputShape=t.outShape;let C=e===\"avg\",S=\"0.0\";if(C||(S=\"-1.0 / 1e-20\"),o){let P=\">=\";this.userCode=`\n const ivec3 strides =\n ivec3(${i}, ${p}, ${u});\n const ivec3 pads = ivec3(${g}, ${x}, ${b});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 xCorner = ivec3(coords.y, coords.z, coords.w) * strides - pads;\n int xDCorner = xCorner.x;\n int xRCorner = xCorner.y;\n int xCCorner = xCorner.z;\n\n // max/min x(?, ?, ?, ch) to get y(yD, yR, yC, ch).\n // ? = to be determined\n float minMaxValue = 0.0;\n float minMaxValueFound = 0.0;\n int minMaxPosition = 0;\n\n for (int wD = 0; wD < ${d};\n wD += ${c}) {\n int xD = xDCorner + wD;\n\n if (xD < 0 || xD >= ${t.inDepth}) {\n continue;\n }\n\n for (int wR = 0; wR < ${f};\n wR += ${l}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${h};\n wC += ${m}) {\n int xC = xCCorner + wC;\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float value = getX(batch, xD, xR, xC, ch);\n\n // If a min / max value has already been found, use it. If not,\n // use the current value.\n float currMinMaxValue = mix(\n value, minMaxValue, minMaxValueFound);\n if (value ${P} currMinMaxValue) {\n minMaxValue = value;\n minMaxValueFound = 1.0;\n minMaxPosition = ${n?s?`(((batch * ${t.inDepth} + xD) * ${t.inHeight} + xR) * ${t.inWidth} + xC) * ${t.inChannels} + ch`:`((xD * ${t.inHeight} + xR) * ${t.inWidth} + xC) * ${t.inChannels} + ch`:`wD * ${f} * ${h} +\n wR * ${h} + wC`};\n }\n }\n }\n }\n setOutput(float(minMaxPosition));\n }\n `;return}let k=\"max\",_=`${e}(${e}(${e}(minMaxValue[0], minMaxValue[1]), minMaxValue[2]), minMaxValue[3])`;e===\"avg\"&&(_=\"avgValue / max(count, 1.0)\");let E=Math.floor(a/4)*4,R=a%4,D=`\n if (${C}) {\n avgValue += dot(values, ones);\n } else {\n minMaxValue = ${k}(values, minMaxValue);\n }\n `;this.userCode=`\n const ivec3 strides =\n ivec3(${i}, ${p}, ${u});\n const ivec3 pads = ivec3(${g}, ${x}, ${b});\n const float initializationValue = ${S};\n const vec4 ones = vec4(1.0, 1.0, 1.0, 1.0);\n\n float count = 0.0;\n\n float getValue(int batch, int xD, int xR, int xC, int ch) {\n if (xC < 0 || xC >= ${t.inWidth}) {\n return initializationValue;\n }\n count += 1.0;\n return getX(batch, xD, xR, xC, ch);\n }\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 xCorner = ivec3(coords.y, coords.z, coords.w) * strides - pads;\n int xDCorner = xCorner.x;\n int xRCorner = xCorner.y;\n int xCCorner = xCorner.z;\n\n // max/min x(?, ?, ?, d) to get y(yD, yR, yC, ch).\n // ? = to be determined\n vec4 minMaxValue = vec4(${S});\n float avgValue = 0.0;\n count = 0.0;\n\n for (int wD = 0; wD < ${d};\n wD += ${c}) {\n int xD = xDCorner + wD;\n\n if (xD < 0 || xD >= ${t.inDepth}) {\n continue;\n }\n\n for (int wR = 0; wR < ${f};\n wR += ${l}) {\n int xR = xRCorner + wR;\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${E}; wC += 4) {\n int xC = xCCorner + wC * ${m};\n\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n getValue(batch, xD, xR, xC + ${m}, ch),\n getValue(batch, xD, xR, xC + 2 * ${m}, ch),\n getValue(batch, xD, xR, xC + 3 * ${m}, ch)\n );\n\n ${D}\n }\n\n int xC = xCCorner + ${E};\n if (${R===1}) {\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n ${D}\n } else if (${R===2}) {\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n getValue(batch, xD, xR, xC + ${m}, ch),\n initializationValue,\n initializationValue\n );\n\n ${D}\n } else if (${R===3}) {\n vec4 values = vec4(\n getValue(batch, xD, xR, xC, ch),\n getValue(batch, xD, xR, xC + ${m}, ch),\n getValue(batch, xD, xR, xC + 2 * ${m}, ch),\n initializationValue\n );\n\n ${D}\n }\n }\n }\n setOutput(${_});\n }\n `}};function A9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t;Vs(n,\"avgPool\");let{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1;y.assert(w.eitherStridesOrDilationsAreOne(a,u),()=>`Error in avgPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p);if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))return At({inputs:{x:n},backend:e});let l=new Us(c,\"avg\",!1);return e.runWebGLProgram(l,[n],\"float32\")}var fA={kernelName:Zo,backendName:\"webgl\",kernelFunc:A9};function F9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,p,u),m=new Iu(l,\"avg\",!1);return e.runWebGLProgram(m,[n],\"float32\")}var hA={kernelName:Zs,backendName:\"webgl\",kernelFunc:F9};var kh=class{constructor(t){this.variableNames=[\"dy\"],this.outputShape=t.inShape;let e=t.filterHeight,o=t.filterWidth,n=t.strideHeight,s=t.strideWidth,a=t.dilationHeight,i=t.dilationWidth,p=t.effectiveFilterHeight,u=t.effectiveFilterWidth,c=p-1-t.padInfo.top,l=u-1-t.padInfo.left,m=1/(e*o);this.userCode=`\n const ivec2 pads = ivec2(${c}, ${l});\n const float avgMultiplier = float(${m});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n\n ivec2 dyRCCorner = coords.yz - pads;\n int dyRCorner = dyRCCorner.x;\n int dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${p};\n wR += ${a}) {\n float dyR = float(dyRCorner + wR) / ${n}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${u};\n wC+= ${i}) {\n float dyC = float(dyCCorner + wC) / ${s}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(b, idyR, idyC, d);\n\n dotProd += dyValue * avgMultiplier;\n }\n }\n setOutput(dotProd);\n }\n `}},Nh=class{constructor(t){this.variableNames=[\"dy\"],this.outputShape=t.inShape;let e=t.filterDepth,o=t.filterHeight,n=t.filterWidth,s=t.strideDepth,a=t.strideHeight,i=t.strideWidth,p=t.dilationDepth,u=t.dilationHeight,c=t.dilationWidth,l=t.effectiveFilterDepth,m=t.effectiveFilterHeight,d=t.effectiveFilterWidth,f=l-1-t.padInfo.front,h=m-1-t.padInfo.top,g=d-1-t.padInfo.left,x=1/(e*o*n);this.userCode=`\n const ivec3 pads = ivec3(${f}, ${h}, ${g});\n const float avgMultiplier = float(${x});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 dyCorner = ivec3(coords.y, coords.z, coords.w) - pads;\n int dyDCorner = dyCorner.x;\n int dyRCorner = dyCorner.y;\n int dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, d) with pos mask(:, :, :, ch) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n\n for (int wD = 0; wD < ${l};\n wD += ${p}) {\n float dyD = float(dyDCorner + wD) / ${s}.0;\n\n if (dyD < 0.0 || dyD >= ${t.outDepth}.0 || fract(dyD) > 0.0) {\n continue;\n }\n int idyD = int(dyD);\n\n for (int wR = 0; wR < ${m};\n wR += ${u}) {\n float dyR = float(dyRCorner + wR) / ${a}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 ||\n fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${d};\n wC += ${c}) {\n float dyC = float(dyCCorner + wC) / ${i}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(batch, idyD, idyR, idyC, ch);\n\n dotProd += dyValue * avgMultiplier;\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function P9(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=[1,1,1],m=w.computePool3DInfo(a.shape,i,p,l,u,c),d=new Nh(m);return e.runWebGLProgram(d,[n],a.dtype)}var gA={kernelName:Ai,backendName:\"webgl\",kernelFunc:P9};function O9(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s;Vs([n,s],\"avgPoolGrad\");let{filterSize:i,strides:p,pad:u}=o,c=w.computePool2DInfo(a.shape,i,p,1,u),l=new kh(c);return e.runWebGLProgram(l,[n],a.dtype)}var xA={kernelName:Di,backendName:\"webgl\",kernelFunc:O9};function M9(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;return _p({a:n,b:s,transposeA:a,transposeB:i,backend:e})}var yA={kernelName:Jo,backendName:\"webgl\",kernelFunc:M9};var Th=class{constructor(t,e,o,n,s,a){this.outputShape=[],this.variableNames=[\"x\",\"mean\",\"variance\"],w.assertAndGetBroadcastShape(t,e),w.assertAndGetBroadcastShape(t,o);let i=\"0.0\";n!=null&&(w.assertAndGetBroadcastShape(t,n),this.variableNames.push(\"offset\"),i=\"getOffsetAtOutCoords()\");let p=\"1.0\";s!=null&&(w.assertAndGetBroadcastShape(t,s),this.variableNames.push(\"scale\"),p=\"getScaleAtOutCoords()\"),this.outputShape=t,this.userCode=`\n void main() {\n float x = getXAtOutCoords();\n float mean = getMeanAtOutCoords();\n float variance = getVarianceAtOutCoords();\n float offset = ${i};\n float scale = ${p};\n float inv = scale * inversesqrt(variance + float(${a}));\n setOutput(dot(vec3(x, -mean, offset), vec3(inv, inv, 1)));\n }\n `}};var _h=class{constructor(t,e,o,n,s,a){this.packedInputs=!0,this.packedOutput=!0,this.variableNames=[\"x\",\"mean\",\"variance\"],w.assertAndGetBroadcastShape(t,e),w.assertAndGetBroadcastShape(t,o);let i=\"vec4(0.0)\";n!=null&&(w.assertAndGetBroadcastShape(t,n),this.variableNames.push(\"offset\"),i=\"getOffsetAtOutCoords()\");let p=\"vec4(1.0)\";s!=null&&(w.assertAndGetBroadcastShape(t,s),this.variableNames.push(\"scale\"),p=\"getScaleAtOutCoords()\"),this.outputShape=t,this.userCode=`\n void main() {\n vec4 offset = ${i};\n vec4 scale = ${p};\n\n vec4 x = getXAtOutCoords();\n vec4 mean = getMeanAtOutCoords();\n vec4 variance = getVarianceAtOutCoords();\n\n vec4 inv = scale * inversesqrt(variance + vec4(${a}));\n\n setOutput((x - mean) * inv + offset);\n }\n `}};var L9=({inputs:r,backend:t,attrs:e})=>{let{x:o,mean:n,variance:s,offset:a,scale:i}=r;y.assert(n.shape.length===s.shape.length,()=>\"Batch normalization gradient requires mean and variance to have equal ranks.\"),y.assert(a==null||n.shape.length===a.shape.length,()=>\"Batch normalization gradient requires mean and offset to have equal ranks.\"),y.assert(i==null||n.shape.length===i.shape.length,()=>\"Batch normalization gradient requires mean and scale to have equal ranks.\");let{varianceEpsilon:p}=e;p==null&&(p=.001);let u=[o,n,s],c=null;a!=null&&(c=a.shape,u.push(a));let l=null;i!=null&&(l=i.shape,u.push(i));let m=A().getBool(\"WEBGL_PACK_NORMALIZATION\")?new _h(o.shape,n.shape,s.shape,c,l,p):new Th(o.shape,n.shape,s.shape,c,l,p);return t.runWebGLProgram(m,u,u[0].dtype)},bA={kernelName:vn,backendName:\"webgl\",kernelFunc:L9};var $h=class{constructor(t){this.variableNames=[\"source\"],this.outputShape=t,this.rank=t.length;let e=Re(this.rank);this.customUniforms=[{name:\"start\",arrayIndex:this.rank,type:\"int\"}];let o=B9(this.rank),n,s=t.map((a,i)=>`sourceLoc.${bv[i]} = start[${i}] + coords.${bv[i]};`);n=`\n ${e} sourceLoc;\n ${e} coords = getOutputCoords();\n ${s.join(`\n`)}\n `,this.userCode=`\n void main() {\n ${n}\n setOutput(getSource(${o}));\n }\n `}},bv=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"];function B9(r){if(r===1)return\"sourceLoc\";if(r<=6)return bv.slice(0,r).map(t=>\"sourceLoc.\"+t).join(\",\");throw Error(`Slicing for rank ${r} is not yet supported`)}var Eh=class{constructor(t){this.variableNames=[\"source\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=t,this.rank=t.length,this.customUniforms=[{name:\"start\",arrayIndex:this.rank,type:\"int\"}];let e=Re(this.rank),o=Dt(\"coords\",this.rank),n=Dt(\"sourceLoc\",this.rank),s=this.rank===1?\"sourceLoc\":`vec2(${n.slice(-2).join()})`,a=`getChannel(getSource(${n.join()}), ${s})`,i=`\n result.x = ${a};\n if (++${o[this.rank-1]} < ${t[this.rank-1]}) {\n ++${n[this.rank-1]};\n result.y = ${a};\n --${n[this.rank-1]};\n }\n `,p=this.rank===1?\"\":`\n --${o[this.rank-1]};\n if (++${o[this.rank-2]} < ${t[this.rank-2]}) {\n ++${n[this.rank-2]};\n result.z = ${a};\n if (++${o[this.rank-1]} < ${t[this.rank-1]}) {\n ++${n[this.rank-1]};\n result.w = ${a};\n }\n }\n `,u=this.rank<=4?`sourceLoc = coords +\n ${e}(${t.map((c,l)=>`start[${l}]`).join()});`:t.map((c,l)=>`${n[l]} = ${o[l]} + start[${l}];`).join(`\n`);this.userCode=`\n void main() {\n ${e} coords = getOutputCoords();\n ${e} sourceLoc;\n ${u}\n vec4 result = vec4(0.);\n ${i}\n ${p}\n setOutput(result);\n }\n `}};function z9(r,t,e,o){let n=o.texData.get(r.dataId),s=o.makeTensorInfo(e,r.dtype),a=o.texData.get(s.dataId);Object.assign(a,n),a.refCount=1,a.shape=e,a.dtype=r.dtype;let i=ct.computeFlatOffset(t,y.computeStrides(r.shape));n.slice&&(i+=n.slice.flatOffset),a.slice={flatOffset:i,origDataId:n.slice&&n.slice.origDataId||r.dataId};let p=o.dataRefCount.get(a.slice.origDataId)||1;return o.dataRefCount.set(a.slice.origDataId,p+1),s}function Gs(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,size:a}=o,[i,p]=ct.parseSliceParams(n,s,a);if(ct.assertParamsValid(n,i,p),y.sizeFromShape(p)===0)return e.makeTensorInfo(p,n.dtype,[]);if(e.shouldExecuteOnCPU([n])||n.dtype===\"string\"){let l=e.texData.get(n.dataId),m=pD(l.values,i,p,n.shape,n.dtype);return e.makeTensorInfo(p,n.dtype,m)}let{isPacked:u}=e.texData.get(n.dataId),c=ct.isSliceContinous(n.shape,i,p);if(u||!c){let l=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new Eh(p):new $h(p),m=[i];return e.runWebGLProgram(l,[n],n.dtype,m)}return e.uploadToGPU(n.dataId),z9(n,i,p,e)}var CA={kernelName:ha,backendName:\"webgl\",kernelFunc:Gs};var V9=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,crops:a}=o;y.assert(n.shape.length<=4,()=>\"batchToSpaceND for rank > 4 with a WebGL backend not implemented yet\");let i=s.reduce((b,C)=>b*C),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=[],f=te({inputs:{x:n},backend:e,attrs:{shape:p}}),h=Ct({inputs:{x:f},backend:e,attrs:{perm:u}}),g=te({inputs:{x:h},backend:e,attrs:{shape:c}}),x=Gs({inputs:{x:g},backend:e,attrs:{begin:l,size:m}});return d.push(f),d.push(h),d.push(g),d.forEach(b=>e.disposeIntermediateTensorInfo(b)),x},wA={kernelName:Js,backendName:\"webgl\",kernelFunc:V9};function W9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a}=o,i=e.readSync(n.dataId),p=e.readSync(s.dataId),u=ph(i,p,s.dtype,s.shape,a);return e.makeTensorInfo([a],s.dtype,u)}var SA={kernelName:en,backendName:\"webgl\",kernelFunc:W9};var U9=`\n int r = int(a.r) & int(b.r);\n int g = int(a.g) & int(b.g);\n int rb = int(a.b) & int(b.b);\n int ra = int(a.a) & int(b.a);\n return vec4(r, g, rb, ra);\n`,G9=`\n return float(int(a.r) & int(b.r));\n`;function H9(r){let{inputs:t,backend:e}=r,{a:o,b:n}=t,s=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\"),a=A().getNumber(\"WEBGL_VERSION\");if(e.shouldExecuteOnCPU([o,n])||a===1){let p=e.texData.get(o.dataId).values,u=e.texData.get(n.dataId).values,[c,l]=AR(o.shape,n.shape,p,u,o.dtype),m=e.makeTensorInfo(l,o.dtype),d=e.texData.get(m.dataId);return d.values=c,m}let i;return s?i=new jr(U9,o.shape,n.shape,!1):i=new Pr(G9,o.shape,n.shape),e.runWebGLProgram(i,[o,n],o.dtype)}var IA={kernelName:ja,backendName:\"webgl\",kernelFunc:H9};function K9(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t,s=e.readSync(o.dataId),a=e.readSync(n.dataId),i=w.assertAndGetBroadcastShape(Array.from(s),Array.from(a));return e.makeTensorInfo([i.length],\"int32\",Int32Array.from(i))}var vA={kernelName:ea,backendName:\"webgl\",kernelFunc:K9};var q9=\"return float(a != b);\",Cv=nt({opSnippet:q9,cpuKernelImpl:eD,dtype:\"bool\"}),kA={kernelName:Qn,backendName:\"webgl\",kernelFunc:Cv};function wi(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.texData.get(o.dataId);return At({inputs:{x:n.complexTensorInfos.real},backend:e})}var NA={kernelName:qi,backendName:\"webgl\",kernelFunc:wi};var j9=\"return float(int(x));\";function TA(r,t){let e=new or(r.shape,j9),o=t.runWebGLProgram(e,[r],\"int32\");return{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}function wv(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dtype:s}=o;if(s===\"complex64\"){if(n.dtype===\"complex64\")return At({inputs:{x:n},backend:e});let a=Gr(n.shape),i=wv({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}}),p=Or({inputs:{real:i,imag:a},backend:e});return a.dispose(),e.disposeIntermediateTensorInfo(i),p}if(n.dtype===\"complex64\"){let a=wi({inputs:{input:n},backend:e}),i=wv({inputs:{x:a},backend:e,attrs:{dtype:s}});return e.disposeIntermediateTensorInfo(a),i}if(!y.hasEncodingLoss(n.dtype,s)){let a=At({inputs:{x:n},backend:e});return{dataId:a.dataId,shape:a.shape,dtype:s}}if(e.shouldExecuteOnCPU([n])){let a=e.texData.get(n.dataId).values,[i,p,u]=FR(a,n.shape,n.dtype,s);return e.makeTensorInfo(i,p,u)}if(s===\"int32\")return TA(n,e);if(s===\"bool\"){let a=e.makeTensorInfo([],\"bool\",y.getTypedArrayFromDType(\"bool\",1)),p=Cv({inputs:{a:n,b:a},backend:e});return e.disposeIntermediateTensorInfo(a),p}throw new Error(`Error in Cast: failed to cast ${n.dtype} to ${s}`)}var _A={kernelName:bo,backendName:\"webgl\",kernelFunc:wv};var $A=\"return ceil(x);\",X9=xe({opSnippet:$A,packedOpSnippet:$A,cpuKernelImpl:PR}),EA={kernelName:tn,backendName:\"webgl\",kernelFunc:X9};var Rh=class{constructor(t){this.variableNames=[\"A\"],this.customUniforms=[{name:\"minVal\",type:\"float\"},{name:\"maxVal\",type:\"float\"}],this.outputShape=t,this.userCode=`\n\n void main() {\n float value = getAAtOutCoords();\n if (isnan(value)) {\n setOutput(value);\n return;\n }\n\n setOutput(clamp(value, minVal, maxVal));\n }\n `}};var Dh=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"minVal\",type:\"float\"},{name:\"maxVal\",type:\"float\"}],this.outputShape=t,this.userCode=`\n void main() {\n vec4 value = getAAtOutCoords();\n\n if (any(isnan(value))) {\n setOutput(value);\n return;\n }\n\n setOutput(clamp(value, vec4(minVal), vec4(maxVal)));\n }\n `}};function Y9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{clipValueMin:s,clipValueMax:a}=o,i;A().getBool(\"WEBGL_PACK_CLIP\")?i=new Dh(n.shape):i=new Rh(n.shape);let p=[[s],[a]];return e.runWebGLProgram(i,[n],n.dtype,p)}var RA={kernelName:Co,backendName:\"webgl\",kernelFunc:Y9};var Ah=class{constructor(t){this.variableNames=[\"real\",\"imag\"],this.outputShape=t,this.userCode=`\n void main() {\n float re = abs(getRealAtOutCoords());\n float im = abs(getImagAtOutCoords());\n float mx = max(re, im);\n\n // sadly the length function in glsl is not underflow-safe\n // (at least not on Intel GPUs). So the safe solution is\n // to ensure underflow-safety in all cases.\n setOutput(\n mx == 0.0 ? 0.0 : mx * length(vec2(1, min(re, im)/mx))\n );\n }\n `}};function DA(r,t){return{dataId:t.dataId,dtype:t.dtype,shape:r.shape}}function Q9(r){let{inputs:t,backend:e}=r,{x:o}=t,n=e.texData.get(o.dataId),s=new Ah(o.shape),a=[DA(o,n.complexTensorInfos.real),DA(o,n.complexTensorInfos.imag)];return e.runWebGLProgram(s,a,a[0].dtype)}var AA={kernelName:Pi,backendName:\"webgl\",kernelFunc:Q9};var Fh=class{constructor(t){this.outputShape=[],this.outputShape=w.computeOutShape(t,1),this.variableNames=t.map((a,i)=>`T${i}`);let e=new Array(t.length-1);e[0]=t[0][1];for(let a=1;a`T${g}`);let p=new Array(t.length-1);p[0]=t[0][e];for(let h=1;h= ${p[h-1]}) {\n return getChannel(\n getT${h}(${Ph(i,u,g)}),\n vec2(${Ph(c,u,g)}));\n }`}let d=p.length,f=p[p.length-1];m+=`\n return getChannel(\n getT${d}(${Ph(i,u,f)}),\n vec2(${Ph(c,u,f)}));`,this.userCode=`\n float getValue(${i.map(h=>\"int \"+h)}) {\n ${m}\n }\n\n void main() {\n ${s} coords = getOutputCoords();\n vec4 result = vec4(getValue(${a}), 0., 0., 0.);\n\n ${a[n-1]} = ${a[n-1]} + 1;\n if (${a[n-1]} < ${o[n-1]}) {\n result.g = getValue(${a});\n }\n\n ${a[n-2]} = ${a[n-2]} + 1;\n if (${a[n-2]} < ${o[n-2]}) {\n result.a = getValue(${a});\n }\n\n ${a[n-1]} = ${a[n-1]} - 1;\n if (${a[n-2]} < ${o[n-2]} &&\n ${a[n-1]} < ${o[n-1]}) {\n result.b = getValue(${a});\n }\n setOutput(result);\n }\n `}};function Ph(r,t,e){let o=r.indexOf(t);return r.map((s,a)=>a===o?`${s} - ${e}`:s).join()}function $p(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.texData.get(o.dataId);return At({inputs:{x:n.complexTensorInfos.imag},backend:e})}var FA={kernelName:Gi,backendName:\"webgl\",kernelFunc:$p};function Gc(r,t,e){let o=r[0].dtype;if(o===\"complex64\"){let d=r.map(b=>wi({inputs:{input:b},backend:e})),f=r.map(b=>$p({inputs:{input:b},backend:e})),h=Gc(d,t,e),g=Gc(f,t,e),x=Or({inputs:{real:h,imag:g},backend:e});return d.forEach(b=>e.disposeIntermediateTensorInfo(b)),f.forEach(b=>e.disposeIntermediateTensorInfo(b)),e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(g),x}let n=e.shouldExecuteOnCPU(r);if(o===\"string\"&&(n=!0),n){let d=r.map(S=>{let _=[-1,y.sizeFromShape(S.shape.slice(t))];return te({inputs:{x:S},backend:e,attrs:{shape:_}})}),f=d.map(S=>({vals:e.readSync(S.dataId),shape:S.shape})),h=w.computeOutShape(d.map(S=>S.shape),1),g=d[0].shape[0]===1,x=OR(f,h,o,g),b=w.computeOutShape(r.map(S=>S.shape),t),C=e.makeTensorInfo(b,o,x);return d.forEach(S=>e.disposeIntermediateTensorInfo(S)),C}let s=r.filter(d=>y.sizeFromShape(d.shape)>0),a=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")&&s[0].shape.length>1;if(s.length===1){let d=a?new or(r[0].shape,Ba):new Fr(r[0].shape,Ba);return e.runWebGLProgram(d,r,o)}let i=A().getNumber(\"WEBGL_MAX_TEXTURES_IN_SHADER\");if(s.length>i){let d=[];for(let h=0;hf.shape),t);return e.runWebGLProgram(d,s,o)}let{tensors2D:p,outShape:u}=Z9(s,t,e),c=new Fh(p.map(d=>d.shape)),l=e.runWebGLProgram(c,p,o);p.forEach(d=>e.disposeIntermediateTensorInfo(d));let m=te({inputs:{x:l},attrs:{shape:u},backend:e});return e.disposeIntermediateTensorInfo(l),m}function Z9(r,t,e){let o=w.computeOutShape(r.map(s=>s.shape),t);return{tensors2D:r.map(s=>te({inputs:{x:s},attrs:{shape:[-1,y.sizeFromShape(s.shape.slice(t))]},backend:e})),outShape:o}}function Sv(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o,s=y.parseAxisParam(n,t[0].shape)[0],a=t.map(u=>u.shape);w.assertParamsConsistent(a,s);let i=w.computeOutShape(t.map(u=>u.shape),s);if(y.sizeFromShape(i)===0)return e.makeTensorInfo(i,t[0].dtype,[]);let p=t.filter(u=>y.sizeFromShape(u.shape)>0);return p.length===1?At({inputs:{x:p[0]},backend:e}):Gc(p,s,e)}var PA={kernelName:ta,backendName:\"webgl\",kernelFunc:Sv};var Hc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.outputShape=t.outShape;let a=t.padInfo.top,i=t.padInfo.left,p=t.strideHeight,u=t.strideWidth,c=t.dilationHeight,l=t.dilationWidth,m=t.filterHeight,d=t.filterWidth,f=Math.floor(t.inChannels/4)*4,h=t.inChannels%4,g=t.dataFormat===\"channelsLast\",x=g?1:2,b=g?2:3,C=g?3:1,S=\"\",k=\"\";o&&(n?S=`float activation(float a) {\n float b = getPreluActivationWeightsAtOutCoords();\n ${o}\n }`:s?S=`float activation(float a) {\n float b = getLeakyreluAlphaAtOutCoords();\n ${o}\n }`:S=`\n float activation(float x) {\n ${o}\n }\n `,k=\"result = activation(result);\");let _=e?\"result += getBiasAtOutCoords();\":\"\";e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),s&&this.variableNames.push(\"leakyreluAlpha\"),this.userCode=`\n ${S}\n\n const ivec2 strides = ivec2(${p}, ${u});\n const ivec2 pads = ivec2(${a}, ${i});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d2 = coords[${C}];\n\n ivec2 xRCCorner =\n ivec2(coords[${x}], coords[${b}]) * strides - pads;\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // Convolve x(?, ?, d1) with w(:, :, d1, d2) to get y(yR, yC, d2).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${m}; wR++) {\n int xR = xRCorner + wR * ${c};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${d}; wC++) {\n int xC = xCCorner + wC * ${l};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n for (int d1 = 0; d1 < ${f}; d1 += 4) {\n vec4 wValues = vec4(\n getW(wR, wC, d1, d2),\n getW(wR, wC, d1 + 1, d2),\n getW(wR, wC, d1 + 2, d2),\n getW(wR, wC, d1 + 3, d2)\n );\n\n if (${g}) {\n vec4 xValues = vec4(\n getX(batch, xR, xC, d1),\n getX(batch, xR, xC, d1 + 1),\n getX(batch, xR, xC, d1 + 2),\n getX(batch, xR, xC, d1 + 3)\n );\n dotProd += dot(xValues, wValues);\n } else {\n vec4 xValues = vec4(\n getX(batch, d1, xR, xC),\n getX(batch, d1 + 1, xR, xC),\n getX(batch, d1 + 2, xR, xC),\n getX(batch, d1 + 3, xR, xC)\n );\n dotProd += dot(xValues, wValues);\n }\n }\n\n if (${h===1}) {\n\n if (${g}) {\n dotProd +=\n getX(batch, xR, xC, ${f}) *\n getW(wR, wC, ${f}, d2);\n } else {\n dotProd +=\n getX(batch, ${f}, xR, xC) *\n getW(wR, wC, ${f}, d2);\n }\n\n } else if (${h===2}) {\n vec2 wValues = vec2(\n getW(wR, wC, ${f}, d2),\n getW(wR, wC, ${f} + 1, d2)\n );\n\n if (${g}) {\n vec2 xValues = vec2(\n getX(batch, xR, xC, ${f}),\n getX(batch, xR, xC, ${f} + 1)\n );\n dotProd += dot(xValues, wValues);\n } else {\n vec2 xValues = vec2(\n getX(batch, ${f}, xR, xC),\n getX(batch, ${f} + 1, xR, xC)\n );\n dotProd += dot(xValues, wValues);\n }\n\n } else if (${h===3}) {\n vec3 wValues = vec3(\n getW(wR, wC, ${f}, d2),\n getW(wR, wC, ${f} + 1, d2),\n getW(wR, wC, ${f} + 2, d2)\n );\n\n if (${g}) {\n vec3 xValues = vec3(\n getX(batch, xR, xC, ${f}),\n getX(batch, xR, xC, ${f} + 1),\n getX(batch, xR, xC, ${f} + 2)\n );\n dotProd += dot(xValues, wValues);\n } else {\n vec3 xValues = vec3(\n getX(batch, ${f}, xR, xC),\n getX(batch, ${f} + 1, xR, xC),\n getX(batch, ${f} + 2, xR, xC)\n );\n dotProd += dot(xValues, wValues);\n }\n\n }\n }\n }\n\n float result = dotProd;\n ${_}\n ${k}\n setOutput(result);\n }\n `}},Mh=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.outputShape=t.outShape;let e=t.padInfo.front,o=t.padInfo.top,n=t.padInfo.left,s=t.strideDepth,a=t.strideHeight,i=t.strideWidth,p=t.dilationDepth,u=t.dilationHeight,c=t.dilationWidth,l=t.filterDepth,m=t.filterHeight,d=t.filterWidth,f=Math.floor(t.inChannels/4)*4,h=t.inChannels%4;this.userCode=`\n const ivec3 strides = ivec3(${s}, ${a}, ${i});\n const ivec3 pads = ivec3(${e}, ${o}, ${n});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int d2 = coords.u;\n\n ivec3 xFRCCorner = ivec3(coords.y, coords.z, coords.w) * strides - pads;\n int xFCorner = xFRCCorner.x;\n int xRCorner = xFRCCorner.y;\n int xCCorner = xFRCCorner.z;\n\n // Convolve x(?, ?, ?, d1) with w(:, :, :, d1, d2) to get\n // y(yF, yR, yC, d2). ? = to be determined. : = across all\n // values in that axis.\n float dotProd = 0.0;\n for (int wF = 0; wF < ${l}; wF++) {\n int xF = xFCorner + wF * ${p};\n\n if (xF < 0 || xF >= ${t.inDepth}) {\n continue;\n }\n\n for (int wR = 0; wR < ${m}; wR++) {\n int xR = xRCorner + wR * ${u};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int wC = 0; wC < ${d}; wC++) {\n int xC = xCCorner + wC * ${c};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n for (int d1 = 0; d1 < ${f}; d1 += 4) {\n vec4 xValues = vec4(\n getX(batch, xF, xR, xC, d1),\n getX(batch, xF, xR, xC, d1 + 1),\n getX(batch, xF, xR, xC, d1 + 2),\n getX(batch, xF, xR, xC, d1 + 3)\n );\n vec4 wValues = vec4(\n getW(wF, wR, wC, d1, d2),\n getW(wF, wR, wC, d1 + 1, d2),\n getW(wF, wR, wC, d1 + 2, d2),\n getW(wF, wR, wC, d1 + 3, d2)\n );\n\n dotProd += dot(xValues, wValues);\n }\n\n if (${h===1}) {\n dotProd +=\n getX(batch, xF, xR, xC, ${f}) *\n getW(wF, wR, wC, ${f}, d2);\n } else if (${h===2}) {\n vec2 xValues = vec2(\n getX(batch, xF, xR, xC, ${f}),\n getX(batch, xF, xR, xC, ${f} + 1)\n );\n vec2 wValues = vec2(\n getW(wF, wR, wC, ${f}, d2),\n getW(wF, wR, wC, ${f} + 1, d2)\n );\n dotProd += dot(xValues, wValues);\n } else if (${h===3}) {\n vec3 xValues = vec3(\n getX(batch, xF, xR, xC, ${f}),\n getX(batch, xF, xR, xC, ${f} + 1),\n getX(batch, xF, xR, xC, ${f} + 2)\n );\n vec3 wValues = vec3(\n getW(wF, wR, wC, ${f}, d2),\n getW(wF, wR, wC, ${f} + 1, d2),\n getW(wF, wR, wC, ${f} + 2, d2)\n );\n dotProd += dot(xValues, wValues);\n }\n }\n }\n }\n setOutput(dotProd);\n }\n `}};var Kc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"pads\",type:\"ivec2\"},{name:\"strides\",type:\"ivec2\"},{name:\"dilations\",type:\"ivec2\"},{name:\"inDims\",type:\"ivec2\"}],this.outputShape=t.outShape,this.enableShapeUniforms=pt(this.outputShape.length);let a=t.padInfo.left,i=t.strideWidth,p=t.dilationWidth,u=t.filterHeight,c=t.filterWidth,l=c,m=`\n int xR; int xC; int xCOffset;\n vec4 wTexel; vec4 previous; vec4 final;`;for(let g=0;g=0 && xR < inDims[0]) {\n `;for(let g=0;g<(l+1)/2;g++){let x=g*2;if(m+=`\n xC = xCCorner + ${x*p};\n `,i===1){if(x= 0 && xCOffset < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n `,p===1&&x>0?m+=`\n xC${x} = vec4(xTexelC${x-2}.zw, xTexelC${x}.xy);\n `:m+=`\n xCOffset = xC + 1 - 2;\n\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n previous.zw = vec2(0.0);\n }\n\n xC${x} = vec4(previous.zw, xTexelC${x}.xy);\n } else {\n xC${x} = vec4(0.0, 0.0, xTexelC${x}.xy);\n }\n `):m+=`\n if (xC >= 0 && xC < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n\n xC${x} = xTexelC${x};\n `,x+1= 0 && xCOffset < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.0);\n }\n xTexelC${x+1}Ready = 1;\n }\n `,p>1?m+=`\n xCOffset -= 2;\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n xC${x+1} = vec4(previous.zw, xTexelC${x+1}.xy);\n } else {\n xC${x+1} = vec4(0.0, 0.0, xTexelC${x+1}.xy);\n }\n `:m+=`\n xC${x+1} = vec4(xTexelC${x}.zw, xTexelC${x+1}.xy);\n `):b===1?m+=`\n xC${x+1} = xTexelC${x};\n `:m+=`\n xCOffset = xC + ${b};\n\n if (xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.0);\n }\n xTexelC${x+1}Ready = 1;\n }\n\n xC${x+1} = xTexelC${x+1};\n `}}else x= 0 && xCOffset < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xCOffset, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n\n if(xC + 1 >= 0 && xC + 1 < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xC + 1, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xC + 2 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.0);\n }\n xTexelC${x+1}Ready = 1;\n }\n\n xC${x} = vec4(xTexelC${x}.zw, xTexelC${x+1}.zw);\n `,x+1= 0 && xCOffset < inDims[1]) {\n final = getX(batch, xR, xCOffset, d1);\n }\n xC${x+1} = vec4(xTexelC${x+1}.xy, final.xy);\n `)):(m+=`\n if(xC >= 0 && xC < inDims[1] && xTexelC${x}Ready == 0) {\n xTexelC${x} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${x}.zw = vec2(0.0);\n }\n xTexelC${x}Ready = 1;\n }\n\n xCOffset = xC + strides[1];\n if(xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${x+1}Ready == 0) {\n xTexelC${x+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${x+1}.zw = vec2(0.);\n }\n xTexelC${x+1}Ready = 1;\n }\n\n xC${x} = vec4(\n xTexelC${x}.xy, xTexelC${x+1}.xy);\n `,x+1= 0) {\n // Use custom imod instead mod. On Intel GPU, mod may generate\n // unexpected value.\n // https://github.com/tensorflow/tfjs/issues/5447\n offsetX = imod(blockIndex, outWidth) * stride[1] - pad[1];\n d1 = offsetX + dilation[1] * (imod(pos, itemsPerBlockRow) /\n inChannels);\n\n if(d1 < inputShape[${i}] && d1 >= 0) {\n\n ch = imod(pos, inChannels);\n\n if (${s}) {\n innerDims = vec2(d1, ch);\n result[${c*2+l}] = getChannel(\n getA(rc.x, d0, int(innerDims.x),\n int(innerDims.y)), innerDims);\n } else {\n innerDims = vec2(d0, d1);\n result[${c*2+l}] = getChannel(\n getA(rc.x, ch, int(innerDims.x),\n int(innerDims.y)), innerDims);\n }\n }\n }\n }\n `;this.userCode=`\n void main() {\n ivec3 rc = getOutputCoords();\n\n vec4 result = vec4(0);\n\n int blockIndex, pos, offsetY, d0, offsetX, d1, ch;\n vec2 innerDims;\n\n ${u}\n\n ${n.output} = result;\n }\n `}};function Bh(r,t){let e=r.length;return e>=3?t?[...r.slice(0,-3),r[e-3]*r[e-2],r[e-1]]:[...r.slice(0,-3),r[e-3],r[e-2]*r[e-1]]:!t&&e===1&&r[0]>1?[r[0],1]:null}function zh({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let p=r.shape,u=o.texData.get(r.dataId),c=e.inChannels,l=p[0]*p[1]*p[2],m=e.outChannels,d=e.dataFormat===\"channelsLast\",f=!1,h=!1,g,x=[];if(s!=null){let S=Bh(s.shape,d);S!=null&&(s=te({inputs:{x:s},backend:o,attrs:{shape:S}}),x.push(s))}if(n!=null){let S=Bh(n.shape,d);S!=null&&(n=te({inputs:{x:n},backend:o,attrs:{shape:S}}),x.push(n))}if(!((l===1||m===1)&&c>yv)&&u.isPacked&&d&&u.texture!=null&&p[2]%2!==0&&y.arraysEqual(u.shape.slice(-3),p.slice(-3))){let S=p[0]*p[1]*(p[2]+1),k={dataId:r.dataId,shape:[1,S,e.inChannels],dtype:r.dtype},_=u.shape;u.shape=u.shape.slice(),u.shape[u.shape.length-2]++,y.assert(Cu(u.shape,k.shape),()=>`packed reshape ${u.shape} to ${k.shape} isn't free`);let E=te({inputs:{x:t},backend:o,attrs:{shape:[1,e.inChannels,e.outChannels]}});x.push(E);let R=_p({a:k,b:E,backend:o,transposeA:f,transposeB:h,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a}),D=o.texData.get(R.dataId);y.assert(D.isPacked,()=>\"batchMatMul result is expected to be packed\"),u.shape=_,D.shape=e.outShape,g=At({inputs:{x:R},backend:o}),g.shape=e.outShape,x.push(R)}else{let S=e.outHeight*e.outWidth,k=te({inputs:{x:r},backend:o,attrs:{shape:d?[e.batchSize,S,e.inChannels]:[e.batchSize,e.inChannels,S]}}),_=te({inputs:{x:t},backend:o,attrs:{shape:[1,e.inChannels,e.outChannels]}}),E=_p({a:d?k:_,b:d?_:k,transposeA:!d,transposeB:h,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a});g=te({inputs:{x:E},backend:o,attrs:{shape:e.outShape}}),x.push(k),x.push(_),x.push(E)}for(let S of x)o.disposeIntermediateTensorInfo(S);return g}function Vh({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let{filterWidth:p,filterHeight:u,inChannels:c,outWidth:l,outHeight:m,dataFormat:d}=e,f=d===\"channelsLast\",h=p*u*c,g=m*l,x=[e.batchSize,h,g],b=!0,C=!1,S=[];if(s!=null){let q=Bh(s.shape,f);q!=null&&(s=te({inputs:{x:s},backend:o,attrs:{shape:q}}),S.push(s))}if(n!=null){let q=Bh(n.shape,f);q!=null&&(n=te({inputs:{x:n},backend:o,attrs:{shape:q}}),S.push(n))}let k=te({inputs:{x:t},backend:o,attrs:{shape:[1,h,y.sizeFromShape(t.shape)/h]}});S.push(k);let _=new Lh(x,e),E=[r.shape,[e.padInfo.top,e.padInfo.left],[e.strideHeight,e.strideWidth],[e.dilationHeight,e.dilationWidth],[e.inChannels],[e.filterWidth*e.inChannels],[e.outWidth]],R=o.runWebGLProgram(_,[r],\"float32\",E),D=te({inputs:{x:R},backend:o,attrs:{shape:x}});S.push(R),S.push(D);let P=n!=null,O=s!=null,M=i===\"leakyrelu\",L=i?Ci(i,!0):null,B=new Uc(f?D.shape:k.shape,f?k.shape:D.shape,f?[e.batchSize,g,e.outChannels]:[e.batchSize,e.outChannels,g],b,C,P,L,O,M),z=f?[D,k]:[k,D];if(n&&z.push(n),O&&z.push(s),M){let q=o.makeTensorInfo([],\"float32\",y.createScalarValue(a,\"float32\"));z.push(q),S.push(q)}let U=o.runWebGLProgram(B,z,\"float32\"),j=te({inputs:{x:U},backend:o,attrs:{shape:e.outShape}});S.push(U);for(let q of S)o.disposeIntermediateTensorInfo(q);return j}function J9(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,s.shape,a,u,i,c,!1,l),d;if(m.filterHeight===1&&m.filterWidth===1&&m.dilationHeight===1&&m.dilationWidth===1&&m.strideHeight===1&&m.strideWidth===1&&(m.padInfo.type===\"SAME\"||m.padInfo.type===\"VALID\"))d=zh({x:n,filter:s,convInfo:m,backend:e});else if(m.strideWidth<=2&&l===\"channelsLast\"&&A().getBool(\"WEBGL_EXP_CONV\")){let h=new Kc(m),g=[[m.padInfo.top,m.padInfo.left],[m.strideHeight,m.strideWidth],[m.dilationHeight,m.dilationWidth],[m.inHeight,m.inWidth]];d=e.runWebGLProgram(h,[n,s],\"float32\",g)}else if(A().getBool(\"WEBGL_CONV_IM2COL\"))d=Vh({x:n,filter:s,convInfo:m,backend:e});else{let h=new Hc(m);d=e.runWebGLProgram(h,[n,s],\"float32\")}let f=te({inputs:{x:d},backend:e,attrs:{shape:m.outShape}});return e.disposeIntermediateTensorInfo(d),f}var OA={kernelName:rn,backendName:\"webgl\",kernelFunc:J9};var Wh=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.outputShape=t.filterShape;let e=t.strideHeight,o=t.strideWidth,n=t.padInfo.top,s=t.padInfo.left,a=t.dataFormat===\"channelsLast\";this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int wR = coords.x;\n int wC = coords.y;\n int d1 = coords.z;\n int d2 = coords.w;\n\n // Convolve x(?, ?, d1) with dy(:, :, d2) to get dw(wR, wC, d1, d2).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n\n for (int b = 0; b < ${t.batchSize}; b++) {\n for (int yR = 0; yR < ${t.outHeight}; yR++) {\n int xR = wR + yR * ${e} - ${n};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int yC = 0; yC < ${t.outWidth}; yC++) {\n int xC = wC + yC * ${o} - ${s};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n ${a?`float dyValue = getDy(b, yR, yC, d2);\n float xValue = getX(b, xR, xC, d1);\n dotProd += (xValue * dyValue);`:`float dyValue = getDy(b, d2, yR, yC);\n float xValue = getX(b, d1, xR, xC);\n dotProd += (xValue * dyValue);`}\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Uh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.outputShape=t.inShape;let e=t.filterHeight,o=t.filterWidth,n=t.strideHeight,s=t.strideWidth,a=t.dataFormat===\"channelsLast\",i=e-1-t.padInfo.top,p=o-1-t.padInfo.left,u=a?1:2,c=a?2:3,l=a?3:1;this.userCode=`\n const ivec2 pads = ivec2(${i}, ${p});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d1 = coords[${l}];\n\n ivec2 dyCorner = ivec2(coords[${u}], coords[${c}]) - pads;\n int dyRCorner = dyCorner.x;\n int dyCCorner = dyCorner.y;\n\n // Convolve dy(?, ?, d2) with w(:, :, d1, d2) to compute dx(xR, xC, d1).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${e}; wR++) {\n float dyR = float(dyRCorner + wR) / ${n}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n int wRPerm = ${e} - 1 - wR;\n\n for (int wC = 0; wC < ${o}; wC++) {\n float dyC = float(dyCCorner + wC) / ${s}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n int wCPerm = ${o} - 1 - wC;\n\n for (int d2 = 0; d2 < ${t.outChannels}; d2++) {\n\n if (${a}) {\n float xValue = getDy(batch, idyR, idyC, d2);\n float wValue = getW(wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n } else {\n float xValue = getDy(batch, d2, idyR, idyC);\n float wValue = getW(wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n }\n\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Gh=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.outputShape=t.filterShape;let e=t.strideDepth,o=t.strideHeight,n=t.strideWidth,s=t.padInfo.front,a=t.padInfo.top,i=t.padInfo.left;this.userCode=`\n void main() {\n ivec5 coords = getOutputCoords();\n int wF = coords.x;\n int wR = coords.y;\n int wC = coords.z;\n int d1 = coords.w;\n int d2 = coords.u;\n\n float dotProd = 0.0;\n\n for (int b = 0; b < ${t.batchSize}; b++) {\n for (int yF = 0; yF < ${t.outDepth}; yF++) {\n int xF = wF + yF * ${e} - ${s};\n\n if (xF < 0 || xF >= ${t.inDepth}) {\n continue;\n }\n\n for (int yR = 0; yR < ${t.outHeight}; yR++) {\n int xR = wR + yR * ${o} - ${a};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int yC = 0; yC < ${t.outWidth}; yC++) {\n int xC = wC + yC * ${n} - ${i};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float dyValue = getDy(b, yF, yR, yC, d2);\n float xValue = getX(b, xF, xR, xC, d1);\n dotProd += (xValue * dyValue);\n }\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Hh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.outputShape=t.inShape;let e=t.filterDepth,o=t.filterHeight,n=t.filterWidth,s=t.strideDepth,a=t.strideHeight,i=t.strideWidth,p=e-1-t.padInfo.front,u=o-1-t.padInfo.top,c=n-1-t.padInfo.left;this.userCode=`\n const ivec3 pads = ivec3(${p}, ${u}, ${c});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int d1 = coords.u;\n\n\n ivec3 dyCorner = ivec3(coords.y, coords.z, coords.w) - pads;\n int dyFCorner = dyCorner.x;\n int dyRCorner = dyCorner.y;\n int dyCCorner = dyCorner.z;\n\n float dotProd = 0.0;\n for (int wF = 0; wF < ${e}; wF++) {\n float dyF = float(dyFCorner + wF) / ${s}.0;\n\n if (dyF < 0.0 || dyF >= ${t.outDepth}.0 || fract(dyF) > 0.0) {\n continue;\n }\n int idyF = int(dyF);\n\n int wFPerm = ${e} - 1 - wF;\n\n for (int wR = 0; wR < ${o}; wR++) {\n float dyR = float(dyRCorner + wR) / ${a}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 ||\n fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n int wRPerm = ${o} - 1 - wR;\n\n for (int wC = 0; wC < ${n}; wC++) {\n float dyC = float(dyCCorner + wC) / ${i}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n int wCPerm = ${n} - 1 - wC;\n\n for (int d2 = 0; d2 < ${t.outChannels}; d2++) {\n float xValue = getDy(batch, idyF, idyR, idyC, d2);\n float wValue = getW(wFPerm, wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n }\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function eJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,dataFormat:p,dimRoundingMode:u,filterShape:c}=o,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,c,a,1,i,u,!1,l),d=new Wh(m);return e.runWebGLProgram(d,[n,s],\"float32\")}var MA={kernelName:Oi,backendName:\"webgl\",kernelFunc:eJ};var Kh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"strides\",type:\"vec2\"}],this.outputShape=t.inShape,this.enableShapeUniforms=pt(this.outputShape.length);let e=t.filterHeight,o=t.filterWidth,n=e-1-t.padInfo.top,s=o-1-t.padInfo.left;this.userCode=`\n const ivec2 pads = ivec2(${n}, ${s});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d1 = coords[3];\n\n ivec2 dyCorner = ivec2(coords[1], coords[2]) - pads;\n int dyRCorner = dyCorner.x;\n int dyCCorner = dyCorner.y;\n\n vec4 result = vec4(0.);\n for (int wR = 0; wR < ${e}; wR++) {\n float dyR = float(dyRCorner + wR) / strides[0];\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n int wRPerm = ${e} - 1 - wR;\n\n for (int wC = 0; wC < ${o}; wC++) {\n int wCPerm = ${o} - 1 - wC;\n\n float dyC = float(dyCCorner + wC) / strides[1];\n bool idyCVal = (dyC >= 0.0) && (dyC < ${t.outWidth}.0)\n && (fract(dyC) == 0.0);\n int idyC = int(dyC);\n\n float dyC2 = float(dyCCorner + wC + 1) / strides[1];\n bool idyCVal2 = (dyC2 >= 0.0) && (dyC2 < ${t.outWidth}.0)\n && (fract(dyC2) == 0.0);\n int idyC2 = int(dyC2);\n\n if (idyCVal && idyCVal2) {\n for (int d2 = 0; d2 < ${t.outChannels}; d2 += 2) {\n vec4 wValue = getW(wRPerm, wCPerm, d1, d2);\n vec4 dySample = getDy(batch, idyR, idyC, d2);\n vec4 dySample2 = (idyC / 2 == idyC2 / 2) ?\n dySample : getDy(batch, idyR, idyC2, d2);\n\n vec2 dyValue = mod(float(idyC), 2.) == 0. ?\n dySample.xy : dySample.zw;\n result.xy += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n\n dyValue = mod(float(idyC2), 2.) == 0. ?\n dySample2.xy : dySample2.zw;\n result.zw += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n }\n } else if (idyCVal) {\n for (int d2 = 0; d2 < ${t.outChannels}; d2 += 2) {\n vec4 wValue = getW(wRPerm, wCPerm, d1, d2);\n vec4 dySample = getDy(batch, idyR, idyC, d2);\n vec2 dyValue = mod(float(idyC), 2.) == 0. ?\n dySample.xy : dySample.zw;\n result.xy += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n }\n } else if (idyCVal2) {\n for (int d2 = 0; d2 < ${t.outChannels}; d2 += 2) {\n vec4 wValue = getW(wRPerm, wCPerm, d1, d2);\n vec4 dySample = getDy(batch, idyR, idyC2, d2);\n vec2 dyValue = mod(float(idyC2), 2.) == 0. ?\n dySample.xy : dySample.zw;\n result.zw += vec2(dot(dyValue, wValue.xy),\n dot(dyValue, wValue.zw));\n }\n }\n }\n }\n setOutput(result);\n }\n `}};function tJ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{inputShape:a,strides:i,pad:p,dataFormat:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(u),m=w.computeConv2DInfo(a,s.shape,i,1,p,c,!1,l);if(A().getBool(\"WEBGL_PACK_CONV2DTRANSPOSE\")&&l===\"channelsLast\"){let d=[[m.strideHeight,m.strideWidth]],f=new Kh(m);return e.runWebGLProgram(f,[n,s],\"float32\",d)}else{let d=new Uh(m);return e.runWebGLProgram(d,[n,s],\"float32\")}}var LA={kernelName:on,backendName:\"webgl\",kernelFunc:tJ};function rJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeConv3DInfo(n.shape,s.shape,a,p,i),c=new Mh(u);return e.runWebGLProgram(c,[n,s],\"float32\")}var BA={kernelName:nn,backendName:\"webgl\",kernelFunc:rJ};function oJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,filterShape:p}=o,u=w.computeConv3DInfo(n.shape,p,a,1,i),c=new Gh(u);return e.runWebGLProgram(c,[n,s],\"float32\")}var zA={kernelName:Xa,backendName:\"webgl\",kernelFunc:oJ};function nJ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{pad:a,strides:i,inputShape:p}=o,u=w.computeConv3DInfo(p,s.shape,i,1,a),c=new Hh(u);return e.runWebGLProgram(c,[n,s],\"float32\")}var VA={kernelName:sn,backendName:\"webgl\",kernelFunc:nJ};var sJ=Po+`\n return cos(x);\n`,aJ=`\n vec4 result = cos(x);\n bvec4 isNaN = isnan(x);\n ${Xr}\n return result;\n`,iJ=xe({opSnippet:sJ,packedOpSnippet:aJ}),WA={kernelName:an,backendName:\"webgl\",kernelFunc:iJ};var uJ=`\n float e2x = exp(-x);\n return (e2x + 1.0 / e2x) / 2.0;\n`,pJ=xe({opSnippet:uJ}),UA={kernelName:un,backendName:\"webgl\",kernelFunc:pJ};var qh=class{constructor(t,e,o,n,s){this.variableNames=[\"Image\",\"Boxes\",\"BoxInd\"],this.outputShape=[];let[a,i,p,u]=t,[c]=e,[l,m]=o;this.outputShape=[c,l,m,u];let d=n===\"bilinear\"?1:0,[f,h]=[`${i-1}.0`,`${p-1}.0`],[g,x,b]=l>1?[`${(i-1)/(l-1)}`,\"(y2-y1) * height_ratio\",`y1*${f} + float(y)*(height_scale)`]:[\"0.0\",\"0.0\",`0.5 * (y1+y2) * ${f}`],[C,S,k]=m>1?[`${(p-1)/(m-1)}`,\"(x2-x1) * width_ratio\",`x1*${h} + float(x)*(width_scale)`]:[\"0.0\",\"0.0\",`0.5 * (x1+x2) * ${h}`];this.userCode=`\n const float height_ratio = float(${g});\n const float width_ratio = float(${C});\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int y = coords[1];\n int x = coords[2];\n int d = coords[3];\n\n // get box vals\n float y1 = getBoxes(b,0);\n float x1 = getBoxes(b,1);\n float y2 = getBoxes(b,2);\n float x2 = getBoxes(b,3);\n\n // get image in batch index\n int bInd = round(getBoxInd(b));\n if(bInd < 0 || bInd >= ${a}) {\n return;\n }\n\n float height_scale = ${x};\n float width_scale = ${S};\n\n float in_y = ${b};\n if( in_y < 0.0 || in_y > ${f} ) {\n setOutput(float(${s}));\n return;\n }\n float in_x = ${k};\n if( in_x < 0.0 || in_x > ${h} ) {\n setOutput(float(${s}));\n return;\n }\n\n vec2 sourceFracIndexCR = vec2(in_x,in_y);\n if(${d} == 1) {\n // Compute the four integer indices.\n ivec2 sourceFloorCR = ivec2(sourceFracIndexCR);\n ivec2 sourceCeilCR = ivec2(ceil(sourceFracIndexCR));\n\n float topLeft = getImage(b, sourceFloorCR.y, sourceFloorCR.x, d);\n float bottomLeft = getImage(b, sourceCeilCR.y, sourceFloorCR.x, d);\n float topRight = getImage(b, sourceFloorCR.y, sourceCeilCR.x, d);\n float bottomRight = getImage(b, sourceCeilCR.y, sourceCeilCR.x, d);\n\n vec2 fracCR = sourceFracIndexCR - vec2(sourceFloorCR);\n\n float top = topLeft + (topRight - topLeft) * fracCR.x;\n float bottom = bottomLeft + (bottomRight - bottomLeft) * fracCR.x;\n float newValue = top + (bottom - top) * fracCR.y;\n setOutput(newValue);\n } else {\n // Compute the coordinators of nearest neighbor point.\n ivec2 sourceNearestCR = ivec2(floor(\n sourceFracIndexCR + vec2(0.5,0.5)));\n float newValue = getImage(b, sourceNearestCR.y, sourceNearestCR.x, d);\n setOutput(newValue);\n }\n }\n `}};var cJ=r=>{let{inputs:t,backend:e,attrs:o}=r,{image:n,boxes:s,boxInd:a}=t,{cropSize:i,method:p,extrapolationValue:u}=o,c=new qh(n.shape,s.shape,i,p,u);return e.runWebGLProgram(c,[n,s,a],\"float32\")},GA={kernelName:ln,backendName:\"webgl\",kernelFunc:cJ};var Ep;(function(r){r.Prod=\"*\",r.Sum=\"+\"})(Ep||(Ep={}));var om=class{constructor(t,e,o,n){this.op=t,this.outputShape=e,this.variableNames=[\"x\"],this.customUniforms=[{name:\"index\",type:\"float\"}];let s=this.outputShape.length,a=this.op===Ep.Prod?\"1.0\":\"0.0\",i=o?a:`getX(${HA(s,\"coords\",this.op)})`,p=this.outputShape[this.outputShape.length-1],u=\"\",c=\"\";o?(u=n?`end != ${p-1}`:\"end != 0\",c=n?\"end + 1\":\"end - 1\"):(u=n?`end + pow2 < ${p}`:\"end >= pow2\",c=n?\"end + pow2\":\"end - pow2\"),this.userCode=`\n void main() {\n ${Re(s)} coords = getOutputCoords();\n int end = ${KA(s,\"coords\",this.op)};\n float val = ${i};\n int pow2 = int(pow(2.0, index));\n if (${u}) {\n int idx = ${c};\n ${KA(s,\"coords\",this.op)} = idx;\n val ${this.op}= getX(${HA(s,\"coords\",this.op)});\n }\n setOutput(val);\n }\n `}};function HA(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.x, ${t}.y`;if(r===3)return`${t}.x, ${t}.y, ${t}.z`;if(r===4)return`${t}.x, ${t}.y, ${t}.z, ${t}.w`;throw new Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function KA(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.y`;if(r===3)return`${t}.z`;if(r===4)return`${t}.w`;throw new Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function jh(r,t,e,o,n,s){let a=t.shape.length,i=w.getAxesPermutation([o],a),p=t;i!=null&&(p=Ct({inputs:{x:t},backend:e,attrs:{perm:i}}));let u=w.getInnerMostAxes(1,a)[0];if(u!==a-1)throw new Error(`WebGL cumprod shader expects an inner-most axis=${t.shape.length-1} but got axis=${o}`);let c=p.shape[u],l=At({inputs:{x:p},backend:e});for(let m=0;m<=Math.ceil(Math.log2(c))-1;m++){let d=new om(r,p.shape,!1,s),f=[[m]],h=l;l=e.runWebGLProgram(d,[l],l.dtype,f),e.disposeIntermediateTensorInfo(h)}if(n){let m=new om(r,p.shape,n,s),d=l;l=e.runWebGLProgram(m,[l],l.dtype),e.disposeIntermediateTensorInfo(d)}if(i!=null){let m=w.getUndoAxesPermutation(i),d=Ct({inputs:{x:l},backend:e,attrs:{perm:m}});return e.disposeIntermediateTensorInfo(l),e.disposeIntermediateTensorInfo(p),d}return l}function lJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return jh(Ep.Prod,n,e,s,a,i)}var qA={kernelName:pn,backendName:\"webgl\",kernelFunc:lJ};function mJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return jh(Ep.Sum,n,e,s,a,i)}var jA={kernelName:cn,backendName:\"webgl\",kernelFunc:mJ};function dJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a,binaryOutput:i}=o;if(n.shape.length===1){let p=e.readSync(n.dataId),u=e.readSync(s.dataId),c=ph(p,u,s.dtype,s.shape,a);return e.makeTensorInfo([a],s.dtype,c)}else if(n.shape.length===2){let p=e.bufferSync(n),u=e.bufferSync(s),c=DR(p,u,a,i);return e.makeTensorInfo(c.shape,s.dtype,c.values)}throw new Error(`Error in denseBincount: input must be at most rank 2, but got rank${n.shape.length}.`)}var XA={kernelName:ra,backendName:\"webgl\",kernelFunc:dJ};var Xh=class{constructor(t,e,o){this.variableNames=[\"x\"],this.outputShape=[],this.outputShape=t,this.blockSize=e,this.dataFormat=o,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int h = ${this.getHeightCoordString()};\n int w = ${this.getWidthCoordString()};\n int d = ${this.getDepthCoordString()};\n\n int in_h = h / ${e};\n int offset_h = imod(h, ${e});\n int in_w = w / ${e};\n int offset_w = imod(w, ${e});\n int offset_d = (offset_h * ${e} + offset_w) *\n ${this.getOutputDepthSize()};\n int in_d = d + offset_d;\n\n float result = ${this.getInputSamplingString()};\n setOutput(result);\n }\n `}getHeightCoordString(){return this.dataFormat===\"NHWC\"?\"coords[1]\":\"coords[2]\"}getWidthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[2]\":\"coords[3]\"}getDepthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[3]\":\"coords[1]\"}getOutputDepthSize(){return this.dataFormat===\"NHWC\"?this.outputShape[3]:this.outputShape[1]}getInputSamplingString(){return this.dataFormat===\"NHWC\"?\"getX(b, in_h, in_w, in_d)\":\"getX(b, in_d, in_h, in_w)\"}};function fJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockSize:s,dataFormat:a}=o,i=n.shape[0],p=a===\"NHWC\"?n.shape[1]:n.shape[2],u=a===\"NHWC\"?n.shape[2]:n.shape[3],c=a===\"NHWC\"?n.shape[3]:n.shape[1],l=p*s,m=u*s,d=c/(s*s),f=a===\"NHWC\"?[i,l,m,d]:[i,d,l,m],h=new Xh(f,s,a);return e.runWebGLProgram(h,[n],n.dtype)}var YA={kernelName:mn,backendName:\"webgl\",kernelFunc:fJ};var qc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.customUniforms=[{name:\"pads\",type:\"ivec2\"},{name:\"strides\",type:\"ivec2\"},{name:\"dilations\",type:\"ivec2\"},{name:\"inDims\",type:\"ivec2\"}],this.outputShape=t.outShape,this.enableShapeUniforms=pt(this.outputShape.length);let a=t.filterHeight,i=t.filterWidth,p=t.outChannels/t.inChannels,u=\"\",c=\"\";o&&(n?u=`float activation(float a) {\n float b = getPreluActivationWeightsAtOutCoords();\n ${o}\n }`:s?u=`float activation(float a) {\n float b = getLeakyreluAlphaAtOutCoords();\n ${o}\n }`:u=`\n float activation(float x) {\n ${o}\n }\n `,c=\"result = activation(result);\");let l=e?\"result += getBiasAtOutCoords();\":\"\";e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),s&&this.variableNames.push(\"leakyreluAlpha\"),this.userCode=`\n ${u}\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords.x;\n ivec2 xRCCorner = coords.yz * strides - pads;\n int d2 = coords.w;\n int d1 = d2 / ${p};\n int q = d2 - d1 * ${p};\n\n int xRCorner = xRCCorner.x;\n int xCCorner = xRCCorner.y;\n\n // Convolve x(?, ?, d1) with w(:, :, d1, q) to get y(yR, yC, d2).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n // TO DO(dsmilkov): Flatten the two for loops and vec4 the operations.\n for (int wR = 0; wR < ${a}; wR++) {\n int xR = xRCorner + wR * dilations[0];\n\n if (xR < 0 || xR >= inDims[0]) {\n continue;\n }\n\n for (int wC = 0; wC < ${i}; wC++) {\n int xC = xCCorner + wC * dilations[1];\n\n if (xC < 0 || xC >= inDims[1]) {\n continue;\n }\n\n float xVal = getX(batch, xR, xC, d1);\n float wVal = getW(wR, wC, d1, q);\n dotProd += xVal * wVal;\n }\n }\n\n float result = dotProd;\n ${l}\n ${c}\n setOutput(result);\n }\n `}};var jc=class{constructor(t,e=!1,o=null,n=!1,s=!1){this.variableNames=[\"x\",\"W\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"pads\",type:\"ivec2\"},{name:\"strides\",type:\"ivec2\"},{name:\"dilations\",type:\"ivec2\"},{name:\"inDims\",type:\"ivec2\"}],this.outputShape=t.outShape,this.enableShapeUniforms=pt(this.outputShape.length);let a=t.outChannels/t.inChannels,i=t.padInfo.left,p=t.strideWidth,u=t.dilationWidth,c=t.filterHeight,l=t.filterWidth,m=l,d=`\n int xR; int xC; int xCOffset;\n vec4 wTexel; vec4 previous; vec4 final;`;for(let x=0;x=0 && xR < inDims[0]) {\n `;for(let x=0;x<(m+1)/2;x++){let b=x*2;if(d+=`\n xC = xCCorner + ${b*u};\n `,p===1){if(b= 0 && xCOffset < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n `,u===1&&b>0?d+=`\n xC${b} = vec4(xTexelC${b-2}.zw, xTexelC${b}.xy);\n `:d+=`\n xCOffset = xC + 1 - 2;\n\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n previous.zw = vec2(0.0);\n }\n\n xC${b} = vec4(previous.zw, xTexelC${b}.xy);\n } else {\n xC${b} = vec4(0.0, 0.0, xTexelC${b}.xy);\n }\n `):d+=`\n if (xC >= 0 && xC < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n\n xC${b} = xTexelC${b};\n `,b+1= 0 && xCOffset < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xCOffset, d1);\n\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.0);\n }\n xTexelC${b+1}Ready = 1;\n }\n `,u>1?d+=`\n xCOffset -= 2;\n if (xCOffset >= 0 && xCOffset < inDims[1]) {\n previous = getX(batch, xR, xCOffset, d1);\n xC${b+1} = vec4(previous.zw, xTexelC${b+1}.xy);\n } else {\n xC${b+1} = vec4(0.0, 0.0, xTexelC${b+1}.xy);\n }\n `:d+=`\n xC${b+1} = vec4(xTexelC${b}.zw, xTexelC${b+1}.xy);\n `):C===1?d+=`\n xC${b+1} = xTexelC${b};\n `:d+=`\n xCOffset = xC + ${C};\n\n if (xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.0);\n }\n xTexelC${b+1}Ready = 1;\n }\n\n xC${b+1} = xTexelC${b+1};\n `}}else b= 0 && xCOffset < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xCOffset, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n\n if(xC + 1 >= 0 && xC + 1 < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xC + 1, d1);\n // Need to manually clear unused channels in case\n // we're reading from recycled texture.\n if (xC + 2 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.0);\n }\n xTexelC${b+1}Ready = 1;\n }\n\n xC${b} = vec4(xTexelC${b}.zw, xTexelC${b+1}.zw);\n `,b+1= 0 && xCOffset < inDims[1]) {\n final = getX(batch, xR, xCOffset, d1);\n }\n xC${b+1} = vec4(xTexelC${b+1}.xy, final.xy);\n `)):(d+=`\n if(xC >= 0 && xC < inDims[1] && xTexelC${b}Ready == 0) {\n xTexelC${b} = getX(batch, xR, xC, d1);\n if (xC + 1 >= inDims[1]) {\n xTexelC${b}.zw = vec2(0.0);\n }\n xTexelC${b}Ready = 1;\n }\n\n xCOffset = xC + strides[1];\n if(xCOffset >= 0 && xCOffset < inDims[1] && xTexelC${b+1}Ready == 0) {\n xTexelC${b+1} = getX(batch, xR, xCOffset, d1);\n if (xCOffset + 1 >= inDims[1]) {\n xTexelC${b+1}.zw = vec2(0.);\n }\n xTexelC${b+1}Ready = 1;\n }\n\n xC${b} = vec4(\n xTexelC${b}.xy, xTexelC${b+1}.xy);\n `,b+1`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${a} and dilations '${c}'`);let l=w.computeConv2DInfo(n.shape,s.shape,a,c,i,u,!0),m;A().getBool(\"WEBGL_PACK_DEPTHWISECONV\")&&l.strideWidth<=2&&l.outChannels/l.inChannels===1?m=new jc(l):m=new qc(l);let d=[[l.padInfo.top,l.padInfo.left],[l.strideHeight,l.strideWidth],[l.dilationHeight,l.dilationWidth],[l.inHeight,l.inWidth]];return e.runWebGLProgram(m,[n,s],\"float32\",d)}var QA={kernelName:dn,backendName:\"webgl\",kernelFunc:hJ};var Yh=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.outputShape=t.filterShape;let e=t.strideHeight,o=t.strideWidth,n=t.padInfo.top,s=t.padInfo.left,a=t.outChannels/t.inChannels;this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int wR = coords.x;\n int wC = coords.y;\n int d1 = coords.z;\n int dm = coords.w;\n int d2 = d1 * ${a} + dm;\n\n float dotProd = 0.0;\n\n // TO DO: Vec4 over the batch size\n for (int b = 0; b < ${t.batchSize}; b++) {\n for (int yR = 0; yR < ${t.outHeight}; yR++) {\n int xR = wR + yR * ${e} - ${n};\n\n if (xR < 0 || xR >= ${t.inHeight}) {\n continue;\n }\n\n for (int yC = 0; yC < ${t.outWidth}; yC++) {\n int xC = wC + yC * ${o} - ${s};\n\n if (xC < 0 || xC >= ${t.inWidth}) {\n continue;\n }\n\n float dyValue = getDy(b, yR, yC, d2);\n float xValue = getX(b, xR, xC, d1);\n dotProd += (xValue * dyValue);\n }\n }\n }\n setOutput(dotProd);\n }\n `}},Qh=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.outputShape=t.inShape;let e=t.filterHeight,o=t.filterWidth,n=t.strideHeight,s=t.strideWidth,a=e-1-t.padInfo.top,i=o-1-t.padInfo.left,p=t.outChannels/t.inChannels;this.userCode=`\n const ivec2 pads = ivec2(${a}, ${i});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords[0];\n int d1 = coords[3];\n ivec2 dyCorner = coords.yz - pads;\n int dyRCorner = dyCorner.x;\n int dyCCorner = dyCorner.y;\n\n float dotProd = 0.0;\n\n for (int wR = 0; wR < ${e}; wR++) {\n float dyR = float(dyRCorner + wR) / ${n}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n int wRPerm = ${e} - 1 - wR;\n\n for (int wC = 0; wC < ${o}; wC++) {\n float dyC = float(dyCCorner + wC) / ${s}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n int wCPerm = ${o} - 1 - wC;\n\n // TO DO: Vec4 over the channelMul\n for (int dm = 0; dm < ${p}; dm++) {\n int d2 = d1 * ${p} + dm;\n float xValue = getDy(batch, idyR, idyC, d2);\n float wValue = getW(wRPerm, wCPerm, d1, dm);\n dotProd += xValue * wValue;\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function gJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,filterShape:c}=o,l=w.computeConv2DInfo(n.shape,c,a,i,p,u,!0),m=new Yh(l);return e.runWebGLProgram(m,[n,s],\"float32\")}var ZA={kernelName:Mi,backendName:\"webgl\",kernelFunc:gJ};function xJ(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,inputShape:c}=o,l=w.computeConv2DInfo(c,s.shape,a,i,p,u,!0),m=new Qh(l);return e.runWebGLProgram(m,[n,s],\"float32\")}var JA={kernelName:Li,backendName:\"webgl\",kernelFunc:xJ};var Zh=class{constructor(t){this.variableNames=[\"X\"],this.outputShape=[t,t],this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n float val = coords[0] == coords[1] ? getX(coords[0]) : 0.0;\n setOutput(val);\n }\n `}};function yJ(r){let{inputs:t,backend:e}=r,{x:o}=t,n=[...o.shape,...o.shape],s=y.sizeFromShape(o.shape),a=te({inputs:{x:o},backend:e,attrs:{shape:[s]}}),i=new Zh(s),p=e.runWebGLProgram(i,[a],a.dtype),u=te({inputs:{x:p},backend:e,attrs:{shape:n}});return e.disposeIntermediateTensorInfo(a),e.disposeIntermediateTensorInfo(p),u}var eF={kernelName:oa,backendName:\"webgl\",kernelFunc:yJ};var Jh=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.outputShape=t.outShape;let{inHeight:e,inWidth:o,padInfo:n,strideHeight:s,strideWidth:a,filterHeight:i,filterWidth:p,dilationHeight:u,dilationWidth:c}=t,{top:l,left:m}=n;this.userCode=`\n const ivec2 strides = ivec2(${s}, ${a});\n const ivec2 pads = ivec2(${l}, ${m});\n const float neg_infinity = -3.4e38;\n\n void main() {\n ivec4 coords = getOutputCoords();\n int batch = coords.x;\n int d1 = coords.w;\n ivec2 outTopLeftCorner =\n coords.yz * strides - pads;\n int hBeg = outTopLeftCorner.x;\n int wBeg = outTopLeftCorner.y;\n\n float curVal = neg_infinity;\n for (int h = 0; h < ${i}; h++) {\n int hIn = hBeg + h * ${u};\n\n if (hIn >= 0 && hIn < ${e}) {\n for (int w = 0; w < ${p}; w++) {\n int wIn = wBeg + w * ${c};\n\n if (wIn >= 0 && wIn < ${o}) {\n float xVal = getX(batch, hIn, wIn, d1);\n float wVal = getW(h, w, d1);\n\n float val = xVal + wVal;\n if (val > curVal) {\n curVal = val;\n }\n }\n }\n }\n }\n\n float result = curVal;\n setOutput(result);\n }\n `}};function bJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeDilation2DInfo(n.shape,s.shape,a,i,\"NHWC\",p),c,l=new Jh(u);c=e.runWebGLProgram(l,[n,s],\"float32\");let m=te({inputs:{x:c},backend:e,attrs:{shape:u.outShape}});return e.disposeIntermediateTensorInfo(c),m}var tF={kernelName:fn,backendName:\"webgl\",kernelFunc:bJ};function CJ(r){let{inputs:t,backend:e,attrs:o}=r,{equation:n}=o,s=t,{allDims:a,summedDims:i,idDims:p}=w.decodeEinsumEquation(n,s.length);w.checkEinsumDimSizes(a.length,p,s);let{path:u,steps:c}=w.getEinsumComputePath(i,p),l=c.length,m=null,d=a.length,f=[];for(let h=0;h=0&&(m=Tp({inputs:{x:m},backend:e,attrs:{axis:u[h]-(a.length-d),keepDims:!1}}),f.push(m)),d--)}for(let h of f)h!==m&&e.disposeIntermediateTensorInfo(h);return m}var rF={kernelName:Vi,backendName:\"webgl\",kernelFunc:CJ};var wJ=\"return (x >= 0.0) ? x : (exp(x) - 1.0);\",SJ=`\n vec4 result;\n\n result.r = (x.r >= 0.0) ? x.r : (exp(x.r) - 1.0);\n result.g = (x.g >= 0.0) ? x.g : (exp(x.g) - 1.0);\n result.b = (x.b >= 0.0) ? x.b : (exp(x.b) - 1.0);\n result.a = (x.a >= 0.0) ? x.a : (exp(x.a) - 1.0);\n\n return result;\n`,IJ=xe({opSnippet:wJ,packedOpSnippet:SJ}),oF={kernelName:gn,backendName:\"webgl\",kernelFunc:IJ};var vJ=\"return (b >= 0.0) ? a : a * (b + 1.0);\",kJ=`\n vec4 bGTEZero = vec4(greaterThanEqual(b, vec4(0.)));\n return (bGTEZero * a) + ((vec4(1.0) - bGTEZero) * (a * (b + vec4(1.0))));\n`,NJ=r=>{let{inputs:t,backend:e}=r,{dy:o,y:n}=t,s=A().getBool(\"WEBGL_PACK_BINARY_OPERATIONS\")?new jr(kJ,o.shape,n.shape):new Pr(vJ,o.shape,n.shape);return e.runWebGLProgram(s,[o,n],o.dtype)},nF={kernelName:Ya,backendName:\"webgl\",kernelFunc:NJ};var TJ=`\n return vec4(equal(a, b));\n`,_J=\"return float(a == b);\",$J=nt({opSnippet:_J,packedOpSnippet:TJ,dtype:\"bool\",cpuKernelImpl:MR}),sF={kernelName:yn,backendName:\"webgl\",kernelFunc:$J};var EJ=`\n // Error function is calculated approximately with elementary function.\n // See \"Handbook of Mathematical Functions with Formulas,\n // Graphs, and Mathematical Tables\", Abramowitz and Stegun.\n float p = ${w.ERF_P};\n float a1 = ${w.ERF_A1};\n float a2 = ${w.ERF_A2};\n float a3 = ${w.ERF_A3};\n float a4 = ${w.ERF_A4};\n float a5 = ${w.ERF_A5};\n\n float sign = sign(x);\n x = abs(x);\n float t = 1.0 / (1.0 + p * x);\n return sign * (1.0 - (((((a5*t + a4)*t) + a3)*t + a2)*t + a1)*t*exp(-x*x));\n`,RJ=xe({opSnippet:EJ}),aF={kernelName:xn,backendName:\"webgl\",kernelFunc:RJ};var DJ=Po+`\n return exp(x);\n`,AJ=`\n vec4 result = exp(x);\n bvec4 isNaN = isnan(x);\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,Iv=xe({opSnippet:DJ,packedOpSnippet:AJ,cpuKernelImpl:LR,dtype:\"float32\"}),iF={kernelName:bn,backendName:\"webgl\",kernelFunc:Iv};function eg(r){let{inputs:t,attrs:e,backend:o}=r,{dim:n}=e,{input:s}=t,a=s.shape.length,i=s.shape.slice(),p=n;return n<0&&(y.assert(-(a+1)<=n,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+n+1),i.splice(p,0,1),te({inputs:{x:s},backend:o,attrs:{shape:i}})}var uF={kernelName:na,backendName:\"webgl\",kernelFunc:eg};var pF=\"return exp(x) - 1.0;\",FJ=xe({opSnippet:pF,packedOpSnippet:pF,cpuKernelImpl:BR}),cF={kernelName:Cn,backendName:\"webgl\",kernelFunc:FJ};var nm=class{constructor(t,e,o){this.variableNames=[\"real\",\"imag\"];let n=e[1];this.outputShape=e;let s=o?`2.0 * ${Math.PI}`:`-2.0 * ${Math.PI}`,a=o?`${n}.0`:\"1.0\",i;if(t===\"real\")i=\"return real * expR - imag * expI;\";else if(t===\"imag\")i=\"return real * expI + imag * expR;\";else throw new Error(`FFT component must be either \"real\" or \"imag\", got ${t}.`);this.userCode=`\n const float exponentMultiplier = ${s};\n\n float unaryOpComplex(float real, float expR, float imag, float expI) {\n ${i}\n }\n\n float mulMatDFT(int batch, int index) {\n float indexRatio = float(index) / float(${n});\n float exponentMultiplierTimesIndexRatio =\n exponentMultiplier * indexRatio;\n\n float result = 0.0;\n\n for (int i = 0; i < ${n}; i++) {\n // x = (-2|2 * PI / N) * index * i;\n float x = exponentMultiplierTimesIndexRatio * float(i);\n float expR = cos(x);\n float expI = sin(x);\n float real = getReal(batch, i);\n float imag = getImag(batch, i);\n\n result +=\n unaryOpComplex(real, expR, imag, expI) / ${a};\n }\n\n return result;\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n setOutput(mulMatDFT(coords[0], coords[1]));\n }\n `}};function tg(r,t,e){let o=e.texData.get(r.dataId),n=y.sizeFromShape(r.shape),s=r.shape[r.shape.length-1],a=n/s,i=te({inputs:{x:r},backend:e,attrs:{shape:[a,s]}}),p=i.shape,u=new nm(\"real\",p,t),c=new nm(\"imag\",p,t),l=[{dataId:o.complexTensorInfos.real.dataId,dtype:o.complexTensorInfos.real.dtype,shape:p},{dataId:o.complexTensorInfos.imag.dataId,dtype:o.complexTensorInfos.imag.dtype,shape:p}],m=e.runWebGLProgram(u,l,\"float32\"),d=e.runWebGLProgram(c,l,\"float32\"),f=Or({inputs:{real:m,imag:d},backend:e});e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d);let h=te({inputs:{x:f},backend:e,attrs:{shape:r.shape}});return e.disposeIntermediateTensorInfo(i),e.disposeIntermediateTensorInfo(f),h}function PJ(r){let{inputs:t,backend:e}=r,{input:o}=t;return tg(o,!1,e)}var lF={kernelName:Wi,backendName:\"webgl\",kernelFunc:PJ};var rg=class{constructor(t,e){this.outputShape=[],this.customUniforms=[{name:\"value\",type:\"float\"}],this.variableNames=[\"x\"],this.outputShape=t,this.userCode=`\n void main() {\n // Input can be obtained from uniform value.\n setOutput(value);\n }\n `}};function Si(r){let{backend:t,attrs:e}=r,{shape:o,value:n}=e,{dtype:s}=e;if(s=s||y.inferDtype(n),s===\"string\"){let a=y.getArrayFromDType(s,y.sizeFromShape(o));return a.fill(n),t.makeTensorInfo(o,s,a)}else{let a=new rg(o,n),i=[[n]];return t.runWebGLProgram(a,[],s,i)}}var mF={kernelName:sa,backendName:\"webgl\",kernelFunc:Si};var og=class{constructor(t){this.variableNames=[\"Image\"],this.outputShape=[];let e=t[2];this.outputShape=t,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int x = coords[2];\n\n int coordX = ${e} - x - 1;\n float outputValue;\n if(coordX >= 0 && coordX < ${e}) {\n outputValue = getImage(coords[0], coords[1], coordX, coords[3]);\n } else {\n outputValue = getImage(coords[0], coords[1], coords[2], coords[3]);\n }\n setOutput(outputValue);\n }\n `}};var dF={kernelName:wn,backendName:\"webgl\",kernelFunc:({inputs:r,backend:t})=>{let{image:e}=r,o=t,n=new og(e.shape);return o.runWebGLProgram(n,[e],e.dtype)}};var fF=\"return floor(x);\",OJ=xe({opSnippet:fF,packedOpSnippet:fF,cpuKernelImpl:zR}),hF={kernelName:Sn,backendName:\"webgl\",kernelFunc:OJ};var MJ=`\n float s = sign(a) * sign(b);\n int ia = round(a);\n int ib = round(b);\n if (ib != 0) {\n // Windows (D3D) wants guaranteed non-zero int division at compile-time.\n return float(idiv(ia, ib, s));\n } else {\n return NAN;\n }\n`,LJ=`\n ivec4 ia = round(a);\n ivec4 ib = round(b);\n bvec4 cond = notEqual(ib, ivec4(0));\n ivec4 result = ivec4(0);\n vec4 s = sign(a) * sign(b);\n\n // Windows (D3D) wants guaranteed non-zero int division at compile-time.\n if (cond[0]) {\n result[0] = idiv(ia[0], ib[0], s[0]);\n }\n if (cond[1]) {\n result[1] = idiv(ia[1], ib[1], s[1]);\n }\n if (cond[2]) {\n result[2] = idiv(ia[2], ib[2], s[2]);\n }\n if (cond[3]) {\n result[3] = idiv(ia[3], ib[3], s[3]);\n }\n return vec4(result);\n`,BJ=nt({opSnippet:MJ,packedOpSnippet:LJ,dtype:\"int32\"}),gF={kernelName:In,backendName:\"webgl\",kernelFunc:BJ};var ng=class{constructor(t){this.variableNames=[\"A\"];let e=vt(),[o,n]=t;this.outputShape=t,this.userCode=`\n void main() {\n ivec3 coords = getOutputCoords();\n int texR = coords[0];\n int texC = coords[1];\n int depth = coords[2];\n vec2 uv = (vec2(texC, texR) + halfCR) / vec2(${n}.0, ${o}.0);\n\n vec4 values = ${e.texture2D}(A, uv);\n float value;\n if (depth == 0) {\n value = values.r;\n } else if (depth == 1) {\n value = values.g;\n } else if (depth == 2) {\n value = values.b;\n } else if (depth == 3) {\n value = values.a;\n }\n\n setOutput(floor(value * 255.0 + 0.5));\n }\n `}};var sg=class{constructor(t){this.variableNames=[\"A\"],this.packedInputs=!1,this.packedOutput=!0;let e=vt(),[o,n]=t;this.outputShape=t,this.userCode=`\n void main() {\n ivec3 coords = getOutputCoords();\n int texR = coords[0];\n int texC = coords[1];\n int depth = coords[2];\n\n vec4 result = vec4(0.);\n\n for(int row=0; row<=1; row++) {\n for(int col=0; col<=1; col++) {\n texC = coords[1] + row;\n depth = coords[2] + col;\n\n vec2 uv = (vec2(texC, texR) + halfCR) /\n vec2(${n}.0, ${o}.0);\n vec4 values = ${e.texture2D}(A, uv);\n float value;\n if (depth == 0) {\n value = values.r;\n } else if (depth == 1) {\n value = values.g;\n } else if (depth == 2) {\n value = values.b;\n } else if (depth == 3) {\n value = values.a;\n }\n\n result[row * 2 + col] = floor(value * 255.0 + 0.5);\n }\n }\n\n ${e.output} = result;\n }\n `}};var xF={kernelName:Mu,backendName:\"webgl\",kernelFunc:zJ},Xc,vv=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");function zJ(r){let{inputs:t,backend:e,attrs:o}=r,{pixels:n}=t,{numChannels:s}=o,a=typeof HTMLVideoElement!=\"undefined\"&&n instanceof HTMLVideoElement,i=typeof HTMLImageElement!=\"undefined\"&&n instanceof HTMLImageElement,[p,u]=a?[n.videoWidth,n.videoHeight]:[n.width,n.height],c=[u,p],l=[u,p,s];if(i||a){let h=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");(Xc==null||h!==vv)&&(vv=h,Xc=document.createElement(\"canvas\").getContext(\"2d\",{willReadFrequently:vv})),Xc.canvas.width=p,Xc.canvas.height=u,Xc.drawImage(n,0,0,p,u),n=Xc.canvas}let m=e.makeTensorInfo(c,\"int32\");e.texData.get(m.dataId).usage=dr.PIXELS,e.gpgpu.uploadPixelDataToTexture(e.getTexture(m.dataId),n);let d=A().getBool(\"WEBGL_PACK\")?new sg(l):new ng(l),f=e.runWebGLProgram(d,[m],\"int32\");return e.disposeData(m.dataId),f}function VJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dataFormat:c,dilations:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=o,h=w.convertConv2DDataFormat(c),g=w.computeConv2DInfo(n.shape,s.shape,p,l,u,m,!1,h),x,b=[],C=a!=null,S=i!=null,k=d===\"leakyrelu\",_=()=>{let R=[n,s],D=(P,O)=>{if(O===\"NCHW\"&&P.shape.length===1&&P.shape[0]!==1){let M=te({inputs:{x:P},backend:e,attrs:{shape:[P.shape[0],1,1]}});return b.push(M),M}return P};if(C&&R.push(D(a,c)),S&&R.push(D(i,c)),k){let P=e.makeTensorInfo([],\"float32\",y.createScalarValue(f,\"float32\"));R.push(P),b.push(P)}return R};if(g.filterHeight===1&&g.filterWidth===1&&g.dilationHeight===1&&g.dilationWidth===1&&g.strideHeight===1&&g.strideWidth===1&&(g.padInfo.type===\"SAME\"||g.padInfo.type===\"VALID\"))x=zh({x:n,filter:s,convInfo:g,backend:e,bias:a,activation:d,preluActivationWeights:i,leakyreluAlpha:f});else if(g.strideWidth<=2&&h===\"channelsLast\"&&A().getBool(\"WEBGL_EXP_CONV\")){let R=d?Ci(d,!0):null,D=new Kc(g,C,R,S,k),P=[[g.padInfo.top,g.padInfo.left],[g.strideHeight,g.strideWidth],[g.dilationHeight,g.dilationWidth],[g.inHeight,g.inWidth]],O=_();x=e.runWebGLProgram(D,O,\"float32\",P)}else if(A().getBool(\"WEBGL_CONV_IM2COL\"))x=Vh({x:n,filter:s,convInfo:g,backend:e,bias:a,activation:d,preluActivationWeights:i,leakyreluAlpha:f});else{let R=d?Ci(d,!1):null,D=new Hc(g,C,R,S,k),P=_();x=e.runWebGLProgram(D,P,\"float32\")}let E=te({inputs:{x},backend:e,attrs:{shape:g.outShape}});return b.push(x),b.forEach(R=>e.disposeIntermediateTensorInfo(R)),E}var yF={kernelName:vo,backendName:\"webgl\",kernelFunc:VJ};function WJ(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dimRoundingMode:l,activation:m,leakyreluAlpha:d}=o,f=[],h=c;h==null&&(h=[1,1]),y.assert(w.eitherStridesOrDilationsAreOne(p,h),()=>`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${p} and dilations '${h}'`);let g=w.computeConv2DInfo(n.shape,s.shape,p,h,u,l,!0),x=A().getBool(\"WEBGL_PACK_DEPTHWISECONV\")&&g.strideWidth<=2&&g.outChannels/g.inChannels===1,b=m?Ci(m,x):null,C=[n,s],S=a!=null,k=i!=null,_=m===\"leakyrelu\";if(S&&C.push(a),k&&C.push(i),_){let P=e.makeTensorInfo([],\"float32\",y.createScalarValue(d,\"float32\"));C.push(P),f.push(P)}let E;x?E=new jc(g,S,b,k,_):E=new qc(g,S,b,k,_);let R=[[g.padInfo.top,g.padInfo.left],[g.strideHeight,g.strideWidth],[g.dilationHeight,g.dilationWidth],[g.inHeight,g.inWidth]],D=e.runWebGLProgram(E,C,\"float32\",R);return f.forEach(P=>e.disposeIntermediateTensorInfo(P)),D}var bF={kernelName:ko,backendName:\"webgl\",kernelFunc:WJ};var ag=class{constructor(t,e,o,n){this.sliceDim=t,this.strides=e,this.paramsShape=n,this.variableNames=[\"x\",\"indices\"],this.outputShape=o;let s=Re(o.length),a=`\n int index;`;for(let i=0;i= ${this.paramsShape[i]};\n flattenIndex += index * ${this.strides[i]};`;this.userCode=`\n void main() {\n ${s} coords = getOutputCoords();\n int flattenIndex = 0;\n bool out_of_bounds = false;\n\n ${a}\n\n setOutput(out_of_bounds ? 0.0 : getX(flattenIndex, coords[1]));\n }\n `}};function UJ(r){let{inputs:t,backend:e}=r,{params:o,indices:n}=t,s=n.shape,a=s[s.length-1],i=y.sizeFromShape(o.shape),[p,u,c,l]=w.prepareAndValidate(o,n),m=te({inputs:{x:n},backend:e,attrs:{shape:[u,a]}}),d=te({inputs:{x:o},backend:e,attrs:{shape:[y.sizeFromShape(o.shape)/c,c]}});if(e.shouldExecuteOnCPU([o,n])||o.dtype===\"string\"){let x=e.readSync(n.dataId),b=e.bufferSync(o),C=VR(x,b,o.dtype,u,a,c,l,o.shape,i);return e.makeTensorInfo(p,o.dtype,C.values)}let f=new ag(a,l,[u,c],o.shape),h=e.runWebGLProgram(f,[d,m],d.dtype),g=te({inputs:{x:h},backend:e,attrs:{shape:p}});return e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(h),g}var CF={kernelName:kn,backendName:\"webgl\",kernelFunc:UJ};var ig=class{constructor(t,e){this.variableNames=[\"A\",\"indices\"],this.outputShape=e,this.rank=e.length;let o=Re(this.rank),n=GJ(t,2);this.userCode=`\n void main() {\n ${o} resRC = getOutputCoords();\n int index = int(getIndices(resRC.x, resRC.z));\n float inBounds = (index >= 0) && (index < ${t[2]}) ? 1.0 : 0.0;\n setOutput(inBounds * getA(${n}));\n }\n `}};function GJ(r,t){let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],o=[];for(let n=0;n=0,()=>`GatherV2: the index value ${k} is not in [0, ${C-1}]`)}}let u=w.segment_util.collectGatherOpShapeInfo(n,s,p,i),c=y.sizeFromShape(s.shape),l=[],m=te({inputs:{x:n},backend:e,attrs:{shape:[u.batchSize,u.outerSize,u.dimSize,u.sliceSize]}}),d=te({inputs:{x:s},backend:e,attrs:{shape:[u.batchSize,c/u.batchSize]}});l.push(m),l.push(d);let f=[u.batchSize,u.outerSize,c/u.batchSize,u.sliceSize];if(e.shouldExecuteOnCPU([n,s])||n.dtype===\"string\"){let b=e.bufferSync(d),C=e.bufferSync(m),S=WR(C,b,f);return l.forEach(k=>e.disposeIntermediateTensorInfo(k)),e.makeTensorInfo(u.outputShape,S.dtype,S.values)}let h=new ig(m.shape,f),g=e.runWebGLProgram(h,[m,d],m.dtype);l.push(g);let x=te({inputs:{x:g},backend:e,attrs:{shape:u.outputShape}});return l.forEach(b=>e.disposeIntermediateTensorInfo(b)),x}var wF={kernelName:aa,backendName:\"webgl\",kernelFunc:kv};var HJ=\"return float(a > b);\",KJ=`\n return vec4(greaterThan(a, b));\n`,qJ=nt({opSnippet:HJ,packedOpSnippet:KJ,cpuKernelImpl:UR,dtype:\"bool\"}),SF={kernelName:Nn,backendName:\"webgl\",kernelFunc:qJ};var jJ=\"return float(a >= b);\",XJ=`\n return vec4(greaterThanEqual(a, b));\n`,YJ=nt({opSnippet:jJ,packedOpSnippet:XJ,dtype:\"bool\",cpuKernelImpl:GR}),IF={kernelName:Tn,backendName:\"webgl\",kernelFunc:YJ};function QJ(r){let{inputs:t,backend:e}=r,{input:o}=t;return tg(o,!0,e)}var vF={kernelName:Ui,backendName:\"webgl\",kernelFunc:QJ};var ZJ=\"return float(!isnan(x) && !isinf(x));\",JJ=xe({opSnippet:ZJ,dtype:\"bool\"}),kF={kernelName:_n,backendName:\"webgl\",kernelFunc:JJ};var eee=\"return float(isinf(x));\",tee=xe({opSnippet:eee,dtype:\"bool\"}),NF={kernelName:$n,backendName:\"webgl\",kernelFunc:tee};var ree=\"return float(isnan(x));\",oee=xe({opSnippet:ree,dtype:\"bool\"}),TF={kernelName:En,backendName:\"webgl\",kernelFunc:oee};var nee=\"return float(a < b);\",see=`\n return vec4(lessThan(a, b));\n`,aee=nt({opSnippet:nee,packedOpSnippet:see,cpuKernelImpl:HR,dtype:\"bool\"}),_F={kernelName:Dn,backendName:\"webgl\",kernelFunc:aee};var iee=\"return float(a <= b);\",uee=`\n return vec4(lessThanEqual(a, b));\n`,pee=nt({opSnippet:iee,packedOpSnippet:uee,cpuKernelImpl:KR,dtype:\"bool\"}),$F={kernelName:An,backendName:\"webgl\",kernelFunc:pee};function cee(r){let{backend:t,attrs:e}=r,{start:o,stop:n,num:s}=e,a=qR(o,n,s);return t.makeTensorInfo([a.length],\"float32\",a)}var EF={kernelName:Fn,backendName:\"webgl\",kernelFunc:cee};var lee=Po+`\n return x < 0.0 ? 0./0. : log(x);\n`,mee=`\n vec4 result = log(x);\n bvec4 isNaN = isnan(x);\n result.r = isNaN.r ? x.r : (x.r < 0.0 ? 0./0. : result.r);\n result.g = isNaN.g ? x.g : (x.g < 0.0 ? 0./0. : result.g);\n result.b = isNaN.b ? x.b : (x.b < 0.0 ? 0./0. : result.b);\n result.a = isNaN.a ? x.a : (x.a < 0.0 ? 0./0. : result.a);\n return result;\n`,dee=xe({opSnippet:lee,packedOpSnippet:mee,cpuKernelImpl:jR}),RF={kernelName:Pn,backendName:\"webgl\",kernelFunc:dee};var fee=Po+`\n return log(1.0 + x);\n`,hee=xe({opSnippet:fee}),DF={kernelName:On,backendName:\"webgl\",kernelFunc:hee};var gee=\"return float(a >= 1.0 && b >= 1.0);\",xee=`\n return vec4(\n vec4(greaterThanEqual(a, vec4(1.0))) *\n vec4(greaterThanEqual(b, vec4(1.0))));\n`,yee=nt({opSnippet:gee,packedOpSnippet:xee,dtype:\"bool\"}),AF={kernelName:Mn,backendName:\"webgl\",kernelFunc:yee};var bee=\"return float(!(x >= 1.0));\",Cee=xe({opSnippet:bee}),FF={kernelName:Ln,backendName:\"webgl\",kernelFunc:Cee};var wee=\"return float(a >= 1.0 || b >= 1.0);\",See=`\n return min(\n vec4(greaterThanEqual(a, vec4(1.0))) +\n vec4(greaterThanEqual(b, vec4(1.0))),\n vec4(1.0));\n`,Iee=nt({opSnippet:wee,packedOpSnippet:See,dtype:\"bool\"}),PF={kernelName:Bn,backendName:\"webgl\",kernelFunc:Iee};var ug=class{constructor(t,e,o,n,s){this.variableNames=[\"x\"],this.outputShape=[];let a=e,i=t[3]-1;this.outputShape=t;let p,u=`float(${o}) + float(${n}) * sum`;s===.5?p=`inversesqrt(${u})`:s===1?p=`1.0/(${u})`:p=`exp(log(${u}) * float(-${s}));`,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int r = coords[1];\n int c = coords[2];\n int d = coords[3];\n float x = getX(b, r, c, d);\n float sum = 0.0;\n for (int j = -${a}; j <= ${a}; j++) {\n int idx = d + j;\n if (idx >= 0 && idx <= ${i}) {\n float z = getX(b, r, c, idx);\n sum += z * z;\n }\n }\n float val = x * ${p};\n setOutput(val);\n }\n `}};var pg=class{constructor(t,e,o,n,s){this.variableNames=[\"x\"],this.outputShape=[],this.packedInputs=!0,this.packedOutput=!0;let a=e,i=t[3]-1;this.outputShape=t;let p,u=`float(${o}) + float(${n}) * sum`;s===.5?p=`inversesqrt(${u})`:s===1?p=`1.0/(${u})`:p=`exp(log(${u}) * float(-${s}));`,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords.x;\n int r = coords.y;\n int c = coords.z;\n int d = coords.w;\n\n bool hasNextCol = d < ${this.outputShape[3]};\n bool hasNextRow = c < ${this.outputShape[2]};\n\n vec4 sum = vec4(0.);\n vec4 xFragAtOutputCoords = getX(b, r, c, d);\n\n vec4 xAtOutputCoords = vec4(\n getChannel(xFragAtOutputCoords, vec2(c, d)),\n hasNextCol ?\n getChannel(xFragAtOutputCoords, vec2(c, d + 1)) : 0.0,\n hasNextRow ?\n getChannel(xFragAtOutputCoords , vec2(c + 1, d)) : 0.0,\n (hasNextRow && hasNextCol) ?\n getChannel(xFragAtOutputCoords, vec2(c + 1, d + 1)) : 0.0\n );\n\n int firstChannel = d - ${a};\n vec2 cache = vec2(0.);\n if(firstChannel >= 0){\n vec4 firstChannelFrag = getX(b, r, c, firstChannel);\n cache.x = getChannel(firstChannelFrag, vec2(c, firstChannel));\n if(hasNextRow){\n cache.y = getChannel(firstChannelFrag, vec2(c + 1, firstChannel));\n }\n }\n\n ivec2 depth = ivec2(d, d + 1);\n for (int j = - ${a}; j <= ${a}; j++) {\n ivec2 idx = depth + j;\n bvec2 aboveLowerBound = greaterThanEqual(idx, ivec2(0));\n bvec2 belowUpperBound = lessThanEqual(idx, ivec2(${i}));\n\n bool depthInRange = aboveLowerBound.x && belowUpperBound.x;\n bool depthPlusOneInRange = aboveLowerBound.y && belowUpperBound.y;\n\n if(depthInRange || depthPlusOneInRange){\n vec4 z = vec4(0.);\n vec4 xFragAtCurrentDepth;\n z.xz = cache.xy;\n if(depthPlusOneInRange && hasNextCol){\n xFragAtCurrentDepth = idx.y != d ?\n getX(b, r, c, idx.y) : xFragAtOutputCoords;\n z.y = getChannel(xFragAtCurrentDepth, vec2(c, idx.y));\n if(hasNextRow){\n z.w = getChannel(xFragAtCurrentDepth, vec2(c + 1, idx.y));\n }\n }\n cache.xy = z.yw;\n sum += z * z;\n }\n }\n vec4 result = xAtOutputCoords * ${p};\n setOutput(result);\n }\n `}};var vee=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o,u=A().getBool(\"WEBGL_PACK_NORMALIZATION\")?new pg(n.shape,s,a,i,p):new ug(n.shape,s,a,i,p);return e.runWebGLProgram(u,[n],n.dtype)},OF={kernelName:zn,backendName:\"webgl\",kernelFunc:vee};var cg=class{constructor(t,e,o,n,s){this.variableNames=[\"inputImage\",\"outputImage\",\"dy\"],this.outputShape=[],this.outputShape=t,this.depth=t[3],this.depthRadius=e,this.bias=o,this.alpha=n,this.beta=s,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int r = coords[1];\n int c = coords[2];\n\n float result = 0.0;\n for (int d = 0; d < ${this.depth}; ++d) {\n int depthBegin = int(max(0.0, float(d - ${e})));\n int depthEnd = int(min(float(${this.depth}),\n float(d + ${e} + 1)));\n\n const int MIN_DEPTH_BEGIN = 0;\n const int MAX_DEPTH_END = ${this.depth};\n\n float norm = 0.0;\n for (int k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; ++k) {\n if (k < depthBegin){\n continue;\n }\n else if (k >= depthBegin && k < depthEnd) {\n norm += getInputImage(b, r, c, k) * getInputImage(b, r, c, k);\n }\n else {\n break;\n }\n }\n\n norm = float(${n}) * norm + float(${o});\n\n for(int k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; ++k){\n if (k < depthBegin){\n continue;\n }\n else if (k >= depthBegin && k < depthEnd){\n float dyi = -2.0 * float(${n})\n * float(${s})\n * getInputImage(b, r, c, k) * getOutputImage(b, r, c, d)\n / norm;\n if (k == d) {\n dyi += pow(norm, -1.0 * ${s});\n }\n if (k == coords[3]) {\n dyi *= getDy(b, r, c, d);\n result += dyi;\n }\n }\n else {\n break;\n }\n }\n }\n setOutput(result);\n }\n `}};var kee=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n,y:s,dy:a}=t,{depthRadius:i,bias:p,alpha:u,beta:c}=o,l=new cg(n.shape,i,p,u,c);return e.runWebGLProgram(l,[n,s,a],n.dtype)},MF={kernelName:Qa,backendName:\"webgl\",kernelFunc:kee};function LF(r,t,e,o){let n=y.sizeFromShape(t),a=y.sizeFromShape(r.shape)/n,i=te({inputs:{x:r},attrs:{shape:[a,n]},backend:o}),p=Yr(i,r.dtype,\"max\",o),u=te({inputs:{x:p},attrs:{shape:e},backend:o});return o.disposeIntermediateTensorInfo(i),o.disposeIntermediateTensorInfo(p),u}function Nv(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{reductionIndices:s,keepDims:a}=o,i=n.shape.length,p=y.parseAxisParam(s,n.shape),u=p,c=w.getAxesPermutation(u,i),l=c!=null,m=e.shouldExecuteOnCPU([n]),d=n;if(l){if(m){let C=e.texData.get(d.dataId).values,S=new Array(i);for(let E=0;E`Error in maxPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,u,i,p);if(c.filterWidth===1&&c.filterHeight===1&&y.arraysEqual(c.inShape,c.outShape))return At({inputs:{x:n},backend:e});let l=new Us(c,\"max\",!1);return e.runWebGLProgram(l,[n],n.dtype)}var VF={kernelName:Un,backendName:\"webgl\",kernelFunc:$ee};function Eee(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dataFormat:p,dimRoundingMode:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,u,p),m=new Iu(l,\"max\",!1);return e.runWebGLProgram(m,[n],n.dtype)}var WF={kernelName:ia,backendName:\"webgl\",kernelFunc:Eee};var lg=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.outputShape=t.inShape;let e=t.strideHeight,o=t.strideWidth,n=t.dilationHeight,s=t.effectiveFilterHeight,a=t.effectiveFilterWidth,i=s-1-t.padInfo.top,p=a-1-t.padInfo.left,u=s*a-1;this.userCode=`\n const ivec2 pads = ivec2(${i}, ${p});\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n\n ivec2 dyRCCorner = coords.yz - pads;\n int dyRCorner = dyRCCorner.x;\n int dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n for (int wR = 0; wR < ${s};\n wR += ${n}) {\n float dyR = float(dyRCorner + wR) / ${e}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 || fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${a}; wC++) {\n float dyC = float(dyCCorner + wC) / ${o}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(b, idyR, idyC, d);\n int maxPosValue = ${u} - int(getMaxPos(b, idyR, idyC, d));\n\n // Get the current value, check it against the value from the\n // position matrix.\n int curPosValue = wR * ${a} + wC;\n float mask = float(maxPosValue == curPosValue ? 1.0 : 0.0);\n\n dotProd += dyValue * mask;\n }\n }\n setOutput(dotProd);\n }\n `}},mg=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.outputShape=t.inShape;let e=t.strideDepth,o=t.strideHeight,n=t.strideWidth,s=t.dilationDepth,a=t.dilationHeight,i=t.dilationWidth,p=t.effectiveFilterDepth,u=t.effectiveFilterHeight,c=t.effectiveFilterWidth,l=p-1-t.padInfo.front,m=u-1-t.padInfo.top,d=c-1-t.padInfo.left,f=p*u*c-1;this.userCode=`\n const ivec3 pads = ivec3(${l}, ${m}, ${d});\n\n void main() {\n ivec5 coords = getOutputCoords();\n int batch = coords.x;\n int ch = coords.u;\n\n ivec3 dyCorner = ivec3(coords.y, coords.z, coords.w) - pads;\n int dyDCorner = dyCorner.x;\n int dyRCorner = dyCorner.y;\n int dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, ch) with pos mask(:, :, :, d) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n float dotProd = 0.0;\n\n for (int wD = 0; wD < ${p};\n wD += ${s}) {\n float dyD = float(dyDCorner + wD) / ${e}.0;\n\n if (dyD < 0.0 || dyD >= ${t.outDepth}.0 || fract(dyD) > 0.0) {\n continue;\n }\n int idyD = int(dyD);\n\n for (int wR = 0; wR < ${u};\n wR += ${a}) {\n float dyR = float(dyRCorner + wR) / ${o}.0;\n\n if (dyR < 0.0 || dyR >= ${t.outHeight}.0 ||\n fract(dyR) > 0.0) {\n continue;\n }\n int idyR = int(dyR);\n\n for (int wC = 0; wC < ${c};\n wC += ${i}) {\n float dyC = float(dyCCorner + wC) / ${n}.0;\n\n if (dyC < 0.0 || dyC >= ${t.outWidth}.0 ||\n fract(dyC) > 0.0) {\n continue;\n }\n int idyC = int(dyC);\n\n float dyValue = getDy(batch, idyD, idyR, idyC, ch);\n int maxPosValue = ${f} -\n int(getMaxPos(batch, idyD, idyR, idyC, ch));\n\n // Get the current value, check it against the value from the\n // position matrix.\n int curPosValue =\n wD * ${u} * ${c} +\n wR * ${c} + wC;\n float mask = float(maxPosValue == curPosValue ? 1.0 : 0.0);\n\n dotProd += dyValue * mask;\n }\n }\n }\n setOutput(dotProd);\n }\n `}};function Ree(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=[1,1,1],m=w.computePool3DInfo(a.shape,i,p,l,u,c),d=new Iu(m,\"max\",!0),f=e.runWebGLProgram(d,[a],a.dtype),h=new mg(m),g=e.runWebGLProgram(h,[n,f],a.dtype);return e.disposeIntermediateTensorInfo(f),g}var UF={kernelName:Ki,backendName:\"webgl\",kernelFunc:Ree};function Dee(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s,output:a}=t,i=s;Vs([s,a],\"maxPoolGrad\");let{filterSize:p,strides:u,pad:c,dimRoundingMode:l}=o,m=w.computePool2DInfo(i.shape,p,u,1,c,l),d=!0,f=new Us(m,\"max\",d),h=e.runWebGLProgram(f,[i],i.dtype),g=new lg(m),x=e.runWebGLProgram(g,[n,h],i.dtype);return e.disposeIntermediateTensorInfo(h),x}var GF={kernelName:Hi,backendName:\"webgl\",kernelFunc:Dee};function HF(r,t,e,o){let n=new Us(e,\"max\",!1),s=o.runWebGLProgram(n,[r],\"float32\");n=new Us(e,\"max\",!0,!0,t);let a=o.runWebGLProgram(n,[r],\"float32\");return[s,a]}var KF={kernelName:ua,backendName:\"webgl\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{filterSize:n,strides:s,pad:a,includeBatchInIndex:i}=t,p=e;y.assert(o.shape.length===4,()=>`Error in maxPool: input must be rank 4 but got rank ${o.shape.length}.`);let u=[1,1];y.assert(w.eitherStridesOrDilationsAreOne(s,u),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${s} and dilations '${u}'`);let c=w.computePool2DInfo(o.shape,n,s,u,a),[l,m]=HF(o,i,c,p);return[l,m]}};function qF(r,t,e,o){let n=y.sizeFromShape(t),a=y.sizeFromShape(r.shape)/n,i=te({inputs:{x:r},attrs:{shape:[a,n]},backend:o}),p=Yr(i,\"float32\",\"mean\",o),u=te({inputs:{x:p},attrs:{shape:e},backend:o});return o.disposeIntermediateTensorInfo(i),o.disposeIntermediateTensorInfo(p),u}var jF={kernelName:Gn,backendName:\"webgl\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{keepDims:n,axis:s}=t,a=e,i=o.shape.length,p=y.parseAxisParam(s,o.shape),u=p,c=w.getAxesPermutation(u,i),l=c!=null,m=a.shouldExecuteOnCPU([o]),d=[],f=o;if(l){if(m){let S=a.texData.get(f.dataId).values,k=new Array(i);for(let R=0;Rc[0]+t[l]+c[1]);let n=t.length,s=Re(n),a=e.map(c=>c[0]).join(\",\"),i=e.map((c,l)=>c[0]+t[l]).join(\",\"),p=[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,n),u=o===\"reflect\"?0:1;if(n===1){this.userCode=`\n int start = ${a};\n int end = ${i};\n\n void main() {\n int outC = getOutputCoords();\n if (outC < start) {\n outC = start * 2 - outC - ${u};\n } else if(outC >= end) {\n outC = (end - 1) * 2 - outC + ${u};\n }\n setOutput(getX(outC - start));\n }\n `;return}this.userCode=`\n ${s} start = ${s}(${a});\n ${s} end = ${s}(${i});\n\n void main() {\n ${s} outC = getOutputCoords();\n for (int i = 0; i < ${n}; i++) {\n if (outC[i] < start[i]) {\n outC[i] = start[i] * 2 - outC[i] - ${u};\n } else if(outC[i] >= end[i]) {\n outC[i] = (end[i] - 1) * 2 - outC[i] + ${u};\n }\n }\n ${s} coords = outC - start;\n setOutput(getX(${p}));\n }\n `}};var fg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=e.map((f,h)=>f[0]+t[h]+f[1]);let n=t.length,s=Re(n),a=e.map(f=>f[0]).join(\",\"),i=e.map((f,h)=>f[0]+t[h]).join(\",\"),p=Dt(\"rc\",n),u=Dt(\"source\",n),c=`${p[n-1]} < ${this.outputShape[n-1]}`,l=n===1?\"source\":`vec2(${u.slice(-2).join()})`,m=o===\"reflect\"?0:1,d=\"\";if(n===1){let f=`\n ${s} source = rc;\n if (source < start) {\n source = start * 2 - source - ${m};\n } else if (source >= end) {\n source = (end - 1) * 2 - source + ${m};\n }\n source -= start;\n `;d=`\n ${s} rc = outputLoc;\n ${f}\n result[0] = getChannel(getX(${u.join()}), ${l});\n ${p[n-1]} += 1;\n if(${c}) {\n ${f}\n result[1] = getChannel(getX(${u.join()}), ${l});\n }\n `}else{let f=`\n ${s} source = rc;\n ${s} lt = ${s}(lessThan(source, start));\n ${s} gte = ${s}(greaterThanEqual(source, end));\n ${s} orig = 1 - (lt + gte);\n source = orig * source +\n lt * (start * 2 - source - ${m}) +\n gte * ((end - 1) * 2 - source + ${m});\n source -= start;\n `;d=`\n ${s} rc = outputLoc;\n ${f}\n result[0] = getChannel(getX(${u.join()}), ${l});\n ${p[n-1]} += 1;\n if(${c}) {\n ${f}\n result[1] = getChannel(getX(${u.join()}), ${l});\n }\n rc = outputLoc;\n ${p[n-2]} += 1;\n if(${p[n-2]} < ${this.outputShape[n-2]}) {\n ${f}\n result[2] = getChannel(getX(${u.join()}), ${l});\n ${p[n-1]} += 1;\n if(${c}) {\n ${f}\n result[3] = getChannel(getX(${u.join()}), ${l});\n }\n }\n `}this.userCode=`\n const ${s} start = ${s}(${a});\n const ${s} end = ${s}(${i});\n\n void main() {\n ${s} outputLoc = getOutputCoords();\n vec4 result = vec4(0.);\n ${d}\n setOutput(result);\n }\n `}};var Mee=({inputs:r,backend:t,attrs:e})=>{let{x:o}=r,{paddings:n,mode:s}=e,a=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new fg(o.shape,n,s):new dg(o.shape,n,s);return t.runWebGLProgram(a,[o],o.dtype)},QF={kernelName:qn,backendName:\"webgl\",kernelFunc:Mee};var Lee=`if (b == 0.0) return NAN;\n return mod(a, b);`,Bee=`\n vec4 result = mod(a, b);\n bvec4 isNaN = equal(b, vec4(0.0));\n `+Xr+`\n return result;\n`,zee=nt({opSnippet:Lee,packedOpSnippet:Bee}),ZF={kernelName:jn,backendName:\"webgl\",kernelFunc:zee};var hg=class{constructor(t,e,o){this.variableNames=[\"probs\"],this.customUniforms=[{name:\"seed\",type:\"float\"}],this.outputShape=[t,o],this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n\n float r = random(seed);\n float cdf = 0.0;\n\n for (int i = 0; i < ${e-1}; i++) {\n cdf += getProbs(batch, i);\n\n if (r < cdf) {\n setOutput(float(i));\n return;\n }\n }\n\n // If no other event happened, last event happened.\n setOutput(float(${e-1}));\n }\n `}};var Vee=`\nif (a == b) {\n return 1.0;\n};\nreturn a / b;`,Wee=`\n // vec4 one = vec4(equal(a, b));\n // return one + (vec4(1.0) - one) * a / b;\n vec4 result = a / b;\n if(a.x == b.x) {\n result.x = 1.;\n }\n if(a.y == b.y) {\n result.y = 1.;\n }\n if(a.z == b.z) {\n result.z = 1.;\n }\n if(a.w == b.w) {\n result.w = 1.;\n }\n\n return result;\n`,Tv=nt({opSnippet:Vee,packedOpSnippet:Wee,checkOutOfBounds:!0}),JF={kernelName:hn,backendName:\"webgl\",kernelFunc:Tv};var e3=\"return a - b;\",_v=nt({opSnippet:e3,packedOpSnippet:e3,supportsComplex:!0,cpuKernelImpl:yD}),t3={kernelName:_s,backendName:\"webgl\",kernelFunc:_v};function $v(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{dim:s}=o,a=y.parseAxisParam([s],n.shape),i=Nv({inputs:{x:n},backend:e,attrs:{reductionIndices:a,keepDims:!1}}),p=w.expandShapeToKeepDim(i.shape,a),u=te({inputs:{x:i},backend:e,attrs:{shape:p}}),c=_v({inputs:{a:n,b:u},backend:e}),l=Iv({inputs:{x:c},backend:e}),m=Tp({inputs:{x:l},backend:e,attrs:{axis:a,keepDims:!1}}),d=te({inputs:{x:m},backend:e,attrs:{shape:p}}),f=Tv({inputs:{a:l,b:d},backend:e});return e.disposeIntermediateTensorInfo(i),e.disposeIntermediateTensorInfo(u),e.disposeIntermediateTensorInfo(c),e.disposeIntermediateTensorInfo(l),e.disposeIntermediateTensorInfo(m),e.disposeIntermediateTensorInfo(d),f}var r3={kernelName:vs,backendName:\"webgl\",kernelFunc:$v};function Uee(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o,p=i?n:$v({inputs:{logits:n},backend:e,attrs:{dim:n.shape.length-1}}),u=p.shape[0],c=p.shape[1],l=new hg(u,c,s),m=[[a]],d=e.runWebGLProgram(l,[p],\"int32\",m);return i||e.disposeIntermediateTensorInfo(p),d}var o3={kernelName:Xn,backendName:\"webgl\",kernelFunc:Uee};var Gee=Ut+`\n return -x;\n`,Hee=`\n vec4 result = -x;\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`;function Kee(r){let{inputs:t,backend:e}=r,{x:o}=t;if(e.shouldExecuteOnCPU([o])){let s=e.texData.get(o.dataId),[a,i]=JR(s.values,o.shape,o.dtype);return e.makeTensorInfo(i,o.dtype,a)}let n;return A().getBool(\"WEBGL_PACK_UNARY_OPERATIONS\")?n=new Fr(o.shape,Hee):n=new or(o.shape,Gee),e.runWebGLProgram(n,[o],o.dtype)}var n3={kernelName:pa,backendName:\"webgl\",kernelFunc:Kee};var qee=Wt.nonMaxSuppressionV3Impl;function jee(r){w.warn(\"tf.nonMaxSuppression() in webgl locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p}=o,u=e.readSync(n.dataId),c=e.readSync(s.dataId),{selectedIndices:l}=qee(u,c,a,i,p);return e.makeTensorInfo([l.length],\"int32\",new Int32Array(l))}var s3={kernelName:Zn,backendName:\"webgl\",kernelFunc:jee};var Xee=Wt.nonMaxSuppressionV4Impl;function Yee(r){w.warn(\"tf.nonMaxSuppression() in webgl locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p,padToMaxOutputSize:u}=o,c=e.readSync(n.dataId),l=e.readSync(s.dataId),{selectedIndices:m,validOutputs:d}=Xee(c,l,a,i,p,u);return[e.makeTensorInfo([m.length],\"int32\",new Int32Array(m)),e.makeTensorInfo([],\"int32\",new Int32Array([d]))]}var a3={kernelName:Za,backendName:\"webgl\",kernelFunc:Yee};var Qee=Wt.nonMaxSuppressionV5Impl;function Zee(r){w.warn(\"tf.nonMaxSuppression() in webgl locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p,softNmsSigma:u}=o,c=e.readSync(n.dataId),l=e.readSync(s.dataId),m=a,d=i,f=p,h=u,{selectedIndices:g,selectedScores:x}=Qee(c,l,m,d,f,h);return[e.makeTensorInfo([g.length],\"int32\",new Int32Array(g)),e.makeTensorInfo([x.length],\"float32\",new Float32Array(x))]}var i3={kernelName:Jn,backendName:\"webgl\",kernelFunc:Zee};var gg=class{constructor(t,e,o,n){this.variableNames=[\"indices\"],this.outputShape=[t,e],this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int index = round(getIndices(coords.x));\n setOutput(mix(float(${n}), float(${o}),\n float(index == coords.y)));\n }\n `}};var Jee=r=>{let{inputs:t,backend:e,attrs:o}=r,{indices:n}=t,{dtype:s,depth:a,onValue:i,offValue:p}=o,u=y.sizeFromShape(n.shape),c=new gg(u,a,i,p),l=te({inputs:{x:n},backend:e,attrs:{shape:[u]}}),m=e.runWebGLProgram(c,[l],s);e.disposeIntermediateTensorInfo(l);let d=[...n.shape,a],f=te({inputs:{x:m},backend:e,attrs:{shape:d}});return e.disposeIntermediateTensorInfo(m),f},u3={kernelName:es,backendName:\"webgl\",kernelFunc:Jee};function sm(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"complex64\"){let n=wi({inputs:{input:o},backend:e}),s=sm({inputs:{x:n},backend:e}),a=$p({inputs:{input:o},backend:e}),i=sm({inputs:{x:a},backend:e}),p=Or({inputs:{real:s,imag:i},backend:e});return e.disposeIntermediateTensorInfo(n),e.disposeIntermediateTensorInfo(s),e.disposeIntermediateTensorInfo(a),e.disposeIntermediateTensorInfo(i),p}else return Si({attrs:{shape:o.shape,dtype:o.dtype,value:o.dtype===\"string\"?\"\":0},backend:e})}var p3={kernelName:Sa,backendName:\"webgl\",kernelFunc:sm};function c3(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"string\")throw new Error(\"onesLike is not supported under string dtype\");if(o.dtype===\"complex64\"){let n=wi({inputs:{input:o},backend:e}),s=c3({inputs:{x:n},backend:e}),a=$p({inputs:{input:o},backend:e}),i=sm({inputs:{x:a},backend:e}),p=Or({inputs:{real:s,imag:i},backend:e});return e.disposeIntermediateTensorInfo(n),e.disposeIntermediateTensorInfo(s),e.disposeIntermediateTensorInfo(a),e.disposeIntermediateTensorInfo(i),p}else return Si({attrs:{shape:o.shape,dtype:o.dtype,value:1},backend:e})}var l3={kernelName:ca,backendName:\"webgl\",kernelFunc:c3};function ete(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o;if(t.length===1)return eg({inputs:{input:t[0]},backend:e,attrs:{dim:n}});let s=t[0].shape,a=t[0].dtype;t.forEach(c=>{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=eg({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=Sv({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeIntermediateTensorInfo(c)),u}var m3={kernelName:la,backendName:\"webgl\",kernelFunc:ete};var xg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.customUniforms=[{name:\"value\",type:\"float\"}],this.outputShape=e.map((u,c)=>u[0]+t[c]+u[1]);let n=t.length,s=Re(n),a=e.map(u=>u[0]).join(\",\"),i=e.map((u,c)=>u[0]+t[c]).join(\",\"),p=[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,n);if(n===1){this.userCode=`\n int start = ${a};\n int end = ${i};\n\n void main() {\n int outC = getOutputCoords();\n if (outC < start || outC >= end) {\n setOutput(value);\n } else {\n setOutput(getX(outC - start));\n }\n }\n `;return}this.userCode=`\n ${s} start = ${s}(${a});\n ${s} end = ${s}(${i});\n\n void main() {\n ${s} outC = getOutputCoords();\n if (any(lessThan(outC, start)) || any(greaterThanEqual(outC, end))) {\n setOutput(value);\n } else {\n ${s} coords = outC - start;\n setOutput(getX(${p}));\n }\n }\n `}};var yg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.packedInputs=!0,this.packedOutput=!0,this.customUniforms=[{name:\"value\",type:\"float\"}],this.outputShape=e.map((h,g)=>h[0]+t[g]+h[1]);let n=t.length,s=Re(n),a=e.map(h=>h[0]).join(\",\"),i=e.map((h,g)=>h[0]+t[g]).join(\",\"),p=Dt(\"rc\",n),u=Dt(\"source\",n),c=`${p[n-1]} < ${this.outputShape[n-1]}`,l=n===1?\"source\":`vec2(${u.slice(-2).join()})`,m=[`${s} rc = outputLoc;`,`${p[n-1]} += 1;\n if(${c}) {\n `,n===1?\"\":`}\n rc = outputLoc;\n ${p[n-2]} += 1;\n if(${p[n-2]} < ${this.outputShape[n-2]}) {`,n===1?\"\":` ${p[n-1]} += 1;\n if(${c}) {`],d=n===1?\"rc < start || rc >= end\":\"any(lessThan(rc, start)) || any(greaterThanEqual(rc, end))\",f=\"\";for(let h=0,g=n===1?2:4;h{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{paddings:s,constantValue:a}=o;if(y.sizeFromShape(n.shape)===0){let u=s.map((c,l)=>c[0]+n.shape[l]+c[1]);return Si({backend:e,attrs:{shape:u,value:a,dtype:n.dtype}})}let i=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new yg(n.shape,s,a):new xg(n.shape,s,a),p=[[a]];return e.runWebGLProgram(i,[n],n.dtype,p)},d3={kernelName:ts,backendName:\"webgl\",kernelFunc:Ev};var tte=`\n if(a < 0.0 && floor(b) < b){\n return NAN;\n }\n if (b == 0.0) {\n return 1.0;\n }\n return (round(mod(b, 2.0)) != 1) ?\n pow(abs(a), b) : sign(a) * pow(abs(a), b);\n`,rte=`\n // isModRound1 has 1 for components with round(mod(b, 2.0)) == 1, 0 otherwise.\n vec4 isModRound1 = vec4(equal(round(mod(b, 2.0)), ivec4(1)));\n vec4 multiplier = sign(a) * isModRound1 + (vec4(1.0) - isModRound1);\n vec4 result = multiplier * pow(abs(a), b);\n\n // Ensure that a^0 = 1, including 0^0 = 1 as this correspond to TF and JS\n bvec4 isExpZero = equal(b, vec4(0.0));\n result.r = isExpZero.r ? 1.0 : result.r;\n result.g = isExpZero.g ? 1.0 : result.g;\n result.b = isExpZero.b ? 1.0 : result.b;\n result.a = isExpZero.a ? 1.0 : result.a;\n\n bvec4 isNaN1 = lessThan(a, vec4(0.0));\n bvec4 isNaN2 = lessThan(floor(b), b);\n bvec4 isNaN = bvec4(isNaN1.x && isNaN2.x, isNaN1.y && isNaN2.y, isNaN1.z && isNaN2.z, isNaN1.w && isNaN2.w);\n `+Xr+`\n return result;\n`,ote=nt({opSnippet:tte,packedOpSnippet:rte}),f3={kernelName:rs,backendName:\"webgl\",kernelFunc:ote};function nte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o,i=n.shape.length,p=[],u=y.parseAxisParam(s,n.shape),c=u,l=w.getAxesPermutation(c,i),m=n;l!=null&&(m=Ct({inputs:{x:n},backend:e,attrs:{perm:l}}),c=w.getInnerMostAxes(c.length,i),p.push(m)),w.assertAxesAreInnerMostDims(\"prod\",c,i);let d;if(e.shouldExecuteOnCPU([m])){let f=e.texData.get(m.dataId).values,{outVals:h,outShape:g,outDtype:x}=tD(m.shape,m.dtype,f,c);d=e.makeTensorInfo(g,x,h)}else{let[f,h]=w.computeOutAndReduceShapes(m.shape,c),g=y.sizeFromShape(h),x=te({inputs:{x:m},backend:e,attrs:{shape:[-1,g]}}),b=ni(n.dtype),C=Yr(x,b,\"prod\",e);d=te({inputs:{x:C},backend:e,attrs:{shape:f}}),p.push(x),p.push(C)}if(a){p.push(d);let f=w.expandShapeToKeepDim(d.shape,u);d=te({inputs:{x:d},backend:e,attrs:{shape:f}})}return p.forEach(f=>e.disposeIntermediateTensorInfo(f)),d}var h3={kernelName:ns,backendName:\"webgl\",kernelFunc:nte};function ste(r){let{inputs:t,backend:e,attrs:o}=r,{paramsNestedSplits:n,paramsDenseValues:s,indices:a}=t,{outputRaggedRank:i}=o,p=n.map(x=>e.readSync(x.dataId)),u=n.map(x=>x.shape),c=e.readSync(s.dataId),l=e.readSync(a.dataId),[m,d,f]=rD(p,u,c,s.shape,s.dtype,l,a.shape,i),h=m.map(x=>e.makeTensorInfo([x.length],\"int32\",x)),g=e.makeTensorInfo(f,s.dtype,d);return h.concat([g])}var g3={kernelName:Qp,backendName:\"webgl\",kernelFunc:ste};function ate(r){let{inputs:t,backend:e}=r,{starts:o,limits:n,deltas:s}=t,a=e.readSync(o.dataId),i=e.readSync(n.dataId),p=e.readSync(s.dataId),[u,c]=oD(a,o.shape,o.dtype,i,n.shape,p,s.shape),l=e.makeTensorInfo([u.length],\"int32\",u),m=e.makeTensorInfo([c.length],o.dtype,c);return[l,m]}var x3={kernelName:Zp,backendName:\"webgl\",kernelFunc:ate};function ite(r){let{inputs:t,backend:e,attrs:o}=r,{shape:n,values:s,defaultValue:a,rowPartitionTensors:i}=t,{rowPartitionTypes:p}=o,u=e.readSync(n.dataId),c=e.readSync(s.dataId),l=e.readSync(a.dataId),m=i.map(g=>e.readSync(g.dataId)),d=i.map(g=>g.shape),[f,h]=nD(u,n.shape,c,s.shape,s.dtype,l,a.shape,m,d,p);return e.makeTensorInfo(f,s.dtype,h)}var y3={kernelName:Jp,backendName:\"webgl\",kernelFunc:ite};var Rv=r=>{let{backend:t,attrs:e}=r,{start:o,stop:n,step:s,dtype:a}=e,i=sD(o,n,s,a);return t.makeTensorInfo([i.length],a,i)},b3={kernelName:ma,backendName:\"webgl\",kernelFunc:Rv};var ute=\"return 1.0 / x;\",pte=xe({opSnippet:ute}),C3={kernelName:ss,backendName:\"webgl\",kernelFunc:pte};var cte=Ut+`\n return (x < 0.0) ? 0.0 : x;\n`,lte=`\n vec4 result = x * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,mte=xe({opSnippet:cte,packedOpSnippet:lte}),w3={kernelName:as,backendName:\"webgl\",kernelFunc:mte};var dte=Ut+`\n return (x < 0.0) ? 0.0 : min(6.0, x);\n`,fte=`\n vec4 result = min(x, vec4(6.)) * vec4(greaterThanEqual(x, vec4(0.0)));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,hte=xe({opSnippet:dte,packedOpSnippet:fte}),S3={kernelName:ps,backendName:\"webgl\",kernelFunc:hte};var bg=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m;s?m=\"(vec2(yRC) + vec2(0.5)) * effectiveInputOverOutputRatioRC - vec2(0.5)\":m=\"vec2(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec2 effectiveInputOverOutputRatioRC = vec2(\n ${c[0]/l[0]},\n ${c[1]/l[1]});\n const vec2 inputShapeRC = vec2(${i}.0, ${p}.0);\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n ivec2 yRC = coords.yz;\n\n // Fractional source index.\n vec2 sourceFracIndexRC = ${m};\n\n // Compute the four integer indices.\n ivec2 sourceFloorRC = ivec2(max(sourceFracIndexRC, vec2(0.0)));\n ivec2 sourceCeilRC = ivec2(\n min(inputShapeRC - 1.0, ceil(sourceFracIndexRC)));\n\n float topLeft = getA(b, sourceFloorRC.x, sourceFloorRC.y, d);\n float bottomLeft = getA(b, sourceCeilRC.x, sourceFloorRC.y, d);\n float topRight = getA(b, sourceFloorRC.x, sourceCeilRC.y, d);\n float bottomRight = getA(b, sourceCeilRC.x, sourceCeilRC.y, d);\n\n vec2 fracRC = sourceFracIndexRC - vec2(sourceFloorRC);\n\n float top = topLeft + (topRight - topLeft) * fracRC.y;\n float bottom = bottomLeft + (bottomRight - bottomLeft) * fracRC.y;\n float newValue = top + (bottom - top) * fracRC.x;\n\n setOutput(newValue);\n }\n `}};var Cg=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m;s?m=\"(vec3(yRC) + vec3(0.5)) * effectiveInputOverOutputRatioRC - vec3(0.5)\":m=\"vec3(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec3 effectiveInputOverOutputRatioRC = vec3(\n ${c[0]/l[0]},\n ${c[1]/l[1]},\n ${c[1]/l[1]});\n const vec3 inputShapeRC = vec3(${i}.0, ${p}.0,\n ${p}.0);\n\n float getAValue(int b, int r, int c, int d) {\n return getChannel(getA(b, r, c, d), vec2(c, d));\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n // Calculate values for next column in yRC.z.\n ivec3 yRC = coords.yzz + ivec3(0, 0, 1);\n\n // Fractional source index.\n vec3 sourceFracIndexRC = ${m};\n\n // Compute the four integer indices.\n ivec3 sourceFloorRC = ivec3(max(sourceFracIndexRC, vec3(0.0)));\n ivec3 sourceCeilRC = ivec3(\n min(inputShapeRC - 1.0, ceil(sourceFracIndexRC)));\n\n // Should we calculate next column and row elements in 2x2 packed cell.\n bool hasNextCol = d < ${u-1};\n bool hasNextRow = coords.z < ${o-1};\n\n // In parallel, construct four corners for all four components in\n // packed 2x2 cell.\n vec4 topLeft = vec4(\n getAValue(b, sourceFloorRC.x, sourceFloorRC.y, d),\n hasNextCol ? getAValue(b, sourceFloorRC.x, sourceFloorRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceFloorRC.x, sourceFloorRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceFloorRC.x, sourceFloorRC.z, d + 1) : 0.0);\n\n vec4 bottomLeft = vec4(\n getAValue(b, sourceCeilRC.x, sourceFloorRC.y, d),\n hasNextCol ? getAValue(b, sourceCeilRC.x, sourceFloorRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceCeilRC.x, sourceFloorRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceCeilRC.x, sourceFloorRC.z, d + 1) : 0.0);\n\n vec4 topRight = vec4(\n getAValue(b, sourceFloorRC.x, sourceCeilRC.y, d),\n hasNextCol ? getAValue(b, sourceFloorRC.x, sourceCeilRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceFloorRC.x, sourceCeilRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceFloorRC.x, sourceCeilRC.z, d + 1) : 0.0);\n\n vec4 bottomRight = vec4(\n getAValue(b, sourceCeilRC.x, sourceCeilRC.y, d),\n hasNextCol ? getAValue(b, sourceCeilRC.x, sourceCeilRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceCeilRC.x, sourceCeilRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceCeilRC.x, sourceCeilRC.z, d + 1) : 0.0);\n\n vec3 fracRC = sourceFracIndexRC - vec3(sourceFloorRC);\n\n vec4 top = mix(topLeft, topRight, fracRC.yyzz);\n vec4 bottom = mix(bottomLeft, bottomRight, fracRC.yyzz);\n vec4 newValue = mix(top, bottom, fracRC.x);\n\n setOutput(newValue);\n }\n `}};function gte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,c=A().getBool(\"WEBGL_PACK_IMAGE_OPERATIONS\")?new Cg(n.shape,p,u,s,a):new bg(n.shape,p,u,s,a);return e.runWebGLProgram(c,[n],\"float32\")}var I3={kernelName:us,backendName:\"webgl\",kernelFunc:gte};var wg=class{constructor(t,e,o){this.variableNames=[\"dy\"],this.outputShape=[],this.outputShape=e;let[,n,s]=e,[,a,i]=t,p=[o&&a>1?n-1:n,o&&i>1?s-1:s],u=[o&&a>1?a-1:a,o&&i>1?i-1:i],c=p[0]/u[0],l=p[1]/u[1],m=1/c,d=1/l,f=Math.ceil(m)*2+2,h=Math.ceil(d)*2+2;this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n int r = coords[1];\n int c = coords[2];\n\n float accumulator = 0.0;\n\n const float heightScale = float(${c});\n const float widthScale = float(${l});\n\n const float invHeightScale = float(${m});\n const float invWidthScale = float(${d});\n\n const int winHeight = int(${f});\n const int winWidth = int(${h});\n\n // Compute bounds for where in dy we will look\n float startRLerp = floor(float(r) * invHeightScale);\n int startDyR = int(startRLerp - float(winHeight / 2));\n\n float startCLerp = floor(float(c) * invWidthScale);\n int startDyC = int(startCLerp - float(winWidth / 2));\n\n // Loop over dy\n for (int dyROffset = 0; dyROffset < winHeight; dyROffset++) {\n int dyR = dyROffset + startDyR;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= ${a}) {\n continue;\n }\n\n for (int dyCOffset = 0; dyCOffset < winWidth; dyCOffset++) {\n int dyC = dyCOffset + startDyC;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= ${i}) {\n continue;\n }\n\n float dxR = float(dyR) * heightScale;\n int topDxRIndex = int(floor(dxR));\n int bottomDxRIndex = int(min(ceil(dxR), ${n-1}.0));\n float dxRLerp = dxR - float(topDxRIndex);\n float inverseDxRLerp = 1.0 - dxRLerp;\n\n float dxC = float(dyC) * widthScale;\n int leftDxCIndex = int(floor(dxC));\n int rightDxCIndex = int(min(ceil(dxC), ${s-1}.0));\n float dxCLerp = dxC - float(leftDxCIndex);\n float inverseDxCLerp = 1.0 - dxCLerp;\n\n if (r == topDxRIndex && c == leftDxCIndex) {\n // topLeft\n accumulator +=\n getDy(b, dyR, dyC, d) * inverseDxRLerp * inverseDxCLerp;\n }\n\n if (r == topDxRIndex && c == rightDxCIndex) {\n // topRight\n accumulator += getDy(b, dyR, dyC, d) * inverseDxRLerp * dxCLerp;\n }\n\n if (r == bottomDxRIndex && c == leftDxCIndex) {\n // bottomLeft\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * inverseDxCLerp;\n }\n\n if (r == bottomDxRIndex && c == rightDxCIndex) {\n // bottomRight\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * dxCLerp;\n }\n }\n }\n // End loop over dy\n\n setOutput(accumulator);\n }\n `}};function xte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=new wg(s.shape,n.shape,a);return e.runWebGLProgram(i,[s],s.dtype)}var v3={kernelName:ei,backendName:\"webgl\",kernelFunc:xte};var Sg=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m=n?\"0.5\":\"0.0\",d;s?d=\"max((vec2(yRC) + vec2(0.5)) * effectiveInputOverOutputRatioRC, vec2(0.0))\":d=\"vec2(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec2 effectiveInputOverOutputRatioRC = vec2(\n ${c[0]/l[0]},\n ${c[1]/l[1]});\n const vec2 inputShapeRC = vec2(${i}.0, ${p}.0);\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n ivec2 yRC = coords.yz;\n\n // Fractional source index.\n vec2 sourceFracIndexRC = ${d};\n\n // Compute the coordinators of nearest neighbor point.\n ivec2 sourceNearestRC = ivec2(\n min(inputShapeRC - 1.0, floor(sourceFracIndexRC + ${m})));\n float newValue = getA(b, sourceNearestRC.x, sourceNearestRC.y, d);\n\n setOutput(newValue);\n }\n `}};var Ig=class{constructor(t,e,o,n,s){this.variableNames=[\"A\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=[];let[a,i,p,u]=t;this.outputShape=[a,e,o,u];let c=[n&&e>1?i-1:i,n&&o>1?p-1:p],l=[n&&e>1?e-1:e,n&&o>1?o-1:o],m=n?\"0.5\":\"0.0\",d;s?d=\"max((vec3(yRC) + vec3(0.5)) * effectiveInputOverOutputRatioRC, vec3(0.0))\":d=\"vec3(yRC) * effectiveInputOverOutputRatioRC\",this.userCode=`\n const vec3 effectiveInputOverOutputRatioRC = vec3(\n ${c[0]/l[0]},\n ${c[1]/l[1]},\n ${c[1]/l[1]});\n const vec3 inputShapeRC = vec3(${i}.0, ${p}.0,\n ${p}.0);\n\n float getAValue(int b, int r, int c, int d) {\n return getChannel(getA(b, r, c, d), vec2(c, d));\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n // Calculate values for next column in yRC.z.\n ivec3 yRC = coords.yzz + ivec3(0, 0, 1);\n\n // Fractional source index.\n vec3 sourceFracIndexRC = ${d};\n\n // Compute the coordinators of nearest neighbor point.\n ivec3 sourceNearestRC = ivec3(\n min(inputShapeRC - 1.0, floor(sourceFracIndexRC + ${m})));\n\n // Should we calculate next column and row elements in 2x2 packed cell.\n bool hasNextCol = d < ${u-1};\n bool hasNextRow = coords.z < ${o-1};\n\n vec4 newValue = vec4(\n getAValue(b, sourceNearestRC.x, sourceNearestRC.y, d),\n hasNextCol ? getAValue(b, sourceNearestRC.x, sourceNearestRC.y, d + 1)\n : 0.0,\n hasNextRow ? getAValue(b, sourceNearestRC.x, sourceNearestRC.z, d)\n : 0.0,\n (hasNextRow && hasNextCol) ?\n getAValue(b, sourceNearestRC.x, sourceNearestRC.z, d + 1) : 0.0);\n\n setOutput(newValue);\n }\n `}};function yte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,c=A().getBool(\"WEBGL_PACK_IMAGE_OPERATIONS\")?new Ig(n.shape,p,u,s,a):new Sg(n.shape,p,u,s,a);return e.runWebGLProgram(c,[n],n.dtype)}var k3={kernelName:is,backendName:\"webgl\",kernelFunc:yte};var vg=class{constructor(t,e,o){this.variableNames=[\"dy\"],this.outputShape=[],this.outputShape=e;let[,n,s]=e,[,a,i]=t,p=[o&&a>1?n-1:n,o&&i>1?s-1:s],u=[o&&a>1?a-1:a,o&&i>1?i-1:i],c=p[0]/u[0],l=p[1]/u[1],m=1/c,d=1/l,f=Math.ceil(m)*2+2,h=Math.ceil(d)*2+2;this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int b = coords[0];\n int d = coords[3];\n int r = coords[1];\n int c = coords[2];\n\n float accumulator = 0.0;\n\n const float heightScale = float(${c});\n const float widthScale = float(${l});\n\n const float invHeightScale = float(${m});\n const float invWidthScale = float(${d});\n\n const int winHeight = int(${f});\n const int winWidth = int(${h});\n\n // Compute bounds for where in dy we will look\n float startRLerp = floor(float(r) * invHeightScale);\n int startDyR = int(floor(startRLerp - float(winHeight / 2)));\n\n float startCLerp = floor(float(c) * invWidthScale);\n int startDyC = int(floor(startCLerp - float(winWidth / 2)));\n\n // Loop over dy\n for (int dyROffset = 0; dyROffset < winHeight; dyROffset++) {\n int dyR = dyROffset + startDyR;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= ${a}) {\n continue;\n }\n\n for (int dyCOffset = 0; dyCOffset < winWidth; dyCOffset++) {\n int dyC = dyCOffset + startDyC;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= ${i}) {\n continue;\n }\n\n float sourceFracRow =\n float(${p[0]}) *\n (float(dyR) / float(${u[0]}));\n\n float sourceFracCol =\n float(${p[1]}) *\n (float(dyC) / float(${u[1]}));\n\n int sourceNearestRow = int(min(\n float(int(${n}) - 1),\n ${o} ? float(round(sourceFracRow)) :\n float(floor(sourceFracRow))));\n\n int sourceNearestCol = int(min(\n float(int(${s}) - 1),\n ${o} ? float(round(sourceFracCol)) :\n float(floor(sourceFracCol))));\n\n if (r == sourceNearestRow && c == sourceNearestCol) {\n accumulator += getDy(b, dyR, dyC, d);\n }\n }\n }\n // End loop over dy\n\n setOutput(accumulator);\n }\n `}};function bte(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=new vg(s.shape,n.shape,a);return e.runWebGLProgram(i,[s],s.dtype)}var N3={kernelName:Ja,backendName:\"webgl\",kernelFunc:bte};var kg=class{constructor(t,e){this.variableNames=[\"x\"];let o=t.length;if(o>4)throw new Error(`WebGL backend: Reverse of rank-${o} tensor is not yet supported`);if(this.outputShape=t,o===1){this.userCode=`\n void main() {\n int coord = getOutputCoords();\n setOutput(getX(${t[0]} - coord - 1));\n }\n `;return}let n=i=>e.indexOf(i)!==-1&&t[i]!==1?`${t[i]} - coords[${i}] - 1`:`coords[${i}]`,s=t.map((i,p)=>n(p)).join(\",\"),a=Re(o);this.userCode=`\n void main() {\n ${a} coords = getOutputCoords();\n setOutput(getX(${s}));\n }\n `}};var Ng=class{constructor(t,e){this.variableNames=[\"x\"],this.packedInputs=!0,this.packedOutput=!0;let o=t.length;if(o>4)throw new Error(`WebGL backend: Reverse of rank-${o} tensor is not yet supported`);this.outputShape=t;let n=Dt(\"rc\",o),s=`${n[o-1]} + 1 < ${this.outputShape[o-1]}`,a=`${n[o-2]} + 1 < ${this.outputShape[o-2]}`,i=Re(o);o===1?this.userCode=`\n void main(){\n int rc = getOutputCoords();\n vec4 result = vec4(0.);\n result.r = getChannel(getX(${t[0]} - rc - 1),\n ${t[0]} - rc - 1);\n if(${s}){\n result.g = getChannel(getX(${t[0]} - (rc + 1) - 1),\n ${t[0]} - (rc + 1) - 1);\n }\n setOutput(result);\n }\n `:this.userCode=`\n void main() {\n ${i} rc = getOutputCoords();\n vec4 result = vec4(0.);\n result.r = ${p(n.slice())};\n if(${s}){\n result.g = ${u(n.slice())};\n }\n if(${a}) {\n result.b = ${c(n.slice())};\n if(${s}) {\n result.a = ${l(n.slice())};\n }\n }\n setOutput(result);\n }\n `;function p(f){return m(f)}function u(f){return f[o-1]=\"(\"+f[o-1]+\" + 1)\",m(f)}function c(f){return f[o-2]=\"(\"+f[o-2]+\" + 1)\",m(f)}function l(f){return f[o-1]=\"(\"+f[o-1]+\" + 1)\",f[o-2]=\"(\"+f[o-2]+\" + 1)\",m(f)}function m(f){let h=t.map((b,C)=>d(C,f)),g=h.join(\",\"),x=h.slice(-2).join(\",\");return`getChannel(getX(${g}), vec2(${x}))`}function d(f,h){return e.indexOf(f)!==-1&&t[f]!==1?`${t[f]} - ${h[f]} - 1`:`${h[f]}`}}};function Cte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o,a=n.shape.length,i=y.parseAxisParam(s,n.shape);if(a===0)return At({inputs:{x:n},backend:e});let p=A().getBool(\"WEBGL_PACK_ARRAY_OPERATIONS\")?new Ng(n.shape,i):new kg(n.shape,i);return e.runWebGLProgram(p,[n],n.dtype)}var T3={kernelName:cs,backendName:\"webgl\",kernelFunc:Cte};var Tg=class{constructor(t,e){this.variableNames=[\"Image\"],this.outputShape=[],this.customUniforms=[{name:\"params\",type:\"vec4\"}];let o=t[1],n=t[2];this.outputShape=t;let s=\"\";typeof e==\"number\"?s=`float outputValue = ${e.toFixed(2)};`:s=`\n vec3 fill = vec3(${e.join(\",\")});\n float outputValue = fill[coords[3]];`,this.userCode=`\n void main() {\n ivec4 coords = getOutputCoords();\n int x = coords[2];\n int y = coords[1];\n float coordXFloat = (float(x) - params[0]) * params[3] -\n (float(y) - params[1]) * params[2];\n float coordYFloat = (float(x) - params[0]) * params[2] +\n (float(y) - params[1]) * params[3];\n int coordX = int(round(coordXFloat + params[0]));\n int coordY = int(round(coordYFloat + params[1]));\n ${s}\n if(coordX >= 0 && coordX < ${n} && coordY >= 0 && coordY < ${o}) {\n outputValue = getImage(coords[0], coordY, coordX, coords[3]);\n }\n setOutput(outputValue);\n }\n `}};var _3={kernelName:As,backendName:\"webgl\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{image:o}=r,{radians:n,fillValue:s,center:a}=t,i=e,p=new Tg(o.shape,s),[u,c]=w.getImageCenter(a,o.shape[1],o.shape[2]),l=[[u,c,Math.sin(n),Math.cos(n)]];return i.runWebGLProgram(p,[o],o.dtype,l)}};var wte=`\n // OpenGL ES does not support round function.\n // The algorithm is based on banker's rounding.\n float base = floor(x);\n if ((x - base) < 0.5) {\n return floor(x);\n } else if ((x - base) > 0.5) {\n return ceil(x);\n } else {\n if (mod(base, 2.0) == 0.0) {\n return base;\n } else {\n return base + 1.0;\n }\n }\n`,Ste=xe({opSnippet:wte}),$3={kernelName:ls,backendName:\"webgl\",kernelFunc:Ste};var Ite=\"return inversesqrt(x);\",vte=xe({opSnippet:Ite,cpuKernelImpl:aD}),E3={kernelName:ms,backendName:\"webgl\",kernelFunc:vte};var vu=class{constructor(t,e,o,n,s,a,i=!0,p=!1){this.variableNames=[\"updates\",\"indices\",\"defaultValue\"],this.outputShape=a;let u=Re(s.length),c=Re(a.length),l=\"\";o===1?l=\"i\":o===2&&(l=\"i, j\");let m=`getIndices(${l})`,d=\"\";n===1?d=\"i\":n===2&&(d=\"i, coords[1]\");let f=`getUpdates(${d})`,h=\"\";p&&(h=\"coords[0], coords[1]\");let g=`getDefaultValue(${h})`,x=e>1?\"strides[j]\":\"strides\";this.userCode=`\n ${u} strides = ${u}(${s});\n\n void main() {\n ${c} coords = getOutputCoords();\n float sum = 0.0;\n bool found = false;\n for (int i = 0; i < ${t}; i++) {\n int flattenedIndex = 0;\n for (int j = 0; j < ${e}; j++) {\n int index = round(${m});\n flattenedIndex += index * ${x};\n }\n if (flattenedIndex == coords[0]) {\n sum += ${f};\n found = true;\n }\n }\n setOutput(mix(${g}, sum, float(found)));\n }\n `}};var _g=class{constructor(t,e,o,n,s,a,i=!0,p=!1){this.variableNames=[\"updates\",\"indices\",\"defaultValue\"],this.packedInputs=!0,this.packedOutput=!0,this.outputShape=a;let u=Re(s.length),c=Re(a.length),l=\"\";o===1?l=\"i\":o===2&&(l=\"i, j\");let m=`getIndices(${l})`,d=\"\";n===1?d=\"i\":n===2&&(d=\"i, coords[1]\");let f=`getUpdates(${d})`,h=\"\";p&&(h=\"coords[0], coords[1]\");let g=`getDefaultValue(${h})`,x=e>1?\"strides[j]\":\"strides\",b=e>1?\"strides[j + 1]\":\"strides\";this.userCode=`\n ${u} strides = ${u}(${s});\n\n void main() {\n ${c} coords = getOutputCoords();\n vec4 sum = vec4(0.);\n vec4 found = vec4(0.);\n for (int i = 0; i < ${t}; i+=2) {\n ivec2 flattenedIndex = ivec2(0);\n for (int j = 0; j < ${e}; j+=2) {\n ivec4 index = round(${m});\n flattenedIndex += index.xz * ${x};\n if (j + 1 < ${e}) {\n flattenedIndex += index.yw * ${b};\n }\n }\n if (flattenedIndex[0] == coords[0] || flattenedIndex[1] == coords[0] ||\n flattenedIndex[0] == coords[0] + 1 || flattenedIndex[1] == coords[0] + 1) {\n vec4 updVals = ${f};\n if (flattenedIndex[0] == coords[0]) {\n sum.xy += updVals.xy;\n found.xy = vec2(1.);\n } else if (flattenedIndex[0] == coords[0] + 1) {\n sum.zw += updVals.xy;\n found.zw = vec2(1.);\n }\n if (flattenedIndex[1] == coords[0]) {\n sum.xy += updVals.zw;\n found.xy = vec2(1.);\n } else if (flattenedIndex[1] == coords[0] + 1) {\n sum.zw += updVals.zw;\n found.zw = vec2(1.);\n }\n }\n }\n setOutput(mix(${g}, sum, found));\n }\n `}};function kte(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n,updates:s}=t,{shape:a}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(s,n,a),m=[l/u,u];if(l===0)return e.makeTensorInfo(a,n.dtype);let d=te({inputs:{x:n},backend:e,attrs:{shape:[p,i]}}),f=te({inputs:{x:s},backend:e,attrs:{shape:[p,u]}}),h=e.makeTensorInfo([],\"float32\",new Float32Array([0])),g;A().getBool(\"WEBGL_PACK\")?g=new _g(p,i,d.shape.length,f.shape.length,c,m):g=new vu(p,i,d.shape.length,f.shape.length,c,m);let x=e.runWebGLProgram(g,[f,d,h],f.dtype),b=te({inputs:{x},backend:e,attrs:{shape:a}});return e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(x),e.disposeIntermediateTensorInfo(h),b}var R3={kernelName:ds,backendName:\"webgl\",kernelFunc:kte};var $g=class{constructor(t,e,o,n){this.variableNames=[\"sortedSequence\",\"values\"],this.customUniforms=[{name:\"numInputs\",type:\"int\"}],this.outputShape=[t,o];let s=\"while (left < right) {\",a=`for (int i = 0; i < ${Math.ceil(Math.log2(e+1))}; ++i) { if (left >= right) break;`,i=A().getNumber(\"WEBGL_VERSION\")===2?s:a,p=n===\"left\"?\"<\":\"<=\";this.userCode=`\n int findBound(int batch, float value) {\n int left = 0;\n int right = numInputs;\n int mid;\n ${i}\n mid = (left + right) / 2;\n if (getSortedSequence(batch, mid) ${p} value) {\n left = mid + 1;\n } else {\n right = mid;\n }\n }\n return right;\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int valueIndex = coords[1];\n\n float value = getValues(batch, valueIndex);\n\n setOutput(float(findBound(batch, value)));\n }\n `}};function Nte(r){let{inputs:t,backend:e,attrs:o}=r,{sortedSequence:n,values:s}=t,{side:a}=o,i=new $g(n.shape[0],n.shape[1],s.shape[1],a),p=[[n.shape[1]]];return e.runWebGLProgram(i,[n,s],\"int32\",p)}var D3={kernelName:hs,backendName:\"webgl\",kernelFunc:Nte};var Eg=class{constructor(t,e,o){this.variableNames=[\"c\",\"a\",\"b\"],this.outputShape=e;let n,s;if(o>4)throw Error(`Where for rank ${o} is not yet supported`);if(o===1)s=\"resRC\",n=\"resRC\";else{let i=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],p=[],u=[];for(let c=0;c= 1.0) {\n setOutput(getA(${s}));\n } else {\n setOutput(getB(${s}));\n }\n }\n `}};function Tte(r){let{inputs:t,backend:e}=r,{condition:o,t:n,e:s}=t,a=new Eg(o.shape.length,n.shape,n.shape.length);return e.runWebGLProgram(a,[o,n,s],dt(n.dtype,s.dtype))}var A3={kernelName:fa,backendName:\"webgl\",kernelFunc:Tte};var _te=`\n // Stable and Attracting Fixed Point (0, 1) for Normalized Weights.\n // see: https://arxiv.org/abs/1706.02515\n float scaleAlpha = ${w.SELU_SCALEALPHA};\n float scale = ${w.SELU_SCALE};\n return (x >= 0.0) ? scale * x : scaleAlpha * (exp(x) - 1.0);\n`,$te=xe({opSnippet:_te}),F3={kernelName:gs,backendName:\"webgl\",kernelFunc:$te};var Ete=Po+`\n return 1.0 / (1.0 + exp(-1.0 * x));\n`,Rte=`\n vec4 result = 1.0 / (1.0 + exp(-1.0 * x));\n bvec4 isNaN = isnan(x);\n\n result.r = isNaN.r ? x.r : result.r;\n result.g = isNaN.g ? x.g : result.g;\n result.b = isNaN.b ? x.b : result.b;\n result.a = isNaN.a ? x.a : result.a;\n\n return result;\n`,Dte=xe({opSnippet:Ete,packedOpSnippet:Rte,cpuKernelImpl:uD}),P3={kernelName:Cs,backendName:\"webgl\",kernelFunc:Dte};var Ate=`\n if (isnan(x)) { return 0.0; }\n return sign(x);\n`,Fte=xe({opSnippet:Ate}),O3={kernelName:bs,backendName:\"webgl\",kernelFunc:Fte};var Pte=Po+`\n return sin(x);\n`,Ote=`\n vec4 result = sin(x);\n bvec4 isNaN = isnan(x);\n ${Xr}\n return result;\n`,Mte=xe({opSnippet:Pte,packedOpSnippet:Ote}),M3={kernelName:xs,backendName:\"webgl\",kernelFunc:Mte};var Lte=`\n float e2x = exp(x);\n return (e2x - 1.0 / e2x) / 2.0;\n`,Bte=xe({opSnippet:Lte}),L3={kernelName:ys,backendName:\"webgl\",kernelFunc:Bte};var zte=`\n float epsilon = 1.1920928955078125e-7;\n float threshold = log(epsilon) + 2.0;\n\n bool too_large = x > -threshold;\n bool too_small = x < threshold;\n\n float result;\n float exp_x = exp(x);\n\n if (too_large){\n result = x;\n }\n else if (too_small){\n result = exp_x;\n }\n else{\n result = log(exp_x + 1.0);\n }\n return result;\n`,Vte=xe({opSnippet:zte}),B3={kernelName:ws,backendName:\"webgl\",kernelFunc:Vte};var Wte=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,paddings:a}=o;y.assert(n.shape.length<=4,()=>\"spaceToBatchND for rank > 4 with a WebGL backend not implemented yet\");let i=s.reduce((x,b)=>x*b),p=[[0,0]];p.push(...a);for(let x=1+s.length;xe.disposeIntermediateTensorInfo(x)),g},z3={kernelName:ga,backendName:\"webgl\",kernelFunc:Wte};function Ute(r){let{inputs:t,backend:e}=r,{indices:o,values:n,denseShape:s,defaultValue:a}=t;if(s.shape.length!==1)throw new Error(`Dense shape must be a vector, saw:\n ${s.shape}`);if(o.shape.length!==2)throw new Error(`Indices must be a matrix, saw:\n ${o.shape}`);if(n.shape.length!==1)throw new Error(`Values must be a vector, saw:\n ${n.shape}`);if(a.shape.length!==0)throw new Error(`Default value must be a scalar, saw:\n ${a.shape}`);let i=e.readSync(o.dataId),p=e.readSync(n.dataId),u=e.readSync(s.dataId),c=e.readSync(a.dataId)[0],[l,m,d,f,h]=cD(i,o.shape,o.dtype,p,n.dtype,u,c);return[e.makeTensorInfo(m,o.dtype,l),e.makeTensorInfo([m[0]],n.dtype,d),e.makeTensorInfo([f.length],\"bool\",new Uint8Array(f.map(g=>Number(g)))),e.makeTensorInfo([h.length],o.dtype,new Int32Array(h))]}var V3={kernelName:ji,backendName:\"webgl\",kernelFunc:Ute};function Gte(r){let{inputs:t,backend:e}=r,{inputIndices:o,inputShape:n,newShape:s}=t;if(o.shape.length!==2)throw new Error(`Input indices should be a matrix but received shape ${o.shape}`);if(n.shape.length!==1)throw new Error(`Input shape should be a vector but received shape ${n.shape}`);if(s.shape.length!==1)throw new Error(`Target shape should be a vector but received shape ${s.shape}`);let a=Array.from(e.readSync(n.dataId)),i=e.readSync(o.dataId),p=Array.from(e.readSync(s.dataId)),[u,c,l]=lD(i,o.shape,o.dtype,a,p);return[e.makeTensorInfo(c,o.dtype,u),e.makeTensorInfo([l.length],s.dtype,new Int32Array(l))]}var W3={kernelName:ti,backendName:\"webgl\",kernelFunc:Gte};function Hte(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);let a=e.readSync(o.dataId),i=e.readSync(n.dataId),p=e.readSync(s.dataId),[u,c]=lh(a,o.shape,o.dtype,i,p,!0);return e.makeTensorInfo(c,o.dtype,u)}var U3={kernelName:ya,backendName:\"webgl\",kernelFunc:Hte};function Kte(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;if(o.shape.length<1)throw new Error(\"Data should be at least 1 dimensional but received scalar\");if(n.shape.length!==1)throw new Error(`Indices should be a vector but received shape\n ${n.shape}`);if(s.shape.length!==1)throw new Error(`Segment ids should be a vector but received shape\n ${s.shape}`);let a=e.readSync(o.dataId),i=e.readSync(n.dataId),p=e.readSync(s.dataId),[u,c]=lh(a,o.shape,o.dtype,i,p);return e.makeTensorInfo(c,o.dtype,u)}var G3={kernelName:ba,backendName:\"webgl\",kernelFunc:Kte};function qte(r){let{inputs:t,backend:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=t,{outputShape:i}=o,{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=w.calculateShapes(s,n,i),d=!1;if(s.dtype===\"string\"){let x=e.bufferSync(n),b=e.bufferSync(s),C=y.decodeString(e.readSync(a.dataId)[0]),S=iD(x,b,i,m,c,u,p,l,C,d);return e.makeTensorInfo(i,S.dtype,S.values)}let f=new vu(u,p,n.shape.length,s.shape.length,l,[m,1],d),h=e.runWebGLProgram(f,[s,n,a],s.dtype),g=te({inputs:{x:h},backend:e,attrs:{shape:i}});return e.disposeIntermediateTensorInfo(h),g}var H3={kernelName:ks,backendName:\"webgl\",kernelFunc:qte};function jte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=o,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=n.shape.length,c=new Array(u).fill(0),l=n.shape.slice();return p.map(m=>{let d=[...l];d[i]=m;let f=Gs({inputs:{x:n},backend:e,attrs:{begin:c,size:d}});return c[i]+=m,f})}var K3={kernelName:xa,backendName:\"webgl\",kernelFunc:jte};var q3=\"return sqrt(x);\",Xte=xe({opSnippet:q3,packedOpSnippet:q3,cpuKernelImpl:mD}),j3={kernelName:Ss,backendName:\"webgl\",kernelFunc:Xte};var Yte=\"return x * x;\",Qte=xe({opSnippet:Yte}),X3={kernelName:Xi,backendName:\"webgl\",kernelFunc:Qte};var Y3=\"return (a - b) * (a - b);\",Zte=nt({opSnippet:Y3,packedOpSnippet:Y3}),Q3={kernelName:Ns,backendName:\"webgl\",kernelFunc:Zte};function Jte(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t;if(n.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");let s=e.readSync(n.dataId),a=w.fromUint8ToStringArray(s),i=dD(a,\"string\",o);return e.makeTensorInfo(n.shape,\"string\",i)}var Z3={kernelName:Ou,backendName:\"webgl\",kernelFunc:Jte};function ere({inputs:r,attrs:t,backend:e}){let{x:o}=r,n=Ut+`\n return x > 0.0 ? 1.0 : float(${t.alpha});\n `,s=new or(o.shape,n);return e.runWebGLProgram(s,[o],o.dtype)}var J3={kernelName:So,backendName:\"webgl\",kernelFunc:ere};var Rg=class{constructor(t,e,o){this.variableNames=[\"x\"],this.outputShape=o;let n=o.length,s=Re(o.length),a=Re(o.length),i=\"\";if(n===1)i=\"coords * strides + begin\";else{let p=0;i=o.map((u,c)=>(p++,o.length===1?`coords * strides[${c}] + begin[${c}]`:`coords[${p-1}] * strides[${c}] + begin[${c}]`)).join(\",\")}this.userCode=`\n ${s} begin = ${s}(${t});\n ${s} strides = ${s}(${e});\n\n void main() {\n ${a} coords = getOutputCoords();\n setOutput(getX(${i}));\n }\n `}};function tre(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o,{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=te({inputs:{x:n},backend:e,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let E=ct.computeOutShape(b,C,S),R=Gs({inputs:{x:n},backend:e,attrs:{begin:b,size:E}});k=te({inputs:{x:R},backend:e,attrs:{shape:f}}),e.disposeIntermediateTensorInfo(R)}else if(e.shouldExecuteOnCPU([n])){let R=e.readSync(n.dataId),D=me(n.shape,n.dtype,R),P=fD(d,D,S,b);k=e.makeTensorInfo(f,n.dtype,P.values)}else{let R=new Rg(b,S,d);k=e.runWebGLProgram(R,[n],n.dtype)}let _=te({inputs:{x:k},backend:e,attrs:{shape:f}});return e.disposeIntermediateTensorInfo(k),_}var eP={kernelName:Ts,backendName:\"webgl\",kernelFunc:tre};function rre(r){let{inputs:t,backend:e,attrs:o}=r,{separator:n,nGramWidths:s,leftPad:a,rightPad:i,padWidth:p,preserveShortSequences:u}=o,{data:c,dataSplits:l}=t,m=e.readSync(c.dataId),d=e.readSync(l.dataId),[f,h]=hD(m,d,n,s,a,i,p,u);return[e.makeTensorInfo([f.length],\"string\",f),e.makeTensorInfo(l.shape,\"int32\",h)]}var tP={kernelName:Ca,backendName:\"webgl\",kernelFunc:rre};function ore(r){let{inputs:t,backend:e,attrs:o}=r,{skipEmpty:n}=o,{input:s,delimiter:a}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(s.shape.length!==1)throw new Error(`Input must be a vector, got shape: ${s.shape}`);if(a.shape.length!==0)throw new Error(`Delimiter must be a scalar, got shape: ${a.shape}`);let i=e.readSync(s.dataId),p=e.readSync(a.dataId)[0],[u,c,l]=gD(i,p,n),m=c.length;return[e.makeTensorInfo([m,2],\"int32\",u),e.makeTensorInfo([m],\"string\",c),e.makeTensorInfo([2],\"int32\",new Int32Array(l))]}var rP={kernelName:Yi,backendName:\"webgl\",kernelFunc:ore};function nre(r){let{inputs:t,backend:e,attrs:o}=r,{numBuckets:n}=o,{input:s}=t;if(s.dtype!==\"string\")throw new Error(\"Input must be of datatype string\");if(n<=0)throw new Error(\"Number of buckets must be at least 1\");let a=e.readSync(s.dataId),i=xD(a,n);return e.makeTensorInfo(s.shape,\"int32\",i)}var oP={kernelName:Qi,backendName:\"webgl\",kernelFunc:nre};var sre=\"return tan(x);\",are=xe({opSnippet:sre}),nP={kernelName:$s,backendName:\"webgl\",kernelFunc:are};var ire=`\n float e2x = exp(-2.0 * abs(x));\n return sign(x) * (1.0 - e2x) / (1.0 + e2x);\n`,ure=xe({opSnippet:ire}),sP={kernelName:Es,backendName:\"webgl\",kernelFunc:ure};function pre(r){let{inputs:t,backend:e,attrs:o}=r,{tensor:n,indices:s,updates:a}=t,{}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(a,s,n.shape),m=[l/u,u];if(l===0)return e.makeTensorInfo(n.shape,s.dtype);let d=te({inputs:{x:s},backend:e,attrs:{shape:[p,i]}}),f=te({inputs:{x:a},backend:e,attrs:{shape:[p,u]}}),h=te({inputs:{x:n},backend:e,attrs:{shape:m}}),g=new vu(p,i,d.shape.length,f.shape.length,c,m,!1,!0),x=e.runWebGLProgram(g,[f,d,h],h.dtype),b=te({inputs:{x},backend:e,attrs:{shape:n.shape}});return e.disposeIntermediateTensorInfo(d),e.disposeIntermediateTensorInfo(f),e.disposeIntermediateTensorInfo(h),e.disposeIntermediateTensorInfo(x),b}var aP={kernelName:fs,backendName:\"webgl\",kernelFunc:pre};var Dg=class{constructor(t,e){this.variableNames=[\"A\"];let o=new Array(t.length);for(let a=0;a5)throw Error(`Tile for rank ${t} is not yet supported`);if(t===1)return`imod(resRC, ${r[0]})`;let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\",\"resRC.u\"],o=[];for(let n=0;n5){let p=e.readSync(n.dataId),u=n.dtype===\"string\"?p.map(m=>y.decodeString(m)):p,c=me(n.shape,n.dtype,u),l=bD(c,s);return e.makeTensorInfo(l.shape,l.dtype,l.values)}let a=new Dg(n.shape,s);return e.runWebGLProgram(a,[n],n.dtype)}var iP={kernelName:po,backendName:\"webgl\",kernelFunc:Dv};var Ag=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.customUniforms=[{name:\"n\",type:\"int\"},{name:\"firstPass\",type:\"int\"},{name:\"negativeInf\",type:\"float\"},{name:\"dir\",type:\"int\"},{name:\"inc\",type:\"int\"}],this.outputShape=t,this.userCode=`\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int elemIdx = coords[1];\n\n // We compare elements pair-wise within a group of size 2 * inc.\n // The comparing rule for each group alternates between ascending\n // and descending. Within each group, we compare each pair at\n // positions i and i+inc. To decide whether an element at position i\n // is x0 or x1, we mod it by 2 * inc, if the result is smaller than\n // inc, it is in the first half of the group, we denote it as x0,\n // otherwise we denote it as x1.\n // For example, as shown in the Bitonic top K paper referenced above,\n // Figure5(a) shows that element[1] is in the\n // second half of the group when group size is 2, but it is in the\n // first half of the group when group size is 4.\n\n bool isFirstInPair = imod(elemIdx, 2 * inc) < inc;\n int i = isFirstInPair ? elemIdx : elemIdx - inc;\n\n int i0 = firstPass == 1 ? i : int(getIndices(batch, i));\n int i1 = firstPass == 1 ? i + inc : int(getIndices(batch, i + inc));\n float x0 = i0 < n ? getX(batch, i0) : negativeInf;\n float x1 = i1 < n ? getX(batch, i1) : negativeInf;\n\n // Denotes which direction indices are in (ascending or descending).\n bool reverse = imod(elemIdx, 2 * dir) >= dir;\n bool isGreater = x0 > x1 || (x0 == x1 && i1 > i0);\n if (reverse == isGreater) { // Elements in opposite order of direction\n int iTemp = i0;\n i0 = i1;\n i1 = iTemp;\n }\n if (isFirstInPair) {\n setOutput(float(i0));\n } else {\n setOutput(float(i1));\n }\n }\n `}},Fg=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.customUniforms=[{name:\"n\",type:\"int\"},{name:\"firstPass\",type:\"int\"},{name:\"k\",type:\"int\"}],this.outputShape=t,this.userCode=`\n void main() {\n // Takes max of indices (0, k), (1, k + 1), (2, k + 2) ...\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int elemIdx = coords[1];\n\n // The output size is half of the previous size.\n // If the previous sequence is | | | | _ _ _ _ | | | | _ _ _ _ (k=4),\n // we only need to output the indices at positions |, the indices at\n // positions _ can be thrown away, see Figure5(b) After Phase 2\n // (Merge phase) in the Bitonic Top K paper referenced above.\n // For example, the paper shows we only need to output the orange bars.\n // The output sequence should look like this | | | | | | | |.\n // Because the sequence is halved, to map the output index back\n // to the previous sequence to find the corresponding value,\n // we need to double the index. When we double the index,\n // we basically interpolate a position, so 2i looks like\n // | _ | _ | _ | _ | _ | _ | _. We move the | to the first k position\n // of each 2k positions by - elemIdx % k. E.g. for output at\n // index 4,5,6,7, we want to get the corresponding element at\n // original index 8,9,10,11, for output at index 8,9,10,11,\n // we want to get the corresponding element at original index\n // 16,17,18,19, so on and so forth.\n\n int i = elemIdx < k ? elemIdx : (elemIdx * 2 - imod(elemIdx, k));\n int i0 = firstPass == 1 ? i : int(getIndices(batch, i));\n int i1 = firstPass == 1 ? i + k : int(getIndices(batch, i + k));\n\n float x0 = getX(batch, i0);\n float x1 = i1 < n ? getX(batch, i1) : x0;\n\n setOutput(x0 >= x1 ? float(i0) : float(i1));\n }\n `}};function Rp(r,t){t!==null&&r.disposeIntermediateTensorInfo(t)}function uP(r){let t=1;for(;tp){let P=e.readSync(n.dataId),[O,M]=CD(P,u,n.dtype,s,a);return[e.makeTensorInfo(O.shape,O.dtype,O.values),e.makeTensorInfo(M.shape,M.dtype,M.values)]}if(s===0)return u[u.length-1]=0,[e.makeTensorInfo(u,n.dtype,[]),e.makeTensorInfo(u,\"int32\",[])];if(c===1)return[n,Si({attrs:{shape:u,dtype:\"int32\",value:0},backend:e})];let l=e.texData.get(n.dataId),m=l!==null&&l.isPacked,d=m?e.unpackTensor(n):n,h=y.sizeFromShape(u)/c,g=te({inputs:{x:d},attrs:{shape:[h,c]},backend:e});m&&Rp(e,d);let x=uP(s),b=uP(c),C=null,S=()=>C===null?[g,g]:[g,C],k=(P,O,M)=>{let L=S(),B=new Ag(M),U=[[c],[C===null?1:0],[Number.NEGATIVE_INFINITY],[P],[O]],j=C;C=e.runWebGLProgram(B,L,\"int32\",U),Rp(e,j)};for(let P=1;P=1;M/=2)k(O,M,[h,b])}for(let P=b;P>x;P/=2){let O=S(),M=new Fg([h,P/2]),B=[[c],[C===null?1:0],[x]],z=C;C=e.runWebGLProgram(M,O,\"int32\",B),Rp(e,z);let U=x/2,j=U*2;for(let q=U;q>=1;q/=2)k(j,q,C.shape)}let _=C;C=Gs({inputs:{x:C},backend:e,attrs:{begin:0,size:[h,s]}}),Rp(e,_);let E=kv({inputs:{x:g,indices:C},backend:e,attrs:{axis:1,batchDims:1}});Rp(e,g);let R=u.slice(0,-1);R.push(s),_=C,C=te({inputs:{x:C},attrs:{shape:R},backend:e}),Rp(e,_);let D=E;return E=te({inputs:{x:E},attrs:{shape:R},backend:e}),Rp(e,D),[E,C]}var pP={kernelName:Rs,backendName:\"webgl\",kernelFunc:lre};var Pg=class{constructor(t,e,o,n,s,a){this.variableNames=[\"Image\",\"Transforms\"],this.outputShape=a;let i=o===\"nearest\"?1:2,p;switch(n){case\"constant\":p=1;break;case\"reflect\":p=2;break;case\"wrap\":p=3;break;case\"nearest\":p=4;break;default:p=1;break}this.userCode=`\n float mapCoord(float outCoord, float len) {\n float inCoord = outCoord;\n if(${p} == 2) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz2 = 2.0 * len;\n if (inCoord < sz2) {\n inCoord = sz2 * float(int(float(-inCoord / sz2))) +\n inCoord;\n }\n inCoord = inCoord < -len ? inCoord + sz2 : -inCoord - 1.0;\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz2 = 2.0 * len;\n inCoord -= sz2 * float(int(float(inCoord / sz2)));\n if (inCoord >= len) {\n inCoord = sz2 - inCoord - 1.0;\n }\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (${p} == 3) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz = len - 1.0;\n inCoord += len * (float(int(float(-inCoord / sz))) + 1.0);\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n float sz = len - 1.0;\n inCoord -= len * float(int(float(inCoord / sz)));\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (${p} == 4) {\n return clamp(outCoord, 0.0, len - 1.0);\n } else {\n return outCoord;\n }\n }\n\n float readWithFillValue(int batch, int coordY, int coordX,\n int channel) {\n float outputValue;\n if (0 <= coordY && coordY < ${t} && 0 <= coordX && coordX < ${e}) {\n outputValue = getImage(batch, coordY, coordX, channel);\n } else {\n outputValue = float(${s});\n }\n return outputValue;\n }\n\n void main() {\n ivec4 coords = getOutputCoords();\n float outputValue;\n int batch = coords[0];\n int x = coords[2];\n int y = coords[1];\n int channel = coords[3];\n float xf = float(x);\n float yf = float(y);\n float a1 = getTransforms(batch, 0);\n float a2 = getTransforms(batch, 1);\n float a3 = getTransforms(batch, 2);\n float b1 = getTransforms(batch, 3);\n float b2 = getTransforms(batch, 4);\n float b3 = getTransforms(batch, 5);\n float c1 = getTransforms(batch, 6);\n float c2 = getTransforms(batch, 7);\n float projection = c1 * xf + c2 * yf + 1.0;\n if (projection == 0.0) {\n outputValue = float(${s});\n } else {\n float inX = (a1 * xf + a2 * yf + a3) / projection;\n float inY = (b1 * xf + b2 * yf + b3) / projection;\n float mapX = mapCoord(inX, float(${e}));\n float mapY = mapCoord(inY, float(${t}));\n\n if (${i} == 1) {\n int coordY = int(round(mapY));\n int coordX = int(round(mapX));\n outputValue = readWithFillValue(batch, coordY, coordX,\n channel);\n } else {\n float yFloor = floor(mapY);\n float xFloor = floor(mapX);\n float yCeil = yFloor + 1.0;\n float xCeil = xFloor + 1.0;\n float valueYFloor = (xCeil - mapX) *\n readWithFillValue(batch, int(yFloor), int(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, int(yFloor), int(xCeil), channel);\n float valueYCeil = (xCeil - mapX) *\n readWithFillValue(batch, int(yCeil), int(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, int(yCeil), int(xCeil), channel);\n outputValue = (yCeil - mapY) * valueYFloor +\n (mapY - yFloor) * valueYCeil;\n }\n }\n setOutput(outputValue);\n }\n `}};function mre(r){let{inputs:t,backend:e,attrs:o}=r,{image:n,transforms:s}=t,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=o,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=new Pg(l,m,a,i,p,g);return e.runWebGLProgram(x,[n,s],\"float32\")}var cP={kernelName:Ds,backendName:\"webgl\",kernelFunc:mre};function dre(r){let{inputs:t,attrs:e,backend:o}=r,{axis:n}=e,{x:s}=t;Vs(s,\"unique\"),console.warn(\"WARNING: \",\"UI might be locked temporarily as data is being downloaded\");let a=o.readSync(s.dataId),{outputValues:i,outputShape:p,indices:u}=wD(a,n,s.shape,s.dtype);return[o.makeTensorInfo(p,s.dtype,i),o.makeTensorInfo([u.length],\"int32\",u)]}var lP={kernelName:Zi,backendName:\"webgl\",kernelFunc:dre};function fre(r){let{inputs:t,backend:e,attrs:o}=r,{value:n}=t,{axis:s}=o;s<0&&(s+=n.shape.length);let a=n,i=a.shape.length,p=n.shape[s],u=new Array(i-1),c=0;for(let h=0;he.disposeIntermediateTensorInfo(h)),f}var mP={kernelName:wa,backendName:\"webgl\",kernelFunc:fre};var Og=class{constructor(t,e){this.variableNames=[\"x\",\"segmentIds\"];let o=t.windowSize,n=t.batchSize,s=t.inSize,a=t.numSegments,i=a*Math.ceil(s/o);this.outputShape=[n,i];let p=\"0.0\",u=\"sumValue\",c=Math.floor(o/4)*4,l=o%4,m=`\n sumValue += dot(values, segFilter);\n `,d=\"\";s%o>0&&(d=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return initializationValue;\n }\n `);let f=\"\";s%o>0&&(f=`\n if (inIdx < 0 || inIdx >= ${s}) {\n return -1.0;\n }\n `),this.userCode=`\n const float initializationValue = ${p};\n\n float getValue(int batch, int inIdx) {\n ${d}\n return getX(batch, inIdx);\n }\n\n float getSegmentIdAtIndex(int inIdx) {\n ${f}\n return getSegmentIds(inIdx);\n }\n\n void main() {\n ivec2 coords = getOutputCoords();\n int batch = coords[0];\n int outIdx = coords[1];\n int inOffset = int(floor(float(outIdx) / float(\n ${a})) * float(${o}));\n int currentSeg = int(mod(float(outIdx), float(${a})));\n\n float sumValue = 0.0;\n\n for (int i = 0; i < ${c}; i += 4) {\n int inIdx = inOffset + i;\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n getValue(batch, inIdx + 3)\n );\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 1)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 2)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 3)) == currentSeg ? 1 : 0\n );\n\n ${m}\n }\n\n int inIdx = inOffset + ${c};\n if (${l===1}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n initializationValue,\n initializationValue,\n initializationValue\n );\n\n int inIdxSeg = int(getSegmentIdAtIndex(inIdx));\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n 0,\n 0,\n 0\n );\n\n ${m}\n } else if (${l===2}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n initializationValue,\n initializationValue\n );\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 1)) == currentSeg ? 1 : 0,\n 0,\n 0\n );\n\n ${m}\n } else if (${l===3}) {\n vec4 values = vec4(\n getValue(batch, inIdx),\n getValue(batch, inIdx + 1),\n getValue(batch, inIdx + 2),\n initializationValue\n );\n\n vec4 segFilter = vec4(\n int(getSegmentIdAtIndex(inIdx)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 1)) == currentSeg ? 1 : 0,\n int(getSegmentIdAtIndex(inIdx + 2)) == currentSeg ? 1 : 0,\n 0\n );\n\n ${m}\n }\n setOutput(${u});\n }\n `}};function hre(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,segmentIds:s}=t,{numSegments:a}=o,i=n.shape.length,p=[],u=0,c=w.getAxesPermutation([u],i),l=n;c!=null&&(l=Ct({inputs:{x:n},backend:e,attrs:{perm:c}}),p.push(l),u=w.getInnerMostAxes(1,i)[0]);let m=w.segment_util.computeOutShape(l.shape,u,a),d=y.sizeFromShape([l.shape[u]]),f=te({inputs:{x:l},backend:e,attrs:{shape:[-1,d]}});p.push(f);let h=ni(n.dtype),g=(S,k,_,E,R)=>{let D=S.shape[0],P=S.shape[1],O=w.segment_util.segOpComputeOptimalWindowSize(P,R),M={windowSize:O,inSize:P,batchSize:D,numSegments:R},L=new Og(M,k),B=e.compileAndRun(L,[S,_],E);if(p.push(B),B.shape[1]===R)return B;let z=Rv({backend:e,attrs:{start:0,stop:R,step:1,dtype:\"float32\"}}),U=Dv({inputs:{x:z},backend:e,attrs:{reps:[P/O]}});return p.push(z),p.push(U),g(B,k,U,E,R)},x=g(f,\"unsortedSegmentSum\",s,h,a),b=te({inputs:{x},backend:e,attrs:{shape:m}}),C=b;if(c!=null){p.push(b);let S=w.getUndoAxesPermutation(c);C=Ct({inputs:{x:C},backend:e,attrs:{perm:S}})}return p.forEach(S=>e.disposeIntermediateTensorInfo(S)),C}var dP={kernelName:Ji,backendName:\"webgl\",kernelFunc:hre};var gre=[XD,QD,ZD,JD,tA,rA,oA,nA,iA,uA,pA,cA,lA,mA,dA,fA,hA,gA,xA,yA,bA,wA,SA,IA,vA,_A,EA,RA,BD,AA,PA,OA,MA,LA,BA,zA,VA,WA,UA,GA,qA,jA,XA,YA,QA,ZA,JA,eF,tF,rF,oF,nF,sF,aF,iF,uF,cF,lF,mF,dF,hF,gF,xF,yF,bF,CF,wF,SF,IF,LD,vF,FA,kF,NF,TF,zD,_F,$F,EF,RF,DF,AF,FF,PF,OF,MF,BF,zF,VF,WF,UF,GF,KF,jF,XF,YF,QF,ZF,o3,UD,n3,s3,a3,i3,kA,u3,l3,m3,d3,f3,VD,h3,g3,x3,y3,b3,NA,JF,C3,w3,S3,HD,I3,v3,k3,N3,T3,_3,$3,E3,R3,D3,A3,F3,P3,O3,M3,L3,CA,r3,B3,z3,V3,W3,U3,G3,H3,K3,j3,X3,Q3,Z3,J3,eP,tP,rP,oP,t3,qD,nP,sP,aP,iP,pP,cP,jD,lP,mP,dP,p3];for(let r of gre)ri(r);var we;(function(r){r[r.float32=0]=\"float32\",r[r.int32=1]=\"int32\",r[r.bool=2]=\"bool\",r[r.string=3]=\"string\",r[r.complex64=4]=\"complex64\"})(we||(we={}));var ku;(function(r){r[r.linear=0]=\"linear\",r[r.relu=1]=\"relu\",r[r.relu6=2]=\"relu6\",r[r.prelu=3]=\"prelu\",r[r.leakyrelu=4]=\"leakyrelu\",r[r.sigmoid=5]=\"sigmoid\",r[r.elu=6]=\"elu\"})(ku||(ku={}));var fP;function xre(r){fP=r.wasm.cwrap(Io,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function yre(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s,bias:a,preluActivationWeights:i}=t;if(n.dtype!==\"float32\"||s.dtype!==\"float32\")throw new Error(\"_FusedMatMul for non non-float32 tensors not yet supported.\");let{transposeA:p,transposeB:u,activation:c,leakyreluAlpha:l}=o,m=e.dataIdMap.get(n.dataId).id,d=e.dataIdMap.get(s.dataId).id,f=0;if(a!=null){let R=e.dataIdMap.get(a.dataId);if(R.shape.length!==1)throw new Error(`_FusedMatMul only supports rank-1 bias but got rank ${R.shape.length}.`);f=R.id}let h=i==null?0:e.dataIdMap.get(i.dataId).id,g=ku[c];if(g==null)throw new Error(`${c} activation not yet supported for FusedConv2D in the wasm backend.`);let x=p?n.shape[2]:n.shape[1],b=u?s.shape[1]:s.shape[2],C=Ir.assertAndGetBroadcastShape(n.shape.slice(0,-2),s.shape.slice(0,-2)),S=e.makeOutput([...C,x,b],n.dtype),k=e.dataIdMap.get(S.dataId).id,_=new Uint8Array(new Int32Array(n.shape).buffer),E=new Uint8Array(new Int32Array(s.shape).buffer);return fP(m,_,n.shape.length,d,E,s.shape.length,p,u,g,f,h,l||0,k),S}var hP={kernelName:Io,backendName:\"wasm\",setupFunc:xre,kernelFunc:yre};function he(r,t){let e;function o(s){e=s.wasm.cwrap(r,null,[\"number\",\"number\",\"number\"])}function n(s){let{backend:a,inputs:{x:i}}=s,p=a.dataIdMap.get(i.dataId).id,u=a.makeOutput(i.shape,t||i.dtype),c=a.dataIdMap.get(u.dataId).id;return y.sizeFromShape(u.shape)===0||e(p,we[i.dtype],c),u}return{kernelName:r,backendName:\"wasm\",setupFunc:o,kernelFunc:n}}var gP=he(Xs);var xP=he(Wo);var yP=he(Uo);function Ue(r,t,e){let o;function n(a){o=a.wasm.cwrap(r,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\"])}function s(a){let{backend:i,inputs:p}=a,{a:u,b:c}=p,l=i.dataIdMap.get(u.dataId).id,m=i.dataIdMap.get(c.dataId).id,d=e!=null?e:u.dtype,f=w.assertAndGetBroadcastShape(u.shape,c.shape),h=i.makeOutput(f,d);if(y.sizeFromShape(f)===0)return h;let g=new Uint8Array(new Int32Array(u.shape).buffer),x=new Uint8Array(new Int32Array(c.shape).buffer),b=i.dataIdMap.get(h.dataId).id;return(()=>o(l,g,u.shape.length,m,x,c.shape.length,we[u.dtype],b))(),h}return{kernelName:r,backendName:\"wasm\",setupFunc:n,kernelFunc:s}}var bre=!0,bP=Ue(uo,bre);var CP;function Cre(r){CP=r.wasm.cwrap(Go,null,[\"array\",\"number\",\"number\",\"number\"])}function wre(r){let{inputs:t,backend:e}=r,o=e.makeOutput(t[0].shape,t[0].dtype);if(y.sizeFromShape(o.shape)===0)return o;let n=t.map(i=>e.dataIdMap.get(i.dataId).id),s=new Uint8Array(new Int32Array(n).buffer),a=e.dataIdMap.get(o.dataId).id;return CP(s,n.length,we[o.dtype],a),o}var wP={kernelName:Go,backendName:\"wasm\",setupFunc:Cre,kernelFunc:wre};function Dp(r){let{inputs:{x:t},backend:e}=r;if(t.dtype===\"string\")return ur(e.readSync(t.dataId),t.shape,t.dtype);let o=e.makeOutput(t.shape,t.dtype),n=e.typedArrayFromHeap(t);return e.typedArrayFromHeap(o).set(n),o}var SP={kernelName:wo,backendName:\"wasm\",kernelFunc:Dp};var IP;function Sre(r){IP=r.wasm.cwrap(co,null,[\"number\",\"array\",\"number\",\"number\",\"number\",\"array\",\"number\"])}function go(r){let{inputs:t,backend:e,attrs:o}=r,[n,s]=vre(t.x.shape,o.perm),a=!0;for(let f=0;f=n&&(s===-1||o[s]>o[a])&&(s=a);o[s]=n}return[e,o]}var vP={kernelName:co,backendName:\"wasm\",kernelFunc:go,setupFunc:Sre};function _r(r,t,e){let o=r.shape,n=r.shape.length,s=y.parseAxisParam(t,o),a=s,i=w.getAxesPermutation(a,n),p=null,u=!1;if(i!=null){let c=new Array(n);for(let d=0;d`new shape: ${a}, old shape: ${o.shape}. New shape and old shape must have the same number of elements.`),r.backend.incRef(o.dataId),{dataId:o.dataId,shape:a,dtype:o.dtype}}var GP={kernelName:da,backendName:\"wasm\",kernelFunc:Vt};var HP;function Mre(r){HP=r.wasm.cwrap(Jo,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\",\"number\"])}function Lre(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;if(n.dtype!==\"float32\"||s.dtype!==\"float32\")throw new Error(\"BatchMatMul for non non-float32 tensors not yet supported.\");let p=n.shape.length,u=s.shape.length,c=a?n.shape[p-2]:n.shape[p-1],l=i?s.shape[u-1]:s.shape[u-2],m=a?n.shape[p-1]:n.shape[p-2],d=i?s.shape[u-2]:s.shape[u-1],f=n.shape.slice(0,-2),h=s.shape.slice(0,-2),g=y.sizeFromShape(f),x=y.sizeFromShape(h),C=Ir.assertAndGetBroadcastShape(n.shape.slice(0,-2),s.shape.slice(0,-2)).concat([m,d]);y.assert(c===l,()=>`Error in matMul: inner shapes (${c}) and (${l}) of Tensors with shapes ${n.shape} and ${s.shape} and transposeA=${a} and transposeB=${i} must match.`);let S=a?[g,c,m]:[g,m,c],k=i?[x,d,l]:[x,l,d],_=Vt({inputs:{x:n},backend:e,attrs:{shape:S}}),E=Vt({inputs:{x:s},backend:e,attrs:{shape:k}}),R=e.dataIdMap.get(_.dataId).id,D=e.dataIdMap.get(E.dataId).id,P=a?_.shape[2]:_.shape[1],O=i?E.shape[1]:E.shape[2],M=Math.max(g,x),L=e.makeOutput([M,P,O],_.dtype),B=e.dataIdMap.get(L.dataId).id,z=new Uint8Array(new Int32Array(_.shape).buffer),U=new Uint8Array(new Int32Array(E.shape).buffer);return HP(R,z,_.shape.length,D,U,E.shape.length,a,i,B),e.disposeData(_.dataId),e.disposeData(E.dataId),L.shape=C,L}var KP={kernelName:Jo,backendName:\"wasm\",setupFunc:Mre,kernelFunc:Lre};function Oo(r){let{inputs:{x:t},attrs:{begin:e,size:o},backend:n}=r,[s,a]=ct.parseSliceParams(t,e,o),i=ct.isSliceContinous(t.shape,s,a),p=n.readSync(t.dataId),u=n.makeOutput(a,t.dtype),c=y.computeStrides(t.shape),l=n.dataIdMap.get(u.dataId);if(i){let f=ct.computeFlatOffset(s,c);return t.dtype===\"string\"?l.stringBytes=p.slice(f,f+y.sizeFromShape(a)):n.typedArrayFromHeap(u).set(p.subarray(f,f+y.sizeFromShape(a))),u}if(t.dtype===\"string\"){let f=hp(p,s,a,t.shape,t.dtype);return l.stringBytes=f,u}let m=n.typedArrayFromHeap(u),d=t.shape.length;if(d===2)Bre(p,c[0],m,s,a);else if(d===3)zre(p,c[0],c[1],m,s,a);else if(d===4)Vre(p,c[0],c[1],c[2],m,s,a);else{let f=hp(p,s,a,t.shape,t.dtype);m.set(f)}return u}function Bre(r,t,e,o,n){let s=0,a=o[0],i=o[1],p=a+n[0];for(let u=a;ux*b),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=Vt({inputs:{x:n},backend:e,attrs:{shape:p}}),f=go({inputs:{x:d},backend:e,attrs:{perm:u}}),h=Vt({inputs:{x:f},backend:e,attrs:{shape:c}}),g=Oo({inputs:{x:h},backend:e,attrs:{begin:l,size:m}});return e.disposeData(d.dataId),e.disposeData(f.dataId),e.disposeData(h.dataId),g}var jP={kernelName:Js,backendName:\"wasm\",kernelFunc:Wre};var XP;function Ure(r){XP=r.wasm.cwrap(en,null,[\"number\",\"number\",\"boolean\",\"number\",\"number\",\"number\"])}function Gre(r){let{backend:t,inputs:e,attrs:o}=r,{x:n,weights:s}=e,{size:a}=o,i=s.shape.reduce((l,m)=>l*m,1)!==0,p=n.shape.length===1?[a]:[n.shape[0],a],u=t.makeOutput(p,s.dtype);function c(l){return t.dataIdMap.get(l.dataId).id}return XP(c(n),a,i,c(s),we[s.dtype],c(u)),u}var YP={kernelName:en,backendName:\"wasm\",setupFunc:Ure,kernelFunc:Gre};var Hre=!0,QP=Ue(ja,Hre);function Kre(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t,s=e.typedArrayFromHeap(o),a=e.typedArrayFromHeap(n),i=w.assertAndGetBroadcastShape(Array.from(s),Array.from(a));return e.makeOutput([i.length],\"int32\",void 0,new Int32Array(i))}var ZP={kernelName:ea,backendName:\"wasm\",kernelFunc:Kre};function Mr(r){let{inputs:{x:t},attrs:{dtype:e},backend:o}=r,n=o.makeOutput(t.shape,e),s=o.typedArrayFromHeap(t);return o.typedArrayFromHeap(n).set(s),n}var JP={kernelName:bo,backendName:\"wasm\",kernelFunc:Mr};var eO=he(tn);var tO;function qre(r){tO=r.wasm.cwrap(Co,null,[\"number\",\"number\",\"number\",\"number\"])}function jre(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{clipValueMin:s,clipValueMax:a}=o,i=e.dataIdMap.get(n.dataId).id,p=e.makeOutput(n.shape,n.dtype),u=e.dataIdMap.get(p.dataId).id;return tO(i,s,a,u),p}var rO={kernelName:Co,backendName:\"wasm\",setupFunc:qre,kernelFunc:jre};function Av(r){let{inputs:t,backend:e}=r,o=y.parseAxisParam(r.attrs.axis,t[0].shape)[0],n=t.map(d=>d.shape);w.assertParamsConsistent(n,o);let s=w.computeOutShape(t.map(d=>d.shape),o),a=t.filter(d=>y.sizeFromShape(d.shape)>0);if(a.length===1)return Dp({inputs:{x:a[0]},backend:e});let i=e.makeOutput(s,t[0].dtype);if(y.sizeFromShape(s)===0)return i;if(a[0].dtype===\"string\"){let d=a.map(C=>{let k=[-1,y.sizeFromShape(C.shape.slice(o))];return Vt({inputs:{x:C},backend:e,attrs:{shape:k}})}),f=d.map(C=>({vals:e.readSync(C.dataId),shape:C.shape}));s=w.computeOutShape(d.map(C=>C.shape),1);let h=d[0].shape[0]===1,g=mp(f,s,t[0].dtype,h),x=w.computeOutShape(a.map(C=>C.shape),o);i.shape=x;let b=e.dataIdMap.get(i.dataId);return b.stringBytes=w.fromStringArrayToUint8(g),d.forEach(C=>e.disposeData(C.dataId)),i}let p=y.sizeFromShape(a[0].shape.slice(0,o)),u=0,c=a.map(d=>{let f=y.sizeFromShape(d.shape.slice(o));return u+=f,f}),l=a.map(d=>e.typedArrayFromHeap(d)),m=e.typedArrayFromHeap(i);for(let d=0;d`cumprod does not support ${n.dtype} tensors in the WASM backend`);let u=w.getAxesPermutation([s],p),c=n;u!==null&&(c=go({inputs:{x:n},attrs:{perm:u},backend:e}));let l=w.getInnerMostAxes(1,p)[0];w.assertAxesAreInnerMostDims(\"cumprod\",[l],p);let m=e.makeOutput(c.shape,c.dtype),d=c.shape[l],f=e.dataIdMap.get(c.dataId).id,h=e.dataIdMap.get(m.dataId).id;yO(f,a?1:0,i?1:0,d,h,we[n.dtype]);let g=m;if(u!==null){let x=w.getUndoAxesPermutation(u);g=go({inputs:{x:m},attrs:{perm:x},backend:e}),e.disposeData(c.dataId),e.disposeData(m.dataId)}return g}var bO={kernelName:pn,backendName:\"wasm\",setupFunc:ioe,kernelFunc:uoe};var CO;function poe(r){CO=r.wasm.cwrap(cn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function coe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o,p=n.shape.length;y.assert(n.dtype===\"float32\"||n.dtype===\"int32\",()=>`cumsum does not support ${n.dtype} tensors in the WASM backend`);let u=w.getAxesPermutation([s],p),c=n;u!==null&&(c=go({inputs:{x:n},attrs:{perm:u},backend:e}));let l=w.getInnerMostAxes(1,p)[0];w.assertAxesAreInnerMostDims(\"cumsum\",[l],p);let m=e.makeOutput(c.shape,c.dtype),d=c.shape[l],f=e.dataIdMap.get(c.dataId).id,h=e.dataIdMap.get(m.dataId).id;CO(f,a?1:0,i?1:0,d,h,we[n.dtype]);let g=m;if(u!==null){let x=w.getUndoAxesPermutation(u);g=go({inputs:{x:m},attrs:{perm:x},backend:e}),e.disposeData(c.dataId),e.disposeData(m.dataId)}return g}var wO={kernelName:cn,backendName:\"wasm\",setupFunc:poe,kernelFunc:coe};var SO;function loe(r){SO=r.wasm.cwrap(\"DenseBincount\",null,[\"number\",\"array\",\"number\",\"number\",\"boolean\",\"number\",\"number\",\"boolean\",\"number\"])}function moe(r){let{backend:t,inputs:e,attrs:o}=r,{x:n,weights:s}=e,{size:a,binaryOutput:i}=o,p=s.shape.reduce((m,d)=>m*d,1)!==0,u=n.shape.length===1?[a]:[n.shape[0],a],c=t.makeOutput(u,s.dtype);function l(m){return t.dataIdMap.get(m.dataId).id}return SO(l(n),new Uint8Array(new Int32Array(n.shape).buffer),n.shape.length,a,p,l(s),we[s.dtype],i,l(c)),c}var IO={kernelName:ra,backendName:\"wasm\",setupFunc:loe,kernelFunc:moe};var vO;function doe(r){vO=r.wasm.cwrap(mn,null,[\"number\",\"number\",\"number\",\"array\",\"number\",\"array\",\"array\",\"number\",\"number\"])}function foe(r){let{backend:t,inputs:e,attrs:o}=r,{x:n}=e,{blockSize:s,dataFormat:a}=o,i=n.shape[0],p=a===\"NHWC\"?n.shape[1]:n.shape[2],u=a===\"NHWC\"?n.shape[2]:n.shape[3],c=a===\"NHWC\"?n.shape[3]:n.shape[1],l=p*s,m=u*s,d=c/(s*s),f=a===\"NHWC\"?[i,l,m,d]:[i,d,l,m],h=t.makeOutput(f,\"float32\"),x=t.dataIdMap.get(n.dataId).id,b=new Uint8Array(new Int32Array(y.computeStrides(n.shape)).buffer),C=new Uint8Array(new Int32Array(f).buffer),S=new Uint8Array(new Int32Array(y.computeStrides(f)).buffer),k=t.dataIdMap.get(h.dataId).id;return vO(x,s,a===\"NHWC\"?1:0,b,n.shape.length-1,C,S,f.length,k),h}var kO={kernelName:mn,backendName:\"wasm\",setupFunc:doe,kernelFunc:foe};var NO;function hoe(r){NO=r.wasm.cwrap(dn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function goe(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s}=t,a=o.dataIdMap.get(n.dataId).id,i=o.dataIdMap.get(s.dataId).id,{strides:p,dilations:u,pad:c,dimRoundingMode:l}=e,m=u==null?[1,1]:u,d=w.computeConv2DInfo(n.shape,s.shape,p,m,c,l,!0),f=d.filterHeight,h=d.filterWidth,g=d.padInfo.top,x=d.padInfo.right,b=d.padInfo.bottom,C=d.padInfo.left,S=d.dilationHeight,k=d.dilationWidth,_=d.strideHeight,E=d.strideWidth,R=d.inChannels,D=d.outChannels,P=d.padInfo.type===\"SAME\"?1:0;if(d.dataFormat!==\"channelsLast\")throw new Error(`wasm backend DepthwiseConv2dNative does not support dataFormat:'${d.dataFormat}'. Please use 'channelsLast'.`);let O=o.makeOutput(d.outShape,\"float32\"),M=o.dataIdMap.get(O.dataId).id;return NO(a,n.shape[0],n.shape[1],n.shape[2],i,f,h,g,x,b,C,P,S,k,_,E,R,D,M),O}var TO={kernelName:dn,backendName:\"wasm\",setupFunc:hoe,kernelFunc:goe};var _O;function xoe(r){_O=r.wasm.cwrap(\"Diag\",null,[\"number\",\"number\",\"number\",\"number\"])}function yoe(r){let{inputs:t,backend:e}=r,{x:o}=t,n=y.sizeFromShape(o.shape),s=e.makeOutput([...o.shape,...o.shape],o.dtype);return _O(e.dataIdMap.get(o.dataId).id,we[o.dtype],n,e.dataIdMap.get(s.dataId).id),s}var $O={kernelName:oa,backendName:\"wasm\",setupFunc:xoe,kernelFunc:yoe};var EO;function boe(r){EO=r.wasm.cwrap(fn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Coe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o;if(n.dtype!==s.dtype)throw new Error(`Dilation2D error: x must have the same dtype as filter. Got ${n.dtype} and ${s.dtype}`);let u=w.computeDilation2DInfo(n.shape,s.shape,a,i,\"NHWC\",p),c=e.makeOutput(u.outShape,n.dtype);return EO(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(c.dataId).id,we[n.dtype],u.batchSize,u.inChannels,u.inHeight,u.inWidth,u.outHeight,u.outWidth,u.strideHeight,u.strideWidth,u.dilationHeight,u.dilationWidth,u.filterHeight,u.filterWidth,u.padInfo.top,u.padInfo.left),c}var RO={kernelName:fn,backendName:\"wasm\",setupFunc:boe,kernelFunc:Coe};var DO;function woe(r){DO=r.wasm.cwrap(zi,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Soe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o;if(n.dtype!==s.dtype||n.dtype!==a.dtype)throw new Error(`Dilation2DBackpropFilter error: x must have the same dtype as filter and dy. Got ${n.dtype}, ${s.dtype}, and ${a.dtype}`);let c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=e.makeOutput(s.shape,s.dtype);return DO(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(a.dataId).id,e.dataIdMap.get(l.dataId).id,we[n.dtype],c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.filterHeight,c.filterWidth,c.padInfo.top,c.padInfo.left),l}var AO={kernelName:zi,backendName:\"wasm\",setupFunc:woe,kernelFunc:Soe};var FO;function Ioe(r){FO=r.wasm.cwrap(Bi,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function voe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o;if(n.dtype!==s.dtype||n.dtype!==a.dtype)throw new Error(`Dilation2DBackpropInput error: x must have the same dtype as filter and dy. Got ${n.dtype}, ${s.dtype}, and ${a.dtype}`);let c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=e.makeOutput(n.shape,n.dtype);return FO(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(a.dataId).id,e.dataIdMap.get(l.dataId).id,we[n.dtype],c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.filterHeight,c.filterWidth,c.padInfo.top,c.padInfo.left),l}var PO={kernelName:Bi,backendName:\"wasm\",setupFunc:Ioe,kernelFunc:voe};var OO=he(gn);var MO;function koe(r){MO=r.wasm.cwrap(Ya,null,[\"number\",\"number\",\"number\"])}function Noe(r){let{inputs:t,backend:e}=r,{dy:o,y:n}=t,s=e.makeOutput(n.shape,\"float32\"),a=i=>e.dataIdMap.get(i.dataId).id;return MO(a(n),a(o),a(s)),s}var LO={kernelName:Ya,backendName:\"wasm\",setupFunc:koe,kernelFunc:Noe};var Toe=!1,BO=Ue(yn,Toe,\"bool\");var zO=he(xn);var VO=he(bn,\"float32\");function Lg(r){let{inputs:t,attrs:e,backend:o}=r,{input:n}=t,{dim:s}=e,a=n.shape.length,i=n.shape.slice(),p=s;return s<0&&(y.assert(-(a+1)<=s,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+s+1),i.splice(p,0,1),Vt({inputs:{x:n},backend:o,attrs:{shape:i}})}var WO={kernelName:na,backendName:\"wasm\",kernelFunc:Lg};var UO=he(Cn,\"float32\");function Pv(r){let{attrs:{shape:t,value:e,dtype:o},backend:n}=r,s=n.makeOutput(t,o);return n.typedArrayFromHeap(s).fill(e),s}var GO={kernelName:sa,backendName:\"wasm\",kernelFunc:Pv};var HO;function _oe(r){HO=r.wasm.cwrap(wn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function $oe(r){let{inputs:t,backend:e}=r,{image:o}=t,n=e.makeOutput(o.shape,o.dtype),s=e.dataIdMap.get(o.dataId).id,a=e.dataIdMap.get(n.dataId).id,[i,p,u,c]=o.shape;return HO(s,i,p,u,c,a),n}var KO={kernelName:wn,backendName:\"wasm\",kernelFunc:$oe,setupFunc:_oe};var qO=he(Sn);var Eoe=!1,jO=Ue(In,Eoe);var XO;function Roe(r){XO=r.wasm.cwrap(vn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Doe(r){let{backend:t,inputs:e,attrs:o}=r,{varianceEpsilon:n}=o,{x:s,mean:a,variance:i,offset:p,scale:u}=e,c=t.dataIdMap.get(s.dataId).id,l=t.dataIdMap.get(a.dataId).id,m=t.dataIdMap.get(i.dataId).id,d=p!=null?t.dataIdMap.get(p.dataId).id:0,f=u!=null?t.dataIdMap.get(u.dataId).id:0,h=t.makeOutput(s.shape,s.dtype);if(y.sizeFromShape(s.shape)===0)return h;let g=t.dataIdMap.get(h.dataId).id;return XO(c,l,m,d,f,n,g),h}var YO={kernelName:vn,backendName:\"wasm\",setupFunc:Roe,kernelFunc:Doe};var QO;function Aoe(r){QO=r.wasm.cwrap(vo,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Foe(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dataFormat:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=e,h=w.computeConv2DInfo(n.shape,s.shape,p,c,u,m),g=ku[d];if(g==null)throw new Error(`${d} activation not yet supported for FusedConv2D in the wasm backend.`);let x=o.dataIdMap.get(n.dataId).id,b=o.dataIdMap.get(s.dataId).id,C=h.outChannels,S=0;if(a!=null){let ee=o.dataIdMap.get(a.dataId);if(ee.shape.length!==1)throw new Error(`FusedConv2D only supports rank-1 bias but got rank ${ee.shape.length}.`);if(ee.shape[0]!==C)throw new Error(`FusedConv2D bias shape (${ee.shape}) does not match the number of output channels (${C})`);S=ee.id}let k=h.filterHeight,_=h.filterWidth,E=h.padInfo.top,R=h.padInfo.right,D=h.padInfo.bottom,P=h.padInfo.left,O=h.dilationHeight,M=h.dilationWidth,L=h.strideHeight,B=h.strideWidth,z=h.inChannels,U=h.padInfo.type===\"SAME\"?1:0,j=h.batchSize,q=h.inHeight,Y=h.inWidth;if(l!==\"NHWC\")throw new Error(`wasm backend FusedConv2D does not support dataFormat:'${l}'. Please use 'NHWC'.`);let J=o.makeOutput(h.outShape,\"float32\"),re=o.dataIdMap.get(J.dataId).id,ne=i==null?0:o.dataIdMap.get(i.dataId).id;return QO(x,j,q,Y,b,k,_,S,E,R,D,P,U,O,M,L,B,z,C,g,ne,f||0,re),J}var ZO={kernelName:vo,backendName:\"wasm\",setupFunc:Aoe,kernelFunc:Foe};var JO;function Poe(r){JO=r.wasm.cwrap(ko,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Ooe(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dataFormat:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=e,h=w.computeConv2DInfo(n.shape,s.shape,p,c,u,m,!0),g=ku[d];if(g==null)throw new Error(`${d} activation not yet supported for FusedDepthwiseConv2D in the wasm backend.`);let x=o.dataIdMap.get(n.dataId).id,b=o.dataIdMap.get(s.dataId).id,C=h.outChannels,S=0;if(a!=null){let ee=o.dataIdMap.get(a.dataId);if(ee.shape.length!==1)throw new Error(`FusedDepthwiseConv2D only supports rank-1 bias but got rank ${ee.shape.length}.`);if(ee.shape[0]!==C)throw new Error(`FusedDepthwiseConv2D bias shape (${ee.shape}) does not match the number of output channels (${C})`);S=ee.id}let k=h.filterHeight,_=h.filterWidth,E=h.padInfo.top,R=h.padInfo.right,D=h.padInfo.bottom,P=h.padInfo.left,O=h.dilationHeight,M=h.dilationWidth,L=h.strideHeight,B=h.strideWidth,z=h.inChannels,U=h.padInfo.type===\"SAME\"?1:0,j=h.batchSize,q=h.inHeight,Y=h.inWidth;if(l!==\"NHWC\")throw new Error(`wasm backend FusedDepthwiseConv2D does not support dataFormat:'${l}'. Please use 'NHWC'.`);let J=o.makeOutput(h.outShape,\"float32\"),re=o.dataIdMap.get(J.dataId).id,ne=i==null?0:o.dataIdMap.get(i.dataId).id;return JO(x,j,q,Y,b,k,_,S,E,R,D,P,U,O,M,L,B,z,C,g,ne,f||0,re),J}var eM={kernelName:ko,backendName:\"wasm\",setupFunc:Poe,kernelFunc:Ooe};var tM;function Moe(r){tM=r.wasm.cwrap(kn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\"])}function Loe(r){let{backend:t,inputs:e}=r,{params:o,indices:n}=e,[s,a,i,p]=af.prepareAndValidate(o,n),u=t.makeOutput(s,o.dtype);if(a===0)return u;let c=n.shape,l=c[c.length-1],d=t.dataIdMap.get(o.dataId).id,h=t.dataIdMap.get(n.dataId).id,g=new Uint8Array(new Int32Array(p).buffer),x=t.dataIdMap.get(u.dataId).id;return tM(d,we[o.dtype],h,a,l,i,g,x),u}var rM={kernelName:kn,backendName:\"wasm\",setupFunc:Moe,kernelFunc:Loe};var oM;function Boe(r){oM=r.wasm.cwrap(\"Gather\",null,[\"number\",\"number\",\"array\",\"number\",\"number\",\"number\",\"array\",\"number\"])}function zoe(r){let{backend:t,inputs:e,attrs:o}=r,{x:n,indices:s}=e,{axis:a,batchDims:i}=o,p=y.parseAxisParam(a,n.shape)[0],u=t.readSync(s.dataId),c=n.shape[p];for(let D=0;D=0,()=>`GatherV2: the index value ${P} is not in [0, ${c-1}]`)}let l=w.segment_util.collectGatherOpShapeInfo(n,s,p,i),m=Vt({inputs:{x:n},attrs:{shape:[l.batchSize,l.outerSize,l.dimSize,l.sliceSize]},backend:t}),d=y.sizeFromShape(s.shape),f=Vt({inputs:{x:s},attrs:{shape:[l.batchSize,d/l.batchSize]},backend:t}),h=[l.batchSize,l.outerSize,d/l.batchSize,l.sliceSize],g=t.makeOutput(h,n.dtype);if(y.sizeFromShape(n.shape)===0)return g;let x=m.shape.length-1,C=t.dataIdMap.get(m.dataId).id,k=t.dataIdMap.get(f.dataId).id,_=t.dataIdMap.get(g.dataId).id,E=new Uint8Array(new Int32Array(y.computeStrides(m.shape)).buffer),R=new Uint8Array(new Int32Array(y.computeStrides(h)).buffer);return oM(C,we[n.dtype],E,x,k,l.batchSize,R,_),t.disposeData(m.dataId),t.disposeData(f.dataId),g.shape=l.outputShape,g}var nM={kernelName:aa,backendName:\"wasm\",setupFunc:Boe,kernelFunc:zoe};var Voe=!1,sM=Ue(Nn,Voe,\"bool\");var Woe=!1,aM=Ue(Tn,Woe,\"bool\");var iM=he(_n,\"bool\");var uM=he($n,\"bool\");var pM=he(En,\"bool\");var cM;function Uoe(r){cM=r.wasm.cwrap(Rn,null,[\"number\",\"number\",\"number\",\"number\"])}function Goe(r){let{inputs:{x:t},attrs:{alpha:e},backend:o}=r,n=o.dataIdMap.get(t.dataId).id,s=o.makeOutput(t.shape,\"float32\");if(y.sizeFromShape(t.shape)!==0){let a=o.dataIdMap.get(s.dataId).id;cM(n,we[t.dtype],e,a)}return s}var lM={kernelName:Rn,backendName:\"wasm\",setupFunc:Uoe,kernelFunc:Goe};var Hoe=!1,mM=Ue(Dn,Hoe,\"bool\");var Koe=!1,dM=Ue(An,Koe,\"bool\");var fM;function qoe(r){fM=r.wasm.cwrap(Fn,null,[\"number\",\"number\",\"number\",\"number\"])}function joe(r){let{attrs:t,backend:e}=r,{start:o,stop:n,num:s}=t,a=Math.floor(s),i=e.makeOutput([a],\"float32\");return fM(e.dataIdMap.get(i.dataId).id,o,n,a),i}var hM={kernelName:Fn,backendName:\"wasm\",setupFunc:qoe,kernelFunc:joe};var gM=he(Pn);var xM=he(On);var Xoe=!1,yM=Ue(Mn,Xoe,\"bool\");var bM=he(Ln);var Yoe=!1,CM=Ue(Bn,Yoe,\"bool\");var Qoe=!1,wM=Ue($0,Qoe,\"bool\");var SM;function Zoe(r){SM=r.wasm.cwrap(zn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Joe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o;if(n.dtype!==\"float32\")throw new Error(\"LRN error: x must have dtype float32\");let u=e.makeOutput(n.shape,n.dtype);return SM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(u.dataId).id,n.shape[3],s,a,i,p),u}var IM={kernelName:zn,backendName:\"wasm\",setupFunc:Zoe,kernelFunc:Joe};var vM;function ene(r){vM=r.wasm.cwrap(Qa,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function tne(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,y:s,dy:a}=t,{depthRadius:i,bias:p,alpha:u,beta:c}=o;if(n.dtype!==\"float32\"||s.dtype!==\"float32\"||a.dtype!==\"float32\")throw new Error(\"LRNGrad error: x, y, and dy must have dtype float32\");let l=e.makeOutput(n.shape,n.dtype);return vM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(a.dataId).id,e.dataIdMap.get(l.dataId).id,a.shape[3],i,p,u,c),l}var kM={kernelName:Qa,backendName:\"wasm\",setupFunc:ene,kernelFunc:tne};var NM;function rne(r){NM=r.wasm.cwrap(Vn,null,[\"number\",\"number\",\"number\",\"number\"])}function one(r){let{backend:t,inputs:e,attrs:o}=r,{reductionIndices:n,keepDims:s}=o,{x:a}=e,p=t.dataIdMap.get(a.dataId).id,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t);if(d){let C=t.dataIdMap.get(c.dataId).id;u=c,p=C}let f=u.shape.length;w.assertAxesAreInnerMostDims(\"max\",l,f);let[h,g]=w.computeOutAndReduceShapes(u.shape,l),x=y.sizeFromShape(g),b=t.makeOutput(h,a.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;NM(p,we[a.dtype],x,C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var TM={kernelName:Vn,backendName:\"wasm\",setupFunc:rne,kernelFunc:one};var nne=!1,_M=Ue(Wn,nne);var $M;function sne(r){$M=r.wasm.cwrap(Un,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function ane(r){let{inputs:t,attrs:e,backend:o}=r,n=t.x,s=o.dataIdMap.get(n.dataId).id;y.assert(n.dtype===\"float32\",()=>`Error in MaxPool: only float32 input is supported. Got ${n.dtype}.`);let{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=e,c=w.computePool2DInfo(n.shape,a,i,1,p,u),l=c.filterHeight,m=c.filterWidth,d=c.padInfo.top,f=c.padInfo.right,h=c.padInfo.bottom,g=c.padInfo.left,x=c.dilationHeight,b=c.dilationWidth,C=c.strideHeight,S=c.strideWidth,k=c.inChannels,_=c.outChannels;if(c.dataFormat!==\"channelsLast\")throw new Error(`wasm backend does not support dataFormat:'${c.dataFormat}'. Please use 'channelsLast'.`);let E=o.makeOutput(c.outShape,\"float32\"),R=o.dataIdMap.get(E.dataId).id;return $M(s,n.shape[0],n.shape[1],n.shape[2],l,m,d,f,h,g,x,b,C,S,k,_,R),E}var EM={kernelName:Un,backendName:\"wasm\",setupFunc:sne,kernelFunc:ane};var RM;function ine(r){RM=r.wasm.cwrap(\"MaxPool3D\",null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function une(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p,dataFormat:u}=o,c=w.computePool3DInfo(n.shape,s,a,1,i,p,u),l=e.makeOutput(c.outShape,n.dtype);return RM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,c.batchSize,c.inChannels,c.inDepth,c.inHeight,c.inWidth,c.outDepth,c.outHeight,c.outWidth,c.strideDepth,c.strideHeight,c.strideWidth,c.dilationDepth,c.dilationHeight,c.dilationWidth,c.effectiveFilterDepth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.front,c.padInfo.top,c.padInfo.left),l}var DM={kernelName:ia,backendName:\"wasm\",setupFunc:ine,kernelFunc:une};var AM;function pne(r){AM=r.wasm.cwrap(\"MaxPool3DGrad\",null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function cne(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o,c=w.computePool3DInfo(s.shape,a,i,1,p,u),l=e.makeOutput(s.shape,s.dtype);return AM(e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,c.batchSize,c.inChannels,c.inDepth,c.inHeight,c.inWidth,c.outDepth,c.outHeight,c.outWidth,c.strideDepth,c.strideHeight,c.strideWidth,c.dilationDepth,c.dilationHeight,c.dilationWidth,c.effectiveFilterDepth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.front,c.padInfo.top,c.padInfo.left),l}var FM={kernelName:Ki,backendName:\"wasm\",setupFunc:pne,kernelFunc:cne};var PM;function lne(r){PM=r.wasm.cwrap(\"MaxPoolGrad\",null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function mne(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,{filterSize:a,strides:i,pad:p,dimRoundingMode:u}=o,c=w.computePool2DInfo(s.shape,a,i,1,p,u),l=e.makeOutput(s.shape,s.dtype);return PM(e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.top,c.padInfo.left),l}var OM={kernelName:Hi,backendName:\"wasm\",setupFunc:lne,kernelFunc:mne};var MM;function dne(r){MM=r.wasm.cwrap(\"MaxPoolWithArgmax\",null,[\"number\",\"number\",\"number\",\"number\",\"boolean\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function fne(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,includeBatchInIndex:p}=o;y.assert(n.shape.length===4,()=>`Error in maxPool: input must be rank 4 but got rank ${n.shape.length}.`);let u=[1,1];y.assert(w.eitherStridesOrDilationsAreOne(a,u),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${a} and dilations '${u}'`);let c=w.computePool2DInfo(n.shape,s,a,[1,1],i),l=e.makeOutput(c.outShape,n.dtype),m=e.makeOutput(c.outShape,\"int32\");return MM(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(l.dataId).id,e.dataIdMap.get(m.dataId).id,we[n.dtype],p,c.batchSize,c.inChannels,c.inHeight,c.inWidth,c.outHeight,c.outWidth,c.strideHeight,c.strideWidth,c.dilationHeight,c.dilationWidth,c.effectiveFilterHeight,c.effectiveFilterWidth,c.padInfo.top,c.padInfo.left),[l,m]}var LM={kernelName:ua,backendName:\"wasm\",setupFunc:dne,kernelFunc:fne};var BM;function hne(r){BM=r.wasm.cwrap(Gn,null,[\"number, number, number\"])}function gne(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t),f=l;if(d){let S=t.dataIdMap.get(c.dataId).id;S!==i&&(u=c,p=S,f=w.getInnerMostAxes(f.length,u.shape.length))}w.assertAxesAreInnerMostDims(\"mean\",f,u.shape.length);let[h,g]=w.computeOutAndReduceShapes(u.shape,f),x=y.sizeFromShape(g),b=u;u.dtype!==\"float32\"&&(b=Mr({backend:t,inputs:{x:u},attrs:{dtype:\"float32\"}}),p=t.dataIdMap.get(b.dataId).id);let C=t.makeOutput(h,\"float32\");if(y.sizeFromShape(u.shape)!==0){let S=t.dataIdMap.get(C.dataId).id;BM(p,x,S)}if(d&&t.disposeData(c.dataId),s){let S=w.expandShapeToKeepDim(C.shape,m);C.shape=S}return u.dtype!==\"float32\"&&t.disposeData(b.dataId),C}var zM={kernelName:Gn,backendName:\"wasm\",setupFunc:hne,kernelFunc:gne};var VM;function xne(r){VM=r.wasm.cwrap(Hn,null,[\"number\",\"number\",\"number\",\"number\"])}function yne(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t);if(d){let C=t.dataIdMap.get(c.dataId).id;C!==i&&(u=c,p=C)}let f=u.shape.length;w.assertAxesAreInnerMostDims(\"min\",l,f);let[h,g]=w.computeOutAndReduceShapes(u.shape,l),x=y.sizeFromShape(g),b=t.makeOutput(h,u.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;VM(p,we[a.dtype],x,C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var WM={kernelName:Hn,backendName:\"wasm\",setupFunc:xne,kernelFunc:yne};var bne=!1,UM=Ue(Kn,bne);var Ov;(function(r){r[r.reflect=0]=\"reflect\",r[r.symmetric=1]=\"symmetric\"})(Ov||(Ov={}));var GM;function Cne(r){GM=r.wasm.cwrap(qn,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"array\",\"number\",\"number\"])}function wne(r){let{inputs:{x:t},backend:e,attrs:{paddings:o,mode:n}}=r,s=o.map((f,h)=>f[0]+t.shape[h]+f[1]),a=e.dataIdMap.get(t.dataId).id,i=e.makeOutput(s,t.dtype),p=e.dataIdMap.get(i.dataId).id,u=new Uint8Array(new Int32Array(t.shape).buffer),c=o.map(f=>f[0]),l=o.map(f=>f[1]),m=new Uint8Array(new Int32Array(c).buffer),d=new Uint8Array(new Int32Array(l).buffer);return GM(a,u,t.shape.length,we[t.dtype],m,d,Ov[n],p),i}var HM={kernelName:qn,backendName:\"wasm\",kernelFunc:wne,setupFunc:Cne};var KM;function Sne(r){KM=r.wasm.cwrap(vs,null,[\"number\",\"number\",\"number\",\"number\"])}function Mv(r){let{backend:t,inputs:{logits:e},attrs:{dim:o}}=r,n=t.dataIdMap.get(e.dataId).id,s=t.makeOutput(e.shape,e.dtype),a=t.dataIdMap.get(s.dataId).id,i=e.shape[o],p=y.sizeFromShape(e.shape)/i;return y.sizeFromShape(s.shape)===0||KM(n,a,i,p),s}var qM={kernelName:vs,backendName:\"wasm\",setupFunc:Sne,kernelFunc:Mv};var jM;function Ine(r){jM=r.wasm.cwrap(Xn,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function vne(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o;if(n.dtype!==\"float32\")throw new Error(`Tensor logits must have dtype float32, got ${n.dtype}`);let p=i?n:Mv({inputs:{logits:n},backend:e,attrs:{dim:n.shape.length-1}}),[u,c]=p.shape,l=e.makeOutput([u,s],\"int32\");return jM(e.dataIdMap.get(p.dataId).id,u,c,s,a,e.dataIdMap.get(l.dataId).id),i||e.disposeData(p.dataId),l}var XM={kernelName:Xn,backendName:\"wasm\",setupFunc:Ine,kernelFunc:vne};var YM=Ue(jn,!0);var kne=!0,QM=Ue(Yn,kne);var ZM=he(pa);function Yc(r,t){let e=new Int32Array(r.wasm.HEAPU8.buffer,t,4),o=e[0],n=e[1],s=e[2],a=e[3];return r.wasm._free(t),{pSelectedIndices:o,selectedSize:n,pSelectedScores:s,pValidOutputs:a}}var JM;function Nne(r){JM=r.wasm.cwrap(Zn,\"number\",[\"number\",\"number\",\"number\",\"number\",\"number\"])}function Tne(r){let{backend:t,inputs:e,attrs:o}=r,{iouThreshold:n,maxOutputSize:s,scoreThreshold:a}=o,{boxes:i,scores:p}=e,u=t.dataIdMap.get(i.dataId).id,c=t.dataIdMap.get(p.dataId).id,l=JM(u,c,s,n,a),{pSelectedIndices:m,selectedSize:d,pSelectedScores:f,pValidOutputs:h}=Yc(t,l);return t.wasm._free(f),t.wasm._free(h),t.makeOutput([d],\"int32\",m)}var eL={kernelName:Zn,backendName:\"wasm\",setupFunc:Nne,kernelFunc:Tne};var tL;function _ne(r){tL=r.wasm.cwrap(Za,\"number\",[\"number\",\"number\",\"number\",\"number\",\"number\",\"bool\"])}function $ne(r){let{backend:t,inputs:e,attrs:o}=r,{iouThreshold:n,maxOutputSize:s,scoreThreshold:a,padToMaxOutputSize:i}=o,{boxes:p,scores:u}=e,c=t.dataIdMap.get(p.dataId).id,l=t.dataIdMap.get(u.dataId).id,m=tL(c,l,s,n,a,i),{pSelectedIndices:d,selectedSize:f,pSelectedScores:h,pValidOutputs:g}=Yc(t,m);t.wasm._free(h);let x=t.makeOutput([f],\"int32\",d),b=t.makeOutput([],\"int32\",g);return[x,b]}var rL={kernelName:Za,backendName:\"wasm\",setupFunc:_ne,kernelFunc:$ne};var oL;function Ene(r){oL=r.wasm.cwrap(Jn,\"number\",[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Rne(r){let{backend:t,inputs:e,attrs:o}=r,{iouThreshold:n,maxOutputSize:s,scoreThreshold:a,softNmsSigma:i}=o,{boxes:p,scores:u}=e,c=t.dataIdMap.get(p.dataId).id,l=t.dataIdMap.get(u.dataId).id,m=oL(c,l,s,n,a,i),{pSelectedIndices:d,selectedSize:f,pSelectedScores:h,pValidOutputs:g}=Yc(t,m);t.wasm._free(g);let x=t.makeOutput([f],\"int32\",d),b=t.makeOutput([f],\"float32\",h);return[x,b]}var nL={kernelName:Jn,backendName:\"wasm\",setupFunc:Ene,kernelFunc:Rne};var Dne=!1,sL=Ue(Qn,Dne,\"bool\");var aL;function Ane(r){aL=r.wasm.cwrap(es,null,[\"number\",\"number\",\"number\",\"number\",\"number\"])}function Fne(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n}=t,{dtype:s,depth:a,onValue:i,offValue:p}=o,u=e.makeOutput([...n.shape,a],s),c=e.dataIdMap.get(u.dataId).id,m=e.dataIdMap.get(n.dataId).id;return aL(m,a,i,p,c),u}var iL={kernelName:es,backendName:\"wasm\",setupFunc:Ane,kernelFunc:Fne};function Pne(r){let{inputs:{x:t},backend:e}=r,o=e.makeOutput(t.shape,t.dtype);return e.typedArrayFromHeap(o).fill(1),o}var uL={kernelName:ca,backendName:\"wasm\",kernelFunc:Pne};function One(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o;if(t.length===1)return Lg({inputs:{input:t[0]},backend:e,attrs:{dim:n}});let s=t[0].shape,a=t[0].dtype;t.forEach(c=>{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=Lg({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=Av({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeData(c.dataId)),u}var pL={kernelName:la,backendName:\"wasm\",kernelFunc:One};var cL;function Mne(r){cL=r.wasm.cwrap(ts,null,[\"number\",\"array\",\"number\",\"number\",\"array\",\"array\",\"number\",\"number\"])}function Lne(r){let{inputs:{x:t},backend:e,attrs:{paddings:o,constantValue:n}}=r,s=o.map((h,g)=>h[0]+t.shape[g]+h[1]);if(y.sizeFromShape(t.shape)===0)return Pv({backend:e,attrs:{shape:s,value:n,dtype:t.dtype}});let a=e.dataIdMap.get(t.dataId).id,i=e.makeOutput(s,t.dtype),u=e.dataIdMap.get(i.dataId).id,c=new Uint8Array(new Int32Array(t.shape).buffer),l=o.map(h=>h[0]),m=o.map(h=>h[1]),d=new Uint8Array(new Int32Array(l).buffer),f=new Uint8Array(new Int32Array(m).buffer);return cL(a,c,t.shape.length,we[t.dtype],d,f,n,u),i}var Bg={kernelName:ts,backendName:\"wasm\",kernelFunc:Lne,setupFunc:Mne};var Bne=!1,lL=Ue(rs,Bne);var mL;function zne(r){mL=r.wasm.cwrap(os,null,[\"number\",\"number\",\"number\"])}function Vne(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t,s=e.dataIdMap.get(o.dataId).id,a=e.dataIdMap.get(n.dataId).id,i=s,p=o,u=p;p.dtype!==\"float32\"&&(u=Mr({backend:e,inputs:{x:o},attrs:{dtype:\"float32\"}}),i=e.dataIdMap.get(u.dataId).id);let c=e.makeOutput(o.shape,\"float32\"),l=e.dataIdMap.get(c.dataId).id;return mL(i,a,l),p.dtype!==\"float32\"&&e.disposeData(u.dataId),c}var dL={kernelName:os,backendName:\"wasm\",setupFunc:zne,kernelFunc:Vne};var fL;function Wne(r){fL=r.wasm.cwrap(ns,null,[\"number\",\"number\",\"number\",\"number\"])}function Une(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t),f=l;if(d){let C=t.dataIdMap.get(c.dataId).id;C!==i&&(u=c,p=C,f=w.getInnerMostAxes(f.length,u.shape.length))}w.assertAxesAreInnerMostDims(\"prod\",f,u.shape.length);let[h,g]=w.computeOutAndReduceShapes(u.shape,f),x=y.sizeFromShape(g),b=t.makeOutput(h,u.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;fL(p,x,we[b.dtype],C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var hL={kernelName:ns,backendName:\"wasm\",setupFunc:Wne,kernelFunc:Une};var Gne=r=>{let{backend:t,attrs:e}=r,{start:o,stop:n,step:s,dtype:a}=e,i=fp(o,n,s,a),p=t.makeOutput([i.length],a);return t.typedArrayFromHeap(p).set(i),p},gL={kernelName:ma,backendName:\"wasm\",kernelFunc:Gne};var Hne=!0,xL=Ue(hn,Hne);var yL=he(ss);var bL=he(as);var CL=he(ps);var wL;function Kne(r){wL=r.wasm.cwrap(us,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function qne(r){let{backend:t,inputs:e,attrs:o}=r,{images:n}=e,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,[c,l,m,d]=n.shape,f=[c,p,u,d],h=t.dataIdMap.get(n.dataId),g;h.dtype!==\"float32\"&&(g=Mr({backend:t,inputs:{x:n},attrs:{dtype:\"float32\"}}),h=t.dataIdMap.get(g.dataId));let x=h.id,b=t.makeOutput(f,\"float32\");if(y.sizeFromShape(n.shape)===0)return b;let C=t.dataIdMap.get(b.dataId).id;return wL(x,c,l,m,d,p,u,s?1:0,a?1:0,C),g!=null&&t.disposeData(g.dataId),b}var SL={kernelName:us,backendName:\"wasm\",setupFunc:Kne,kernelFunc:qne};var IL;function jne(r){IL=r.wasm.cwrap(ei,null,[\"number\",\"number\",\"number\",\"array\",\"array\",\"boolean\"])}function Xne(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=e.makeOutput(n.shape,\"float32\"),p=e.dataIdMap.get(n.dataId),u;return p.dtype!==\"float32\"&&(u=Mr({backend:e,inputs:{x:n},attrs:{dtype:\"float32\"}}),p=e.dataIdMap.get(u.dataId)),IL(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(i.dataId).id,new Uint8Array(new Int32Array(n.shape).buffer),new Uint8Array(new Int32Array(s.shape).buffer),a),u!=null&&e.disposeData(u.dataId),i}var vL={kernelName:ei,backendName:\"wasm\",setupFunc:jne,kernelFunc:Xne};var kL;function Yne(r){kL=r.wasm.cwrap(is,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function Qne(r){let{backend:t,inputs:e,attrs:o}=r,{images:n}=e,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,[c,l,m,d]=n.shape,f=[c,p,u,d],h=t.makeOutput(f,\"float32\");if(y.sizeFromShape(n.shape)===0)return h;let g=t.dataIdMap.get(n.dataId),x;g.dtype!==\"float32\"&&(x=Mr({backend:t,inputs:{x:n},attrs:{dtype:\"float32\"}}),g=t.dataIdMap.get(x.dataId));let b=g.id,C=t.dataIdMap.get(h.dataId).id;return kL(b,c,l,m,d,p,u,s?1:0,a?1:0,C),x!=null&&t.disposeData(x.dataId),h}var NL={kernelName:is,backendName:\"wasm\",setupFunc:Yne,kernelFunc:Qne};var TL;function Zne(r){TL=r.wasm.cwrap(Ja,null,[\"number\",\"number\",\"number\",\"array\",\"array\",\"boolean\"])}function Jne(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,i=e.makeOutput(n.shape,\"float32\"),p=e.dataIdMap.get(n.dataId),u;return p.dtype!==\"float32\"&&(u=Mr({backend:e,inputs:{x:n},attrs:{dtype:\"float32\"}}),p=e.dataIdMap.get(u.dataId)),TL(e.dataIdMap.get(n.dataId).id,e.dataIdMap.get(s.dataId).id,e.dataIdMap.get(i.dataId).id,new Uint8Array(new Int32Array(n.shape).buffer),new Uint8Array(new Int32Array(s.shape).buffer),a),u!=null&&e.disposeData(u.dataId),i}var _L={kernelName:Ja,backendName:\"wasm\",setupFunc:Zne,kernelFunc:Jne};var $L;function ese(r){$L=r.wasm.cwrap(cs,null,[\"number\",\"array\",\"number\",\"array\",\"number\",\"number\"])}function tse(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o,a=y.parseAxisParam(s,n.shape);if(n.shape.length===0)return Dp({inputs:{x:n},backend:e});let i=e.makeOutput(n.shape,n.dtype),p=e.dataIdMap.get(n.dataId).id,u=e.dataIdMap.get(i.dataId).id,c=new Uint8Array(new Int32Array(a).buffer),l=new Uint8Array(new Int32Array(n.shape).buffer);$L(p,c,a.length,l,n.shape.length,u);let m=Vt({inputs:{x:i},attrs:{shape:n.shape},backend:e});return e.disposeData(i.dataId),m}var EL={kernelName:cs,backendName:\"wasm\",kernelFunc:tse,setupFunc:ese};var RL;function rse(r){RL=r.wasm.cwrap(As,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\"])}function ose(r){let{inputs:t,backend:e,attrs:o}=r,{image:n}=t,{radians:s,fillValue:a,center:i}=o,p=e.makeOutput(n.shape,n.dtype),u=e.dataIdMap.get(n.dataId).id,c=e.dataIdMap.get(p.dataId).id,[l,m,d,f]=n.shape,[h,g]=w.getImageCenter(i,m,d),x=a===0,b=255,C=typeof a==\"number\"?[a,a,a,x?0:b]:[...a,b],S=new Uint8Array(new Int32Array(C).buffer);return RL(u,l,m,d,f,s,h,g,S,C.length,c),p}var DL={kernelName:As,backendName:\"wasm\",kernelFunc:ose,setupFunc:rse};var AL=he(ls);var FL=he(ms);var PL;function nse(r){PL=r.wasm.cwrap(ds,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\"])}function sse(r){let{backend:t,inputs:e,attrs:o}=r,{indices:n,updates:s}=e,{shape:a}=o,i=t.makeOutput(a,s.dtype);if(y.sizeFromShape(a)===0)return i;let{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=hu.calculateShapes(s,n,a),f=t.dataIdMap.get(n.dataId).id,g=t.dataIdMap.get(s.dataId).id,x=new Uint8Array(new Int32Array(l).buffer),b=t.dataIdMap.get(i.dataId).id;return PL(f,g,we[s.dtype],p,u,c,x,m,b),i}var OL={kernelName:ds,backendName:\"wasm\",setupFunc:nse,kernelFunc:sse};var ML;function ase(r){ML=r.wasm.cwrap(hs,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"bool\",\"number\"])}function ise(r){let{inputs:t,backend:e,attrs:o}=r,{sortedSequence:n,values:s}=t,{side:a}=o;if(n.dtype!==s.dtype)throw new Error(`SearchSorted error: sorted_sequence must have the same dtype as values. Got ${n.dtype} and ${s.dtype}`);let i=e.makeOutput(s.shape,\"int32\");function p(u){return e.dataIdMap.get(u.dataId).id}return ML(p(n),p(s),n.shape[0],n.shape[1],s.shape[1],we[n.dtype],a===\"left\",p(i)),i}var LL={kernelName:hs,backendName:\"wasm\",setupFunc:ase,kernelFunc:ise};var BL;function use(r){BL=r.wasm.cwrap(\"SelectV2\",null,[\"number\",\"number\",\"number\",\"number\",\"number\"])}function pse(r){let{inputs:t,backend:e}=r,{condition:o,t:n,e:s}=t,a=e.dataIdMap.get(o.dataId).id,i=e.dataIdMap.get(n.dataId).id,p=e.dataIdMap.get(s.dataId).id,u=e.makeOutput(n.shape,n.dtype),c=e.dataIdMap.get(u.dataId).id,l=o.shape.length,m=n.shape.length,d=l===0||l>1||m===1?1:y.sizeFromShape(n.shape.slice(1));return BL(a,i,p,d,c),u}var zL={kernelName:fa,backendName:\"wasm\",kernelFunc:pse,setupFunc:use};var VL=he(gs);var WL;function cse(r){WL=r.wasm.cwrap(Cs,null,[\"number\",\"number\"])}function lse(r){let{backend:t,inputs:{x:e}}=r,o=t.dataIdMap.get(e.dataId).id,n=t.makeOutput(e.shape,e.dtype),s=t.dataIdMap.get(n.dataId).id;return y.sizeFromShape(n.shape)===0||WL(o,s),n}var UL={kernelName:\"Sigmoid\",backendName:\"wasm\",setupFunc:cse,kernelFunc:lse};var GL=he(bs);var HL=he(xs);var KL=he(ys);var qL=he(ws);function mse(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,paddings:a}=o,i=y.sizeFromShape(s),p=[[0,0]];p.push(...a);for(let _=1+s.length;_0?p+1:0;if(c<0)throw new Error(w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage());let l=n.shape.slice();l[0]=c;let m=e.dataIdMap.get(n.dataId).id,d=e.dataIdMap.get(s.dataId).id,f=e.dataIdMap.get(a.dataId).id,h=e.makeOutput(l,n.dtype),g=e.dataIdMap.get(h.dataId).id,x=e.makeOutput([4],\"int32\"),b=e.dataIdMap.get(x.dataId).id;JL(m,we[n.dtype],n.shape[0],d,f,g,b,t,0);let C=e.readSync(x.dataId),S;switch(C[0]){case 0:{S=w.getSparseSegmentReductionNegativeSegmentIdsErrorMessage();break}case 1:{S=w.getSparseSegmentReductionNonIncreasingSegmentIdsErrorMessage();break}case 2:S=w.getSparseSegmentReductionSegmentIdOutOfRangeErrorMessage(C[1],C[2]);break;case 3:S=w.getSparseSegmentReductionIndicesOutOfRangeErrorMessage(C[1],C[2],C[3]);break;default:S=\"\"}if(e.disposeData(x.dataId),S)throw e.disposeData(h.dataId),new Error(S);return h}function xse(r){return Vg(r,!0)}var eB={kernelName:ya,backendName:\"wasm\",setupFunc:zg,kernelFunc:xse};function yse(r){return Vg(r,!1)}var tB={kernelName:ba,backendName:\"wasm\",setupFunc:zg,kernelFunc:yse};var rB;function bse(r){rB=r.wasm.cwrap(ks,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\"])}function Cse(r){let{backend:t,inputs:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=e,{outputShape:i}=o,p=t.makeOutput(i,a.dtype);if(y.sizeFromShape(i)===0)return p;let{sliceRank:u,numUpdates:c,sliceSize:l,strides:m,outputSize:d}=w.calculateShapes(s,n,i),f=t.dataIdMap.get(n.dataId).id,h=t.dataIdMap.get(s.dataId).id,g=t.dataIdMap.get(a.dataId).id,x=new Uint8Array(new Int32Array(m).buffer),b=t.dataIdMap.get(p.dataId).id;return rB(f,h,s.shape.length,g,we[a.dtype],u,c,l,x,d,b),p}var oB={kernelName:ks,backendName:\"wasm\",setupFunc:bse,kernelFunc:Cse};function wse(r){let{inputs:t,attrs:e,backend:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=e,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=new Array(n.shape.length).fill(0),c=n.shape.slice();return p.map(l=>{let m=[...c];m[i]=l;let d=Oo({inputs:{x:n},attrs:{begin:u,size:m},backend:o});return u[i]+=l,d})}var nB={kernelName:xa,backendName:\"wasm\",kernelFunc:wse};var sB=he(Ss);var aB=he(Xi);var Sse=!0,iB=Ue(Ns,Sse);var uB;function Ise(r){uB=r.wasm.cwrap(So,null,[\"number\",\"number\",\"number\",\"number\"])}function vse(r){let{backend:t,inputs:e,attrs:o}=r,{alpha:n}=o,{x:s}=e,a=t.dataIdMap.get(s.dataId).id,i=t.makeOutput(s.shape,s.dtype),p=t.dataIdMap.get(i.dataId).id;return uB(a,n,we[s.dtype],p),i}var pB={kernelName:So,backendName:\"wasm\",setupFunc:Ise,kernelFunc:vse};var cB;function kse(r){cB=r.wasm.cwrap(Ts,null,[\"number\",\"array\",\"number\",\"array\",\"array\",\"array\",\"array\",\"array\",\"number\",\"number\"])}function Nse(r){let{backend:t,inputs:e,attrs:o}=r,{x:n}=e,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o,{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=Vt({inputs:{x:n},backend:t,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let _=ct.computeOutShape(b,C,S),E=Oo({inputs:{x:n},backend:t,attrs:{begin:b,size:_}});k=Vt({inputs:{x:E},backend:t,attrs:{shape:f}}),t.disposeData(E.dataId)}else{let _=t.makeOutput(d,\"float32\"),E=t.dataIdMap.get(n.dataId).id,R=new Uint8Array(new Int32Array(y.computeStrides(n.shape)).buffer),D=new Uint8Array(new Int32Array(b).buffer),P=new Uint8Array(new Int32Array(C).buffer),O=new Uint8Array(new Int32Array(S).buffer),M=new Uint8Array(new Int32Array(d).buffer),L=new Uint8Array(new Int32Array(y.computeStrides(d)).buffer),B=t.dataIdMap.get(_.dataId).id;cB(E,R,n.shape.length,D,P,O,M,L,d.length,B),k=Vt({inputs:{x:_},backend:t,attrs:{shape:f}}),t.disposeData(_.dataId)}return k}var lB={kernelName:Ts,backendName:\"wasm\",setupFunc:kse,kernelFunc:Nse};function Tse(r){let{backend:t,inputs:e,attrs:o}=r,{data:n,dataSplits:s}=e,{separator:a,nGramWidths:i,leftPad:p,rightPad:u,padWidth:c,preserveShortSequences:l}=o,m=t.readSync(n.dataId),d=t.readSync(s.dataId),[f,h]=gp(m,d,a,i,p,u,c,l),g=t.makeOutput([f.length],\"string\"),x=t.dataIdMap.get(g.dataId);x.stringBytes=f;let b=t.makeOutput(s.shape,\"int32\");return t.typedArrayFromHeap(b).set(h),[g,b]}var mB={kernelName:Ca,backendName:\"wasm\",kernelFunc:Tse};function _se(r){let{backend:t,inputs:e,attrs:o}=r,{input:n,delimiter:s}=e,{skipEmpty:a}=o,i=t.readSync(n.dataId),p=t.readSync(s.dataId),[u,c,l]=xp(i,p[0],a),m=c.length,d=t.makeOutput([m,2],\"int32\");t.typedArrayFromHeap(d).set(u);let h=t.makeOutput([m],\"string\"),g=t.dataIdMap.get(h.dataId);g.stringBytes=c;let x=t.makeOutput([2],\"int32\");return t.typedArrayFromHeap(x).set(l),[d,h,x]}var dB={kernelName:Yi,backendName:\"wasm\",kernelFunc:_se};function $se(r){let{backend:t,inputs:e,attrs:o}=r,{input:n}=e,{numBuckets:s}=o,a=t.readSync(n.dataId),i=yp(a,s),p=t.makeOutput(n.shape,\"int32\");return t.typedArrayFromHeap(p).set(i),p}var fB={kernelName:Qi,backendName:\"wasm\",kernelFunc:$se};var Ese=!0,hB=Ue(_s,Ese);var gB;function Rse(r){gB=r.wasm.cwrap(Is,null,[\"number\",\"number\",\"number\",\"number\"])}function Dse(r){let{backend:t,inputs:e,attrs:o}=r,{axis:n,keepDims:s}=o,{x:a}=e,i=t.dataIdMap.get(a.dataId).id,p=i,u=a,{transposed:c,axes:l,originalAxes:m,inputWasTransposed:d}=_r(a,n,t),f=l;if(d){let C=t.dataIdMap.get(c.dataId).id;C!==i&&(u=c,p=C,f=w.getInnerMostAxes(f.length,u.shape.length))}w.assertAxesAreInnerMostDims(\"sum\",f,u.shape.length);let[h,g]=w.computeOutAndReduceShapes(u.shape,f),x=y.sizeFromShape(g),b=t.makeOutput(h,u.dtype);if(y.sizeFromShape(u.shape)!==0){let C=t.dataIdMap.get(b.dataId).id;gB(p,x,we[b.dtype],C)}if(d&&t.disposeData(c.dataId),s){let C=w.expandShapeToKeepDim(b.shape,m);b.shape=C}return b}var xB={kernelName:Is,backendName:\"wasm\",setupFunc:Rse,kernelFunc:Dse};var yB=he($s);var bB=he(Es);var CB;function Ase(r){CB=r.wasm.cwrap(fs,null,[\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"number\",\"number\"])}function Fse(r){let{backend:t,inputs:e,attrs:o}=r,{tensor:n,indices:s,updates:a}=e,{}=o,i=t.makeOutput(n.shape,n.dtype);if(y.sizeFromShape(n.shape)===0)return i;let{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=hu.calculateShapes(a,s,n.shape),f=t.dataIdMap.get(s.dataId).id,g=t.dataIdMap.get(a.dataId).id,b=t.dataIdMap.get(n.dataId).id,C=new Uint8Array(new Int32Array(l).buffer),S=t.dataIdMap.get(i.dataId).id;return CB(f,g,we[a.dtype],p,u,c,C,m,S,b),i}var wB={kernelName:fs,backendName:\"wasm\",setupFunc:Ase,kernelFunc:Fse};var SB;function Pse(r){SB=r.wasm.cwrap(po,null,[\"number\",\"array\",\"number\",\"array\",\"number\",\"number\"])}function Ose(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,s=e.dataIdMap.get(n.dataId).id,{reps:a}=o,i=new Array(n.shape.length);for(let m=0;m{let{x:o}=r,{k:n,sorted:s}=e,a=t.dataIdMap.get(o.dataId).id,i=new Uint8Array(new Int32Array(o.shape).buffer),p=o.shape.slice();p[p.length-1]=n;let u=t.makeOutput(p,o.dtype),c=t.dataIdMap.get(u.dataId).id,l=t.makeOutput(p,\"int32\"),m=t.dataIdMap.get(l.dataId).id;return vB(a,i,o.shape.length,we[o.dtype],n,s,c,m),[u,l]},kB={kernelName:Rs,backendName:\"wasm\",setupFunc:Mse,kernelFunc:Lse};var NB;function Bse(r){NB=r.wasm.cwrap(Ds,null,[\"number\",\"number\",\"bool\",\"number\",\"number\",\"number\",\"number\",\"number\",\"number\",\"array\",\"number\",\"array\",\"number\",\"number\",\"number\",\"number\",\"number\"])}function zse(r){let{backend:t,inputs:e,attrs:o}=r,{image:n,transforms:s}=e,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=o,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=new Uint8Array(new Int32Array(y.computeStrides(n.shape)).buffer),b=new Uint8Array(new Int32Array(y.computeStrides(g)).buffer),C=t.makeOutput(g,n.dtype),S=t.dataIdMap.get(C.dataId).id,_=t.dataIdMap.get(n.dataId).id,R=t.dataIdMap.get(s.dataId).id,D=a===\"nearest\"?1:2,P;switch(i){case\"constant\":P=1;break;case\"reflect\":P=2;break;case\"wrap\":P=3;break;case\"nearest\":P=4;break;default:P=1;break}return NB(_,R,s.shape[0]>1,c,f,h,d,m,l,x,n.shape.length-1,b,g.length-1,D,P,p,S),C}var TB={kernelName:Ds,backendName:\"wasm\",setupFunc:Bse,kernelFunc:zse};function Vse(r){let{inputs:t,attrs:e,backend:o}=r,{axis:n}=e,{x:s}=t,{outputValues:a,outputShape:i,indices:p}=bp(o.readSync(s.dataId),n,s.shape,s.dtype);return[o.makeOutput(i,s.dtype,void 0,a),o.makeOutput([p.length],\"int32\",void 0,p)]}var _B={kernelName:Zi,backendName:\"wasm\",kernelFunc:Vse};function Wse(r){let{inputs:t,backend:e,attrs:o}=r,{value:n}=t,{axis:s}=o;s<0&&(s+=n.shape.length);let a=n.shape[s],i=n.shape.length,p=new Array(i-1),u=0;for(let d=0;d({dataId:d,dtype:f,shape:p}))}var $B={kernelName:wa,backendName:\"wasm\",kernelFunc:Wse};function Use(r){let{inputs:{x:t},backend:e}=r,o=e.makeOutput(t.shape,t.dtype);return e.typedArrayFromHeap(o).fill(0),o}var EB={kernelName:Sa,backendName:\"wasm\",kernelFunc:Use};var Gse=[hP,gP,xP,yP,bP,wP,NP,_P,$P,EP,RP,DP,AP,FP,PP,MP,UP,BP,VP,KP,jP,YP,QP,ZP,JP,eO,rO,oO,sO,iO,pO,lO,dO,fO,hO,xO,bO,wO,IO,kO,TO,$O,RO,AO,PO,OO,LO,BO,zO,VO,WO,UO,GO,KO,qO,jO,YO,ZO,eM,rM,nM,sM,aM,SP,iM,uM,pM,lM,mM,dM,hM,xM,gM,yM,bM,CM,wM,IM,kM,TM,_M,EM,DM,FM,OM,LM,zM,WM,UM,HM,XM,YM,QM,ZM,eL,rL,nL,sL,iL,uL,pL,Bg,lL,dL,hL,gL,xL,yL,bL,CL,GP,SL,vL,NL,_L,EL,DL,AL,FL,OL,LL,zL,VL,UL,GL,HL,KL,qP,qM,qL,jL,YL,ZL,eB,tB,oB,nB,sB,aB,iB,pB,lB,mB,dB,fB,hB,xB,yB,bB,wB,IB,kB,TB,vP,_B,$B,EB];for(let r of Gse)ri(r);var Lv=A();Lv.registerFlag(\"WASM_HAS_SIMD_SUPPORT\",async()=>{try{return WebAssembly.validate(new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,2,1,0,10,9,1,7,0,65,0,253,15,26,11]))}catch(r){return!1}});Lv.registerFlag(\"WASM_HAS_MULTITHREAD_SUPPORT\",async()=>{if(Lv.get(\"IS_NODE\"))return!1;try{return new MessageChannel().port1.postMessage(new SharedArrayBuffer(1)),WebAssembly.validate(new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,2,1,0,5,4,1,3,1,1,10,11,1,9,0,65,0,254,16,2,0,26,11]))}catch(r){return!1}});var Kv=Kp(FB()),zB=Kp(OB()),qv=Kp(MB());var LB=Kv.default||Kv,Hse=qv.default||qv,pm=class extends ao{constructor(t){super(),this.wasm=t,this.dataIdNextNumber=1,this.wasm.tfjs.initWithThreadsCount(WB),Hv=this.wasm.tfjs.getThreadsCount(),this.dataIdMap=new zo(this,pr())}write(t,e,o){let n={id:this.dataIdNextNumber++};return this.move(n,t,e,o,1),n}numDataIds(){return this.dataIdMap.numDataIds()}async time(t){let e=y.now();return t(),{kernelMs:y.now()-e}}move(t,e,o,n,s){let a=this.dataIdNextNumber++;if(n===\"string\"){let c=e;this.dataIdMap.set(t,{id:a,stringBytes:c,shape:o,dtype:n,memoryOffset:null,refCount:s});return}let i=y.sizeFromShape(o),p=i*y.bytesPerElement(n),u=this.wasm._malloc(p)>>>0;this.dataIdMap.set(t,{id:a,memoryOffset:u,shape:o,dtype:n,refCount:s}),this.wasm.tfjs.registerTensor(a,i,u),e!=null&&this.wasm.HEAPU8.set(new Uint8Array(e.buffer,e.byteOffset,p),u)}async read(t){return this.readSync(t)}readSync(t,e,o){let{memoryOffset:n,dtype:s,shape:a,stringBytes:i}=this.dataIdMap.get(t);if(s===\"string\")return(e==null||e===0)&&(o==null||o>=i.length)?i:i.slice(e,o);e=e||0,o=o||y.sizeFromShape(a);let p=y.bytesPerElement(s),u=this.wasm.HEAPU8.slice(n+e*p,n+o*p);return qse(u.buffer,s)}disposeData(t,e=!1){if(this.dataIdMap.has(t)){let o=this.dataIdMap.get(t);if(o.refCount--,!e&&o.refCount>0)return!1;this.wasm._free(o.memoryOffset),this.wasm.tfjs.disposeData(o.id),this.dataIdMap.delete(t)}return!0}refCount(t){return this.dataIdMap.has(t)?this.dataIdMap.get(t).refCount:0}incRef(t){let e=this.dataIdMap.get(t);e!=null&&e.refCount++}floatPrecision(){return 32}getMemoryOffset(t){return this.dataIdMap.get(t).memoryOffset}dispose(){this.wasm.tfjs.dispose(),\"PThread\"in this.wasm&&this.wasm.PThread.terminateAllThreads(),this.wasm=null}memory(){return{unreliable:!1}}makeOutput(t,e,o,n){let s;if(o==null)s=this.write(n!=null?n:null,t,e);else{let a=this.dataIdNextNumber++;s={id:a},this.dataIdMap.set(s,{id:a,memoryOffset:o,shape:t,dtype:e,refCount:1});let i=y.sizeFromShape(t);this.wasm.tfjs.registerTensor(a,i,o)}return{dataId:s,shape:t,dtype:e}}typedArrayFromHeap({shape:t,dtype:e,dataId:o}){let n=this.wasm.HEAPU8.buffer,{memoryOffset:s}=this.dataIdMap.get(o),a=y.sizeFromShape(t);switch(e){case\"float32\":return new Float32Array(n,s,a);case\"int32\":return new Int32Array(n,s,a);case\"bool\":return new Uint8Array(n,s,a);default:throw new Error(`Unknown dtype ${e}`)}}};function Kse(r){return(t,e)=>(y.fetch(r,{credentials:\"same-origin\"}).then(o=>{o.ok||t.env.a(`failed to load wasm binary file at '${r}'`),o.arrayBuffer().then(n=>{WebAssembly.instantiate(n,t).then(s=>{e(s.instance,s.module)})})}),{})}function BB(r,t,e){if(Gg!=null)return Gg;let o=\"tfjs-backend-wasm.wasm\";return r&&t?o=\"tfjs-backend-wasm-threaded-simd.wasm\":r&&(o=\"tfjs-backend-wasm-simd.wasm\"),im!=null&&im[o]!=null?im[o]:e+o}async function VB(){let[r,t]=await Promise.all([A().getAsync(\"WASM_HAS_SIMD_SUPPORT\"),A().getAsync(\"WASM_HAS_MULTITHREAD_SUPPORT\")]);return new Promise((e,o)=>{let n={};n.locateFile=(i,p)=>{if(i.endsWith(\".worker.js\")){let u=zB.wasmWorkerContents.replace(/\\n/g,\"\\\\n\"),c=new Blob([u],{type:\"application/javascript\"});return URL.createObjectURL(c)}return i.endsWith(\".wasm\")?BB(r,t,am!=null?am:p):p+i},jv&&(n.instantiateWasm=Kse(BB(r,t,am!=null?am:\"\")));let s=!1;n.onAbort=()=>{if(s||um)return;um=!0,o({message:\"Make sure the server can serve the `.wasm` file relative to the bundled js file. For more details see https://github.com/tensorflow/tfjs/blob/master/tfjs-backend-wasm/README.md#using-bundlers\"})};let a;t&&r&&Gg==null?(n.mainScriptUrlOrBlob=new Blob([\"var WasmBackendModuleThreadedSimd = \"+LB.toString()],{type:\"text/javascript\"}),a=LB(n)):a=Hse(n),a.then(i=>{s=!0,um=!1;let p=null;i.tfjs={init:i.cwrap(\"init\",null,[]),initWithThreadsCount:i.cwrap(\"init_with_threads_count\",null,[\"number\"]),getThreadsCount:i.cwrap(\"get_threads_count\",\"number\",[]),registerTensor:i.cwrap(\"register_tensor\",null,[\"number\",\"number\",\"number\"]),disposeData:i.cwrap(\"dispose_data\",p,[\"number\"]),dispose:i.cwrap(\"dispose\",p,[])},e({wasm:i})}).catch(o)})}function qse(r,t){switch(t){case\"float32\":return new Float32Array(r);case\"int32\":return new Int32Array(r);case\"bool\":return new Uint8Array(r);default:throw new Error(`Unknown dtype ${t}`)}}var jse=[\"tfjs-backend-wasm.wasm\",\"tfjs-backend-wasm-simd.wasm\",\"tfjs-backend-wasm-threaded-simd.wasm\"],Gg=null,am=null,im={},um=!1,jv=!1;function Xse(r,t=!1){if(Pw(\"setWasmPath has been deprecated in favor of setWasmPaths and will be removed in a future release.\"),um)throw new Error(\"The WASM backend was already initialized. Make sure you call `setWasmPath()` before you call `tf.setBackend()` or `tf.ready()`\");Gg=r,jv=t}function Yse(r,t=!1){if(um)throw new Error(\"The WASM backend was already initialized. Make sure you call `setWasmPaths()` before you call `tf.setBackend()` or `tf.ready()`\");if(typeof r==\"string\")am=r;else{im=r;let e=jse.filter(o=>im[o]==null);if(e.length>0)throw new Error(`There were no entries found for the following binaries: ${e.join(\",\")}. Please either call setWasmPaths with a map providing a path for each binary, or with a string indicating the directory where all the binaries can be found.`)}jv=t}var WB=-1,Hv=-1;function Qse(r){WB=r}function Zse(){if(Hv===-1)throw new Error(\"WASM backend not initialized.\");return Hv}var Jse=\"4.11.0\";var eae=2;su(\"wasm\",async()=>{let{wasm:r}=await VB();return new pm(r)},eae);var xo=A();xo.registerFlag(\"WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE\",()=>15);xo.registerFlag(\"WEBGPU_CPU_FORWARD\",()=>!0);xo.registerFlag(\"WEBGPU_MATMUL_PROGRAM_TYPE\",()=>-1);xo.registerFlag(\"WEBGPU_USE_NAIVE_CONV2D_TRANSPOSE\",()=>!0);xo.registerFlag(\"WEBGPU_USE_LOW_POWER_GPU\",()=>!1);xo.registerFlag(\"WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD\",()=>1e3);xo.registerFlag(\"WEBGPU_USE_PROFILE_TOOL\",()=>!1);xo.registerFlag(\"WEBGPU_IMPORT_EXTERNAL_TEXTURE\",()=>!0);xo.registerFlag(\"WEBGPU_USE_NAIVE_CONV2D_DEBUG\",()=>!1);xo.registerFlag(\"WEBGPU_THRESHOLD_TO_INCREASE_WORKGROUPS_FOR_MATMUL\",()=>-1);xo.registerFlag(\"WEBGPU_CONV_SEPARATE_IM2COL_SHADER\",()=>!1);xo.registerFlag(\"WEBGPU_PRINT_SHADER\",()=>\"\");xo.registerFlag(\"WEBGPU_ENGINE_COMPILE_ONLY\",()=>!1);var Hg=class{constructor(t){t&&(this.vendor=t.vendor,this.architecture=t.architecture,this.intelGPUGeneration=this.getIntelGPUGeneration())}getIntelGPUGeneration(){if(this.isIntel()){if(this.architecture.startsWith(\"gen\"))return Number(this.architecture.match(/\\d+/));if(this.architecture.startsWith(\"xe\"))return 12}return 0}isIntel(){return this.vendor===\"intel\"}};var Kg=class{constructor(t){this.device=t,this.numUsedBuffers=0,this.numFreeBuffers=0,this.freeBuffers=new Map,this.usedBuffers=new Map,this.numBytesUsed=0,this.numBytesAllocated=0}acquireBuffer(t,e,o=!1,n=!0){let s,a=UB(t,e);return n?(this.freeBuffers.has(a)||this.freeBuffers.set(a,[]),this.freeBuffers.get(a).length>0?(s=this.freeBuffers.get(a).pop(),this.numFreeBuffers--):(s=this.device.createBuffer({size:t,usage:e,mappedAtCreation:o}),this.numBytesAllocated+=t)):(s=this.device.createBuffer({size:t,usage:e,mappedAtCreation:o}),this.numBytesAllocated+=t),this.usedBuffers.has(a)||this.usedBuffers.set(a,[]),this.usedBuffers.get(a).push(s),this.numUsedBuffers++,this.numBytesUsed+=t,s}releaseBuffer(t,e=!0){if(this.freeBuffers.size===0)return;let o=t.size,n=t.usage,s=UB(o,n),a=this.usedBuffers.get(s),i=a.indexOf(t);if(i<0)throw new Error(\"Cannot find the buffer in buffer manager\");a[i]=a[a.length-1],a.pop(),this.numUsedBuffers--,this.numBytesUsed-=o,e?(this.freeBuffers.get(s).push(t),this.numFreeBuffers++):(t.destroy(),this.numBytesAllocated-=o)}getNumUsedBuffers(){return this.numUsedBuffers}getNumFreeBuffers(){return this.numFreeBuffers}dispose(){this.freeBuffers.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.usedBuffers.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.freeBuffers=new Map,this.usedBuffers=new Map,this.numUsedBuffers=0,this.numFreeBuffers=0,this.numBytesUsed=0,this.numBytesAllocated=0}};function UB(r,t){return`${r}_${t}`}var qg=class{constructor(t){this.device=t,this.numUsedTextures=0,this.numFreeTextures=0,this.freeTextures=new Map,this.usedTextures=new Map,this.numBytesUsed=0,this.numBytesAllocated=0}acquireTexture(t,e,o,n){let s=HB(o),a=t*e*s,i=GB(t,e,o,n);if(this.freeTextures.has(i)||this.freeTextures.set(i,[]),this.usedTextures.has(i)||this.usedTextures.set(i,[]),this.numBytesUsed+=a,this.numUsedTextures++,this.freeTextures.get(i).length>0){this.numFreeTextures--;let u=this.freeTextures.get(i).shift();return this.usedTextures.get(i).push(u),u}this.numBytesAllocated+=a;let p=this.device.createTexture({size:[t,e],format:o,usage:n});return this.usedTextures.get(i).push(p),p}releaseTexture(t){if(this.freeTextures.size===0)return;let e=t.width,o=t.height,n=t.format,s=t.usage,a=GB(e,o,n,s);this.freeTextures.has(a)||this.freeTextures.set(a,[]),this.freeTextures.get(a).push(t),this.numFreeTextures++,this.numUsedTextures--;let i=this.usedTextures.get(a),p=i.indexOf(t);if(p<0)throw new Error(\"Cannot release a texture that was never provided by this texture manager\");i.splice(p,1);let u=HB(n),c=e*o*u;this.numBytesUsed-=c}getNumUsedTextures(){return this.numUsedTextures}getNumFreeTextures(){return this.numFreeTextures}dispose(){this.freeTextures.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.usedTextures.forEach((t,e)=>{t.forEach(o=>{o.destroy()})}),this.freeTextures=new Map,this.usedTextures=new Map,this.numUsedTextures=0,this.numFreeTextures=0,this.numBytesUsed=0,this.numBytesAllocated=0}};function GB(r,t,e,o){return`${r}_${t}_${e}_${o}`}function HB(r){if(r===\"rgba8unorm\")return 16;throw new Error(`${r} is not supported!`)}function KB(r,t){if(Math.max(...r)>5)throw new Error(\"Cannot symbolically compute strides for rank > 6 tensor.\");let e=r.length,o=\"xyzwuv\",n=r.map(a=>`${t}.${o[a]}`),s=new Array(e-1);s[e-2]=n[e-1];for(let a=e-3;a>=0;--a)s[a]=`(${s[a+1]} * ${n[a+1]})`;return s}var Qr=(r,t,e)=>e===\"int32\"?`atomicAdd(${r}, bitcast(${t}));`:`\n {\n var oldValue = 0;\n loop {\n let newValueF32 = bitcast(oldValue) + (${t});\n let newValue = bitcast(newValueF32);\n let res = atomicCompareExchangeWeak(${r}, oldValue, newValue);\n if res.exchanged {\n break;\n }\n oldValue = res.old_value;\n }\n }`;var Ii;(function(r){r[r.FROM_PIXELS=0]=\"FROM_PIXELS\",r[r.DRAW=1]=\"DRAW\"})(Ii||(Ii={}));var YB=(r,t,e,o,n)=>{let s={dtype:o.dtype,shape:o.shape},a=rae(e,s,t),i=r.createShaderModule({code:a,label:t.constructor.name}),p=A().get(\"WEBGPU_PRINT_SHADER\");if(p!==\"\"){p=p.toLowerCase();let u=p.split(\",\");(p===\"all\"||u.some(c=>t.shaderKey.toLowerCase().includes(c)))&&(console.group(t.shaderKey),console.debug(a),console.groupEnd())}return n?r.createComputePipelineAsync({compute:{module:i,entryPoint:\"_start\"},label:t.constructor.name,layout:\"auto\"}):r.createComputePipeline({compute:{module:i,entryPoint:\"_start\"},label:t.constructor.name,layout:\"auto\"})},Ae=(r,t=\"f32\")=>{switch(r){case 1:return`${t}`;case 2:return`vec2<${t}>`;case 3:return`vec3<${t}>`;case 4:return`vec4<${t}>`;default:throw new Error(`${r}-component ${t} is not supported.`)}};function ht(r){if(r<=1)return\"i32\";if(r===2)return\"vec2\";if(r===3)return\"vec3\";if(r===4)return\"vec4\";if(r===5)return\"vec5\";if(r===6)return\"vec6\";throw Error(`GPU for rank ${r} is not yet supported`)}function Mo(r){if(r===0)return\"x\";if(r===1)return\"y\";if(r===2)return\"z\";if(r===3)return\"w\";if(r===4)return\"u\";if(r===5)return\"v\";throw Error(`Index ${r} is not yet supported`)}function G(...r){let t;switch(r.length){case 0:t=`\n fn main()\n `;break;case 1:t=`\n fn main(${r[0]} : i32)\n `;break;default:throw Error(\"Unreachable\")}return t}function qB(r,t){let e;return e=`\n ${tae(t)}\n fn _start(@builtin(local_invocation_id) LocalId : vec3,\n @builtin(global_invocation_id) GlobalId : vec3,\n @builtin(local_invocation_index) LocalIndex: u32,\n @builtin(workgroup_id) WorkgroupId : vec3,\n @builtin(num_workgroups) NumWorkgroups : vec3) {\n localId = LocalId;\n localIndex = LocalIndex;\n globalId = GlobalId;\n numWorkgroups = NumWorkgroups;\n workgroupId = WorkgroupId;\n ${r?\"main(getGlobalIndex());\":\"main();\"};\n }\n `,e}function tae(r){return`\n @compute @workgroup_size(${r.workgroupSize[0]}, ${r.workgroupSize[1]}, ${r.workgroupSize[2]})\n`}function rae(r,t,e){let o=[],n=e.workgroupSize[0]*e.workgroupSize[1]*e.workgroupSize[2];if(e.outputComponent=e.outputComponent?e.outputComponent:1,o.push(`\n\n var localId: vec3;\n var localIndex: u32;\n var globalId: vec3;\n var numWorkgroups: vec3;\n var workgroupId: vec3;\n\n // Only used when the y/z dimension of workgroup size is 1.\n fn getGlobalIndex() -> i32 {\n ${ZB(e)?\" return i32(globalId.x);\":` return i32((workgroupId.z * numWorkgroups.x * numWorkgroups.y +\n workgroupId.y * numWorkgroups.x + workgroupId.x) * ${n}u +\n localIndex);\n `}\n }\n `),e.pixelsOpType!=null){let f=e.pixelsOpType===Ii.FROM_PIXELS?`@group(0) @binding(0) var result: array<${Nu(t.dtype,e.outputComponent)}>;`:`@group(0) @binding(1) var inBuf : array<${Nu(r[0].dtype,e.outputComponent)}>;`,h=t.shape.length===3?\"vec2\":\"i32\";o.push(`\n struct Uniform {\n outShapeStrides : ${h},\n size : i32,\n numChannels : i32,\n alpha : f32,\n };\n\n ${f}\n @group(0) @binding(2) var uniforms: Uniform;\n `);let g=XB(e);return[jB,o.join(`\n`),cm(t.shape),e.getUserCode(),qB(g,e)].join(`\n`)}let s,a,i=\"struct Uniforms { NAN : f32, INFINITY : f32, \";e.variableNames.forEach((f,h)=>{let g=ht(r[h].shape.length);i+=`${f.charAt(0).toLowerCase()+f.slice(1)}Shape : ${g}, `,s=r[h].shape.length-1,a=ht(s),i+=`${f.charAt(0).toLowerCase()+f.slice(1)}ShapeStrides: ${a}, `});let p=ht(t.shape.length);i+=`outShape : ${p}, `,s=t.shape.length-1,a=ht(s),i+=`\n outShapeStrides: ${a}, `,e.size&&(i+=\"size : i32, \"),e.uniforms&&(i+=e.uniforms),i+=\"};\",i=cae(i),o.push(i),e.atomic?o.push(`\n @group(0) @binding(0) var result: array>;\n `):o.push(`\n @group(0) @binding(0) var result: array<${Nu(t.dtype,e.outputComponent)}>;\n `),e.variableNames.forEach((f,h)=>{o.push(`\n @group(0) @binding(${1+h}) var ${f}: array<${e.variableComponents?Nu(r[h].dtype,e.variableComponents[h]):Nu(r[h].dtype,e.outputComponent)}>;\n `)}),i!==\"\"&&o.push(`\n @group(0) @binding(${1+e.variableNames.length}) var uniforms: Uniforms;\n `);let u=iae(t.shape,e.dispatchLayout),c=[jB,o.join(`\n`)+oae,cm(t.shape),u,uae(t.shape.length)];e.atomic||c.push(pae(t.shape,t.dtype,e.outputComponent)),e.variableNames.forEach((f,h)=>{c.push(`${cm(r[h].shape,f)}`)});let l=r.map((f,h)=>aae(f,t.shape,e.variableComponents?e.variableComponents[h]:e.outputComponent,e.dispatchLayout.x.length===t.shape.length)).join(`\n`);c.push(l),c.push(e.getUserCode());let m=XB(e);return c.push(qB(m,e)),c.join(`\n`)}function QB(r,t,e){let o=r.shaderKey;if(r.pixelsOpType!=null)return o;let n=[],s=[];t.forEach(c=>{n.push(c.shape),s.push(c.dtype)}),n.push(e.shape),s.push(e.dtype);let a=t.map(c=>w.getBroadcastDims(c.shape,e.shape)),i=t.map(c=>y.arraysEqual(c.shape,e.shape)).join(\"_\"),p=a.map(c=>c.join(\"_\")).join(\";\"),u=ZB(r)?\"flatDispatch\":\"\";return o+=\"_\"+(r.workgroupSize?r.workgroupSize.join(\",\"):\"\")+n.map(c=>c.length).join(\",\")+s.join(\",\")+r.variableNames.join(\",\")+p+i+u,o}var jB=`\n struct vec5 {x: i32, y: i32, z: i32, w: i32, u: i32};\n struct vec6 {x: i32, y: i32, z: i32, w: i32, u: i32, v: i32};\n\n // Checks whether coordinates lie within the bounds of the shape.\n fn coordsInBounds2D(coord : vec2, shape : vec2) -> bool {\n return all(coord >= vec2(0)) && all(coord < shape);\n }\n fn coordsInBounds3D(coord : vec3, shape : vec3) -> bool {\n return all(coord >= vec3(0)) && all(coord < shape);\n }\n fn coordsInBounds4D(coord : vec4, shape : vec4) -> bool {\n return all(coord >= vec4(0)) && all(coord < shape);\n }\n\n fn getIndexFromCoords1D(coord : i32, shape : i32) -> i32 {\n return coord;\n }\n fn getIndexFromCoords2D(coords : vec2, shape : vec2) -> i32 {\n return dot(coords, vec2(shape.y, 1));\n }\n fn getIndexFromCoords3D(coords : vec3, shape : vec3) -> i32 {\n return dot(coords, vec3(shape.y * shape.z, shape.z, 1));\n }\n fn getIndexFromCoords4D(coords : vec4, shape : vec4) -> i32 {\n return dot(coords, vec4(\n shape.y * shape.z * shape.w, shape.z * shape.w, shape.w, 1));\n }\n fn getIndexFromCoords5D(coords : vec5, shape : vec5) -> i32 {\n let shapeStrides: vec5 = vec5(shape.y * shape.z * shape.w * shape.u, shape.z * shape.w * shape.u, shape.w * shape.u, shape.u, 1);\n return coords.x*shapeStrides.x + coords.y*shapeStrides.y + coords.z*shapeStrides.z + coords.w*shapeStrides.w + coords.u*shapeStrides.u;\n }\n fn getIndexFromCoords6D(coords : vec6, shape : vec6) -> i32 {\n let shapeStrides: vec6 = vec6(shape.y * shape.z * shape.w * shape.u * shape.v, shape.z * shape.w * shape.u * shape.v, shape.w * shape.u * shape.v, shape.u * shape.v, shape.v, 1);\n return coords.x*shapeStrides.x + coords.y*shapeStrides.y + coords.z*shapeStrides.z + coords.w*shapeStrides.w + coords.u*shapeStrides.u + coords.v*shapeStrides.v;\n }\n\n // NaN defination in IEEE 754-1985 is :\n // - sign = either 0 or 1.\n // - biased exponent = all 1 bits.\n // - fraction = anything except all 0 bits (since all 0 bits represents infinity).\n // https://en.wikipedia.org/wiki/IEEE_754-1985#Representation_of_non-numbers\n fn isnan(val: f32) -> bool {\n let floatToUint: u32 = bitcast(val);\n return (floatToUint & 0x7fffffffu) > 0x7f800000u;\n }\n fn isnanVec4(val : vec4) -> vec4 {\n let floatToUint: vec4 = bitcast>(val);\n return (floatToUint & vec4(0x7fffffffu)) > vec4(0x7f800000u);\n }\n`,oae=`\n fn isinf(val: f32) -> bool {\n return abs(val) == uniforms.INFINITY;\n }\n`;function cm(r,t=\"\"){let e=r.length,o=t!==\"\"?`get${t.charAt(0).toUpperCase()+t.slice(1)}CoordsFromIndex`:\"getCoordsFromIndex\",n=t!==\"\"?`${t.charAt(0).toLowerCase()+t.slice(1)}ShapeStrides`:\"outShapeStrides\";if(e<=1)return`fn ${o}(index : i32) -> i32 { return index; }`;let s=y.computeStrides(r),a=ht(e),i=[];for(let u=0;u vec2 {\n let d0 = index / uniforms.${n}; let d1 = index - d0 * uniforms.${n};\n return vec2(d0, d1);\n }`;let p;return p=\"var index2 = index;\"+s.map((u,c)=>{let l=`let ${i[c]} = index2 / uniforms.${n}.${Mo(c)}`,m=c===s.length-1?`let ${i[c+1]} = index2 - ${i[c]} * uniforms.${n}.${Mo(c)}`:`index2 = index2 - ${i[c]} * uniforms.${n}.${Mo(c)}`;return`${l}; ${m};`}).join(\"\"),`\n fn ${o}(index : i32) -> ${a} {\n ${p}\n return ${a}(${i.join(\",\")});\n }\n `}function nae(r,t){let e=r.name,o=r.shape.length,n=ht(o),s=\"get\"+e.charAt(0).toUpperCase()+e.slice(1),a=[\"d0\",\"d1\",\"d2\",\"d3\",\"d4\",\"d5\"].slice(0,o),i=a.map(c=>`${c} : i32`).join(\", \");if(o<1)return`\n fn ${s}() -> ${Ae(t)} {\n return ${Ae(t)}(${e}[0]);\n }\n `;let p=`uniforms.${e.charAt(0).toLowerCase()+e.slice(1)}Shape`,u=`${o}D`;return o===0&&(u=\"1D\"),`\n fn ${s}(${i}) -> ${Ae(t)} {\n return ${Ae(t)}(${e}[getIndexFromCoords${u}(${n}(${a.join(\",\")}),\n ${p})${t===1?\"\":` / ${t}`}]);\n }\n `}function sae(r,t,e,o){let n=r.name,s=n.charAt(0).toUpperCase()+n.slice(1),a=\"get\"+s+\"ByOutput\",i=r.shape.length,p=t.length,u=ht(p);if(y.arraysEqual(r.shape,t)&&o)return`\n fn ${a}Index(globalIndex : i32) -> ${Ae(e)} {\n return ${Ae(e)}(${n}[globalIndex]);\n }\n\n fn ${a}Coords(coords : ${u}) -> ${Ae(e)} {\n return ${Ae(e)}(${n}[${p>1?\"getOutputIndexFromCoords(coords)\":\"coords\"}${e===1?\"\":` / ${e}`}]);\n }\n `;let c=w.getBroadcastDims(r.shape,t),l=p-i,m=\"\";if(i===0)return`\n fn ${a}Index(globalIndex : i32) -> ${Ae(e)}{\n return get${s}();\n }\n\n fn ${a}Coords(coords : ${u}) -> ${Ae(e)}{\n return get${s}();\n }\n `;p<2&&c.length>=1?m=\"coords = 0;\":m=c.map(g=>`coords.${Mo(g+l)} = 0;`).join(`\n`);let d=\"\";if(p<2&&i>0)d=\"coords\";else if(p>1){let g=ht(i),x=r.shape.map((b,C)=>`coords.${Mo(C+l)}`).join(\", \");d=`${g}(${x})`}else d=\"coords\";let f=`uniforms.${n.charAt(0).toLowerCase()+n.slice(1)}Shape`,h=`${i}D`;return`\n fn ${a}Index(globalIndex : i32) -> ${Ae(e)} {\n var coords = getCoordsFromIndex(globalIndex);\n ${m}\n return ${Ae(e)}(${n}[getIndexFromCoords${h}(${d}, ${f})${e===1?\"\":` / ${e}`}]);\n }\n\n fn ${a}Coords(coordsIn : ${u}) -> ${Ae(e)} {\n var coords = coordsIn;\n ${m}\n return ${Ae(e)}(${n}[getIndexFromCoords${h}(${d}, ${f})${e===1?\"\":` / ${e}`}]);\n }\n`}function aae(r,t,e,o){let n=nae(r,e);return r.shape.length<=t.length&&(n+=sae(r,t,e,o)),n}function iae(r,t){let{x:e,y:o=[],z:n=[]}=t,s=r.length,a=e.length+o.length+n.length;if(a!==s)return\"\";if(e.length===s)return`fn getOutputCoords() -> ${ht(s)}{\n let globalIndex = getGlobalIndex();\n return getCoordsFromIndex(globalIndex);\n }\n `;let i=\"\",p=[e,o,n];for(let m=0;m ${c} {\n ${i}\n`;return u.length===0?l+=`return ${c}(0); }`:l+=`return ${c}(${u.join(\",\")}); }`,l}function uae(r){let t=\"\";switch(r){case 0:case 1:t+=`\n fn getOutputIndexFromCoords(coords : i32) -> i32 {\n return coords;\n }\n `;break;case 2:t+=`\n fn getOutputIndexFromCoords(coords : vec2) -> i32 {\n return dot(coords, vec2(uniforms.outShapeStrides, 1));\n }\n `;break;case 3:t+=`\n fn getOutputIndexFromCoords(coords : vec3) -> i32 {\n return dot(coords, vec3(uniforms.outShapeStrides.x, uniforms.outShapeStrides.y, 1));\n }\n `;break;case 4:t+=`\n fn getOutputIndexFromCoords(coords : vec4) -> i32 {\n return dot(coords, vec4(\n uniforms.outShapeStrides.x, uniforms.outShapeStrides.y, uniforms.outShapeStrides.z, 1));\n }\n `;break;case 5:t+=`\n fn getOutputIndexFromCoords(coords : vec5) -> i32 {\n return coords.x * uniforms.outShapeStrides.x +\n coords.y * uniforms.outShapeStrides.y +\n coords.z * uniforms.outShapeStrides.z +\n coords.w * uniforms.outShapeStrides.w +\n coords.u;\n }\n `;break;case 6:t+=`\n fn getOutputIndexFromCoords(coords : vec6) -> i32 {\n return coords.x * uniforms.outShapeStrides.x +\n coords.y * uniforms.outShapeStrides.y +\n coords.z * uniforms.outShapeStrides.z +\n coords.w * uniforms.outShapeStrides.w +\n coords.u * uniforms.outShapeStrides.u +\n coords.v;\n }\n `;break;default:y.assert(!1,()=>`Unsupported ${r}D shape`);break}return t}function ZB(r){return r.dispatch[1]===1&&r.dispatch[2]===1}function Nu(r,t=1){if(r===\"float32\")return Ae(t,\"f32\");if(r===\"int32\"||r===\"bool\")return Ae(t,\"i32\");throw new Error(`type ${r} is not supported.`)}function pae(r,t,e){let o=r.length,n=Nu(t,e),s=`fn setOutputAtIndex(flatIndex : i32, value : ${Ae(e)}) {\n result[flatIndex] = ${n}(value);\n }\n\n fn setOutputAtIndexI32(flatIndex : i32, value : ${Ae(e,\"i32\")}) {\n result[flatIndex] = ${n}(value);\n }\n `;if(o>=2){let a=[\"d0\",\"d1\",\"d2\",\"d3\",\"d4\",\"d5\"].slice(0,o),i=ht(o);s+=`\n fn setOutputAtCoords(${a.map(p=>`${p} : i32`).join(\", \")}, value : ${Ae(e)}) {\n let flatIndex = getOutputIndexFromCoords(${i}(${a.join(\", \")}));\n setOutputAtIndex(flatIndex${e===1?\"\":` / ${e}`}, value);\n }\n fn setOutputAtCoordsI32(${a.map(p=>`${p} : i32`).join(\", \")}, value : ${Ae(e,\"i32\")}) {\n let flatIndex = getOutputIndexFromCoords(${i}(${a.join(\", \")}));\n setOutputAtIndexI32(flatIndex${e===1?\"\":` / ${e}`}, value);\n }\n `}return s}function cae(r){let t=/(\\w+)\\s*:\\s*vec(5|6)/g;r=r.replace(t,o=>\"@align(16) \"+o);let e=/vec(5|6)\\s*,\\s*(\\w+)/g;return r=r.replace(e,(o,n,s)=>`vec${n}, @align(16) ${s}`),r}function XB(r){return!(r.dispatchLayout.hasOwnProperty(\"y\")&&r.dispatchLayout.y.length!==0||r.dispatchLayout.hasOwnProperty(\"z\")&&r.dispatchLayout.z.length!==0)}var Yv={};qe(Yv,{GPUBytesPerElement:()=>jg,MatMulProgramType:()=>Lo,assertNotComplex:()=>fm,computeDispatch:()=>H,computeWorkPerThreadForConv2d:()=>mm,computeWorkgroupInfoForMatMul:()=>Xv,computeWorkgroupSizeForConv2d:()=>lm,flatDispatchLayout:()=>X,isWebGPUSupported:()=>dm,tilesFitEvenlyIntoShape:()=>mae});var Ap=r=>{let t=1;for(let e=0;ee%r[o]===0)}function H(r,t,e=[1,1,1],o=[1,1,1]){let[n,s,a]=[Math.ceil(Ap(r.x.map(i=>t[i]))/(e[0]*o[0])),r.y?Math.ceil(Ap(r.y.map(i=>t[i]))/(e[1]*o[1])):1,r.z?Math.ceil(Ap(r.z.map(i=>t[i]))/(e[2]*o[2])):1];return[n,s,a]}function Xv(r,t,e,o=!1){let n=[8,8,1],s=[4,4,1];return o||(r<=8&&(s[1]=1),t<=16&&e<=16&&(n[0]=4)),{workgroupSize:n,elementsPerThread:s}}function lm(r,t,e=!1){if(e)return[8,8,1];let o=Ap(r.x.map(s=>t[s])),n=Ap(r.y.map(s=>t[s]));return o<=4?[4,16,1]:n<=4?[16,4,1]:[16,16,1]}function mm(r,t,e=!1){if(e)return[4,4,1];let o=Ap(r.x.map(s=>t[s])),n=Ap(r.y.map(s=>t[s]));return o<=4?[1,2,1]:n<=4?[2,1,1]:[2,2,1]}function X(r){return{x:r.map((t,e)=>e)}}function jg(r){if(r===\"float32\"||r===\"int32\"||r===\"bool\"||r===\"string\")return 4;if(r===\"complex64\")return 8;throw new Error(`Unknown dtype ${r}`)}function dm(){return(typeof window!=\"undefined\"||typeof WorkerGlobalScope!=\"undefined\")&&!!navigator.gpu}function fm(r,t){Array.isArray(r)||(r=[r]),r.forEach(e=>{e!=null&&y.assert(e.dtype!==\"complex64\",()=>`${t} does not support complex64 tensors in the WebGPU backend.`)})}var Lo;(function(r){r[r.MatMulReduceProgram=0]=\"MatMulReduceProgram\",r[r.MatMulSplitKProgram=1]=\"MatMulSplitKProgram\",r[r.MatMulSmallOutputSizeProgram=2]=\"MatMulSmallOutputSizeProgram\",r[r.MatMulPackedProgram=3]=\"MatMulPackedProgram\",r[r.MatMulMax=4]=\"MatMulMax\"})(Lo||(Lo={}));var dae=A().getNumber(\"WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD\"),fae=(r,t)=>{let e=r.limits.maxComputeWorkgroupsPerDimension,o=t.dispatchLayout,n=t.dispatch;if(n.every(a=>a<=e))return n;y.assert(n[0]>e&&o.y===void 0&&o.z===void 0,()=>\"Dispatch size exceeds WebGPU limits in Y or Z dimension.\");let s=Math.ceil(Math.sqrt(n[0]));return s>e?(s=Math.ceil(Math.cbrt(n[0])),y.assert(s<=e,()=>\"Total dispatch size exceeds WebGPU maximum.\"),[s,s,s]):[s,s,1]},Tu=class extends ao{nextDataId(){return Tu.nextDataId++}constructor(t,e){if(super(),this.commandQueueOwnedIds=new WeakSet,this.dispatchCountInPass=0,this.disposed=!1,this.downloadWaitMs=0,this.tensorDataPendingDisposal=[],this.queryResolveBuffer=null,this.querySet=null,this.querySetCount=2,this.stagingPendingDisposal=[],this.uniformPendingDisposal=[],this.uploadWaitMs=0,this.hasReadSyncWarned=!1,this.hasTimestampQueryWarned=!1,!dm())throw new Error(\"WebGPU is not supported on this device\");this.pipelineCache={},this.device=t,this.queue=t.queue,this.commandEncoder=null,this.computePassEncoder=null,this.adapterInfo=new Hg(e),this.supportTimestampQuery=this.device.features.has(\"timestamp-query\"),this.thresholdToIncreaseWorkgroups=this.adapterInfo.intelGPUGeneration>=12?16:8,this.bufferManager=new Kg(this.device),this.textureManager=new qg(this.device),this.tensorMap=new zo(this,pr()),A().getBool(\"WEBGPU_USE_PROFILE_TOOL\")&&(this.dummyCanvas=document.createElement(\"canvas\"),this.dummyCanvas.width=1,this.dummyCanvas.height=1,this.dummyContext=this.dummyCanvas.getContext(\"webgpu\"),this.dummyContext.configure({device:t,format:\"bgra8unorm\"}),document.body.appendChild(this.dummyCanvas))}floatPrecision(){return 32}disposeData(t,e=!1){if(!this.tensorMap.has(t))return!0;let o=this.tensorMap.get(t);return e?o.refCount=0:o.refCount--,o.refCount>0?!1:(o.complexTensorInfos!=null&&(this.disposeData(o.complexTensorInfos.real.dataId),this.disposeData(o.complexTensorInfos.imag.dataId)),this.commandQueueOwnedIds.has(t)?(this.tensorDataPendingDisposal.push(t),!0):(this.releaseResource(t),this.tensorMap.delete(t),!0))}memory(){return{numBytesInGPU:this.bufferManager.numBytesUsed,numBytesAllocatedInGPU:this.bufferManager.numBytesAllocated,unreliable:!1}}releaseResource(t){let e=this.tensorMap.get(t);if(!(!e||!e.resource)){if(e.external){e.resource=null;return}e.resource instanceof GPUBuffer?this.bufferManager.releaseBuffer(e.resource):e.resource instanceof GPUTexture&&this.textureManager.releaseTexture(e.resource),e.resource=null}}refCount(t){return this.tensorMap.has(t)?this.tensorMap.get(t).refCount:0}incRef(t){let e=this.tensorMap.get(t);e.refCount++}decRef(t){if(this.tensorMap.has(t)){let e=this.tensorMap.get(t);e.refCount--}}write(t,e,o){if(o===\"complex64\"&&t!=null)throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");let n={id:this.nextDataId()};return this.tensorMap.set(n,{dtype:o,shape:e,values:t,refCount:1}),n}move(t,e,o,n,s){if(n===\"complex64\")throw new Error(\"Cannot write to a complex64 dtype. Please use tf.complex(real, imag).\");this.tensorMap.set(t,{dtype:n,shape:o,values:e,refCount:s})}submitQueue(){this.queue.submit([this.commandEncoder.finish()]),this.commandEncoder=null,this.dispatchCountInPass=0,this.commandQueueOwnedIds=new WeakSet,this.tensorDataPendingDisposal.forEach(t=>{this.releaseResource(t),this.tensorMap.delete(t)}),this.uniformPendingDisposal.forEach(t=>this.bufferManager.releaseBuffer(t)),this.stagingPendingDisposal.forEach(t=>this.bufferManager.releaseBuffer(t,!1)),this.tensorDataPendingDisposal=[],this.uniformPendingDisposal=[],this.stagingPendingDisposal=[]}ensureCommandEncoderReady(){this.commandEncoder||(this.commandEncoder=this.device.createCommandEncoder())}endComputePassEncoder(){this.computePassEncoder&&(this.computePassEncoder.end(),this.computePassEncoder=null)}async checkCompileCompletionAsync(){let t;try{t=await Promise.all(Object.values(this.pipelineCache))}catch(e){throw new Error(e.message)}Object.keys(this.pipelineCache).map((e,o)=>{this.pipelineCache[e]=t[o]})}async getBufferData(t){if(A().getBool(\"WEBGPU_ENGINE_COMPILE_ONLY\"))return console.warn(\"The data may be invalid since WEBGPU_ENGINE_COMPILE_ONLY is true, this can only be called when WEBGPU_ENGINE_COMPILE_ONLY is false\"),null;let e=t.size,o=this.bufferManager.acquireBuffer(e,GPUBufferUsage.COPY_DST|GPUBufferUsage.MAP_READ);this.ensureCommandEncoderReady(),this.endComputePassEncoder(),this.commandEncoder.copyBufferToBuffer(t,0,o,0,e),this.submitQueue(),await o.mapAsync(GPUMapMode.READ);let n=o.getMappedRange().slice(0);return o.unmap(),o!=null&&this.bufferManager.releaseBuffer(o),A().getBool(\"WEBGPU_USE_PROFILE_TOOL\")&&(y.assert(this.dummyContext!==void 0,()=>\"Fail to get context for profiling tool\"),this.dummyContext.getCurrentTexture()),n}convertAndCacheOnCPU(t,e){let o=this.tensorMap.get(t);return o.values=e,o.values}readSync(t){let e=this.tensorMap.get(t),{values:o,complexTensorInfos:n}=e;if(o!=null||e.dtype===\"string\")return o;if(e.dtype===\"complex64\"){let h=this.readSync(n.real.dataId),g=this.readSync(n.imag.dataId),x=y.convertBackendValuesAndArrayBuffer(w.mergeRealAndImagArrays(h,g).buffer,\"float32\");return this.convertAndCacheOnCPU(t,x),x}this.hasReadSyncWarned||(this.hasReadSyncWarned=!0,console.warn(\"The performance of synchronously reading data from GPU to CPU is poor on the webgpu backend, please use asynchronous APIs instead.\"));let s=[\"opaque\",\"premultiplied\"],a=e.resource,i=a.size;y.assert(i%4===0,()=>\"Because there is 4 bytes for one pixel, buffer size must be multiple of 4.\");let p=i/4,u=new ArrayBuffer(i),c=256,l=256,m=s.map(h=>new OffscreenCanvas(c,l)),d=new OffscreenCanvas(c,l);this.endComputePassEncoder(),m.map((h,g)=>{let x=h.getContext(\"webgpu\");return x.configure({device:this.device,format:\"bgra8unorm\",usage:GPUTextureUsage.COPY_DST,alphaMode:s[g]}),x.getCurrentTexture()}).map((h,g)=>{let x=c*4,b=(R,D,P)=>{this.ensureCommandEncoderReady(),this.commandEncoder.copyBufferToTexture({buffer:a,bytesPerRow:x,offset:P},{texture:h},{width:R,height:D}),this.submitQueue();let O=d.getContext(\"2d\",{willReadFrequently:!0});O.clearRect(0,0,R,D),O.drawImage(m[g],0,0);let M=O.getImageData(0,0,R,D).data,L=s[g],B=new Uint8ClampedArray(u,P,R*D*4);for(let z=0;z0&&(b(S,k,_),_+=k*(c*4)),S=E%c,S>0&&b(S,1,_)});let f=y.convertBackendValuesAndArrayBuffer(u,e.dtype);return this.convertAndCacheOnCPU(t,f),f}async read(t){if(!this.tensorMap.has(t))throw new Error(`Tensor ${t} was not registered!`);let e=this.tensorMap.get(t),{values:o}=e;if(o!=null)return o;let n;if(e.dtype===\"complex64\"){let s=await Promise.all([this.read(e.complexTensorInfos.real.dataId),this.read(e.complexTensorInfos.imag.dataId)]),a=s[0],i=s[1];n=w.mergeRealAndImagArrays(a,i)}else{let s=await this.getBufferData(e.resource);n=y.convertBackendValuesAndArrayBuffer(s,e.dtype)}return this.convertAndCacheOnCPU(t,n),n}copyBuffer(t){let e=t.size,o=t.usage,n=this.bufferManager.acquireBuffer(e,o);return this.ensureCommandEncoderReady(),this.endComputePassEncoder(),this.commandEncoder.copyBufferToBuffer(t,0,n,0,e),this.submitQueue(),n}createTensorFromGPUData(t,e,o){let n=t.buffer;if(o===\"complex64\")throw new Error(\"Cannot write to a complex64 dtype. \");let s={id:this.nextDataId()};this.tensorMap.set(s,{dtype:o,shape:e,values:null,refCount:1,external:t.zeroCopy});let a=this.tensorMap.get(s),i=jg(a.dtype)*y.sizeFromShape(a.shape);if(t.buffer.sizey.decodeString(n));return me(t.shape,t.dtype,o)}catch(o){throw new Error(\"Failed to decode encoded string bytes into utf-8\")}return me(t.shape,t.dtype,e)}async time(t){!this.supportTimestampQuery&&!this.hasTimestampQueryWarned&&(console.warn(\"This device doesn't support timestamp-query extension. Start Chrome browser with flag --disable-dawn-features=disallow_unsafe_apis to try it again. Otherwise, zero will be shown for the kernel time when profiling mode is enabled.\"),this.hasTimestampQueryWarned=!0);let e=this.activeTimers,o=[],n=!1;this.programTimersStack==null?(this.programTimersStack=o,n=!0):this.activeTimers.push(o),this.activeTimers=o,t();let s=y.flatten(this.activeTimers.map(u=>u.query)).filter(u=>u!=null),a=y.flatten(this.activeTimers.map(u=>u.name)).filter(u=>u!=null);this.activeTimers=e,n&&(this.programTimersStack=null);let i={uploadWaitMs:this.uploadWaitMs,downloadWaitMs:this.downloadWaitMs,kernelMs:null,wallMs:null},p=await Promise.all(s);return i.kernelMs=y.sum(p),i.getExtraProfileInfo=()=>p.map((u,c)=>({name:a[c],ms:u})).map(u=>`${u.name}: ${u.ms}`).join(\", \"),this.uploadWaitMs=0,this.downloadWaitMs=0,i}makeTensorInfo(t,e,o){return e===\"string\"&&o!=null&&o.length>0&&y.isString(o[0])&&(o=o.map(s=>y.encodeString(s))),{dataId:this.write(o,t,e),shape:t,dtype:e}}tensorToBinding(t){if(!t)return null;let o=this.tensorMap.get(t.dataId).resource;return o instanceof GPUBuffer?{buffer:o}:o instanceof GPUTexture?o.createView():o}uploadToGPU(t){let e=this.tensorMap.get(t);if(e.resource!=null)return;let o=jg(e.dtype)*y.sizeFromShape(e.shape),n,s=GPUBufferUsage.STORAGE|GPUBufferUsage.COPY_SRC|GPUBufferUsage.COPY_DST;if(e.values){if(n=this.bufferManager.acquireBuffer(o,s,!0),n.mapState===\"unmapped\"){let a=this.bufferManager.acquireBuffer(o,GPUBufferUsage.MAP_WRITE|GPUBufferUsage.COPY_SRC,!0,!1),i=a.getMappedRange();e.dtype===\"int32\"||e.dtype===\"bool\"?new Int32Array(i).set(e.values):new Float32Array(i).set(e.values),a.unmap(),this.ensureCommandEncoderReady(),this.endComputePassEncoder(),this.commandEncoder.copyBufferToBuffer(a,0,n,0,o),this.stagingPendingDisposal.push(a)}else{let a=n.getMappedRange();e.dtype===\"int32\"||e.dtype===\"bool\"?new Int32Array(a).set(e.values):new Float32Array(a).set(e.values),n.unmap()}e.values=null}else n=this.bufferManager.acquireBuffer(o,s);e.resource=n}makeUniforms(t){let e=0,o=0,n=[],s=1;t.forEach(p=>{p.data.length===0&&(p.data=[1]);let u;switch(p.data.length){case 1:u=4;break;case 2:u=8;break;case 3:u=16;break;case 4:u=16;break;case 5:u=16;break;case 6:u=16;break;default:y.assert(!1,()=>`Unsupported ${p.data.length}D shape`)}(o===5||o===6)&&(u=16),u>s&&(s=u),e=Math.ceil(e/u)*u,o=p.data.length,n.push(e),e+=p.data.length*4}),e=Math.ceil(e/s)*s;let a=new ArrayBuffer(e);t.forEach((p,u)=>{let c=n[u];p.type===\"int32\"?new Int32Array(a,c,p.data.length).set(p.data):p.type===\"uint32\"?new Uint32Array(a,c,p.data.length).set(p.data):new Float32Array(a,c,p.data.length).set(p.data)});let i=this.bufferManager.acquireBuffer(e,GPUBufferUsage.COPY_DST|GPUBufferUsage.UNIFORM);return this.queue.writeBuffer(i,0,a,0,e),this.uniformPendingDisposal.push(i),{offset:0,size:e,buffer:i}}runWebGPUProgram(t,e,o,n,s){if(s||(s=this.makeTensorInfo(t.outputShape,o)),y.sizeFromShape(s.shape)===0)return this.tensorMap.get(s.dataId).values=y.getTypedArrayFromDType(s.dtype,0),s;this.uploadToGPU(s.dataId),t.dispatch=fae(this.device,t);let a=e.map((p,u)=>{if(p.dtype===\"complex64\")throw new Error(\"GPGPUProgram does not support complex64 input. For complex64 dtypes, please separate the program into real and imaginary parts.\");return this.uploadToGPU(p.dataId),{dtype:this.tensorMap.get(p.dataId).dtype,shape:p.shape,name:t.variableNames[u]}});t.shaderKey=QB(t,a,s);let i=A().getBool(\"WEBGPU_ENGINE_COMPILE_ONLY\");return t.shaderKey in this.pipelineCache||(this.pipelineCache[t.shaderKey]=YB(this.device,t,a,s,i)),t.pipeline=this.pipelineCache[t.shaderKey],i||this.recordAndSubmit(t,s,e,n),s}recordAndSubmit(t,e,o,n){if(t.pipeline instanceof Promise)throw new Error(\"Please call checkCompileCompletionAsync to ensure parallel compilation is done!\");let s=[],a=[],i=\"int32\";if(t.pixelsOpType==null){s.push({type:\"float32\",data:[NaN]},{type:\"float32\",data:[1/0]}),a=o.concat(e).map(d=>d.shape);let m=\"int32\";a.map(d=>{s.push({type:m,data:d});let f=y.computeStrides(d);s.push({type:m,data:f})})}else{let m=y.computeStrides(e.shape);s.push({type:i,data:m})}if(t.size){let m=y.sizeFromShape(t.outputShape);s.push({type:i,data:[t.outputComponent?m/t.outputComponent:m]})}n&&(s=[...s,...n]);let p=[this.tensorToBinding(e),...o.map(m=>this.tensorToBinding(m)),this.makeUniforms(s)];o.forEach(m=>{this.commandQueueOwnedIds.add(m.dataId)}),this.commandQueueOwnedIds.add(e.dataId);let u=this.device.createBindGroup({layout:t.pipeline.getBindGroupLayout(0),entries:p.map((m,d)=>({binding:d,resource:m}))}),c=this.activeTimers!=null;this.ensureCommandEncoderReady();let l={};c&&this.supportTimestampQuery?(this.endComputePassEncoder(),this.querySet==null&&(this.querySet=this.device.createQuerySet({type:\"timestamp\",count:this.querySetCount})),l.timestampWrites=[{querySet:this.querySet,queryIndex:0,location:\"beginning\"},{querySet:this.querySet,queryIndex:1,location:\"end\"}],this.computePassEncoder=this.commandEncoder.beginComputePass(l)):this.computePassEncoder||(this.computePassEncoder=this.commandEncoder.beginComputePass(l)),this.computePassEncoder.setPipeline(t.pipeline),this.computePassEncoder.setBindGroup(0,u),this.computePassEncoder.dispatchWorkgroups(t.dispatch[0],t.dispatch[1],t.dispatch[2]),this.dispatchCountInPass++,(c||A().get(\"WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE\")<=this.dispatchCountInPass||t.pixelsOpType===Ii.DRAW)&&(this.endComputePassEncoder(),c?this.activeTimers.push({name:t.constructor.name,query:this.getQueryTime()}):this.submitQueue())}async getQueryTime(){if(!this.supportTimestampQuery)return 0;this.queryResolveBuffer==null&&(this.queryResolveBuffer=this.bufferManager.acquireBuffer(this.querySetCount*8,GPUBufferUsage.COPY_SRC|GPUBufferUsage.COPY_DST|GPUBufferUsage.QUERY_RESOLVE)),this.commandEncoder.resolveQuerySet(this.querySet,0,this.querySetCount,this.queryResolveBuffer,0);let t=this.bufferManager.acquireBuffer(this.querySetCount*8,GPUBufferUsage.MAP_READ|GPUBufferUsage.COPY_DST);this.commandEncoder.copyBufferToBuffer(this.queryResolveBuffer,0,t,0,this.querySetCount*8),this.submitQueue(),await t.mapAsync(GPUMapMode.READ);let e=new BigUint64Array(t.getMappedRange()),o=Number(e[1]-e[0])/1e6;return t.unmap(),this.bufferManager.releaseBuffer(t),o}shouldExecuteOnCPU(t,e=dae){return A().getBool(\"WEBGPU_CPU_FORWARD\")&&t.every(o=>this.tensorMap.get(o.dataId).resource==null&&y.sizeFromShape(o.shape){let r={powerPreference:A().get(\"WEBGPU_USE_LOW_POWER_GPU\")?\"low-power\":\"high-performance\"},t=await navigator.gpu.requestAdapter(r),e={},o=[];t.features.has(\"timestamp-query\")&&o.push(\"timestamp-query\"),t.features.has(\"bgra8unorm-storage\")&&o.push([\"bgra8unorm-storage\"]),e.requiredFeatures=o;let n=t.limits;e.requiredLimits={maxComputeWorkgroupStorageSize:n.maxComputeWorkgroupStorageSize,maxComputeWorkgroupsPerDimension:n.maxComputeWorkgroupsPerDimension,maxStorageBufferBindingSize:n.maxStorageBufferBindingSize,maxBufferSize:n.maxBufferSize,maxComputeWorkgroupSizeX:n.maxComputeWorkgroupSizeX,maxComputeInvocationsPerWorkgroup:n.maxComputeInvocationsPerWorkgroup};let s=await t.requestDevice(e),a=await t.requestAdapterInfo();return new Tu(s,a)},3);var fe;(function(r){r[r.ADD=0]=\"ADD\",r[r.ATAN2=1]=\"ATAN2\",r[r.COMPLEX_MULTIPLY_IMAG=2]=\"COMPLEX_MULTIPLY_IMAG\",r[r.COMPLEX_MULTIPLY_REAL=3]=\"COMPLEX_MULTIPLY_REAL\",r[r.DIV=4]=\"DIV\",r[r.ELU_DER=5]=\"ELU_DER\",r[r.EQUAL=6]=\"EQUAL\",r[r.FLOOR_DIV=7]=\"FLOOR_DIV\",r[r.GREATER=8]=\"GREATER\",r[r.GREATER_EQUAL=9]=\"GREATER_EQUAL\",r[r.LESS=10]=\"LESS\",r[r.LESS_EQUAL=11]=\"LESS_EQUAL\",r[r.LOGICAL_AND=12]=\"LOGICAL_AND\",r[r.LOGICAL_OR=13]=\"LOGICAL_OR\",r[r.MAX=14]=\"MAX\",r[r.MIN=15]=\"MIN\",r[r.MOD=16]=\"MOD\",r[r.MUL=17]=\"MUL\",r[r.NOT_EQUAL=18]=\"NOT_EQUAL\",r[r.POW=19]=\"POW\",r[r.PRELU=20]=\"PRELU\",r[r.SQUARED_DIFFERENCE=21]=\"SQUARED_DIFFERENCE\",r[r.SUB=22]=\"SUB\"})(fe||(fe={}));var hae=\"let resultTemp = a + b;\",gae=\"let resultTemp = atan2(a, b);\",xae=\"let resultTemp = areal * breal - aimag * bimag;\",yae=\"let resultTemp = areal * bimag + aimag * breal;\",bae=\"let resultTemp = a / b;\",Cae=\"let resultTemp = select(a * (b + 1.0), a, b >= b - b);\",wae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a == b);\n`,Sae=`\n let remainder =\n select(a % b, round(a % b), (round(a) == a) & (round(b) == b));\n let quotient = (a - remainder) / b;\n let resultTemp =\n round(select(quotient, quotient - 1, sign(remainder) == -sign(b)));\n`,Iae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a > b);\n`,vae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a >= b);\n`,kae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a < b);\n`,Nae=`\n let zero = sign(a) * 0 + 0;\n let one = sign(b) * 0 + 1;\n let resultTemp = select(zero, one, a <= b);\n`,Tae=\"return f32(a >= 1.0 && b >= 1.0);\",_ae=`return (vec4(a >= vec4(1.0)) *\n vec4(b >= vec4(1.0)));`,$ae=\"return f32(a >= 1.0 || b >= 1.0);\",Eae=`return min(vec4(a >= vec4(1.0)) +\n vec4(b >= vec4(1.0)), vec4(1.0));`,Rae=\"let resultTemp = max(a, b);\",Dae=\"let resultTemp = min(a, b);\",Aae=`\n let isNaN = b == 0.;\n var resultTemp = a % b;\n resultTemp = select((resultTemp + b) % b, resultTemp,\n (a < 0. && b < 0.) || (a >= 0. && b > 0.));\n`,Fae=`\n let isNaN = !vec4(b);\n var resultTemp = vec4(a % b);\n if (!((a[0] < 0. && b[0] < 0.) || (a[0] >= 0. && b[0] > 0.))) {\n resultTemp[0] = (resultTemp[0] + b[0]) % b[0];\n }\n if (!((a[1] < 0. && b[1] < 0.) || (a[1] >= 0. && b[1] > 0.))) {\n resultTemp[1] = (resultTemp[1] + b[1]) % b[1];\n }\n if (!((a[2] < 0. && b[2] < 0.) || (a[2] >= 0. && b[2] > 0.))) {\n resultTemp[2] = (resultTemp[2] + b[2]) % b[2];\n }\n if (!((a[3] < 0. && b[3] < 0.) || (a[3] >= 0. && b[3] > 0.))) {\n resultTemp[3] = (resultTemp[3] + b[3]) % b[3];\n }\n`,Pae=\"let resultTemp = a * b;\",Oae=`\n var resultTemp = f32(a != b);\n let valueForNaN = 1.0;\n`,Mae=`\n var resultTemp = vec4(a != b);\n let valueForNaN = 1.0;\n`,Lae=`\n let isNaN = a < 0.0 && floor(b) < b;\n if (b == 0.0) {\n return 1.0;\n }\n var resultTemp = select(sign(a) * pow(abs(a), b), pow(abs(a), b),\n round(abs(b) % 2.0) != 1.0);\n`,Bae=`\n let isModRound1Bool = vec4(round(abs(b) % vec4(2.0))) == vec4(1);\n let isModRound1 = vec4(isModRound1Bool);\n let multiplier = sign(a) * isModRound1 + (vec4(1.0) - isModRound1);\n var resultTemp = multiplier * pow(abs(a), b);\n\n // Ensure that a^0 = 1, including 0^0 = 1 as this correspond to TF and JS\n let isExpZero = b == vec4(0.0);\n if (isExpZero.r) {\n resultTemp.r = 1.0;\n }\n if (isExpZero.g) {\n resultTemp.g = 1.0;\n }\n if (isExpZero.b) {\n resultTemp.b = 1.0;\n }\n if (isExpZero.a) {\n resultTemp.a = 1.0;\n }\n let isNaN = (a < vec4(0.0)) & (floor(b) < b);\n`,zae=\"if (a < 0.0) { return b * a; } return a;\",Vae=`\n let aLessThanZero = vec4(a < vec4(0.0));\n return (aLessThanZero * (b * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`,Wae=\"let resultTemp = (a - b) * (a - b);\",Uae=\"let resultTemp = a - b;\";function Qc(r,t){let e;do{switch(r){case fe.ATAN2:e=gae;break;case fe.MAX:e=Rae;break;case fe.MIN:e=Dae;break;case fe.MOD:e=t?Fae:Aae;break;case fe.NOT_EQUAL:e=t?Mae:Oae;break;case fe.POW:e=t?Bae:Lae;break;default:continue}let o,n,s;return t?(o=\"isnanVec4\",n=\"vec4\",s=\"vec4\"):(o=\"isnan\",n=\"f32\",s=\"bool\"),`\n let aIsNaN = ${o}(a);\n let aPostLegalization = select(a, ${n}(42), aIsNaN);\n let bIsNaN = ${o}(b);\n let bPostLegalization = select(b, ${n}(42), bIsNaN);\n let isNaN = false;\n let valueForNaN = uniforms.NAN;\n {\n let a = aPostLegalization;\n let b = bPostLegalization;\n ${e}\n return select(\n resultTemp, ${n}(valueForNaN),\n ${s}(isNaN) | aIsNaN | bIsNaN);\n }\n `}while(!1);switch(r){case fe.ADD:e=hae;break;case fe.COMPLEX_MULTIPLY_IMAG:e=yae;break;case fe.COMPLEX_MULTIPLY_REAL:e=xae;break;case fe.DIV:e=bae;break;case fe.ELU_DER:e=Cae;break;case fe.EQUAL:e=wae;break;case fe.FLOOR_DIV:e=Sae;break;case fe.GREATER:e=Iae;break;case fe.GREATER_EQUAL:e=vae;break;case fe.LESS:e=kae;break;case fe.LESS_EQUAL:e=Nae;break;case fe.LOGICAL_AND:return t?_ae:Tae;case fe.LOGICAL_OR:return t?Eae:$ae;case fe.MUL:e=Pae;break;case fe.PRELU:return t?Vae:zae;case fe.SQUARED_DIFFERENCE:e=Wae;break;case fe.SUB:e=Uae;break;default:}return`\n ${e}\n return resultTemp;\n `}var Z;(function(r){r[r.ABS=0]=\"ABS\",r[r.ACOS=1]=\"ACOS\",r[r.ACOSH=2]=\"ACOSH\",r[r.ASIN=3]=\"ASIN\",r[r.ASINH=4]=\"ASINH\",r[r.ATAN=5]=\"ATAN\",r[r.ATANH=6]=\"ATANH\",r[r.CEIL=7]=\"CEIL\",r[r.COS=8]=\"COS\",r[r.COSH=9]=\"COSH\",r[r.ELU=10]=\"ELU\",r[r.ERF=11]=\"ERF\",r[r.EXP=12]=\"EXP\",r[r.EXPM1=13]=\"EXPM1\",r[r.FLOOR=14]=\"FLOOR\",r[r.IS_FINITE=15]=\"IS_FINITE\",r[r.IS_INF=16]=\"IS_INF\",r[r.IS_NAN=17]=\"IS_NAN\",r[r.LINEAR=18]=\"LINEAR\",r[r.LOG=19]=\"LOG\",r[r.LOG1P=20]=\"LOG1P\",r[r.LOGICAL_NOT=21]=\"LOGICAL_NOT\",r[r.NEG=22]=\"NEG\",r[r.RELU=23]=\"RELU\",r[r.RELU6=24]=\"RELU6\",r[r.LEAKYRELU=25]=\"LEAKYRELU\",r[r.RECIPROCAL=26]=\"RECIPROCAL\",r[r.ROUND=27]=\"ROUND\",r[r.RSQRT=28]=\"RSQRT\",r[r.SELU=29]=\"SELU\",r[r.SIGMOID=30]=\"SIGMOID\",r[r.SIGN=31]=\"SIGN\",r[r.SIN=32]=\"SIN\",r[r.SINH=33]=\"SINH\",r[r.SOFTPLUS=34]=\"SOFTPLUS\",r[r.SQRT=35]=\"SQRT\",r[r.SQUARE=36]=\"SQUARE\",r[r.STEP=37]=\"STEP\",r[r.TAN=38]=\"TAN\",r[r.TANH=39]=\"TANH\",r[r.TO_INT=40]=\"TO_INT\"})(Z||(Z={}));var Gae=\"return abs(a);\",Hae=`\n if (abs(a) > 1.) {\n return uniforms.NAN;\n }\n return acos(a);\n`,Kae=`\n if (a < 1.) {\n return uniforms.NAN;\n }\n return acosh(a);\n`,qae=`\n if (abs(a) > 1.) {\n return uniforms.NAN;\n }\n return asin(a);\n`,jae=\"return asinh(a);\",Xae=`\n if (isnan(a)) {\n return uniforms.NAN;\n }\n return atan(a);\n`,Yae=`\n if (abs(a) > 1.) {\n return uniforms.NAN;\n }\n if (a == 1.) {\n return uniforms.INFINITY;\n }\n if (a == -1.) {\n return -uniforms.INFINITY;\n }\n return atanh(a);\n`,Qae=\"return ceil(a);\",Zae=\"return cos(a);\",Jae=`\n let e2x = exp(-a);\n return (e2x + 1.0 / e2x) / 2.0;\n`,eie=\"return exp(a) - 1.0;\",tie=\"if (a >= 0.0) { return a; } return (exp(a) - 1.0);\",rie=`\n var resFloat = exp(a) - vec4(1.0);\n if (a.r >= 0.0) {\n resFloat.r = a.r;\n }\n if (a.g >= 0.0) {\n resFloat.g = a.g;\n }\n if (a.b >= 0.0) {\n resFloat.b = a.b;\n }\n if (a.a >= 0.0) {\n resFloat.a = a.a;\n }\n return resFloat;\n`,oie=`\n // Error function is calculated approximately with elementary function.\n // See \"Handbook of Mathematical Functions with Formulas,\n // Graphs, and Mathematical Tables\", Abramowitz and Stegun.\n let p = ${w.ERF_P};\n let a1 = ${w.ERF_A1};\n let a2 = ${w.ERF_A2};\n let a3 = ${w.ERF_A3};\n let a4 = ${w.ERF_A4};\n let a5 = ${w.ERF_A5};\n\n let sign = sign(a);\n let absA = abs(a);\n let t = 1.0 / (1.0 + p * absA);\n return sign * (1.0 - (((((a5 * t + a4) * t) + a3) * t + a2) * t + a1) * t * exp(-absA * absA));\n`,nie=\"return exp(a);\",sie=\"return floor(a);\",aie=\"return f32(!isnan(a) && !isinf(a));\",iie=\"return f32(isinf(a));\",uie=\"return f32(isnan(a));\",pie=\"return a;\",cie=`if (a < 0.0) { return uniforms.NAN; }\n return log(a);`,lie=`\n if (isnan(a)) { return a; }\n return log(1.0 + a);\n`,mie=\"return f32(!(a >= 1.0));\",die=\"return -a;\",fie=\"if (a < 0.0) { return uniforms.alpha * a; } return a;\",hie=`\n let aLessThanZero = vec4(a < vec4(0.0));\n return (aLessThanZero * (uniforms.alpha * a)) + ((vec4(1.0) - aLessThanZero) * a);\n`,gie=\"return 1.0 / a;\",xie=\"return select(a, 0.0, a < 0.0);\",yie=\"return clamp(a, 0.0, 6.0);\",bie=\"return clamp(a, vec4(0.0, 0.0, 0.0, 0.0), vec4(6.0, 6.0, 6.0, 6.0));\",Cie=`\n return select(a, vec4(0.0), a < vec4(0.0));\n`,wie=\"return round(a);\",Sie=\"return inverseSqrt(a);\",Iie=`\n if (a >= 0.0) {\n return ${w.SELU_SCALE} * a;\n } else {\n return ${w.SELU_SCALEALPHA} * (exp(a) - 1.0);\n }\n`,vie=\"return 1.0 / (1.0 + exp(-1.0 * a));\",kie=\"return sign(a);\",Nie=\"return sin(a);\",Tie=`\n let e2x = exp(a);\n return (e2x - 1.0 / e2x) / 2.0;\n`,_ie=`\n let epsilon = 1.1920928955078125e-7;\n let threshold = log(epsilon) + 2.0;\n\n let too_large = a > -threshold;\n let too_small = a < threshold;\n let exp_a = exp(a);\n\n if (too_large) {\n return a;\n } else if (too_small) {\n return exp_a;\n } else {\n return log(exp_a + 1.0);\n }\n`,$ie=\"return sqrt(a);\",Eie=\"return a * a;\",Rie=`\n if (isnan(a)) {\n return a;\n }\n\n return select(uniforms.stepAlpha, 1.0, a > 0.0);\n`,Die=\"return tan(a);\",Aie=`\n let e2x = exp(-2.0 * abs(a));\n return sign(a) * (1.0 - e2x) / (1.0 + e2x);\n`,Fie=\"return f32(i32((a)));\";function vi(r,t){switch(r){case Z.ABS:return Gae;case Z.ACOS:return Hae;case Z.ACOSH:return Kae;case Z.ASIN:return qae;case Z.ASINH:return jae;case Z.ATAN:return Xae;case Z.ATANH:return Yae;case Z.COS:return Zae;case Z.COSH:return Jae;case Z.CEIL:return Qae;case Z.ELU:return t?rie:tie;case Z.ERF:return oie;case Z.EXP:return nie;case Z.EXPM1:return eie;case Z.FLOOR:return sie;case Z.IS_FINITE:return aie;case Z.IS_INF:return iie;case Z.IS_NAN:return uie;case Z.LINEAR:return pie;case Z.LOG:return cie;case Z.LOG1P:return lie;case Z.LOGICAL_NOT:return mie;case Z.NEG:return die;case Z.LEAKYRELU:return t?hie:fie;case Z.RECIPROCAL:return gie;case Z.RELU:return t?Cie:xie;case Z.RELU6:return t?bie:yie;case Z.ROUND:return wie;case Z.RSQRT:return Sie;case Z.SELU:return Iie;case Z.SIGMOID:return vie;case Z.SIGN:return kie;case Z.SIN:return Nie;case Z.SINH:return Tie;case Z.SOFTPLUS:return _ie;case Z.SQRT:return $ie;case Z.SQUARE:return Eie;case Z.STEP:return Rie;case Z.TAN:return Die;case Z.TANH:return Aie;case Z.TO_INT:return Fie;default:throw new Error(`BinaryType ${r} is not implemented!`)}}function fr(r,t=!1,e=!1,o=3){if(r===null)return\"\";let n=\"\";if(r===\"linear\")n=vi(Z.LINEAR);else if(r===\"relu\")n=vi(Z.RELU,e);else if(r===\"elu\")n=vi(Z.ELU,e);else if(r===\"relu6\")n=vi(Z.RELU6,e);else if(r===\"prelu\")n=Qc(fe.PRELU,e);else if(r===\"sigmoid\")n=vi(Z.SIGMOID,e);else if(r===\"leakyrelu\")n=vi(Z.LEAKYRELU,e);else throw new Error(`Activation ${r} has not been implemented for the WebGPU backend.`);let a=Ae(e?4:1),i=\"\";return t?i=`\n fn activation(a : ${a}, coords : vec${o}) -> ${a} {\n let b = getPreluActivationWeightsByOutputCoords(coords);\n ${n}\n }`:i=`\n fn activation(a : ${a}, coords : vec${o}) -> ${a} {\n ${n}\n }`,i}function Zr(r,t){return`\n ${r?\"value = value + getBiasByOutputCoords(coords);\":\"\"}\n ${t?\"value = activation(value, coords);\":\"\"}\n `}function Qv(r,t,e=!1,o=!1,n=!1,s=1){y.assert(r&&s===1||!r,()=>`transposeA ${r} is not compatible with component size ${s}`);let a=`\n ${r?\"value = getA(batch, col, row);\":\"value = getA(batch, row, col);\"}\n\n `,i=t?\"value = getB(batch, col, row);\":\"value = getB(batch, row, col);\";return`\n fn mm_readA(batch: i32, row: i32, col: i32) -> ${Ae(s)} {\n var value = ${Ae(s)}(0.0);\n ${e&&n?a:`\n ${r?\"if(row < uniforms.dimAOuter && col < uniforms.dimInner)\":\"if(row < uniforms.aShape[1] && col < uniforms.aShape[2])\"}\n {\n ${a}\n }\n `}\n return value;\n }\n\n fn mm_readB(batch: i32, row: i32, col: i32) -> ${Ae(s)} {\n var value = ${Ae(s)}(0.0);\n ${i}\n return value;\n }\n `}function hm(r,t,e,o,n=!1,s=!1,a=!1,i=1){return`\n ${Qv(e,o,n,s,a,i)}\n fn mm_write(batch: i32, row: i32, col: i32, valueIn: ${Ae(i)}) {\n ${n&&s?\"\":\"if (row < uniforms.dimAOuter && col < uniforms.dimBOuter)\"}\n {\n var value = valueIn;\n let coords = vec3(batch, row, col);\n ${Zr(r,t)}\n setOutputAtCoords(coords[0], coords[1], coords[2], value);\n }\n }\n `}var Pie=(r,t)=>r?`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n kStart + inputRow,\n globalRowStart + inputCol * ${t});\n `:`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n globalRow + innerRow,\n kStart + inputCol * ${t});\n `,Oie=(r,t,e,o)=>{if(r)return`\n for (var k = 0; k < ${o}; k++) {\n let BCached0 = mm_Bsub[k][tileCol];\n let ACached0 = mm_Asub[k][localRow];\n for (var i = 0; i < ${e}; i++) {\n acc[i] = fma(BCached0, vec4(ACached0[i]), acc[i]);\n }\n }`;{let n=\"\",s=\"\";for(let a=0;a(ACached[${a}]), acc[i]);`;return`\n for (var k = 0; k < ${o/t}; k++) {\n ${n}\n for (var i = 0; i < ${e}; i++) {\n let ACached = mm_Asub[tileRow + i][k];\n ${s}\n }\n }`}};function Fp(r,t,e=!1,o=32,n=!1,s=32,a=!1){let i=t[1]*r[1],p=t[0]*r[0],u=e?i:o,c=e?o:i,l=u/t[0],m=o/t[1],d=r[1],f=r[0];return y.assert((e&&l===4&&r[1]===4||!e&&(l===3||l===4))&&u%t[0]===0&&o%t[1]===0&&r[0]===4,()=>`If transposeA ${e} is true, innerElementSize ${l} and workPerThread[1] ${r[1]} must be 4.\n Otherwise, innerElementSize ${l} must be 3 or 4.\n tileAWidth ${u} must be divisible by workgroupSize[0]${t[0]}. tileInner ${o} must be divisible by workgroupSize[1] ${t[1]}. colPerThread ${r[0]} must be 4.`),`\n var mm_Asub : array, ${u/l}>, ${c}>;\n var mm_Bsub : array, ${p/r[0]}>, ${o}>;\n\n ${G()} {\n let localRow = i32(localId.y);\n let tileRow = localRow * ${d};\n let tileCol = i32(localId.x);\n\n let globalRow = i32(globalId.y) * ${d};\n let globalCol = i32(globalId.x) * ${f};\n let batch = ${n?\"0\":\"i32(globalId.z)\"};\n let batchA = ${n||!a?\"batch\":\"batch % uniforms.aShape[0]\"};\n let batchB = ${n||!a?\"batch\":\"batch % uniforms.bShape[0]\"};\n let globalRowStart = i32(workgroupId.y) * ${i};\n\n let numTiles = ${n?`${Math.ceil(s/o)}`:`(uniforms.dimInner - 1) / ${o} + 1`};\n var kStart = ${n?`i32(globalId.z) * ${s}`:\"0\"};\n\n var acc: array, ${d}>;\n\n // Loop over shared dimension.\n let tileRowB = localRow * ${m};\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n for (var innerRow = 0; innerRow < ${d}; innerRow++) {\n let inputRow = tileRow + innerRow;\n let inputCol = tileCol;\n ${Pie(e,l)}\n }\n\n // Load one tile of B into local memory.\n for (var innerRow = 0; innerRow < ${m}; innerRow++) {\n let inputRow = tileRowB + innerRow;\n let inputCol = tileCol;\n mm_Bsub[inputRow][inputCol] = mm_readB(batchB, kStart + inputRow, globalCol);\n }\n kStart = kStart + ${o};\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n ${Oie(e,l,d,o)}\n workgroupBarrier();\n }\n\n for (var innerRow = 0; innerRow < ${d}; innerRow++) {\n mm_write(batch, globalRow + innerRow, globalCol, acc[innerRow]);\n }\n }`}var JB=r=>r?`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n kStart + inputRow,\n globalRowStart + inputCol);\n `:`\n mm_Asub[inputRow][inputCol] = mm_readA(batchA,\n globalRowStart + inputRow,\n kStart + inputCol);\n `,Mie=r=>r?\"let ACached = mm_Asub[k][tileRow + innerRow];\":\"let ACached = mm_Asub[tileRow + innerRow][k];\";function Pp(r,t,e=!1,o=32,n=!1,s=32,a=!1,i=!1){let p=r[1]*t[1],u=r[0]*t[0],c=e?p:o,l=e?o:p;y.assert(l%t[1]===0&&c%t[0]===0&&o%t[1]===0,()=>`tileAHight ${l} must be divisible by workgroupSize[1]${t[1]}, tileAWidth ${c} must be divisible by workgroupSize[0]${t[0]}, tileInner ${o} must be divisible by workgroupSize[1]${t[1]}`);let m=l/t[1],d=c/t[0],f=o/t[1],h=r[1],g=r[0],x=a?`\n let localRow = i32(localId.y);\n let localCol = i32(localId.x);\n let globalRowStart = i32(workgroupId.y) * ${p};\n let globalColStart = i32(workgroupId.x) * ${u};\n\n // Loop over shared dimension.\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n for (var inputRow = localRow; inputRow < ${l}; inputRow = inputRow + ${t[1]}) {\n for (var inputCol = localCol; inputCol < ${c}; inputCol = inputCol + ${t[0]}) {\n ${JB(e)}\n }\n }\n // Load one tile of B into local memory.\n for (var inputRow = localRow; inputRow < ${o}; inputRow = inputRow + ${t[1]}) {\n for (var inputCol = localCol; inputCol < ${u}; inputCol = inputCol + ${t[0]}) {\n mm_Bsub[inputRow][inputCol] = mm_readB(batchB,\n kStart + inputRow,\n globalColStart + inputCol);\n }\n }\n kStart = kStart + ${o};\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n var BCached : array;\n for (var k = 0; k < ${o}; k++) {\n for (var inner = 0; inner < ${g}; inner++) {\n BCached[inner] = mm_Bsub[k][localCol + inner * ${t[0]}];\n }\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n let ACached = ${e?`mm_Asub[k][localRow + innerRow * ${t[1]}];`:`mm_Asub[localRow + innerRow * ${t[1]}][k];`}\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n acc[innerRow][innerCol] =\n fma(ACached, BCached[innerCol], acc[innerRow][innerCol]);\n }\n }\n }\n workgroupBarrier();\n }\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n let gRow = globalRowStart + localRow + innerRow * ${t[1]};\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n let gCol = globalColStart + localCol + innerCol * ${t[0]};\n mm_write(batch, gRow, gCol, acc[innerRow][innerCol]);\n }\n }\n `:`\n let tileRow = i32(localId.y) * ${h};\n let tileCol = i32(localId.x) * ${g};\n\n let globalRow = i32(globalId.y) * ${h};\n let globalCol = i32(globalId.x) * ${g};\n let globalRowStart = i32(workgroupId.y) * ${p};\n\n let tileRowA = i32(localId.y) * ${m};\n let tileColA = i32(localId.x) * ${d};\n let tileRowB = i32(localId.y) * ${f};\n // Loop over shared dimension.\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n for (var innerRow = 0; innerRow < ${m}; innerRow++) {\n for (var innerCol = 0; innerCol < ${d}; innerCol++) {\n let inputRow = tileRowA + innerRow;\n let inputCol = tileColA + innerCol;\n ${JB(e)}\n }\n }\n\n // Load one tile of B into local memory.\n for (var innerRow = 0; innerRow < ${f}; innerRow++) {\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n let inputRow = tileRowB + innerRow;\n let inputCol = tileCol + innerCol;\n mm_Bsub[inputRow][inputCol] = mm_readB(batchB,\n kStart + inputRow,\n globalCol + innerCol);\n }\n }\n kStart = kStart + ${o};\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n var BCached : array;\n for (var k = 0; k < ${o}; k++) {\n for (var inner = 0; inner < ${g}; inner++) {\n BCached[inner] = mm_Bsub[k][tileCol + inner];\n }\n\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n ${Mie(e)}\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n acc[innerRow][innerCol] =\n fma(ACached, BCached[innerCol], acc[innerRow][innerCol]);\n }\n }\n }\n\n workgroupBarrier();\n }\n\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n mm_write(batch, globalRow + innerRow, globalCol + innerCol,\n acc[innerRow][innerCol]);\n }\n }\n `;return`\n var mm_Asub : array, ${l}>;\n var mm_Bsub : array, ${o}>;\n\n ${G()} {\n let batch = ${n?\"0\":\"i32(globalId.z)\"};\n let batchA = ${n||!i?\"batch\":\"batch % uniforms.aShape[0]\"};\n let batchB = ${n||!i?\"batch\":\"batch % uniforms.bShape[0]\"};\n let numTiles = ${n?`${Math.ceil(s/o)}`:`(uniforms.dimInner - 1) / ${o} + 1`};\n var kStart = ${n?`i32(globalId.z) * ${s}`:\"0\"};\n\n var acc : array, ${h}>;\n\n // Without this initialization strange values show up in acc.\n for (var innerRow = 0; innerRow < ${h}; innerRow++) {\n for (var innerCol = 0; innerCol < ${g}; innerCol++) {\n acc[innerRow][innerCol] = 0.0;\n }\n }\n ${x}\n }\n `}var Lie=r=>r?`\n mm_readA(batchA, colA, globalRow),\n mm_readA(batchA, colA + 1, globalRow),\n mm_readA(batchA, colA + 2, globalRow),\n mm_readA(batchA, colA + 3, globalRow)\n `:`\n mm_readA(batchA, globalRow, colA),\n mm_readA(batchA, globalRow, colA + 1),\n mm_readA(batchA, globalRow, colA + 2),\n mm_readA(batchA, globalRow, colA + 3)\n `;function Bie(r,t=!1){y.assert(r[1]===1&&r[2]===1,()=>`A linear work group size is required. But got ${r}.`);let e=r[0]*4;return`\n var mm_Asub : array, ${r[0]}>;\n\n ${G()} {\n let tileCol = i32(localId.x);\n let globalCol = i32(globalId.x);\n let globalRow = i32(globalId.y);\n\n let numTiles = (uniforms.dimInner - 1) / ${e} + 1;\n let batch = i32(globalId.z);\n let batchA = batch % uniforms.aShape[0];\n let batchB = batch % uniforms.bShape[0];\n // Without this initialization strange values show up in acc.\n var acc = 0.0;\n\n // Loop over shared dimension.\n for (var t = 0; t < numTiles; t++) {\n // Load one tile of A into local memory.\n let colA = t * ${e} + tileCol * 4;\n mm_Asub[tileCol] = vec4(${Lie(t)});\n workgroupBarrier();\n\n // Compute acc values for a single thread.\n for (var k = 0; k < ${e/4}; k++) {\n let rowB = t * ${e} + k * 4;\n let BCached = vec4(mm_readB(batchB, rowB, globalCol),\n mm_readB(batchB, rowB + 1, globalCol),\n mm_readB(batchB, rowB + 2, globalCol),\n mm_readB(batchB, rowB + 3, globalCol));\n\n let ACached = mm_Asub[k];\n acc = acc + dot(ACached, BCached);\n }\n\n workgroupBarrier();\n }\n\n mm_write(batch, globalRow, globalCol, acc);\n }\n `}var Xg=class{constructor(t,e,o=!1,n=!1,s=null,a=null,i=null,p=!1){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.outputShape=e,this.dispatchLayout={x:[2],y:[1],z:[0]};let u=o?t[1]:t[2];if(this.isVec4=(u%4===0&&!o||e[1]%4===0&&o)&&e[2]%4===0&&!n,this.outputComponent=this.isVec4?4:1,this.isVectorA=e[1]===1&&!o,!this.isVec4&&this.isVectorA)this.elementsPerThread=[1,1,1],this.workgroupSize=[32,1,1];else{let m=Xv(e[1],u,e[2],o);this.workgroupSize=m.workgroupSize,this.elementsPerThread=m.elementsPerThread}this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,this.elementsPerThread);let c=s!=null,l=i!=null;c&&this.variableNames.push(\"bias\"),l&&this.variableNames.push(\"preluActivationWeights\"),this.sequentialAccessByThreads=p,this.transposeA=o,this.transposeB=n,this.addBias=c,this.activation=a,this.hasPreluActivationWeights=l,[this.fitAOuter,this.fitBOuter,this.fitInner]=this.getShapeFit(e[1],e[2],u),this.shaderKey=`matMulPacked_${this.elementsPerThread}_${o}_${n}_${this.activation}_${this.fitAOuter}_${this.fitBOuter}_${this.fitInner}_${this.isVec4}_${this.isVectorA}_${this.sequentialAccessByThreads}`}getShapeFit(t,e,o){let n=this.workgroupSize[1]*this.elementsPerThread[1],s=this.workgroupSize[0]*this.elementsPerThread[0];!this.isVec4&&this.isVectorA?this.tileInner=this.workgroupSize[0]*4:this.tileInner=s;let a=t%n===0,i=e%s===0,p=o%this.tileInner===0;return[a,i,p]}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights,this.isVec4)}\n ${hm(this.addBias,this.activation,!1,this.transposeB,this.fitAOuter,this.fitBOuter,this.fitInner,this.isVec4?4:1)}\n ${this.isVec4?Fp(this.elementsPerThread,this.workgroupSize,this.transposeA,this.tileInner,!1,null,!0):this.isVectorA?Bie(this.workgroupSize,this.transposeA):Pp(this.elementsPerThread,this.workgroupSize,this.transposeA,this.tileInner,!1,null,this.sequentialAccessByThreads,!0)}\n `}};function zie(r){return`\n var sumValues : array;\n ${G()} {\n let coords = getOutputCoords();\n let batch = coords[0];\n let batchA = batch % uniforms.aShape[0];\n let batchB = batch % uniforms.bShape[0];\n let row = coords[1];\n let col = coords[2];\n var sum = 0.0;\n let Length = uniforms.dimInner;\n for (var k = i32(localId.x); k < Length; k = k + ${r}) {\n let dataA = mm_readA(batchA, row, k);\n let dataB = mm_readB(batchB, k, col);\n sum = sum + dataA * dataB;\n }\n sumValues[localId.x] = sum;\n workgroupBarrier();\n\n for(var currentSize = ${r/2}u; currentSize > 1u;\n currentSize = currentSize / 2u) {\n if (localId.x < currentSize)\n {\n sumValues[localId.x] = sumValues[localId.x] + sumValues[localId.x + currentSize];\n }\n workgroupBarrier();\n }\n\n if (localId.x == 0u) {\n sum = sumValues[0] + sumValues[1];\n mm_write(batch, row, col, sum);\n }\n }\n `}var Yg=class{constructor(t,e=!1,o=!1,n=null,s=null,a=null){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.workgroupSize=[256,1,1],this.outputShape=t,this.dispatchLayout={x:[],y:[1,2],z:[0]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize);let i=n!=null,p=a!=null;i&&this.variableNames.push(\"bias\"),p&&this.variableNames.push(\"preluActivationWeights\"),this.transposeA=e,this.transposeB=o,this.addBias=i,this.activation=s,this.hasPreluActivationWeights=p,this.shaderKey=`matMulReduce_${this.activation}_${e}_${o}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights)}\n ${hm(this.addBias,this.activation,this.transposeA,this.transposeB)}\n ${zie(this.workgroupSize[0])}\n `}};function Vie(r){let t=r[1],e=r[0],o=t>e?t:e;return`\n var mm_Asub : array, ${t}>;\n var mm_Bsub : array, ${o}>;\n\n // If the output size is small for matrix multiplication, avoid to use vec4\n // and handle some elements per thread to optimally utilize the ALU.\n // Read data from global memory to registers firstly, then store them into\n // shared memory, so it is instruction-Level parallelism for arithmetic\n // operations and others handle IO operations between barrier api, makes ALU\n // and load/store units work simultaneously, could improves the performance.\n ${G()} {\n let tileRow = i32(localId.y);\n let tileCol = i32(localId.x);\n let globalRow = i32(globalId.y);\n let globalCol = i32(globalId.x);\n let batch = i32(globalId.z);\n let batchA = batch % uniforms.aShape[0];\n let batchB = batch % uniforms.bShape[0];\n\n // uniforms.dimInner should be greater than 0.\n let numTiles = (uniforms.dimInner - 1) / ${o} + 1;\n var acc = 0.0;\n\n var globalColA = tileCol;\n var globalRowB = 0;\n var regA = mm_readA(batchA, globalRow, globalColA);\n var regB0 = mm_readB(batchB, globalRowB + 2 * tileRow, globalCol);\n var regB1 = mm_readB(batchB, globalRowB + 2 * tileRow + 1, globalCol);\n globalColA = globalColA + ${o};\n globalRowB = globalRowB + ${o};\n\n for (var t = 0; t < numTiles; t = t + 1) {\n mm_Asub[tileRow][tileCol] = regA;\n mm_Bsub[2 * tileRow][tileCol] = regB0;\n mm_Bsub[2 * tileRow + 1][tileCol] = regB1;\n\n workgroupBarrier();\n\n regA = mm_readA(batchA, globalRow, globalColA);\n regB0 = mm_readB(batchB, globalRowB + 2 * tileRow, globalCol);\n regB1 = mm_readB(batchB, globalRowB + 2 * tileRow + 1, globalCol);\n globalColA = globalColA + ${o};\n globalRowB = globalRowB + ${o};\n\n for (var k = 0; k < ${o}; k = k + 1) {\n acc = acc + mm_Asub[tileRow][k] * mm_Bsub[k][tileCol];\n }\n workgroupBarrier();\n }\n\n mm_write(batch, globalRow, globalCol, acc);\n }\n `}var Qg=class{constructor(t,e,o,n=!1,s=!1,a=null,i=null,p=null){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.workgroupSize=[16,8,1],this.outputShape=o,this.dispatchLayout={x:[2],y:[1],z:[0]},this.dispatch=[Math.ceil(o[2]/this.workgroupSize[0]),Math.ceil(o[1]/this.workgroupSize[1]),o[0]];let u=a!=null;u&&this.variableNames.push(\"bias\");let c=p!=null;c&&this.variableNames.push(\"preluActivationWeights\"),this.transposeA=n,this.transposeB=s,this.addBias=u,this.activation=i,this.hasPreluActivationWeights=c,this.shaderKey=`matMulSmallOutputSize_${this.activation}_${n}_${s}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights)}\n ${hm(this.addBias,this.activation,this.transposeA,this.transposeB)}\n ${Vie(this.workgroupSize)}\n `}};var Zg=class{constructor(t,e,o=!1,n=!1){this.variableNames=[\"A\",\"B\"],this.uniforms=\"dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.workgroupSize=[8,8,1],this.atomic=!0,this.splitedDimInner=128,y.assert(t[0]===1,()=>\"MatMulSplitKProgram only supports batch = 1.\"),this.outputShape=t,this.dispatchLayout={x:[2],y:[1],z:[0,3]};let s=(o&&this.outputShape[1]%4===0||!o&&e%4===0)&&this.outputShape[2]%4===0;this.elementsPerThread=[4,4,this.splitedDimInner],this.outputComponent=s?4:1,s||(this.outputShape[1]<16&&(this.elementsPerThread[1]=1),this.outputShape[2]<16&&(this.elementsPerThread[0]=1)),this.dispatch=H(this.dispatchLayout,[this.outputShape[0],this.outputShape[1],this.outputShape[2],e],this.workgroupSize,this.elementsPerThread),this.transposeA=o,this.transposeB=n,this.shaderKey=`matMulSplitK_${o}_${n}_${this.elementsPerThread}_${this.outputComponent}`}getUserCode(){let t=this.outputComponent;return`\n ${Qv(!1,this.transposeB,!1,!1,!1,t)}\n fn mm_write(batch: i32, row : i32, col : i32, value : ${Ae(t)}) {\n if (row < uniforms.dimAOuter && col < uniforms.dimBOuter) {\n let coords = vec3(batch, row, col);\n let flatIndex = getOutputIndexFromCoords(coords);\n // The problem is that we should initialize output to zero before using.\n // Otherwise, the original value will be added to the result.\n for (var i = 0; i < ${t}; i = i + 1) {\n ${Qr(\"&result[flatIndex + i]\",`${t>1?\"value[i]\":\"value\"}`,\"float32\")}\n }\n }\n }\n ${t===4?Fp(this.elementsPerThread,this.workgroupSize,this.transposeA,32,!0,this.splitedDimInner):Pp(this.elementsPerThread,this.workgroupSize,this.transposeA,32,!0,this.splitedDimInner)}\n `}},Jg=class{constructor(t,e=null,o=null,n=null){this.uniforms=\"\",this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.addBias=e!=null,this.hasPreluActivationWeights=n!=null,this.activation=o,this.addBias&&this.variableNames.push(\"bias\"),this.hasPreluActivationWeights&&this.variableNames.push(\"preluActivationWeights\"),this.shaderKey=`biasActivation_${o}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights)}\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n var value = getXByOutputIndex(index);\n ${Zr(this.addBias,this.activation)}\n setOutputAtIndex(index, value);\n }\n }\n `}};var ex=class{constructor(t){this.variableNames=[],this.outputShape=[],this.uniforms=\"value : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"fill\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n setOutputAtIndex(index, uniforms.value);\n }\n }\n `}};function kt(r){let{backend:t,attrs:e}=r,{shape:o,value:n}=e,{dtype:s}=e;if(s=s||y.inferDtype(n),s===\"string\"){let a=y.getArrayFromDType(s,y.sizeFromShape(o));return a.fill(n),t.makeTensorInfo(o,s,a)}else{let a=new ex(o),i=[{type:\"float32\",data:[n]}];return t.runWebGPUProgram(a,[],s,i)}}var ez={kernelName:sa,backendName:\"webgpu\",kernelFunc:kt};function pe(r){let{inputs:t,attrs:e}=r,{x:o}=t,{shape:n}=e,s=y.sizeFromShape(o.shape),a=y.inferFromImplicitShape(n,s),i=y.sizeFromShape(a);return y.assert(s===i,()=>`The new shape (${a}) has ${i} elements and the old shape (${o.shape}) has ${s} elements. The new shape and old shape must have the same number of elements.`),r.backend.incRef(o.dataId),{dataId:o.dataId,shape:a,dtype:o.dtype}}var tz={kernelName:da,backendName:\"webgpu\",kernelFunc:pe};function Op({a:r,b:t,transposeA:e,transposeB:o,backend:n,bias:s=null,preluActivationWeights:a=null,leakyreluAlpha:i=0,activation:p=null}){let u=r.shape.length,c=t.shape.length,l=e?r.shape[u-2]:r.shape[u-1],m=o?t.shape[c-1]:t.shape[c-2],d=e?r.shape[u-1]:r.shape[u-2],f=o?t.shape[c-2]:t.shape[c-1],h=r.shape.slice(0,-2),g=t.shape.slice(0,-2),x=y.sizeFromShape(h),b=y.sizeFromShape(g),S=Ir.assertAndGetBroadcastShape(r.shape.slice(0,-2),t.shape.slice(0,-2)).concat([d,f]);y.assert(l===m,()=>`Error in matMul: inner shapes (${l}) and (${m}) of Tensors with shapes ${r.shape} and ${t.shape} and transposeA=${e} and transposeB=${o} must match.`);let k=e?[x,l,d]:[x,d,l],_=o?[b,f,m]:[b,m,f],E=pe({inputs:{x:r},backend:n,attrs:{shape:k}}),R=pe({inputs:{x:t},backend:n,attrs:{shape:_}}),D=[E,R],P=Math.max(x,b),O=[E,R],M=[{type:\"int32\",data:[d]},{type:\"int32\",data:[f]},{type:\"int32\",data:[l]}],L,B,z=[P,d,f],U=A().get(\"WEBGPU_MATMUL_PROGRAM_TYPE\");if(U<0){let q=A().getNumber(\"WEBGPU_THRESHOLD_TO_INCREASE_WORKGROUPS_FOR_MATMUL\"),Y=q>0?q:n.thresholdToIncreaseWorkgroups,J=P*Math.ceil(d/32)*Math.ceil(f/32);J<=Y||d<=8&&J<=Y*2?P*d*f<=128?U=Lo.MatMulReduceProgram:P===1&&m>=2e3?U=Lo.MatMulSplitKProgram:U=Lo.MatMulSmallOutputSizeProgram:U=Lo.MatMulPackedProgram}switch(U){case Lo.MatMulReduceProgram:L=new Yg(z,e,o,s,p,a);break;case Lo.MatMulSplitKProgram:{if(B=kt({backend:n,attrs:{shape:z,value:0,dtype:r.dtype}}),L=new Zg(z,m,e,o),s||p){B=n.runWebGPUProgram(L,O,r.dtype,M,B);let Y=new Jg(B.shape,s,p,a),J=null,re=[B];s&&re.push(s),a&&re.push(a),p===\"leakyrelu\"&&(J=[{type:\"float32\",data:[i]}],Y.uniforms+=\" alpha : f32,\");let ne=n.runWebGPUProgram(Y,re,B.dtype,J);D.push(B);let ee=pe({inputs:{x:ne},backend:n,attrs:{shape:S}});D.push(ne);for(let oe of D)n.disposeData(oe.dataId);return ee}break}case Lo.MatMulSmallOutputSizeProgram:L=new Qg(k,_,z,e,o,s,p,a);break;case Lo.MatMulPackedProgram:let q=n.adapterInfo.isIntel();L=new Xg(k,z,e,o,s,p,a,q);break;default:throw new Error(`Unsupported MatMulProgramType ${U}.`)}s&&O.push(s),a&&O.push(a),p===\"leakyrelu\"&&(M.push({type:\"float32\",data:[i]}),L.uniforms+=\" alpha : f32,\"),B=n.runWebGPUProgram(L,O,r.dtype,M,B);let j=pe({inputs:{x:B},backend:n,attrs:{shape:S}});D.push(B);for(let q of D)n.disposeData(q.dataId);return j}function Wie(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s,bias:a,preluActivationWeights:i}=t,{transposeA:p,transposeB:u,activation:c,leakyreluAlpha:l}=o;return Op({a:n,b:s,transposeA:p,transposeB:u,backend:e,bias:a,preluActivationWeights:i,leakyreluAlpha:l,activation:c})}var rz={kernelName:Io,backendName:\"webgpu\",kernelFunc:Wie};var gm=class{constructor(t,e,o){this.variableNames=[\"AReal\",\"AImag\",\"BReal\",\"BImag\"],this.workgroupSize=[128,1,1],this.size=!0,this.outputShape=w.assertAndGetBroadcastShape(e,o),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=`binaryOpComplex_${t}`,this.op=t}getUserCode(){return`\n fn binaryOpComplex(\n areal : f32, aimag : f32, breal : f32, bimag : f32) -> f32 {\n ${Qc(this.op,!1)}\n }\n\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let areal = getARealByOutputIndex(index);\n let aimag = getAImagByOutputIndex(index);\n let breal = getBRealByOutputIndex(index);\n let bimag = getBImagByOutputIndex(index);\n setOutputAtIndex(index, binaryOpComplex(areal, aimag, breal, bimag));\n }\n }\n `}};var ki=class{constructor(t,e,o){if(this.size=!0,this.variableNames=[\"A\",\"B\"],this.outputShape=w.assertAndGetBroadcastShape(e,o),this.dispatchLayout=X(this.outputShape),this.op=t,this.useSharedMemoryWithA=e.length<=1&&o.length>1&&e[0]<128,this.useSharedMemoryWithB=o.length<=1&&e.length>1&&o[0]<128,this.useSharedMemoryWithA||this.useSharedMemoryWithB)this.outputComponent=1,this.variableComponents=[1,1],this.lastDimensionSize=this.useSharedMemoryWithB?o[0]:e[0],this.shaderKey=`binary_${t}_${this.lastDimensionSize}`,this.type=\"shared\",this.workgroupSize=[256,1,1];else{let n=e.length>0&&e[e.length-1]%4===0,s=o.length>0&&o[o.length-1]%4===0;n&&s?(this.outputComponent=4,this.variableComponents=[4,4]):n&&(y.isScalarShape(o)||o[o.length-1]===1)||s&&(y.isScalarShape(e)||e[e.length-1]===1)?(this.outputComponent=4,this.variableComponents=n?[4,1]:[1,4]):(this.outputComponent=1,this.variableComponents=[1,1]),this.type=\"nonshared\",this.shaderKey=`binary_${t}_${this.variableComponents}`,this.workgroupSize=[128,1,1]}this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.outputComponent,1,1])}getUserCode(){let t,e=this.outputComponent===4?\"vec4\":\"f32\",o=`\n fn binaryOperation(a : ${e}, b : ${e}) -> ${e} {\n ${Qc(this.op,this.outputComponent===4)}\n };\n `;if(this.type===\"shared\"){let n=this.lastDimensionSize>1?`coords[${this.outputShape.length-1}]`:\"0\",s=this.useSharedMemoryWithB?`let a = getAByOutputIndex(index);\n let b = sharedBuf[${n}];`:`let a = sharedBuf[${n}];\n let b = getBByOutputIndex(index);`;t=`\n ${o}\n var sharedBuf : array;\n ${G(\"index\")} {\n // Fill in the shared memory buffer.\n let localIndex = i32(localId.x);\n if(localIndex < ${this.lastDimensionSize}) {\n sharedBuf[localIndex] = f32(${this.useSharedMemoryWithB?\"B\":\"A\"}[localIndex]);\n }\n workgroupBarrier();\n\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n ${s}\n setOutputAtIndex(index, binaryOperation(a, b));\n }\n }\n `}else t=`\n ${o}\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index * ${this.outputComponent});\n let a = ${e}(getAByOutputCoords(coords));\n let b = ${e}(getBByOutputCoords(coords));\n setOutputAtIndex(index, binaryOperation(a, b));\n }\n }\n `;return t}};function Ft(r){let{inputs:t}=r,{x:e}=t;return r.backend.incRef(e.dataId),{dataId:e.dataId,shape:e.shape,dtype:e.dtype}}var oz={kernelName:wo,backendName:\"webgpu\",kernelFunc:Ft};function yo(r){let{inputs:t,backend:e}=r,{real:o,imag:n}=t,s=e.makeTensorInfo(o.shape,\"complex64\"),a=e.tensorMap.get(s.dataId),i=Ft({inputs:{x:o},backend:e}),p=Ft({inputs:{x:n},backend:e});return a.complexTensorInfos={real:i,imag:p},s}var nz={kernelName:Fi,backendName:\"webgpu\",kernelFunc:yo};var Jr=class{constructor(t,e,o=\"\"){this.variableNames=[\"A\"],this.size=!0;let n=128;this.workgroupSize=[n,1,1],this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.op=e,o!==\"\"&&(this.uniforms=o),this.shaderKey=`unary_${e}`}getUserCode(){return`\n fn unaryOperation(a : f32) -> f32 {\n ${vi(this.op,!1)}\n }\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let a = getAByOutputIndex(index);\n setOutputAtIndex(index, unaryOperation(a));\n }\n }\n `}};function ye({opType:r,cpuKernelImpl:t,dtype:e}){return({inputs:o,backend:n})=>{let{x:s}=o,a=n,i=e||s.dtype;if(a.shouldExecuteOnCPU([s])&&t!=null){let u=a.tensorMap.get(s.dataId),c=t(u.values,i);return a.makeTensorInfo(s.shape,i,c)}let p=new Jr(s.shape,r);return a.runWebGPUProgram(p,[s],i)}}function et({opType:r,cpuKernelImpl:t,supportsComplex:e=!1,dtype:o}){return({inputs:n,backend:s})=>{let{a,b:i}=n,p=s;if(e&&a.dtype===\"complex64\"){let l=p.tensorMap.get(a.dataId),m=p.tensorMap.get(i.dataId),d,f;if(r!==fe.MUL)[d,f]=[[l.complexTensorInfos.real,m.complexTensorInfos.real],[l.complexTensorInfos.imag,m.complexTensorInfos.imag]].map(g=>{let[x,b]=g,C={dataId:x.dataId,dtype:x.dtype,shape:a.shape},S={dataId:b.dataId,dtype:b.dtype,shape:i.shape},k=new ki(r,a.shape,i.shape);return p.runWebGPUProgram(k,[C,S],dt(x.dtype,b.dtype))});else{let g=new gm(fe.COMPLEX_MULTIPLY_REAL,a.shape,i.shape),x=new gm(fe.COMPLEX_MULTIPLY_IMAG,a.shape,i.shape),b=[{dataId:l.complexTensorInfos.real.dataId,dtype:l.complexTensorInfos.real.dtype,shape:a.shape},{dataId:l.complexTensorInfos.imag.dataId,dtype:l.complexTensorInfos.imag.dtype,shape:a.shape},{dataId:m.complexTensorInfos.real.dataId,dtype:m.complexTensorInfos.real.dtype,shape:i.shape},{dataId:m.complexTensorInfos.imag.dataId,dtype:m.complexTensorInfos.imag.dtype,shape:i.shape}];d=p.runWebGPUProgram(g,b,\"float32\"),f=p.runWebGPUProgram(x,b,\"float32\")}let h=yo({inputs:{real:d,imag:f},backend:p});return p.disposeData(d.dataId),p.disposeData(f.dataId),h}let u=o||dt(a.dtype,i.dtype);if((a.dtype===\"string\"||i.dtype===\"string\"||p.shouldExecuteOnCPU([a,i]))&&t!=null){let l=p.tensorMap.get(a.dataId).values,m=p.tensorMap.get(i.dataId).values,d=a.dtype===\"string\"?w.fromUint8ToStringArray(l):l,f=a.dtype===\"string\"?w.fromUint8ToStringArray(m):m,[h,g]=t(a.shape,i.shape,d,f,u);return p.makeTensorInfo(g,u,h)}let c=new ki(r,a.shape,i.shape);return p.runWebGPUProgram(c,[a,i],u)}}var{addImpl:sz,castImpl:az,ceilImpl:iz,concatImpl:uz,equalImpl:pz,expImpl:cz,expm1Impl:lz,floorImpl:mz,floorDivImpl:dz,gatherNdImpl:fz,gatherV2Impl:hz,greaterEqualImpl:gz,greaterImpl:xz,lessEqualImpl:yz,lessImpl:bz,logImpl:Cz,maxImpl:wz,maximumImpl:Sz,minimumImpl:Iz,multiplyImpl:vz,negImpl:kz,notEqualImpl:Nz,prodImpl:Tz,rangeImpl:_z,rsqrtImpl:$z,scatterImpl:Ez,simpleAbsImpl:Rz,sliceImpl:Dz,stridedSliceImpl:Az,stringNGramsImpl:Fz,subImpl:Pz,tileImpl:Oz,topKImpl:Mz,transposeImpl:Lz,uniqueImpl:HPt}=Tc;var Uie=ye({opType:Z.ABS,cpuKernelImpl:Rz}),Bz={kernelName:Xs,backendName:\"webgpu\",kernelFunc:Uie};var Gie=ye({opType:Z.ACOS}),zz={kernelName:Wo,backendName:\"webgpu\",kernelFunc:Gie};var Hie=ye({opType:Z.ACOSH}),Vz={kernelName:Uo,backendName:\"webgpu\",kernelFunc:Hie};var Kie=et({opType:fe.ADD,cpuKernelImpl:sz,supportsComplex:!0}),Wz={kernelName:uo,backendName:\"webgpu\",kernelFunc:Kie};var tx=class{constructor(t){this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t[0],this.variableNames=t.map((e,o)=>`T${o}`),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.shaderKey=\"addN\"}getUserCode(){let t=[];this.variableNames.forEach(n=>{t.push(`let v${n} = get${n}ByOutputCoords(coords);`)});let e=this.variableNames.map(n=>`v${n}`).join(\" + \");return`\n ${G(\"index\")} {\n for (var i = 0; i < ${this.workPerThread}; i = i + 1) {\n let flatIndex = index * ${this.workPerThread} + i;\n if (flatIndex < uniforms.size) {\n let coords = getCoordsFromIndex(flatIndex);\n ${t.join(`\n `)}\n setOutputAtIndex(flatIndex, ${e});\n }\n }\n }\n `}};function qie(r){let{inputs:t,backend:e}=r,o=t;if(o.length===1)return Ft({inputs:{x:o[0]},backend:e});let n=o.map(i=>i.dtype).reduce((i,p)=>dt(i,p)),s=o.map(i=>i.shape),a=new tx(s);return e.runWebGPUProgram(a,o,n)}var Uz={kernelName:Go,backendName:\"webgpu\",kernelFunc:qie};var rx=class{constructor(t,e){this.variableNames=[\"A\"],this.workgroupSize=[16,16,1];let o=new Array(t.length);for(let n=0;n`Must be a square tile, current tile shape is ${this.workgroupSize[0]} x ${this.workgroupSize[1]}`);let t=this.workgroupSize[0];return`\n var tile : array, ${this.workgroupSize[0]}>;\n ${G()} {\n var x = i32(workgroupId.x) * ${t} + i32(localId.x);\n var y = i32(workgroupId.y) * ${t} + i32(localId.y);\n let width = uniforms.outShape[0];\n let height = uniforms.outShape[1];\n if (x < width && y < height) {\n tile[localId.y][localId.x] = f32(A[y * width + x]);\n }\n workgroupBarrier();\n\n x = i32(workgroupId.y) * ${t} + i32(localId.x);\n y = i32(workgroupId.x) * ${t} + i32(localId.y);\n if (x < height && y < width) {\n setOutputAtIndex((y * height + x), tile[localId.x]\n [localId.y]);\n }\n }\n `}};var ox=class{constructor(t,e){this.variableNames=[\"A\"],this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0;let o=new Array(t.length);for(let n=0;n6)throw Error(`Transpose for rank ${t} is not yet supported`);let e=new Array(t);for(let o=0;o=32768&&o>=512?this.workgroupSize=[512,1,1]:t.inSize>=4096?this.workgroupSize=[256,1,1]:this.workgroupSize=[64,1,1],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,[1,1,1]),this.reduceType=e,this.shaderKey=`reduce_${e}`}getUserCode(){let t=\"\",e=\"0.0\",o=this.workgroupSize[0];this.reduceType===\"min\"||this.reduceType===\"max\"?(t=`\n if (isnan(candidate)) {\n bestValue = uniforms.NAN;\n } else if (!isnan(bestValue) && candidate ${this.reduceType===\"min\"?\"<\":\">\"} bestValue)\n { bestValue = candidate; }`,e=\"f32(x[offset])\"):this.reduceType===\"sum\"||this.reduceType===\"mean\"?t=\" bestValue = bestValue + candidate; \":this.reduceType===\"prod\"?(t=\" bestValue = bestValue * candidate; \",e=\"1.0\"):this.reduceType===\"all\"?(t=\" bestValue = f32(bestValue >= 1.0 && candidate >= 1.0); \",e=\"1.0\"):this.reduceType===\"any\"&&(t=\" bestValue = f32(bestValue >= 1.0 || candidate >= 1.0); \",e=\"0.0\");let n=this.reduceType===\"mean\"?\"setOutputAtIndex(outputIndex, bestValue / f32(uniforms.reduceSize));\":\"setOutputAtIndex(outputIndex, bestValue);\";return`\n fn DIV_CEIL(a : u32, b : u32) -> u32 {\n return ((a - 1u) / b + 1u);\n }\n\n ${`\n var xBestValues : array;\n `}\n fn getOffset(outputIndex : i32) -> i32 {\n let outputCoords = getCoordsFromIndex(outputIndex);\n let offset = ${this.outputShape.length===1?\"outputCoords\":\"outputCoords[0]\"} * uniforms.reduceSize;\n return offset;\n }\n ${G(\"index\")} {\n let outputIndex = index / ${o};\n let offset = getOffset(outputIndex);\n var bestValue = ${e};\n let Length = uniforms.reduceSize;\n let WorkPerThread = DIV_CEIL(u32(Length), ${o}u);\n for (var k = i32(localId.x); k < Length && outputIndex < uniforms.size;\n k = k + ${o}) {\n let candidate = f32(x[offset + k]);\n ${t}\n }\n xBestValues[localId.x] = bestValue;\n workgroupBarrier();\n\n var reduceSize = min(u32(Length), ${o}u);\n for (var currentSize = reduceSize / 2u; reduceSize > 1u;\n currentSize = reduceSize / 2u) {\n let interval = DIV_CEIL(reduceSize, 2u);\n if (localId.x < currentSize) {\n let candidate = xBestValues[localId.x + interval];\n ${t}\n xBestValues[localId.x] = bestValue;\n }\n reduceSize = interval;\n workgroupBarrier();\n }\n\n if (localId.x == 0u && outputIndex < uniforms.size) {\n ${n}\n }\n }\n `}};var jie={mean:\"float32\",all:\"bool\",any:\"bool\"};function eo(r,t,e,o,n){let s=r.shape.length,a=[],i=y.parseAxisParam(t,r.shape),p=i,u=w.getAxesPermutation(p,s),c=r;u!=null&&(c=yr({inputs:{x:r},attrs:{perm:u},backend:n}),p=w.getInnerMostAxes(p.length,s),a.push(c)),w.assertAxesAreInnerMostDims(o,p,s);let[l,m]=w.computeOutAndReduceShapes(c.shape,p),d=l;e&&(d=w.expandShapeToKeepDim(l,i));let f;if((o===\"max\"||o===\"prod\")&&n.shouldExecuteOnCPU([c])){let h=n.tensorMap.get(c.dataId).values;switch(o){case\"max\":let g=wz(h,y.sizeFromShape(m),d,r.dtype);f=n.makeTensorInfo(d,r.dtype,g);break;case\"prod\":let{outVals:x,outShape:b,outDtype:C}=Tz(c.shape,c.dtype,h,p);f=n.makeTensorInfo(b,C,x);break;default:throw new Error(`${o} CPU implementation is not yet supported.`)}}else{let h=y.sizeFromShape(m),x=y.sizeFromShape(c.shape)/h,b={windowSize:h,inSize:h,batchSize:x,outSize:1},C=jie[o]||ni(r.dtype),S=[{type:\"int32\",data:[h]}],k=new nx(b,o,n.device.limits.maxComputeWorkgroupSizeX),_=n.runWebGPUProgram(k,[c],C,S);a.push(_),f=pe({inputs:{x:_},attrs:{shape:d},backend:n})}return a.forEach(h=>n.disposeData(h.dataId)),f}function Xie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{keepDims:s,axis:a}=o;return eo(n,a,s,\"all\",e)}var Hz={kernelName:Ho,backendName:\"webgpu\",kernelFunc:Xie};function Yie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{keepDims:s,axis:a}=o;return eo(n,a,s,\"any\",e)}var Kz={kernelName:Ko,backendName:\"webgpu\",kernelFunc:Yie};var Zc=class{constructor(t,e,o){this.workgroupSize=[64,1,1],this.variableNames=[\"x\"],this.uniforms=\"infinityValue : f32,\",this.size=!0;let n=[e];this.op=o===\"min\"?\"<\":\">\";let[s,a]=w.computeOutAndReduceShapes(t,n);this.outputShape=s.length===0?[1]:s,this.dispatchLayout=X(this.outputShape),y.sizeFromShape(a)<32?(this.type=\"plain\",this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize)):(this.type=\"shared\",this.dispatch=H(this.dispatchLayout,this.outputShape,[1,1,1])),this.inputShape=t,this.shaderKey=`argMinMax_${this.op}_${this.type}`}getUserCode(){let t=this.workgroupSize[0],e=()=>this.inputShape.length===1?\"uniforms.xShape\":`uniforms.xShape.${Mo(this.inputShape.length-1)}`,o=()=>{let n=\"\";if(this.outputShape.length===1)this.inputShape.length!==1&&(n+=\"outputCoords,\");else for(let s=0;s u32 {\n return ((a - 1u) / b + 1u);\n }\n\n ${`\n var xBestIndices : array;\n var xBestValues : array;\n `}\n\n ${G(\"index\")} {\n let outputIndex = index / ${t};\n let reduceLength = ${e()};\n\n var bestIndex = i32(localId.x);\n var bestValue = uniforms.infinityValue;\n let outputCoords = getCoordsFromIndex(outputIndex);\n for (var k = i32(localId.x); k < reduceLength && outputIndex < uniforms.size;\n k = k + ${t}) {\n let candidate = getX(${o()} k);\n if (!isnan(candidate) && candidate ${this.op} bestValue) {\n bestValue = candidate;\n bestIndex = k;\n }\n }\n xBestValues[localId.x] = bestValue;\n xBestIndices[localId.x] = bestIndex;\n workgroupBarrier();\n\n var reduceSize = min(u32(reduceLength), ${t}u);\n for (var currentSize = reduceSize / 2u; reduceSize > 1u;\n currentSize = reduceSize / 2u) {\n let interval = DIV_CEIL(reduceSize, 2u);\n if (localId.x < currentSize) {\n let candidate = xBestValues[localId.x + interval];\n if (candidate ${this.op} bestValue) {\n bestValue = candidate;\n xBestValues[localId.x] = bestValue;\n xBestIndices[localId.x] = xBestIndices[localId.x + interval];\n }\n }\n reduceSize = interval;\n workgroupBarrier();\n }\n\n if (localId.x == 0u && outputIndex < uniforms.size) {\n setOutputAtIndexI32(outputIndex, xBestIndices[localId.x]);\n }\n }\n `:`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let outputCoords = getCoordsFromIndex(index);\n var bestIndex = 0;\n var bestValue = getX(${o()} 0);\n let reduceLength = ${e()};\n for (var i = 1; i < reduceLength; i++) {\n let candidate = getX(${o()} i);\n if (candidate ${this.op} bestValue) {\n bestValue = candidate;\n bestIndex = i;\n }\n }\n setOutputAtIndexI32(index, bestIndex);\n }\n }\n `}};function Qie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=yr({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMax\",[a[0]],p.shape.length);let c=new Zc(p.shape,a[0],\"max\"),l=[{type:\"float32\",data:[Number.NEGATIVE_INFINITY]}],m=e.runWebGPUProgram(c,[p],\"int32\",l);return u.forEach(d=>e.disposeData(d.dataId)),m}var qz={kernelName:Ys,backendName:\"webgpu\",kernelFunc:Qie};function Zie(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s}=o,a=y.parseAxisParam(s,n.shape),i=w.getAxesPermutation(a,n.shape.length),p=n,u=[];i!=null&&(p=yr({inputs:{x:n},backend:e,attrs:{perm:i}}),u.push(p),a=w.getInnerMostAxes(a.length,p.shape.length)),w.assertAxesAreInnerMostDims(\"argMin\",[a[0]],p.shape.length);let c=new Zc(p.shape,a[0],\"min\"),l=[{type:\"float32\",data:[Number.POSITIVE_INFINITY]}],m=e.runWebGPUProgram(c,[p],\"int32\",l);return u.forEach(d=>e.disposeData(d.dataId)),m}var jz={kernelName:Qs,backendName:\"webgpu\",kernelFunc:Zie};var Jie=ye({opType:Z.ASIN}),Xz={kernelName:qo,backendName:\"webgpu\",kernelFunc:Jie};var eue=ye({opType:Z.ASINH}),Yz={kernelName:jo,backendName:\"webgpu\",kernelFunc:eue};var tue=ye({opType:Z.ATAN}),Qz={kernelName:Xo,backendName:\"webgpu\",kernelFunc:tue};var rue=et({opType:fe.ATAN2}),Zz={kernelName:Qo,backendName:\"webgpu\",kernelFunc:rue};var oue=ye({opType:Z.ATANH}),Jz={kernelName:Yo,backendName:\"webgpu\",kernelFunc:oue};var sx=class{constructor(t){this.variableNames=[\"x\"],this.uniforms=\"strides : vec2,\",this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"poolWithFilterSizeEqualsOne\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n\n let xRCCorner = coords.yz * uniforms.strides;\n let xRCorner = xRCCorner.x;\n let xCCorner = xRCCorner.y;\n\n let value = getX(batch, xRCorner, xCCorner, d);\n setOutputAtIndex(index, value);\n }\n }\n `}};var za=class{constructor(t,e,o=!1,n=!1,s=!1){if(this.variableNames=[\"x\"],this.uniforms=\"strides : vec2, pads : vec2, dilations : vec2, convDims : vec2, filterDims : vec2,\",this.workgroupSize=[128,1,1],this.size=!0,e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.poolType=e,this.computePositions=o,this.flattenPositions=n,this.includeBatchIndex=s,this.shaderKey=`pool2D_${e}_${o}_${n}_${s}`}getUserCode(){let t;this.poolType===\"avg\"?t=\"resultValue = resultValue + value; count = count + 1.0;\":this.computePositions?t=`let currMaxValue = mix(value, maxValue, maxValueFound);\n if (value >= currMaxValue) {\n maxValue = value;\n maxValueFound = 1.0;\n maxPosition = ${this.flattenPositions?this.includeBatchIndex?\"((batch * uniforms.xShape[1] + xR) * uniforms.xShape[2] + xC) * uniforms.xShape[3] + d\":\"(xR * uniforms.xShape[2] + xC) * uniforms.xShape[3] + d\":\"wR * uniforms.filterDims.y + wC\"};\n }`:t=\"resultValue = max(value, resultValue);\";let e=\"resultValue\";return this.poolType===\"avg\"&&(e=\"resultValue / max(count, 1.0)\"),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n let xRCCorner = vec2(coords.yz) * uniforms.strides - uniforms.pads;\n let xRCorner = xRCCorner.x;\n let xCCorner = xRCCorner.y;\n\n ${this.computePositions?`var maxValue = 0.0;\n var maxValueFound = 0.0;\n var maxPosition = 0;`:`var resultValue = ${this.poolType===\"avg\"?\"0.0\":\"-1.0 / pow(10.0, -20.0)\"};`}\n\n var count = 0.0;\n for (var wR = 0; wR < uniforms.filterDims.x; wR = wR + uniforms.dilations.x) {\n let xR = xRCorner + wR;\n\n if (xR < 0 || xR >= uniforms.convDims.x) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterDims.y; wC = wC + uniforms.dilations.y) {\n let xC = xCCorner + wC;\n if (xC < 0 || xC >= uniforms.convDims.y) {\n continue;\n }\n\n let value = getX(batch, xR, xC, d);\n ${t}\n }\n }\n\n ${this.computePositions?\"setOutputAtIndexI32(index, maxPosition);\":`setOutputAtIndex(index, ${e});`}\n }\n }\n `}},_u=class{constructor(t,e,o=!1,n=!1,s=!1){if(this.variableNames=[\"x\"],this.uniforms=\"strides : vec3, pads : vec3, convDims : vec3, filterDims : vec3,\",this.workgroupSize=[128,1,1],this.size=!0,e===\"avg\"&&o)throw new Error(\"Cannot compute positions for average pool.\");this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.poolType=e,this.computePositions=o,this.flattenPositions=n,this.includeBatchIndex=s,this.shaderKey=`pool3D_${e}_${o}_${n}_${s}`}getUserCode(){let t;this.poolType===\"avg\"?t=\"resultValue += value; count += 1.0;\":this.computePositions?t=`let currMaxValue = mix(value, maxValue, maxValueFound);\n if (value >= currMaxValue) {\n maxValue = value;\n maxValueFound = 1.0;\n maxPosition = ${this.flattenPositions?this.includeBatchIndex?\"(((batch * uniforms.xShape.y + xD) * uniforms.xShape.z + xR) * uniforms.xShape.w + xC) * uniforms.xShape.u + ch\":\"((xD * uniforms.xShape.z + xR) * uniforms.xShape.w + xC) * uniforms.xShape.u + ch\":\"wD * uniforms.filterDims.y * uniforms.filterDims.y + wR * uniforms.filterDims.z + wC\"};\n }`:t=\"resultValue = max(value, resultValue);\";let e=\"resultValue\";return this.poolType===\"avg\"&&(e=\"resultValue / max(count, 1.0)\"),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let ch = coords.u;\n\n let xCorner = vec3(coords.y, coords.z, coords.w) * uniforms.strides - uniforms.pads;\n let xDCorner = xCorner.x;\n let xRCorner = xCorner.y;\n let xCCorner = xCorner.z;\n\n ${this.computePositions?`var maxValue = 0.0;\n var maxValueFound = 0.0;\n var maxPosition = 0;`:`var resultValue = ${this.poolType===\"avg\"?\"0.0\":\"-1.0 / pow(10.0, -20.0)\"};`}\n\n var count = 0.0;\n for (var wD = 0; wD < uniforms.filterDims.x; wD++) {\n let xD = xDCorner + wD;\n if (xD < 0 || xD >= uniforms.convDims.x) {\n continue;\n }\n\n for (var wR = 0; wR < uniforms.filterDims.y; wR++) {\n let xR = xRCorner + wR;\n if (xR < 0 || xR >= uniforms.convDims.y) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterDims.z; wC++) {\n let xC = xCCorner + wC;\n if (xC < 0 || xC >= uniforms.convDims.z) {\n continue;\n }\n\n let value = getX(batch, xD, xR, xC, ch);\n ${t}\n }\n }\n }\n\n ${this.computePositions?\"setOutputAtIndexI32(index, maxPosition);\":`setOutputAtIndex(index, ${e});`}\n }\n }\n `}};function Jv(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{reductionIndices:s,keepDims:a}=o;return eo(n,s,a,\"max\",e)}var eV={kernelName:Vn,backendName:\"webgpu\",kernelFunc:Jv};function e0(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{keepDims:s,axis:a}=o;return eo(n,a,s,\"mean\",e)}var tV={kernelName:Gn,backendName:\"webgpu\",kernelFunc:e0};function ax(r,t,e,o){if(t.filterWidth===1&&t.filterHeight===1&&y.arraysEqual(t.inShape,t.outShape))return Ft({inputs:{x:r},backend:o});if(t.filterWidth===t.inWidth&&t.filterHeight===t.inHeight&&t.batchSize===1&&t.padInfo.type===\"VALID\"){let a=r.shape.length,i=pe({inputs:{x:r},backend:o,attrs:{shape:[r.shape[a-3]*r.shape[a-2],r.shape[a-1]]}}),p;e===\"avg\"?p=e0({inputs:{x:i},backend:o,attrs:{axis:0,keepDims:!1}}):(y.assert(e===\"max\",()=>`Invalid pool type ${e}`),p=Jv({inputs:{x:i},backend:o,attrs:{reductionIndices:0,keepDims:!1}}));let u=pe({inputs:{x:p},backend:o,attrs:{shape:t.outShape}});return o.disposeData(i.dataId),o.disposeData(p.dataId),u}let n,s=[{type:\"int32\",data:[t.strideHeight,t.strideWidth]}];return t.filterHeight===1&&t.filterWidth===1?n=new sx(t):(e===\"avg\"?n=new za(t,\"avg\"):(y.assert(e===\"max\",()=>`Invalid pool type ${e}`),n=new za(t,\"max\")),s.push({type:\"int32\",data:[t.padInfo.top,t.padInfo.left]},{type:\"int32\",data:[t.dilationHeight,t.dilationWidth]},{type:\"int32\",data:[t.inHeight,t.inWidth]},{type:\"int32\",data:[t.effectiveFilterHeight,t.effectiveFilterWidth]})),o.runWebGPUProgram(n,[r],r.dtype,s)}function nue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1,c=w.computePool2DInfo(n.shape,s,a,u,i,p);return ax(n,c,\"avg\",e)}var rV={kernelName:Zo,backendName:\"webgpu\",kernelFunc:nue};function sue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dataFormat:p,dimRoundingMode:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,u,p),m=new _u(l,\"avg\"),d=[{type:\"int32\",data:[l.strideDepth,l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.padInfo.front,l.padInfo.top,l.padInfo.left]},{type:\"int32\",data:[l.inDepth,l.inHeight,l.inWidth]},{type:\"int32\",data:[l.effectiveFilterDepth,l.effectiveFilterHeight,l.effectiveFilterWidth]}];return e.runWebGPUProgram(m,[n],n.dtype,d)}var oV={kernelName:Zs,backendName:\"webgpu\",kernelFunc:sue};var ix=class{constructor(t){this.variableNames=[\"dy\"],this.uniforms=`strides : vec2, pads : vec2, dilations : vec2, filterDims : vec2,\n outHeight : i32, outWidth : i32, avgMultiplier : f32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"avgPool2DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n\n let dyRCCorner = vec2(coords.yz) - uniforms.pads;\n let dyRCorner = dyRCCorner.x;\n let dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var wR = 0; wR < uniforms.filterDims[0]; wR = wR + uniforms.dilations[0]) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[0]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[1]; wC = wC + uniforms.dilations[1]) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[1]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyR, idyC, d);\n\n dotProd = dotProd + dyValue * uniforms.avgMultiplier;\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},ux=class{constructor(t){this.variableNames=[\"dy\"],this.uniforms=`strides : vec3, pads : vec3, filterDims : vec3,\n outDepth : i32, outHeight : i32, outWidth : i32, avgMultiplier : f32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"avgPool3DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let ch = coords.u;\n\n let dyCorner = vec3(coords.y, coords.z, coords.w) - uniforms.pads;\n let dyDCorner = dyCorner.x;\n let dyRCorner = dyCorner.y;\n let dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, d) with pos mask(:, :, :, ch) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var wD = 0; wD < uniforms.filterDims[0]; wD++) {\n let dyD = f32(dyDCorner + wD) / f32(uniforms.strides[0]);\n\n if (dyD < 0.0 || dyD >= f32(uniforms.outDepth) || fract(dyD) > 0.0) {\n continue;\n }\n let idyD = i32(dyD);\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[1]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[2]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyD, idyR, idyC, ch);\n dotProd += dyValue * uniforms.avgMultiplier;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function aue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=w.computePool3DInfo(a.shape,i,p,1,u,c),m=new ux(l),d=1/(l.filterDepth*l.filterHeight*l.filterWidth),f=[{type:\"int32\",data:[l.strideDepth,l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.effectiveFilterDepth-1-l.padInfo.front,l.effectiveFilterHeight-1-l.padInfo.top,l.effectiveFilterWidth-1-l.padInfo.left]},{type:\"int32\",data:[l.effectiveFilterDepth,l.effectiveFilterHeight,l.effectiveFilterWidth]},{type:\"int32\",data:[l.outDepth]},{type:\"int32\",data:[l.outHeight]},{type:\"int32\",data:[l.outWidth]},{type:\"float32\",data:[d]}];return e.runWebGPUProgram(m,[n],a.dtype,f)}var nV={kernelName:Ai,backendName:\"webgpu\",kernelFunc:aue};function iue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s;fm([n,s],\"avgPoolGrad\");let{filterSize:i,strides:p,pad:u}=o,c=w.computePool2DInfo(a.shape,i,p,1,u),l=new ix(c),m=1/(c.filterHeight*c.filterWidth),d=[{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.effectiveFilterHeight-1-c.padInfo.top,c.effectiveFilterWidth-1-c.padInfo.left]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[c.effectiveFilterHeight,c.effectiveFilterWidth]},{type:\"int32\",data:[c.outHeight]},{type:\"int32\",data:[c.outWidth]},{type:\"float32\",data:[m]}];return e.runWebGPUProgram(l,[n],a.dtype,d)}var sV={kernelName:Di,backendName:\"webgpu\",kernelFunc:iue};function uue(r){let{inputs:t,backend:e,attrs:o}=r,{a:n,b:s}=t,{transposeA:a,transposeB:i}=o;return Op({a:n,b:s,transposeA:a,transposeB:i,backend:e})}var aV={kernelName:Jo,backendName:\"webgpu\",kernelFunc:uue};var px=class{constructor(t,e){this.variableNames=[\"source\"],this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.rank=e.length,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.start=t,this.uniforms=`start : ${ht(t.length)}, `,this.shaderKey=\"slice\"}getUserCode(){let t=ht(this.rank),e=pue(this.rank),o;return this.start.length===1?o=this.outputShape.map((s,a)=>\"sourceLoc = uniforms.start + coords;\"):o=this.outputShape.map((s,a)=>`sourceLoc.${t0[a]} = uniforms.start.${Mo(a)} + coords.${t0[a]};`),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var sourceLoc : ${t};\n let coords = getCoordsFromIndex(index);\n ${o.join(`\n`)}\n setOutputAtIndex(index, getSource(${e}));\n }\n }\n `}},t0=[\"x\",\"y\",\"z\",\"w\",\"u\",\"v\"];function pue(r){if(r===1)return\"sourceLoc\";if(r<=6)return t0.slice(0,r).map(t=>`sourceLoc.${t}`).join(\",\");throw Error(`Slicing for rank ${r} is not yet supported`)}function Hs(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,size:a}=o,[i,p]=ct.parseSliceParams(n,s,a);if(ct.assertParamsValid(n,i,p),e.shouldExecuteOnCPU([n])||n.dtype===\"string\"){let l=e.tensorMap.get(n.dataId),m=Dz(l.values,i,p,n.shape,n.dtype);return e.makeTensorInfo(p,n.dtype,m)}if(y.sizeFromShape(p)===0)return e.makeTensorInfo(p,n.dtype,[]);let u=new px(i,p),c=[{type:\"int32\",data:i}];return e.runWebGPUProgram(u,[n],n.dtype,c)}var iV={kernelName:ha,backendName:\"webgpu\",kernelFunc:Hs};var cue=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,crops:a}=o;y.assert(n.shape.length<=4,()=>\"batchToSpaceND for rank > 4 with a WebGPU backend not implemented yet\");let i=s.reduce((b,C)=>b*C),p=w.getReshaped(n.shape,s,i),u=w.getPermuted(p.length,s.length),c=w.getReshapedPermuted(n.shape,s,i),l=w.getSliceBeginCoords(a,s.length),m=w.getSliceSize(c,a,s.length),d=[],f=pe({inputs:{x:n},backend:e,attrs:{shape:p}}),h=yr({inputs:{x:f},backend:e,attrs:{perm:u}}),g=pe({inputs:{x:h},backend:e,attrs:{shape:c}}),x=Hs({inputs:{x:g},backend:e,attrs:{begin:l,size:m}});return d.push(f),d.push(h),d.push(g),d.forEach(b=>e.disposeData(b.dataId)),x},uV={kernelName:Js,backendName:\"webgpu\",kernelFunc:cue};var lue=`\n fn bincount_write(index: i32, value: f32) {\n ${Qr(\"&result[index]\",\"value\",\"float32\")}\n }\n`,mue=`\n fn bincount_write(index: i32, value: f32) {\n atomicStore(&result[index], bitcast(value));\n }\n`,Jc=class{constructor(t,e,o=!1){this.outputShape=[],this.variableNames=[\"x\"],this.uniforms=\"binCountSize : i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.hasWeights=!0,this.binaryOutput=!1,this.outputShape=t,this.rank=t.length,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.binaryOutput=o,o&&(this.atomic=!1),this.hasWeights=e,this.hasWeights&&this.variableNames.push(\"w\"),this.shaderKey=`bincount_${this.hasWeights}_${this.binaryOutput}_${this.rank}`}getUserCode(){return`\n ${this.binaryOutput?mue:lue}\n ${G(\"index\")} {\n ${this.rank===1?`if (index < uniforms.xShape) {\n let indexVal = i32(getX(index));\n if (indexVal < uniforms.binCountSize) {\n let value = ${this.binaryOutput?1:this.hasWeights?\"getW(index)\":\"1.\"};\n bincount_write(indexVal, value);\n }\n }`:`let coord = getCoordsFromIndex(index);\n if (coordsInBounds2D(coord, uniforms.xShape)) {\n let indexVal = i32(getX(coord[0], coord[1]));\n if (indexVal < uniforms.binCountSize) {\n let value = ${this.binaryOutput?1:this.hasWeights?\"getW(coord[0], coord[1])\":\"1.\"};\n bincount_write(coord.x * uniforms.binCountSize + indexVal, value);\n }\n }`}\n }\n `}};function due(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a}=o,i=y.sizeFromShape(n.shape),u=y.sizeFromShape(s.shape)>0,c=[a],l=s.dtype,m=kt({backend:e,attrs:{shape:c,value:0,dtype:l}}),d=new Jc([i],u),f=[{type:\"int32\",data:[a]}],h=u?[n,s]:[n];return e.runWebGPUProgram(d,h,l,f,m)}var pV={kernelName:en,backendName:\"webgpu\",kernelFunc:due};var cx=class{constructor(t){this.outputShape=[],this.variableNames=[\"s0\",\"s1\"],this.uniforms=\"s0Size : i32, s1Size : i32, \",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"broadcastArgs\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var s0 = 1.0;\n var s1 = 1.0;\n let indexS0 = index - uniforms.size + uniforms.s0Size;\n let indexS1 = index - uniforms.size + uniforms.s1Size;\n if (indexS0 >= 0) {\n s0 = getS0(indexS0);\n }\n if (indexS1 >= 0) {\n s1 = getS1(indexS1);\n }\n\n if (s0 == 1.0) {\n setOutputAtIndex(index, s1);\n } else if (s1 == 1.0) {\n setOutputAtIndex(index, s0);\n } else if (s0 != s1) {\n setOutputAtIndex(index, uniforms.NAN);\n } else {\n setOutputAtIndex(index, s0);\n }\n }\n }\n `}};function fue(r){let{inputs:t,backend:e}=r,{s0:o,s1:n}=t;if(e.shouldExecuteOnCPU([o,n])){let c=e.tensorMap.get(o.dataId),l=e.tensorMap.get(n.dataId),m=c.values,d=l.values,f=w.assertAndGetBroadcastShape(Array.from(m),Array.from(d));return e.makeTensorInfo([f.length],\"int32\",Int32Array.from(f))}let s=y.sizeFromShape(o.shape),a=y.sizeFromShape(n.shape),i=Math.max(s,a),p=new cx(i),u=[{type:\"int32\",data:[s]},{type:\"int32\",data:[a]}];return e.runWebGPUProgram(p,[o,n],\"int32\",u)}var cV={kernelName:ea,backendName:\"webgpu\",kernelFunc:fue};var r0=et({opType:fe.NOT_EQUAL,dtype:\"bool\",cpuKernelImpl:Nz}),lV={kernelName:Qn,backendName:\"webgpu\",kernelFunc:r0};function Ni(r){let{inputs:t,backend:e}=r,{input:o}=t,n=e.tensorMap.get(o.dataId);return Ft({inputs:{x:n.complexTensorInfos.real},backend:e})}var mV={kernelName:qi,backendName:\"webgpu\",kernelFunc:Ni};function dV(r,t){let e=new Jr(r.shape,Z.TO_INT),o=t.runWebGPUProgram(e,[r],\"int32\");return{dataId:o.dataId,shape:o.shape,dtype:o.dtype}}function o0(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dtype:s}=o;if(s===\"complex64\"){if(n.dtype===\"complex64\")return Ft({inputs:{x:n},backend:e});let a=Gr(n.shape),i=o0({inputs:{x:n},backend:e,attrs:{dtype:\"float32\"}}),p=yo({inputs:{real:i,imag:a},backend:e});return a.dispose(),e.disposeData(i.dataId),p}if(n.dtype===\"complex64\"){let a=Ni({inputs:{input:n},backend:e}),i=o0({inputs:{x:a},backend:e,attrs:{dtype:s}});return e.disposeData(a.dataId),i}if(!y.hasEncodingLoss(n.dtype,s)){let a=Ft({inputs:{x:n},backend:e});return{dataId:a.dataId,shape:a.shape,dtype:s}}if(e.shouldExecuteOnCPU([n])){let a=e.tensorMap.get(n.dataId).values,[i,p,u]=az(a,n.shape,n.dtype,s);return e.makeTensorInfo(i,p,u)}if(s===\"int32\")return dV(n,e);if(s===\"bool\"){let a=e.makeTensorInfo([],\"bool\",y.getTypedArrayFromDType(\"bool\",1)),p=r0({inputs:{a:n,b:a},backend:e});return e.disposeData(a.dataId),p}throw new Error(`Error in Cast: failed to cast ${n.dtype} to ${s}`)}var fV={kernelName:bo,backendName:\"webgpu\",kernelFunc:o0};var hue=ye({opType:Z.CEIL,cpuKernelImpl:iz}),hV={kernelName:tn,backendName:\"webgpu\",kernelFunc:hue};var lx=class{constructor(t){this.variableNames=[\"A\"],this.uniforms=\"minVal : f32, maxVal : f32,\",this.workPerThread=4,this.workgroupSize=[64,1,1],this.outputComponent=4,this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.shaderKey=\"clipVec4\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let value = getAByOutputIndex(index);\n var clampedValue = clamp(\n value, vec4(uniforms.minVal), vec4(uniforms.maxVal));\n clampedValue = select(clampedValue, value, isnanVec4(value));\n setOutputAtIndex(index, clampedValue);\n }\n }\n `}};var mx=class{constructor(t){this.variableNames=[\"A\"],this.uniforms=\"minVal : f32, maxVal : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"clip\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let value = getAByOutputIndex(index);\n if (isnan(value)) {\n setOutputAtIndex(index, value);\n return;\n }\n setOutputAtIndex(index, clamp(value, uniforms.minVal, uniforms.maxVal));\n }\n }\n `}};function gue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{clipValueMin:s,clipValueMax:a}=o,i,p=[{type:\"float32\",data:[s]},{type:\"float32\",data:[a]}];return y.sizeFromShape(n.shape)%4===0?i=new lx(n.shape):i=new mx(n.shape),e.runWebGPUProgram(i,[n],n.dtype,p)}var gV={kernelName:Co,backendName:\"webgpu\",kernelFunc:gue};var dx=class{constructor(t){this.outputShape=[],this.variableNames=[\"real\",\"imag\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"complexAbs\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let re = abs(getRealByOutputIndex(index));\n let im = abs(getImagByOutputIndex(index));\n let mx = max(re, im);\n\n // The length function in wgsl may be not underflow-safe on some GPUs.\n // So the safe solution is to ensure underflow-safety in all cases.\n setOutputAtIndex(index, select(mx * length(vec2(1, min(re, im)/mx)), 0.0, mx == 0.0));\n }\n }\n `}};function xV(r,t){return{dataId:t.dataId,dtype:t.dtype,shape:r.shape}}function xue(r){let{inputs:t,backend:e}=r,{x:o}=t,n=e.tensorMap.get(o.dataId),s=new dx(o.shape),a=[xV(o,n.complexTensorInfos.real),xV(o,n.complexTensorInfos.imag)];return e.runWebGPUProgram(s,a,a[0].dtype)}var yV={kernelName:Pi,backendName:\"webgpu\",kernelFunc:xue};var fx=class{constructor(t){this.uniforms=\"\",this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=w.computeOutShape(t,1),this.variableNames=t.map((e,o)=>`T${o}`),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]),this.offsetLength=t.length-1;for(let e=0;e0){t.push(\"if (yC < uniforms.offset0){ setOutputAtCoords(coords.x, coords.y, getT0(yR, yC)); }\");for(let s=1;sNi({inputs:{input:C},backend:e})),h=r.map(C=>Mp({inputs:{input:C},backend:e})),g=el(f,t,e),x=el(h,t,e),b=yo({inputs:{real:g,imag:x},backend:e});return f.forEach(C=>e.disposeData(C.dataId)),h.forEach(C=>e.disposeData(C.dataId)),e.disposeData(g.dataId),e.disposeData(x.dataId),b}let n=e.shouldExecuteOnCPU(r);if(o===\"string\"&&(n=!0),n){let f=r.map(k=>{let E=[-1,y.sizeFromShape(k.shape.slice(t))];return pe({inputs:{x:k},backend:e,attrs:{shape:E}})}),h=f.map(k=>({vals:e.readSync(k.dataId),shape:k.shape})),g=w.computeOutShape(f.map(k=>k.shape),1),x=f[0].shape[0]===1,b=uz(h,g,o,x),C=w.computeOutShape(r.map(k=>k.shape),t),S=e.makeTensorInfo(C,o,b);return f.forEach(k=>e.disposeData(k.dataId)),S}let s=e.device.limits.maxStorageBuffersPerShaderStage-1;if(r.length>s){let f=[];for(let g=0;gf.shape),u=new fx(p),c=[],l=new Array(p.length-1);if(l.length>0){l[0]=p[0][1],c.push({type:\"int32\",data:[l[0]]});for(let f=1;fe.disposeData(f.dataId));let d=pe({inputs:{x:m},backend:e,attrs:{shape:i}});return e.disposeData(m.dataId),d}function yue(r,t,e){let o=w.computeOutShape(r.map(s=>s.shape),t);return{tensors2D:r.map(s=>pe({inputs:{x:s},backend:e,attrs:{shape:[y.sizeFromShape(s.shape.slice(0,t)),y.sizeFromShape(s.shape.slice(t))]}})),outShape:o}}function n0(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o,s=y.parseAxisParam(n,t[0].shape)[0],a=t.map(u=>u.shape);w.assertParamsConsistent(a,s);let i=w.computeOutShape(t.map(u=>u.shape),s);if(y.sizeFromShape(i)===0)return e.makeTensorInfo(i,t[0].dtype,[]);let p=t.filter(u=>y.sizeFromShape(u.shape)>0);return p.length===1?Ft({inputs:{x:p[0]},backend:e}):el(p,s,e)}var CV={kernelName:ta,backendName:\"webgpu\",kernelFunc:n0};function bue(r,t,e,o,n=!1,s=null,a=!1,i=4,p=4,u=4){let c=D=>{switch(D){case 1:return\"resData = f32(x[xIndex]);\";case 3:return\"resData = vec3(x[xIndex], x[xIndex + 1], x[xIndex + 2]);\";case 4:return\"resData = vec4(x[xIndex / 4]);\";default:throw new Error(`innerElementSize ${D} is not supported.`)}},l=D=>{switch(D){case 1:return\"return f32(W[row * uniforms.wShape[3] + col]);\";case 4:return\"return vec4(W[(row * uniforms.wShape[3] + col) / 4]);\";default:throw new Error(`innerElementSize ${D} is not supported.`)}},m=r?`\n let coord = vec4(batch, xRow, xCol, xCh);\n `:`\n let coord = vec4(batch, xCh, xRow, xCol);\n `,d=r?`\n let coords = vec4(\n batch,\n row / outWidth,\n row % outWidth,\n col);\n `:`\n let coords = vec4(\n batch,\n row,\n col / outWidth,\n col % outWidth);\n `,f=r?\"uniforms.xShape[1]\":\"uniforms.xShape[2]\",h=r?\"uniforms.xShape[2]\":\"uniforms.xShape[3]\",g=r?\"row\":\"col\",x=r?\"col\":\"row\",b=`\n let inChannels = uniforms.wShape[2];\n let outWidth = ${r?\"uniforms.outShape[2]\":\"uniforms.outShape[3]\"};\n let outRow = ${g} / outWidth;\n let outCol = ${g} % outWidth;\n\n let WRow = ${x} / (uniforms.filterDims[1] * inChannels);\n let WCol = ${x} / inChannels % uniforms.filterDims[1];\n let xRow = outRow * uniforms.strides[0] + uniforms.dilations[0] * WRow - uniforms.pads[0];\n let xCol = outCol * uniforms.strides[1] + uniforms.dilations[1] * WCol - uniforms.pads[1];\n let xCh = ${x} % inChannels;\n var resData = ${Ae(i)}(0.0);\n // The bounds checking is always needed since we use it to pad zero for\n // the 'same' padding type.\n if (xRow >= 0 && xRow < ${f} && xCol >= 0 && xCol < ${h}) {\n ${m}\n let xIndex = getIndexFromCoords4D(coord, uniforms.xShape);\n ${c(i)}\n }\n return resData;`,C=r?t&&o?`\n ${b}`:`\n if (row < uniforms.dimAOuter && col < uniforms.dimInner) {\n ${b}\n }\n return ${Ae(i)}(0.0);`:o&&e?`\n ${b}`:`\n if (row < uniforms.dimInner && col < uniforms.dimBOuter) {\n ${b}\n }\n return ${Ae(i)}(0.0);`,S=`${l(p)}`,k=Ae(u),_=r?Ae(i):Ae(p),E=r?Ae(p):Ae(i);return`\n ${fr(s,a,u===4,4)}\n fn mm_readA(batch: i32, row : i32, col : i32) -> ${_} {\n ${r?C:S}\n }\n\n fn mm_readB(batch: i32, row : i32, col : i32) -> ${E} {\n ${r?S:C}\n }\n\n fn mm_write(batch: i32, row : i32, col : i32, valueIn : ${k}) {\n if (row < uniforms.dimAOuter && col < uniforms.dimBOuter)\n {\n var value = valueIn;\n let outWidth = ${r?\"uniforms.outShape[2]\":\"uniforms.outShape[3]\"};\n ${d}\n ${Zr(n,s)}\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], value);\n }\n }`}var hx=class{constructor(t,e,o,n,s=!1,a=null,i=!1,p=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims : vec2, pads : vec2, strides : vec2, dilations : vec2, dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.outputShape=t.outShape,this.isChannelsLast=t.dataFormat===\"channelsLast\",this.isVec4=((t.inChannels%4===0||t.inChannels%3===0)&&this.isChannelsLast||t.outWidth%4===0&&!this.isChannelsLast)&&t.outChannels%4===0,this.dispatchLayout=this.isChannelsLast?{x:[3],y:[1,2],z:[0]}:{x:[2,3],y:[1],z:[0]},this.workgroupSize=lm(this.dispatchLayout,this.outputShape,this.isVec4),this.elementsPerThread=mm(this.dispatchLayout,this.outputShape,this.isVec4),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,this.elementsPerThread),this.isVec4?(this.outputComponent=4,this.isChannelsLast&&t.inChannels%4!==0?(this.innerElementSize=3,this.variableComponents=[1,4]):(this.innerElementSize=4,this.variableComponents=[4,4]),s&&(this.variableNames.push(\"bias\"),this.variableComponents.push(4)),i&&(this.variableNames.push(\"preluActivationWeights\"),this.variableComponents.push(4))):(this.innerElementSize=this.elementsPerThread[0],s&&this.variableNames.push(\"bias\"),i&&this.variableNames.push(\"preluActivationWeights\")),this.sequentialAccessByThreads=p,this.addBias=s,this.activation=a,this.hasPreluActivationWeights=i,this.tileAOuter=this.workgroupSize[1]*this.elementsPerThread[1],this.tileBOuter=this.workgroupSize[0]*this.elementsPerThread[0],this.tileInner=Math.max(this.workgroupSize[0]*this.innerElementSize,this.workgroupSize[1]),this.fitAOuter=e%this.tileAOuter===0,this.fitBOuter=o%this.tileBOuter===0,this.fitInner=n%this.tileInner===0,this.shaderKey=`conv2DMM_${this.elementsPerThread}_${this.activation}}_${this.fitAOuter}_${this.fitBOuter}_${this.fitInner}_${this.isVec4}_${this.innerElementSize}_${this.isChannelsLast}_${this.sequentialAccessByThreads}`}getUserCode(){let t=this.isVec4?Fp(this.elementsPerThread,this.workgroupSize,!this.isChannelsLast,this.tileInner):Pp(this.elementsPerThread,this.workgroupSize,!this.isChannelsLast,this.tileInner,!1,null,this.sequentialAccessByThreads),e=this.isVec4?[this.innerElementSize,4,4]:[1,1,1];return`\n ${bue(this.isChannelsLast,this.fitAOuter,this.fitBOuter,this.fitInner,this.addBias,this.activation,this.hasPreluActivationWeights,e[0],e[1],e[2])}\n ${t}\n `}};var gx=class{constructor(t,e=!1,o=null,n=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2,\",this.workgroupSize=[4,4,8],this.outputShape=t.outShape,this.isChannelsLast=t.dataFormat===\"channelsLast\",this.dispatchLayout=this.isChannelsLast?{x:[2],y:[1],z:[0,3]}:{x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.addBias=e,this.activation=o,this.hasPreluActivationWeights=n,e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),this.shaderKey=`conv2dnaive_${this.activation}_${this.isChannelsLast}`}getUserCode(){return`\n ${fr(this.activation,this.hasPreluActivationWeights,!1,4)}\n fn readInp(batch : i32, row : i32, col : i32, chan : i32) -> f32{\n let coords = vec4(batch, row, col, chan);\n if (coordsInBounds4D(coords, uniforms.xShape)) {\n return getX(batch, row, col, chan);\n } else {\n return 0.0;\n }\n }\n fn readFilt(row : i32, col : i32, xChannel : i32, outChannel : i32) -> f32{\n let coords = vec4(row, col, xChannel, outChannel);\n if(coordsInBounds4D(coords, uniforms.wShape)) {\n return getW(row, col, xChannel, outChannel);\n } else {\n return 0.0;\n }\n }\n fn writeResult(batch : i32, row : i32, col : i32, chan : i32, valueIn : f32) {\n let coords = ${this.isChannelsLast?\"vec4(batch, row, col, chan);\":\"vec4(batch, chan, row, col);\"}\n if (coordsInBounds4D(coords, uniforms.outShape)) {\n var value = valueIn;\n ${Zr(this.addBias,this.activation)}\n setOutputAtCoords(coords.x, coords.y, coords.z, coords.w, value);\n }\n }\n ${G(\"index\")} {\n let coords = getOutputCoords();\n let batch = coords[0];\n let outChannel = ${this.isChannelsLast?\"coords[3];\":\"coords[1];\"}\n let outRow = ${this.isChannelsLast?\"coords[1];\":\"coords[2];\"}\n let outCol = ${this.isChannelsLast?\"coords[2];\":\"coords[3];\"}\n var acc : f32 = 0.0;\n for (var row = 0; row < uniforms.filterDims[0]; row = row + 1) {\n for (var col = 0; col < uniforms.filterDims[1]; col = col + 1) {\n let xRow = outRow * uniforms.strides[0] + uniforms.dilations[0] * row - uniforms.pads[0];\n let xCol = outCol * uniforms.strides[1] + uniforms.dilations[1] * col - uniforms.pads[1];\n for (var xChannel = 0; xChannel < ${this.isChannelsLast?\"uniforms.xShape[3];\":\"uniforms.xShape[1];\"} xChannel = xChannel + 1) {\n ${this.isChannelsLast?\"let v = readInp(batch, xRow, xCol, xChannel);\":\"let v = readInp(batch, xChannel, xRow, xCol);\"}\n let f = readFilt(row, col, xChannel, outChannel);\n acc = acc + v * f;\n }\n }\n }\n writeResult(batch, outRow, outCol, outChannel, acc);\n }\n `}};var xx=class{constructor(t,e){this.variableNames=[\"x\"],this.uniforms=`pads : vec2, strides : vec2, dilations : vec2, outWidth : i32, itemsPerBlockRow : i32,\n inChannels : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.isChannelsLast=e,this.shaderKey=`im2col_${this.isChannelsLast}`}getUserCode(){let t=this.isChannelsLast?1:2,e=this.isChannelsLast?2:3,o=this.isChannelsLast?\"coords[1]\":\"coords[2]\",n=this.isChannelsLast?\"coords[2]\":\"coords[1]\",s=this.isChannelsLast?\"getX(batch, xRow, xCol, ch)\":\"getX(batch, ch, xRow, xCol)\";return`\n ${G(\"index\")} {\n let coords = getCoordsFromIndex(index);\n if(index < uniforms.size) {\n let batch = coords[0];\n let row = ${o};\n let col = ${n};\n let offsetY = (row / uniforms.outWidth) * uniforms.strides[0] - uniforms.pads[0];\n let xRow = offsetY + uniforms.dilations[0] * (col / uniforms.itemsPerBlockRow);\n var value = 0.0;\n if(xRow < uniforms.xShape[${t}] && xRow >= 0) {\n let offsetX = (row % uniforms.outWidth) * uniforms.strides[1] -\n uniforms.pads[1];\n let xCol = offsetX + uniforms.dilations[1] * ((col %\n uniforms.itemsPerBlockRow) / uniforms.inChannels);\n let ch = col % uniforms.inChannels;\n if(xCol < uniforms.xShape[${e}] && xCol >= 0) {\n value = ${s};\n }\n }\n setOutputAtIndex(index, value);\n }\n }\n `}};function yx(r,t){let e=r.length;return e>=3?t?[...r.slice(0,-3),r[e-3]*r[e-2],r[e-1]]:[...r.slice(0,-3),r[e-3],r[e-2]*r[e-1]]:!t&&e===1&&r[0]>1?[r[0],1]:null}function Cue({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let p=e.dataFormat===\"channelsLast\",u=!p,c=!1,l=p&&e.filterHeight===e.inHeight&&e.filterWidth===e.inWidth&&e.padInfo.type===\"VALID\",m=[],d,f;if(l){let x=e.inHeight*e.inWidth*e.inChannels;d=pe({inputs:{x:r},backend:o,attrs:{shape:[1,e.batchSize,x]}}),f=pe({inputs:{x:t},backend:o,attrs:{shape:[1,x,e.outChannels]}})}else d=pe({inputs:{x:r},backend:o,attrs:{shape:p?[e.batchSize,e.inHeight*e.inWidth,e.inChannels]:[e.batchSize,e.inChannels,e.inHeight*e.inWidth]}}),f=pe({inputs:{x:t},backend:o,attrs:{shape:[1,e.inChannels,e.outChannels]}});if(m.push(d),m.push(f),s!=null){let x=yx(s.shape,p);x!=null&&(s=pe({inputs:{x:s},backend:o,attrs:{shape:x}}),m.push(s))}if(n!=null){let x=yx(n.shape,p);x!=null&&(n=pe({inputs:{x:n},backend:o,attrs:{shape:x}}),m.push(n))}let h=Op({a:p?d:f,b:p?f:d,transposeA:u,transposeB:c,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a}),g=pe({inputs:{x:h},backend:o,attrs:{shape:e.outShape}});m.push(h);for(let x of m)o.disposeData(x.dataId);return g}function wue({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let{filterWidth:p,filterHeight:u,inChannels:c,strideWidth:l,strideHeight:m,padInfo:d,outWidth:f,outHeight:h,dilationWidth:g,dilationHeight:x,dataFormat:b}=e,C=b===\"channelsLast\",S=p*u*c,k=h*f,_=C?[e.batchSize,k,S]:[e.batchSize,S,k],E=new xx(_,C),R=[{type:\"int32\",data:[d.top,d.left]},{type:\"int32\",data:[m,l]},{type:\"int32\",data:[x,g]},{type:\"int32\",data:[f]},{type:\"int32\",data:[c*p]},{type:\"int32\",data:[c]}],D=o.runWebGPUProgram(E,[r],r.dtype,R),P=[];P.push(D);let O=pe({inputs:{x:t},backend:o,attrs:{shape:[1,S,-1]}});if(P.push(O),s!=null){let U=yx(s.shape,C);U!=null&&(s=pe({inputs:{x:s},backend:o,attrs:{shape:U}}),P.push(s))}if(n!=null){let U=yx(n.shape,C);U!=null&&(n=pe({inputs:{x:n},backend:o,attrs:{shape:U}}),P.push(n))}let B=Op({a:C?D:O,b:C?O:D,transposeA:!C,transposeB:!1,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a}),z=pe({inputs:{x:B},backend:o,attrs:{shape:e.outShape}});P.push(B);for(let U of P)o.disposeData(U.dataId);return z}function bx({x:r,filter:t,convInfo:e,backend:o,bias:n=null,preluActivationWeights:s=null,leakyreluAlpha:a=0,activation:i=null}){let p=n!=null,u=s!=null,c=e.dataFormat===\"channelsLast\",l=c&&e.filterHeight===e.inHeight&&e.filterWidth===e.inWidth&&e.padInfo.type===\"VALID\",m=A().getBool(\"WEBGPU_USE_NAIVE_CONV2D_DEBUG\");if(!m&&(l||e.filterHeight===1&&e.filterWidth===1&&e.dilationHeight===1&&e.dilationWidth===1&&e.strideHeight===1&&e.strideWidth===1&&(e.padInfo.type===\"SAME\"||e.padInfo.type===\"VALID\")))return Cue({x:r,filter:t,convInfo:e,backend:o,bias:n,activation:i,preluActivationWeights:s,leakyreluAlpha:a});let d=A().getNumber(\"WEBGPU_THRESHOLD_TO_INCREASE_WORKGROUPS_FOR_MATMUL\"),f=d>-1?d:o.thresholdToIncreaseWorkgroups,h=e.batchSize*Math.ceil(e.outHeight*e.outWidth/32)*Math.ceil(e.outChannels/32);if(A().getBool(\"WEBGPU_CONV_SEPARATE_IM2COL_SHADER\")||h<=f)return wue({x:r,filter:t,convInfo:e,backend:o,bias:n,preluActivationWeights:s,leakyreluAlpha:a,activation:i});let g,x=[e.padInfo.top,e.padInfo.left],b=[{type:\"int32\",data:[e.filterHeight,e.filterWidth]},{type:\"int32\",data:[...x]},{type:\"int32\",data:[e.strideHeight,e.strideWidth]},{type:\"int32\",data:[e.dilationHeight,e.dilationWidth]}];if(m)g=new gx(e,p,i,u);else{let _=c?e.outHeight*e.outWidth:e.outChannels,E=c?e.outChannels:e.outHeight*e.outWidth,R=e.filterHeight*e.filterWidth*e.inChannels;b.push({type:\"int32\",data:[_]},{type:\"int32\",data:[E]},{type:\"int32\",data:[R]});let D=o.adapterInfo.isIntel();g=new hx(e,_,E,R,p,i,u,D)}let C=[],S=[r,t];p&&(!c&&n.shape.length===1&&(n=pe({inputs:{x:n},backend:o,attrs:{shape:[n.shape[0],1,1]}}),C.push(n)),S.push(n)),u&&(!c&&s.shape.length===1&&(s=pe({inputs:{x:s},backend:o,attrs:{shape:[s.shape[0],1,1]}}),C.push(s)),S.push(s)),i===\"leakyrelu\"&&(b.push({type:\"float32\",data:[a]}),g.uniforms+=\" alpha : f32,\");let k=o.runWebGPUProgram(g,S,r.dtype,b);for(let _ of C)o.disposeData(_.dataId);return k}function Sue(r){let{inputs:t,attrs:e,backend:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=e,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,s.shape,a,u,i,c,!1,l);return bx({x:n,filter:s,convInfo:m,backend:o})}var wV={kernelName:rn,backendName:\"webgpu\",kernelFunc:Sue};var Cx=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.uniforms=\"filterDims : vec2, pads : vec2, strides : vec2, outBackprop : vec4,\",this.workgroupSize=[64,1,1],this.size=!1,this.isVec4=!1,this.workPerThread=1,this.outputShape=t.inShape,this.isChannelsLast=t.dataFormat===\"channelsLast\",this.isVec4=this.isChannelsLast&&t.outChannels%4===0&&t.inChannels%4===0,this.isVec4?(this.workPerThread=2,this.outputComponent=4,this.workgroupSize=[4,4,4],this.dispatchLayout={x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[4,this.workPerThread,1])):(this.size=!0,this.workPerThread=1,this.workgroupSize=[64,1,1],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize)),this.shaderKey=`conv2DDerInput_${this.isChannelsLast}_${this.isVec4}_${this.workPerThread}`}getUserCode(){let t=this.isChannelsLast?1:2,e=this.isChannelsLast?2:3,o=this.isChannelsLast?3:1,n=`\n ${G()} {\n let batch = i32(globalId.z) / uniforms.outShape[1];\n let r = i32(globalId.z) % uniforms.outShape[1];\n let c = i32(globalId.y) * ${this.workPerThread};\n let d1 = i32(globalId.x) * 4;\n\n let dyCorner = vec2(r, c) - uniforms.pads;\n\n // Convolve dy(?, ?, d2) with w(:, :, d1, d2) to compute dx(xR, xC, d1).\n // ? = to be determined. : = across all values in that axis.\n var dotProd: array, ${this.workPerThread}>;\n for (var i = 0; i < ${this.workPerThread}; i++) {\n dotProd[i] = vec4(0.0);\n }\n for (var wR = 0; wR < uniforms.filterDims.x; wR = wR + 1) {\n let dyR = f32(dyCorner.x + wR) / f32(uniforms.strides.x);\n let wRPerm = uniforms.filterDims.x - 1 - wR;\n if (dyR < 0.0 || dyR >= f32(uniforms.outBackprop[1]) ||\n fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims.y; wC = wC + 1) {\n let dyC = f32(dyCorner.y + wC) / f32(uniforms.strides.y);\n let dyC2 = f32(dyCorner.y + 1 + wC) / f32(uniforms.strides.y);\n let wCPerm = uniforms.filterDims.y - 1 - wC;\n var bDyCVal = true;\n var bDyCVal2 = true;\n if (dyC < 0.0 || dyC >= f32(uniforms.outBackprop[2]) ||\n fract(dyC) > 0.0) {\n bDyCVal = false;\n }\n if (dyC2 < 0.0 || dyC2 >= f32(uniforms.outBackprop[2]) ||\n fract(dyC2) > 0.0) {\n bDyCVal2 = false;\n }\n\n let idyC = i32(dyC);\n let idyC2 = i32(dyC2);\n if (bDyCVal && bDyCVal2) {\n let d2Length = uniforms.outBackprop[3];\n for (var d2 = 0; d2 < d2Length; d2 = d2 + 4) {\n let wValue0 = getW(wRPerm, wCPerm, d1, d2);\n let wValue1 = getW(wRPerm, wCPerm, d1 + 1, d2);\n let wValue2 = getW(wRPerm, wCPerm, d1 + 2, d2);\n let wValue3 = getW(wRPerm, wCPerm, d1 + 3, d2);\n var xValue = getDy(batch, idyR, idyC, d2);\n let tmpval = vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n dotProd[0] = dotProd[0] + tmpval;\n xValue = getDy(batch, idyR, idyC2, d2);\n dotProd[1] = dotProd[1] + vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n }\n } else if (bDyCVal) {\n let d2Length = uniforms.outBackprop[3];\n for (var d2 = 0; d2 < d2Length; d2 = d2 + 4) {\n let wValue0 = getW(wRPerm, wCPerm, d1, d2);\n let wValue1 = getW(wRPerm, wCPerm, d1 + 1, d2);\n let wValue2 = getW(wRPerm, wCPerm, d1 + 2, d2);\n let wValue3 = getW(wRPerm, wCPerm, d1 + 3, d2);\n var xValue = getDy(batch, idyR, idyC, d2);\n let tmpval = vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n dotProd[0] = dotProd[0] + tmpval;\n }\n } else if (bDyCVal2) {\n let d2Length = uniforms.outBackprop[3];\n for (var d2 = 0; d2 < d2Length; d2 = d2 + 4) {\n let wValue0 = getW(wRPerm, wCPerm, d1, d2);\n let wValue1 = getW(wRPerm, wCPerm, d1 + 1, d2);\n let wValue2 = getW(wRPerm, wCPerm, d1 + 2, d2);\n let wValue3 = getW(wRPerm, wCPerm, d1 + 3, d2);\n var xValue = getDy(batch, idyR, idyC2, d2);\n let tmpval = vec4(dot(xValue, wValue0),\n dot(xValue, wValue1),\n dot(xValue, wValue2),\n dot(xValue, wValue3));\n dotProd[1] = dotProd[1] + tmpval;\n }\n }\n }\n }\n\n for (var i = 0; i < ${this.workPerThread}; i = i + 1) {\n let coords = vec4(batch, r, c + i, d1);\n if (coordsInBounds4D(coords, uniforms.outShape)) {\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], dotProd[i]);\n }\n }\n }\n `;return this.isVec4?`\n ${n}\n `:`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d1 = coords[${o}];\n\n let dyCorner = vec2(coords[${t}], coords[${e}]) - uniforms.pads;\n let dyRCorner = dyCorner.x;\n let dyCCorner = dyCorner.y;\n\n // Convolve dy(?, ?, d2) with w(:, :, d1, d2) to compute dx(xR, xC, d1).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var wR = 0; wR < uniforms.filterDims.x; wR = wR + 1) {\n let dyR = (f32(dyRCorner) + f32(wR)) / f32(uniforms.strides.x);\n let wRPerm = uniforms.filterDims.x - 1 - wR;\n if (dyR < 0.0 || dyR >= f32(uniforms.outBackprop[1]) || fract(dyR) > 0.0 ||\n wRPerm < 0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims.y; wC = wC + 1) {\n let dyC = (f32(dyCCorner) + f32(wC)) / f32(uniforms.strides.y);\n let wCPerm = uniforms.filterDims.y - 1 - wC;\n if (dyC < 0.0 || dyC >= f32(uniforms.outBackprop[2]) ||\n fract(dyC) > 0.0 || wCPerm < 0) {\n continue;\n }\n let idyC = i32(dyC);\n\n for (var d2 = 0; d2 < uniforms.outBackprop[3]; d2 = d2 + 1) {\n let xValue = ${this.isChannelsLast?\"getDy(batch, idyR, idyC, d2)\":\"getDy(batch, d2, idyR, idyC)\"};\n let wValue = getW(wRPerm, wCPerm, d1, d2);\n dotProd = dotProd + xValue * wValue;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},wx=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.uniforms=\"pads : vec2, strides : vec2, batchSize : i32, outHeight : i32, outWidth : i32, inHeight : i32, inWidth : i32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.isChannelsLast=t.dataFormat===\"channelsLast\",this.shaderKey=`conv2DDerFilter_${this.isChannelsLast}`}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let wR = coords[0];\n let wC = coords[1];\n let d1 = coords[2];\n let d2 = coords[3];\n\n // Convolve x(?, ?, d1) with dy(:, :, d2) to get dw(wR, wC, d1, d2).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n for (var b = 0; b < uniforms.batchSize; b = b + 1) {\n for (var yR = 0; yR < uniforms.outHeight; yR = yR + 1) {\n let xR = wR + yR * uniforms.strides[0] - uniforms.pads[0];\n if (xR < 0 || xR >= uniforms.inHeight) {\n continue;\n }\n\n for (var yC = 0; yC < uniforms.outWidth; yC = yC + 1) {\n let xC = wC + yC * uniforms.strides[1] - uniforms.pads[1];\n\n if (xC < 0 || xC >= uniforms.inWidth) {\n continue;\n }\n\n if (${this.isChannelsLast}) {\n let dyValue = getDy(b, yR, yC, d2);\n let xValue = getX(b, xR, xC, d1);\n dotProd = dotProd + xValue * dyValue;\n } else {\n let dyValue = getDy(b, d2, yR, yC);\n let xValue = getX(b, d1, xR, xC);\n dotProd = dotProd + xValue * dyValue;\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Sx=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.uniforms=`pads : vec3, strides : vec3, batchSize : i32, outDepth : i32,\n outHeight : i32, outWidth : i32, inDepth : i32, inHeight : i32, inWidth : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"conv3DDerFilter\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let wF = coords.x;\n let wR = coords.y;\n let wC = coords.z;\n let d1 = coords.w;\n let d2 = coords.u;\n\n var dotProd = 0.0;\n for (var b = 0; b < uniforms.batchSize; b++) {\n for (var yF = 0; yF < uniforms.outDepth; yF++) {\n let xF = wF + yF * uniforms.strides[0] - uniforms.pads[0];\n if (xF < 0 || xF >= uniforms.inDepth) {\n continue;\n }\n\n for (var yR = 0; yR < uniforms.outHeight; yR++) {\n let xR = wR + yR * uniforms.strides[1] - uniforms.pads[1];\n if (xR < 0 || xR >= uniforms.inHeight) {\n continue;\n }\n\n for (var yC = 0; yC < uniforms.outWidth; yC++) {\n let xC = wC + yC * uniforms.strides[2] - uniforms.pads[2];\n if (xC < 0 || xC >= uniforms.inWidth) {\n continue;\n }\n\n let dyValue = getDy(b, yF, yR, yC, d2);\n let xValue = getX(b, xF, xR, xC, d1);\n dotProd += xValue * dyValue;\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Ix=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.uniforms=`filterDims : vec3, pads : vec3, strides : vec3,\n outDepth : i32, outHeight : i32, outWidth : i32, outChannels : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"conv3DDerInput\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let d1 = coords.u;\n\n let dyCorner = vec3(coords.y, coords.z, coords.w) - uniforms.pads;\n let dyFCorner = dyCorner.x;\n let dyRCorner = dyCorner.y;\n let dyCCorner = dyCorner.z;\n\n var dotProd = 0.0;\n for (var wF = 0; wF < uniforms.filterDims[0]; wF++) {\n let dyF = f32(dyFCorner + wF) / f32(uniforms.strides[0]);\n if (dyF < 0.0 || dyF >= f32(uniforms.outDepth) || fract(dyF) > 0.0) {\n continue;\n }\n let idyF = i32(dyF);\n\n let wFPerm = uniforms.filterDims[0] - 1 - wF;\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[1]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n let wRPerm = uniforms.filterDims[1] - 1 - wR;\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[2]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let wCPerm = uniforms.filterDims[2] - 1 - wC;\n\n for (var d2 = 0; d2 < uniforms.outChannels; d2++) {\n let xValue = getDy(batch, idyF, idyR, idyC, d2);\n let wValue = getW(wFPerm, wRPerm, wCPerm, d1, d2);\n dotProd += xValue * wValue;\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function Iue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,dataFormat:p,dimRoundingMode:u,filterShape:c}=o,l=w.convertConv2DDataFormat(p),m=w.computeConv2DInfo(n.shape,c,a,1,i,u,!1,l),d=new wx(m),f=[{type:\"int32\",data:[m.padInfo.top,m.padInfo.left]},{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.batchSize]},{type:\"int32\",data:[m.outHeight]},{type:\"int32\",data:[m.outWidth]},{type:\"int32\",data:[m.inHeight]},{type:\"int32\",data:[m.inWidth]}];return e.runWebGPUProgram(d,[n,s],n.dtype,f)}var SV={kernelName:Oi,backendName:\"webgpu\",kernelFunc:Iue};function vue(r=4){let t=s=>{switch(s){case 1:return\"return W[getIndexFromCoords4D(coord, uniforms.wShape)];\";case 4:return`\n let coord1 = vec4(coordX, coordY, col + 1, rowInner);\n let coord2 = vec4(coordX, coordY, col + 2, rowInner);\n let coord3 = vec4(coordX, coordY, col + 3, rowInner);\n let v0 = W[getIndexFromCoords4D(coord, uniforms.wShape)];\n let v1 = W[getIndexFromCoords4D(coord1, uniforms.wShape)];\n let v2 = W[getIndexFromCoords4D(coord2, uniforms.wShape)];\n let v3 = W[getIndexFromCoords4D(coord3, uniforms.wShape)];\n return vec4(v0, v1, v2, v3);\n `;default:throw new Error(`innerElementSize ${s} is not supported.`)}},o=`if (row < uniforms.dimAOuter && col < uniforms.dimInner) {\n ${`\n let outRow = row / uniforms.outShape[2];\n let outCol = row % uniforms.outShape[2];\n\n let WRow = col / (uniforms.filterDims[1] * uniforms.outBackprop[3]);\n let WCol = col / uniforms.outBackprop[3] % uniforms.filterDims[1];\n let xR = f32(outRow - uniforms.pads[0] + WRow) / f32(uniforms.strides[0]);\n let xC = f32(outCol - uniforms.pads[1] + WCol) / f32(uniforms.strides[1]);\n if (xR < 0.0 || xR >= f32(uniforms.outBackprop[1]) || fract(xR) > 0.0) {\n return ${Ae(r)}(0.0);\n }\n if (xC < 0.0 || xC >= f32(uniforms.outBackprop[2]) || fract(xC) > 0.0) {\n return ${Ae(r)}(0.0);\n }\n let coord = vec4(\n batch,\n i32(xR),\n i32(xC),\n col % uniforms.outBackprop[3]);\n return x[getIndexFromCoords4D(coord, uniforms.xShape)/${r}];`}\n }\n return ${Ae(r)}(0.0);`;return`\n fn mm_readA(batch: i32, row : i32, col : i32) -> ${Ae(r)} {\n ${o}\n }\n\n fn mm_readB(batch: i32, row : i32, col : i32) -> ${Ae(r)} {\n let coordX = uniforms.filterDims.x - 1 -\n row / (uniforms.filterDims[1] * uniforms.outBackprop[3]);\n let coordY = uniforms.filterDims.y - 1 -\n (row / uniforms.outBackprop[3]) % uniforms.filterDims[1];\n if (row < uniforms.dimInner && col < uniforms.dimBOuter &&\n coordX >= 0 && coordY >= 0) {\n let rowInner = row % uniforms.outBackprop[3];\n let coord = vec4(coordX, coordY, col, rowInner);\n ${t(r)}\n }\n return ${Ae(r)}(0.0);\n }\n\n fn mm_write(batch: i32, row : i32, col : i32, valueInput : ${Ae(r)}) {\n if (row < uniforms.dimAOuter && col < uniforms.dimBOuter) {\n var value = valueInput;\n let outCoord = vec4(\n batch,\n row / uniforms.outShape[2],\n row % uniforms.outShape[2],\n col);\n result[getIndexFromCoords4D(outCoord, uniforms.outShape)/${r}] = value;\n }\n }`}var vx=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims : vec2, pads : vec2, strides : vec2, outBackprop : vec4, dimAOuter : i32, dimBOuter : i32, dimInner : i32,\",this.outputShape=t.inShape,y.assert(t.dataFormat===\"channelsLast\",()=>\"TODO: NCHW is unimplemented\"),this.isVec4=t.inChannels%4===0&&t.outChannels%4===0,this.dispatchLayout={x:[3],y:[1,2],z:[0]},this.workgroupSize=lm(this.dispatchLayout,this.outputShape,this.isVec4),this.elementsPerThread=mm(this.dispatchLayout,this.outputShape,this.isVec4),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,this.elementsPerThread),this.isVec4&&(this.outputComponent=4,this.variableComponents=[4,1]),this.shaderKey=`conv2DDerInputMM_${this.isVec4}_${this.elementsPerThread}`}getUserCode(){let t=this.isVec4?Fp(this.elementsPerThread,this.workgroupSize):Pp(this.elementsPerThread,this.workgroupSize);return`\n ${vue(this.isVec4?4:1)}\n ${t}\n `}};function kue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{inputShape:a,strides:i,pad:p,dataFormat:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(u),m=w.computeConv2DInfo(a,s.shape,i,1,p,c,!1,l),d=[{type:\"int32\",data:[m.filterHeight,m.filterWidth]},{type:\"int32\",data:[m.filterHeight-1-m.padInfo.top,m.filterWidth-1-m.padInfo.left]},{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.batchSize,m.outHeight,m.outWidth,m.outChannels]}],f;if(A().getBool(\"WEBGPU_USE_NAIVE_CONV2D_TRANSPOSE\")||m.dataFormat!==\"channelsLast\")f=new Cx(m);else{f=new vx(m);let h=m.inHeight*m.inWidth,g=m.inChannels,x=m.filterHeight*m.filterWidth*m.outChannels;d.push({type:\"uint32\",data:[h]},{type:\"uint32\",data:[g]},{type:\"uint32\",data:[x]})}return e.runWebGPUProgram(f,[n,s],\"float32\",d)}var IV={kernelName:on,backendName:\"webgpu\",kernelFunc:kue};var kx=class{constructor(t){this.variableNames=[\"x\",\"W\"],this.uniforms=\"filterDims: vec3, pads: vec3, strides: vec3, dilations: vec3,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"conv3dnaive\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let batch = coords.x;\n let d2 = coords.u;\n\n let xFRCCorner = vec3(coords.y, coords.z, coords.w) * uniforms.strides - uniforms.pads;\n let xFCorner = xFRCCorner.x;\n let xRCorner = xFRCCorner.y;\n let xCCorner = xFRCCorner.z;\n\n let inputDepthNearestVec4 = (uniforms.xShape.u / 4) * 4;\n let inputDepthVec4Remainder = uniforms.xShape.u % 4;\n\n var dotProd = 0.0;\n for (var wF = 0; wF < uniforms.filterDims[0]; wF++) {\n let xF = xFCorner + wF * uniforms.dilations[0];\n if (xF < 0 || xF >= uniforms.xShape.y) {\n continue;\n }\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let xR = xRCorner + wR * uniforms.dilations[1];\n if (xR < 0 || xR >= uniforms.xShape.z) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let xC = xCCorner + wC * uniforms.dilations[2];\n if (xC < 0 || xC >= uniforms.xShape.w) {\n continue;\n }\n\n for (var d1 = 0; d1 < inputDepthNearestVec4; d1 += 4) {\n let xValues = vec4(\n getX(batch, xF, xR, xC, d1),\n getX(batch, xF, xR, xC, d1 + 1),\n getX(batch, xF, xR, xC, d1 + 2),\n getX(batch, xF, xR, xC, d1 + 3)\n );\n let wValues = vec4(\n getW(wF, wR, wC, d1, d2),\n getW(wF, wR, wC, d1 + 1, d2),\n getW(wF, wR, wC, d1 + 2, d2),\n getW(wF, wR, wC, d1 + 3, d2)\n );\n\n dotProd += dot(xValues, wValues);\n }\n\n if (inputDepthVec4Remainder == 1) {\n dotProd += getX(batch, xF, xR, xC, inputDepthNearestVec4) *\n getW(wF, wR, wC, inputDepthNearestVec4, d2);\n } else if (inputDepthVec4Remainder == 2) {\n let xValues = vec2(\n getX(batch, xF, xR, xC, inputDepthNearestVec4),\n getX(batch, xF, xR, xC, inputDepthNearestVec4 + 1)\n );\n let wValues = vec2(\n getW(wF, wR, wC, inputDepthNearestVec4, d2),\n getW(wF, wR, wC, inputDepthNearestVec4 + 1, d2)\n );\n dotProd += dot(xValues, wValues);\n } else if (inputDepthVec4Remainder == 3) {\n let xValues = vec3(\n getX(batch, xF, xR, xC, inputDepthNearestVec4),\n getX(batch, xF, xR, xC, inputDepthNearestVec4 + 1),\n getX(batch, xF, xR, xC, inputDepthNearestVec4 + 2)\n );\n let wValues = vec3(\n getW(wF, wR, wC, inputDepthNearestVec4, d2),\n getW(wF, wR, wC, inputDepthNearestVec4 + 1, d2),\n getW(wF, wR, wC, inputDepthNearestVec4 + 2, d2)\n );\n dotProd += dot(xValues, wValues);\n }\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }`}};function Nue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeConv3DInfo(n.shape,s.shape,a,p,i),c=[u.padInfo.front,u.padInfo.top,u.padInfo.left],l=[{type:\"int32\",data:[u.filterDepth,u.filterHeight,u.filterWidth]},{type:\"int32\",data:[...c]},{type:\"int32\",data:[u.strideDepth,u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.dilationDepth,u.dilationHeight,u.dilationWidth]}],m=new kx(u),d=dt(n.dtype,s.dtype);return e.runWebGPUProgram(m,[n,s],d,l)}var vV={kernelName:nn,backendName:\"webgpu\",kernelFunc:Nue};function Tue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,pad:i,filterShape:p}=o,u=w.computeConv3DInfo(n.shape,p,a,1,i),c=new Sx(u),l=[{type:\"int32\",data:[u.padInfo.front,u.padInfo.top,u.padInfo.left]},{type:\"int32\",data:[u.strideDepth,u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.batchSize]},{type:\"int32\",data:[u.outDepth]},{type:\"int32\",data:[u.outHeight]},{type:\"int32\",data:[u.outWidth]},{type:\"int32\",data:[u.inDepth]},{type:\"int32\",data:[u.inHeight]},{type:\"int32\",data:[u.inWidth]}];return e.runWebGPUProgram(c,[n,s],s.dtype,l)}var kV={kernelName:Xa,backendName:\"webgpu\",kernelFunc:Tue};function _ue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{strides:a,pad:i,inputShape:p}=o,u=w.computeConv3DInfo(p,s.shape,a,1,i),c=new Ix(u),l=[{type:\"int32\",data:[u.filterDepth,u.filterHeight,u.filterWidth]},{type:\"int32\",data:[u.filterDepth-1-u.padInfo.front,u.filterHeight-1-u.padInfo.top,u.filterWidth-1-u.padInfo.left]},{type:\"int32\",data:[u.strideDepth,u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.outDepth]},{type:\"int32\",data:[u.outHeight]},{type:\"int32\",data:[u.outWidth]},{type:\"int32\",data:[u.outChannels]}];return e.runWebGPUProgram(c,[n,s],n.dtype,l)}var NV={kernelName:sn,backendName:\"webgpu\",kernelFunc:_ue};var $ue=ye({opType:Z.COS}),TV={kernelName:an,backendName:\"webgpu\",kernelFunc:$ue};var Eue=ye({opType:Z.COSH}),_V={kernelName:un,backendName:\"webgpu\",kernelFunc:Eue};var Nx=class{constructor(t,e,o,n){this.variableNames=[\"Image\",\"Boxes\",\"BoxInd\"],this.uniforms=\"extrapolationValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0;let[s]=e;this.outputShape=[s,o[0],o[1],t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.methodId=n===\"bilinear\"?1:0,this.cropHeightBiggerThan1=this.outputShape[1]>1,this.cropWidthBiggerThan1=this.outputShape[2]>1,this.shaderKey=`cropAndResize_${this.methodId}_${this.cropHeightBiggerThan1}_${this.cropWidthBiggerThan1}`}getUserCode(){let[t,e]=[\"f32(uniforms.imageShape[1] - 1)\",\"f32(uniforms.imageShape[2] - 1)\"],[o,n,s]=this.cropHeightBiggerThan1?[`(${t} / f32(uniforms.outShape[1] - 1))`,\"(y2-y1) * height_ratio\",`y1*${t} + f32(y)*(height_scale)`]:[\"0.0\",\"0.0\",`0.5 * (y1+y2) * ${t}`],[a,i,p]=this.cropWidthBiggerThan1?[`(${e} / f32(uniforms.outShape[2] - 1))`,\"(x2-x1) * width_ratio\",`x1*${e} + f32(x)*(width_scale)`]:[\"0.0\",\"0.0\",`0.5 * (x1+x2) * ${e}`];return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let height_ratio = f32(${o});\n let width_ratio = f32(${a});\n let b = coords[0];\n let y = coords[1];\n let x = coords[2];\n let d = coords[3];\n // get box vals\n let y1 = getBoxes(b, 0);\n let x1 = getBoxes(b, 1);\n let y2 = getBoxes(b, 2);\n let x2 = getBoxes(b, 3);\n // get image in batch index\n let bInd = i32(round(getBoxInd(b)));\n if(bInd < 0 || bInd >= uniforms.outShape[0]) {\n return;\n }\n let height_scale = ${n};\n let width_scale = ${i};\n let in_y = ${s};\n if( in_y < 0.0 || in_y > ${t} ) {\n setOutputAtIndex(index, uniforms.extrapolationValue);\n return;\n }\n let in_x = ${p};\n if( in_x < 0.0 || in_x > ${e} ) {\n setOutputAtIndex(index, uniforms.extrapolationValue);\n return;\n }\n let sourceFracIndexCR = vec2(in_x,in_y);\n if(${this.methodId} == 1) {\n // Compute the four integer indices.\n let sourceFloorCR = vec2(sourceFracIndexCR);\n let sourceCeilCR = vec2(ceil(sourceFracIndexCR));\n let topLeft = getImage(bInd, sourceFloorCR.y, sourceFloorCR.x, d);\n let bottomLeft = getImage(bInd, sourceCeilCR.y, sourceFloorCR.x, d);\n let topRight = getImage(bInd, sourceFloorCR.y, sourceCeilCR.x, d);\n let bottomRight = getImage(bInd, sourceCeilCR.y, sourceCeilCR.x, d);\n let fracCR = sourceFracIndexCR - vec2(sourceFloorCR);\n let top = topLeft + (topRight - topLeft) * fracCR.x;\n let bottom = bottomLeft + (bottomRight - bottomLeft) * fracCR.x;\n let newValue = top + (bottom - top) * fracCR.y;\n setOutputAtIndex(index, newValue);\n } else {\n // Compute the coordinators of nearest neighbor point.\n let sourceNearestCR = vec2(floor(\n sourceFracIndexCR + vec2(0.5,0.5)));\n let newValue = getImage(\n bInd, sourceNearestCR.y, sourceNearestCR.x, d);\n setOutputAtIndex(index, newValue);\n }\n }\n }\n `}};var Rue=r=>{let{inputs:t,backend:e,attrs:o}=r,{image:n,boxes:s,boxInd:a}=t,{cropSize:i,method:p,extrapolationValue:u}=o,c=new Nx(n.shape[3],s.shape,i,p),l=[{type:\"float32\",data:[u]}];return e.runWebGPUProgram(c,[n,s,a],\"float32\",l)},$V={kernelName:ln,backendName:\"webgpu\",kernelFunc:Rue};var Lp;(function(r){r.Prod=\"*\",r.Sum=\"+\"})(Lp||(Lp={}));var xm=class{constructor(t,e,o,n){this.variableNames=[\"x\"],this.uniforms=\"index : f32,\",this.size=!0,this.workgroupSize=[128,1,1],this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.exclusive=o,this.reverse=n,this.op=t,this.shaderKey=`cum_${this.op}_${this.exclusive}_${this.reverse}`}getUserCode(){let t=this.outputShape.length,e=this.op===Lp.Prod?\"1.0\":\"0.0\",o=this.exclusive?e:`getX(${EV(t,\"coords\",this.op)})`,n=this.outputShape[this.outputShape.length-1],s=\"\",a=\"\";return this.exclusive?(s=this.reverse?`end != ${n-1}`:\"end != 0\",a=this.reverse?\"end + 1\":\"end - 1\"):(s=this.reverse?`end + pow2 < ${n}`:\"end >= pow2\",a=this.reverse?\"end + pow2\":\"end - pow2\"),`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var coords = getCoordsFromIndex(index);\n\n let end = ${RV(t,\"coords\",this.op)};\n var val = ${o};\n let pow2 = i32(pow(2.0, uniforms.index));\n if (${s}) {\n let idx = ${a};\n ${RV(t,\"coords\",this.op)} = idx;\n val ${this.op}= getX(${EV(t,\"coords\",this.op)});\n }\n setOutputAtIndex(index, val);\n }\n }\n `}};function EV(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.x, ${t}.y`;if(r===3)return`${t}.x, ${t}.y, ${t}.z`;if(r===4)return`${t}.x, ${t}.y, ${t}.z, ${t}.w`;throw Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function RV(r,t,e){if(r===1)return`${t}`;if(r===2)return`${t}.y`;if(r===3)return`${t}.z`;if(r===4)return`${t}.w`;throw Error(`Cumulative ${e} for rank ${r} is not yet supported`)}function Tx(r,t,e,o,n,s){let a=t.shape.length,i=w.getAxesPermutation([o],a),p=t;i!=null&&(p=yr({inputs:{x:t},backend:e,attrs:{perm:i}}));let u=w.getInnerMostAxes(1,a)[0];if(u!==a-1)throw new Error(`WebGPU cumprod shader expects an inner-most axis=${t.shape.length-1} but got axis=${o}`);let c=p.shape[u],l=Ft({inputs:{x:p},backend:e});for(let m=0;m<=Math.ceil(Math.log2(c))-1;m++){let d=new xm(r,p.shape,!1,s),f=l,h=[{type:\"float32\",data:[m]}];l=e.runWebGPUProgram(d,[l],l.dtype,h),e.disposeData(f.dataId)}if(n){let m=new xm(r,p.shape,n,s),d=l,f=[{type:\"float32\",data:[0]}];l=e.runWebGPUProgram(m,[l],l.dtype,f),e.disposeData(d.dataId)}if(i!=null){let m=w.getUndoAxesPermutation(i),d=yr({inputs:{x:l},backend:e,attrs:{perm:m}});return e.disposeData(l.dataId),e.disposeData(p.dataId),d}return l}function Due(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return Tx(Lp.Prod,n,e,s,a,i)}var DV={kernelName:pn,backendName:\"webgpu\",kernelFunc:Due};function Aue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,exclusive:a,reverse:i}=o;return Tx(Lp.Sum,n,e,s,a,i)}var AV={kernelName:cn,backendName:\"webgpu\",kernelFunc:Aue};function Fue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,weights:s}=t,{size:a,binaryOutput:i}=o,p=n.shape.length===1,c=y.sizeFromShape(s.shape)>0,l=s.dtype,m=p?[n.shape[0]]:[n.shape[0],n.shape[1]],d=p?[a]:[n.shape[0],a],f=kt({backend:e,attrs:{shape:d,value:0,dtype:l}}),h=new Jc(m,c,i),g=[{type:\"int32\",data:[a]}],x=c?[n,s]:[n];return e.runWebGPUProgram(h,x,l,g,f)}var FV={kernelName:ra,backendName:\"webgpu\",kernelFunc:Fue};var _x=class{constructor(t,e){this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.uniforms=\"blockSize : i32,\",this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=`depthToSpace_${e}`,this.dataFormat=e}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let b = coords[0];\n let h = ${this.getHeightCoordString()};\n let w = ${this.getWidthCoordString()};\n let d = ${this.getDepthCoordString()};\n\n let in_h = h / uniforms.blockSize;\n let offset_h = h % uniforms.blockSize;\n let in_w = w / uniforms.blockSize;\n let offset_w = w % uniforms.blockSize;\n let offset_d = (offset_h * uniforms.blockSize + offset_w) *\n ${this.getOutputDepthSize()};\n let in_d = d + offset_d;\n\n let rlt = ${this.getInputSamplingString()};\n setOutputAtIndex(index, rlt);\n }\n }`}getHeightCoordString(){return this.dataFormat===\"NHWC\"?\"coords[1]\":\"coords[2]\"}getWidthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[2]\":\"coords[3]\"}getDepthCoordString(){return this.dataFormat===\"NHWC\"?\"coords[3]\":\"coords[1]\"}getOutputDepthSize(){return this.dataFormat===\"NHWC\"?\"uniforms.outShape[3]\":\"uniforms.outShape[1]\"}getInputSamplingString(){return this.dataFormat===\"NHWC\"?\"getX(b, in_h, in_w, in_d)\":\"getX(b, in_d, in_h, in_w)\"}};function Pue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockSize:s,dataFormat:a}=o,i=n.shape[0],p=a===\"NHWC\"?n.shape[1]:n.shape[2],u=a===\"NHWC\"?n.shape[2]:n.shape[3],c=a===\"NHWC\"?n.shape[3]:n.shape[1],l=p*s,m=u*s,d=c/(s*s),f=a===\"NHWC\"?[i,l,m,d]:[i,d,l,m],h=[{type:\"int32\",data:[s]}],g=new _x(f,a);return e.runWebGPUProgram(g,[n],n.dtype,h)}var PV={kernelName:mn,backendName:\"webgpu\",kernelFunc:Pue};var $x=class{constructor(t,e,o,n=!1,s=null,a=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=\"pads : vec2, inDims : vec2,\",this.workgroupSize=[16,16,1],this.outputShape=t,this.dispatchLayout={x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),n&&this.variableNames.push(\"bias\"),a&&this.variableNames.push(\"preluActivationWeights\"),this.addBias=n,this.activation=s,this.hasPreluActivation=a,this.filterHeight=e,this.filterWidth=o,this.shaderKey=`depthwiseNCHW_${this.activation}_${this.filterHeight}_${this.filterWidth}`}getUserCode(){let t=this.filterWidth*this.filterHeight,e=this.workgroupSize[0]*this.workgroupSize[1]*this.workgroupSize[2],o=this.workgroupSize[1]+this.filterHeight-1,n=this.workgroupSize[0]+this.filterWidth-1;return`\n ${fr(this.activation,this.hasPreluActivation,!1,4)}\n\n var mm_Asub : array, ${o}>;\n var mm_Bsub : array, ${this.filterHeight}>;\n fn readX(batch : i32, channel : i32, row : i32, col : i32) -> f32 {\n var value = 0.0;\n if (row >=0 && row < uniforms.inDims[0] && col >=0 && col < uniforms.inDims[1])\n {\n value = getX(batch, channel, row, col);\n }\n return value;\n }\n\n ${G()} {\n let coords = getOutputCoords();\n let batch = coords[0];\n let xRCCorner = vec2(coords.zw) - uniforms.pads;\n let channelMul = uniforms.wShape[3];\n let d1 = coords[1] / channelMul;\n let q = coords[1] % channelMul;\n\n let inputRowStart = xRCCorner.x;\n let inputColStart = xRCCorner.y;\n\n let localRow = i32(localId.y);\n let localCol = i32(localId.x);\n\n // Load one tile of X into local memory.\n for (var inputRow = localRow; inputRow < ${o}; inputRow = inputRow + ${this.workgroupSize[1]}) {\n for (var inputCol = localCol; inputCol < ${n}; inputCol = inputCol + ${this.workgroupSize[0]}) {\n let rowOffset = inputRow - localRow;\n let colOffset = inputCol - localCol;\n mm_Asub[inputRow][inputCol] = readX(batch, d1, inputRowStart + rowOffset, inputColStart + colOffset);\n }\n }\n\n // Load one tile of W into local memory.\n var wIndex = i32(localIndex);\n ${t, inDims : vec2, virtualWidth : i32,\",this.workgroupSize=[64,1,1],this.workPerThread=4,this.outputComponent=4,this.outputShape=t.outShape,this.virtualWidth=Math.ceil(this.outputShape[2]/this.workPerThread)*this.workPerThread;let s=[this.outputShape[0],this.outputShape[1],this.virtualWidth,this.outputShape[3]];this.dispatchLayout=X(s),this.dispatch=H(this.dispatchLayout,s,this.workgroupSize,[this.outputComponent*this.workPerThread,1,1]),y.assert(t.dataFormat===\"channelsLast\",()=>\"TODO: NCHW is unimplemented\"),e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),this.convInfo=t,this.addBias=e,this.activation=o,this.hasPreluActivation=n,this.shaderKey=`depthwiseVec4_${o}_${this.convInfo.filterHeight}_${this.convInfo.filterWidth}_${this.convInfo.strideHeight}_${this.convInfo.strideWidth}_${this.workPerThread}`}getUserCode(){let t=(this.workPerThread-1)*this.convInfo.strideWidth+this.convInfo.filterWidth,e=this.convInfo.strideHeight,o=this.convInfo.strideWidth;return`\n ${fr(this.activation,this.hasPreluActivation,!0,4)}\n fn readX(batch : i32, row : i32, col : i32, channel : i32) -> vec4 {\n var value = vec4(0.0);\n if (col >=0 && col < uniforms.inDims[1]) {\n value = getX(batch, row, col, channel);\n }\n return value;\n }\n\n ${G(\"index\")} {\n let width0 = uniforms.outShape[3] / ${this.outputComponent};\n let d1 = (index % width0) * ${this.outputComponent};\n var index1 = index / width0;\n let width1 = uniforms.virtualWidth / ${this.workPerThread};\n let c = (index1 % width1) * ${this.workPerThread};\n index1 = index1 / width1;\n let r = index1 % uniforms.outShape[1];\n let batch = index1 / uniforms.outShape[1];\n\n let xRCCorner = vec2(r, c) * vec2(${e}, ${o}) - uniforms.pads;\n\n let xRCorner = xRCCorner.x;\n let xCCorner = xRCCorner.y;\n var xVals : array, ${t}>;\n var dotProd : array, ${this.workPerThread}>;\n for (var i = 0; i < ${this.workPerThread}; i++) {\n dotProd[i] = vec4(0.0);\n }\n\n // Use constant instead of uniform can give better performance.\n for (var wR = 0; wR < ${this.convInfo.filterHeight}; wR = wR + 1) {\n let xR = xRCorner + wR;\n if (xR >=0 && xR < uniforms.inDims[0]) {\n for (var i = 0; i < ${t}; i++) {\n xVals[i] = readX(batch, xR, xCCorner + i, d1);\n }\n for (var wC = 0; wC < ${this.convInfo.filterWidth}; wC = wC + 1) {\n let wValue = getW(wR, wC, d1, 0);\n for (var i = 0; i < ${this.workPerThread}; i++) {\n dotProd[i] = fma(xVals[i * ${o} + wC], wValue, dotProd[i]);\n }\n }\n }\n }\n\n for (var i = 0; i < ${this.workPerThread}; i = i + 1) {\n let coords = vec4(batch, r, c + i, d1);\n if (coordsInBounds4D(coords, uniforms.outShape)) {\n var value = dotProd[i];\n ${Zr(this.addBias,this.activation)}\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], value);\n }\n }\n }\n `}};var rl=class{constructor(t,e=!1,o=null,n=!1){this.variableNames=[\"x\",\"W\"],this.uniforms=`pads : vec2, inDims : vec2, filterHeight : i32,\n filterWidth : i32, strides : vec2, dilations : vec2,`,this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.isChannelsLast=t.dataFormat===\"channelsLast\",e&&this.variableNames.push(\"bias\"),n&&this.variableNames.push(\"preluActivationWeights\"),this.convInfo=t,this.addBias=e,this.activation=o,this.hasPreluActivation=n,this.shaderKey=`depthwise_${this.activation}_${this.isChannelsLast}`}getUserCode(){let t=this.isChannelsLast?\"getX(batch, xR, xC, d1);\":\"getX(batch, d1, xR, xC);\";return`\n ${fr(this.activation,this.hasPreluActivation,!1,4)}\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let batch = coords[0];\n let xRCCorner = vec2(coords.${this.isChannelsLast?\"yz\":\"zw\"}) * uniforms.strides - uniforms.pads;\n let d2 = coords[${this.isChannelsLast?3:1}];\n let channelMul = uniforms.wShape[3];\n let d1 = d2 / channelMul;\n let q = d2 % channelMul;\n\n let inputRowStart = xRCCorner.x;\n let inputColStart = xRCCorner.y;\n let inputRowEnd = inputRowStart + uniforms.filterHeight *\n uniforms.dilations[0];\n let inputColEnd = inputColStart + uniforms.filterWidth *\n uniforms.dilations[1];\n\n // Convolve x(?, ?, d1)|x(d1, ?, ?) with w(:, :, d1, q) to get\n // y(yR, yC, d2)|y(d2, yR, yC). ? = to be determined. : = across all\n // values in that axis. x(?, ?, d1) and y(yR, yC, d2) is for NHWC.\n // x(d1, ?, ?) and y(d2, yR, yC) is for NCHW.\n var value = 0.0;\n\n // Extract if checking out of for loop for performance.\n if (inputRowStart >= 0 && inputColStart >= 0 &&\n inputRowEnd < uniforms.inDims[0] &&\n inputColEnd < uniforms.inDims[1]) {\n for (var wR = 0; wR < uniforms.filterHeight; wR = wR + 1) {\n let xR = inputRowStart + wR * uniforms.dilations[0];\n\n for (var wC = 0; wC < uniforms.filterWidth; wC = wC + 1) {\n let xC = inputColStart + wC * uniforms.dilations[1];\n\n let xVal = ${t};\n let wVal = getW(wR, wC, d1, q);\n value = value + xVal * wVal;\n }\n }\n } else {\n for (var wR = 0; wR < uniforms.filterHeight; wR = wR + 1) {\n let xR = inputRowStart + wR * uniforms.dilations[0];\n\n if (xR < 0 || xR >= uniforms.inDims[0]) {\n continue;\n }\n\n for (var wC = 0; wC < uniforms.filterWidth; wC = wC + 1) {\n let xC = inputColStart + wC * uniforms.dilations[1];\n\n if (xC < 0 || xC >= uniforms.inDims[1]) {\n continue;\n }\n\n let xVal = ${t};\n let wVal = getW(wR, wC, d1, q);\n value = value + xVal * wVal;\n }\n }\n }\n ${Zr(this.addBias,this.activation)}\n setOutputAtCoords(coords[0], coords[1], coords[2], coords[3], value);\n }\n }\n `}};function Oue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dataFormat:p,dilations:u,dimRoundingMode:c}=o,l=w.convertConv2DDataFormat(p),m=u;m==null&&(m=[1,1]);let d=w.computeConv2DInfo(n.shape,s.shape,a,m,i,c,!0,l),f=[{type:\"int32\",data:[d.padInfo.top,d.padInfo.left]},{type:\"int32\",data:[d.inHeight,d.inWidth]}],h=d.dataFormat===\"channelsLast\",g;return!h&&d.inHeight>16&&d.inWidth>16&&d.strideHeight===1&&d.strideWidth===1&&d.dilationWidth===1&&d.dilationHeight===1&&d.inChannels===d.outChannels?g=new $x(d.outShape,d.filterHeight,d.filterWidth):h&&d.outHeight>4&&d.outWidth>4&&d.strideWidth<=2&&d.inChannels===d.outChannels&&d.dilationHeight===1&&d.dilationWidth===1&&d.inChannels%4===0?(g=new tl(d),f.push({type:\"int32\",data:[g.virtualWidth]})):(g=new rl(d),f.push({type:\"int32\",data:[d.filterHeight]},{type:\"int32\",data:[d.filterWidth]},{type:\"int32\",data:[d.strideHeight,d.strideWidth]},{type:\"int32\",data:[d.dilationHeight,d.dilationWidth]})),e.runWebGPUProgram(g,[n,s],n.dtype,f)}var OV={kernelName:dn,backendName:\"webgpu\",kernelFunc:Oue};var Ex=class{constructor(t){this.variableNames=[\"x\",\"dy\"],this.uniforms=`strides : vec2, pads : vec2, filterDims : vec2, outHeight : i32,\n outWidth : i32, inHeight : i32, inWidth : i32, batchSize : i32, channelMul : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"depthwise_conv2d_backprop_filter\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let wR = coords[0];\n let wC = coords[1];\n let d1 = coords[2];\n let dm = coords[3];\n let d2 = d1 * uniforms.channelMul + dm;\n\n var dotProd = 0.0;\n for (var b = 0; b < uniforms.batchSize; b++) {\n for (var yR = 0; yR < uniforms.outHeight; yR++) {\n let xR = wR + yR * uniforms.strides[0] - uniforms.pads[0];\n\n if (xR < 0 || xR >= uniforms.inHeight) {\n continue;\n }\n\n for (var yC = 0; yC < uniforms.outWidth; yC++) {\n let xC = wC + yC * uniforms.strides[1] - uniforms.pads[1];\n\n if (xC < 0 || xC >= uniforms.inWidth) {\n continue;\n }\n\n let dyValue = getDy(b, yR, yC, d2);\n let xValue = getX(b, xR, xC, d1);\n dotProd += xValue * dyValue;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Rx=class{constructor(t){this.variableNames=[\"dy\",\"W\"],this.uniforms=`strides : vec2, pads : vec2, filterDims : vec2,\n outHeight : i32, outWidth : i32, channelMul : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"depthwise_conv2d_backprop_input\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d1 = coords[3];\n let dyCorner = coords.yz - uniforms.pads;\n let dyRCorner = dyCorner.x;\n let dyCCorner = dyCorner.y;\n\n var dotProd = 0.0;\n for (var wR = 0; wR < uniforms.filterDims[0]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[0]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n\n let idyR = i32(dyR);\n let wRPerm = uniforms.filterDims[0] - 1 - wR;\n\n for (var wC = 0; wC < uniforms.filterDims[1]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[1]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n\n let idyC = i32(dyC);\n let wCPerm = uniforms.filterDims[1] - 1 - wC;\n\n for (var dm = 0; dm < uniforms.channelMul; dm++) {\n let d2 = d1 * uniforms.channelMul + dm;\n let xValue = getDy(batch, idyR, idyC, d2);\n let wValue = getW(wRPerm, wCPerm, d1, dm);\n dotProd += xValue * wValue;\n }\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function Mue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,dy:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,filterShape:c}=o,l=w.computeConv2DInfo(n.shape,c,a,i,p,u,!0),m=new Ex(l),d=[{type:\"int32\",data:[l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.padInfo.top,l.padInfo.left]},{type:\"int32\",data:[l.filterHeight,l.filterWidth]},{type:\"int32\",data:[l.outHeight]},{type:\"int32\",data:[l.outWidth]},{type:\"int32\",data:[l.inHeight]},{type:\"int32\",data:[l.inWidth]},{type:\"int32\",data:[l.batchSize]},{type:\"int32\",data:[l.outChannels/l.inChannels]}];return e.runWebGPUProgram(m,[n,s],\"float32\",d)}var MV={kernelName:Mi,backendName:\"webgpu\",kernelFunc:Mue};function Lue(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,filter:s}=t,{strides:a,dilations:i,pad:p,dimRoundingMode:u,inputShape:c}=o,l=w.computeConv2DInfo(c,s.shape,a,i,p,u,!0),m=new Rx(l),d=[{type:\"int32\",data:[l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.filterHeight-1-l.padInfo.top,l.filterWidth-1-l.padInfo.left]},{type:\"int32\",data:[l.filterHeight,l.filterWidth]},{type:\"int32\",data:[l.outHeight]},{type:\"int32\",data:[l.outWidth]},{type:\"int32\",data:[l.outChannels/l.inChannels]}];return e.runWebGPUProgram(m,[n,s],n.dtype,d)}var LV={kernelName:Li,backendName:\"webgpu\",kernelFunc:Lue};var Dx=class{constructor(t){this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t,t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"diag\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let value = select(0.0, getX(coords[0]), coords[0] == coords[1]);\n setOutputAtIndex(index, value);\n }\n }\n `}};function Bue(r){let{inputs:t,backend:e}=r,{x:o}=t,n=[...o.shape,...o.shape],s=y.sizeFromShape(o.shape),a=pe({inputs:{x:o},backend:e,attrs:{shape:[s]}}),i=new Dx(s),p=e.runWebGPUProgram(i,[a],a.dtype),u=pe({inputs:{x:p},backend:e,attrs:{shape:n}});return e.disposeData(a.dataId),e.disposeData(p.dataId),u}var BV={kernelName:oa,backendName:\"webgpu\",kernelFunc:Bue};var Ax=class{constructor(t){this.variableNames=[\"x\",\"w\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.outShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"dilation2d\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let neg_infinity = -3.4e38;\n let coords = getOutputCoords();\n let batch = coords.x;\n let d1 = coords.w;\n let outTopLeftCorner = coords.yz * uniforms.strides - uniforms.pads;\n let hBeg = outTopLeftCorner.x;\n let wBeg = outTopLeftCorner.y;\n\n var curVal = neg_infinity;\n for (var h = 0; h < uniforms.filterDims[0]; h = h + 1) {\n let hIn = hBeg + h * uniforms.dilations[0];\n\n if (hIn >= 0 && hIn < uniforms.xShape[1]) {\n for (var w = 0; w < uniforms.filterDims[1]; w = w + 1) {\n let wIn = wBeg + w * uniforms.dilations[1];\n\n if (wIn >= 0 && wIn < uniforms.xShape[2]) {\n let val = getX(batch, hIn, wIn, d1) + getW(h, w, d1);\n if (val > curVal) {\n curVal = val;\n }\n }\n }\n }\n }\n\n setOutputAtIndex(index, curVal);\n }\n }\n `}};function zue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s}=t,{strides:a,pad:i,dilations:p}=o,u=w.computeDilation2DInfo(n.shape,s.shape,a,i,\"NHWC\",p),c=[u.padInfo.top,u.padInfo.left],l=[{type:\"int32\",data:[u.filterHeight,u.filterWidth]},{type:\"int32\",data:[...c]},{type:\"int32\",data:[u.strideHeight,u.strideWidth]},{type:\"int32\",data:[u.dilationHeight,u.dilationWidth]}],m=new Ax(u);return e.runWebGPUProgram(m,[n,s],n.dtype,l)}var zV={kernelName:fn,backendName:\"webgpu\",kernelFunc:zue};var Fx=class{constructor(t,e){if(this.variableNames=[\"x\",\"w\",\"dy\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2, dySize: i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=t.inShape,this.dispatchLayout=X(t.outShape),this.dispatch=H(this.dispatchLayout,t.outShape,this.workgroupSize),e!==\"float32\"&&e!==\"int32\")throw new Error(`Dilation2DBackpropInput only supports float32 and int32\n types, does not support ${e} type.`);this.type=e,this.shaderKey=\"dilation2DBackpropInput\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.dySize) {\n let coords = getDyCoordsFromIndex(index);\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n let d = coords[3];\n\n let dyCorner = vec2(r, c) * uniforms.strides - uniforms.pads;\n var curVal = -3.4e38; // neg_infinity\n var xRMax = 0;\n var xCMax = 0;\n\n // In the case of multiple argmax branches, we only back-propagate\n // along the last branch, i.e., the one with largest value of\n // 'wR * uniforms.filterDims[1] + wC', similarly to the max-pooling\n // backward routines.\n for (var wR = 0; wR < uniforms.filterDims[0]; wR++) {\n let xR = dyCorner.x + wR * uniforms.dilations[0];\n\n if (xR >= 0 && xR < uniforms.xShape[1]) {\n for (var wC = 0; wC < uniforms.filterDims[1]; wC++) {\n let xC = dyCorner.y + wC * uniforms.dilations[1];\n\n if (xC >= 0 && xC < uniforms.xShape[2]) {\n let val = getX(b, xR, xC, d) + getW(wR, wC, d);\n if (val > curVal) {\n curVal = val;\n xRMax = xR;\n xCMax = xC;\n }\n }\n }\n }\n }\n\n let flatIndexIn = d + uniforms.xShape[3] *\n (xCMax + uniforms.xShape[2] * (xRMax + uniforms.xShape[1] * b));\n let value = getDy(b, r, c, d);\n ${Qr(\"&result[flatIndexIn]\",\"value\",this.type)}\n }\n }\n `}},Px=class{constructor(t,e,o){if(this.variableNames=[\"x\",\"w\",\"dy\"],this.uniforms=\"filterDims: vec2, pads: vec2, strides: vec2, dilations: vec2, dySize: i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=t.filterShape,this.dispatchLayout=X(t.outShape),this.dispatch=H(this.dispatchLayout,t.outShape,this.workgroupSize),o!==\"float32\"&&o!==\"int32\")throw new Error(`Dilation2DBackpropFilter only supports float32 and int32\n types, does not support ${o} type.`);this.type=o,this.shaderKey=\"dilation2DBackpropFilter\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.dySize) {\n let coords = getDyCoordsFromIndex(index);\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n let d = coords[3];\n\n let dyCorner = vec2(r, c) * uniforms.strides - uniforms.pads;\n var curVal = -3.4e38; // neg_infinity\n var wRMax = 0;\n var wCMax = 0;\n\n // In the case of multiple argmax branches, we only back-propagate\n // along the last branch, i.e., the one with largest value of\n // 'wR * uniforms.filterDims[1] + wC', similarly to the max-pooling\n // backward routines.\n for (var wR = 0; wR < uniforms.filterDims[0]; wR++) {\n let xR = dyCorner.x + wR * uniforms.dilations[0];\n\n if (xR >= 0 && xR < uniforms.xShape[1]) {\n for (var wC = 0; wC < uniforms.filterDims[1]; wC++) {\n let xC = dyCorner.y + wC * uniforms.dilations[1];\n\n if (xC >= 0 && xC < uniforms.xShape[2]) {\n let val = getX(b, xR, xC, d) + getW(wR, wC, d);\n if (val > curVal) {\n curVal = val;\n wRMax = wR;\n wCMax = wC;\n }\n }\n }\n }\n }\n\n let flatIndexIn = d + uniforms.wShape[2] * (wCMax + wRMax * uniforms.wShape[1]);\n let value = getDy(b, r, c, d);\n ${Qr(\"&result[flatIndexIn]\",\"value\",this.type)}\n }\n }\n `}};function Vue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o,c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=s.dtype,m=new Px(c,s.shape,l),d=[{type:\"int32\",data:[c.filterHeight,c.filterWidth]},{type:\"int32\",data:[c.padInfo.top,c.padInfo.left]},{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[y.sizeFromShape(c.outShape)]}],f=kt({backend:e,attrs:{shape:s.shape,value:0,dtype:l}});return e.runWebGPUProgram(m,[n,s,a],l,d,f)}var VV={kernelName:zi,backendName:\"webgpu\",kernelFunc:Vue};function Wue(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,dy:a}=t,{strides:i,pad:p,dilations:u}=o,c=w.computeDilation2DInfo(n.shape,s.shape,i,p,\"NHWC\",u),l=n.dtype,m=new Fx(c,l),d=[{type:\"int32\",data:[c.filterHeight,c.filterWidth]},{type:\"int32\",data:[c.padInfo.top,c.padInfo.left]},{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[y.sizeFromShape(c.outShape)]}],f=kt({backend:e,attrs:{shape:c.inShape,value:0,dtype:l}});return e.runWebGPUProgram(m,[n,s,a],l,d,f)}var WV={kernelName:Bi,backendName:\"webgpu\",kernelFunc:Wue};var Ox=class{constructor(t,e,o){this.variableNames=[\"Image\"],this.uniforms=\"alpha: f32,\",this.workgroupSize=[64,1,1],this.pixelsOpType=Ii.DRAW,this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.type=e,this.textureFormat=o,this.shaderKey=`draw_${e}_${o}`}getUserCode(){let t,e=this.type===\"float32\"?\"value\":\"value / 255.0\";return t=`\n if (uniforms.numChannels == 1) {\n rgba[0] = ${e};\n rgba[1] = ${e};\n rgba[2] = ${e};\n } else {\n rgba[d] = ${e};\n }`,`\n @group(0) @binding(0) var outImage : texture_storage_2d<${this.textureFormat}, write>;\n ${G(\"index\")} {\n if (index < uniforms.size) {\n var rgba = vec4(0.0, 0.0, 0.0, uniforms.alpha);\n for (var d = 0; d < uniforms.numChannels; d = d + 1) {\n let value = f32(inBuf[index * uniforms.numChannels + d]);\n ${t}\n }\n rgba.x = rgba.x * rgba.w;\n rgba.y = rgba.y * rgba.w;\n rgba.z = rgba.z * rgba.w;\n let coords = getCoordsFromIndex(index);\n textureStore(outImage, vec2(coords.yx), rgba);\n }\n }\n `}};function Uue(r){let{inputs:t,backend:e,attrs:o}=r,{image:n}=t,{canvas:s,options:a}=o,[i,p]=n.shape.slice(0,2),{imageOptions:u}=a||{},c=(u==null?void 0:u.alpha)||1,l=e.device.features.has(\"bgra8unorm-storage\")?\"bgra8unorm\":\"rgba8unorm\",m=[i,p],d=new Ox(m,n.dtype,l);s.width=p,s.height=i;let f=\"webgpu\",h=s.getContext(f),g;h||(g=new OffscreenCanvas(p,i),h=g.getContext(f));let x=n.shape.length===3?n.shape[2]:1;h.configure({device:e.device,format:l,usage:GPUTextureUsage.STORAGE_BINDING,alphaMode:\"premultiplied\"});let b=\"int32\",C=e.makeTensorInfo(m,b),S=e.tensorMap.get(C.dataId);S.resource=h.getCurrentTexture(),S.external=!0;let k=[{type:\"uint32\",data:[x]},{type:\"float32\",data:[c]}];if(e.runWebGPUProgram(d,[n],b,k,C),g){let _=s.getContext(\"2d\");if(!_)throw new Error(\"Please make sure this canvas has only been used for 2d or webgpu context!\");_.drawImage(g,0,0)}return e.disposeData(C.dataId),n}var UV={kernelName:Pu,backendName:\"webgpu\",kernelFunc:Uue};var s0=et({opType:fe.MUL,cpuKernelImpl:vz,supportsComplex:!0}),GV={kernelName:Yn,backendName:\"webgpu\",kernelFunc:s0};function a0(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;return eo(n,s,a,\"sum\",e)}var HV={kernelName:Is,backendName:\"webgpu\",kernelFunc:a0};function Gue(r){let{inputs:t,backend:e,attrs:o}=r,{equation:n}=o,s=t,{allDims:a,summedDims:i,idDims:p}=w.decodeEinsumEquation(n,s.length);w.checkEinsumDimSizes(a.length,p,s);let{path:u,steps:c}=w.getEinsumComputePath(i,p),l=c.length,m=null,d=a.length,f=[];for(let h=0;h=0&&(m=a0({inputs:{x:m},backend:e,attrs:{axis:u[h]-(a.length-d),keepDims:!1}}),f.push(m)),d--)}for(let h of f)h!==m&&e.disposeData(h.dataId);return m}var KV={kernelName:Vi,backendName:\"webgpu\",kernelFunc:Gue};var Hue=ye({opType:Z.ELU}),qV={kernelName:gn,backendName:\"webgpu\",kernelFunc:Hue};var Kue=r=>{let{inputs:t,backend:e}=r,{dy:o,y:n}=t,s=new ki(fe.ELU_DER,o.shape,n.shape);return e.runWebGPUProgram(s,[o,n],o.dtype)},jV={kernelName:Ya,backendName:\"webgpu\",kernelFunc:Kue};var que=et({opType:fe.EQUAL,dtype:\"bool\",cpuKernelImpl:pz}),XV={kernelName:yn,backendName:\"webgpu\",kernelFunc:que};var jue=ye({opType:Z.ERF}),YV={kernelName:xn,backendName:\"webgpu\",kernelFunc:jue};var Xue=ye({opType:Z.EXP,cpuKernelImpl:cz,dtype:\"float32\"}),QV={kernelName:bn,backendName:\"webgpu\",kernelFunc:Xue};function Mx(r){let{inputs:t,attrs:e,backend:o}=r,{dim:n}=e,{input:s}=t,a=s.shape.length,i=s.shape.slice(),p=n;return n<0&&(y.assert(-(a+1)<=n,()=>`Axis must be in the interval [${-(a+1)}, ${a}]`),p=a+n+1),i.splice(p,0,1),pe({inputs:{x:s},backend:o,attrs:{shape:i}})}var ZV={kernelName:na,backendName:\"webgpu\",kernelFunc:Mx};var Yue=ye({opType:Z.EXPM1,cpuKernelImpl:lz}),JV={kernelName:Cn,backendName:\"webgpu\",kernelFunc:Yue};var ym=class{constructor(t,e){this.variableNames=[\"real\",\"imag\"],this.outputShape=[],this.uniforms=\"exponentMultiplier : f32, denominator: f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.component=t,this.shaderKey=`fft_${t}`}getUserCode(){return`\n fn unaryOpComplex(real: f32, expR: f32, imag: f32, expI: f32) -> f32 {\n ${this.component===\"real\"?\"return real * expR - imag * expI;\":\"return real * expI + imag * expR;\"}\n }\n\n fn mulMatDFT(batch: i32, index: i32) -> f32 {\n let indexRatio = f32(index) / f32(uniforms.realShape[1]);\n let exponentMultiplierTimesIndexRatio =\n uniforms.exponentMultiplier * indexRatio;\n\n var result = 0.0;\n\n for (var i = 0; i < uniforms.realShape[1]; i = i + 1) {\n // x = (-2|2 * PI / N) * index * i;\n let x = exponentMultiplierTimesIndexRatio * f32(i);\n let expR = cos(x);\n let expI = sin(x);\n let real = getReal(batch, i);\n let imag = getImag(batch, i);\n\n result = result +\n unaryOpComplex(real, expR, imag, expI) / uniforms.denominator;\n }\n\n return result;\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n setOutputAtIndex(index, mulMatDFT(coords[0], coords[1]));\n }\n }\n `}};function Lx(r,t,e){let o=e.tensorMap.get(r.dataId),n=y.sizeFromShape(r.shape),s=r.shape[r.shape.length-1],a=n/s,i=[],p=pe({inputs:{x:r},backend:e,attrs:{shape:[a,s]}});i.push(p);let u=p.shape,c=new ym(\"real\",u),l=new ym(\"imag\",u),m=[{dataId:o.complexTensorInfos.real.dataId,dtype:o.complexTensorInfos.real.dtype,shape:u},{dataId:o.complexTensorInfos.imag.dataId,dtype:o.complexTensorInfos.imag.dtype,shape:u}],d=t?2*Math.PI:-2*Math.PI,f=t?u[1]:1,h=[{type:\"float32\",data:[d]},{type:\"float32\",data:[f]}],g=e.runWebGPUProgram(c,m,\"float32\",h);i.push(g);let x=e.runWebGPUProgram(l,m,\"float32\",h);i.push(x);let b=yo({inputs:{real:g,imag:x},backend:e});i.push(b);let C=pe({inputs:{x:b},backend:e,attrs:{shape:r.shape}});return i.forEach(S=>e.disposeData(S.dataId)),C}function Que(r){let{inputs:t,backend:e}=r,{input:o}=t;return Lx(o,!1,e)}var eW={kernelName:Wi,backendName:\"webgpu\",kernelFunc:Que};var Bx=class{constructor(t){this.outputShape=[],this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"flipLeftRight\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let coordX = uniforms.xShape[2] - coords[2] - 1;\n let outputValue = getX(coords[0], coords[1], coordX, coords[3]);\n setOutputAtIndex(index, outputValue);\n }\n }\n `}};var tW={kernelName:wn,backendName:\"webgpu\",kernelFunc:({inputs:r,backend:t})=>{let{image:e}=r,o=t,n=new Bx(e.shape);return o.runWebGPUProgram(n,[e],e.dtype)}};var Zue=ye({opType:Z.FLOOR,cpuKernelImpl:mz}),rW={kernelName:Sn,backendName:\"webgpu\",kernelFunc:Zue};var Jue=et({opType:fe.FLOOR_DIV,cpuKernelImpl:dz,dtype:\"int32\"}),oW={kernelName:In,backendName:\"webgpu\",kernelFunc:Jue};var zx=class{constructor(t,e,o=!1){this.pixelsOpType=Ii.FROM_PIXELS,this.outputShape=[0],this.variableNames=[],this.workgroupSize=[256,1,1],this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[e,1,1]),this.importVideo=o,this.shaderKey=`fromPixels_${this.importVideo}`}getUserCode(){let t=this.importVideo?\"textureLoad(src, vec2(coords.yx));\":\"textureLoad(src, vec2(coords.yx), 0)\";return`\n @binding(1) @group(0) var src: ${this.importVideo?\"texture_external\":\"texture_2d\"};\n ${G(\"index\")} {\n let flatIndex = index * uniforms.numChannels;\n if (flatIndex < uniforms.size) {\n let coords = getCoordsFromIndex(flatIndex);\n let values = ${t};\n for (var i = 0; i < uniforms.numChannels; i = i + 1) {\n result[flatIndex + i] = i32(floor(255.0 * values[i]));\n }\n }\n }\n `}};var nW={kernelName:Mu,backendName:\"webgpu\",kernelFunc:epe},ol,i0=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");function epe(r){let{inputs:t,backend:e,attrs:o}=r,{pixels:n}=t,{numChannels:s}=o;if(n==null)throw new Error(\"pixels passed to tf.browser.fromPixels() can not be null\");let a=typeof HTMLVideoElement!=\"undefined\"&&n instanceof HTMLVideoElement,i=typeof HTMLImageElement!=\"undefined\"&&n instanceof HTMLImageElement,p=typeof HTMLCanvasElement!=\"undefined\"&&n instanceof HTMLCanvasElement||typeof OffscreenCanvas!=\"undefined\"&&n instanceof OffscreenCanvas,u=typeof ImageBitmap!=\"undefined\"&&n instanceof ImageBitmap,[c,l]=a?[n.videoWidth,n.videoHeight]:[n.width,n.height],m=[l,c,s],d=!1,f=a||i;if(u||p||f){let b;if(d)b=e.device.importExternalTexture({source:n});else{if(f){let L=A().getBool(\"CANVAS2D_WILL_READ_FREQUENTLY_FOR_GPU\");(ol==null||L!==i0)&&(i0=L,ol=document.createElement(\"canvas\").getContext(\"2d\",{willReadFrequently:i0})),ol.canvas.width=c,ol.canvas.height=l,ol.drawImage(n,0,0,c,l),n=ol.canvas}let P=GPUTextureUsage.COPY_DST|GPUTextureUsage.RENDER_ATTACHMENT|GPUTextureUsage.TEXTURE_BINDING,O=\"rgba8unorm\",M=e.textureManager.acquireTexture(m[1],m[0],O,P);e.queue.copyExternalImageToTexture({source:n},{texture:M},[m[1],m[0]]),b=M}let C=y.sizeFromShape(m),S=y.computeStrides(m),k=new zx(m,s,d),_=[{type:\"uint32\",data:[C]},{type:\"uint32\",data:[s]},{type:\"uint32\",data:[...S]}],E=e.makeTensorInfo([l,c],\"int32\"),R=e.tensorMap.get(E.dataId);R.resource=b;let D=e.runWebGPUProgram(k,[E],\"int32\",_);return e.disposeData(E.dataId),D}let h=n.data,g=h;if(s!=null&&s!==4){g=new Uint8Array(n.width*n.height*s);let b=h.length,C=0;for(let S=0;S(xValue, -meanValue, offsetValue), vec3(inv, inv, 1.0)));\n }\n }\n `}};var sW={kernelName:vn,backendName:\"webgpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o,scale:n,offset:s,mean:a,variance:i}=r,{varianceEpsilon:p}=t,u=e,c=[o,a,i],l=null;s!=null&&(l=s.shape,c.push(s));let m=null;n!=null&&(m=n.shape,c.push(n));let d=new Vx(o.shape,a.shape,i.shape,l,m),f=[{type:\"float32\",data:[p]}];return u.runWebGPUProgram(d,c,o.dtype,f)}};function tpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dataFormat:c,dilations:l,dimRoundingMode:m,activation:d,leakyreluAlpha:f}=o,h=w.convertConv2DDataFormat(c),g=w.computeConv2DInfo(n.shape,s.shape,p,l,u,m,!1,h);return bx({x:n,filter:s,convInfo:g,backend:e,bias:a,preluActivationWeights:i,leakyreluAlpha:f,activation:d})}var aW={kernelName:vo,backendName:\"webgpu\",kernelFunc:tpe};function rpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,filter:s,bias:a,preluActivationWeights:i}=t,{strides:p,pad:u,dilations:c,dimRoundingMode:l,activation:m,leakyreluAlpha:d}=o,f=c;f==null&&(f=[1,1]),y.assert(w.eitherStridesOrDilationsAreOne(p,f),()=>`Error in depthwiseConv2d: Either strides or dilations must be 1. Got strides ${p} and dilations '${f}'`);let h=w.computeConv2DInfo(n.shape,s.shape,p,f,u,l,!0),g=[n,s],x=a!=null,b=i!=null;x&&g.push(a),b&&g.push(i);let C=[{type:\"int32\",data:[h.padInfo.top,h.padInfo.left]},{type:\"int32\",data:[h.inHeight,h.inWidth]}],S;return h.outHeight>4&&h.outWidth>4&&h.strideWidth<=2&&h.inChannels===h.outChannels&&h.dilationHeight===1&&h.dilationWidth===1&&h.inChannels%4===0?(S=new tl(h,x,m,b),C.push({type:\"int32\",data:[S.virtualWidth]})):(S=new rl(h,x,m,b),C.push({type:\"int32\",data:[h.filterHeight]},{type:\"int32\",data:[h.filterWidth]},{type:\"int32\",data:[h.strideHeight,h.strideWidth]},{type:\"int32\",data:[h.dilationHeight,h.dilationWidth]})),m===\"leakyrelu\"&&(C.push({type:\"float32\",data:[d]}),S.uniforms+=\" alpha : f32,\"),e.runWebGPUProgram(S,g,\"float32\",C)}var iW={kernelName:ko,backendName:\"webgpu\",kernelFunc:rpe};var Wx=class{constructor(t,e){this.variableNames=[\"A\",\"indices\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=`gathernd_${t}`,this.sliceDim=t,this.uniforms=`sliceDim : i32, strides : ${ht(t)},`}getUserCode(){let t;return this.sliceDim>1?t=\"uniforms.strides[j]\":t=\"uniforms.strides\",`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n var flattenIndex = 0;\n for (var j = 0; j < uniforms.sliceDim; j = j + 1) {\n let indexTemp = i32(round(getIndices(coords[0], j)));\n let strideNum = ${t};\n flattenIndex = flattenIndex + indexTemp * strideNum;\n }\n\n setOutputAtIndex(index, getA(flattenIndex, coords[1]));\n }\n }\n `}};function ope(r){let{inputs:t,backend:e}=r,{params:o,indices:n}=t,s=n.shape,a=s[s.length-1],i=y.sizeFromShape(o.shape),[p,u,c,l]=w.prepareAndValidate(o,n),m=pe({inputs:{x:n},backend:e,attrs:{shape:[u,a]}}),d=pe({inputs:{x:o},backend:e,attrs:{shape:[y.sizeFromShape(o.shape)/c,c]}});if(e.shouldExecuteOnCPU([o,n])||o.dtype===\"string\"){let b=e.readSync(n.dataId),C=e.bufferSync(o),S=fz(b,C,o.dtype,u,a,c,l,o.shape,i);return e.makeTensorInfo(p,o.dtype,S.values)}let f=new Wx(a,[u,c]),h=[{type:\"int32\",data:[a]},{type:\"int32\",data:l}],g=e.runWebGPUProgram(f,[d,m],d.dtype,h),x=pe({inputs:{x:g},backend:e,attrs:{shape:p}});return e.disposeData(m.dataId),e.disposeData(d.dataId),e.disposeData(g.dataId),x}var uW={kernelName:kn,backendName:\"webgpu\",kernelFunc:ope};var Ux=class{constructor(t,e){this.variableNames=[\"A\",\"indices\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.slice(),this.aShape=t,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"gather\"}getUserCode(){let t=npe(this.aShape);return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let resRC = getCoordsFromIndex(index);\n let indexZ = i32(getIndices(resRC.x, resRC.z));\n let inBounds = select(0.0, 1.0, indexZ >= 0 && indexZ < uniforms.aShape[2]);\n setOutputAtIndex(index, inBounds * getA(${t}));\n }\n }\n `}};function npe(r){let t=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],e=[];for(let o=0;oe.disposeData(D.dataId)),e.makeTensorInfo(u.outputShape,R.dtype,R.values)}let h=new Ux(m.shape,f),g=e.runWebGPUProgram(h,[m,d],m.dtype);l.push(g);let x=pe({inputs:{x:g},backend:e,attrs:{shape:u.outputShape}});return l.forEach(b=>e.disposeData(b.dataId)),x}var pW={kernelName:aa,backendName:\"webgpu\",kernelFunc:u0};var spe=et({opType:fe.GREATER,cpuKernelImpl:xz,dtype:\"bool\"}),cW={kernelName:Nn,backendName:\"webgpu\",kernelFunc:spe};var ape=et({opType:fe.GREATER_EQUAL,dtype:\"bool\",cpuKernelImpl:gz}),lW={kernelName:Tn,backendName:\"webgpu\",kernelFunc:ape};function ipe(r){let{inputs:t,backend:e}=r,{input:o}=t;return Lx(o,!0,e)}var mW={kernelName:Ui,backendName:\"webgpu\",kernelFunc:ipe};var upe=ye({opType:Z.IS_FINITE,dtype:\"bool\"}),dW={kernelName:_n,backendName:\"webgpu\",kernelFunc:upe};var ppe=ye({opType:Z.IS_INF,dtype:\"bool\"}),fW={kernelName:$n,backendName:\"webgpu\",kernelFunc:ppe};var cpe=ye({opType:Z.IS_NAN,dtype:\"bool\"}),hW={kernelName:En,backendName:\"webgpu\",kernelFunc:cpe};function lpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{alpha:s}=o,a=[{type:\"float32\",data:[s]}],i=new Jr(n.shape,Z.LEAKYRELU,\"alpha : f32,\");return e.runWebGPUProgram(i,[n],\"float32\",a)}var gW={kernelName:Rn,backendName:\"webgpu\",kernelFunc:lpe};var mpe=et({opType:fe.LESS,dtype:\"bool\",cpuKernelImpl:bz}),xW={kernelName:Dn,backendName:\"webgpu\",kernelFunc:mpe};var dpe=et({opType:fe.LESS_EQUAL,dtype:\"bool\",cpuKernelImpl:yz}),yW={kernelName:An,backendName:\"webgpu\",kernelFunc:dpe};var Gx=class{constructor(t){this.variableNames=[],this.outputShape=[],this.uniforms=\"start : f32, step : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"linSpace\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n setOutputAtIndex(index, uniforms.start + f32(index) * uniforms.step);\n }\n }\n `}};function fpe(r){let{backend:t,attrs:e}=r,{start:o,stop:n,num:s}=e,a=(n-o)/(s-1),i=new Gx(s),p=[{type:\"float32\",data:[o]},{type:\"float32\",data:[a]}];return t.runWebGPUProgram(i,[],\"float32\",p)}var bW={kernelName:Fn,backendName:\"webgpu\",kernelFunc:fpe};var hpe=ye({opType:Z.LOG,cpuKernelImpl:Cz}),CW={kernelName:Pn,backendName:\"webgpu\",kernelFunc:hpe};var gpe=ye({opType:Z.LOG1P}),wW={kernelName:On,backendName:\"webgpu\",kernelFunc:gpe};var xpe=et({opType:fe.LOGICAL_AND,dtype:\"bool\"}),SW={kernelName:Mn,backendName:\"webgpu\",kernelFunc:xpe};var ype=ye({opType:Z.LOGICAL_NOT}),IW={kernelName:Ln,backendName:\"webgpu\",kernelFunc:ype};var bpe=et({opType:fe.LOGICAL_OR}),vW={kernelName:Bn,backendName:\"webgpu\",kernelFunc:bpe};var kW=`\n var powValue = 0.0;\n let basis = uniforms.bias + uniforms.alpha * sum;\n if (uniforms.beta == 0.5) {\n powValue = inverseSqrt(basis);\n } else if (uniforms.beta == 1.0) {\n powValue = 1.0 / basis;\n } else {\n powValue = exp(log(basis) * (-uniforms.beta));\n }\n`,Hx=class{constructor(t){this.outputShape=[],this.variableNames=[\"x\"],this.uniforms=\"radius : i32, bias : f32, alpha : f32, beta : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"lrn\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n let d = coords[3];\n\n let x = getX(b, r, c, d);\n var sum = 0.0;\n for (var i = -uniforms.radius; i <= uniforms.radius; i = i + 1) {\n let idx = d + i;\n if (idx >= 0 && idx < uniforms.xShape[3]) {\n let z = getX(b, r, c, idx);\n sum = sum + z * z;\n }\n }\n ${kW}\n\n setOutputAtIndex(index, x * powValue);\n }\n }\n `}},Kx=class{constructor(t,e){this.outputShape=[],this.variableNames=[\"x\"],this.uniforms=\"radius : i32, bias : f32, alpha : f32, beta : f32,\",this.workgroupSize=[256,1,1],this.maxAllowRadius=16,y.assert(e<=this.maxAllowRadius,()=>`Radius must be less than or equal to ${this.maxAllowRadius}, current radius is ${e}`),this.outputShape=t,this.elementsPerWorkgroup=this.workgroupSize[0]-2*this.maxAllowRadius,this.dispatchLayout={x:[3],y:[2],z:[0,1]},this.dispatch=H(this.dispatchLayout,this.outputShape,[this.elementsPerWorkgroup,this.workgroupSize[1],this.workgroupSize[2]]),this.shaderKey=\"lrn_shared\"}getUserCode(){return`\n var lrnSub: array;\n const elementsPerWorkgroup = ${this.elementsPerWorkgroup};\n const maxAllowRadius = ${this.maxAllowRadius};\n\n ${G()} {\n let localDepth = i32(localId.x);\n let workgroupDepth = i32(workgroupId.x) * elementsPerWorkgroup;\n let xDepth = workgroupDepth + localDepth - maxAllowRadius;\n let b = i32(globalId.z) / uniforms.xShape[1];\n let r = i32(globalId.z) - b * uniforms.xShape[1];\n let c = i32(globalId.y);\n let d = workgroupDepth + localDepth;\n\n var x = 0.0;\n if (xDepth >= 0 && xDepth < uniforms.xShape[3]) {\n x = getX(b, r, c, xDepth);\n }\n lrnSub[localDepth] = x;\n workgroupBarrier();\n\n if (localDepth < elementsPerWorkgroup && d < uniforms.outShape[3]) {\n var sum = 0.0;\n let index = localDepth + maxAllowRadius;\n for (var i = -uniforms.radius; i <= uniforms.radius; i = i + 1) {\n let z = lrnSub[index + i];\n sum = sum + z * z;\n }\n ${kW}\n\n setOutputAtCoords(b, r, c, d, lrnSub[index] * powValue);\n }\n } `}};function Cpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{depthRadius:s,bias:a,alpha:i,beta:p}=o,u;s>16?u=new Hx(n.shape):u=new Kx(n.shape,s);let c=[{type:\"int32\",data:[s]},{type:\"float32\",data:[a]},{type:\"float32\",data:[i]},{type:\"float32\",data:[p]}];return e.runWebGPUProgram(u,[n],n.dtype,c)}var NW={kernelName:zn,backendName:\"webgpu\",kernelFunc:Cpe};var qx=class{constructor(t){this.outputShape=[],this.variableNames=[\"inputImage\",\"outputImage\",\"dy\"],this.uniforms=\"depthRadius : i32, bias : f32, alpha : f32, beta : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"lrn_grad\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let r = coords[1];\n let c = coords[2];\n\n let MIN_DEPTH_BEGIN = 0;\n let MAX_DEPTH_END = uniforms.outShape[3];\n var result = 0.0;\n for (var d = MIN_DEPTH_BEGIN; d < MAX_DEPTH_END; d++) {\n let depthBegin = max(MIN_DEPTH_BEGIN, d - uniforms.depthRadius);\n let depthEnd = min(MAX_DEPTH_END, d + uniforms.depthRadius + 1);\n\n var norm = 0.0;\n for (var k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; k++) {\n if (k < depthBegin) {\n continue;\n } else if (k >= depthBegin && k < depthEnd) {\n norm += getInputImage(b, r, c, k) * getInputImage(b, r, c, k);\n } else {\n break;\n }\n }\n\n norm = uniforms.alpha * norm + uniforms.bias;\n\n for (var k = MIN_DEPTH_BEGIN; k < MAX_DEPTH_END; k++) {\n if (k < depthBegin) {\n continue;\n } else if (k >= depthBegin && k < depthEnd) {\n var dyi = -2.0 * uniforms.alpha * uniforms.beta\n * getInputImage(b, r, c, k) * getOutputImage(b, r, c, d) / norm;\n if (k == d) {\n dyi += pow(norm, -1.0 * uniforms.beta);\n }\n if (k == coords[3]) {\n dyi *= getDy(b, r, c, d);\n result += dyi;\n }\n } else {\n break;\n }\n }\n }\n\n setOutputAtIndex(index, result);\n }\n }\n `}};function wpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,y:s,dy:a}=t,{depthRadius:i,bias:p,alpha:u,beta:c}=o,l=new qx(n.shape),m=[{type:\"int32\",data:[i]},{type:\"float32\",data:[p]},{type:\"float32\",data:[u]},{type:\"float32\",data:[c]}];return e.runWebGPUProgram(l,[n,s,a],n.dtype,m)}var TW={kernelName:Qa,backendName:\"webgpu\",kernelFunc:wpe};var Spe=et({opType:fe.MAX,cpuKernelImpl:Sz}),_W={kernelName:Wn,backendName:\"webgpu\",kernelFunc:Spe};function Ipe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dimRoundingMode:p}=o,u=1,c=w.computePool2DInfo(n.shape,s,a,u,i,p);return ax(n,c,\"max\",e)}var $W={kernelName:Un,backendName:\"webgpu\",kernelFunc:Ipe};function vpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{filterSize:s,strides:a,pad:i,dataFormat:p,dimRoundingMode:u}=o,c=[1,1,1],l=w.computePool3DInfo(n.shape,s,a,c,i,u,p),m=new _u(l,\"max\"),d=[{type:\"int32\",data:[l.strideDepth,l.strideHeight,l.strideWidth]},{type:\"int32\",data:[l.padInfo.front,l.padInfo.top,l.padInfo.left]},{type:\"int32\",data:[l.inDepth,l.inHeight,l.inWidth]},{type:\"int32\",data:[l.effectiveFilterDepth,l.effectiveFilterHeight,l.effectiveFilterWidth]}];return e.runWebGPUProgram(m,[n],n.dtype,d)}var EW={kernelName:ia,backendName:\"webgpu\",kernelFunc:vpe};var jx=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.uniforms=`strides : vec2, pads : vec2, dilations : vec2, filterDims : vec2,\n outHeight : i32, outWidth : i32`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"maxPool2DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords[0];\n let d = coords[3];\n\n let dyRCCorner = vec2(coords.yz) - uniforms.pads;\n let dyRCorner = dyRCCorner.x;\n let dyCCorner = dyRCCorner.y;\n\n // Convolve dy(?, ?, d) with pos mask(:, :, d) to get dx(xR, xC, d).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n let lastIndex = uniforms.filterDims[0] * uniforms.filterDims[1] - 1;\n for (var wR = 0; wR < uniforms.filterDims[0]; wR += uniforms.dilations[0]) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[0]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[1]; wC += uniforms.dilations[1]) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[1]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyR, idyC, d);\n let maxPosValue = lastIndex - i32(getMaxPos(batch, idyR, idyC, d));\n\n // Get the current value, check it against the value from the\n // position matrix.\n let curPosValue = wR * uniforms.filterDims[1] + wC;\n let mask = select(0.0, 1.0, maxPosValue == curPosValue);\n dotProd += dyValue * mask;\n }\n }\n setOutputAtIndex(index, dotProd);\n }\n }\n `}},Xx=class{constructor(t){this.variableNames=[\"dy\",\"maxPos\"],this.uniforms=`strides : vec3, pads : vec3, filterDims : vec3,\n outDepth : i32, outHeight : i32, outWidth : i32`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t.inShape,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"maxPool3DBackprop\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let batch = coords.x;\n let ch = coords.u;\n\n let dyCorner = vec3(coords.y, coords.z, coords.w) - uniforms.pads;\n let dyDCorner = dyCorner.x;\n let dyRCorner = dyCorner.y;\n let dyCCorner = dyCorner.z;\n\n // Convolve dy(?, ?, ?, ch) with pos mask(:, :, :, d) to get\n // dx(xD, xR, xC, ch).\n // ? = to be determined. : = across all values in that axis.\n var dotProd = 0.0;\n let lastIndex = uniforms.filterDims[0] * uniforms.filterDims[1] * uniforms.filterDims[2] - 1;\n\n for (var wD = 0; wD < uniforms.filterDims[0]; wD++) {\n let dyD = f32(dyDCorner + wD) / f32(uniforms.strides[0]);\n\n if (dyD < 0.0 || dyD >= f32(uniforms.outDepth) || fract(dyD) > 0.0) {\n continue;\n }\n let idyD = i32(dyD);\n\n for (var wR = 0; wR < uniforms.filterDims[1]; wR++) {\n let dyR = f32(dyRCorner + wR) / f32(uniforms.strides[1]);\n\n if (dyR < 0.0 || dyR >= f32(uniforms.outHeight) || fract(dyR) > 0.0) {\n continue;\n }\n let idyR = i32(dyR);\n\n for (var wC = 0; wC < uniforms.filterDims[2]; wC++) {\n let dyC = f32(dyCCorner + wC) / f32(uniforms.strides[2]);\n\n if (dyC < 0.0 || dyC >= f32(uniforms.outWidth) || fract(dyC) > 0.0) {\n continue;\n }\n let idyC = i32(dyC);\n\n let dyValue = getDy(batch, idyD, idyR, idyC, ch);\n let maxPosValue = lastIndex - i32(getMaxPos(batch, idyD, idyR, idyC, ch));\n\n // Get the current value, check it against the value from the\n // position matrix.\n let curPosValue = wD * uniforms.filterDims[1] * uniforms.filterDims[2] + wR * uniforms.filterDims[2] + wC;\n let mask = select(0.0, 1.0, maxPosValue == curPosValue);\n dotProd += dyValue * mask;\n }\n }\n }\n\n setOutputAtIndex(index, dotProd);\n }\n }\n `}};function kpe(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s}=t,a=s,{filterSize:i,strides:p,pad:u,dimRoundingMode:c}=o,l=[1,1,1],m=w.computePool3DInfo(a.shape,i,p,l,u,c),d=new _u(m,\"max\",!0),f=[{type:\"int32\",data:[m.strideDepth,m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.padInfo.front,m.padInfo.top,m.padInfo.left]},{type:\"int32\",data:[m.inDepth,m.inHeight,m.inWidth]},{type:\"int32\",data:[m.effectiveFilterDepth,m.effectiveFilterHeight,m.effectiveFilterWidth]}],h=e.runWebGPUProgram(d,[a],\"int32\",f),g=new Xx(m);f=[{type:\"int32\",data:[m.strideDepth,m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.effectiveFilterDepth-1-m.padInfo.front,m.effectiveFilterHeight-1-m.padInfo.top,m.effectiveFilterWidth-1-m.padInfo.left]},{type:\"int32\",data:[m.effectiveFilterDepth,m.effectiveFilterHeight,m.effectiveFilterWidth]},{type:\"int32\",data:[m.outDepth]},{type:\"int32\",data:[m.outHeight]},{type:\"int32\",data:[m.outWidth]}];let x=e.runWebGPUProgram(g,[n,h],a.dtype,f);return e.disposeData(h.dataId),x}var RW={kernelName:Ki,backendName:\"webgpu\",kernelFunc:kpe};function Npe(r){let{inputs:t,backend:e,attrs:o}=r,{dy:n,input:s,output:a}=t,i=s;fm([s,a],\"maxPoolGrad\");let{filterSize:p,strides:u,pad:c,dimRoundingMode:l}=o,m=w.computePool2DInfo(i.shape,p,u,1,c,l),d=new za(m,\"max\",!0),f=[{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.padInfo.top,m.padInfo.left]},{type:\"int32\",data:[m.dilationHeight,m.dilationWidth]},{type:\"int32\",data:[m.inHeight,m.inWidth]},{type:\"int32\",data:[m.effectiveFilterHeight,m.effectiveFilterWidth]}],h=e.runWebGPUProgram(d,[i],\"int32\",f),g=new jx(m);f=[{type:\"int32\",data:[m.strideHeight,m.strideWidth]},{type:\"int32\",data:[m.effectiveFilterHeight-1-m.padInfo.top,m.effectiveFilterWidth-1-m.padInfo.left]},{type:\"int32\",data:[m.dilationHeight,m.dilationWidth]},{type:\"int32\",data:[m.effectiveFilterHeight,m.effectiveFilterWidth]},{type:\"int32\",data:[m.outHeight]},{type:\"int32\",data:[m.outWidth]}];let x=e.runWebGPUProgram(g,[n,h],i.dtype,f);return e.disposeData(h.dataId),x}var DW={kernelName:Hi,backendName:\"webgpu\",kernelFunc:Npe};function Tpe(r){let{inputs:t,backend:e,attrs:o}=r,{filterSize:n,strides:s,pad:a,includeBatchInIndex:i}=o,{x:p}=t;y.assert(p.shape.length===4,()=>`Error in maxPool: input must be rank 4 but got rank ${p.shape.length}.`);let u=[1,1];y.assert(w.eitherStridesOrDilationsAreOne(s,u),()=>`Error in maxPool: Either strides or dilations must be 1. Got strides ${s} and dilations '${u}'`);let c=w.computePool2DInfo(p.shape,n,s,u,a),l=[{type:\"int32\",data:[c.strideHeight,c.strideWidth]},{type:\"int32\",data:[c.padInfo.top,c.padInfo.left]},{type:\"int32\",data:[c.dilationHeight,c.dilationWidth]},{type:\"int32\",data:[c.inHeight,c.inWidth]},{type:\"int32\",data:[c.effectiveFilterHeight,c.effectiveFilterWidth]}],m=new za(c,\"max\",!1),d=e.runWebGPUProgram(m,[p],p.dtype,l);m=new za(c,\"max\",!0,!0,i);let f=e.runWebGPUProgram(m,[p],\"int32\",l);return[d,f]}var AW={kernelName:ua,backendName:\"webgpu\",kernelFunc:Tpe};function _pe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;return eo(n,s,a,\"min\",e)}var FW={kernelName:Hn,backendName:\"webgpu\",kernelFunc:_pe};var $pe=et({opType:fe.MIN,cpuKernelImpl:Iz}),PW={kernelName:Kn,backendName:\"webgpu\",kernelFunc:$pe};var Yx=class{constructor(t,e,o){this.uniforms=\"\",this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e.map((n,s)=>n[0]+t[s]+n[1]),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.xShape=t,e.map((n,s)=>{this.uniforms+=` pad${s} : vec2,`}),this.offset=o===\"reflect\"?0:1,this.shaderKey=`mirrorPad_${o}`}getUserCode(){let t=this.xShape.length,e=this.xShape.map((u,c)=>`uniforms.pad${c}[0]`).join(\",\"),o=this.xShape.map((u,c)=>`uniforms.pad${c}[0] + uniforms.xShape${t>1?`[${c}]`:\"\"}`).join(\",\"),n=t===1?\"start\":\"start[i]\",s=t===1?\"end\":\"end[i]\",a=t===1?\"outC\":\"outC[i]\",i=ht(t),p=t>1?[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,t):\"coords\";return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let start = ${i}(${e});\n let end = ${i}(${o});\n var outC = getCoordsFromIndex(index);\n for (var i = 0; i < ${t}; i = i + 1) {\n if (${a} < ${n}) {\n ${a} = ${n} * 2 - ${a} - ${this.offset};\n } else if(${a} >= ${s}) {\n ${a} = (${s} - 1) * 2 - ${a} + ${this.offset};\n }\n }\n let coords = outC - start;\n setOutputAtIndex(index, getX(${p}));\n }\n }\n `}};var OW={kernelName:qn,backendName:\"webgpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{x:o}=r,{paddings:n,mode:s}=t,a=e,i=n.map(c=>({type:\"int32\",data:[c[0],c[1]]})),p=new Yx(o.shape,n,s);return a.runWebGPUProgram(p,[o],o.dtype,i)}};var Epe=et({opType:fe.MOD}),MW={kernelName:jn,backendName:\"webgpu\",kernelFunc:Epe};var Qx=class{constructor(t,e){this.variableNames=[\"probs\"],this.outputShape=[],this.uniforms=\"seed : f32, numOutcomes: i32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t,e],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"multinomial\"}getUserCode(){return`\n //Based on the work of Dave Hoskins\n //https://www.shadertoy.com/view/4djSRW\n fn random (seed : f32, resultUV : vec2) -> f32 {\n let HASHSCALE1 = 443.8975;\n let p = resultUV * seed;\n var p3 = fract(vec3(p.xyx) * HASHSCALE1);\n p3 = p3 + dot(p3, p3.yzx + 19.19);\n return fract((p3.x + p3.y) * p3.z);\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let batch = coords[0];\n\n let resUV = vec2(f32(coords[1]) / f32(uniforms.outShape[1]),\n f32(coords[0]) / f32(uniforms.outShape[0]));\n let r = random(uniforms.seed, resUV);\n var cdf = 0.0;\n for (var i = 0; i < uniforms.numOutcomes - 1; i = i + 1) {\n cdf = cdf + getProbs(batch, i);\n\n if (r < cdf) {\n setOutputAtIndexI32(index, i);\n return;\n }\n }\n\n // If no other event happened, last event happened.\n setOutputAtIndexI32(index, uniforms.numOutcomes - 1);\n }\n }\n `}};var Zx=class{constructor(t){this.variableNames=[\"logits\"],this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=[this.outputShape[0],1,1],this.outputShape[1]>=4096?this.workgroupSize=[256,1,1]:this.workgroupSize=[64,1,1],this.shaderKey=\"softmax\"}getUserCode(){return`\n var buf : array;\n var rowMaxShared : f32;\n var rowSumShared : f32;\n const blockSize = ${this.workgroupSize[0]};\n ${G(\"index\")} {\n let row = index / blockSize;\n let tid = i32(localId.x);\n let cols = uniforms.outShape[1];\n\n var threadMax = -3.402823e+38f;\n for (var col = tid; col < cols; col += blockSize) {\n let value = getLogits(row, col);\n threadMax = max(threadMax, value);\n }\n if (tid < cols) {\n buf[tid] = threadMax;\n }\n workgroupBarrier();\n\n var reduceSize = min(cols, blockSize);\n for (var currSize = reduceSize >> 1; currSize > 0; currSize = reduceSize >> 1) {\n reduceSize = currSize + (reduceSize & 1);\n if (tid < currSize) {\n buf[tid] = max(buf[tid], buf[tid + reduceSize]);\n }\n workgroupBarrier();\n }\n\n if (tid == 0) {\n rowMaxShared = buf[0];\n }\n workgroupBarrier();\n\n var threadSum = 0.0;\n for (var col = tid; col < cols; col += blockSize) {\n let subExp = exp(getLogits(row, col) - rowMaxShared);\n threadSum += subExp;\n }\n buf[tid] = threadSum;\n workgroupBarrier();\n\n for (var currSize = blockSize >> 1; currSize > 0; currSize = currSize >> 1) {\n if (tid < currSize) {\n buf[tid] = buf[tid] + buf[tid + currSize];\n }\n workgroupBarrier();\n }\n\n if (tid == 0) {\n rowSumShared = buf[0];\n }\n workgroupBarrier();\n\n for (var col = tid; col < cols; col += blockSize) {\n let value = exp(getLogits(row, col) - rowMaxShared) / rowSumShared;\n setOutputAtCoords(row, col, value);\n }\n }\n `}};function p0(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{dim:s}=o,a=pe({inputs:{x:n},backend:e,attrs:{shape:[y.sizeFromShape(n.shape)/n.shape[s],n.shape[s]]}}),i=new Zx(a.shape),p=e.runWebGPUProgram(i,[a],n.dtype),u=pe({inputs:{x:p},backend:e,attrs:{shape:n.shape}});return e.disposeData(a.dataId),e.disposeData(p.dataId),u}var LW={kernelName:vs,backendName:\"webgpu\",kernelFunc:p0};function Rpe(r){let{inputs:t,backend:e,attrs:o}=r,{logits:n}=t,{numSamples:s,seed:a,normalized:i}=o,p=i?n:p0({inputs:{logits:n},backend:e,attrs:{dim:n.shape.length-1}}),u=p.shape[0],c=p.shape[1],l=new Qx(u,s),m=[{type:\"float32\",data:[a]},{type:\"int32\",data:[c]}],d=e.runWebGPUProgram(l,[p],\"int32\",m);return i||e.disposeData(p.dataId),d}var BW={kernelName:Xn,backendName:\"webgpu\",kernelFunc:Rpe};function Dpe(r){let{inputs:t,backend:e}=r,{x:o}=t;if(e.shouldExecuteOnCPU([o])){let s=e.tensorMap.get(o.dataId),[a,i]=kz(s.values,o.shape,o.dtype);return e.makeTensorInfo(i,o.dtype,a)}let n=new Jr(o.shape,Z.NEG);return e.runWebGPUProgram(n,[o],o.dtype)}var zW={kernelName:pa,backendName:\"webgpu\",kernelFunc:Dpe};function Ape(r){console.warn(\"tf.nonMaxSuppression() in webgpu locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p}=o,u=e.readSync(n.dataId),c=e.readSync(s.dataId),{selectedIndices:l}=Wt.nonMaxSuppressionV3Impl(u,c,a,i,p);return e.makeTensorInfo([l.length],\"int32\",new Int32Array(l))}var VW={kernelName:Zn,backendName:\"webgpu\",kernelFunc:Ape};function Fpe(r){console.warn(\"tf.nonMaxSuppression() in webgpu locks the UI thread. Call tf.nonMaxSuppressionAsync() instead\");let{inputs:t,backend:e,attrs:o}=r,{boxes:n,scores:s}=t,{maxOutputSize:a,iouThreshold:i,scoreThreshold:p,softNmsSigma:u}=o,c=e.readSync(n.dataId),l=e.readSync(s.dataId),m=a,d=i,f=p,h=u,{selectedIndices:g,selectedScores:x}=Wt.nonMaxSuppressionV5Impl(c,l,m,d,f,h);return[e.makeTensorInfo([g.length],\"int32\",new Int32Array(g)),e.makeTensorInfo([x.length],\"float32\",new Float32Array(x))]}var WW={kernelName:Jn,backendName:\"webgpu\",kernelFunc:Fpe};var Jx=class{constructor(t,e){this.variableNames=[\"x\"],this.uniforms=\"onValue : f32, offValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t,e],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"onehot\"}getUserCode(){return`\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n setOutputAtIndex(index, mix(uniforms.offValue, uniforms.onValue,\n f32(i32(round(getX(coords.x))) == coords.y)));\n }\n }\n `}};function Ppe(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n}=t,{dtype:s,depth:a,onValue:i,offValue:p}=o,u=y.sizeFromShape(n.shape),c=new Jx(u,a),l=pe({inputs:{x:n},backend:e,attrs:{shape:[u]}}),m=[{type:\"float32\",data:[i]},{type:\"float32\",data:[p]}],d=e.runWebGPUProgram(c,[l],s,m);e.disposeData(l.dataId);let f=[...n.shape,a],h=pe({inputs:{x:d},backend:e,attrs:{shape:f}});return e.disposeData(d.dataId),h}var UW={kernelName:es,backendName:\"webgpu\",kernelFunc:Ppe};function bm(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"complex64\"){let n=Ni({inputs:{input:o},backend:e}),s=bm({inputs:{x:n},backend:e}),a=Mp({inputs:{input:o},backend:e}),i=bm({inputs:{x:a},backend:e}),p=yo({inputs:{real:s,imag:i},backend:e});return e.disposeData(n.dataId),e.disposeData(s.dataId),e.disposeData(a.dataId),e.disposeData(i.dataId),p}else return kt({attrs:{shape:o.shape,dtype:o.dtype,value:o.dtype===\"string\"?\"\":0},backend:e})}var GW={kernelName:Sa,backendName:\"webgpu\",kernelFunc:bm};function HW(r){let{inputs:t,backend:e}=r,{x:o}=t;if(o.dtype===\"string\")throw new Error(\"onesLike is not supported under string dtype\");if(o.dtype===\"complex64\"){let n=Ni({inputs:{input:o},backend:e}),s=HW({inputs:{x:n},backend:e}),a=Mp({inputs:{input:o},backend:e}),i=bm({inputs:{x:a},backend:e}),p=yo({inputs:{real:s,imag:i},backend:e});return e.disposeData(n.dataId),e.disposeData(s.dataId),e.disposeData(a.dataId),e.disposeData(i.dataId),p}else return kt({attrs:{shape:o.shape,dtype:o.dtype,value:1},backend:e})}var KW={kernelName:ca,backendName:\"webgpu\",kernelFunc:HW};function Ope(r){let{inputs:t,backend:e,attrs:o}=r,{axis:n}=o;if(t.length===1)return Mx({inputs:{input:t[0]},backend:e,attrs:{dim:n}});let s=t[0].shape,a=t[0].dtype;t.forEach(c=>{y.assertShapesMatch(s,c.shape,\"All tensors passed to stack must have matching shapes\"),y.assert(a===c.dtype,()=>\"All tensors passed to stack must have matching dtypes\")});let i=[],p=t.map(c=>{let l=Mx({inputs:{input:c},backend:e,attrs:{dim:n}});return i.push(l),l}),u=n0({inputs:p,backend:e,attrs:{axis:n}});return i.forEach(c=>e.disposeData(c.dataId)),u}var qW={kernelName:la,backendName:\"webgpu\",kernelFunc:Ope};function c0(r,t=!1){let e=r.length,o=ht(e),n=r.map((l,m)=>`uniforms.pad${m}[0]`).join(\",\"),s=r.map((l,m)=>`uniforms.pad${m}[0] + uniforms.xShape${e>1?`[${m}]`:\"\"}`).join(\",\"),a=e>1?`${o}(${n})`:`${n}`,i=e>1?`${o}(${s})`:`${s}`,p=e>1?\"any(paddedCoords < start)\":\"paddedCoords < start\",u=e>1?\"any(paddedCoords >= end)\":\"paddedCoords >= end\",c=e>1?[\"coords[0]\",\"coords[1]\",\"coords[2]\",\"coords[3]\"].slice(0,e):\"coords\";return`\n let start = ${a};\n let end = ${i};\n if (${p} || ${u}) {\n setOutputAtIndex(index, ${t?0:\"uniforms.constantValue\"});\n } else {\n let coords = paddedCoords - start;\n setOutputAtIndex(index, getX(${c}));\n }\n `}var ey=class{constructor(t,e){this.variableNames=[\"x\"],this.uniforms=\"constantValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e.map((o,n)=>o[0]+t[n]+o[1]),this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),e.map((o,n)=>{this.uniforms+=` pad${n} : vec2,`}),this.xShape=t,this.shaderKey=\"pad\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let paddedCoords = getCoordsFromIndex(index);\n ${c0(this.xShape)}\n }\n }\n `}};var Mpe=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{paddings:s,constantValue:a}=o;if(s.every(u=>y.arraysEqual(u,[0,0])))return Ft({inputs:{x:n},backend:e});if(y.sizeFromShape(n.shape)===0){let u=s.map((c,l)=>c[0]+n.shape[l]+c[1]);return kt({backend:e,attrs:{shape:u,value:a,dtype:n.dtype}})}let i=[{type:\"float32\",data:[a]}];s.map(u=>i.push({type:\"int32\",data:[u[0],u[1]]}));let p=new ey(n.shape,s);return e.runWebGPUProgram(p,[n],n.dtype,i)},jW={kernelName:ts,backendName:\"webgpu\",kernelFunc:Mpe};var Lpe=et({opType:fe.POW}),XW={kernelName:rs,backendName:\"webgpu\",kernelFunc:Lpe};function Bpe(r){let{inputs:t,backend:e}=r,{x:o,alpha:n}=t,s=new ki(fe.PRELU,o.shape,n.shape);return e.runWebGPUProgram(s,[o,n],\"float32\")}var YW={kernelName:os,backendName:\"webgpu\",kernelFunc:Bpe};function zpe(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{axis:s,keepDims:a}=o;return eo(n,s,a,\"prod\",e)}var QW={kernelName:ns,backendName:\"webgpu\",kernelFunc:zpe};var Vpe=r=>{let{backend:t,attrs:e}=r,{start:o,stop:n,step:s,dtype:a}=e,i=_z(o,n,s,a);return t.makeTensorInfo([i.length],a,i)},ZW={kernelName:ma,backendName:\"webgpu\",kernelFunc:Vpe};var Wpe=et({opType:fe.DIV}),JW={kernelName:hn,backendName:\"webgpu\",kernelFunc:Wpe};var Upe=ye({opType:Z.RECIPROCAL}),eU={kernelName:ss,backendName:\"webgpu\",kernelFunc:Upe};var Gpe=ye({opType:Z.RELU}),tU={kernelName:as,backendName:\"webgpu\",kernelFunc:Gpe};var Hpe=ye({opType:Z.RELU6}),rU={kernelName:ps,backendName:\"webgpu\",kernelFunc:Hpe};var ty=class{constructor(t,e,o){this.variableNames=[\"x\"],this.uniforms=\"adjustHeightWidth : vec2, halfPixelCenters : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t[0],e,o,t[3]],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"resizeBilinear\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let b = coords[0];\n let d = coords[3];\n let rc = coords.yz;\n\n let effectiveInSize = vec2(\n f32(uniforms.xShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.xShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveOutSize = vec2(\n f32(uniforms.outShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.outShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveInputOverOutputRatioRC =\n effectiveInSize / effectiveOutSize;\n\n // Fractional source index\n let sourceFracIndexRC =\n (vec2(rc) + vec2(uniforms.halfPixelCenters)) *\n effectiveInputOverOutputRatioRC - vec2(uniforms.halfPixelCenters);\n\n // Compute the four integer indices.\n let sourceFloorRC = vec2(sourceFracIndexRC);\n let sourceCeilRC = vec2(\n min(vec2(uniforms.xShape.yz) - vec2(1.0), ceil(sourceFracIndexRC)));\n\n let topLeft = getX(b, sourceFloorRC.x, sourceFloorRC.y, d);\n let bottomLeft = getX(b, sourceCeilRC.x, sourceFloorRC.y, d);\n let topRight = getX(b, sourceFloorRC.x, sourceCeilRC.y, d);\n let bottomRight = getX(b, sourceCeilRC.x, sourceCeilRC.y, d);\n\n let fracRC = sourceFracIndexRC - vec2(sourceFloorRC);\n\n let top = topLeft + (topRight - topLeft) * fracRC.y;\n let bottom = bottomLeft + (bottomRight - bottomLeft) * fracRC.y;\n let newValue = top + (bottom - top) * fracRC.x;\n\n setOutputAtIndex(index, newValue);\n }\n }\n `}};function Kpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,size:a,halfPixelCenters:i}=o,[p,u]=a,c=s&&p>1?1:0,l=s&&u>1?1:0,d=[{type:\"float32\",data:[c,l]},{type:\"float32\",data:[i?.5:0]}],f=new ty(n.shape,p,u);return e.runWebGPUProgram(f,[n],\"float32\",d)}var oU={kernelName:us,backendName:\"webgpu\",kernelFunc:Kpe};var ry=class{constructor(t,e){this.variableNames=[\"dy\"],this.uniforms=`effectiveXSize : vec2, effectiveYSize : vec2, heightScale : f32, widthScale : f32,\n invHeightScale : f32, invWidthScale : f32, winHeight : i32, winWidth : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.alignCorners=e,this.shaderKey=`resizeBilinearBackprop_${e}`}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let d = coords[3];\n let r = coords[1];\n let c = coords[2];\n\n var accumulator = 0.0;\n\n // Compute bounds for where in dy we will look\n let startRLerp = floor(f32(r) * uniforms.invHeightScale);\n let startDyR = i32(startRLerp - f32(uniforms.winHeight / 2));\n\n let startCLerp = floor(f32(c) * uniforms.invWidthScale);\n let startDyC = i32(startCLerp - f32(uniforms.winWidth / 2));\n\n // Loop over dy\n for (var dyROffset = 0; dyROffset < uniforms.winHeight; dyROffset++) {\n let dyR = startDyR + dyROffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= uniforms.dyShape[1]) {\n continue;\n }\n\n for (var dyCOffset = 0; dyCOffset < uniforms.winWidth; dyCOffset++) {\n let dyC = startDyC + dyCOffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= uniforms.dyShape[2]) {\n continue;\n }\n\n let dxR = f32(dyR) * uniforms.heightScale;\n let topDxRIndex = i32(floor(dxR));\n let bottomDxRIndex = i32(min(ceil(dxR), f32(uniforms.outShape[1] - 1)));\n let dxRLerp = dxR - f32(topDxRIndex);\n let inverseDxRLerp = 1.0 - dxRLerp;\n\n let dxC = f32(dyC) * uniforms.widthScale;\n let leftDxCIndex = i32(floor(dxC));\n let rightDxCIndex = i32(min(ceil(dxC), f32(uniforms.outShape[2] - 1)));\n let dxCLerp = dxC - f32(leftDxCIndex);\n let inverseDxCLerp = 1.0 - dxCLerp;\n\n if (r == topDxRIndex && c == leftDxCIndex) {\n // topLeft\n accumulator +=\n getDy(b, dyR, dyC, d) * inverseDxRLerp * inverseDxCLerp;\n }\n\n if (r == topDxRIndex && c == rightDxCIndex) {\n // topRight\n accumulator += getDy(b, dyR, dyC, d) * inverseDxRLerp * dxCLerp;\n }\n\n if (r == bottomDxRIndex && c == leftDxCIndex) {\n // bottomLeft\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * inverseDxCLerp;\n }\n\n if (r == bottomDxRIndex && c == rightDxCIndex) {\n // bottomRight\n accumulator += getDy(b, dyR, dyC, d) * dxRLerp * dxCLerp;\n }\n }\n }\n // End loop over dy\n\n setOutputAtIndex(index, accumulator);\n }\n }\n `}};function qpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,[,i,p]=n.shape,[,u,c]=s.shape,l=[a&&u>1?i-1:i,a&&c>1?p-1:p],m=[a&&u>1?u-1:u,a&&c>1?c-1:c],d=l[0]/m[0],f=l[1]/m[1],h=1/d,g=1/f,x=Math.ceil(h)*2+2,b=Math.ceil(g)*2+2,C=new ry(n.shape,a),S=[{type:\"int32\",data:l},{type:\"int32\",data:m},{type:\"float32\",data:[d]},{type:\"float32\",data:[f]},{type:\"float32\",data:[h]},{type:\"float32\",data:[g]},{type:\"int32\",data:[x]},{type:\"int32\",data:[b]}];return e.runWebGPUProgram(C,[s],s.dtype,S)}var nU={kernelName:ei,backendName:\"webgpu\",kernelFunc:qpe};var oy=class{constructor(t,e,o,n){this.variableNames=[\"x\"],this.uniforms=\"adjustHeightWidth : vec2, roundBase : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=[t[0],e,o,t[3]],this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.halfPixelCenters=n,this.shaderKey=`resizeNearest_${n}`}getUserCode(){let t;return this.halfPixelCenters?t=\"max((vec2(rc) + vec2(0.5)) * effectiveInputOverOutputRatioRC, vec2(0.0))\":t=\"vec2(rc) * effectiveInputOverOutputRatioRC\",`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let b = coords[0];\n let d = coords[3];\n let rc = coords.yz;\n\n let effectiveInSize = vec2(\n f32(uniforms.xShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.xShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveOutSize = vec2(\n f32(uniforms.outShape.y) - uniforms.adjustHeightWidth[0],\n f32(uniforms.outShape.z) - uniforms.adjustHeightWidth[1]);\n\n let effectiveInputOverOutputRatioRC =\n effectiveInSize / effectiveOutSize;\n\n // Fractional source index\n let sourceFracIndexRC = ${t};\n\n // Compute the coordinators of nearest neighbor point.\n let inputShapeRC = vec2(f32(uniforms.xShape.y), f32(uniforms.xShape.z));\n let sourceNearestRC = vec2(\n min(inputShapeRC - 1.0, floor(sourceFracIndexRC + uniforms.roundBase)));\n let newValue = getX(b, sourceNearestRC.x, sourceNearestRC.y, d);\n\n setOutputAtIndex(index, newValue);\n }\n }\n `}};function jpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n}=t,{alignCorners:s,halfPixelCenters:a,size:i}=o,[p,u]=i,c=s&&p>1?1:0,l=s&&u>1?1:0,d=[{type:\"float32\",data:[c,l]},{type:\"float32\",data:[s?.5:0]}],f=new oy(n.shape,p,u,a);return e.runWebGPUProgram(f,[n],n.dtype,d)}var sU={kernelName:is,backendName:\"webgpu\",kernelFunc:jpe};var ny=class{constructor(t,e){this.variableNames=[\"dy\"],this.uniforms=`effectiveXSize : vec2, effectiveYSize : vec2, invHeightScale : f32, invWidthScale : f32,\n winHeight : i32, winWidth : i32,`,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.alignCorners=e,this.shaderKey=`resizeNearestNeigborBackprop_${e}`}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getOutputCoords();\n let b = coords[0];\n let d = coords[3];\n let r = coords[1];\n let c = coords[2];\n\n var accumulator = 0.0;\n\n // Compute bounds for where in dy we will look\n let startRLerp = floor(f32(r) * uniforms.invHeightScale);\n let startDyR = i32(floor(startRLerp - f32(uniforms.winHeight / 2)));\n\n let startCLerp = floor(f32(c) * uniforms.invWidthScale);\n let startDyC = i32(floor(startCLerp - f32(uniforms.winWidth / 2)));\n\n // Loop over dy\n for (var dyROffset = 0; dyROffset < uniforms.winHeight; dyROffset++) {\n let dyR = startDyR + dyROffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyR < 0 || dyR >= uniforms.dyShape[1]) {\n continue;\n }\n\n for (var dyCOffset = 0; dyCOffset < uniforms.winWidth; dyCOffset++) {\n let dyC = startDyC + dyCOffset;\n\n // Guard against the window exceeding the bounds of dy\n if (dyC < 0 || dyC >= uniforms.dyShape[2]) {\n continue;\n }\n\n let sourceFracRow = f32(uniforms.effectiveXSize[0]) *\n (f32(dyR) / f32(uniforms.effectiveYSize[0]));\n\n let sourceFracCol = f32(uniforms.effectiveXSize[1]) *\n (f32(dyC) / f32(uniforms.effectiveYSize[1]));\n\n let sourceNearestRow =\n i32(min(f32(uniforms.outShape[1] - 1),\n ${this.alignCorners?\"floor(sourceFracRow + 0.5)\":\"floor(sourceFracRow)\"}));\n\n let sourceNearestCol =\n i32(min(f32(uniforms.outShape[2] - 1),\n ${this.alignCorners?\"floor(sourceFracCol + 0.5)\":\"floor(sourceFracCol)\"}));\n\n if (r == sourceNearestRow && c == sourceNearestCol) {\n accumulator += getDy(b, dyR, dyC, d);\n }\n }\n }\n // End loop over dy\n\n setOutputAtIndex(index, accumulator);\n }\n }\n `}};function Xpe(r){let{inputs:t,backend:e,attrs:o}=r,{images:n,dy:s}=t,{alignCorners:a}=o,[,i,p]=n.shape,[,u,c]=s.shape,l=[a&&u>1?i-1:i,a&&c>1?p-1:p],m=[a&&u>1?u-1:u,a&&c>1?c-1:c],d=l[0]/m[0],f=l[1]/m[1],h=1/d,g=1/f,x=Math.ceil(h)*2+2,b=Math.ceil(g)*2+2,C=new ny(n.shape,a),S=[{type:\"int32\",data:l},{type:\"int32\",data:m},{type:\"float32\",data:[h]},{type:\"float32\",data:[g]},{type:\"int32\",data:[x]},{type:\"int32\",data:[b]}];return e.runWebGPUProgram(C,[s],s.dtype,S)}var aU={kernelName:Ja,backendName:\"webgpu\",kernelFunc:Xpe};var sy=class{constructor(t){this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=\" axis : vec4,\",this.shaderKey=\"reverse\"}getUserCode(){return`\n \n // Using uniform variables as judging conditions, so the function has\n // coherent execution within all threads.\n fn getReverseCoords(coords : vec4) -> vec4 {\n var reverseCoords = coords;\n if (uniforms.axis[0] == 1) {\n reverseCoords[0] = uniforms.xShape[0] - coords[0] - 1;\n }\n if (uniforms.axis[1] == 1) {\n reverseCoords[1] = uniforms.xShape[1] - coords[1] - 1;\n }\n if (uniforms.axis[2] == 1) {\n reverseCoords[2] = uniforms.xShape[2] - coords[2] - 1;\n }\n if (uniforms.axis[3] == 1) {\n reverseCoords[3] = uniforms.xShape[3] - coords[3] - 1;\n }\n\n return reverseCoords;\n }\n \n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let reverseCoords = getReverseCoords(coords);\n setOutputAtIndex(index, getX(reverseCoords[0],\n reverseCoords[1], reverseCoords[2], reverseCoords[3]));\n }\n }\n `}};function Ype(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{dims:s}=o,a=n.shape.length;if(a===0)return Ft({inputs:{x:n},backend:e});let i=n.shape,p=[1,1,1,1];i.forEach((g,x)=>{let b=x+4-a;p[b]=g});let u=y.parseAxisParam(s,n.shape),c=[0,0,0,0];u.forEach(g=>{let x=g+4-a;c[x]=1});let l=[{type:\"int32\",data:c}],m=pe({inputs:{x:n},backend:e,attrs:{shape:p}}),d=new sy(p),f=e.runWebGPUProgram(d,[m],m.dtype,l);e.disposeData(m.dataId);let h=pe({inputs:{x:f},backend:e,attrs:{shape:i}});return e.disposeData(f.dataId),h}var iU={kernelName:cs,backendName:\"webgpu\",kernelFunc:Ype};var ay=class{constructor(t,e){this.outputShape=[],this.variableNames=[\"x\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=`centerX : f32, centerY : f32, sinRadians : f32,\n cosRadians : f32,`,this.shaderKey=\"rotate\",this.outputShape=t,typeof e==\"number\"?(this.uniforms+=\" fillValue : f32,\",this.fillSnippet=\"var outputValue = uniforms.fillValue;\",this.shaderKey+=\"_float\"):(this.uniforms+=\" fillValue : vec3,\",this.fillSnippet=\"var outputValue = uniforms.fillValue[coords[3]];\",this.shaderKey+=\"_vec3\")}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let coordXFloat = (f32(coords[2]) - uniforms.centerX) *\n uniforms.cosRadians - (f32(coords[1]) - uniforms.centerY) *\n uniforms.sinRadians;\n let coordYFloat = (f32(coords[2]) - uniforms.centerX) *\n uniforms.sinRadians + (f32(coords[1]) - uniforms.centerY) *\n uniforms.cosRadians;\n let coordX = i32(round(coordXFloat + uniforms.centerX));\n let coordY = i32(round(coordYFloat + uniforms.centerY));\n ${this.fillSnippet}\n if(coordX >= 0 && coordX < uniforms.xShape[2] && coordY >= 0 &&\n coordY < uniforms.xShape[1]) {\n outputValue = getX(coords[0], coordY, coordX, coords[3]);\n }\n setOutputAtIndex(index, outputValue);\n }\n }\n `}};var uU={kernelName:As,backendName:\"webgpu\",kernelFunc:({inputs:r,attrs:t,backend:e})=>{let{image:o}=r,{radians:n,fillValue:s,center:a}=t,i=e,p=new ay(o.shape,s),[u,c]=w.getImageCenter(a,o.shape[1],o.shape[2]),l=[{type:\"float32\",data:[u]},{type:\"float32\",data:[c]},{type:\"float32\",data:[Math.sin(n)]},{type:\"float32\",data:[Math.cos(n)]}];return typeof s==\"number\"?l.push({type:\"float32\",data:[Number.parseFloat(s.toFixed(2))]}):l.push({type:\"float32\",data:s}),i.runWebGPUProgram(p,[o],o.dtype,l)}};var Qpe=ye({opType:Z.ROUND}),pU={kernelName:ls,backendName:\"webgpu\",kernelFunc:Qpe};var Zpe=ye({opType:Z.RSQRT,cpuKernelImpl:$z}),cU={kernelName:ms,backendName:\"webgpu\",kernelFunc:Zpe};var Va=class{constructor(t,e,o,n,s,a,i,p=!0){this.variableNames=[\"updates\",\"indices\"],this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=a,this.type=i,this.sumDupeIndices=p,this.dispatchLayout=X(t),this.dispatch=H(this.dispatchLayout,t,this.workgroupSize),this.sliceDimGreaterThanOne=e>1,this.shaderKey=`scatter_${o}_${n}_${this.sliceDimGreaterThanOne}_${i}_${p}`;let u=ht(s.length);this.uniforms=`sliceDim : i32, strides: ${u}, updatesSize: i32,`,this.updatesRank=n,this.indicesRank=o}getUserCode(){let t=\"\";this.indicesRank===1?t=\"coords[0]\":this.indicesRank===2&&(t=\"coords[0], j\");let e=`getIndices(${t})`,o=this.sliceDimGreaterThanOne?\"uniforms.strides[j]\":\"uniforms.strides\",n=\"\",s=\"\";this.dispatchLayout.x.length===1?(n=\"flattenedIndex\",s=`\n fn getUpdatesCoordsFromFlatIndex(index : i32) -> i32 {\n return index;\n }\n `):this.dispatchLayout.x.length===2&&(n=\"vec2(flattenedIndex, coords[1])\",s=`\n fn getUpdatesCoordsFromFlatIndex(index : i32) -> vec2 {\n // N.B. |updates| could be a scalar tensor, conceptually representing a\n // 2D tensor with all values equal to that. By design, its size must be\n // the same as |outShape[1]| in one dimension, and |indicesShape[0]|\n // gives the other.\n let sliceSize = uniforms.outShape[1];\n let d0 = index / sliceSize;\n let d1 = index - d0 * sliceSize;\n return vec2(d0, d1);\n }\n `);let i=`getUpdates(${Array.from({length:this.updatesRank},(u,c)=>`coords[${c}]`).join(\", \")})`;return`\n ${s}\n ${G(\"index\")} {\n if (index < uniforms.updatesSize) {\n let coords = getUpdatesCoordsFromFlatIndex(index);\n var flattenedIndex = 0;\n for (var j = 0; j < uniforms.sliceDim; j = j + 1) {\n let indexInside = i32(round(${e}));\n flattenedIndex = flattenedIndex + indexInside * ${o};\n }\n let updateValue =\n ${Nu(this.type)}(${i});\n let flatIndex = getOutputIndexFromCoords(${n});\n\n ${this.sumDupeIndices?Qr(\"&result[flatIndex]\",\"updateValue\",this.type):\"atomicStore(&result[flatIndex], bitcast(updateValue));\"}\n }\n }`}};function Jpe(r){let{inputs:t,backend:e,attrs:o}=r,{indices:n,updates:s}=t,{shape:a}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(s,n,a),m=[l/u,u];if(l===0)return e.makeTensorInfo(a,n.dtype);let d=pe({inputs:{x:n},backend:e,attrs:{shape:[p,i]}}),f=pe({inputs:{x:s},backend:e,attrs:{shape:[p,u]}}),h=f.dtype,g=kt({backend:e,attrs:{shape:m,value:0,dtype:h}}),x=y.sizeFromShape(f.shape),b=[{type:\"int32\",data:[i]},{type:\"int32\",data:c},{type:\"int32\",data:[x]}],C=new Va(f.shape,i,d.shape.length,f.shape.length,c,m,h),S=e.runWebGPUProgram(C,[f,d],h,b,g),k=pe({inputs:{x:S},backend:e,attrs:{shape:a}});return e.disposeData(d.dataId),e.disposeData(f.dataId),e.disposeData(S.dataId),k}var lU={kernelName:ds,backendName:\"webgpu\",kernelFunc:Jpe};var iy=class{constructor(t,e){this.outputShape=[],this.variableNames=[\"sortedSequence\",\"values\"],this.uniforms=\"numInputs : i32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.side=e,this.shaderKey=`search_sorted_${e}`}getUserCode(){return`\n fn findBound(batch: i32, value: f32) -> i32 {\n var left = i32(0);\n var right = uniforms.numInputs;\n while (left < right) {\n var mid = (left + right) / 2;\n if (getSortedSequence(batch, mid) ${this.side===\"left\"?\"<\":\"<=\"} value) {\n left = mid + 1;\n } else {\n right = mid;\n }\n }\n return right;\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let value = getValuesByOutputIndex(index);\n setOutputAtIndexI32(index, findBound(coords[0], value));\n }\n }\n `}};function ece(r){let{inputs:t,backend:e,attrs:o}=r,{sortedSequence:n,values:s}=t,{side:a}=o,i=new iy([s.shape[0],s.shape[1]],a),p=[{type:\"int32\",data:[n.shape[1]]}];return e.runWebGPUProgram(i,[n,s],\"int32\",p)}var mU={kernelName:hs,backendName:\"webgpu\",kernelFunc:ece};var uy=class{constructor(t,e,o){this.variableNames=[\"c\",\"a\",\"b\"],this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=e,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.cRank=t,this.rank=o,this.shaderKey=\"select\"}getUserCode(){let t,e;if(this.rank>4)throw Error(`Where for rank ${this.rank} is not yet supported`);if(this.rank===1)e=\"resRC\",t=\"resRC\";else{let n=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],s=[],a=[];for(let i=0;i= 1.0) {\n setOutputAtIndex(index, getA(${e}));\n } else {\n setOutputAtIndex(index, getB(${e}));\n }\n }\n }\n `}};function tce(r){let{inputs:t,backend:e}=r,{condition:o,t:n,e:s}=t,a=new uy(o.shape.length,n.shape,n.shape.length);return e.runWebGPUProgram(a,[o,n,s],dt(n.dtype,s.dtype))}var dU={kernelName:fa,backendName:\"webgpu\",kernelFunc:tce};var rce=ye({opType:Z.SELU}),fU={kernelName:gs,backendName:\"webgpu\",kernelFunc:rce};var oce=ye({opType:Z.SIGMOID}),hU={kernelName:Cs,backendName:\"webgpu\",kernelFunc:oce};var nce=ye({opType:Z.SIGN}),gU={kernelName:bs,backendName:\"webgpu\",kernelFunc:nce};var sce=ye({opType:Z.SIN}),xU={kernelName:xs,backendName:\"webgpu\",kernelFunc:sce};var ace=ye({opType:Z.SINH}),yU={kernelName:ys,backendName:\"webgpu\",kernelFunc:ace};var ice=ye({opType:Z.SOFTPLUS}),bU={kernelName:ws,backendName:\"webgpu\",kernelFunc:ice};var py=class{constructor(t,e,o,n,s,a){this.variableNames=[\"x\"],this.outputShape=[],this.uniforms=\"\",this.workgroupSize=[64,1,1],this.size=!0;let i=new Array(n.length);for(let p=0;p{this.uniforms+=` pad${u} : vec2,`}),this.shaderKey=`spaceToBatchND_${s}`}getUserCode(){let t=ht(this.outputShape.length),e=Zv(this.newDim);return`\n ${cm(this.paddedXShape,\"PaddedX\")}\n ${G(\"index\")} {\n if(index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n let switchedIndex = getIndexFromCoords${this.outputShape.length}D(${t}(${e}), uniforms.reshapedPaddedXShape);\n let paddedCoords = getPaddedXCoordsFromIndex(switchedIndex);\n ${c0(this.xShape,!0)}\n }\n }\n `}};var uce=r=>{let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{blockShape:s,paddings:a}=o;y.assert(n.shape.length<=4,()=>\"spaceToBatchND for rank > 4 with a WebGPU backend not implemented yet\");let i=s.reduce((b,C)=>b*C),p=[[0,0]];p.push(...a);for(let b=1+s.length;bb[0]+n.shape[C]+b[1]),c=w.getReshaped(u,s,i,!1),l=w.getPermuted(c.length,s.length,!1),m=w.getReshapedPermuted(u,s,i,!1),d=y.computeStrides(u),f=new py(n.shape,u,p,c,l,d.length),h=[{type:\"int32\",data:c},{type:\"int32\",data:d}];p.map(b=>h.push({type:\"int32\",data:[b[0],b[1]]}));let g=e.runWebGPUProgram(f,[n],n.dtype,h),x=pe({inputs:{x:g},backend:e,attrs:{shape:m}});return e.disposeData(g.dataId),x},CU={kernelName:ga,backendName:\"webgpu\",kernelFunc:uce};var cy=class{constructor(t,e,o){this.variableNames=[\"input\",\"indices\",\"segmentIds\"],this.outputShape=[],this.uniforms=\"segmentSize : i32, sparseSize : i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=t,this.type=o,this.dispatchLayout=X([e]),this.dispatch=H(this.dispatchLayout,[e],this.workgroupSize),this.shaderKey=\"sparseSegmentSum\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.sparseSize) {\n let indexInSegmentIds = index / uniforms.segmentSize;\n let indexInSegment = index % uniforms.segmentSize;\n let indexInInput = indices[indexInSegmentIds];\n let segmentId = segmentIds[indexInSegmentIds];\n\n let value = input[indexInInput * uniforms.segmentSize + indexInSegment];\n let outIndex = segmentId * uniforms.segmentSize + indexInSegment;\n ${Qr(\"&result[outIndex]\",\"value\",this.type)}\n }\n }\n `}},ly=class{constructor(t,e){this.variableNames=[\"segmentIds\"],this.outputShape=[],this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=[t],this.dispatchLayout=X(e),this.dispatch=H(this.dispatchLayout,e,this.workgroupSize),this.shaderKey=\"sparseSegmentIdCountProgram\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.segmentIdsShape) {\n let segmentId = segmentIds[index];\n ${Qr(\"&result[segmentId]\",\"1\",\"int32\")}\n }\n }\n `}},my=class{constructor(t,e){this.variableNames=[\"segmentSum\",\"sameSegmentIdCount\"],this.outputShape=[],this.uniforms=\"segmentSize : i32\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.type=e,this.dispatchLayout=X(t),this.dispatch=H(this.dispatchLayout,t,this.workgroupSize),this.shaderKey=\"sparseSegmentMean\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let segmentId = index / uniforms.segmentSize;\n let count = sameSegmentIdCount[segmentId];\n if (count != 0) {\n ${this.type===\"float32\"?\"setOutputAtIndex(index, segmentSum[index] / f32(count));\":\"setOutputAtIndexI32(index, segmentSum[index] / count);\"}\n }\n }\n }\n `}};function dy(r,t,e,o=!1,n){let a=y.sizeFromShape(r.shape)/r.shape[0],i=r.dtype,p=y.sizeFromShape(t.shape),u=n.readSync(e.dataId),l=p>0?u[p-1]+1:0,m,d=r.shape.slice();d[0]=l;let f=p*a,h=kt({backend:n,attrs:{shape:d,value:0,dtype:i}});m=new cy(d,f,i);let g=[{type:\"int32\",data:[a]},{type:\"int32\",data:[f]}],x=n.runWebGPUProgram(m,[r,t,e],i,g,h);if(o)return x;let b=kt({backend:n,attrs:{shape:[l],value:0,dtype:\"int32\"}});m=new ly(l,e.shape);let C=n.runWebGPUProgram(m,[e],\"int32\",null,b),S=kt({backend:n,attrs:{shape:d,value:0,dtype:i}});m=new my(d,i),g=[{type:\"int32\",data:[a]}];let k=n.runWebGPUProgram(m,[x,C],i,g,S);return n.disposeData(x.dataId),n.disposeData(C.dataId),k}function pce(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;return dy(o,n,s,!1,e)}var wU={kernelName:ya,backendName:\"webgpu\",kernelFunc:pce};function cce(r){let{inputs:t,backend:e}=r,{data:o,indices:n,segmentIds:s}=t;return dy(o,n,s,!0,e)}var SU={kernelName:ba,backendName:\"webgpu\",kernelFunc:cce};var fy=class{constructor(t,e){this.variableNames=[\"A\"],this.workgroupSize=[64,1,1],this.size=!0;let o=new Array(t.length);for(let n=0;n=5)throw Error(`Tile for rank ${r} is not yet supported`);if(r===1)return`(resRC % ${t}aShape)`;let e=[\"resRC.x\",\"resRC.y\",\"resRC.z\",\"resRC.w\"],o=[];for(let n=0;n=5){let p=e.readSync(n.dataId),u=n.dtype===\"string\"?p.map(m=>y.decodeString(m)):p,c=me(n.shape,n.dtype,u),l=Oz(c,s);return e.makeTensorInfo(l.shape,l.dtype,l.values)}let a=new fy(n.shape,s);return e.runWebGPUProgram(a,[n],n.dtype)}var IU={kernelName:po,backendName:\"webgpu\",kernelFunc:Cm};function mce(r){let{inputs:t,backend:e,attrs:o}=r,{sparseIndices:n,sparseValues:s,defaultValue:a}=t,{outputShape:i}=o,{sliceRank:p,numUpdates:u,sliceSize:c,strides:l,outputSize:m}=w.calculateShapes(s,n,i),d=!1;if(s.dtype===\"string\"){let R=e.bufferSync(n),D=e.bufferSync(s),P=y.decodeString(e.readSync(a.dataId)[0]),O=Ez(R,D,i,m,c,u,p,l,P,d);return e.makeTensorInfo(i,O.dtype,O.values)}let f=[m/c,c],h=pe({inputs:{x:n},backend:e,attrs:{shape:[u,p]}}),g=s.shape.length?pe({inputs:{x:s},backend:e,attrs:{shape:[u,c]}}):Ft({inputs:{x:s},backend:e}),x=g.dtype,b=e.makeTensorInfo([],x,y.makeZerosTypedArray(1,x)),C=pe({inputs:{x:a},backend:e,attrs:{shape:Array(f.length).fill(1)}}),S=Cm({inputs:{x:C},backend:e,attrs:{reps:f}}),k=y.sizeFromShape([u,c]),_=[{type:\"int32\",data:[p]},{type:\"int32\",data:l},{type:\"int32\",data:[k]}];switch(u){case 0:break;case 1:{let R=new Va([u,c],p,h.shape.length,g.shape.length,l,f,x,d);e.runWebGPUProgram(R,[g,h],x,_,S)}break;default:{let R=new Va([u,c],p,h.shape.length,b.shape.length,l,f,x,d);e.runWebGPUProgram(R,[b,h],x,_,S)}{let R=new Va([u,c],p,h.shape.length,g.shape.length,l,f,x);e.runWebGPUProgram(R,[g,h],x,_,S)}}let E=pe({inputs:{x:S},backend:e,attrs:{shape:i}});return e.disposeData(h.dataId),e.disposeData(g.dataId),e.disposeData(C.dataId),e.disposeData(b.dataId),e.disposeData(S.dataId),E}var vU={kernelName:ks,backendName:\"webgpu\",kernelFunc:mce};function dce(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{numOrSizeSplits:s,axis:a}=o,i=y.parseAxisParam(a,n.shape)[0],p=w.prepareSplitSize(n,s,i),u=n.shape.length,c=new Array(u).fill(0),l=n.shape.slice();return p.map(m=>{let d=[...l];d[i]=m;let f=Hs({inputs:{x:n},backend:e,attrs:{begin:c,size:d}});return c[i]+=m,f})}var kU={kernelName:xa,backendName:\"webgpu\",kernelFunc:dce};var fce=ye({opType:Z.SQRT}),NU={kernelName:Ss,backendName:\"webgpu\",kernelFunc:fce};var TU={kernelName:Xi,backendName:\"webgpu\",kernelFunc:({inputs:r,backend:t})=>{let{x:e}=r,o=t,n=new Jr(e.shape,Z.SQUARE);return o.runWebGPUProgram(n,[e],e.dtype)}};var hce=et({opType:fe.SQUARED_DIFFERENCE}),_U={kernelName:Ns,backendName:\"webgpu\",kernelFunc:hce};function gce({inputs:r,attrs:t,backend:e}){let{x:o}=r,n=new Jr(o.shape,Z.STEP,\"stepAlpha : f32,\"),s=[{type:\"float32\",data:[t.alpha]}];return e.runWebGPUProgram(n,[o],o.dtype,s)}var $U={kernelName:So,backendName:\"webgpu\",kernelFunc:gce};var hy=class{constructor(t){this.variableNames=[\"x\"],this.workPerThread=1,this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize,[this.workPerThread,1,1]);let e=ht(this.outputShape.length);this.uniforms=`begin : ${e}, strides : ${e}, `,this.shaderKey=\"stridedSlice\"}getUserCode(){let t=this.outputShape.length,e=\"\";if(t===1)e=\"coords * uniforms.strides + uniforms.begin\";else{let n=0;e=this.outputShape.map((s,a)=>(n++,this.outputShape.length===1?`coords * uniforms.strides[${a}] + uniforms.begin[${a}]`:`coords[${n-1}] * uniforms.strides[${a}] + uniforms.begin[${a}]`)).join(\",\")}return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n setOutputAtIndex(index, getX(${e}));\n }\n }\n `}};function xce(r){let{inputs:t,backend:e,attrs:o}=r,{x:n}=t,{begin:s,end:a,strides:i,beginMask:p,endMask:u,ellipsisMask:c,newAxisMask:l,shrinkAxisMask:m}=o,{finalShapeSparse:d,finalShape:f,isIdentity:h,sliceDim0:g,isSimpleSlice:x,begin:b,end:C,strides:S}=ct.sliceInfo(n.shape,s,a,i,p,u,c,l,m),k;if(h)k=pe({inputs:{x:n},backend:e,attrs:{shape:f}});else if(g||x){y.assert(n.shape.length>=1,()=>`Input must have rank at least 1, got: ${n.shape.length}`);let _=ct.computeOutShape(b,C,S),E=Hs({inputs:{x:n},backend:e,attrs:{begin:b,size:_}});k=pe({inputs:{x:E},backend:e,attrs:{shape:f}}),e.disposeData(E.dataId)}else if(e.shouldExecuteOnCPU([n])){let E=e.readSync(n.dataId),R=me(n.shape,n.dtype,E),D=Az(d,R,S,b);k=e.makeTensorInfo(f,n.dtype,D.values)}else{let E=new hy(d),R=[{type:\"int32\",data:b},{type:\"int32\",data:S}],D=e.runWebGPUProgram(E,[n],n.dtype,R);k=pe({inputs:{x:D},backend:e,attrs:{shape:f}}),e.disposeData(D.dataId)}return k}var EU={kernelName:Ts,backendName:\"webgpu\",kernelFunc:xce};function yce(r){let{inputs:t,backend:e,attrs:o}=r,{separator:n,nGramWidths:s,leftPad:a,rightPad:i,padWidth:p,preserveShortSequences:u}=o,{data:c,dataSplits:l}=t,m=e.readSync(c.dataId),d=e.readSync(l.dataId),[f,h]=Fz(m,d,n,s,a,i,p,u);return[e.makeTensorInfo([f.length],\"string\",f),e.makeTensorInfo(l.shape,\"int32\",h)]}var RU={kernelName:Ca,backendName:\"webgpu\",kernelFunc:yce};var bce=et({opType:fe.SUB,cpuKernelImpl:Pz,supportsComplex:!0}),DU={kernelName:_s,backendName:\"webgpu\",kernelFunc:bce};var Cce=ye({opType:Z.TAN}),AU={kernelName:$s,backendName:\"webgpu\",kernelFunc:Cce};var wce=ye({opType:Z.TANH}),FU={kernelName:Es,backendName:\"webgpu\",kernelFunc:wce};function Sce(r){let{inputs:t,backend:e,attrs:o}=r,{tensor:n,indices:s,updates:a}=t,{}=o,{sliceRank:i,numUpdates:p,sliceSize:u,strides:c,outputSize:l}=w.calculateShapes(a,s,n.shape),m=[l/u,u];if(l===0)return e.makeTensorInfo(n.shape,s.dtype);let d=[],f=pe({inputs:{x:s},backend:e,attrs:{shape:[p,i]}});d.push(f);let h=pe({inputs:{x:a},backend:e,attrs:{shape:[p,u]}});d.push(h);let g=pe({inputs:{x:n},backend:e,attrs:{shape:m}});d.push(g);let x=Cm({inputs:{x:g},backend:e,attrs:{reps:Array(m.length).fill(1)}}),b=new Va([p,u],i,f.shape.length,h.shape.length,c,m,n.dtype,!1),C=y.sizeFromShape([p,u]),S=[{type:\"int32\",data:[i]},{type:\"int32\",data:c},{type:\"int32\",data:[C]}],k=e.runWebGPUProgram(b,[h,f],g.dtype,S,x);d.push(k);let _=pe({inputs:{x:k},backend:e,attrs:{shape:n.shape}});return d.forEach(E=>e.disposeData(E.dataId)),_}var PU={kernelName:fs,backendName:\"webgpu\",kernelFunc:Sce};var gy=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=`inputSize : i32, firstPass : i32, negativeInf : f32,\n dir : i32, inc : i32,`,this.shaderKey=\"swap\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let outC = getCoordsFromIndex(index);\n let batch = outC[0];\n let elemIdx = outC[1];\n // We compare elements pair-wise within a group of size 2 * inc.\n // The comparing rule for each group alternates between ascending\n // and descending. Within each group, we compare each pair at\n // positions i and i+inc. To decide whether an element at position i\n // is x0 or x1, we mod it by 2 * inc, if the result is smaller than\n // inc, it is in the first half of the group, we denote it as x0,\n // otherwise we denote it as x1.\n // For example, as shown in the Bitonic top K paper referenced\n // above, Figure5(a) shows that element[1] is in the second half of\n // the group when group size is 2, but it is in the first half of\n // the group when group size is 4.\n let isFirstInPair = elemIdx % (2 * uniforms.inc) < uniforms.inc;\n var i = 0;\n if (isFirstInPair) {\n i = elemIdx;\n } else {\n i = elemIdx - uniforms.inc;\n }\n\n var i0 = 0;\n if (uniforms.firstPass == 1) {\n i0 = i;\n } else {\n i0 = i32(getIndices(batch, i));\n }\n\n var i1 = 0;\n if (uniforms.firstPass == 1) {\n i1 = i + uniforms.inc;\n } else {\n i1 = i32(getIndices(batch, i + uniforms.inc));\n }\n\n var x0 = f32(0.0);\n var x1 = f32(0.0);\n if (i0 < uniforms.inputSize) {\n x0 = getX(batch, i0);\n } else {\n x0 = uniforms.negativeInf;\n }\n if (i1 < uniforms.inputSize) {\n x1 = getX(batch, i1);\n } else {\n x1 = uniforms.negativeInf;\n }\n\n let reverse = elemIdx % (2 * uniforms.dir) >= uniforms.dir;\n let isGreater = x0 > x1 || (x0 == x1 && i1 > i0);\n if (reverse == isGreater) {\n // Elements in opposite order of direction\n let iTemp = i0;\n i0 = i1;\n i1 = iTemp;\n }\n if (isFirstInPair) {\n setOutputAtIndex(index, f32(i0));\n } else {\n setOutputAtIndex(index, f32(i1));\n }\n }\n }\n `}},xy=class{constructor(t){this.variableNames=[\"x\",\"indices\"],this.workgroupSize=[256,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.uniforms=\"inputSize : i32, firstPass : i32, k : i32,\",this.shaderKey=\"merge\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let outC = getCoordsFromIndex(index);\n let batch = outC[0];\n let elemIdx = outC[1];\n // The output size is half of the previous size.\n // If the previous sequence is | | | | _ _ _ _ | | | | _ _ _ _\n // (k=4), we only need to output the indices at positions |, the\n // indices at positions _ can be thrown away, see Figure5(b) After\n // Phase 2 (Merge phase) in the Bitonic Top K paper referenced\n // above.\n // For example, the paper shows we only need to output the orange\n // bars. The output sequence should look like this | | | | | | | |.\n // Because the sequence is halved, to map the output index back to\n // the previous sequence to find the corresponding value, we need\n // to double the index. When we double the index, we basically\n // interpolate a position, so 2i looks like\n // | _ | _ | _ | _ | _ | _ | _. We move the | to the first k\n // position of each 2k positions by - elemIdx % k. E.g. for output\n // at index 4,5,6,7, we want to get the corresponding element at\n // original index 8,9,10,11, for output at index 8,9,10,11,\n // we want to get the corresponding element at original index\n // 16,17,18,19, so on and so forth.\n\n var i = 0;\n if (elemIdx < uniforms.k) {\n i = elemIdx;\n } else {\n i = elemIdx * 2 - elemIdx % uniforms.k;\n }\n var i0 = 0;\n if (uniforms.firstPass == 1) {\n i0 = i;\n } else {\n i0 = i32(getIndices(batch, i));\n }\n var i1 = 0;\n if (uniforms.firstPass == 1) {\n i1 = i + uniforms.k;\n } else {\n i1 = i32(getIndices(batch, i + uniforms.k));\n }\n\n let x0 = getX(batch, i0);\n var x1 = f32(0.0);\n if (i1 < uniforms.inputSize) {\n x1 = getX(batch, i1);\n } else {\n x1 = x0;\n }\n\n if (x0 >= x1) {\n setOutputAtIndex(index, f32(i0));\n } else {\n setOutputAtIndex(index, f32(i1));\n }\n }\n }\n `}};function nl(r,t){t!==null&&r.disposeData(t.dataId)}function OU(r){let t=1;for(;tf===null?[l,l]:[l,f],g=(k,_,E)=>{let R=h(),D=new gy(E),O=[{type:\"int32\",data:[p]},{type:\"int32\",data:[f===null?1:0]},{type:\"float32\",data:[Number.NEGATIVE_INFINITY]},{type:\"int32\",data:[k]},{type:\"int32\",data:[_]}],M=f;f=e.runWebGPUProgram(D,R,\"int32\",O),nl(e,M)};for(let k=1;k=1;E/=2)g(_,E,[c,d])}for(let k=d;k>m;k/=2){let _=h(),E=new xy([c,k/2]),D=[{type:\"int32\",data:[p]},{type:\"int32\",data:[f===null?1:0]},{type:\"int32\",data:[m]}],P=f;f=e.runWebGPUProgram(E,_,\"int32\",D),nl(e,P);let O=m/2,M=O*2;for(let L=O;L>=1;L/=2)g(M,L,f.shape)}let x=f;f=Hs({inputs:{x:f},backend:e,attrs:{begin:0,size:[c,s]}}),nl(e,x);let b=u0({inputs:{x:l,indices:f},backend:e,attrs:{axis:1,batchDims:1}});nl(e,l);let C=i.slice(0,-1);C.push(s),x=f,f=pe({inputs:{x:f},attrs:{shape:C},backend:e}),nl(e,x);let S=b;return b=pe({inputs:{x:b},attrs:{shape:C},backend:e}),nl(e,S),[b,f]}var MU={kernelName:Rs,backendName:\"webgpu\",kernelFunc:Ice};var yy=class{constructor(t){this.variableNames=[\"Image\",\"Transforms\"],this.uniforms=\"interpolationModeId : i32, fillModeId : i32, fillValue : f32,\",this.workgroupSize=[64,1,1],this.size=!0,this.outputShape=t,this.dispatchLayout=X(this.outputShape),this.dispatch=H(this.dispatchLayout,this.outputShape,this.workgroupSize),this.shaderKey=\"transform\"}getUserCode(){return`\n fn mapCoord(outCoord : f32, len : f32) -> f32{\n var inCoord = outCoord;\n if(uniforms.fillModeId == 2) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz2 = 2.0 * len;\n if (inCoord < sz2) {\n inCoord = sz2 * f32(i32(f32(-inCoord / sz2))) +\n inCoord;\n }\n if (inCoord < -len) {\n inCoord = inCoord + sz2;\n } else {\n inCoord = -inCoord - 1.0;\n }\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz2 = 2.0 * len;\n inCoord = inCoord - sz2 * f32(i32(f32(inCoord / sz2)));\n if (inCoord >= len) {\n inCoord = sz2 - inCoord - 1.0;\n }\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (uniforms.fillModeId == 3) {\n if (inCoord < 0.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz = len - 1.0;\n inCoord = inCoord + len * (f32(i32(f32(-inCoord / sz))) + 1.0);\n }\n } else if (inCoord > len - 1.0) {\n if (len <= 1.0) {\n inCoord = 0.0;\n } else {\n let sz = len - 1.0;\n inCoord = inCoord - len * f32(i32(f32(inCoord / sz)));\n }\n }\n return clamp(inCoord, 0.0, len - 1.0);\n } else if (uniforms.fillModeId == 4) {\n return clamp(outCoord, 0.0, len - 1.0);\n }\n return outCoord;\n }\n fn readWithFillValue(batch : i32, coordY : i32, coordX : i32,\n channel : i32) -> f32 {\n var outputValue : f32;\n if (0 <= coordY && coordY < uniforms.imageShape[1] && 0 <= coordX && coordX < uniforms.imageShape[2]) {\n outputValue = getImage(batch, coordY, coordX, channel);\n } else {\n outputValue = uniforms.fillValue;\n }\n return outputValue;\n }\n\n ${G(\"index\")} {\n if (index < uniforms.size) {\n let coords = getCoordsFromIndex(index);\n var outputValue : f32;\n let batch = coords[0];\n let x = coords[2];\n let y = coords[1];\n let channel = coords[3];\n let xf = f32(x);\n let yf = f32(y);\n let a1 = getTransforms(batch, 0);\n let a2 = getTransforms(batch, 1);\n let a3 = getTransforms(batch, 2);\n let b1 = getTransforms(batch, 3);\n let b2 = getTransforms(batch, 4);\n let b3 = getTransforms(batch, 5);\n let c1 = getTransforms(batch, 6);\n let c2 = getTransforms(batch, 7);\n let projection = c1 * xf + c2 * yf + 1.0;\n if (projection == 0.0) {\n outputValue = uniforms.fillValue;\n } else {\n let inX = (a1 * xf + a2 * yf + a3) / projection;\n let inY = (b1 * xf + b2 * yf + b3) / projection;\n let mapX = mapCoord(inX, f32(uniforms.imageShape[2]));\n let mapY = mapCoord(inY, f32(uniforms.imageShape[1]));\n\n if (uniforms.interpolationModeId == 1) {\n let coordY = i32(round(mapY));\n let coordX = i32(round(mapX));\n outputValue = readWithFillValue(batch, coordY, coordX,\n channel);\n } else {\n let yFloor = floor(mapY);\n let xFloor = floor(mapX);\n let yCeil = yFloor + 1.0;\n let xCeil = xFloor + 1.0;\n let valueYFloor = (xCeil - mapX) *\n readWithFillValue(batch, i32(yFloor), i32(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, i32(yFloor), i32(xCeil), channel);\n let valueYCeil = (xCeil - mapX) *\n readWithFillValue(batch, i32(yCeil), i32(xFloor), channel) +\n (mapX - xFloor) *\n readWithFillValue(batch, i32(yCeil), i32(xCeil), channel);\n outputValue = (yCeil - mapY) * valueYFloor +\n (mapY - yFloor) * valueYCeil;\n }\n }\n setOutputAtIndex(index, outputValue);\n }\n }\n `}};function vce(r){let{inputs:t,backend:e,attrs:o}=r,{image:n,transforms:s}=t,{interpolation:a,fillMode:i,fillValue:p,outputShape:u}=o,[c,l,m,d]=n.shape,[f,h]=u!=null?u:[l,m],g=[c,f,h,d],x=new yy(g),b=a===\"nearest\"?1:2,C;switch(i){case\"constant\":C=1;break;case\"reflect\":C=2;break;case\"wrap\":C=3;break;case\"nearest\":C=4;break;default:C=1;break}let S=[{type:\"int32\",data:[b]},{type:\"int32\",data:[C]},{type:\"float32\",data:[p]}];return e.runWebGPUProgram(x,[n,s],\"float32\",S)}var LU={kernelName:Ds,backendName:\"webgpu\",kernelFunc:vce};function kce(r){let{inputs:t,backend:e,attrs:o}=r,{value:n}=t,{axis:s}=o;s<0&&(s+=n.shape.length);let a=n,i=a.shape.length,p=n.shape[s],u=new Array(i-1),c=0;for(let h=0;he.disposeData(h.dataId)),f}var BU={kernelName:wa,backendName:\"webgpu\",kernelFunc:kce};var by=class{constructor(t,e,o){if(this.outputShape=[],this.variableNames=[\"x\",\"segmentIds\"],this.uniforms=\"numSegments : i32, xSize: i32,\",this.workgroupSize=[64,1,1],this.atomic=!0,this.outputShape=e,this.dispatchLayout=X(t),this.dispatch=H(this.dispatchLayout,t,this.workgroupSize),o!==\"float32\"&&o!==\"int32\")throw new Error(`UnsortedSegmentSum only supports float32 and int32\n types, does not support ${o} type.`);this.type=o,this.shaderKey=\"unsortedSegmentSum\"}getUserCode(){return`\n ${G(\"index\")} {\n if (index < uniforms.xSize) {\n let coords = getXCoordsFromIndex(index);\n let b = coords[0];\n let inCol = coords[1];\n\n let segmentId = i32(getSegmentIds(inCol));\n if (segmentId >= 0) {\n let flatIndex = b * uniforms.numSegments + segmentId % uniforms.numSegments;\n let value = getX(b, inCol);\n\n ${Qr(\"&result[flatIndex]\",\"value\",this.type)}\n }\n }\n }\n `}};function Nce(r){let{inputs:t,backend:e,attrs:o}=r,{x:n,segmentIds:s}=t,{numSegments:a}=o,i=n.shape.length,p=[],u=0,c=w.getAxesPermutation([u],i),l=n;c!=null&&(l=yr({inputs:{x:n},backend:e,attrs:{perm:c}}),p.push(l),u=w.getInnerMostAxes(1,i)[0]);let m=w.segment_util.computeOutShape(l.shape,u,a),d=y.sizeFromShape([l.shape[u]]),f=pe({inputs:{x:l},backend:e,attrs:{shape:[-1,d]}});p.push(f);let h=n.dtype,g=[f.shape[0],a],x=kt({backend:e,attrs:{shape:g,value:0,dtype:h}}),b=new by(f.shape,g,h),C=[{type:\"int32\",data:[a]},{type:\"int32\",data:[y.sizeFromShape(f.shape)]}],S=e.runWebGPUProgram(b,[f,s],h,C,x),k=pe({inputs:{x:S},backend:e,attrs:{shape:m}});p.push(S);let _=k;if(c!=null){p.push(k);let E=w.getUndoAxesPermutation(c);_=yr({inputs:{x:_},backend:e,attrs:{perm:E}})}return p.forEach(E=>e.disposeData(E.dataId)),_}var zU={kernelName:Ji,backendName:\"webgpu\",kernelFunc:Nce};var Tce=[rz,Bz,zz,Vz,Wz,Uz,Hz,Kz,qz,jz,Xz,Yz,Qz,Zz,Jz,rV,oV,nV,sV,aV,uV,pV,cV,fV,hV,gV,nz,yV,CV,wV,SV,IV,vV,kV,NV,TV,_V,$V,DV,AV,FV,PV,MV,LV,OV,BV,zV,VV,WV,UV,KV,qV,jV,XV,YV,QV,ZV,JV,eW,ez,tW,nW,rW,oW,sW,aW,iW,uW,pW,cW,lW,oz,mW,bV,dW,fW,hW,gW,xW,yW,bW,wW,CW,SW,IW,vW,NW,TW,eV,_W,$W,DW,EW,RW,AW,tV,FW,PW,OW,MW,BW,GV,zW,VW,WW,lV,UW,KW,qW,jW,XW,YW,QW,ZW,mV,JW,eU,tU,rU,tz,oU,nU,sU,aU,iU,uU,pU,cU,lU,mU,dU,fU,hU,gU,xU,yU,iV,$U,EU,RU,LW,bU,CU,wU,SU,vU,kU,NU,TU,_U,DU,HV,AU,FU,PU,IU,MU,LU,Gz,BU,zU,GW];for(let r of Tce)ri(r);var VU=\"4.11.0\",_ce=\"4.11.0\",$ce=\"4.11.0\",Ece=\"4.11.0\",Rce=\"4.11.0\",Dce=\"4.11.0\",Ace={tfjs:VU,\"tfjs-core\":VU,\"tfjs-converter\":_ce,\"tfjs-backend-cpu\":$ce,\"tfjs-backend-webgl\":Ece,\"tfjs-backend-wasm\":Rce,\"tfjs-backend-webgpu\":Dce};export{Xs as Abs,Wo as Acos,Uo as Acosh,np as AdadeltaOptimizer,sp as AdagradOptimizer,ap as AdamOptimizer,ip as AdamaxOptimizer,uo as Add,Go as AddN,Ho as All,Ko as Any,Ys as ArgMax,Qs as ArgMin,qo as Asin,jo as Asinh,Xo as Atan,Qo as Atan2,Yo as Atanh,Zo as AvgPool,Zs as AvgPool3D,Ai as AvgPool3DGrad,Di as AvgPoolGrad,pm as BackendWasm,Jo as BatchMatMul,Js as BatchToSpaceND,en as Bincount,ja as BitwiseAnd,ea as BroadcastArgs,Bce as BroadcastTo,bo as Cast,tn as Ceil,Co as ClipByValue,Fi as Complex,Pi as ComplexAbs,ta as Concat,rn as Conv2D,Oi as Conv2DBackpropFilter,on as Conv2DBackpropInput,nn as Conv3D,Xa as Conv3DBackpropFilterV2,sn as Conv3DBackpropInputV2,an as Cos,un as Cosh,ln as CropAndResize,pn as Cumprod,cn as Cumsum,zo as DataStorage,ra as DenseBincount,mn as DepthToSpace,dn as DepthwiseConv2dNative,Mi as DepthwiseConv2dNativeBackpropFilter,Li as DepthwiseConv2dNativeBackpropInput,oa as Diag,fn as Dilation2D,zi as Dilation2DBackpropFilter,Bi as Dilation2DBackpropInput,Pu as Draw,nw as ENV,Vi as Einsum,gn as Elu,Ya as EluGrad,hl as Environment,yn as Equal,xn as Erf,bn as Exp,na as ExpandDims,Cn as Expm1,Wi as FFT,sa as Fill,wn as FlipLeftRight,Sn as Floor,In as FloorDiv,Mu as FromPixels,vn as FusedBatchNorm,vo as FusedConv2D,ko as FusedDepthwiseConv2D,kp as GPGPUContext,kn as GatherNd,aa as GatherV2,Bl as GraphModel,Nn as Greater,Tn as GreaterEqual,Ui as IFFT,wo as Identity,Gi as Imag,_n as IsFinite,$n as IsInf,En as IsNan,ao as KernelBackend,zn as LRN,Qa as LRNGrad,Rn as LeakyRelu,Dn as Less,An as LessEqual,Fn as LinSpace,Pn as Log,On as Log1p,zce as LogSoftmax,Mn as LogicalAnd,Ln as LogicalNot,Bn as LogicalOr,$0 as LogicalXor,Vce as LowerBound,xu as MathBackendCPU,wu as MathBackendWebGL,Wce as MatrixBandPart,Vn as Max,Un as MaxPool,ia as MaxPool3D,Ki as MaxPool3DGrad,Hi as MaxPoolGrad,ua as MaxPoolWithArgmax,Wn as Maximum,Gn as Mean,Hn as Min,Kn as Minimum,qn as MirrorPad,jn as Mod,up as MomentumOptimizer,Xn as Multinomial,Yn as Multiply,pa as Neg,Zn as NonMaxSuppressionV3,Za as NonMaxSuppressionV4,Jn as NonMaxSuppressionV5,Qn as NotEqual,kw as OP_SCOPE_SUFFIX,es as OneHot,ca as OnesLike,Nr as Optimizer,Pl as OptimizerConstructors,la as Pack,ts as PadV2,Uce as Pool,rs as Pow,os as Prelu,ns as Prod,pp as RMSPropOptimizer,Qp as RaggedGather,Zp as RaggedRange,Jp as RaggedTensorToTensor,ma as Range,hw as Rank,qi as Real,hn as RealDiv,ss as Reciprocal,Rt as Reduction,as as Relu,ps as Relu6,da as Reshape,us as ResizeBilinear,ei as ResizeBilinearGrad,is as ResizeNearestNeighbor,Ja as ResizeNearestNeighborGrad,cs as Reverse,As as RotateWithOffset,ls as Round,ms as Rsqrt,mi as SGDOptimizer,ds as ScatterNd,hs as SearchSorted,fa as Select,gs as Selu,Cs as Sigmoid,bs as Sign,xs as Sin,ys as Sinh,ha as Slice,vs as Softmax,ws as Softplus,ga as SpaceToBatchND,ji as SparseFillEmptyRows,ti as SparseReshape,ya as SparseSegmentMean,ba as SparseSegmentSum,ks as SparseToDense,xa as SplitV,Ss as Sqrt,Xi as Square,Ns as SquaredDifference,Ou as StaticRegexReplace,So as Step,Ts as StridedSlice,Ca as StringNGrams,Yi as StringSplit,Qi as StringToHashBucketFast,_s as Sub,Is as Sum,$s as Tan,Es as Tanh,ut as Tensor,tt as TensorBuffer,fs as TensorScatterUpdate,po as Tile,Rs as TopK,Ds as Transform,co as Transpose,Zi as Unique,wa as Unpack,Ji as UnsortedSegmentSum,Gce as UpperBound,oi as Variable,Tu as WebGPUBackend,Sa as ZerosLike,Io as _FusedMatMul,Jt as abs,kk as acos,Nk as acosh,Ce as add,Tk as addN,_k as all,$k as any,Ek as argMax,Rk as argMin,Dk as asin,Ak as asinh,Fk as atan,Pk as atan2,Ok as atanh,fd as avgPool,Bk as avgPool3d,vde as backend,w as backend_util,zk as basicLSTMCell,au as batchNorm,Wk as batchNorm2d,Uk as batchNorm3d,Gk as batchNorm4d,hd as batchToSpaceND,gd as bincount,Hk as bitwiseAnd,E6 as booleanMaskAsync,Kk as broadcastArgs,iu as broadcastTo,Ir as broadcast_util,oT as browser,me as buffer,We as cast,qk as ceil,jk as clipByValue,Ur as clone,Er as complex,bt as concat,Xk as concat1d,Yk as concat2d,Qk as concat3d,Zk as concat4d,Jk as conv1d,uu as conv2d,e2 as conv2dTranspose,t2 as conv3d,o2 as conv3dTranspose,Zce as copyRegisteredKernels,n2 as cos,s2 as cosh,Rl as cosineWindow,a2 as cumprod,i2 as cumsum,vr as customGrad,u2 as denseBincount,Pw as deprecationWarn,p2 as depthToSpace,lc as depthwiseConv2d,A5 as deregisterOp,ou as device_util,c2 as diag,l2 as dilation2d,dde as disableDeprecationWarnings,Mt as dispose,fde as disposeVariables,je as div,d2 as divNoNan,f2 as dot,W6 as dropout,pu as einsum,Cd as elu,mde as enableDebugMode,lde as enableProdMode,Qw as enclosingPowerOfTwo,pr as engine,h2 as ensureShape,A as env,bd as equal,g2 as erf,b2 as euclideanNorm,$o as exp,Ms as expandDims,C2 as expm1,wd as eye,fc as fft,Ea as fill,Sde as findBackend,Ide as findBackendFactory,Sd as floor,dd as floorDiv,MD as forceHalfFloat,Zw as fused,Id as gather,z6 as gatherND,af as gather_util,Cde as getBackend,iw as getGradient,tc as getKernel,Ym as getKernelsForBackend,Zse as getThreadsCount,cv as gpgpu_util,AK as grad,FK as grads,qu as greater,vd as greaterEqual,Ju as ifft,lu as imag,Kj as image,G6 as inTopKAsync,fi as io,Kd as irfft,w2 as isFinite,S2 as isInf,I2 as isNaN,Rr as keep,Wt as kernel_impls,kd as leakyRelu,_l as less,mc as lessEqual,qj as linalg,v2 as linspace,$8 as loadGraphModel,E8 as loadGraphModelSync,k2 as localResponseNormalization,pi as log,Nd as log1p,N2 as logSigmoid,T2 as logSoftmax,$d as logSumExp,ju as logicalAnd,Ed as logicalNot,Rd as logicalOr,_2 as logicalXor,jj as losses,$2 as lowerBound,Ze as matMul,JN as math,Ra as max,Ad as maxPool,E2 as maxPool3d,R2 as maxPoolWithArgmax,Fd as maximum,Xu as mean,hde as memory,D2 as meshgrid,Tl as min,Yu as minimum,A2 as mirrorPad,F2 as mod,P2 as moments,A6 as movingAverage,se as mul,O2 as multiRNNCell,M2 as multinomial,cr as neg,pS as nextFrame,Ku as norm,Pd as notEqual,El as oneHot,Da as ones,L2 as onesLike,N as op,B2 as outerProduct,Aa as pad,z2 as pad1d,V2 as pad2d,W2 as pad3d,U2 as pad4d,G2 as pool,ui as pow,Md as prelu,md as print,H2 as prod,gde as profile,K2 as raggedGather,q2 as raggedRange,j2 as raggedTensorToTensor,X2 as rand,g1 as randomGamma,Ud as randomNormal,x1 as randomStandardNormal,dc as randomUniform,y1 as randomUniformInt,mu as range,bde as ready,ci as real,b1 as reciprocal,su as registerBackend,Xce as registerGradient,ri as registerKernel,D5 as registerOp,du as relu,Gd as relu6,wde as removeBackend,W as reshape,mo as reverse,C1 as reverse1d,w1 as reverse2d,S1 as reverse3d,I1 as reverse4d,hc as rfft,Hd as round,v1 as rsqrt,ke as scalar,P6 as scatterND,hu as scatter_util,$l as searchSorted,k1 as selu,N1 as separableConv2d,WN as serialization,yde as setBackend,kde as setPlatform,Qse as setThreadsCount,Xse as setWasmPath,Yse as setWasmPaths,vI as setWebGLContext,T1 as setdiff1dAsync,Tc as shared,$a as sigmoid,_1 as sign,Hj as signal,$1 as sin,E1 as sinh,Xe as slice,R1 as slice1d,D1 as slice2d,A1 as slice3d,F1 as slice4d,ct as slice_util,P1 as softmax,_d as softplus,Od as spaceToBatchND,Xj as sparse,L6 as sparseToDense,Gj as spectral,li as split,Dr as sqrt,er as square,qd as squaredDifference,gc as squeeze,kr as stack,jd as step,O1 as stridedSlice,Yj as string,Te as sub,ot as sum,ni as sumOutType,M1 as tan,Nl as tanh,ur as tensor,tr as tensor1d,fu as tensor2d,Xd as tensor3d,L1 as tensor4d,B1 as tensor5d,z1 as tensor6d,W1 as tensorScatterUpdate,ek as tensor_util,h1 as test_util,De as tidy,cu as tile,xde as time,U1 as topk,TGe as train,yc as transpose,G1 as truncatedNormal,H1 as unique,Qce as unregisterGradient,Yce as unregisterKernel,K1 as unsortedSegmentSum,fo as unstack,dt as upcastType,q1 as upperBound,y as util,PK as valueAndGrad,OK as valueAndGrads,j1 as variable,zw as variableGrads,Ace as version,D8 as version_converter,_X as version_core,cY as version_cpu,Jse as version_wasm,s9 as version_webgl,Cat as webgl,Ac as webgl_util,Yv as webgpu_util,lo as where,Qd as whereAsync,Gr as zeros,Ht as zerosLike};\n", "import type { Config } from '../exports';\n\n/**\n * Simple helper functions used accross codebase\n */\n\n// helper function: wrapper around console output\nexport function log(...msg): void {\n const dt = new Date();\n const ts = `${dt.getHours().toString().padStart(2, '0')}:${dt.getMinutes().toString().padStart(2, '0')}:${dt.getSeconds().toString().padStart(2, '0')}.${dt.getMilliseconds().toString().padStart(3, '0')}`;\n if (msg) console.log(ts, 'Human:', ...msg); // eslint-disable-line no-console\n}\n\n// helper function: join two paths\nexport function join(folder: string, file: string): string {\n const separator = folder.endsWith('/') ? '' : '/';\n const skipJoin = file.startsWith('.') || file.startsWith('/') || file.startsWith('http:') || file.startsWith('https:') || file.startsWith('file:');\n const path = skipJoin ? `${file}` : `${folder}${separator}${file}`;\n if (!path.toLocaleLowerCase().includes('.json')) throw new Error(`modelpath error: expecting json file: ${path}`);\n return path;\n}\n\n// helper function: gets elapsed time on both browser and nodejs\nexport const now = () => {\n if (typeof performance !== 'undefined') return performance.now();\n return parseInt((Number(process.hrtime.bigint()) / 1000 / 1000).toString());\n};\n\n// helper function: checks current config validity\nexport function validate(defaults: Partial, config: Partial, parent = 'config', msgs: { reason: string, where: string, expected?: string }[] = []) {\n for (const key of Object.keys(config)) {\n if (typeof config[key] === 'object') {\n validate(defaults[key], config[key], key, msgs);\n } else {\n const defined = defaults && (typeof defaults[key] !== 'undefined');\n if (!defined) msgs.push({ reason: 'unknown property', where: `${parent}.${key} = ${config[key]}` });\n const same = defaults && typeof defaults[key] === typeof config[key];\n if (defined && !same) msgs.push({ reason: 'property type mismatch', where: `${parent}.${key} = ${config[key]}`, expected: typeof defaults[key] });\n }\n // ok = ok && defined && same;\n }\n if (config.debug && parent === 'config' && msgs.length > 0) log('invalid configuration', msgs);\n return msgs;\n}\n\n// helper function: perform deep merge of multiple objects so it allows full inheritance with overrides\nexport function mergeDeep(...objects) {\n const isObject = (obj) => obj && typeof obj === 'object';\n return objects.reduce((prev, obj) => {\n Object.keys(obj || {}).forEach((key) => {\n const pVal = prev[key];\n const oVal = obj[key];\n if (Array.isArray(pVal) && Array.isArray(oVal)) prev[key] = pVal.concat(...oVal);\n else if (isObject(pVal) && isObject(oVal)) prev[key] = mergeDeep(pVal, oVal);\n else prev[key] = oVal;\n });\n return prev;\n }, {});\n}\n\n// helper function: return min and max from input array\nexport const minmax = (data: number[]) => data.reduce((acc: number[], val) => {\n acc[0] = (acc[0] === undefined || val < acc[0]) ? val : acc[0];\n acc[1] = (acc[1] === undefined || val > acc[1]) ? val : acc[1];\n return acc;\n}, []);\n\n// helper function: async wait\nexport async function wait(time: number) {\n const waiting = new Promise((resolve) => { setTimeout(() => resolve(true), time); });\n await waiting;\n}\n", "/* eslint-disable no-multi-spaces */\n\n/** Possible TensorFlow backends */\nexport type BackendEnum = '' | 'cpu' | 'wasm' | 'webgl' | 'humangl' | 'tensorflow' | 'webgpu';\n\n/** Possible values for `human.warmup` */\nexport type WarmupEnum = '' | 'none' | 'face' | 'full' | 'body';\n\n/** Possible segmentation model behavior */\nexport type SegmentationEnum = 'default' | 'alpha' | 'foreground' | 'state'\n\n/** Generic config type inherited by all module types */\nexport interface GenericConfig {\n /** is module enabled? */\n enabled: boolean,\n /** path to model json file (relative to `modelBasePath` */\n modelPath: string,\n /** how many max frames to go without re-running model if cached results are acceptable\n * for two-phase models such as face and hand caching applies to bounding boxes detection only */\n skipFrames: number,\n /** how many max milliseconds to go without re-running model if cached results are acceptable\n * for two-phase models such as face and hand caching applies to bounding boxes detection only */\n skipTime: number,\n}\n\n/** Detector part of face configuration */\nexport interface FaceDetectorConfig extends GenericConfig {\n /** is face rotation correction performed after detecting face?\n * used to correctly analyze faces under high angles\n */\n rotation: boolean,\n /** maximum number of detected faces */\n maxDetected: number,\n /** minimum confidence for a detected face before results are discarded */\n minConfidence: number,\n /** minimum size in pixels of a detected face box before resutls are discared */\n minSize: number,\n /** minimum overlap between two detected faces before one is discarded */\n iouThreshold: number,\n /** should child models perform on masked image of a face */\n mask: boolean,\n /** should face detection return processed and cropped face tensor that can with an external model for addtional processing?\n * if enabled it must be manually deallocated to avoid memory leak */\n return: boolean,\n}\n\n/** Mesh part of face configuration */\nexport interface FaceMeshConfig extends GenericConfig {\n /** Keep detected faces that cannot be verified using facemesh */\n keepInvalid: boolean\n}\n\n/** Iris part of face configuration */\nexport interface FaceIrisConfig extends GenericConfig {}\n\n/** Attention part of face configuration */\nexport interface FaceAttentionConfig extends GenericConfig {}\n\n/** Description or face embedding part of face configuration\n * - also used by age and gender detection\n */\nexport interface FaceDescriptionConfig extends GenericConfig {\n /** minimum confidence for a detected face before results are discarded */\n minConfidence: number,\n}\n\n/** Emotion part of face configuration */\nexport interface FaceEmotionConfig extends GenericConfig {\n /** minimum confidence for a detected face before results are discarded */\n minConfidence: number,\n}\n\n/** Anti-spoofing part of face configuration */\nexport interface FaceAntiSpoofConfig extends GenericConfig {}\n\n/** Liveness part of face configuration */\nexport interface FaceLivenessConfig extends GenericConfig {}\n\n/** Gear part of face configuration */\nexport interface FaceGearConfig extends GenericConfig {\n /** minimum confidence for a detected race before results are discarded */\n minConfidence: number,\n}\n\n/** Configures all face-specific options: face detection, mesh analysis, age, gender, emotion detection and face description */\nexport interface FaceConfig extends GenericConfig {\n detector: Partial,\n mesh: Partial,\n attention: Partial,\n iris: Partial,\n description: Partial,\n emotion: Partial,\n antispoof: Partial,\n liveness: Partial,\n gear: Partial,\n}\n\n/** Configures all body detection specific options */\nexport interface BodyConfig extends GenericConfig {\n /** maximum number of detected bodies */\n maxDetected: number,\n /** minimum confidence for a detected body before results are discarded */\n minConfidence: number,\n /* experimental\n /** experimental: detector used for body model before actual analysis\n detector?: {\n /** experimental: enable body detector before body landmarks\n enabled: boolean,\n /** experimental: path to optional body detector model json file\n modelPath: string,\n /** experimental: minimum confidence for a detected body before results are discarded\n minConfidence: number,\n /** experimental: minimum overlap between two detected bodies before one is discarded\n iouThreshold: number\n },\n */\n}\n\n/** Configures all hand detection specific options */\nexport interface HandConfig extends GenericConfig {\n /** should hand rotation correction be performed after hand detection? */\n rotation: boolean,\n /** minimum confidence for a detected hand before results are discarded */\n minConfidence: number,\n /** minimum overlap between two detected hands before one is discarded */\n iouThreshold: number,\n /** maximum number of detected hands */\n maxDetected: number,\n /** should hand landmarks be detected or just return detected hand box */\n landmarks: boolean,\n detector: {\n /** path to hand detector model json */\n modelPath?: string,\n },\n skeleton: {\n /** path to hand skeleton model json */\n modelPath?: string,\n },\n}\n\n/** Configures all object detection specific options */\nexport interface ObjectConfig extends GenericConfig {\n /** minimum confidence for a detected objects before results are discarded */\n minConfidence: number,\n /** minimum overlap between two detected objects before one is discarded */\n iouThreshold: number,\n /** maximum number of detected objects */\n maxDetected: number,\n}\n\n/** Configures all body segmentation module\n * removes background from input containing person\n * if segmentation is enabled it will run as preprocessing task before any other model\n * alternatively leave it disabled and use it on-demand using human.segmentation method which can\n * remove background or replace it with user-provided background\n*/\nexport interface SegmentationConfig extends GenericConfig {\n /** downsample ratio, adjust to reflect approximately how much of input is taken by body */\n ratio: number,\n /** possible rvm segmentation mode */\n mode: SegmentationEnum,\n}\n\n/** Run input through image filters before inference\n * - available only in Browser environments\n * - image filters run with near-zero latency as they are executed on the GPU using WebGL\n*/\nexport interface FilterConfig {\n /** are image filters enabled? */\n enabled: boolean,\n /** perform image histogram equalization\n * - equalization is performed on input as a whole and detected face before its passed for further analysis\n */\n equalization: boolean,\n /** resize input width\n * - if both width and height are set to 0, there is no resizing\n * - if just one is set, second one is scaled automatically\n * - if both are set, values are used as-is\n */\n width: number,\n /** resize input height\n * - if both width and height are set to 0, there is no resizing\n * - if just one is set, second one is scaled automatically\n * - if both are set, values are used as-is\n */\n height: number,\n /** return processed canvas imagedata in result */\n return: boolean,\n /** flip input as mirror image */\n flip: boolean,\n /** apply auto-brighness */\n autoBrightness: boolean,\n /** range: -1 (darken) to 1 (lighten) */\n brightness: number,\n /** range: -1 (reduce contrast) to 1 (increase contrast) */\n contrast: number,\n /** range: 0 (no sharpening) to 1 (maximum sharpening) */\n sharpness: number,\n /** range: 0 (no blur) to N (blur radius in pixels) */\n blur: number\n /** range: -1 (reduce saturation) to 1 (increase saturation) */\n saturation: number,\n /** range: 0 (no change) to 360 (hue rotation in degrees) */\n hue: number,\n /** image negative */\n negative: boolean,\n /** image sepia colors */\n sepia: boolean,\n /** image vintage colors */\n vintage: boolean,\n /** image kodachrome colors */\n kodachrome: boolean,\n /** image technicolor colors */\n technicolor: boolean,\n /** image polaroid camera effect */\n polaroid: boolean,\n /** range: 0 (no pixelate) to N (number of pixels to pixelate) */\n pixelate: number,\n}\n\n/** Controlls gesture detection */\nexport interface GestureConfig {\n /** is gesture detection enabled? */\n enabled: boolean,\n}\n/**\n * Configuration interface definition for **Human** library\n * Contains all configurable parameters\n * Defaults: [config](https://github.com/vladmandic/human/blob/main/src/config.ts#L262)\n */\nexport interface Config {\n /** Backend used for TFJS operations\n * valid build-in backends are:\n * - Browser: `cpu`, `wasm`, `webgl`, `humangl`, `webgpu`\n * - NodeJS: `cpu`, `wasm`, `tensorflow`\n * default: `webgl` for browser and `tensorflow` for nodejs\n */\n backend: BackendEnum,\n\n /** Path to *.wasm files if backend is set to `wasm`\n *\n * default: auto-detects to link to CDN `jsdelivr` when running in browser\n */\n wasmPath: string,\n\n /** Force WASM loader to use platform fetch\n *\n * default: false\n */\n wasmPlatformFetch: boolean,\n\n /** Print debug statements to console\n *\n * default: `true`\n */\n debug: boolean,\n\n /** Perform model loading and inference concurrently or sequentially\n *\n * default: `true`\n */\n async: boolean,\n\n /** What to use for `human.warmup()`\n * - warmup pre-initializes all models for faster inference but can take significant time on startup\n * - used by `webgl`, `humangl` and `webgpu` backends\n *\n * default: `full`\n */\n warmup: WarmupEnum,\n\n /** Base model path (typically starting with file://, http:// or https://) for all models\n * - individual modelPath values are relative to this path\n *\n * default: `../models/` for browsers and `file://models/` for nodejs\n */\n modelBasePath: string,\n\n /** Cache models in IndexDB on first sucessfull load\n * default: true if indexdb is available (browsers), false if its not (nodejs)\n */\n cacheModels: boolean,\n\n /** Validate kernel ops used in model during model load\n * default: true\n * any errors will be printed on console but will be treated as non-fatal\n */\n validateModels: boolean,\n\n /** Cache sensitivity\n * - values 0..1 where 0.01 means reset cache if input changed more than 1%\n * - set to 0 to disable caching\n *\n * default: 0.7\n */\n cacheSensitivity: number;\n\n /** Explicit flags passed to initialize TFJS */\n flags: Record,\n\n /** Software Kernels\n * Registers software kernel ops running on CPU when accelerated version of kernel is not found in the current backend\n */\n softwareKernels: boolean,\n\n /** Perform immediate garbage collection on deallocated tensors instead of caching them */\n deallocate: boolean;\n\n /** Internal Variable */\n skipAllowed: boolean;\n\n /** Filter config {@link FilterConfig} */\n filter: Partial,\n\n /** Gesture config {@link GestureConfig} */\n gesture: Partial;\n\n /** Face config {@link FaceConfig} */\n face: Partial,\n\n /** Body config {@link BodyConfig} */\n body: Partial,\n\n /** Hand config {@link HandConfig} */\n hand: Partial,\n\n /** Object config {@link ObjectConfig} */\n object: Partial,\n\n /** Segmentation config {@link SegmentationConfig} */\n segmentation: Partial,\n}\n\n/** - [See all default Config values...](https://github.com/vladmandic/human/blob/main/src/config.ts#L262) */\nconst config: Config = {\n backend: '',\n modelBasePath: '',\n cacheModels: true,\n validateModels: true,\n wasmPath: '',\n wasmPlatformFetch: false,\n debug: false,\n async: true,\n warmup: 'full',\n cacheSensitivity: 0.70,\n skipAllowed: false,\n deallocate: false,\n flags: {},\n softwareKernels: false,\n filter: {\n enabled: true,\n equalization: false,\n width: 0,\n height: 0,\n flip: false,\n return: true,\n autoBrightness: true,\n brightness: 0,\n contrast: 0,\n sharpness: 0,\n blur: 0,\n saturation: 0,\n hue: 0,\n negative: false,\n sepia: false,\n vintage: false,\n kodachrome: false,\n technicolor: false,\n polaroid: false,\n pixelate: 0,\n },\n gesture: {\n enabled: true,\n },\n face: {\n enabled: true,\n detector: {\n modelPath: 'blazeface.json',\n rotation: false,\n maxDetected: 1,\n skipFrames: 99,\n skipTime: 2500,\n minConfidence: 0.2,\n minSize: 0,\n iouThreshold: 0.1,\n mask: false,\n return: false,\n },\n mesh: {\n enabled: true,\n modelPath: 'facemesh.json',\n keepInvalid: false,\n },\n attention: {\n enabled: false,\n modelPath: 'facemesh-attention.json',\n },\n iris: {\n enabled: true,\n modelPath: 'iris.json',\n },\n emotion: {\n enabled: true,\n minConfidence: 0.1,\n skipFrames: 99,\n skipTime: 1500,\n modelPath: 'emotion.json',\n },\n description: {\n enabled: true,\n modelPath: 'faceres.json',\n skipFrames: 99,\n skipTime: 3000,\n minConfidence: 0.1,\n },\n antispoof: {\n enabled: false,\n skipFrames: 99,\n skipTime: 4000,\n modelPath: 'antispoof.json',\n },\n liveness: {\n enabled: false,\n skipFrames: 99,\n skipTime: 4000,\n modelPath: 'liveness.json',\n },\n },\n body: {\n enabled: true,\n modelPath: 'movenet-lightning.json',\n maxDetected: -1,\n minConfidence: 0.3,\n skipFrames: 1,\n skipTime: 200,\n },\n hand: {\n enabled: true,\n rotation: true,\n skipFrames: 99,\n skipTime: 1000,\n minConfidence: 0.50,\n iouThreshold: 0.2,\n maxDetected: -1,\n landmarks: true,\n detector: {\n modelPath: 'handtrack.json',\n },\n skeleton: {\n modelPath: 'handlandmark-lite.json',\n },\n },\n object: {\n enabled: false,\n modelPath: 'centernet.json',\n minConfidence: 0.2,\n iouThreshold: 0.4,\n maxDetected: 10,\n skipFrames: 99,\n skipTime: 2000,\n },\n segmentation: {\n enabled: false,\n modelPath: 'rvm.json',\n ratio: 0.5,\n mode: 'default',\n },\n};\n\nexport { config as defaults };\n", "export const vertexIdentity = `\n precision highp float;\n attribute vec2 pos;\n attribute vec2 uv;\n varying vec2 vUv;\n uniform float flipY;\n void main(void) {\n vUv = uv;\n gl_Position = vec4(pos.x, pos.y*flipY, 0.0, 1.);\n }\n`;\n\nexport const fragmentIdentity = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n void main(void) {\n gl_FragColor = texture2D(texture, vUv);\n }\n`;\n\nexport const colorMatrixWithAlpha = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform float m[20];\n void main(void) {\n vec4 c = texture2D(texture, vUv);\n gl_FragColor.r = m[0] * c.r + m[1] * c.g + m[2] * c.b + m[3] * c.a + m[4];\n gl_FragColor.g = m[5] * c.r + m[6] * c.g + m[7] * c.b + m[8] * c.a + m[9];\n gl_FragColor.b = m[10] * c.r + m[11] * c.g + m[12] * c.b + m[13] * c.a + m[14];\n gl_FragColor.a = m[15] * c.r + m[16] * c.g + m[17] * c.b + m[18] * c.a + m[19];\n }\n`;\n\nexport const colorMatrixWithoutAlpha = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform float m[20];\n void main(void) {\n vec4 c = texture2D(texture, vUv);\n gl_FragColor.r = m[0] * c.r + m[1] * c.g + m[2] * c.b + m[4];\n gl_FragColor.g = m[5] * c.r + m[6] * c.g + m[7] * c.b + m[9];\n gl_FragColor.b = m[10] * c.r + m[11] * c.g + m[12] * c.b + m[14];\n gl_FragColor.a = c.a;\n }\n`;\n\nexport const pixelate = `\n precision highp float;\n varying vec2 vUv;\n uniform vec2 size;\n uniform sampler2D texture;\n vec2 pixelate(vec2 coord, vec2 size) {\n return floor( coord / size ) * size;\n }\n void main(void) {\n gl_FragColor = vec4(0.0);\n vec2 coord = pixelate(vUv, size);\n gl_FragColor += texture2D(texture, coord);\n }\n`;\n\nexport const blur = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform vec2 px;\n void main(void) {\n gl_FragColor = vec4(0.0);\n gl_FragColor += texture2D(texture, vUv + vec2(-7.0*px.x, -7.0*px.y))*0.0044299121055113265;\n gl_FragColor += texture2D(texture, vUv + vec2(-6.0*px.x, -6.0*px.y))*0.00895781211794;\n gl_FragColor += texture2D(texture, vUv + vec2(-5.0*px.x, -5.0*px.y))*0.0215963866053;\n gl_FragColor += texture2D(texture, vUv + vec2(-4.0*px.x, -4.0*px.y))*0.0443683338718;\n gl_FragColor += texture2D(texture, vUv + vec2(-3.0*px.x, -3.0*px.y))*0.0776744219933;\n gl_FragColor += texture2D(texture, vUv + vec2(-2.0*px.x, -2.0*px.y))*0.115876621105;\n gl_FragColor += texture2D(texture, vUv + vec2(-1.0*px.x, -1.0*px.y))*0.147308056121;\n gl_FragColor += texture2D(texture, vUv )*0.159576912161;\n gl_FragColor += texture2D(texture, vUv + vec2( 1.0*px.x, 1.0*px.y))*0.147308056121;\n gl_FragColor += texture2D(texture, vUv + vec2( 2.0*px.x, 2.0*px.y))*0.115876621105;\n gl_FragColor += texture2D(texture, vUv + vec2( 3.0*px.x, 3.0*px.y))*0.0776744219933;\n gl_FragColor += texture2D(texture, vUv + vec2( 4.0*px.x, 4.0*px.y))*0.0443683338718;\n gl_FragColor += texture2D(texture, vUv + vec2( 5.0*px.x, 5.0*px.y))*0.0215963866053;\n gl_FragColor += texture2D(texture, vUv + vec2( 6.0*px.x, 6.0*px.y))*0.00895781211794;\n gl_FragColor += texture2D(texture, vUv + vec2( 7.0*px.x, 7.0*px.y))*0.0044299121055113265;\n }\n`;\n\nexport const convolution = `\n precision highp float;\n varying vec2 vUv;\n uniform sampler2D texture;\n uniform vec2 px;\n uniform float m[9];\n void main(void) {\n vec4 c11 = texture2D(texture, vUv - px); // top left\n vec4 c12 = texture2D(texture, vec2(vUv.x, vUv.y - px.y)); // top center\n vec4 c13 = texture2D(texture, vec2(vUv.x + px.x, vUv.y - px.y)); // top right\n vec4 c21 = texture2D(texture, vec2(vUv.x - px.x, vUv.y) ); // mid left\n vec4 c22 = texture2D(texture, vUv); // mid center\n vec4 c23 = texture2D(texture, vec2(vUv.x + px.x, vUv.y) ); // mid right\n vec4 c31 = texture2D(texture, vec2(vUv.x - px.x, vUv.y + px.y) ); // bottom left\n vec4 c32 = texture2D(texture, vec2(vUv.x, vUv.y + px.y) ); // bottom center\n vec4 c33 = texture2D(texture, vUv + px ); // bottom right\n gl_FragColor = \n c11 * m[0] + c12 * m[1] + c22 * m[2] +\n c21 * m[3] + c22 * m[4] + c23 * m[5] +\n c31 * m[6] + c32 * m[7] + c33 * m[8];\n gl_FragColor.a = c22.a;\n }\n`;\n", "/**\n * Image Filters in WebGL algoritm implementation\n * Based on: [WebGLImageFilter](https://github.com/phoboslab/WebGLImageFilter)\n */\n\n/* eslint-disable func-names */\n\nimport * as shaders from './imagefxshaders';\nimport { canvas } from './image';\nimport { log } from '../util/util';\n\nconst collect = (source, prefix: string, collection) => {\n const r = new RegExp('\\\\b' + prefix + ' \\\\w+ (\\\\w+)', 'ig');\n source.replace(r, (match, name) => {\n collection[name] = 0;\n return match;\n });\n};\n\nclass GLProgram {\n uniform = {};\n attribute = {};\n gl: WebGLRenderingContext;\n id: WebGLProgram;\n\n constructor(gl, vertexSource, fragmentSource) {\n this.gl = gl;\n const vertexShader = this.compile(vertexSource, this.gl.VERTEX_SHADER);\n const fragmentShader = this.compile(fragmentSource, this.gl.FRAGMENT_SHADER);\n this.id = this.gl.createProgram() as WebGLProgram;\n if (!vertexShader || !fragmentShader) return;\n if (!this.id) {\n log('filter: could not create webgl program');\n return;\n }\n this.gl.attachShader(this.id, vertexShader);\n this.gl.attachShader(this.id, fragmentShader);\n this.gl.linkProgram(this.id);\n if (!this.gl.getProgramParameter(this.id, this.gl.LINK_STATUS)) {\n log(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id) || 'unknown'}`);\n return;\n }\n this.gl.useProgram(this.id);\n collect(vertexSource, 'attribute', this.attribute); // Collect attributes\n for (const a in this.attribute) this.attribute[a] = this.gl.getAttribLocation(this.id, a);\n collect(vertexSource, 'uniform', this.uniform); // Collect uniforms\n collect(fragmentSource, 'uniform', this.uniform);\n for (const u in this.uniform) this.uniform[u] = this.gl.getUniformLocation(this.id, u);\n }\n\n compile = (source, type): WebGLShader | null => {\n const shader = this.gl.createShader(type);\n if (!shader) {\n log('filter: could not create shader');\n return null;\n }\n this.gl.shaderSource(shader, source);\n this.gl.compileShader(shader);\n if (!this.gl.getShaderParameter(shader, this.gl.COMPILE_STATUS)) {\n log(`filter: gl compile failed: ${this.gl.getShaderInfoLog(shader) || 'unknown'}`);\n return null;\n }\n return shader;\n };\n}\n\n// function that is instantiated as class so it has private this members\n/**\n * @class GLImageFilter\n * @property {function} reset reset current filter chain\n * @property {function} add add specified filter to filter chain\n * @property {function} apply execute filter chain and draw result\n * @property {function} draw just draw input to result\n */\n\nexport function GLImageFilter() {\n let drawCount = 0;\n let sourceTexture: WebGLTexture | null = null;\n let lastInChain = false;\n let currentFramebufferIndex = -1;\n let tempFramebuffers: [null, null] | [{ fbo: WebGLFramebuffer | null, texture: WebGLTexture | null }] = [null, null];\n let filterChain: Record[] = [];\n let vertexBuffer: WebGLBuffer | null = null;\n let currentProgram: GLProgram | null = null;\n const fxcanvas = canvas(100, 100) as HTMLCanvasElement;\n const shaderProgramCache = { }; // key is the shader program source, value is the compiled program\n const DRAW = { INTERMEDIATE: 1 };\n const gl = fxcanvas.getContext('webgl') as WebGLRenderingContext;\n if (!gl) {\n log('filter: cannot get webgl context');\n return;\n }\n // @ts-ignore used for sanity checks outside of imagefx\n this.gl = gl;\n\n function resize(width, height) {\n if (width === fxcanvas.width && height === fxcanvas.height) return; // Same width/height? Nothing to do here\n fxcanvas.width = width;\n fxcanvas.height = height;\n if (!vertexBuffer) { // Create the context if we don't have it yet\n const vertices = new Float32Array([-1, -1, 0, 1, 1, -1, 1, 1, -1, 1, 0, 0, -1, 1, 0, 0, 1, -1, 1, 1, 1, 1, 1, 0]); // Create the vertex buffer for the two triangles [x, y, u, v] * 6\n vertexBuffer = gl.createBuffer();\n gl.bindBuffer(gl.ARRAY_BUFFER, vertexBuffer);\n gl.bufferData(gl.ARRAY_BUFFER, vertices, gl.STATIC_DRAW);\n gl.pixelStorei(gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, true);\n }\n gl.viewport(0, 0, fxcanvas.width, fxcanvas.height);\n tempFramebuffers = [null, null]; // Delete old temp framebuffers\n }\n\n function createFramebufferTexture(width, height) {\n const fbo = gl.createFramebuffer();\n gl.bindFramebuffer(gl.FRAMEBUFFER, fbo);\n const renderbuffer = gl.createRenderbuffer();\n gl.bindRenderbuffer(gl.RENDERBUFFER, renderbuffer);\n const texture = gl.createTexture();\n gl.bindTexture(gl.TEXTURE_2D, texture);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, width, height, 0, gl.RGBA, gl.UNSIGNED_BYTE, null);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.framebufferTexture2D(gl.FRAMEBUFFER, gl.COLOR_ATTACHMENT0, gl.TEXTURE_2D, texture, 0);\n gl.bindTexture(gl.TEXTURE_2D, null);\n gl.bindFramebuffer(gl.FRAMEBUFFER, null);\n return { fbo, texture };\n }\n\n function getTempFramebuffer(index): { fbo: WebGLFramebuffer | null, texture: WebGLTexture | null } {\n tempFramebuffers[index] = tempFramebuffers[index] || createFramebufferTexture(fxcanvas.width, fxcanvas.height);\n return tempFramebuffers[index] as { fbo: WebGLFramebuffer, texture: WebGLTexture };\n }\n\n function draw(flags = 0) {\n if (!currentProgram) return;\n let source: WebGLTexture | null = null;\n let target: WebGLFramebuffer | null = null;\n let flipY = false;\n if (drawCount === 0) source = sourceTexture; // First draw call - use the source texture\n else source = getTempFramebuffer(currentFramebufferIndex).texture || null; // All following draw calls use the temp buffer last drawn to\n drawCount++;\n if (lastInChain && !(flags & DRAW.INTERMEDIATE)) { // Last filter in our chain - draw directly to the WebGL Canvas. We may also have to flip the image vertically now\n target = null;\n flipY = drawCount % 2 === 0;\n } else {\n currentFramebufferIndex = (currentFramebufferIndex + 1) % 2;\n target = getTempFramebuffer(currentFramebufferIndex).fbo || null; // Intermediate draw call - get a temp buffer to draw to\n }\n gl.bindTexture(gl.TEXTURE_2D, source); // Bind the source and target and draw the two triangles\n gl.bindFramebuffer(gl.FRAMEBUFFER, target);\n gl.uniform1f(currentProgram.uniform['flipY'], (flipY ? -1 : 1));\n gl.drawArrays(gl.TRIANGLES, 0, 6);\n }\n\n function compileShader(fragmentSource): GLProgram | null {\n if (shaderProgramCache[fragmentSource]) {\n currentProgram = shaderProgramCache[fragmentSource];\n gl.useProgram((currentProgram ? currentProgram.id : null) || null);\n return currentProgram;\n }\n currentProgram = new GLProgram(gl, shaders.vertexIdentity, fragmentSource);\n if (!currentProgram) {\n log('filter: could not get webgl program');\n return null;\n }\n const floatSize = Float32Array.BYTES_PER_ELEMENT;\n const vertSize = 4 * floatSize;\n gl.enableVertexAttribArray(currentProgram.attribute['pos']);\n gl.vertexAttribPointer(currentProgram.attribute['pos'], 2, gl.FLOAT, false, vertSize, 0 * floatSize);\n gl.enableVertexAttribArray(currentProgram.attribute['uv']);\n gl.vertexAttribPointer(currentProgram.attribute['uv'], 2, gl.FLOAT, false, vertSize, 2 * floatSize);\n shaderProgramCache[fragmentSource] = currentProgram;\n return currentProgram;\n }\n\n const filter = {\n colorMatrix: (matrix: number[]) => { // general color matrix filter\n const m = new Float32Array(matrix);\n m[4] /= 255;\n m[9] /= 255;\n m[14] /= 255;\n m[19] /= 255;\n const shader = (m[18] === 1 && m[3] === 0 && m[8] === 0 && m[13] === 0 && m[15] === 0 && m[16] === 0 && m[17] === 0 && m[19] === 0) // Can we ignore the alpha value? Makes things a bit faster.\n ? shaders.colorMatrixWithoutAlpha\n : shaders.colorMatrixWithAlpha;\n const program = compileShader(shader);\n if (!program) return;\n gl.uniform1fv(program.uniform['m'], m);\n draw();\n },\n\n brightness: (brightness: number) => {\n const b = (brightness || 0) + 1;\n filter.colorMatrix([\n b, 0, 0, 0, 0,\n 0, b, 0, 0, 0,\n 0, 0, b, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n saturation: (amount: number) => {\n const x = (amount || 0) * 2 / 3 + 1;\n const y = ((x - 1) * -0.5);\n filter.colorMatrix([\n x, y, y, 0, 0,\n y, x, y, 0, 0,\n y, y, x, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n desaturate: () => {\n filter.saturation(-1);\n },\n\n contrast: (amount: number) => {\n const v = (amount || 0) + 1;\n const o = -128 * (v - 1);\n filter.colorMatrix([\n v, 0, 0, 0, o,\n 0, v, 0, 0, o,\n 0, 0, v, 0, o,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n negative: () => {\n filter.contrast(-2);\n },\n\n hue: (rotation: number) => {\n rotation = (rotation || 0) / 180 * Math.PI;\n const cos = Math.cos(rotation);\n const sin = Math.sin(rotation);\n const lumR = 0.213;\n const lumG = 0.715;\n const lumB = 0.072;\n filter.colorMatrix([\n lumR + cos * (1 - lumR) + sin * (-lumR), lumG + cos * (-lumG) + sin * (-lumG), lumB + cos * (-lumB) + sin * (1 - lumB), 0, 0,\n lumR + cos * (-lumR) + sin * (0.143), lumG + cos * (1 - lumG) + sin * (0.140), lumB + cos * (-lumB) + sin * (-0.283), 0, 0,\n lumR + cos * (-lumR) + sin * (-(1 - lumR)), lumG + cos * (-lumG) + sin * (lumG), lumB + cos * (1 - lumB) + sin * (lumB), 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n desaturateLuminance: () => {\n filter.colorMatrix([\n 0.2764723, 0.9297080, 0.0938197, 0, -37.1,\n 0.2764723, 0.9297080, 0.0938197, 0, -37.1,\n 0.2764723, 0.9297080, 0.0938197, 0, -37.1,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n sepia: () => {\n filter.colorMatrix([\n 0.393, 0.7689999, 0.18899999, 0, 0,\n 0.349, 0.6859999, 0.16799999, 0, 0,\n 0.272, 0.5339999, 0.13099999, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n brownie: () => {\n filter.colorMatrix([\n 0.5997023498159715, 0.34553243048391263, -0.2708298674538042, 0, 47.43192855600873,\n -0.037703249837783157, 0.8609577587992641, 0.15059552388459913, 0, -36.96841498319127,\n 0.24113635128153335, -0.07441037908422492, 0.44972182064877153, 0, -7.562075277591283,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n vintagePinhole: () => {\n filter.colorMatrix([\n 0.6279345635605994, 0.3202183420819367, -0.03965408211312453, 0, 9.651285835294123,\n 0.02578397704808868, 0.6441188644374771, 0.03259127616149294, 0, 7.462829176470591,\n 0.0466055556782719, -0.0851232987247891, 0.5241648018700465, 0, 5.159190588235296,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n kodachrome: () => {\n filter.colorMatrix([\n 1.1285582396593525, -0.3967382283601348, -0.03992559172921793, 0, 63.72958762196502,\n -0.16404339962244616, 1.0835251566291304, -0.05498805115633132, 0, 24.732407896706203,\n -0.16786010706155763, -0.5603416277695248, 1.6014850761964943, 0, 35.62982807460946,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n technicolor: () => {\n filter.colorMatrix([\n 1.9125277891456083, -0.8545344976951645, -0.09155508482755585, 0, 11.793603434377337,\n -0.3087833385928097, 1.7658908555458428, -0.10601743074722245, 0, -70.35205161461398,\n -0.231103377548616, -0.7501899197440212, 1.847597816108189, 0, 30.950940869491138,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n polaroid: () => {\n filter.colorMatrix([\n 1.438, -0.062, -0.062, 0, 0,\n -0.122, 1.378, -0.122, 0, 0,\n -0.016, -0.016, 1.483, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n shiftToBGR: () => {\n filter.colorMatrix([\n 0, 0, 1, 0, 0,\n 0, 1, 0, 0, 0,\n 1, 0, 0, 0, 0,\n 0, 0, 0, 1, 0,\n ]);\n },\n\n convolution: (matrix: number[]) => { // general convolution Filter\n const m = new Float32Array(matrix);\n const pixelSizeX = 1 / fxcanvas.width;\n const pixelSizeY = 1 / fxcanvas.height;\n const program = compileShader(shaders.convolution);\n if (!program) return;\n gl.uniform1fv(program.uniform['m'], m);\n gl.uniform2f(program.uniform['px'], pixelSizeX, pixelSizeY);\n draw();\n },\n\n detectEdges: () => {\n // @ts-ignore this\n filter.convolution.call(this, [\n 0, 1, 0,\n 1, -4, 1,\n 0, 1, 0,\n ]);\n },\n\n sobelX: () => {\n // @ts-ignore this\n filter.convolution.call(this, [\n -1, 0, 1,\n -2, 0, 2,\n -1, 0, 1,\n ]);\n },\n\n sobelY: () => {\n // @ts-ignore this\n filter.convolution.call(this, [\n -1, -2, -1,\n 0, 0, 0,\n 1, 2, 1,\n ]);\n },\n\n sharpen: (amount) => {\n const a = amount || 1;\n // @ts-ignore this\n filter.convolution.call(this, [\n 0, -1 * a, 0,\n -1 * a, 1 + 4 * a, -1 * a,\n 0, -1 * a, 0,\n ]);\n },\n\n emboss: (size: number) => {\n const s = size || 1;\n // @ts-ignore this\n filter.convolution.call(this, [\n -2 * s, -1 * s, 0,\n -1 * s, 1, 1 * s,\n 0, 1 * s, 2 * s,\n ]);\n },\n\n blur: (size: number) => {\n const blurSizeX = (size / 7) / fxcanvas.width;\n const blurSizeY = (size / 7) / fxcanvas.height;\n const program = compileShader(shaders.blur);\n if (!program) return;\n // Vertical\n gl.uniform2f(program.uniform['px'], 0, blurSizeY);\n draw(DRAW.INTERMEDIATE);\n // Horizontal\n gl.uniform2f(program.uniform['px'], blurSizeX, 0);\n draw();\n },\n\n pixelate: (size: number) => {\n const blurSizeX = (size) / fxcanvas.width;\n const blurSizeY = (size) / fxcanvas.height;\n const program = compileShader(shaders.pixelate);\n if (!program) return;\n gl.uniform2f(program.uniform['size'], blurSizeX, blurSizeY);\n draw();\n },\n };\n\n // @ts-ignore this\n this.add = function (name) {\n const args = Array.prototype.slice.call(arguments, 1); // eslint-disable-line prefer-rest-params\n const func = filter[name];\n filterChain.push({ func, args });\n };\n\n // @ts-ignore this\n this.reset = function () {\n filterChain = [];\n };\n\n // @ts-ignore this\n this.get = function () {\n return filterChain;\n };\n\n // @ts-ignore this\n this.apply = function (image) {\n resize(image.width, image.height);\n drawCount = 0;\n if (!sourceTexture) sourceTexture = gl.createTexture(); // Create the texture for the input image if we haven't yet\n gl.bindTexture(gl.TEXTURE_2D, sourceTexture);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.NEAREST);\n gl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MAG_FILTER, gl.NEAREST);\n gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, image);\n for (let i = 0; i < filterChain.length; i++) {\n lastInChain = (i === filterChain.length - 1);\n const f = filterChain[i];\n // @ts-ignore function assigment\n f.func.apply(this, f.args || []);\n }\n return fxcanvas;\n };\n\n // @ts-ignore this\n this.draw = function (image) {\n this.add('brightness', 0);\n return this.apply(image);\n };\n}\n", "/**\n * Image enhancements\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Tensor } from '../tfjs/types';\n\nexport async function histogramEqualization(inputImage: Tensor): Promise {\n const squeeze = inputImage.shape.length === 4 ? tf.squeeze(inputImage) : inputImage;\n const rgb = tf.split(squeeze, 3, 2);\n const min: Tensor[] = [tf.min(rgb[0]), tf.min(rgb[1]), tf.min(rgb[2])]; // minimum pixel value per channel T[]\n const max: Tensor[] = [tf.max(rgb[0]), tf.max(rgb[1]), tf.max(rgb[2])]; // maximum pixel value per channel T[]\n // const absMin = await Promise.all(min.map((channel) => channel.data())); // minimum pixel value per channel A[]\n // const minValue = Math.min(absMax[0][0], absMin[1][0], absMin[2][0]);\n const absMax = await Promise.all(max.map((channel) => channel.data())); // maximum pixel value per channel A[]\n const maxValue = Math.max(absMax[0][0], absMax[1][0], absMax[2][0]);\n const maxRange = maxValue > 1 ? 255 : 1;\n const factor = maxRange / maxValue;\n let final: Tensor;\n if (factor > 1) {\n const sub = [tf.sub(rgb[0], min[0]), tf.sub(rgb[1], min[1]), tf.sub(rgb[2], min[2])]; // channels offset by min values\n const range = [tf.sub(max[0], min[0]), tf.sub(max[1], min[1]), tf.sub(max[2], min[2])]; // channel ranges\n // const fact = [tf.div(maxRange, absMax[0]), tf.div(maxRange, absMax[1]), tf.div(maxRange, absMax[1])]; // factors between\n const enh = [tf.mul(sub[0], factor), tf.mul(sub[1], factor), tf.mul(sub[2], factor)];\n const stack = tf.stack([enh[0], enh[1], enh[2]], 2);\n final = tf.reshape(stack, [1, squeeze.shape[0] || 0, squeeze.shape[1] || 0, 3]);\n tf.dispose([...sub, ...range, ...enh, stack]);\n } else {\n final = tf.expandDims(squeeze, 0);\n }\n tf.dispose([...rgb, ...min, ...max, rgb, squeeze, inputImage]);\n return final;\n}\n", "/**\n * Image Processing algorithm implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as fxImage from './imagefx';\nimport type { Input, AnyCanvas, Config } from '../exports';\nimport type { Tensor, Tensor3D, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\nimport { log } from '../util/util';\nimport * as enhance from './enhance';\n\nconst maxSize = 3840;\n// internal temp canvases\nlet inCanvas: AnyCanvas | null = null; // use global variable to avoid recreating canvas on each frame\nlet outCanvas: AnyCanvas | null = null; // use global variable to avoid recreating canvas on each frame\nlet tmpCanvas: AnyCanvas | null = null; // use global variable to avoid recreating canvas on each frame\n// @ts-ignore // imagefx is js module that should be converted to a class\nlet fx: fxImage.GLImageFilter | null; // eslint-disable-line @typescript-eslint/no-redundant-type-constituents\n\nconst last: { inputSum: number, cacheDiff: number, sumMethod: number, inputTensor: undefined | Tensor } = {\n inputSum: 0,\n cacheDiff: 1,\n sumMethod: 0,\n inputTensor: undefined,\n};\n\nexport function reset() {\n last.inputSum = 0;\n last.cacheDiff = 1;\n last.sumMethod = 0;\n last.inputTensor = undefined;\n}\n\nexport function canvas(width: number, height: number): AnyCanvas {\n let c: AnyCanvas;\n if (env.browser) { // browser defines canvas object\n if (env.worker) { // if runing in web worker use OffscreenCanvas\n if (typeof OffscreenCanvas === 'undefined') throw new Error('canvas error: attempted to run in web worker but OffscreenCanvas is not supported');\n c = new OffscreenCanvas(width, height);\n } else { // otherwise use DOM canvas\n if (typeof document !== 'undefined') {\n c = document.createElement('canvas');\n c.width = width;\n c.height = height;\n } else if (typeof navigator !== 'undefined' && navigator.product === 'ReactNative') {\n // @ts-ignore // env.canvas is an external monkey-patch\n if (typeof env.Canvas !== 'undefined') c = new env.Canvas(width, height);\n else if (typeof globalThis.Canvas !== 'undefined') c = new globalThis.Canvas(width, height);\n else throw new Error('canvas error: attempted to use canvas in react-native without canvas support installed');\n } else {\n throw new Error('canvas error: attempted to run in browser but DOM is not defined');\n }\n }\n } else { // if not running in browser, there is no \"default\" canvas object, so we need monkey patch or fail\n // @ts-ignore // env.canvas is an external monkey-patch\n if (typeof env.Canvas !== 'undefined') c = new env.Canvas(width, height);\n else if (typeof globalThis.Canvas !== 'undefined') c = new globalThis.Canvas(width, height);\n // else throw new Error('canvas error: attempted to use canvas in nodejs without canvas support installed');\n }\n // @ts-ignore its either defined or we already threw an error\n return c;\n}\n\n// helper function to copy canvas from input to output\nexport function copy(input: AnyCanvas, output?: AnyCanvas) {\n const outputCanvas = output || canvas(input.width, input.height);\n const ctx = outputCanvas.getContext('2d') as CanvasRenderingContext2D;\n ctx.drawImage(input, 0, 0);\n return outputCanvas;\n}\n\n// process input image and return tensor\n// input can be tensor, imagedata, htmlimageelement, htmlvideoelement\n// input is resized and run through imagefx filter\nexport async function process(input: Input, config: Config, getTensor: boolean = true): Promise<{ tensor: Tensor4D | null, canvas: AnyCanvas | null }> {\n if (!input) {\n // throw new Error('input is missing');\n if (config.debug) log('input error: input is missing');\n return { tensor: null, canvas: null }; // video may become temporarily unavailable due to onresize\n }\n // sanity checks since different browsers do not implement all dom elements\n if (\n !(input instanceof tf.Tensor)\n && !(typeof Image !== 'undefined' && input instanceof Image)\n && !(typeof globalThis.Canvas !== 'undefined' && input instanceof globalThis.Canvas)\n && !(typeof ImageData !== 'undefined' && input instanceof ImageData)\n && !(typeof ImageBitmap !== 'undefined' && input instanceof ImageBitmap)\n && !(typeof HTMLImageElement !== 'undefined' && input instanceof HTMLImageElement)\n && !(typeof HTMLMediaElement !== 'undefined' && input instanceof HTMLMediaElement)\n && !(typeof HTMLVideoElement !== 'undefined' && input instanceof HTMLVideoElement)\n && !(typeof HTMLCanvasElement !== 'undefined' && input instanceof HTMLCanvasElement)\n && !(typeof OffscreenCanvas !== 'undefined' && input instanceof OffscreenCanvas)\n ) {\n throw new Error('input error: type not recognized');\n }\n if (input instanceof tf.Tensor) { // if input is tensor use as-is without filters but correct shape as needed\n let tensor: Tensor | null = null;\n if (input['isDisposedInternal']) throw new Error('input error: attempted to use tensor but it is disposed');\n if (!(input as Tensor).shape) throw new Error('input error: attempted to use tensor without a shape');\n if ((input as Tensor).shape.length === 3) { // [height, width, 3 || 4]\n if ((input as Tensor).shape[2] === 3) { // [height, width, 3] so add batch\n tensor = tf.expandDims(input, 0);\n } else if ((input as Tensor).shape[2] === 4) { // [height, width, 4] so strip alpha and add batch\n const rgb = tf.slice3d(input as Tensor3D, [0, 0, 0], [-1, -1, 3]);\n tensor = tf.expandDims(rgb, 0);\n tf.dispose(rgb);\n }\n } else if ((input as Tensor).shape.length === 4) { // [1, width, height, 3 || 4]\n if ((input as Tensor).shape[3] === 3) { // [1, width, height, 3] just clone\n tensor = tf.clone(input);\n } else if ((input as Tensor).shape[3] === 4) { // [1, width, height, 4] so strip alpha\n tensor = tf.slice4d(input as Tensor4D, [0, 0, 0, 0], [-1, -1, -1, 3]);\n }\n }\n // at the end shape must be [1, height, width, 3]\n if (tensor == null || tensor.shape.length !== 4 || tensor.shape[0] !== 1 || tensor.shape[3] !== 3) throw new Error(`input error: attempted to use tensor with unrecognized shape: ${((input as Tensor).shape).toString()}`);\n if ((tensor).dtype === 'int32') {\n const cast = tf.cast(tensor, 'float32');\n tf.dispose(tensor);\n tensor = cast;\n }\n return { tensor: tensor as Tensor4D, canvas: (config.filter.return ? outCanvas : null) };\n }\n // check if resizing will be needed\n if (typeof input['readyState'] !== 'undefined' && (input as HTMLMediaElement).readyState <= 2) {\n if (config.debug) log('input stream is not ready');\n return { tensor: null, canvas: inCanvas }; // video may become temporarily unavailable due to onresize\n }\n const originalWidth: number = input['naturalWidth'] || input['videoWidth'] || input['width'] || (input['shape'] && (input['shape'][1] > 0));\n const originalHeight: number = input['naturalHeight'] || input['videoHeight'] || input['height'] || (input['shape'] && (input['shape'][2] > 0));\n if (!originalWidth || !originalHeight) {\n if (config.debug) log('cannot determine input dimensions');\n return { tensor: null, canvas: inCanvas }; // video may become temporarily unavailable due to onresize\n }\n let targetWidth: number = originalWidth;\n let targetHeight: number = originalHeight;\n if (targetWidth > maxSize) {\n targetWidth = maxSize;\n targetHeight = Math.trunc(targetWidth * originalHeight / originalWidth);\n }\n if (targetHeight > maxSize) {\n targetHeight = maxSize;\n targetWidth = Math.trunc(targetHeight * originalWidth / originalHeight);\n }\n\n // create our canvas and resize it if needed\n if ((config.filter?.width || 0) > 0) targetWidth = config.filter.width as number;\n else if ((config.filter?.height || 0) > 0) targetWidth = originalWidth * ((config.filter.height || 0) / originalHeight);\n if ((config.filter.height || 0) > 0) targetHeight = config.filter.height as number;\n else if ((config.filter.width || 0) > 0) targetHeight = originalHeight * ((config.filter.width || 0) / originalWidth);\n if (!targetWidth || !targetHeight) throw new Error('input error: cannot determine dimension');\n if (!inCanvas || (inCanvas.width !== targetWidth) || (inCanvas.height !== targetHeight)) inCanvas = canvas(targetWidth, targetHeight);\n\n // draw input to our canvas\n const inCtx = inCanvas.getContext('2d') as CanvasRenderingContext2D;\n if ((typeof ImageData !== 'undefined') && (input instanceof ImageData)) {\n inCtx.putImageData(input, 0, 0);\n } else {\n if (config.filter.flip && typeof inCtx.translate !== 'undefined') {\n inCtx.translate(originalWidth, 0);\n inCtx.scale(-1, 1);\n inCtx.drawImage(input as AnyCanvas, 0, 0, originalWidth, originalHeight, 0, 0, inCanvas.width, inCanvas.height);\n inCtx.setTransform(1, 0, 0, 1, 0, 0); // resets transforms to defaults\n } else {\n inCtx.drawImage(input as AnyCanvas, 0, 0, originalWidth, originalHeight, 0, 0, inCanvas.width, inCanvas.height);\n }\n }\n\n if (!outCanvas || (inCanvas.width !== outCanvas.width) || (inCanvas.height !== outCanvas.height)) outCanvas = canvas(inCanvas.width, inCanvas.height); // init output canvas\n\n // imagefx transforms using gl from input canvas to output canvas\n if (config.filter.enabled && env.webgl.supported) {\n if (!fx) fx = env.browser ? new fxImage.GLImageFilter() : null; // && (typeof document !== 'undefined')\n env.filter = !!fx;\n if (!fx?.add) {\n if (config.debug) log('input process error: cannot initialize filters');\n env.webgl.supported = false;\n config.filter.enabled = false;\n copy(inCanvas, outCanvas); // filter failed to initialize\n // return { tensor: null, canvas: inCanvas };\n } else {\n fx.reset();\n if (config.filter.brightness !== 0) fx.add('brightness', config.filter.brightness);\n if (config.filter.contrast !== 0) fx.add('contrast', config.filter.contrast);\n if (config.filter.sharpness !== 0) fx.add('sharpen', config.filter.sharpness);\n if (config.filter.blur !== 0) fx.add('blur', config.filter.blur);\n if (config.filter.saturation !== 0) fx.add('saturation', config.filter.saturation);\n if (config.filter.hue !== 0) fx.add('hue', config.filter.hue);\n if (config.filter.negative) fx.add('negative');\n if (config.filter.sepia) fx.add('sepia');\n if (config.filter.vintage) fx.add('brownie');\n if (config.filter.sepia) fx.add('sepia');\n if (config.filter.kodachrome) fx.add('kodachrome');\n if (config.filter.technicolor) fx.add('technicolor');\n if (config.filter.polaroid) fx.add('polaroid');\n if (config.filter.pixelate !== 0) fx.add('pixelate', config.filter.pixelate);\n if (fx.get()?.length > 1) outCanvas = fx.apply(inCanvas);\n else outCanvas = fx.draw(inCanvas);\n }\n } else {\n copy(inCanvas, outCanvas); // if no filters applied, output canvas is input canvas\n if (fx) fx = null;\n env.filter = !!fx;\n }\n\n if (!getTensor) return { tensor: null, canvas: outCanvas }; // just canvas was requested\n if (!outCanvas) throw new Error('canvas error: cannot create output');\n\n // create tensor from image unless input was a tensor already\n let pixels;\n let depth = 3;\n if ((typeof ImageData !== 'undefined' && input instanceof ImageData) || ((input as ImageData).data && (input as ImageData).width && (input as ImageData).height)) { // if input is imagedata, just use it\n if (env.browser && tf.browser) {\n pixels = tf.browser ? tf.browser.fromPixels(input as ImageData) : null;\n } else {\n depth = (input as ImageData).data.length / (input as ImageData).height / (input as ImageData).width;\n // const arr = Uint8Array.from(input['data']);\n const arr = new Uint8Array((input as ImageData).data.buffer);\n pixels = tf.tensor(arr, [(input as ImageData).height, (input as ImageData).width, depth], 'int32');\n }\n } else {\n if (!tmpCanvas || (outCanvas.width !== tmpCanvas.width) || (outCanvas.height !== tmpCanvas.height)) tmpCanvas = canvas(outCanvas.width, outCanvas.height); // init output canvas\n if (tf.browser && env.browser) {\n if (config.backend === 'webgl' || config.backend === 'humangl' || config.backend === 'webgpu') {\n pixels = tf.browser.fromPixels(outCanvas as HTMLCanvasElement); // safe to reuse since both backend and context are gl based\n } else {\n tmpCanvas = copy(outCanvas); // cannot use output canvas as it already has gl context so we do a silly one more canvas\n pixels = tf.browser.fromPixels(tmpCanvas as HTMLCanvasElement);\n }\n } else {\n const tempCanvas = copy(outCanvas); // cannot use output canvas as it already has gl context so we do a silly one more canvas\n const tempCtx = tempCanvas.getContext('2d') as CanvasRenderingContext2D;\n const tempData = tempCtx.getImageData(0, 0, targetWidth, targetHeight);\n depth = tempData.data.length / targetWidth / targetHeight;\n const arr = new Uint8Array(tempData.data.buffer);\n pixels = tf.tensor(arr, [targetWidth, targetHeight, depth]);\n }\n }\n if (depth === 4) { // rgba to rgb\n const rgb = tf.slice3d(pixels, [0, 0, 0], [-1, -1, 3]); // strip alpha channel\n tf.dispose(pixels);\n pixels = rgb;\n }\n if (!pixels) throw new Error('input error: cannot create tensor');\n const casted: Tensor = tf.cast(pixels, 'float32');\n const tensor: Tensor = config.filter.equalization ? await enhance.histogramEqualization(casted) : tf.expandDims(casted, 0);\n tf.dispose([pixels, casted]);\n\n if (config.filter.autoBrightness) {\n const max = tf.max(tensor);\n const maxVal = await max.data();\n config.filter.brightness = maxVal[0] > 1 ? (1 - maxVal[0] / 255) : (1 - maxVal[0]);\n tf.dispose(max);\n }\n\n return { tensor: tensor as Tensor4D, canvas: (config.filter.return ? outCanvas : null) };\n}\n\n/*\nconst checksum = async (input: Tensor): Promise => { // use tf sum or js based sum loop depending on which is faster\n const resizeFact = 48;\n const reduced: Tensor = tf.image.resizeBilinear(input, [Math.trunc((input.shape[1] || 1) / resizeFact), Math.trunc((input.shape[2] || 1) / resizeFact)]);\n const tfSum = async (): Promise => {\n const sumT = tf.sum(reduced);\n const sum0 = await sumT.data();\n tf.dispose(sumT);\n return sum0[0];\n };\n const jsSum = async (): Promise => {\n const reducedData = await reduced.data(); // raw image rgb array\n let sum0 = 0;\n for (let i = 0; i < reducedData.length / 3; i++) sum0 += reducedData[3 * i + 2]; // look only at green value of each pixel\n return sum0;\n };\n if (last.sumMethod === 0) {\n const t0 = now();\n await jsSum();\n const t1 = now();\n await tfSum();\n const t2 = now();\n last.sumMethod = t1 - t0 < t2 - t1 ? 1 : 2;\n }\n const res = last.sumMethod === 1 ? await jsSum() : await tfSum();\n tf.dispose(reduced);\n return res;\n};\n*/\n\nexport async function skip(config: Partial, input: Tensor) {\n let skipFrame = false;\n if (config.cacheSensitivity === 0 || !input.shape || input.shape.length !== 4 || input.shape[1] > 3840 || input.shape[2] > 2160) return skipFrame; // cache disabled or input is invalid or too large for cache analysis\n\n /*\n const checkSum = await checksum(input);\n const diff = 100 * (Math.max(checkSum, last.inputSum) / Math.min(checkSum, last.inputSum) - 1);\n last.inputSum = checkSum;\n // if previous frame was skipped, skip this frame if changed more than cacheSensitivity\n // if previous frame was not skipped, then look for cacheSensitivity or difference larger than one in previous frame to avoid resetting cache in subsequent frames unnecessarily\n let skipFrame = diff < Math.max(config.cacheSensitivity, last.cacheDiff);\n // if difference is above 10x threshold, don't use last value to force reset cache for significant change of scenes or images\n last.cacheDiff = diff > 10 * config.cacheSensitivity ? 0 : diff;\n skipFrame = skipFrame && (last.cacheDiff > 0); // if no cached diff value then force no skip\n */\n\n if (!last.inputTensor) {\n last.inputTensor = tf.clone(input);\n } else if (last.inputTensor.shape[1] !== input.shape[1] || last.inputTensor.shape[2] !== input.shape[2]) { // input resolution changed\n tf.dispose(last.inputTensor);\n last.inputTensor = tf.clone(input);\n } else {\n const t: Record = {};\n t.diff = tf.sub(input, last.inputTensor);\n t.squared = tf.mul(t.diff, t.diff);\n t.sum = tf.sum(t.squared);\n const diffSum = await t.sum.data();\n const diffRelative = diffSum[0] / (input.shape[1] || 1) / (input.shape[2] || 1) / 255 / 3; // squared difference relative to input resolution and averaged per channel\n tf.dispose([last.inputTensor, t.diff, t.squared, t.sum]);\n last.inputTensor = tf.clone(input);\n skipFrame = diffRelative <= (config.cacheSensitivity || 0);\n }\n return skipFrame;\n}\n\nexport async function compare(config: Partial, input1: Tensor, input2: Tensor): Promise {\n const t: Record = {};\n if (!input1 || !input2 || input1.shape.length !== 4 || input1.shape.length !== input2.shape.length) {\n if (!config.debug) log('invalid input tensor or tensor shapes do not match:', input1.shape, input2.shape);\n return 0;\n }\n if (input1.shape[0] !== 1 || input2.shape[0] !== 1 || input1.shape[3] !== 3 || input2.shape[3] !== 3) {\n if (!config.debug) log('input tensors must be of shape [1, height, width, 3]:', input1.shape, input2.shape);\n return 0;\n }\n t.input1 = tf.clone(input1);\n t.input2 = (input1.shape[1] !== input2.shape[1] || input1.shape[2] !== input2.shape[2]) ? tf.image.resizeBilinear(input2 as Tensor3D, [input1.shape[1], input1.shape[2]]) : tf.clone(input2);\n t.diff = tf.sub(t.input1, t.input2);\n t.squared = tf.mul(t.diff, t.diff);\n t.sum = tf.sum(t.squared);\n const diffSum = await t.sum.data();\n const diffRelative = diffSum[0] / (input1.shape[1] || 1) / (input1.shape[2] || 1) / 255 / 3;\n tf.dispose([t.input1, t.input2, t.diff, t.squared, t.sum]);\n return diffRelative;\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport * as image from '../image/image';\n\n/** Env class that holds detected capabilities */\nexport class Env {\n /** Running in Browser */\n browser: boolean;\n /** Running in NodeJS */\n node: boolean;\n /** Running in WebWorker thread */\n worker: boolean;\n /** Detected platform */\n platform: string = '';\n /** Detected agent */\n agent: string = '';\n /** List of supported backends */\n backends: string[] = [];\n /** Has any work been performed so far */\n initial: boolean;\n /** Are image filters supported? */\n filter: boolean | undefined;\n /** TFJS instance details */\n tfjs: {\n version: undefined | string,\n };\n /** Is offscreenCanvas supported? */\n offscreen: undefined | boolean;\n /** Are performance counter instant values or additive */\n perfadd: boolean = false;\n /** If using tfjs-node get version of underlying tensorflow shared library and if gpu acceleration is enabled */\n tensorflow: {\n version: undefined | string,\n gpu: undefined | boolean,\n } = {\n version: undefined,\n gpu: undefined,\n };\n /** WASM detected capabilities */\n wasm: {\n supported: undefined | boolean,\n backend: undefined | boolean,\n simd: undefined | boolean,\n multithread: undefined | boolean,\n } = {\n supported: undefined,\n backend: undefined,\n simd: undefined,\n multithread: undefined,\n };\n /** WebGL detected capabilities */\n webgl: {\n supported: undefined | boolean,\n backend: undefined | boolean,\n version: undefined | string,\n renderer: undefined | string,\n shader: undefined | string,\n vendor: undefined | string,\n } = {\n supported: undefined,\n backend: undefined,\n version: undefined,\n renderer: undefined,\n shader: undefined,\n vendor: undefined,\n };\n /** WebGPU detected capabilities */\n webgpu: {\n supported: undefined | boolean,\n backend: undefined | boolean,\n adapter: undefined | GPUAdapterInfo,\n } = {\n supported: undefined,\n backend: undefined,\n adapter: undefined,\n };\n /** CPU info */\n cpu: {\n model: undefined | string,\n flags: string[],\n } = {\n model: undefined,\n flags: [],\n };\n /** List of supported kernels for current backend */\n kernels: string[] = [];\n\n /** MonkeyPatch for Canvas/Image/ImageData */\n #canvas: undefined;\n #image: undefined;\n #imageData: undefined;\n\n get Canvas() { return this.#canvas; }\n set Canvas(val) { this.#canvas = val; globalThis.Canvas = val; }\n get Image() { return this.#image; }\n // @ts-ignore monkey-patch;\n set Image(val) { this.#image = val; globalThis.Image = val; }\n get ImageData() { return this.#imageData; }\n // @ts-ignore monkey-patch;\n set ImageData(val) { this.#imageData = val; globalThis.ImageData = val; }\n\n constructor() {\n this.browser = typeof navigator !== 'undefined';\n this.node = (typeof process !== 'undefined') && (typeof process.versions !== 'undefined') && (typeof process.versions.node !== 'undefined');\n this.tfjs = { version: tf.version['tfjs-core'] };\n this.offscreen = typeof OffscreenCanvas !== 'undefined';\n this.initial = true;\n\n // @ts-ignore WorkerGlobalScope evaluated in browser only\n this.worker = this.browser && this.offscreen ? (typeof WorkerGlobalScope !== 'undefined') : undefined;\n if ((typeof navigator !== 'undefined') && (typeof navigator.userAgent !== 'undefined')) { // TBD replace with navigator.userAgentData once in mainline\n const agent = navigator.userAgent || '';\n const raw = agent.match(/\\(([^()]+)\\)/g);\n if (raw?.[0]) {\n const platformMatch = raw[0].match(/\\(([^()]+)\\)/g);\n this.platform = (platformMatch?.[0]) ? platformMatch[0].replace(/\\(|\\)/g, '') : '';\n this.agent = agent.replace(raw[0], '');\n if (this.platform[1]) this.agent = this.agent.replace(raw[1], '');\n this.agent = this.agent.replace(/ /g, ' ');\n }\n } else if (typeof process !== 'undefined') {\n this.platform = `${process.platform} ${process.arch}`;\n this.agent = `NodeJS ${process.version}`;\n }\n }\n\n /** update backend information */\n async updateBackend() {\n // analyze backends\n this.backends = Object.keys(tf.engine().registryFactory);\n try { // backend may not be initialized\n this.tensorflow = {\n version: (tf.backend()['binding'] ? tf.backend()['binding'].TF_Version : undefined),\n gpu: (tf.backend()['binding'] ? tf.backend()['binding'].isUsingGpuDevice() : undefined),\n };\n } catch { /**/ }\n this.wasm.supported = typeof WebAssembly !== 'undefined';\n this.wasm.backend = this.backends.includes('wasm');\n if (this.wasm.supported && this.wasm.backend) {\n this.wasm.simd = await tf.env().getAsync('WASM_HAS_SIMD_SUPPORT') as boolean;\n this.wasm.multithread = await tf.env().getAsync('WASM_HAS_MULTITHREAD_SUPPORT') as boolean;\n }\n const c = image.canvas(100, 100);\n const gl = c ? c.getContext('webgl2') as WebGL2RenderingContext : undefined; // causes too many gl contexts\n this.webgl.supported = typeof gl !== 'undefined';\n this.webgl.backend = this.backends.includes('webgl');\n if (this.webgl.supported && this.webgl.backend && gl) {\n this.webgl.version = gl.getParameter(gl.VERSION);\n this.webgl.vendor = gl.getParameter(gl.VENDOR);\n this.webgl.renderer = gl.getParameter(gl.RENDERER);\n this.webgl.shader = gl.getParameter(gl.SHADING_LANGUAGE_VERSION);\n }\n this.webgpu.supported = this.browser && typeof navigator !== 'undefined' && typeof navigator.gpu !== 'undefined';\n this.webgpu.backend = this.backends.includes('webgpu');\n try {\n if (this.webgpu.supported) {\n const adapter = await navigator.gpu.requestAdapter();\n this.webgpu.adapter = await adapter?.requestAdapterInfo();\n }\n } catch {\n this.webgpu.supported = false;\n }\n try {\n this.kernels = tf.getKernelsForBackend(tf.getBackend()).map((kernel) => kernel.kernelName.toLowerCase());\n } catch { /**/ }\n }\n\n /** update cpu information */\n updateCPU() {\n const cpu = { model: '', flags: [] };\n if (this.node && this.platform.startsWith('linux')) {\n /*\n const fs = require('fs');\n try {\n const data = fs.readFileSync('/proc/cpuinfo').toString();\n for (const line of data.split('\\n')) {\n if (line.startsWith('model name')) cpu.model = line.match(/:(.*)/g)[0].replace(':', '').trim();\n if (line.startsWith('flags')) cpu.flags = line.match(/:(.*)/g)[0].replace(':', '').trim().split(' ').sort();\n }\n } catch { }\n */\n }\n if (!this.cpu) Object.defineProperty(this, 'cpu', { value: cpu });\n else this.cpu = cpu;\n }\n}\n\nexport const env = new Env();\n", "import { log } from './util';\n\n// const log = (...msg) => console.log('webcam', ...msg); // eslint-disable-line no-console\n\n/** WebCam configuration */\nexport interface WebCamConfig {\n /**\n * element can be:\n * - string which indicates dom element id\n * - actual HTMLVideo dom element\n * - undefined in which case a new HTMLVideoElement will be created\n */\n element: string | HTMLVideoElement | undefined,\n /** print messages on console */\n debug: boolean,\n /** use front or back camera */\n mode: 'front' | 'back',\n /** camera crop mode */\n crop: boolean,\n /** desired webcam width */\n width: number,\n /** desired webcam height */\n height: number,\n /** deviceId of the video device to use */\n id?: string,\n}\n\nexport class WebCam { // eslint-disable-line @typescript-eslint/no-extraneous-class\n /** current webcam configuration */\n config: WebCamConfig;\n /** instance of dom element associated with webcam stream */\n element: HTMLVideoElement | undefined;\n /** active webcam stream */\n stream: MediaStream | undefined;\n /** enumerated video devices */\n devices: MediaDeviceInfo[] = [];\n\n constructor() {\n this.config = {\n element: undefined,\n debug: true,\n mode: 'front',\n crop: false,\n width: 0,\n height: 0,\n };\n }\n\n /** get active webcam stream track */\n public get track(): MediaStreamTrack | undefined {\n if (!this.stream) return undefined;\n return this.stream.getVideoTracks()[0];\n }\n\n /** get webcam capabilities */\n public get capabilities(): MediaTrackCapabilities | undefined {\n if (!this.track) return undefined;\n return this.track.getCapabilities ? this.track.getCapabilities() : undefined;\n }\n\n /** get webcam constraints */\n public get constraints(): MediaTrackConstraints | undefined {\n if (!this.track) return undefined;\n return this.track.getConstraints ? this.track.getConstraints() : undefined;\n }\n\n /** get webcam settings */\n public get settings(): MediaTrackSettings | undefined {\n if (!this.stream) return undefined;\n const track: MediaStreamTrack = this.stream.getVideoTracks()[0];\n return track.getSettings ? track.getSettings() : undefined;\n }\n\n /** get webcam label */\n public get label(): string {\n if (!this.track) return '';\n return this.track.label;\n }\n\n /** is webcam paused */\n public get paused(): boolean {\n return this.element?.paused || false;\n }\n\n /** webcam current width */\n public get width(): number {\n return this.element?.videoWidth || 0;\n }\n\n /** webcam current height */\n public get height(): number {\n return this.element?.videoHeight || 0;\n }\n\n public enumerate = async (): Promise => {\n try {\n const devices = await navigator.mediaDevices.enumerateDevices();\n this.devices = devices.filter((device) => device.kind === 'videoinput');\n } catch {\n this.devices = [];\n }\n return this.devices;\n };\n\n /** start method initializizes webcam stream and associates it with a dom video element */\n public start = async (webcamConfig?: Partial): Promise => {\n // set config\n if (webcamConfig?.debug) this.config.debug = webcamConfig?.debug;\n if (webcamConfig?.crop) this.config.crop = webcamConfig?.crop;\n if (webcamConfig?.mode) this.config.mode = webcamConfig?.mode;\n if (webcamConfig?.width) this.config.width = webcamConfig?.width;\n if (webcamConfig?.height) this.config.height = webcamConfig?.height;\n if (webcamConfig?.id) this.config.id = webcamConfig?.id;\n\n // use or create dom element\n if (webcamConfig?.element) {\n if (typeof webcamConfig.element === 'string') {\n const el = document.getElementById(webcamConfig.element);\n if (el && el instanceof HTMLVideoElement) {\n this.element = el;\n } else {\n if (this.config.debug) log('webcam', 'cannot get dom element', webcamConfig.element);\n return `webcam error: cannot get dom element: ${webcamConfig.element}`;\n }\n } else if (webcamConfig.element instanceof HTMLVideoElement) {\n this.element = webcamConfig.element;\n } else {\n if (this.config.debug) log('webcam', 'unknown dom element', webcamConfig.element);\n return `webcam error: unknown dom element: ${webcamConfig.element}`;\n }\n } else {\n this.element = document.createElement('video');\n }\n\n // set constraints to use\n const requestedConstraints: MediaStreamConstraints = {\n audio: false,\n video: {\n facingMode: this.config.mode === 'front' ? 'user' : 'environment',\n // @ts-ignore // resizeMode is still not defined in tslib\n resizeMode: this.config.crop ? 'crop-and-scale' : 'none',\n },\n };\n if (this.config?.width > 0) (requestedConstraints.video as MediaTrackConstraints).width = { ideal: this.config.width };\n if (this.config?.height > 0) (requestedConstraints.video as MediaTrackConstraints).height = { ideal: this.config.height };\n if (this.config.id) (requestedConstraints.video as MediaTrackConstraintSet).deviceId = this.config.id;\n\n // set default event listeners\n this.element.addEventListener('play', () => { if (this.config.debug) log('webcam', 'play'); });\n this.element.addEventListener('pause', () => { if (this.config.debug) log('webcam', 'pause'); });\n this.element.addEventListener('click', async () => { // pause when clicked on screen and resume on next click\n if (!this.element || !this.stream) return;\n if (this.element.paused) await this.element.play();\n else this.element.pause();\n });\n\n // get webcam and set it to run in dom element\n if (!navigator?.mediaDevices) {\n if (this.config.debug) log('webcam error', 'no devices');\n return 'webcam error: no devices';\n }\n try {\n this.stream = await navigator.mediaDevices.getUserMedia(requestedConstraints); // get stream that satisfies constraints\n } catch (err) {\n log('webcam', err);\n return `webcam error: ${err}`;\n }\n if (!this.stream) {\n if (this.config.debug) log('webcam error', 'no stream');\n return 'webcam error no stream';\n }\n this.element.srcObject = this.stream; // assign it to dom element\n const ready = new Promise((resolve) => { // wait until stream is ready\n if (!this.element) resolve(false);\n else this.element.onloadeddata = () => resolve(true);\n });\n await ready;\n await this.element.play(); // start playing\n\n if (this.config.debug) {\n log('webcam', {\n width: this.width,\n height: this.height,\n label: this.label,\n stream: this.stream,\n track: this.track,\n settings: this.settings,\n constraints: this.constraints,\n capabilities: this.capabilities,\n });\n }\n return `webcam: ${this.label}`;\n };\n\n /** pause webcam video method */\n public pause = (): void => {\n if (this.element) this.element.pause();\n };\n\n /** play webcam video method */\n public play = async (): Promise => {\n if (this.element) await this.element.play();\n };\n\n /** stop method stops active webcam stream track and disconnects webcam */\n public stop = (): void => {\n if (this.config.debug) log('webcam', 'stop');\n if (this.track) this.track.stop();\n };\n}\n", "{\n \"antispoof\": 853098,\n \"blazeface\": 538928,\n \"centernet\": 4030290,\n \"emotion\": 820516,\n \"facemesh\": 1477958,\n \"faceres\": 6978814,\n \"handlandmark-lite\": 2023432,\n \"handtrack\": 2964837,\n \"iris\": 2599092,\n \"liveness\": 592976,\n \"models\": 0,\n \"movenet-lightning\": 4650216,\n \"affectnet-mobilenet\": 6920630,\n \"age\": 161240,\n \"blazeface-back\": 538928,\n \"blazeface-front\": 402048,\n \"blazepose-detector\": 5928856,\n \"blazepose-full\": 6339202,\n \"blazepose-heavy\": 27502466,\n \"blazepose-lite\": 2726402,\n \"efficientpose\": 5651240,\n \"faceboxes\": 2013002,\n \"facemesh-attention-pinto\": 2387598,\n \"facemesh-attention\": 2382414,\n \"facemesh-detection-full\": 1026192,\n \"facemesh-detection-short\": 201268,\n \"faceres-deep\": 13957620,\n \"gear-e1\": 112438,\n \"gear-e2\": 112438,\n \"gear\": 1498916,\n \"gender-ssrnet-imdb\": 161236,\n \"gender\": 201808,\n \"handdetect\": 3515612,\n \"handlandmark-full\": 5431368,\n \"handlandmark-sparse\": 5286322,\n \"handskeleton\": 5502280,\n \"meet\": 372228,\n \"mobileface\": 2183192,\n \"mobilefacenet\": 5171976,\n \"movenet-multipose\": 9448838,\n \"movenet-thunder\": 12477112,\n \"nanodet\": 7574558,\n \"posenet\": 5032780,\n \"rvm\": 3739355,\n \"selfie\": 212886,\n \"anti-spoofing\": 853098,\n \"efficientpose-i-lite\": 2269064,\n \"efficientpose-ii-lite\": 5651240,\n \"efficientpose-iv\": 25643252,\n \"insightface-efficientnet-b0\": 13013224,\n \"insightface-ghostnet-strides1\": 8093408,\n \"insightface-ghostnet-strides2\": 8049584,\n \"insightface-mobilenet-emore\": 6938536,\n \"insightface-mobilenet-swish\": 12168584,\n \"nanodet-e\": 12319156,\n \"nanodet-g\": 7574558,\n \"nanodet-m\": 1887474,\n \"nanodet-t\": 5294216\n}", "import * as tf from 'dist/tfjs.esm.js';\nimport { log, join } from '../util/util';\nimport type { GraphModel } from './types';\nimport type { Config } from '../config';\nimport * as modelsDefs from '../../models/models.json';\n\nconst options = {\n cacheModels: true,\n cacheSupported: true,\n verbose: true,\n debug: false,\n modelBasePath: '',\n};\n\nexport interface ModelInfo {\n name: string,\n inCache: boolean,\n sizeDesired: number,\n sizeFromManifest: number,\n sizeLoadedWeights: number,\n url: string,\n}\n\nexport const modelStats: Record = {};\n\nasync function httpHandler(url: string, init?: RequestInit): Promise {\n if (options.debug) log('load model fetch:', url, init);\n return fetch(url, init);\n}\n\nexport function setModelLoadOptions(config: Config) {\n options.cacheModels = config.cacheModels;\n options.verbose = config.debug;\n options.modelBasePath = config.modelBasePath;\n}\n\nexport async function loadModel(modelPath: string | undefined): Promise {\n let modelUrl = join(options.modelBasePath, modelPath || '');\n if (!modelUrl.toLowerCase().endsWith('.json')) modelUrl += '.json';\n const modelPathSegments = modelUrl.includes('/') ? modelUrl.split('/') : modelUrl.split('\\\\');\n const shortModelName = modelPathSegments[modelPathSegments.length - 1].replace('.json', '');\n const cachedModelName = 'indexeddb://' + shortModelName; // generate short model name for cache\n modelStats[shortModelName] = {\n name: shortModelName,\n sizeFromManifest: 0,\n sizeLoadedWeights: 0,\n sizeDesired: modelsDefs[shortModelName],\n inCache: false,\n url: '',\n };\n options.cacheSupported = (typeof indexedDB !== 'undefined'); // check if localStorage and indexedb are available\n let cachedModels = {};\n try {\n cachedModels = (options.cacheSupported && options.cacheModels) ? await tf.io.listModels() : {}; // list all models already in cache // this fails for webview although localStorage is defined\n } catch {\n options.cacheSupported = false;\n }\n modelStats[shortModelName].inCache = (options.cacheSupported && options.cacheModels) && Object.keys(cachedModels).includes(cachedModelName); // is model found in cache\n modelStats[shortModelName].url = modelStats[shortModelName].inCache ? cachedModelName : modelUrl;\n const tfLoadOptions = typeof fetch === 'undefined' ? {} : { fetchFunc: (url: string, init?: RequestInit) => httpHandler(url, init) };\n let model: GraphModel = new tf.GraphModel(modelStats[shortModelName].url, tfLoadOptions) as unknown as GraphModel; // create model prototype and decide if load from cache or from original modelurl\n let loaded = false;\n try {\n // @ts-ignore private function\n model.findIOHandler(); // decide how to actually load a model\n if (options.debug) log('model load handler:', model['handler']);\n } catch (err) {\n log('error finding model i/o handler:', modelUrl, err);\n }\n try {\n // @ts-ignore private property\n const artifacts = await model.handler?.load() || null; // load manifest\n modelStats[shortModelName].sizeFromManifest = artifacts?.weightData?.byteLength || 0;\n if (artifacts) model.loadSync(artifacts); // load weights\n else model = await tf.loadGraphModel(modelStats[shortModelName].inCache ? cachedModelName : modelUrl, tfLoadOptions) as unknown as GraphModel;\n // @ts-ignore private property\n modelStats[shortModelName].sizeLoadedWeights = model.artifacts?.weightData?.byteLength || 0;\n if (options.verbose) log('load:', { model: shortModelName, url: model['modelUrl'], bytes: modelStats[shortModelName].sizeLoadedWeights });\n loaded = true;\n } catch (err) {\n log('error loading model:', modelUrl, err);\n }\n if (loaded && options.cacheModels && options.cacheSupported && !modelStats[shortModelName].inCache) { // save model to cache\n try {\n const saveResult = await model.save(cachedModelName);\n if (options.debug) log('model saved:', cachedModelName, saveResult);\n } catch (err) {\n log('error saving model:', modelUrl, err);\n }\n }\n return model;\n}\n", "{\n \"name\": \"@vladmandic/human\",\n \"version\": \"3.1.2\",\n \"description\": \"Human: AI-powered 3D Face Detection & Rotation Tracking, Face Description & Recognition, Body Pose Tracking, 3D Hand & Finger Tracking, Iris Analysis, Age & Gender & Emotion Prediction, Gesture Recognition\",\n \"sideEffects\": false,\n \"main\": \"dist/human.node.js\",\n \"module\": \"dist/human.esm.js\",\n \"browser\": \"dist/human.esm.js\",\n \"types\": \"types/human.d.ts\",\n \"exports\": {\n \"node\": {\n \"require\": \"./dist/human.node.js\",\n \"import\": \"./dist/human.node.js\",\n \"module\": \"./dist/human.node.js\"\n },\n \"require\": \"./dist/human.node.js\",\n \"import\": \"./dist/human.esm.js\",\n \"script\": \"./dist/human.js\",\n \"module\": \"./dist/human.esm.js\",\n \"types\": \"./types/human.d.ts\",\n \"dist/human\": \"./dist/human.js\",\n \"dist/human.js\": \"./dist/human.js\",\n \"dist/human.esm\": \"./dist/human.esm.js\",\n \"dist/human.esm.js\": \"./dist/human.esm.js\",\n \"dist/human.esm-nobundle\": \"./dist/human.esm-nobundle.js\",\n \"dist/human.esm-nobundle.js\": \"./dist/human.esm-nobundle.js\",\n \"dist/human.node\": \"./dist/human.node.js\",\n \"dist/human.node.js\": \"./dist/human.node.js\",\n \"dist/human.node-wasm\": \"./dist/human.node-wasm.js\",\n \"dist/human.node-wasm.js\": \"./dist/human.node-wasm.js\",\n \"dist/human.node-gpu\": \"./dist/human.node-gpu.js\",\n \"dist/human.node-gpu.js\": \"./dist/human.node-gpu.js\"\n },\n \"author\": \"Vladimir Mandic \",\n \"bugs\": {\n \"url\": \"https://github.com/vladmandic/human/issues\"\n },\n \"homepage\": \"https://vladmandic.github.io/human/demo/index.html\",\n \"license\": \"MIT\",\n \"engines\": {\n \"node\": \">=14.0.0\"\n },\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/vladmandic/human.git\"\n },\n \"scripts\": {\n \"start\": \"node --no-warnings demo/nodejs/node.js\",\n \"dev\": \"build --profile development\",\n \"clean\": \"build --profile clean\",\n \"build\": \"rimraf test/build.log && node build.js\",\n \"test\": \"node --no-warnings --unhandled-rejections=strict --trace-uncaught test/node.js\",\n \"lint\": \"eslint *.json *.js src demo test models wiki\",\n \"scan\": \"npx auditjs@latest ossi --dev --quiet\"\n },\n \"keywords\": [\n \"human\",\n \"human-library\",\n \"face-detection\",\n \"faceid\",\n \"face-geometry\",\n \"face-embedding\",\n \"face-recognition\",\n \"face-description\",\n \"face-matching\",\n \"body-tracking\",\n \"body-segmentation\",\n \"hand-tracking\",\n \"iris-tracking\",\n \"age-estimation\",\n \"emotion-detection\",\n \"gender-prediction\",\n \"gesture-recognition\",\n \"gaze-tracking\",\n \"age-gender\",\n \"tensorflowjs\",\n \"tfjs\",\n \"tensorflow\"\n ],\n \"devDependencies\": {\n \"@html-eslint/eslint-plugin\": \"^0.19.1\",\n \"@html-eslint/parser\": \"^0.19.1\",\n \"@microsoft/api-extractor\": \"^7.37.0\",\n \"@tensorflow/tfjs-backend-cpu\": \"^4.11.0\",\n \"@tensorflow/tfjs-backend-wasm\": \"^4.11.0\",\n \"@tensorflow/tfjs-backend-webgl\": \"^4.11.0\",\n \"@tensorflow/tfjs-backend-webgpu\": \"4.11.0\",\n \"@tensorflow/tfjs-converter\": \"^4.11.0\",\n \"@tensorflow/tfjs-core\": \"^4.11.0\",\n \"@tensorflow/tfjs-data\": \"^4.11.0\",\n \"@tensorflow/tfjs-layers\": \"^4.11.0\",\n \"@tensorflow/tfjs-node\": \"^4.11.0\",\n \"@tensorflow/tfjs-node-gpu\": \"^4.11.0\",\n \"@types/node\": \"^20.6.2\",\n \"@types/offscreencanvas\": \"^2019.7.1\",\n \"@typescript-eslint/eslint-plugin\": \"^6.7.0\",\n \"@typescript-eslint/parser\": \"^6.7.0\",\n \"@vladmandic/build\": \"^0.9.2\",\n \"@vladmandic/pilogger\": \"^0.4.8\",\n \"@vladmandic/tfjs\": \"github:vladmandic/tfjs\",\n \"canvas\": \"^2.11.2\",\n \"esbuild\": \"^0.19.3\",\n \"eslint\": \"8.49.0\",\n \"eslint-config-airbnb-base\": \"^15.0.0\",\n \"eslint-plugin-html\": \"^7.1.0\",\n \"eslint-plugin-import\": \"^2.28.1\",\n \"eslint-plugin-json\": \"^3.1.0\",\n \"eslint-plugin-markdown\": \"^3.0.1\",\n \"eslint-plugin-node\": \"^11.1.0\",\n \"eslint-plugin-promise\": \"^6.1.1\",\n \"rimraf\": \"^5.0.1\",\n \"tslib\": \"^2.6.2\",\n \"typedoc\": \"0.25.1\",\n \"typescript\": \"^5.1.6\"\n }\n}\n", "/** TFJS custom backend registration */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Human } from '../human';\nimport { log } from '../util/util';\nimport * as image from '../image/image';\nimport type { AnyCanvas } from '../exports';\n\nexport const config = {\n name: 'humangl',\n priority: 999,\n canvas: null as null | AnyCanvas,\n gl: null as null | WebGL2RenderingContext,\n extensions: [] as string[] | null,\n webGLattr: { // https://www.khronos.org/registry/webgl/specs/latest/1.0/#5.2\n alpha: false,\n antialias: false,\n premultipliedAlpha: false,\n preserveDrawingBuffer: false,\n depth: false,\n stencil: false,\n failIfMajorPerformanceCaveat: false, // default=true\n desynchronized: true, // default=undefined\n },\n};\n\nfunction extensions(): void {\n /*\n https://www.khronos.org/registry/webgl/extensions/\n https://webglreport.com/?v=2\n */\n const gl = config.gl;\n if (!gl) return;\n config.extensions = gl.getSupportedExtensions();\n // gl.getExtension('KHR_parallel_shader_compile');\n}\n\n/**\n * Registers custom WebGL2 backend to be used by Human library\n *\n * @returns void\n */\nexport function register(instance: Human): void {\n // force backend reload if gl context is not valid\n if (instance.config.backend !== 'humangl') return;\n if ((config.name in tf.engine().registry) && !config?.gl?.getParameter(config.gl.VERSION)) {\n log('humangl error: backend invalid context');\n instance.models.reset();\n /*\n log('resetting humangl backend');\n await tf.removeBackend(config.name);\n await register(instance); // re-register\n */\n }\n if (!tf.findBackend(config.name)) {\n try {\n config.canvas = image.canvas(100, 100);\n } catch (err) {\n log('humangl error: cannot create canvas:', err);\n return;\n }\n try {\n config.gl = config.canvas.getContext('webgl2', config.webGLattr) as WebGL2RenderingContext;\n if (!config.gl) {\n log('humangl error: cannot get webgl context');\n return;\n }\n const glv2 = config.gl.getParameter(config.gl.VERSION).includes('2.0');\n if (!glv2) {\n log('backend override: using fallback webgl backend as webgl 2.0 is not detected');\n instance.config.backend = 'webgl';\n return;\n }\n if (config.canvas) {\n config.canvas.addEventListener('webglcontextlost', (e) => {\n log('humangl error:', e.type);\n log('possible browser memory leak using webgl or conflict with multiple backend registrations');\n instance.emit('error');\n throw new Error('backend error: webgl context lost');\n });\n config.canvas.addEventListener('webglcontextrestored', (e) => {\n log('humangl error: context restored:', e);\n });\n config.canvas.addEventListener('webglcontextcreationerror', (e) => {\n log('humangl error: context create:', e);\n });\n }\n } catch (err) {\n log('humangl error: cannot get webgl context:', err);\n return;\n }\n try {\n tf.setWebGLContext(2, config.gl);\n } catch (err) {\n log('humangl error: cannot set webgl context:', err);\n return;\n }\n try {\n const ctx = new tf.GPGPUContext(config.gl);\n // @ts-ignore uncompatible kernelMs timing info\n tf.registerBackend(config.name, () => new tf.MathBackendWebGL(ctx), config.priority);\n } catch (err) {\n log('humangl error: cannot register webgl backend:', err);\n return;\n }\n try {\n const kernels = tf.getKernelsForBackend('webgl');\n kernels.forEach((kernelConfig) => {\n const newKernelConfig = { ...kernelConfig, backendName: config.name };\n tf.registerKernel(newKernelConfig);\n });\n } catch (err) {\n log('humangl error: cannot update webgl backend registration:', err);\n return;\n }\n try {\n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_VERSION) tf.env().set('WEBGL_VERSION', 2);\n } catch (err) {\n log('humangl error: cannot set WebGL backend flags:', err);\n return;\n }\n extensions();\n const backend = tf.backend();\n const current = typeof backend['gpgpu'] !== 'undefined' ? backend['getGPGPUContext']().gl : null;\n if (current) {\n if (instance.config.debug) log('humangl backend registered:', { webgl: current.getParameter(current.VERSION) as string, renderer: current.getParameter(current.RENDERER) as string });\n } else {\n log('humangl error: no current gl context:', current, config.gl);\n }\n }\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport type { Tensor } from './types';\n\nexport const constants: Record = {\n tf255: 255.0,\n tf1: 1.0,\n tf2: 2.0,\n tf05: 0.5,\n tf127: 127.5,\n rgb: [0.2989, 0.5870, 0.1140],\n};\n\nexport function init() {\n constants.tf255 = tf.scalar(255.0, 'float32');\n constants.tf1 = tf.scalar(1.0, 'float32');\n constants.tf2 = tf.scalar(2.0, 'float32');\n constants.tf05 = tf.scalar(0.5, 'float32');\n constants.tf127 = tf.scalar(127.5, 'float32');\n constants.rgb = tf.tensor1d([0.2989, 0.5870, 0.1140], 'float32'); // factors for red/green/blue colors when converting to grayscale\n}\n", "/** TFJS backend initialization and customization */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Human, Config, BackendEnum } from '../human';\nimport { log, now } from '../util/util';\nimport { env } from '../util/env';\nimport * as humangl from './humangl';\nimport * as constants from './constants';\nimport type { TensorInfo } from './types';\n\nexport async function getBestBackend(): Promise {\n await env.updateBackend(); // update env on backend init\n if (env.tensorflow?.version) return 'tensorflow';\n if (env.webgpu.supported && env.webgpu.backend) return 'webgpu';\n if (env.webgl.supported && env.webgl.backend) return 'webgl';\n if (env.wasm.supported && env.wasm.backend) return 'wasm';\n return 'cpu';\n}\n\nfunction registerCustomOps(config: Config) {\n const newKernels: string[] = [];\n if (!env.kernels.includes('mod')) {\n const kernelMod = {\n kernelName: 'Mod',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => tf.sub(op.inputs.a, tf.mul(tf.div(op.inputs.a, op.inputs.b), op.inputs.b))),\n };\n tf.registerKernel(kernelMod);\n env.kernels.push('mod');\n newKernels.push('mod');\n }\n if (!env.kernels.includes('floormod')) {\n const kernelFloorMod = {\n kernelName: 'FloorMod',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => tf.add(tf.mul(tf.floorDiv(op.inputs.a, op.inputs.b), op.inputs.b), tf.mod(op.inputs.a, op.inputs.b))),\n };\n tf.registerKernel(kernelFloorMod);\n env.kernels.push('floormod');\n newKernels.push('floormod');\n }\n /*\n if (!env.kernels.includes('atan2') && config.softwareKernels) {\n const kernelAtan2 = {\n kernelName: 'Atan2',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => {\n const backend = tf.getBackend();\n tf.setBackend('cpu');\n const t = tf.atan2(op.inputs.a, op.inputs.b);\n tf.setBackend(backend);\n return t;\n }),\n };\n if (config.debug) log('registered kernel:', 'atan2');\n log('registered kernel:', 'atan2');\n tf.registerKernel(kernelAtan2);\n env.kernels.push('atan2');\n newKernels.push('atan2');\n }\n */\n if (!env.kernels.includes('rotatewithoffset') && config.softwareKernels) {\n const kernelRotateWithOffset = {\n kernelName: 'RotateWithOffset',\n backendName: tf.getBackend(),\n kernelFunc: (op) => tf.tidy(() => {\n const backend = tf.getBackend();\n tf.setBackend('cpu'); // eslint-disable-line @typescript-eslint/no-floating-promises\n const t = tf.image.rotateWithOffset(op.inputs.image, op.attrs.radians, op.attrs.fillValue, op.attrs.center);\n tf.setBackend(backend); // eslint-disable-line @typescript-eslint/no-floating-promises\n return t;\n }),\n };\n tf.registerKernel(kernelRotateWithOffset);\n env.kernels.push('rotatewithoffset');\n newKernels.push('rotatewithoffset');\n }\n if ((newKernels.length > 0) && config.debug) log('registered kernels:', newKernels);\n}\n\nlet defaultFlags: Record = {};\n\nexport async function check(instance: Human, force = false) {\n instance.state = 'backend';\n if (instance.config.backend?.length === 0) instance.config.backend = await getBestBackend();\n if (force || env.initial || (instance.config.backend && (instance.config.backend.length > 0) && (tf.getBackend() !== instance.config.backend))) {\n const timeStamp = now();\n\n if (instance.config.backend && instance.config.backend.length > 0) {\n // detect web worker\n // @ts-ignore ignore missing type for WorkerGlobalScope as that is the point\n if (typeof window === 'undefined' && typeof WorkerGlobalScope !== 'undefined' && instance.config.debug) {\n if (instance.config.debug) log('running inside web worker');\n }\n\n if (typeof navigator !== 'undefined' && navigator?.userAgent?.toLowerCase().includes('electron')) {\n if (instance.config.debug) log('running inside electron');\n }\n\n // check available backends\n let available = Object.keys(tf.engine().registryFactory as Record);\n if (instance.config.backend === 'humangl' && !available.includes('humangl')) {\n humangl.register(instance);\n available = Object.keys(tf.engine().registryFactory as Record);\n }\n if (instance.config.debug) log('available backends:', available);\n\n // force browser vs node backend\n if (env.browser && !env.node && (instance.config.backend === 'tensorflow') && available.includes('webgl')) {\n if (instance.config.debug) log('override: backend set to tensorflow while running in browser');\n instance.config.backend = 'webgl';\n }\n if (env.node && !env.browser && (instance.config.backend === 'webgl' || instance.config.backend === 'humangl') && available.includes('tensorflow')) {\n if (instance.config.debug) log(`override: backend set to ${instance.config.backend} while running in nodejs`);\n instance.config.backend = 'tensorflow';\n }\n\n // handle webgpu\n if (env.browser && instance.config.backend === 'webgpu') {\n if (typeof navigator === 'undefined' || typeof navigator.gpu === 'undefined') {\n log('override: backend set to webgpu but browser does not support webgpu');\n instance.config.backend = 'webgl';\n } else {\n const adapter = await navigator.gpu.requestAdapter();\n if (instance.config.debug) log('enumerated webgpu adapter:', adapter);\n if (!adapter) {\n log('override: backend set to webgpu but browser reports no available gpu');\n instance.config.backend = 'webgl';\n } else {\n // @ts-ignore requestAdapterInfo is not in tslib\n const adapterInfo = 'requestAdapterInfo' in adapter ? await adapter.requestAdapterInfo() : undefined;\n // if (adapter.features) adapter.features.forEach((feature) => log('webgpu features:', feature));\n log('webgpu adapter info:', adapterInfo);\n }\n }\n }\n\n if (!available.includes(instance.config.backend)) {\n log(`error: backend ${instance.config.backend} not found in registry`);\n instance.config.backend = env.node ? 'tensorflow' : 'webgl';\n if (instance.config.debug) log(`override: setting backend ${instance.config.backend}`);\n }\n\n if (instance.config.debug) log('setting backend:', [instance.config.backend]);\n\n // customize wasm\n if (instance.config.backend === 'wasm') {\n // @ts-ignore private property\n if (tf.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY) tf.env().set('CANVAS2D_WILL_READ_FREQUENTLY', true);\n if (instance.config.debug) log('wasm path:', instance.config.wasmPath);\n if (typeof tf.setWasmPaths !== 'undefined') tf.setWasmPaths(instance.config.wasmPath, instance.config.wasmPlatformFetch);\n else throw new Error('backend error: attempting to use wasm backend but wasm path is not set');\n let mt = false;\n let simd = false;\n try {\n mt = await tf.env().getAsync('WASM_HAS_MULTITHREAD_SUPPORT') as boolean;\n simd = await tf.env().getAsync('WASM_HAS_SIMD_SUPPORT') as boolean;\n if (instance.config.debug) log(`wasm execution: ${simd ? 'simd' : 'no simd'} ${mt ? 'multithreaded' : 'singlethreaded'}`);\n if (instance.config.debug && !simd) log('warning: wasm simd support is not enabled');\n } catch {\n log('wasm detection failed');\n }\n }\n\n try {\n await tf.setBackend(instance.config.backend);\n await tf.ready();\n } catch (err) {\n log('error: cannot set backend:', instance.config.backend, err);\n return false;\n }\n // @ts-ignore private property\n if (instance.config.debug) defaultFlags = JSON.parse(JSON.stringify(tf.env().flags));\n }\n\n // customize humangl\n if (tf.getBackend() === 'humangl' || tf.getBackend() === 'webgl') {\n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS) tf.env().set('WEBGL_USE_SHAPES_UNIFORMS', true); // default=false \n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_EXP_CONV) tf.env().set('WEBGL_EXP_CONV', true); // default=false \n // if (tf.env().flagRegistry['WEBGL_PACK_DEPTHWISECONV']) tf.env().set('WEBGL_PACK_DEPTHWISECONV', false); // default=true \n // if (tf.env().flagRegistry.USE_SETTIMEOUTCUSTOM) tf.env().set('USE_SETTIMEOUTCUSTOM', true); // default=false \n // if (tf.env().flagRegistry.CPU_HANDOFF_SIZE_THRESHOLD) tf.env().set('CPU_HANDOFF_SIZE_THRESHOLD', 1024); // default=1000\n // if (tf.env().flagRegistry['WEBGL_FORCE_F16_TEXTURES'] && !instance.config.object.enabled) tf.env().set('WEBGL_FORCE_F16_TEXTURES', true); // safe to use 16bit precision\n if (instance.config.debug && typeof instance.config.deallocate !== 'undefined' && instance.config.deallocate) { // hidden param\n log('changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:', true);\n tf.env().set('WEBGL_DELETE_TEXTURE_THRESHOLD', 0);\n }\n }\n\n // customize webgpu\n if (tf.getBackend() === 'webgpu') {\n // if (tf.env().flagRegistry['WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD']) tf.env().set('WEBGPU_CPU_HANDOFF_SIZE_THRESHOLD', 512);\n // if (tf.env().flagRegistry['WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE']) tf.env().set('WEBGPU_DEFERRED_SUBMIT_BATCH_SIZE', 0);\n // if (tf.env().flagRegistry['WEBGPU_CPU_FORWARD']) tf.env().set('WEBGPU_CPU_FORWARD', true);\n }\n\n if (instance.config.debug) {\n // @ts-ignore private property\n const newFlags = tf.env().flags;\n const updatedFlags = {};\n for (const key of Object.keys(newFlags)) {\n if (defaultFlags[key] === newFlags[key]) continue;\n updatedFlags[key] = newFlags[key];\n }\n if (instance.config.debug && Object.keys(updatedFlags).length > 0) log('backend:', tf.getBackend(), 'flags:', updatedFlags);\n }\n\n if (instance.config.flags && Object.keys(instance.config.flags).length > 0) {\n if (instance.config.debug) log('flags:', instance.config['flags']);\n for (const [key, val] of Object.entries(instance.config.flags)) {\n tf.env().set(key, val as number | boolean);\n }\n }\n\n tf.enableProdMode();\n constants.init();\n instance.performance.initBackend = Math.trunc(now() - timeStamp);\n instance.config.backend = tf.getBackend() as BackendEnum;\n await env.updateBackend(); // update env on backend init\n registerCustomOps(instance.config);\n // await env.updateBackend(); // update env on backend init\n // env.initial = false;\n }\n return true;\n}\n\n// register fake missing tfjs ops\nexport function fakeOps(kernelNames: string[], config) {\n // if (config.debug) log('registerKernel:', kernelNames);\n for (const kernelName of kernelNames) {\n const kernelConfig = {\n kernelName,\n backendName: config.backend,\n kernelFunc: (param): TensorInfo => {\n if (config.debug) log('kernelFunc', kernelName, config.backend, param);\n return param?.inputs?.info as TensorInfo;\n },\n // setupFunc: () => { if (config.debug) log('kernelFunc', kernelName, config.backend); },\n // disposeFunc: () => { if (config.debug) log('kernelFunc', kernelName, config.backend); },\n };\n tf.registerKernel(kernelConfig);\n }\n env.kernels = tf.getKernelsForBackend(tf.getBackend()).map((kernel) => kernel.kernelName.toLowerCase()); // re-scan registered ops\n}\n", "/**\n * Module that implements helper draw functions, exposed as human.draw\n */\n\nimport { mergeDeep, now } from '../util/util';\nimport { env } from '../util/env';\nimport { getCanvasContext, rect } from './primitives';\nimport { options } from './options';\nimport { face } from './face';\nimport { body } from './body';\nimport { hand } from './hand';\nimport { object } from './object';\nimport { gesture } from './gesture';\nimport { defaultLabels } from './labels';\nimport type { Result, PersonResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\nlet drawTime = 0;\n\nexport { options } from './options';\nexport { face } from './face';\nexport { body } from './body';\nexport { hand } from './hand';\nexport { object } from './object';\nexport { gesture } from './gesture';\n\n/** draw combined person results instead of individual detection result objects */\nexport function person(inCanvas: AnyCanvas, result: PersonResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n ctx.font = localOptions.font;\n\n for (let i = 0; i < result.length; i++) {\n if (localOptions.drawBoxes) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n rect(ctx, result[i].box[0], result[i].box[1], result[i].box[2], result[i].box[3], localOptions);\n if (localOptions.drawLabels) {\n const label = `person #${i}`;\n if (localOptions.shadowColor && localOptions.shadowColor !== '') {\n ctx.fillStyle = localOptions.shadowColor;\n ctx.fillText(label, result[i].box[0] + 3, 1 + result[i].box[1] + localOptions.lineHeight, result[i].box[2]);\n }\n ctx.fillStyle = localOptions.labelColor;\n ctx.fillText(label, result[i].box[0] + 2, 0 + result[i].box[1] + localOptions.lineHeight, result[i].box[2]);\n }\n ctx.stroke();\n }\n }\n}\n\n/** draw processed canvas */\nexport function canvas(input: AnyCanvas | HTMLImageElement | HTMLVideoElement, output: AnyCanvas) {\n if (!input || !output) return;\n const ctx = getCanvasContext(output) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.drawImage(input, 0, 0);\n}\n\n/** meta-function that performs draw for: canvas, face, body, hand */\nexport async function all(inCanvas: AnyCanvas, result: Result, drawOptions?: Partial) {\n if (!result?.performance || !inCanvas) return null;\n const timeStamp = now();\n const localOptions = mergeDeep(options, drawOptions);\n const promise = Promise.all([\n face(inCanvas, result.face, localOptions),\n body(inCanvas, result.body, localOptions),\n hand(inCanvas, result.hand, localOptions),\n object(inCanvas, result.object, localOptions),\n gesture(inCanvas, result.gesture, localOptions), // gestures do not have buffering\n // person(inCanvas, result.persons, localOptions); // already included above\n ]);\n drawTime = env.perfadd ? drawTime + Math.round(now() - timeStamp) : Math.round(now() - timeStamp);\n result.performance.draw = drawTime;\n return promise;\n}\n\n/** sets default label templates for face/body/hand/object/gestures */\nexport function init() {\n options.faceLabels = defaultLabels.face;\n options.bodyLabels = defaultLabels.body;\n options.bodyPartLabels = defaultLabels.bodyPart;\n options.handLabels = defaultLabels.hand;\n options.fingerLabels = defaultLabels.finger;\n options.objectLabels = defaultLabels.object;\n options.gestureLabels = defaultLabels.gesture;\n}\n", "import { log } from '../util/util';\nimport type { AnyCanvas } from '../exports';\nimport type { Point } from '../result';\nimport type { DrawOptions } from './options';\n\nexport const getCanvasContext = (input: AnyCanvas) => {\n if (!input) log('draw error: invalid canvas');\n else if (!input.getContext) log('draw error: canvas context not defined');\n else {\n const ctx = input.getContext('2d', { willReadFrequently: true });\n if (!ctx) log('draw error: cannot get canvas context');\n else return ctx;\n }\n return null;\n};\n\nexport const rad2deg = (theta: number) => Math.round((theta * 180) / Math.PI);\n\nexport const replace = (str: string, source: string, target: string | number) => str.replace(source, typeof target === 'number' ? target.toFixed(1) : target);\n\nexport const colorDepth = (z: number | undefined, opt: DrawOptions): string => { // performance optimization needed\n if (!opt.useDepth || typeof z === 'undefined') return opt.color;\n const rgb = Uint8ClampedArray.from([127 + (2 * z), 127 - (2 * z), 255]);\n return `rgba(${rgb[0]}, ${rgb[1]}, ${rgb[2]}, ${opt.alpha})`;\n};\n\nexport function labels(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, str: string, startX: number, startY: number, localOptions: DrawOptions) {\n const line: string[] = str.replace(/\\[.*\\]/g, '').split('\\n').map((l) => l.trim()); // remove unmatched templates and split into array\n const x = Math.max(0, startX);\n for (let i = line.length - 1; i >= 0; i--) {\n const y = i * localOptions.lineHeight + startY;\n if (localOptions.shadowColor && localOptions.shadowColor !== '') {\n ctx.fillStyle = localOptions.shadowColor;\n ctx.fillText(line[i], x + 5, y + 16);\n }\n ctx.fillStyle = localOptions.labelColor;\n ctx.fillText(line[i], x + 4, y + 15);\n }\n}\n\nexport function point(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, x: number, y: number, z: number | undefined, localOptions: DrawOptions) {\n ctx.fillStyle = colorDepth(z, localOptions);\n ctx.beginPath();\n ctx.arc(x, y, localOptions.pointSize, 0, 2 * Math.PI);\n ctx.fill();\n}\n\nexport function rect(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, x: number, y: number, width: number, height: number, localOptions: DrawOptions) {\n ctx.beginPath();\n ctx.lineWidth = localOptions.lineWidth;\n if (localOptions.useCurves) {\n const cx = (x + x + width) / 2;\n const cy = (y + y + height) / 2;\n ctx.ellipse(cx, cy, width / 2, height / 2, 0, 0, 2 * Math.PI);\n } else {\n ctx.moveTo(x + localOptions.roundRect, y);\n ctx.lineTo(x + width - localOptions.roundRect, y);\n ctx.quadraticCurveTo(x + width, y, x + width, y + localOptions.roundRect);\n ctx.lineTo(x + width, y + height - localOptions.roundRect);\n ctx.quadraticCurveTo(x + width, y + height, x + width - localOptions.roundRect, y + height);\n ctx.lineTo(x + localOptions.roundRect, y + height);\n ctx.quadraticCurveTo(x, y + height, x, y + height - localOptions.roundRect);\n ctx.lineTo(x, y + localOptions.roundRect);\n ctx.quadraticCurveTo(x, y, x + localOptions.roundRect, y);\n ctx.closePath();\n }\n ctx.stroke();\n}\n\nexport function lines(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, points: Point[], localOptions: DrawOptions) {\n if (points.length < 2) return;\n ctx.beginPath();\n ctx.moveTo(points[0][0], points[0][1]);\n for (const pt of points) {\n ctx.strokeStyle = colorDepth(pt[2] || 0, localOptions);\n ctx.lineTo(Math.trunc(pt[0]), Math.trunc(pt[1]));\n }\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.closePath();\n ctx.fill();\n }\n}\n\nexport function curves(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, points: Point[], localOptions: DrawOptions) {\n if (points.length < 2) return;\n ctx.lineWidth = localOptions.lineWidth;\n if (!localOptions.useCurves || points.length <= 2) {\n lines(ctx, points, localOptions);\n return;\n }\n ctx.moveTo(points[0][0], points[0][1]);\n for (let i = 0; i < points.length - 2; i++) {\n const xc = (points[i][0] + points[i + 1][0]) / 2;\n const yc = (points[i][1] + points[i + 1][1]) / 2;\n ctx.quadraticCurveTo(points[i][0], points[i][1], xc, yc);\n }\n ctx.quadraticCurveTo(points[points.length - 2][0], points[points.length - 2][1], points[points.length - 1][0], points[points.length - 1][1]);\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.closePath();\n ctx.fill();\n }\n}\n\nexport function arrow(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, from: Point, to: Point, radius = 5) {\n let angle;\n let x;\n let y;\n ctx.beginPath();\n ctx.moveTo(from[0], from[1]);\n ctx.lineTo(to[0], to[1]);\n angle = Math.atan2(to[1] - from[1], to[0] - from[0]);\n x = radius * Math.cos(angle) + to[0];\n y = radius * Math.sin(angle) + to[1];\n ctx.moveTo(x, y);\n angle += (1.0 / 3.0) * (2 * Math.PI);\n x = radius * Math.cos(angle) + to[0];\n y = radius * Math.sin(angle) + to[1];\n ctx.lineTo(x, y);\n angle += (1.0 / 3.0) * (2 * Math.PI);\n x = radius * Math.cos(angle) + to[0];\n y = radius * Math.sin(angle) + to[1];\n ctx.lineTo(x, y);\n ctx.closePath();\n ctx.stroke();\n ctx.fill();\n}\n", "/** Draw Options\n * - Accessed via `human.draw.options` or provided per each draw method as the drawOptions optional parameter\n */\n\nexport interface DrawOptions {\n /** draw line color */\n color: string,\n /** alpha value used for lines */\n alpha: number,\n /** label color */\n labelColor: string,\n /** label shadow color */\n shadowColor: string,\n /** label font */\n font: string,\n /** line spacing between labels */\n lineHeight: number,\n /** line width for drawn lines */\n lineWidth: number,\n /** size of drawn points */\n pointSize: number,\n /** draw rounded boxes by n pixels */\n roundRect: number,\n /** should points be drawn? */\n drawPoints: boolean,\n /** should labels be drawn? */\n drawLabels: boolean,\n /** should face attention keypoints be highlighted */\n drawAttention: boolean;\n /** should detected gestures be drawn? */\n drawGestures: boolean,\n /** should draw boxes around detection results? */\n drawBoxes: boolean,\n /** should draw polygons from detection points? */\n drawPolygons: boolean,\n /** should draw gaze arrows? */\n drawGaze: boolean,\n /** should fill polygons? */\n fillPolygons: boolean,\n /** use z-coordinate when available */\n useDepth: boolean,\n /** should lines be curved? */\n useCurves: boolean,\n /** string template for face labels */\n faceLabels: string,\n /** string template for body labels */\n bodyLabels: string,\n /** string template for body part labels */\n bodyPartLabels: string,\n /** string template for hand labels */\n handLabels: string,\n /** string template for hand labels */\n fingerLabels: string,\n /** string template for object labels */\n objectLabels: string,\n /** string template for gesture labels */\n gestureLabels: string,\n}\n\n/** currently set draw options {@link DrawOptions} */\nexport const options: DrawOptions = {\n color: 'rgba(173, 216, 230, 0.6)' as string, // 'lightblue' with light alpha channel\n labelColor: 'rgba(173, 216, 230, 1)' as string, // 'lightblue' with dark alpha channel\n shadowColor: 'black' as string,\n alpha: 0.5 as number,\n font: 'small-caps 16px \"Segoe UI\"' as string,\n lineHeight: 18 as number,\n lineWidth: 4 as number,\n pointSize: 2 as number,\n roundRect: 8 as number,\n drawPoints: false as boolean,\n drawLabels: true as boolean,\n drawBoxes: true as boolean,\n drawAttention: true as boolean,\n drawGestures: true as boolean,\n drawPolygons: true as boolean,\n drawGaze: true as boolean,\n fillPolygons: false as boolean,\n useDepth: true as boolean,\n useCurves: false as boolean,\n faceLabels: '' as string,\n bodyLabels: '' as string,\n bodyPartLabels: '' as string,\n objectLabels: '' as string,\n handLabels: '' as string,\n fingerLabels: '' as string,\n gestureLabels: '' as string,\n};\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n * See `facemesh.ts` for entry point\n */\n\nexport const meshAnnotations: Record = {\n silhouette: [\n 10, 338, 297, 332, 284, 251, 389, 356, 454, 323, 361, 288,\n 397, 365, 379, 378, 400, 377, 152, 148, 176, 149, 150, 136,\n 172, 58, 132, 93, 234, 127, 162, 21, 54, 103, 67, 109,\n ],\n // lipsUpperOuter: [61, 185, 40, 39, 37, 0, 267, 269, 270, 409, 291], // 11\n // lipsLowerOuter: [146, 91, 181, 84, 17, 314, 405, 321, 375, 291], // 10\n // lipsUpperInner: [78, 191, 80, 81, 82, 13, 312, 311, 310, 415, 308], // 11\n // lipsLowerInner: [78, 95, 88, 178, 87, 14, 317, 402, 318, 324, 308], // 11\n lipsUpperOuter: [185, 40, 39, 37, 0, 267, 269, 270, 409],\n lipsLowerOuter: [61, 146, 91, 181, 84, 17, 314, 405, 321, 375, 291],\n lipsUpperInner: [191, 80, 81, 82, 13, 312, 311, 310, 415],\n lipsLowerInner: [78, 95, 88, 178, 87, 14, 317, 402, 318, 324, 308],\n lipsLowerSemiOuter: [76, 77, 90, 180, 85, 16, 315, 404, 320, 307, 306],\n lipsUpperSemiOuter: [184, 74, 73, 72, 11, 302, 303, 304, 408],\n lipsLowerSemiInner: [62, 96, 89, 179, 86, 15, 316, 403, 319, 325, 292],\n lipsUpperSemiInner: [183, 42, 41, 38, 12, 268, 271, 272, 407],\n rightEyeUpper0: [246, 161, 160, 159, 158, 157, 173], // 7\n rightEyeLower0: [33, 7, 163, 144, 145, 153, 154, 155, 133], // 9\n rightEyeUpper1: [247, 30, 29, 27, 28, 56, 190], // 7\n rightEyeLower1: [130, 25, 110, 24, 23, 22, 26, 112, 243], // 9\n rightEyeUpper2: [113, 225, 224, 223, 222, 221, 189], // 7\n rightEyeLower2: [226, 31, 228, 229, 230, 231, 232, 233, 244], // 9\n rightEyeLower3: [143, 111, 117, 118, 119, 120, 121, 128, 245], // 9\n rightEyebrowUpper: [156, 70, 63, 105, 66, 107, 55, 193], // 8\n rightEyebrowLower: [35, 124, 46, 53, 52, 65], // 6\n rightEyeIris: [473, 474, 475, 476, 477], // 5\n leftEyeUpper0: [466, 388, 387, 386, 385, 384, 398],\n leftEyeLower0: [263, 249, 390, 373, 374, 380, 381, 382, 362],\n leftEyeUpper1: [467, 260, 259, 257, 258, 286, 414],\n leftEyeLower1: [359, 255, 339, 254, 253, 252, 256, 341, 463],\n leftEyeUpper2: [342, 445, 444, 443, 442, 441, 413],\n leftEyeLower2: [446, 261, 448, 449, 450, 451, 452, 453, 464],\n leftEyeLower3: [372, 340, 346, 347, 348, 349, 350, 357, 465],\n leftEyebrowUpper: [383, 300, 293, 334, 296, 336, 285, 417],\n leftEyebrowLower: [265, 353, 276, 283, 282, 295],\n leftEyeIris: [468, 469, 470, 471, 472],\n midwayBetweenEyes: [168],\n noseTip: [1],\n noseBottom: [2],\n noseRightCorner: [98],\n noseLeftCorner: [327],\n rightCheek: [205],\n leftCheek: [425],\n};\n\nexport const meshLandmarks: Record = {\n count: 468,\n mouth: 13,\n symmetryLine: [13, meshAnnotations.midwayBetweenEyes[0]],\n};\n\nexport const blazeFaceLandmarks: Record = {\n leftEye: 0,\n rightEye: 1,\n nose: 2,\n mouth: 3,\n leftEar: 4,\n rightEar: 5,\n symmetryLine: [3, 2],\n};\n\nexport const irisIndices: { key: string, indices: number[] }[] = [ // A mapping from facemesh model keypoints to iris model keypoints.\n { key: 'EyeUpper0', indices: [9, 10, 11, 12, 13, 14, 15] }, // 7 x 3d\n { key: 'EyeUpper1', indices: [25, 26, 27, 28, 29, 30, 31] }, // 7 x 3d\n { key: 'EyeUpper2', indices: [41, 42, 43, 44, 45, 46, 47] }, // 7 x 3d\n { key: 'EyeLower0', indices: [0, 1, 2, 3, 4, 5, 6, 7, 8] }, // 7 x 3d\n { key: 'EyeLower1', indices: [16, 17, 18, 19, 20, 21, 22, 23, 24] }, // 9 x 3d\n { key: 'EyeLower2', indices: [32, 33, 34, 35, 36, 37, 38, 39, 40] }, // 9 x 3d\n { key: 'EyeLower3', indices: [54, 55, 56, 57, 58, 59, 60, 61, 62] }, // 9 x 3d\n { key: 'EyebrowUpper', indices: [63, 64, 65, 66, 67, 68, 69, 70] }, // 8 x 3d\n { key: 'EyebrowLower', indices: [48, 49, 50, 51, 52, 53] }, // 6 x 3d\n];\n\nexport const UV468: [number, number][] = [\n [0.499976992607117, 0.652534008026123],\n [0.500025987625122, 0.547487020492554],\n [0.499974012374878, 0.602371990680695],\n [0.482113003730774, 0.471979022026062],\n [0.500150978565216, 0.527155995368958],\n [0.499909996986389, 0.498252987861633],\n [0.499523013830185, 0.40106201171875],\n [0.289712011814117, 0.380764007568359],\n [0.499954998493195, 0.312398016452789],\n [0.499987006187439, 0.269918978214264],\n [0.500023007392883, 0.107050001621246],\n [0.500023007392883, 0.666234016418457],\n [0.5000159740448, 0.679224014282227],\n [0.500023007392883, 0.692348003387451],\n [0.499976992607117, 0.695277988910675],\n [0.499976992607117, 0.70593398809433],\n [0.499976992607117, 0.719385027885437],\n [0.499976992607117, 0.737019002437592],\n [0.499967992305756, 0.781370997428894],\n [0.499816000461578, 0.562981009483337],\n [0.473773002624512, 0.573909997940063],\n [0.104906998574734, 0.254140973091125],\n [0.365929991006851, 0.409575998783112],\n [0.338757991790771, 0.41302502155304],\n [0.311120003461838, 0.409460008144379],\n [0.274657994508743, 0.389131009578705],\n [0.393361985683441, 0.403706014156342],\n [0.345234006643295, 0.344011008739471],\n [0.370094001293182, 0.346076011657715],\n [0.319321990013123, 0.347265005111694],\n [0.297903001308441, 0.353591024875641],\n [0.24779200553894, 0.410809993743896],\n [0.396889001131058, 0.842755019664764],\n [0.280097991228104, 0.375599980354309],\n [0.106310002505779, 0.399955987930298],\n [0.2099249958992, 0.391353011131287],\n [0.355807989835739, 0.534406006336212],\n [0.471751004457474, 0.65040397644043],\n [0.474155008792877, 0.680191993713379],\n [0.439785003662109, 0.657229006290436],\n [0.414617002010345, 0.66654098033905],\n [0.450374007225037, 0.680860996246338],\n [0.428770989179611, 0.682690978050232],\n [0.374971002340317, 0.727805018424988],\n [0.486716985702515, 0.547628998756409],\n [0.485300987958908, 0.527395009994507],\n [0.257764995098114, 0.314490020275116],\n [0.401223003864288, 0.455172002315521],\n [0.429818987846375, 0.548614978790283],\n [0.421351999044418, 0.533740997314453],\n [0.276895999908447, 0.532056987285614],\n [0.483370006084442, 0.499586999416351],\n [0.33721199631691, 0.282882988452911],\n [0.296391993761063, 0.293242990970612],\n [0.169294998049736, 0.193813979625702],\n [0.447580009698868, 0.302609980106354],\n [0.392390012741089, 0.353887975215912],\n [0.354490011930466, 0.696784019470215],\n [0.067304998636246, 0.730105042457581],\n [0.442739009857178, 0.572826027870178],\n [0.457098007202148, 0.584792017936707],\n [0.381974011659622, 0.694710969924927],\n [0.392388999462128, 0.694203019142151],\n [0.277076005935669, 0.271932005882263],\n [0.422551989555359, 0.563233017921448],\n [0.385919004678726, 0.281364023685455],\n [0.383103013038635, 0.255840003490448],\n [0.331431001424789, 0.119714021682739],\n [0.229923993349075, 0.232002973556519],\n [0.364500999450684, 0.189113974571228],\n [0.229622006416321, 0.299540996551514],\n [0.173287004232407, 0.278747975826263],\n [0.472878992557526, 0.666198015213013],\n [0.446828007698059, 0.668527007102966],\n [0.422762006521225, 0.673889994621277],\n [0.445307999849319, 0.580065965652466],\n [0.388103008270264, 0.693961024284363],\n [0.403039008378983, 0.706539988517761],\n [0.403629004955292, 0.693953037261963],\n [0.460041999816895, 0.557139039039612],\n [0.431158006191254, 0.692366003990173],\n [0.452181994915009, 0.692366003990173],\n [0.475387006998062, 0.692366003990173],\n [0.465828001499176, 0.779190003871918],\n [0.472328990697861, 0.736225962638855],\n [0.473087012767792, 0.717857003211975],\n [0.473122000694275, 0.704625964164734],\n [0.473033010959625, 0.695277988910675],\n [0.427942007780075, 0.695277988910675],\n [0.426479011774063, 0.703539967536926],\n [0.423162013292313, 0.711845993995667],\n [0.4183090031147, 0.720062971115112],\n [0.390094995498657, 0.639572978019714],\n [0.013953999616206, 0.560034036636353],\n [0.499913990497589, 0.58014702796936],\n [0.413199990987778, 0.69539999961853],\n [0.409626007080078, 0.701822996139526],\n [0.468080013990402, 0.601534962654114],\n [0.422728985548019, 0.585985004901886],\n [0.463079988956451, 0.593783974647522],\n [0.37211999297142, 0.47341400384903],\n [0.334562003612518, 0.496073007583618],\n [0.411671012639999, 0.546965003013611],\n [0.242175996303558, 0.14767599105835],\n [0.290776997804642, 0.201445996761322],\n [0.327338010072708, 0.256527006626129],\n [0.399509996175766, 0.748921036720276],\n [0.441727995872498, 0.261676013469696],\n [0.429764986038208, 0.187834024429321],\n [0.412198007106781, 0.108901023864746],\n [0.288955003023148, 0.398952007293701],\n [0.218936994671822, 0.435410976409912],\n [0.41278201341629, 0.398970007896423],\n [0.257135003805161, 0.355440020561218],\n [0.427684992551804, 0.437960982322693],\n [0.448339998722076, 0.536936044692993],\n [0.178560003638268, 0.45755398273468],\n [0.247308000922203, 0.457193970680237],\n [0.286267012357712, 0.467674970626831],\n [0.332827985286713, 0.460712015628815],\n [0.368755996227264, 0.447206974029541],\n [0.398963987827301, 0.432654976844788],\n [0.476410001516342, 0.405806005001068],\n [0.189241006970406, 0.523923993110657],\n [0.228962004184723, 0.348950982093811],\n [0.490725994110107, 0.562400996685028],\n [0.404670000076294, 0.485132992267609],\n [0.019469000399113, 0.401564002037048],\n [0.426243007183075, 0.420431017875671],\n [0.396993011236191, 0.548797011375427],\n [0.266469985246658, 0.376977026462555],\n [0.439121007919312, 0.51895797252655],\n [0.032313998788595, 0.644356966018677],\n [0.419054001569748, 0.387154996395111],\n [0.462783008813858, 0.505746960639954],\n [0.238978996872902, 0.779744982719421],\n [0.198220998048782, 0.831938028335571],\n [0.107550002634525, 0.540755033493042],\n [0.183610007166862, 0.740257024765015],\n [0.134409993886948, 0.333683013916016],\n [0.385764002799988, 0.883153975009918],\n [0.490967005491257, 0.579378008842468],\n [0.382384985685349, 0.508572995662689],\n [0.174399003386497, 0.397670984268188],\n [0.318785011768341, 0.39623498916626],\n [0.343364000320435, 0.400596976280212],\n [0.396100014448166, 0.710216999053955],\n [0.187885001301765, 0.588537991046906],\n [0.430987000465393, 0.944064974784851],\n [0.318993002176285, 0.898285031318665],\n [0.266247987747192, 0.869701027870178],\n [0.500023007392883, 0.190576016902924],\n [0.499976992607117, 0.954452991485596],\n [0.366169989109039, 0.398822009563446],\n [0.393207013607025, 0.39553701877594],\n [0.410373002290726, 0.391080021858215],\n [0.194993004202843, 0.342101991176605],\n [0.388664990663528, 0.362284004688263],\n [0.365961998701096, 0.355970978736877],\n [0.343364000320435, 0.355356991291046],\n [0.318785011768341, 0.35834002494812],\n [0.301414996385574, 0.363156020641327],\n [0.058132998645306, 0.319076001644135],\n [0.301414996385574, 0.387449026107788],\n [0.499987989664078, 0.618434011936188],\n [0.415838003158569, 0.624195992946625],\n [0.445681989192963, 0.566076993942261],\n [0.465844005346298, 0.620640993118286],\n [0.49992299079895, 0.351523995399475],\n [0.288718998432159, 0.819945991039276],\n [0.335278987884521, 0.852819979190826],\n [0.440512001514435, 0.902418971061707],\n [0.128294005990028, 0.791940987110138],\n [0.408771991729736, 0.373893976211548],\n [0.455606997013092, 0.451801002025604],\n [0.499877005815506, 0.908990025520325],\n [0.375436991453171, 0.924192011356354],\n [0.11421000212431, 0.615022003650665],\n [0.448662012815475, 0.695277988910675],\n [0.4480200111866, 0.704632043838501],\n [0.447111994028091, 0.715808033943176],\n [0.444831997156143, 0.730794012546539],\n [0.430011987686157, 0.766808986663818],\n [0.406787008047104, 0.685672998428345],\n [0.400738000869751, 0.681069016456604],\n [0.392399996519089, 0.677703022956848],\n [0.367855995893478, 0.663918972015381],\n [0.247923001646996, 0.601333022117615],\n [0.452769994735718, 0.420849978923798],\n [0.43639200925827, 0.359887003898621],\n [0.416164010763168, 0.368713974952698],\n [0.413385987281799, 0.692366003990173],\n [0.228018000721931, 0.683571994304657],\n [0.468268007040024, 0.352671027183533],\n [0.411361992359161, 0.804327011108398],\n [0.499989002943039, 0.469825029373169],\n [0.479153990745544, 0.442654013633728],\n [0.499974012374878, 0.439637005329132],\n [0.432112008333206, 0.493588984012604],\n [0.499886006116867, 0.866917014122009],\n [0.49991300702095, 0.821729004383087],\n [0.456548988819122, 0.819200992584229],\n [0.344549000263214, 0.745438992977142],\n [0.37890899181366, 0.574010014533997],\n [0.374292999505997, 0.780184984207153],\n [0.319687992334366, 0.570737957954407],\n [0.357154995203018, 0.604269981384277],\n [0.295284003019333, 0.621580958366394],\n [0.447750002145767, 0.862477004528046],\n [0.410986006259918, 0.508723020553589],\n [0.31395098567009, 0.775308012962341],\n [0.354128003120422, 0.812552988529205],\n [0.324548006057739, 0.703992962837219],\n [0.189096003770828, 0.646299958229065],\n [0.279776990413666, 0.71465802192688],\n [0.1338230073452, 0.682700991630554],\n [0.336768001317978, 0.644733011722565],\n [0.429883986711502, 0.466521978378296],\n [0.455527991056442, 0.548622965812683],\n [0.437114000320435, 0.558896005153656],\n [0.467287987470627, 0.529924988746643],\n [0.414712011814117, 0.335219979286194],\n [0.37704598903656, 0.322777986526489],\n [0.344107985496521, 0.320150971412659],\n [0.312875986099243, 0.32233202457428],\n [0.283526003360748, 0.333190023899078],\n [0.241245999932289, 0.382785975933075],\n [0.102986000478268, 0.468762993812561],\n [0.267612010240555, 0.424560010433197],\n [0.297879010438919, 0.433175981044769],\n [0.333433985710144, 0.433878004550934],\n [0.366427004337311, 0.426115989685059],\n [0.396012008190155, 0.416696012020111],\n [0.420121014118195, 0.41022801399231],\n [0.007561000064015, 0.480777025222778],\n [0.432949006557465, 0.569517970085144],\n [0.458638995885849, 0.479089021682739],\n [0.473466008901596, 0.545744001865387],\n [0.476087987422943, 0.563830018043518],\n [0.468472003936768, 0.555056989192963],\n [0.433990985155106, 0.582361996173859],\n [0.483518004417419, 0.562983989715576],\n [0.482482999563217, 0.57784903049469],\n [0.42645001411438, 0.389798998832703],\n [0.438998997211456, 0.39649498462677],\n [0.450067013502121, 0.400434017181396],\n [0.289712011814117, 0.368252992630005],\n [0.276670008897781, 0.363372981548309],\n [0.517862021923065, 0.471948027610779],\n [0.710287988185883, 0.380764007568359],\n [0.526226997375488, 0.573909997940063],\n [0.895093023777008, 0.254140973091125],\n [0.634069979190826, 0.409575998783112],\n [0.661242008209229, 0.41302502155304],\n [0.688880026340485, 0.409460008144379],\n [0.725341975688934, 0.389131009578705],\n [0.606630027294159, 0.40370500087738],\n [0.654766023159027, 0.344011008739471],\n [0.629905998706818, 0.346076011657715],\n [0.680678009986877, 0.347265005111694],\n [0.702096998691559, 0.353591024875641],\n [0.75221198797226, 0.410804986953735],\n [0.602918028831482, 0.842862963676453],\n [0.719901978969574, 0.375599980354309],\n [0.893692970275879, 0.399959981441498],\n [0.790081977844238, 0.391354024410248],\n [0.643998026847839, 0.534487962722778],\n [0.528249025344849, 0.65040397644043],\n [0.525849997997284, 0.680191040039062],\n [0.560214996337891, 0.657229006290436],\n [0.585384011268616, 0.66654098033905],\n [0.549625992774963, 0.680860996246338],\n [0.57122802734375, 0.682691991329193],\n [0.624852001667023, 0.72809898853302],\n [0.513050019741058, 0.547281980514526],\n [0.51509702205658, 0.527251958847046],\n [0.742246985435486, 0.314507007598877],\n [0.598631024360657, 0.454979002475739],\n [0.570338010787964, 0.548575043678284],\n [0.578631997108459, 0.533622980117798],\n [0.723087012767792, 0.532054007053375],\n [0.516445994377136, 0.499638974666595],\n [0.662801027297974, 0.282917976379395],\n [0.70362401008606, 0.293271005153656],\n [0.830704987049103, 0.193813979625702],\n [0.552385985851288, 0.302568018436432],\n [0.607609987258911, 0.353887975215912],\n [0.645429015159607, 0.696707010269165],\n [0.932694971561432, 0.730105042457581],\n [0.557260990142822, 0.572826027870178],\n [0.542901992797852, 0.584792017936707],\n [0.6180260181427, 0.694710969924927],\n [0.607590973377228, 0.694203019142151],\n [0.722943007946014, 0.271963000297546],\n [0.577413976192474, 0.563166975975037],\n [0.614082992076874, 0.281386971473694],\n [0.616907000541687, 0.255886018276215],\n [0.668509006500244, 0.119913995265961],\n [0.770092010498047, 0.232020974159241],\n [0.635536015033722, 0.189248979091644],\n [0.77039098739624, 0.299556016921997],\n [0.826722025871277, 0.278755009174347],\n [0.527121007442474, 0.666198015213013],\n [0.553171992301941, 0.668527007102966],\n [0.577238023281097, 0.673889994621277],\n [0.554691970348358, 0.580065965652466],\n [0.611896991729736, 0.693961024284363],\n [0.59696102142334, 0.706539988517761],\n [0.596370995044708, 0.693953037261963],\n [0.539958000183105, 0.557139039039612],\n [0.568841993808746, 0.692366003990173],\n [0.547818005084991, 0.692366003990173],\n [0.52461302280426, 0.692366003990173],\n [0.534089982509613, 0.779141008853912],\n [0.527670979499817, 0.736225962638855],\n [0.526912987232208, 0.717857003211975],\n [0.526877999305725, 0.704625964164734],\n [0.526966989040375, 0.695277988910675],\n [0.572058022022247, 0.695277988910675],\n [0.573521018028259, 0.703539967536926],\n [0.57683801651001, 0.711845993995667],\n [0.581691026687622, 0.720062971115112],\n [0.609944999217987, 0.639909982681274],\n [0.986046016216278, 0.560034036636353],\n [0.5867999792099, 0.69539999961853],\n [0.590372025966644, 0.701822996139526],\n [0.531915009021759, 0.601536989212036],\n [0.577268004417419, 0.585934996604919],\n [0.536915004253387, 0.593786001205444],\n [0.627542972564697, 0.473352015018463],\n [0.665585994720459, 0.495950996875763],\n [0.588353991508484, 0.546862006187439],\n [0.757824003696442, 0.14767599105835],\n [0.709249973297119, 0.201507985591888],\n [0.672684013843536, 0.256581008434296],\n [0.600408971309662, 0.74900496006012],\n [0.55826598405838, 0.261672019958496],\n [0.570303976535797, 0.187870979309082],\n [0.588165998458862, 0.109044015407562],\n [0.711045026779175, 0.398952007293701],\n [0.781069993972778, 0.435405015945435],\n [0.587247014045715, 0.398931980133057],\n [0.742869973182678, 0.355445981025696],\n [0.572156012058258, 0.437651991844177],\n [0.55186802148819, 0.536570012569427],\n [0.821442008018494, 0.457556009292603],\n [0.752701997756958, 0.457181990146637],\n [0.71375697851181, 0.467626988887787],\n [0.66711300611496, 0.460672974586487],\n [0.631101012229919, 0.447153985500336],\n [0.6008620262146, 0.432473003864288],\n [0.523481011390686, 0.405627012252808],\n [0.810747981071472, 0.523926019668579],\n [0.771045982837677, 0.348959028720856],\n [0.509127020835876, 0.562718033790588],\n [0.595292985439301, 0.485023975372314],\n [0.980530977249146, 0.401564002037048],\n [0.573499977588654, 0.420000016689301],\n [0.602994978427887, 0.548687994480133],\n [0.733529984951019, 0.376977026462555],\n [0.560611009597778, 0.519016981124878],\n [0.967685997486115, 0.644356966018677],\n [0.580985009670258, 0.387160003185272],\n [0.537728011608124, 0.505385041236877],\n [0.760966002941132, 0.779752969741821],\n [0.801778972148895, 0.831938028335571],\n [0.892440974712372, 0.54076099395752],\n [0.816350996494293, 0.740260004997253],\n [0.865594983100891, 0.333687007427216],\n [0.614073991775513, 0.883246004581451],\n [0.508952975273132, 0.579437971115112],\n [0.617941975593567, 0.508316040039062],\n [0.825608015060425, 0.397674977779388],\n [0.681214988231659, 0.39623498916626],\n [0.656635999679565, 0.400596976280212],\n [0.603900015354156, 0.710216999053955],\n [0.81208598613739, 0.588539004325867],\n [0.56801301240921, 0.944564998149872],\n [0.681007981300354, 0.898285031318665],\n [0.733752012252808, 0.869701027870178],\n [0.633830010890961, 0.398822009563446],\n [0.606792986392975, 0.39553701877594],\n [0.589659988880157, 0.391062021255493],\n [0.805015981197357, 0.342108011245728],\n [0.611334979534149, 0.362284004688263],\n [0.634037971496582, 0.355970978736877],\n [0.656635999679565, 0.355356991291046],\n [0.681214988231659, 0.35834002494812],\n [0.698584973812103, 0.363156020641327],\n [0.941866993904114, 0.319076001644135],\n [0.698584973812103, 0.387449026107788],\n [0.584177017211914, 0.624107003211975],\n [0.554318010807037, 0.566076993942261],\n [0.534153997898102, 0.62064003944397],\n [0.711217999458313, 0.819975018501282],\n [0.664629995822906, 0.852871000766754],\n [0.559099972248077, 0.902631998062134],\n [0.871706008911133, 0.791940987110138],\n [0.591234028339386, 0.373893976211548],\n [0.544341027736664, 0.451583981513977],\n [0.624562978744507, 0.924192011356354],\n [0.88577002286911, 0.615028977394104],\n [0.551338016986847, 0.695277988910675],\n [0.551980018615723, 0.704632043838501],\n [0.552887976169586, 0.715808033943176],\n [0.555167973041534, 0.730794012546539],\n [0.569944024085999, 0.767035007476807],\n [0.593203008174896, 0.685675978660583],\n [0.599261999130249, 0.681069016456604],\n [0.607599973678589, 0.677703022956848],\n [0.631937980651855, 0.663500010967255],\n [0.752032995223999, 0.601315021514893],\n [0.547226011753082, 0.420395016670227],\n [0.563543975353241, 0.359827995300293],\n [0.583841025829315, 0.368713974952698],\n [0.586614012718201, 0.692366003990173],\n [0.771915018558502, 0.683578014373779],\n [0.531597018241882, 0.352482974529266],\n [0.588370978832245, 0.804440975189209],\n [0.52079701423645, 0.442565023899078],\n [0.567984998226166, 0.493479013442993],\n [0.543282985687256, 0.819254994392395],\n [0.655317008495331, 0.745514988899231],\n [0.621008992195129, 0.574018001556396],\n [0.625559985637665, 0.78031200170517],\n [0.680198013782501, 0.570719003677368],\n [0.64276397228241, 0.604337990283966],\n [0.704662978649139, 0.621529996395111],\n [0.552012026309967, 0.862591981887817],\n [0.589071989059448, 0.508637011051178],\n [0.685944974422455, 0.775357007980347],\n [0.645735025405884, 0.812640011310577],\n [0.675342977046967, 0.703978002071381],\n [0.810858011245728, 0.646304965019226],\n [0.72012197971344, 0.714666962623596],\n [0.866151988506317, 0.682704985141754],\n [0.663187026977539, 0.644596993923187],\n [0.570082008838654, 0.466325998306274],\n [0.544561982154846, 0.548375964164734],\n [0.562758982181549, 0.558784961700439],\n [0.531987011432648, 0.530140042304993],\n [0.585271000862122, 0.335177004337311],\n [0.622952997684479, 0.32277899980545],\n [0.655896008014679, 0.320163011550903],\n [0.687132000923157, 0.322345972061157],\n [0.716481983661652, 0.333200991153717],\n [0.758756995201111, 0.382786989212036],\n [0.897013008594513, 0.468769013881683],\n [0.732392013072968, 0.424547016620636],\n [0.70211398601532, 0.433162987232208],\n [0.66652500629425, 0.433866024017334],\n [0.633504986763, 0.426087975502014],\n [0.603875994682312, 0.416586995124817],\n [0.579657971858978, 0.409945011138916],\n [0.992439985275269, 0.480777025222778],\n [0.567192018032074, 0.569419980049133],\n [0.54136598110199, 0.478899002075195],\n [0.526564002037048, 0.546118021011353],\n [0.523913025856018, 0.563830018043518],\n [0.531529009342194, 0.555056989192963],\n [0.566035985946655, 0.582329034805298],\n [0.51631098985672, 0.563053965568542],\n [0.5174720287323, 0.577877044677734],\n [0.573594987392426, 0.389806985855103],\n [0.560697972774506, 0.395331978797913],\n [0.549755990505219, 0.399751007556915],\n [0.710287988185883, 0.368252992630005],\n [0.723330020904541, 0.363372981548309],\n];\n\nexport const TRI468: number[] = [\n 127, 34, 139, 11, 0, 37, 232, 231, 120, 72, 37, 39, 128, 121, 47, 232, 121, 128, 104, 69, 67, 175, 171, 148, 157, 154, 155, 118, 50, 101, 73, 39, 40, 9,\n 151, 108, 48, 115, 131, 194, 204, 211, 74, 40, 185, 80, 42, 183, 40, 92, 186, 230, 229, 118, 202, 212, 214, 83, 18, 17, 76, 61, 146, 160, 29, 30, 56,\n 157, 173, 106, 204, 194, 135, 214, 192, 203, 165, 98, 21, 71, 68, 51, 45, 4, 144, 24, 23, 77, 146, 91, 205, 50, 187, 201, 200, 18, 91, 106, 182, 90, 91,\n 181, 85, 84, 17, 206, 203, 36, 148, 171, 140, 92, 40, 39, 193, 189, 244, 159, 158, 28, 247, 246, 161, 236, 3, 196, 54, 68, 104, 193, 168, 8, 117,\n 228, 31, 189, 193, 55, 98, 97, 99, 126, 47, 100, 166, 79, 218, 155, 154, 26, 209, 49, 131, 135, 136, 150, 47, 126, 217, 223, 52, 53, 45, 51, 134, 211,\n 170, 140, 67, 69, 108, 43, 106, 91, 230, 119, 120, 226, 130, 247, 63, 53, 52, 238, 20, 242, 46, 70, 156, 78, 62, 96, 46, 53, 63, 143, 34, 227, 173,\n 155, 133, 123, 117, 111, 44, 125, 19, 236, 134, 51, 216, 206, 205, 154, 153, 22, 39, 37, 167, 200, 201, 208, 36, 142, 100, 57, 212, 202, 20, 60, 99, 28,\n 158, 157, 35, 226, 113, 160, 159, 27, 204, 202, 210, 113, 225, 46, 43, 202, 204, 62, 76, 77, 137, 123, 116, 41, 38, 72, 203, 129, 142, 64, 98, 240, 49,\n 102, 64, 41, 73, 74, 212, 216, 207, 42, 74, 184, 169, 170, 211, 170, 149, 176, 105, 66, 69, 122, 6, 168, 123, 147, 187, 96, 77, 90, 65, 55, 107, 89,\n 90, 180, 101, 100, 120, 63, 105, 104, 93, 137, 227, 15, 86, 85, 129, 102, 49, 14, 87, 86, 55, 8, 9, 100, 47, 121, 145, 23, 22, 88, 89, 179, 6, 122,\n 196, 88, 95, 96, 138, 172, 136, 215, 58, 172, 115, 48, 219, 42, 80, 81, 195, 3, 51, 43, 146, 61, 171, 175, 199, 81, 82, 38, 53, 46, 225, 144, 163, 110,\n 246, 33, 7, 52, 65, 66, 229, 228, 117, 34, 127, 234, 107, 108, 69, 109, 108, 151, 48, 64, 235, 62, 78, 191, 129, 209, 126, 111, 35, 143, 163, 161, 246,\n 117, 123, 50, 222, 65, 52, 19, 125, 141, 221, 55, 65, 3, 195, 197, 25, 7, 33, 220, 237, 44, 70, 71, 139, 122, 193, 245, 247, 130, 33, 71, 21, 162,\n 153, 158, 159, 170, 169, 150, 188, 174, 196, 216, 186, 92, 144, 160, 161, 2, 97, 167, 141, 125, 241, 164, 167, 37, 72, 38, 12, 145, 159, 160, 38, 82, 13,\n 63, 68, 71, 226, 35, 111, 158, 153, 154, 101, 50, 205, 206, 92, 165, 209, 198, 217, 165, 167, 97, 220, 115, 218, 133, 112, 243, 239, 238, 241, 214,\n 135, 169, 190, 173, 133, 171, 208, 32, 125, 44, 237, 86, 87, 178, 85, 86, 179, 84, 85, 180, 83, 84, 181, 201, 83, 182, 137, 93, 132, 76, 62, 183, 61,\n 76, 184, 57, 61, 185, 212, 57, 186, 214, 207, 187, 34, 143, 156, 79, 239, 237, 123, 137, 177, 44, 1, 4, 201, 194, 32, 64, 102, 129, 213, 215, 138, 59,\n 166, 219, 242, 99, 97, 2, 94, 141, 75, 59, 235, 24, 110, 228, 25, 130, 226, 23, 24, 229, 22, 23, 230, 26, 22, 231, 112, 26, 232, 189, 190, 243, 221, 56,\n 190, 28, 56, 221, 27, 28, 222, 29, 27, 223, 30, 29, 224, 247, 30, 225, 238, 79, 20, 166, 59, 75, 60, 75, 240, 147, 177, 215, 20, 79, 166, 187, 147, 213,\n 112, 233, 244, 233, 128, 245, 128, 114, 188, 114, 217, 174, 131, 115, 220, 217, 198, 236, 198, 131, 134, 177, 132, 58, 143, 35, 124, 110, 163, 7, 228,\n 110, 25, 356, 389, 368, 11, 302, 267, 452, 350, 349, 302, 303, 269, 357, 343, 277, 452, 453, 357, 333, 332, 297, 175, 152, 377, 384, 398, 382, 347,\n 348, 330, 303, 304, 270, 9, 336, 337, 278, 279, 360, 418, 262, 431, 304, 408, 409, 310, 415, 407, 270, 409, 410, 450, 348, 347, 422, 430, 434, 313,\n 314, 17, 306, 307, 375, 387, 388, 260, 286, 414, 398, 335, 406, 418, 364, 367, 416, 423, 358, 327, 251, 284, 298, 281, 5, 4, 373, 374, 253, 307, 320,\n 321, 425, 427, 411, 421, 313, 18, 321, 405, 406, 320, 404, 405, 315, 16, 17, 426, 425, 266, 377, 400, 369, 322, 391, 269, 417, 465, 464, 386, 257, 258,\n 466, 260, 388, 456, 399, 419, 284, 332, 333, 417, 285, 8, 346, 340, 261, 413, 441, 285, 327, 460, 328, 355, 371, 329, 392, 439, 438, 382, 341, 256,\n 429, 420, 360, 364, 394, 379, 277, 343, 437, 443, 444, 283, 275, 440, 363, 431, 262, 369, 297, 338, 337, 273, 375, 321, 450, 451, 349, 446, 342, 467,\n 293, 334, 282, 458, 461, 462, 276, 353, 383, 308, 324, 325, 276, 300, 293, 372, 345, 447, 382, 398, 362, 352, 345, 340, 274, 1, 19, 456, 248, 281, 436,\n 427, 425, 381, 256, 252, 269, 391, 393, 200, 199, 428, 266, 330, 329, 287, 273, 422, 250, 462, 328, 258, 286, 384, 265, 353, 342, 387, 259, 257, 424,\n 431, 430, 342, 353, 276, 273, 335, 424, 292, 325, 307, 366, 447, 345, 271, 303, 302, 423, 266, 371, 294, 455, 460, 279, 278, 294, 271, 272, 304, 432,\n 434, 427, 272, 407, 408, 394, 430, 431, 395, 369, 400, 334, 333, 299, 351, 417, 168, 352, 280, 411, 325, 319, 320, 295, 296, 336, 319, 403, 404, 330,\n 348, 349, 293, 298, 333, 323, 454, 447, 15, 16, 315, 358, 429, 279, 14, 15, 316, 285, 336, 9, 329, 349, 350, 374, 380, 252, 318, 402, 403, 6, 197, 419,\n 318, 319, 325, 367, 364, 365, 435, 367, 397, 344, 438, 439, 272, 271, 311, 195, 5, 281, 273, 287, 291, 396, 428, 199, 311, 271, 268, 283, 444, 445,\n 373, 254, 339, 263, 466, 249, 282, 334, 296, 449, 347, 346, 264, 447, 454, 336, 296, 299, 338, 10, 151, 278, 439, 455, 292, 407, 415, 358, 371, 355,\n 340, 345, 372, 390, 249, 466, 346, 347, 280, 442, 443, 282, 19, 94, 370, 441, 442, 295, 248, 419, 197, 263, 255, 359, 440, 275, 274, 300, 383, 368,\n 351, 412, 465, 263, 467, 466, 301, 368, 389, 380, 374, 386, 395, 378, 379, 412, 351, 419, 436, 426, 322, 373, 390, 388, 2, 164, 393, 370, 462, 461,\n 164, 0, 267, 302, 11, 12, 374, 373, 387, 268, 12, 13, 293, 300, 301, 446, 261, 340, 385, 384, 381, 330, 266, 425, 426, 423, 391, 429, 355, 437, 391,\n 327, 326, 440, 457, 438, 341, 382, 362, 459, 457, 461, 434, 430, 394, 414, 463, 362, 396, 369, 262, 354, 461, 457, 316, 403, 402, 315, 404, 403, 314,\n 405, 404, 313, 406, 405, 421, 418, 406, 366, 401, 361, 306, 408, 407, 291, 409, 408, 287, 410, 409, 432, 436, 410, 434, 416, 411, 264, 368, 383, 309,\n 438, 457, 352, 376, 401, 274, 275, 4, 421, 428, 262, 294, 327, 358, 433, 416, 367, 289, 455, 439, 462, 370, 326, 2, 326, 370, 305, 460, 455, 254,\n 449, 448, 255, 261, 446, 253, 450, 449, 252, 451, 450, 256, 452, 451, 341, 453, 452, 413, 464, 463, 441, 413, 414, 258, 442, 441, 257, 443, 442, 259,\n 444, 443, 260, 445, 444, 467, 342, 445, 459, 458, 250, 289, 392, 290, 290, 328, 460, 376, 433, 435, 250, 290, 392, 411, 416, 433, 341, 463, 464, 453,\n 464, 465, 357, 465, 412, 343, 412, 399, 360, 363, 440, 437, 399, 456, 420, 456, 363, 401, 435, 288, 372, 383, 353, 339, 255, 249, 448, 261, 255, 133,\n 243, 190, 133, 155, 112, 33, 246, 247, 33, 130, 25, 398, 384, 286, 362, 398, 414, 362, 463, 341, 263, 359, 467, 263, 249, 255, 466, 467, 260, 75, 60,\n 166, 238, 239, 79, 162, 127, 139, 72, 11, 37, 121, 232, 120, 73, 72, 39, 114, 128, 47, 233, 232, 128, 103, 104, 67, 152, 175, 148, 173, 157, 155,\n 119, 118, 101, 74, 73, 40, 107, 9, 108, 49, 48, 131, 32, 194, 211, 184, 74, 185, 191, 80, 183, 185, 40, 186, 119, 230, 118, 210, 202, 214, 84, 83, 17,\n 77, 76, 146, 161, 160, 30, 190, 56, 173, 182, 106, 194, 138, 135, 192, 129, 203, 98, 54, 21, 68, 5, 51, 4, 145, 144, 23, 90, 77, 91, 207, 205, 187, 83,\n 201, 18, 181, 91, 182, 180, 90, 181, 16, 85, 17, 205, 206, 36, 176, 148, 140, 165, 92, 39, 245, 193, 244, 27, 159, 28, 30, 247, 161, 174, 236, 196,\n 103, 54, 104, 55, 193, 8, 111, 117, 31, 221, 189, 55, 240, 98, 99, 142, 126, 100, 219, 166, 218, 112, 155, 26, 198, 209, 131, 169, 135, 150, 114, 47,\n 217, 224, 223, 53, 220, 45, 134, 32, 211, 140, 109, 67, 108, 146, 43, 91, 231, 230, 120, 113, 226, 247, 105, 63, 52, 241, 238, 242, 124, 46, 156, 95,\n 78, 96, 70, 46, 63, 116, 143, 227, 116, 123, 111, 1, 44, 19, 3, 236, 51, 207, 216, 205, 26, 154, 22, 165, 39, 167, 199, 200, 208, 101, 36, 100, 43,\n 57, 202, 242, 20, 99, 56, 28, 157, 124, 35, 113, 29, 160, 27, 211, 204, 210, 124, 113, 46, 106, 43, 204, 96, 62, 77, 227, 137, 116, 73, 41, 72, 36, 203,\n 142, 235, 64, 240, 48, 49, 64, 42, 41, 74, 214, 212, 207, 183, 42, 184, 210, 169, 211, 140, 170, 176, 104, 105, 69, 193, 122, 168, 50, 123, 187, 89, 96,\n 90, 66, 65, 107, 179, 89, 180, 119, 101, 120, 68, 63, 104, 234, 93, 227, 16, 15, 85, 209, 129, 49, 15, 14, 86, 107, 55, 9, 120, 100, 121, 153, 145, 22,\n 178, 88, 179, 197, 6, 196, 89, 88, 96, 135, 138, 136, 138, 215, 172, 218, 115, 219, 41, 42, 81, 5, 195, 51, 57, 43, 61, 208, 171, 199, 41, 81, 38,\n 224, 53, 225, 24, 144, 110, 105, 52, 66, 118, 229, 117, 227, 34, 234, 66, 107, 69, 10, 109, 151, 219, 48, 235, 183, 62, 191, 142, 129, 126, 116, 111,\n 143, 7, 163, 246, 118, 117, 50, 223, 222, 52, 94, 19, 141, 222, 221, 65, 196, 3, 197, 45, 220, 44, 156, 70, 139, 188, 122, 245, 139, 71, 162, 145,\n 153, 159, 149, 170, 150, 122, 188, 196, 206, 216, 92, 163, 144, 161, 164, 2, 167, 242, 141, 241, 0, 164, 37, 11, 72, 12, 144, 145, 160, 12, 38, 13, 70,\n 63, 71, 31, 226, 111, 157, 158, 154, 36, 101, 205, 203, 206, 165, 126, 209, 217, 98, 165, 97, 237, 220, 218, 237, 239, 241, 210, 214, 169, 140, 171, 32,\n 241, 125, 237, 179, 86, 178, 180, 85, 179, 181, 84, 180, 182, 83, 181, 194, 201, 182, 177, 137, 132, 184, 76, 183, 185, 61, 184, 186, 57, 185, 216, 212,\n 186, 192, 214, 187, 139, 34, 156, 218, 79, 237, 147, 123, 177, 45, 44, 4, 208, 201, 32, 98, 64, 129, 192, 213, 138, 235, 59, 219, 141, 242, 97, 97, 2,\n 141, 240, 75, 235, 229, 24, 228, 31, 25, 226, 230, 23, 229, 231, 22, 230, 232, 26, 231, 233, 112, 232, 244, 189, 243, 189, 221, 190, 222, 28, 221,\n 223, 27, 222, 224, 29, 223, 225, 30, 224, 113, 247, 225, 99, 60, 240, 213, 147, 215, 60, 20, 166, 192, 187, 213, 243, 112, 244, 244, 233, 245, 245,\n 128, 188, 188, 114, 174, 134, 131, 220, 174, 217, 236, 236, 198, 134, 215, 177, 58, 156, 143, 124, 25, 110, 7, 31, 228, 25, 264, 356, 368, 0, 11, 267,\n 451, 452, 349, 267, 302, 269, 350, 357, 277, 350, 452, 357, 299, 333, 297, 396, 175, 377, 381, 384, 382, 280, 347, 330, 269, 303, 270, 151, 9, 337,\n 344, 278, 360, 424, 418, 431, 270, 304, 409, 272, 310, 407, 322, 270, 410, 449, 450, 347, 432, 422, 434, 18, 313, 17, 291, 306, 375, 259, 387, 260,\n 424, 335, 418, 434, 364, 416, 391, 423, 327, 301, 251, 298, 275, 281, 4, 254, 373, 253, 375, 307, 321, 280, 425, 411, 200, 421, 18, 335, 321, 406,\n 321, 320, 405, 314, 315, 17, 423, 426, 266, 396, 377, 369, 270, 322, 269, 413, 417, 464, 385, 386, 258, 248, 456, 419, 298, 284, 333, 168, 417, 8,\n 448, 346, 261, 417, 413, 285, 326, 327, 328, 277, 355, 329, 309, 392, 438, 381, 382, 256, 279, 429, 360, 365, 364, 379, 355, 277, 437, 282, 443, 283,\n 281, 275, 363, 395, 431, 369, 299, 297, 337, 335, 273, 321, 348, 450, 349, 359, 446, 467, 283, 293, 282, 250, 458, 462, 300, 276, 383, 292, 308, 325,\n 283, 276, 293, 264, 372, 447, 346, 352, 340, 354, 274, 19, 363, 456, 281, 426, 436, 425, 380, 381, 252, 267, 269, 393, 421, 200, 428, 371, 266, 329,\n 432, 287, 422, 290, 250, 328, 385, 258, 384, 446, 265, 342, 386, 387, 257, 422, 424, 430, 445, 342, 276, 422, 273, 424, 306, 292, 307, 352, 366, 345,\n 268, 271, 302, 358, 423, 371, 327, 294, 460, 331, 279, 294, 303, 271, 304, 436, 432, 427, 304, 272, 408, 395, 394, 431, 378, 395, 400, 296, 334, 299,\n 6, 351, 168, 376, 352, 411, 307, 325, 320, 285, 295, 336, 320, 319, 404, 329, 330, 349, 334, 293, 333, 366, 323, 447, 316, 15, 315, 331, 358, 279,\n 317, 14, 316, 8, 285, 9, 277, 329, 350, 253, 374, 252, 319, 318, 403, 351, 6, 419, 324, 318, 325, 397, 367, 365, 288, 435, 397, 278, 344, 439, 310,\n 272, 311, 248, 195, 281, 375, 273, 291, 175, 396, 199, 312, 311, 268, 276, 283, 445, 390, 373, 339, 295, 282, 296, 448, 449, 346, 356, 264, 454, 337,\n 336, 299, 337, 338, 151, 294, 278, 455, 308, 292, 415, 429, 358, 355, 265, 340, 372, 388, 390, 466, 352, 346, 280, 295, 442, 282, 354, 19, 370, 285,\n 441, 295, 195, 248, 197, 457, 440, 274, 301, 300, 368, 417, 351, 465, 251, 301, 389, 385, 380, 386, 394, 395, 379, 399, 412, 419, 410, 436, 322, 387,\n 373, 388, 326, 2, 393, 354, 370, 461, 393, 164, 267, 268, 302, 12, 386, 374, 387, 312, 268, 13, 298, 293, 301, 265, 446, 340, 380, 385, 381, 280, 330,\n 425, 322, 426, 391, 420, 429, 437, 393, 391, 326, 344, 440, 438, 458, 459, 461, 364, 434, 394, 428, 396, 262, 274, 354, 457, 317, 316, 402, 316, 315,\n 403, 315, 314, 404, 314, 313, 405, 313, 421, 406, 323, 366, 361, 292, 306, 407, 306, 291, 408, 291, 287, 409, 287, 432, 410, 427, 434, 411, 372, 264,\n 383, 459, 309, 457, 366, 352, 401, 1, 274, 4, 418, 421, 262, 331, 294, 358, 435, 433, 367, 392, 289, 439, 328, 462, 326, 94, 2, 370, 289, 305, 455, 339,\n 254, 448, 359, 255, 446, 254, 253, 449, 253, 252, 450, 252, 256, 451, 256, 341, 452, 414, 413, 463, 286, 441, 414, 286, 258, 441, 258, 257, 442, 257,\n 259, 443, 259, 260, 444, 260, 467, 445, 309, 459, 250, 305, 289, 290, 305, 290, 460, 401, 376, 435, 309, 250, 392, 376, 411, 433, 453, 341, 464, 357,\n 453, 465, 343, 357, 412, 437, 343, 399, 344, 360, 440, 420, 437, 456, 360, 420, 363, 361, 401, 288, 265, 372, 353, 390, 339, 249, 339, 448, 255];\n\nexport const TRI68: number[] = [0, 1, 36, 0, 36, 17, 1, 2, 41, 1, 41, 36, 2, 3, 31, 2, 31, 41, 3, 4, 48, 3, 48, 31, 4, 5, 48, 5, 6, 48, 6, 7, 59, 6, 59, 48, 7, 8, 58, 7, 58, 59,\n 8, 9, 56, 8, 56, 57, 8, 57, 58, 9, 10, 55, 9, 55, 56, 10, 11, 54, 10, 54, 55, 11, 12, 54, 12, 13, 54, 13, 14, 35, 13, 35, 54, 14, 15, 46, 14, 46, 35, 15, 16,\n 45, 15, 45, 46, 16, 26, 45, 17, 36, 18, 18, 37, 19, 18, 36, 37, 19, 38, 20, 19, 37, 38, 20, 39, 21, 20, 38, 39, 21, 39, 27, 22, 42, 23, 22, 27, 42, 23, 43, 24,\n 23, 42, 43, 24, 44, 25, 24, 43, 44, 25, 45, 26, 25, 44, 45, 27, 39, 28, 27, 28, 42, 28, 39, 29, 28, 29, 42, 29, 31, 30, 29, 30, 35, 29, 40, 31, 29, 35, 47, 29,\n 39, 40, 29, 47, 42, 30, 31, 32, 30, 32, 33, 30, 33, 34, 30, 34, 35, 31, 50, 32, 31, 40, 41, 31, 48, 49, 31, 49, 50, 32, 51, 33, 32, 50, 51, 33, 51, 34, 34, 52,\n 35, 34, 51, 52, 35, 46, 47, 35, 52, 53, 35, 53, 54, 36, 41, 37, 37, 40, 38, 37, 41, 40, 38, 40, 39, 42, 47, 43, 43, 47, 44, 44, 46, 45, 44, 47, 46, 48, 60, 49,\n 48, 59, 60, 49, 61, 50, 49, 60, 61, 50, 62, 51, 50, 61, 62, 51, 62, 52, 52, 63, 53, 52, 62, 63, 53, 64, 54, 53, 63, 64, 54, 64, 55, 55, 65, 56, 55, 64, 65, 56,\n 66, 57, 56, 65, 66, 57, 66, 58, 58, 67, 59, 58, 66, 67, 59, 67, 60, 60, 67, 61, 61, 66, 62, 61, 67, 66, 62, 66, 63, 63, 65, 64, 63, 66, 65, 21, 27, 22];\n\nexport const TRI33: number[] = [\n /* eyes */ 0, 8, 7, 7, 8, 1, 2, 10, 9, 9, 10, 3,\n /* brows */ 17, 0, 18, 18, 0, 7, 18, 7, 19, 19, 7, 1, 19, 1, 11, 19, 11, 20, 21, 3, 22, 21, 9, 3, 20, 9, 21, 20, 2, 9, 20, 11, 2,\n /* 4head */ 23, 17, 18, 25, 21, 22, 24, 19, 20, 24, 18, 19, 24, 20, 21, 24, 23, 18, 24, 21, 25,\n /* nose */ 11, 12, 4, 11, 4, 13, 1, 12, 11, 11, 13, 2, 12, 14, 4, 4, 14, 13,\n /* up-lip */ 14, 5, 15, 14, 15, 6, 12, 5, 14, 14, 6, 13,\n /* cheeks */ 8, 12, 1, 2, 13, 10, 8, 26, 12, 10, 13, 27, 26, 5, 12, 13, 6, 27, 0, 26, 8, 10, 27, 3,\n /* chin */ 5, 32, 16, 16, 32, 6, 5, 30, 32, 6, 32, 31,\n /* cont */ 26, 30, 5, 27, 6, 31, 0, 28, 26, 3, 27, 29, 17, 28, 0, 3, 29, 22, 23, 28, 17, 22, 29, 25, 28, 30, 26, 27, 31, 29,\n];\n\nexport const TRI7: number[] = [0, 4, 1, 2, 4, 3, 4, 5, 6];\n\nexport const VTX68: number[] = [\n /* cont */ 127, 234, 132, 58, 172, 150, 149, 148, 152, 377, 378, 379, 397, 288, 361, 454, 356,\n /* brows */ 70, 63, 105, 66, 107, 336, 296, 334, 293, 300,\n /* nose */ 168, 6, 195, 4, 98, 97, 2, 326, 327,\n /* eyes */ 33, 160, 158, 133, 153, 144, 362, 385, 387, 263, 373, 380,\n /* lip */ 57, 40, 37, 0, 267, 270, 287, 321, 314, 17, 84, 91,\n /* mouth */ 78, 81, 13, 311, 308, 402, 14, 178,\n];\n\nexport const VTX33: number[] = [33, 133, 362, 263, 1, 62, 308, 159, 145, 386, 374, 6, 102, 331, 2, 13, 14, 70, 105, 107, 336, 334, 300, 54, 10, 284, 50, 280, 234, 454, 58, 288, 152];\n\nexport const VTX7: number[] = [33, 133, 362, 263, 1, 78, 308];\n\nexport const UV68 = VTX68.map((x) => UV468[x]);\n\nexport const UV33 = VTX33.map((x) => UV468[x]);\n\nexport const UV7 = VTX7.map((x) => UV468[x]);\n\n// https://github.com/tensorflow/tfjs-models/blob/master/face-landmarks-detection/src/constants.ts\n// https://github.com/google/mediapipe/mediapipe/python/solutions/face_mesh_connections.py\n\ntype PairArray = [number, number][];\n\nfunction connectionsToIndices(connections: PairArray) {\n const indices = connections.map((connection) => connection[0]);\n indices.push(connections[connections.length - 1][1]);\n return indices;\n}\n\nexport const pairsLips: PairArray = [\n [61, 146], [146, 91], [91, 181], [181, 84], [84, 17], [17, 314], [314, 405], [405, 321], [321, 375], [375, 291], [61, 185], [185, 40], [40, 39], [39, 37], [37, 0], [0, 267], [267, 269], [269, 270], [270, 409], [409, 291],\n [78, 95], [95, 88], [88, 178], [178, 87], [87, 14], [14, 317], [317, 402], [402, 318], [318, 324], [324, 308], [78, 191], [191, 80], [80, 81], [81, 82], [82, 13], [13, 312], [312, 311], [311, 310], [310, 415], [415, 308],\n];\n\nexport const pairsLeftEye: PairArray = [[263, 249], [249, 390], [390, 373], [373, 374], [374, 380], [380, 381], [381, 382], [382, 362], [263, 466], [466, 388], [388, 387], [387, 386], [386, 385], [385, 384], [384, 398], [398, 362]];\n\nexport const pairsLeftEyebrow: PairArray = [[276, 283], [283, 282], [282, 295], [295, 285], [300, 293], [293, 334], [334, 296], [296, 336]];\n\nexport const pairsLeftIris: PairArray = [[474, 475], [475, 476], [476, 477], [477, 474]];\n\nexport const pairsRightEye: PairArray = [[33, 7], [7, 163], [163, 144], [144, 145], [145, 153], [153, 154], [154, 155], [155, 133], [33, 246], [246, 161], [161, 160], [160, 159], [159, 158], [158, 157], [157, 173], [173, 133]];\n\nexport const pairsRightEyebrow: PairArray = [[46, 53], [53, 52], [52, 65], [65, 55], [70, 63], [63, 105], [105, 66], [66, 107]];\n\nexport const pairsRightIris: PairArray = [[469, 470], [470, 471], [471, 472], [472, 469]];\n\nexport const pairsFaceContour: PairArray = [\n [10, 338], [338, 297], [297, 332], [332, 284], [284, 251], [251, 389],\n [389, 356], [356, 454], [454, 323], [323, 361], [361, 288], [288, 397],\n [397, 365], [365, 379], [379, 378], [378, 400], [400, 377], [377, 152],\n [152, 148], [148, 176], [176, 149], [149, 150], [150, 136], [136, 172],\n [172, 58], [58, 132], [132, 93], [93, 234], [234, 127], [127, 162],\n [162, 21], [21, 54], [54, 103], [103, 67], [67, 109], [109, 10],\n];\n\nexport const contourKeypoints = {\n lips: connectionsToIndices(pairsLips),\n leftEye: connectionsToIndices(pairsLeftEye),\n leftEyebrow: connectionsToIndices(pairsLeftEyebrow),\n leftIris: connectionsToIndices(pairsLeftIris),\n rightEye: connectionsToIndices(pairsRightEye),\n rightEyebrow: connectionsToIndices(pairsRightEyebrow),\n rightIris: connectionsToIndices(pairsRightIris),\n faceOval: connectionsToIndices(pairsFaceContour),\n};\n\nexport const pairsFaceMesh: PairArray = [\n [127, 34], [34, 139], [139, 127], [11, 0], [0, 37], [37, 11],\n [232, 231], [231, 120], [120, 232], [72, 37], [37, 39], [39, 72],\n [128, 121], [121, 47], [47, 128], [232, 121], [121, 128], [128, 232],\n [104, 69], [69, 67], [67, 104], [175, 171], [171, 148], [148, 175],\n [118, 50], [50, 101], [101, 118], [73, 39], [39, 40], [40, 73],\n [9, 151], [151, 108], [108, 9], [48, 115], [115, 131], [131, 48],\n [194, 204], [204, 211], [211, 194], [74, 40], [40, 185], [185, 74],\n [80, 42], [42, 183], [183, 80], [40, 92], [92, 186], [186, 40],\n [230, 229], [229, 118], [118, 230], [202, 212], [212, 214], [214, 202],\n [83, 18], [18, 17], [17, 83], [76, 61], [61, 146], [146, 76],\n [160, 29], [29, 30], [30, 160], [56, 157], [157, 173], [173, 56],\n [106, 204], [204, 194], [194, 106], [135, 214], [214, 192], [192, 135],\n [203, 165], [165, 98], [98, 203], [21, 71], [71, 68], [68, 21],\n [51, 45], [45, 4], [4, 51], [144, 24], [24, 23], [23, 144],\n [77, 146], [146, 91], [91, 77], [205, 50], [50, 187], [187, 205],\n [201, 200], [200, 18], [18, 201], [91, 106], [106, 182], [182, 91],\n [90, 91], [91, 181], [181, 90], [85, 84], [84, 17], [17, 85],\n [206, 203], [203, 36], [36, 206], [148, 171], [171, 140], [140, 148],\n [92, 40], [40, 39], [39, 92], [193, 189], [189, 244], [244, 193],\n [159, 158], [158, 28], [28, 159], [247, 246], [246, 161], [161, 247],\n [236, 3], [3, 196], [196, 236], [54, 68], [68, 104], [104, 54],\n [193, 168], [168, 8], [8, 193], [117, 228], [228, 31], [31, 117],\n [189, 193], [193, 55], [55, 189], [98, 97], [97, 99], [99, 98],\n [126, 47], [47, 100], [100, 126], [166, 79], [79, 218], [218, 166],\n [155, 154], [154, 26], [26, 155], [209, 49], [49, 131], [131, 209],\n [135, 136], [136, 150], [150, 135], [47, 126], [126, 217], [217, 47],\n [223, 52], [52, 53], [53, 223], [45, 51], [51, 134], [134, 45],\n [211, 170], [170, 140], [140, 211], [67, 69], [69, 108], [108, 67],\n [43, 106], [106, 91], [91, 43], [230, 119], [119, 120], [120, 230],\n [226, 130], [130, 247], [247, 226], [63, 53], [53, 52], [52, 63],\n [238, 20], [20, 242], [242, 238], [46, 70], [70, 156], [156, 46],\n [78, 62], [62, 96], [96, 78], [46, 53], [53, 63], [63, 46],\n [143, 34], [34, 227], [227, 143], [123, 117], [117, 111], [111, 123],\n [44, 125], [125, 19], [19, 44], [236, 134], [134, 51], [51, 236],\n [216, 206], [206, 205], [205, 216], [154, 153], [153, 22], [22, 154],\n [39, 37], [37, 167], [167, 39], [200, 201], [201, 208], [208, 200],\n [36, 142], [142, 100], [100, 36], [57, 212], [212, 202], [202, 57],\n [20, 60], [60, 99], [99, 20], [28, 158], [158, 157], [157, 28],\n [35, 226], [226, 113], [113, 35], [160, 159], [159, 27], [27, 160],\n [204, 202], [202, 210], [210, 204], [113, 225], [225, 46], [46, 113],\n [43, 202], [202, 204], [204, 43], [62, 76], [76, 77], [77, 62],\n [137, 123], [123, 116], [116, 137], [41, 38], [38, 72], [72, 41],\n [203, 129], [129, 142], [142, 203], [64, 98], [98, 240], [240, 64],\n [49, 102], [102, 64], [64, 49], [41, 73], [73, 74], [74, 41],\n [212, 216], [216, 207], [207, 212], [42, 74], [74, 184], [184, 42],\n [169, 170], [170, 211], [211, 169], [170, 149], [149, 176], [176, 170],\n [105, 66], [66, 69], [69, 105], [122, 6], [6, 168], [168, 122],\n [123, 147], [147, 187], [187, 123], [96, 77], [77, 90], [90, 96],\n [65, 55], [55, 107], [107, 65], [89, 90], [90, 180], [180, 89],\n [101, 100], [100, 120], [120, 101], [63, 105], [105, 104], [104, 63],\n [93, 137], [137, 227], [227, 93], [15, 86], [86, 85], [85, 15],\n [129, 102], [102, 49], [49, 129], [14, 87], [87, 86], [86, 14],\n [55, 8], [8, 9], [9, 55], [100, 47], [47, 121], [121, 100],\n [145, 23], [23, 22], [22, 145], [88, 89], [89, 179], [179, 88],\n [6, 122], [122, 196], [196, 6], [88, 95], [95, 96], [96, 88],\n [138, 172], [172, 136], [136, 138], [215, 58], [58, 172], [172, 215],\n [115, 48], [48, 219], [219, 115], [42, 80], [80, 81], [81, 42],\n [195, 3], [3, 51], [51, 195], [43, 146], [146, 61], [61, 43],\n [171, 175], [175, 199], [199, 171], [81, 82], [82, 38], [38, 81],\n [53, 46], [46, 225], [225, 53], [144, 163], [163, 110], [110, 144],\n [52, 65], [65, 66], [66, 52], [229, 228], [228, 117], [117, 229],\n [34, 127], [127, 234], [234, 34], [107, 108], [108, 69], [69, 107],\n [109, 108], [108, 151], [151, 109], [48, 64], [64, 235], [235, 48],\n [62, 78], [78, 191], [191, 62], [129, 209], [209, 126], [126, 129],\n [111, 35], [35, 143], [143, 111], [117, 123], [123, 50], [50, 117],\n [222, 65], [65, 52], [52, 222], [19, 125], [125, 141], [141, 19],\n [221, 55], [55, 65], [65, 221], [3, 195], [195, 197], [197, 3],\n [25, 7], [7, 33], [33, 25], [220, 237], [237, 44], [44, 220],\n [70, 71], [71, 139], [139, 70], [122, 193], [193, 245], [245, 122],\n [247, 130], [130, 33], [33, 247], [71, 21], [21, 162], [162, 71],\n [170, 169], [169, 150], [150, 170], [188, 174], [174, 196], [196, 188],\n [216, 186], [186, 92], [92, 216], [2, 97], [97, 167], [167, 2],\n [141, 125], [125, 241], [241, 141], [164, 167], [167, 37], [37, 164],\n [72, 38], [38, 12], [12, 72], [38, 82], [82, 13], [13, 38],\n [63, 68], [68, 71], [71, 63], [226, 35], [35, 111], [111, 226],\n [101, 50], [50, 205], [205, 101], [206, 92], [92, 165], [165, 206],\n [209, 198], [198, 217], [217, 209], [165, 167], [167, 97], [97, 165],\n [220, 115], [115, 218], [218, 220], [133, 112], [112, 243], [243, 133],\n [239, 238], [238, 241], [241, 239], [214, 135], [135, 169], [169, 214],\n [190, 173], [173, 133], [133, 190], [171, 208], [208, 32], [32, 171],\n [125, 44], [44, 237], [237, 125], [86, 87], [87, 178], [178, 86],\n [85, 86], [86, 179], [179, 85], [84, 85], [85, 180], [180, 84],\n [83, 84], [84, 181], [181, 83], [201, 83], [83, 182], [182, 201],\n [137, 93], [93, 132], [132, 137], [76, 62], [62, 183], [183, 76],\n [61, 76], [76, 184], [184, 61], [57, 61], [61, 185], [185, 57],\n [212, 57], [57, 186], [186, 212], [214, 207], [207, 187], [187, 214],\n [34, 143], [143, 156], [156, 34], [79, 239], [239, 237], [237, 79],\n [123, 137], [137, 177], [177, 123], [44, 1], [1, 4], [4, 44],\n [201, 194], [194, 32], [32, 201], [64, 102], [102, 129], [129, 64],\n [213, 215], [215, 138], [138, 213], [59, 166], [166, 219], [219, 59],\n [242, 99], [99, 97], [97, 242], [2, 94], [94, 141], [141, 2],\n [75, 59], [59, 235], [235, 75], [24, 110], [110, 228], [228, 24],\n [25, 130], [130, 226], [226, 25], [23, 24], [24, 229], [229, 23],\n [22, 23], [23, 230], [230, 22], [26, 22], [22, 231], [231, 26],\n [112, 26], [26, 232], [232, 112], [189, 190], [190, 243], [243, 189],\n [221, 56], [56, 190], [190, 221], [28, 56], [56, 221], [221, 28],\n [27, 28], [28, 222], [222, 27], [29, 27], [27, 223], [223, 29],\n [30, 29], [29, 224], [224, 30], [247, 30], [30, 225], [225, 247],\n [238, 79], [79, 20], [20, 238], [166, 59], [59, 75], [75, 166],\n [60, 75], [75, 240], [240, 60], [147, 177], [177, 215], [215, 147],\n [20, 79], [79, 166], [166, 20], [187, 147], [147, 213], [213, 187],\n [112, 233], [233, 244], [244, 112], [233, 128], [128, 245], [245, 233],\n [128, 114], [114, 188], [188, 128], [114, 217], [217, 174], [174, 114],\n [131, 115], [115, 220], [220, 131], [217, 198], [198, 236], [236, 217],\n [198, 131], [131, 134], [134, 198], [177, 132], [132, 58], [58, 177],\n [143, 35], [35, 124], [124, 143], [110, 163], [163, 7], [7, 110],\n [228, 110], [110, 25], [25, 228], [356, 389], [389, 368], [368, 356],\n [11, 302], [302, 267], [267, 11], [452, 350], [350, 349], [349, 452],\n [302, 303], [303, 269], [269, 302], [357, 343], [343, 277], [277, 357],\n [452, 453], [453, 357], [357, 452], [333, 332], [332, 297], [297, 333],\n [175, 152], [152, 377], [377, 175], [347, 348], [348, 330], [330, 347],\n [303, 304], [304, 270], [270, 303], [9, 336], [336, 337], [337, 9],\n [278, 279], [279, 360], [360, 278], [418, 262], [262, 431], [431, 418],\n [304, 408], [408, 409], [409, 304], [310, 415], [415, 407], [407, 310],\n [270, 409], [409, 410], [410, 270], [450, 348], [348, 347], [347, 450],\n [422, 430], [430, 434], [434, 422], [313, 314], [314, 17], [17, 313],\n [306, 307], [307, 375], [375, 306], [387, 388], [388, 260], [260, 387],\n [286, 414], [414, 398], [398, 286], [335, 406], [406, 418], [418, 335],\n [364, 367], [367, 416], [416, 364], [423, 358], [358, 327], [327, 423],\n [251, 284], [284, 298], [298, 251], [281, 5], [5, 4], [4, 281],\n [373, 374], [374, 253], [253, 373], [307, 320], [320, 321], [321, 307],\n [425, 427], [427, 411], [411, 425], [421, 313], [313, 18], [18, 421],\n [321, 405], [405, 406], [406, 321], [320, 404], [404, 405], [405, 320],\n [315, 16], [16, 17], [17, 315], [426, 425], [425, 266], [266, 426],\n [377, 400], [400, 369], [369, 377], [322, 391], [391, 269], [269, 322],\n [417, 465], [465, 464], [464, 417], [386, 257], [257, 258], [258, 386],\n [466, 260], [260, 388], [388, 466], [456, 399], [399, 419], [419, 456],\n [284, 332], [332, 333], [333, 284], [417, 285], [285, 8], [8, 417],\n [346, 340], [340, 261], [261, 346], [413, 441], [441, 285], [285, 413],\n [327, 460], [460, 328], [328, 327], [355, 371], [371, 329], [329, 355],\n [392, 439], [439, 438], [438, 392], [382, 341], [341, 256], [256, 382],\n [429, 420], [420, 360], [360, 429], [364, 394], [394, 379], [379, 364],\n [277, 343], [343, 437], [437, 277], [443, 444], [444, 283], [283, 443],\n [275, 440], [440, 363], [363, 275], [431, 262], [262, 369], [369, 431],\n [297, 338], [338, 337], [337, 297], [273, 375], [375, 321], [321, 273],\n [450, 451], [451, 349], [349, 450], [446, 342], [342, 467], [467, 446],\n [293, 334], [334, 282], [282, 293], [458, 461], [461, 462], [462, 458],\n [276, 353], [353, 383], [383, 276], [308, 324], [324, 325], [325, 308],\n [276, 300], [300, 293], [293, 276], [372, 345], [345, 447], [447, 372],\n [352, 345], [345, 340], [340, 352], [274, 1], [1, 19], [19, 274],\n [456, 248], [248, 281], [281, 456], [436, 427], [427, 425], [425, 436],\n [381, 256], [256, 252], [252, 381], [269, 391], [391, 393], [393, 269],\n [200, 199], [199, 428], [428, 200], [266, 330], [330, 329], [329, 266],\n [287, 273], [273, 422], [422, 287], [250, 462], [462, 328], [328, 250],\n [258, 286], [286, 384], [384, 258], [265, 353], [353, 342], [342, 265],\n [387, 259], [259, 257], [257, 387], [424, 431], [431, 430], [430, 424],\n [342, 353], [353, 276], [276, 342], [273, 335], [335, 424], [424, 273],\n [292, 325], [325, 307], [307, 292], [366, 447], [447, 345], [345, 366],\n [271, 303], [303, 302], [302, 271], [423, 266], [266, 371], [371, 423],\n [294, 455], [455, 460], [460, 294], [279, 278], [278, 294], [294, 279],\n [271, 272], [272, 304], [304, 271], [432, 434], [434, 427], [427, 432],\n [272, 407], [407, 408], [408, 272], [394, 430], [430, 431], [431, 394],\n [395, 369], [369, 400], [400, 395], [334, 333], [333, 299], [299, 334],\n [351, 417], [417, 168], [168, 351], [352, 280], [280, 411], [411, 352],\n [325, 319], [319, 320], [320, 325], [295, 296], [296, 336], [336, 295],\n [319, 403], [403, 404], [404, 319], [330, 348], [348, 349], [349, 330],\n [293, 298], [298, 333], [333, 293], [323, 454], [454, 447], [447, 323],\n [15, 16], [16, 315], [315, 15], [358, 429], [429, 279], [279, 358],\n [14, 15], [15, 316], [316, 14], [285, 336], [336, 9], [9, 285],\n [329, 349], [349, 350], [350, 329], [374, 380], [380, 252], [252, 374],\n [318, 402], [402, 403], [403, 318], [6, 197], [197, 419], [419, 6],\n [318, 319], [319, 325], [325, 318], [367, 364], [364, 365], [365, 367],\n [435, 367], [367, 397], [397, 435], [344, 438], [438, 439], [439, 344],\n [272, 271], [271, 311], [311, 272], [195, 5], [5, 281], [281, 195],\n [273, 287], [287, 291], [291, 273], [396, 428], [428, 199], [199, 396],\n [311, 271], [271, 268], [268, 311], [283, 444], [444, 445], [445, 283],\n [373, 254], [254, 339], [339, 373], [282, 334], [334, 296], [296, 282],\n [449, 347], [347, 346], [346, 449], [264, 447], [447, 454], [454, 264],\n [336, 296], [296, 299], [299, 336], [338, 10], [10, 151], [151, 338],\n [278, 439], [439, 455], [455, 278], [292, 407], [407, 415], [415, 292],\n [358, 371], [371, 355], [355, 358], [340, 345], [345, 372], [372, 340],\n [346, 347], [347, 280], [280, 346], [442, 443], [443, 282], [282, 442],\n [19, 94], [94, 370], [370, 19], [441, 442], [442, 295], [295, 441],\n [248, 419], [419, 197], [197, 248], [263, 255], [255, 359], [359, 263],\n [440, 275], [275, 274], [274, 440], [300, 383], [383, 368], [368, 300],\n [351, 412], [412, 465], [465, 351], [263, 467], [467, 466], [466, 263],\n [301, 368], [368, 389], [389, 301], [395, 378], [378, 379], [379, 395],\n [412, 351], [351, 419], [419, 412], [436, 426], [426, 322], [322, 436],\n [2, 164], [164, 393], [393, 2], [370, 462], [462, 461], [461, 370],\n [164, 0], [0, 267], [267, 164], [302, 11], [11, 12], [12, 302],\n [268, 12], [12, 13], [13, 268], [293, 300], [300, 301], [301, 293],\n [446, 261], [261, 340], [340, 446], [330, 266], [266, 425], [425, 330],\n [426, 423], [423, 391], [391, 426], [429, 355], [355, 437], [437, 429],\n [391, 327], [327, 326], [326, 391], [440, 457], [457, 438], [438, 440],\n [341, 382], [382, 362], [362, 341], [459, 457], [457, 461], [461, 459],\n [434, 430], [430, 394], [394, 434], [414, 463], [463, 362], [362, 414],\n [396, 369], [369, 262], [262, 396], [354, 461], [461, 457], [457, 354],\n [316, 403], [403, 402], [402, 316], [315, 404], [404, 403], [403, 315],\n [314, 405], [405, 404], [404, 314], [313, 406], [406, 405], [405, 313],\n [421, 418], [418, 406], [406, 421], [366, 401], [401, 361], [361, 366],\n [306, 408], [408, 407], [407, 306], [291, 409], [409, 408], [408, 291],\n [287, 410], [410, 409], [409, 287], [432, 436], [436, 410], [410, 432],\n [434, 416], [416, 411], [411, 434], [264, 368], [368, 383], [383, 264],\n [309, 438], [438, 457], [457, 309], [352, 376], [376, 401], [401, 352],\n [274, 275], [275, 4], [4, 274], [421, 428], [428, 262], [262, 421],\n [294, 327], [327, 358], [358, 294], [433, 416], [416, 367], [367, 433],\n [289, 455], [455, 439], [439, 289], [462, 370], [370, 326], [326, 462],\n [2, 326], [326, 370], [370, 2], [305, 460], [460, 455], [455, 305],\n [254, 449], [449, 448], [448, 254], [255, 261], [261, 446], [446, 255],\n [253, 450], [450, 449], [449, 253], [252, 451], [451, 450], [450, 252],\n [256, 452], [452, 451], [451, 256], [341, 453], [453, 452], [452, 341],\n [413, 464], [464, 463], [463, 413], [441, 413], [413, 414], [414, 441],\n [258, 442], [442, 441], [441, 258], [257, 443], [443, 442], [442, 257],\n [259, 444], [444, 443], [443, 259], [260, 445], [445, 444], [444, 260],\n [467, 342], [342, 445], [445, 467], [459, 458], [458, 250], [250, 459],\n [289, 392], [392, 290], [290, 289], [290, 328], [328, 460], [460, 290],\n [376, 433], [433, 435], [435, 376], [250, 290], [290, 392], [392, 250],\n [411, 416], [416, 433], [433, 411], [341, 463], [463, 464], [464, 341],\n [453, 464], [464, 465], [465, 453], [357, 465], [465, 412], [412, 357],\n [343, 412], [412, 399], [399, 343], [360, 363], [363, 440], [440, 360],\n [437, 399], [399, 456], [456, 437], [420, 456], [456, 363], [363, 420],\n [401, 435], [435, 288], [288, 401], [372, 383], [383, 353], [353, 372],\n [339, 255], [255, 249], [249, 339], [448, 261], [261, 255], [255, 448],\n [133, 243], [243, 190], [190, 133], [133, 155], [155, 112], [112, 133],\n [33, 246], [246, 247], [247, 33], [33, 130], [130, 25], [25, 33],\n [398, 384], [384, 286], [286, 398], [362, 398], [398, 414], [414, 362],\n [362, 463], [463, 341], [341, 362], [263, 359], [359, 467], [467, 263],\n [263, 249], [249, 255], [255, 263], [466, 467], [467, 260], [260, 466],\n [75, 60], [60, 166], [166, 75], [238, 239], [239, 79], [79, 238],\n [162, 127], [127, 139], [139, 162], [72, 11], [11, 37], [37, 72],\n [121, 232], [232, 120], [120, 121], [73, 72], [72, 39], [39, 73],\n [114, 128], [128, 47], [47, 114], [233, 232], [232, 128], [128, 233],\n [103, 104], [104, 67], [67, 103], [152, 175], [175, 148], [148, 152],\n [119, 118], [118, 101], [101, 119], [74, 73], [73, 40], [40, 74],\n [107, 9], [9, 108], [108, 107], [49, 48], [48, 131], [131, 49],\n [32, 194], [194, 211], [211, 32], [184, 74], [74, 185], [185, 184],\n [191, 80], [80, 183], [183, 191], [185, 40], [40, 186], [186, 185],\n [119, 230], [230, 118], [118, 119], [210, 202], [202, 214], [214, 210],\n [84, 83], [83, 17], [17, 84], [77, 76], [76, 146], [146, 77],\n [161, 160], [160, 30], [30, 161], [190, 56], [56, 173], [173, 190],\n [182, 106], [106, 194], [194, 182], [138, 135], [135, 192], [192, 138],\n [129, 203], [203, 98], [98, 129], [54, 21], [21, 68], [68, 54],\n [5, 51], [51, 4], [4, 5], [145, 144], [144, 23], [23, 145],\n [90, 77], [77, 91], [91, 90], [207, 205], [205, 187], [187, 207],\n [83, 201], [201, 18], [18, 83], [181, 91], [91, 182], [182, 181],\n [180, 90], [90, 181], [181, 180], [16, 85], [85, 17], [17, 16],\n [205, 206], [206, 36], [36, 205], [176, 148], [148, 140], [140, 176],\n [165, 92], [92, 39], [39, 165], [245, 193], [193, 244], [244, 245],\n [27, 159], [159, 28], [28, 27], [30, 247], [247, 161], [161, 30],\n [174, 236], [236, 196], [196, 174], [103, 54], [54, 104], [104, 103],\n [55, 193], [193, 8], [8, 55], [111, 117], [117, 31], [31, 111],\n [221, 189], [189, 55], [55, 221], [240, 98], [98, 99], [99, 240],\n [142, 126], [126, 100], [100, 142], [219, 166], [166, 218], [218, 219],\n [112, 155], [155, 26], [26, 112], [198, 209], [209, 131], [131, 198],\n [169, 135], [135, 150], [150, 169], [114, 47], [47, 217], [217, 114],\n [224, 223], [223, 53], [53, 224], [220, 45], [45, 134], [134, 220],\n [32, 211], [211, 140], [140, 32], [109, 67], [67, 108], [108, 109],\n [146, 43], [43, 91], [91, 146], [231, 230], [230, 120], [120, 231],\n [113, 226], [226, 247], [247, 113], [105, 63], [63, 52], [52, 105],\n [241, 238], [238, 242], [242, 241], [124, 46], [46, 156], [156, 124],\n [95, 78], [78, 96], [96, 95], [70, 46], [46, 63], [63, 70],\n [116, 143], [143, 227], [227, 116], [116, 123], [123, 111], [111, 116],\n [1, 44], [44, 19], [19, 1], [3, 236], [236, 51], [51, 3],\n [207, 216], [216, 205], [205, 207], [26, 154], [154, 22], [22, 26],\n [165, 39], [39, 167], [167, 165], [199, 200], [200, 208], [208, 199],\n [101, 36], [36, 100], [100, 101], [43, 57], [57, 202], [202, 43],\n [242, 20], [20, 99], [99, 242], [56, 28], [28, 157], [157, 56],\n [124, 35], [35, 113], [113, 124], [29, 160], [160, 27], [27, 29],\n [211, 204], [204, 210], [210, 211], [124, 113], [113, 46], [46, 124],\n [106, 43], [43, 204], [204, 106], [96, 62], [62, 77], [77, 96],\n [227, 137], [137, 116], [116, 227], [73, 41], [41, 72], [72, 73],\n [36, 203], [203, 142], [142, 36], [235, 64], [64, 240], [240, 235],\n [48, 49], [49, 64], [64, 48], [42, 41], [41, 74], [74, 42],\n [214, 212], [212, 207], [207, 214], [183, 42], [42, 184], [184, 183],\n [210, 169], [169, 211], [211, 210], [140, 170], [170, 176], [176, 140],\n [104, 105], [105, 69], [69, 104], [193, 122], [122, 168], [168, 193],\n [50, 123], [123, 187], [187, 50], [89, 96], [96, 90], [90, 89],\n [66, 65], [65, 107], [107, 66], [179, 89], [89, 180], [180, 179],\n [119, 101], [101, 120], [120, 119], [68, 63], [63, 104], [104, 68],\n [234, 93], [93, 227], [227, 234], [16, 15], [15, 85], [85, 16],\n [209, 129], [129, 49], [49, 209], [15, 14], [14, 86], [86, 15],\n [107, 55], [55, 9], [9, 107], [120, 100], [100, 121], [121, 120],\n [153, 145], [145, 22], [22, 153], [178, 88], [88, 179], [179, 178],\n [197, 6], [6, 196], [196, 197], [89, 88], [88, 96], [96, 89],\n [135, 138], [138, 136], [136, 135], [138, 215], [215, 172], [172, 138],\n [218, 115], [115, 219], [219, 218], [41, 42], [42, 81], [81, 41],\n [5, 195], [195, 51], [51, 5], [57, 43], [43, 61], [61, 57],\n [208, 171], [171, 199], [199, 208], [41, 81], [81, 38], [38, 41],\n [224, 53], [53, 225], [225, 224], [24, 144], [144, 110], [110, 24],\n [105, 52], [52, 66], [66, 105], [118, 229], [229, 117], [117, 118],\n [227, 34], [34, 234], [234, 227], [66, 107], [107, 69], [69, 66],\n [10, 109], [109, 151], [151, 10], [219, 48], [48, 235], [235, 219],\n [183, 62], [62, 191], [191, 183], [142, 129], [129, 126], [126, 142],\n [116, 111], [111, 143], [143, 116], [118, 117], [117, 50], [50, 118],\n [223, 222], [222, 52], [52, 223], [94, 19], [19, 141], [141, 94],\n [222, 221], [221, 65], [65, 222], [196, 3], [3, 197], [197, 196],\n [45, 220], [220, 44], [44, 45], [156, 70], [70, 139], [139, 156],\n [188, 122], [122, 245], [245, 188], [139, 71], [71, 162], [162, 139],\n [149, 170], [170, 150], [150, 149], [122, 188], [188, 196], [196, 122],\n [206, 216], [216, 92], [92, 206], [164, 2], [2, 167], [167, 164],\n [242, 141], [141, 241], [241, 242], [0, 164], [164, 37], [37, 0],\n [11, 72], [72, 12], [12, 11], [12, 38], [38, 13], [13, 12],\n [70, 63], [63, 71], [71, 70], [31, 226], [226, 111], [111, 31],\n [36, 101], [101, 205], [205, 36], [203, 206], [206, 165], [165, 203],\n [126, 209], [209, 217], [217, 126], [98, 165], [165, 97], [97, 98],\n [237, 220], [220, 218], [218, 237], [237, 239], [239, 241], [241, 237],\n [210, 214], [214, 169], [169, 210], [140, 171], [171, 32], [32, 140],\n [241, 125], [125, 237], [237, 241], [179, 86], [86, 178], [178, 179],\n [180, 85], [85, 179], [179, 180], [181, 84], [84, 180], [180, 181],\n [182, 83], [83, 181], [181, 182], [194, 201], [201, 182], [182, 194],\n [177, 137], [137, 132], [132, 177], [184, 76], [76, 183], [183, 184],\n [185, 61], [61, 184], [184, 185], [186, 57], [57, 185], [185, 186],\n [216, 212], [212, 186], [186, 216], [192, 214], [214, 187], [187, 192],\n [139, 34], [34, 156], [156, 139], [218, 79], [79, 237], [237, 218],\n [147, 123], [123, 177], [177, 147], [45, 44], [44, 4], [4, 45],\n [208, 201], [201, 32], [32, 208], [98, 64], [64, 129], [129, 98],\n [192, 213], [213, 138], [138, 192], [235, 59], [59, 219], [219, 235],\n [141, 242], [242, 97], [97, 141], [97, 2], [2, 141], [141, 97],\n [240, 75], [75, 235], [235, 240], [229, 24], [24, 228], [228, 229],\n [31, 25], [25, 226], [226, 31], [230, 23], [23, 229], [229, 230],\n [231, 22], [22, 230], [230, 231], [232, 26], [26, 231], [231, 232],\n [233, 112], [112, 232], [232, 233], [244, 189], [189, 243], [243, 244],\n [189, 221], [221, 190], [190, 189], [222, 28], [28, 221], [221, 222],\n [223, 27], [27, 222], [222, 223], [224, 29], [29, 223], [223, 224],\n [225, 30], [30, 224], [224, 225], [113, 247], [247, 225], [225, 113],\n [99, 60], [60, 240], [240, 99], [213, 147], [147, 215], [215, 213],\n [60, 20], [20, 166], [166, 60], [192, 187], [187, 213], [213, 192],\n [243, 112], [112, 244], [244, 243], [244, 233], [233, 245], [245, 244],\n [245, 128], [128, 188], [188, 245], [188, 114], [114, 174], [174, 188],\n [134, 131], [131, 220], [220, 134], [174, 217], [217, 236], [236, 174],\n [236, 198], [198, 134], [134, 236], [215, 177], [177, 58], [58, 215],\n [156, 143], [143, 124], [124, 156], [25, 110], [110, 7], [7, 25],\n [31, 228], [228, 25], [25, 31], [264, 356], [356, 368], [368, 264],\n [0, 11], [11, 267], [267, 0], [451, 452], [452, 349], [349, 451],\n [267, 302], [302, 269], [269, 267], [350, 357], [357, 277], [277, 350],\n [350, 452], [452, 357], [357, 350], [299, 333], [333, 297], [297, 299],\n [396, 175], [175, 377], [377, 396], [280, 347], [347, 330], [330, 280],\n [269, 303], [303, 270], [270, 269], [151, 9], [9, 337], [337, 151],\n [344, 278], [278, 360], [360, 344], [424, 418], [418, 431], [431, 424],\n [270, 304], [304, 409], [409, 270], [272, 310], [310, 407], [407, 272],\n [322, 270], [270, 410], [410, 322], [449, 450], [450, 347], [347, 449],\n [432, 422], [422, 434], [434, 432], [18, 313], [313, 17], [17, 18],\n [291, 306], [306, 375], [375, 291], [259, 387], [387, 260], [260, 259],\n [424, 335], [335, 418], [418, 424], [434, 364], [364, 416], [416, 434],\n [391, 423], [423, 327], [327, 391], [301, 251], [251, 298], [298, 301],\n [275, 281], [281, 4], [4, 275], [254, 373], [373, 253], [253, 254],\n [375, 307], [307, 321], [321, 375], [280, 425], [425, 411], [411, 280],\n [200, 421], [421, 18], [18, 200], [335, 321], [321, 406], [406, 335],\n [321, 320], [320, 405], [405, 321], [314, 315], [315, 17], [17, 314],\n [423, 426], [426, 266], [266, 423], [396, 377], [377, 369], [369, 396],\n [270, 322], [322, 269], [269, 270], [413, 417], [417, 464], [464, 413],\n [385, 386], [386, 258], [258, 385], [248, 456], [456, 419], [419, 248],\n [298, 284], [284, 333], [333, 298], [168, 417], [417, 8], [8, 168],\n [448, 346], [346, 261], [261, 448], [417, 413], [413, 285], [285, 417],\n [326, 327], [327, 328], [328, 326], [277, 355], [355, 329], [329, 277],\n [309, 392], [392, 438], [438, 309], [381, 382], [382, 256], [256, 381],\n [279, 429], [429, 360], [360, 279], [365, 364], [364, 379], [379, 365],\n [355, 277], [277, 437], [437, 355], [282, 443], [443, 283], [283, 282],\n [281, 275], [275, 363], [363, 281], [395, 431], [431, 369], [369, 395],\n [299, 297], [297, 337], [337, 299], [335, 273], [273, 321], [321, 335],\n [348, 450], [450, 349], [349, 348], [359, 446], [446, 467], [467, 359],\n [283, 293], [293, 282], [282, 283], [250, 458], [458, 462], [462, 250],\n [300, 276], [276, 383], [383, 300], [292, 308], [308, 325], [325, 292],\n [283, 276], [276, 293], [293, 283], [264, 372], [372, 447], [447, 264],\n [346, 352], [352, 340], [340, 346], [354, 274], [274, 19], [19, 354],\n [363, 456], [456, 281], [281, 363], [426, 436], [436, 425], [425, 426],\n [380, 381], [381, 252], [252, 380], [267, 269], [269, 393], [393, 267],\n [421, 200], [200, 428], [428, 421], [371, 266], [266, 329], [329, 371],\n [432, 287], [287, 422], [422, 432], [290, 250], [250, 328], [328, 290],\n [385, 258], [258, 384], [384, 385], [446, 265], [265, 342], [342, 446],\n [386, 387], [387, 257], [257, 386], [422, 424], [424, 430], [430, 422],\n [445, 342], [342, 276], [276, 445], [422, 273], [273, 424], [424, 422],\n [306, 292], [292, 307], [307, 306], [352, 366], [366, 345], [345, 352],\n [268, 271], [271, 302], [302, 268], [358, 423], [423, 371], [371, 358],\n [327, 294], [294, 460], [460, 327], [331, 279], [279, 294], [294, 331],\n [303, 271], [271, 304], [304, 303], [436, 432], [432, 427], [427, 436],\n [304, 272], [272, 408], [408, 304], [395, 394], [394, 431], [431, 395],\n [378, 395], [395, 400], [400, 378], [296, 334], [334, 299], [299, 296],\n [6, 351], [351, 168], [168, 6], [376, 352], [352, 411], [411, 376],\n [307, 325], [325, 320], [320, 307], [285, 295], [295, 336], [336, 285],\n [320, 319], [319, 404], [404, 320], [329, 330], [330, 349], [349, 329],\n [334, 293], [293, 333], [333, 334], [366, 323], [323, 447], [447, 366],\n [316, 15], [15, 315], [315, 316], [331, 358], [358, 279], [279, 331],\n [317, 14], [14, 316], [316, 317], [8, 285], [285, 9], [9, 8],\n [277, 329], [329, 350], [350, 277], [253, 374], [374, 252], [252, 253],\n [319, 318], [318, 403], [403, 319], [351, 6], [6, 419], [419, 351],\n [324, 318], [318, 325], [325, 324], [397, 367], [367, 365], [365, 397],\n [288, 435], [435, 397], [397, 288], [278, 344], [344, 439], [439, 278],\n [310, 272], [272, 311], [311, 310], [248, 195], [195, 281], [281, 248],\n [375, 273], [273, 291], [291, 375], [175, 396], [396, 199], [199, 175],\n [312, 311], [311, 268], [268, 312], [276, 283], [283, 445], [445, 276],\n [390, 373], [373, 339], [339, 390], [295, 282], [282, 296], [296, 295],\n [448, 449], [449, 346], [346, 448], [356, 264], [264, 454], [454, 356],\n [337, 336], [336, 299], [299, 337], [337, 338], [338, 151], [151, 337],\n [294, 278], [278, 455], [455, 294], [308, 292], [292, 415], [415, 308],\n [429, 358], [358, 355], [355, 429], [265, 340], [340, 372], [372, 265],\n [352, 346], [346, 280], [280, 352], [295, 442], [442, 282], [282, 295],\n [354, 19], [19, 370], [370, 354], [285, 441], [441, 295], [295, 285],\n [195, 248], [248, 197], [197, 195], [457, 440], [440, 274], [274, 457],\n [301, 300], [300, 368], [368, 301], [417, 351], [351, 465], [465, 417],\n [251, 301], [301, 389], [389, 251], [394, 395], [395, 379], [379, 394],\n [399, 412], [412, 419], [419, 399], [410, 436], [436, 322], [322, 410],\n [326, 2], [2, 393], [393, 326], [354, 370], [370, 461], [461, 354],\n [393, 164], [164, 267], [267, 393], [268, 302], [302, 12], [12, 268],\n [312, 268], [268, 13], [13, 312], [298, 293], [293, 301], [301, 298],\n [265, 446], [446, 340], [340, 265], [280, 330], [330, 425], [425, 280],\n [322, 426], [426, 391], [391, 322], [420, 429], [429, 437], [437, 420],\n [393, 391], [391, 326], [326, 393], [344, 440], [440, 438], [438, 344],\n [458, 459], [459, 461], [461, 458], [364, 434], [434, 394], [394, 364],\n [428, 396], [396, 262], [262, 428], [274, 354], [354, 457], [457, 274],\n [317, 316], [316, 402], [402, 317], [316, 315], [315, 403], [403, 316],\n [315, 314], [314, 404], [404, 315], [314, 313], [313, 405], [405, 314],\n [313, 421], [421, 406], [406, 313], [323, 366], [366, 361], [361, 323],\n [292, 306], [306, 407], [407, 292], [306, 291], [291, 408], [408, 306],\n [291, 287], [287, 409], [409, 291], [287, 432], [432, 410], [410, 287],\n [427, 434], [434, 411], [411, 427], [372, 264], [264, 383], [383, 372],\n [459, 309], [309, 457], [457, 459], [366, 352], [352, 401], [401, 366],\n [1, 274], [274, 4], [4, 1], [418, 421], [421, 262], [262, 418],\n [331, 294], [294, 358], [358, 331], [435, 433], [433, 367], [367, 435],\n [392, 289], [289, 439], [439, 392], [328, 462], [462, 326], [326, 328],\n [94, 2], [2, 370], [370, 94], [289, 305], [305, 455], [455, 289],\n [339, 254], [254, 448], [448, 339], [359, 255], [255, 446], [446, 359],\n [254, 253], [253, 449], [449, 254], [253, 252], [252, 450], [450, 253],\n [252, 256], [256, 451], [451, 252], [256, 341], [341, 452], [452, 256],\n [414, 413], [413, 463], [463, 414], [286, 441], [441, 414], [414, 286],\n [286, 258], [258, 441], [441, 286], [258, 257], [257, 442], [442, 258],\n [257, 259], [259, 443], [443, 257], [259, 260], [260, 444], [444, 259],\n [260, 467], [467, 445], [445, 260], [309, 459], [459, 250], [250, 309],\n [305, 289], [289, 290], [290, 305], [305, 290], [290, 460], [460, 305],\n [401, 376], [376, 435], [435, 401], [309, 250], [250, 392], [392, 309],\n [376, 411], [411, 433], [433, 376], [453, 341], [341, 464], [464, 453],\n [357, 453], [453, 465], [465, 357], [343, 357], [357, 412], [412, 343],\n [437, 343], [343, 399], [399, 437], [344, 360], [360, 440], [440, 344],\n [420, 437], [437, 456], [456, 420], [360, 420], [420, 363], [363, 360],\n [361, 401], [401, 288], [288, 361], [265, 372], [372, 353], [353, 265],\n [390, 339], [339, 249], [249, 390], [339, 448], [448, 255], [255, 339],\n];\n", "// @tensorflow/tfjs-models/face-landmark-detection/src/constants.ts\n// https://github.com/google/mediapipe/mediapipe/python/solutions/face_mesh_connections.py\n\ntype PairArray = [number, number][];\n\nconst LIPS_CONNECTIONS: PairArray = [\n [61, 146], [146, 91], [91, 181], [181, 84], [84, 17], [17, 314], [314, 405], [405, 321], [321, 375], [375, 291], [61, 185], [185, 40], [40, 39], [39, 37], [37, 0], [0, 267], [267, 269], [269, 270], [270, 409], [409, 291],\n [78, 95], [95, 88], [88, 178], [178, 87], [87, 14], [14, 317], [317, 402], [402, 318], [318, 324], [324, 308], [78, 191], [191, 80], [80, 81], [81, 82], [82, 13], [13, 312], [312, 311], [311, 310], [310, 415], [415, 308],\n];\n\nconst LEFT_EYE_CONNECTIONS: PairArray = [[263, 249], [249, 390], [390, 373], [373, 374], [374, 380], [380, 381], [381, 382], [382, 362], [263, 466], [466, 388], [388, 387], [387, 386], [386, 385], [385, 384], [384, 398], [398, 362]];\n\nconst LEFT_EYEBROW_CONNECTIONS: PairArray = [[276, 283], [283, 282], [282, 295], [295, 285], [300, 293], [293, 334], [334, 296], [296, 336]];\n\nconst LEFT_IRIS_CONNECTIONS: PairArray = [[474, 475], [475, 476], [476, 477], [477, 474]];\n\nconst RIGHT_EYE_CONNECTIONS: PairArray = [[33, 7], [7, 163], [163, 144], [144, 145], [145, 153], [153, 154], [154, 155], [155, 133], [33, 246], [246, 161], [161, 160], [160, 159], [159, 158], [158, 157], [157, 173], [173, 133]];\n\nconst RIGHT_EYEBROW_CONNECTIONS: PairArray = [[46, 53], [53, 52], [52, 65], [65, 55], [70, 63], [63, 105], [105, 66], [66, 107]];\n\nconst RIGHT_IRIS_CONNECTIONS: PairArray = [[469, 470], [470, 471], [471, 472], [472, 469]];\n\nconst FACE_OVAL_CONNECTIONS: PairArray = [\n [10, 338], [338, 297], [297, 332], [332, 284], [284, 251], [251, 389], [389, 356], [356, 454], [454, 323], [323, 361], [361, 288], [288, 397], [397, 365], [365, 379], [379, 378], [378, 400], [400, 377], [377, 152],\n [152, 148], [148, 176], [176, 149], [149, 150], [150, 136], [136, 172], [172, 58], [58, 132], [132, 93], [93, 234], [234, 127], [127, 162], [162, 21], [21, 54], [54, 103], [103, 67], [67, 109], [109, 10],\n];\n\nexport const MEDIAPIPE_FACE_MESH_CONNECTED_KEYPOINTS_PAIRS: PairArray = [\n [127, 34], [34, 139], [139, 127], [11, 0], [0, 37], [37, 11], [232, 231], [231, 120], [120, 232], [72, 37], [37, 39], [39, 72], [128, 121], [121, 47], [47, 128], [232, 121], [121, 128], [128, 232],\n [104, 69], [69, 67], [67, 104], [175, 171], [171, 148], [148, 175], [118, 50], [50, 101], [101, 118], [73, 39], [39, 40], [40, 73], [9, 151], [151, 108], [108, 9], [48, 115], [115, 131], [131, 48],\n [194, 204], [204, 211], [211, 194], [74, 40], [40, 185], [185, 74], [80, 42], [42, 183], [183, 80], [40, 92], [92, 186], [186, 40], [230, 229], [229, 118], [118, 230], [202, 212], [212, 214], [214, 202],\n [83, 18], [18, 17], [17, 83], [76, 61], [61, 146], [146, 76], [160, 29], [29, 30], [30, 160], [56, 157], [157, 173], [173, 56], [106, 204], [204, 194], [194, 106], [135, 214], [214, 192], [192, 135],\n [203, 165], [165, 98], [98, 203], [21, 71], [71, 68], [68, 21], [51, 45], [45, 4], [4, 51], [144, 24], [24, 23], [23, 144], [77, 146], [146, 91], [91, 77], [205, 50], [50, 187], [187, 205],\n [201, 200], [200, 18], [18, 201], [91, 106], [106, 182], [182, 91], [90, 91], [91, 181], [181, 90], [85, 84], [84, 17], [17, 85], [206, 203], [203, 36], [36, 206], [148, 171], [171, 140], [140, 148],\n [92, 40], [40, 39], [39, 92], [193, 189], [189, 244], [244, 193], [159, 158], [158, 28], [28, 159], [247, 246], [246, 161], [161, 247], [236, 3], [3, 196], [196, 236], [54, 68], [68, 104], [104, 54],\n [193, 168], [168, 8], [8, 193], [117, 228], [228, 31], [31, 117], [189, 193], [193, 55], [55, 189], [98, 97], [97, 99], [99, 98], [126, 47], [47, 100], [100, 126], [166, 79], [79, 218], [218, 166],\n [155, 154], [154, 26], [26, 155], [209, 49], [49, 131], [131, 209], [135, 136], [136, 150], [150, 135], [47, 126], [126, 217], [217, 47], [223, 52], [52, 53], [53, 223], [45, 51], [51, 134], [134, 45],\n [211, 170], [170, 140], [140, 211], [67, 69], [69, 108], [108, 67], [43, 106], [106, 91], [91, 43], [230, 119], [119, 120], [120, 230], [226, 130], [130, 247], [247, 226], [63, 53], [53, 52], [52, 63],\n [238, 20], [20, 242], [242, 238], [46, 70], [70, 156], [156, 46], [78, 62], [62, 96], [96, 78], [46, 53], [53, 63], [63, 46], [143, 34], [34, 227], [227, 143], [123, 117], [117, 111], [111, 123],\n [44, 125], [125, 19], [19, 44], [236, 134], [134, 51], [51, 236], [216, 206], [206, 205], [205, 216], [154, 153], [153, 22], [22, 154], [39, 37], [37, 167], [167, 39], [200, 201], [201, 208], [208, 200],\n [36, 142], [142, 100], [100, 36], [57, 212], [212, 202], [202, 57], [20, 60], [60, 99], [99, 20], [28, 158], [158, 157], [157, 28], [35, 226], [226, 113], [113, 35], [160, 159], [159, 27], [27, 160],\n [204, 202], [202, 210], [210, 204], [113, 225], [225, 46], [46, 113], [43, 202], [202, 204], [204, 43], [62, 76], [76, 77], [77, 62], [137, 123], [123, 116], [116, 137], [41, 38], [38, 72], [72, 41],\n [203, 129], [129, 142], [142, 203], [64, 98], [98, 240], [240, 64], [49, 102], [102, 64], [64, 49], [41, 73], [73, 74], [74, 41], [212, 216], [216, 207], [207, 212], [42, 74], [74, 184], [184, 42],\n [169, 170], [170, 211], [211, 169], [170, 149], [149, 176], [176, 170], [105, 66], [66, 69], [69, 105], [122, 6], [6, 168], [168, 122], [123, 147], [147, 187], [187, 123], [96, 77], [77, 90], [90, 96],\n [65, 55], [55, 107], [107, 65], [89, 90], [90, 180], [180, 89], [101, 100], [100, 120], [120, 101], [63, 105], [105, 104], [104, 63], [93, 137], [137, 227], [227, 93], [15, 86], [86, 85], [85, 15],\n [129, 102], [102, 49], [49, 129], [14, 87], [87, 86], [86, 14], [55, 8], [8, 9], [9, 55], [100, 47], [47, 121], [121, 100], [145, 23], [23, 22], [22, 145], [88, 89], [89, 179], [179, 88],\n [6, 122], [122, 196], [196, 6], [88, 95], [95, 96], [96, 88], [138, 172], [172, 136], [136, 138], [215, 58], [58, 172], [172, 215], [115, 48], [48, 219], [219, 115], [42, 80], [80, 81], [81, 42],\n [195, 3], [3, 51], [51, 195], [43, 146], [146, 61], [61, 43], [171, 175], [175, 199], [199, 171], [81, 82], [82, 38], [38, 81], [53, 46], [46, 225], [225, 53], [144, 163], [163, 110], [110, 144],\n [52, 65], [65, 66], [66, 52], [229, 228], [228, 117], [117, 229], [34, 127], [127, 234], [234, 34], [107, 108], [108, 69], [69, 107], [109, 108], [108, 151], [151, 109], [48, 64], [64, 235], [235, 48],\n [62, 78], [78, 191], [191, 62], [129, 209], [209, 126], [126, 129], [111, 35], [35, 143], [143, 111], [117, 123], [123, 50], [50, 117], [222, 65], [65, 52], [52, 222], [19, 125], [125, 141], [141, 19],\n [221, 55], [55, 65], [65, 221], [3, 195], [195, 197], [197, 3], [25, 7], [7, 33], [33, 25], [220, 237], [237, 44], [44, 220], [70, 71], [71, 139], [139, 70], [122, 193], [193, 245], [245, 122],\n [247, 130], [130, 33], [33, 247], [71, 21], [21, 162], [162, 71], [170, 169], [169, 150], [150, 170], [188, 174], [174, 196], [196, 188], [216, 186], [186, 92], [92, 216], [2, 97], [97, 167], [167, 2],\n [141, 125], [125, 241], [241, 141], [164, 167], [167, 37], [37, 164], [72, 38], [38, 12], [12, 72], [38, 82], [82, 13], [13, 38], [63, 68], [68, 71], [71, 63], [226, 35], [35, 111], [111, 226],\n [101, 50], [50, 205], [205, 101], [206, 92], [92, 165], [165, 206], [209, 198], [198, 217], [217, 209], [165, 167], [167, 97], [97, 165], [220, 115], [115, 218], [218, 220], [133, 112], [112, 243], [243, 133],\n [239, 238], [238, 241], [241, 239], [214, 135], [135, 169], [169, 214], [190, 173], [173, 133], [133, 190], [171, 208], [208, 32], [32, 171], [125, 44], [44, 237], [237, 125], [86, 87], [87, 178], [178, 86],\n [85, 86], [86, 179], [179, 85], [84, 85], [85, 180], [180, 84], [83, 84], [84, 181], [181, 83], [201, 83], [83, 182], [182, 201], [137, 93], [93, 132], [132, 137], [76, 62], [62, 183], [183, 76],\n [61, 76], [76, 184], [184, 61], [57, 61], [61, 185], [185, 57], [212, 57], [57, 186], [186, 212], [214, 207], [207, 187], [187, 214], [34, 143], [143, 156], [156, 34], [79, 239], [239, 237], [237, 79],\n [123, 137], [137, 177], [177, 123], [44, 1], [1, 4], [4, 44], [201, 194], [194, 32], [32, 201], [64, 102], [102, 129], [129, 64], [213, 215], [215, 138], [138, 213], [59, 166], [166, 219], [219, 59],\n [242, 99], [99, 97], [97, 242], [2, 94], [94, 141], [141, 2], [75, 59], [59, 235], [235, 75], [24, 110], [110, 228], [228, 24], [25, 130], [130, 226], [226, 25], [23, 24], [24, 229], [229, 23],\n [22, 23], [23, 230], [230, 22], [26, 22], [22, 231], [231, 26], [112, 26], [26, 232], [232, 112], [189, 190], [190, 243], [243, 189], [221, 56], [56, 190], [190, 221], [28, 56], [56, 221], [221, 28],\n [27, 28], [28, 222], [222, 27], [29, 27], [27, 223], [223, 29], [30, 29], [29, 224], [224, 30], [247, 30], [30, 225], [225, 247], [238, 79], [79, 20], [20, 238], [166, 59], [59, 75], [75, 166],\n [60, 75], [75, 240], [240, 60], [147, 177], [177, 215], [215, 147], [20, 79], [79, 166], [166, 20], [187, 147], [147, 213], [213, 187], [112, 233], [233, 244], [244, 112], [233, 128], [128, 245], [245, 233],\n [128, 114], [114, 188], [188, 128], [114, 217], [217, 174], [174, 114], [131, 115], [115, 220], [220, 131], [217, 198], [198, 236], [236, 217], [198, 131], [131, 134], [134, 198], [177, 132], [132, 58], [58, 177],\n [143, 35], [35, 124], [124, 143], [110, 163], [163, 7], [7, 110], [228, 110], [110, 25], [25, 228], [356, 389], [389, 368], [368, 356], [11, 302], [302, 267], [267, 11], [452, 350], [350, 349], [349, 452],\n [302, 303], [303, 269], [269, 302], [357, 343], [343, 277], [277, 357], [452, 453], [453, 357], [357, 452], [333, 332], [332, 297], [297, 333], [175, 152], [152, 377], [377, 175], [347, 348], [348, 330], [330, 347],\n [303, 304], [304, 270], [270, 303], [9, 336], [336, 337], [337, 9], [278, 279], [279, 360], [360, 278], [418, 262], [262, 431], [431, 418], [304, 408], [408, 409], [409, 304], [310, 415], [415, 407], [407, 310],\n [270, 409], [409, 410], [410, 270], [450, 348], [348, 347], [347, 450], [422, 430], [430, 434], [434, 422], [313, 314], [314, 17], [17, 313], [306, 307], [307, 375], [375, 306], [387, 388], [388, 260], [260, 387],\n [286, 414], [414, 398], [398, 286], [335, 406], [406, 418], [418, 335], [364, 367], [367, 416], [416, 364], [423, 358], [358, 327], [327, 423], [251, 284], [284, 298], [298, 251], [281, 5], [5, 4], [4, 281],\n [373, 374], [374, 253], [253, 373], [307, 320], [320, 321], [321, 307], [425, 427], [427, 411], [411, 425], [421, 313], [313, 18], [18, 421], [321, 405], [405, 406], [406, 321], [320, 404], [404, 405], [405, 320],\n [315, 16], [16, 17], [17, 315], [426, 425], [425, 266], [266, 426], [377, 400], [400, 369], [369, 377], [322, 391], [391, 269], [269, 322], [417, 465], [465, 464], [464, 417], [386, 257], [257, 258], [258, 386],\n [466, 260], [260, 388], [388, 466], [456, 399], [399, 419], [419, 456], [284, 332], [332, 333], [333, 284], [417, 285], [285, 8], [8, 417], [346, 340], [340, 261], [261, 346], [413, 441], [441, 285], [285, 413],\n [327, 460], [460, 328], [328, 327], [355, 371], [371, 329], [329, 355], [392, 439], [439, 438], [438, 392], [382, 341], [341, 256], [256, 382], [429, 420], [420, 360], [360, 429], [364, 394], [394, 379], [379, 364],\n [277, 343], [343, 437], [437, 277], [443, 444], [444, 283], [283, 443], [275, 440], [440, 363], [363, 275], [431, 262], [262, 369], [369, 431], [297, 338], [338, 337], [337, 297], [273, 375], [375, 321], [321, 273],\n [450, 451], [451, 349], [349, 450], [446, 342], [342, 467], [467, 446], [293, 334], [334, 282], [282, 293], [458, 461], [461, 462], [462, 458], [276, 353], [353, 383], [383, 276], [308, 324], [324, 325], [325, 308],\n [276, 300], [300, 293], [293, 276], [372, 345], [345, 447], [447, 372], [352, 345], [345, 340], [340, 352], [274, 1], [1, 19], [19, 274], [456, 248], [248, 281], [281, 456], [436, 427], [427, 425], [425, 436],\n [381, 256], [256, 252], [252, 381], [269, 391], [391, 393], [393, 269], [200, 199], [199, 428], [428, 200], [266, 330], [330, 329], [329, 266], [287, 273], [273, 422], [422, 287], [250, 462], [462, 328], [328, 250],\n [258, 286], [286, 384], [384, 258], [265, 353], [353, 342], [342, 265], [387, 259], [259, 257], [257, 387], [424, 431], [431, 430], [430, 424], [342, 353], [353, 276], [276, 342], [273, 335], [335, 424], [424, 273],\n [292, 325], [325, 307], [307, 292], [366, 447], [447, 345], [345, 366], [271, 303], [303, 302], [302, 271], [423, 266], [266, 371], [371, 423], [294, 455], [455, 460], [460, 294], [279, 278], [278, 294], [294, 279],\n [271, 272], [272, 304], [304, 271], [432, 434], [434, 427], [427, 432], [272, 407], [407, 408], [408, 272], [394, 430], [430, 431], [431, 394], [395, 369], [369, 400], [400, 395], [334, 333], [333, 299], [299, 334],\n [351, 417], [417, 168], [168, 351], [352, 280], [280, 411], [411, 352], [325, 319], [319, 320], [320, 325], [295, 296], [296, 336], [336, 295], [319, 403], [403, 404], [404, 319], [330, 348], [348, 349], [349, 330],\n [293, 298], [298, 333], [333, 293], [323, 454], [454, 447], [447, 323], [15, 16], [16, 315], [315, 15], [358, 429], [429, 279], [279, 358], [14, 15], [15, 316], [316, 14], [285, 336], [336, 9], [9, 285],\n [329, 349], [349, 350], [350, 329], [374, 380], [380, 252], [252, 374], [318, 402], [402, 403], [403, 318], [6, 197], [197, 419], [419, 6], [318, 319], [319, 325], [325, 318], [367, 364], [364, 365], [365, 367],\n [435, 367], [367, 397], [397, 435], [344, 438], [438, 439], [439, 344], [272, 271], [271, 311], [311, 272], [195, 5], [5, 281], [281, 195], [273, 287], [287, 291], [291, 273], [396, 428], [428, 199], [199, 396],\n [311, 271], [271, 268], [268, 311], [283, 444], [444, 445], [445, 283], [373, 254], [254, 339], [339, 373], [282, 334], [334, 296], [296, 282], [449, 347], [347, 346], [346, 449], [264, 447], [447, 454], [454, 264],\n [336, 296], [296, 299], [299, 336], [338, 10], [10, 151], [151, 338], [278, 439], [439, 455], [455, 278], [292, 407], [407, 415], [415, 292], [358, 371], [371, 355], [355, 358], [340, 345], [345, 372], [372, 340],\n [346, 347], [347, 280], [280, 346], [442, 443], [443, 282], [282, 442], [19, 94], [94, 370], [370, 19], [441, 442], [442, 295], [295, 441], [248, 419], [419, 197], [197, 248], [263, 255], [255, 359], [359, 263],\n [440, 275], [275, 274], [274, 440], [300, 383], [383, 368], [368, 300], [351, 412], [412, 465], [465, 351], [263, 467], [467, 466], [466, 263], [301, 368], [368, 389], [389, 301], [395, 378], [378, 379], [379, 395],\n [412, 351], [351, 419], [419, 412], [436, 426], [426, 322], [322, 436], [2, 164], [164, 393], [393, 2], [370, 462], [462, 461], [461, 370], [164, 0], [0, 267], [267, 164], [302, 11], [11, 12], [12, 302],\n [268, 12], [12, 13], [13, 268], [293, 300], [300, 301], [301, 293], [446, 261], [261, 340], [340, 446], [330, 266], [266, 425], [425, 330], [426, 423], [423, 391], [391, 426], [429, 355], [355, 437], [437, 429],\n [391, 327], [327, 326], [326, 391], [440, 457], [457, 438], [438, 440], [341, 382], [382, 362], [362, 341], [459, 457], [457, 461], [461, 459], [434, 430], [430, 394], [394, 434], [414, 463], [463, 362], [362, 414],\n [396, 369], [369, 262], [262, 396], [354, 461], [461, 457], [457, 354], [316, 403], [403, 402], [402, 316], [315, 404], [404, 403], [403, 315], [314, 405], [405, 404], [404, 314], [313, 406], [406, 405], [405, 313],\n [421, 418], [418, 406], [406, 421], [366, 401], [401, 361], [361, 366], [306, 408], [408, 407], [407, 306], [291, 409], [409, 408], [408, 291], [287, 410], [410, 409], [409, 287], [432, 436], [436, 410], [410, 432],\n [434, 416], [416, 411], [411, 434], [264, 368], [368, 383], [383, 264], [309, 438], [438, 457], [457, 309], [352, 376], [376, 401], [401, 352], [274, 275], [275, 4], [4, 274], [421, 428], [428, 262], [262, 421],\n [294, 327], [327, 358], [358, 294], [433, 416], [416, 367], [367, 433], [289, 455], [455, 439], [439, 289], [462, 370], [370, 326], [326, 462], [2, 326], [326, 370], [370, 2], [305, 460], [460, 455], [455, 305],\n [254, 449], [449, 448], [448, 254], [255, 261], [261, 446], [446, 255], [253, 450], [450, 449], [449, 253], [252, 451], [451, 450], [450, 252], [256, 452], [452, 451], [451, 256], [341, 453], [453, 452], [452, 341],\n [413, 464], [464, 463], [463, 413], [441, 413], [413, 414], [414, 441], [258, 442], [442, 441], [441, 258], [257, 443], [443, 442], [442, 257], [259, 444], [444, 443], [443, 259], [260, 445], [445, 444], [444, 260],\n [467, 342], [342, 445], [445, 467], [459, 458], [458, 250], [250, 459], [289, 392], [392, 290], [290, 289], [290, 328], [328, 460], [460, 290], [376, 433], [433, 435], [435, 376], [250, 290], [290, 392], [392, 250],\n [411, 416], [416, 433], [433, 411], [341, 463], [463, 464], [464, 341], [453, 464], [464, 465], [465, 453], [357, 465], [465, 412], [412, 357], [343, 412], [412, 399], [399, 343], [360, 363], [363, 440], [440, 360],\n [437, 399], [399, 456], [456, 437], [420, 456], [456, 363], [363, 420], [401, 435], [435, 288], [288, 401], [372, 383], [383, 353], [353, 372], [339, 255], [255, 249], [249, 339], [448, 261], [261, 255], [255, 448],\n [133, 243], [243, 190], [190, 133], [133, 155], [155, 112], [112, 133], [33, 246], [246, 247], [247, 33], [33, 130], [130, 25], [25, 33], [398, 384], [384, 286], [286, 398], [362, 398], [398, 414], [414, 362],\n [362, 463], [463, 341], [341, 362], [263, 359], [359, 467], [467, 263], [263, 249], [249, 255], [255, 263], [466, 467], [467, 260], [260, 466], [75, 60], [60, 166], [166, 75], [238, 239], [239, 79], [79, 238],\n [162, 127], [127, 139], [139, 162], [72, 11], [11, 37], [37, 72], [121, 232], [232, 120], [120, 121], [73, 72], [72, 39], [39, 73], [114, 128], [128, 47], [47, 114], [233, 232], [232, 128], [128, 233],\n [103, 104], [104, 67], [67, 103], [152, 175], [175, 148], [148, 152], [119, 118], [118, 101], [101, 119], [74, 73], [73, 40], [40, 74], [107, 9], [9, 108], [108, 107], [49, 48], [48, 131], [131, 49],\n [32, 194], [194, 211], [211, 32], [184, 74], [74, 185], [185, 184], [191, 80], [80, 183], [183, 191], [185, 40], [40, 186], [186, 185], [119, 230], [230, 118], [118, 119], [210, 202], [202, 214], [214, 210],\n [84, 83], [83, 17], [17, 84], [77, 76], [76, 146], [146, 77], [161, 160], [160, 30], [30, 161], [190, 56], [56, 173], [173, 190], [182, 106], [106, 194], [194, 182], [138, 135], [135, 192], [192, 138],\n [129, 203], [203, 98], [98, 129], [54, 21], [21, 68], [68, 54], [5, 51], [51, 4], [4, 5], [145, 144], [144, 23], [23, 145], [90, 77], [77, 91], [91, 90], [207, 205], [205, 187], [187, 207],\n [83, 201], [201, 18], [18, 83], [181, 91], [91, 182], [182, 181], [180, 90], [90, 181], [181, 180], [16, 85], [85, 17], [17, 16], [205, 206], [206, 36], [36, 205], [176, 148], [148, 140], [140, 176],\n [165, 92], [92, 39], [39, 165], [245, 193], [193, 244], [244, 245], [27, 159], [159, 28], [28, 27], [30, 247], [247, 161], [161, 30], [174, 236], [236, 196], [196, 174], [103, 54], [54, 104], [104, 103],\n [55, 193], [193, 8], [8, 55], [111, 117], [117, 31], [31, 111], [221, 189], [189, 55], [55, 221], [240, 98], [98, 99], [99, 240], [142, 126], [126, 100], [100, 142], [219, 166], [166, 218], [218, 219],\n [112, 155], [155, 26], [26, 112], [198, 209], [209, 131], [131, 198], [169, 135], [135, 150], [150, 169], [114, 47], [47, 217], [217, 114], [224, 223], [223, 53], [53, 224], [220, 45], [45, 134], [134, 220],\n [32, 211], [211, 140], [140, 32], [109, 67], [67, 108], [108, 109], [146, 43], [43, 91], [91, 146], [231, 230], [230, 120], [120, 231], [113, 226], [226, 247], [247, 113], [105, 63], [63, 52], [52, 105],\n [241, 238], [238, 242], [242, 241], [124, 46], [46, 156], [156, 124], [95, 78], [78, 96], [96, 95], [70, 46], [46, 63], [63, 70], [116, 143], [143, 227], [227, 116], [116, 123], [123, 111], [111, 116],\n [1, 44], [44, 19], [19, 1], [3, 236], [236, 51], [51, 3], [207, 216], [216, 205], [205, 207], [26, 154], [154, 22], [22, 26], [165, 39], [39, 167], [167, 165], [199, 200], [200, 208], [208, 199],\n [101, 36], [36, 100], [100, 101], [43, 57], [57, 202], [202, 43], [242, 20], [20, 99], [99, 242], [56, 28], [28, 157], [157, 56], [124, 35], [35, 113], [113, 124], [29, 160], [160, 27], [27, 29],\n [211, 204], [204, 210], [210, 211], [124, 113], [113, 46], [46, 124], [106, 43], [43, 204], [204, 106], [96, 62], [62, 77], [77, 96], [227, 137], [137, 116], [116, 227], [73, 41], [41, 72], [72, 73],\n [36, 203], [203, 142], [142, 36], [235, 64], [64, 240], [240, 235], [48, 49], [49, 64], [64, 48], [42, 41], [41, 74], [74, 42], [214, 212], [212, 207], [207, 214], [183, 42], [42, 184], [184, 183],\n [210, 169], [169, 211], [211, 210], [140, 170], [170, 176], [176, 140], [104, 105], [105, 69], [69, 104], [193, 122], [122, 168], [168, 193], [50, 123], [123, 187], [187, 50], [89, 96], [96, 90], [90, 89],\n [66, 65], [65, 107], [107, 66], [179, 89], [89, 180], [180, 179], [119, 101], [101, 120], [120, 119], [68, 63], [63, 104], [104, 68], [234, 93], [93, 227], [227, 234], [16, 15], [15, 85], [85, 16],\n [209, 129], [129, 49], [49, 209], [15, 14], [14, 86], [86, 15], [107, 55], [55, 9], [9, 107], [120, 100], [100, 121], [121, 120], [153, 145], [145, 22], [22, 153], [178, 88], [88, 179], [179, 178],\n [197, 6], [6, 196], [196, 197], [89, 88], [88, 96], [96, 89], [135, 138], [138, 136], [136, 135], [138, 215], [215, 172], [172, 138], [218, 115], [115, 219], [219, 218], [41, 42], [42, 81], [81, 41],\n [5, 195], [195, 51], [51, 5], [57, 43], [43, 61], [61, 57], [208, 171], [171, 199], [199, 208], [41, 81], [81, 38], [38, 41], [224, 53], [53, 225], [225, 224], [24, 144], [144, 110], [110, 24],\n [105, 52], [52, 66], [66, 105], [118, 229], [229, 117], [117, 118], [227, 34], [34, 234], [234, 227], [66, 107], [107, 69], [69, 66], [10, 109], [109, 151], [151, 10], [219, 48], [48, 235], [235, 219],\n [183, 62], [62, 191], [191, 183], [142, 129], [129, 126], [126, 142], [116, 111], [111, 143], [143, 116], [118, 117], [117, 50], [50, 118], [223, 222], [222, 52], [52, 223], [94, 19], [19, 141], [141, 94],\n [222, 221], [221, 65], [65, 222], [196, 3], [3, 197], [197, 196], [45, 220], [220, 44], [44, 45], [156, 70], [70, 139], [139, 156], [188, 122], [122, 245], [245, 188], [139, 71], [71, 162], [162, 139],\n [149, 170], [170, 150], [150, 149], [122, 188], [188, 196], [196, 122], [206, 216], [216, 92], [92, 206], [164, 2], [2, 167], [167, 164], [242, 141], [141, 241], [241, 242], [0, 164], [164, 37], [37, 0],\n [11, 72], [72, 12], [12, 11], [12, 38], [38, 13], [13, 12], [70, 63], [63, 71], [71, 70], [31, 226], [226, 111], [111, 31], [36, 101], [101, 205], [205, 36], [203, 206], [206, 165], [165, 203],\n [126, 209], [209, 217], [217, 126], [98, 165], [165, 97], [97, 98], [237, 220], [220, 218], [218, 237], [237, 239], [239, 241], [241, 237], [210, 214], [214, 169], [169, 210], [140, 171], [171, 32], [32, 140],\n [241, 125], [125, 237], [237, 241], [179, 86], [86, 178], [178, 179], [180, 85], [85, 179], [179, 180], [181, 84], [84, 180], [180, 181], [182, 83], [83, 181], [181, 182], [194, 201], [201, 182], [182, 194],\n [177, 137], [137, 132], [132, 177], [184, 76], [76, 183], [183, 184], [185, 61], [61, 184], [184, 185], [186, 57], [57, 185], [185, 186], [216, 212], [212, 186], [186, 216], [192, 214], [214, 187], [187, 192],\n [139, 34], [34, 156], [156, 139], [218, 79], [79, 237], [237, 218], [147, 123], [123, 177], [177, 147], [45, 44], [44, 4], [4, 45], [208, 201], [201, 32], [32, 208], [98, 64], [64, 129], [129, 98],\n [192, 213], [213, 138], [138, 192], [235, 59], [59, 219], [219, 235], [141, 242], [242, 97], [97, 141], [97, 2], [2, 141], [141, 97], [240, 75], [75, 235], [235, 240], [229, 24], [24, 228], [228, 229],\n [31, 25], [25, 226], [226, 31], [230, 23], [23, 229], [229, 230], [231, 22], [22, 230], [230, 231], [232, 26], [26, 231], [231, 232], [233, 112], [112, 232], [232, 233], [244, 189], [189, 243], [243, 244],\n [189, 221], [221, 190], [190, 189], [222, 28], [28, 221], [221, 222], [223, 27], [27, 222], [222, 223], [224, 29], [29, 223], [223, 224], [225, 30], [30, 224], [224, 225], [113, 247], [247, 225], [225, 113],\n [99, 60], [60, 240], [240, 99], [213, 147], [147, 215], [215, 213], [60, 20], [20, 166], [166, 60], [192, 187], [187, 213], [213, 192], [243, 112], [112, 244], [244, 243], [244, 233], [233, 245], [245, 244],\n [245, 128], [128, 188], [188, 245], [188, 114], [114, 174], [174, 188], [134, 131], [131, 220], [220, 134], [174, 217], [217, 236], [236, 174], [236, 198], [198, 134], [134, 236], [215, 177], [177, 58], [58, 215],\n [156, 143], [143, 124], [124, 156], [25, 110], [110, 7], [7, 25], [31, 228], [228, 25], [25, 31], [264, 356], [356, 368], [368, 264], [0, 11], [11, 267], [267, 0], [451, 452], [452, 349], [349, 451],\n [267, 302], [302, 269], [269, 267], [350, 357], [357, 277], [277, 350], [350, 452], [452, 357], [357, 350], [299, 333], [333, 297], [297, 299], [396, 175], [175, 377], [377, 396], [280, 347], [347, 330], [330, 280],\n [269, 303], [303, 270], [270, 269], [151, 9], [9, 337], [337, 151], [344, 278], [278, 360], [360, 344], [424, 418], [418, 431], [431, 424], [270, 304], [304, 409], [409, 270], [272, 310], [310, 407], [407, 272],\n [322, 270], [270, 410], [410, 322], [449, 450], [450, 347], [347, 449], [432, 422], [422, 434], [434, 432], [18, 313], [313, 17], [17, 18], [291, 306], [306, 375], [375, 291], [259, 387], [387, 260], [260, 259],\n [424, 335], [335, 418], [418, 424], [434, 364], [364, 416], [416, 434], [391, 423], [423, 327], [327, 391], [301, 251], [251, 298], [298, 301], [275, 281], [281, 4], [4, 275], [254, 373], [373, 253], [253, 254],\n [375, 307], [307, 321], [321, 375], [280, 425], [425, 411], [411, 280], [200, 421], [421, 18], [18, 200], [335, 321], [321, 406], [406, 335], [321, 320], [320, 405], [405, 321], [314, 315], [315, 17], [17, 314],\n [423, 426], [426, 266], [266, 423], [396, 377], [377, 369], [369, 396], [270, 322], [322, 269], [269, 270], [413, 417], [417, 464], [464, 413], [385, 386], [386, 258], [258, 385], [248, 456], [456, 419], [419, 248],\n [298, 284], [284, 333], [333, 298], [168, 417], [417, 8], [8, 168], [448, 346], [346, 261], [261, 448], [417, 413], [413, 285], [285, 417], [326, 327], [327, 328], [328, 326], [277, 355], [355, 329], [329, 277],\n [309, 392], [392, 438], [438, 309], [381, 382], [382, 256], [256, 381], [279, 429], [429, 360], [360, 279], [365, 364], [364, 379], [379, 365], [355, 277], [277, 437], [437, 355], [282, 443], [443, 283], [283, 282],\n [281, 275], [275, 363], [363, 281], [395, 431], [431, 369], [369, 395], [299, 297], [297, 337], [337, 299], [335, 273], [273, 321], [321, 335], [348, 450], [450, 349], [349, 348], [359, 446], [446, 467], [467, 359],\n [283, 293], [293, 282], [282, 283], [250, 458], [458, 462], [462, 250], [300, 276], [276, 383], [383, 300], [292, 308], [308, 325], [325, 292], [283, 276], [276, 293], [293, 283], [264, 372], [372, 447], [447, 264],\n [346, 352], [352, 340], [340, 346], [354, 274], [274, 19], [19, 354], [363, 456], [456, 281], [281, 363], [426, 436], [436, 425], [425, 426], [380, 381], [381, 252], [252, 380], [267, 269], [269, 393], [393, 267],\n [421, 200], [200, 428], [428, 421], [371, 266], [266, 329], [329, 371], [432, 287], [287, 422], [422, 432], [290, 250], [250, 328], [328, 290], [385, 258], [258, 384], [384, 385], [446, 265], [265, 342], [342, 446],\n [386, 387], [387, 257], [257, 386], [422, 424], [424, 430], [430, 422], [445, 342], [342, 276], [276, 445], [422, 273], [273, 424], [424, 422], [306, 292], [292, 307], [307, 306], [352, 366], [366, 345], [345, 352],\n [268, 271], [271, 302], [302, 268], [358, 423], [423, 371], [371, 358], [327, 294], [294, 460], [460, 327], [331, 279], [279, 294], [294, 331], [303, 271], [271, 304], [304, 303], [436, 432], [432, 427], [427, 436],\n [304, 272], [272, 408], [408, 304], [395, 394], [394, 431], [431, 395], [378, 395], [395, 400], [400, 378], [296, 334], [334, 299], [299, 296], [6, 351], [351, 168], [168, 6], [376, 352], [352, 411], [411, 376],\n [307, 325], [325, 320], [320, 307], [285, 295], [295, 336], [336, 285], [320, 319], [319, 404], [404, 320], [329, 330], [330, 349], [349, 329], [334, 293], [293, 333], [333, 334], [366, 323], [323, 447], [447, 366],\n [316, 15], [15, 315], [315, 316], [331, 358], [358, 279], [279, 331], [317, 14], [14, 316], [316, 317], [8, 285], [285, 9], [9, 8], [277, 329], [329, 350], [350, 277], [253, 374], [374, 252], [252, 253],\n [319, 318], [318, 403], [403, 319], [351, 6], [6, 419], [419, 351], [324, 318], [318, 325], [325, 324], [397, 367], [367, 365], [365, 397], [288, 435], [435, 397], [397, 288], [278, 344], [344, 439], [439, 278],\n [310, 272], [272, 311], [311, 310], [248, 195], [195, 281], [281, 248], [375, 273], [273, 291], [291, 375], [175, 396], [396, 199], [199, 175], [312, 311], [311, 268], [268, 312], [276, 283], [283, 445], [445, 276],\n [390, 373], [373, 339], [339, 390], [295, 282], [282, 296], [296, 295], [448, 449], [449, 346], [346, 448], [356, 264], [264, 454], [454, 356], [337, 336], [336, 299], [299, 337], [337, 338], [338, 151], [151, 337],\n [294, 278], [278, 455], [455, 294], [308, 292], [292, 415], [415, 308], [429, 358], [358, 355], [355, 429], [265, 340], [340, 372], [372, 265], [352, 346], [346, 280], [280, 352], [295, 442], [442, 282], [282, 295],\n [354, 19], [19, 370], [370, 354], [285, 441], [441, 295], [295, 285], [195, 248], [248, 197], [197, 195], [457, 440], [440, 274], [274, 457], [301, 300], [300, 368], [368, 301], [417, 351], [351, 465], [465, 417],\n [251, 301], [301, 389], [389, 251], [394, 395], [395, 379], [379, 394], [399, 412], [412, 419], [419, 399], [410, 436], [436, 322], [322, 410], [326, 2], [2, 393], [393, 326], [354, 370], [370, 461], [461, 354],\n [393, 164], [164, 267], [267, 393], [268, 302], [302, 12], [12, 268], [312, 268], [268, 13], [13, 312], [298, 293], [293, 301], [301, 298], [265, 446], [446, 340], [340, 265], [280, 330], [330, 425], [425, 280],\n [322, 426], [426, 391], [391, 322], [420, 429], [429, 437], [437, 420], [393, 391], [391, 326], [326, 393], [344, 440], [440, 438], [438, 344], [458, 459], [459, 461], [461, 458], [364, 434], [434, 394], [394, 364],\n [428, 396], [396, 262], [262, 428], [274, 354], [354, 457], [457, 274], [317, 316], [316, 402], [402, 317], [316, 315], [315, 403], [403, 316], [315, 314], [314, 404], [404, 315], [314, 313], [313, 405], [405, 314],\n [313, 421], [421, 406], [406, 313], [323, 366], [366, 361], [361, 323], [292, 306], [306, 407], [407, 292], [306, 291], [291, 408], [408, 306], [291, 287], [287, 409], [409, 291], [287, 432], [432, 410], [410, 287],\n [427, 434], [434, 411], [411, 427], [372, 264], [264, 383], [383, 372], [459, 309], [309, 457], [457, 459], [366, 352], [352, 401], [401, 366], [1, 274], [274, 4], [4, 1], [418, 421], [421, 262], [262, 418],\n [331, 294], [294, 358], [358, 331], [435, 433], [433, 367], [367, 435], [392, 289], [289, 439], [439, 392], [328, 462], [462, 326], [326, 328], [94, 2], [2, 370], [370, 94], [289, 305], [305, 455], [455, 289],\n [339, 254], [254, 448], [448, 339], [359, 255], [255, 446], [446, 359], [254, 253], [253, 449], [449, 254], [253, 252], [252, 450], [450, 253], [252, 256], [256, 451], [451, 252], [256, 341], [341, 452], [452, 256],\n [414, 413], [413, 463], [463, 414], [286, 441], [441, 414], [414, 286], [286, 258], [258, 441], [441, 286], [258, 257], [257, 442], [442, 258], [257, 259], [259, 443], [443, 257], [259, 260], [260, 444], [444, 259],\n [260, 467], [467, 445], [445, 260], [309, 459], [459, 250], [250, 309], [305, 289], [289, 290], [290, 305], [305, 290], [290, 460], [460, 305], [401, 376], [376, 435], [435, 401], [309, 250], [250, 392], [392, 309],\n [376, 411], [411, 433], [433, 376], [453, 341], [341, 464], [464, 453], [357, 453], [453, 465], [465, 357], [343, 357], [357, 412], [412, 343], [437, 343], [343, 399], [399, 437], [344, 360], [360, 440], [440, 344],\n [420, 437], [437, 456], [456, 420], [360, 420], [420, 363], [363, 360], [361, 401], [401, 288], [288, 361], [265, 372], [372, 353], [353, 265], [390, 339], [339, 249], [249, 390], [339, 448], [448, 255], [255, 339],\n];\n\nfunction connectionsToIndices(connections: PairArray) {\n const indices = connections.map((connection) => connection[0]);\n indices.push(connections[connections.length - 1][1]);\n return indices;\n}\n\nexport const MEDIAPIPE_FACE_MESH_KEYPOINTS_BY_CONTOUR = {\n lips: connectionsToIndices(LIPS_CONNECTIONS),\n leftEye: connectionsToIndices(LEFT_EYE_CONNECTIONS),\n leftEyebrow: connectionsToIndices(LEFT_EYEBROW_CONNECTIONS),\n leftIris: connectionsToIndices(LEFT_IRIS_CONNECTIONS),\n rightEye: connectionsToIndices(RIGHT_EYE_CONNECTIONS),\n rightEyebrow: connectionsToIndices(RIGHT_EYEBROW_CONNECTIONS),\n rightIris: connectionsToIndices(RIGHT_IRIS_CONNECTIONS),\n faceOval: connectionsToIndices(FACE_OVAL_CONNECTIONS),\n};\n\nconst indexLabelPairs: [number, string][] = Object.entries(MEDIAPIPE_FACE_MESH_KEYPOINTS_BY_CONTOUR)\n .map(([label, indices]) => indices.map((index) => [index, label] as [number, string]))\n .flat();\n\nexport const MEDIAPIPE_FACE_MESH_KEYPOINTS = new Map(indexLabelPairs);\n\ntype AssignAverage = number[];\nexport interface LandmarksRefinementConfig {\n indexesMapping: number[]; // Maps indexes of the given set of landmarks to indexes of the resulting set of landmarks. Should be non empty and contain the same amount of indexes as landmarks in the corresponding input\n zRefinement: 'none'|'copy'|AssignAverage; // Z refinement instructions.\n}\n\nexport const LANDMARKS_REFINEMENT_LIPS_CONFIG = [\n 61, 146, 91, 181, 84, 17, 314, 405, 321, 375, 291, // Lower outer.\n 185, 40, 39, 37, 0, 267, 269, 270, 409, // Upper outer(excluding corners).\n 78, 95, 88, 178, 87, 14, 317, 402, 318, 324, 308, // Lower inner.\n 191, 80, 81, 82, 13, 312, 311, 310, 415, // Upper inner(excluding corners).\n 76, 77, 90, 180, 85, 16, 315, 404, 320, 307, 306, // Lower semi - outer.\n 184, 74, 73, 72, 11, 302, 303, 304, 408, // Upper semi - outer(excluding corners).\n 62, 96, 89, 179, 86, 15, 316, 403, 319, 325, 292, // Lower semi - inner.\n 183, 42, 41, 38, 12, 268, 271, 272, 407, // Upper semi - inner(excluding corners).\n];\n\nexport const LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG = [\n 33, 7, 163, 144, 145, 153, 154, 155, 133, // Lower contour.\n 246, 161, 160, 159, 158, 157, 173, // upper contour (excluding corners).\n 130, 25, 110, 24, 23, 22, 26, 112, 243, // Halo x2 lower contour.\n 247, 30, 29, 27, 28, 56, 190, // Halo x2 upper contour (excluding corners).\n 226, 31, 228, 229, 230, 231, 232, 233, 244, // Halo x3 lower contour.\n 113, 225, 224, 223, 222, 221, 189, // Halo x3 upper contour (excluding corners).\n 35, 124, 46, 53, 52, 65, // Halo x4 upper contour (no lower because of mesh structure) or eyebrow inner contour.\n 143, 111, 117, 118, 119, 120, 121, 128, 245, // Halo x5 lower contour.\n 156, 70, 63, 105, 66, 107, 55, 193, // Halo x5 upper contour (excluding corners) or eyebrow outer contour.\n];\n\nexport const LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG = [\n 263, 249, 390, 373, 374, 380, 381, 382, 362, // Lower contour.\n 466, 388, 387, 386, 385, 384, 398, // Upper contour (excluding corners).\n 359, 255, 339, 254, 253, 252, 256, 341, 463, // Halo x2 lower contour.\n 467, 260, 259, 257, 258, 286, 414, // Halo x2 upper contour (excluding corners).\n 446, 261, 448, 449, 450, 451, 452, 453, 464, // Halo x3 lower contour.\n 342, 445, 444, 443, 442, 441, 413, // Halo x3 upper contour (excluding corners).\n 265, 353, 276, 283, 282, 295, // Halo x4 upper contour (no lower because of mesh structure) or/ eyebrow inner contour.\n 372, 340, 346, 347, 348, 349, 350, 357, 465, // Halo x5 lower contour.\n 383, 300, 293, 334, 296, 336, 285, 417, // Halo x5 upper contour (excluding corners) or eyebrow outer contour.\n];\n\nexport const LANDMARKS_REFINEMENT_LEFT_IRIS_CONFIG = [\n 468, // Center.\n 469, // Iris right edge.\n 470, // Iris top edge.\n 471, // Iris left edge.\n 472, // Iris bottom edge.\n];\n/*\nzRefinement: [\n 33, 7, 163, 144, 145, 153, 154, 155, 133, // Lower contour.\n 246, 161, 160, 159, 158, 157, 173, // Upper contour (excluding corners).\n];\n*/\n\nexport const LANDMARKS_REFINEMENT_RIGHT_IRIS_CONFIG = [\n 473, // Center.\n 474, // Iris right edge.\n 475, // Iris top edge.\n 476, // Iris left edge.\n 477, // Iris bottom edge.\n];\n/*\nzRefinement: [\n 263, 249, 390, 373, 374, 380, 381, 382, 362, // Lower contour.\n 466, 388, 387, 386, 385, 384, 398, // Upper contour (excluding corners).\n];\n*/\n", "import { TRI468 as triangulation } from '../face/facemeshcoords';\nimport { mergeDeep } from '../util/util';\nimport { getCanvasContext, rad2deg, rect, point, lines, arrow, labels, replace } from './primitives';\nimport { options } from './options';\nimport * as facemeshConstants from '../face/constants';\nimport type { FaceResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\nlet localOptions: DrawOptions;\n\nfunction drawLabels(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (!localOptions.drawLabels || (localOptions.faceLabels?.length === 0)) return;\n let l = localOptions.faceLabels.slice();\n l = replace(l, '[id]', f.id.toFixed(0));\n if (f.score) l = replace(l, '[score]', 100 * f.score);\n if (f.gender) l = replace(l, '[gender]', f.gender);\n if (f.genderScore) l = replace(l, '[genderScore]', 100 * f.genderScore);\n if (f.age) l = replace(l, '[age]', f.age);\n if (f.distance) l = replace(l, '[distance]', 100 * f.distance);\n if (f.real) l = replace(l, '[real]', 100 * f.real);\n if (f.live) l = replace(l, '[live]', 100 * f.live);\n if (f.emotion && f.emotion.length > 0) {\n const emotion = f.emotion.map((a) => `${Math.trunc(100 * a.score)}% ${a.emotion}`);\n if (emotion.length > 3) emotion.length = 3;\n l = replace(l, '[emotions]', emotion.join(' '));\n }\n if (f.rotation?.angle?.roll) l = replace(l, '[roll]', rad2deg(f.rotation.angle.roll));\n if (f.rotation?.angle?.yaw) l = replace(l, '[yaw]', rad2deg(f.rotation.angle.yaw));\n if (f.rotation?.angle?.pitch) l = replace(l, '[pitch]', rad2deg(f.rotation.angle.pitch));\n if (f.rotation?.gaze?.bearing) l = replace(l, '[gaze]', rad2deg(f.rotation.gaze.bearing));\n labels(ctx, l, f.box[0], f.box[1], localOptions);\n}\n\nfunction drawIrisElipse(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n // iris: array[center, left, top, right, bottom]\n if (f.annotations?.leftEyeIris && f.annotations?.leftEyeIris[0]) {\n ctx.strokeStyle = localOptions.useDepth ? 'rgba(255, 200, 255, 0.3)' : localOptions.color;\n ctx.beginPath();\n const sizeX = Math.abs(f.annotations.leftEyeIris[3][0] - f.annotations.leftEyeIris[1][0]) / 2;\n const sizeY = Math.abs(f.annotations.leftEyeIris[4][1] - f.annotations.leftEyeIris[2][1]) / 2;\n ctx.ellipse(f.annotations.leftEyeIris[0][0], f.annotations.leftEyeIris[0][1], sizeX, sizeY, 0, 0, 2 * Math.PI);\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.fillStyle = localOptions.useDepth ? 'rgba(255, 255, 200, 0.3)' : localOptions.color;\n ctx.fill();\n }\n }\n if (f.annotations?.rightEyeIris && f.annotations?.rightEyeIris[0]) {\n ctx.strokeStyle = localOptions.useDepth ? 'rgba(255, 200, 255, 0.3)' : localOptions.color;\n ctx.beginPath();\n const sizeX = Math.abs(f.annotations.rightEyeIris[3][0] - f.annotations.rightEyeIris[1][0]) / 2;\n const sizeY = Math.abs(f.annotations.rightEyeIris[4][1] - f.annotations.rightEyeIris[2][1]) / 2;\n ctx.ellipse(f.annotations.rightEyeIris[0][0], f.annotations.rightEyeIris[0][1], sizeX, sizeY, 0, 0, 2 * Math.PI);\n ctx.stroke();\n if (localOptions.fillPolygons) {\n ctx.fillStyle = localOptions.useDepth ? 'rgba(255, 255, 200, 0.3)' : localOptions.color;\n ctx.fill();\n }\n }\n}\n\nfunction drawGazeSpheres(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawGaze && f.rotation?.angle && typeof Path2D !== 'undefined') {\n ctx.strokeStyle = 'pink';\n const valX = (f.box[0] + f.box[2] / 2) - (f.box[3] * rad2deg(f.rotation.angle.yaw) / 90);\n const valY = (f.box[1] + f.box[3] / 2) + (f.box[2] * rad2deg(f.rotation.angle.pitch) / 90);\n const pathV = new Path2D(`\n M ${f.box[0] + f.box[2] / 2} ${f.box[1]}\n C\n ${valX} ${f.box[1]},\n ${valX} ${f.box[1] + f.box[3]},\n ${f.box[0] + f.box[2] / 2} ${f.box[1] + f.box[3]}\n `);\n const pathH = new Path2D(`\n M ${f.box[0]} ${f.box[1] + f.box[3] / 2}\n C \n ${f.box[0]} ${valY},\n ${f.box[0] + f.box[2]} ${valY},\n ${f.box[0] + f.box[2]} ${f.box[1] + f.box[3] / 2}\n `);\n ctx.stroke(pathH);\n ctx.stroke(pathV);\n }\n}\n\nfunction drawGazeArrows(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawGaze && f.rotation?.gaze.strength && f.rotation.gaze.bearing && f.annotations.leftEyeIris && f.annotations.rightEyeIris && f.annotations.leftEyeIris[0] && f.annotations.rightEyeIris[0]) {\n ctx.strokeStyle = 'pink';\n ctx.fillStyle = 'pink';\n const leftGaze = [\n f.annotations.leftEyeIris[0][0] + (Math.sin(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[3]),\n f.annotations.leftEyeIris[0][1] + (Math.cos(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[2]),\n ];\n arrow(ctx, [f.annotations.leftEyeIris[0][0], f.annotations.leftEyeIris[0][1]], [leftGaze[0], leftGaze[1]], 4);\n const rightGaze = [\n f.annotations.rightEyeIris[0][0] + (Math.sin(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[3]),\n f.annotations.rightEyeIris[0][1] + (Math.cos(f.rotation.gaze.bearing) * f.rotation.gaze.strength * f.box[2]),\n ];\n arrow(ctx, [f.annotations.rightEyeIris[0][0], f.annotations.rightEyeIris[0][1]], [rightGaze[0], rightGaze[1]], 4);\n }\n}\n\nfunction drawFacePolygons(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawPolygons && f.mesh.length >= 468) {\n ctx.lineWidth = 1;\n for (let i = 0; i < triangulation.length / 3; i++) {\n const points = [triangulation[i * 3 + 0], triangulation[i * 3 + 1], triangulation[i * 3 + 2]].map((index) => f.mesh[index]);\n lines(ctx, points, localOptions);\n }\n drawIrisElipse(f, ctx);\n }\n /*\n if (localOptions.drawPolygons && f.contours.length > 1) {\n ctx.lineWidth = 5;\n lines(ctx, f.contours, opt);\n }\n ctx.lineWidth = 1;\n */\n}\n\nfunction drawFacePoints(f: FaceResult, ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D) {\n if (localOptions.drawPoints) {\n if (f?.mesh.length >= 468) {\n for (let i = 0; i < f.mesh.length; i++) {\n point(ctx, f.mesh[i][0], f.mesh[i][1], f.mesh[i][2], localOptions);\n if (localOptions.drawAttention) {\n if (facemeshConstants.LANDMARKS_REFINEMENT_LIPS_CONFIG.includes(i)) point(ctx, f.mesh[i][0], f.mesh[i][1], (f.mesh[i][2] as number) + 127, localOptions);\n if (facemeshConstants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG.includes(i)) point(ctx, f.mesh[i][0], f.mesh[i][1], (f.mesh[i][2] as number) - 127, localOptions);\n if (facemeshConstants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG.includes(i)) point(ctx, f.mesh[i][0], f.mesh[i][1], (f.mesh[i][2] as number) - 127, localOptions);\n }\n }\n } else {\n for (const [k, v] of Object.entries(f?.annotations || {})) {\n if (!v?.[0]) continue;\n const pt = v[0];\n point(ctx, pt[0], pt[1], 0, localOptions);\n if (localOptions.drawLabels) labels(ctx, k, pt[0], pt[1], localOptions);\n }\n }\n }\n}\n\nfunction drawFaceBoxes(f: FaceResult, ctx) {\n if (localOptions.drawBoxes) {\n rect(ctx, f.box[0], f.box[1], f.box[2], f.box[3], localOptions);\n }\n}\n\n/** draw detected faces */\nexport function face(inCanvas: AnyCanvas, result: FaceResult[], drawOptions?: Partial) {\n localOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.font = localOptions.font;\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n for (const f of result) {\n drawFaceBoxes(f, ctx);\n drawLabels(f, ctx);\n if (f.mesh && f.mesh.length > 0) {\n drawFacePoints(f, ctx);\n drawFacePolygons(f, ctx);\n drawGazeSpheres(f, ctx);\n drawGazeArrows(f, ctx);\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, rect, point, curves, colorDepth, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { BodyResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\n/** draw detected bodies */\nexport function body(inCanvas: AnyCanvas, result: BodyResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n for (let i = 0; i < result.length; i++) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n ctx.lineWidth = localOptions.lineWidth;\n ctx.font = localOptions.font;\n if (localOptions.drawBoxes && result[i].box && result[i].box.length === 4) {\n rect(ctx, result[i].box[0], result[i].box[1], result[i].box[2], result[i].box[3], localOptions);\n if (localOptions.drawLabels && (localOptions.bodyLabels?.length > 0)) {\n let l = localOptions.bodyLabels.slice();\n l = replace(l, '[id]', result[i].id.toFixed(0));\n l = replace(l, '[score]', 100 * result[i].score);\n labels(ctx, l, result[i].box[0], result[i].box[1], localOptions);\n }\n }\n if (localOptions.drawPoints && result[i].keypoints) {\n for (let pt = 0; pt < result[i].keypoints.length; pt++) {\n if (!result[i].keypoints[pt].score || (result[i].keypoints[pt].score === 0)) continue;\n ctx.fillStyle = colorDepth(result[i].keypoints[pt].position[2], localOptions);\n point(ctx, result[i].keypoints[pt].position[0], result[i].keypoints[pt].position[1], 0, localOptions);\n }\n }\n if (localOptions.drawLabels && (localOptions.bodyPartLabels?.length > 0) && result[i].keypoints) {\n ctx.font = localOptions.font;\n for (const pt of result[i].keypoints) {\n if (!pt.score || (pt.score === 0)) continue;\n let l = localOptions.bodyPartLabels.slice();\n l = replace(l, '[label]', pt.part);\n l = replace(l, '[score]', 100 * pt.score);\n labels(ctx, l, pt.position[0], pt.position[1], localOptions);\n }\n }\n if (localOptions.drawPolygons && result[i].keypoints && result[i].annotations) {\n for (const part of Object.values(result[i].annotations)) {\n for (const connected of part) curves(ctx, connected, localOptions);\n }\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, rect, point, colorDepth, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { HandResult } from '../result';\nimport type { AnyCanvas, DrawOptions, Point } from '../exports';\n\n/** draw detected hands */\nexport function hand(inCanvas: AnyCanvas, result: HandResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n ctx.font = localOptions.font;\n for (const h of result) {\n if (localOptions.drawBoxes) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n rect(ctx, h.box[0], h.box[1], h.box[2], h.box[3], localOptions);\n if (localOptions.drawLabels && (localOptions.handLabels?.length > 0)) {\n let l = localOptions.handLabels.slice();\n l = replace(l, '[id]', h.id.toFixed(0));\n l = replace(l, '[label]', h.label);\n l = replace(l, '[score]', 100 * h.score);\n labels(ctx, l, h.box[0], h.box[1], localOptions);\n }\n ctx.stroke();\n }\n if (localOptions.drawPoints) {\n if (h.keypoints && h.keypoints.length > 0) {\n for (const pt of h.keypoints) {\n ctx.fillStyle = colorDepth(pt[2], localOptions);\n point(ctx, pt[0], pt[1], 0, localOptions);\n }\n }\n }\n if (localOptions.drawLabels && h.annotations && (localOptions.fingerLabels?.length > 0)) {\n for (const [part, pt] of Object.entries(h.annotations)) {\n let l = localOptions.fingerLabels.slice();\n l = replace(l, '[label]', part);\n labels(ctx, l, pt[pt.length - 1][0], pt[pt.length - 1][1], localOptions);\n }\n }\n if (localOptions.drawPolygons && h.annotations) {\n const addHandLine = (part: Point[]) => {\n if (!part || part.length === 0 || !part[0]) return;\n for (let i = 0; i < part.length; i++) {\n ctx.beginPath();\n const z = part[i][2] || 0;\n ctx.strokeStyle = colorDepth(i * z, localOptions);\n ctx.moveTo(part[i > 0 ? i - 1 : 0][0], part[i > 0 ? i - 1 : 0][1]);\n ctx.lineTo(part[i][0], part[i][1]);\n ctx.stroke();\n }\n };\n ctx.lineWidth = localOptions.lineWidth;\n addHandLine(h.annotations.index);\n addHandLine(h.annotations.middle);\n addHandLine(h.annotations.ring);\n addHandLine(h.annotations.pinky);\n addHandLine(h.annotations.thumb);\n // addPart(h.annotations.palm);\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, rect, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { ObjectResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\n/** draw detected objects */\nexport function object(inCanvas: AnyCanvas, result: ObjectResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.lineJoin = 'round';\n ctx.font = localOptions.font;\n for (const h of result) {\n if (localOptions.drawBoxes) {\n ctx.strokeStyle = localOptions.color;\n ctx.fillStyle = localOptions.color;\n rect(ctx, h.box[0], h.box[1], h.box[2], h.box[3], localOptions);\n if (localOptions.drawLabels && (localOptions.objectLabels?.length > 0)) {\n let l = localOptions.objectLabels.slice();\n l = replace(l, '[id]', h.id.toFixed(0));\n l = replace(l, '[label]', h.label);\n l = replace(l, '[score]', 100 * h.score);\n labels(ctx, l, h.box[0], h.box[1], localOptions);\n }\n ctx.stroke();\n }\n }\n}\n", "import { mergeDeep } from '../util/util';\nimport { getCanvasContext, replace, labels } from './primitives';\nimport { options } from './options';\nimport type { GestureResult } from '../result';\nimport type { AnyCanvas, DrawOptions } from '../exports';\n\n/** draw detected gestures */\nexport function gesture(inCanvas: AnyCanvas, result: GestureResult[], drawOptions?: Partial) {\n const localOptions: DrawOptions = mergeDeep(options, drawOptions);\n if (!result || !inCanvas) return;\n if (localOptions.drawGestures && (localOptions.gestureLabels?.length > 0)) {\n const ctx = getCanvasContext(inCanvas) as CanvasRenderingContext2D;\n if (!ctx) return;\n ctx.font = localOptions.font;\n ctx.fillStyle = localOptions.color;\n let i = 1;\n for (let j = 0; j < result.length; j++) {\n const [where, what] = Object.entries(result[j]);\n if ((what.length > 1) && ((what[1] as string).length > 0)) {\n const who = where[1] as number > 0 ? `#${where[1]}` : '';\n let l = localOptions.gestureLabels.slice();\n l = replace(l, '[where]', where[0]);\n l = replace(l, '[who]', who);\n l = replace(l, '[what]', what[1]);\n labels(ctx, l, 8, 2 + (i * localOptions.lineHeight), localOptions);\n i += 1;\n }\n }\n }\n}\n", "export const defaultLabels = {\n face: `face\n confidence: [score]%\n [gender] [genderScore]%\n age: [age] years\n distance: [distance]cm\n real: [real]%\n live: [live]%\n [emotions]\n roll: [roll]\u00B0 yaw:[yaw]\u00B0 pitch:[pitch]\u00B0\n gaze: [gaze]\u00B0`,\n body: 'body [score]%',\n bodyPart: '[label] [score]%',\n object: '[label] [score]%',\n hand: '[label] [score]%',\n finger: '[label]',\n gesture: '[where] [who]: [what]',\n};\n", "/* eslint-disable no-multi-spaces */\n\nexport const kpt: string[] = [\n 'nose', // 0\n 'leftEyeInside', // 1\n 'leftEye', // 2\n 'leftEyeOutside', // 3\n 'rightEyeInside', // 4\n 'rightEye', // 5\n 'rightEyeOutside', // 6\n 'leftEar', // 7\n 'rightEar', // 8\n 'leftMouth', // 9\n 'rightMouth', // 10\n 'leftShoulder', // 11\n 'rightShoulder', // 12\n 'leftElbow', // 13\n 'rightElbow', // 14\n 'leftWrist', // 15\n 'rightWrist', // 16\n 'leftPinky', // 17\n 'rightPinky', // 18\n 'leftIndex', // 19\n 'rightIndex', // 20\n 'leftThumb', // 21\n 'rightThumb', // 22\n 'leftHip', // 23\n 'rightHip', // 24\n 'leftKnee', // 25\n 'rightKnee', // 26\n 'leftAnkle', // 27\n 'rightAnkle', // 28\n 'leftHeel', // 29\n 'rightHeel', // 30\n 'leftFoot', // 31\n 'rightFoot', // 32\n 'bodyCenter', // 33\n 'bodyTop', // 34\n 'leftPalm', // 35 // z-coord not ok\n 'leftHand', // 36 // similar to wrist but z-coord not ok\n 'rightPalm', // 37 // z-coord not ok\n 'rightHand', // 38 // similar to wrist but z-coord not ok\n];\n\nexport const connected: Record = {\n shoulders: ['leftShoulder', 'rightShoulder'],\n hips: ['rightHip', 'leftHip'],\n mouth: ['leftMouth', 'rightMouth'],\n leftLegUpper: ['leftHip', 'leftKnee'],\n leftLegLower: ['leftKnee', 'leftAnkle'],\n leftFoot: ['leftAnkle', 'leftHeel', 'leftFoot'],\n leftTorso: ['leftShoulder', 'leftHip'],\n leftArmUpper: ['leftShoulder', 'leftElbow'],\n leftArmLower: ['leftElbow', 'leftWrist'],\n leftHand: ['leftWrist', 'leftPalm'],\n leftHandPinky: ['leftPalm', 'leftPinky'],\n leftHandIndex: ['leftPalm', 'leftIndex'],\n leftHandThumb: ['leftPalm', 'leftThumb'],\n leftEyeOutline: ['leftEyeInside', 'leftEyeOutside'],\n rightLegUpper: ['rightHip', 'rightKnee'],\n rightLegLower: ['rightKnee', 'rightAnkle'],\n rightFoot: ['rightAnkle', 'rightHeel', 'rightFoot'],\n rightTorso: ['rightShoulder', 'rightHip'],\n rightArmUpper: ['rightShoulder', 'rightElbow'],\n rightArmLower: ['rightElbow', 'rightWrist'],\n rightHand: ['rightWrist', 'rightPalm'],\n rightHandPinky: ['rightPalm', 'rightPinky'],\n rightHandIndex: ['rightPalm', 'rightIndex'],\n rightHandThumb: ['rightPalm', 'rightThumb'],\n rightEyeOutline: ['rightEyeInside', 'rightEyeOutside'],\n};\n", "import * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { env } from '../util/env';\nimport { loadModel } from '../tfjs/load';\nimport type { Box } from '../result';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor1D, Tensor2D } from '../tfjs/types';\n\nexport interface DetectedBox { box: Box, boxRaw: Box, score: number }\n\nlet model: GraphModel | null;\nlet inputSize = 224;\nlet anchorTensor: { x, y };\nconst numLayers = 5;\nconst strides = [8, 16, 32, 32, 32];\n\nexport function createAnchors() {\n const anchors: { x: number, y: number }[] = [];\n let layerId = 0;\n while (layerId < numLayers) {\n let anchorCount = 0;\n let lastSameStrideLayer = layerId;\n while (lastSameStrideLayer < strides.length && strides[lastSameStrideLayer] === strides[layerId]) {\n anchorCount += 2;\n lastSameStrideLayer++;\n }\n const stride = strides[layerId];\n const featureMapHeight = Math.ceil(inputSize / stride);\n const featureMapWidth = Math.ceil(inputSize / stride);\n for (let y = 0; y < featureMapHeight; ++y) {\n for (let x = 0; x < featureMapWidth; ++x) {\n for (let anchorId = 0; anchorId < anchorCount; ++anchorId) {\n anchors.push({ x: (x + 0.5) / featureMapWidth, y: (y + 0.5) / featureMapHeight });\n }\n }\n }\n layerId = lastSameStrideLayer;\n }\n anchorTensor = { x: tf.tensor1d(anchors.map((a) => a.x)), y: tf.tensor1d(anchors.map((a) => a.y)) };\n}\n\nexport async function loadDetector(config: Config): Promise {\n if (env.initial) model = null;\n if (!model && config.body['detector'] && config.body['detector'].modelPath || '') {\n model = await loadModel(config.body['detector'].modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n } else if (config.debug && model) log('cached model:', model['modelUrl']);\n createAnchors();\n return model as GraphModel;\n}\n\nconst cropFactor = [5.0, 5.0];\nexport function decodeBoxes(boxesTensor, anchor) {\n return tf.tidy(() => {\n const split = tf.split(boxesTensor, 12, 1); // first 4 are box data [x,y,w,h] and 4 are keypoints data [x,y] for total of 12\n let xCenter = tf.squeeze(split[0]);\n let yCenter = tf.squeeze(split[1]);\n let width = tf.squeeze(split[2]);\n let height = tf.squeeze(split[3]);\n xCenter = tf.add(tf.div(xCenter, inputSize), anchor.x);\n yCenter = tf.add(tf.div(yCenter, inputSize), anchor.y);\n width = tf.mul(tf.div(width, inputSize), cropFactor[0]);\n height = tf.mul(tf.div(height, inputSize), cropFactor[1]);\n const xMin = tf.sub(xCenter, tf.div(width, 2));\n const yMin = tf.sub(yCenter, tf.div(height, 2));\n const xMax = tf.add(xMin, width);\n const yMax = tf.add(yMin, height);\n const boxes = tf.stack([xMin, yMin, xMax, yMax], 1);\n return boxes;\n });\n}\n\nasync function decodeResults(boxesTensor: Tensor, logitsTensor: Tensor, config: Config, outputSize: [number, number]): Promise {\n const detectedBoxes: DetectedBox[] = [];\n const t: Record = {};\n t.boxes = decodeBoxes(boxesTensor, anchorTensor);\n t.scores = tf.sigmoid(logitsTensor);\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.scores as Tensor1D, 1, config.body['detector']?.minConfidence || 0.1, config.body['detector']?.iouThreshold || 0.1);\n const nms = await t.nms.data();\n const scores = await t.scores.data();\n const boxes = await t.boxes.array();\n for (const i of Array.from(nms)) {\n const score = scores[i];\n const boxRaw: Box = boxes[i];\n const box: Box = [Math.round(boxRaw[0] * outputSize[0]), Math.round(boxRaw[1] * outputSize[1]), Math.round(boxRaw[2] * outputSize[0]), Math.round(boxRaw[3] * outputSize[1])];\n const detectedBox: DetectedBox = { score, boxRaw, box };\n detectedBoxes.push(detectedBox);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return detectedBoxes;\n}\n\nexport async function detectBoxes(input: Tensor, config: Config, outputSize: [number, number]) {\n const t: Record = {};\n t.res = model?.execute(input, ['Identity']) as Tensor; //\n t.logitsRaw = tf.slice(t.res, [0, 0, 0], [1, -1, 1]);\n t.boxesRaw = tf.slice(t.res, [0, 0, 1], [1, -1, -1]);\n t.logits = tf.squeeze(t.logitsRaw);\n t.boxes = tf.squeeze(t.boxesRaw);\n const boxes = await decodeResults(t.boxes, t.logits, config, outputSize);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return boxes;\n}\n", "import type { Point, Box } from '../result';\n\nexport function calc(keypoints: Point[], outputSize: [number, number] = [1, 1]) {\n const coords = [keypoints.map((pt) => pt[0]), keypoints.map((pt) => pt[1])]; // all x/y coords\n const min = [Math.min(...coords[0]), Math.min(...coords[1])];\n const max = [Math.max(...coords[0]), Math.max(...coords[1])];\n const box: Box = [min[0], min[1], max[0] - min[0], max[1] - min[1]];\n const boxRaw: Box = [box[0] / outputSize[0], box[1] / outputSize[1], box[2] / outputSize[0], box[3] / outputSize[1]];\n return { box, boxRaw };\n}\n\nexport function square(keypoints: Point[], outputSize: [number, number] = [1, 1]) {\n const coords = [keypoints.map((pt) => pt[0]), keypoints.map((pt) => pt[1])]; // all x/y coords\n const min = [Math.min(...coords[0]), Math.min(...coords[1])];\n const max = [Math.max(...coords[0]), Math.max(...coords[1])];\n const center = [(min[0] + max[0]) / 2, (min[1] + max[1]) / 2]; // find center x and y coord of all fingers\n const dist = Math.max(center[0] - min[0], center[1] - min[1], -center[0] + max[0], -center[1] + max[1]); // largest distance from center in any direction\n const box: Box = [Math.trunc(center[0] - dist), Math.trunc(center[1] - dist), Math.trunc(2 * dist), Math.trunc(2 * dist)];\n const boxRaw: Box = [box[0] / outputSize[0], box[1] / outputSize[1], box[2] / outputSize[0], box[3] / outputSize[1]];\n return { box, boxRaw };\n}\n\nexport function scale(box: Box, scaleFact: number) {\n const dist = [box[2] * scaleFact, box[3] * scaleFact];\n const newBox: Box = [\n box[0] - (dist[0] - box[2]) / 2,\n box[1] - (dist[1] - box[3]) / 2,\n dist[0],\n dist[1],\n ];\n return newBox;\n}\n\nexport function crop(box: Box) { // [y1, x1, y2, x2] clamped to 0..1\n const yxBox: Box = [Math.max(0, box[1]), Math.max(0, box[0]), Math.min(1, box[3] + box[1]), Math.min(1, box[2] + box[0])];\n return yxBox;\n}\n", "/**\n * BlazePose model implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport { log, now } from '../util/util';\nimport type { BodyKeypoint, BodyResult, BodyLandmark, Box, Point, BodyAnnotation } from '../result';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport * as coords from './blazeposecoords';\nimport { loadDetector, detectBoxes, DetectedBox } from './blazeposedetector';\nimport * as box from '../util/box';\nimport { env } from '../util/env';\n\n// const models: [GraphModel | null, GraphModel | null] = [null, null];\nlet model: GraphModel | null;\nlet inputSize = 256;\nlet skipped = Number.MAX_SAFE_INTEGER;\nconst outputNodes: { detector: string[], landmarks: string[] } = {\n landmarks: ['ld_3d', 'activation_segmentation', 'activation_heatmap', 'world_3d', 'output_poseflag'],\n detector: [],\n};\n\nconst cache: BodyResult[] = [];\nlet padding: [number, number][] = [[0, 0], [0, 0], [0, 0], [0, 0]];\nlet lastTime = 0;\n\nconst sigmoid = (x) => (1 - (1 / (1 + Math.exp(x))));\n\nexport const loadDetect = (config: Config): Promise => loadDetector(config);\n\nexport async function loadPose(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n model = await loadModel(config.body.modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n } else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nfunction prepareImage(input: Tensor4D, size: number, cropBox?: Box): Tensor {\n const t: Record = {};\n if (!input?.shape?.[1] || !input?.shape?.[2]) return input;\n let final: Tensor;\n if (cropBox) {\n t.cropped = tf.image.cropAndResize(input, [cropBox], [0], [input.shape[1], input.shape[2]]); // if we have cached box use it to crop input\n }\n if (input.shape[1] !== input.shape[2]) { // only pad if width different than height\n const height: [number, number] = [\n input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0,\n input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0,\n ];\n const width: [number, number] = [\n input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0,\n input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0,\n ];\n padding = [\n [0, 0], // dont touch batch\n height, // height before&after\n width, // width before&after\n [0, 0], // dont touch rbg\n ];\n t.pad = tf.pad(t.cropped || input, padding); // use cropped box if it exists\n t.resize = tf.image.resizeBilinear(t.pad as Tensor4D, [size, size]);\n final = tf.div(t.resize, constants.tf255);\n } else if (input.shape[1] !== size) { // if input needs resizing\n t.resize = tf.image.resizeBilinear(t.cropped as Tensor4D || input, [size, size]);\n final = tf.div(t.resize, constants.tf255);\n } else { // if input is already in a correct resolution just normalize it\n final = tf.div(t.cropped || input, constants.tf255);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return final;\n}\n\nfunction rescaleKeypoints(keypoints: BodyKeypoint[], outputSize: [number, number], cropBox?: Box): BodyKeypoint[] {\n for (const kpt of keypoints) { // first rescale due to padding\n kpt.position = [\n Math.trunc(kpt.position[0] * (outputSize[0] + padding[2][0] + padding[2][1]) / outputSize[0] - padding[2][0]),\n Math.trunc(kpt.position[1] * (outputSize[1] + padding[1][0] + padding[1][1]) / outputSize[1] - padding[1][0]),\n kpt.position[2] as number,\n ];\n kpt.positionRaw = [kpt.position[0] / outputSize[0], kpt.position[1] / outputSize[1], 2 * (kpt.position[2] as number) / (outputSize[0] + outputSize[1])];\n }\n if (cropBox) { // second rescale due to cropping\n const width = cropBox[2] - cropBox[0];\n const height = cropBox[3] - cropBox[1];\n for (const kpt of keypoints) {\n kpt.positionRaw = [\n kpt.positionRaw[0] / height + cropBox[1], // correct offset due to crop\n kpt.positionRaw[1] / width + cropBox[0], // correct offset due to crop\n kpt.positionRaw[2] as number,\n ];\n kpt.position = [\n Math.trunc(kpt.positionRaw[0] * outputSize[0]),\n Math.trunc(kpt.positionRaw[1] * outputSize[1]),\n kpt.positionRaw[2] as number,\n ];\n }\n }\n return keypoints;\n}\n\nfunction fixKeypoints(keypoints: BodyKeypoint[]) {\n // palm z-coord is incorrect around near-zero so we approximate it\n const leftPalm = keypoints.find((k) => k.part === 'leftPalm') as BodyKeypoint;\n const leftWrist = keypoints.find((k) => k.part === 'leftWrist') as BodyKeypoint;\n const leftIndex = keypoints.find((k) => k.part === 'leftIndex') as BodyKeypoint;\n leftPalm.position[2] = ((leftWrist.position[2] || 0) + (leftIndex.position[2] || 0)) / 2;\n const rightPalm = keypoints.find((k) => k.part === 'rightPalm') as BodyKeypoint;\n const rightWrist = keypoints.find((k) => k.part === 'rightWrist') as BodyKeypoint;\n const rightIndex = keypoints.find((k) => k.part === 'rightIndex') as BodyKeypoint;\n rightPalm.position[2] = ((rightWrist.position[2] || 0) + (rightIndex.position[2] || 0)) / 2;\n}\n\nasync function detectLandmarks(input: Tensor, config: Config, outputSize: [number, number]): Promise {\n /**\n * t.ld: 39 keypoints [x,y,z,score,presence] normalized to input size\n * t.segmentation:\n * t.heatmap:\n * t.world: 39 keypoints [x,y,z] normalized to -1..1\n * t.poseflag: body score\n */\n if (!model?.['executor']) return null;\n const t: Record = {};\n [t.ld/* 1,195(39*5) */, t.segmentation/* 1,256,256,1 */, t.heatmap/* 1,64,64,39 */, t.world/* 1,117(39*3) */, t.poseflag/* 1,1 */] = model?.execute(input, outputNodes.landmarks) as Tensor[]; // run model\n const poseScore = (await t.poseflag.data())[0];\n const points = await t.ld.data();\n const distances = await t.world.data();\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor])); // dont need tensors after this\n const keypointsRelative: BodyKeypoint[] = [];\n const depth = 5; // each points has x,y,z,visibility,presence\n for (let i = 0; i < points.length / depth; i++) {\n const score = sigmoid(points[depth * i + 3]);\n const presence = sigmoid(points[depth * i + 4]);\n const adjScore = Math.trunc(100 * score * presence * poseScore) / 100;\n const positionRaw: Point = [points[depth * i + 0] / inputSize, points[depth * i + 1] / inputSize, points[depth * i + 2] + 0];\n const position: Point = [Math.trunc(outputSize[0] * positionRaw[0]), Math.trunc(outputSize[1] * positionRaw[1]), positionRaw[2] as number];\n const distance: Point = [distances[depth * i + 0], distances[depth * i + 1], distances[depth * i + 2] + 0];\n keypointsRelative.push({ part: coords.kpt[i] as BodyLandmark, positionRaw, position, distance, score: adjScore });\n }\n if (poseScore < (config.body.minConfidence || 0)) return null;\n fixKeypoints(keypointsRelative);\n const keypoints: BodyKeypoint[] = rescaleKeypoints(keypointsRelative, outputSize); // keypoints were relative to input image which is padded\n const kpts = keypoints.map((k) => k.position);\n const boxes = box.calc(kpts, [outputSize[0], outputSize[1]]); // now find boxes based on rescaled keypoints\n const annotations: Record = {} as Record;\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = keypoints.find((kpt) => kpt.part === indexes[i]);\n const pt1 = keypoints.find((kpt) => kpt.part === indexes[i + 1]);\n if (pt0 && pt1) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n const body = { id: 0, score: Math.trunc(100 * poseScore) / 100, box: boxes.box, boxRaw: boxes.boxRaw, keypoints, annotations };\n return body;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n const outputSize: [number, number] = [input.shape[2] || 0, input.shape[1] || 0];\n const skipTime = (config.body.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.body.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && cache !== null) {\n skipped++;\n } else {\n let boxes: DetectedBox[] = [];\n if (config.body?.['detector']?.['enabled']) {\n const preparedImage = prepareImage(input, 224);\n boxes = await detectBoxes(preparedImage, config, outputSize);\n tf.dispose(preparedImage);\n } else {\n boxes = [{ box: [0, 0, 0, 0] as Box, boxRaw: [0, 0, 1, 1], score: 0 }]; // running without detector\n }\n for (let i = 0; i < boxes.length; i++) {\n const preparedBox = prepareImage(input, 256, boxes[i]?.boxRaw); // padded and resized\n cache.length = 0;\n const bodyResult = await detectLandmarks(preparedBox, config, outputSize);\n tf.dispose(preparedBox);\n if (!bodyResult) continue;\n bodyResult.id = i;\n // bodyResult.score = 0; // TBD\n cache.push(bodyResult);\n }\n /*\n cropBox = [0, 0, 1, 1]; // reset crop coordinates\n if (cache?.boxRaw && config.skipAllowed) {\n const cx = (2.0 * cache.boxRaw[0] + cache.boxRaw[2]) / 2;\n const cy = (2.0 * cache.boxRaw[1] + cache.boxRaw[3]) / 2;\n let size = cache.boxRaw[2] > cache.boxRaw[3] ? cache.boxRaw[2] : cache.boxRaw[3];\n size = (size * 1.0) / 2; // enlarge and half it\n if (cx > 0.1 && cx < 0.9 && cy > 0.1 && cy < 0.9 && size > 0.1) { // only update if box is sane\n const y = 0; // cy - size;\n const x = cx - size;\n cropBox = [y, x, y + 1, x + 1]; // [y0,x0,y1,x1] used for cropping but width/height are not yet implemented so we only reposition image to center of body\n }\n }\n */\n lastTime = now();\n skipped = 0;\n }\n return cache;\n}\n", "/**\n * CoCo Labels used by object detection implementations\n */\nexport const labels = [\n { class: 1, label: 'person' },\n { class: 2, label: 'bicycle' },\n { class: 3, label: 'car' },\n { class: 4, label: 'motorcycle' },\n { class: 5, label: 'airplane' },\n { class: 6, label: 'bus' },\n { class: 7, label: 'train' },\n { class: 8, label: 'truck' },\n { class: 9, label: 'boat' },\n { class: 10, label: 'traffic light' },\n { class: 11, label: 'fire hydrant' },\n { class: 12, label: 'stop sign' },\n { class: 13, label: 'parking meter' },\n { class: 14, label: 'bench' },\n { class: 15, label: 'bird' },\n { class: 16, label: 'cat' },\n { class: 17, label: 'dog' },\n { class: 18, label: 'horse' },\n { class: 19, label: 'sheep' },\n { class: 20, label: 'cow' },\n { class: 21, label: 'elephant' },\n { class: 22, label: 'bear' },\n { class: 23, label: 'zebra' },\n { class: 24, label: 'giraffe' },\n { class: 25, label: 'backpack' },\n { class: 26, label: 'umbrella' },\n { class: 27, label: 'handbag' },\n { class: 28, label: 'tie' },\n { class: 29, label: 'suitcase' },\n { class: 30, label: 'frisbee' },\n { class: 31, label: 'skis' },\n { class: 32, label: 'snowboard' },\n { class: 33, label: 'sports ball' },\n { class: 34, label: 'kite' },\n { class: 35, label: 'baseball bat' },\n { class: 36, label: 'baseball glove' },\n { class: 37, label: 'skateboard' },\n { class: 38, label: 'surfboard' },\n { class: 39, label: 'tennis racket' },\n { class: 40, label: 'bottle' },\n { class: 41, label: 'wine glass' },\n { class: 42, label: 'cup' },\n { class: 43, label: 'fork' },\n { class: 44, label: 'knife' },\n { class: 45, label: 'spoon' },\n { class: 46, label: 'bowl' },\n { class: 47, label: 'banana' },\n { class: 48, label: 'apple' },\n { class: 49, label: 'sandwich' },\n { class: 50, label: 'orange' },\n { class: 51, label: 'broccoli' },\n { class: 52, label: 'carrot' },\n { class: 53, label: 'hot dog' },\n { class: 54, label: 'pizza' },\n { class: 55, label: 'donut' },\n { class: 56, label: 'cake' },\n { class: 57, label: 'chair' },\n { class: 58, label: 'couch' },\n { class: 59, label: 'potted plant' },\n { class: 60, label: 'bed' },\n { class: 61, label: 'dining table' },\n { class: 62, label: 'toilet' },\n { class: 63, label: 'tv' },\n { class: 64, label: 'laptop' },\n { class: 65, label: 'mouse' },\n { class: 66, label: 'remote' },\n { class: 67, label: 'keyboard' },\n { class: 68, label: 'cell phone' },\n { class: 69, label: 'microwave' },\n { class: 70, label: 'oven' },\n { class: 71, label: 'toaster' },\n { class: 72, label: 'sink' },\n { class: 73, label: 'refrigerator' },\n { class: 74, label: 'book' },\n { class: 75, label: 'clock' },\n { class: 76, label: 'vase' },\n { class: 77, label: 'scissors' },\n { class: 78, label: 'teddy bear' },\n { class: 79, label: 'hair drier' },\n { class: 80, label: 'toothbrush' },\n];\n", "/**\n * CenterNet object detection model implementation\n *\n * Based on: [**MB3-CenterNet**](https://github.com/610265158/mobilenetv3_centernet)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { labels } from './labels';\nimport type { ObjectResult, ObjectType, Box } from '../result';\nimport type { GraphModel, Tensor, Tensor1D, Tensor2D, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nlet inputSize = 0;\nlet last: ObjectResult[] = [];\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n // fakeOps(['floormod'], config);\n model = await loadModel(config.object.modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 0;\n } else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nasync function process(res: Tensor | null, outputShape: [number, number], config: Config) {\n if (!res) return [];\n const t: Record = {};\n const results: ObjectResult[] = [];\n const detections = await res.array() as number[][][];\n t.squeeze = tf.squeeze(res);\n const arr = tf.split(t.squeeze, 6, 1); // x1, y1, x2, y2, score, class\n t.stack = tf.stack([arr[1], arr[0], arr[3], arr[2]], 1); // reorder dims as tf.nms expects y, x\n t.boxes = tf.squeeze(t.stack);\n t.scores = tf.squeeze(arr[4]);\n t.classes = tf.squeeze(arr[5]);\n tf.dispose([res, ...arr]);\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.scores as Tensor1D, config.object.maxDetected || 0, config.object.iouThreshold, (config.object.minConfidence || 0));\n const nms = await t.nms.data();\n let i = 0;\n for (const id of Array.from(nms)) {\n const score = Math.trunc(100 * detections[0][id][4]) / 100;\n const classVal = detections[0][id][5];\n if (Number.isNaN(classVal)) continue;\n const label = labels[classVal].label as ObjectType;\n const [x, y] = [\n detections[0][id][0] / inputSize,\n detections[0][id][1] / inputSize,\n ];\n const boxRaw: Box = [\n x,\n y,\n detections[0][id][2] / inputSize - x,\n detections[0][id][3] / inputSize - y,\n ];\n const box: Box = [\n Math.trunc(boxRaw[0] * outputShape[0]),\n Math.trunc(boxRaw[1] * outputShape[1]),\n Math.trunc(boxRaw[2] * outputShape[0]),\n Math.trunc(boxRaw[3] * outputShape[1]),\n ];\n results.push({ id: i++, score, class: classVal, label, box, boxRaw });\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return results;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model?.['executor']) return [];\n const skipTime = (config.object.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.object.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (last.length > 0)) {\n skipped++;\n return last;\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const outputSize = [input.shape[2] || 0, input.shape[1] || 0] as [number, number];\n const resize = tf.image.resizeBilinear(input, [inputSize, inputSize]);\n const objectT = config.object.enabled ? model?.execute(resize, ['tower_0/detections']) as Tensor : null;\n lastTime = now();\n tf.dispose(resize);\n\n const obj = await process(objectT, outputSize, config);\n last = obj;\n\n resolve(obj);\n });\n}\n", "export const kpt: string[] = [\n 'head',\n 'neck',\n 'rightShoulder',\n 'rightElbow',\n 'rightWrist',\n 'chest',\n 'leftShoulder',\n 'leftElbow',\n 'leftWrist',\n 'bodyCenter',\n 'rightHip',\n 'rightKnee',\n 'rightAnkle',\n 'leftHip',\n 'leftKnee',\n 'leftAnkle',\n];\n\nexport const connected: Record = {\n leftLeg: ['leftHip', 'leftKnee', 'leftAnkle'],\n rightLeg: ['rightHip', 'rightKnee', 'rightAnkle'],\n torso: ['leftShoulder', 'rightShoulder', 'rightHip', 'leftHip', 'leftShoulder'],\n leftArm: ['leftShoulder', 'leftElbow', 'leftWrist'],\n rightArm: ['rightShoulder', 'rightElbow', 'rightWrist'],\n head: [],\n};\n", "/**\n * EfficientPose model implementation\n *\n * Based on: [**EfficientPose**](https://github.com/daniegr/EfficientPose)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport * as coords from './efficientposecoords';\nimport { constants } from '../tfjs/constants';\nimport type { BodyResult, Point, BodyLandmark, BodyAnnotation } from '../result';\nimport type { GraphModel, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nlet lastTime = 0;\nconst cache: BodyResult = { id: 0, keypoints: [], box: [0, 0, 0, 0], boxRaw: [0, 0, 0, 0], score: 0, annotations: {} as Record };\n\n// const keypoints: Array = [];\n// let box: Box = [0, 0, 0, 0];\n// let boxRaw: Box = [0, 0, 0, 0];\n// let score = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.body.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\n// performs argmax and max functions on a 2d tensor\nasync function max2d(inputs, minScore): Promise<[number, number, number]> {\n const [width, height] = inputs.shape;\n const reshaped = tf.reshape(inputs, [height * width]); // combine all data\n const max = tf.max(reshaped, 0);\n const newScore: number = (await max.data())[0]; // get highest score\n if (newScore > minScore) { // skip coordinate calculation is score is too low\n const coordinates = tf.argMax(reshaped, 0);\n const mod = tf.mod(coordinates, width);\n const x = (await mod.data())[0];\n const div = tf.div(coordinates, width);\n const y: number = (await div.data())[0];\n tf.dispose([reshaped, max, coordinates, mod, div]);\n return [x, y, newScore];\n }\n tf.dispose([reshaped, max]);\n return [0, 0, newScore];\n}\n\nexport async function predict(image: Tensor4D, config: Config): Promise {\n if (!model?.['executor'] || !model?.inputs[0].shape) return [];\n const skipTime = (config.body.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.body.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && Object.keys(cache.keypoints).length > 0) {\n skipped++;\n return [cache];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const tensor = tf.tidy(() => {\n const resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape?.[2] || 0, model?.inputs[0].shape?.[1] || 0], false);\n const enhance = tf.mul(resize, constants.tf2);\n const norm = tf.sub(enhance, constants.tf1);\n return norm;\n });\n let resT;\n if (config.body.enabled) resT = model?.execute(tensor);\n lastTime = now();\n tf.dispose(tensor);\n\n if (resT) {\n cache.keypoints.length = 0;\n const squeeze = tf.squeeze(resT);\n tf.dispose(resT);\n // body parts are basically just a stack of 2d tensors\n const stack = tf.unstack(squeeze, 2);\n tf.dispose(squeeze);\n\n // process each unstacked tensor as a separate body part\n for (let id = 0; id < stack.length; id++) {\n // actual processing to get coordinates and score\n const [x, y, partScore] = await max2d(stack[id], config.body.minConfidence);\n if (partScore > (config.body.minConfidence || 0)) {\n cache.keypoints.push({\n score: Math.round(100 * partScore) / 100,\n part: coords.kpt[id] as BodyLandmark,\n positionRaw: [ // normalized to 0..1\n // @ts-ignore model is not undefined here\n x / model.inputs[0].shape[2], y / model.inputs[0].shape[1],\n ],\n position: [ // normalized to input image size\n // @ts-ignore model is not undefined here\n Math.round(image.shape[2] * x / model.inputs[0].shape[2]), Math.round(image.shape[1] * y / model.inputs[0].shape[1]),\n ],\n });\n }\n }\n stack.forEach((s) => tf.dispose(s));\n }\n cache.score = cache.keypoints.reduce((prev, curr) => (curr.score > prev ? curr.score : prev), 0);\n const x = cache.keypoints.map((a) => a.position[0]);\n const y = cache.keypoints.map((a) => a.position[1]);\n cache.box = [\n Math.min(...x),\n Math.min(...y),\n Math.max(...x) - Math.min(...x),\n Math.max(...y) - Math.min(...y),\n ];\n const xRaw = cache.keypoints.map((a) => a.positionRaw[0]);\n const yRaw = cache.keypoints.map((a) => a.positionRaw[1]);\n cache.boxRaw = [\n Math.min(...xRaw),\n Math.min(...yRaw),\n Math.max(...xRaw) - Math.min(...xRaw),\n Math.max(...yRaw) - Math.min(...yRaw),\n ];\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = cache.keypoints.find((kpt) => kpt.part === indexes[i]);\n const pt1 = cache.keypoints.find((kpt) => kpt.part === indexes[i + 1]);\n if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n }\n cache.annotations[name] = pt;\n }\n resolve([cache]);\n });\n}\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n * See `facemesh.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as coords from './facemeshcoords';\nimport { constants } from '../tfjs/constants';\nimport type { Box, Point } from '../result';\nimport { env } from '../util/env';\n\nexport const createBox = (startEndTensor) => ({ startPoint: tf.slice(startEndTensor, [0, 0], [-1, 2]), endPoint: tf.slice(startEndTensor, [0, 2], [-1, 2]) });\n\nexport const disposeBox = (t) => tf.dispose([t.startPoint, t.endPoint]);\n\nexport const getBoxSize = (box): [number, number] => [Math.abs(box.endPoint[0] - box.startPoint[0]), Math.abs(box.endPoint[1] - box.startPoint[1])];\n\nexport const getBoxCenter = (box): [number, number, number] => [box.startPoint[0] + (box.endPoint[0] - box.startPoint[0]) / 2, box.startPoint[1] + (box.endPoint[1] - box.startPoint[1]) / 2, 1];\n\nexport const clampBox = (box, input): Box => (box ? [\n Math.trunc(Math.max(0, box.startPoint[0])),\n Math.trunc(Math.max(0, box.startPoint[1])),\n Math.trunc(Math.min((input.shape[2] || 0), box.endPoint[0]) - Math.max(0, box.startPoint[0])),\n Math.trunc(Math.min((input.shape[1] || 0), box.endPoint[1]) - Math.max(0, box.startPoint[1])),\n] : [0, 0, 0, 0]);\n\nexport const getRawBox = (box, input): Box => (box ? [\n box.startPoint[0] / (input.shape[2] || 0),\n box.startPoint[1] / (input.shape[1] || 0),\n (box.endPoint[0] - box.startPoint[0]) / (input.shape[2] || 0),\n (box.endPoint[1] - box.startPoint[1]) / (input.shape[1] || 0),\n] : [0, 0, 0, 0]);\n\nexport const scaleBoxCoordinates = (box, factor, anchor) => {\n const startPoint: Point = [box.startPoint[0] * factor[0], box.startPoint[1] * factor[1]];\n const endPoint: Point = [box.endPoint[0] * factor[0], box.endPoint[1] * factor[1]];\n // const centerPoint = [(startPoint[0] + endPoint[0]) / 2, (startPoint[1] + endPoint[1]) / 2];\n const landmarks = box.landmarks.map((pt) => [(pt[0] + anchor[0]) * factor[0], (pt[1] + anchor[1]) * factor[1]]);\n /**\n face.mesh = box.landmarks.map((pt) => [\n ((box.startPoint[0] + box.endPoint[0]) / 2) + (pt[0] * input.shape[2] / blazeface.size()),\n ((box.startPoint[1] + box.endPoint[1]) / 2) + (pt[1] * input.shape[1] / blazeface.size()),\n ]);\n */\n\n return { startPoint, endPoint, landmarks, confidence: box.confidence };\n};\n\nexport const cutAndResize = (box, image, cropSize) => {\n const h = image.shape[1];\n const w = image.shape[2];\n const cutBox = [box.startPoint[1] / h, box.startPoint[0] / w, box.endPoint[1] / h, box.endPoint[0] / w];\n const crop = tf.image.cropAndResize(image, [cutBox], [0], cropSize);\n const norm = tf.div(crop, constants.tf255);\n tf.dispose(crop);\n return norm;\n};\n\nexport const enlargeBox = (box, factor) => {\n const center = getBoxCenter(box);\n const size = getBoxSize(box);\n const halfSize: [number, number] = [factor * size[0] / 2, factor * size[1] / 2];\n return {\n startPoint: [center[0] - halfSize[0], center[1] - halfSize[1]] as Point,\n endPoint: [center[0] + halfSize[0], center[1] + halfSize[1]] as Point,\n landmarks: box.landmarks,\n confidence: box.confidence,\n size,\n };\n};\n\nexport const squarifyBox = (box) => {\n const centers = getBoxCenter(box);\n const size = getBoxSize(box);\n const halfSize = Math.max(...size) / 2;\n return {\n startPoint: [Math.round(centers[0] - halfSize), Math.round(centers[1] - halfSize)] as Point,\n endPoint: [Math.round(centers[0] + halfSize), Math.round(centers[1] + halfSize)] as Point,\n landmarks: box.landmarks,\n confidence: box.confidence,\n size: [Math.round(size[0]), Math.round(size[1])] as [number, number],\n };\n};\n\nexport const calculateLandmarksBoundingBox = (landmarks) => {\n const x = landmarks.map((d) => d[0]);\n const y = landmarks.map((d) => d[1]);\n return {\n startPoint: [Math.min(...x), Math.min(...y)] as Point,\n endPoint: [Math.max(...x), Math.max(...y)] as Point,\n landmarks,\n };\n};\n\nexport const fixedRotationMatrix = [[1, 0, 0], [0, 1, 0], [0, 0, 1]];\n\nexport const normalizeRadians = (angle: number) => angle - 2 * Math.PI * Math.floor((angle + Math.PI) / (2 * Math.PI));\n\nexport const computeRotation = (point1, point2) => normalizeRadians(Math.PI / 2 - Math.atan2(-(point2[1] - point1[1]), point2[0] - point1[0]));\n\nexport const radToDegrees = (rad) => rad * 180 / Math.PI;\n\nexport const buildTranslationMatrix = (x, y) => [[1, 0, x], [0, 1, y], [0, 0, 1]];\n\nexport const dot = (v1: number[], v2: number[]) => {\n let product = 0;\n for (let i = 0; i < v1.length; i++) product += v1[i] * v2[i];\n return product;\n};\n\nexport const getColumnFrom2DArr = (arr, columnIndex) => {\n const column: number[] = [];\n for (let i = 0; i < arr.length; i++) column.push(arr[i][columnIndex]);\n return column;\n};\n\nexport const multiplyTransformMatrices = (mat1, mat2) => {\n const product: number[][] = [];\n const size = mat1.length;\n for (let row = 0; row < size; row++) {\n product.push([]);\n for (let col = 0; col < size; col++) product[row].push(dot(mat1[row], getColumnFrom2DArr(mat2, col)));\n }\n return product;\n};\n\nexport const buildRotationMatrix = (rotation, center) => {\n const cosA = Math.cos(rotation);\n const sinA = Math.sin(rotation);\n const rotationMatrix = [[cosA, -sinA, 0], [sinA, cosA, 0], [0, 0, 1]];\n const translationMatrix = buildTranslationMatrix(center[0], center[1]);\n const translationTimesRotation = multiplyTransformMatrices(translationMatrix, rotationMatrix);\n const negativeTranslationMatrix = buildTranslationMatrix(-center[0], -center[1]);\n return multiplyTransformMatrices(translationTimesRotation, negativeTranslationMatrix);\n};\n\nexport const invertTransformMatrix = (matrix) => {\n const rotationComponent = [[matrix[0][0], matrix[1][0]], [matrix[0][1], matrix[1][1]]];\n const translationComponent = [matrix[0][2], matrix[1][2]];\n const invertedTranslation = [-dot(rotationComponent[0], translationComponent), -dot(rotationComponent[1], translationComponent)];\n return [rotationComponent[0].concat(invertedTranslation[0]), rotationComponent[1].concat(invertedTranslation[1]), [0, 0, 1]];\n};\n\nexport const rotatePoint = (homogeneousCoordinate, rotationMatrix) => [dot(homogeneousCoordinate, rotationMatrix[0]), dot(homogeneousCoordinate, rotationMatrix[1])];\n\nexport const xyDistanceBetweenPoints = (a, b) => Math.sqrt(((a[0] - b[0]) ** 2) + ((a[1] - b[1]) ** 2));\n\nexport function generateAnchors(inputSize: number) {\n const spec = inputSize === 192\n ? { strides: [4], anchors: [1] } // facemesh-detector\n : { strides: [inputSize / 16, inputSize / 8], anchors: [2, 6] }; // blazeface\n const anchors: [number, number][] = [];\n for (let i = 0; i < spec.strides.length; i++) {\n const stride = spec.strides[i];\n const gridRows = Math.floor((inputSize + stride - 1) / stride);\n const gridCols = Math.floor((inputSize + stride - 1) / stride);\n const anchorsNum = spec.anchors[i];\n for (let gridY = 0; gridY < gridRows; gridY++) {\n const anchorY = stride * (gridY + 0.5);\n for (let gridX = 0; gridX < gridCols; gridX++) {\n const anchorX = stride * (gridX + 0.5);\n for (let n = 0; n < anchorsNum; n++) anchors.push([anchorX, anchorY]);\n }\n }\n }\n return anchors;\n}\n\nexport function transformRawCoords(coordsRaw, box, angle, rotationMatrix, inputSize) {\n const boxSize = getBoxSize(box);\n const coordsScaled = coordsRaw.map((coord) => ([ // scaled around zero-point\n (boxSize[0] / inputSize) * (coord[0] - (inputSize / 2)),\n (boxSize[1] / inputSize) * (coord[1] - (inputSize / 2)),\n (coord[2] || 0),\n ]));\n const largeAngle = angle && (angle !== 0) && (Math.abs(angle) > 0.2);\n const coordsRotationMatrix = largeAngle ? buildRotationMatrix(angle, [0, 0]) : fixedRotationMatrix;\n const coordsRotated = largeAngle ? coordsScaled.map((coord) => ([...rotatePoint(coord, coordsRotationMatrix), coord[2]])) : coordsScaled;\n const inverseRotationMatrix = largeAngle ? invertTransformMatrix(rotationMatrix) : fixedRotationMatrix;\n const boxCenter = getBoxCenter(box);\n const offsets = [dot(boxCenter, inverseRotationMatrix[0]), dot(boxCenter, inverseRotationMatrix[1])];\n return coordsRotated.map((coord) => ([\n Math.trunc(coord[0] + offsets[0]),\n Math.trunc(coord[1] + offsets[1]),\n Math.trunc(coord[2] || 0),\n ]));\n}\n\nexport function correctFaceRotation(rotate, box, input, inputSize) {\n const symmetryLine = (box.landmarks.length >= coords.meshLandmarks.count)\n ? coords.meshLandmarks.symmetryLine\n : coords.blazeFaceLandmarks.symmetryLine;\n let angle = 0; // default\n let rotationMatrix = fixedRotationMatrix; // default\n let face; // default\n\n if (rotate && env.kernels.includes('rotatewithoffset')) {\n angle = computeRotation(box.landmarks[symmetryLine[0]], box.landmarks[symmetryLine[1]]);\n const largeAngle = angle && (angle !== 0) && (Math.abs(angle) > 0.2);\n if (largeAngle) { // perform rotation only if angle is sufficiently high\n const center: Point = getBoxCenter(box);\n const centerRaw: Point = [center[0] / input.shape[2], center[1] / input.shape[1]];\n const rotated = tf.image.rotateWithOffset(input, angle, 0, [centerRaw[0], centerRaw[1]]);\n rotationMatrix = buildRotationMatrix(-angle, center);\n face = cutAndResize(box, rotated, [inputSize, inputSize]);\n tf.dispose(rotated);\n } else {\n face = cutAndResize(box, input, [inputSize, inputSize]);\n }\n } else {\n face = cutAndResize(box, input, [inputSize, inputSize]);\n }\n return [angle, rotationMatrix, face];\n}\n\nexport const findFaceCenter = (mesh) => {\n const x = mesh.map((m) => m[0]);\n const y = mesh.map((m) => m[1]);\n // weighted center\n /*\n const sum = (arr: number[]) => arr.reduce((prev, curr) => prev + curr, 0);\n return [sum(x) / mesh.length, sum(y) / mesh.length];\n */\n // absolute center\n return [Math.min(...x) + (Math.max(...x) - Math.min(...x)) / 2, Math.min(...y) + (Math.max(...y) - Math.min(...y)) / 2];\n};\n\nexport const calculateFaceBox = (mesh, previousBox) => {\n const center = findFaceCenter(mesh);\n const boxSize = getBoxSize(previousBox);\n const calculatedBox = {\n startPoint: [center[0] - boxSize[0] / 2, center[1] - boxSize[1] / 2] as Point,\n endPoint: [center[0] + boxSize[0] / 2, center[1] + boxSize[1] / 2] as Point,\n };\n return calculatedBox;\n};\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n * See `facemesh.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport * as util from './facemeshutil';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { Config } from '../config';\nimport type { Tensor, GraphModel, Tensor1D, Tensor2D, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\nimport type { Point } from '../result';\n\nconst keypointsCount = 6;\nconst faceBoxScaleFactor = 1.4;\nlet model: GraphModel | null;\nlet anchors: Tensor | null = null;\nlet inputSize = 0;\nlet inputSizeT: Tensor | null = null;\n\nexport interface DetectBox { startPoint: Point, endPoint: Point, landmarks: Point[], confidence: number, size: [number, number] }\n\nexport const size = () => inputSize;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.detector?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n inputSize = (model['executor'] && model.inputs[0].shape) ? model.inputs[0].shape[2] : 256;\n inputSizeT = tf.scalar(inputSize, 'int32') as Tensor;\n anchors = tf.tensor2d(util.generateAnchors(inputSize)) as Tensor;\n return model;\n}\n\nfunction decodeBoxes(boxOutputs: Tensor) {\n if (!anchors || !inputSizeT) return tf.zeros([0, 0]);\n const t: Record = {};\n t.boxStarts = tf.slice(boxOutputs, [0, 1], [-1, 2]);\n t.centers = tf.add(t.boxStarts, anchors);\n t.boxSizes = tf.slice(boxOutputs, [0, 3], [-1, 2]);\n t.boxSizesNormalized = tf.div(t.boxSizes, inputSizeT);\n t.centersNormalized = tf.div(t.centers, inputSizeT);\n t.halfBoxSize = tf.div(t.boxSizesNormalized, constants.tf2);\n t.starts = tf.sub(t.centersNormalized, t.halfBoxSize);\n t.ends = tf.add(t.centersNormalized, t.halfBoxSize);\n t.startNormalized = tf.mul(t.starts, inputSizeT);\n t.endNormalized = tf.mul(t.ends, inputSizeT);\n const boxes = tf.concat2d([t.startNormalized as Tensor2D, t.endNormalized as Tensor2D], 1);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return boxes;\n}\n\nexport async function getBoxes(inputImage: Tensor4D, config: Config): Promise {\n // sanity check on input\n if ((!inputImage) || (inputImage['isDisposedInternal']) || (inputImage.shape.length !== 4) || (inputImage.shape[1] < 1) || (inputImage.shape[2] < 1)) return [];\n const t: Record = {};\n t.resized = tf.image.resizeBilinear(inputImage, [inputSize, inputSize]);\n t.div = tf.div(t.resized, constants.tf127);\n t.normalized = tf.sub(t.div, constants.tf05);\n const res = model?.execute(t.normalized) as Tensor[];\n if (Array.isArray(res) && res.length > 2) { // pinto converted model?\n const sorted = res.sort((a, b) => a.size - b.size);\n t.concat384 = tf.concat([sorted[0], sorted[2]], 2); // dim: 384, 1 + 16\n t.concat512 = tf.concat([sorted[1], sorted[3]], 2); // dim: 512, 1 + 16\n t.concat = tf.concat([t.concat512, t.concat384], 1);\n t.batch = tf.squeeze(t.concat, [0]);\n } else if (Array.isArray(res)) { // new facemesh-detection tfhub model\n t.batch = tf.squeeze(res[0]);\n } else { // original blazeface tfhub model\n t.batch = tf.squeeze(res);\n }\n tf.dispose(res);\n t.boxes = decodeBoxes(t.batch);\n t.logits = tf.slice(t.batch, [0, 0], [-1, 1]);\n t.sigmoid = tf.sigmoid(t.logits);\n t.scores = tf.squeeze(t.sigmoid);\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.scores as Tensor1D, (config.face.detector?.maxDetected || 0), (config.face.detector?.iouThreshold || 0), (config.face.detector?.minConfidence || 0));\n const nms = await t.nms.array() as number[];\n const boxes: DetectBox[] = [];\n const scores = await t.scores.data();\n for (let i = 0; i < nms.length; i++) {\n const confidence = scores[nms[i]];\n\n if (confidence > (config.face.detector?.minConfidence || 0)) {\n const b: Record = {};\n b.bbox = tf.slice(t.boxes, [nms[i], 0], [1, -1]);\n b.slice = tf.slice(t.batch, [nms[i], keypointsCount - 1], [1, -1]);\n b.squeeze = tf.squeeze(b.slice);\n b.landmarks = tf.reshape(b.squeeze, [keypointsCount, -1]);\n const points = await b.bbox.data();\n const rawBox = {\n startPoint: [points[0], points[1]] as Point,\n endPoint: [points[2], points[3]] as Point,\n landmarks: (await b.landmarks.array()) as Point[],\n confidence,\n };\n b.anchor = tf.slice(anchors as Tensor, [nms[i], 0], [1, 2]);\n const anchor = await b.anchor.data();\n const scaledBox = util.scaleBoxCoordinates(rawBox, [(inputImage.shape[2] || 0) / inputSize, (inputImage.shape[1] || 0) / inputSize], anchor);\n const enlargedBox = util.enlargeBox(scaledBox, config.face['scale'] || faceBoxScaleFactor);\n const squaredBox = util.squarifyBox(enlargedBox);\n if (squaredBox.size[0] > (config.face.detector?.['minSize'] || 0) && squaredBox.size[1] > (config.face.detector?.['minSize'] || 0)) boxes.push(squaredBox);\n Object.keys(b).forEach((tensor) => tf.dispose(b[tensor]));\n }\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return boxes;\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport * as coords from './facemeshcoords';\nimport * as util from './facemeshutil';\nimport type { Tensor, GraphModel } from '../tfjs/types';\nimport { env } from '../util/env';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Config } from '../config';\nimport type { Point } from '../result';\n\nlet model: GraphModel | null;\nlet inputSize = 0;\n\nconst irisEnlarge = 2.3;\n\nconst leftOutline = coords.meshAnnotations.leftEyeLower0;\nconst rightOutline = coords.meshAnnotations.rightEyeLower0;\n\nconst eyeLandmarks = {\n leftBounds: [leftOutline[0], leftOutline[leftOutline.length - 1]],\n rightBounds: [rightOutline[0], rightOutline[rightOutline.length - 1]],\n};\n\nconst irisLandmarks = {\n upperCenter: 3,\n lowerCenter: 4,\n index: 71,\n numCoordinates: 76,\n};\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.iris?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n inputSize = (model?.['executor'] && model.inputs?.[0].shape) ? model.inputs[0].shape[2] : 0;\n if (inputSize === -1) inputSize = 64;\n return model;\n}\n\n// Replace the raw coordinates returned by facemesh with refined iris model coordinates and update the z coordinate to be an average of the original and the new.\nexport function replaceIrisCoords(rawCoords, newCoords, prefix, keys) {\n for (let i = 0; i < coords.irisIndices.length; i++) {\n const { key, indices } = coords.irisIndices[i];\n const originalIndices = coords.meshAnnotations[`${prefix}${key}`];\n if (!keys || keys.includes(key)) {\n for (let j = 0; j < indices.length; j++) {\n const index = indices[j];\n rawCoords[originalIndices[j]] = [\n newCoords[index][0],\n newCoords[index][1],\n (newCoords[index][2] + rawCoords[originalIndices[j]][2]) / 2,\n ];\n }\n }\n }\n}\n\nexport const getLeftToRightEyeDepthDifference = (rawCoords) => {\n const leftEyeZ = rawCoords[eyeLandmarks.leftBounds[0]][2];\n const rightEyeZ = rawCoords[eyeLandmarks.rightBounds[0]][2];\n return leftEyeZ - rightEyeZ;\n};\n\n// Returns a box describing a cropped region around the eye fit for passing to the iris model.\nexport const getEyeBox = (rawCoords, face, eyeInnerCornerIndex, eyeOuterCornerIndex, meshSize, flip = false) => {\n const box = util.squarifyBox(util.enlargeBox(util.calculateLandmarksBoundingBox([rawCoords[eyeInnerCornerIndex], rawCoords[eyeOuterCornerIndex]]), irisEnlarge));\n const boxSize = util.getBoxSize(box);\n let crop = tf.image.cropAndResize(face, [[\n box.startPoint[1] / meshSize,\n box.startPoint[0] / meshSize, box.endPoint[1] / meshSize,\n box.endPoint[0] / meshSize,\n ]], [0], [inputSize, inputSize]);\n if (flip && env.kernels.includes('flipleftright')) {\n const flipped = tf.image.flipLeftRight(crop); // flipLeftRight is not defined for tfjs-node\n tf.dispose(crop);\n crop = flipped;\n }\n return { box, boxSize, crop };\n};\n\n// Given a cropped image of an eye, returns the coordinates of the contours surrounding the eye and the iris.\nexport const getEyeCoords = (eyeData, eyeBox, eyeBoxSize, flip = false) => {\n const eyeRawCoords: Point[] = [];\n for (let i = 0; i < irisLandmarks.numCoordinates; i++) {\n const x = eyeData[i * 3];\n const y = eyeData[i * 3 + 1];\n const z = eyeData[i * 3 + 2];\n eyeRawCoords.push([\n (flip ? (1 - (x / inputSize)) : (x / inputSize)) * eyeBoxSize[0] + eyeBox.startPoint[0],\n (y / inputSize) * eyeBoxSize[1] + eyeBox.startPoint[1], z,\n ]);\n }\n return { rawCoords: eyeRawCoords, iris: eyeRawCoords.slice(irisLandmarks.index) };\n};\n\n// The z-coordinates returned for the iris are unreliable, so we take the z values from the surrounding keypoints.\nexport const getAdjustedIrisCoords = (rawCoords, irisCoords, direction) => {\n const upperCenterZ = rawCoords[coords.meshAnnotations[`${direction}EyeUpper0`][irisLandmarks.upperCenter]][2];\n const lowerCenterZ = rawCoords[coords.meshAnnotations[`${direction}EyeLower0`][irisLandmarks.lowerCenter]][2];\n const averageZ = (upperCenterZ + lowerCenterZ) / 2;\n // Iris indices: 0: center | 1: right | 2: above | 3: left | 4: below\n return irisCoords.map((coord, i) => {\n let z = averageZ;\n if (i === 2) {\n z = upperCenterZ;\n } else if (i === 4) {\n z = lowerCenterZ;\n }\n return [coord[0], coord[1], z];\n });\n};\n\nexport async function augmentIris(rawCoords, face, meshSize) {\n if (!model?.['executor']) return rawCoords;\n const { box: leftEyeBox, boxSize: leftEyeBoxSize, crop: leftEyeCrop } = getEyeBox(rawCoords, face, eyeLandmarks.leftBounds[0], eyeLandmarks.leftBounds[1], meshSize, true);\n const { box: rightEyeBox, boxSize: rightEyeBoxSize, crop: rightEyeCrop } = getEyeBox(rawCoords, face, eyeLandmarks.rightBounds[0], eyeLandmarks.rightBounds[1], meshSize, true);\n const combined = tf.concat([leftEyeCrop, rightEyeCrop]);\n tf.dispose(leftEyeCrop);\n tf.dispose(rightEyeCrop);\n const eyePredictions = model.execute(combined) as Tensor;\n tf.dispose(combined);\n const eyePredictionsData = await eyePredictions.data();\n tf.dispose(eyePredictions);\n const leftEyeData = eyePredictionsData.slice(0, irisLandmarks.numCoordinates * 3);\n const { rawCoords: leftEyeRawCoords, iris: leftIrisRawCoords } = getEyeCoords(leftEyeData, leftEyeBox, leftEyeBoxSize, true);\n const rightEyeData = eyePredictionsData.slice(irisLandmarks.numCoordinates * 3);\n const { rawCoords: rightEyeRawCoords, iris: rightIrisRawCoords } = getEyeCoords(rightEyeData, rightEyeBox, rightEyeBoxSize, false);\n const leftToRightEyeDepthDifference = getLeftToRightEyeDepthDifference(rawCoords);\n if (Math.abs(leftToRightEyeDepthDifference) < 30) { // User is looking straight ahead.\n replaceIrisCoords(rawCoords, leftEyeRawCoords, 'left', null);\n replaceIrisCoords(rawCoords, rightEyeRawCoords, 'right', null);\n // If the user is looking to the left or to the right, the iris coordinates tend to diverge too much from the mesh coordinates for them to be merged so we only update a single contour line above and below the eye.\n } else if (leftToRightEyeDepthDifference < 1) { // User is looking towards the right.\n replaceIrisCoords(rawCoords, leftEyeRawCoords, 'left', ['EyeUpper0', 'EyeLower0']);\n } else { // User is looking towards the left.\n replaceIrisCoords(rawCoords, rightEyeRawCoords, 'right', ['EyeUpper0', 'EyeLower0']);\n }\n const adjustedLeftIrisCoords = getAdjustedIrisCoords(rawCoords, leftIrisRawCoords, 'left');\n const adjustedRightIrisCoords = getAdjustedIrisCoords(rawCoords, rightIrisRawCoords, 'right');\n const newCoords = rawCoords.concat(adjustedLeftIrisCoords).concat(adjustedRightIrisCoords);\n return newCoords;\n}\n", "import * as constants from './constants';\nimport type { Tensor } from '../tfjs/types';\n\nexport async function augment(rawCoords, results: Tensor[]) {\n const t: Record = { // all attention models produce 2d results so it needs to be later augmented with correct z-coords\n // mesh: results[0], // already have it in rawCoords // output_mesh_identity\n // flag: results[1], // already processed in parent // conv_faceflag\n lips: await results.filter((r) => r.size === 160)?.[0]?.data() as Float32Array, // 80 x 2d = 160 // output_lips\n irisL: await results.filter((r) => r.size === 10)?.[0]?.data() as Float32Array, // 5 x 2d = 10 // output_right_iris\n eyeL: await results.filter((r) => r.size === 142)?.[0]?.data() as Float32Array, // 71 x 2d = 142 // output_right_eye\n irisR: await results.filter((r) => r.size === 10)?.[1]?.data() as Float32Array, // 5 x 2d = 10 // output_left_iris\n eyeR: await results.filter((r) => r.size === 142)?.[1]?.data() as Float32Array, // 71 x 2d = 142// output_left_eye\n };\n for (const val of Object.values(t)) {\n if (!val) return rawCoords; // could not find tensor\n }\n\n // augment iris: adds additional 5 keypoints per eye\n const irisLDepth = constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG.reduce((prev, curr) => prev += rawCoords[curr][2], 0) / constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG.length; // get average z-coord for iris\n for (let i = 0; i < t.irisL.length / 2; i++) rawCoords.push([t.irisL[2 * i + 0], t.irisL[2 * i + 1], irisLDepth]);\n const irisRDepth = constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG.reduce((prev, curr) => prev += rawCoords[curr][2], 0) / constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG.length; // get average z-coord for iris\n for (let i = 0; i < t.irisR.length / 2; i++) rawCoords.push([t.irisR[2 * i + 0], t.irisR[2 * i + 1], irisRDepth]);\n\n // augment eyes: replaces eye keypoints based on heuristic mapping\n for (let i = 0; i < t.eyeL.length / 2; i++) rawCoords[constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG[i]] = [t.eyeL[2 * i + 0], t.eyeL[2 * i + 1], rawCoords[constants.LANDMARKS_REFINEMENT_LEFT_EYE_CONFIG[i]][2]];\n for (let i = 0; i < t.eyeR.length / 2; i++) rawCoords[constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG[i]] = [t.eyeR[2 * i + 0], t.eyeR[2 * i + 1], rawCoords[constants.LANDMARKS_REFINEMENT_RIGHT_EYE_CONFIG[i]][2]];\n\n // augment lips: replaces eye keypoints based on heuristic mapping\n for (let i = 0; i < t.lips.length / 2; i++) rawCoords[constants.LANDMARKS_REFINEMENT_LIPS_CONFIG[i]] = [t.lips[2 * i + 0], t.lips[2 * i + 1], rawCoords[constants.LANDMARKS_REFINEMENT_LIPS_CONFIG[i]][2]];\n\n return rawCoords;\n}\n", "/**\n * BlazeFace, FaceMesh & Iris model implementation\n *\n * Based on:\n * - [**MediaPipe BlazeFace**](https://drive.google.com/file/d/1f39lSzU5Oq-j_OXgS67KfN5wNsoeAZ4V/view)\n * - Facial Spacial Geometry: [**MediaPipe FaceMesh**](https://drive.google.com/file/d/1VFC_wIpw4O7xBOiTgUldl79d9LA-LsnA/view)\n * - Eye Iris Details: [**MediaPipe Iris**](https://drive.google.com/file/d/1bsWbokp9AklH2ANjCfmjqEzzxO1CNbMu/view)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport * as blazeface from './blazeface';\nimport * as util from './facemeshutil';\nimport * as coords from './facemeshcoords';\nimport * as iris from './iris';\nimport * as attention from './attention';\nimport { histogramEqualization } from '../image/enhance';\nimport { env } from '../util/env';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { FaceResult, FaceLandmark, Point } from '../result';\nimport type { Config } from '../config';\nimport type { DetectBox } from './blazeface';\n\nconst cache = {\n boxes: [] as DetectBox[],\n skipped: Number.MAX_SAFE_INTEGER,\n timestamp: 0,\n};\n\nlet model: GraphModel | null = null;\nlet inputSize = 0;\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n // reset cached boxes\n const skipTime = (config.face.detector?.skipTime || 0) > (now() - cache.timestamp);\n const skipFrame = cache.skipped < (config.face.detector?.skipFrames || 0);\n if (!config.skipAllowed || !skipTime || !skipFrame || cache.boxes.length === 0) {\n cache.boxes = await blazeface.getBoxes(input, config); // get results from blazeface detector\n cache.timestamp = now();\n cache.skipped = 0;\n } else {\n cache.skipped++;\n }\n const faces: FaceResult[] = [];\n const newCache: DetectBox[] = [];\n let id = 0;\n const size = inputSize;\n for (let i = 0; i < cache.boxes.length; i++) {\n const box = cache.boxes[i];\n let angle = 0;\n let rotationMatrix;\n const face: FaceResult = { // init face result\n id: id++,\n mesh: [],\n meshRaw: [],\n box: [0, 0, 0, 0],\n boxRaw: [0, 0, 0, 0],\n score: 0,\n boxScore: 0,\n faceScore: 0,\n size: [0, 0],\n // contoursRaw: [],\n // contours: [],\n annotations: {} as Record,\n };\n\n // optional rotation correction based on detector data only if mesh is disabled otherwise perform it later when we have more accurate mesh data. if no rotation correction this function performs crop\n [angle, rotationMatrix, face.tensor] = util.correctFaceRotation(config.face.detector?.rotation, box, input, config.face.mesh?.enabled ? inputSize : blazeface.size());\n if (config.filter.equalization) {\n const equilized = face.tensor ? await histogramEqualization(face.tensor) : undefined;\n tf.dispose(face.tensor);\n if (equilized) face.tensor = equilized;\n }\n face.boxScore = Math.round(100 * box.confidence) / 100;\n if (!config.face.mesh?.enabled || !model?.['executor']) { // mesh not enabled or not loaded, return resuts from detector only\n face.box = util.clampBox(box, input);\n face.boxRaw = util.getRawBox(box, input);\n face.score = face.boxScore;\n face.size = box.size;\n face.mesh = box.landmarks;\n face.meshRaw = face.mesh.map((pt) => [pt[0] / (input.shape[2] || 0), pt[1] / (input.shape[1] || 0), (pt[2] || 0) / size]);\n for (const key of Object.keys(coords.blazeFaceLandmarks)) face.annotations[key] = [face.mesh[coords.blazeFaceLandmarks[key] as number]]; // add annotations\n } else if (!model) { // mesh enabled, but not loaded\n if (config.debug) log('face mesh detection requested, but model is not loaded');\n } else { // mesh enabled\n if (config.face.attention?.enabled && !env.kernels.includes('atan2')) {\n config.face.attention.enabled = false;\n tf.dispose(face.tensor);\n return faces;\n }\n const results = model.execute(face.tensor as Tensor) as Tensor[];\n const confidenceT = results.find((t) => t.shape[t.shape.length - 1] === 1) as Tensor;\n const faceConfidence = await confidenceT.data();\n face.faceScore = Math.round(100 * faceConfidence[0]) / 100;\n if (face.faceScore < (config.face.detector?.minConfidence || 1)) { // low confidence in detected mesh\n box.confidence = face.faceScore; // reset confidence of cached box\n if (config.face.mesh['keepInvalid']) {\n face.box = util.clampBox(box, input);\n face.boxRaw = util.getRawBox(box, input);\n face.size = box.size;\n face.score = face.boxScore;\n face.mesh = box.landmarks;\n face.meshRaw = face.mesh.map((pt) => [pt[0] / (input.shape[2] || 1), pt[1] / (input.shape[1] || 1), (pt[2] || 0) / size]);\n for (const key of Object.keys(coords.blazeFaceLandmarks)) {\n face.annotations[key] = [face.mesh[coords.blazeFaceLandmarks[key] as number]]; // add annotations\n }\n }\n } else {\n const meshT = results.find((t) => t.shape[t.shape.length - 1] === 1404) as Tensor;\n const coordsReshaped = tf.reshape(meshT, [-1, 3]);\n let rawCoords = await coordsReshaped.array();\n tf.dispose(coordsReshaped);\n if (config.face.attention?.enabled) {\n rawCoords = await attention.augment(rawCoords, results); // augment iris results using attention model results\n } else if (config.face.iris?.enabled) {\n rawCoords = await iris.augmentIris(rawCoords, face.tensor, inputSize); // run iris model and augment results\n }\n face.mesh = util.transformRawCoords(rawCoords, box, angle, rotationMatrix, inputSize); // get processed mesh\n face.meshRaw = face.mesh.map((pt) => [pt[0] / (input.shape[2] || 0), pt[1] / (input.shape[1] || 0), (pt[2] || 0) / size]);\n for (const key of Object.keys(coords.meshAnnotations)) face.annotations[key] = coords.meshAnnotations[key].map((index) => face.mesh[index]); // add annotations\n face.score = face.faceScore;\n const calculatedBox = {\n ...util.calculateFaceBox(face.mesh, box),\n confidence: box.confidence,\n landmarks: box.landmarks,\n size: box.size,\n };\n face.box = util.clampBox(calculatedBox, input);\n face.boxRaw = util.getRawBox(calculatedBox, input);\n face.size = calculatedBox.size;\n /*\n const contoursT = results.find((t) => t.shape[t.shape.length - 1] === 266) as Tensor;\n const contoursData = contoursT && await contoursT.data(); // 133 x 2d points\n face.contoursRaw = [];\n for (let j = 0; j < contoursData.length / 2; j++) face.contoursRaw.push([contoursData[2 * j + 0] / inputSize, contoursData[2 * j + 1] / inputSize]);\n face.contours = face.contoursRaw.map((c) => [Math.trunc((input.shape[2] || 1) * c[0]), Math.trunc((input.shape[1] || 1) * c[1])]);\n */\n newCache.push(calculatedBox);\n }\n tf.dispose(results);\n }\n if (face.score > (config.face.detector?.minConfidence || 1)) faces.push(face);\n else tf.dispose(face.tensor);\n }\n cache.boxes = newCache; // reset cache\n return faces;\n}\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (config.face.attention?.enabled && model?.['signature']) {\n if (Object.keys(model?.['signature']?.outputs || {}).length < 6) model = null;\n }\n if (!model) {\n if (config.face.attention?.enabled) model = await loadModel(config.face.attention.modelPath);\n else model = await loadModel(config.face.mesh?.modelPath);\n } else if (config.debug) {\n log('cached model:', model['modelUrl']);\n }\n inputSize = (model['executor'] && model?.inputs?.[0].shape) ? model?.inputs?.[0].shape[2] : 256;\n return model;\n}\n\nexport const triangulation = coords.TRI468;\nexport const uvmap = coords.UV468;\n", "/**\n * Emotion model implementation\n *\n * [**Oarriaga**](https://github.com/oarriaga/face_classification)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport type { Emotion } from '../result';\nimport { log, now } from '../util/util';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { loadModel } from '../tfjs/load';\nimport { env } from '../util/env';\nimport { constants } from '../tfjs/constants';\n\nlet annotations: string[] = [];\nlet model: GraphModel | null;\nconst last: { score: number, emotion: Emotion }[][] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet rgb = false;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n model = await loadModel(config.face.emotion?.modelPath);\n rgb = model?.inputs?.[0].shape?.[3] === 3;\n if (!rgb) annotations = ['angry', 'disgust', 'fear', 'happy', 'sad', 'surprise', 'neutral']; // oarriaga and gear\n else annotations = ['angry', 'disgust', 'fear', 'happy', 'neutral', 'sad', 'surprise']; // affectnet\n } else if (config.debug) {\n log('cached model:', model['modelUrl']);\n }\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise<{ score: number, emotion: Emotion }[]> {\n if (!model) return [];\n const skipFrame = skipped < (config.face.emotion?.skipFrames || 0);\n const skipTime = (config.face.emotion?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx] && (last[idx].length > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const obj: { score: number, emotion: Emotion }[] = [];\n if (config.face.emotion?.enabled) {\n const t: Record = {};\n const inputSize = model?.inputs[0].shape ? model.inputs[0].shape[2] : 0;\n if (config.face.emotion?.['crop'] > 0) { // optional crop\n const crop = config.face.emotion?.['crop'];\n const box = [[crop, crop, 1 - crop, 1 - crop]];\n t.resize = tf.image.cropAndResize(image, box, [0], [inputSize, inputSize]);\n } else {\n t.resize = tf.image.resizeBilinear(image, [inputSize, inputSize], false);\n }\n if (rgb) {\n t.mul = tf.mul(t.resize, 255);\n t.normalize = tf.sub(t.mul, [103.939, 116.779, 123.68]); // affectnet uses specific norm values\n t.emotion = model?.execute(t.normalize) as Tensor; // result is already in range 0..1, no need for additional activation\n } else {\n // [t.red, t.green, t.blue] = tf.split(t.resize, 3, 3);\n // weighted rgb to grayscale: https://www.mathworks.com/help/matlab/ref/rgb2gray.html\n // t.redNorm = tf.mul(t.red, rgb[0]);\n // t.greenNorm = tf.mul(t.green, rgb[1]);\n // t.blueNorm = tf.mul(t.blue, rgb[2]);\n // t.grayscale = tf.addN([t.redNorm, t.greenNorm, t.blueNorm]);\n t.channels = tf.mul(t.resize, constants.rgb);\n t.grayscale = tf.sum(t.channels, 3, true);\n t.grayscaleSub = tf.sub(t.grayscale, constants.tf05);\n t.grayscaleMul = tf.mul(t.grayscaleSub, constants.tf2);\n t.emotion = model?.execute(t.grayscaleMul) as Tensor; // result is already in range 0..1, no need for additional activation\n }\n lastTime = now();\n const data = await t.emotion.data();\n for (let i = 0; i < data.length; i++) {\n if (data[i] > (config.face.emotion.minConfidence || 0)) obj.push({ score: Math.min(0.99, Math.trunc(100 * data[i]) / 100), emotion: annotations[i] as Emotion });\n }\n obj.sort((a, b) => b.score - a.score);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n last[idx] = obj;\n lastCount = count;\n resolve(obj);\n });\n}\n", "/**\n * FaceRes model implementation\n *\n * Returns Age, Gender, Descriptor\n * Implements Face similarity function\n *\n * Based on: [**HSE-FaceRes**](https://github.com/HSE-asavchenko/HSE_FaceRec_tf)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { env } from '../util/env';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { Tensor, GraphModel, Tensor4D, Tensor1D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport type { Gender, Race } from '../result';\n\nexport interface FaceRes { age: number, gender: Gender, genderScore: number, descriptor: number[], race?: { score: number, race: Race }[] }\n\nlet model: GraphModel | null;\nconst last: FaceRes[] = [];\n\nlet lastTime = 0;\nlet lastCount = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.description?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport function enhance(input, config: Config): Tensor {\n const tensor = (input.image || input.tensor || input) as Tensor4D; // input received from detector is already normalized to 0..1, input is also assumed to be straightened\n if (!model?.inputs[0].shape) return tensor; // model has no shape so no point continuing\n let crop: Tensor;\n if (config.face.description?.['crop'] > 0) { // optional crop\n const cropval = config.face.description?.['crop'];\n const box = [[cropval, cropval, 1 - cropval, 1 - cropval]];\n crop = tf.image.cropAndResize(tensor, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n } else {\n crop = tf.image.resizeBilinear(tensor, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false);\n }\n const norm: Tensor = tf.mul(crop, constants.tf255);\n tf.dispose(crop);\n return norm;\n /*\n // do a tight crop of image and resize it to fit the model\n const box = [[0.05, 0.15, 0.85, 0.85]]; // empyrical values for top, left, bottom, right\n const crop = (tensor.shape.length === 3)\n ? tf.image.cropAndResize(tf.expandDims(tensor, 0), box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]) // add batch dimension if missing\n : tf.image.cropAndResize(tensor, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n */\n /*\n // convert to black&white to avoid colorization impact\n const rgb = [0.2989, 0.5870, 0.1140]; // factors for red/green/blue colors when converting to grayscale: https://www.mathworks.com/help/matlab/ref/rgb2gray.html\n const [red, green, blue] = tf.split(crop, 3, 3);\n const redNorm = tf.mul(red, rgb[0]);\n const greenNorm = tf.mul(green, rgb[1]);\n const blueNorm = tf.mul(blue, rgb[2]);\n const grayscale = tf.addN([redNorm, greenNorm, blueNorm]);\n const merge = tf.stack([grayscale, grayscale, grayscale], 3).squeeze(4);\n */\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n const obj: FaceRes = {\n age: 0 as number,\n gender: 'unknown' as Gender,\n genderScore: 0 as number,\n descriptor: [] as number[],\n };\n if (!model?.['executor']) return obj;\n const skipFrame = skipped < (config.face.description?.skipFrames || 0);\n const skipTime = (config.face.description?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipFrame && skipTime && (lastCount === count) && (last?.[idx]?.age > 0) && (last?.[idx]?.genderScore > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (config.face.description?.enabled) {\n const enhanced = enhance(image, config);\n const resT = model?.execute(enhanced) as Tensor[];\n lastTime = now();\n tf.dispose(enhanced);\n const genderT = resT.find((t) => t.shape[1] === 1) as Tensor;\n const gender = await genderT.data();\n const confidence = Math.trunc(200 * Math.abs((gender[0] - 0.5))) / 100;\n if (confidence > (config.face.description.minConfidence || 0)) {\n obj.gender = gender[0] <= 0.5 ? 'female' : 'male';\n obj.genderScore = Math.min(0.99, confidence);\n }\n const argmax = tf.argMax(resT.find((t) => t.shape[1] === 100) as Tensor1D, 1);\n const ageIdx: number = (await argmax.data())[0];\n tf.dispose(argmax);\n const ageT = resT.find((t) => t.shape[1] === 100) as Tensor;\n const all = await ageT.data();\n obj.age = Math.round(all[ageIdx - 1] > all[ageIdx + 1] ? 10 * ageIdx - 100 * all[ageIdx - 1] : 10 * ageIdx + 100 * all[ageIdx + 1]) / 10;\n\n if (Number.isNaN(gender[0]) || Number.isNaN(all[0])) log('faceres error:', { model, result: resT });\n\n const desc = resT.find((t) => t.shape[1] === 1024);\n // const reshape = desc.reshape([128, 8]); // reshape large 1024-element descriptor to 128 x 8\n // const reduce = reshape.logSumExp(1); // reduce 2nd dimension by calculating logSumExp on it which leaves us with 128-element descriptor\n const descriptor = desc ? await desc.data() : [] as number[];\n obj.descriptor = Array.from(descriptor);\n resT.forEach((t) => tf.dispose(t));\n }\n last[idx] = obj;\n lastCount = count;\n resolve(obj);\n });\n}\n", "import type { Tensor } from '../tfjs/types';\nimport type { FaceResult } from '../result';\n// import * as tf from 'dist/tfjs.esm.js';\nimport { meshAnnotations } from './facemeshcoords';\n\nconst expandFact = 0.1;\nconst alpha = 0.5;\n\n// point inclusion in polygon based on https://wrf.ecse.rpi.edu/Research/Short_Notes/pnpoly.html\nfunction insidePoly(x: number, y: number, polygon: { x: number, y: number }[]): boolean {\n let inside = false;\n let j = polygon.length - 1;\n for (let i = 0; i < polygon.length; j = i++) {\n if (((polygon[i].y > y) !== (polygon[j].y > y)) && (x < (polygon[j].x - polygon[i].x) * (y - polygon[i].y) / (polygon[j].y - polygon[i].y) + polygon[i].x)) inside = !inside;\n }\n return inside;\n}\n\nexport async function mask(face: FaceResult): Promise {\n if (!face.tensor) return face.tensor;\n if (!face.mesh || face.mesh.length < 100) return face.tensor;\n const width = face.tensor.shape[2] || 0;\n const height = face.tensor.shape[1] || 0;\n const buffer = await face.tensor.buffer();\n let silhouette: { x: number, y: number }[] = [];\n for (const pt of meshAnnotations.silhouette) silhouette.push({ x: (face.mesh[pt][0] - face.box[0]) / face.box[2], y: (face.mesh[pt][1] - face.box[1]) / face.box[3] }); // add all silhouette points scaled to local box\n if (expandFact && expandFact > 0) silhouette = silhouette.map((pt) => ({ x: pt.x > 0.5 ? pt.x + expandFact : pt.x - expandFact, y: pt.y > 0.5 ? pt.y + expandFact : pt.y - expandFact })); // expand silhouette\n for (let x = 0; x < width; x++) {\n for (let y = 0; y < height; y++) {\n const inside = insidePoly(x / width, y / width, silhouette);\n if (!inside) {\n buffer.set(alpha * buffer.get(0, y, x, 0), 0, y, x, 0);\n buffer.set(alpha * buffer.get(0, y, x, 1), 0, y, x, 1);\n buffer.set(alpha * buffer.get(0, y, x, 2), 0, y, x, 2);\n }\n }\n }\n const output = buffer.toTensor();\n // tf.dispose(buffer);\n return output;\n}\n", "/**\n * Anti-spoofing model implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { loadModel } from '../tfjs/load';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst cached: number[] = [];\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet lastCount = 0;\nlet lastTime = 0;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.antispoof?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n if (!model?.['executor']) return 0;\n const skipTime = (config.face.antispoof?.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.face.antispoof?.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && cached[idx]) {\n skipped++;\n return cached[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape ? model.inputs[0].shape[2] : 0, model?.inputs[0].shape ? model.inputs[0].shape[1] : 0], false);\n const res = model?.execute(resize) as Tensor;\n const num = (await res.data())[0];\n cached[idx] = Math.round(100 * num) / 100;\n lastCount = count;\n lastTime = now();\n tf.dispose([resize, res]);\n resolve(cached[idx]);\n });\n}\n", "/**\n * Anti-spoofing model implementation\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst cached: number[] = [];\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet lastCount = 0;\nlet lastTime = 0;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.liveness?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n if (!model?.['executor']) return 0;\n const skipTime = (config.face.liveness?.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.face.liveness?.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && cached[idx]) {\n skipped++;\n return cached[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n const resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape ? model.inputs[0].shape[2] : 0, model?.inputs[0].shape ? model.inputs[0].shape[1] : 0], false);\n const res = model?.execute(resize) as Tensor;\n const num = (await res.data())[0];\n cached[idx] = Math.round(100 * num) / 100;\n lastCount = count;\n lastTime = now();\n tf.dispose([resize, res]);\n resolve(cached[idx]);\n });\n}\n", "/**\n * GEAR [gender/emotion/age/race] model implementation\n *\n * Based on: [**GEAR Predictor**](https://github.com/Udolf15/GEAR-Predictor)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Gender, Race } from '../result';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\n\nexport interface GearType { age: number, gender: Gender, genderScore: number, race: { score: number, race: Race }[] }\nlet model: GraphModel | null;\nconst last: GearType[] = [];\nconst raceNames = ['white', 'black', 'asian', 'indian', 'other'];\nconst ageWeights = [15, 23, 28, 35.5, 45.5, 55.5, 65];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config) {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face.gear?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise {\n if (!model) return { age: 0, gender: 'unknown', genderScore: 0, race: [] };\n const skipFrame = skipped < (config.face.gear?.skipFrames || 0);\n const skipTime = (config.face.gear?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx]) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (!model?.inputs[0].shape) return;\n const t: Record = {};\n // t.resize = tf.image.resizeBilinear(image, [model?.inputs[0].shape[2], model?.inputs[0].shape[1]], false);\n let box = [[0.0, 0.10, 0.90, 0.90]]; // empyrical values for top, left, bottom, right\n if (config.face.gear?.['crop'] > 0) { // optional crop config value\n const crop = config.face.gear?.['crop'];\n box = [[crop, crop, 1 - crop, 1 - crop]];\n }\n t.resize = tf.image.cropAndResize(image, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n const obj: GearType = { age: 0, gender: 'unknown', genderScore: 0, race: [] };\n if (config.face.gear?.enabled) [t.age, t.gender, t.race] = model.execute(t.resize, ['age_output', 'gender_output', 'race_output']) as Tensor[];\n const gender = await t.gender.data();\n obj.gender = gender[0] > gender[1] ? 'male' : 'female';\n obj.genderScore = Math.round(100 * (gender[0] > gender[1] ? gender[0] : gender[1])) / 100;\n const race = await t.race.data();\n for (let i = 0; i < race.length; i++) {\n if (race[i] > (config.face.gear?.minConfidence || 0.2)) obj.race.push({ score: Math.round(100 * race[i]) / 100, race: raceNames[i] as Race });\n }\n obj.race.sort((a, b) => b.score - a.score);\n // {0: 'Below20', 1: '21-25', 2: '26-30', 3: '31-40',4: '41-50', 5: '51-60', 6: 'Above60'}\n const ageDistribution = Array.from(await t.age.data());\n const ageSorted = ageDistribution.map((a, i) => [ageWeights[i], a]).sort((a, b) => b[1] - a[1]);\n let age = ageSorted[0][0]; // pick best starting point\n for (let i = 1; i < ageSorted.length; i++) age += ageSorted[i][1] * (ageSorted[i][0] - age); // adjust with each other choice by weight\n obj.age = Math.round(10 * age) / 10;\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n last[idx] = obj;\n lastCount = count;\n lastTime = now();\n resolve(obj);\n });\n}\n", "/**\n * Age model implementation\n *\n * Based on: [**SSR-Net**](https://github.com/shamangary/SSR-Net)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { env } from '../util/env';\nimport { constants } from '../tfjs/constants';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\n\nlet model: GraphModel | null;\nconst last: { age: number }[] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config) {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['ssrnet'].modelPathAge);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx: number, count: number): Promise<{ age: number }> {\n if (!model) return { age: 0 };\n const skipFrame = skipped < (config.face['ssrnet']?.skipFrames || 0);\n const skipTime = (config.face['ssrnet']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipFrame && skipTime && (lastCount === count) && last[idx]?.age && (last[idx]?.age > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (!model?.inputs || !model.inputs[0] || !model.inputs[0].shape) return;\n const t: Record = {};\n if (config.face['ssrnet']?.['crop'] > 0) { // optional crop\n const crop = config.face['ssrnet']?.['crop'];\n const box = [[crop, crop, 1 - crop, 1 - crop]];\n t.resize = tf.image.cropAndResize(image, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n } else {\n t.resize = tf.image.resizeBilinear(image, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false);\n }\n t.enhance = tf.mul(t.resize, constants.tf255);\n const obj = { age: 0 };\n if (config.face['ssrnet']?.enabled) t.age = model.execute(t.enhance) as Tensor;\n if (t.age) {\n const data = await t.age.data();\n obj.age = Math.trunc(10 * data[0]) / 10;\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n last[idx] = obj;\n lastCount = count;\n lastTime = now();\n resolve(obj);\n });\n}\n", "/**\n * Gender model implementation\n *\n * Based on: [**SSR-Net**](https://github.com/shamangary/SSR-Net)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { Gender } from '../result';\nimport type { Config } from '../config';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst last: { gender: Gender, genderScore: number }[] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\n// tuning values\nconst rgb = [0.2989, 0.5870, 0.1140]; // factors for red/green/blue colors when converting to grayscale\n\nexport async function load(config: Config) {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['ssrnet']?.modelPathGender);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(image: Tensor4D, config: Config, idx, count): Promise<{ gender: Gender, genderScore: number }> {\n if (!model) return { gender: 'unknown', genderScore: 0 };\n const skipFrame = skipped < (config.face['ssrnet']?.skipFrames || 0);\n const skipTime = (config.face['ssrnet']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipFrame && skipTime && (lastCount === count) && last[idx]?.gender && (last[idx]?.genderScore > 0)) {\n skipped++;\n return last[idx];\n }\n skipped = 0;\n return new Promise(async (resolve) => {\n if (!model?.inputs[0].shape) return;\n const t: Record = {};\n if (config.face['ssrnet']?.['crop'] > 0) { // optional crop\n const crop = config.face['ssrnet']?.['crop'];\n const box = [[crop, crop, 1 - crop, 1 - crop]];\n t.resize = tf.image.cropAndResize(image, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n } else {\n t.resize = tf.image.resizeBilinear(image, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false);\n }\n t.enhance = tf.tidy(() => {\n let normalize: Tensor;\n if (model?.inputs?.[0].shape?.[3] === 1) {\n const [red, green, blue] = tf.split(t.resize, 3, 3);\n const redNorm = tf.mul(red, rgb[0]);\n const greenNorm = tf.mul(green, rgb[1]);\n const blueNorm = tf.mul(blue, rgb[2]);\n const grayscale = tf.addN([redNorm, greenNorm, blueNorm]);\n normalize = tf.mul(tf.sub(grayscale, constants.tf05), 2); // range grayscale:-1..1\n } else {\n normalize = tf.mul(tf.sub(t.resize, constants.tf05), 2); // range rgb:-1..1\n }\n return normalize;\n });\n const obj: { gender: Gender, genderScore: number } = { gender: 'unknown', genderScore: 0 };\n if (config.face['ssrnet']?.enabled) t.gender = model.execute(t.enhance) as Tensor;\n const data = await t.gender.data();\n obj.gender = data[0] > data[1] ? 'female' : 'male'; // returns two values 0..1, bigger one is prediction\n obj.genderScore = data[0] > data[1] ? (Math.trunc(100 * data[0]) / 100) : (Math.trunc(100 * data[1]) / 100);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n last[idx] = obj;\n lastCount = count;\n lastTime = now();\n resolve(obj);\n });\n}\n", "/**\n * MobileFaceNet model implementation\n *\n * Based on: [**BecauseofAI MobileFace**](https://github.com/becauseofAI/MobileFace)\n *\n * Obsolete and replaced by `faceres` that performs age/gender/descriptor analysis\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Tensor, Tensor4D, GraphModel } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst last: number[][] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['mobilefacenet']?.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\n/*\n// convert to black&white to avoid colorization impact\nconst rgb = [0.2989, 0.5870, 0.1140]; // factors for red/green/blue colors when converting to grayscale: https://www.mathworks.com/help/matlab/ref/rgb2gray.html\nconst [red, green, blue] = tf.split(crop, 3, 3);\nconst redNorm = tf.mul(red, rgb[0]);\nconst greenNorm = tf.mul(green, rgb[1]);\nconst blueNorm = tf.mul(blue, rgb[2]);\nconst grayscale = tf.addN([redNorm, greenNorm, blueNorm]);\nconst merge = tf.stack([grayscale, grayscale, grayscale], 3).squeeze(4);\n\n// optional increase image contrast\n// or do it per-channel so mean is done on each channel\n// or do it based on histogram\nconst mean = merge.mean();\nconst factor = 5;\nconst contrast = merge.sub(mean).mul(factor).add(mean);\n*/\n\nexport async function predict(input: Tensor4D, config: Config, idx, count): Promise {\n if (!model?.['executor']) return [];\n const skipFrame = skipped < (config.face['mobilefacenet']?.skipFrames || 0);\n const skipTime = (config.face['mobilefacenet']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx]) {\n skipped++;\n return last[idx];\n }\n return new Promise(async (resolve) => {\n let data: number[] = [];\n if (config.face['mobilefacenet']?.enabled && model?.inputs[0].shape) {\n const t: Record = {};\n t.crop = tf.image.resizeBilinear(input, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false); // just resize to fit the embedding model\n // do a tight crop of image and resize it to fit the model\n // const box = [[0.05, 0.15, 0.85, 0.85]]; // empyrical values for top, left, bottom, right\n // t.crop = tf.image.cropAndResize(input, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n t.data = model.execute(t.crop) as Tensor;\n /*\n // optional normalize outputs with l2 normalization\n const scaled = tf.tidy(() => {\n const l2 = res.norm('euclidean');\n const scale = res.div(l2);\n return scale;\n });\n\n // optional reduce feature vector complexity\n const reshape = tf.reshape(res, [128, 2]); // split 256 vectors into 128 x 2\n const reduce = reshape.logSumExp(1); // reduce 2nd dimension by calculating logSumExp on it\n */\n const output = await t.data.data();\n data = Array.from(output); // convert typed array to simple array\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n last[idx] = data;\n lastCount = count;\n lastTime = now();\n resolve(data);\n });\n}\n", "/**\n * InsightFace model implementation\n *\n * Based on: [**DeepInsight InsightFace**](https://github.com/deepinsight/insightface)\n *\n * Alternative face embedding detection\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { Tensor, Tensor4D, GraphModel } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nconst last: number[][] = [];\nlet lastCount = 0;\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) model = await loadModel(config.face['insightface'].modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(input: Tensor4D, config: Config, idx, count): Promise {\n if (!model?.['executor']) return [];\n const skipFrame = skipped < (config.face['insightface']?.skipFrames || 0);\n const skipTime = (config.face['insightface']?.skipTime || 0) > (now() - lastTime);\n if (config.skipAllowed && skipTime && skipFrame && (lastCount === count) && last[idx]) {\n skipped++;\n return last[idx];\n }\n return new Promise(async (resolve) => {\n let data: number[] = [];\n if (config.face['insightface']?.enabled && model?.inputs[0].shape) {\n const t: Record = {};\n t.crop = tf.image.resizeBilinear(input, [model.inputs[0].shape[2], model.inputs[0].shape[1]], false); // just resize to fit the embedding model\n // do a tight crop of image and resize it to fit the model\n // const box = [[0.05, 0.15, 0.85, 0.85]]; // empyrical values for top, left, bottom, right\n // t.crop = tf.image.cropAndResize(input, box, [0], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n t.data = model.execute(t.crop) as Tensor;\n const output = await t.data.data();\n data = Array.from(output); // convert typed array to simple array\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n last[idx] = data;\n lastCount = count;\n lastTime = now();\n resolve(data);\n });\n}\n", "import type { Point, FaceResult } from '../result';\n\ntype Vector = [number, number, number];\n\nconst calculateGaze = (face: FaceResult): { bearing: number, strength: number } => {\n const radians = (pt1: Point, pt2: Point) => Math.atan2(pt1[1] - pt2[1], pt1[0] - pt2[0]); // function to calculate angle between any two points\n if (!face.annotations.rightEyeIris || !face.annotations.leftEyeIris) return { bearing: 0, strength: 0 };\n\n const offsetIris = [0, -0.1]; // iris center may not align with average of eye extremes\n const eyeRatio = 1; // factor to normalize changes x vs y\n\n const left = (face.mesh[33][2] || 0) > (face.mesh[263][2] || 0); // pick left or right eye depending which one is closer bazed on outsize point z axis\n const irisCenter = left ? face.mesh[473] : face.mesh[468];\n const eyeCenter = left // eye center is average of extreme points on x axis for both x and y, ignoring y extreme points as eyelids naturally open/close more when gazing up/down so relative point is less precise\n ? [(face.mesh[133][0] + face.mesh[33][0]) / 2, (face.mesh[133][1] + face.mesh[33][1]) / 2]\n : [(face.mesh[263][0] + face.mesh[362][0]) / 2, (face.mesh[263][1] + face.mesh[362][1]) / 2];\n const eyeSize = left // eye size is difference between extreme points for both x and y, used to normalize & squarify eye dimensions\n ? [face.mesh[133][0] - face.mesh[33][0], face.mesh[23][1] - face.mesh[27][1]]\n : [face.mesh[263][0] - face.mesh[362][0], face.mesh[253][1] - face.mesh[257][1]];\n const eyeDiff: Point = [ // x distance between extreme point and center point normalized with eye size\n (eyeCenter[0] - irisCenter[0]) / eyeSize[0] - offsetIris[0],\n eyeRatio * (irisCenter[1] - eyeCenter[1]) / eyeSize[1] - offsetIris[1],\n ];\n let strength = Math.sqrt((eyeDiff[0] * eyeDiff[0]) + (eyeDiff[1] * eyeDiff[1])); // vector length is a diagonal between two differences\n strength = Math.min(strength, face.boxRaw[2] / 2, face.boxRaw[3] / 2); // limit strength to half of box size to avoid clipping due to low precision\n const bearing = (radians([0, 0], eyeDiff) + (Math.PI / 2)) % Math.PI; // using eyeDiff instead eyeCenter/irisCenter combo due to manual adjustments and rotate clockwise 90degrees\n return { bearing, strength };\n};\n\nexport const calculateFaceAngle = (face: FaceResult, imageSize: [number, number]): {\n angle: { pitch: number, yaw: number, roll: number },\n matrix: [number, number, number, number, number, number, number, number, number],\n gaze: { bearing: number, strength: number },\n} => {\n // const degrees = (theta) => Math.abs(((theta * 180) / Math.PI) % 360);\n const normalize = (v: Vector): Vector => { // normalize vector\n const length = Math.sqrt(v[0] * v[0] + v[1] * v[1] + v[2] * v[2]);\n v[0] /= length;\n v[1] /= length;\n v[2] /= length;\n return v;\n };\n const subVectors = (a: Vector, b: Vector): Vector => { // vector subtraction (a - b)\n const x = a[0] - b[0];\n const y = a[1] - b[1];\n const z = a[2] - b[2];\n return [x, y, z];\n };\n const crossVectors = (a: Vector, b: Vector): Vector => { // vector cross product (a x b)\n const x = a[1] * b[2] - a[2] * b[1];\n const y = a[2] * b[0] - a[0] * b[2];\n const z = a[0] * b[1] - a[1] * b[0];\n return [x, y, z];\n };\n // 3x3 rotation matrix to Euler angles based on https://www.geometrictools.com/Documentation/EulerAngles.pdf\n const rotationMatrixToEulerAngle = (r: number[]): { pitch: number, yaw: number, roll: number } => {\n const [r00, _r01, _r02, r10, r11, r12, r20, r21, r22] = r; // eslint-disable-line @typescript-eslint/no-unused-vars\n let thetaX: number;\n let thetaY: number;\n let thetaZ: number;\n if (r10 < 1) { // YZX calculation\n if (r10 > -1) {\n thetaZ = Math.asin(r10);\n thetaY = Math.atan2(-r20, r00);\n thetaX = Math.atan2(-r12, r11);\n } else {\n thetaZ = -Math.PI / 2;\n thetaY = -Math.atan2(r21, r22);\n thetaX = 0;\n }\n } else {\n thetaZ = Math.PI / 2;\n thetaY = Math.atan2(r21, r22);\n thetaX = 0;\n }\n if (Number.isNaN(thetaX)) thetaX = 0;\n if (Number.isNaN(thetaY)) thetaY = 0;\n if (Number.isNaN(thetaZ)) thetaZ = 0;\n return { pitch: 2 * -thetaX, yaw: 2 * -thetaY, roll: 2 * -thetaZ };\n };\n\n /*\n const meshToEulerAngle = (mesh) => { // simple Euler angle calculation based existing 3D mesh\n const radians = (a1, a2, b1, b2) => Math.atan2(b2 - a2, b1 - a1);\n return { // values are in radians in range of -pi/2 to pi/2 which is -90 to +90 degrees, value of 0 means center\n pitch: radians(mesh[10][1], mesh[10][2], mesh[152][1], mesh[152][2]), // looking at y,z of top and bottom points of the face // pitch is face move up/down\n yaw: radians(mesh[33][0], mesh[33][2], mesh[263][0], mesh[263][2]), // looking at x,z of outside corners of leftEye and rightEye // yaw is face turn left/right\n roll: radians(mesh[33][0], mesh[33][1], mesh[263][0], mesh[263][1]), // looking at x,y of outside corners of leftEye and rightEye // roll is face lean left/right\n };\n };\n */\n\n // initialize gaze and mesh\n const mesh = face.meshRaw;\n if (!mesh || mesh.length < 300) return { angle: { pitch: 0, yaw: 0, roll: 0 }, matrix: [1, 0, 0, 0, 1, 0, 0, 0, 1], gaze: { bearing: 0, strength: 0 } };\n\n const size = Math.max(face.boxRaw[2] * imageSize[0], face.boxRaw[3] * imageSize[1]) / 1.5;\n // top, bottom, left, right\n const pts: Point[] = [mesh[10], mesh[152], mesh[234], mesh[454]].map((pt) => [pt[0] * imageSize[0] / size, pt[1] * imageSize[1] / size, pt[2]] as Point); // make the xyz coordinates proportional, independent of the image/box size\n\n const yAxis = normalize(subVectors(pts[1] as Vector, pts[0] as Vector));\n let xAxis = normalize(subVectors(pts[3] as Vector, pts[2] as Vector));\n const zAxis = normalize(crossVectors(xAxis, yAxis));\n // adjust xAxis to make sure that all axes are perpendicular to each other\n xAxis = crossVectors(yAxis, zAxis);\n\n // Rotation Matrix from Axis Vectors - http://renderdan.blogspot.com/2006/05/rotation-matrix-from-axis-vectors.html\n // 3x3 rotation matrix is flatten to array in row-major order. Note that the rotation represented by this matrix is inverted.\n const matrix: [number, number, number, number, number, number, number, number, number] = [\n xAxis[0], xAxis[1], xAxis[2],\n yAxis[0], yAxis[1], yAxis[2],\n zAxis[0], zAxis[1], zAxis[2],\n ];\n const angle = rotationMatrixToEulerAngle(matrix);\n // const angle = meshToEulerAngle(mesh);\n\n // we have iris keypoints so we can calculate gaze direction\n const gaze = mesh.length === 478 ? calculateGaze(face) : { bearing: 0, strength: 0 };\n\n return { angle, matrix, gaze };\n};\n", "import type { FaceResult } from '../result';\n\nexport function calculateCameraDistance(face: FaceResult, width: number): number {\n // iris points are [center, left, top, right, bottom]\n // average size of human iris is 11.7mm - fairly constant for all ages/genders/races\n const f = face?.annotations;\n if (!f?.leftEyeIris || !f?.rightEyeIris) return 0;\n // get size of left and right iris in pixels, pick larger one as its likely to be more accurate and normalize to 0..1 range instead of pixels\n const irisSize = Math.max(Math.abs(f.leftEyeIris[3][0] - f.leftEyeIris[1][0]), Math.abs(f.rightEyeIris[3][0] - f.rightEyeIris[1][0])) / width;\n // distance of eye from camera in meters\n const cameraDistance = Math.round(1.17 / irisSize) / 100;\n return cameraDistance;\n}\n\nexport function calculateEyesDistance(face: FaceResult, width: number): number {\n // average distance between eyes is 65mm - fairly constant for typical adult male, but varies otherwise\n const f = face?.annotations;\n if (!f?.leftEyeIris || !f?.rightEyeIris) return 0;\n // get size of left and right iris in pixels, pick larger one as its likely to be more accurate and normalize to 0..1 range instead of pixels\n const irisSize = Math.max(Math.abs(f.leftEyeIris[3][0] - f.leftEyeIris[1][0]), Math.abs(f.rightEyeIris[3][0] - f.rightEyeIris[1][0])) / width;\n // pixel x and y distance of centers of left and right iris, you can use edges instead\n const irisDistanceXY = [f.leftEyeIris[0][0] - f.rightEyeIris[0][0], f.leftEyeIris[0][1] - f.rightEyeIris[0][1]];\n // absolute distance bewtween eyes in 0..1 range to account for head pitch (we can ignore yaw)\n const irisDistance = Math.sqrt((irisDistanceXY[0] * irisDistanceXY[0]) + (irisDistanceXY[1] * irisDistanceXY[1])) / width;\n // distance between eyes in meters\n const eyesDistance = Math.round(1.17 * irisDistance / irisSize) / 100;\n return eyesDistance;\n}\n", "/**\n * Face algorithm implementation\n * Uses FaceMesh, Emotion and FaceRes models to create a unified pipeline\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { env } from '../util/env';\nimport * as facemesh from './facemesh';\nimport * as emotion from '../gear/emotion';\nimport * as faceres from './faceres';\nimport * as mask from './mask';\nimport * as antispoof from './antispoof';\nimport * as liveness from './liveness';\nimport * as gear from '../gear/gear';\nimport * as ssrnetAge from '../gear/ssrnet-age';\nimport * as ssrnetGender from '../gear/ssrnet-gender';\nimport * as mobilefacenet from './mobilefacenet';\nimport * as insightface from './insightface';\nimport type { FaceResult, Emotion, Gender, Race } from '../result';\nimport type { Tensor4D } from '../tfjs/types';\nimport type { Human } from '../human';\nimport { calculateFaceAngle } from './angles';\nimport { calculateCameraDistance } from './anthropometry';\n\ninterface DescRes { age: number, gender: Gender, genderScore: number, descriptor: number[], race?: { score: number, race: Race }[] }\n\nexport const detectFace = async (instance: Human /* instance of human */, input: Tensor4D): Promise => {\n // run facemesh, includes blazeface and iris\n let timeStamp: number = now();\n let ageRes: { age: number } | Promise<{ age: number }> | null;\n let gearRes: gear.GearType | Promise | null;\n let genderRes: { gender: string, genderScore: number } | Promise<{ gender: string, genderScore: number }> | null;\n let emotionRes: { score: number, emotion: Emotion }[] | Promise<{ score: number, emotion: Emotion }[]>;\n let mobilefacenetRes: number[] | Promise | null;\n let insightfaceRes: number[] | Promise | null;\n let antispoofRes: number | Promise | null;\n let livenessRes: number | Promise | null;\n let descRes: DescRes | Promise | null;\n\n const faceRes: FaceResult[] = [];\n instance.state = 'run:face';\n const faces: FaceResult[] = await facemesh.predict(input, instance.config);\n instance.performance.face = env.perfadd ? (instance.performance.face || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n if (!input.shape || input.shape.length !== 4) return [];\n if (!faces) return [];\n // for (const face of faces) {\n for (let i = 0; i < faces.length; i++) {\n instance.analyze('Get Face');\n\n // is something went wrong, skip the face\n // @ts-ignore possibly undefied\n if (!faces[i].tensor || faces[i].tensor.isDisposedInternal) {\n log('Face object is disposed:', faces[i].tensor);\n continue;\n }\n\n // optional face mask\n if (instance.config.face.detector?.mask) {\n const masked = await mask.mask(faces[i]);\n tf.dispose(faces[i].tensor);\n if (masked) faces[i].tensor = masked;\n }\n\n // calculate face angles\n const rotation = faces[i].mesh && (faces[i].mesh.length > 200) ? calculateFaceAngle(faces[i], [input.shape[2], input.shape[1]]) : null;\n\n // run emotion, inherits face from blazeface\n instance.analyze('Start Emotion:');\n if (instance.config.async) {\n emotionRes = instance.config.face.emotion?.enabled ? emotion.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : [];\n } else {\n instance.state = 'run:emotion';\n timeStamp = now();\n emotionRes = instance.config.face.emotion?.enabled ? await emotion.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : [];\n instance.performance.emotion = env.perfadd ? (instance.performance.emotion || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End Emotion:');\n\n // run antispoof, inherits face from blazeface\n instance.analyze('Start AntiSpoof:');\n if (instance.config.async) {\n antispoofRes = instance.config.face.antispoof?.enabled ? antispoof.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n } else {\n instance.state = 'run:antispoof';\n timeStamp = now();\n antispoofRes = instance.config.face.antispoof?.enabled ? await antispoof.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n instance.performance.antispoof = env.perfadd ? (instance.performance.antispoof || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End AntiSpoof:');\n\n // run liveness, inherits face from blazeface\n instance.analyze('Start Liveness:');\n if (instance.config.async) {\n livenessRes = instance.config.face.liveness?.enabled ? liveness.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n } else {\n instance.state = 'run:liveness';\n timeStamp = now();\n livenessRes = instance.config.face.liveness?.enabled ? await liveness.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : 0;\n instance.performance.liveness = env.perfadd ? (instance.performance.antispoof || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End Liveness:');\n\n // run gear, inherits face from blazeface\n instance.analyze('Start GEAR:');\n if (instance.config.async) {\n gearRes = instance.config.face.gear?.enabled ? gear.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:gear';\n timeStamp = now();\n gearRes = instance.config.face.gear?.enabled ? await gear.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.gear = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End GEAR:');\n\n // run gear, inherits face from blazeface\n instance.analyze('Start SSRNet:');\n if (instance.config.async) {\n ageRes = instance.config.face['ssrnet']?.enabled ? ssrnetAge.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n genderRes = instance.config.face['ssrnet']?.enabled ? ssrnetGender.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:ssrnet';\n timeStamp = now();\n ageRes = instance.config.face['ssrnet']?.enabled ? await ssrnetAge.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n genderRes = instance.config.face['ssrnet']?.enabled ? await ssrnetGender.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.ssrnet = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End SSRNet:');\n\n // run mobilefacenet alternative, inherits face from blazeface\n instance.analyze('Start MobileFaceNet:');\n if (instance.config.async) {\n mobilefacenetRes = instance.config.face['mobilefacenet']?.enabled ? mobilefacenet.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:mobilefacenet';\n timeStamp = now();\n mobilefacenetRes = instance.config.face['mobilefacenet']?.enabled ? await mobilefacenet.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.mobilefacenet = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End MobileFaceNet:');\n\n // run insightface alternative, inherits face from blazeface\n instance.analyze('Start InsightFace:');\n if (instance.config.async) {\n insightfaceRes = instance.config.face['insightface']?.enabled ? insightface.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n } else {\n instance.state = 'run:mobilefacenet';\n timeStamp = now();\n insightfaceRes = instance.config.face['insightface']?.enabled ? await insightface.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length) : null;\n instance.performance.mobilefacenet = Math.trunc(now() - timeStamp);\n }\n instance.analyze('End InsightFace:');\n\n // run faceres, inherits face from blazeface\n instance.analyze('Start Description:');\n if (instance.config.async) {\n descRes = faceres.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length);\n } else {\n instance.state = 'run:description';\n timeStamp = now();\n descRes = await faceres.predict(faces[i].tensor as Tensor4D || tf.tensor([]), instance.config, i, faces.length);\n instance.performance.description = env.perfadd ? (instance.performance.description || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n instance.analyze('End Description:');\n\n // if async wait for results\n if (instance.config.async) {\n [ageRes, genderRes, emotionRes, mobilefacenetRes, insightfaceRes, descRes, gearRes, antispoofRes, livenessRes] = await Promise.all([ageRes, genderRes, emotionRes, mobilefacenetRes, insightfaceRes, descRes, gearRes, antispoofRes, livenessRes]);\n }\n instance.analyze('Finish Face:');\n\n if (instance.config.face['ssrnet']?.enabled && ageRes && genderRes) { // override age/gender if ssrnet model is used\n descRes = {\n ...(descRes as DescRes),\n age: (ageRes as { age: number}).age,\n gender: (genderRes as { gender: Gender, genderScore: number }).gender,\n genderScore: (genderRes as { gender: Gender, genderScore: number }).genderScore,\n };\n }\n if (instance.config.face.gear?.enabled && gearRes) { // override age/gender/race if gear model is used\n descRes = {\n ...(descRes as DescRes),\n age: (gearRes as gear.GearType).age,\n gender: (gearRes as gear.GearType).gender,\n genderScore: (gearRes as gear.GearType).genderScore,\n race: (gearRes as gear.GearType).race,\n };\n }\n if (instance.config.face['mobilefacenet']?.enabled && mobilefacenetRes) { // override descriptor if mobilefacenet model is used\n (descRes as DescRes).descriptor = mobilefacenetRes as number[];\n }\n\n if (instance.config.face['insightface']?.enabled && insightfaceRes) { // override descriptor if insightface model is used\n (descRes as DescRes).descriptor = insightfaceRes as number[];\n }\n\n const irisSize = instance.config.face.iris?.enabled ? calculateCameraDistance(faces[i], input.shape[2]) : 0;\n\n // optionally return tensor\n const tensor = instance.config.face.detector?.return ? tf.squeeze(faces[i].tensor as Tensor4D) : null;\n // dispose original face tensor\n tf.dispose(faces[i].tensor);\n // delete temp face image\n if (faces[i].tensor) delete faces[i].tensor;\n // combine results\n const res: FaceResult = {\n ...faces[i],\n id: i,\n };\n if ((descRes as DescRes).age) res.age = (descRes as DescRes).age;\n if ((descRes as DescRes).gender) res.gender = (descRes as DescRes).gender;\n if ((descRes as DescRes).genderScore) res.genderScore = (descRes as DescRes).genderScore;\n if ((descRes as DescRes).descriptor) res.embedding = (descRes as DescRes).descriptor;\n if ((descRes as DescRes).race) res.race = (descRes as DescRes).race as { score: number, race: Race }[];\n if (emotionRes) res.emotion = emotionRes as { score: number, emotion: Emotion }[];\n if (antispoofRes) res.real = antispoofRes as number;\n if (livenessRes) res.live = livenessRes as number;\n if (irisSize > 0) res.distance = irisSize;\n if (rotation) res.rotation = rotation;\n if (tensor) res.tensor = tensor;\n faceRes.push(res);\n instance.analyze('End Face');\n }\n instance.analyze('End FaceMesh:');\n if (instance.config.async) {\n if (instance.performance.face) delete instance.performance.face;\n if (instance.performance.age) delete instance.performance.age;\n if (instance.performance.gender) delete instance.performance.gender;\n if (instance.performance.emotion) delete instance.performance.emotion;\n }\n return faceRes;\n};\n", "/**\n * FingerPose algorithm implementation\n * See `fingerpose.ts` for entry point\n */\n\nexport const Finger = {\n thumb: 0,\n index: 1,\n middle: 2,\n ring: 3,\n pinky: 4,\n all: [0, 1, 2, 3, 4], // just for convenience\n nameMapping: { 0: 'thumb', 1: 'index', 2: 'middle', 3: 'ring', 4: 'pinky' },\n // Describes mapping of joints based on the 21 points returned by handpose.\n // [0] Palm\n // [1-4] Thumb\n // [5-8] Index\n // [9-12] Middle\n // [13-16] Ring\n // [17-20] Pinky\n pointsMapping: {\n 0: [[0, 1], [1, 2], [2, 3], [3, 4]],\n 1: [[0, 5], [5, 6], [6, 7], [7, 8]],\n 2: [[0, 9], [9, 10], [10, 11], [11, 12]],\n 3: [[0, 13], [13, 14], [14, 15], [15, 16]],\n 4: [[0, 17], [17, 18], [18, 19], [19, 20]],\n },\n getName: (value) => Finger.nameMapping[value],\n getPoints: (value) => Finger.pointsMapping[value],\n};\n\nexport const FingerCurl = {\n none: 0,\n half: 1,\n full: 2,\n nameMapping: { 0: 'none', 1: 'half', 2: 'full' },\n getName: (value) => FingerCurl.nameMapping[value],\n};\n\nexport const FingerDirection = {\n verticalUp: 0,\n verticalDown: 1,\n horizontalLeft: 2,\n horizontalRight: 3,\n diagonalUpRight: 4,\n diagonalUpLeft: 5,\n diagonalDownRight: 6,\n diagonalDownLeft: 7,\n nameMapping: { 0: 'verticalUp', 1: 'verticalDown', 2: 'horizontalLeft', 3: 'horizontalRight', 4: 'diagonalUpRight', 5: 'diagonalUpLeft', 6: 'diagonalDownRight', 7: 'diagonalDownLeft' },\n getName: (value) => FingerDirection.nameMapping[value],\n};\n\nexport class FingerGesture {\n name;\n curls;\n directions;\n weights;\n weightsRelative;\n\n constructor(name) {\n // name (should be unique)\n this.name = name;\n this.curls = {};\n this.directions = {};\n this.weights = [1.0, 1.0, 1.0, 1.0, 1.0];\n this.weightsRelative = [1.0, 1.0, 1.0, 1.0, 1.0];\n }\n\n curl(finger, curl, confidence) {\n if (typeof this.curls[finger] === 'undefined') this.curls[finger] = [];\n this.curls[finger].push([curl, confidence]);\n }\n\n direction(finger, position, confidence) {\n if (!this.directions[finger]) this.directions[finger] = [];\n this.directions[finger].push([position, confidence]);\n }\n\n weight(finger, weight) {\n this.weights[finger] = weight;\n // recalculate relative weights\n const total = this.weights.reduce((a, b) => a + b, 0);\n this.weightsRelative = this.weights.map((el) => el * 5 / total);\n }\n\n matchAgainst(detectedCurls, detectedDirections) {\n let confidence = 0.0;\n // look at the detected curl of each finger and compare with\n // the expected curl of this finger inside current gesture\n for (const fingerIdx in detectedCurls) {\n const detectedCurl = detectedCurls[fingerIdx];\n const expectedCurls = this.curls[fingerIdx];\n if (typeof expectedCurls === 'undefined') {\n // no curl description available for this finger\n // add default confidence of \"1\"\n confidence += this.weightsRelative[fingerIdx];\n continue;\n }\n // compare to each possible curl of this specific finger\n for (const [expectedCurl, score] of expectedCurls) {\n if (detectedCurl === expectedCurl) {\n confidence += score * this.weightsRelative[fingerIdx];\n break;\n }\n }\n }\n // same for detected direction of each finger\n for (const fingerIdx in detectedDirections) {\n const detectedDirection = detectedDirections[fingerIdx];\n const expectedDirections = this.directions[fingerIdx];\n if (typeof expectedDirections === 'undefined') {\n // no direction description available for this finger\n // add default confidence of \"1\"\n confidence += this.weightsRelative[fingerIdx];\n continue;\n }\n // compare to each possible direction of this specific finger\n for (const [expectedDirection, score] of expectedDirections) {\n if (detectedDirection === expectedDirection) {\n confidence += score * this.weightsRelative[fingerIdx];\n break;\n }\n }\n }\n return confidence / 10;\n }\n}\n", "/**\n * FingerPose algorithm implementation\n * See `fingerpose.ts` for entry point\n */\n\nimport { Finger, FingerCurl, FingerDirection, FingerGesture } from './fingerdef';\n\nexport const { thumb, index, middle, ring, pinky } = Finger;\nexport const { none, half, full } = FingerCurl;\nexport const { verticalUp, verticalDown, horizontalLeft, horizontalRight, diagonalUpRight, diagonalUpLeft, diagonalDownRight, diagonalDownLeft } = FingerDirection;\n\n// describe thumbs up gesture \uD83D\uDC4D\nconst ThumbsUp = new FingerGesture('thumbs up');\nThumbsUp.curl(thumb, none, 1.0);\nThumbsUp.direction(thumb, verticalUp, 1.0);\nThumbsUp.direction(thumb, diagonalUpLeft, 0.25);\nThumbsUp.direction(thumb, diagonalUpRight, 0.25);\nfor (const finger of [Finger.index, Finger.middle, Finger.ring, Finger.pinky]) {\n ThumbsUp.curl(finger, full, 1.0);\n ThumbsUp.direction(finger, horizontalLeft, 1.0);\n ThumbsUp.direction(finger, horizontalRight, 1.0);\n}\n\n// describe Victory gesture \u270C\uFE0F\nconst Victory = new FingerGesture('victory');\nVictory.curl(thumb, half, 0.5);\nVictory.curl(thumb, none, 0.5);\nVictory.direction(thumb, verticalUp, 1.0);\nVictory.direction(thumb, diagonalUpLeft, 1.0);\nVictory.curl(index, none, 1.0);\nVictory.direction(index, verticalUp, 0.75);\nVictory.direction(index, diagonalUpLeft, 1.0);\nVictory.curl(middle, none, 1.0);\nVictory.direction(middle, verticalUp, 1.0);\nVictory.direction(middle, diagonalUpLeft, 0.75);\nVictory.curl(ring, full, 1.0);\nVictory.direction(ring, verticalUp, 0.2);\nVictory.direction(ring, diagonalUpLeft, 1.0);\nVictory.direction(ring, horizontalLeft, 0.2);\nVictory.curl(pinky, full, 1.0);\nVictory.direction(pinky, verticalUp, 0.2);\nVictory.direction(pinky, diagonalUpLeft, 1.0);\nVictory.direction(pinky, horizontalLeft, 0.2);\nVictory.weight(index, 2);\nVictory.weight(middle, 2);\n\n// describe Point gesture \u270C\uFE0F\nconst Point = new FingerGesture('point');\nPoint.curl(thumb, full, 1.0);\nPoint.curl(index, none, 0.5);\nPoint.curl(middle, full, 0.5);\nPoint.curl(ring, full, 0.5);\nPoint.curl(pinky, full, 0.5);\nPoint.weight(index, 2);\nPoint.weight(middle, 2);\n\n// describe Point gesture \u270C\uFE0F\nconst MiddleFinger = new FingerGesture('middle finger');\nMiddleFinger.curl(thumb, none, 1.0);\nMiddleFinger.curl(index, full, 0.5);\nMiddleFinger.curl(middle, full, 0.5);\nMiddleFinger.curl(ring, full, 0.5);\nMiddleFinger.curl(pinky, full, 0.5);\nMiddleFinger.weight(index, 2);\nMiddleFinger.weight(middle, 2);\n\n// describe Open Palm gesture \u270C\uFE0F\nconst OpenPalm = new FingerGesture('open palm');\nOpenPalm.curl(thumb, none, 0.75);\nOpenPalm.curl(index, none, 0.75);\nOpenPalm.curl(middle, none, 0.75);\nOpenPalm.curl(ring, none, 0.75);\nOpenPalm.curl(pinky, none, 0.75);\n\nexport default [ThumbsUp, Victory, Point, MiddleFinger, OpenPalm];\n", "/**\n * FingerPose algorithm implementation constants\n *\n * Based on: [**FingerPose***](https://github.com/andypotato/fingerpose)\n */\n\n/* eslint-disable camelcase */\n\nimport { Finger, FingerCurl, FingerDirection } from './fingerdef';\nimport Gestures from '../hand/fingergesture';\n\nconst minConfidence = 0.7;\nconst options = {\n // curl estimation\n HALF_CURL_START_LIMIT: 60.0,\n NO_CURL_START_LIMIT: 130.0,\n // direction estimation\n DISTANCE_VOTE_POWER: 1.1,\n SINGLE_ANGLE_VOTE_POWER: 0.9,\n TOTAL_ANGLE_VOTE_POWER: 1.6,\n};\n\nfunction calculateSlope(point1x, point1y, point2x, point2y) {\n const value = (point1y - point2y) / (point1x - point2x);\n let slope = Math.atan(value) * 180 / Math.PI;\n if (slope <= 0) slope = -slope;\n else if (slope > 0) slope = 180 - slope;\n return slope;\n}\n\n// point1, point2 are 2d or 3d point arrays (xy[z])\n// returns either a single scalar (2d) or array of two slopes (3d)\nfunction getSlopes(point1, point2) {\n if (!point1 || !point2) return [0, 0];\n const slopeXY = calculateSlope(point1[0], point1[1], point2[0], point2[1]);\n if (point1.length === 2) return slopeXY;\n const slopeYZ = calculateSlope(point1[1], point1[2], point2[1], point2[2]);\n return [slopeXY, slopeYZ];\n}\n\nfunction angleOrientationAt(angle, weightageAt = 1.0) {\n let isVertical = 0;\n let isDiagonal = 0;\n let isHorizontal = 0;\n if (angle >= 75.0 && angle <= 105.0) isVertical = 1 * weightageAt;\n else if (angle >= 25.0 && angle <= 155.0) isDiagonal = 1 * weightageAt;\n else isHorizontal = 1 * weightageAt;\n return [isVertical, isDiagonal, isHorizontal];\n}\n\nfunction estimateFingerCurl(startPoint, midPoint, endPoint) {\n const start_mid_x_dist = startPoint[0] - midPoint[0];\n const start_end_x_dist = startPoint[0] - endPoint[0];\n const mid_end_x_dist = midPoint[0] - endPoint[0];\n const start_mid_y_dist = startPoint[1] - midPoint[1];\n const start_end_y_dist = startPoint[1] - endPoint[1];\n const mid_end_y_dist = midPoint[1] - endPoint[1];\n const start_mid_z_dist = startPoint[2] - midPoint[2];\n const start_end_z_dist = startPoint[2] - endPoint[2];\n const mid_end_z_dist = midPoint[2] - endPoint[2];\n const start_mid_dist = Math.sqrt(start_mid_x_dist * start_mid_x_dist + start_mid_y_dist * start_mid_y_dist + start_mid_z_dist * start_mid_z_dist);\n const start_end_dist = Math.sqrt(start_end_x_dist * start_end_x_dist + start_end_y_dist * start_end_y_dist + start_end_z_dist * start_end_z_dist);\n const mid_end_dist = Math.sqrt(mid_end_x_dist * mid_end_x_dist + mid_end_y_dist * mid_end_y_dist + mid_end_z_dist * mid_end_z_dist);\n let cos_in = (mid_end_dist * mid_end_dist + start_mid_dist * start_mid_dist - start_end_dist * start_end_dist) / (2 * mid_end_dist * start_mid_dist);\n if (cos_in > 1.0) cos_in = 1.0;\n else if (cos_in < -1.0) cos_in = -1.0;\n let angleOfCurve = Math.acos(cos_in);\n angleOfCurve = (57.2958 * angleOfCurve) % 180;\n let fingerCurl;\n if (angleOfCurve > options.NO_CURL_START_LIMIT) fingerCurl = FingerCurl.none;\n else if (angleOfCurve > options.HALF_CURL_START_LIMIT) fingerCurl = FingerCurl.half;\n else fingerCurl = FingerCurl.full;\n return fingerCurl;\n}\n\nfunction estimateHorizontalDirection(start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x) {\n let estimatedDirection;\n if (max_dist_x === Math.abs(start_end_x_dist)) {\n if (start_end_x_dist > 0) estimatedDirection = FingerDirection.horizontalLeft;\n else estimatedDirection = FingerDirection.horizontalRight;\n } else if (max_dist_x === Math.abs(start_mid_x_dist)) {\n if (start_mid_x_dist > 0) estimatedDirection = FingerDirection.horizontalLeft;\n else estimatedDirection = FingerDirection.horizontalRight;\n } else {\n if (mid_end_x_dist > 0) estimatedDirection = FingerDirection.horizontalLeft;\n else estimatedDirection = FingerDirection.horizontalRight;\n }\n return estimatedDirection;\n}\n\nfunction estimateVerticalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y) {\n let estimatedDirection;\n if (max_dist_y === Math.abs(start_end_y_dist)) {\n if (start_end_y_dist < 0) estimatedDirection = FingerDirection.verticalDown;\n else estimatedDirection = FingerDirection.verticalUp;\n } else if (max_dist_y === Math.abs(start_mid_y_dist)) {\n if (start_mid_y_dist < 0) estimatedDirection = FingerDirection.verticalDown;\n else estimatedDirection = FingerDirection.verticalUp;\n } else {\n if (mid_end_y_dist < 0) estimatedDirection = FingerDirection.verticalDown;\n else estimatedDirection = FingerDirection.verticalUp;\n }\n return estimatedDirection;\n}\n\nfunction estimateDiagonalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y, start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x) {\n let estimatedDirection;\n const reqd_vertical_direction = estimateVerticalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y);\n const reqd_horizontal_direction = estimateHorizontalDirection(start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x);\n if (reqd_vertical_direction === FingerDirection.verticalUp) {\n if (reqd_horizontal_direction === FingerDirection.horizontalLeft) estimatedDirection = FingerDirection.diagonalUpLeft;\n else estimatedDirection = FingerDirection.diagonalUpRight;\n } else {\n if (reqd_horizontal_direction === FingerDirection.horizontalLeft) estimatedDirection = FingerDirection.diagonalDownLeft;\n else estimatedDirection = FingerDirection.diagonalDownRight;\n }\n return estimatedDirection;\n}\n\nfunction calculateFingerDirection(startPoint, midPoint, endPoint, fingerSlopes) {\n const start_mid_x_dist = startPoint[0] - midPoint[0];\n const start_end_x_dist = startPoint[0] - endPoint[0];\n const mid_end_x_dist = midPoint[0] - endPoint[0];\n const start_mid_y_dist = startPoint[1] - midPoint[1];\n const start_end_y_dist = startPoint[1] - endPoint[1];\n const mid_end_y_dist = midPoint[1] - endPoint[1];\n const max_dist_x = Math.max(Math.abs(start_mid_x_dist), Math.abs(start_end_x_dist), Math.abs(mid_end_x_dist));\n const max_dist_y = Math.max(Math.abs(start_mid_y_dist), Math.abs(start_end_y_dist), Math.abs(mid_end_y_dist));\n let voteVertical = 0.0;\n let voteDiagonal = 0.0;\n let voteHorizontal = 0.0;\n const start_end_x_y_dist_ratio = max_dist_y / (max_dist_x + 0.00001);\n if (start_end_x_y_dist_ratio > 1.5) voteVertical += options.DISTANCE_VOTE_POWER;\n else if (start_end_x_y_dist_ratio > 0.66) voteDiagonal += options.DISTANCE_VOTE_POWER;\n else voteHorizontal += options.DISTANCE_VOTE_POWER;\n const start_mid_dist = Math.sqrt(start_mid_x_dist * start_mid_x_dist + start_mid_y_dist * start_mid_y_dist);\n const start_end_dist = Math.sqrt(start_end_x_dist * start_end_x_dist + start_end_y_dist * start_end_y_dist);\n const mid_end_dist = Math.sqrt(mid_end_x_dist * mid_end_x_dist + mid_end_y_dist * mid_end_y_dist);\n const max_dist = Math.max(start_mid_dist, start_end_dist, mid_end_dist);\n let calc_start_point_x = startPoint[0];\n let calc_start_point_y = startPoint[1];\n let calc_end_point_x = endPoint[0];\n let calc_end_point_y = endPoint[1];\n if (max_dist === start_mid_dist) {\n calc_end_point_x = endPoint[0];\n calc_end_point_y = endPoint[1];\n } else if (max_dist === mid_end_dist) {\n calc_start_point_x = midPoint[0];\n calc_start_point_y = midPoint[1];\n }\n const calcStartPoint = [calc_start_point_x, calc_start_point_y];\n const calcEndPoint = [calc_end_point_x, calc_end_point_y];\n const totalAngle = getSlopes(calcStartPoint, calcEndPoint);\n const votes = angleOrientationAt(totalAngle, options.TOTAL_ANGLE_VOTE_POWER);\n voteVertical += votes[0];\n voteDiagonal += votes[1];\n voteHorizontal += votes[2];\n for (const fingerSlope of fingerSlopes) {\n const fingerVotes = angleOrientationAt(fingerSlope, options.SINGLE_ANGLE_VOTE_POWER);\n voteVertical += fingerVotes[0];\n voteDiagonal += fingerVotes[1];\n voteHorizontal += fingerVotes[2];\n }\n // in case of tie, highest preference goes to Vertical,\n // followed by horizontal and then diagonal\n let estimatedDirection;\n if (voteVertical === Math.max(voteVertical, voteDiagonal, voteHorizontal)) {\n estimatedDirection = estimateVerticalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y);\n } else if (voteHorizontal === Math.max(voteDiagonal, voteHorizontal)) {\n estimatedDirection = estimateHorizontalDirection(start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x);\n } else {\n estimatedDirection = estimateDiagonalDirection(start_end_y_dist, start_mid_y_dist, mid_end_y_dist, max_dist_y, start_end_x_dist, start_mid_x_dist, mid_end_x_dist, max_dist_x);\n }\n return estimatedDirection;\n}\n\nfunction estimate(landmarks) {\n // step 1: calculate slopes\n const slopesXY: number[][] = [];\n const slopesYZ: number[][] = [];\n const fingerCurls: number[] = [];\n const fingerDirections: number[] = [];\n if (!landmarks) return { curls: fingerCurls, directions: fingerDirections };\n\n // step 1: calculate slopes\n for (const finger of Finger.all) {\n const points = Finger.getPoints(finger);\n const slopeAtXY: number[] = [];\n const slopeAtYZ: number[] = [];\n for (const point of points) {\n const point1 = landmarks[point[0]];\n const point2 = landmarks[point[1]];\n // calculate single slope\n const slopes = getSlopes(point1, point2);\n const slopeXY = slopes[0];\n const slopeYZ = slopes[1];\n slopeAtXY.push(slopeXY);\n slopeAtYZ.push(slopeYZ);\n }\n slopesXY.push(slopeAtXY);\n slopesYZ.push(slopeAtYZ);\n }\n\n // step 2: calculate orientations\n for (const finger of Finger.all) {\n // start finger predictions from palm - except for thumb\n const pointIndexAt = (finger === Finger.thumb) ? 1 : 0;\n const fingerPointsAt = Finger.getPoints(finger);\n const startPoint = landmarks[fingerPointsAt[pointIndexAt][0]];\n const midPoint = landmarks[fingerPointsAt[pointIndexAt + 1][1]];\n const endPoint = landmarks[fingerPointsAt[3][1]];\n // check if finger is curled\n const fingerCurled = estimateFingerCurl(startPoint, midPoint, endPoint);\n const fingerPosition = calculateFingerDirection(startPoint, midPoint, endPoint, slopesXY[finger].slice(pointIndexAt));\n fingerCurls[finger] = fingerCurled;\n fingerDirections[finger] = fingerPosition;\n }\n return { curls: fingerCurls, directions: fingerDirections };\n}\n\nexport function analyze(keypoints) { // get estimations of curl / direction for each finger\n if (!keypoints || keypoints.length === 0) return null;\n const estimatorRes = estimate(keypoints);\n const landmarks = {};\n for (const fingerIdx of Finger.all) {\n landmarks[Finger.getName(fingerIdx)] = {\n curl: FingerCurl.getName(estimatorRes.curls[fingerIdx]),\n direction: FingerDirection.getName(estimatorRes.directions[fingerIdx]),\n };\n }\n return landmarks;\n}\n\nexport function match(keypoints) { // compare gesture description to each known gesture\n const poses: { name: string, confidence: number }[] = [];\n if (!keypoints || keypoints.length === 0) return poses;\n const estimatorRes = estimate(keypoints);\n for (const gesture of Gestures) {\n const confidence = gesture.matchAgainst(estimatorRes.curls, estimatorRes.directions);\n if (confidence >= minConfidence) poses.push({ name: gesture.name, confidence });\n }\n return poses;\n}\n", "/**\n * Gesture detection algorithm\n */\n\nimport type { GestureResult, BodyResult, FaceResult, HandResult, Point } from '../result';\nimport * as fingerPose from '../hand/fingerpose';\n\n/** face gesture type */\nexport type FaceGesture =\n `facing ${'left' | 'center' | 'right'}`\n | `blink ${'left' | 'right'} eye`\n | `mouth ${number}% open`\n | `head ${'up' | 'down'}`;\n\n/** iris gesture type */\nexport type IrisGesture =\n 'facing center'\n | `looking ${'left' | 'right' | 'up' | 'down'}`\n | 'looking center';\n\n/** body gesture type */\nexport type BodyGesture =\n `leaning ${'left' | 'right'}`\n | `raise ${'left' | 'right'} hand`\n | 'i give up';\n\n/** hand gesture type */\nexport type HandGesture =\n `${'thumb' | 'index' | 'middle' | 'ring' | 'pinky'} forward`\n | `${'thumb' | 'index' | 'middle' | 'ring' | 'pinky'} up`\n | 'victory'\n | 'thumbs up';\n\nexport const body = (res: BodyResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { body: number, gesture: BodyGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n // raising hands\n const leftWrist = res[i].keypoints.find((a) => (a.part === 'leftWrist'));\n const rightWrist = res[i].keypoints.find((a) => (a.part === 'rightWrist'));\n const nose = res[i].keypoints.find((a) => (a.part === 'nose'));\n if (nose && leftWrist && rightWrist && (leftWrist.position[1] < nose.position[1]) && (rightWrist.position[1] < nose.position[1])) gestures.push({ body: i, gesture: 'i give up' });\n else if (nose && leftWrist && (leftWrist.position[1] < nose.position[1])) gestures.push({ body: i, gesture: 'raise left hand' });\n else if (nose && rightWrist && (rightWrist.position[1] < nose.position[1])) gestures.push({ body: i, gesture: 'raise right hand' });\n\n // leaning\n const leftShoulder = res[i].keypoints.find((a) => (a.part === 'leftShoulder'));\n const rightShoulder = res[i].keypoints.find((a) => (a.part === 'rightShoulder'));\n if (leftShoulder && rightShoulder && Math.abs(leftShoulder.positionRaw[1] - rightShoulder.positionRaw[1]) > 0.1) {\n gestures.push({ body: i, gesture: `leaning ${(leftShoulder.position[1] > rightShoulder.position[1]) ? 'left' : 'right'}` });\n }\n }\n return gestures;\n};\n\nexport const face = (res: FaceResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { face: number, gesture: FaceGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n if (res[i].mesh && res[i].mesh.length > 450) {\n const zDiff = (res[i].mesh[33][2] || 0) - (res[i].mesh[263][2] || 0);\n const xDiff = res[i].mesh[33][0] - res[i].mesh[263][0];\n if (Math.abs(zDiff / xDiff) <= 0.15) gestures.push({ face: i, gesture: 'facing center' });\n else gestures.push({ face: i, gesture: `facing ${zDiff < 0 ? 'left' : 'right'}` });\n const openLeft = Math.abs(res[i].mesh[374][1] - res[i].mesh[386][1]) / Math.abs(res[i].mesh[443][1] - res[i].mesh[450][1]); // center of eye inner lid y coord div center of wider eye border y coord\n if (openLeft < 0.2) gestures.push({ face: i, gesture: 'blink left eye' });\n const openRight = Math.abs(res[i].mesh[145][1] - res[i].mesh[159][1]) / Math.abs(res[i].mesh[223][1] - res[i].mesh[230][1]); // center of eye inner lid y coord div center of wider eye border y coord\n if (openRight < 0.2) gestures.push({ face: i, gesture: 'blink right eye' });\n const mouthOpen = Math.min(100, 500 * Math.abs(res[i].mesh[13][1] - res[i].mesh[14][1]) / Math.abs(res[i].mesh[10][1] - res[i].mesh[152][1]));\n if (mouthOpen > 10) gestures.push({ face: i, gesture: `mouth ${Math.trunc(mouthOpen)}% open` });\n const chinDepth = res[i].mesh[152][2] || 0;\n if (Math.abs(chinDepth) > 10) gestures.push({ face: i, gesture: `head ${chinDepth < 0 ? 'up' : 'down'}` });\n }\n }\n return gestures;\n};\n\nexport const iris = (res: FaceResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { iris: number, gesture: IrisGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n if (!res[i].annotations?.leftEyeIris?.[0] || !res[i].annotations?.rightEyeIris?.[0]) continue;\n const sizeXLeft = res[i].annotations.leftEyeIris[3][0] - res[i].annotations.leftEyeIris[1][0];\n const sizeYLeft = res[i].annotations.leftEyeIris[4][1] - res[i].annotations.leftEyeIris[2][1];\n const areaLeft = Math.abs(sizeXLeft * sizeYLeft);\n\n const sizeXRight = res[i].annotations.rightEyeIris[3][0] - res[i].annotations.rightEyeIris[1][0];\n const sizeYRight = res[i].annotations.rightEyeIris[4][1] - res[i].annotations.rightEyeIris[2][1];\n const areaRight = Math.abs(sizeXRight * sizeYRight);\n\n let center = false;\n const difference = Math.abs(areaLeft - areaRight) / Math.max(areaLeft, areaRight);\n if (difference < 0.25) {\n center = true;\n gestures.push({ iris: i, gesture: 'facing center' });\n }\n\n const leftIrisCenterX = Math.abs(res[i].mesh[263][0] - res[i].annotations.leftEyeIris[0][0]) / res[i].box[2];\n const rightIrisCenterX = Math.abs(res[i].mesh[33][0] - res[i].annotations.rightEyeIris[0][0]) / res[i].box[2];\n if (leftIrisCenterX > 0.06 || rightIrisCenterX > 0.06) center = false;\n if (leftIrisCenterX > rightIrisCenterX) { // check eye with bigger offset\n if (rightIrisCenterX > 0.04) gestures.push({ iris: i, gesture: 'looking right' });\n } else {\n if (leftIrisCenterX > 0.04) gestures.push({ iris: i, gesture: 'looking left' });\n }\n\n const rightIrisCenterY = Math.abs(res[i].mesh[145][1] - res[i].annotations.rightEyeIris[0][1]) / res[i].box[3];\n const leftIrisCenterY = Math.abs(res[i].mesh[374][1] - res[i].annotations.leftEyeIris[0][1]) / res[i].box[3];\n if (leftIrisCenterY < 0.01 || rightIrisCenterY < 0.01 || leftIrisCenterY > 0.022 || rightIrisCenterY > 0.022) center = false;\n if (leftIrisCenterY < 0.01 || rightIrisCenterY < 0.01) gestures.push({ iris: i, gesture: 'looking down' });\n if (leftIrisCenterY > 0.022 || rightIrisCenterY > 0.022) gestures.push({ iris: i, gesture: 'looking up' });\n\n // still center;\n if (center) gestures.push({ iris: i, gesture: 'looking center' });\n }\n return gestures;\n};\n\nexport const hand = (res: HandResult[]): GestureResult[] => {\n if (!res) return [];\n const gestures: { hand: number, gesture: HandGesture }[] = [];\n for (let i = 0; i < res.length; i++) {\n const fingers: { name: string, position: Point }[] = [];\n if (res[i].annotations) {\n for (const [finger, pos] of Object.entries(res[i].annotations)) {\n if (finger !== 'palmBase' && Array.isArray(pos) && pos[0]) fingers.push({ name: finger.toLowerCase(), position: pos[0] }); // get tip of each finger\n }\n }\n if (fingers && fingers.length > 0) {\n const closest = fingers.reduce((best, a) => ((best.position[2] || 0) < (a.position[2] || 0) ? best : a));\n gestures.push({ hand: i, gesture: `${closest.name} forward` as HandGesture });\n const highest = fingers.reduce((best, a) => (best.position[1] < a.position[1] ? best : a));\n gestures.push({ hand: i, gesture: `${highest.name} up` as HandGesture });\n }\n if (res[i].keypoints) {\n const poses = fingerPose.match(res[i].keypoints);\n for (const pose of poses) gestures.push({ hand: i, gesture: pose.name as HandGesture });\n }\n }\n return gestures;\n};\n", "import * as tf from 'dist/tfjs.esm.js';\nimport type { Point } from '../result';\n\nexport function getBoxSize(box) {\n return [\n Math.abs(box.endPoint[0] - box.startPoint[0]),\n Math.abs(box.endPoint[1] - box.startPoint[1]),\n ];\n}\n\nexport function getBoxCenter(box) {\n return [\n box.startPoint[0] + (box.endPoint[0] - box.startPoint[0]) / 2,\n box.startPoint[1] + (box.endPoint[1] - box.startPoint[1]) / 2,\n ];\n}\n\nexport function cutBoxFromImageAndResize(box, image, cropSize) {\n const h = image.shape[1];\n const w = image.shape[2];\n const boxes = [[\n box.startPoint[1] / h,\n box.startPoint[0] / w,\n box.endPoint[1] / h,\n box.endPoint[0] / w,\n ]];\n return tf.image.cropAndResize(image, boxes, [0], cropSize);\n}\n\nexport function scaleBoxCoordinates(box, factor) {\n const startPoint = [box.startPoint[0] * factor[0], box.startPoint[1] * factor[1]] as Point;\n const endPoint = [box.endPoint[0] * factor[0], box.endPoint[1] * factor[1]] as Point;\n const palmLandmarks = box.palmLandmarks.map((coord) => {\n const scaledCoord = [coord[0] * factor[0], coord[1] * factor[1]];\n return scaledCoord;\n });\n return { startPoint, endPoint, palmLandmarks, confidence: box.confidence };\n}\n\nexport function enlargeBox(box, factor = 1.5) {\n const center = getBoxCenter(box);\n const size = getBoxSize(box);\n const newHalfSize = [factor * size[0] / 2, factor * size[1] / 2];\n const startPoint = [center[0] - newHalfSize[0], center[1] - newHalfSize[1]] as Point;\n const endPoint = [center[0] + newHalfSize[0], center[1] + newHalfSize[1]] as Point;\n return { startPoint, endPoint, palmLandmarks: box.palmLandmarks };\n}\n\nexport function squarifyBox(box) {\n const centers = getBoxCenter(box);\n const size = getBoxSize(box);\n const maxEdge = Math.max(...size);\n const halfSize = maxEdge / 2;\n const startPoint = [centers[0] - halfSize, centers[1] - halfSize] as Point;\n const endPoint = [centers[0] + halfSize, centers[1] + halfSize] as Point;\n return { startPoint, endPoint, palmLandmarks: box.palmLandmarks };\n}\n\nexport function shiftBox(box, shiftFactor) {\n const boxSize = [\n box.endPoint[0] - box.startPoint[0],\n box.endPoint[1] - box.startPoint[1],\n ];\n const shiftVector = [boxSize[0] * shiftFactor[0], boxSize[1] * shiftFactor[1]];\n const startPoint = [box.startPoint[0] + shiftVector[0], box.startPoint[1] + shiftVector[1]] as Point;\n const endPoint = [box.endPoint[0] + shiftVector[0], box.endPoint[1] + shiftVector[1]] as Point;\n return { startPoint, endPoint, palmLandmarks: box.palmLandmarks };\n}\n\nexport function normalizeRadians(angle) {\n return angle - 2 * Math.PI * Math.floor((angle + Math.PI) / (2 * Math.PI));\n}\n\nexport function computeRotation(point1, point2) {\n const radians = Math.PI / 2 - Math.atan2(-(point2[1] - point1[1]), point2[0] - point1[0]);\n return normalizeRadians(radians);\n}\n\nexport const buildTranslationMatrix = (x, y) => [[1, 0, x], [0, 1, y], [0, 0, 1]];\n\nexport function dot(v1, v2) {\n let product = 0;\n for (let i = 0; i < v1.length; i++) {\n product += v1[i] * v2[i];\n }\n return product;\n}\n\nexport function getColumnFrom2DArr(arr, columnIndex) {\n const column: number[] = [];\n for (let i = 0; i < arr.length; i++) {\n column.push(arr[i][columnIndex]);\n }\n return column;\n}\n\nexport function multiplyTransformMatrices(mat1, mat2) {\n const product: number[][] = [];\n const size = mat1.length;\n for (let row = 0; row < size; row++) {\n product.push([]);\n for (let col = 0; col < size; col++) {\n product[row].push(dot(mat1[row], getColumnFrom2DArr(mat2, col)));\n }\n }\n return product;\n}\n\nexport function buildRotationMatrix(rotation, center) {\n const cosA = Math.cos(rotation);\n const sinA = Math.sin(rotation);\n const rotationMatrix = [[cosA, -sinA, 0], [sinA, cosA, 0], [0, 0, 1]];\n const translationMatrix = buildTranslationMatrix(center[0], center[1]);\n const translationTimesRotation = multiplyTransformMatrices(translationMatrix, rotationMatrix);\n const negativeTranslationMatrix = buildTranslationMatrix(-center[0], -center[1]);\n return multiplyTransformMatrices(translationTimesRotation, negativeTranslationMatrix);\n}\n\nexport function invertTransformMatrix(matrix) {\n const rotationComponent = [[matrix[0][0], matrix[1][0]], [matrix[0][1], matrix[1][1]]];\n const translationComponent = [matrix[0][2], matrix[1][2]];\n const invertedTranslation = [\n -dot(rotationComponent[0], translationComponent),\n -dot(rotationComponent[1], translationComponent),\n ];\n return [\n rotationComponent[0].concat(invertedTranslation[0]),\n rotationComponent[1].concat(invertedTranslation[1]),\n [0, 0, 1],\n ];\n}\n\nexport function rotatePoint(homogeneousCoordinate, rotationMatrix) {\n return [\n dot(homogeneousCoordinate, rotationMatrix[0]),\n dot(homogeneousCoordinate, rotationMatrix[1]),\n ];\n}\n", "/**\n * HandPose model implementation constants\n * See `handpose.ts` for entry point\n */\n\nexport const anchors = [\n { x: 0.015625, y: 0.015625 },\n { x: 0.015625, y: 0.015625 },\n { x: 0.046875, y: 0.015625 },\n { x: 0.046875, y: 0.015625 },\n { x: 0.078125, y: 0.015625 },\n { x: 0.078125, y: 0.015625 },\n { x: 0.109375, y: 0.015625 },\n { x: 0.109375, y: 0.015625 },\n { x: 0.140625, y: 0.015625 },\n { x: 0.140625, y: 0.015625 },\n { x: 0.171875, y: 0.015625 },\n { x: 0.171875, y: 0.015625 },\n { x: 0.203125, y: 0.015625 },\n { x: 0.203125, y: 0.015625 },\n { x: 0.234375, y: 0.015625 },\n { x: 0.234375, y: 0.015625 },\n { x: 0.265625, y: 0.015625 },\n { x: 0.265625, y: 0.015625 },\n { x: 0.296875, y: 0.015625 },\n { x: 0.296875, y: 0.015625 },\n { x: 0.328125, y: 0.015625 },\n { x: 0.328125, y: 0.015625 },\n { x: 0.359375, y: 0.015625 },\n { x: 0.359375, y: 0.015625 },\n { x: 0.390625, y: 0.015625 },\n { x: 0.390625, y: 0.015625 },\n { x: 0.421875, y: 0.015625 },\n { x: 0.421875, y: 0.015625 },\n { x: 0.453125, y: 0.015625 },\n { x: 0.453125, y: 0.015625 },\n { x: 0.484375, y: 0.015625 },\n { x: 0.484375, y: 0.015625 },\n { x: 0.515625, y: 0.015625 },\n { x: 0.515625, y: 0.015625 },\n { x: 0.546875, y: 0.015625 },\n { x: 0.546875, y: 0.015625 },\n { x: 0.578125, y: 0.015625 },\n { x: 0.578125, y: 0.015625 },\n { x: 0.609375, y: 0.015625 },\n { x: 0.609375, y: 0.015625 },\n { x: 0.640625, y: 0.015625 },\n { x: 0.640625, y: 0.015625 },\n { x: 0.671875, y: 0.015625 },\n { x: 0.671875, y: 0.015625 },\n { x: 0.703125, y: 0.015625 },\n { x: 0.703125, y: 0.015625 },\n { x: 0.734375, y: 0.015625 },\n { x: 0.734375, y: 0.015625 },\n { x: 0.765625, y: 0.015625 },\n { x: 0.765625, y: 0.015625 },\n { x: 0.796875, y: 0.015625 },\n { x: 0.796875, y: 0.015625 },\n { x: 0.828125, y: 0.015625 },\n { x: 0.828125, y: 0.015625 },\n { x: 0.859375, y: 0.015625 },\n { x: 0.859375, y: 0.015625 },\n { x: 0.890625, y: 0.015625 },\n { x: 0.890625, y: 0.015625 },\n { x: 0.921875, y: 0.015625 },\n { x: 0.921875, y: 0.015625 },\n { x: 0.953125, y: 0.015625 },\n { x: 0.953125, y: 0.015625 },\n { x: 0.984375, y: 0.015625 },\n { x: 0.984375, y: 0.015625 },\n { x: 0.015625, y: 0.046875 },\n { x: 0.015625, y: 0.046875 },\n { x: 0.046875, y: 0.046875 },\n { x: 0.046875, y: 0.046875 },\n { x: 0.078125, y: 0.046875 },\n { x: 0.078125, y: 0.046875 },\n { x: 0.109375, y: 0.046875 },\n { x: 0.109375, y: 0.046875 },\n { x: 0.140625, y: 0.046875 },\n { x: 0.140625, y: 0.046875 },\n { x: 0.171875, y: 0.046875 },\n { x: 0.171875, y: 0.046875 },\n { x: 0.203125, y: 0.046875 },\n { x: 0.203125, y: 0.046875 },\n { x: 0.234375, y: 0.046875 },\n { x: 0.234375, y: 0.046875 },\n { x: 0.265625, y: 0.046875 },\n { x: 0.265625, y: 0.046875 },\n { x: 0.296875, y: 0.046875 },\n { x: 0.296875, y: 0.046875 },\n { x: 0.328125, y: 0.046875 },\n { x: 0.328125, y: 0.046875 },\n { x: 0.359375, y: 0.046875 },\n { x: 0.359375, y: 0.046875 },\n { x: 0.390625, y: 0.046875 },\n { x: 0.390625, y: 0.046875 },\n { x: 0.421875, y: 0.046875 },\n { x: 0.421875, y: 0.046875 },\n { x: 0.453125, y: 0.046875 },\n { x: 0.453125, y: 0.046875 },\n { x: 0.484375, y: 0.046875 },\n { x: 0.484375, y: 0.046875 },\n { x: 0.515625, y: 0.046875 },\n { x: 0.515625, y: 0.046875 },\n { x: 0.546875, y: 0.046875 },\n { x: 0.546875, y: 0.046875 },\n { x: 0.578125, y: 0.046875 },\n { x: 0.578125, y: 0.046875 },\n { x: 0.609375, y: 0.046875 },\n { x: 0.609375, y: 0.046875 },\n { x: 0.640625, y: 0.046875 },\n { x: 0.640625, y: 0.046875 },\n { x: 0.671875, y: 0.046875 },\n { x: 0.671875, y: 0.046875 },\n { x: 0.703125, y: 0.046875 },\n { x: 0.703125, y: 0.046875 },\n { x: 0.734375, y: 0.046875 },\n { x: 0.734375, y: 0.046875 },\n { x: 0.765625, y: 0.046875 },\n { x: 0.765625, y: 0.046875 },\n { x: 0.796875, y: 0.046875 },\n { x: 0.796875, y: 0.046875 },\n { x: 0.828125, y: 0.046875 },\n { x: 0.828125, y: 0.046875 },\n { x: 0.859375, y: 0.046875 },\n { x: 0.859375, y: 0.046875 },\n { x: 0.890625, y: 0.046875 },\n { x: 0.890625, y: 0.046875 },\n { x: 0.921875, y: 0.046875 },\n { x: 0.921875, y: 0.046875 },\n { x: 0.953125, y: 0.046875 },\n { x: 0.953125, y: 0.046875 },\n { x: 0.984375, y: 0.046875 },\n { x: 0.984375, y: 0.046875 },\n { x: 0.015625, y: 0.078125 },\n { x: 0.015625, y: 0.078125 },\n { x: 0.046875, y: 0.078125 },\n { x: 0.046875, y: 0.078125 },\n { x: 0.078125, y: 0.078125 },\n { x: 0.078125, y: 0.078125 },\n { x: 0.109375, y: 0.078125 },\n { x: 0.109375, y: 0.078125 },\n { x: 0.140625, y: 0.078125 },\n { x: 0.140625, y: 0.078125 },\n { x: 0.171875, y: 0.078125 },\n { x: 0.171875, y: 0.078125 },\n { x: 0.203125, y: 0.078125 },\n { x: 0.203125, y: 0.078125 },\n { x: 0.234375, y: 0.078125 },\n { x: 0.234375, y: 0.078125 },\n { x: 0.265625, y: 0.078125 },\n { x: 0.265625, y: 0.078125 },\n { x: 0.296875, y: 0.078125 },\n { x: 0.296875, y: 0.078125 },\n { x: 0.328125, y: 0.078125 },\n { x: 0.328125, y: 0.078125 },\n { x: 0.359375, y: 0.078125 },\n { x: 0.359375, y: 0.078125 },\n { x: 0.390625, y: 0.078125 },\n { x: 0.390625, y: 0.078125 },\n { x: 0.421875, y: 0.078125 },\n { x: 0.421875, y: 0.078125 },\n { x: 0.453125, y: 0.078125 },\n { x: 0.453125, y: 0.078125 },\n { x: 0.484375, y: 0.078125 },\n { x: 0.484375, y: 0.078125 },\n { x: 0.515625, y: 0.078125 },\n { x: 0.515625, y: 0.078125 },\n { x: 0.546875, y: 0.078125 },\n { x: 0.546875, y: 0.078125 },\n { x: 0.578125, y: 0.078125 },\n { x: 0.578125, y: 0.078125 },\n { x: 0.609375, y: 0.078125 },\n { x: 0.609375, y: 0.078125 },\n { x: 0.640625, y: 0.078125 },\n { x: 0.640625, y: 0.078125 },\n { x: 0.671875, y: 0.078125 },\n { x: 0.671875, y: 0.078125 },\n { x: 0.703125, y: 0.078125 },\n { x: 0.703125, y: 0.078125 },\n { x: 0.734375, y: 0.078125 },\n { x: 0.734375, y: 0.078125 },\n { x: 0.765625, y: 0.078125 },\n { x: 0.765625, y: 0.078125 },\n { x: 0.796875, y: 0.078125 },\n { x: 0.796875, y: 0.078125 },\n { x: 0.828125, y: 0.078125 },\n { x: 0.828125, y: 0.078125 },\n { x: 0.859375, y: 0.078125 },\n { x: 0.859375, y: 0.078125 },\n { x: 0.890625, y: 0.078125 },\n { x: 0.890625, y: 0.078125 },\n { x: 0.921875, y: 0.078125 },\n { x: 0.921875, y: 0.078125 },\n { x: 0.953125, y: 0.078125 },\n { x: 0.953125, y: 0.078125 },\n { x: 0.984375, y: 0.078125 },\n { x: 0.984375, y: 0.078125 },\n { x: 0.015625, y: 0.109375 },\n { x: 0.015625, y: 0.109375 },\n { x: 0.046875, y: 0.109375 },\n { x: 0.046875, y: 0.109375 },\n { x: 0.078125, y: 0.109375 },\n { x: 0.078125, y: 0.109375 },\n { x: 0.109375, y: 0.109375 },\n { x: 0.109375, y: 0.109375 },\n { x: 0.140625, y: 0.109375 },\n { x: 0.140625, y: 0.109375 },\n { x: 0.171875, y: 0.109375 },\n { x: 0.171875, y: 0.109375 },\n { x: 0.203125, y: 0.109375 },\n { x: 0.203125, y: 0.109375 },\n { x: 0.234375, y: 0.109375 },\n { x: 0.234375, y: 0.109375 },\n { x: 0.265625, y: 0.109375 },\n { x: 0.265625, y: 0.109375 },\n { x: 0.296875, y: 0.109375 },\n { x: 0.296875, y: 0.109375 },\n { x: 0.328125, y: 0.109375 },\n { x: 0.328125, y: 0.109375 },\n { x: 0.359375, y: 0.109375 },\n { x: 0.359375, y: 0.109375 },\n { x: 0.390625, y: 0.109375 },\n { x: 0.390625, y: 0.109375 },\n { x: 0.421875, y: 0.109375 },\n { x: 0.421875, y: 0.109375 },\n { x: 0.453125, y: 0.109375 },\n { x: 0.453125, y: 0.109375 },\n { x: 0.484375, y: 0.109375 },\n { x: 0.484375, y: 0.109375 },\n { x: 0.515625, y: 0.109375 },\n { x: 0.515625, y: 0.109375 },\n { x: 0.546875, y: 0.109375 },\n { x: 0.546875, y: 0.109375 },\n { x: 0.578125, y: 0.109375 },\n { x: 0.578125, y: 0.109375 },\n { x: 0.609375, y: 0.109375 },\n { x: 0.609375, y: 0.109375 },\n { x: 0.640625, y: 0.109375 },\n { x: 0.640625, y: 0.109375 },\n { x: 0.671875, y: 0.109375 },\n { x: 0.671875, y: 0.109375 },\n { x: 0.703125, y: 0.109375 },\n { x: 0.703125, y: 0.109375 },\n { x: 0.734375, y: 0.109375 },\n { x: 0.734375, y: 0.109375 },\n { x: 0.765625, y: 0.109375 },\n { x: 0.765625, y: 0.109375 },\n { x: 0.796875, y: 0.109375 },\n { x: 0.796875, y: 0.109375 },\n { x: 0.828125, y: 0.109375 },\n { x: 0.828125, y: 0.109375 },\n { x: 0.859375, y: 0.109375 },\n { x: 0.859375, y: 0.109375 },\n { x: 0.890625, y: 0.109375 },\n { x: 0.890625, y: 0.109375 },\n { x: 0.921875, y: 0.109375 },\n { x: 0.921875, y: 0.109375 },\n { x: 0.953125, y: 0.109375 },\n { x: 0.953125, y: 0.109375 },\n { x: 0.984375, y: 0.109375 },\n { x: 0.984375, y: 0.109375 },\n { x: 0.015625, y: 0.140625 },\n { x: 0.015625, y: 0.140625 },\n { x: 0.046875, y: 0.140625 },\n { x: 0.046875, y: 0.140625 },\n { x: 0.078125, y: 0.140625 },\n { x: 0.078125, y: 0.140625 },\n { x: 0.109375, y: 0.140625 },\n { x: 0.109375, y: 0.140625 },\n { x: 0.140625, y: 0.140625 },\n { x: 0.140625, y: 0.140625 },\n { x: 0.171875, y: 0.140625 },\n { x: 0.171875, y: 0.140625 },\n { x: 0.203125, y: 0.140625 },\n { x: 0.203125, y: 0.140625 },\n { x: 0.234375, y: 0.140625 },\n { x: 0.234375, y: 0.140625 },\n { x: 0.265625, y: 0.140625 },\n { x: 0.265625, y: 0.140625 },\n { x: 0.296875, y: 0.140625 },\n { x: 0.296875, y: 0.140625 },\n { x: 0.328125, y: 0.140625 },\n { x: 0.328125, y: 0.140625 },\n { x: 0.359375, y: 0.140625 },\n { x: 0.359375, y: 0.140625 },\n { x: 0.390625, y: 0.140625 },\n { x: 0.390625, y: 0.140625 },\n { x: 0.421875, y: 0.140625 },\n { x: 0.421875, y: 0.140625 },\n { x: 0.453125, y: 0.140625 },\n { x: 0.453125, y: 0.140625 },\n { x: 0.484375, y: 0.140625 },\n { x: 0.484375, y: 0.140625 },\n { x: 0.515625, y: 0.140625 },\n { x: 0.515625, y: 0.140625 },\n { x: 0.546875, y: 0.140625 },\n { x: 0.546875, y: 0.140625 },\n { x: 0.578125, y: 0.140625 },\n { x: 0.578125, y: 0.140625 },\n { x: 0.609375, y: 0.140625 },\n { x: 0.609375, y: 0.140625 },\n { x: 0.640625, y: 0.140625 },\n { x: 0.640625, y: 0.140625 },\n { x: 0.671875, y: 0.140625 },\n { x: 0.671875, y: 0.140625 },\n { x: 0.703125, y: 0.140625 },\n { x: 0.703125, y: 0.140625 },\n { x: 0.734375, y: 0.140625 },\n { x: 0.734375, y: 0.140625 },\n { x: 0.765625, y: 0.140625 },\n { x: 0.765625, y: 0.140625 },\n { x: 0.796875, y: 0.140625 },\n { x: 0.796875, y: 0.140625 },\n { x: 0.828125, y: 0.140625 },\n { x: 0.828125, y: 0.140625 },\n { x: 0.859375, y: 0.140625 },\n { x: 0.859375, y: 0.140625 },\n { x: 0.890625, y: 0.140625 },\n { x: 0.890625, y: 0.140625 },\n { x: 0.921875, y: 0.140625 },\n { x: 0.921875, y: 0.140625 },\n { x: 0.953125, y: 0.140625 },\n { x: 0.953125, y: 0.140625 },\n { x: 0.984375, y: 0.140625 },\n { x: 0.984375, y: 0.140625 },\n { x: 0.015625, y: 0.171875 },\n { x: 0.015625, y: 0.171875 },\n { x: 0.046875, y: 0.171875 },\n { x: 0.046875, y: 0.171875 },\n { x: 0.078125, y: 0.171875 },\n { x: 0.078125, y: 0.171875 },\n { x: 0.109375, y: 0.171875 },\n { x: 0.109375, y: 0.171875 },\n { x: 0.140625, y: 0.171875 },\n { x: 0.140625, y: 0.171875 },\n { x: 0.171875, y: 0.171875 },\n { x: 0.171875, y: 0.171875 },\n { x: 0.203125, y: 0.171875 },\n { x: 0.203125, y: 0.171875 },\n { x: 0.234375, y: 0.171875 },\n { x: 0.234375, y: 0.171875 },\n { x: 0.265625, y: 0.171875 },\n { x: 0.265625, y: 0.171875 },\n { x: 0.296875, y: 0.171875 },\n { x: 0.296875, y: 0.171875 },\n { x: 0.328125, y: 0.171875 },\n { x: 0.328125, y: 0.171875 },\n { x: 0.359375, y: 0.171875 },\n { x: 0.359375, y: 0.171875 },\n { x: 0.390625, y: 0.171875 },\n { x: 0.390625, y: 0.171875 },\n { x: 0.421875, y: 0.171875 },\n { x: 0.421875, y: 0.171875 },\n { x: 0.453125, y: 0.171875 },\n { x: 0.453125, y: 0.171875 },\n { x: 0.484375, y: 0.171875 },\n { x: 0.484375, y: 0.171875 },\n { x: 0.515625, y: 0.171875 },\n { x: 0.515625, y: 0.171875 },\n { x: 0.546875, y: 0.171875 },\n { x: 0.546875, y: 0.171875 },\n { x: 0.578125, y: 0.171875 },\n { x: 0.578125, y: 0.171875 },\n { x: 0.609375, y: 0.171875 },\n { x: 0.609375, y: 0.171875 },\n { x: 0.640625, y: 0.171875 },\n { x: 0.640625, y: 0.171875 },\n { x: 0.671875, y: 0.171875 },\n { x: 0.671875, y: 0.171875 },\n { x: 0.703125, y: 0.171875 },\n { x: 0.703125, y: 0.171875 },\n { x: 0.734375, y: 0.171875 },\n { x: 0.734375, y: 0.171875 },\n { x: 0.765625, y: 0.171875 },\n { x: 0.765625, y: 0.171875 },\n { x: 0.796875, y: 0.171875 },\n { x: 0.796875, y: 0.171875 },\n { x: 0.828125, y: 0.171875 },\n { x: 0.828125, y: 0.171875 },\n { x: 0.859375, y: 0.171875 },\n { x: 0.859375, y: 0.171875 },\n { x: 0.890625, y: 0.171875 },\n { x: 0.890625, y: 0.171875 },\n { x: 0.921875, y: 0.171875 },\n { x: 0.921875, y: 0.171875 },\n { x: 0.953125, y: 0.171875 },\n { x: 0.953125, y: 0.171875 },\n { x: 0.984375, y: 0.171875 },\n { x: 0.984375, y: 0.171875 },\n { x: 0.015625, y: 0.203125 },\n { x: 0.015625, y: 0.203125 },\n { x: 0.046875, y: 0.203125 },\n { x: 0.046875, y: 0.203125 },\n { x: 0.078125, y: 0.203125 },\n { x: 0.078125, y: 0.203125 },\n { x: 0.109375, y: 0.203125 },\n { x: 0.109375, y: 0.203125 },\n { x: 0.140625, y: 0.203125 },\n { x: 0.140625, y: 0.203125 },\n { x: 0.171875, y: 0.203125 },\n { x: 0.171875, y: 0.203125 },\n { x: 0.203125, y: 0.203125 },\n { x: 0.203125, y: 0.203125 },\n { x: 0.234375, y: 0.203125 },\n { x: 0.234375, y: 0.203125 },\n { x: 0.265625, y: 0.203125 },\n { x: 0.265625, y: 0.203125 },\n { x: 0.296875, y: 0.203125 },\n { x: 0.296875, y: 0.203125 },\n { x: 0.328125, y: 0.203125 },\n { x: 0.328125, y: 0.203125 },\n { x: 0.359375, y: 0.203125 },\n { x: 0.359375, y: 0.203125 },\n { x: 0.390625, y: 0.203125 },\n { x: 0.390625, y: 0.203125 },\n { x: 0.421875, y: 0.203125 },\n { x: 0.421875, y: 0.203125 },\n { x: 0.453125, y: 0.203125 },\n { x: 0.453125, y: 0.203125 },\n { x: 0.484375, y: 0.203125 },\n { x: 0.484375, y: 0.203125 },\n { x: 0.515625, y: 0.203125 },\n { x: 0.515625, y: 0.203125 },\n { x: 0.546875, y: 0.203125 },\n { x: 0.546875, y: 0.203125 },\n { x: 0.578125, y: 0.203125 },\n { x: 0.578125, y: 0.203125 },\n { x: 0.609375, y: 0.203125 },\n { x: 0.609375, y: 0.203125 },\n { x: 0.640625, y: 0.203125 },\n { x: 0.640625, y: 0.203125 },\n { x: 0.671875, y: 0.203125 },\n { x: 0.671875, y: 0.203125 },\n { x: 0.703125, y: 0.203125 },\n { x: 0.703125, y: 0.203125 },\n { x: 0.734375, y: 0.203125 },\n { x: 0.734375, y: 0.203125 },\n { x: 0.765625, y: 0.203125 },\n { x: 0.765625, y: 0.203125 },\n { x: 0.796875, y: 0.203125 },\n { x: 0.796875, y: 0.203125 },\n { x: 0.828125, y: 0.203125 },\n { x: 0.828125, y: 0.203125 },\n { x: 0.859375, y: 0.203125 },\n { x: 0.859375, y: 0.203125 },\n { x: 0.890625, y: 0.203125 },\n { x: 0.890625, y: 0.203125 },\n { x: 0.921875, y: 0.203125 },\n { x: 0.921875, y: 0.203125 },\n { x: 0.953125, y: 0.203125 },\n { x: 0.953125, y: 0.203125 },\n { x: 0.984375, y: 0.203125 },\n { x: 0.984375, y: 0.203125 },\n { x: 0.015625, y: 0.234375 },\n { x: 0.015625, y: 0.234375 },\n { x: 0.046875, y: 0.234375 },\n { x: 0.046875, y: 0.234375 },\n { x: 0.078125, y: 0.234375 },\n { x: 0.078125, y: 0.234375 },\n { x: 0.109375, y: 0.234375 },\n { x: 0.109375, y: 0.234375 },\n { x: 0.140625, y: 0.234375 },\n { x: 0.140625, y: 0.234375 },\n { x: 0.171875, y: 0.234375 },\n { x: 0.171875, y: 0.234375 },\n { x: 0.203125, y: 0.234375 },\n { x: 0.203125, y: 0.234375 },\n { x: 0.234375, y: 0.234375 },\n { x: 0.234375, y: 0.234375 },\n { x: 0.265625, y: 0.234375 },\n { x: 0.265625, y: 0.234375 },\n { x: 0.296875, y: 0.234375 },\n { x: 0.296875, y: 0.234375 },\n { x: 0.328125, y: 0.234375 },\n { x: 0.328125, y: 0.234375 },\n { x: 0.359375, y: 0.234375 },\n { x: 0.359375, y: 0.234375 },\n { x: 0.390625, y: 0.234375 },\n { x: 0.390625, y: 0.234375 },\n { x: 0.421875, y: 0.234375 },\n { x: 0.421875, y: 0.234375 },\n { x: 0.453125, y: 0.234375 },\n { x: 0.453125, y: 0.234375 },\n { x: 0.484375, y: 0.234375 },\n { x: 0.484375, y: 0.234375 },\n { x: 0.515625, y: 0.234375 },\n { x: 0.515625, y: 0.234375 },\n { x: 0.546875, y: 0.234375 },\n { x: 0.546875, y: 0.234375 },\n { x: 0.578125, y: 0.234375 },\n { x: 0.578125, y: 0.234375 },\n { x: 0.609375, y: 0.234375 },\n { x: 0.609375, y: 0.234375 },\n { x: 0.640625, y: 0.234375 },\n { x: 0.640625, y: 0.234375 },\n { x: 0.671875, y: 0.234375 },\n { x: 0.671875, y: 0.234375 },\n { x: 0.703125, y: 0.234375 },\n { x: 0.703125, y: 0.234375 },\n { x: 0.734375, y: 0.234375 },\n { x: 0.734375, y: 0.234375 },\n { x: 0.765625, y: 0.234375 },\n { x: 0.765625, y: 0.234375 },\n { x: 0.796875, y: 0.234375 },\n { x: 0.796875, y: 0.234375 },\n { x: 0.828125, y: 0.234375 },\n { x: 0.828125, y: 0.234375 },\n { x: 0.859375, y: 0.234375 },\n { x: 0.859375, y: 0.234375 },\n { x: 0.890625, y: 0.234375 },\n { x: 0.890625, y: 0.234375 },\n { x: 0.921875, y: 0.234375 },\n { x: 0.921875, y: 0.234375 },\n { x: 0.953125, y: 0.234375 },\n { x: 0.953125, y: 0.234375 },\n { x: 0.984375, y: 0.234375 },\n { x: 0.984375, y: 0.234375 },\n { x: 0.015625, y: 0.265625 },\n { x: 0.015625, y: 0.265625 },\n { x: 0.046875, y: 0.265625 },\n { x: 0.046875, y: 0.265625 },\n { x: 0.078125, y: 0.265625 },\n { x: 0.078125, y: 0.265625 },\n { x: 0.109375, y: 0.265625 },\n { x: 0.109375, y: 0.265625 },\n { x: 0.140625, y: 0.265625 },\n { x: 0.140625, y: 0.265625 },\n { x: 0.171875, y: 0.265625 },\n { x: 0.171875, y: 0.265625 },\n { x: 0.203125, y: 0.265625 },\n { x: 0.203125, y: 0.265625 },\n { x: 0.234375, y: 0.265625 },\n { x: 0.234375, y: 0.265625 },\n { x: 0.265625, y: 0.265625 },\n { x: 0.265625, y: 0.265625 },\n { x: 0.296875, y: 0.265625 },\n { x: 0.296875, y: 0.265625 },\n { x: 0.328125, y: 0.265625 },\n { x: 0.328125, y: 0.265625 },\n { x: 0.359375, y: 0.265625 },\n { x: 0.359375, y: 0.265625 },\n { x: 0.390625, y: 0.265625 },\n { x: 0.390625, y: 0.265625 },\n { x: 0.421875, y: 0.265625 },\n { x: 0.421875, y: 0.265625 },\n { x: 0.453125, y: 0.265625 },\n { x: 0.453125, y: 0.265625 },\n { x: 0.484375, y: 0.265625 },\n { x: 0.484375, y: 0.265625 },\n { x: 0.515625, y: 0.265625 },\n { x: 0.515625, y: 0.265625 },\n { x: 0.546875, y: 0.265625 },\n { x: 0.546875, y: 0.265625 },\n { x: 0.578125, y: 0.265625 },\n { x: 0.578125, y: 0.265625 },\n { x: 0.609375, y: 0.265625 },\n { x: 0.609375, y: 0.265625 },\n { x: 0.640625, y: 0.265625 },\n { x: 0.640625, y: 0.265625 },\n { x: 0.671875, y: 0.265625 },\n { x: 0.671875, y: 0.265625 },\n { x: 0.703125, y: 0.265625 },\n { x: 0.703125, y: 0.265625 },\n { x: 0.734375, y: 0.265625 },\n { x: 0.734375, y: 0.265625 },\n { x: 0.765625, y: 0.265625 },\n { x: 0.765625, y: 0.265625 },\n { x: 0.796875, y: 0.265625 },\n { x: 0.796875, y: 0.265625 },\n { x: 0.828125, y: 0.265625 },\n { x: 0.828125, y: 0.265625 },\n { x: 0.859375, y: 0.265625 },\n { x: 0.859375, y: 0.265625 },\n { x: 0.890625, y: 0.265625 },\n { x: 0.890625, y: 0.265625 },\n { x: 0.921875, y: 0.265625 },\n { x: 0.921875, y: 0.265625 },\n { x: 0.953125, y: 0.265625 },\n { x: 0.953125, y: 0.265625 },\n { x: 0.984375, y: 0.265625 },\n { x: 0.984375, y: 0.265625 },\n { x: 0.015625, y: 0.296875 },\n { x: 0.015625, y: 0.296875 },\n { x: 0.046875, y: 0.296875 },\n { x: 0.046875, y: 0.296875 },\n { x: 0.078125, y: 0.296875 },\n { x: 0.078125, y: 0.296875 },\n { x: 0.109375, y: 0.296875 },\n { x: 0.109375, y: 0.296875 },\n { x: 0.140625, y: 0.296875 },\n { x: 0.140625, y: 0.296875 },\n { x: 0.171875, y: 0.296875 },\n { x: 0.171875, y: 0.296875 },\n { x: 0.203125, y: 0.296875 },\n { x: 0.203125, y: 0.296875 },\n { x: 0.234375, y: 0.296875 },\n { x: 0.234375, y: 0.296875 },\n { x: 0.265625, y: 0.296875 },\n { x: 0.265625, y: 0.296875 },\n { x: 0.296875, y: 0.296875 },\n { x: 0.296875, y: 0.296875 },\n { x: 0.328125, y: 0.296875 },\n { x: 0.328125, y: 0.296875 },\n { x: 0.359375, y: 0.296875 },\n { x: 0.359375, y: 0.296875 },\n { x: 0.390625, y: 0.296875 },\n { x: 0.390625, y: 0.296875 },\n { x: 0.421875, y: 0.296875 },\n { x: 0.421875, y: 0.296875 },\n { x: 0.453125, y: 0.296875 },\n { x: 0.453125, y: 0.296875 },\n { x: 0.484375, y: 0.296875 },\n { x: 0.484375, y: 0.296875 },\n { x: 0.515625, y: 0.296875 },\n { x: 0.515625, y: 0.296875 },\n { x: 0.546875, y: 0.296875 },\n { x: 0.546875, y: 0.296875 },\n { x: 0.578125, y: 0.296875 },\n { x: 0.578125, y: 0.296875 },\n { x: 0.609375, y: 0.296875 },\n { x: 0.609375, y: 0.296875 },\n { x: 0.640625, y: 0.296875 },\n { x: 0.640625, y: 0.296875 },\n { x: 0.671875, y: 0.296875 },\n { x: 0.671875, y: 0.296875 },\n { x: 0.703125, y: 0.296875 },\n { x: 0.703125, y: 0.296875 },\n { x: 0.734375, y: 0.296875 },\n { x: 0.734375, y: 0.296875 },\n { x: 0.765625, y: 0.296875 },\n { x: 0.765625, y: 0.296875 },\n { x: 0.796875, y: 0.296875 },\n { x: 0.796875, y: 0.296875 },\n { x: 0.828125, y: 0.296875 },\n { x: 0.828125, y: 0.296875 },\n { x: 0.859375, y: 0.296875 },\n { x: 0.859375, y: 0.296875 },\n { x: 0.890625, y: 0.296875 },\n { x: 0.890625, y: 0.296875 },\n { x: 0.921875, y: 0.296875 },\n { x: 0.921875, y: 0.296875 },\n { x: 0.953125, y: 0.296875 },\n { x: 0.953125, y: 0.296875 },\n { x: 0.984375, y: 0.296875 },\n { x: 0.984375, y: 0.296875 },\n { x: 0.015625, y: 0.328125 },\n { x: 0.015625, y: 0.328125 },\n { x: 0.046875, y: 0.328125 },\n { x: 0.046875, y: 0.328125 },\n { x: 0.078125, y: 0.328125 },\n { x: 0.078125, y: 0.328125 },\n { x: 0.109375, y: 0.328125 },\n { x: 0.109375, y: 0.328125 },\n { x: 0.140625, y: 0.328125 },\n { x: 0.140625, y: 0.328125 },\n { x: 0.171875, y: 0.328125 },\n { x: 0.171875, y: 0.328125 },\n { x: 0.203125, y: 0.328125 },\n { x: 0.203125, y: 0.328125 },\n { x: 0.234375, y: 0.328125 },\n { x: 0.234375, y: 0.328125 },\n { x: 0.265625, y: 0.328125 },\n { x: 0.265625, y: 0.328125 },\n { x: 0.296875, y: 0.328125 },\n { x: 0.296875, y: 0.328125 },\n { x: 0.328125, y: 0.328125 },\n { x: 0.328125, y: 0.328125 },\n { x: 0.359375, y: 0.328125 },\n { x: 0.359375, y: 0.328125 },\n { x: 0.390625, y: 0.328125 },\n { x: 0.390625, y: 0.328125 },\n { x: 0.421875, y: 0.328125 },\n { x: 0.421875, y: 0.328125 },\n { x: 0.453125, y: 0.328125 },\n { x: 0.453125, y: 0.328125 },\n { x: 0.484375, y: 0.328125 },\n { x: 0.484375, y: 0.328125 },\n { x: 0.515625, y: 0.328125 },\n { x: 0.515625, y: 0.328125 },\n { x: 0.546875, y: 0.328125 },\n { x: 0.546875, y: 0.328125 },\n { x: 0.578125, y: 0.328125 },\n { x: 0.578125, y: 0.328125 },\n { x: 0.609375, y: 0.328125 },\n { x: 0.609375, y: 0.328125 },\n { x: 0.640625, y: 0.328125 },\n { x: 0.640625, y: 0.328125 },\n { x: 0.671875, y: 0.328125 },\n { x: 0.671875, y: 0.328125 },\n { x: 0.703125, y: 0.328125 },\n { x: 0.703125, y: 0.328125 },\n { x: 0.734375, y: 0.328125 },\n { x: 0.734375, y: 0.328125 },\n { x: 0.765625, y: 0.328125 },\n { x: 0.765625, y: 0.328125 },\n { x: 0.796875, y: 0.328125 },\n { x: 0.796875, y: 0.328125 },\n { x: 0.828125, y: 0.328125 },\n { x: 0.828125, y: 0.328125 },\n { x: 0.859375, y: 0.328125 },\n { x: 0.859375, y: 0.328125 },\n { x: 0.890625, y: 0.328125 },\n { x: 0.890625, y: 0.328125 },\n { x: 0.921875, y: 0.328125 },\n { x: 0.921875, y: 0.328125 },\n { x: 0.953125, y: 0.328125 },\n { x: 0.953125, y: 0.328125 },\n { x: 0.984375, y: 0.328125 },\n { x: 0.984375, y: 0.328125 },\n { x: 0.015625, y: 0.359375 },\n { x: 0.015625, y: 0.359375 },\n { x: 0.046875, y: 0.359375 },\n { x: 0.046875, y: 0.359375 },\n { x: 0.078125, y: 0.359375 },\n { x: 0.078125, y: 0.359375 },\n { x: 0.109375, y: 0.359375 },\n { x: 0.109375, y: 0.359375 },\n { x: 0.140625, y: 0.359375 },\n { x: 0.140625, y: 0.359375 },\n { x: 0.171875, y: 0.359375 },\n { x: 0.171875, y: 0.359375 },\n { x: 0.203125, y: 0.359375 },\n { x: 0.203125, y: 0.359375 },\n { x: 0.234375, y: 0.359375 },\n { x: 0.234375, y: 0.359375 },\n { x: 0.265625, y: 0.359375 },\n { x: 0.265625, y: 0.359375 },\n { x: 0.296875, y: 0.359375 },\n { x: 0.296875, y: 0.359375 },\n { x: 0.328125, y: 0.359375 },\n { x: 0.328125, y: 0.359375 },\n { x: 0.359375, y: 0.359375 },\n { x: 0.359375, y: 0.359375 },\n { x: 0.390625, y: 0.359375 },\n { x: 0.390625, y: 0.359375 },\n { x: 0.421875, y: 0.359375 },\n { x: 0.421875, y: 0.359375 },\n { x: 0.453125, y: 0.359375 },\n { x: 0.453125, y: 0.359375 },\n { x: 0.484375, y: 0.359375 },\n { x: 0.484375, y: 0.359375 },\n { x: 0.515625, y: 0.359375 },\n { x: 0.515625, y: 0.359375 },\n { x: 0.546875, y: 0.359375 },\n { x: 0.546875, y: 0.359375 },\n { x: 0.578125, y: 0.359375 },\n { x: 0.578125, y: 0.359375 },\n { x: 0.609375, y: 0.359375 },\n { x: 0.609375, y: 0.359375 },\n { x: 0.640625, y: 0.359375 },\n { x: 0.640625, y: 0.359375 },\n { x: 0.671875, y: 0.359375 },\n { x: 0.671875, y: 0.359375 },\n { x: 0.703125, y: 0.359375 },\n { x: 0.703125, y: 0.359375 },\n { x: 0.734375, y: 0.359375 },\n { x: 0.734375, y: 0.359375 },\n { x: 0.765625, y: 0.359375 },\n { x: 0.765625, y: 0.359375 },\n { x: 0.796875, y: 0.359375 },\n { x: 0.796875, y: 0.359375 },\n { x: 0.828125, y: 0.359375 },\n { x: 0.828125, y: 0.359375 },\n { x: 0.859375, y: 0.359375 },\n { x: 0.859375, y: 0.359375 },\n { x: 0.890625, y: 0.359375 },\n { x: 0.890625, y: 0.359375 },\n { x: 0.921875, y: 0.359375 },\n { x: 0.921875, y: 0.359375 },\n { x: 0.953125, y: 0.359375 },\n { x: 0.953125, y: 0.359375 },\n { x: 0.984375, y: 0.359375 },\n { x: 0.984375, y: 0.359375 },\n { x: 0.015625, y: 0.390625 },\n { x: 0.015625, y: 0.390625 },\n { x: 0.046875, y: 0.390625 },\n { x: 0.046875, y: 0.390625 },\n { x: 0.078125, y: 0.390625 },\n { x: 0.078125, y: 0.390625 },\n { x: 0.109375, y: 0.390625 },\n { x: 0.109375, y: 0.390625 },\n { x: 0.140625, y: 0.390625 },\n { x: 0.140625, y: 0.390625 },\n { x: 0.171875, y: 0.390625 },\n { x: 0.171875, y: 0.390625 },\n { x: 0.203125, y: 0.390625 },\n { x: 0.203125, y: 0.390625 },\n { x: 0.234375, y: 0.390625 },\n { x: 0.234375, y: 0.390625 },\n { x: 0.265625, y: 0.390625 },\n { x: 0.265625, y: 0.390625 },\n { x: 0.296875, y: 0.390625 },\n { x: 0.296875, y: 0.390625 },\n { x: 0.328125, y: 0.390625 },\n { x: 0.328125, y: 0.390625 },\n { x: 0.359375, y: 0.390625 },\n { x: 0.359375, y: 0.390625 },\n { x: 0.390625, y: 0.390625 },\n { x: 0.390625, y: 0.390625 },\n { x: 0.421875, y: 0.390625 },\n { x: 0.421875, y: 0.390625 },\n { x: 0.453125, y: 0.390625 },\n { x: 0.453125, y: 0.390625 },\n { x: 0.484375, y: 0.390625 },\n { x: 0.484375, y: 0.390625 },\n { x: 0.515625, y: 0.390625 },\n { x: 0.515625, y: 0.390625 },\n { x: 0.546875, y: 0.390625 },\n { x: 0.546875, y: 0.390625 },\n { x: 0.578125, y: 0.390625 },\n { x: 0.578125, y: 0.390625 },\n { x: 0.609375, y: 0.390625 },\n { x: 0.609375, y: 0.390625 },\n { x: 0.640625, y: 0.390625 },\n { x: 0.640625, y: 0.390625 },\n { x: 0.671875, y: 0.390625 },\n { x: 0.671875, y: 0.390625 },\n { x: 0.703125, y: 0.390625 },\n { x: 0.703125, y: 0.390625 },\n { x: 0.734375, y: 0.390625 },\n { x: 0.734375, y: 0.390625 },\n { x: 0.765625, y: 0.390625 },\n { x: 0.765625, y: 0.390625 },\n { x: 0.796875, y: 0.390625 },\n { x: 0.796875, y: 0.390625 },\n { x: 0.828125, y: 0.390625 },\n { x: 0.828125, y: 0.390625 },\n { x: 0.859375, y: 0.390625 },\n { x: 0.859375, y: 0.390625 },\n { x: 0.890625, y: 0.390625 },\n { x: 0.890625, y: 0.390625 },\n { x: 0.921875, y: 0.390625 },\n { x: 0.921875, y: 0.390625 },\n { x: 0.953125, y: 0.390625 },\n { x: 0.953125, y: 0.390625 },\n { x: 0.984375, y: 0.390625 },\n { x: 0.984375, y: 0.390625 },\n { x: 0.015625, y: 0.421875 },\n { x: 0.015625, y: 0.421875 },\n { x: 0.046875, y: 0.421875 },\n { x: 0.046875, y: 0.421875 },\n { x: 0.078125, y: 0.421875 },\n { x: 0.078125, y: 0.421875 },\n { x: 0.109375, y: 0.421875 },\n { x: 0.109375, y: 0.421875 },\n { x: 0.140625, y: 0.421875 },\n { x: 0.140625, y: 0.421875 },\n { x: 0.171875, y: 0.421875 },\n { x: 0.171875, y: 0.421875 },\n { x: 0.203125, y: 0.421875 },\n { x: 0.203125, y: 0.421875 },\n { x: 0.234375, y: 0.421875 },\n { x: 0.234375, y: 0.421875 },\n { x: 0.265625, y: 0.421875 },\n { x: 0.265625, y: 0.421875 },\n { x: 0.296875, y: 0.421875 },\n { x: 0.296875, y: 0.421875 },\n { x: 0.328125, y: 0.421875 },\n { x: 0.328125, y: 0.421875 },\n { x: 0.359375, y: 0.421875 },\n { x: 0.359375, y: 0.421875 },\n { x: 0.390625, y: 0.421875 },\n { x: 0.390625, y: 0.421875 },\n { x: 0.421875, y: 0.421875 },\n { x: 0.421875, y: 0.421875 },\n { x: 0.453125, y: 0.421875 },\n { x: 0.453125, y: 0.421875 },\n { x: 0.484375, y: 0.421875 },\n { x: 0.484375, y: 0.421875 },\n { x: 0.515625, y: 0.421875 },\n { x: 0.515625, y: 0.421875 },\n { x: 0.546875, y: 0.421875 },\n { x: 0.546875, y: 0.421875 },\n { x: 0.578125, y: 0.421875 },\n { x: 0.578125, y: 0.421875 },\n { x: 0.609375, y: 0.421875 },\n { x: 0.609375, y: 0.421875 },\n { x: 0.640625, y: 0.421875 },\n { x: 0.640625, y: 0.421875 },\n { x: 0.671875, y: 0.421875 },\n { x: 0.671875, y: 0.421875 },\n { x: 0.703125, y: 0.421875 },\n { x: 0.703125, y: 0.421875 },\n { x: 0.734375, y: 0.421875 },\n { x: 0.734375, y: 0.421875 },\n { x: 0.765625, y: 0.421875 },\n { x: 0.765625, y: 0.421875 },\n { x: 0.796875, y: 0.421875 },\n { x: 0.796875, y: 0.421875 },\n { x: 0.828125, y: 0.421875 },\n { x: 0.828125, y: 0.421875 },\n { x: 0.859375, y: 0.421875 },\n { x: 0.859375, y: 0.421875 },\n { x: 0.890625, y: 0.421875 },\n { x: 0.890625, y: 0.421875 },\n { x: 0.921875, y: 0.421875 },\n { x: 0.921875, y: 0.421875 },\n { x: 0.953125, y: 0.421875 },\n { x: 0.953125, y: 0.421875 },\n { x: 0.984375, y: 0.421875 },\n { x: 0.984375, y: 0.421875 },\n { x: 0.015625, y: 0.453125 },\n { x: 0.015625, y: 0.453125 },\n { x: 0.046875, y: 0.453125 },\n { x: 0.046875, y: 0.453125 },\n { x: 0.078125, y: 0.453125 },\n { x: 0.078125, y: 0.453125 },\n { x: 0.109375, y: 0.453125 },\n { x: 0.109375, y: 0.453125 },\n { x: 0.140625, y: 0.453125 },\n { x: 0.140625, y: 0.453125 },\n { x: 0.171875, y: 0.453125 },\n { x: 0.171875, y: 0.453125 },\n { x: 0.203125, y: 0.453125 },\n { x: 0.203125, y: 0.453125 },\n { x: 0.234375, y: 0.453125 },\n { x: 0.234375, y: 0.453125 },\n { x: 0.265625, y: 0.453125 },\n { x: 0.265625, y: 0.453125 },\n { x: 0.296875, y: 0.453125 },\n { x: 0.296875, y: 0.453125 },\n { x: 0.328125, y: 0.453125 },\n { x: 0.328125, y: 0.453125 },\n { x: 0.359375, y: 0.453125 },\n { x: 0.359375, y: 0.453125 },\n { x: 0.390625, y: 0.453125 },\n { x: 0.390625, y: 0.453125 },\n { x: 0.421875, y: 0.453125 },\n { x: 0.421875, y: 0.453125 },\n { x: 0.453125, y: 0.453125 },\n { x: 0.453125, y: 0.453125 },\n { x: 0.484375, y: 0.453125 },\n { x: 0.484375, y: 0.453125 },\n { x: 0.515625, y: 0.453125 },\n { x: 0.515625, y: 0.453125 },\n { x: 0.546875, y: 0.453125 },\n { x: 0.546875, y: 0.453125 },\n { x: 0.578125, y: 0.453125 },\n { x: 0.578125, y: 0.453125 },\n { x: 0.609375, y: 0.453125 },\n { x: 0.609375, y: 0.453125 },\n { x: 0.640625, y: 0.453125 },\n { x: 0.640625, y: 0.453125 },\n { x: 0.671875, y: 0.453125 },\n { x: 0.671875, y: 0.453125 },\n { x: 0.703125, y: 0.453125 },\n { x: 0.703125, y: 0.453125 },\n { x: 0.734375, y: 0.453125 },\n { x: 0.734375, y: 0.453125 },\n { x: 0.765625, y: 0.453125 },\n { x: 0.765625, y: 0.453125 },\n { x: 0.796875, y: 0.453125 },\n { x: 0.796875, y: 0.453125 },\n { x: 0.828125, y: 0.453125 },\n { x: 0.828125, y: 0.453125 },\n { x: 0.859375, y: 0.453125 },\n { x: 0.859375, y: 0.453125 },\n { x: 0.890625, y: 0.453125 },\n { x: 0.890625, y: 0.453125 },\n { x: 0.921875, y: 0.453125 },\n { x: 0.921875, y: 0.453125 },\n { x: 0.953125, y: 0.453125 },\n { x: 0.953125, y: 0.453125 },\n { x: 0.984375, y: 0.453125 },\n { x: 0.984375, y: 0.453125 },\n { x: 0.015625, y: 0.484375 },\n { x: 0.015625, y: 0.484375 },\n { x: 0.046875, y: 0.484375 },\n { x: 0.046875, y: 0.484375 },\n { x: 0.078125, y: 0.484375 },\n { x: 0.078125, y: 0.484375 },\n { x: 0.109375, y: 0.484375 },\n { x: 0.109375, y: 0.484375 },\n { x: 0.140625, y: 0.484375 },\n { x: 0.140625, y: 0.484375 },\n { x: 0.171875, y: 0.484375 },\n { x: 0.171875, y: 0.484375 },\n { x: 0.203125, y: 0.484375 },\n { x: 0.203125, y: 0.484375 },\n { x: 0.234375, y: 0.484375 },\n { x: 0.234375, y: 0.484375 },\n { x: 0.265625, y: 0.484375 },\n { x: 0.265625, y: 0.484375 },\n { x: 0.296875, y: 0.484375 },\n { x: 0.296875, y: 0.484375 },\n { x: 0.328125, y: 0.484375 },\n { x: 0.328125, y: 0.484375 },\n { x: 0.359375, y: 0.484375 },\n { x: 0.359375, y: 0.484375 },\n { x: 0.390625, y: 0.484375 },\n { x: 0.390625, y: 0.484375 },\n { x: 0.421875, y: 0.484375 },\n { x: 0.421875, y: 0.484375 },\n { x: 0.453125, y: 0.484375 },\n { x: 0.453125, y: 0.484375 },\n { x: 0.484375, y: 0.484375 },\n { x: 0.484375, y: 0.484375 },\n { x: 0.515625, y: 0.484375 },\n { x: 0.515625, y: 0.484375 },\n { x: 0.546875, y: 0.484375 },\n { x: 0.546875, y: 0.484375 },\n { x: 0.578125, y: 0.484375 },\n { x: 0.578125, y: 0.484375 },\n { x: 0.609375, y: 0.484375 },\n { x: 0.609375, y: 0.484375 },\n { x: 0.640625, y: 0.484375 },\n { x: 0.640625, y: 0.484375 },\n { x: 0.671875, y: 0.484375 },\n { x: 0.671875, y: 0.484375 },\n { x: 0.703125, y: 0.484375 },\n { x: 0.703125, y: 0.484375 },\n { x: 0.734375, y: 0.484375 },\n { x: 0.734375, y: 0.484375 },\n { x: 0.765625, y: 0.484375 },\n { x: 0.765625, y: 0.484375 },\n { x: 0.796875, y: 0.484375 },\n { x: 0.796875, y: 0.484375 },\n { x: 0.828125, y: 0.484375 },\n { x: 0.828125, y: 0.484375 },\n { x: 0.859375, y: 0.484375 },\n { x: 0.859375, y: 0.484375 },\n { x: 0.890625, y: 0.484375 },\n { x: 0.890625, y: 0.484375 },\n { x: 0.921875, y: 0.484375 },\n { x: 0.921875, y: 0.484375 },\n { x: 0.953125, y: 0.484375 },\n { x: 0.953125, y: 0.484375 },\n { x: 0.984375, y: 0.484375 },\n { x: 0.984375, y: 0.484375 },\n { x: 0.015625, y: 0.515625 },\n { x: 0.015625, y: 0.515625 },\n { x: 0.046875, y: 0.515625 },\n { x: 0.046875, y: 0.515625 },\n { x: 0.078125, y: 0.515625 },\n { x: 0.078125, y: 0.515625 },\n { x: 0.109375, y: 0.515625 },\n { x: 0.109375, y: 0.515625 },\n { x: 0.140625, y: 0.515625 },\n { x: 0.140625, y: 0.515625 },\n { x: 0.171875, y: 0.515625 },\n { x: 0.171875, y: 0.515625 },\n { x: 0.203125, y: 0.515625 },\n { x: 0.203125, y: 0.515625 },\n { x: 0.234375, y: 0.515625 },\n { x: 0.234375, y: 0.515625 },\n { x: 0.265625, y: 0.515625 },\n { x: 0.265625, y: 0.515625 },\n { x: 0.296875, y: 0.515625 },\n { x: 0.296875, y: 0.515625 },\n { x: 0.328125, y: 0.515625 },\n { x: 0.328125, y: 0.515625 },\n { x: 0.359375, y: 0.515625 },\n { x: 0.359375, y: 0.515625 },\n { x: 0.390625, y: 0.515625 },\n { x: 0.390625, y: 0.515625 },\n { x: 0.421875, y: 0.515625 },\n { x: 0.421875, y: 0.515625 },\n { x: 0.453125, y: 0.515625 },\n { x: 0.453125, y: 0.515625 },\n { x: 0.484375, y: 0.515625 },\n { x: 0.484375, y: 0.515625 },\n { x: 0.515625, y: 0.515625 },\n { x: 0.515625, y: 0.515625 },\n { x: 0.546875, y: 0.515625 },\n { x: 0.546875, y: 0.515625 },\n { x: 0.578125, y: 0.515625 },\n { x: 0.578125, y: 0.515625 },\n { x: 0.609375, y: 0.515625 },\n { x: 0.609375, y: 0.515625 },\n { x: 0.640625, y: 0.515625 },\n { x: 0.640625, y: 0.515625 },\n { x: 0.671875, y: 0.515625 },\n { x: 0.671875, y: 0.515625 },\n { x: 0.703125, y: 0.515625 },\n { x: 0.703125, y: 0.515625 },\n { x: 0.734375, y: 0.515625 },\n { x: 0.734375, y: 0.515625 },\n { x: 0.765625, y: 0.515625 },\n { x: 0.765625, y: 0.515625 },\n { x: 0.796875, y: 0.515625 },\n { x: 0.796875, y: 0.515625 },\n { x: 0.828125, y: 0.515625 },\n { x: 0.828125, y: 0.515625 },\n { x: 0.859375, y: 0.515625 },\n { x: 0.859375, y: 0.515625 },\n { x: 0.890625, y: 0.515625 },\n { x: 0.890625, y: 0.515625 },\n { x: 0.921875, y: 0.515625 },\n { x: 0.921875, y: 0.515625 },\n { x: 0.953125, y: 0.515625 },\n { x: 0.953125, y: 0.515625 },\n { x: 0.984375, y: 0.515625 },\n { x: 0.984375, y: 0.515625 },\n { x: 0.015625, y: 0.546875 },\n { x: 0.015625, y: 0.546875 },\n { x: 0.046875, y: 0.546875 },\n { x: 0.046875, y: 0.546875 },\n { x: 0.078125, y: 0.546875 },\n { x: 0.078125, y: 0.546875 },\n { x: 0.109375, y: 0.546875 },\n { x: 0.109375, y: 0.546875 },\n { x: 0.140625, y: 0.546875 },\n { x: 0.140625, y: 0.546875 },\n { x: 0.171875, y: 0.546875 },\n { x: 0.171875, y: 0.546875 },\n { x: 0.203125, y: 0.546875 },\n { x: 0.203125, y: 0.546875 },\n { x: 0.234375, y: 0.546875 },\n { x: 0.234375, y: 0.546875 },\n { x: 0.265625, y: 0.546875 },\n { x: 0.265625, y: 0.546875 },\n { x: 0.296875, y: 0.546875 },\n { x: 0.296875, y: 0.546875 },\n { x: 0.328125, y: 0.546875 },\n { x: 0.328125, y: 0.546875 },\n { x: 0.359375, y: 0.546875 },\n { x: 0.359375, y: 0.546875 },\n { x: 0.390625, y: 0.546875 },\n { x: 0.390625, y: 0.546875 },\n { x: 0.421875, y: 0.546875 },\n { x: 0.421875, y: 0.546875 },\n { x: 0.453125, y: 0.546875 },\n { x: 0.453125, y: 0.546875 },\n { x: 0.484375, y: 0.546875 },\n { x: 0.484375, y: 0.546875 },\n { x: 0.515625, y: 0.546875 },\n { x: 0.515625, y: 0.546875 },\n { x: 0.546875, y: 0.546875 },\n { x: 0.546875, y: 0.546875 },\n { x: 0.578125, y: 0.546875 },\n { x: 0.578125, y: 0.546875 },\n { x: 0.609375, y: 0.546875 },\n { x: 0.609375, y: 0.546875 },\n { x: 0.640625, y: 0.546875 },\n { x: 0.640625, y: 0.546875 },\n { x: 0.671875, y: 0.546875 },\n { x: 0.671875, y: 0.546875 },\n { x: 0.703125, y: 0.546875 },\n { x: 0.703125, y: 0.546875 },\n { x: 0.734375, y: 0.546875 },\n { x: 0.734375, y: 0.546875 },\n { x: 0.765625, y: 0.546875 },\n { x: 0.765625, y: 0.546875 },\n { x: 0.796875, y: 0.546875 },\n { x: 0.796875, y: 0.546875 },\n { x: 0.828125, y: 0.546875 },\n { x: 0.828125, y: 0.546875 },\n { x: 0.859375, y: 0.546875 },\n { x: 0.859375, y: 0.546875 },\n { x: 0.890625, y: 0.546875 },\n { x: 0.890625, y: 0.546875 },\n { x: 0.921875, y: 0.546875 },\n { x: 0.921875, y: 0.546875 },\n { x: 0.953125, y: 0.546875 },\n { x: 0.953125, y: 0.546875 },\n { x: 0.984375, y: 0.546875 },\n { x: 0.984375, y: 0.546875 },\n { x: 0.015625, y: 0.578125 },\n { x: 0.015625, y: 0.578125 },\n { x: 0.046875, y: 0.578125 },\n { x: 0.046875, y: 0.578125 },\n { x: 0.078125, y: 0.578125 },\n { x: 0.078125, y: 0.578125 },\n { x: 0.109375, y: 0.578125 },\n { x: 0.109375, y: 0.578125 },\n { x: 0.140625, y: 0.578125 },\n { x: 0.140625, y: 0.578125 },\n { x: 0.171875, y: 0.578125 },\n { x: 0.171875, y: 0.578125 },\n { x: 0.203125, y: 0.578125 },\n { x: 0.203125, y: 0.578125 },\n { x: 0.234375, y: 0.578125 },\n { x: 0.234375, y: 0.578125 },\n { x: 0.265625, y: 0.578125 },\n { x: 0.265625, y: 0.578125 },\n { x: 0.296875, y: 0.578125 },\n { x: 0.296875, y: 0.578125 },\n { x: 0.328125, y: 0.578125 },\n { x: 0.328125, y: 0.578125 },\n { x: 0.359375, y: 0.578125 },\n { x: 0.359375, y: 0.578125 },\n { x: 0.390625, y: 0.578125 },\n { x: 0.390625, y: 0.578125 },\n { x: 0.421875, y: 0.578125 },\n { x: 0.421875, y: 0.578125 },\n { x: 0.453125, y: 0.578125 },\n { x: 0.453125, y: 0.578125 },\n { x: 0.484375, y: 0.578125 },\n { x: 0.484375, y: 0.578125 },\n { x: 0.515625, y: 0.578125 },\n { x: 0.515625, y: 0.578125 },\n { x: 0.546875, y: 0.578125 },\n { x: 0.546875, y: 0.578125 },\n { x: 0.578125, y: 0.578125 },\n { x: 0.578125, y: 0.578125 },\n { x: 0.609375, y: 0.578125 },\n { x: 0.609375, y: 0.578125 },\n { x: 0.640625, y: 0.578125 },\n { x: 0.640625, y: 0.578125 },\n { x: 0.671875, y: 0.578125 },\n { x: 0.671875, y: 0.578125 },\n { x: 0.703125, y: 0.578125 },\n { x: 0.703125, y: 0.578125 },\n { x: 0.734375, y: 0.578125 },\n { x: 0.734375, y: 0.578125 },\n { x: 0.765625, y: 0.578125 },\n { x: 0.765625, y: 0.578125 },\n { x: 0.796875, y: 0.578125 },\n { x: 0.796875, y: 0.578125 },\n { x: 0.828125, y: 0.578125 },\n { x: 0.828125, y: 0.578125 },\n { x: 0.859375, y: 0.578125 },\n { x: 0.859375, y: 0.578125 },\n { x: 0.890625, y: 0.578125 },\n { x: 0.890625, y: 0.578125 },\n { x: 0.921875, y: 0.578125 },\n { x: 0.921875, y: 0.578125 },\n { x: 0.953125, y: 0.578125 },\n { x: 0.953125, y: 0.578125 },\n { x: 0.984375, y: 0.578125 },\n { x: 0.984375, y: 0.578125 },\n { x: 0.015625, y: 0.609375 },\n { x: 0.015625, y: 0.609375 },\n { x: 0.046875, y: 0.609375 },\n { x: 0.046875, y: 0.609375 },\n { x: 0.078125, y: 0.609375 },\n { x: 0.078125, y: 0.609375 },\n { x: 0.109375, y: 0.609375 },\n { x: 0.109375, y: 0.609375 },\n { x: 0.140625, y: 0.609375 },\n { x: 0.140625, y: 0.609375 },\n { x: 0.171875, y: 0.609375 },\n { x: 0.171875, y: 0.609375 },\n { x: 0.203125, y: 0.609375 },\n { x: 0.203125, y: 0.609375 },\n { x: 0.234375, y: 0.609375 },\n { x: 0.234375, y: 0.609375 },\n { x: 0.265625, y: 0.609375 },\n { x: 0.265625, y: 0.609375 },\n { x: 0.296875, y: 0.609375 },\n { x: 0.296875, y: 0.609375 },\n { x: 0.328125, y: 0.609375 },\n { x: 0.328125, y: 0.609375 },\n { x: 0.359375, y: 0.609375 },\n { x: 0.359375, y: 0.609375 },\n { x: 0.390625, y: 0.609375 },\n { x: 0.390625, y: 0.609375 },\n { x: 0.421875, y: 0.609375 },\n { x: 0.421875, y: 0.609375 },\n { x: 0.453125, y: 0.609375 },\n { x: 0.453125, y: 0.609375 },\n { x: 0.484375, y: 0.609375 },\n { x: 0.484375, y: 0.609375 },\n { x: 0.515625, y: 0.609375 },\n { x: 0.515625, y: 0.609375 },\n { x: 0.546875, y: 0.609375 },\n { x: 0.546875, y: 0.609375 },\n { x: 0.578125, y: 0.609375 },\n { x: 0.578125, y: 0.609375 },\n { x: 0.609375, y: 0.609375 },\n { x: 0.609375, y: 0.609375 },\n { x: 0.640625, y: 0.609375 },\n { x: 0.640625, y: 0.609375 },\n { x: 0.671875, y: 0.609375 },\n { x: 0.671875, y: 0.609375 },\n { x: 0.703125, y: 0.609375 },\n { x: 0.703125, y: 0.609375 },\n { x: 0.734375, y: 0.609375 },\n { x: 0.734375, y: 0.609375 },\n { x: 0.765625, y: 0.609375 },\n { x: 0.765625, y: 0.609375 },\n { x: 0.796875, y: 0.609375 },\n { x: 0.796875, y: 0.609375 },\n { x: 0.828125, y: 0.609375 },\n { x: 0.828125, y: 0.609375 },\n { x: 0.859375, y: 0.609375 },\n { x: 0.859375, y: 0.609375 },\n { x: 0.890625, y: 0.609375 },\n { x: 0.890625, y: 0.609375 },\n { x: 0.921875, y: 0.609375 },\n { x: 0.921875, y: 0.609375 },\n { x: 0.953125, y: 0.609375 },\n { x: 0.953125, y: 0.609375 },\n { x: 0.984375, y: 0.609375 },\n { x: 0.984375, y: 0.609375 },\n { x: 0.015625, y: 0.640625 },\n { x: 0.015625, y: 0.640625 },\n { x: 0.046875, y: 0.640625 },\n { x: 0.046875, y: 0.640625 },\n { x: 0.078125, y: 0.640625 },\n { x: 0.078125, y: 0.640625 },\n { x: 0.109375, y: 0.640625 },\n { x: 0.109375, y: 0.640625 },\n { x: 0.140625, y: 0.640625 },\n { x: 0.140625, y: 0.640625 },\n { x: 0.171875, y: 0.640625 },\n { x: 0.171875, y: 0.640625 },\n { x: 0.203125, y: 0.640625 },\n { x: 0.203125, y: 0.640625 },\n { x: 0.234375, y: 0.640625 },\n { x: 0.234375, y: 0.640625 },\n { x: 0.265625, y: 0.640625 },\n { x: 0.265625, y: 0.640625 },\n { x: 0.296875, y: 0.640625 },\n { x: 0.296875, y: 0.640625 },\n { x: 0.328125, y: 0.640625 },\n { x: 0.328125, y: 0.640625 },\n { x: 0.359375, y: 0.640625 },\n { x: 0.359375, y: 0.640625 },\n { x: 0.390625, y: 0.640625 },\n { x: 0.390625, y: 0.640625 },\n { x: 0.421875, y: 0.640625 },\n { x: 0.421875, y: 0.640625 },\n { x: 0.453125, y: 0.640625 },\n { x: 0.453125, y: 0.640625 },\n { x: 0.484375, y: 0.640625 },\n { x: 0.484375, y: 0.640625 },\n { x: 0.515625, y: 0.640625 },\n { x: 0.515625, y: 0.640625 },\n { x: 0.546875, y: 0.640625 },\n { x: 0.546875, y: 0.640625 },\n { x: 0.578125, y: 0.640625 },\n { x: 0.578125, y: 0.640625 },\n { x: 0.609375, y: 0.640625 },\n { x: 0.609375, y: 0.640625 },\n { x: 0.640625, y: 0.640625 },\n { x: 0.640625, y: 0.640625 },\n { x: 0.671875, y: 0.640625 },\n { x: 0.671875, y: 0.640625 },\n { x: 0.703125, y: 0.640625 },\n { x: 0.703125, y: 0.640625 },\n { x: 0.734375, y: 0.640625 },\n { x: 0.734375, y: 0.640625 },\n { x: 0.765625, y: 0.640625 },\n { x: 0.765625, y: 0.640625 },\n { x: 0.796875, y: 0.640625 },\n { x: 0.796875, y: 0.640625 },\n { x: 0.828125, y: 0.640625 },\n { x: 0.828125, y: 0.640625 },\n { x: 0.859375, y: 0.640625 },\n { x: 0.859375, y: 0.640625 },\n { x: 0.890625, y: 0.640625 },\n { x: 0.890625, y: 0.640625 },\n { x: 0.921875, y: 0.640625 },\n { x: 0.921875, y: 0.640625 },\n { x: 0.953125, y: 0.640625 },\n { x: 0.953125, y: 0.640625 },\n { x: 0.984375, y: 0.640625 },\n { x: 0.984375, y: 0.640625 },\n { x: 0.015625, y: 0.671875 },\n { x: 0.015625, y: 0.671875 },\n { x: 0.046875, y: 0.671875 },\n { x: 0.046875, y: 0.671875 },\n { x: 0.078125, y: 0.671875 },\n { x: 0.078125, y: 0.671875 },\n { x: 0.109375, y: 0.671875 },\n { x: 0.109375, y: 0.671875 },\n { x: 0.140625, y: 0.671875 },\n { x: 0.140625, y: 0.671875 },\n { x: 0.171875, y: 0.671875 },\n { x: 0.171875, y: 0.671875 },\n { x: 0.203125, y: 0.671875 },\n { x: 0.203125, y: 0.671875 },\n { x: 0.234375, y: 0.671875 },\n { x: 0.234375, y: 0.671875 },\n { x: 0.265625, y: 0.671875 },\n { x: 0.265625, y: 0.671875 },\n { x: 0.296875, y: 0.671875 },\n { x: 0.296875, y: 0.671875 },\n { x: 0.328125, y: 0.671875 },\n { x: 0.328125, y: 0.671875 },\n { x: 0.359375, y: 0.671875 },\n { x: 0.359375, y: 0.671875 },\n { x: 0.390625, y: 0.671875 },\n { x: 0.390625, y: 0.671875 },\n { x: 0.421875, y: 0.671875 },\n { x: 0.421875, y: 0.671875 },\n { x: 0.453125, y: 0.671875 },\n { x: 0.453125, y: 0.671875 },\n { x: 0.484375, y: 0.671875 },\n { x: 0.484375, y: 0.671875 },\n { x: 0.515625, y: 0.671875 },\n { x: 0.515625, y: 0.671875 },\n { x: 0.546875, y: 0.671875 },\n { x: 0.546875, y: 0.671875 },\n { x: 0.578125, y: 0.671875 },\n { x: 0.578125, y: 0.671875 },\n { x: 0.609375, y: 0.671875 },\n { x: 0.609375, y: 0.671875 },\n { x: 0.640625, y: 0.671875 },\n { x: 0.640625, y: 0.671875 },\n { x: 0.671875, y: 0.671875 },\n { x: 0.671875, y: 0.671875 },\n { x: 0.703125, y: 0.671875 },\n { x: 0.703125, y: 0.671875 },\n { x: 0.734375, y: 0.671875 },\n { x: 0.734375, y: 0.671875 },\n { x: 0.765625, y: 0.671875 },\n { x: 0.765625, y: 0.671875 },\n { x: 0.796875, y: 0.671875 },\n { x: 0.796875, y: 0.671875 },\n { x: 0.828125, y: 0.671875 },\n { x: 0.828125, y: 0.671875 },\n { x: 0.859375, y: 0.671875 },\n { x: 0.859375, y: 0.671875 },\n { x: 0.890625, y: 0.671875 },\n { x: 0.890625, y: 0.671875 },\n { x: 0.921875, y: 0.671875 },\n { x: 0.921875, y: 0.671875 },\n { x: 0.953125, y: 0.671875 },\n { x: 0.953125, y: 0.671875 },\n { x: 0.984375, y: 0.671875 },\n { x: 0.984375, y: 0.671875 },\n { x: 0.015625, y: 0.703125 },\n { x: 0.015625, y: 0.703125 },\n { x: 0.046875, y: 0.703125 },\n { x: 0.046875, y: 0.703125 },\n { x: 0.078125, y: 0.703125 },\n { x: 0.078125, y: 0.703125 },\n { x: 0.109375, y: 0.703125 },\n { x: 0.109375, y: 0.703125 },\n { x: 0.140625, y: 0.703125 },\n { x: 0.140625, y: 0.703125 },\n { x: 0.171875, y: 0.703125 },\n { x: 0.171875, y: 0.703125 },\n { x: 0.203125, y: 0.703125 },\n { x: 0.203125, y: 0.703125 },\n { x: 0.234375, y: 0.703125 },\n { x: 0.234375, y: 0.703125 },\n { x: 0.265625, y: 0.703125 },\n { x: 0.265625, y: 0.703125 },\n { x: 0.296875, y: 0.703125 },\n { x: 0.296875, y: 0.703125 },\n { x: 0.328125, y: 0.703125 },\n { x: 0.328125, y: 0.703125 },\n { x: 0.359375, y: 0.703125 },\n { x: 0.359375, y: 0.703125 },\n { x: 0.390625, y: 0.703125 },\n { x: 0.390625, y: 0.703125 },\n { x: 0.421875, y: 0.703125 },\n { x: 0.421875, y: 0.703125 },\n { x: 0.453125, y: 0.703125 },\n { x: 0.453125, y: 0.703125 },\n { x: 0.484375, y: 0.703125 },\n { x: 0.484375, y: 0.703125 },\n { x: 0.515625, y: 0.703125 },\n { x: 0.515625, y: 0.703125 },\n { x: 0.546875, y: 0.703125 },\n { x: 0.546875, y: 0.703125 },\n { x: 0.578125, y: 0.703125 },\n { x: 0.578125, y: 0.703125 },\n { x: 0.609375, y: 0.703125 },\n { x: 0.609375, y: 0.703125 },\n { x: 0.640625, y: 0.703125 },\n { x: 0.640625, y: 0.703125 },\n { x: 0.671875, y: 0.703125 },\n { x: 0.671875, y: 0.703125 },\n { x: 0.703125, y: 0.703125 },\n { x: 0.703125, y: 0.703125 },\n { x: 0.734375, y: 0.703125 },\n { x: 0.734375, y: 0.703125 },\n { x: 0.765625, y: 0.703125 },\n { x: 0.765625, y: 0.703125 },\n { x: 0.796875, y: 0.703125 },\n { x: 0.796875, y: 0.703125 },\n { x: 0.828125, y: 0.703125 },\n { x: 0.828125, y: 0.703125 },\n { x: 0.859375, y: 0.703125 },\n { x: 0.859375, y: 0.703125 },\n { x: 0.890625, y: 0.703125 },\n { x: 0.890625, y: 0.703125 },\n { x: 0.921875, y: 0.703125 },\n { x: 0.921875, y: 0.703125 },\n { x: 0.953125, y: 0.703125 },\n { x: 0.953125, y: 0.703125 },\n { x: 0.984375, y: 0.703125 },\n { x: 0.984375, y: 0.703125 },\n { x: 0.015625, y: 0.734375 },\n { x: 0.015625, y: 0.734375 },\n { x: 0.046875, y: 0.734375 },\n { x: 0.046875, y: 0.734375 },\n { x: 0.078125, y: 0.734375 },\n { x: 0.078125, y: 0.734375 },\n { x: 0.109375, y: 0.734375 },\n { x: 0.109375, y: 0.734375 },\n { x: 0.140625, y: 0.734375 },\n { x: 0.140625, y: 0.734375 },\n { x: 0.171875, y: 0.734375 },\n { x: 0.171875, y: 0.734375 },\n { x: 0.203125, y: 0.734375 },\n { x: 0.203125, y: 0.734375 },\n { x: 0.234375, y: 0.734375 },\n { x: 0.234375, y: 0.734375 },\n { x: 0.265625, y: 0.734375 },\n { x: 0.265625, y: 0.734375 },\n { x: 0.296875, y: 0.734375 },\n { x: 0.296875, y: 0.734375 },\n { x: 0.328125, y: 0.734375 },\n { x: 0.328125, y: 0.734375 },\n { x: 0.359375, y: 0.734375 },\n { x: 0.359375, y: 0.734375 },\n { x: 0.390625, y: 0.734375 },\n { x: 0.390625, y: 0.734375 },\n { x: 0.421875, y: 0.734375 },\n { x: 0.421875, y: 0.734375 },\n { x: 0.453125, y: 0.734375 },\n { x: 0.453125, y: 0.734375 },\n { x: 0.484375, y: 0.734375 },\n { x: 0.484375, y: 0.734375 },\n { x: 0.515625, y: 0.734375 },\n { x: 0.515625, y: 0.734375 },\n { x: 0.546875, y: 0.734375 },\n { x: 0.546875, y: 0.734375 },\n { x: 0.578125, y: 0.734375 },\n { x: 0.578125, y: 0.734375 },\n { x: 0.609375, y: 0.734375 },\n { x: 0.609375, y: 0.734375 },\n { x: 0.640625, y: 0.734375 },\n { x: 0.640625, y: 0.734375 },\n { x: 0.671875, y: 0.734375 },\n { x: 0.671875, y: 0.734375 },\n { x: 0.703125, y: 0.734375 },\n { x: 0.703125, y: 0.734375 },\n { x: 0.734375, y: 0.734375 },\n { x: 0.734375, y: 0.734375 },\n { x: 0.765625, y: 0.734375 },\n { x: 0.765625, y: 0.734375 },\n { x: 0.796875, y: 0.734375 },\n { x: 0.796875, y: 0.734375 },\n { x: 0.828125, y: 0.734375 },\n { x: 0.828125, y: 0.734375 },\n { x: 0.859375, y: 0.734375 },\n { x: 0.859375, y: 0.734375 },\n { x: 0.890625, y: 0.734375 },\n { x: 0.890625, y: 0.734375 },\n { x: 0.921875, y: 0.734375 },\n { x: 0.921875, y: 0.734375 },\n { x: 0.953125, y: 0.734375 },\n { x: 0.953125, y: 0.734375 },\n { x: 0.984375, y: 0.734375 },\n { x: 0.984375, y: 0.734375 },\n { x: 0.015625, y: 0.765625 },\n { x: 0.015625, y: 0.765625 },\n { x: 0.046875, y: 0.765625 },\n { x: 0.046875, y: 0.765625 },\n { x: 0.078125, y: 0.765625 },\n { x: 0.078125, y: 0.765625 },\n { x: 0.109375, y: 0.765625 },\n { x: 0.109375, y: 0.765625 },\n { x: 0.140625, y: 0.765625 },\n { x: 0.140625, y: 0.765625 },\n { x: 0.171875, y: 0.765625 },\n { x: 0.171875, y: 0.765625 },\n { x: 0.203125, y: 0.765625 },\n { x: 0.203125, y: 0.765625 },\n { x: 0.234375, y: 0.765625 },\n { x: 0.234375, y: 0.765625 },\n { x: 0.265625, y: 0.765625 },\n { x: 0.265625, y: 0.765625 },\n { x: 0.296875, y: 0.765625 },\n { x: 0.296875, y: 0.765625 },\n { x: 0.328125, y: 0.765625 },\n { x: 0.328125, y: 0.765625 },\n { x: 0.359375, y: 0.765625 },\n { x: 0.359375, y: 0.765625 },\n { x: 0.390625, y: 0.765625 },\n { x: 0.390625, y: 0.765625 },\n { x: 0.421875, y: 0.765625 },\n { x: 0.421875, y: 0.765625 },\n { x: 0.453125, y: 0.765625 },\n { x: 0.453125, y: 0.765625 },\n { x: 0.484375, y: 0.765625 },\n { x: 0.484375, y: 0.765625 },\n { x: 0.515625, y: 0.765625 },\n { x: 0.515625, y: 0.765625 },\n { x: 0.546875, y: 0.765625 },\n { x: 0.546875, y: 0.765625 },\n { x: 0.578125, y: 0.765625 },\n { x: 0.578125, y: 0.765625 },\n { x: 0.609375, y: 0.765625 },\n { x: 0.609375, y: 0.765625 },\n { x: 0.640625, y: 0.765625 },\n { x: 0.640625, y: 0.765625 },\n { x: 0.671875, y: 0.765625 },\n { x: 0.671875, y: 0.765625 },\n { x: 0.703125, y: 0.765625 },\n { x: 0.703125, y: 0.765625 },\n { x: 0.734375, y: 0.765625 },\n { x: 0.734375, y: 0.765625 },\n { x: 0.765625, y: 0.765625 },\n { x: 0.765625, y: 0.765625 },\n { x: 0.796875, y: 0.765625 },\n { x: 0.796875, y: 0.765625 },\n { x: 0.828125, y: 0.765625 },\n { x: 0.828125, y: 0.765625 },\n { x: 0.859375, y: 0.765625 },\n { x: 0.859375, y: 0.765625 },\n { x: 0.890625, y: 0.765625 },\n { x: 0.890625, y: 0.765625 },\n { x: 0.921875, y: 0.765625 },\n { x: 0.921875, y: 0.765625 },\n { x: 0.953125, y: 0.765625 },\n { x: 0.953125, y: 0.765625 },\n { x: 0.984375, y: 0.765625 },\n { x: 0.984375, y: 0.765625 },\n { x: 0.015625, y: 0.796875 },\n { x: 0.015625, y: 0.796875 },\n { x: 0.046875, y: 0.796875 },\n { x: 0.046875, y: 0.796875 },\n { x: 0.078125, y: 0.796875 },\n { x: 0.078125, y: 0.796875 },\n { x: 0.109375, y: 0.796875 },\n { x: 0.109375, y: 0.796875 },\n { x: 0.140625, y: 0.796875 },\n { x: 0.140625, y: 0.796875 },\n { x: 0.171875, y: 0.796875 },\n { x: 0.171875, y: 0.796875 },\n { x: 0.203125, y: 0.796875 },\n { x: 0.203125, y: 0.796875 },\n { x: 0.234375, y: 0.796875 },\n { x: 0.234375, y: 0.796875 },\n { x: 0.265625, y: 0.796875 },\n { x: 0.265625, y: 0.796875 },\n { x: 0.296875, y: 0.796875 },\n { x: 0.296875, y: 0.796875 },\n { x: 0.328125, y: 0.796875 },\n { x: 0.328125, y: 0.796875 },\n { x: 0.359375, y: 0.796875 },\n { x: 0.359375, y: 0.796875 },\n { x: 0.390625, y: 0.796875 },\n { x: 0.390625, y: 0.796875 },\n { x: 0.421875, y: 0.796875 },\n { x: 0.421875, y: 0.796875 },\n { x: 0.453125, y: 0.796875 },\n { x: 0.453125, y: 0.796875 },\n { x: 0.484375, y: 0.796875 },\n { x: 0.484375, y: 0.796875 },\n { x: 0.515625, y: 0.796875 },\n { x: 0.515625, y: 0.796875 },\n { x: 0.546875, y: 0.796875 },\n { x: 0.546875, y: 0.796875 },\n { x: 0.578125, y: 0.796875 },\n { x: 0.578125, y: 0.796875 },\n { x: 0.609375, y: 0.796875 },\n { x: 0.609375, y: 0.796875 },\n { x: 0.640625, y: 0.796875 },\n { x: 0.640625, y: 0.796875 },\n { x: 0.671875, y: 0.796875 },\n { x: 0.671875, y: 0.796875 },\n { x: 0.703125, y: 0.796875 },\n { x: 0.703125, y: 0.796875 },\n { x: 0.734375, y: 0.796875 },\n { x: 0.734375, y: 0.796875 },\n { x: 0.765625, y: 0.796875 },\n { x: 0.765625, y: 0.796875 },\n { x: 0.796875, y: 0.796875 },\n { x: 0.796875, y: 0.796875 },\n { x: 0.828125, y: 0.796875 },\n { x: 0.828125, y: 0.796875 },\n { x: 0.859375, y: 0.796875 },\n { x: 0.859375, y: 0.796875 },\n { x: 0.890625, y: 0.796875 },\n { x: 0.890625, y: 0.796875 },\n { x: 0.921875, y: 0.796875 },\n { x: 0.921875, y: 0.796875 },\n { x: 0.953125, y: 0.796875 },\n { x: 0.953125, y: 0.796875 },\n { x: 0.984375, y: 0.796875 },\n { x: 0.984375, y: 0.796875 },\n { x: 0.015625, y: 0.828125 },\n { x: 0.015625, y: 0.828125 },\n { x: 0.046875, y: 0.828125 },\n { x: 0.046875, y: 0.828125 },\n { x: 0.078125, y: 0.828125 },\n { x: 0.078125, y: 0.828125 },\n { x: 0.109375, y: 0.828125 },\n { x: 0.109375, y: 0.828125 },\n { x: 0.140625, y: 0.828125 },\n { x: 0.140625, y: 0.828125 },\n { x: 0.171875, y: 0.828125 },\n { x: 0.171875, y: 0.828125 },\n { x: 0.203125, y: 0.828125 },\n { x: 0.203125, y: 0.828125 },\n { x: 0.234375, y: 0.828125 },\n { x: 0.234375, y: 0.828125 },\n { x: 0.265625, y: 0.828125 },\n { x: 0.265625, y: 0.828125 },\n { x: 0.296875, y: 0.828125 },\n { x: 0.296875, y: 0.828125 },\n { x: 0.328125, y: 0.828125 },\n { x: 0.328125, y: 0.828125 },\n { x: 0.359375, y: 0.828125 },\n { x: 0.359375, y: 0.828125 },\n { x: 0.390625, y: 0.828125 },\n { x: 0.390625, y: 0.828125 },\n { x: 0.421875, y: 0.828125 },\n { x: 0.421875, y: 0.828125 },\n { x: 0.453125, y: 0.828125 },\n { x: 0.453125, y: 0.828125 },\n { x: 0.484375, y: 0.828125 },\n { x: 0.484375, y: 0.828125 },\n { x: 0.515625, y: 0.828125 },\n { x: 0.515625, y: 0.828125 },\n { x: 0.546875, y: 0.828125 },\n { x: 0.546875, y: 0.828125 },\n { x: 0.578125, y: 0.828125 },\n { x: 0.578125, y: 0.828125 },\n { x: 0.609375, y: 0.828125 },\n { x: 0.609375, y: 0.828125 },\n { x: 0.640625, y: 0.828125 },\n { x: 0.640625, y: 0.828125 },\n { x: 0.671875, y: 0.828125 },\n { x: 0.671875, y: 0.828125 },\n { x: 0.703125, y: 0.828125 },\n { x: 0.703125, y: 0.828125 },\n { x: 0.734375, y: 0.828125 },\n { x: 0.734375, y: 0.828125 },\n { x: 0.765625, y: 0.828125 },\n { x: 0.765625, y: 0.828125 },\n { x: 0.796875, y: 0.828125 },\n { x: 0.796875, y: 0.828125 },\n { x: 0.828125, y: 0.828125 },\n { x: 0.828125, y: 0.828125 },\n { x: 0.859375, y: 0.828125 },\n { x: 0.859375, y: 0.828125 },\n { x: 0.890625, y: 0.828125 },\n { x: 0.890625, y: 0.828125 },\n { x: 0.921875, y: 0.828125 },\n { x: 0.921875, y: 0.828125 },\n { x: 0.953125, y: 0.828125 },\n { x: 0.953125, y: 0.828125 },\n { x: 0.984375, y: 0.828125 },\n { x: 0.984375, y: 0.828125 },\n { x: 0.015625, y: 0.859375 },\n { x: 0.015625, y: 0.859375 },\n { x: 0.046875, y: 0.859375 },\n { x: 0.046875, y: 0.859375 },\n { x: 0.078125, y: 0.859375 },\n { x: 0.078125, y: 0.859375 },\n { x: 0.109375, y: 0.859375 },\n { x: 0.109375, y: 0.859375 },\n { x: 0.140625, y: 0.859375 },\n { x: 0.140625, y: 0.859375 },\n { x: 0.171875, y: 0.859375 },\n { x: 0.171875, y: 0.859375 },\n { x: 0.203125, y: 0.859375 },\n { x: 0.203125, y: 0.859375 },\n { x: 0.234375, y: 0.859375 },\n { x: 0.234375, y: 0.859375 },\n { x: 0.265625, y: 0.859375 },\n { x: 0.265625, y: 0.859375 },\n { x: 0.296875, y: 0.859375 },\n { x: 0.296875, y: 0.859375 },\n { x: 0.328125, y: 0.859375 },\n { x: 0.328125, y: 0.859375 },\n { x: 0.359375, y: 0.859375 },\n { x: 0.359375, y: 0.859375 },\n { x: 0.390625, y: 0.859375 },\n { x: 0.390625, y: 0.859375 },\n { x: 0.421875, y: 0.859375 },\n { x: 0.421875, y: 0.859375 },\n { x: 0.453125, y: 0.859375 },\n { x: 0.453125, y: 0.859375 },\n { x: 0.484375, y: 0.859375 },\n { x: 0.484375, y: 0.859375 },\n { x: 0.515625, y: 0.859375 },\n { x: 0.515625, y: 0.859375 },\n { x: 0.546875, y: 0.859375 },\n { x: 0.546875, y: 0.859375 },\n { x: 0.578125, y: 0.859375 },\n { x: 0.578125, y: 0.859375 },\n { x: 0.609375, y: 0.859375 },\n { x: 0.609375, y: 0.859375 },\n { x: 0.640625, y: 0.859375 },\n { x: 0.640625, y: 0.859375 },\n { x: 0.671875, y: 0.859375 },\n { x: 0.671875, y: 0.859375 },\n { x: 0.703125, y: 0.859375 },\n { x: 0.703125, y: 0.859375 },\n { x: 0.734375, y: 0.859375 },\n { x: 0.734375, y: 0.859375 },\n { x: 0.765625, y: 0.859375 },\n { x: 0.765625, y: 0.859375 },\n { x: 0.796875, y: 0.859375 },\n { x: 0.796875, y: 0.859375 },\n { x: 0.828125, y: 0.859375 },\n { x: 0.828125, y: 0.859375 },\n { x: 0.859375, y: 0.859375 },\n { x: 0.859375, y: 0.859375 },\n { x: 0.890625, y: 0.859375 },\n { x: 0.890625, y: 0.859375 },\n { x: 0.921875, y: 0.859375 },\n { x: 0.921875, y: 0.859375 },\n { x: 0.953125, y: 0.859375 },\n { x: 0.953125, y: 0.859375 },\n { x: 0.984375, y: 0.859375 },\n { x: 0.984375, y: 0.859375 },\n { x: 0.015625, y: 0.890625 },\n { x: 0.015625, y: 0.890625 },\n { x: 0.046875, y: 0.890625 },\n { x: 0.046875, y: 0.890625 },\n { x: 0.078125, y: 0.890625 },\n { x: 0.078125, y: 0.890625 },\n { x: 0.109375, y: 0.890625 },\n { x: 0.109375, y: 0.890625 },\n { x: 0.140625, y: 0.890625 },\n { x: 0.140625, y: 0.890625 },\n { x: 0.171875, y: 0.890625 },\n { x: 0.171875, y: 0.890625 },\n { x: 0.203125, y: 0.890625 },\n { x: 0.203125, y: 0.890625 },\n { x: 0.234375, y: 0.890625 },\n { x: 0.234375, y: 0.890625 },\n { x: 0.265625, y: 0.890625 },\n { x: 0.265625, y: 0.890625 },\n { x: 0.296875, y: 0.890625 },\n { x: 0.296875, y: 0.890625 },\n { x: 0.328125, y: 0.890625 },\n { x: 0.328125, y: 0.890625 },\n { x: 0.359375, y: 0.890625 },\n { x: 0.359375, y: 0.890625 },\n { x: 0.390625, y: 0.890625 },\n { x: 0.390625, y: 0.890625 },\n { x: 0.421875, y: 0.890625 },\n { x: 0.421875, y: 0.890625 },\n { x: 0.453125, y: 0.890625 },\n { x: 0.453125, y: 0.890625 },\n { x: 0.484375, y: 0.890625 },\n { x: 0.484375, y: 0.890625 },\n { x: 0.515625, y: 0.890625 },\n { x: 0.515625, y: 0.890625 },\n { x: 0.546875, y: 0.890625 },\n { x: 0.546875, y: 0.890625 },\n { x: 0.578125, y: 0.890625 },\n { x: 0.578125, y: 0.890625 },\n { x: 0.609375, y: 0.890625 },\n { x: 0.609375, y: 0.890625 },\n { x: 0.640625, y: 0.890625 },\n { x: 0.640625, y: 0.890625 },\n { x: 0.671875, y: 0.890625 },\n { x: 0.671875, y: 0.890625 },\n { x: 0.703125, y: 0.890625 },\n { x: 0.703125, y: 0.890625 },\n { x: 0.734375, y: 0.890625 },\n { x: 0.734375, y: 0.890625 },\n { x: 0.765625, y: 0.890625 },\n { x: 0.765625, y: 0.890625 },\n { x: 0.796875, y: 0.890625 },\n { x: 0.796875, y: 0.890625 },\n { x: 0.828125, y: 0.890625 },\n { x: 0.828125, y: 0.890625 },\n { x: 0.859375, y: 0.890625 },\n { x: 0.859375, y: 0.890625 },\n { x: 0.890625, y: 0.890625 },\n { x: 0.890625, y: 0.890625 },\n { x: 0.921875, y: 0.890625 },\n { x: 0.921875, y: 0.890625 },\n { x: 0.953125, y: 0.890625 },\n { x: 0.953125, y: 0.890625 },\n { x: 0.984375, y: 0.890625 },\n { x: 0.984375, y: 0.890625 },\n { x: 0.015625, y: 0.921875 },\n { x: 0.015625, y: 0.921875 },\n { x: 0.046875, y: 0.921875 },\n { x: 0.046875, y: 0.921875 },\n { x: 0.078125, y: 0.921875 },\n { x: 0.078125, y: 0.921875 },\n { x: 0.109375, y: 0.921875 },\n { x: 0.109375, y: 0.921875 },\n { x: 0.140625, y: 0.921875 },\n { x: 0.140625, y: 0.921875 },\n { x: 0.171875, y: 0.921875 },\n { x: 0.171875, y: 0.921875 },\n { x: 0.203125, y: 0.921875 },\n { x: 0.203125, y: 0.921875 },\n { x: 0.234375, y: 0.921875 },\n { x: 0.234375, y: 0.921875 },\n { x: 0.265625, y: 0.921875 },\n { x: 0.265625, y: 0.921875 },\n { x: 0.296875, y: 0.921875 },\n { x: 0.296875, y: 0.921875 },\n { x: 0.328125, y: 0.921875 },\n { x: 0.328125, y: 0.921875 },\n { x: 0.359375, y: 0.921875 },\n { x: 0.359375, y: 0.921875 },\n { x: 0.390625, y: 0.921875 },\n { x: 0.390625, y: 0.921875 },\n { x: 0.421875, y: 0.921875 },\n { x: 0.421875, y: 0.921875 },\n { x: 0.453125, y: 0.921875 },\n { x: 0.453125, y: 0.921875 },\n { x: 0.484375, y: 0.921875 },\n { x: 0.484375, y: 0.921875 },\n { x: 0.515625, y: 0.921875 },\n { x: 0.515625, y: 0.921875 },\n { x: 0.546875, y: 0.921875 },\n { x: 0.546875, y: 0.921875 },\n { x: 0.578125, y: 0.921875 },\n { x: 0.578125, y: 0.921875 },\n { x: 0.609375, y: 0.921875 },\n { x: 0.609375, y: 0.921875 },\n { x: 0.640625, y: 0.921875 },\n { x: 0.640625, y: 0.921875 },\n { x: 0.671875, y: 0.921875 },\n { x: 0.671875, y: 0.921875 },\n { x: 0.703125, y: 0.921875 },\n { x: 0.703125, y: 0.921875 },\n { x: 0.734375, y: 0.921875 },\n { x: 0.734375, y: 0.921875 },\n { x: 0.765625, y: 0.921875 },\n { x: 0.765625, y: 0.921875 },\n { x: 0.796875, y: 0.921875 },\n { x: 0.796875, y: 0.921875 },\n { x: 0.828125, y: 0.921875 },\n { x: 0.828125, y: 0.921875 },\n { x: 0.859375, y: 0.921875 },\n { x: 0.859375, y: 0.921875 },\n { x: 0.890625, y: 0.921875 },\n { x: 0.890625, y: 0.921875 },\n { x: 0.921875, y: 0.921875 },\n { x: 0.921875, y: 0.921875 },\n { x: 0.953125, y: 0.921875 },\n { x: 0.953125, y: 0.921875 },\n { x: 0.984375, y: 0.921875 },\n { x: 0.984375, y: 0.921875 },\n { x: 0.015625, y: 0.953125 },\n { x: 0.015625, y: 0.953125 },\n { x: 0.046875, y: 0.953125 },\n { x: 0.046875, y: 0.953125 },\n { x: 0.078125, y: 0.953125 },\n { x: 0.078125, y: 0.953125 },\n { x: 0.109375, y: 0.953125 },\n { x: 0.109375, y: 0.953125 },\n { x: 0.140625, y: 0.953125 },\n { x: 0.140625, y: 0.953125 },\n { x: 0.171875, y: 0.953125 },\n { x: 0.171875, y: 0.953125 },\n { x: 0.203125, y: 0.953125 },\n { x: 0.203125, y: 0.953125 },\n { x: 0.234375, y: 0.953125 },\n { x: 0.234375, y: 0.953125 },\n { x: 0.265625, y: 0.953125 },\n { x: 0.265625, y: 0.953125 },\n { x: 0.296875, y: 0.953125 },\n { x: 0.296875, y: 0.953125 },\n { x: 0.328125, y: 0.953125 },\n { x: 0.328125, y: 0.953125 },\n { x: 0.359375, y: 0.953125 },\n { x: 0.359375, y: 0.953125 },\n { x: 0.390625, y: 0.953125 },\n { x: 0.390625, y: 0.953125 },\n { x: 0.421875, y: 0.953125 },\n { x: 0.421875, y: 0.953125 },\n { x: 0.453125, y: 0.953125 },\n { x: 0.453125, y: 0.953125 },\n { x: 0.484375, y: 0.953125 },\n { x: 0.484375, y: 0.953125 },\n { x: 0.515625, y: 0.953125 },\n { x: 0.515625, y: 0.953125 },\n { x: 0.546875, y: 0.953125 },\n { x: 0.546875, y: 0.953125 },\n { x: 0.578125, y: 0.953125 },\n { x: 0.578125, y: 0.953125 },\n { x: 0.609375, y: 0.953125 },\n { x: 0.609375, y: 0.953125 },\n { x: 0.640625, y: 0.953125 },\n { x: 0.640625, y: 0.953125 },\n { x: 0.671875, y: 0.953125 },\n { x: 0.671875, y: 0.953125 },\n { x: 0.703125, y: 0.953125 },\n { x: 0.703125, y: 0.953125 },\n { x: 0.734375, y: 0.953125 },\n { x: 0.734375, y: 0.953125 },\n { x: 0.765625, y: 0.953125 },\n { x: 0.765625, y: 0.953125 },\n { x: 0.796875, y: 0.953125 },\n { x: 0.796875, y: 0.953125 },\n { x: 0.828125, y: 0.953125 },\n { x: 0.828125, y: 0.953125 },\n { x: 0.859375, y: 0.953125 },\n { x: 0.859375, y: 0.953125 },\n { x: 0.890625, y: 0.953125 },\n { x: 0.890625, y: 0.953125 },\n { x: 0.921875, y: 0.953125 },\n { x: 0.921875, y: 0.953125 },\n { x: 0.953125, y: 0.953125 },\n { x: 0.953125, y: 0.953125 },\n { x: 0.984375, y: 0.953125 },\n { x: 0.984375, y: 0.953125 },\n { x: 0.015625, y: 0.984375 },\n { x: 0.015625, y: 0.984375 },\n { x: 0.046875, y: 0.984375 },\n { x: 0.046875, y: 0.984375 },\n { x: 0.078125, y: 0.984375 },\n { x: 0.078125, y: 0.984375 },\n { x: 0.109375, y: 0.984375 },\n { x: 0.109375, y: 0.984375 },\n { x: 0.140625, y: 0.984375 },\n { x: 0.140625, y: 0.984375 },\n { x: 0.171875, y: 0.984375 },\n { x: 0.171875, y: 0.984375 },\n { x: 0.203125, y: 0.984375 },\n { x: 0.203125, y: 0.984375 },\n { x: 0.234375, y: 0.984375 },\n { x: 0.234375, y: 0.984375 },\n { x: 0.265625, y: 0.984375 },\n { x: 0.265625, y: 0.984375 },\n { x: 0.296875, y: 0.984375 },\n { x: 0.296875, y: 0.984375 },\n { x: 0.328125, y: 0.984375 },\n { x: 0.328125, y: 0.984375 },\n { x: 0.359375, y: 0.984375 },\n { x: 0.359375, y: 0.984375 },\n { x: 0.390625, y: 0.984375 },\n { x: 0.390625, y: 0.984375 },\n { x: 0.421875, y: 0.984375 },\n { x: 0.421875, y: 0.984375 },\n { x: 0.453125, y: 0.984375 },\n { x: 0.453125, y: 0.984375 },\n { x: 0.484375, y: 0.984375 },\n { x: 0.484375, y: 0.984375 },\n { x: 0.515625, y: 0.984375 },\n { x: 0.515625, y: 0.984375 },\n { x: 0.546875, y: 0.984375 },\n { x: 0.546875, y: 0.984375 },\n { x: 0.578125, y: 0.984375 },\n { x: 0.578125, y: 0.984375 },\n { x: 0.609375, y: 0.984375 },\n { x: 0.609375, y: 0.984375 },\n { x: 0.640625, y: 0.984375 },\n { x: 0.640625, y: 0.984375 },\n { x: 0.671875, y: 0.984375 },\n { x: 0.671875, y: 0.984375 },\n { x: 0.703125, y: 0.984375 },\n { x: 0.703125, y: 0.984375 },\n { x: 0.734375, y: 0.984375 },\n { x: 0.734375, y: 0.984375 },\n { x: 0.765625, y: 0.984375 },\n { x: 0.765625, y: 0.984375 },\n { x: 0.796875, y: 0.984375 },\n { x: 0.796875, y: 0.984375 },\n { x: 0.828125, y: 0.984375 },\n { x: 0.828125, y: 0.984375 },\n { x: 0.859375, y: 0.984375 },\n { x: 0.859375, y: 0.984375 },\n { x: 0.890625, y: 0.984375 },\n { x: 0.890625, y: 0.984375 },\n { x: 0.921875, y: 0.984375 },\n { x: 0.921875, y: 0.984375 },\n { x: 0.953125, y: 0.984375 },\n { x: 0.953125, y: 0.984375 },\n { x: 0.984375, y: 0.984375 },\n { x: 0.984375, y: 0.984375 },\n { x: 0.03125, y: 0.03125 },\n { x: 0.03125, y: 0.03125 },\n { x: 0.09375, y: 0.03125 },\n { x: 0.09375, y: 0.03125 },\n { x: 0.15625, y: 0.03125 },\n { x: 0.15625, y: 0.03125 },\n { x: 0.21875, y: 0.03125 },\n { x: 0.21875, y: 0.03125 },\n { x: 0.28125, y: 0.03125 },\n { x: 0.28125, y: 0.03125 },\n { x: 0.34375, y: 0.03125 },\n { x: 0.34375, y: 0.03125 },\n { x: 0.40625, y: 0.03125 },\n { x: 0.40625, y: 0.03125 },\n { x: 0.46875, y: 0.03125 },\n { x: 0.46875, y: 0.03125 },\n { x: 0.53125, y: 0.03125 },\n { x: 0.53125, y: 0.03125 },\n { x: 0.59375, y: 0.03125 },\n { x: 0.59375, y: 0.03125 },\n { x: 0.65625, y: 0.03125 },\n { x: 0.65625, y: 0.03125 },\n { x: 0.71875, y: 0.03125 },\n { x: 0.71875, y: 0.03125 },\n { x: 0.78125, y: 0.03125 },\n { x: 0.78125, y: 0.03125 },\n { x: 0.84375, y: 0.03125 },\n { x: 0.84375, y: 0.03125 },\n { x: 0.90625, y: 0.03125 },\n { x: 0.90625, y: 0.03125 },\n { x: 0.96875, y: 0.03125 },\n { x: 0.96875, y: 0.03125 },\n { x: 0.03125, y: 0.09375 },\n { x: 0.03125, y: 0.09375 },\n { x: 0.09375, y: 0.09375 },\n { x: 0.09375, y: 0.09375 },\n { x: 0.15625, y: 0.09375 },\n { x: 0.15625, y: 0.09375 },\n { x: 0.21875, y: 0.09375 },\n { x: 0.21875, y: 0.09375 },\n { x: 0.28125, y: 0.09375 },\n { x: 0.28125, y: 0.09375 },\n { x: 0.34375, y: 0.09375 },\n { x: 0.34375, y: 0.09375 },\n { x: 0.40625, y: 0.09375 },\n { x: 0.40625, y: 0.09375 },\n { x: 0.46875, y: 0.09375 },\n { x: 0.46875, y: 0.09375 },\n { x: 0.53125, y: 0.09375 },\n { x: 0.53125, y: 0.09375 },\n { x: 0.59375, y: 0.09375 },\n { x: 0.59375, y: 0.09375 },\n { x: 0.65625, y: 0.09375 },\n { x: 0.65625, y: 0.09375 },\n { x: 0.71875, y: 0.09375 },\n { x: 0.71875, y: 0.09375 },\n { x: 0.78125, y: 0.09375 },\n { x: 0.78125, y: 0.09375 },\n { x: 0.84375, y: 0.09375 },\n { x: 0.84375, y: 0.09375 },\n { x: 0.90625, y: 0.09375 },\n { x: 0.90625, y: 0.09375 },\n { x: 0.96875, y: 0.09375 },\n { x: 0.96875, y: 0.09375 },\n { x: 0.03125, y: 0.15625 },\n { x: 0.03125, y: 0.15625 },\n { x: 0.09375, y: 0.15625 },\n { x: 0.09375, y: 0.15625 },\n { x: 0.15625, y: 0.15625 },\n { x: 0.15625, y: 0.15625 },\n { x: 0.21875, y: 0.15625 },\n { x: 0.21875, y: 0.15625 },\n { x: 0.28125, y: 0.15625 },\n { x: 0.28125, y: 0.15625 },\n { x: 0.34375, y: 0.15625 },\n { x: 0.34375, y: 0.15625 },\n { x: 0.40625, y: 0.15625 },\n { x: 0.40625, y: 0.15625 },\n { x: 0.46875, y: 0.15625 },\n { x: 0.46875, y: 0.15625 },\n { x: 0.53125, y: 0.15625 },\n { x: 0.53125, y: 0.15625 },\n { x: 0.59375, y: 0.15625 },\n { x: 0.59375, y: 0.15625 },\n { x: 0.65625, y: 0.15625 },\n { x: 0.65625, y: 0.15625 },\n { x: 0.71875, y: 0.15625 },\n { x: 0.71875, y: 0.15625 },\n { x: 0.78125, y: 0.15625 },\n { x: 0.78125, y: 0.15625 },\n { x: 0.84375, y: 0.15625 },\n { x: 0.84375, y: 0.15625 },\n { x: 0.90625, y: 0.15625 },\n { x: 0.90625, y: 0.15625 },\n { x: 0.96875, y: 0.15625 },\n { x: 0.96875, y: 0.15625 },\n { x: 0.03125, y: 0.21875 },\n { x: 0.03125, y: 0.21875 },\n { x: 0.09375, y: 0.21875 },\n { x: 0.09375, y: 0.21875 },\n { x: 0.15625, y: 0.21875 },\n { x: 0.15625, y: 0.21875 },\n { x: 0.21875, y: 0.21875 },\n { x: 0.21875, y: 0.21875 },\n { x: 0.28125, y: 0.21875 },\n { x: 0.28125, y: 0.21875 },\n { x: 0.34375, y: 0.21875 },\n { x: 0.34375, y: 0.21875 },\n { x: 0.40625, y: 0.21875 },\n { x: 0.40625, y: 0.21875 },\n { x: 0.46875, y: 0.21875 },\n { x: 0.46875, y: 0.21875 },\n { x: 0.53125, y: 0.21875 },\n { x: 0.53125, y: 0.21875 },\n { x: 0.59375, y: 0.21875 },\n { x: 0.59375, y: 0.21875 },\n { x: 0.65625, y: 0.21875 },\n { x: 0.65625, y: 0.21875 },\n { x: 0.71875, y: 0.21875 },\n { x: 0.71875, y: 0.21875 },\n { x: 0.78125, y: 0.21875 },\n { x: 0.78125, y: 0.21875 },\n { x: 0.84375, y: 0.21875 },\n { x: 0.84375, y: 0.21875 },\n { x: 0.90625, y: 0.21875 },\n { x: 0.90625, y: 0.21875 },\n { x: 0.96875, y: 0.21875 },\n { x: 0.96875, y: 0.21875 },\n { x: 0.03125, y: 0.28125 },\n { x: 0.03125, y: 0.28125 },\n { x: 0.09375, y: 0.28125 },\n { x: 0.09375, y: 0.28125 },\n { x: 0.15625, y: 0.28125 },\n { x: 0.15625, y: 0.28125 },\n { x: 0.21875, y: 0.28125 },\n { x: 0.21875, y: 0.28125 },\n { x: 0.28125, y: 0.28125 },\n { x: 0.28125, y: 0.28125 },\n { x: 0.34375, y: 0.28125 },\n { x: 0.34375, y: 0.28125 },\n { x: 0.40625, y: 0.28125 },\n { x: 0.40625, y: 0.28125 },\n { x: 0.46875, y: 0.28125 },\n { x: 0.46875, y: 0.28125 },\n { x: 0.53125, y: 0.28125 },\n { x: 0.53125, y: 0.28125 },\n { x: 0.59375, y: 0.28125 },\n { x: 0.59375, y: 0.28125 },\n { x: 0.65625, y: 0.28125 },\n { x: 0.65625, y: 0.28125 },\n { x: 0.71875, y: 0.28125 },\n { x: 0.71875, y: 0.28125 },\n { x: 0.78125, y: 0.28125 },\n { x: 0.78125, y: 0.28125 },\n { x: 0.84375, y: 0.28125 },\n { x: 0.84375, y: 0.28125 },\n { x: 0.90625, y: 0.28125 },\n { x: 0.90625, y: 0.28125 },\n { x: 0.96875, y: 0.28125 },\n { x: 0.96875, y: 0.28125 },\n { x: 0.03125, y: 0.34375 },\n { x: 0.03125, y: 0.34375 },\n { x: 0.09375, y: 0.34375 },\n { x: 0.09375, y: 0.34375 },\n { x: 0.15625, y: 0.34375 },\n { x: 0.15625, y: 0.34375 },\n { x: 0.21875, y: 0.34375 },\n { x: 0.21875, y: 0.34375 },\n { x: 0.28125, y: 0.34375 },\n { x: 0.28125, y: 0.34375 },\n { x: 0.34375, y: 0.34375 },\n { x: 0.34375, y: 0.34375 },\n { x: 0.40625, y: 0.34375 },\n { x: 0.40625, y: 0.34375 },\n { x: 0.46875, y: 0.34375 },\n { x: 0.46875, y: 0.34375 },\n { x: 0.53125, y: 0.34375 },\n { x: 0.53125, y: 0.34375 },\n { x: 0.59375, y: 0.34375 },\n { x: 0.59375, y: 0.34375 },\n { x: 0.65625, y: 0.34375 },\n { x: 0.65625, y: 0.34375 },\n { x: 0.71875, y: 0.34375 },\n { x: 0.71875, y: 0.34375 },\n { x: 0.78125, y: 0.34375 },\n { x: 0.78125, y: 0.34375 },\n { x: 0.84375, y: 0.34375 },\n { x: 0.84375, y: 0.34375 },\n { x: 0.90625, y: 0.34375 },\n { x: 0.90625, y: 0.34375 },\n { x: 0.96875, y: 0.34375 },\n { x: 0.96875, y: 0.34375 },\n { x: 0.03125, y: 0.40625 },\n { x: 0.03125, y: 0.40625 },\n { x: 0.09375, y: 0.40625 },\n { x: 0.09375, y: 0.40625 },\n { x: 0.15625, y: 0.40625 },\n { x: 0.15625, y: 0.40625 },\n { x: 0.21875, y: 0.40625 },\n { x: 0.21875, y: 0.40625 },\n { x: 0.28125, y: 0.40625 },\n { x: 0.28125, y: 0.40625 },\n { x: 0.34375, y: 0.40625 },\n { x: 0.34375, y: 0.40625 },\n { x: 0.40625, y: 0.40625 },\n { x: 0.40625, y: 0.40625 },\n { x: 0.46875, y: 0.40625 },\n { x: 0.46875, y: 0.40625 },\n { x: 0.53125, y: 0.40625 },\n { x: 0.53125, y: 0.40625 },\n { x: 0.59375, y: 0.40625 },\n { x: 0.59375, y: 0.40625 },\n { x: 0.65625, y: 0.40625 },\n { x: 0.65625, y: 0.40625 },\n { x: 0.71875, y: 0.40625 },\n { x: 0.71875, y: 0.40625 },\n { x: 0.78125, y: 0.40625 },\n { x: 0.78125, y: 0.40625 },\n { x: 0.84375, y: 0.40625 },\n { x: 0.84375, y: 0.40625 },\n { x: 0.90625, y: 0.40625 },\n { x: 0.90625, y: 0.40625 },\n { x: 0.96875, y: 0.40625 },\n { x: 0.96875, y: 0.40625 },\n { x: 0.03125, y: 0.46875 },\n { x: 0.03125, y: 0.46875 },\n { x: 0.09375, y: 0.46875 },\n { x: 0.09375, y: 0.46875 },\n { x: 0.15625, y: 0.46875 },\n { x: 0.15625, y: 0.46875 },\n { x: 0.21875, y: 0.46875 },\n { x: 0.21875, y: 0.46875 },\n { x: 0.28125, y: 0.46875 },\n { x: 0.28125, y: 0.46875 },\n { x: 0.34375, y: 0.46875 },\n { x: 0.34375, y: 0.46875 },\n { x: 0.40625, y: 0.46875 },\n { x: 0.40625, y: 0.46875 },\n { x: 0.46875, y: 0.46875 },\n { x: 0.46875, y: 0.46875 },\n { x: 0.53125, y: 0.46875 },\n { x: 0.53125, y: 0.46875 },\n { x: 0.59375, y: 0.46875 },\n { x: 0.59375, y: 0.46875 },\n { x: 0.65625, y: 0.46875 },\n { x: 0.65625, y: 0.46875 },\n { x: 0.71875, y: 0.46875 },\n { x: 0.71875, y: 0.46875 },\n { x: 0.78125, y: 0.46875 },\n { x: 0.78125, y: 0.46875 },\n { x: 0.84375, y: 0.46875 },\n { x: 0.84375, y: 0.46875 },\n { x: 0.90625, y: 0.46875 },\n { x: 0.90625, y: 0.46875 },\n { x: 0.96875, y: 0.46875 },\n { x: 0.96875, y: 0.46875 },\n { x: 0.03125, y: 0.53125 },\n { x: 0.03125, y: 0.53125 },\n { x: 0.09375, y: 0.53125 },\n { x: 0.09375, y: 0.53125 },\n { x: 0.15625, y: 0.53125 },\n { x: 0.15625, y: 0.53125 },\n { x: 0.21875, y: 0.53125 },\n { x: 0.21875, y: 0.53125 },\n { x: 0.28125, y: 0.53125 },\n { x: 0.28125, y: 0.53125 },\n { x: 0.34375, y: 0.53125 },\n { x: 0.34375, y: 0.53125 },\n { x: 0.40625, y: 0.53125 },\n { x: 0.40625, y: 0.53125 },\n { x: 0.46875, y: 0.53125 },\n { x: 0.46875, y: 0.53125 },\n { x: 0.53125, y: 0.53125 },\n { x: 0.53125, y: 0.53125 },\n { x: 0.59375, y: 0.53125 },\n { x: 0.59375, y: 0.53125 },\n { x: 0.65625, y: 0.53125 },\n { x: 0.65625, y: 0.53125 },\n { x: 0.71875, y: 0.53125 },\n { x: 0.71875, y: 0.53125 },\n { x: 0.78125, y: 0.53125 },\n { x: 0.78125, y: 0.53125 },\n { x: 0.84375, y: 0.53125 },\n { x: 0.84375, y: 0.53125 },\n { x: 0.90625, y: 0.53125 },\n { x: 0.90625, y: 0.53125 },\n { x: 0.96875, y: 0.53125 },\n { x: 0.96875, y: 0.53125 },\n { x: 0.03125, y: 0.59375 },\n { x: 0.03125, y: 0.59375 },\n { x: 0.09375, y: 0.59375 },\n { x: 0.09375, y: 0.59375 },\n { x: 0.15625, y: 0.59375 },\n { x: 0.15625, y: 0.59375 },\n { x: 0.21875, y: 0.59375 },\n { x: 0.21875, y: 0.59375 },\n { x: 0.28125, y: 0.59375 },\n { x: 0.28125, y: 0.59375 },\n { x: 0.34375, y: 0.59375 },\n { x: 0.34375, y: 0.59375 },\n { x: 0.40625, y: 0.59375 },\n { x: 0.40625, y: 0.59375 },\n { x: 0.46875, y: 0.59375 },\n { x: 0.46875, y: 0.59375 },\n { x: 0.53125, y: 0.59375 },\n { x: 0.53125, y: 0.59375 },\n { x: 0.59375, y: 0.59375 },\n { x: 0.59375, y: 0.59375 },\n { x: 0.65625, y: 0.59375 },\n { x: 0.65625, y: 0.59375 },\n { x: 0.71875, y: 0.59375 },\n { x: 0.71875, y: 0.59375 },\n { x: 0.78125, y: 0.59375 },\n { x: 0.78125, y: 0.59375 },\n { x: 0.84375, y: 0.59375 },\n { x: 0.84375, y: 0.59375 },\n { x: 0.90625, y: 0.59375 },\n { x: 0.90625, y: 0.59375 },\n { x: 0.96875, y: 0.59375 },\n { x: 0.96875, y: 0.59375 },\n { x: 0.03125, y: 0.65625 },\n { x: 0.03125, y: 0.65625 },\n { x: 0.09375, y: 0.65625 },\n { x: 0.09375, y: 0.65625 },\n { x: 0.15625, y: 0.65625 },\n { x: 0.15625, y: 0.65625 },\n { x: 0.21875, y: 0.65625 },\n { x: 0.21875, y: 0.65625 },\n { x: 0.28125, y: 0.65625 },\n { x: 0.28125, y: 0.65625 },\n { x: 0.34375, y: 0.65625 },\n { x: 0.34375, y: 0.65625 },\n { x: 0.40625, y: 0.65625 },\n { x: 0.40625, y: 0.65625 },\n { x: 0.46875, y: 0.65625 },\n { x: 0.46875, y: 0.65625 },\n { x: 0.53125, y: 0.65625 },\n { x: 0.53125, y: 0.65625 },\n { x: 0.59375, y: 0.65625 },\n { x: 0.59375, y: 0.65625 },\n { x: 0.65625, y: 0.65625 },\n { x: 0.65625, y: 0.65625 },\n { x: 0.71875, y: 0.65625 },\n { x: 0.71875, y: 0.65625 },\n { x: 0.78125, y: 0.65625 },\n { x: 0.78125, y: 0.65625 },\n { x: 0.84375, y: 0.65625 },\n { x: 0.84375, y: 0.65625 },\n { x: 0.90625, y: 0.65625 },\n { x: 0.90625, y: 0.65625 },\n { x: 0.96875, y: 0.65625 },\n { x: 0.96875, y: 0.65625 },\n { x: 0.03125, y: 0.71875 },\n { x: 0.03125, y: 0.71875 },\n { x: 0.09375, y: 0.71875 },\n { x: 0.09375, y: 0.71875 },\n { x: 0.15625, y: 0.71875 },\n { x: 0.15625, y: 0.71875 },\n { x: 0.21875, y: 0.71875 },\n { x: 0.21875, y: 0.71875 },\n { x: 0.28125, y: 0.71875 },\n { x: 0.28125, y: 0.71875 },\n { x: 0.34375, y: 0.71875 },\n { x: 0.34375, y: 0.71875 },\n { x: 0.40625, y: 0.71875 },\n { x: 0.40625, y: 0.71875 },\n { x: 0.46875, y: 0.71875 },\n { x: 0.46875, y: 0.71875 },\n { x: 0.53125, y: 0.71875 },\n { x: 0.53125, y: 0.71875 },\n { x: 0.59375, y: 0.71875 },\n { x: 0.59375, y: 0.71875 },\n { x: 0.65625, y: 0.71875 },\n { x: 0.65625, y: 0.71875 },\n { x: 0.71875, y: 0.71875 },\n { x: 0.71875, y: 0.71875 },\n { x: 0.78125, y: 0.71875 },\n { x: 0.78125, y: 0.71875 },\n { x: 0.84375, y: 0.71875 },\n { x: 0.84375, y: 0.71875 },\n { x: 0.90625, y: 0.71875 },\n { x: 0.90625, y: 0.71875 },\n { x: 0.96875, y: 0.71875 },\n { x: 0.96875, y: 0.71875 },\n { x: 0.03125, y: 0.78125 },\n { x: 0.03125, y: 0.78125 },\n { x: 0.09375, y: 0.78125 },\n { x: 0.09375, y: 0.78125 },\n { x: 0.15625, y: 0.78125 },\n { x: 0.15625, y: 0.78125 },\n { x: 0.21875, y: 0.78125 },\n { x: 0.21875, y: 0.78125 },\n { x: 0.28125, y: 0.78125 },\n { x: 0.28125, y: 0.78125 },\n { x: 0.34375, y: 0.78125 },\n { x: 0.34375, y: 0.78125 },\n { x: 0.40625, y: 0.78125 },\n { x: 0.40625, y: 0.78125 },\n { x: 0.46875, y: 0.78125 },\n { x: 0.46875, y: 0.78125 },\n { x: 0.53125, y: 0.78125 },\n { x: 0.53125, y: 0.78125 },\n { x: 0.59375, y: 0.78125 },\n { x: 0.59375, y: 0.78125 },\n { x: 0.65625, y: 0.78125 },\n { x: 0.65625, y: 0.78125 },\n { x: 0.71875, y: 0.78125 },\n { x: 0.71875, y: 0.78125 },\n { x: 0.78125, y: 0.78125 },\n { x: 0.78125, y: 0.78125 },\n { x: 0.84375, y: 0.78125 },\n { x: 0.84375, y: 0.78125 },\n { x: 0.90625, y: 0.78125 },\n { x: 0.90625, y: 0.78125 },\n { x: 0.96875, y: 0.78125 },\n { x: 0.96875, y: 0.78125 },\n { x: 0.03125, y: 0.84375 },\n { x: 0.03125, y: 0.84375 },\n { x: 0.09375, y: 0.84375 },\n { x: 0.09375, y: 0.84375 },\n { x: 0.15625, y: 0.84375 },\n { x: 0.15625, y: 0.84375 },\n { x: 0.21875, y: 0.84375 },\n { x: 0.21875, y: 0.84375 },\n { x: 0.28125, y: 0.84375 },\n { x: 0.28125, y: 0.84375 },\n { x: 0.34375, y: 0.84375 },\n { x: 0.34375, y: 0.84375 },\n { x: 0.40625, y: 0.84375 },\n { x: 0.40625, y: 0.84375 },\n { x: 0.46875, y: 0.84375 },\n { x: 0.46875, y: 0.84375 },\n { x: 0.53125, y: 0.84375 },\n { x: 0.53125, y: 0.84375 },\n { x: 0.59375, y: 0.84375 },\n { x: 0.59375, y: 0.84375 },\n { x: 0.65625, y: 0.84375 },\n { x: 0.65625, y: 0.84375 },\n { x: 0.71875, y: 0.84375 },\n { x: 0.71875, y: 0.84375 },\n { x: 0.78125, y: 0.84375 },\n { x: 0.78125, y: 0.84375 },\n { x: 0.84375, y: 0.84375 },\n { x: 0.84375, y: 0.84375 },\n { x: 0.90625, y: 0.84375 },\n { x: 0.90625, y: 0.84375 },\n { x: 0.96875, y: 0.84375 },\n { x: 0.96875, y: 0.84375 },\n { x: 0.03125, y: 0.90625 },\n { x: 0.03125, y: 0.90625 },\n { x: 0.09375, y: 0.90625 },\n { x: 0.09375, y: 0.90625 },\n { x: 0.15625, y: 0.90625 },\n { x: 0.15625, y: 0.90625 },\n { x: 0.21875, y: 0.90625 },\n { x: 0.21875, y: 0.90625 },\n { x: 0.28125, y: 0.90625 },\n { x: 0.28125, y: 0.90625 },\n { x: 0.34375, y: 0.90625 },\n { x: 0.34375, y: 0.90625 },\n { x: 0.40625, y: 0.90625 },\n { x: 0.40625, y: 0.90625 },\n { x: 0.46875, y: 0.90625 },\n { x: 0.46875, y: 0.90625 },\n { x: 0.53125, y: 0.90625 },\n { x: 0.53125, y: 0.90625 },\n { x: 0.59375, y: 0.90625 },\n { x: 0.59375, y: 0.90625 },\n { x: 0.65625, y: 0.90625 },\n { x: 0.65625, y: 0.90625 },\n { x: 0.71875, y: 0.90625 },\n { x: 0.71875, y: 0.90625 },\n { x: 0.78125, y: 0.90625 },\n { x: 0.78125, y: 0.90625 },\n { x: 0.84375, y: 0.90625 },\n { x: 0.84375, y: 0.90625 },\n { x: 0.90625, y: 0.90625 },\n { x: 0.90625, y: 0.90625 },\n { x: 0.96875, y: 0.90625 },\n { x: 0.96875, y: 0.90625 },\n { x: 0.03125, y: 0.96875 },\n { x: 0.03125, y: 0.96875 },\n { x: 0.09375, y: 0.96875 },\n { x: 0.09375, y: 0.96875 },\n { x: 0.15625, y: 0.96875 },\n { x: 0.15625, y: 0.96875 },\n { x: 0.21875, y: 0.96875 },\n { x: 0.21875, y: 0.96875 },\n { x: 0.28125, y: 0.96875 },\n { x: 0.28125, y: 0.96875 },\n { x: 0.34375, y: 0.96875 },\n { x: 0.34375, y: 0.96875 },\n { x: 0.40625, y: 0.96875 },\n { x: 0.40625, y: 0.96875 },\n { x: 0.46875, y: 0.96875 },\n { x: 0.46875, y: 0.96875 },\n { x: 0.53125, y: 0.96875 },\n { x: 0.53125, y: 0.96875 },\n { x: 0.59375, y: 0.96875 },\n { x: 0.59375, y: 0.96875 },\n { x: 0.65625, y: 0.96875 },\n { x: 0.65625, y: 0.96875 },\n { x: 0.71875, y: 0.96875 },\n { x: 0.71875, y: 0.96875 },\n { x: 0.78125, y: 0.96875 },\n { x: 0.78125, y: 0.96875 },\n { x: 0.84375, y: 0.96875 },\n { x: 0.84375, y: 0.96875 },\n { x: 0.90625, y: 0.96875 },\n { x: 0.90625, y: 0.96875 },\n { x: 0.96875, y: 0.96875 },\n { x: 0.96875, y: 0.96875 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.0625, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.1875, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.3125, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.4375, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.5625, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.6875, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.8125, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.9375, y: 0.0625 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.0625, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.1875, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.3125, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.4375, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.5625, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.6875, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.8125, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.9375, y: 0.1875 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.0625, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.1875, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.3125, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.4375, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.5625, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.6875, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.8125, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.9375, y: 0.3125 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.0625, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.1875, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.3125, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.4375, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.5625, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.6875, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.8125, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.9375, y: 0.4375 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.0625, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.1875, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.3125, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.4375, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.5625, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.6875, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.8125, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.9375, y: 0.5625 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.0625, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.1875, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.3125, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.4375, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.5625, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.6875, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.8125, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.9375, y: 0.6875 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.0625, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.1875, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.3125, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.4375, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.5625, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.6875, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.8125, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.9375, y: 0.8125 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.0625, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.1875, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.3125, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.4375, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.5625, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.6875, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.8125, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n { x: 0.9375, y: 0.9375 },\n];\n", "/**\n * HandPose model implementation\n * See `handpose.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as util from './handposeutil';\nimport * as anchors from './handposeanchors';\nimport { constants } from '../tfjs/constants';\nimport type { Tensor, Tensor1D, Tensor2D, Tensor4D, GraphModel } from '../tfjs/types';\nimport type { Point } from '../result';\nimport type { Config } from '../config';\n\nexport class HandDetector {\n model: GraphModel;\n anchors: number[][];\n anchorsTensor: Tensor;\n inputSize: number;\n inputSizeTensor: Tensor;\n doubleInputSizeTensor: Tensor;\n\n constructor(model: GraphModel) {\n this.model = model;\n this.anchors = anchors.anchors.map((anchor) => [anchor.x, anchor.y]);\n this.anchorsTensor = tf.tensor2d(this.anchors);\n this.inputSize = this?.model?.inputs?.[0]?.shape?.[2] || 0;\n this.inputSizeTensor = tf.tensor1d([this.inputSize, this.inputSize]);\n this.doubleInputSizeTensor = tf.tensor1d([this.inputSize * 2, this.inputSize * 2]);\n }\n\n normalizeBoxes(boxes) {\n const t: Record = {};\n t.boxOffsets = tf.slice(boxes, [0, 0], [-1, 2]);\n t.boxSizes = tf.slice(boxes, [0, 2], [-1, 2]);\n t.div = tf.div(t.boxOffsets, this.inputSizeTensor);\n t.boxCenterPoints = tf.add(t.div, this.anchorsTensor);\n t.halfBoxSizes = tf.div(t.boxSizes, this.doubleInputSizeTensor);\n t.sub = tf.sub(t.boxCenterPoints, t.halfBoxSizes);\n t.startPoints = tf.mul(t.sub, this.inputSizeTensor);\n t.add = tf.add(t.boxCenterPoints, t.halfBoxSizes);\n t.endPoints = tf.mul(t.add, this.inputSizeTensor);\n const res = tf.concat2d([t.startPoints as Tensor2D, t.endPoints as Tensor2D], 1);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return res as Tensor;\n }\n\n normalizeLandmarks(rawPalmLandmarks, index: number): Tensor {\n const t: Record = {};\n t.reshape = tf.reshape(rawPalmLandmarks, [-1, 7, 2]);\n t.div = tf.div(t.reshape, this.inputSizeTensor);\n t.landmarks = tf.add(t.div, this.anchors[index] ? this.anchors[index] : 0);\n const res = tf.mul(t.landmarks, this.inputSizeTensor);\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return res;\n }\n\n async predict(input: Tensor4D, config: Config): Promise<{ startPoint: Point; endPoint: Point, palmLandmarks: Point[]; confidence: number }[]> {\n const t: Record = {};\n t.resize = tf.image.resizeBilinear(input, [this.inputSize, this.inputSize]);\n t.div = tf.div(t.resize, constants.tf127);\n t.image = tf.sub(t.div, constants.tf1);\n t.batched = this.model.execute(t.image) as Tensor;\n t.predictions = tf.squeeze(t.batched);\n t.slice = tf.slice(t.predictions, [0, 0], [-1, 1]);\n t.sigmoid = tf.sigmoid(t.slice);\n t.scores = tf.squeeze(t.sigmoid);\n const scores = await t.scores.data();\n t.boxes = tf.slice(t.predictions, [0, 1], [-1, 4]);\n t.norm = this.normalizeBoxes(t.boxes);\n // box detection is flaky so we look for 3x boxes than we need results\n t.nms = await tf.image.nonMaxSuppressionAsync(t.norm as Tensor2D, t.scores as Tensor1D, 3 * (config.hand?.maxDetected || 1), config.hand.iouThreshold, config.hand.minConfidence);\n const nms = await t.nms.array() as number[];\n const hands: { startPoint: Point; endPoint: Point; palmLandmarks: Point[]; confidence: number }[] = [];\n for (const index of nms) {\n const p: Record = {};\n p.box = tf.slice(t.norm, [index, 0], [1, -1]);\n p.slice = tf.slice(t.predictions, [index, 5], [1, 14]);\n p.norm = this.normalizeLandmarks(p.slice, index);\n p.palmLandmarks = tf.reshape(p.norm, [-1, 2]);\n const box = await p.box.data();\n const startPoint = box.slice(0, 2) as unknown as Point;\n const endPoint = box.slice(2, 4) as unknown as Point;\n const palmLandmarks = await p.palmLandmarks.array();\n const hand = { startPoint, endPoint, palmLandmarks, confidence: scores[index] };\n const scaled = util.scaleBoxCoordinates(hand, [(input.shape[2] || 1) / this.inputSize, (input.shape[1] || 0) / this.inputSize]);\n hands.push(scaled);\n Object.keys(p).forEach((tensor) => tf.dispose(p[tensor]));\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return hands;\n }\n}\n", "/**\n * HandPose model implementation\n * See `handpose.ts` for entry point\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport * as util from './handposeutil';\nimport type * as detector from './handposedetector';\nimport { constants } from '../tfjs/constants';\nimport type { Tensor, GraphModel } from '../tfjs/types';\nimport { env } from '../util/env';\nimport { now } from '../util/util';\nimport type { Point } from '../result';\n\nconst palmBoxEnlargeFactor = 5; // default 3\nconst handBoxEnlargeFactor = 1.65; // default 1.65\nconst palmLandmarkIds = [0, 5, 9, 13, 17, 1, 2];\nconst palmLandmarksPalmBase = 0;\nconst palmLandmarksMiddleFingerBase = 2;\nlet lastTime = 0;\n\nexport class HandPipeline {\n handDetector: detector.HandDetector;\n handPoseModel: GraphModel;\n inputSize: number;\n storedBoxes: ({ startPoint: Point; endPoint: Point; palmLandmarks: Point[]; confidence: number } | null)[];\n skipped: number;\n detectedHands: number;\n\n constructor(handDetector, handPoseModel) {\n this.handDetector = handDetector;\n this.handPoseModel = handPoseModel;\n this.inputSize = this.handPoseModel?.inputs?.[0].shape?.[2] || 0;\n this.storedBoxes = [];\n this.skipped = Number.MAX_SAFE_INTEGER;\n this.detectedHands = 0;\n }\n\n calculateLandmarksBoundingBox(landmarks) { // eslint-disable-line class-methods-use-this\n const xs = landmarks.map((d) => d[0]);\n const ys = landmarks.map((d) => d[1]);\n const startPoint = [Math.min(...xs), Math.min(...ys)];\n const endPoint = [Math.max(...xs), Math.max(...ys)];\n return { startPoint, endPoint };\n }\n\n getBoxForPalmLandmarks(palmLandmarks, rotationMatrix) {\n const rotatedPalmLandmarks = palmLandmarks.map((coord) => util.rotatePoint([...coord, 1], rotationMatrix));\n const boxAroundPalm = this.calculateLandmarksBoundingBox(rotatedPalmLandmarks);\n return util.enlargeBox(util.squarifyBox(boxAroundPalm), palmBoxEnlargeFactor);\n }\n\n getBoxForHandLandmarks(landmarks) {\n const boundingBox = this.calculateLandmarksBoundingBox(landmarks);\n const boxAroundHand = util.enlargeBox(util.squarifyBox(boundingBox), handBoxEnlargeFactor);\n boxAroundHand.palmLandmarks = [];\n for (let i = 0; i < palmLandmarkIds.length; i++) {\n boxAroundHand.palmLandmarks.push(landmarks[palmLandmarkIds[i]].slice(0, 2));\n }\n return boxAroundHand;\n }\n\n transformRawCoords(rawCoords, box2, angle, rotationMatrix) {\n const boxSize = util.getBoxSize(box2);\n const scaleFactor = [boxSize[0] / this.inputSize, boxSize[1] / this.inputSize, (boxSize[0] + boxSize[1]) / this.inputSize / 2];\n const coordsScaled = rawCoords.map((coord) => [\n scaleFactor[0] * (coord[0] - this.inputSize / 2),\n scaleFactor[1] * (coord[1] - this.inputSize / 2),\n scaleFactor[2] * coord[2],\n ]);\n const coordsRotationMatrix = util.buildRotationMatrix(angle, [0, 0]);\n const coordsRotated = coordsScaled.map((coord) => {\n const rotated = util.rotatePoint(coord, coordsRotationMatrix);\n return [...rotated, coord[2]];\n });\n const inverseRotationMatrix = util.invertTransformMatrix(rotationMatrix);\n const boxCenter = [...util.getBoxCenter(box2), 1];\n const originalBoxCenter = [\n util.dot(boxCenter, inverseRotationMatrix[0]),\n util.dot(boxCenter, inverseRotationMatrix[1]),\n ];\n return coordsRotated.map((coord) => [\n Math.trunc(coord[0] + originalBoxCenter[0]),\n Math.trunc(coord[1] + originalBoxCenter[1]),\n Math.trunc(coord[2]),\n ]);\n }\n\n async estimateHands(image, config) {\n let useFreshBox = false;\n\n // run new detector every skipFrames\n let boxes;\n const skipTime = (config.hand.skipTime || 0) > (now() - lastTime);\n const skipFrame = this.skipped < (config.hand.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame) {\n this.skipped++;\n } else {\n boxes = await this.handDetector.predict(image, config);\n this.skipped = 0;\n }\n\n // if detector result count doesn't match current working set, use it to reset current working set\n if (boxes && (boxes.length > 0) && ((boxes.length !== this.detectedHands) && (this.detectedHands !== config.hand.maxDetected) || !config.hand.landmarks)) {\n this.detectedHands = 0;\n this.storedBoxes = [...boxes];\n // for (const possible of boxes) this.storedBoxes.push(possible);\n if (this.storedBoxes.length > 0) useFreshBox = true;\n }\n const hands: { landmarks: Point[], confidence: number, boxConfidence: number, fingerConfidence: number, box: { topLeft: Point, bottomRight: Point } }[] = [];\n\n // go through working set of boxes\n for (let i = 0; i < this.storedBoxes.length; i++) {\n const currentBox = this.storedBoxes[i];\n if (!currentBox) continue;\n if (config.hand.landmarks) {\n const angle = config.hand.rotation ? util.computeRotation(currentBox.palmLandmarks[palmLandmarksPalmBase], currentBox.palmLandmarks[palmLandmarksMiddleFingerBase]) : 0;\n const palmCenter = util.getBoxCenter(currentBox);\n const palmCenterNormalized: [number, number] = [palmCenter[0] / image.shape[2], palmCenter[1] / image.shape[1]];\n const rotatedImage = config.hand.rotation && env.kernels.includes('rotatewithoffset') ? tf.image.rotateWithOffset(image, angle, 0, palmCenterNormalized) : image.clone();\n const rotationMatrix = util.buildRotationMatrix(-angle, palmCenter);\n const newBox = useFreshBox ? this.getBoxForPalmLandmarks(currentBox.palmLandmarks, rotationMatrix) : currentBox;\n const croppedInput = util.cutBoxFromImageAndResize(newBox, rotatedImage, [this.inputSize, this.inputSize]);\n const handImage = tf.div(croppedInput, constants.tf255);\n tf.dispose(croppedInput);\n tf.dispose(rotatedImage);\n const [confidenceT, keypoints] = this.handPoseModel.execute(handImage) as Tensor[];\n lastTime = now();\n tf.dispose(handImage);\n const confidence = (await confidenceT.data())[0];\n tf.dispose(confidenceT);\n if (confidence >= config.hand.minConfidence / 4) {\n const keypointsReshaped = tf.reshape(keypoints, [-1, 3]);\n const rawCoords = await keypointsReshaped.array();\n tf.dispose(keypoints);\n tf.dispose(keypointsReshaped);\n const coords = this.transformRawCoords(rawCoords, newBox, angle, rotationMatrix);\n const nextBoundingBox = this.getBoxForHandLandmarks(coords);\n this.storedBoxes[i] = { ...nextBoundingBox, confidence };\n const result = {\n landmarks: coords,\n confidence,\n boxConfidence: currentBox.confidence,\n fingerConfidence: confidence,\n box: { topLeft: nextBoundingBox.startPoint, bottomRight: nextBoundingBox.endPoint },\n };\n hands.push(result);\n } else {\n this.storedBoxes[i] = null;\n }\n tf.dispose(keypoints);\n } else {\n // const enlarged = box.enlargeBox(box.squarifyBox(box.shiftBox(currentBox, HAND_BOX_SHIFT_VECTOR)), handBoxEnlargeFactor);\n const enlarged = util.enlargeBox(util.squarifyBox(currentBox), handBoxEnlargeFactor);\n const result = {\n confidence: currentBox.confidence,\n boxConfidence: currentBox.confidence,\n fingerConfidence: 0,\n box: { topLeft: enlarged.startPoint, bottomRight: enlarged.endPoint },\n landmarks: [],\n };\n hands.push(result);\n }\n }\n this.storedBoxes = this.storedBoxes.filter((a) => a !== null);\n this.detectedHands = hands.length;\n if (hands.length > config.hand.maxDetected) hands.length = config.hand.maxDetected;\n return hands;\n }\n}\n", "/**\n * HandPose model implementation\n *\n * Based on: [**MediaPipe HandPose**](https://drive.google.com/file/d/1sv4sSb9BSNVZhLzxXJ0jBv9DqD-4jnAz/view)\n */\n\nimport { log } from '../util/util';\nimport * as handdetector from './handposedetector';\nimport * as handpipeline from './handposepipeline';\nimport * as fingerPose from './fingerpose';\nimport { loadModel } from '../tfjs/load';\nimport type { HandResult, Box, Point } from '../result';\nimport type { Tensor, GraphModel } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nconst meshAnnotations = {\n thumb: [1, 2, 3, 4],\n index: [5, 6, 7, 8],\n middle: [9, 10, 11, 12],\n ring: [13, 14, 15, 16],\n pinky: [17, 18, 19, 20],\n palm: [0],\n};\n\nlet handDetectorModel: GraphModel | null;\nlet handPoseModel: GraphModel | null;\nlet handPipeline: handpipeline.HandPipeline;\n\nexport function initPipeline() {\n const handDetector = handDetectorModel ? new handdetector.HandDetector(handDetectorModel) : undefined;\n if (handDetector && handPoseModel) handPipeline = new handpipeline.HandPipeline(handDetector, handPoseModel);\n}\n\nexport async function predict(input: Tensor, config: Config): Promise {\n if (!handPipeline) initPipeline();\n const predictions = await handPipeline.estimateHands(input, config);\n if (!predictions) return [];\n const hands: HandResult[] = [];\n for (let i = 0; i < predictions.length; i++) {\n const annotations = {};\n if (predictions[i].landmarks) {\n for (const key of Object.keys(meshAnnotations)) {\n annotations[key] = meshAnnotations[key].map((index) => predictions[i].landmarks[index]);\n }\n }\n const keypoints = predictions[i].landmarks as unknown as Point[];\n let box: Box = [Number.MAX_SAFE_INTEGER, Number.MAX_SAFE_INTEGER, 0, 0]; // maximums so conditionals work\n let boxRaw: Box = [0, 0, 0, 0];\n if (keypoints && keypoints.length > 0) { // if we have landmarks, calculate box based on landmarks\n for (const pt of keypoints) {\n if (pt[0] < box[0]) box[0] = pt[0];\n if (pt[1] < box[1]) box[1] = pt[1];\n if (pt[0] > box[2]) box[2] = pt[0];\n if (pt[1] > box[3]) box[3] = pt[1];\n }\n box[2] -= box[0];\n box[3] -= box[1];\n boxRaw = [box[0] / (input.shape[2] || 0), box[1] / (input.shape[1] || 0), box[2] / (input.shape[2] || 0), box[3] / (input.shape[1] || 0)];\n } else { // otherwise use box from prediction\n box = predictions[i].box ? [\n Math.trunc(Math.max(0, predictions[i].box.topLeft[0])),\n Math.trunc(Math.max(0, predictions[i].box.topLeft[1])),\n Math.trunc(Math.min((input.shape[2] || 0), predictions[i].box.bottomRight[0]) - Math.max(0, predictions[i].box.topLeft[0])),\n Math.trunc(Math.min((input.shape[1] || 0), predictions[i].box.bottomRight[1]) - Math.max(0, predictions[i].box.topLeft[1])),\n ] : [0, 0, 0, 0];\n boxRaw = [\n (predictions[i].box.topLeft[0]) / (input.shape[2] || 0),\n (predictions[i].box.topLeft[1]) / (input.shape[1] || 0),\n (predictions[i].box.bottomRight[0] - predictions[i].box.topLeft[0]) / (input.shape[2] || 0),\n (predictions[i].box.bottomRight[1] - predictions[i].box.topLeft[1]) / (input.shape[1] || 0),\n ];\n }\n const landmarks = fingerPose.analyze(keypoints);\n hands.push({\n id: i,\n score: Math.round(100 * predictions[i].confidence) / 100,\n boxScore: Math.round(100 * predictions[i].boxConfidence) / 100,\n fingerScore: Math.round(100 * predictions[i].fingerConfidence) / 100,\n label: 'hand',\n box,\n boxRaw,\n keypoints,\n annotations: annotations as HandResult['annotations'],\n landmarks: landmarks as HandResult['landmarks'],\n });\n }\n return hands;\n}\n\nexport async function loadDetect(config: Config): Promise {\n if (env.initial) handDetectorModel = null;\n if (!handDetectorModel) handDetectorModel = await loadModel(config.hand.detector?.modelPath);\n else if (config.debug) log('cached model:', handDetectorModel['modelUrl']);\n return handDetectorModel;\n}\n\nexport async function loadSkeleton(config: Config): Promise {\n if (env.initial) handPoseModel = null;\n if (!handPoseModel) handPoseModel = await loadModel(config.hand.skeleton?.modelPath);\n else if (config.debug) log('cached model:', handPoseModel['modelUrl']);\n return handPoseModel;\n}\n", "/**\n * HandTrack model implementation\n *\n * Based on:\n * - Hand Detection & Skeleton: [**MediaPipe HandPose**](https://drive.google.com/file/d/1sv4sSb9BSNVZhLzxXJ0jBv9DqD-4jnAz/view)\n * - Hand Tracking: [**HandTracking**](https://github.com/victordibia/handtracking)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport * as box from '../util/box';\nimport { loadModel } from '../tfjs/load';\nimport type { HandResult, HandType, Box, Point } from '../result';\nimport type { GraphModel, Tensor, Tensor1D, Tensor2D, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\nimport * as fingerPose from './fingerpose';\nimport { fakeOps } from '../tfjs/backend';\nimport { constants } from '../tfjs/constants';\n\nconst models: [GraphModel | null, GraphModel | null] = [null, null];\nconst modelOutputNodes = ['StatefulPartitionedCall/Postprocessor/Slice', 'StatefulPartitionedCall/Postprocessor/ExpandDims_1'];\n\nconst inputSize = [[0, 0], [0, 0]];\n\nconst classes = ['hand', 'fist', 'pinch', 'point', 'face', 'tip', 'pinchtip'];\nconst faceIndex = 4;\n\nconst boxExpandFact = 1.6;\nconst maxDetectorResolution = 512;\nconst detectorExpandFact = 1.4;\n\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet lastTime = 0;\nlet outputSize: [number, number] = [0, 0];\n\ninterface HandDetectResult {\n id: number,\n score: number,\n box: Box,\n boxRaw: Box,\n label: HandType,\n}\n\nconst cache: {\n boxes: HandDetectResult[],\n hands: HandResult[];\n} = {\n boxes: [],\n hands: [],\n};\n\nconst fingerMap = {\n /*\n thumb: [0, 1, 2, 3, 4],\n index: [0, 5, 6, 7, 8],\n middle: [0, 9, 10, 11, 12],\n ring: [0, 13, 14, 15, 16],\n pinky: [0, 17, 18, 19, 20],\n palm: [0],\n */\n thumb: [1, 2, 3, 4],\n index: [5, 6, 7, 8],\n middle: [9, 10, 11, 12],\n ring: [13, 14, 15, 16],\n pinky: [17, 18, 19, 20],\n base: [0],\n palm: [0, 17, 13, 9, 5, 1, 0],\n};\n\nexport async function loadDetect(config: Config): Promise {\n // HandTrack Model: Original: TFJS Port: \n if (env.initial) models[0] = null;\n if (!models[0]) {\n // handtrack model has some kernel ops defined in model but those are never referenced and non-existent in tfjs\n // ideally need to prune the model itself\n fakeOps(['tensorlistreserve', 'enter', 'tensorlistfromtensor', 'merge', 'loopcond', 'switch', 'exit', 'tensorliststack', 'nextiteration', 'tensorlistsetitem', 'tensorlistgetitem', 'reciprocal', 'shape', 'split', 'where'], config);\n models[0] = await loadModel(config.hand.detector?.modelPath);\n const inputs = models[0]['executor'] ? Object.values(models[0].modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[0][0] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[0][1] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 0;\n } else if (config.debug) log('cached model:', models[0]['modelUrl']);\n return models[0];\n}\n\nexport async function loadSkeleton(config: Config): Promise {\n if (env.initial) models[1] = null;\n if (!models[1]) {\n models[1] = await loadModel(config.hand.skeleton?.modelPath);\n const inputs = models[1]['executor'] ? Object.values(models[1].modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[1][0] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[1].size) : 0;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize[1][1] = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 0;\n } else if (config.debug) log('cached model:', models[1]['modelUrl']);\n return models[1];\n}\n\nexport async function load(config: Config): Promise<[GraphModel | null, GraphModel | null]> {\n if (!models[0]) await loadDetect(config);\n if (!models[1]) await loadSkeleton(config);\n return models;\n}\n\nasync function detectHands(input: Tensor4D, config: Config): Promise {\n const hands: HandDetectResult[] = [];\n if (!input || !models[0]) return hands;\n const t: Record = {};\n const ratio = (input.shape[2] || 1) / (input.shape[1] || 1);\n const height = Math.min(Math.round((input.shape[1] || 0) / 8) * 8, maxDetectorResolution); // use dynamic input size but cap at 512\n const width = Math.round(height * ratio / 8) * 8;\n t.resize = tf.image.resizeBilinear(input, [height, width]); // todo: resize with padding\n t.cast = tf.cast(t.resize, 'int32');\n [t.rawScores, t.rawBoxes] = await models[0].executeAsync(t.cast, modelOutputNodes) as Tensor[];\n t.boxes = tf.squeeze(t.rawBoxes, [0, 2]);\n t.scores = tf.squeeze(t.rawScores, [0]);\n const classScores: Tensor[] = tf.unstack(t.scores, 1); // unstack scores based on classes\n tf.dispose(classScores[faceIndex]);\n classScores.splice(faceIndex, 1); // remove faces\n t.filtered = tf.stack(classScores, 1); // restack\n tf.dispose(classScores);\n // t.filtered = t.scores;\n t.max = tf.max(t.filtered, 1); // max overall score\n t.argmax = tf.argMax(t.filtered, 1); // class index of max overall score\n let id = 0;\n t.nms = await tf.image.nonMaxSuppressionAsync(t.boxes as Tensor2D, t.max as Tensor1D, (config.hand.maxDetected || 0) + 1, config.hand.iouThreshold || 0, config.hand.minConfidence || 1);\n const nms = await t.nms.data();\n const scores = await t.max.data();\n const classNum = await t.argmax.data();\n for (const nmsIndex of Array.from(nms)) { // generates results for each class\n const boxSlice = tf.slice(t.boxes, nmsIndex, 1);\n const boxYX = await boxSlice.data();\n tf.dispose(boxSlice);\n const boxData: Box = [boxYX[1], boxYX[0], boxYX[3] - boxYX[1], boxYX[2] - boxYX[0]]; // yx box reshaped to standard box\n const boxRaw: Box = box.scale(boxData, detectorExpandFact);\n const boxFull: Box = [Math.trunc(boxData[0] * outputSize[0]), Math.trunc(boxData[1] * outputSize[1]), Math.trunc(boxData[2] * outputSize[0]), Math.trunc(boxData[3] * outputSize[1])];\n const score = scores[nmsIndex];\n const label = classes[classNum[nmsIndex]] as HandType;\n const hand: HandDetectResult = { id: id++, score, box: boxFull, boxRaw, label };\n hands.push(hand);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n hands.sort((a, b) => b.score - a.score);\n if (hands.length > (config.hand.maxDetected || 1)) hands.length = (config.hand.maxDetected || 1);\n return hands;\n}\n\nasync function detectFingers(input: Tensor4D, h: HandDetectResult, config: Config): Promise {\n const hand: HandResult = { // initial values inherited from hand detect\n id: h.id,\n score: Math.round(100 * h.score) / 100,\n boxScore: Math.round(100 * h.score) / 100,\n fingerScore: 0,\n box: h.box,\n boxRaw: h.boxRaw,\n label: h.label,\n keypoints: [],\n landmarks: {} as HandResult['landmarks'],\n annotations: {} as HandResult['annotations'],\n };\n if (input && models[1] && config.hand.landmarks && h.score > (config.hand.minConfidence || 0)) {\n const t: Record = {};\n const boxCrop = [h.boxRaw[1], h.boxRaw[0], h.boxRaw[3] + h.boxRaw[1], h.boxRaw[2] + h.boxRaw[0]] as Box;\n t.crop = tf.image.cropAndResize(input, [boxCrop], [0], [inputSize[1][0], inputSize[1][1]], 'bilinear');\n t.div = tf.div(t.crop, constants.tf255);\n [t.score, t.keypoints] = models[1].execute(t.div, ['Identity_1', 'Identity']) as Tensor[];\n const rawScore = (await t.score.data())[0];\n const score = (100 - Math.trunc(100 / (1 + Math.exp(rawScore)))) / 100; // reverse sigmoid value\n if (score >= (config.hand.minConfidence || 0)) {\n hand.fingerScore = score;\n t.reshaped = tf.reshape(t.keypoints, [-1, 3]);\n const coordsData: Point[] = await t.reshaped.array() as Point[];\n const coordsRaw: Point[] = coordsData.map((kpt) => [kpt[0] / inputSize[1][1], kpt[1] / inputSize[1][0], (kpt[2] || 0)]);\n const coordsNorm: Point[] = coordsRaw.map((kpt) => [kpt[0] * h.boxRaw[2], kpt[1] * h.boxRaw[3], (kpt[2] || 0)]);\n hand.keypoints = (coordsNorm).map((kpt) => [outputSize[0] * (kpt[0] + h.boxRaw[0]), outputSize[1] * (kpt[1] + h.boxRaw[1]), (kpt[2] || 0)]);\n hand.landmarks = fingerPose.analyze(hand.keypoints) as HandResult['landmarks']; // calculate finger gestures\n for (const key of Object.keys(fingerMap)) { // map keypoints to per-finger annotations\n hand.annotations[key] = fingerMap[key].map((index: number) => (hand.landmarks && hand.keypoints[index] ? hand.keypoints[index] : null));\n }\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n }\n return hand;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!models[0]?.['executor'] || !models[1]?.['executor'] || !models[0].inputs[0].shape || !models[1].inputs[0].shape) return []; // something is wrong with the model\n outputSize = [input.shape[2] || 0, input.shape[1] || 0];\n skipped++; // increment skip frames\n const skipTime = (config.hand.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.hand.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame) {\n return cache.hands; // return cached results without running anything\n }\n return new Promise(async (resolve) => {\n const skipTimeExtended = 3 * (config.hand.skipTime || 0) > (now() - lastTime);\n const skipFrameExtended = skipped < 3 * (config.hand.skipFrames || 0);\n if (config.skipAllowed && cache.hands.length === config.hand.maxDetected) { // we have all detected hands so we're definitely skipping\n cache.hands = await Promise.all(cache.boxes.map((handBox) => detectFingers(input, handBox, config)));\n } else if (config.skipAllowed && skipTimeExtended && skipFrameExtended && cache.hands.length > 0) { // we have some cached results: maybe not enough but anyhow continue for bit longer\n cache.hands = await Promise.all(cache.boxes.map((handBox) => detectFingers(input, handBox, config)));\n } else { // finally rerun detector\n cache.boxes = await detectHands(input, config);\n lastTime = now();\n cache.hands = await Promise.all(cache.boxes.map((handBox) => detectFingers(input, handBox, config)));\n skipped = 0;\n }\n\n const oldCache = [...cache.boxes];\n cache.boxes.length = 0; // reset cache\n if (config.cacheSensitivity > 0) {\n for (let i = 0; i < cache.hands.length; i++) {\n const boxKpt = box.square(cache.hands[i].keypoints, outputSize);\n if (boxKpt.box[2] / (input.shape[2] || 1) > 0.05 && boxKpt.box[3] / (input.shape[1] || 1) > 0.05 && cache.hands[i].fingerScore && cache.hands[i].fingerScore > (config.hand.minConfidence || 0)) {\n const boxScale = box.scale(boxKpt.box, boxExpandFact);\n const boxScaleRaw = box.scale(boxKpt.boxRaw, boxExpandFact);\n // const boxCrop = box.crop(boxScaleRaw);\n cache.boxes.push({ ...oldCache[i], box: boxScale, boxRaw: boxScaleRaw });\n }\n }\n }\n for (let i = 0; i < cache.hands.length; i++) { // replace detected boxes with calculated boxes in final output\n const bbox = box.calc(cache.hands[i].keypoints, outputSize);\n cache.hands[i].box = bbox.box;\n cache.hands[i].boxRaw = bbox.boxRaw;\n }\n resolve(cache.hands);\n });\n}\n", "/**\n * Type definitions for Human result object\n */\n\nimport type { Tensor } from './tfjs/types';\nimport type { FaceGesture, BodyGesture, HandGesture, IrisGesture } from './gesture/gesture';\nimport type { AnyCanvas } from './exports';\n\n/** generic box as [x, y, width, height] */\nexport type Box = [number, number, number, number];\n/** generic point as [x, y, z?] */\nexport type Point = [number, number, number?];\n\nexport type Emotion = 'angry' | 'disgust' | 'fear' | 'happy' | 'sad' | 'surprise' | 'neutral';\nexport type Gender = 'male' | 'female' | 'unknown';\nexport type Race = 'white' | 'black' | 'asian' | 'indian' | 'other';\nexport type FaceLandmark = 'leftEye' | 'rightEye' | 'nose' | 'mouth' | 'leftEar' | 'rightEar' | 'symmetryLine' | 'silhouette'\n | 'lipsUpperOuter' | 'lipsLowerOuter' | 'lipsUpperInner' | 'lipsLowerInner'\n | 'rightEyeUpper0' | 'rightEyeLower0' | 'rightEyeUpper1' | 'rightEyeLower1' | 'rightEyeUpper2' | 'rightEyeLower2' | 'rightEyeLower3' | 'rightEyebrowUpper' | 'rightEyebrowLower' | 'rightEyeIris'\n | 'leftEyeUpper0' | 'leftEyeLower0' | 'leftEyeUpper1' | 'leftEyeLower1' | 'leftEyeUpper2' | 'leftEyeLower2' | 'leftEyeLower3' | 'leftEyebrowUpper' | 'leftEyebrowLower' | 'leftEyeIris'\n | 'midwayBetweenEyes' | 'noseTip' | 'noseBottom' | 'noseRightCorner' | 'noseLeftCorner' | 'rightCheek' | 'leftCheek';\n\n/** Face results\n * - Combined results of face detector, face mesh, age, gender, emotion, embedding, iris models\n * - Some values may be null if specific model is not enabled\n */\nexport interface FaceResult {\n /** face id */\n id: number\n /** overall face score */\n score: number,\n /** detection score */\n boxScore: number,\n /** mesh score */\n faceScore: number,\n /** detected face box */\n box: Box,\n /** detected face box normalized to 0..1 */\n boxRaw: Box,\n /** detected face box size */\n size: [number, number],\n /** detected face mesh */\n mesh: Point[]\n /** detected face mesh normalized to 0..1 */\n meshRaw: Point[],\n /** face contours as array of 2d points normalized to 0..1 */\n // contoursRaw: Array<[number, number]>,\n /** face contours as array of 2d points */\n // contours: Array<[number, number]>,\n /** mesh keypoints combined into annotated results */\n annotations: Record,\n /** detected age */\n age?: number,\n /** detected gender */\n gender?: Gender,\n /** gender detection score */\n genderScore?: number,\n /** detected emotions */\n emotion?: { score: number, emotion: Emotion }[],\n /** detected race */\n race?: { score: number, race: Race }[],\n /** face descriptor */\n embedding?: number[],\n /** face distance from camera */\n distance?: number,\n /** face anti-spoofing result confidence */\n real?: number,\n /** face liveness result confidence */\n live?: number,\n /** face rotation details */\n rotation?: {\n angle: { roll: number, yaw: number, pitch: number },\n matrix: [number, number, number, number, number, number, number, number, number],\n gaze: { bearing: number, strength: number },\n } | null,\n /** detected face as tensor that can be used in further pipelines */\n tensor?: Tensor,\n}\n\nexport type BodyLandmarkPoseNet = 'nose' | 'leftEye' | 'rightEye' | 'leftEar' | 'rightEar' | 'leftShoulder' | 'rightShoulder' | 'leftElbow' | 'rightElbow' | 'leftWrist' | 'rightWrist' | 'leftHip' | 'rightHip' | 'leftKnee' | 'rightKnee' | 'leftAnkle' | 'rightAnkle';\nexport type BodyLandmarkMoveNet = 'nose' | 'leftEye' | 'rightEye' | 'leftEar' | 'rightEar' | 'leftShoulder' | 'rightShoulder' | 'leftElbow' | 'rightElbow' | 'leftWrist' | 'rightWrist' | 'leftHip' | 'rightHip' | 'leftKnee' | 'rightKnee' | 'leftAnkle' | 'rightAnkle';\nexport type BodyLandmarkEfficientNet = 'head' | 'neck' | 'rightShoulder' | 'rightElbow' | 'rightWrist' | 'chest' | 'leftShoulder' | 'leftElbow' | 'leftWrist' | 'bodyCenter' | 'rightHip' | 'rightKnee' | 'rightAnkle' | 'leftHip' | 'leftKnee' | 'leftAnkle';\nexport type BodyLandmarkBlazePose = 'nose' | 'leftEyeInside' | 'leftEye' | 'leftEyeOutside' | 'rightEyeInside' | 'rightEye' | 'rightEyeOutside' | 'leftEar' | 'rightEar' | 'leftMouth' | 'rightMouth' | 'leftShoulder' | 'rightShoulder'\n | 'leftElbow' | 'rightElbow' | 'leftWrist' | 'rightWrist' | 'leftPinky' | 'rightPinky' | 'leftIndex' | 'rightIndex' | 'leftThumb' | 'rightThumb' | 'leftHip' | 'rightHip' | 'leftKnee' | 'rightKnee' | 'leftAnkle' | 'rightAnkle'\n | 'leftHeel' | 'rightHeel' | 'leftFoot' | 'rightFoot' | 'bodyCenter' | 'bodyTop' | 'leftPalm' | 'leftHand' | 'rightPalm' | 'rightHand';\nexport type BodyLandmark = BodyLandmarkPoseNet | BodyLandmarkMoveNet | BodyLandmarkEfficientNet | BodyLandmarkBlazePose;\nexport type BodyAnnotationBlazePose = 'leftLeg' | 'rightLeg' | 'torso' | 'leftArm' | 'rightArm' | 'leftEye' | 'rightEye' | 'mouth';\nexport type BodyAnnotationEfficientPose = 'leftLeg' | 'rightLeg' | 'torso' | 'leftArm' | 'rightArm' | 'head';\nexport type BodyAnnotation = BodyAnnotationBlazePose | BodyAnnotationEfficientPose;\n\n/** Body Result keypoints */\nexport interface BodyKeypoint {\n /** body part name */\n part: BodyLandmark,\n /** body part position */\n position: Point,\n /** body part position normalized to 0..1 */\n positionRaw: Point,\n /** body part position relative to body center in meters */\n distance?: Point,\n /** body part detection score */\n score: number,\n}\n\n/** Body results */\nexport interface BodyResult {\n /** body id */\n id: number,\n /** body detection score */\n score: number,\n /** detected body box */\n box: Box,\n /** detected body box normalized to 0..1 */\n boxRaw: Box,\n /** detected body keypoints */\n keypoints: BodyKeypoint[]\n /** detected body keypoints combined into annotated parts */\n annotations: Record,\n}\n\nexport type HandType = 'hand' | 'fist' | 'pinch' | 'point' | 'face' | 'tip' | 'pinchtip';\nexport type Finger = 'index' | 'middle' | 'pinky' | 'ring' | 'thumb' | 'palm';\nexport type FingerCurl = 'none' | 'half' | 'full';\nexport type FingerDirection = 'verticalUp' | 'verticalDown' | 'horizontalLeft' | 'horizontalRight' | 'diagonalUpRight' | 'diagonalUpLeft' | 'diagonalDownRight' | 'diagonalDownLeft';\n\n/** Hand results */\nexport interface HandResult {\n /** hand id */\n id: number,\n /** hand overal score */\n score: number,\n /** hand detection score */\n boxScore: number,\n /** hand skelton score */\n fingerScore: number,\n /** detected hand box */\n box: Box,\n /** detected hand box normalized to 0..1 */\n boxRaw: Box,\n /** detected hand keypoints */\n keypoints: Point[],\n /** detected hand class */\n label: HandType,\n /** detected hand keypoints combined into annotated parts */\n annotations: Record,\n /** detected hand parts annotated with part gestures */\n landmarks: Record,\n}\n\nexport type ObjectType = 'person' | 'bicycle' | 'car' | 'motorcycle' | 'airplane' | 'bus' | 'train' | 'truck' | 'boat' | 'traffic light' | 'fire hydrant' | 'stop sign' | 'parking meter'\n | 'bench' | 'bird' | 'cat' | 'dog' | 'horse' | 'sheep' | 'cow' | 'elephant' | 'bear' | 'zebra' | 'giraffe' | 'backpack' | 'umbrella' | 'handbag' | 'tie' | 'suitcase' | 'frisbee'\n | 'skis' | 'snowboard' | 'sports ball' | 'kite' | 'baseball bat' | 'baseball glove' | 'skateboard' | 'surfboard' | 'tennis racket' | 'bottle' | 'wine glass' | 'cup' | 'fork'\n | 'knife' | 'spoon' | 'bowl' | 'banana' | 'apple' | 'sandwich' | 'orange' | 'broccoli' | 'carrot' | 'hot dog' | 'pizza' | 'donut' | 'cake' | 'chair' | 'couch' | 'potted plant'\n | 'bed' | 'dining table' | 'toilet' | 'tv' | 'laptop' | 'mouse' | 'remote' | 'keyboard' | 'cell phone' | 'microwave' | 'oven' | 'toaster' | 'sink' | 'refrigerator' | 'book'\n | 'clock' | 'vase' | 'scissors' | 'teddy bear' | 'hair drier' | 'toothbrush';\n\n/** Object results */\nexport interface ObjectResult {\n /** object id */\n id: number,\n /** object detection score */\n score: number,\n /** detected object class id */\n class: number,\n /** detected object class name */\n label: ObjectType,\n /** detected object box */\n box: Box,\n /** detected object box normalized to 0..1 */\n boxRaw: Box,\n}\n\n/** Gesture combined results\n * Each result has:\n * - part: part name and number where gesture was detected: `face`, `iris`, `body`, `hand`\n * - gesture: gesture detected\n */\nexport type GestureResult =\n { 'face': number, gesture: FaceGesture }\n | { 'iris': number, gesture: IrisGesture }\n | { 'body': number, gesture: BodyGesture }\n | { 'hand': number, gesture: HandGesture }\n\n/** Person getter\n* - Triggers combining all individual results into a virtual person object\n*/\nexport interface PersonResult {\n /** person id */\n id: number,\n /** face result that belongs to this person */\n face: FaceResult,\n /** body result that belongs to this person */\n body: BodyResult | null,\n /** left and right hand results that belong to this person */\n hands: { left: HandResult | null, right: HandResult | null },\n /** detected gestures specific to this person */\n gestures: GestureResult[],\n /** box that defines the person */\n box: Box,\n /** box that defines the person normalized to 0..1 */\n boxRaw?: Box,\n}\n\n/**\n * Result interface definition for **Human** library\n *\n * Contains all possible detection results\n */\nexport interface Result {\n /** {@link FaceResult}: detection & analysis results */\n face: FaceResult[],\n /** {@link BodyResult}: detection & analysis results */\n body: BodyResult[],\n /** {@link HandResult}: detection & analysis results */\n hand: HandResult[],\n /** {@link GestureResult}: detection & analysis results */\n gesture: GestureResult[],\n /** {@link ObjectResult}: detection & analysis results */\n object: ObjectResult[]\n /** global performance object with timing values for each operation */\n performance: Record,\n /** optional processed canvas that can be used to draw input on screen */\n canvas?: AnyCanvas | null,\n /** timestamp of detection representing the milliseconds elapsed since the UNIX epoch */\n readonly timestamp: number,\n /** getter property that returns unified persons object */\n persons: PersonResult[],\n /** Last known error message */\n error: string | null;\n /** Resolution width */\n width: number,\n /** Resolution height */\n height: number,\n}\n\nexport const empty = (error: string | null = null): Result => ({ face: [], body: [], hand: [], gesture: [], object: [], persons: [], performance: {}, timestamp: 0, width: 0, height: 0, error });\n", "export const kpt: string[] = [ // used to create part labels\n 'nose',\n 'leftEye',\n 'rightEye',\n 'leftEar',\n 'rightEar',\n 'leftShoulder',\n 'rightShoulder',\n 'leftElbow',\n 'rightElbow',\n 'leftWrist',\n 'rightWrist',\n 'leftHip',\n 'rightHip',\n 'leftKnee',\n 'rightKnee',\n 'leftAnkle',\n 'rightAnkle',\n];\n\nexport const horizontal: string[][] = [ // used to fix left vs right\n ['leftEye', 'rightEye'],\n ['leftEar', 'rightEar'],\n ['leftShoulder', 'rightShoulder'],\n ['leftElbow', 'rightElbow'],\n ['leftWrist', 'rightWrist'],\n ['leftHip', 'rightHip'],\n ['leftKnee', 'rightKnee'],\n ['leftAnkle', 'rightAnkle'],\n];\n\nexport const vertical: string[][] = [ // used to remove unlikely keypoint positions\n ['leftKnee', 'leftShoulder'],\n ['rightKnee', 'rightShoulder'],\n ['leftAnkle', 'leftKnee'],\n ['rightAnkle', 'rightKnee'],\n];\n\nexport const relative: string[][][] = [ // used to match relative body parts\n [['leftHip', 'rightHip'], ['leftShoulder', 'rightShoulder']],\n [['leftElbow', 'rightElbow'], ['leftShoulder', 'rightShoulder']],\n];\n\nexport const connected: Record = { // used to create body outline in annotations\n leftLeg: ['leftHip', 'leftKnee', 'leftAnkle'],\n rightLeg: ['rightHip', 'rightKnee', 'rightAnkle'],\n torso: ['leftShoulder', 'rightShoulder', 'rightHip', 'leftHip', 'leftShoulder'],\n leftArm: ['leftShoulder', 'leftElbow', 'leftWrist'],\n rightArm: ['rightShoulder', 'rightElbow', 'rightWrist'],\n head: [],\n};\n", "/**\n * Results interpolation for smoothening of video detection results inbetween detected frames\n */\n\nimport { Result, FaceResult, BodyResult, HandResult, ObjectResult, PersonResult, Box, Point, BodyLandmark, BodyAnnotation, empty, FaceLandmark } from '../result';\nimport type { Config } from '../config';\n\nimport * as moveNetCoords from '../body/movenetcoords';\nimport * as blazePoseCoords from '../body/blazeposecoords';\nimport * as efficientPoseCoords from '../body/efficientposecoords';\nimport { now } from './util';\nimport { env } from './env';\n\nconst bufferedResult: Result = empty();\nlet interpolateTime = 0;\n\nexport function calc(newResult: Result, config: Config): Result {\n const t0 = now();\n if (!newResult) return empty();\n // each record is only updated using deep clone when number of detected record changes, otherwise it will converge by itself\n // otherwise bufferedResult is a shallow clone of result plus updated local calculated values\n // thus mixing by-reference and by-value assignments to minimize memory operations\n\n const elapsed = Date.now() - newResult.timestamp;\n\n /* curve fitted: buffer = 8 - ln(delay)\n interpolation formula: current = ((buffer - 1) * previous + live) / buffer\n - at 50ms delay buffer = ~4.1 => 28% towards live data\n - at 250ms delay buffer = ~2.5 => 40% towards live data\n - at 500ms delay buffer = ~1.8 => 55% towards live data\n - at 750ms delay buffer = ~1.4 => 71% towards live data\n - at 1sec delay buffer = 1 which means live data is used\n */\n const bufferedFactor = elapsed < 1000 ? 8 - Math.log(elapsed + 1) : 1;\n\n if (newResult.canvas) bufferedResult.canvas = newResult.canvas;\n if (newResult.error) bufferedResult.error = newResult.error;\n\n // interpolate body results\n if (!bufferedResult.body || (newResult.body.length !== bufferedResult.body.length)) {\n bufferedResult.body = JSON.parse(JSON.stringify(newResult.body)) as BodyResult[]; // deep clone once\n } else {\n for (let i = 0; i < newResult.body.length; i++) {\n const box = newResult.body[i].box // update box\n .map((newBoxCoord, j) => ((bufferedFactor - 1) * bufferedResult.body[i].box[j] + newBoxCoord) / bufferedFactor) as Box;\n const boxRaw = newResult.body[i].boxRaw // update boxRaw\n .map((newBoxCoord, j) => ((bufferedFactor - 1) * bufferedResult.body[i].boxRaw[j] + newBoxCoord) / bufferedFactor) as Box;\n const keypoints = (newResult.body[i].keypoints // update keypoints\n .map((newKpt, j) => ({\n score: newKpt.score,\n part: newKpt.part,\n position: [\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].position[0] || 0) + (newKpt.position[0] || 0)) / bufferedFactor : newKpt.position[0],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].position[1] || 0) + (newKpt.position[1] || 0)) / bufferedFactor : newKpt.position[1],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].position[2] || 0) + (newKpt.position[2] || 0)) / bufferedFactor : newKpt.position[2],\n ],\n positionRaw: [\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].positionRaw[0] || 0) + (newKpt.positionRaw[0] || 0)) / bufferedFactor : newKpt.positionRaw[0],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].positionRaw[1] || 0) + (newKpt.positionRaw[1] || 0)) / bufferedFactor : newKpt.positionRaw[1],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].positionRaw[2] || 0) + (newKpt.positionRaw[2] || 0)) / bufferedFactor : newKpt.positionRaw[2],\n ],\n distance: [\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].distance?.[0] || 0) + (newKpt.distance?.[0] || 0)) / bufferedFactor : newKpt.distance?.[0],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].distance?.[1] || 0) + (newKpt.distance?.[1] || 0)) / bufferedFactor : newKpt.distance?.[1],\n bufferedResult.body[i].keypoints[j] ? ((bufferedFactor - 1) * (bufferedResult.body[i].keypoints[j].distance?.[2] || 0) + (newKpt.distance?.[2] || 0)) / bufferedFactor : newKpt.distance?.[2],\n ],\n }))) as { score: number, part: BodyLandmark, position: [number, number, number?], positionRaw: [number, number, number?] }[];\n\n const annotations: Record = {} as Record; // recreate annotations\n let coords = { connected: {} };\n if (config.body.modelPath?.includes('efficientpose')) coords = efficientPoseCoords;\n else if (config.body.modelPath?.includes('blazepose')) coords = blazePoseCoords;\n else if (config.body.modelPath?.includes('movenet')) coords = moveNetCoords;\n for (const [name, indexes] of Object.entries(coords.connected as Record)) {\n const pt: Point[][] = [];\n for (let j = 0; j < indexes.length - 1; j++) {\n const pt0 = keypoints.find((kp) => kp.part === indexes[j]);\n const pt1 = keypoints.find((kp) => kp.part === indexes[j + 1]);\n // if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n if (pt0 && pt1) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n bufferedResult.body[i] = { ...newResult.body[i], box, boxRaw, keypoints, annotations }; // shallow clone plus updated values\n }\n }\n\n // interpolate hand results\n if (!bufferedResult.hand || (newResult.hand.length !== bufferedResult.hand.length)) {\n bufferedResult.hand = JSON.parse(JSON.stringify(newResult.hand)); // deep clone once\n } else {\n for (let i = 0; i < newResult.hand.length; i++) {\n const box = (newResult.hand[i].box// update box\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.hand[i].box[j] + b) / bufferedFactor)) as Box;\n const boxRaw = (newResult.hand[i].boxRaw // update boxRaw\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.hand[i].boxRaw[j] + b) / bufferedFactor)) as Box;\n if (bufferedResult.hand[i].keypoints.length !== newResult.hand[i].keypoints.length) bufferedResult.hand[i].keypoints = newResult.hand[i].keypoints; // reset keypoints as previous frame did not have them\n const keypoints = newResult.hand[i].keypoints && newResult.hand[i].keypoints.length > 0 ? newResult.hand[i].keypoints // update landmarks\n .map((landmark, j) => landmark\n .map((coord, k) => (((bufferedFactor - 1) * (bufferedResult.hand[i].keypoints[j][k] || 1) + (coord || 0)) / bufferedFactor)) as Point)\n : [];\n let annotations = {};\n if (Object.keys(bufferedResult.hand[i].annotations).length !== Object.keys(newResult.hand[i].annotations).length) {\n bufferedResult.hand[i].annotations = newResult.hand[i].annotations; // reset annotations as previous frame did not have them\n annotations = bufferedResult.hand[i].annotations;\n } else if (newResult.hand[i].annotations) {\n for (const key of Object.keys(newResult.hand[i].annotations)) { // update annotations\n annotations[key] = newResult.hand[i]?.annotations?.[key]?.[0]\n ? newResult.hand[i].annotations[key]\n .map((val, j: number) => val\n .map((coord: number, k: number) => ((bufferedFactor - 1) * bufferedResult.hand[i].annotations[key][j][k] + coord) / bufferedFactor))\n : null;\n }\n }\n bufferedResult.hand[i] = { ...newResult.hand[i], box, boxRaw, keypoints, annotations: annotations as HandResult['annotations'] }; // shallow clone plus updated values\n }\n }\n\n // interpolate face results\n if (!bufferedResult.face || (newResult.face.length !== bufferedResult.face.length)) {\n bufferedResult.face = JSON.parse(JSON.stringify(newResult.face)) as FaceResult[]; // deep clone once\n } else {\n for (let i = 0; i < newResult.face.length; i++) {\n const box = (newResult.face[i].box // update box\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.face[i].box[j] + b) / bufferedFactor)) as Box;\n const boxRaw = (newResult.face[i].boxRaw // update boxRaw\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.face[i].boxRaw[j] + b) / bufferedFactor)) as Box;\n let annotations: Record = newResult.face[i].annotations;\n if (Object.keys(bufferedResult.face[i].annotations).length !== Object.keys(newResult.face[i].annotations).length) {\n bufferedResult.face[i].annotations = newResult.face[i].annotations; // reset annotations as previous frame did not have them\n annotations = bufferedResult.face[i].annotations;\n } else if (newResult.face[i].annotations) {\n for (const key of Object.keys(newResult.face[i].annotations)) { // update annotations\n annotations[key] = newResult.face[i]?.annotations?.[key]?.[0]\n ? newResult.face[i].annotations[key]\n .map((val, j: number) => val\n .map((coord: number, k: number) => ((bufferedFactor - 1) * bufferedResult.face[i].annotations[key][j][k] + coord) / bufferedFactor))\n : null;\n }\n }\n if (newResult.face[i].rotation) {\n const rotation: {\n matrix: [number, number, number, number, number, number, number, number, number],\n angle: { roll: number, yaw: number, pitch: number },\n gaze: { bearing: number, strength: number }\n } = { matrix: [0, 0, 0, 0, 0, 0, 0, 0, 0], angle: { roll: 0, yaw: 0, pitch: 0 }, gaze: { bearing: 0, strength: 0 } };\n rotation.matrix = newResult.face[i].rotation?.matrix as [number, number, number, number, number, number, number, number, number];\n rotation.angle = {\n roll: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.angle?.roll || 0) + (newResult.face[i].rotation?.angle?.roll || 0)) / bufferedFactor,\n yaw: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.angle?.yaw || 0) + (newResult.face[i].rotation?.angle?.yaw || 0)) / bufferedFactor,\n pitch: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.angle?.pitch || 0) + (newResult.face[i].rotation?.angle?.pitch || 0)) / bufferedFactor,\n };\n rotation.gaze = {\n // not fully correct due projection on circle, also causes wrap-around draw on jump from negative to positive\n bearing: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.gaze.bearing || 0) + (newResult.face[i].rotation?.gaze.bearing || 0)) / bufferedFactor,\n strength: ((bufferedFactor - 1) * (bufferedResult.face[i].rotation?.gaze.strength || 0) + (newResult.face[i].rotation?.gaze.strength || 0)) / bufferedFactor,\n };\n bufferedResult.face[i] = { ...newResult.face[i], rotation, box, boxRaw, annotations }; // shallow clone plus updated values\n } else {\n bufferedResult.face[i] = { ...newResult.face[i], box, boxRaw, annotations }; // shallow clone plus updated values\n }\n }\n }\n\n // interpolate object detection results\n if (!bufferedResult.object || (newResult.object.length !== bufferedResult.object.length)) {\n bufferedResult.object = JSON.parse(JSON.stringify(newResult.object)) as ObjectResult[]; // deep clone once\n } else {\n for (let i = 0; i < newResult.object.length; i++) {\n const box = (newResult.object[i].box // update box\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.object[i].box[j] + b) / bufferedFactor)) as Box;\n const boxRaw = (newResult.object[i].boxRaw // update boxRaw\n .map((b, j) => ((bufferedFactor - 1) * bufferedResult.object[i].boxRaw[j] + b) / bufferedFactor)) as Box;\n bufferedResult.object[i] = { ...newResult.object[i], box, boxRaw }; // shallow clone plus updated values\n }\n }\n\n // interpolate person results\n if (newResult.persons) {\n const newPersons = newResult.persons; // trigger getter function\n if (!bufferedResult.persons || (newPersons.length !== bufferedResult.persons.length)) {\n bufferedResult.persons = JSON.parse(JSON.stringify(newPersons)) as PersonResult[];\n } else {\n for (let i = 0; i < newPersons.length; i++) { // update person box, we don't update the rest as it's updated as reference anyhow\n bufferedResult.persons[i].box = (newPersons[i].box\n .map((box, j) => ((bufferedFactor - 1) * bufferedResult.persons[i].box[j] + box) / bufferedFactor)) as Box;\n }\n }\n }\n\n // copy latest gestures without interpolation\n if (newResult.gesture) bufferedResult.gesture = newResult.gesture;\n\n // copy resolution info\n bufferedResult.width = newResult.width;\n bufferedResult.height = newResult.height;\n\n // append interpolation performance data\n const t1 = now();\n interpolateTime = env.perfadd ? interpolateTime + Math.round(t1 - t0) : Math.round(t1 - t0);\n if (newResult.performance) bufferedResult.performance = { ...newResult.performance, interpolate: interpolateTime };\n\n return bufferedResult;\n}\n", "/**\n * Image segmentation for body detection model\n *\n * Based on:\n * - [**MediaPipe Meet**](https://drive.google.com/file/d/1lnP1bRi9CSqQQXUHa13159vLELYDgDu0/preview)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.segmentation.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model) model = await load(config);\n if (!model?.['executor'] || !model?.inputs?.[0].shape) return null; // something is wrong with the model\n const t: Record = {};\n t.resize = tf.image.resizeBilinear(input, [model.inputs[0].shape ? model.inputs[0].shape[1] : 0, model.inputs[0].shape ? model.inputs[0].shape[2] : 0], false);\n t.norm = tf.div(t.resize, constants.tf255);\n t.res = model.execute(t.norm) as Tensor;\n t.squeeze = tf.squeeze(t.res, [0]);\n // t.softmax = tf.softmax(t.squeeze); // model meet has two channels for fg and bg\n [t.bgRaw, t.fgRaw] = tf.unstack(t.squeeze, 2);\n // t.bg = tf.softmax(t.bgRaw); // we can ignore bg channel\n t.fg = tf.softmax(t.fgRaw);\n t.mul = tf.mul(t.fg, constants.tf255);\n t.expand = tf.expandDims(t.mul, 2);\n t.output = tf.image.resizeBilinear(t.expand as Tensor4D, [input.shape[1] || 0, input.shape[2] || 0]);\n let rgba: Tensor;\n switch (config.segmentation.mode || 'default') {\n case 'default':\n t.input = tf.squeeze(input);\n t.concat = tf.concat([t.input, t.output], -1);\n rgba = tf.cast(t.concat, 'int32'); // combined original with alpha\n break;\n case 'alpha':\n rgba = tf.cast(t.output, 'int32'); // just get alpha value from model\n break;\n default:\n rgba = tf.tensor(0);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return rgba;\n}\n", "/** Face descriptor type as number array */\nexport type Descriptor = number[]\nexport type MatchOptions = { order?: number, threshold?: number, multiplier?: number, min?: number, max?: number } | undefined;\n\n/** Calculates distance between two descriptors\n * @param options - calculation options\n * - order - algorithm to use\n * Euclidean distance if `order` is 2 (default), Minkowski distance algorithm of nth order if `order` is higher than 2\n * - multiplier - by how much to enhance difference analysis in range of 1..100\n * default is 20 which normalizes results to similarity above 0.5 can be considered a match\n */\nexport function distance(descriptor1: Descriptor, descriptor2: Descriptor, options: MatchOptions = { order: 2, multiplier: 25 }) {\n // general minkowski distance, euclidean distance is limited case where order is 2\n if (!descriptor1 || !descriptor1) return Number.MAX_SAFE_INTEGER;\n let sum = 0;\n for (let i = 0; i < descriptor1.length; i++) {\n const diff = (!options.order || options.order === 2) ? (descriptor1[i] - descriptor2[i]) : (Math.abs(descriptor1[i] - descriptor2[i]));\n sum += (!options.order || options.order === 2) ? (diff * diff) : (diff ** options.order);\n }\n return (options.multiplier || 20) * sum;\n}\n\n// invert distance to similarity, normalize to given range and clamp\nconst normalizeDistance = (dist, order, min, max) => {\n if (dist === 0) return 1; // short circuit for identical inputs\n const root = order === 2 ? Math.sqrt(dist) : dist ** (1 / order); // take root of distance\n const norm = (1 - (root / 100) - min) / (max - min); // normalize to range\n const clamp = Math.max(Math.min(norm, 1), 0); // clamp to 0..1\n return clamp;\n};\n\n/** Calculates normalized similarity between two face descriptors based on their `distance`\n * @param options - calculation options\n * - order - algorithm to use\n * Euclidean distance if `order` is 2 (default), Minkowski distance algorithm of nth order if `order` is higher than 2\n * - multiplier - by how much to enhance difference analysis in range of 1..100\n * default is 20 which normalizes results to similarity above 0.5 can be considered a match\n * - min - normalize similarity result to a given range\n * - max - normalzie similarity resutl to a given range\n * default is 0.2...0.8\n * Returns similarity between two face descriptors normalized to 0..1 range where 0 is no similarity and 1 is perfect similarity\n */\nexport function similarity(descriptor1: Descriptor, descriptor2: Descriptor, options: MatchOptions = { order: 2, multiplier: 25, min: 0.2, max: 0.8 }) {\n const dist = distance(descriptor1, descriptor2, options);\n return normalizeDistance(dist, options.order || 2, options.min || 0, options.max || 1);\n}\n\n/** Matches given descriptor to a closest entry in array of descriptors\n * @param descriptor - face descriptor\n * @param descriptors - array of face descriptors to commpare given descriptor to\n * @param options - see `similarity` method for options description\n * Returns\n * - `index` index array index where best match was found or -1 if no matches\n * - `distance` calculated `distance` of given descriptor to the best match\n * - `similarity` calculated normalized `similarity` of given descriptor to the best match\n*/\nexport function find(descriptor: Descriptor, descriptors: Descriptor[], options: MatchOptions = { order: 2, multiplier: 25, threshold: 0, min: 0.2, max: 0.8 }) {\n if (!Array.isArray(descriptor) || !Array.isArray(descriptors) || descriptor.length < 64 || descriptors.length === 0) { // validate input\n return { index: -1, distance: Number.POSITIVE_INFINITY, similarity: 0 };\n }\n let lowestDistance = Number.MAX_SAFE_INTEGER;\n let index = -1;\n for (let i = 0; i < descriptors.length; i++) {\n const res = descriptors[i].length === descriptor.length ? distance(descriptor, descriptors[i], options) : Number.MAX_SAFE_INTEGER;\n if (res < lowestDistance) {\n lowestDistance = res;\n index = i;\n }\n if (lowestDistance < (options.threshold || 0)) break;\n }\n const normalizedSimilarity = normalizeDistance(lowestDistance, options.order || 2, options.min || 0, options.max || 1);\n return { index, distance: lowestDistance, similarity: normalizedSimilarity };\n}\n", "/**\n * Loader and Validator for all models used by Human\n */\n\nimport { env } from './util/env';\nimport { log } from './util/util';\nimport * as antispoof from './face/antispoof';\nimport * as blazeface from './face/blazeface';\nimport * as blazepose from './body/blazepose';\nimport * as centernet from './object/centernet';\nimport * as efficientpose from './body/efficientpose';\nimport * as emotion from './gear/emotion';\nimport * as facemesh from './face/facemesh';\nimport * as faceres from './face/faceres';\nimport * as gear from './gear/gear';\nimport * as handpose from './hand/handpose';\nimport * as handtrack from './hand/handtrack';\nimport * as insightface from './face/insightface';\nimport * as iris from './face/iris';\nimport * as liveness from './face/liveness';\nimport * as meet from './segmentation/meet';\nimport * as mobilefacenet from './face/mobilefacenet';\nimport * as movenet from './body/movenet';\nimport * as nanodet from './object/nanodet';\nimport * as posenet from './body/posenet';\nimport * as rvm from './segmentation/rvm';\nimport * as selfie from './segmentation/selfie';\nimport * as ssrnetAge from './gear/ssrnet-age';\nimport * as ssrnetGender from './gear/ssrnet-gender';\nimport { modelStats, ModelInfo } from './tfjs/load';\nimport type { GraphModel } from './tfjs/types';\nimport type { Human } from './human';\n\nexport interface KernelOps { name: string, url: string, missing: string[], ops: string[] }\n\nexport function validateModel(instance: Human | null, model: GraphModel | null, name: string): KernelOps | null {\n if (!model) return null;\n if (!instance?.config?.validateModels) return null;\n const simpleOps = ['const', 'placeholder', 'noop', 'pad', 'squeeze', 'add', 'sub', 'mul', 'div'];\n const ignoreOps = ['biasadd', 'fusedbatchnormv3', 'matmul', 'switch', 'shape', 'merge', 'split', 'broadcastto'];\n const ops: string[] = [];\n const missing: string[] = [];\n interface Op { name: string, category: string, op: string }\n const url = model['modelUrl'] as string;\n const executor = model['executor'];\n if (executor?.graph?.nodes) {\n for (const kernel of Object.values(executor.graph.nodes)) {\n const op = (kernel as Op).op.toLowerCase();\n if (!ops.includes(op)) ops.push(op);\n }\n } else {\n if (!executor && instance.config.debug) {\n log('model not loaded', name);\n }\n }\n for (const op of ops) {\n if (!simpleOps.includes(op) // exclude simple ops\n && !ignoreOps.includes(op) // exclude specific ops\n && !instance.env.kernels.includes(op) // check actual kernel ops\n && !instance.env.kernels.includes(op.replace('_', '')) // check variation without _\n && !instance.env.kernels.includes(op.replace('native', '')) // check standard variation\n && !instance.env.kernels.includes(op.replace('v2', ''))) { // check non-versioned variation\n missing.push(op);\n }\n }\n if (instance.config.debug && missing.length > 0) log('model validation failed:', name, missing);\n return missing.length > 0 ? { name, missing, ops, url } : null;\n}\n\n/** structure that holds global stats for currently loaded models */\nexport interface ModelStats {\n numLoadedModels: number,\n numDefinedModels: number,\n percentageLoaded: number,\n totalSizeFromManifest: number,\n totalSizeWeights: number,\n totalSizeLoading: number,\n modelStats: ModelInfo[],\n}\n\n/** Models class used by Human\n * - models: record of all GraphModels\n * - list: returns list of configured models with their stats\n * - loaded: returns array of loaded models\n * - reset: unloads all models\n * - validate: checks loaded models for valid kernel ops vs current backend\n * - stats: live detailed model stats that can be checked during model load phase\n */\nexport class Models {\n private instance: Human;\n models: Record = {};\n\n constructor(currentInstance: Human) {\n this.models = {};\n this.instance = currentInstance;\n }\n\n stats(): ModelStats {\n let totalSizeFromManifest = 0;\n let totalSizeWeights = 0;\n let totalSizeLoading = 0;\n for (const m of Object.values(modelStats)) {\n totalSizeFromManifest += m.sizeFromManifest;\n totalSizeWeights += m.sizeLoadedWeights;\n totalSizeLoading += m.sizeDesired;\n }\n const percentageLoaded = totalSizeLoading > 0 ? totalSizeWeights / totalSizeLoading : 0;\n return {\n numLoadedModels: Object.values(modelStats).length,\n numDefinedModels: Object.keys(this.models).length,\n percentageLoaded,\n totalSizeFromManifest,\n totalSizeWeights,\n totalSizeLoading,\n modelStats: Object.values(modelStats),\n };\n }\n\n reset(): void {\n for (const model of Object.keys(this.models)) this.models[model] = null;\n }\n\n async load(instance?: Human): Promise {\n if (env.initial) this.reset();\n if (instance) this.instance = instance;\n const m: Record> = {};\n // face main models\n m.blazeface = (this.instance.config.face.enabled && !this.models.blazeface) ? blazeface.load(this.instance.config) : null;\n m.antispoof = (this.instance.config.face.enabled && this.instance.config.face.antispoof?.enabled && !this.models.antispoof) ? antispoof.load(this.instance.config) : null;\n m.liveness = (this.instance.config.face.enabled && this.instance.config.face.liveness?.enabled && !this.models.liveness) ? liveness.load(this.instance.config) : null;\n m.faceres = (this.instance.config.face.enabled && this.instance.config.face.description?.enabled && !this.models.faceres) ? faceres.load(this.instance.config) : null;\n m.emotion = (this.instance.config.face.enabled && this.instance.config.face.emotion?.enabled && !this.models.emotion) ? emotion.load(this.instance.config) : null;\n m.iris = (this.instance.config.face.enabled && this.instance.config.face.iris?.enabled && !this.instance.config.face.attention?.enabled && !this.models.iris) ? iris.load(this.instance.config) : null;\n m.facemesh = (this.instance.config.face.enabled && this.instance.config.face.mesh?.enabled && (!this.models.facemesh)) ? facemesh.load(this.instance.config) : null;\n // face alternatives\n m.gear = (this.instance.config.face.enabled && this.instance.config.face['gear']?.enabled && !this.models.gear) ? gear.load(this.instance.config) : null;\n m.ssrnetage = (this.instance.config.face.enabled && this.instance.config.face['ssrnet']?.enabled && !this.models.ssrnetage) ? ssrnetAge.load(this.instance.config) : null;\n m.ssrnetgender = (this.instance.config.face.enabled && this.instance.config.face['ssrnet']?.enabled && !this.models.ssrnetgender) ? ssrnetGender.load(this.instance.config) : null;\n m.mobilefacenet = (this.instance.config.face.enabled && this.instance.config.face['mobilefacenet']?.enabled && !this.models.mobilefacenet) ? mobilefacenet.load(this.instance.config) : null;\n m.insightface = (this.instance.config.face.enabled && this.instance.config.face['insightface']?.enabled && !this.models.insightface) ? insightface.load(this.instance.config) : null;\n // body alterinatives\n m.blazepose = (this.instance.config.body.enabled && !this.models.blazepose && this.instance.config.body.modelPath?.includes('blazepose')) ? blazepose.loadPose(this.instance.config) : null;\n m.blazeposedetect = (this.instance.config.body.enabled && !this.models.blazeposedetect && this.instance.config.body['detector'] && this.instance.config.body['detector'].modelPath) ? blazepose.loadDetect(this.instance.config) : null;\n m.efficientpose = (this.instance.config.body.enabled && !this.models.efficientpose && this.instance.config.body.modelPath?.includes('efficientpose')) ? efficientpose.load(this.instance.config) : null;\n m.movenet = (this.instance.config.body.enabled && !this.models.movenet && this.instance.config.body.modelPath?.includes('movenet')) ? movenet.load(this.instance.config) : null;\n m.posenet = (this.instance.config.body.enabled && !this.models.posenet && this.instance.config.body.modelPath?.includes('posenet')) ? posenet.load(this.instance.config) : null;\n // hand alternatives\n m.handtrack = (this.instance.config.hand.enabled && !this.models.handtrack && this.instance.config.hand.detector?.modelPath?.includes('handtrack')) ? handtrack.loadDetect(this.instance.config) : null;\n m.handskeleton = (this.instance.config.hand.enabled && this.instance.config.hand.landmarks && !this.models.handskeleton && this.instance.config.hand.detector?.modelPath?.includes('handtrack')) ? handtrack.loadSkeleton(this.instance.config) : null;\n // if (this.instance.config.hand.detector?.modelPath?.includes('handdetect')) [m.handpose, m.handskeleton] = (!this.models.handpose) ? await handpose.load(this.instance.config) : [null, null];\n if (this.instance.config.hand.enabled && !this.models.handdetect && this.instance.config.hand.detector?.modelPath?.includes('handdetect')) {\n m.handdetect = handpose.loadDetect(this.instance.config);\n m.handskeleton = handpose.loadSkeleton(this.instance.config);\n }\n // object detection alternatives\n m.centernet = (this.instance.config.object.enabled && !this.models.centernet && this.instance.config.object.modelPath?.includes('centernet')) ? centernet.load(this.instance.config) : null;\n m.nanodet = (this.instance.config.object.enabled && !this.models.nanodet && this.instance.config.object.modelPath?.includes('nanodet')) ? nanodet.load(this.instance.config) : null;\n // segmentation alternatives\n m.selfie = (this.instance.config.segmentation.enabled && !this.models.selfie && this.instance.config.segmentation.modelPath?.includes('selfie')) ? selfie.load(this.instance.config) : null;\n m.meet = (this.instance.config.segmentation.enabled && !this.models.meet && this.instance.config.segmentation.modelPath?.includes('meet')) ? meet.load(this.instance.config) : null;\n m.rvm = (this.instance.config.segmentation.enabled && !this.models.rvm && this.instance.config.segmentation.modelPath?.includes('rvm')) ? rvm.load(this.instance.config) : null;\n\n // models are loaded in parallel asynchronously so lets wait until they are actually loaded\n for (const [model, promise] of Object.entries(m)) {\n if (promise?.['then']) promise['then']((val) => this.models[model] = val);\n }\n await Promise.all(Object.values(m)); // wait so this function does not resolve prematurely\n }\n\n list() {\n const models = Object.keys(this.models).map((model) => ({ name: model, loaded: (this.models[model] !== null), size: 0, url: this.models[model] ? this.models[model]?.['modelUrl'] : null }));\n for (const m of models) {\n const stats = Object.keys(modelStats).find((s) => s.startsWith(m.name));\n if (!stats) continue;\n m.size = modelStats[stats].sizeLoadedWeights;\n m.url = modelStats[stats].url;\n }\n return models;\n }\n\n loaded() {\n const list = this.list();\n const loaded = list.filter((model) => model.loaded).map((model) => model.name);\n return loaded;\n }\n\n validate(): { name: string, missing: string[] }[] {\n const missing: KernelOps[] = [];\n for (const defined of Object.keys(this.models)) {\n const model: GraphModel | null = this.models[defined as keyof Models];\n if (!model) continue;\n const res = validateModel(this.instance, model, defined);\n if (res) missing.push(res);\n }\n return missing;\n }\n}\n", "import * as tf from 'dist/tfjs.esm.js';\nimport type { BodyKeypoint, BodyResult } from '../result';\nimport * as box from '../util/box';\nimport * as coords from './movenetcoords';\nimport type { Tensor, Tensor3D } from '../tfjs/types';\n\nconst maxJitter = 0.005; // default allowed jitter is within 0.5%\n\nconst cache: {\n keypoints: BodyKeypoint[],\n padding: [number, number][];\n} = {\n keypoints: [],\n padding: [[0, 0], [0, 0], [0, 0], [0, 0]],\n};\n\nexport function bodyParts(body: BodyResult) { // model sometimes mixes up left vs right keypoints so we fix them\n for (const pair of coords.horizontal) { // fix body parts left vs right\n const left = body.keypoints.findIndex((kp) => kp.part === pair[0]);\n const right = body.keypoints.findIndex((kp) => kp.part === pair[1]);\n if (body.keypoints[left] && body.keypoints[right]) {\n if (body.keypoints[left].position[0] < body.keypoints[right].position[0]) {\n const tmp = body.keypoints[left];\n body.keypoints[left] = body.keypoints[right];\n body.keypoints[right] = tmp;\n }\n }\n }\n for (const pair of coords.vertical) { // remove body parts with improbable vertical position\n const lower = body.keypoints.findIndex((kp) => (kp && kp.part === pair[0]));\n const higher = body.keypoints.findIndex((kp) => (kp && kp.part === pair[1]));\n if (body.keypoints[lower] && body.keypoints[higher]) {\n if (body.keypoints[lower].position[1] < body.keypoints[higher].position[1]) {\n body.keypoints.splice(lower, 1);\n }\n }\n }\n for (const [pair, compare] of coords.relative) { // rearrange body parts according to their relative position\n const left = body.keypoints.findIndex((kp) => (kp && kp.part === pair[0]));\n const right = body.keypoints.findIndex((kp) => (kp && kp.part === pair[1]));\n const leftTo = body.keypoints.findIndex((kp) => (kp && kp.part === compare[0]));\n const rightTo = body.keypoints.findIndex((kp) => (kp && kp.part === compare[1]));\n if (!body.keypoints[leftTo] || !body.keypoints[rightTo]) continue; // only if we have both compare points\n const distanceLeft = body.keypoints[left] ? [\n Math.abs(body.keypoints[leftTo].position[0] - body.keypoints[left].position[0]),\n Math.abs(body.keypoints[rightTo].position[0] - body.keypoints[left].position[0]),\n ] : [0, 0];\n const distanceRight = body.keypoints[right] ? [\n Math.abs(body.keypoints[rightTo].position[0] - body.keypoints[right].position[0]),\n Math.abs(body.keypoints[leftTo].position[0] - body.keypoints[right].position[0]),\n ] : [0, 0];\n if (distanceLeft[0] > distanceLeft[1] || distanceRight[0] > distanceRight[1]) { // should flip keypoints\n const tmp = body.keypoints[left];\n body.keypoints[left] = body.keypoints[right];\n body.keypoints[right] = tmp;\n }\n }\n}\n\nexport function jitter(keypoints: BodyKeypoint[]): BodyKeypoint[] {\n for (let i = 0; i < keypoints.length; i++) {\n if (keypoints[i] && cache.keypoints[i]) {\n const diff = [Math.abs(keypoints[i].positionRaw[0] - cache.keypoints[i].positionRaw[0]), Math.abs(keypoints[i].positionRaw[1] - cache.keypoints[i].positionRaw[1])];\n if (diff[0] < maxJitter && diff[1] < maxJitter) {\n keypoints[i] = cache.keypoints[i]; // below jitter so replace keypoint\n } else {\n cache.keypoints[i] = keypoints[i]; // above jitter so update cache\n }\n } else {\n cache.keypoints[i] = keypoints[i]; // cache for keypoint doesnt exist so create it here\n }\n }\n return keypoints;\n}\n\nexport function padInput(input: Tensor, inputSize: number): Tensor {\n const t: Record = {};\n if (!input?.shape?.[1] || !input?.shape?.[2]) return input;\n cache.padding = [\n [0, 0], // dont touch batch\n [input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0, input.shape[2] > input.shape[1] ? Math.trunc((input.shape[2] - input.shape[1]) / 2) : 0], // height before&after\n [input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0, input.shape[1] > input.shape[2] ? Math.trunc((input.shape[1] - input.shape[2]) / 2) : 0], // width before&after\n [0, 0], // dont touch rbg\n ];\n t.pad = tf.pad(input, cache.padding);\n t.resize = tf.image.resizeBilinear(t.pad as Tensor3D, [inputSize, inputSize]);\n const final = tf.cast(t.resize, 'int32');\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return final;\n}\n\nexport function rescaleBody(body: BodyResult, outputSize: [number, number]): BodyResult {\n body.keypoints = body.keypoints.filter((kpt) => kpt?.position); // filter invalid keypoints\n for (const kpt of body.keypoints) {\n kpt.position = [\n kpt.position[0] * (outputSize[0] + cache.padding[2][0] + cache.padding[2][1]) / outputSize[0] - cache.padding[2][0],\n kpt.position[1] * (outputSize[1] + cache.padding[1][0] + cache.padding[1][1]) / outputSize[1] - cache.padding[1][0],\n ];\n kpt.positionRaw = [\n kpt.position[0] / outputSize[0], kpt.position[1] / outputSize[1],\n ];\n }\n const rescaledBoxes = box.calc(body.keypoints.map((pt) => pt.position), outputSize);\n body.box = rescaledBoxes.box;\n body.boxRaw = rescaledBoxes.boxRaw;\n return body;\n}\n", "/**\n * MoveNet model implementation\n *\n * Based on: [**MoveNet**](https://blog.tensorflow.org/2021/05/next-generation-pose-detection-with-movenet-and-tensorflowjs.html)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport * as box from '../util/box';\nimport * as coords from './movenetcoords';\nimport * as fix from './movenetfix';\nimport { loadModel } from '../tfjs/load';\nimport type { BodyKeypoint, BodyResult, BodyLandmark, BodyAnnotation, Box, Point } from '../result';\nimport type { GraphModel, Tensor } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { fakeOps } from '../tfjs/backend';\nimport { env } from '../util/env';\n\nlet model: GraphModel | null;\nlet inputSize = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\n// const boxExpandFact = 1.5; // increase to 150%\n\nconst cache: {\n boxes: Box[], // unused\n bodies: BodyResult[];\n last: number,\n} = {\n boxes: [],\n bodies: [],\n last: 0,\n};\n\nexport async function load(config: Config): Promise {\n if (env.initial) model = null;\n if (!model) {\n fakeOps(['size'], config);\n model = await loadModel(config.body.modelPath);\n } else if (config.debug) log('cached model:', model['modelUrl']);\n inputSize = (model?.['executor'] && model?.inputs?.[0].shape) ? model.inputs[0].shape[2] : 0;\n if (inputSize < 64) inputSize = 256;\n // @ts-ignore private property\n if (tf.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS) tf.env().set('WEBGL_USE_SHAPES_UNIFORMS', false); // default=false \n return model;\n}\n\nfunction parseSinglePose(res, config, image) {\n const kpt = res[0][0];\n const keypoints: BodyKeypoint[] = [];\n let score = 0;\n for (let id = 0; id < kpt.length; id++) {\n score = kpt[id][2];\n if (score > config.body.minConfidence) {\n const positionRaw: Point = [kpt[id][1], kpt[id][0]];\n keypoints.push({\n score: Math.round(100 * score) / 100,\n part: coords.kpt[id] as BodyLandmark,\n positionRaw,\n position: [ // normalized to input image size\n Math.round((image.shape[2] || 0) * positionRaw[0]),\n Math.round((image.shape[1] || 0) * positionRaw[1]),\n ],\n });\n }\n }\n score = keypoints.reduce((prev, curr) => (curr.score > prev ? curr.score : prev), 0);\n const bodies: BodyResult[] = [];\n const newBox = box.calc(keypoints.map((pt) => pt.position), [image.shape[2], image.shape[1]]);\n const annotations: Record = {};\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = keypoints.find((kp) => kp.part === indexes[i]);\n const pt1 = keypoints.find((kp) => kp.part === indexes[i + 1]);\n if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n const body: BodyResult = { id: 0, score, box: newBox.box, boxRaw: newBox.boxRaw, keypoints, annotations };\n fix.bodyParts(body);\n bodies.push(body);\n return bodies;\n}\n\nfunction parseMultiPose(res, config, image) {\n const bodies: BodyResult[] = [];\n for (let id = 0; id < res[0].length; id++) {\n const kpt = res[0][id];\n const boxScore = Math.round(100 * kpt[51 + 4]) / 100;\n if (boxScore > config.body.minConfidence) {\n const keypoints: BodyKeypoint[] = [];\n for (let i = 0; i < 17; i++) {\n const score = kpt[3 * i + 2];\n if (score > config.body.minConfidence) {\n const positionRaw: Point = [kpt[3 * i + 1], kpt[3 * i + 0]];\n keypoints.push({\n part: coords.kpt[i] as BodyLandmark,\n score: Math.round(100 * score) / 100,\n positionRaw,\n position: [Math.round((image.shape[2] || 0) * positionRaw[0]), Math.round((image.shape[1] || 0) * positionRaw[1])],\n });\n }\n }\n // const newBox = box.calc(keypoints.map((pt) => pt.position), [image.shape[2], image.shape[1]]);\n // movenet-multipose has built-in box details\n const boxRaw: Box = [kpt[51 + 1], kpt[51 + 0], kpt[51 + 3] - kpt[51 + 1], kpt[51 + 2] - kpt[51 + 0]];\n const boxNorm: Box = [Math.trunc(boxRaw[0] * (image.shape[2] || 0)), Math.trunc(boxRaw[1] * (image.shape[1] || 0)), Math.trunc(boxRaw[2] * (image.shape[2] || 0)), Math.trunc(boxRaw[3] * (image.shape[1] || 0))];\n const annotations: Record = {} as Record;\n for (const [name, indexes] of Object.entries(coords.connected)) {\n const pt: Point[][] = [];\n for (let i = 0; i < indexes.length - 1; i++) {\n const pt0 = keypoints.find((kp) => kp.part === indexes[i]);\n const pt1 = keypoints.find((kp) => kp.part === indexes[i + 1]);\n if (pt0 && pt1 && pt0.score > (config.body.minConfidence || 0) && pt1.score > (config.body.minConfidence || 0)) pt.push([pt0.position, pt1.position]);\n }\n annotations[name] = pt;\n }\n // const body: BodyResult = { id, score: totalScore, box: newBox.box, boxRaw: newBox.boxRaw, keypoints: [...keypoints], annotations };\n const body: BodyResult = { id, score: boxScore, box: boxNorm, boxRaw, keypoints: [...keypoints], annotations };\n fix.bodyParts(body);\n bodies.push(body);\n }\n }\n bodies.sort((a, b) => b.score - a.score);\n if (bodies.length > config.body.maxDetected) bodies.length = config.body.maxDetected;\n return bodies;\n}\n\nexport async function predict(input: Tensor, config: Config): Promise {\n if (!model?.['executor'] || !model?.inputs?.[0].shape) return []; // something is wrong with the model\n if (!config.skipAllowed) cache.boxes.length = 0; // allowed to use cache or not\n skipped++; // increment skip frames\n const skipTime = (config.body.skipTime || 0) > (now() - cache.last);\n const skipFrame = skipped < (config.body.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame) {\n return cache.bodies; // return cached results without running anything\n }\n return new Promise(async (resolve) => {\n const t: Record = {};\n skipped = 0;\n // run detection on squared input and no cached boxes\n t.input = fix.padInput(input, inputSize);\n t.res = model?.execute(t.input) as Tensor;\n cache.last = now();\n const res = await t.res.array();\n cache.bodies = (t.res.shape[2] === 17)\n ? parseSinglePose(res, config, input)\n : parseMultiPose(res, config, input);\n for (const body of cache.bodies) {\n fix.rescaleBody(body, [input.shape[2] || 1, input.shape[1] || 1]);\n fix.jitter(body.keypoints);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n\n resolve(cache.bodies);\n });\n}\n", "/**\n * NanoDet object detection model implementation\n *\n * Based on: [**NanoDet**](https://github.com/RangiLyu/nanodet)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport { labels } from './labels';\nimport type { ObjectResult, ObjectType, Box } from '../result';\nimport type { GraphModel, Tensor, Tensor2D, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\nlet last: ObjectResult[] = [];\nlet lastTime = 0;\nlet skipped = Number.MAX_SAFE_INTEGER;\nlet inputSize = 0;\n\nconst scaleBox = 2.5; // increase box size\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) {\n model = await loadModel(config.object.modelPath);\n const inputs = model?.['executor'] ? Object.values(model.modelSignature['inputs']) : undefined;\n // @ts-ignore model signature properties are not typed and inputs are unreliable for this model\n inputSize = Array.isArray(inputs) ? parseInt(inputs[0].tensorShape.dim[2].size) : 416;\n } else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nasync function process(res: Tensor[], outputShape: [number, number], config: Config) {\n let id = 0;\n let results: ObjectResult[] = [];\n const size = inputSize;\n for (const strideSize of [1, 2, 4]) { // try each stride size as it detects large/medium/small objects\n // find scores, boxes, classes\n const baseSize = strideSize * 13; // 13x13=169, 26x26=676, 52x52=2704\n // find boxes and scores output depending on stride\n const scoresT = tf.squeeze(res.find((a) => (a.shape[1] === (baseSize ** 2) && (a.shape[2] || 0) === labels.length)) as Tensor2D);\n const scores = await scoresT.array(); // optionally use exponential scores or just as-is\n const featuresT = tf.squeeze(res.find((a) => (a.shape[1] === (baseSize ** 2) && (a.shape[2] || 0) < labels.length)) as Tensor2D);\n const boxesMaxT = tf.reshape(featuresT, [-1, 4, (featuresT.shape?.[1] || 0) / 4]); // reshape [output] to [4, output / 4] where number is number of different features inside each stride\n const boxIdxT = tf.argMax(boxesMaxT, 2); // what we need is indexes of features with highest scores, not values itself\n const boxIdx = await boxIdxT.array(); // what we need is indexes of features with highest scores, not values itself\n for (let i = 0; i < scoresT.shape[0]; i++) { // total strides (x * y matrix)\n for (let j = 0; j < (scoresT.shape?.[1] || 0); j++) { // one score for each class\n const score = scores[i][j]; // get score for current position\n if (score > (config.object.minConfidence || 0) && j !== 61) {\n const cx = (0.5 + Math.trunc(i % baseSize)) / baseSize; // center.x normalized to range 0..1\n const cy = (0.5 + Math.trunc(i / baseSize)) / baseSize; // center.y normalized to range 0..1\n const boxOffset = boxIdx[i].map((a: number) => a * (baseSize / strideSize / (size))); // just grab indexes of features with highest scores\n const [x, y] = [\n cx - (scaleBox / strideSize * boxOffset[0]),\n cy - (scaleBox / strideSize * boxOffset[1]),\n ];\n const [w, h] = [\n cx + (scaleBox / strideSize * boxOffset[2]) - x,\n cy + (scaleBox / strideSize * boxOffset[3]) - y,\n ];\n let boxRaw: Box = [x, y, w, h]; // results normalized to range 0..1\n boxRaw = boxRaw.map((a) => Math.max(0, Math.min(a, 1))) as Box; // fix out-of-bounds coords\n const box = [ // results normalized to input image pixels\n boxRaw[0] * outputShape[0],\n boxRaw[1] * outputShape[1],\n boxRaw[2] * outputShape[0],\n boxRaw[3] * outputShape[1],\n ];\n const result = {\n id: id++,\n // strideSize,\n score: Math.round(100 * score) / 100,\n class: j + 1,\n label: labels[j].label as ObjectType,\n // center: [Math.trunc(outputShape[0] * cx), Math.trunc(outputShape[1] * cy)],\n // centerRaw: [cx, cy],\n box: box.map((a) => Math.trunc(a)) as Box,\n boxRaw,\n };\n results.push(result);\n }\n }\n }\n tf.dispose([scoresT, featuresT, boxesMaxT, boxIdxT]);\n }\n\n // normally nms is run on raw results, but since boxes need to be calculated this way we skip calulcation of\n // unnecessary boxes and run nms only on good candidates (basically it just does IOU analysis as scores are already filtered)\n const nmsBoxes = results.map((a) => [a.boxRaw[1], a.boxRaw[0], a.boxRaw[3], a.boxRaw[2]]); // switches coordinates from x,y to y,x as expected by tf.nms\n const nmsScores = results.map((a) => a.score);\n let nmsIdx: number[] = [];\n if (nmsBoxes && nmsBoxes.length > 0) {\n const nms = await tf.image.nonMaxSuppressionAsync(nmsBoxes, nmsScores, config.object.maxDetected || 0, config.object.iouThreshold, config.object.minConfidence);\n nmsIdx = Array.from(await nms.data());\n tf.dispose(nms);\n }\n\n // filter & sort results\n results = results\n .filter((_val, idx) => nmsIdx.includes(idx))\n .sort((a, b) => (b.score - a.score));\n\n return results;\n}\n\nexport async function predict(image: Tensor4D, config: Config): Promise {\n if (!model?.['executor']) return [];\n const skipTime = (config.object.skipTime || 0) > (now() - lastTime);\n const skipFrame = skipped < (config.object.skipFrames || 0);\n if (config.skipAllowed && skipTime && skipFrame && (last.length > 0)) {\n skipped++;\n return last;\n }\n skipped = 0;\n if (!env.kernels.includes('mod') || !env.kernels.includes('sparsetodense')) return last;\n return new Promise(async (resolve) => {\n const outputSize = [image.shape[2] || 0, image.shape[1] || 0];\n const resizeT = tf.image.resizeBilinear(image, [inputSize, inputSize], false);\n const normT = tf.div(resizeT, constants.tf255);\n const transposeT = tf.transpose(normT, [0, 3, 1, 2]);\n\n let objectT;\n if (config.object.enabled) objectT = model.execute(transposeT);\n lastTime = now();\n\n const obj = await process(objectT as Tensor[], outputSize as [number, number], config);\n last = obj;\n tf.dispose([resizeT, normT, transposeT, ...objectT]);\n resolve(obj);\n });\n}\n", "/**\n * PoseNet body detection model implementation constants\n * See `posenet.ts` for entry point\n */\n\nimport type { Point, BodyResult, BodyAnnotation, BodyLandmark } from '../result';\n\nexport const partNames = [\n 'nose', 'leftEye', 'rightEye', 'leftEar', 'rightEar', 'leftShoulder',\n 'rightShoulder', 'leftElbow', 'rightElbow', 'leftWrist', 'rightWrist',\n 'leftHip', 'rightHip', 'leftKnee', 'rightKnee', 'leftAnkle', 'rightAnkle',\n];\n\nexport const count = partNames.length; // 17 keypoints\n\nexport const partIds = partNames.reduce((result, jointName, i) => {\n result[jointName] = i;\n return result;\n}, {});\n\nconst connectedPartNames = [\n ['leftHip', 'leftShoulder'], ['leftElbow', 'leftShoulder'],\n ['leftElbow', 'leftWrist'], ['leftHip', 'leftKnee'],\n ['leftKnee', 'leftAnkle'], ['rightHip', 'rightShoulder'],\n ['rightElbow', 'rightShoulder'], ['rightElbow', 'rightWrist'],\n ['rightHip', 'rightKnee'], ['rightKnee', 'rightAnkle'],\n ['leftShoulder', 'rightShoulder'], ['leftHip', 'rightHip'],\n];\nexport const connectedPartIndices = connectedPartNames.map(([jointNameA, jointNameB]) => ([partIds[jointNameA], partIds[jointNameB]]));\n\nexport const poseChain = [\n ['nose', 'leftEye'], ['leftEye', 'leftEar'], ['nose', 'rightEye'],\n ['rightEye', 'rightEar'], ['nose', 'leftShoulder'],\n ['leftShoulder', 'leftElbow'], ['leftElbow', 'leftWrist'],\n ['leftShoulder', 'leftHip'], ['leftHip', 'leftKnee'],\n ['leftKnee', 'leftAnkle'], ['nose', 'rightShoulder'],\n ['rightShoulder', 'rightElbow'], ['rightElbow', 'rightWrist'],\n ['rightShoulder', 'rightHip'], ['rightHip', 'rightKnee'],\n ['rightKnee', 'rightAnkle'],\n];\n\nexport function eitherPointDoesntMeetConfidence(a: number, b: number, minConfidence: number) {\n return (a < minConfidence || b < minConfidence);\n}\n\nexport function getAdjacentKeyPoints(keypoints, minConfidence: number) {\n return connectedPartIndices.reduce((result, [leftJoint, rightJoint]) => {\n if (eitherPointDoesntMeetConfidence(keypoints[leftJoint].score, keypoints[rightJoint].score, minConfidence)) {\n return result;\n }\n result.push([keypoints[leftJoint], keypoints[rightJoint]]);\n return result;\n }, []);\n}\n\nexport function getBoundingBox(keypoints): [number, number, number, number] {\n const coord = keypoints.reduce(({ maxX, maxY, minX, minY }, { position: { x, y } }) => ({\n maxX: Math.max(maxX, x),\n maxY: Math.max(maxY, y),\n minX: Math.min(minX, x),\n minY: Math.min(minY, y),\n }), {\n maxX: Number.NEGATIVE_INFINITY,\n maxY: Number.NEGATIVE_INFINITY,\n minX: Number.POSITIVE_INFINITY,\n minY: Number.POSITIVE_INFINITY,\n });\n return [coord.minX, coord.minY, coord.maxX - coord.minX, coord.maxY - coord.minY];\n}\n\nexport function scalePoses(poses, [height, width], [inputResolutionHeight, inputResolutionWidth]): BodyResult[] {\n const scaleY = height / inputResolutionHeight;\n const scaleX = width / inputResolutionWidth;\n const scalePose = (pose, i): BodyResult => ({\n id: i,\n score: pose.score,\n boxRaw: [pose.box[0] / inputResolutionWidth, pose.box[1] / inputResolutionHeight, pose.box[2] / inputResolutionWidth, pose.box[3] / inputResolutionHeight],\n box: [Math.trunc(pose.box[0] * scaleX), Math.trunc(pose.box[1] * scaleY), Math.trunc(pose.box[2] * scaleX), Math.trunc(pose.box[3] * scaleY)],\n keypoints: pose.keypoints.map(({ score, part, position }) => ({\n score: score as number,\n part: part as BodyLandmark,\n position: [Math.trunc(position.x * scaleX), Math.trunc(position.y * scaleY)] as Point,\n positionRaw: [position.x / inputResolutionHeight, position.y / inputResolutionHeight] as Point,\n })),\n annotations: {} as Record,\n });\n const scaledPoses = poses.map((pose, i) => scalePose(pose, i));\n return scaledPoses;\n}\n\n// algorithm based on Coursera Lecture from Algorithms, Part 1: https://www.coursera.org/learn/algorithms-part1/lecture/ZjoSM/heapsort\nexport class MaxHeap {\n priorityQueue: unknown[]; // don't touch\n numberOfElements: number;\n getElementValue: unknown; // function call\n\n constructor(maxSize, getElementValue) {\n this.priorityQueue = new Array(maxSize);\n this.numberOfElements = -1;\n this.getElementValue = getElementValue;\n }\n\n enqueue(x) {\n this.priorityQueue[++this.numberOfElements] = x;\n this.swim(this.numberOfElements);\n }\n\n dequeue() {\n const max = this.priorityQueue[0];\n this.exchange(0, this.numberOfElements--);\n this.sink(0);\n this.priorityQueue[this.numberOfElements + 1] = null;\n return max;\n }\n\n empty() { return this.numberOfElements === -1; }\n\n size() { return this.numberOfElements + 1; }\n\n all() { return this.priorityQueue.slice(0, this.numberOfElements + 1); }\n\n max() { return this.priorityQueue[0]; }\n\n swim(k) {\n while (k > 0 && this.less(Math.floor(k / 2), k)) {\n this.exchange(k, Math.floor(k / 2));\n k = Math.floor(k / 2);\n }\n }\n\n sink(k) {\n while (2 * k <= this.numberOfElements) {\n let j = 2 * k;\n if (j < this.numberOfElements && this.less(j, j + 1)) j++;\n if (!this.less(k, j)) break;\n this.exchange(k, j);\n k = j;\n }\n }\n\n getValueAt(i) {\n // @ts-ignore getter is of unknown type\n return this.getElementValue(this.priorityQueue[i]);\n }\n\n less(i, j) {\n return this.getValueAt(i) < this.getValueAt(j);\n }\n\n exchange(i, j) {\n const t = this.priorityQueue[i];\n this.priorityQueue[i] = this.priorityQueue[j];\n this.priorityQueue[j] = t;\n }\n}\n\nexport function getOffsetPoint(y, x, keypoint: number, offsets) {\n return {\n y: offsets.get(y, x, keypoint),\n x: offsets.get(y, x, keypoint + count),\n };\n}\n\nexport function getImageCoords(part, outputStride: number, offsets) {\n const { heatmapY, heatmapX, id: keypoint } = part;\n const { y, x } = getOffsetPoint(heatmapY, heatmapX, keypoint, offsets);\n return {\n x: part.heatmapX * outputStride + x,\n y: part.heatmapY * outputStride + y,\n };\n}\n\nexport function fillArray(element, size) {\n const result = new Array(size);\n for (let i = 0; i < size; i++) {\n result[i] = element;\n }\n return result;\n}\n\nexport function clamp(a, min, max) {\n if (a < min) return min;\n if (a > max) return max;\n return a;\n}\n\nexport function squaredDistance(y1, x1, y2, x2) {\n const dy = y2 - y1;\n const dx = x2 - x1;\n return dy * dy + dx * dx;\n}\n\nexport function addVectors(a: { x: number, y: number }, b: { x: number, y: number }) {\n return { x: a.x + b.x, y: a.y + b.y };\n}\n\nexport function clampVector(a, min, max) {\n return { y: clamp(a.y, min, max), x: clamp(a.x, min, max) };\n}\n", "/**\n * PoseNet body detection model implementation\n *\n * Based on: [**PoseNet**](https://medium.com/tensorflow/real-time-human-pose-estimation-in-the-browser-with-tensorflow-js-7dd0bc881cd5)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport type { BodyResult, BodyLandmark, Box } from '../result';\nimport type { Tensor, GraphModel, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\nimport * as utils from './posenetutils';\n\nlet model: GraphModel;\nconst poseNetOutputs = ['MobilenetV1/offset_2/BiasAdd'/* offsets */, 'MobilenetV1/heatmap_2/BiasAdd'/* heatmapScores */, 'MobilenetV1/displacement_fwd_2/BiasAdd'/* displacementFwd */, 'MobilenetV1/displacement_bwd_2/BiasAdd'/* displacementBwd */];\nconst localMaximumRadius = 1;\nconst outputStride = 16;\nconst squaredNmsRadius = 50 ** 2;\n\nfunction traverse(edgeId: number, sourceKeypoint, targetId, scores, offsets, displacements, offsetRefineStep = 2) {\n const getDisplacement = (point) => ({\n y: displacements.get(point.y, point.x, edgeId),\n x: displacements.get(point.y, point.x, (displacements.shape[2] / 2) + edgeId),\n });\n const getStridedIndexNearPoint = (point, height, width) => ({\n y: utils.clamp(Math.round(point.y / outputStride), 0, height - 1),\n x: utils.clamp(Math.round(point.x / outputStride), 0, width - 1),\n });\n\n const [height, width] = scores.shape;\n // Nearest neighbor interpolation for the source->target displacements.\n const sourceKeypointIndices = getStridedIndexNearPoint(sourceKeypoint.position, height, width);\n const displacement = getDisplacement(sourceKeypointIndices);\n const displacedPoint = utils.addVectors(sourceKeypoint.position, displacement);\n let targetKeypoint = displacedPoint;\n for (let i = 0; i < offsetRefineStep; i++) {\n const targetKeypointIndices = getStridedIndexNearPoint(targetKeypoint, height, width);\n const offsetPoint = utils.getOffsetPoint(targetKeypointIndices.y, targetKeypointIndices.x, targetId, offsets);\n targetKeypoint = utils.addVectors(\n { x: targetKeypointIndices.x * outputStride, y: targetKeypointIndices.y * outputStride },\n { x: offsetPoint.x, y: offsetPoint.y },\n );\n }\n const targetKeyPointIndices = getStridedIndexNearPoint(targetKeypoint, height, width);\n const score = scores.get(targetKeyPointIndices.y, targetKeyPointIndices.x, targetId);\n return { position: targetKeypoint, part: utils.partNames[targetId], score };\n}\n\nexport function decodePose(root, scores, offsets, displacementsFwd, displacementsBwd) {\n const tuples = utils.poseChain.map(([parentJoinName, childJoinName]) => ([utils.partIds[parentJoinName], utils.partIds[childJoinName]]));\n const edgesFwd = tuples.map(([, childJointId]) => childJointId);\n const edgesBwd = tuples.map(([parentJointId]) => parentJointId);\n const numParts = scores.shape[2]; // [21,21,17]\n const numEdges = edgesFwd.length;\n const keypoints = new Array(numParts);\n // Start a new detection instance at the position of the root.\n const rootPoint = utils.getImageCoords(root.part, outputStride, offsets);\n keypoints[root.part.id] = {\n score: root.score,\n part: utils.partNames[root.part.id] as BodyLandmark,\n position: rootPoint,\n };\n // Decode the part positions upwards in the tree, following the backward displacements.\n for (let edge = numEdges - 1; edge >= 0; --edge) {\n const sourceId = edgesFwd[edge];\n const targetId = edgesBwd[edge];\n if (keypoints[sourceId] && !keypoints[targetId]) {\n keypoints[targetId] = traverse(edge, keypoints[sourceId], targetId, scores, offsets, displacementsBwd);\n }\n }\n // Decode the part positions downwards in the tree, following the forward displacements.\n for (let edge = 0; edge < numEdges; ++edge) {\n const sourceId = edgesBwd[edge];\n const targetId = edgesFwd[edge];\n if (keypoints[sourceId] && !keypoints[targetId]) {\n keypoints[targetId] = traverse(edge, keypoints[sourceId], targetId, scores, offsets, displacementsFwd);\n }\n }\n return keypoints;\n}\n\nfunction scoreIsMaximumInLocalWindow(keypointId, score: number, heatmapY: number, heatmapX: number, scores) {\n const [height, width]: [number, number] = scores.shape;\n let localMaximum = true;\n const yStart = Math.max(heatmapY - localMaximumRadius, 0);\n const yEnd = Math.min(heatmapY + localMaximumRadius + 1, height);\n for (let yCurrent = yStart; yCurrent < yEnd; ++yCurrent) {\n const xStart = Math.max(heatmapX - localMaximumRadius, 0);\n const xEnd = Math.min(heatmapX + localMaximumRadius + 1, width);\n for (let xCurrent = xStart; xCurrent < xEnd; ++xCurrent) {\n if (scores.get(yCurrent, xCurrent, keypointId) > score) {\n localMaximum = false;\n break;\n }\n }\n if (!localMaximum) break;\n }\n return localMaximum;\n}\n\nexport function buildPartWithScoreQueue(minConfidence, scores) {\n const [height, width, numKeypoints] = scores.shape;\n const queue = new utils.MaxHeap(height * width * numKeypoints, ({ score }) => score);\n for (let heatmapY = 0; heatmapY < height; ++heatmapY) {\n for (let heatmapX = 0; heatmapX < width; ++heatmapX) {\n for (let keypointId = 0; keypointId < numKeypoints; ++keypointId) {\n const score = scores.get(heatmapY, heatmapX, keypointId);\n // Only consider parts with score greater or equal to threshold as root candidates.\n if (score < minConfidence) continue;\n // Only consider keypoints whose score is maximum in a local window.\n if (scoreIsMaximumInLocalWindow(keypointId, score, heatmapY, heatmapX, scores)) queue.enqueue({ score, part: { heatmapY, heatmapX, id: keypointId } });\n }\n }\n }\n return queue;\n}\n\nfunction withinRadius(poses, { x, y }, keypointId) {\n return poses.some(({ keypoints }) => {\n const correspondingKeypoint = keypoints[keypointId]?.position;\n if (!correspondingKeypoint) return false;\n return utils.squaredDistance(y, x, correspondingKeypoint.y, correspondingKeypoint.x) <= squaredNmsRadius;\n });\n}\n\nfunction getInstanceScore(existingPoses, keypoints) {\n const notOverlappedKeypointScores = keypoints.reduce((result, { position, score }, keypointId) => {\n if (!withinRadius(existingPoses, position, keypointId)) result += score;\n return result;\n }, 0.0);\n return notOverlappedKeypointScores / keypoints.length;\n}\n\nexport function decode(offsets, scores, displacementsFwd, displacementsBwd, maxDetected, minConfidence) {\n const poses: { keypoints, box: Box, score: number }[] = [];\n const queue = buildPartWithScoreQueue(minConfidence, scores);\n // Generate at most maxDetected object instances per image in decreasing root part score order.\n while (poses.length < maxDetected && !queue.empty()) {\n // The top element in the queue is the next root candidate.\n const root = queue.dequeue();\n // Part-based non-maximum suppression: We reject a root candidate if it is within a disk of `nmsRadius` pixels from the corresponding part of a previously detected instance.\n // @ts-ignore this one is tree walk\n const rootImageCoords = utils.getImageCoords(root.part, outputStride, offsets);\n // @ts-ignore this one is tree walk\n if (withinRadius(poses, rootImageCoords, root.part.id)) continue;\n // Else start a new detection instance at the position of the root.\n let keypoints = decodePose(root, scores, offsets, displacementsFwd, displacementsBwd);\n keypoints = keypoints.filter((a) => a.score > minConfidence);\n const score = getInstanceScore(poses, keypoints);\n const box = utils.getBoundingBox(keypoints);\n if (score > minConfidence) poses.push({ keypoints, box, score: Math.round(100 * score) / 100 });\n }\n return poses;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n /** posenet is mostly obsolete\n * caching is not implemented\n */\n if (!model?.['executor']) return [];\n const res = tf.tidy(() => {\n if (!model.inputs[0].shape) return [];\n const resized = tf.image.resizeBilinear(input, [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n const normalized = tf.sub(tf.div(tf.cast(resized, 'float32'), 127.5), 1.0);\n const results: Tensor[] = model.execute(normalized, poseNetOutputs) as Tensor[];\n const results3d = results.map((y) => tf.squeeze(y, [0]));\n results3d[1] = tf.sigmoid(results3d[1]); // apply sigmoid on scores\n return results3d;\n });\n\n const buffers = await Promise.all(res.map((tensor: Tensor) => tensor.buffer()));\n for (const t of res) tf.dispose(t);\n\n const decoded = decode(buffers[0], buffers[1], buffers[2], buffers[3], config.body.maxDetected, config.body.minConfidence);\n if (!model.inputs[0].shape) return [];\n const scaled = utils.scalePoses(decoded, [input.shape[1], input.shape[2]], [model.inputs[0].shape[2], model.inputs[0].shape[1]]);\n return scaled;\n}\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.body.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n", "/**\n * Image segmentation for body detection model\n *\n * Based on:\n * - [**Robust Video Matting**](https://github.com/PeterL1n/RobustVideoMatting)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\n\n// internal state varaibles\nconst outputNodes = ['fgr', 'pha', 'r1o', 'r2o', 'r3o', 'r4o'];\nconst t: Record = {}; // contains input tensor and recurrent states\nlet ratio = 0;\n\nfunction init(config: Config) {\n tf.dispose([t.r1i, t.r2i, t.r3i, t.r4i, t.downsample_ratio]);\n t.r1i = tf.tensor(0.0);\n t.r2i = tf.tensor(0.0);\n t.r3i = tf.tensor(0.0);\n t.r4i = tf.tensor(0.0);\n ratio = config.segmentation.ratio || 0.5;\n t.downsample_ratio = tf.tensor(ratio); // initialize downsample ratio\n}\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.segmentation.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n init(config);\n return model;\n}\n\nconst normalize = (r: Tensor): Tensor => tf.tidy(() => {\n const squeeze = tf.squeeze(r, ([0]));\n const mul = tf.mul(squeeze, constants.tf255);\n const cast = tf.cast(mul, 'int32');\n return cast;\n});\n\nfunction getRGBA(fgr: Tensor | null, pha: Tensor | null): Tensor { // gets rgba // either fgr or pha must be present\n const rgb = fgr\n ? normalize(fgr) // normalize and use value\n : tf.fill([pha!.shape[1] || 0, pha!.shape[2] || 0, 3], 255, 'int32'); // eslint-disable-line @typescript-eslint/no-non-null-assertion\n const a = pha\n ? normalize(pha) // normalize and use value\n : tf.fill([fgr!.shape[1] || 0, fgr!.shape[2] || 0, 1], 255, 'int32'); // eslint-disable-line @typescript-eslint/no-non-null-assertion\n const rgba = tf.concat([rgb, a], -1);\n tf.dispose([rgb, a]);\n return rgba;\n}\n\nfunction getState(state: Tensor): Tensor { // gets internal recurrent states\n return tf.tidy(() => {\n const r: Record = {};\n r.unstack = tf.unstack(state, -1);\n r.concat = tf.concat(r.unstack, 1);\n r.split = tf.split(r.concat, 4, 1);\n r.stack = tf.concat(r.split, 2);\n r.squeeze = tf.squeeze(r.stack, [0]);\n r.expand = tf.expandDims(r.squeeze, -1);\n r.add = tf.add(r.expand, 1);\n r.mul = tf.mul(r.add, 127.5);\n r.cast = tf.cast(r.mul, 'int32');\n r.tile = tf.tile(r.cast, [1, 1, 3]);\n r.alpha = tf.fill([(r.tile as Tensor).shape[0] || 0, (r.tile as Tensor).shape[1] || 0, 1], 255, 'int32'); // eslint-disable-line @typescript-eslint/no-unnecessary-type-assertion\n return tf.concat([r.tile, r.alpha], -1);\n });\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model) model = await load(config);\n if (!model?.['executor']) return null;\n // const expand = tf.expandDims(input, 0);\n t.src = tf.div(input, 255);\n if (ratio !== config.segmentation.ratio) init(config); // reinitialize recurrent states if requested downsample ratio changed\n const [fgr, pha, r1o, r2o, r3o, r4o] = await model.executeAsync(t, outputNodes) as Tensor[]; // execute model\n let rgba: Tensor;\n switch (config.segmentation.mode || 'default') {\n case 'default':\n rgba = getRGBA(fgr, pha);\n break;\n case 'alpha':\n rgba = getRGBA(null, pha);\n break;\n case 'foreground':\n rgba = getRGBA(fgr, null);\n break;\n case 'state':\n rgba = getState(r1o); // can view any internal recurrent state r10, r20, r3o, r4o\n break;\n default:\n rgba = tf.tensor(0);\n }\n tf.dispose([t.src, fgr, pha, t.r1i, t.r2i, t.r3i, t.r4i]);\n [t.r1i, t.r2i, t.r3i, t.r4i] = [r1o, r2o, r3o, r4o]; // update recurrent states\n return rgba;\n}\n", "/**\n * Image segmentation for body detection model\n *\n * Based on:\n * - [**MediaPipe Selfie**](https://drive.google.com/file/d/1dCfozqknMa068vVsO2j_1FgZkW_e3VWv/preview)\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log } from '../util/util';\nimport { loadModel } from '../tfjs/load';\nimport { constants } from '../tfjs/constants';\nimport type { GraphModel, Tensor, Tensor4D } from '../tfjs/types';\nimport type { Config } from '../config';\nimport { env } from '../util/env';\n\nlet model: GraphModel;\n\nexport async function load(config: Config): Promise {\n if (!model || env.initial) model = await loadModel(config.segmentation.modelPath);\n else if (config.debug) log('cached model:', model['modelUrl']);\n return model;\n}\n\nexport async function predict(input: Tensor4D, config: Config): Promise {\n if (!model) model = await load(config);\n if (!model?.['executor'] || !model?.inputs?.[0].shape) return null; // something is wrong with the model\n const t: Record = {};\n t.resize = tf.image.resizeBilinear(input, [model.inputs[0].shape ? model.inputs[0].shape[1] : 0, model.inputs[0].shape ? model.inputs[0].shape[2] : 0], false);\n t.norm = tf.div(t.resize, constants.tf255);\n t.res = model.execute(t.norm) as Tensor;\n t.squeeze = tf.squeeze(t.res, [0]); // meet.shape:[1,256,256,1], selfie.shape:[1,144,256,2]\n t.alpha = tf.image.resizeBilinear(t.squeeze as Tensor4D, [input.shape[1] || 0, input.shape[2] || 0]); // model selfie has a single channel that we can use directly\n t.mul = tf.mul(t.alpha, constants.tf255);\n let rgba: Tensor;\n switch (config.segmentation.mode || 'default') {\n case 'default':\n t.input = tf.squeeze(input);\n t.concat = tf.concat([t.input, t.mul], -1);\n rgba = tf.cast(t.concat, 'int32'); // combined original with alpha\n break;\n case 'alpha':\n rgba = tf.cast(t.mul, 'int32'); // just get alpha value from model\n break;\n default:\n rgba = tf.tensor(0);\n }\n Object.keys(t).forEach((tensor) => tf.dispose(t[tensor]));\n return rgba;\n}\n", "/**\n * Analyze detection Results and sort&combine them into per-person view\n */\n\nimport type { FaceResult, BodyResult, HandResult, GestureResult, PersonResult, Box } from '../result';\n\nexport function join(faces: FaceResult[], bodies: BodyResult[], hands: HandResult[], gestures: GestureResult[], shape: number[] | undefined): PersonResult[] {\n let id = 0;\n const persons: PersonResult[] = [];\n for (const face of faces) { // person is defined primarily by face and then we append other objects as found\n const person: PersonResult = { id: id++, face, body: null, hands: { left: null, right: null }, gestures: [], box: [0, 0, 0, 0] };\n for (const body of bodies) {\n if (face.box[0] > body.box[0] // x within body\n && face.box[0] < body.box[0] + body.box[2]\n && face.box[1] + face.box[3] > body.box[1] // y within body\n && face.box[1] + face.box[3] < body.box[1] + body.box[3]) {\n person.body = body;\n }\n }\n if (person.body) { // only try to join hands if body is found\n for (const hand of hands) {\n if (hand.box[0] + hand.box[2] > person.body.box[0] // x within body for left hand\n && hand.box[0] + hand.box[2] < person.body.box[0] + person.body.box[2]\n && hand.box[1] + hand.box[3] > person.body.box[1] // x within body for left hand\n && hand.box[1] + hand.box[3] < person.body.box[1] + person.body.box[3]) {\n if (person.hands) person.hands.left = hand;\n }\n if (hand.box[0] < person.body.box[0] + person.body.box[2] // x within body for right hand\n && hand.box[0] > person.body.box[0]\n && hand.box[1] + hand.box[3] > person.body.box[1] // x within body for right hand\n && hand.box[1] + hand.box[3] < person.body.box[1] + person.body.box[3]) {\n if (person.hands) person.hands.right = hand;\n }\n }\n }\n for (const gesture of gestures) { // append all gestures according to ids\n if (gesture['face'] !== undefined && gesture['face'] === face.id) person.gestures.push(gesture);\n else if (gesture['iris'] !== undefined && gesture['iris'] === face.id) person.gestures.push(gesture);\n else if (gesture['body'] !== undefined && gesture['body'] === person.body?.id) person.gestures.push(gesture);\n else if (gesture['hand'] !== undefined && gesture['hand'] === person.hands.left?.id) person.gestures.push(gesture);\n else if (gesture['hand'] !== undefined && gesture['hand'] === person.hands.right?.id) person.gestures.push(gesture);\n }\n\n // create new overarching box from all boxes belonging to person\n const x: number[] = [];\n const y: number[] = [];\n const extractXY = (box: Box | undefined) => { // extract all [x, y] coordinates from boxes [x, y, width, height]\n if (box && box.length === 4) {\n x.push(box[0], box[0] + box[2]);\n y.push(box[1], box[1] + box[3]);\n }\n };\n extractXY(person.face.box);\n extractXY(person.body?.box);\n extractXY(person.hands.left?.box);\n extractXY(person.hands.right?.box);\n const minX = Math.min(...x);\n const minY = Math.min(...y);\n person.box = [minX, minY, Math.max(...x) - minX, Math.max(...y) - minY]; // create new overarching box\n\n // shape is known so we calculate boxRaw as well\n if (shape?.[1] && shape?.[2]) person.boxRaw = [person.box[0] / shape[2], person.box[1] / shape[1], person.box[2] / shape[2], person.box[3] / shape[1]];\n\n persons.push(person);\n }\n return persons;\n}\n", "/**\n * Embedded sample images used during warmup in dataURL format\n */\n\n// data:image/jpeg;base64,\nexport const face = `\n/9j/4AAQSkZJRgABAQEAYABgAAD/4QBoRXhpZgAATU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUA\nAAABAAAARgEoAAMAAAABAAIAAAExAAIAAAARAAAATgAAAAAAAABgAAAAAQAAAGAAAAABcGFpbnQu\nbmV0IDQuMi4xMwAA/9sAQwAGBAUGBQQGBgUGBwcGCAoQCgoJCQoUDg8MEBcUGBgXFBYWGh0lHxob\nIxwWFiAsICMmJykqKRkfLTAtKDAlKCko/9sAQwEHBwcKCAoTCgoTKBoWGigoKCgoKCgoKCgoKCgo\nKCgoKCgoKCgoKCgoKCgoKCgoKCgoKCgoKC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h4D7Xaq\nZnPrtNpqz35aRaYOHY9Zk4pNt9rR+rl6zi+OnS+WN57Rv1lXp/YrNaYtruL6zNPnGO3hxP6O5w/2\nf0HDuun09Yv55Le9afznqcOvO4tBreMTHu30unnva0bWt8on+70nDuE4OHYYx4Kbesz3tPrMuhGO\nIjpDOKrK9YVpsyiGUQnYGOyUgI2SlAIEmwMWMs9kTAMJYzDOYRMArmGErZhhMArlHmzmGMwDE3Ts\nbAbs4swj5pgFkSziVcM4BZEsolXDKAZwyhjCYBkACQhIAAAAAAAJAAAAAAAAAAAAAAAAAAAShIAA\nAAAAAAJAAAAAAAAAAAAAABAJEAAAAAAAAAAAAAAAIEoBKAAAAAAAAAAAAAAABAlAAAAAAAIAAAAA\nBAkBAkBAkBAlACEgMZjdjbFW8bWrEx8YWANb6Fp+bfwab+vLDKMFK9qxH5L0bAr8OPRPKz2AY7J2\nSbAjYZAI2E7AIEgIEgIEgMdkSy2NgY7MdlmyNoBXsxmFuyNgVTVjNV3KjlBRNTlXTVHKCrlIqt5T\nlBhEMohlFerLlBjEMohMVTEARDKCITsAk2AEgAAAkAAAAAAAAAAAAAAAAAAAAAAAASAAAAAAAAD/\n2Q==`;\n", "/**\n * Warmup algorithm that uses embedded images to exercise loaded models for faster future inference\n */\n\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now, mergeDeep } from './util/util';\nimport * as sample from './sample';\nimport * as image from './image/image';\nimport * as backend from './tfjs/backend';\nimport { env } from './util/env';\nimport { empty, Result } from './result';\nimport type { Config } from './config';\nimport type { Human } from './human';\nimport type { Tensor, DataType } from './tfjs/types';\n\nasync function warmupBitmap(instance: Human): Promise {\n const b64toBlob = (base64: string, type = 'application/octet-stream') => fetch(`data:${type};base64,${base64}`).then((res) => res.blob());\n let blob: Blob | null;\n let res: Result | undefined;\n switch (instance.config.warmup) {\n case 'face': blob = await b64toBlob(sample.face); break;\n case 'body':\n case 'full': blob = await b64toBlob(sample.body); break;\n default: blob = null;\n }\n if (blob) {\n const bitmap = await createImageBitmap(blob);\n res = await instance.detect(bitmap, instance.config);\n bitmap.close();\n }\n return res;\n}\n\nasync function warmupCanvas(instance: Human): Promise {\n return new Promise((resolve) => {\n let src: string;\n // let size = 0;\n switch (instance.config.warmup) {\n case 'face':\n // size = 256;\n src = 'data:image/jpeg;base64,' + sample.face;\n break;\n case 'full':\n case 'body':\n // size = 1200;\n src = 'data:image/jpeg;base64,' + sample.body;\n break;\n default:\n src = '';\n }\n // src = encodeURI('../assets/human-sample-upper.jpg');\n let img: HTMLImageElement;\n if (typeof Image !== 'undefined') img = new Image();\n // @ts-ignore env.image is an external monkey-patch\n else if (env.Image) img = new env.Image();\n else {\n resolve(undefined);\n return;\n }\n img.onload = async () => {\n const canvas = image.canvas(img.naturalWidth, img.naturalHeight);\n if (!canvas) {\n log('Warmup: Canvas not found');\n resolve(undefined);\n } else {\n const ctx = canvas.getContext('2d') as CanvasRenderingContext2D;\n if (ctx) ctx.drawImage(img, 0, 0);\n // const data = ctx?.getImageData(0, 0, canvas.height, canvas.width);\n const tensor = await instance.image(canvas, true);\n const res = tensor.tensor ? await instance.detect(tensor.tensor, instance.config) : undefined;\n resolve(res);\n }\n };\n if (src) img.src = src;\n else resolve(undefined);\n });\n}\n\nasync function warmupNode(instance: Human): Promise {\n const atob = (str: string) => Buffer.from(str, 'base64');\n let img;\n if (instance.config.warmup === 'face') img = atob(sample.face);\n else img = atob(sample.body);\n let res: Result;\n if (('node' in tf) && (tf.getBackend() === 'tensorflow')) {\n // @ts-ignore\n const data: Tensor = tf['node'].decodeJpeg(img); // eslint-disable-line import/namespace\n const expanded: Tensor = tf.expandDims(data, 0);\n instance.tf.dispose(data);\n // log('Input:', expanded);\n res = await instance.detect(expanded, instance.config);\n instance.tf.dispose(expanded);\n } else {\n if (instance.config.debug) log('Warmup tfjs-node not loaded');\n /*\n const input = await canvasJS.loadImage(img);\n const canvas = canvasJS.createCanvas(input.width, input.height);\n const ctx = canvas.getContext('2d');\n ctx.drawImage(img, 0, 0, input.width, input.height);\n res = await instance.detect(input, instance.config);\n */\n }\n // @ts-ignore\n return res;\n}\n\nasync function runInference(instance: Human) {\n let res: Result | undefined;\n if (typeof createImageBitmap === 'function') res = await warmupBitmap(instance);\n else if ((typeof Image !== 'undefined') || (env.Canvas !== undefined)) res = await warmupCanvas(instance);\n else res = await warmupNode(instance);\n return res;\n}\n\n/** Runs pre-compile on all loaded models */\nexport async function runCompile(instance: Human) {\n // @ts-ignore private property\n if (!tf.env().flagRegistry.ENGINE_COMPILE_ONLY) return; // tfjs does not support compile-only inference\n const backendType = tf.getBackend();\n const webGLBackend = tf.backend();\n if ((backendType !== 'webgl' && backendType !== 'humangl') || !webGLBackend?.['checkCompileCompletion']) {\n // log('compile pass: skip');\n return;\n }\n tf.env().set('ENGINE_COMPILE_ONLY', true);\n const numTensorsStart = tf.engine().state.numTensors;\n const compiledModels: string[] = [];\n for (const [modelName, model] of Object.entries(instance.models.models)) {\n if (!model) continue;\n const shape = (model?.modelSignature && model?.inputs?.[0]?.shape) ? [...model.inputs[0].shape] : [1, 64, 64, 3];\n const dtype: DataType = (model?.modelSignature && model?.inputs?.[0]?.dtype) ? model.inputs[0].dtype : 'float32';\n for (let dim = 0; dim < shape.length; dim++) {\n if (shape[dim] === -1) shape[dim] = dim === 0 ? 1 : 64; // override batch number and any dynamic dimensions\n }\n const tensor = tf.zeros(shape, dtype);\n try {\n const res = model.execute(tensor);\n compiledModels.push(modelName);\n if (Array.isArray(res)) res.forEach((t) => tf.dispose(t));\n else tf.dispose(res);\n } catch {\n if (instance.config.debug) log('compile fail model:', modelName);\n }\n tf.dispose(tensor);\n }\n const kernels = await webGLBackend['checkCompileCompletionAsync']();\n webGLBackend['getUniformLocations']();\n if (instance.config.debug) log('compile pass:', { models: compiledModels, kernels: kernels.length });\n tf.env().set('ENGINE_COMPILE_ONLY', false);\n const numTensorsEnd = tf.engine().state.numTensors;\n if ((numTensorsEnd - numTensorsStart) > 0) log('tensor leak:', numTensorsEnd - numTensorsStart);\n}\n\n/** Warmup method pre-initializes all configured models for faster inference\n * - can take significant time on startup\n * - only used in browser environments for `webgl` and `humangl` backends\n * @param userConfig?: Config\n*/\nexport async function warmup(instance: Human, userConfig?: Partial): Promise {\n await backend.check(instance, false);\n const t0 = now();\n instance.state = 'warmup';\n if (userConfig) instance.config = mergeDeep(instance.config, userConfig) as Config;\n if (!instance.config.warmup || instance.config.warmup.length === 0 || instance.config.warmup === 'none') {\n return empty();\n }\n return new Promise(async (resolve) => {\n await instance.models.load();\n await runCompile(instance);\n const res = await runInference(instance);\n const t1 = now();\n if (instance.config.debug) log('warmup', instance.config.warmup, Math.round(t1 - t0), 'ms');\n instance.emit('warmup');\n resolve(res);\n });\n}\n", "/**\n * Human main module\n * @default Human Library\n * @summary \n * @author \n * @copyright \n * @license MIT\n */\n\n// module imports\nimport * as tf from 'dist/tfjs.esm.js';\nimport { log, now, mergeDeep, validate } from './util/util';\nimport { defaults } from './config';\nimport { env, Env } from './util/env';\nimport { WebCam } from './util/webcam';\nimport { setModelLoadOptions } from './tfjs/load';\nimport * as app from '../package.json';\nimport * as backend from './tfjs/backend';\nimport * as draw from './draw/draw';\nimport * as blazepose from './body/blazepose';\nimport * as centernet from './object/centernet';\nimport * as efficientpose from './body/efficientpose';\nimport * as face from './face/face';\nimport * as facemesh from './face/facemesh';\nimport * as gesture from './gesture/gesture';\nimport * as handpose from './hand/handpose';\nimport * as handtrack from './hand/handtrack';\nimport * as image from './image/image';\nimport * as interpolate from './util/interpolate';\nimport * as meet from './segmentation/meet';\nimport * as match from './face/match';\nimport * as models from './models';\nimport * as movenet from './body/movenet';\nimport * as nanodet from './object/nanodet';\nimport * as persons from './util/persons';\nimport * as posenet from './body/posenet';\nimport * as rvm from './segmentation/rvm';\nimport * as selfie from './segmentation/selfie';\nimport * as warmups from './warmup';\n\n// type definitions\nimport { Input, Config, Result, FaceResult, HandResult, BodyResult, ObjectResult, GestureResult, AnyCanvas, empty } from './exports';\nimport type { Tensor, Tensor4D } from './tfjs/types';\n// type exports\nexport * from './exports';\n\n/** **Human** library main class\n *\n * All methods and properties are available only as members of Human class\n *\n * - Configuration object definition: {@link Config}\n * - Results object definition: {@link Result}\n * - Possible inputs: {@link Input}\n *\n * @param userConfig - {@link Config}\n * @returns instance of {@link Human}\n */\nexport class Human {\n /** Current version of Human library in *semver* format */\n version: string;\n\n /** Current configuration\n * - Defaults: [config](https://github.com/vladmandic/human/blob/main/src/config.ts#L262)\n */\n config: Config;\n\n /** Last known result of detect run\n * - Can be accessed anytime after initial detection\n */\n result: Result;\n\n /** Current state of Human library\n * - Can be polled to determine operations that are currently executed\n * - Progresses through: 'config', 'check', 'backend', 'load', 'run:', 'idle'\n */\n state: string;\n\n /** currenty processed image tensor and canvas */\n process: { tensor: Tensor | null, canvas: AnyCanvas | null };\n\n /** Instance of TensorFlow/JS used by Human\n * - Can be embedded or externally provided\n * [TFJS API](https://js.tensorflow.org/api/latest/)\n */\n tf;\n\n /** Object containing environment information used for diagnostics */\n env: Env = env;\n\n /** Draw helper classes that can draw detected objects on canvas using specified draw\n * - canvas: draws input to canvas\n * - options: are global settings for all draw operations, can be overriden for each draw method {@link DrawOptions}\n * - face, body, hand, gesture, object, person: draws detected results as overlays on canvas\n */\n // draw: { canvas: typeof draw.canvas, face: typeof draw.face, body: typeof draw.body, hand: typeof draw.hand, gesture: typeof draw.gesture, object: typeof draw.object, person: typeof draw.person, all: typeof draw.all, options: DrawOptions };\n draw: typeof draw = draw;\n\n /** Face Matching\n * - similarity: compare two face descriptors and return similarity index\n * - distance: compare two face descriptors and return raw calculated differences\n * - find: compare face descriptor to array of face descriptors and return best match\n */\n match: typeof match = match;\n\n /** Currently loaded models\n * @internal\n * {@link models#Models}\n */\n models: models.Models;\n\n /** Container for events dispatched by Human\n * Possible events:\n * - `create`: triggered when Human object is instantiated\n * - `load`: triggered when models are loaded (explicitly or on-demand)\n * - `image`: triggered when input image is processed\n * - `result`: triggered when detection is complete\n * - `warmup`: triggered when warmup is complete\n * - `error`: triggered on some errors\n */\n events: EventTarget | undefined;\n /** Reference face triangualtion array of 468 points, used for triangle references between points */\n faceTriangulation: number[];\n /** Refernce UV map of 468 values, used for 3D mapping of the face mesh */\n faceUVMap: [number, number][];\n /** Performance object that contains values for all recently performed operations */\n performance: Record; // perf members are dynamically defined as needed\n #numTensors: number;\n #analyzeMemoryLeaks: boolean;\n #checkSanity: boolean;\n // definition end\n\n /** Constructor for **Human** library that is futher used for all operations\n * @param userConfig - user configuration object {@link Config}\n */\n constructor(userConfig?: Partial) {\n /*\n defaults.wasmPath = tf.version['tfjs-core'].includes('-') // custom build or official build\n ? 'https://vladmandic.github.io/tfjs/dist/'\n : `https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@${tf.version_core}/dist/`;\n */\n const tfVersion = (tf.version.tfjs || tf.version_core).replace(/-(.*)/, '');\n defaults.wasmPath = `https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@${tfVersion}/dist/`;\n defaults.modelBasePath = env.browser ? '../models/' : 'file://models/';\n this.version = app.version; // expose version property on instance of class\n Object.defineProperty(this, 'version', { value: app.version }); // expose version property directly on class itself\n this.config = JSON.parse(JSON.stringify(defaults));\n Object.seal(this.config);\n this.config.cacheModels = typeof indexedDB !== 'undefined';\n if (userConfig) this.config = mergeDeep(this.config, userConfig);\n setModelLoadOptions(this.config);\n this.tf = tf;\n this.state = 'idle';\n this.#numTensors = 0;\n this.#analyzeMemoryLeaks = false;\n this.#checkSanity = false;\n this.performance = {};\n this.events = (typeof EventTarget !== 'undefined') ? new EventTarget() : undefined;\n // object that contains all initialized models\n this.models = new models.Models(this);\n // reexport draw methods\n draw.init();\n this.result = empty();\n // export access to image processing\n this.process = { tensor: null, canvas: null };\n // export raw access to underlying models\n this.faceTriangulation = facemesh.triangulation;\n this.faceUVMap = facemesh.uvmap;\n // init model validation\n models.validateModel(this, null, '');\n // include platform info\n this.emit('create');\n if (this.config.debug || this.env.browser) log(`version: ${this.version}`);\n if (this.config.debug) log(`tfjs version: ${this.tf.version['tfjs-core']}`);\n const envTemp = JSON.parse(JSON.stringify(this.env));\n delete envTemp.kernels;\n delete envTemp.initial;\n delete envTemp.perfadd;\n if (this.config.debug) log('environment:', envTemp);\n }\n\n /** internal function to measure tensor leaks */\n analyze = (...msg: string[]) => {\n if (!this.#analyzeMemoryLeaks) return;\n const currentTensors = this.tf.engine().state.numTensors;\n const previousTensors = this.#numTensors;\n this.#numTensors = currentTensors;\n const leaked = currentTensors - previousTensors;\n if (leaked !== 0) log(...msg, leaked);\n };\n\n /** internal function for quick sanity check on inputs @hidden */\n #sanity = (input: Input): null | string => {\n if (!this.#checkSanity) return null;\n if (!input) return 'input is not defined';\n if (this.env.node && !(input instanceof tf.Tensor)) return 'input must be a tensor';\n try {\n this.tf.getBackend();\n } catch {\n return 'backend not loaded';\n }\n return null;\n };\n\n /** Reset configuration to default values */\n reset(): void {\n const currentBackend = this.config.backend; // save backend;\n this.config = JSON.parse(JSON.stringify(defaults));\n this.config.backend = currentBackend;\n image.reset();\n env.initial = true;\n }\n\n /** Validate current configuration schema */\n validate(userConfig?: Partial) {\n const msgs = validate(defaults, userConfig || this.config);\n if (msgs.length === 0) this.config = mergeDeep(this.config, userConfig) as Config;\n return msgs;\n }\n\n /** Utility wrapper for performance.now() */\n now(): number { // eslint-disable-line class-methods-use-this\n return now();\n }\n\n /** Process input as return canvas and tensor\n *\n * @param input - any input {@link Input}\n * @param getTensor - should image processing also return tensor or just canvas\n * Returns object with `tensor` and `canvas`\n */\n image(input: Input, getTensor: boolean = false) {\n return image.process(input, this.config, getTensor);\n }\n\n /** Segmentation method takes any input and returns RGBA tensor\n * Note: Segmentation is not triggered as part of detect process\n *\n * @param input - {@link Input}\n * Returns tensor which contains image data in RGBA format\n */\n async segmentation(input: Input, userConfig?: Partial): Promise {\n if (userConfig) this.config = mergeDeep(this.config, userConfig) as Config;\n if (!this.config.segmentation.enabled) return null;\n const processed = await image.process(input, this.config);\n if (!processed.tensor) return null;\n let tensor: Tensor | null = null;\n if (this.config.segmentation.modelPath?.includes('rvm')) tensor = await rvm.predict(processed.tensor, this.config);\n if (this.config.segmentation.modelPath?.includes('meet')) tensor = await meet.predict(processed.tensor, this.config);\n if (this.config.segmentation.modelPath?.includes('selfie')) tensor = await selfie.predict(processed.tensor, this.config);\n tf.dispose(processed.tensor);\n return tensor;\n }\n\n /** Compare two input tensors for pixel similarity\n * - use `human.image` to process any valid input and get a tensor that can be used for compare\n * - when passing manually generated tensors:\n * - both input tensors must be in format [1, height, width, 3]\n * - if resolution of tensors does not match, second tensor will be resized to match resolution of the first tensor\n * - return value is pixel similarity score normalized by input resolution and rgb channels\n */\n compare(firstImageTensor: Tensor, secondImageTensor: Tensor): Promise {\n return image.compare(this.config, firstImageTensor, secondImageTensor);\n }\n\n /** Explicit backend initialization\n * - Normally done implicitly during initial load phase\n * - Call to explictly register and initialize TFJS backend without any other operations\n * - Use when changing backend during runtime\n */\n async init(): Promise {\n await backend.check(this, true);\n await this.tf.ready();\n image.reset();\n }\n\n /** WebCam helper methods\n *\n */\n public webcam = new WebCam();\n\n /** Load method preloads all configured models on-demand\n * - Not explicitly required as any required model is load implicitly on it's first run\n *\n * @param userConfig - {@link Config}\n */\n async load(userConfig?: Partial): Promise {\n this.state = 'load';\n const timeStamp = now();\n const count = Object.values(this.models.models).filter((model) => model).length;\n if (userConfig) this.config = mergeDeep(this.config, userConfig) as Config;\n if (this.env.initial) { // print version info on first run and check for correct backend setup\n if (!await backend.check(this, false)) log('error: backend check failed');\n await tf.ready();\n if (this.env.browser) {\n if (this.config.debug) log('configuration:', this.config);\n if (this.config.debug) log('tf flags:', this.tf.ENV.flags);\n }\n }\n\n await this.models.load(this); // actually loads models\n if (this.env.initial && this.config.debug) log('tf engine state:', this.tf.engine().state.numBytes, 'bytes', this.tf.engine().state.numTensors, 'tensors'); // print memory stats on first run\n this.env.initial = false;\n\n const loaded = Object.values(this.models.models).filter((model) => model).length;\n if (loaded !== count) { // number of loaded models changed\n this.models.validate(); // validate kernel ops used by model against current backend\n this.emit('load');\n }\n\n const current = Math.trunc(now() - timeStamp);\n if (current > (this.performance.loadModels || 0)) this.performance.loadModels = this.env.perfadd ? (this.performance.loadModels || 0) + current : current;\n }\n\n /** emit event */\n emit = (event: string) => {\n if (this.events?.dispatchEvent) this.events.dispatchEvent(new Event(event));\n };\n\n /** Runs interpolation using last known result and returns smoothened result\n * Interpolation is based on time since last known result so can be called independently\n *\n * @param result - {@link Result} optional use specific result set to run interpolation on\n * @returns result - {@link Result}\n */\n next(result: Result = this.result): Result {\n return interpolate.calc(result, this.config);\n }\n\n /** Warmup method pre-initializes all configured models for faster inference\n * - can take significant time on startup\n * - only used for `webgl` and `humangl` backends\n * @param userConfig - {@link Config}\n * @returns result - {@link Result}\n */\n async warmup(userConfig?: Partial) {\n const t0 = now();\n const res = await warmups.warmup(this, userConfig);\n const t1 = now();\n this.performance.warmup = Math.trunc(t1 - t0);\n return res;\n }\n\n /** Run detect with tensorflow profiling\n * - result object will contain total exeuction time information for top-20 kernels\n * - actual detection object can be accessed via `human.result`\n */\n async profile(input: Input, userConfig?: Partial): Promise<{ kernel: string, time: number, perc: number }[]> {\n // @ts-ignore profile wraps method return values\n const profile = await this.tf.profile(() => this.detect(input, userConfig));\n const kernels: Record = {};\n let total = 0;\n for (const kernel of profile.kernels) { // sum kernel time values per kernel\n const ms = Number(kernel.kernelTimeMs) || 0;\n if (kernels[kernel.name]) kernels[kernel.name] += ms;\n else kernels[kernel.name] = ms;\n total += ms;\n }\n const kernelArr: { kernel: string, time: number, perc: number }[] = [];\n Object.entries(kernels).forEach((key) => kernelArr.push({ kernel: key[0], time: key[1] as unknown as number, perc: 0 })); // convert to array\n for (const kernel of kernelArr) {\n kernel.perc = Math.round(1000 * kernel.time / total) / 1000;\n kernel.time = Math.round(1000 * kernel.time) / 1000;\n }\n kernelArr.sort((a, b) => b.time - a.time); // sort\n kernelArr.length = 20; // crop\n return kernelArr;\n }\n\n /** Main detection method\n * - Analyze configuration: {@link Config}\n * - Pre-process input: {@link Input}\n * - Run inference for all configured models\n * - Process and return result: {@link Result}\n *\n * @param input - {@link Input}\n * @param userConfig - {@link Config}\n * @returns result - {@link Result}\n */\n async detect(input: Input, userConfig?: Partial): Promise {\n // detection happens inside a promise\n this.state = 'detect';\n return new Promise(async (resolve) => {\n this.state = 'config';\n let timeStamp;\n\n // update configuration\n this.config = mergeDeep(this.config, userConfig) as Config;\n\n // sanity checks\n this.state = 'check';\n const error = this.#sanity(input);\n if (error) {\n log(error, input);\n this.emit('error');\n resolve(empty(error));\n }\n\n const timeStart = now();\n\n // load models if enabled\n await this.load();\n\n timeStamp = now();\n this.state = 'image';\n const img = await image.process(input, this.config) as { canvas: AnyCanvas, tensor: Tensor4D };\n this.process = img;\n this.performance.inputProcess = this.env.perfadd ? (this.performance.inputProcess || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n this.analyze('Get Image:');\n\n if (!img.tensor) {\n if (this.config.debug) log('could not convert input to tensor');\n this.emit('error');\n resolve(empty('could not convert input to tensor'));\n return;\n }\n this.emit('image');\n\n timeStamp = now();\n this.config.skipAllowed = await image.skip(this.config, img.tensor);\n this.config.filter.autoBrightness = (this.config.filter.autoBrightness || false) && this.config.skipAllowed; // disable autoBrightness on scene change\n if (!this.performance.totalFrames) this.performance.totalFrames = 0;\n if (!this.performance.cachedFrames) this.performance.cachedFrames = 0;\n (this.performance.totalFrames)++;\n if (this.config.skipAllowed) this.performance.cachedFrames++;\n this.performance.cacheCheck = this.env.perfadd ? (this.performance.cacheCheck || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n this.analyze('Check Changed:');\n\n // prepare where to store model results\n // keep them with weak typing as it can be promise or not\n let faceRes: FaceResult[] | Promise | never[] = [];\n let bodyRes: BodyResult[] | Promise | never[] = [];\n let handRes: HandResult[] | Promise | never[] = [];\n let objectRes: ObjectResult[] | Promise | never[] = [];\n\n // run face detection followed by all models that rely on face bounding box: face mesh, age, gender, emotion\n this.state = 'detect:face';\n if (this.config.async) {\n faceRes = this.config.face.enabled ? face.detectFace(this, img.tensor) : [];\n if (this.performance.face) delete this.performance.face;\n } else {\n timeStamp = now();\n faceRes = this.config.face.enabled ? await face.detectFace(this, img.tensor) : [];\n this.performance.face = this.env.perfadd ? (this.performance.face || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n\n if (this.config.async && (this.config.body.maxDetected === -1 || this.config.hand.maxDetected === -1)) faceRes = await faceRes; // need face result for auto-detect number of hands or bodies\n\n // run body: can be posenet, blazepose, efficientpose, movenet\n this.analyze('Start Body:');\n this.state = 'detect:body';\n const bodyConfig = this.config.body.maxDetected === -1 ? mergeDeep(this.config, { body: { maxDetected: this.config.face.enabled ? 1 * (faceRes as FaceResult[]).length : 1 } }) : this.config; // autodetect number of bodies\n if (this.config.async) {\n if (this.config.body.modelPath?.includes('posenet')) bodyRes = this.config.body.enabled ? posenet.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('blazepose')) bodyRes = this.config.body.enabled ? blazepose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('efficientpose')) bodyRes = this.config.body.enabled ? efficientpose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('movenet')) bodyRes = this.config.body.enabled ? movenet.predict(img.tensor, bodyConfig) : [];\n if (this.performance.body) delete this.performance.body;\n } else {\n timeStamp = now();\n if (this.config.body.modelPath?.includes('posenet')) bodyRes = this.config.body.enabled ? await posenet.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('blazepose')) bodyRes = this.config.body.enabled ? await blazepose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('efficientpose')) bodyRes = this.config.body.enabled ? await efficientpose.predict(img.tensor, bodyConfig) : [];\n else if (this.config.body.modelPath?.includes('movenet')) bodyRes = this.config.body.enabled ? await movenet.predict(img.tensor, bodyConfig) : [];\n this.performance.body = this.env.perfadd ? (this.performance.body || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n this.analyze('End Body:');\n\n // run handpose\n this.analyze('Start Hand:');\n this.state = 'detect:hand';\n const handConfig = this.config.hand.maxDetected === -1 ? mergeDeep(this.config, { hand: { maxDetected: this.config.face.enabled ? 2 * (faceRes as FaceResult[]).length : 1 } }) : this.config; // autodetect number of hands\n if (this.config.async) {\n if (this.config.hand.detector?.modelPath?.includes('handdetect')) handRes = this.config.hand.enabled ? handpose.predict(img.tensor, handConfig) : [];\n else if (this.config.hand.detector?.modelPath?.includes('handtrack')) handRes = this.config.hand.enabled ? handtrack.predict(img.tensor, handConfig) : [];\n if (this.performance.hand) delete this.performance.hand;\n } else {\n timeStamp = now();\n if (this.config.hand.detector?.modelPath?.includes('handdetect')) handRes = this.config.hand.enabled ? await handpose.predict(img.tensor, handConfig) : [];\n else if (this.config.hand.detector?.modelPath?.includes('handtrack')) handRes = this.config.hand.enabled ? await handtrack.predict(img.tensor, handConfig) : [];\n this.performance.hand = this.env.perfadd ? (this.performance.hand || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n this.analyze('End Hand:');\n\n // run object detection\n this.analyze('Start Object:');\n this.state = 'detect:object';\n if (this.config.async) {\n if (this.config.object.modelPath?.includes('nanodet')) objectRes = this.config.object.enabled ? nanodet.predict(img.tensor, this.config) : [];\n else if (this.config.object.modelPath?.includes('centernet')) objectRes = this.config.object.enabled ? centernet.predict(img.tensor, this.config) : [];\n if (this.performance.object) delete this.performance.object;\n } else {\n timeStamp = now();\n if (this.config.object.modelPath?.includes('nanodet')) objectRes = this.config.object.enabled ? await nanodet.predict(img.tensor, this.config) : [];\n else if (this.config.object.modelPath?.includes('centernet')) objectRes = this.config.object.enabled ? await centernet.predict(img.tensor, this.config) : [];\n this.performance.object = this.env.perfadd ? (this.performance.object || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n }\n this.analyze('End Object:');\n\n // if async wait for results\n this.state = 'detect:await';\n if (this.config.async) [faceRes, bodyRes, handRes, objectRes] = await Promise.all([faceRes, bodyRes, handRes, objectRes]);\n\n // run gesture analysis last\n this.state = 'detect:gesture';\n let gestureRes: GestureResult[] = [];\n if (this.config.gesture.enabled) {\n timeStamp = now();\n gestureRes = [...gesture.face(faceRes as FaceResult[]), ...gesture.body(bodyRes as BodyResult[]), ...gesture.hand(handRes as HandResult[]), ...gesture.iris(faceRes as FaceResult[])];\n if (!this.config.async) this.performance.gesture = this.env.perfadd ? (this.performance.gesture || 0) + Math.trunc(now() - timeStamp) : Math.trunc(now() - timeStamp);\n else if (this.performance.gesture) delete this.performance.gesture;\n }\n\n this.performance.total = this.env.perfadd ? (this.performance.total || 0) + Math.trunc(now() - timeStart) : Math.trunc(now() - timeStart);\n const shape = this.process.tensor?.shape || [0, 0, 0, 0];\n this.result = {\n face: faceRes as FaceResult[],\n body: bodyRes as BodyResult[],\n hand: handRes as HandResult[],\n gesture: gestureRes,\n object: objectRes as ObjectResult[],\n performance: this.performance,\n canvas: this.process.canvas,\n timestamp: Date.now(),\n error: null,\n width: shape[2],\n height: shape[1],\n get persons() { return persons.join(faceRes as FaceResult[], bodyRes as BodyResult[], handRes as HandResult[], gestureRes, shape); },\n };\n\n // finally dispose input tensor\n tf.dispose(img.tensor);\n\n // log('Result:', result);\n this.emit('detect');\n this.state = 'idle';\n resolve(this.result);\n });\n }\n\n /** Helper function\n * @param ms - sleep time in miliseconds\n */\n async sleep(ms: number): Promise { // eslint-disable-line class-methods-use-this\n return new Promise((resolve) => { setTimeout(resolve, ms); });\n }\n\n /** internal structure that keeps track of processed videos @hidden */\n #loops: Record = {};\n /** Continously detect video frames\n * @param element - HTMLVideoElement input\n * @param run - boolean run continously or stop if already running, default true\n * @param delay - number delay detection between frames for number of miliseconds, default 0\n */\n async video(element: HTMLVideoElement, run: boolean = true, delay: number = 0) {\n if (run) {\n if (!this.#loops[element.id]) {\n if (this.config.debug) log('video start', element.id);\n this.#loops[element.id] = true;\n }\n if (!element.paused && this.#loops[element.id] && (element.readyState >= 2)) await this.detect(element);\n if (delay > 0) await this.sleep(delay);\n if (this.#loops[element.id]) requestAnimationFrame(() => this.video(element, run, delay));\n } else {\n if (this.config.debug) log('video stop', element.id);\n this.#loops[element.id] = false;\n }\n }\n}\n\n/** Class Human as default export */\n/* eslint no-restricted-exports: [\"off\", { \"restrictedNamedExports\": [\"default\"] }] */\nexport { Human as default, match, draw, models };\n"], "mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA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AA,QACd,QAAQ,MAAM,CAAC;AAAA,QACf,IAAI,UAAU;AAAE,iBAAeK,MAAK,SAAyB,SAAyB,SAAyB,YAAY,KAAK;AAAA,QAAG;AAAA,MACrI;AAGA,MAAG,GAAQ,IAAI,MAAM;AAGrB,WAAK,KAAK,QAAQ;AAClB,WAAK,QAAQ;AACb,cAAQ,KAAK,MAAM;AAAA,IACrB,CAAC;AAAA,EACH;AAAA;AAAA;AAAA;AAAA,EAKA,MAAM,MAAMjB,KAA2B;AACrC,WAAO,IAAI,QAAQ,CAAC,YAAY;AAAE,iBAAW,SAASA,GAAE;AAAA,IAAG,CAAC;AAAA,EAC9D;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EASA,MAAM,MAAM,SAA2B,MAAe,MAAM,QAAgB,GAAG;AAC7E,QAAI,KAAK;AACP,UAAI,CAAC,mBAAK,QAAO,QAAQ,EAAE,GAAG;AAC5B,YAAI,KAAK,OAAO;AAAO,cAAI,eAAe,QAAQ,EAAE;AACpD,2BAAK,QAAO,QAAQ,EAAE,IAAI;AAAA,MAC5B;AACA,UAAI,CAAC,QAAQ,UAAU,mBAAK,QAAO,QAAQ,EAAE,KAAM,QAAQ,cAAc;AAAI,cAAM,KAAK,OAAO,OAAO;AACtG,UAAI,QAAQ;AAAG,cAAM,KAAK,MAAM,KAAK;AACrC,UAAI,mBAAK,QAAO,QAAQ,EAAE;AAAG,8BAAsB,MAAM,KAAK,MAAM,SAAS,KAAK,KAAK,CAAC;AAAA,IAC1F,OAAO;AACL,UAAI,KAAK,OAAO;AAAO,YAAI,cAAc,QAAQ,EAAE;AACnD,yBAAK,QAAO,QAAQ,EAAE,IAAI;AAAA,IAC5B;AAAA,EACF;AACF;AAzbE;AACA;AACA;AA+DA;AAoWA;", "names": ["t", "dt", "ts", "config", "match", "gl", "index", "y", "v", "size", "rgb", "fx", "process", "config", "_c", "tensor", "rgb", "t", "gl", "el", "affectnet-mobilenet", "anti-spoofing", "blazeface-back", "blazeface-front", "blazepose-detector", "blazepose-full", "blazepose-heavy", "blazepose-lite", "efficientpose-i-lite", "efficientpose-ii-lite", "efficientpose-iv", "facemesh-attention", "facemesh-attention-pinto", "facemesh-detection-full", "facemesh-detection-short", "faceres-deep", "gear-e1", "gear-e2", "gender-ssrnet-imdb", "handlandmark-full", "handlandmark-lite", "handlandmark-sparse", "insightface-efficientnet-b0", "insightface-ghostnet-strides1", "insightface-ghostnet-strides2", "insightface-mobilenet-emore", "insightface-mobilenet-swish", "movenet-lightning", "movenet-multipose", "movenet-thunder", "nanodet-e", "nanodet-g", "nanodet-m", "nanodet-t", "init", "config", "_c", "_d", "model", "config", "gl", "config", "op", "t", "canvas", "init", "options", "rgb", "localOptions", "y", "cx", "cy", "pt", "xc", "yc", "options", "connectionsToIndices", "index", "_c", "_d", "_f", "_g", "_h", "emotion", "index", "v", "pt", "inCanvas", "options", "inCanvas", "localOptions", "options", "pt", "connected", "inCanvas", "localOptions", "options", "pt", "inCanvas", "localOptions", "options", "inCanvas", "localOptions", "options", "inCanvas", "localOptions", "options", "canvas", "init", "anchors", "y", "config", "outputSize", "t", "outputSize", "pt", "model", "inputSize", "config", "size", "t", "outputSize", "kpt", "distance", "annotations", "pt", "body", "_c", "labels", "model", "inputSize", "last", "lastTime", "skipped", "config", "process", "t", "id", "labels", "y", "predict", "outputSize", "connected", "kpt", "model", "lastTime", "cache", "skipped", "load", "config", "y", "predict", "enhance", "id", "x", "kpt", "connected", "pt", "pt", "w", "size", "y", "y", "v1", "v2", "size", "inputSize", "anchors", "face", "y", "model", "inputSize", "load", "config", "decodeBoxes", "t", "_c", "_d", "_f", "model", "inputSize", "load", "config", "index", "face", "y", "_c", "_d", "_f", "_g", "_h", "_j", "t", "cache", "model", "inputSize", "predict", "config", "_c", "_d", "_f", "_g", "_h", "_j", "id", "size", "face", "pt", "t", "index", "load", "model", "last", "lastTime", "skipped", "load", "config", "_c", "predict", "count", "_a", "_b", "t", "inputSize", "model", "last", "lastTime", "lastCount", "skipped", "load", "config", "predict", "count", "_c", "_d", "_a", "t", "gender", "all", "y", "face", "pt", "model", "skipped", "lastCount", "lastTime", "load", "config", "predict", "count", "model", "cached", "skipped", "lastCount", "lastTime", "load", "config", "predict", "count", "model", "last", "lastCount", "lastTime", "skipped", "load", "config", "predict", "count", "_a", "_b", "_c", "_d", "t", "gender", "age", "model", "last", "lastCount", "lastTime", "skipped", "load", "config", "predict", "count", "_c", "_d", "_a", "_b", "t", "model", "last", "lastCount", "lastTime", "skipped", "rgb", "load", "config", "predict", "count", "_c", "_d", "_a", "_b", "t", "normalize", "model", "last", "lastCount", "lastTime", "skipped", "load", "config", "predict", "count", "_a", "t", "model", "last", "lastCount", "lastTime", "skipped", "load", "config", "predict", "count", "_a", "t", "face", "normalize", "v", "y", "size", "pt", "face", "_c", "_d", "_f", "_g", "_h", "_j", "_k", "_l", "_n", "_p", "_r", "_s", "_u", "_v", "_w", "predict", "el", "options", "point", "point2", "gesture", "body", "face", "iris", "_c", "_d", "hand", "getBoxSize", "getBoxCenter", "w", "scaleBoxCoordinates", "enlargeBox", "size", "squarifyBox", "normalizeRadians", "computeRotation", "buildTranslationMatrix", "y", "dot", "v1", "v2", "getColumnFrom2DArr", "multiplyTransformMatrices", "size", "buildRotationMatrix", "invertTransformMatrix", "rotatePoint", "anchors", "model", "_c", "_d", "anchors", "t", "index", "config", "hand", "scaleBoxCoordinates", "lastTime", "handPoseModel", "_c", "xs", "ys", "rotatePoint", "enlargeBox", "squarifyBox", "getBoxSize", "buildRotationMatrix", "invertTransformMatrix", "getBoxCenter", "dot", "config", "computeRotation", "meshAnnotations", "predict", "config", "annotations", "index", "pt", "loadDetect", "models", "inputSize", "skipped", "lastTime", "cache", "loadDetect", "config", "loadSkeleton", "config", "models", "t", "ratio", "id", "hand", "inputSize", "kpt", "index", "predict", "skipped", "lastTime", "cache", "connected", "kpt", "calc", "config", "_c", "_d", "_f", "_g", "_h", "_j", "_k", "_l", "_n", "_p", "_r", "_s", "_u", "_v", "_w", "_x", "_z", "t0", "_a", "_b", "_e", "_i", "annotations", "pt", "kp", "t1", "model", "load", "config", "predict", "t", "options", "clamp", "index", "models_exports", "cache", "body", "kp", "compare", "inputSize", "t", "outputSize", "kpt", "pt", "model", "inputSize", "skipped", "cache", "load", "config", "kpt", "id", "pt", "annotations", "connected", "kp", "body", "predict", "t", "model", "last", "lastTime", "skipped", "inputSize", "load", "config", "process", "id", "size", "labels", "cx", "cy", "y", "w", "predict", "outputSize", "y", "maxSize", "t", "outputStride", "y1", "x1", "y2", "x2", "dy", "dx", "model", "point", "height", "width", "minConfidence", "y", "predict", "config", "t", "load", "model", "outputNodes", "init", "config", "load", "rgb", "predict", "model", "load", "config", "predict", "t", "model", "op", "_c", "_d", "_f", "_g", "_h", "_j", "_k", "_l", "_n", "_p", "_r", "_s", "_u", "_v", "_w", "_x", "_z", "_A", "load", "loadDetect", "loadSkeleton", "models", "join", "_c", "_d", "_f", "id", "face", "person", "body", "hand", "gesture", "y", "face", "body", "res", "face", "body", "canvas", "atob", "_c", "_d", "model", "t", "t0", "t1", "init", "process", "_c", "predict", "count", "model", "calc", "t0", "t1", "ms", "_d", "_f", "_g", "_h", "_j", "_k", "_l", "_n", "_p", "_r", "_s", "_u", "face", "body", "hand", "iris", "join"] } diff --git a/dist/human.js b/dist/human.js index 07dc62c9..cd1ca780 100644 --- a/dist/human.js +++ b/dist/human.js @@ -8615,7 +8615,7 @@ return a / b;`,lJ=` c31 * m[6] + c32 * m[7] + c33 * m[8]; gl_FragColor.a = c22.a; } -`;var K3=(e,t,a)=>{let n=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(n,(r,s)=>(a[s]=0,r))},Y3=class{constructor(t,a,n){he(this,"uniform",{});he(this,"attribute",{});he(this,"gl");he(this,"id");he(this,"compile",(t,a)=>{let n=this.gl.createShader(a);return n?(this.gl.shaderSource(n,t),this.gl.compileShader(n),this.gl.getShaderParameter(n,this.gl.COMPILE_STATUS)?n:(K(`filter: gl compile failed: ${this.gl.getShaderInfoLog(n)||"unknown"}`),null)):(K("filter: could not create shader"),null)});this.gl=t;let r=this.compile(a,this.gl.VERTEX_SHADER),s=this.compile(n,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){K("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){K(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),K3(a,"attribute",this.attribute);for(let i in this.attribute)this.attribute[i]=this.gl.getAttribLocation(this.id,i);K3(a,"uniform",this.uniform),K3(n,"uniform",this.uniform);for(let i in this.uniform)this.uniform[i]=this.gl.getUniformLocation(this.id,i)}}};function Vk(){let e=0,t=null,a=!1,n=-1,r=[null,null],s=[],i=null,o=null,l=_n(100,100),u={},p={INTERMEDIATE:1},c=l.getContext("webgl");if(!c){K("filter: cannot get webgl context");return}this.gl=c;function d(x,A){if(!(x===l.width&&A===l.height)){if(l.width=x,l.height=A,!i){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);i=c.createBuffer(),c.bindBuffer(c.ARRAY_BUFFER,i),c.bufferData(c.ARRAY_BUFFER,b,c.STATIC_DRAW),c.pixelStorei(c.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}c.viewport(0,0,l.width,l.height),r=[null,null]}}function h(x,A){let b=c.createFramebuffer();c.bindFramebuffer(c.FRAMEBUFFER,b);let w=c.createRenderbuffer();c.bindRenderbuffer(c.RENDERBUFFER,w);let I=c.createTexture();return c.bindTexture(c.TEXTURE_2D,I),c.texImage2D(c.TEXTURE_2D,0,c.RGBA,x,A,0,c.RGBA,c.UNSIGNED_BYTE,null),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MAG_FILTER,c.LINEAR),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE),c.framebufferTexture2D(c.FRAMEBUFFER,c.COLOR_ATTACHMENT0,c.TEXTURE_2D,I,0),c.bindTexture(c.TEXTURE_2D,null),c.bindFramebuffer(c.FRAMEBUFFER,null),{fbo:b,texture:I}}function m(x){return r[x]=r[x]||h(l.width,l.height),r[x]}function f(x=0){if(!o)return;let A=null,b=null,w=!1;e===0?A=t:A=m(n).texture||null,e++,a&&!(x&p.INTERMEDIATE)?(b=null,w=e%2===0):(n=(n+1)%2,b=m(n).fbo||null),c.bindTexture(c.TEXTURE_2D,A),c.bindFramebuffer(c.FRAMEBUFFER,b),c.uniform1f(o.uniform.flipY,w?-1:1),c.drawArrays(c.TRIANGLES,0,6)}function g(x){if(u[x])return o=u[x],c.useProgram((o?o.id:null)||null),o;if(o=new Y3(c,Dk,x),!o)return K("filter: could not get webgl program"),null;let A=Float32Array.BYTES_PER_ELEMENT,b=4*A;return c.enableVertexAttribArray(o.attribute.pos),c.vertexAttribPointer(o.attribute.pos,2,c.FLOAT,!1,b,0*A),c.enableVertexAttribArray(o.attribute.uv),c.vertexAttribPointer(o.attribute.uv,2,c.FLOAT,!1,b,2*A),u[x]=o,o}let y={colorMatrix:x=>{let A=new Float32Array(x);A[4]/=255,A[9]/=255,A[14]/=255,A[19]/=255;let b=A[18]===1&&A[3]===0&&A[8]===0&&A[13]===0&&A[15]===0&&A[16]===0&&A[17]===0&&A[19]===0?zk:Ok,w=g(b);w&&(c.uniform1fv(w.uniform.m,A),f())},brightness:x=>{let A=(x||0)+1;y.colorMatrix([A,0,0,0,0,0,A,0,0,0,0,0,A,0,0,0,0,0,1,0])},saturation:x=>{let A=(x||0)*2/3+1,b=(A-1)*-.5;y.colorMatrix([A,b,b,0,0,b,A,b,0,0,b,b,A,0,0,0,0,0,1,0])},desaturate:()=>{y.saturation(-1)},contrast:x=>{let A=(x||0)+1,b=-128*(A-1);y.colorMatrix([A,0,0,0,b,0,A,0,0,b,0,0,A,0,b,0,0,0,1,0])},negative:()=>{y.contrast(-2)},hue:x=>{x=(x||0)/180*Math.PI;let A=Math.cos(x),b=Math.sin(x),w=.213,I=.715,T=.072;y.colorMatrix([w+A*(1-w)+b*-w,I+A*-I+b*-I,T+A*-T+b*(1-T),0,0,w+A*-w+b*.143,I+A*(1-I)+b*.14,T+A*-T+b*-.283,0,0,w+A*-w+b*-(1-w),I+A*-I+b*I,T+A*(1-T)+b*T,0,0,0,0,0,1,0])},desaturateLuminance:()=>{y.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{y.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{y.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{y.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{y.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{y.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{y.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{y.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:x=>{let A=new Float32Array(x),b=1/l.width,w=1/l.height,I=g(Bk);I&&(c.uniform1fv(I.uniform.m,A),c.uniform2f(I.uniform.px,b,w),f())},detectEdges:()=>{y.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{y.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{y.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:x=>{let A=x||1;y.convolution.call(this,[0,-1*A,0,-1*A,1+4*A,-1*A,0,-1*A,0])},emboss:x=>{let A=x||1;y.convolution.call(this,[-2*A,-1*A,0,-1*A,1,1*A,0,1*A,2*A])},blur:x=>{let A=x/7/l.width,b=x/7/l.height,w=g(Wk);w&&(c.uniform2f(w.uniform.px,0,b),f(p.INTERMEDIATE),c.uniform2f(w.uniform.px,A,0),f())},pixelate:x=>{let A=x/l.width,b=x/l.height,w=g(Lk);w&&(c.uniform2f(w.uniform.size,A,b),f())}};this.add=function(x){let A=Array.prototype.slice.call(arguments,1),b=y[x];s.push({func:b,args:A})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(x){d(x.width,x.height),e=0,t||(t=c.createTexture()),c.bindTexture(c.TEXTURE_2D,t),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.NEAREST),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MAG_FILTER,c.NEAREST),c.texImage2D(c.TEXTURE_2D,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,x);for(let A=0;Ap.data())),i=Math.max(s[0][0],s[1][0],s[2][0]),l=(i>1?255:1)/i,u;if(l>1){let p=[xe(a[0],n[0]),xe(a[1],n[1]),xe(a[2],n[2])],c=[xe(r[0],n[0]),xe(r[1],n[1]),xe(r[2],n[2])],d=[te(p[0],l),te(p[1],l),te(p[2],l)],h=ca([d[0],d[1],d[2]],2);u=Q(h,[1,t.shape[0]||0,t.shape[1]||0,3]),J([...p,...c,...d,h])}else u=Bt(t,0);return J([...a,...n,...r,a,t,e]),u}var f0=3840,aa=null,na=null,td=null,bt,bn={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function Z3(){bn.inputSum=0,bn.cacheDiff=1,bn.sumMethod=0,bn.inputTensor=void 0}function _n(e,t){let a;if(ne.browser)if(ne.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");a=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")a=document.createElement("canvas"),a.width=e,a.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof ne.Canvas!="undefined")a=new ne.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")a=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof ne.Canvas!="undefined"?a=new ne.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(a=new globalThis.Canvas(e,t));return a}function g0(e,t){let a=t||_n(e.width,e.height);return a.getContext("2d").drawImage(e,0,0),a}async function y0(e,t,a=!0){var d,h,m;if(!e)return t.debug&&K("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof mt)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof mt){let f=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)f=Bt(e,0);else if(e.shape[2]===4){let g=qp(e,[0,0,0],[-1,-1,3]);f=Bt(g,0),J(g)}}else e.shape.length===4&&(e.shape[3]===3?f=Sa(e):e.shape[3]===4&&(f=Bh(e,[0,0,0,0],[-1,-1,-1,3])));if(f==null||f.shape.length!==4||f.shape[0]!==1||f.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(f.dtype==="int32"){let g=Ue(f,"float32");J(f),f=g}return{tensor:f,canvas:t.filter.return?na:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&K("input stream is not ready"),{tensor:null,canvas:aa};let n=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!n||!r)return t.debug&&K("cannot determine input dimensions"),{tensor:null,canvas:aa};let s=n,i=r;if(s>f0&&(s=f0,i=Math.trunc(s*r/n)),i>f0&&(i=f0,s=Math.trunc(i*n/r)),(((d=t.filter)==null?void 0:d.width)||0)>0?s=t.filter.width:(((h=t.filter)==null?void 0:h.height)||0)>0&&(s=n*((t.filter.height||0)/r)),(t.filter.height||0)>0?i=t.filter.height:(t.filter.width||0)>0&&(i=r*((t.filter.width||0)/n)),!s||!i)throw new Error("input error: cannot determine dimension");(!aa||aa.width!==s||aa.height!==i)&&(aa=_n(s,i));let o=aa.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?o.putImageData(e,0,0):t.filter.flip&&typeof o.translate!="undefined"?(o.translate(n,0),o.scale(-1,1),o.drawImage(e,0,0,n,r,0,0,aa.width,aa.height),o.setTransform(1,0,0,1,0,0)):o.drawImage(e,0,0,n,r,0,0,aa.width,aa.height),(!na||aa.width!==na.width||aa.height!==na.height)&&(na=_n(aa.width,aa.height)),t.filter.enabled&&ne.webgl.supported?(bt||(bt=ne.browser?new Vk:null),ne.filter=!!bt,bt!=null&&bt.add?(bt.reset(),t.filter.brightness!==0&&bt.add("brightness",t.filter.brightness),t.filter.contrast!==0&&bt.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&bt.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&bt.add("blur",t.filter.blur),t.filter.saturation!==0&&bt.add("saturation",t.filter.saturation),t.filter.hue!==0&&bt.add("hue",t.filter.hue),t.filter.negative&&bt.add("negative"),t.filter.sepia&&bt.add("sepia"),t.filter.vintage&&bt.add("brownie"),t.filter.sepia&&bt.add("sepia"),t.filter.kodachrome&&bt.add("kodachrome"),t.filter.technicolor&&bt.add("technicolor"),t.filter.polaroid&&bt.add("polaroid"),t.filter.pixelate!==0&&bt.add("pixelate",t.filter.pixelate),((m=bt.get())==null?void 0:m.length)>1?na=bt.apply(aa):na=bt.draw(aa)):(t.debug&&K("input process error: cannot initialize filters"),ne.webgl.supported=!1,t.filter.enabled=!1,g0(aa,na))):(g0(aa,na),bt&&(bt=null),ne.filter=!!bt),!a)return{tensor:null,canvas:na};if(!na)throw new Error("canvas error: cannot create output");let l,u=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(ne.browser&&Er)l=Er?Er.fromPixels(e):null;else{u=e.data.length/e.height/e.width;let f=new Uint8Array(e.data.buffer);l=Ve(f,[e.height,e.width,u],"int32")}else if((!td||na.width!==td.width||na.height!==td.height)&&(td=_n(na.width,na.height)),Er&&ne.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=Er.fromPixels(na):(td=g0(na),l=Er.fromPixels(td));else{let y=g0(na).getContext("2d").getImageData(0,0,s,i);u=y.data.length/s/i;let x=new Uint8Array(y.data.buffer);l=Ve(x,[s,i,u])}if(u===4){let f=qp(l,[0,0,0],[-1,-1,3]);J(l),l=f}if(!l)throw new Error("input error: cannot create tensor");let p=Ue(l,"float32"),c=t.filter.equalization?await m0(p):Bt(p,0);if(J([l,p]),t.filter.autoBrightness){let f=ga(c),g=await f.data();t.filter.brightness=g[0]>1?1-g[0]/255:1-g[0],J(f)}return{tensor:c,canvas:t.filter.return?na:null}}async function Uk(e,t){let a=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return a;if(!bn.inputTensor)bn.inputTensor=Sa(t);else if(bn.inputTensor.shape[1]!==t.shape[1]||bn.inputTensor.shape[2]!==t.shape[2])J(bn.inputTensor),bn.inputTensor=Sa(t);else{let n={};n.diff=xe(t,bn.inputTensor),n.squared=te(n.diff,n.diff),n.sum=ot(n.squared);let s=(await n.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;J([bn.inputTensor,n.diff,n.squared,n.sum]),bn.inputTensor=Sa(t),a=s<=(e.cacheSensitivity||0)}return a}async function Gk(e,t,a){let n={};if(!t||!a||t.shape.length!==4||t.shape.length!==a.shape.length)return e.debug||K("invalid input tensor or tensor shapes do not match:",t.shape,a.shape),0;if(t.shape[0]!==1||a.shape[0]!==1||t.shape[3]!==3||a.shape[3]!==3)return e.debug||K("input tensors must be of shape [1, height, width, 3]:",t.shape,a.shape),0;n.input1=Sa(t),n.input2=t.shape[1]!==a.shape[1]||t.shape[2]!==a.shape[2]?fe.resizeBilinear(a,[t.shape[1],t.shape[2]]):Sa(a),n.diff=xe(n.input1,n.input2),n.squared=te(n.diff,n.diff),n.sum=ot(n.squared);let s=(await n.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return J([n.input1,n.input2,n.diff,n.squared,n.sum]),s}var nc,rc,sc,ac=class{constructor(){he(this,"browser");he(this,"node");he(this,"worker");he(this,"platform","");he(this,"agent","");he(this,"backends",[]);he(this,"initial");he(this,"filter");he(this,"tfjs");he(this,"offscreen");he(this,"perfadd",!1);he(this,"tensorflow",{version:void 0,gpu:void 0});he(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});he(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});he(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});he(this,"cpu",{model:void 0,flags:[]});he(this,"kernels",[]);jn(this,nc,void 0);jn(this,rc,void 0);jn(this,sc,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:tc["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",a=t.match(/\(([^()]+)\)/g);if(a!=null&&a[0]){let n=a[0].match(/\(([^()]+)\)/g);this.platform=n!=null&&n[0]?n[0].replace(/\(|\)/g,""):"",this.agent=t.replace(a[0],""),this.platform[1]&&(this.agent=this.agent.replace(a[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Ka(this,nc)}set Canvas(t){Ar(this,nc,t),globalThis.Canvas=t}get Image(){return Ka(this,rc)}set Image(t){Ar(this,rc,t),globalThis.Image=t}get ImageData(){return Ka(this,sc)}set ImageData(t){Ar(this,sc,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(It().registryFactory);try{this.tensorflow={version:rr().binding?rr().binding.TF_Version:void 0,gpu:rr().binding?rr().binding.isUsingGpuDevice():void 0}}catch(n){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=_n(100,100),a=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof a!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&a&&(this.webgl.version=a.getParameter(a.VERSION),this.webgl.vendor=a.getParameter(a.VENDOR),this.webgl.renderer=a.getParameter(a.RENDERER),this.webgl.shader=a.getParameter(a.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let n=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(n==null?void 0:n.requestAdapterInfo())}}catch(n){this.webgpu.supported=!1}try{this.kernels=Zn(ha()).map(n=>n.kernelName.toLowerCase())}catch(n){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};nc=new WeakMap,rc=new WeakMap,sc=new WeakMap;var ne=new ac;var A0=class{constructor(){he(this,"config");he(this,"element");he(this,"stream");he(this,"devices",[]);he(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(a=>a.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});he(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let i=document.getElementById(t.element);if(i&&i instanceof HTMLVideoElement)this.element=i;else return this.config.debug&&K("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&K("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let a={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(a.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(a.video.height={ideal:this.config.height}),this.config.id&&(a.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&K("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&K("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&K("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(a)}catch(i){return K("webcam",i),`webcam error: ${i}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(i=>{this.element?this.element.onloadeddata=()=>i(!0):i(!1)}),await this.element.play(),this.config.debug&&K("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&K("webcam error","no stream"),"webcam error no stream")});he(this,"pause",()=>{this.element&&this.element.pause()});he(this,"play",async()=>{this.element&&await this.element.play()});he(this,"stop",()=>{this.config.debug&&K("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var J3={};xr(J3,{"affectnet-mobilenet":()=>G2e,age:()=>H2e,"anti-spoofing":()=>k1e,antispoof:()=>_2e,blazeface:()=>P2e,"blazeface-back":()=>j2e,"blazeface-front":()=>q2e,"blazepose-detector":()=>X2e,"blazepose-full":()=>K2e,"blazepose-heavy":()=>Y2e,"blazepose-lite":()=>Z2e,centernet:()=>$2e,default:()=>D1e,efficientpose:()=>J2e,"efficientpose-i-lite":()=>I1e,"efficientpose-ii-lite":()=>S1e,"efficientpose-iv":()=>C1e,emotion:()=>F2e,faceboxes:()=>Q2e,facemesh:()=>D2e,"facemesh-attention":()=>t1e,"facemesh-attention-pinto":()=>e1e,"facemesh-detection-full":()=>a1e,"facemesh-detection-short":()=>n1e,faceres:()=>O2e,"faceres-deep":()=>r1e,gear:()=>o1e,"gear-e1":()=>s1e,"gear-e2":()=>i1e,gender:()=>u1e,"gender-ssrnet-imdb":()=>l1e,handdetect:()=>d1e,"handlandmark-full":()=>p1e,"handlandmark-lite":()=>z2e,"handlandmark-sparse":()=>c1e,handskeleton:()=>h1e,handtrack:()=>L2e,"insightface-efficientnet-b0":()=>T1e,"insightface-ghostnet-strides1":()=>N1e,"insightface-ghostnet-strides2":()=>R1e,"insightface-mobilenet-emore":()=>E1e,"insightface-mobilenet-swish":()=>M1e,iris:()=>W2e,liveness:()=>B2e,meet:()=>m1e,mobileface:()=>f1e,mobilefacenet:()=>g1e,models:()=>V2e,"movenet-lightning":()=>U2e,"movenet-multipose":()=>y1e,"movenet-thunder":()=>x1e,nanodet:()=>A1e,"nanodet-e":()=>_1e,"nanodet-g":()=>P1e,"nanodet-m":()=>$1e,"nanodet-t":()=>F1e,posenet:()=>b1e,rvm:()=>v1e,selfie:()=>w1e});var _2e=853098,P2e=538928,$2e=4030290,F2e=820516,D2e=1477958,O2e=6978814,z2e=2023432,L2e=2964837,W2e=2599092,B2e=592976,V2e=0,U2e=4650216,G2e=6920630,H2e=161240,j2e=538928,q2e=402048,X2e=5928856,K2e=6339202,Y2e=27502466,Z2e=2726402,J2e=5651240,Q2e=2013002,e1e=2387598,t1e=2382414,a1e=1026192,n1e=201268,r1e=13957620,s1e=112438,i1e=112438,o1e=1498916,l1e=161236,u1e=201808,d1e=3515612,p1e=5431368,c1e=5286322,h1e=5502280,m1e=372228,f1e=2183192,g1e=5171976,y1e=9448838,x1e=12477112,A1e=7574558,b1e=5032780,v1e=3739355,w1e=212886,k1e=853098,I1e=2269064,S1e=5651240,C1e=25643252,T1e=13013224,N1e=8093408,R1e=8049584,E1e=6938536,M1e=12168584,_1e=12319156,P1e=7574558,$1e=1887474,F1e=5294216,D1e={antispoof:_2e,blazeface:P2e,centernet:$2e,emotion:F2e,facemesh:D2e,faceres:O2e,"handlandmark-lite":z2e,handtrack:L2e,iris:W2e,liveness:B2e,models:V2e,"movenet-lightning":U2e,"affectnet-mobilenet":G2e,age:H2e,"blazeface-back":j2e,"blazeface-front":q2e,"blazepose-detector":X2e,"blazepose-full":K2e,"blazepose-heavy":Y2e,"blazepose-lite":Z2e,efficientpose:J2e,faceboxes:Q2e,"facemesh-attention-pinto":e1e,"facemesh-attention":t1e,"facemesh-detection-full":a1e,"facemesh-detection-short":n1e,"faceres-deep":r1e,"gear-e1":s1e,"gear-e2":i1e,gear:o1e,"gender-ssrnet-imdb":l1e,gender:u1e,handdetect:d1e,"handlandmark-full":p1e,"handlandmark-sparse":c1e,handskeleton:h1e,meet:m1e,mobileface:f1e,mobilefacenet:g1e,"movenet-multipose":y1e,"movenet-thunder":x1e,nanodet:A1e,posenet:b1e,rvm:v1e,selfie:w1e,"anti-spoofing":k1e,"efficientpose-i-lite":I1e,"efficientpose-ii-lite":S1e,"efficientpose-iv":C1e,"insightface-efficientnet-b0":T1e,"insightface-ghostnet-strides1":N1e,"insightface-ghostnet-strides2":R1e,"insightface-mobilenet-emore":E1e,"insightface-mobilenet-swish":M1e,"nanodet-e":_1e,"nanodet-g":P1e,"nanodet-m":$1e,"nanodet-t":F1e};var Ma={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},xa={};async function O1e(e,t){return Ma.debug&&K("load model fetch:",e,t),fetch(e,t)}function Hk(e){Ma.cacheModels=e.cacheModels,Ma.verbose=e.debug,Ma.modelBasePath=e.modelBasePath}async function _e(e){var u,p,c,d;let t=Fk(Ma.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let a=t.includes("/")?t.split("/"):t.split("\\"),n=a[a.length-1].replace(".json",""),r="indexeddb://"+n;xa[n]={name:n,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:J3[n],inCache:!1,url:""},Ma.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=Ma.cacheSupported&&Ma.cacheModels?await Xn.listModels():{}}catch(h){Ma.cacheSupported=!1}xa[n].inCache=Ma.cacheSupported&&Ma.cacheModels&&Object.keys(s).includes(r),xa[n].url=xa[n].inCache?r:t;let i=typeof fetch=="undefined"?{}:{fetchFunc:(h,m)=>O1e(h,m)},o=new Xp(xa[n].url,i),l=!1;try{o.findIOHandler(),Ma.debug&&K("model load handler:",o.handler)}catch(h){K("error finding model i/o handler:",t,h)}try{let h=await((u=o.handler)==null?void 0:u.load())||null;xa[n].sizeFromManifest=((p=h==null?void 0:h.weightData)==null?void 0:p.byteLength)||0,h?o.loadSync(h):o=await o3(xa[n].inCache?r:t,i),xa[n].sizeLoadedWeights=((d=(c=o.artifacts)==null?void 0:c.weightData)==null?void 0:d.byteLength)||0,Ma.verbose&&K("load:",{model:n,url:o.modelUrl,bytes:xa[n].sizeLoadedWeights}),l=!0}catch(h){K("error loading model:",t,h)}if(l&&Ma.cacheModels&&Ma.cacheSupported&&!xa[n].inCache)try{let h=await o.save(r);Ma.debug&&K("model saved:",r,h)}catch(h){K("error saving model:",t,h)}return o}var Q3="3.1.1";var St={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function W1e(){let e=St.gl;e&&(St.extensions=e.getSupportedExtensions())}function jk(e){var t;if(e.config.backend==="humangl"&&(St.name in It().registry&&!((t=St==null?void 0:St.gl)!=null&&t.getParameter(St.gl.VERSION))&&(K("humangl error: backend invalid context"),e.models.reset()),!lg(St.name))){try{St.canvas=_n(100,100)}catch(r){K("humangl error: cannot create canvas:",r);return}try{if(St.gl=St.canvas.getContext("webgl2",St.webGLattr),!St.gl){K("humangl error: cannot get webgl context");return}if(!St.gl.getParameter(St.gl.VERSION).includes("2.0")){K("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}St.canvas&&(St.canvas.addEventListener("webglcontextlost",s=>{throw K("humangl error:",s.type),K("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),St.canvas.addEventListener("webglcontextrestored",s=>{K("humangl error: context restored:",s)}),St.canvas.addEventListener("webglcontextcreationerror",s=>{K("humangl error: context create:",s)}))}catch(r){K("humangl error: cannot get webgl context:",r);return}try{a0(2,St.gl)}catch(r){K("humangl error: cannot set webgl context:",r);return}try{let r=new Wl(St.gl);Jo(St.name,()=>new Ku(r),St.priority)}catch(r){K("humangl error: cannot register webgl backend:",r);return}try{Zn("webgl").forEach(s=>{let i={...s,backendName:St.name};xn(i)})}catch(r){K("humangl error: cannot update webgl backend registration:",r);return}try{W().flagRegistry.WEBGL_VERSION&&W().set("WEBGL_VERSION",2)}catch(r){K("humangl error: cannot set WebGL backend flags:",r);return}W1e();let a=rr(),n=typeof a.gpgpu!="undefined"?a.getGPGPUContext().gl:null;n?e.config.debug&&K("humangl backend registered:",{webgl:n.getParameter(n.VERSION),renderer:n.getParameter(n.RENDERER)}):K("humangl error: no current gl context:",n,St.gl)}}var ze={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function qk(){ze.tf255=Ge(255,"float32"),ze.tf1=Ge(1,"float32"),ze.tf2=Ge(2,"float32"),ze.tf05=Ge(.5,"float32"),ze.tf127=Ge(127.5,"float32"),ze.rgb=Vt([.2989,.587,.114],"float32")}async function U1e(){var e;return await ne.updateBackend(),(e=ne.tensorflow)!=null&&e.version?"tensorflow":ne.webgpu.supported&&ne.webgpu.backend?"webgpu":ne.webgl.supported&&ne.webgl.backend?"webgl":ne.wasm.supported&&ne.wasm.backend?"wasm":"cpu"}function G1e(e){let t=[];if(!ne.kernels.includes("mod")){let a={kernelName:"Mod",backendName:ha(),kernelFunc:n=>De(()=>xe(n.inputs.a,te(ve(n.inputs.a,n.inputs.b),n.inputs.b)))};xn(a),ne.kernels.push("mod"),t.push("mod")}if(!ne.kernels.includes("floormod")){let a={kernelName:"FloorMod",backendName:ha(),kernelFunc:n=>De(()=>we(te(zp(n.inputs.a,n.inputs.b),n.inputs.b),Bu(n.inputs.a,n.inputs.b)))};xn(a),ne.kernels.push("floormod"),t.push("floormod")}if(!ne.kernels.includes("rotatewithoffset")&&e.softwareKernels){let a={kernelName:"RotateWithOffset",backendName:ha(),kernelFunc:n=>De(()=>{let r=ha();Dp("cpu");let s=fe.rotateWithOffset(n.inputs.image,n.attrs.radians,n.attrs.fillValue,n.attrs.center);return Dp(r),s})};xn(a),ne.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&K("registered kernels:",t)}var Xk={};async function ic(e,t=!1){var a,n;if(e.state="backend",((a=e.config.backend)==null?void 0:a.length)===0&&(e.config.backend=await U1e()),t||ne.initial||e.config.backend&&e.config.backend.length>0&&ha()!==e.config.backend){let r=ae();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&K("running inside web worker"),typeof navigator!="undefined"&&((n=navigator==null?void 0:navigator.userAgent)!=null&&n.toLowerCase().includes("electron"))&&e.config.debug&&K("running inside electron");let s=Object.keys(It().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(jk(e),s=Object.keys(It().registryFactory)),e.config.debug&&K("available backends:",s),ne.browser&&!ne.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&K("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),ne.node&&!ne.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&K(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),ne.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")K("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let i=await navigator.gpu.requestAdapter();if(e.config.debug&&K("enumerated webgpu adapter:",i),!i)K("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let o="requestAdapterInfo"in i?await i.requestAdapterInfo():void 0;K("webgpu adapter info:",o)}}if(s.includes(e.config.backend)||(K(`error: backend ${e.config.backend} not found in registry`),e.config.backend=ne.node?"tensorflow":"webgl",e.config.debug&&K(`override: setting backend ${e.config.backend}`)),e.config.debug&&K("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(W().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&W().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&K("wasm path:",e.config.wasmPath),typeof l0!="undefined")l0(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let i=!1,o=!1;try{i=await W().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),o=await W().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&K(`wasm execution: ${o?"simd":"no simd"} ${i?"multithreaded":"singlethreaded"}`),e.config.debug&&!o&&K("warning: wasm simd support is not enabled")}catch(l){K("wasm detection failed")}}try{await Dp(e.config.backend),await Op()}catch(i){return K("error: cannot set backend:",e.config.backend,i),!1}e.config.debug&&(Xk=JSON.parse(JSON.stringify(W().flags)))}if((ha()==="humangl"||ha()==="webgl")&&(W().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&W().set("WEBGL_USE_SHAPES_UNIFORMS",!0),W().flagRegistry.WEBGL_EXP_CONV&&W().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(K("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),W().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),ha(),e.config.debug){let s=W().flags,i={};for(let o of Object.keys(s))Xk[o]!==s[o]&&(i[o]=s[o]);e.config.debug&&Object.keys(i).length>0&&K("backend:",ha(),"flags:",i)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&K("flags:",e.config.flags);for(let[s,i]of Object.entries(e.config.flags))W().set(s,i)}ig(),qk(),e.performance.initBackend=Math.trunc(ae()-r),e.config.backend=ha(),await ne.updateBackend(),G1e(e.config)}return!0}function b0(e,t){for(let a of e){let n={kernelName:a,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&K("kernelFunc",a,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};xn(n)}ne.kernels=Zn(ha()).map(a=>a.kernelName.toLowerCase())}var C0={};xr(C0,{all:()=>vge,body:()=>w0,canvas:()=>bge,face:()=>v0,gesture:()=>S0,hand:()=>k0,init:()=>iy,object:()=>I0,options:()=>Dt,person:()=>Age});var vn=e=>{if(!e)K("draw error: invalid canvas");else if(!e.getContext)K("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)K("draw error: cannot get canvas context");else return t}return null},ll=e=>Math.round(e*180/Math.PI),ut=(e,t,a)=>e.replace(t,typeof a=="number"?a.toFixed(1):a),ul=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let a=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${a[0]}, ${a[1]}, ${a[2]}, ${t.alpha})`};function wn(e,t,a,n,r){let s=t.replace(/\[.*\]/g,"").split(` +`;var K3=(e,t,a)=>{let n=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(n,(r,s)=>(a[s]=0,r))},Y3=class{constructor(t,a,n){he(this,"uniform",{});he(this,"attribute",{});he(this,"gl");he(this,"id");he(this,"compile",(t,a)=>{let n=this.gl.createShader(a);return n?(this.gl.shaderSource(n,t),this.gl.compileShader(n),this.gl.getShaderParameter(n,this.gl.COMPILE_STATUS)?n:(K(`filter: gl compile failed: ${this.gl.getShaderInfoLog(n)||"unknown"}`),null)):(K("filter: could not create shader"),null)});this.gl=t;let r=this.compile(a,this.gl.VERTEX_SHADER),s=this.compile(n,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){K("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){K(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),K3(a,"attribute",this.attribute);for(let i in this.attribute)this.attribute[i]=this.gl.getAttribLocation(this.id,i);K3(a,"uniform",this.uniform),K3(n,"uniform",this.uniform);for(let i in this.uniform)this.uniform[i]=this.gl.getUniformLocation(this.id,i)}}};function Vk(){let e=0,t=null,a=!1,n=-1,r=[null,null],s=[],i=null,o=null,l=_n(100,100),u={},p={INTERMEDIATE:1},c=l.getContext("webgl");if(!c){K("filter: cannot get webgl context");return}this.gl=c;function d(x,A){if(!(x===l.width&&A===l.height)){if(l.width=x,l.height=A,!i){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);i=c.createBuffer(),c.bindBuffer(c.ARRAY_BUFFER,i),c.bufferData(c.ARRAY_BUFFER,b,c.STATIC_DRAW),c.pixelStorei(c.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}c.viewport(0,0,l.width,l.height),r=[null,null]}}function h(x,A){let b=c.createFramebuffer();c.bindFramebuffer(c.FRAMEBUFFER,b);let w=c.createRenderbuffer();c.bindRenderbuffer(c.RENDERBUFFER,w);let I=c.createTexture();return c.bindTexture(c.TEXTURE_2D,I),c.texImage2D(c.TEXTURE_2D,0,c.RGBA,x,A,0,c.RGBA,c.UNSIGNED_BYTE,null),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MAG_FILTER,c.LINEAR),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.LINEAR),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE),c.framebufferTexture2D(c.FRAMEBUFFER,c.COLOR_ATTACHMENT0,c.TEXTURE_2D,I,0),c.bindTexture(c.TEXTURE_2D,null),c.bindFramebuffer(c.FRAMEBUFFER,null),{fbo:b,texture:I}}function m(x){return r[x]=r[x]||h(l.width,l.height),r[x]}function f(x=0){if(!o)return;let A=null,b=null,w=!1;e===0?A=t:A=m(n).texture||null,e++,a&&!(x&p.INTERMEDIATE)?(b=null,w=e%2===0):(n=(n+1)%2,b=m(n).fbo||null),c.bindTexture(c.TEXTURE_2D,A),c.bindFramebuffer(c.FRAMEBUFFER,b),c.uniform1f(o.uniform.flipY,w?-1:1),c.drawArrays(c.TRIANGLES,0,6)}function g(x){if(u[x])return o=u[x],c.useProgram((o?o.id:null)||null),o;if(o=new Y3(c,Dk,x),!o)return K("filter: could not get webgl program"),null;let A=Float32Array.BYTES_PER_ELEMENT,b=4*A;return c.enableVertexAttribArray(o.attribute.pos),c.vertexAttribPointer(o.attribute.pos,2,c.FLOAT,!1,b,0*A),c.enableVertexAttribArray(o.attribute.uv),c.vertexAttribPointer(o.attribute.uv,2,c.FLOAT,!1,b,2*A),u[x]=o,o}let y={colorMatrix:x=>{let A=new Float32Array(x);A[4]/=255,A[9]/=255,A[14]/=255,A[19]/=255;let b=A[18]===1&&A[3]===0&&A[8]===0&&A[13]===0&&A[15]===0&&A[16]===0&&A[17]===0&&A[19]===0?zk:Ok,w=g(b);w&&(c.uniform1fv(w.uniform.m,A),f())},brightness:x=>{let A=(x||0)+1;y.colorMatrix([A,0,0,0,0,0,A,0,0,0,0,0,A,0,0,0,0,0,1,0])},saturation:x=>{let A=(x||0)*2/3+1,b=(A-1)*-.5;y.colorMatrix([A,b,b,0,0,b,A,b,0,0,b,b,A,0,0,0,0,0,1,0])},desaturate:()=>{y.saturation(-1)},contrast:x=>{let A=(x||0)+1,b=-128*(A-1);y.colorMatrix([A,0,0,0,b,0,A,0,0,b,0,0,A,0,b,0,0,0,1,0])},negative:()=>{y.contrast(-2)},hue:x=>{x=(x||0)/180*Math.PI;let A=Math.cos(x),b=Math.sin(x),w=.213,I=.715,T=.072;y.colorMatrix([w+A*(1-w)+b*-w,I+A*-I+b*-I,T+A*-T+b*(1-T),0,0,w+A*-w+b*.143,I+A*(1-I)+b*.14,T+A*-T+b*-.283,0,0,w+A*-w+b*-(1-w),I+A*-I+b*I,T+A*(1-T)+b*T,0,0,0,0,0,1,0])},desaturateLuminance:()=>{y.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{y.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{y.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{y.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{y.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{y.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{y.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{y.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:x=>{let A=new Float32Array(x),b=1/l.width,w=1/l.height,I=g(Bk);I&&(c.uniform1fv(I.uniform.m,A),c.uniform2f(I.uniform.px,b,w),f())},detectEdges:()=>{y.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{y.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{y.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:x=>{let A=x||1;y.convolution.call(this,[0,-1*A,0,-1*A,1+4*A,-1*A,0,-1*A,0])},emboss:x=>{let A=x||1;y.convolution.call(this,[-2*A,-1*A,0,-1*A,1,1*A,0,1*A,2*A])},blur:x=>{let A=x/7/l.width,b=x/7/l.height,w=g(Wk);w&&(c.uniform2f(w.uniform.px,0,b),f(p.INTERMEDIATE),c.uniform2f(w.uniform.px,A,0),f())},pixelate:x=>{let A=x/l.width,b=x/l.height,w=g(Lk);w&&(c.uniform2f(w.uniform.size,A,b),f())}};this.add=function(x){let A=Array.prototype.slice.call(arguments,1),b=y[x];s.push({func:b,args:A})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(x){d(x.width,x.height),e=0,t||(t=c.createTexture()),c.bindTexture(c.TEXTURE_2D,t),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_S,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_WRAP_T,c.CLAMP_TO_EDGE),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MIN_FILTER,c.NEAREST),c.texParameteri(c.TEXTURE_2D,c.TEXTURE_MAG_FILTER,c.NEAREST),c.texImage2D(c.TEXTURE_2D,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,x);for(let A=0;Ap.data())),i=Math.max(s[0][0],s[1][0],s[2][0]),l=(i>1?255:1)/i,u;if(l>1){let p=[xe(a[0],n[0]),xe(a[1],n[1]),xe(a[2],n[2])],c=[xe(r[0],n[0]),xe(r[1],n[1]),xe(r[2],n[2])],d=[te(p[0],l),te(p[1],l),te(p[2],l)],h=ca([d[0],d[1],d[2]],2);u=Q(h,[1,t.shape[0]||0,t.shape[1]||0,3]),J([...p,...c,...d,h])}else u=Bt(t,0);return J([...a,...n,...r,a,t,e]),u}var f0=3840,aa=null,na=null,td=null,bt,bn={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function Z3(){bn.inputSum=0,bn.cacheDiff=1,bn.sumMethod=0,bn.inputTensor=void 0}function _n(e,t){let a;if(ne.browser)if(ne.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");a=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")a=document.createElement("canvas"),a.width=e,a.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof ne.Canvas!="undefined")a=new ne.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")a=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof ne.Canvas!="undefined"?a=new ne.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(a=new globalThis.Canvas(e,t));return a}function g0(e,t){let a=t||_n(e.width,e.height);return a.getContext("2d").drawImage(e,0,0),a}async function y0(e,t,a=!0){var d,h,m;if(!e)return t.debug&&K("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof mt)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof mt){let f=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)f=Bt(e,0);else if(e.shape[2]===4){let g=qp(e,[0,0,0],[-1,-1,3]);f=Bt(g,0),J(g)}}else e.shape.length===4&&(e.shape[3]===3?f=Sa(e):e.shape[3]===4&&(f=Bh(e,[0,0,0,0],[-1,-1,-1,3])));if(f==null||f.shape.length!==4||f.shape[0]!==1||f.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(f.dtype==="int32"){let g=Ue(f,"float32");J(f),f=g}return{tensor:f,canvas:t.filter.return?na:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&K("input stream is not ready"),{tensor:null,canvas:aa};let n=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!n||!r)return t.debug&&K("cannot determine input dimensions"),{tensor:null,canvas:aa};let s=n,i=r;if(s>f0&&(s=f0,i=Math.trunc(s*r/n)),i>f0&&(i=f0,s=Math.trunc(i*n/r)),(((d=t.filter)==null?void 0:d.width)||0)>0?s=t.filter.width:(((h=t.filter)==null?void 0:h.height)||0)>0&&(s=n*((t.filter.height||0)/r)),(t.filter.height||0)>0?i=t.filter.height:(t.filter.width||0)>0&&(i=r*((t.filter.width||0)/n)),!s||!i)throw new Error("input error: cannot determine dimension");(!aa||aa.width!==s||aa.height!==i)&&(aa=_n(s,i));let o=aa.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?o.putImageData(e,0,0):t.filter.flip&&typeof o.translate!="undefined"?(o.translate(n,0),o.scale(-1,1),o.drawImage(e,0,0,n,r,0,0,aa.width,aa.height),o.setTransform(1,0,0,1,0,0)):o.drawImage(e,0,0,n,r,0,0,aa.width,aa.height),(!na||aa.width!==na.width||aa.height!==na.height)&&(na=_n(aa.width,aa.height)),t.filter.enabled&&ne.webgl.supported?(bt||(bt=ne.browser?new Vk:null),ne.filter=!!bt,bt!=null&&bt.add?(bt.reset(),t.filter.brightness!==0&&bt.add("brightness",t.filter.brightness),t.filter.contrast!==0&&bt.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&bt.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&bt.add("blur",t.filter.blur),t.filter.saturation!==0&&bt.add("saturation",t.filter.saturation),t.filter.hue!==0&&bt.add("hue",t.filter.hue),t.filter.negative&&bt.add("negative"),t.filter.sepia&&bt.add("sepia"),t.filter.vintage&&bt.add("brownie"),t.filter.sepia&&bt.add("sepia"),t.filter.kodachrome&&bt.add("kodachrome"),t.filter.technicolor&&bt.add("technicolor"),t.filter.polaroid&&bt.add("polaroid"),t.filter.pixelate!==0&&bt.add("pixelate",t.filter.pixelate),((m=bt.get())==null?void 0:m.length)>1?na=bt.apply(aa):na=bt.draw(aa)):(t.debug&&K("input process error: cannot initialize filters"),ne.webgl.supported=!1,t.filter.enabled=!1,g0(aa,na))):(g0(aa,na),bt&&(bt=null),ne.filter=!!bt),!a)return{tensor:null,canvas:na};if(!na)throw new Error("canvas error: cannot create output");let l,u=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(ne.browser&&Er)l=Er?Er.fromPixels(e):null;else{u=e.data.length/e.height/e.width;let f=new Uint8Array(e.data.buffer);l=Ve(f,[e.height,e.width,u],"int32")}else if((!td||na.width!==td.width||na.height!==td.height)&&(td=_n(na.width,na.height)),Er&&ne.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=Er.fromPixels(na):(td=g0(na),l=Er.fromPixels(td));else{let y=g0(na).getContext("2d").getImageData(0,0,s,i);u=y.data.length/s/i;let x=new Uint8Array(y.data.buffer);l=Ve(x,[s,i,u])}if(u===4){let f=qp(l,[0,0,0],[-1,-1,3]);J(l),l=f}if(!l)throw new Error("input error: cannot create tensor");let p=Ue(l,"float32"),c=t.filter.equalization?await m0(p):Bt(p,0);if(J([l,p]),t.filter.autoBrightness){let f=ga(c),g=await f.data();t.filter.brightness=g[0]>1?1-g[0]/255:1-g[0],J(f)}return{tensor:c,canvas:t.filter.return?na:null}}async function Uk(e,t){let a=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return a;if(!bn.inputTensor)bn.inputTensor=Sa(t);else if(bn.inputTensor.shape[1]!==t.shape[1]||bn.inputTensor.shape[2]!==t.shape[2])J(bn.inputTensor),bn.inputTensor=Sa(t);else{let n={};n.diff=xe(t,bn.inputTensor),n.squared=te(n.diff,n.diff),n.sum=ot(n.squared);let s=(await n.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;J([bn.inputTensor,n.diff,n.squared,n.sum]),bn.inputTensor=Sa(t),a=s<=(e.cacheSensitivity||0)}return a}async function Gk(e,t,a){let n={};if(!t||!a||t.shape.length!==4||t.shape.length!==a.shape.length)return e.debug||K("invalid input tensor or tensor shapes do not match:",t.shape,a.shape),0;if(t.shape[0]!==1||a.shape[0]!==1||t.shape[3]!==3||a.shape[3]!==3)return e.debug||K("input tensors must be of shape [1, height, width, 3]:",t.shape,a.shape),0;n.input1=Sa(t),n.input2=t.shape[1]!==a.shape[1]||t.shape[2]!==a.shape[2]?fe.resizeBilinear(a,[t.shape[1],t.shape[2]]):Sa(a),n.diff=xe(n.input1,n.input2),n.squared=te(n.diff,n.diff),n.sum=ot(n.squared);let s=(await n.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return J([n.input1,n.input2,n.diff,n.squared,n.sum]),s}var nc,rc,sc,ac=class{constructor(){he(this,"browser");he(this,"node");he(this,"worker");he(this,"platform","");he(this,"agent","");he(this,"backends",[]);he(this,"initial");he(this,"filter");he(this,"tfjs");he(this,"offscreen");he(this,"perfadd",!1);he(this,"tensorflow",{version:void 0,gpu:void 0});he(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});he(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});he(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});he(this,"cpu",{model:void 0,flags:[]});he(this,"kernels",[]);jn(this,nc,void 0);jn(this,rc,void 0);jn(this,sc,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:tc["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",a=t.match(/\(([^()]+)\)/g);if(a!=null&&a[0]){let n=a[0].match(/\(([^()]+)\)/g);this.platform=n!=null&&n[0]?n[0].replace(/\(|\)/g,""):"",this.agent=t.replace(a[0],""),this.platform[1]&&(this.agent=this.agent.replace(a[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Ka(this,nc)}set Canvas(t){Ar(this,nc,t),globalThis.Canvas=t}get Image(){return Ka(this,rc)}set Image(t){Ar(this,rc,t),globalThis.Image=t}get ImageData(){return Ka(this,sc)}set ImageData(t){Ar(this,sc,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(It().registryFactory);try{this.tensorflow={version:rr().binding?rr().binding.TF_Version:void 0,gpu:rr().binding?rr().binding.isUsingGpuDevice():void 0}}catch(n){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=_n(100,100),a=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof a!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&a&&(this.webgl.version=a.getParameter(a.VERSION),this.webgl.vendor=a.getParameter(a.VENDOR),this.webgl.renderer=a.getParameter(a.RENDERER),this.webgl.shader=a.getParameter(a.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let n=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(n==null?void 0:n.requestAdapterInfo())}}catch(n){this.webgpu.supported=!1}try{this.kernels=Zn(ha()).map(n=>n.kernelName.toLowerCase())}catch(n){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};nc=new WeakMap,rc=new WeakMap,sc=new WeakMap;var ne=new ac;var A0=class{constructor(){he(this,"config");he(this,"element");he(this,"stream");he(this,"devices",[]);he(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(a=>a.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});he(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let i=document.getElementById(t.element);if(i&&i instanceof HTMLVideoElement)this.element=i;else return this.config.debug&&K("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&K("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let a={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(a.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(a.video.height={ideal:this.config.height}),this.config.id&&(a.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&K("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&K("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&K("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(a)}catch(i){return K("webcam",i),`webcam error: ${i}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(i=>{this.element?this.element.onloadeddata=()=>i(!0):i(!1)}),await this.element.play(),this.config.debug&&K("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&K("webcam error","no stream"),"webcam error no stream")});he(this,"pause",()=>{this.element&&this.element.pause()});he(this,"play",async()=>{this.element&&await this.element.play()});he(this,"stop",()=>{this.config.debug&&K("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var J3={};xr(J3,{"affectnet-mobilenet":()=>G2e,age:()=>H2e,"anti-spoofing":()=>k1e,antispoof:()=>_2e,blazeface:()=>P2e,"blazeface-back":()=>j2e,"blazeface-front":()=>q2e,"blazepose-detector":()=>X2e,"blazepose-full":()=>K2e,"blazepose-heavy":()=>Y2e,"blazepose-lite":()=>Z2e,centernet:()=>$2e,default:()=>D1e,efficientpose:()=>J2e,"efficientpose-i-lite":()=>I1e,"efficientpose-ii-lite":()=>S1e,"efficientpose-iv":()=>C1e,emotion:()=>F2e,faceboxes:()=>Q2e,facemesh:()=>D2e,"facemesh-attention":()=>t1e,"facemesh-attention-pinto":()=>e1e,"facemesh-detection-full":()=>a1e,"facemesh-detection-short":()=>n1e,faceres:()=>O2e,"faceres-deep":()=>r1e,gear:()=>o1e,"gear-e1":()=>s1e,"gear-e2":()=>i1e,gender:()=>u1e,"gender-ssrnet-imdb":()=>l1e,handdetect:()=>d1e,"handlandmark-full":()=>p1e,"handlandmark-lite":()=>z2e,"handlandmark-sparse":()=>c1e,handskeleton:()=>h1e,handtrack:()=>L2e,"insightface-efficientnet-b0":()=>T1e,"insightface-ghostnet-strides1":()=>N1e,"insightface-ghostnet-strides2":()=>R1e,"insightface-mobilenet-emore":()=>E1e,"insightface-mobilenet-swish":()=>M1e,iris:()=>W2e,liveness:()=>B2e,meet:()=>m1e,mobileface:()=>f1e,mobilefacenet:()=>g1e,models:()=>V2e,"movenet-lightning":()=>U2e,"movenet-multipose":()=>y1e,"movenet-thunder":()=>x1e,nanodet:()=>A1e,"nanodet-e":()=>_1e,"nanodet-g":()=>P1e,"nanodet-m":()=>$1e,"nanodet-t":()=>F1e,posenet:()=>b1e,rvm:()=>v1e,selfie:()=>w1e});var _2e=853098,P2e=538928,$2e=4030290,F2e=820516,D2e=1477958,O2e=6978814,z2e=2023432,L2e=2964837,W2e=2599092,B2e=592976,V2e=0,U2e=4650216,G2e=6920630,H2e=161240,j2e=538928,q2e=402048,X2e=5928856,K2e=6339202,Y2e=27502466,Z2e=2726402,J2e=5651240,Q2e=2013002,e1e=2387598,t1e=2382414,a1e=1026192,n1e=201268,r1e=13957620,s1e=112438,i1e=112438,o1e=1498916,l1e=161236,u1e=201808,d1e=3515612,p1e=5431368,c1e=5286322,h1e=5502280,m1e=372228,f1e=2183192,g1e=5171976,y1e=9448838,x1e=12477112,A1e=7574558,b1e=5032780,v1e=3739355,w1e=212886,k1e=853098,I1e=2269064,S1e=5651240,C1e=25643252,T1e=13013224,N1e=8093408,R1e=8049584,E1e=6938536,M1e=12168584,_1e=12319156,P1e=7574558,$1e=1887474,F1e=5294216,D1e={antispoof:_2e,blazeface:P2e,centernet:$2e,emotion:F2e,facemesh:D2e,faceres:O2e,"handlandmark-lite":z2e,handtrack:L2e,iris:W2e,liveness:B2e,models:V2e,"movenet-lightning":U2e,"affectnet-mobilenet":G2e,age:H2e,"blazeface-back":j2e,"blazeface-front":q2e,"blazepose-detector":X2e,"blazepose-full":K2e,"blazepose-heavy":Y2e,"blazepose-lite":Z2e,efficientpose:J2e,faceboxes:Q2e,"facemesh-attention-pinto":e1e,"facemesh-attention":t1e,"facemesh-detection-full":a1e,"facemesh-detection-short":n1e,"faceres-deep":r1e,"gear-e1":s1e,"gear-e2":i1e,gear:o1e,"gender-ssrnet-imdb":l1e,gender:u1e,handdetect:d1e,"handlandmark-full":p1e,"handlandmark-sparse":c1e,handskeleton:h1e,meet:m1e,mobileface:f1e,mobilefacenet:g1e,"movenet-multipose":y1e,"movenet-thunder":x1e,nanodet:A1e,posenet:b1e,rvm:v1e,selfie:w1e,"anti-spoofing":k1e,"efficientpose-i-lite":I1e,"efficientpose-ii-lite":S1e,"efficientpose-iv":C1e,"insightface-efficientnet-b0":T1e,"insightface-ghostnet-strides1":N1e,"insightface-ghostnet-strides2":R1e,"insightface-mobilenet-emore":E1e,"insightface-mobilenet-swish":M1e,"nanodet-e":_1e,"nanodet-g":P1e,"nanodet-m":$1e,"nanodet-t":F1e};var Ma={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},xa={};async function O1e(e,t){return Ma.debug&&K("load model fetch:",e,t),fetch(e,t)}function Hk(e){Ma.cacheModels=e.cacheModels,Ma.verbose=e.debug,Ma.modelBasePath=e.modelBasePath}async function _e(e){var u,p,c,d;let t=Fk(Ma.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let a=t.includes("/")?t.split("/"):t.split("\\"),n=a[a.length-1].replace(".json",""),r="indexeddb://"+n;xa[n]={name:n,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:J3[n],inCache:!1,url:""},Ma.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=Ma.cacheSupported&&Ma.cacheModels?await Xn.listModels():{}}catch(h){Ma.cacheSupported=!1}xa[n].inCache=Ma.cacheSupported&&Ma.cacheModels&&Object.keys(s).includes(r),xa[n].url=xa[n].inCache?r:t;let i=typeof fetch=="undefined"?{}:{fetchFunc:(h,m)=>O1e(h,m)},o=new Xp(xa[n].url,i),l=!1;try{o.findIOHandler(),Ma.debug&&K("model load handler:",o.handler)}catch(h){K("error finding model i/o handler:",t,h)}try{let h=await((u=o.handler)==null?void 0:u.load())||null;xa[n].sizeFromManifest=((p=h==null?void 0:h.weightData)==null?void 0:p.byteLength)||0,h?o.loadSync(h):o=await o3(xa[n].inCache?r:t,i),xa[n].sizeLoadedWeights=((d=(c=o.artifacts)==null?void 0:c.weightData)==null?void 0:d.byteLength)||0,Ma.verbose&&K("load:",{model:n,url:o.modelUrl,bytes:xa[n].sizeLoadedWeights}),l=!0}catch(h){K("error loading model:",t,h)}if(l&&Ma.cacheModels&&Ma.cacheSupported&&!xa[n].inCache)try{let h=await o.save(r);Ma.debug&&K("model saved:",r,h)}catch(h){K("error saving model:",t,h)}return o}var Q3="3.1.2";var St={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function W1e(){let e=St.gl;e&&(St.extensions=e.getSupportedExtensions())}function jk(e){var t;if(e.config.backend==="humangl"&&(St.name in It().registry&&!((t=St==null?void 0:St.gl)!=null&&t.getParameter(St.gl.VERSION))&&(K("humangl error: backend invalid context"),e.models.reset()),!lg(St.name))){try{St.canvas=_n(100,100)}catch(r){K("humangl error: cannot create canvas:",r);return}try{if(St.gl=St.canvas.getContext("webgl2",St.webGLattr),!St.gl){K("humangl error: cannot get webgl context");return}if(!St.gl.getParameter(St.gl.VERSION).includes("2.0")){K("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}St.canvas&&(St.canvas.addEventListener("webglcontextlost",s=>{throw K("humangl error:",s.type),K("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),St.canvas.addEventListener("webglcontextrestored",s=>{K("humangl error: context restored:",s)}),St.canvas.addEventListener("webglcontextcreationerror",s=>{K("humangl error: context create:",s)}))}catch(r){K("humangl error: cannot get webgl context:",r);return}try{a0(2,St.gl)}catch(r){K("humangl error: cannot set webgl context:",r);return}try{let r=new Wl(St.gl);Jo(St.name,()=>new Ku(r),St.priority)}catch(r){K("humangl error: cannot register webgl backend:",r);return}try{Zn("webgl").forEach(s=>{let i={...s,backendName:St.name};xn(i)})}catch(r){K("humangl error: cannot update webgl backend registration:",r);return}try{W().flagRegistry.WEBGL_VERSION&&W().set("WEBGL_VERSION",2)}catch(r){K("humangl error: cannot set WebGL backend flags:",r);return}W1e();let a=rr(),n=typeof a.gpgpu!="undefined"?a.getGPGPUContext().gl:null;n?e.config.debug&&K("humangl backend registered:",{webgl:n.getParameter(n.VERSION),renderer:n.getParameter(n.RENDERER)}):K("humangl error: no current gl context:",n,St.gl)}}var ze={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function qk(){ze.tf255=Ge(255,"float32"),ze.tf1=Ge(1,"float32"),ze.tf2=Ge(2,"float32"),ze.tf05=Ge(.5,"float32"),ze.tf127=Ge(127.5,"float32"),ze.rgb=Vt([.2989,.587,.114],"float32")}async function U1e(){var e;return await ne.updateBackend(),(e=ne.tensorflow)!=null&&e.version?"tensorflow":ne.webgpu.supported&&ne.webgpu.backend?"webgpu":ne.webgl.supported&&ne.webgl.backend?"webgl":ne.wasm.supported&&ne.wasm.backend?"wasm":"cpu"}function G1e(e){let t=[];if(!ne.kernels.includes("mod")){let a={kernelName:"Mod",backendName:ha(),kernelFunc:n=>De(()=>xe(n.inputs.a,te(ve(n.inputs.a,n.inputs.b),n.inputs.b)))};xn(a),ne.kernels.push("mod"),t.push("mod")}if(!ne.kernels.includes("floormod")){let a={kernelName:"FloorMod",backendName:ha(),kernelFunc:n=>De(()=>we(te(zp(n.inputs.a,n.inputs.b),n.inputs.b),Bu(n.inputs.a,n.inputs.b)))};xn(a),ne.kernels.push("floormod"),t.push("floormod")}if(!ne.kernels.includes("rotatewithoffset")&&e.softwareKernels){let a={kernelName:"RotateWithOffset",backendName:ha(),kernelFunc:n=>De(()=>{let r=ha();Dp("cpu");let s=fe.rotateWithOffset(n.inputs.image,n.attrs.radians,n.attrs.fillValue,n.attrs.center);return Dp(r),s})};xn(a),ne.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&K("registered kernels:",t)}var Xk={};async function ic(e,t=!1){var a,n;if(e.state="backend",((a=e.config.backend)==null?void 0:a.length)===0&&(e.config.backend=await U1e()),t||ne.initial||e.config.backend&&e.config.backend.length>0&&ha()!==e.config.backend){let r=ae();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&K("running inside web worker"),typeof navigator!="undefined"&&((n=navigator==null?void 0:navigator.userAgent)!=null&&n.toLowerCase().includes("electron"))&&e.config.debug&&K("running inside electron");let s=Object.keys(It().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(jk(e),s=Object.keys(It().registryFactory)),e.config.debug&&K("available backends:",s),ne.browser&&!ne.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&K("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),ne.node&&!ne.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&K(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),ne.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")K("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let i=await navigator.gpu.requestAdapter();if(e.config.debug&&K("enumerated webgpu adapter:",i),!i)K("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let o="requestAdapterInfo"in i?await i.requestAdapterInfo():void 0;K("webgpu adapter info:",o)}}if(s.includes(e.config.backend)||(K(`error: backend ${e.config.backend} not found in registry`),e.config.backend=ne.node?"tensorflow":"webgl",e.config.debug&&K(`override: setting backend ${e.config.backend}`)),e.config.debug&&K("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(W().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&W().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&K("wasm path:",e.config.wasmPath),typeof l0!="undefined")l0(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let i=!1,o=!1;try{i=await W().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),o=await W().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&K(`wasm execution: ${o?"simd":"no simd"} ${i?"multithreaded":"singlethreaded"}`),e.config.debug&&!o&&K("warning: wasm simd support is not enabled")}catch(l){K("wasm detection failed")}}try{await Dp(e.config.backend),await Op()}catch(i){return K("error: cannot set backend:",e.config.backend,i),!1}e.config.debug&&(Xk=JSON.parse(JSON.stringify(W().flags)))}if((ha()==="humangl"||ha()==="webgl")&&(W().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&W().set("WEBGL_USE_SHAPES_UNIFORMS",!0),W().flagRegistry.WEBGL_EXP_CONV&&W().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(K("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),W().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),ha(),e.config.debug){let s=W().flags,i={};for(let o of Object.keys(s))Xk[o]!==s[o]&&(i[o]=s[o]);e.config.debug&&Object.keys(i).length>0&&K("backend:",ha(),"flags:",i)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&K("flags:",e.config.flags);for(let[s,i]of Object.entries(e.config.flags))W().set(s,i)}ig(),qk(),e.performance.initBackend=Math.trunc(ae()-r),e.config.backend=ha(),await ne.updateBackend(),G1e(e.config)}return!0}function b0(e,t){for(let a of e){let n={kernelName:a,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&K("kernelFunc",a,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};xn(n)}ne.kernels=Zn(ha()).map(a=>a.kernelName.toLowerCase())}var C0={};xr(C0,{all:()=>vge,body:()=>w0,canvas:()=>bge,face:()=>v0,gesture:()=>S0,hand:()=>k0,init:()=>iy,object:()=>I0,options:()=>Dt,person:()=>Age});var vn=e=>{if(!e)K("draw error: invalid canvas");else if(!e.getContext)K("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)K("draw error: cannot get canvas context");else return t}return null},ll=e=>Math.round(e*180/Math.PI),ut=(e,t,a)=>e.replace(t,typeof a=="number"?a.toFixed(1):a),ul=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let a=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${a[0]}, ${a[1]}, ${a[2]}, ${t.alpha})`};function wn(e,t,a,n,r){let s=t.replace(/\[.*\]/g,"").split(` `).map(o=>o.trim()),i=Math.max(0,a);for(let o=s.length-1;o>=0;o--){let l=o*r.lineHeight+n;r.shadowColor&&r.shadowColor!==""&&(e.fillStyle=r.shadowColor,e.fillText(s[o],i+5,l+16)),e.fillStyle=r.labelColor,e.fillText(s[o],i+4,l+15)}}function ur(e,t,a,n,r){e.fillStyle=ul(n,r),e.beginPath(),e.arc(t,a,r.pointSize,0,2*Math.PI),e.fill()}function dr(e,t,a,n,r,s){if(e.beginPath(),e.lineWidth=s.lineWidth,s.useCurves){let i=(t+t+n)/2,o=(a+a+r)/2;e.ellipse(i,o,n/2,r/2,0,0,2*Math.PI)}else e.moveTo(t+s.roundRect,a),e.lineTo(t+n-s.roundRect,a),e.quadraticCurveTo(t+n,a,t+n,a+s.roundRect),e.lineTo(t+n,a+r-s.roundRect),e.quadraticCurveTo(t+n,a+r,t+n-s.roundRect,a+r),e.lineTo(t+s.roundRect,a+r),e.quadraticCurveTo(t,a+r,t,a+r-s.roundRect),e.lineTo(t,a+s.roundRect),e.quadraticCurveTo(t,a,t+s.roundRect,a),e.closePath();e.stroke()}function ey(e,t,a){if(!(t.length<2)){e.beginPath(),e.moveTo(t[0][0],t[0][1]);for(let n of t)e.strokeStyle=ul(n[2]||0,a),e.lineTo(Math.trunc(n[0]),Math.trunc(n[1]));e.stroke(),a.fillPolygons&&(e.closePath(),e.fill())}}function Yk(e,t,a){if(!(t.length<2)){if(e.lineWidth=a.lineWidth,!a.useCurves||t.length<=2){ey(e,t,a);return}e.moveTo(t[0][0],t[0][1]);for(let n=0;noc[e]),$be=j1e.map(e=>oc[e]),Fbe=q1e.map(e=>oc[e]);function fs(e){let t=e.map(a=>a[0]);return t.push(e[e.length-1][1]),t}var X1e=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],K1e=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Y1e=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],Z1e=[[474,475],[475,476],[476,477],[477,474]],J1e=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Q1e=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],ege=[[469,470],[470,471],[471,472],[472,469]],tge=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]],Dbe={lips:fs(X1e),leftEye:fs(K1e),leftEyebrow:fs(Y1e),leftIris:fs(Z1e),rightEye:fs(J1e),rightEyebrow:fs(Q1e),rightIris:fs(ege),faceOval:fs(tge)};var age=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],nge=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],rge=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],sge=[[474,475],[475,476],[476,477],[477,474]],ige=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],oge=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],lge=[[469,470],[470,471],[471,472],[472,469]],uge=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]];function gs(e){let t=e.map(a=>a[0]);return t.push(e[e.length-1][1]),t}var dge={lips:gs(age),leftEye:gs(nge),leftEyebrow:gs(rge),leftIris:gs(sge),rightEye:gs(ige),rightEyebrow:gs(oge),rightIris:gs(lge),faceOval:gs(uge)},pge=Object.entries(dge).map(([e,t])=>t.map(a=>[a,e])).flat(),Obe=new Map(pge),lc=[61,146,91,181,84,17,314,405,321,375,291,185,40,39,37,0,267,269,270,409,78,95,88,178,87,14,317,402,318,324,308,191,80,81,82,13,312,311,310,415,76,77,90,180,85,16,315,404,320,307,306,184,74,73,72,11,302,303,304,408,62,96,89,179,86,15,316,403,319,325,292,183,42,41,38,12,268,271,272,407],cl=[33,7,163,144,145,153,154,155,133,246,161,160,159,158,157,173,130,25,110,24,23,22,26,112,243,247,30,29,27,28,56,190,226,31,228,229,230,231,232,233,244,113,225,224,223,222,221,189,35,124,46,53,52,65,143,111,117,118,119,120,121,128,245,156,70,63,105,66,107,55,193],hl=[263,249,390,373,374,380,381,382,362,466,388,387,386,385,384,398,359,255,339,254,253,252,256,341,463,467,260,259,257,258,286,414,446,261,448,449,450,451,452,453,464,342,445,444,443,442,441,413,265,353,276,283,282,295,372,340,346,347,348,349,350,357,465,383,300,293,334,296,336,285,417];var rt;function cge(e,t){var n,r,s,i,o,l,u,p,c;if(!rt.drawLabels||((n=rt.faceLabels)==null?void 0:n.length)===0)return;let a=rt.faceLabels.slice();if(a=ut(a,"[id]",e.id.toFixed(0)),e.score&&(a=ut(a,"[score]",100*e.score)),e.gender&&(a=ut(a,"[gender]",e.gender)),e.genderScore&&(a=ut(a,"[genderScore]",100*e.genderScore)),e.age&&(a=ut(a,"[age]",e.age)),e.distance&&(a=ut(a,"[distance]",100*e.distance)),e.real&&(a=ut(a,"[real]",100*e.real)),e.live&&(a=ut(a,"[live]",100*e.live)),e.emotion&&e.emotion.length>0){let d=e.emotion.map(h=>`${Math.trunc(100*h.score)}% ${h.emotion}`);d.length>3&&(d.length=3),a=ut(a,"[emotions]",d.join(" "))}(s=(r=e.rotation)==null?void 0:r.angle)!=null&&s.roll&&(a=ut(a,"[roll]",ll(e.rotation.angle.roll))),(o=(i=e.rotation)==null?void 0:i.angle)!=null&&o.yaw&&(a=ut(a,"[yaw]",ll(e.rotation.angle.yaw))),(u=(l=e.rotation)==null?void 0:l.angle)!=null&&u.pitch&&(a=ut(a,"[pitch]",ll(e.rotation.angle.pitch))),(c=(p=e.rotation)==null?void 0:p.gaze)!=null&&c.bearing&&(a=ut(a,"[gaze]",ll(e.rotation.gaze.bearing))),wn(t,a,e.box[0],e.box[1],rt)}function hge(e,t){var a,n,r,s;if((a=e.annotations)!=null&&a.leftEyeIris&&((n=e.annotations)!=null&&n.leftEyeIris[0])){t.strokeStyle=rt.useDepth?"rgba(255, 200, 255, 0.3)":rt.color,t.beginPath();let i=Math.abs(e.annotations.leftEyeIris[3][0]-e.annotations.leftEyeIris[1][0])/2,o=Math.abs(e.annotations.leftEyeIris[4][1]-e.annotations.leftEyeIris[2][1])/2;t.ellipse(e.annotations.leftEyeIris[0][0],e.annotations.leftEyeIris[0][1],i,o,0,0,2*Math.PI),t.stroke(),rt.fillPolygons&&(t.fillStyle=rt.useDepth?"rgba(255, 255, 200, 0.3)":rt.color,t.fill())}if((r=e.annotations)!=null&&r.rightEyeIris&&((s=e.annotations)!=null&&s.rightEyeIris[0])){t.strokeStyle=rt.useDepth?"rgba(255, 200, 255, 0.3)":rt.color,t.beginPath();let i=Math.abs(e.annotations.rightEyeIris[3][0]-e.annotations.rightEyeIris[1][0])/2,o=Math.abs(e.annotations.rightEyeIris[4][1]-e.annotations.rightEyeIris[2][1])/2;t.ellipse(e.annotations.rightEyeIris[0][0],e.annotations.rightEyeIris[0][1],i,o,0,0,2*Math.PI),t.stroke(),rt.fillPolygons&&(t.fillStyle=rt.useDepth?"rgba(255, 255, 200, 0.3)":rt.color,t.fill())}}function mge(e,t){var a;if(rt.drawGaze&&((a=e.rotation)!=null&&a.angle)&&typeof Path2D!="undefined"){t.strokeStyle="pink";let n=e.box[0]+e.box[2]/2-e.box[3]*ll(e.rotation.angle.yaw)/90,r=e.box[1]+e.box[3]/2+e.box[2]*ll(e.rotation.angle.pitch)/90,s=new Path2D(` M ${e.box[0]+e.box[2]/2} ${e.box[1]} C diff --git a/dist/human.node-gpu.js b/dist/human.node-gpu.js index f8fd8611..3a0ebf8f 100644 --- a/dist/human.node-gpu.js +++ b/dist/human.node-gpu.js @@ -96,7 +96,7 @@ c31 * m[6] + c32 * m[7] + c33 * m[8]; gl_FragColor.a = c22.a; } -`;var Qt=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(r,s)=>(n[s]=0,r))},_t=class{constructor(t,n,o){w(this,"uniform",{});w(this,"attribute",{});w(this,"gl");w(this,"id");w(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(h(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(h("filter: could not create shader"),null)});this.gl=t;let r=this.compile(n,this.gl.VERTEX_SHADER),s=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){h("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){h(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),Qt(n,"attribute",this.attribute);for(let A in this.attribute)this.attribute[A]=this.gl.getAttribLocation(this.id,A);Qt(n,"uniform",this.uniform),Qt(o,"uniform",this.uniform);for(let A in this.uniform)this.uniform[A]=this.gl.getUniformLocation(this.id,A)}}};function G1(){let e=0,t=null,n=!1,o=-1,r=[null,null],s=[],A=null,a=null,l=Ae(100,100),c={},x={INTERMEDIATE:1},i=l.getContext("webgl");if(!i){h("filter: cannot get webgl context");return}this.gl=i;function f(g,p){if(!(g===l.width&&p===l.height)){if(l.width=g,l.height=p,!A){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);A=i.createBuffer(),i.bindBuffer(i.ARRAY_BUFFER,A),i.bufferData(i.ARRAY_BUFFER,b,i.STATIC_DRAW),i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}i.viewport(0,0,l.width,l.height),r=[null,null]}}function d(g,p){let b=i.createFramebuffer();i.bindFramebuffer(i.FRAMEBUFFER,b);let k=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,k);let P=i.createTexture();return i.bindTexture(i.TEXTURE_2D,P),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,g,p,0,i.RGBA,i.UNSIGNED_BYTE,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.framebufferTexture2D(i.FRAMEBUFFER,i.COLOR_ATTACHMENT0,i.TEXTURE_2D,P,0),i.bindTexture(i.TEXTURE_2D,null),i.bindFramebuffer(i.FRAMEBUFFER,null),{fbo:b,texture:P}}function m(g){return r[g]=r[g]||d(l.width,l.height),r[g]}function y(g=0){if(!a)return;let p=null,b=null,k=!1;e===0?p=t:p=m(o).texture||null,e++,n&&!(g&x.INTERMEDIATE)?(b=null,k=e%2===0):(o=(o+1)%2,b=m(o).fbo||null),i.bindTexture(i.TEXTURE_2D,p),i.bindFramebuffer(i.FRAMEBUFFER,b),i.uniform1f(a.uniform.flipY,k?-1:1),i.drawArrays(i.TRIANGLES,0,6)}function u(g){if(c[g])return a=c[g],i.useProgram((a?a.id:null)||null),a;if(a=new _t(i,C1,g),!a)return h("filter: could not get webgl program"),null;let p=Float32Array.BYTES_PER_ELEMENT,b=4*p;return i.enableVertexAttribArray(a.attribute.pos),i.vertexAttribPointer(a.attribute.pos,2,i.FLOAT,!1,b,0*p),i.enableVertexAttribArray(a.attribute.uv),i.vertexAttribPointer(a.attribute.uv,2,i.FLOAT,!1,b,2*p),c[g]=a,a}let T={colorMatrix:g=>{let p=new Float32Array(g);p[4]/=255,p[9]/=255,p[14]/=255,p[19]/=255;let b=p[18]===1&&p[3]===0&&p[8]===0&&p[13]===0&&p[15]===0&&p[16]===0&&p[17]===0&&p[19]===0?D1:W1,k=u(b);k&&(i.uniform1fv(k.uniform.m,p),y())},brightness:g=>{let p=(g||0)+1;T.colorMatrix([p,0,0,0,0,0,p,0,0,0,0,0,p,0,0,0,0,0,1,0])},saturation:g=>{let p=(g||0)*2/3+1,b=(p-1)*-.5;T.colorMatrix([p,b,b,0,0,b,p,b,0,0,b,b,p,0,0,0,0,0,1,0])},desaturate:()=>{T.saturation(-1)},contrast:g=>{let p=(g||0)+1,b=-128*(p-1);T.colorMatrix([p,0,0,0,b,0,p,0,0,b,0,0,p,0,b,0,0,0,1,0])},negative:()=>{T.contrast(-2)},hue:g=>{g=(g||0)/180*Math.PI;let p=Math.cos(g),b=Math.sin(g),k=.213,P=.715,N=.072;T.colorMatrix([k+p*(1-k)+b*-k,P+p*-P+b*-P,N+p*-N+b*(1-N),0,0,k+p*-k+b*.143,P+p*(1-P)+b*.14,N+p*-N+b*-.283,0,0,k+p*-k+b*-(1-k),P+p*-P+b*P,N+p*(1-N)+b*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{T.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{T.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{T.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{T.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{T.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{T.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{T.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{T.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:g=>{let p=new Float32Array(g),b=1/l.width,k=1/l.height,P=u(H1);P&&(i.uniform1fv(P.uniform.m,p),i.uniform2f(P.uniform.px,b,k),y())},detectEdges:()=>{T.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{T.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{T.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:g=>{let p=g||1;T.convolution.call(this,[0,-1*p,0,-1*p,1+4*p,-1*p,0,-1*p,0])},emboss:g=>{let p=g||1;T.convolution.call(this,[-2*p,-1*p,0,-1*p,1,1*p,0,1*p,2*p])},blur:g=>{let p=g/7/l.width,b=g/7/l.height,k=u(B1);k&&(i.uniform2f(k.uniform.px,0,b),y(x.INTERMEDIATE),i.uniform2f(k.uniform.px,p,0),y())},pixelate:g=>{let p=g/l.width,b=g/l.height,k=u(F1);k&&(i.uniform2f(k.uniform.size,p,b),y())}};this.add=function(g){let p=Array.prototype.slice.call(arguments,1),b=T[g];s.push({func:b,args:p})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(g){f(g.width,g.height),e=0,t||(t=i.createTexture()),i.bindTexture(i.TEXTURE_2D,t),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.NEAREST),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.NEAREST),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,g);for(let p=0;px.data())),A=Math.max(s[0][0],s[1][0],s[2][0]),l=(A>1?255:1)/A,c;if(l>1){let x=[U.sub(n[0],o[0]),U.sub(n[1],o[1]),U.sub(n[2],o[2])],i=[U.sub(r[0],o[0]),U.sub(r[1],o[1]),U.sub(r[2],o[2])],f=[U.mul(x[0],l),U.mul(x[1],l),U.mul(x[2],l)],d=U.stack([f[0],f[1],f[2]],2);c=U.reshape(d,[1,t.shape[0]||0,t.shape[1]||0,3]),U.dispose([...x,...i,...f,d])}else c=U.expandDims(t,0);return U.dispose([...n,...o,...r,n,t,e]),c}var X2=3840,R0=null,M0=null,y2=null,e0,ne={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function $t(){ne.inputSum=0,ne.cacheDiff=1,ne.sumMethod=0,ne.inputTensor=void 0}function Ae(e,t){let n;if(R.browser)if(R.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof R.Canvas!="undefined")n=new R.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof R.Canvas!="undefined"?n=new R.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function q2(e,t){let n=t||Ae(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function U2(e,t,n=!0){var f,d,m;if(!e)return t.debug&&h("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof I.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof I.Tensor){let y=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)y=I.expandDims(e,0);else if(e.shape[2]===4){let u=I.slice3d(e,[0,0,0],[-1,-1,3]);y=I.expandDims(u,0),I.dispose(u)}}else e.shape.length===4&&(e.shape[3]===3?y=I.clone(e):e.shape[3]===4&&(y=I.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(y==null||y.shape.length!==4||y.shape[0]!==1||y.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(y.dtype==="int32"){let u=I.cast(y,"float32");I.dispose(y),y=u}return{tensor:y,canvas:t.filter.return?M0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&h("input stream is not ready"),{tensor:null,canvas:R0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!r)return t.debug&&h("cannot determine input dimensions"),{tensor:null,canvas:R0};let s=o,A=r;if(s>X2&&(s=X2,A=Math.trunc(s*r/o)),A>X2&&(A=X2,s=Math.trunc(A*o/r)),(((f=t.filter)==null?void 0:f.width)||0)>0?s=t.filter.width:(((d=t.filter)==null?void 0:d.height)||0)>0&&(s=o*((t.filter.height||0)/r)),(t.filter.height||0)>0?A=t.filter.height:(t.filter.width||0)>0&&(A=r*((t.filter.width||0)/o)),!s||!A)throw new Error("input error: cannot determine dimension");(!R0||R0.width!==s||R0.height!==A)&&(R0=Ae(s,A));let a=R0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?a.putImageData(e,0,0):t.filter.flip&&typeof a.translate!="undefined"?(a.translate(o,0),a.scale(-1,1),a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),a.setTransform(1,0,0,1,0,0)):a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),(!M0||R0.width!==M0.width||R0.height!==M0.height)&&(M0=Ae(R0.width,R0.height)),t.filter.enabled&&R.webgl.supported?(e0||(e0=R.browser?new G1:null),R.filter=!!e0,e0!=null&&e0.add?(e0.reset(),t.filter.brightness!==0&&e0.add("brightness",t.filter.brightness),t.filter.contrast!==0&&e0.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&e0.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&e0.add("blur",t.filter.blur),t.filter.saturation!==0&&e0.add("saturation",t.filter.saturation),t.filter.hue!==0&&e0.add("hue",t.filter.hue),t.filter.negative&&e0.add("negative"),t.filter.sepia&&e0.add("sepia"),t.filter.vintage&&e0.add("brownie"),t.filter.sepia&&e0.add("sepia"),t.filter.kodachrome&&e0.add("kodachrome"),t.filter.technicolor&&e0.add("technicolor"),t.filter.polaroid&&e0.add("polaroid"),t.filter.pixelate!==0&&e0.add("pixelate",t.filter.pixelate),((m=e0.get())==null?void 0:m.length)>1?M0=e0.apply(R0):M0=e0.draw(R0)):(t.debug&&h("input process error: cannot initialize filters"),R.webgl.supported=!1,t.filter.enabled=!1,q2(R0,M0))):(q2(R0,M0),e0&&(e0=null),R.filter=!!e0),!n)return{tensor:null,canvas:M0};if(!M0)throw new Error("canvas error: cannot create output");let l,c=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(R.browser&&I.browser)l=I.browser?I.browser.fromPixels(e):null;else{c=e.data.length/e.height/e.width;let y=new Uint8Array(e.data.buffer);l=I.tensor(y,[e.height,e.width,c],"int32")}else if((!y2||M0.width!==y2.width||M0.height!==y2.height)&&(y2=Ae(M0.width,M0.height)),I.browser&&R.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=I.browser.fromPixels(M0):(y2=q2(M0),l=I.browser.fromPixels(y2));else{let T=q2(M0).getContext("2d").getImageData(0,0,s,A);c=T.data.length/s/A;let g=new Uint8Array(T.data.buffer);l=I.tensor(g,[s,A,c])}if(c===4){let y=I.slice3d(l,[0,0,0],[-1,-1,3]);I.dispose(l),l=y}if(!l)throw new Error("input error: cannot create tensor");let x=I.cast(l,"float32"),i=t.filter.equalization?await Z2(x):I.expandDims(x,0);if(I.dispose([l,x]),t.filter.autoBrightness){let y=I.max(i),u=await y.data();t.filter.brightness=u[0]>1?1-u[0]/255:1-u[0],I.dispose(y)}return{tensor:i,canvas:t.filter.return?M0:null}}async function V1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!ne.inputTensor)ne.inputTensor=I.clone(t);else if(ne.inputTensor.shape[1]!==t.shape[1]||ne.inputTensor.shape[2]!==t.shape[2])I.dispose(ne.inputTensor),ne.inputTensor=I.clone(t);else{let o={};o.diff=I.sub(t,ne.inputTensor),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;I.dispose([ne.inputTensor,o.diff,o.squared,o.sum]),ne.inputTensor=I.clone(t),n=s<=(e.cacheSensitivity||0)}return n}async function Z1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||h("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||h("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=I.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?I.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):I.clone(n),o.diff=I.sub(o.input1,o.input2),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return I.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),s}var z2,S2,j2,E2=class{constructor(){w(this,"browser");w(this,"node");w(this,"worker");w(this,"platform","");w(this,"agent","");w(this,"backends",[]);w(this,"initial");w(this,"filter");w(this,"tfjs");w(this,"offscreen");w(this,"perfadd",!1);w(this,"tensorflow",{version:void 0,gpu:void 0});w(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});w(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});w(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});w(this,"cpu",{model:void 0,flags:[]});w(this,"kernels",[]);ue(this,z2,void 0);ue(this,S2,void 0);ue(this,j2,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:W0.version["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Y0(this,z2)}set Canvas(t){Re(this,z2,t),globalThis.Canvas=t}get Image(){return Y0(this,S2)}set Image(t){Re(this,S2,t),globalThis.Image=t}get ImageData(){return Y0(this,j2)}set ImageData(t){Re(this,j2,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(W0.engine().registryFactory);try{this.tensorflow={version:W0.backend().binding?W0.backend().binding.TF_Version:void 0,gpu:W0.backend().binding?W0.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W0.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W0.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=Ae(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=W0.getKernelsForBackend(W0.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};z2=new WeakMap,S2=new WeakMap,j2=new WeakMap;var R=new E2;var K2=class{constructor(){w(this,"config");w(this,"element");w(this,"stream");w(this,"devices",[]);w(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});w(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let A=document.getElementById(t.element);if(A&&A instanceof HTMLVideoElement)this.element=A;else return this.config.debug&&h("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&h("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(n.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&h("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&h("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&h("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(A){return h("webcam",A),`webcam error: ${A}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(A=>{this.element?this.element.onloadeddata=()=>A(!0):A(!1)}),await this.element.play(),this.config.debug&&h("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&h("webcam error","no stream"),"webcam error no stream")});w(this,"pause",()=>{this.element&&this.element.pause()});w(this,"play",async()=>{this.element&&await this.element.play()});w(this,"stop",()=>{this.config.debug&&h("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var f2=G(H());var e5={};ze(e5,{"affectnet-mobilenet":()=>br,age:()=>gr,"anti-spoofing":()=>_r,antispoof:()=>ar,blazeface:()=>ir,"blazeface-back":()=>Tr,"blazeface-front":()=>vr,"blazepose-detector":()=>Rr,"blazepose-full":()=>Mr,"blazepose-heavy":()=>Pr,"blazepose-lite":()=>kr,centernet:()=>lr,default:()=>ds,efficientpose:()=>wr,"efficientpose-i-lite":()=>$r,"efficientpose-ii-lite":()=>es,"efficientpose-iv":()=>ts,emotion:()=>cr,faceboxes:()=>Er,facemesh:()=>dr,"facemesh-attention":()=>Sr,"facemesh-attention-pinto":()=>zr,"facemesh-detection-full":()=>jr,"facemesh-detection-short":()=>Ir,faceres:()=>xr,"faceres-deep":()=>Nr,gear:()=>Cr,"gear-e1":()=>Lr,"gear-e2":()=>Or,gender:()=>Dr,"gender-ssrnet-imdb":()=>Wr,handdetect:()=>Fr,"handlandmark-full":()=>Br,"handlandmark-lite":()=>yr,"handlandmark-sparse":()=>Hr,handskeleton:()=>Gr,handtrack:()=>fr,"insightface-efficientnet-b0":()=>ns,"insightface-ghostnet-strides1":()=>os,"insightface-ghostnet-strides2":()=>rs,"insightface-mobilenet-emore":()=>ss,"insightface-mobilenet-swish":()=>As,iris:()=>mr,liveness:()=>pr,meet:()=>Vr,mobileface:()=>Zr,mobilefacenet:()=>Xr,models:()=>ur,"movenet-lightning":()=>hr,"movenet-multipose":()=>qr,"movenet-thunder":()=>Ur,nanodet:()=>Yr,"nanodet-e":()=>as,"nanodet-g":()=>is,"nanodet-m":()=>ls,"nanodet-t":()=>cs,posenet:()=>Kr,rvm:()=>Jr,selfie:()=>Qr});var ar=853098,ir=538928,lr=4030290,cr=820516,dr=1477958,xr=6978814,yr=2023432,fr=2964837,mr=2599092,pr=592976,ur=0,hr=4650216,br=6920630,gr=161240,Tr=538928,vr=402048,Rr=5928856,Mr=6339202,Pr=27502466,kr=2726402,wr=5651240,Er=2013002,zr=2387598,Sr=2382414,jr=1026192,Ir=201268,Nr=13957620,Lr=112438,Or=112438,Cr=1498916,Wr=161236,Dr=201808,Fr=3515612,Br=5431368,Hr=5286322,Gr=5502280,Vr=372228,Zr=2183192,Xr=5171976,qr=9448838,Ur=12477112,Yr=7574558,Kr=5032780,Jr=3739355,Qr=212886,_r=853098,$r=2269064,es=5651240,ts=25643252,ns=13013224,os=8093408,rs=8049584,ss=6938536,As=12168584,as=12319156,is=7574558,ls=1887474,cs=5294216,ds={antispoof:ar,blazeface:ir,centernet:lr,emotion:cr,facemesh:dr,faceres:xr,"handlandmark-lite":yr,handtrack:fr,iris:mr,liveness:pr,models:ur,"movenet-lightning":hr,"affectnet-mobilenet":br,age:gr,"blazeface-back":Tr,"blazeface-front":vr,"blazepose-detector":Rr,"blazepose-full":Mr,"blazepose-heavy":Pr,"blazepose-lite":kr,efficientpose:wr,faceboxes:Er,"facemesh-attention-pinto":zr,"facemesh-attention":Sr,"facemesh-detection-full":jr,"facemesh-detection-short":Ir,"faceres-deep":Nr,"gear-e1":Lr,"gear-e2":Or,gear:Cr,"gender-ssrnet-imdb":Wr,gender:Dr,handdetect:Fr,"handlandmark-full":Br,"handlandmark-sparse":Hr,handskeleton:Gr,meet:Vr,mobileface:Zr,mobilefacenet:Xr,"movenet-multipose":qr,"movenet-thunder":Ur,nanodet:Yr,posenet:Kr,rvm:Jr,selfie:Qr,"anti-spoofing":_r,"efficientpose-i-lite":$r,"efficientpose-ii-lite":es,"efficientpose-iv":ts,"insightface-efficientnet-b0":ns,"insightface-ghostnet-strides1":os,"insightface-ghostnet-strides2":rs,"insightface-mobilenet-emore":ss,"insightface-mobilenet-swish":As,"nanodet-e":as,"nanodet-g":is,"nanodet-m":ls,"nanodet-t":cs};var D0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},I0={};async function xs(e,t){return D0.debug&&h("load model fetch:",e,t),fetch(e,t)}function X1(e){D0.cacheModels=e.cacheModels,D0.verbose=e.debug,D0.modelBasePath=e.modelBasePath}async function L(e){var c,x,i,f;let t=O1(D0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),r="indexeddb://"+o;I0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:e5[o],inCache:!1,url:""},D0.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=D0.cacheSupported&&D0.cacheModels?await f2.io.listModels():{}}catch(d){D0.cacheSupported=!1}I0[o].inCache=D0.cacheSupported&&D0.cacheModels&&Object.keys(s).includes(r),I0[o].url=I0[o].inCache?r:t;let A=typeof fetch=="undefined"?{}:{fetchFunc:(d,m)=>xs(d,m)},a=new f2.GraphModel(I0[o].url,A),l=!1;try{a.findIOHandler(),D0.debug&&h("model load handler:",a.handler)}catch(d){h("error finding model i/o handler:",t,d)}try{let d=await((c=a.handler)==null?void 0:c.load())||null;I0[o].sizeFromManifest=((x=d==null?void 0:d.weightData)==null?void 0:x.byteLength)||0,d?a.loadSync(d):a=await f2.loadGraphModel(I0[o].inCache?r:t,A),I0[o].sizeLoadedWeights=((f=(i=a.artifacts)==null?void 0:i.weightData)==null?void 0:f.byteLength)||0,D0.verbose&&h("load:",{model:o,url:a.modelUrl,bytes:I0[o].sizeLoadedWeights}),l=!0}catch(d){h("error loading model:",t,d)}if(l&&D0.cacheModels&&D0.cacheSupported&&!I0[o].inCache)try{let d=await a.save(r);D0.debug&&h("model saved:",r,d)}catch(d){h("error saving model:",t,d)}return a}var t5="3.1.1";var S=G(H());var u0=G(H());var o0={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ms(){let e=o0.gl;e&&(o0.extensions=e.getSupportedExtensions())}function q1(e){var t;if(e.config.backend==="humangl"&&(o0.name in u0.engine().registry&&!((t=o0==null?void 0:o0.gl)!=null&&t.getParameter(o0.gl.VERSION))&&(h("humangl error: backend invalid context"),e.models.reset()),!u0.findBackend(o0.name))){try{o0.canvas=Ae(100,100)}catch(r){h("humangl error: cannot create canvas:",r);return}try{if(o0.gl=o0.canvas.getContext("webgl2",o0.webGLattr),!o0.gl){h("humangl error: cannot get webgl context");return}if(!o0.gl.getParameter(o0.gl.VERSION).includes("2.0")){h("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}o0.canvas&&(o0.canvas.addEventListener("webglcontextlost",s=>{throw h("humangl error:",s.type),h("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),o0.canvas.addEventListener("webglcontextrestored",s=>{h("humangl error: context restored:",s)}),o0.canvas.addEventListener("webglcontextcreationerror",s=>{h("humangl error: context create:",s)}))}catch(r){h("humangl error: cannot get webgl context:",r);return}try{u0.setWebGLContext(2,o0.gl)}catch(r){h("humangl error: cannot set webgl context:",r);return}try{let r=new u0.GPGPUContext(o0.gl);u0.registerBackend(o0.name,()=>new u0.MathBackendWebGL(r),o0.priority)}catch(r){h("humangl error: cannot register webgl backend:",r);return}try{u0.getKernelsForBackend("webgl").forEach(s=>{let A={...s,backendName:o0.name};u0.registerKernel(A)})}catch(r){h("humangl error: cannot update webgl backend registration:",r);return}try{u0.env().flagRegistry.WEBGL_VERSION&&u0.env().set("WEBGL_VERSION",2)}catch(r){h("humangl error: cannot set WebGL backend flags:",r);return}ms();let n=u0.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&h("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):h("humangl error: no current gl context:",o,o0.gl)}}var Se=G(H()),C={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function U1(){C.tf255=Se.scalar(255,"float32"),C.tf1=Se.scalar(1,"float32"),C.tf2=Se.scalar(2,"float32"),C.tf05=Se.scalar(.5,"float32"),C.tf127=Se.scalar(127.5,"float32"),C.rgb=Se.tensor1d([.2989,.587,.114],"float32")}async function hs(){var e;return await R.updateBackend(),(e=R.tensorflow)!=null&&e.version?"tensorflow":R.webgpu.supported&&R.webgpu.backend?"webgpu":R.webgl.supported&&R.webgl.backend?"webgl":R.wasm.supported&&R.wasm.backend?"wasm":"cpu"}function bs(e){let t=[];if(!R.kernels.includes("mod")){let n={kernelName:"Mod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.sub(o.inputs.a,S.mul(S.div(o.inputs.a,o.inputs.b),o.inputs.b)))};S.registerKernel(n),R.kernels.push("mod"),t.push("mod")}if(!R.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.add(S.mul(S.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),S.mod(o.inputs.a,o.inputs.b)))};S.registerKernel(n),R.kernels.push("floormod"),t.push("floormod")}if(!R.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>{let r=S.getBackend();S.setBackend("cpu");let s=S.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return S.setBackend(r),s})};S.registerKernel(n),R.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&h("registered kernels:",t)}var Y1={};async function I2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await hs()),t||R.initial||e.config.backend&&e.config.backend.length>0&&S.getBackend()!==e.config.backend){let r=v();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&h("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&h("running inside electron");let s=Object.keys(S.engine().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(q1(e),s=Object.keys(S.engine().registryFactory)),e.config.debug&&h("available backends:",s),R.browser&&!R.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&h("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),R.node&&!R.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&h(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),R.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")h("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let A=await navigator.gpu.requestAdapter();if(e.config.debug&&h("enumerated webgpu adapter:",A),!A)h("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let a="requestAdapterInfo"in A?await A.requestAdapterInfo():void 0;h("webgpu adapter info:",a)}}if(s.includes(e.config.backend)||(h(`error: backend ${e.config.backend} not found in registry`),e.config.backend=R.node?"tensorflow":"webgl",e.config.debug&&h(`override: setting backend ${e.config.backend}`)),e.config.debug&&h("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(S.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&S.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&h("wasm path:",e.config.wasmPath),typeof S.setWasmPaths!="undefined")S.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let A=!1,a=!1;try{A=await S.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),a=await S.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&h(`wasm execution: ${a?"simd":"no simd"} ${A?"multithreaded":"singlethreaded"}`),e.config.debug&&!a&&h("warning: wasm simd support is not enabled")}catch(l){h("wasm detection failed")}}try{await S.setBackend(e.config.backend),await S.ready()}catch(A){return h("error: cannot set backend:",e.config.backend,A),!1}e.config.debug&&(Y1=JSON.parse(JSON.stringify(S.env().flags)))}if((S.getBackend()==="humangl"||S.getBackend()==="webgl")&&(S.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&S.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),S.env().flagRegistry.WEBGL_EXP_CONV&&S.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(h("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),S.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),S.getBackend(),e.config.debug){let s=S.env().flags,A={};for(let a of Object.keys(s))Y1[a]!==s[a]&&(A[a]=s[a]);e.config.debug&&Object.keys(A).length>0&&h("backend:",S.getBackend(),"flags:",A)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&h("flags:",e.config.flags);for(let[s,A]of Object.entries(e.config.flags))S.env().set(s,A)}S.enableProdMode(),U1(),e.performance.initBackend=Math.trunc(v()-r),e.config.backend=S.getBackend(),await R.updateBackend(),bs(e.config)}return!0}function J2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&h("kernelFunc",n,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};S.registerKernel(o)}R.kernels=S.getKernelsForBackend(S.getBackend()).map(n=>n.kernelName.toLowerCase())}var nt={};ze(nt,{all:()=>Js,body:()=>_2,canvas:()=>Ks,face:()=>Q2,gesture:()=>tt,hand:()=>$2,init:()=>i5,object:()=>et,options:()=>f0,person:()=>Ys});var oe=e=>{if(!e)h("draw error: invalid canvas");else if(!e.getContext)h("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)h("draw error: cannot get canvas context");else return t}return null},Je=e=>Math.round(e*180/Math.PI),Y=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Qe=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function re(e,t,n,o,r){let s=t.replace(/\[.*\]/g,"").split(` +`;var Qt=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(r,s)=>(n[s]=0,r))},_t=class{constructor(t,n,o){w(this,"uniform",{});w(this,"attribute",{});w(this,"gl");w(this,"id");w(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(h(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(h("filter: could not create shader"),null)});this.gl=t;let r=this.compile(n,this.gl.VERTEX_SHADER),s=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){h("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){h(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),Qt(n,"attribute",this.attribute);for(let A in this.attribute)this.attribute[A]=this.gl.getAttribLocation(this.id,A);Qt(n,"uniform",this.uniform),Qt(o,"uniform",this.uniform);for(let A in this.uniform)this.uniform[A]=this.gl.getUniformLocation(this.id,A)}}};function G1(){let e=0,t=null,n=!1,o=-1,r=[null,null],s=[],A=null,a=null,l=Ae(100,100),c={},x={INTERMEDIATE:1},i=l.getContext("webgl");if(!i){h("filter: cannot get webgl context");return}this.gl=i;function f(g,p){if(!(g===l.width&&p===l.height)){if(l.width=g,l.height=p,!A){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);A=i.createBuffer(),i.bindBuffer(i.ARRAY_BUFFER,A),i.bufferData(i.ARRAY_BUFFER,b,i.STATIC_DRAW),i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}i.viewport(0,0,l.width,l.height),r=[null,null]}}function d(g,p){let b=i.createFramebuffer();i.bindFramebuffer(i.FRAMEBUFFER,b);let k=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,k);let P=i.createTexture();return i.bindTexture(i.TEXTURE_2D,P),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,g,p,0,i.RGBA,i.UNSIGNED_BYTE,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.framebufferTexture2D(i.FRAMEBUFFER,i.COLOR_ATTACHMENT0,i.TEXTURE_2D,P,0),i.bindTexture(i.TEXTURE_2D,null),i.bindFramebuffer(i.FRAMEBUFFER,null),{fbo:b,texture:P}}function m(g){return r[g]=r[g]||d(l.width,l.height),r[g]}function y(g=0){if(!a)return;let p=null,b=null,k=!1;e===0?p=t:p=m(o).texture||null,e++,n&&!(g&x.INTERMEDIATE)?(b=null,k=e%2===0):(o=(o+1)%2,b=m(o).fbo||null),i.bindTexture(i.TEXTURE_2D,p),i.bindFramebuffer(i.FRAMEBUFFER,b),i.uniform1f(a.uniform.flipY,k?-1:1),i.drawArrays(i.TRIANGLES,0,6)}function u(g){if(c[g])return a=c[g],i.useProgram((a?a.id:null)||null),a;if(a=new _t(i,C1,g),!a)return h("filter: could not get webgl program"),null;let p=Float32Array.BYTES_PER_ELEMENT,b=4*p;return i.enableVertexAttribArray(a.attribute.pos),i.vertexAttribPointer(a.attribute.pos,2,i.FLOAT,!1,b,0*p),i.enableVertexAttribArray(a.attribute.uv),i.vertexAttribPointer(a.attribute.uv,2,i.FLOAT,!1,b,2*p),c[g]=a,a}let T={colorMatrix:g=>{let p=new Float32Array(g);p[4]/=255,p[9]/=255,p[14]/=255,p[19]/=255;let b=p[18]===1&&p[3]===0&&p[8]===0&&p[13]===0&&p[15]===0&&p[16]===0&&p[17]===0&&p[19]===0?D1:W1,k=u(b);k&&(i.uniform1fv(k.uniform.m,p),y())},brightness:g=>{let p=(g||0)+1;T.colorMatrix([p,0,0,0,0,0,p,0,0,0,0,0,p,0,0,0,0,0,1,0])},saturation:g=>{let p=(g||0)*2/3+1,b=(p-1)*-.5;T.colorMatrix([p,b,b,0,0,b,p,b,0,0,b,b,p,0,0,0,0,0,1,0])},desaturate:()=>{T.saturation(-1)},contrast:g=>{let p=(g||0)+1,b=-128*(p-1);T.colorMatrix([p,0,0,0,b,0,p,0,0,b,0,0,p,0,b,0,0,0,1,0])},negative:()=>{T.contrast(-2)},hue:g=>{g=(g||0)/180*Math.PI;let p=Math.cos(g),b=Math.sin(g),k=.213,P=.715,N=.072;T.colorMatrix([k+p*(1-k)+b*-k,P+p*-P+b*-P,N+p*-N+b*(1-N),0,0,k+p*-k+b*.143,P+p*(1-P)+b*.14,N+p*-N+b*-.283,0,0,k+p*-k+b*-(1-k),P+p*-P+b*P,N+p*(1-N)+b*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{T.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{T.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{T.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{T.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{T.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{T.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{T.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{T.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:g=>{let p=new Float32Array(g),b=1/l.width,k=1/l.height,P=u(H1);P&&(i.uniform1fv(P.uniform.m,p),i.uniform2f(P.uniform.px,b,k),y())},detectEdges:()=>{T.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{T.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{T.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:g=>{let p=g||1;T.convolution.call(this,[0,-1*p,0,-1*p,1+4*p,-1*p,0,-1*p,0])},emboss:g=>{let p=g||1;T.convolution.call(this,[-2*p,-1*p,0,-1*p,1,1*p,0,1*p,2*p])},blur:g=>{let p=g/7/l.width,b=g/7/l.height,k=u(B1);k&&(i.uniform2f(k.uniform.px,0,b),y(x.INTERMEDIATE),i.uniform2f(k.uniform.px,p,0),y())},pixelate:g=>{let p=g/l.width,b=g/l.height,k=u(F1);k&&(i.uniform2f(k.uniform.size,p,b),y())}};this.add=function(g){let p=Array.prototype.slice.call(arguments,1),b=T[g];s.push({func:b,args:p})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(g){f(g.width,g.height),e=0,t||(t=i.createTexture()),i.bindTexture(i.TEXTURE_2D,t),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.NEAREST),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.NEAREST),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,g);for(let p=0;px.data())),A=Math.max(s[0][0],s[1][0],s[2][0]),l=(A>1?255:1)/A,c;if(l>1){let x=[U.sub(n[0],o[0]),U.sub(n[1],o[1]),U.sub(n[2],o[2])],i=[U.sub(r[0],o[0]),U.sub(r[1],o[1]),U.sub(r[2],o[2])],f=[U.mul(x[0],l),U.mul(x[1],l),U.mul(x[2],l)],d=U.stack([f[0],f[1],f[2]],2);c=U.reshape(d,[1,t.shape[0]||0,t.shape[1]||0,3]),U.dispose([...x,...i,...f,d])}else c=U.expandDims(t,0);return U.dispose([...n,...o,...r,n,t,e]),c}var X2=3840,R0=null,M0=null,y2=null,e0,ne={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function $t(){ne.inputSum=0,ne.cacheDiff=1,ne.sumMethod=0,ne.inputTensor=void 0}function Ae(e,t){let n;if(R.browser)if(R.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof R.Canvas!="undefined")n=new R.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof R.Canvas!="undefined"?n=new R.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function q2(e,t){let n=t||Ae(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function U2(e,t,n=!0){var f,d,m;if(!e)return t.debug&&h("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof I.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof I.Tensor){let y=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)y=I.expandDims(e,0);else if(e.shape[2]===4){let u=I.slice3d(e,[0,0,0],[-1,-1,3]);y=I.expandDims(u,0),I.dispose(u)}}else e.shape.length===4&&(e.shape[3]===3?y=I.clone(e):e.shape[3]===4&&(y=I.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(y==null||y.shape.length!==4||y.shape[0]!==1||y.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(y.dtype==="int32"){let u=I.cast(y,"float32");I.dispose(y),y=u}return{tensor:y,canvas:t.filter.return?M0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&h("input stream is not ready"),{tensor:null,canvas:R0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!r)return t.debug&&h("cannot determine input dimensions"),{tensor:null,canvas:R0};let s=o,A=r;if(s>X2&&(s=X2,A=Math.trunc(s*r/o)),A>X2&&(A=X2,s=Math.trunc(A*o/r)),(((f=t.filter)==null?void 0:f.width)||0)>0?s=t.filter.width:(((d=t.filter)==null?void 0:d.height)||0)>0&&(s=o*((t.filter.height||0)/r)),(t.filter.height||0)>0?A=t.filter.height:(t.filter.width||0)>0&&(A=r*((t.filter.width||0)/o)),!s||!A)throw new Error("input error: cannot determine dimension");(!R0||R0.width!==s||R0.height!==A)&&(R0=Ae(s,A));let a=R0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?a.putImageData(e,0,0):t.filter.flip&&typeof a.translate!="undefined"?(a.translate(o,0),a.scale(-1,1),a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),a.setTransform(1,0,0,1,0,0)):a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),(!M0||R0.width!==M0.width||R0.height!==M0.height)&&(M0=Ae(R0.width,R0.height)),t.filter.enabled&&R.webgl.supported?(e0||(e0=R.browser?new G1:null),R.filter=!!e0,e0!=null&&e0.add?(e0.reset(),t.filter.brightness!==0&&e0.add("brightness",t.filter.brightness),t.filter.contrast!==0&&e0.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&e0.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&e0.add("blur",t.filter.blur),t.filter.saturation!==0&&e0.add("saturation",t.filter.saturation),t.filter.hue!==0&&e0.add("hue",t.filter.hue),t.filter.negative&&e0.add("negative"),t.filter.sepia&&e0.add("sepia"),t.filter.vintage&&e0.add("brownie"),t.filter.sepia&&e0.add("sepia"),t.filter.kodachrome&&e0.add("kodachrome"),t.filter.technicolor&&e0.add("technicolor"),t.filter.polaroid&&e0.add("polaroid"),t.filter.pixelate!==0&&e0.add("pixelate",t.filter.pixelate),((m=e0.get())==null?void 0:m.length)>1?M0=e0.apply(R0):M0=e0.draw(R0)):(t.debug&&h("input process error: cannot initialize filters"),R.webgl.supported=!1,t.filter.enabled=!1,q2(R0,M0))):(q2(R0,M0),e0&&(e0=null),R.filter=!!e0),!n)return{tensor:null,canvas:M0};if(!M0)throw new Error("canvas error: cannot create output");let l,c=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(R.browser&&I.browser)l=I.browser?I.browser.fromPixels(e):null;else{c=e.data.length/e.height/e.width;let y=new Uint8Array(e.data.buffer);l=I.tensor(y,[e.height,e.width,c],"int32")}else if((!y2||M0.width!==y2.width||M0.height!==y2.height)&&(y2=Ae(M0.width,M0.height)),I.browser&&R.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=I.browser.fromPixels(M0):(y2=q2(M0),l=I.browser.fromPixels(y2));else{let T=q2(M0).getContext("2d").getImageData(0,0,s,A);c=T.data.length/s/A;let g=new Uint8Array(T.data.buffer);l=I.tensor(g,[s,A,c])}if(c===4){let y=I.slice3d(l,[0,0,0],[-1,-1,3]);I.dispose(l),l=y}if(!l)throw new Error("input error: cannot create tensor");let x=I.cast(l,"float32"),i=t.filter.equalization?await Z2(x):I.expandDims(x,0);if(I.dispose([l,x]),t.filter.autoBrightness){let y=I.max(i),u=await y.data();t.filter.brightness=u[0]>1?1-u[0]/255:1-u[0],I.dispose(y)}return{tensor:i,canvas:t.filter.return?M0:null}}async function V1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!ne.inputTensor)ne.inputTensor=I.clone(t);else if(ne.inputTensor.shape[1]!==t.shape[1]||ne.inputTensor.shape[2]!==t.shape[2])I.dispose(ne.inputTensor),ne.inputTensor=I.clone(t);else{let o={};o.diff=I.sub(t,ne.inputTensor),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;I.dispose([ne.inputTensor,o.diff,o.squared,o.sum]),ne.inputTensor=I.clone(t),n=s<=(e.cacheSensitivity||0)}return n}async function Z1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||h("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||h("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=I.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?I.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):I.clone(n),o.diff=I.sub(o.input1,o.input2),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return I.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),s}var z2,S2,j2,E2=class{constructor(){w(this,"browser");w(this,"node");w(this,"worker");w(this,"platform","");w(this,"agent","");w(this,"backends",[]);w(this,"initial");w(this,"filter");w(this,"tfjs");w(this,"offscreen");w(this,"perfadd",!1);w(this,"tensorflow",{version:void 0,gpu:void 0});w(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});w(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});w(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});w(this,"cpu",{model:void 0,flags:[]});w(this,"kernels",[]);ue(this,z2,void 0);ue(this,S2,void 0);ue(this,j2,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:W0.version["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Y0(this,z2)}set Canvas(t){Re(this,z2,t),globalThis.Canvas=t}get Image(){return Y0(this,S2)}set Image(t){Re(this,S2,t),globalThis.Image=t}get ImageData(){return Y0(this,j2)}set ImageData(t){Re(this,j2,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(W0.engine().registryFactory);try{this.tensorflow={version:W0.backend().binding?W0.backend().binding.TF_Version:void 0,gpu:W0.backend().binding?W0.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W0.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W0.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=Ae(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=W0.getKernelsForBackend(W0.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};z2=new WeakMap,S2=new WeakMap,j2=new WeakMap;var R=new E2;var K2=class{constructor(){w(this,"config");w(this,"element");w(this,"stream");w(this,"devices",[]);w(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});w(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let A=document.getElementById(t.element);if(A&&A instanceof HTMLVideoElement)this.element=A;else return this.config.debug&&h("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&h("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(n.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&h("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&h("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&h("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(A){return h("webcam",A),`webcam error: ${A}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(A=>{this.element?this.element.onloadeddata=()=>A(!0):A(!1)}),await this.element.play(),this.config.debug&&h("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&h("webcam error","no stream"),"webcam error no stream")});w(this,"pause",()=>{this.element&&this.element.pause()});w(this,"play",async()=>{this.element&&await this.element.play()});w(this,"stop",()=>{this.config.debug&&h("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var f2=G(H());var e5={};ze(e5,{"affectnet-mobilenet":()=>br,age:()=>gr,"anti-spoofing":()=>_r,antispoof:()=>ar,blazeface:()=>ir,"blazeface-back":()=>Tr,"blazeface-front":()=>vr,"blazepose-detector":()=>Rr,"blazepose-full":()=>Mr,"blazepose-heavy":()=>Pr,"blazepose-lite":()=>kr,centernet:()=>lr,default:()=>ds,efficientpose:()=>wr,"efficientpose-i-lite":()=>$r,"efficientpose-ii-lite":()=>es,"efficientpose-iv":()=>ts,emotion:()=>cr,faceboxes:()=>Er,facemesh:()=>dr,"facemesh-attention":()=>Sr,"facemesh-attention-pinto":()=>zr,"facemesh-detection-full":()=>jr,"facemesh-detection-short":()=>Ir,faceres:()=>xr,"faceres-deep":()=>Nr,gear:()=>Cr,"gear-e1":()=>Lr,"gear-e2":()=>Or,gender:()=>Dr,"gender-ssrnet-imdb":()=>Wr,handdetect:()=>Fr,"handlandmark-full":()=>Br,"handlandmark-lite":()=>yr,"handlandmark-sparse":()=>Hr,handskeleton:()=>Gr,handtrack:()=>fr,"insightface-efficientnet-b0":()=>ns,"insightface-ghostnet-strides1":()=>os,"insightface-ghostnet-strides2":()=>rs,"insightface-mobilenet-emore":()=>ss,"insightface-mobilenet-swish":()=>As,iris:()=>mr,liveness:()=>pr,meet:()=>Vr,mobileface:()=>Zr,mobilefacenet:()=>Xr,models:()=>ur,"movenet-lightning":()=>hr,"movenet-multipose":()=>qr,"movenet-thunder":()=>Ur,nanodet:()=>Yr,"nanodet-e":()=>as,"nanodet-g":()=>is,"nanodet-m":()=>ls,"nanodet-t":()=>cs,posenet:()=>Kr,rvm:()=>Jr,selfie:()=>Qr});var ar=853098,ir=538928,lr=4030290,cr=820516,dr=1477958,xr=6978814,yr=2023432,fr=2964837,mr=2599092,pr=592976,ur=0,hr=4650216,br=6920630,gr=161240,Tr=538928,vr=402048,Rr=5928856,Mr=6339202,Pr=27502466,kr=2726402,wr=5651240,Er=2013002,zr=2387598,Sr=2382414,jr=1026192,Ir=201268,Nr=13957620,Lr=112438,Or=112438,Cr=1498916,Wr=161236,Dr=201808,Fr=3515612,Br=5431368,Hr=5286322,Gr=5502280,Vr=372228,Zr=2183192,Xr=5171976,qr=9448838,Ur=12477112,Yr=7574558,Kr=5032780,Jr=3739355,Qr=212886,_r=853098,$r=2269064,es=5651240,ts=25643252,ns=13013224,os=8093408,rs=8049584,ss=6938536,As=12168584,as=12319156,is=7574558,ls=1887474,cs=5294216,ds={antispoof:ar,blazeface:ir,centernet:lr,emotion:cr,facemesh:dr,faceres:xr,"handlandmark-lite":yr,handtrack:fr,iris:mr,liveness:pr,models:ur,"movenet-lightning":hr,"affectnet-mobilenet":br,age:gr,"blazeface-back":Tr,"blazeface-front":vr,"blazepose-detector":Rr,"blazepose-full":Mr,"blazepose-heavy":Pr,"blazepose-lite":kr,efficientpose:wr,faceboxes:Er,"facemesh-attention-pinto":zr,"facemesh-attention":Sr,"facemesh-detection-full":jr,"facemesh-detection-short":Ir,"faceres-deep":Nr,"gear-e1":Lr,"gear-e2":Or,gear:Cr,"gender-ssrnet-imdb":Wr,gender:Dr,handdetect:Fr,"handlandmark-full":Br,"handlandmark-sparse":Hr,handskeleton:Gr,meet:Vr,mobileface:Zr,mobilefacenet:Xr,"movenet-multipose":qr,"movenet-thunder":Ur,nanodet:Yr,posenet:Kr,rvm:Jr,selfie:Qr,"anti-spoofing":_r,"efficientpose-i-lite":$r,"efficientpose-ii-lite":es,"efficientpose-iv":ts,"insightface-efficientnet-b0":ns,"insightface-ghostnet-strides1":os,"insightface-ghostnet-strides2":rs,"insightface-mobilenet-emore":ss,"insightface-mobilenet-swish":As,"nanodet-e":as,"nanodet-g":is,"nanodet-m":ls,"nanodet-t":cs};var D0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},I0={};async function xs(e,t){return D0.debug&&h("load model fetch:",e,t),fetch(e,t)}function X1(e){D0.cacheModels=e.cacheModels,D0.verbose=e.debug,D0.modelBasePath=e.modelBasePath}async function L(e){var c,x,i,f;let t=O1(D0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),r="indexeddb://"+o;I0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:e5[o],inCache:!1,url:""},D0.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=D0.cacheSupported&&D0.cacheModels?await f2.io.listModels():{}}catch(d){D0.cacheSupported=!1}I0[o].inCache=D0.cacheSupported&&D0.cacheModels&&Object.keys(s).includes(r),I0[o].url=I0[o].inCache?r:t;let A=typeof fetch=="undefined"?{}:{fetchFunc:(d,m)=>xs(d,m)},a=new f2.GraphModel(I0[o].url,A),l=!1;try{a.findIOHandler(),D0.debug&&h("model load handler:",a.handler)}catch(d){h("error finding model i/o handler:",t,d)}try{let d=await((c=a.handler)==null?void 0:c.load())||null;I0[o].sizeFromManifest=((x=d==null?void 0:d.weightData)==null?void 0:x.byteLength)||0,d?a.loadSync(d):a=await f2.loadGraphModel(I0[o].inCache?r:t,A),I0[o].sizeLoadedWeights=((f=(i=a.artifacts)==null?void 0:i.weightData)==null?void 0:f.byteLength)||0,D0.verbose&&h("load:",{model:o,url:a.modelUrl,bytes:I0[o].sizeLoadedWeights}),l=!0}catch(d){h("error loading model:",t,d)}if(l&&D0.cacheModels&&D0.cacheSupported&&!I0[o].inCache)try{let d=await a.save(r);D0.debug&&h("model saved:",r,d)}catch(d){h("error saving model:",t,d)}return a}var t5="3.1.2";var S=G(H());var u0=G(H());var o0={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ms(){let e=o0.gl;e&&(o0.extensions=e.getSupportedExtensions())}function q1(e){var t;if(e.config.backend==="humangl"&&(o0.name in u0.engine().registry&&!((t=o0==null?void 0:o0.gl)!=null&&t.getParameter(o0.gl.VERSION))&&(h("humangl error: backend invalid context"),e.models.reset()),!u0.findBackend(o0.name))){try{o0.canvas=Ae(100,100)}catch(r){h("humangl error: cannot create canvas:",r);return}try{if(o0.gl=o0.canvas.getContext("webgl2",o0.webGLattr),!o0.gl){h("humangl error: cannot get webgl context");return}if(!o0.gl.getParameter(o0.gl.VERSION).includes("2.0")){h("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}o0.canvas&&(o0.canvas.addEventListener("webglcontextlost",s=>{throw h("humangl error:",s.type),h("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),o0.canvas.addEventListener("webglcontextrestored",s=>{h("humangl error: context restored:",s)}),o0.canvas.addEventListener("webglcontextcreationerror",s=>{h("humangl error: context create:",s)}))}catch(r){h("humangl error: cannot get webgl context:",r);return}try{u0.setWebGLContext(2,o0.gl)}catch(r){h("humangl error: cannot set webgl context:",r);return}try{let r=new u0.GPGPUContext(o0.gl);u0.registerBackend(o0.name,()=>new u0.MathBackendWebGL(r),o0.priority)}catch(r){h("humangl error: cannot register webgl backend:",r);return}try{u0.getKernelsForBackend("webgl").forEach(s=>{let A={...s,backendName:o0.name};u0.registerKernel(A)})}catch(r){h("humangl error: cannot update webgl backend registration:",r);return}try{u0.env().flagRegistry.WEBGL_VERSION&&u0.env().set("WEBGL_VERSION",2)}catch(r){h("humangl error: cannot set WebGL backend flags:",r);return}ms();let n=u0.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&h("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):h("humangl error: no current gl context:",o,o0.gl)}}var Se=G(H()),C={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function U1(){C.tf255=Se.scalar(255,"float32"),C.tf1=Se.scalar(1,"float32"),C.tf2=Se.scalar(2,"float32"),C.tf05=Se.scalar(.5,"float32"),C.tf127=Se.scalar(127.5,"float32"),C.rgb=Se.tensor1d([.2989,.587,.114],"float32")}async function hs(){var e;return await R.updateBackend(),(e=R.tensorflow)!=null&&e.version?"tensorflow":R.webgpu.supported&&R.webgpu.backend?"webgpu":R.webgl.supported&&R.webgl.backend?"webgl":R.wasm.supported&&R.wasm.backend?"wasm":"cpu"}function bs(e){let t=[];if(!R.kernels.includes("mod")){let n={kernelName:"Mod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.sub(o.inputs.a,S.mul(S.div(o.inputs.a,o.inputs.b),o.inputs.b)))};S.registerKernel(n),R.kernels.push("mod"),t.push("mod")}if(!R.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.add(S.mul(S.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),S.mod(o.inputs.a,o.inputs.b)))};S.registerKernel(n),R.kernels.push("floormod"),t.push("floormod")}if(!R.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>{let r=S.getBackend();S.setBackend("cpu");let s=S.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return S.setBackend(r),s})};S.registerKernel(n),R.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&h("registered kernels:",t)}var Y1={};async function I2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await hs()),t||R.initial||e.config.backend&&e.config.backend.length>0&&S.getBackend()!==e.config.backend){let r=v();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&h("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&h("running inside electron");let s=Object.keys(S.engine().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(q1(e),s=Object.keys(S.engine().registryFactory)),e.config.debug&&h("available backends:",s),R.browser&&!R.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&h("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),R.node&&!R.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&h(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),R.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")h("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let A=await navigator.gpu.requestAdapter();if(e.config.debug&&h("enumerated webgpu adapter:",A),!A)h("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let a="requestAdapterInfo"in A?await A.requestAdapterInfo():void 0;h("webgpu adapter info:",a)}}if(s.includes(e.config.backend)||(h(`error: backend ${e.config.backend} not found in registry`),e.config.backend=R.node?"tensorflow":"webgl",e.config.debug&&h(`override: setting backend ${e.config.backend}`)),e.config.debug&&h("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(S.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&S.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&h("wasm path:",e.config.wasmPath),typeof S.setWasmPaths!="undefined")S.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let A=!1,a=!1;try{A=await S.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),a=await S.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&h(`wasm execution: ${a?"simd":"no simd"} ${A?"multithreaded":"singlethreaded"}`),e.config.debug&&!a&&h("warning: wasm simd support is not enabled")}catch(l){h("wasm detection failed")}}try{await S.setBackend(e.config.backend),await S.ready()}catch(A){return h("error: cannot set backend:",e.config.backend,A),!1}e.config.debug&&(Y1=JSON.parse(JSON.stringify(S.env().flags)))}if((S.getBackend()==="humangl"||S.getBackend()==="webgl")&&(S.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&S.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),S.env().flagRegistry.WEBGL_EXP_CONV&&S.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(h("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),S.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),S.getBackend(),e.config.debug){let s=S.env().flags,A={};for(let a of Object.keys(s))Y1[a]!==s[a]&&(A[a]=s[a]);e.config.debug&&Object.keys(A).length>0&&h("backend:",S.getBackend(),"flags:",A)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&h("flags:",e.config.flags);for(let[s,A]of Object.entries(e.config.flags))S.env().set(s,A)}S.enableProdMode(),U1(),e.performance.initBackend=Math.trunc(v()-r),e.config.backend=S.getBackend(),await R.updateBackend(),bs(e.config)}return!0}function J2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&h("kernelFunc",n,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};S.registerKernel(o)}R.kernels=S.getKernelsForBackend(S.getBackend()).map(n=>n.kernelName.toLowerCase())}var nt={};ze(nt,{all:()=>Js,body:()=>_2,canvas:()=>Ks,face:()=>Q2,gesture:()=>tt,hand:()=>$2,init:()=>i5,object:()=>et,options:()=>f0,person:()=>Ys});var oe=e=>{if(!e)h("draw error: invalid canvas");else if(!e.getContext)h("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)h("draw error: cannot get canvas context");else return t}return null},Je=e=>Math.round(e*180/Math.PI),Y=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Qe=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function re(e,t,n,o,r){let s=t.replace(/\[.*\]/g,"").split(` `).map(a=>a.trim()),A=Math.max(0,n);for(let a=s.length-1;a>=0;a--){let l=a*r.lineHeight+o;r.shadowColor&&r.shadowColor!==""&&(e.fillStyle=r.shadowColor,e.fillText(s[a],A+5,l+16)),e.fillStyle=r.labelColor,e.fillText(s[a],A+4,l+15)}}function he(e,t,n,o,r){e.fillStyle=Qe(o,r),e.beginPath(),e.arc(t,n,r.pointSize,0,2*Math.PI),e.fill()}function be(e,t,n,o,r,s){if(e.beginPath(),e.lineWidth=s.lineWidth,s.useCurves){let A=(t+t+o)/2,a=(n+n+r)/2;e.ellipse(A,a,o/2,r/2,0,0,2*Math.PI)}else e.moveTo(t+s.roundRect,n),e.lineTo(t+o-s.roundRect,n),e.quadraticCurveTo(t+o,n,t+o,n+s.roundRect),e.lineTo(t+o,n+r-s.roundRect),e.quadraticCurveTo(t+o,n+r,t+o-s.roundRect,n+r),e.lineTo(t+s.roundRect,n+r),e.quadraticCurveTo(t,n+r,t,n+r-s.roundRect),e.lineTo(t,n+s.roundRect),e.quadraticCurveTo(t,n,t+s.roundRect,n),e.closePath();e.stroke()}function n5(e,t,n){if(!(t.length<2)){e.beginPath(),e.moveTo(t[0][0],t[0][1]);for(let o of t)e.strokeStyle=Qe(o[2]||0,n),e.lineTo(Math.trunc(o[0]),Math.trunc(o[1]));e.stroke(),n.fillPolygons&&(e.closePath(),e.fill())}}function J1(e,t,n){if(!(t.length<2)){if(e.lineWidth=n.lineWidth,!n.useCurves||t.length<=2){n5(e,t,n);return}e.moveTo(t[0][0],t[0][1]);for(let o=0;oN2[e]),Za=Ts.map(e=>N2[e]),Xa=vs.map(e=>N2[e]);function je(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Rs=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Ms=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Ps=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],ks=[[474,475],[475,476],[476,477],[477,474]],ws=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Es=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],zs=[[469,470],[470,471],[471,472],[472,469]],Ss=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]],qa={lips:je(Rs),leftEye:je(Ms),leftEyebrow:je(Ps),leftIris:je(ks),rightEye:je(ws),rightEyebrow:je(Es),rightIris:je(zs),faceOval:je(Ss)};var js=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Is=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Ns=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],Ls=[[474,475],[475,476],[476,477],[477,474]],Os=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Cs=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],Ws=[[469,470],[470,471],[471,472],[472,469]],Ds=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]];function Ie(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Fs={lips:Ie(js),leftEye:Ie(Is),leftEyebrow:Ie(Ns),leftIris:Ie(Ls),rightEye:Ie(Os),rightEyebrow:Ie(Cs),rightIris:Ie(Ws),faceOval:Ie(Ds)},Bs=Object.entries(Fs).map(([e,t])=>t.map(n=>[n,e])).flat(),Ua=new Map(Bs),L2=[61,146,91,181,84,17,314,405,321,375,291,185,40,39,37,0,267,269,270,409,78,95,88,178,87,14,317,402,318,324,308,191,80,81,82,13,312,311,310,415,76,77,90,180,85,16,315,404,320,307,306,184,74,73,72,11,302,303,304,408,62,96,89,179,86,15,316,403,319,325,292,183,42,41,38,12,268,271,272,407],e2=[33,7,163,144,145,153,154,155,133,246,161,160,159,158,157,173,130,25,110,24,23,22,26,112,243,247,30,29,27,28,56,190,226,31,228,229,230,231,232,233,244,113,225,224,223,222,221,189,35,124,46,53,52,65,143,111,117,118,119,120,121,128,245,156,70,63,105,66,107,55,193],t2=[263,249,390,373,374,380,381,382,362,466,388,387,386,385,384,398,359,255,339,254,253,252,256,341,463,467,260,259,257,258,286,414,446,261,448,449,450,451,452,453,464,342,445,444,443,442,441,413,265,353,276,283,282,295,372,340,346,347,348,349,350,357,465,383,300,293,334,296,336,285,417];var q;function Hs(e,t){var o,r,s,A,a,l,c,x,i;if(!q.drawLabels||((o=q.faceLabels)==null?void 0:o.length)===0)return;let n=q.faceLabels.slice();if(n=Y(n,"[id]",e.id.toFixed(0)),e.score&&(n=Y(n,"[score]",100*e.score)),e.gender&&(n=Y(n,"[gender]",e.gender)),e.genderScore&&(n=Y(n,"[genderScore]",100*e.genderScore)),e.age&&(n=Y(n,"[age]",e.age)),e.distance&&(n=Y(n,"[distance]",100*e.distance)),e.real&&(n=Y(n,"[real]",100*e.real)),e.live&&(n=Y(n,"[live]",100*e.live)),e.emotion&&e.emotion.length>0){let f=e.emotion.map(d=>`${Math.trunc(100*d.score)}% ${d.emotion}`);f.length>3&&(f.length=3),n=Y(n,"[emotions]",f.join(" "))}(s=(r=e.rotation)==null?void 0:r.angle)!=null&&s.roll&&(n=Y(n,"[roll]",Je(e.rotation.angle.roll))),(a=(A=e.rotation)==null?void 0:A.angle)!=null&&a.yaw&&(n=Y(n,"[yaw]",Je(e.rotation.angle.yaw))),(c=(l=e.rotation)==null?void 0:l.angle)!=null&&c.pitch&&(n=Y(n,"[pitch]",Je(e.rotation.angle.pitch))),(i=(x=e.rotation)==null?void 0:x.gaze)!=null&&i.bearing&&(n=Y(n,"[gaze]",Je(e.rotation.gaze.bearing))),re(t,n,e.box[0],e.box[1],q)}function Gs(e,t){var n,o,r,s;if((n=e.annotations)!=null&&n.leftEyeIris&&((o=e.annotations)!=null&&o.leftEyeIris[0])){t.strokeStyle=q.useDepth?"rgba(255, 200, 255, 0.3)":q.color,t.beginPath();let A=Math.abs(e.annotations.leftEyeIris[3][0]-e.annotations.leftEyeIris[1][0])/2,a=Math.abs(e.annotations.leftEyeIris[4][1]-e.annotations.leftEyeIris[2][1])/2;t.ellipse(e.annotations.leftEyeIris[0][0],e.annotations.leftEyeIris[0][1],A,a,0,0,2*Math.PI),t.stroke(),q.fillPolygons&&(t.fillStyle=q.useDepth?"rgba(255, 255, 200, 0.3)":q.color,t.fill())}if((r=e.annotations)!=null&&r.rightEyeIris&&((s=e.annotations)!=null&&s.rightEyeIris[0])){t.strokeStyle=q.useDepth?"rgba(255, 200, 255, 0.3)":q.color,t.beginPath();let A=Math.abs(e.annotations.rightEyeIris[3][0]-e.annotations.rightEyeIris[1][0])/2,a=Math.abs(e.annotations.rightEyeIris[4][1]-e.annotations.rightEyeIris[2][1])/2;t.ellipse(e.annotations.rightEyeIris[0][0],e.annotations.rightEyeIris[0][1],A,a,0,0,2*Math.PI),t.stroke(),q.fillPolygons&&(t.fillStyle=q.useDepth?"rgba(255, 255, 200, 0.3)":q.color,t.fill())}}function Vs(e,t){var n;if(q.drawGaze&&((n=e.rotation)!=null&&n.angle)&&typeof Path2D!="undefined"){t.strokeStyle="pink";let o=e.box[0]+e.box[2]/2-e.box[3]*Je(e.rotation.angle.yaw)/90,r=e.box[1]+e.box[3]/2+e.box[2]*Je(e.rotation.angle.pitch)/90,s=new Path2D(` M ${e.box[0]+e.box[2]/2} ${e.box[1]} C diff --git a/dist/human.node-wasm.js b/dist/human.node-wasm.js index a8818efe..2a1aa3d8 100644 --- a/dist/human.node-wasm.js +++ b/dist/human.node-wasm.js @@ -96,7 +96,7 @@ c31 * m[6] + c32 * m[7] + c33 * m[8]; gl_FragColor.a = c22.a; } -`;var _t=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(r,s)=>(n[s]=0,r))},$t=class{constructor(t,n,o){w(this,"uniform",{});w(this,"attribute",{});w(this,"gl");w(this,"id");w(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(h(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(h("filter: could not create shader"),null)});this.gl=t;let r=this.compile(n,this.gl.VERTEX_SHADER),s=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){h("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){h(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),_t(n,"attribute",this.attribute);for(let A in this.attribute)this.attribute[A]=this.gl.getAttribLocation(this.id,A);_t(n,"uniform",this.uniform),_t(o,"uniform",this.uniform);for(let A in this.uniform)this.uniform[A]=this.gl.getUniformLocation(this.id,A)}}};function V1(){let e=0,t=null,n=!1,o=-1,r=[null,null],s=[],A=null,a=null,l=Ae(100,100),c={},x={INTERMEDIATE:1},i=l.getContext("webgl");if(!i){h("filter: cannot get webgl context");return}this.gl=i;function f(g,p){if(!(g===l.width&&p===l.height)){if(l.width=g,l.height=p,!A){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);A=i.createBuffer(),i.bindBuffer(i.ARRAY_BUFFER,A),i.bufferData(i.ARRAY_BUFFER,b,i.STATIC_DRAW),i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}i.viewport(0,0,l.width,l.height),r=[null,null]}}function d(g,p){let b=i.createFramebuffer();i.bindFramebuffer(i.FRAMEBUFFER,b);let k=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,k);let P=i.createTexture();return i.bindTexture(i.TEXTURE_2D,P),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,g,p,0,i.RGBA,i.UNSIGNED_BYTE,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.framebufferTexture2D(i.FRAMEBUFFER,i.COLOR_ATTACHMENT0,i.TEXTURE_2D,P,0),i.bindTexture(i.TEXTURE_2D,null),i.bindFramebuffer(i.FRAMEBUFFER,null),{fbo:b,texture:P}}function m(g){return r[g]=r[g]||d(l.width,l.height),r[g]}function y(g=0){if(!a)return;let p=null,b=null,k=!1;e===0?p=t:p=m(o).texture||null,e++,n&&!(g&x.INTERMEDIATE)?(b=null,k=e%2===0):(o=(o+1)%2,b=m(o).fbo||null),i.bindTexture(i.TEXTURE_2D,p),i.bindFramebuffer(i.FRAMEBUFFER,b),i.uniform1f(a.uniform.flipY,k?-1:1),i.drawArrays(i.TRIANGLES,0,6)}function u(g){if(c[g])return a=c[g],i.useProgram((a?a.id:null)||null),a;if(a=new $t(i,W1,g),!a)return h("filter: could not get webgl program"),null;let p=Float32Array.BYTES_PER_ELEMENT,b=4*p;return i.enableVertexAttribArray(a.attribute.pos),i.vertexAttribPointer(a.attribute.pos,2,i.FLOAT,!1,b,0*p),i.enableVertexAttribArray(a.attribute.uv),i.vertexAttribPointer(a.attribute.uv,2,i.FLOAT,!1,b,2*p),c[g]=a,a}let T={colorMatrix:g=>{let p=new Float32Array(g);p[4]/=255,p[9]/=255,p[14]/=255,p[19]/=255;let b=p[18]===1&&p[3]===0&&p[8]===0&&p[13]===0&&p[15]===0&&p[16]===0&&p[17]===0&&p[19]===0?F1:D1,k=u(b);k&&(i.uniform1fv(k.uniform.m,p),y())},brightness:g=>{let p=(g||0)+1;T.colorMatrix([p,0,0,0,0,0,p,0,0,0,0,0,p,0,0,0,0,0,1,0])},saturation:g=>{let p=(g||0)*2/3+1,b=(p-1)*-.5;T.colorMatrix([p,b,b,0,0,b,p,b,0,0,b,b,p,0,0,0,0,0,1,0])},desaturate:()=>{T.saturation(-1)},contrast:g=>{let p=(g||0)+1,b=-128*(p-1);T.colorMatrix([p,0,0,0,b,0,p,0,0,b,0,0,p,0,b,0,0,0,1,0])},negative:()=>{T.contrast(-2)},hue:g=>{g=(g||0)/180*Math.PI;let p=Math.cos(g),b=Math.sin(g),k=.213,P=.715,N=.072;T.colorMatrix([k+p*(1-k)+b*-k,P+p*-P+b*-P,N+p*-N+b*(1-N),0,0,k+p*-k+b*.143,P+p*(1-P)+b*.14,N+p*-N+b*-.283,0,0,k+p*-k+b*-(1-k),P+p*-P+b*P,N+p*(1-N)+b*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{T.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{T.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{T.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{T.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{T.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{T.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{T.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{T.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:g=>{let p=new Float32Array(g),b=1/l.width,k=1/l.height,P=u(G1);P&&(i.uniform1fv(P.uniform.m,p),i.uniform2f(P.uniform.px,b,k),y())},detectEdges:()=>{T.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{T.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{T.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:g=>{let p=g||1;T.convolution.call(this,[0,-1*p,0,-1*p,1+4*p,-1*p,0,-1*p,0])},emboss:g=>{let p=g||1;T.convolution.call(this,[-2*p,-1*p,0,-1*p,1,1*p,0,1*p,2*p])},blur:g=>{let p=g/7/l.width,b=g/7/l.height,k=u(H1);k&&(i.uniform2f(k.uniform.px,0,b),y(x.INTERMEDIATE),i.uniform2f(k.uniform.px,p,0),y())},pixelate:g=>{let p=g/l.width,b=g/l.height,k=u(B1);k&&(i.uniform2f(k.uniform.size,p,b),y())}};this.add=function(g){let p=Array.prototype.slice.call(arguments,1),b=T[g];s.push({func:b,args:p})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(g){f(g.width,g.height),e=0,t||(t=i.createTexture()),i.bindTexture(i.TEXTURE_2D,t),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.NEAREST),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.NEAREST),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,g);for(let p=0;px.data())),A=Math.max(s[0][0],s[1][0],s[2][0]),l=(A>1?255:1)/A,c;if(l>1){let x=[U.sub(n[0],o[0]),U.sub(n[1],o[1]),U.sub(n[2],o[2])],i=[U.sub(r[0],o[0]),U.sub(r[1],o[1]),U.sub(r[2],o[2])],f=[U.mul(x[0],l),U.mul(x[1],l),U.mul(x[2],l)],d=U.stack([f[0],f[1],f[2]],2);c=U.reshape(d,[1,t.shape[0]||0,t.shape[1]||0,3]),U.dispose([...x,...i,...f,d])}else c=U.expandDims(t,0);return U.dispose([...n,...o,...r,n,t,e]),c}var U2=3840,R0=null,M0=null,y2=null,e0,ne={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function e5(){ne.inputSum=0,ne.cacheDiff=1,ne.sumMethod=0,ne.inputTensor=void 0}function Ae(e,t){let n;if(R.browser)if(R.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof R.Canvas!="undefined")n=new R.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof R.Canvas!="undefined"?n=new R.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function Y2(e,t){let n=t||Ae(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function K2(e,t,n=!0){var f,d,m;if(!e)return t.debug&&h("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof I.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof I.Tensor){let y=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)y=I.expandDims(e,0);else if(e.shape[2]===4){let u=I.slice3d(e,[0,0,0],[-1,-1,3]);y=I.expandDims(u,0),I.dispose(u)}}else e.shape.length===4&&(e.shape[3]===3?y=I.clone(e):e.shape[3]===4&&(y=I.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(y==null||y.shape.length!==4||y.shape[0]!==1||y.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(y.dtype==="int32"){let u=I.cast(y,"float32");I.dispose(y),y=u}return{tensor:y,canvas:t.filter.return?M0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&h("input stream is not ready"),{tensor:null,canvas:R0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!r)return t.debug&&h("cannot determine input dimensions"),{tensor:null,canvas:R0};let s=o,A=r;if(s>U2&&(s=U2,A=Math.trunc(s*r/o)),A>U2&&(A=U2,s=Math.trunc(A*o/r)),(((f=t.filter)==null?void 0:f.width)||0)>0?s=t.filter.width:(((d=t.filter)==null?void 0:d.height)||0)>0&&(s=o*((t.filter.height||0)/r)),(t.filter.height||0)>0?A=t.filter.height:(t.filter.width||0)>0&&(A=r*((t.filter.width||0)/o)),!s||!A)throw new Error("input error: cannot determine dimension");(!R0||R0.width!==s||R0.height!==A)&&(R0=Ae(s,A));let a=R0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?a.putImageData(e,0,0):t.filter.flip&&typeof a.translate!="undefined"?(a.translate(o,0),a.scale(-1,1),a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),a.setTransform(1,0,0,1,0,0)):a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),(!M0||R0.width!==M0.width||R0.height!==M0.height)&&(M0=Ae(R0.width,R0.height)),t.filter.enabled&&R.webgl.supported?(e0||(e0=R.browser?new V1:null),R.filter=!!e0,e0!=null&&e0.add?(e0.reset(),t.filter.brightness!==0&&e0.add("brightness",t.filter.brightness),t.filter.contrast!==0&&e0.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&e0.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&e0.add("blur",t.filter.blur),t.filter.saturation!==0&&e0.add("saturation",t.filter.saturation),t.filter.hue!==0&&e0.add("hue",t.filter.hue),t.filter.negative&&e0.add("negative"),t.filter.sepia&&e0.add("sepia"),t.filter.vintage&&e0.add("brownie"),t.filter.sepia&&e0.add("sepia"),t.filter.kodachrome&&e0.add("kodachrome"),t.filter.technicolor&&e0.add("technicolor"),t.filter.polaroid&&e0.add("polaroid"),t.filter.pixelate!==0&&e0.add("pixelate",t.filter.pixelate),((m=e0.get())==null?void 0:m.length)>1?M0=e0.apply(R0):M0=e0.draw(R0)):(t.debug&&h("input process error: cannot initialize filters"),R.webgl.supported=!1,t.filter.enabled=!1,Y2(R0,M0))):(Y2(R0,M0),e0&&(e0=null),R.filter=!!e0),!n)return{tensor:null,canvas:M0};if(!M0)throw new Error("canvas error: cannot create output");let l,c=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(R.browser&&I.browser)l=I.browser?I.browser.fromPixels(e):null;else{c=e.data.length/e.height/e.width;let y=new Uint8Array(e.data.buffer);l=I.tensor(y,[e.height,e.width,c],"int32")}else if((!y2||M0.width!==y2.width||M0.height!==y2.height)&&(y2=Ae(M0.width,M0.height)),I.browser&&R.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=I.browser.fromPixels(M0):(y2=Y2(M0),l=I.browser.fromPixels(y2));else{let T=Y2(M0).getContext("2d").getImageData(0,0,s,A);c=T.data.length/s/A;let g=new Uint8Array(T.data.buffer);l=I.tensor(g,[s,A,c])}if(c===4){let y=I.slice3d(l,[0,0,0],[-1,-1,3]);I.dispose(l),l=y}if(!l)throw new Error("input error: cannot create tensor");let x=I.cast(l,"float32"),i=t.filter.equalization?await X2(x):I.expandDims(x,0);if(I.dispose([l,x]),t.filter.autoBrightness){let y=I.max(i),u=await y.data();t.filter.brightness=u[0]>1?1-u[0]/255:1-u[0],I.dispose(y)}return{tensor:i,canvas:t.filter.return?M0:null}}async function Z1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!ne.inputTensor)ne.inputTensor=I.clone(t);else if(ne.inputTensor.shape[1]!==t.shape[1]||ne.inputTensor.shape[2]!==t.shape[2])I.dispose(ne.inputTensor),ne.inputTensor=I.clone(t);else{let o={};o.diff=I.sub(t,ne.inputTensor),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;I.dispose([ne.inputTensor,o.diff,o.squared,o.sum]),ne.inputTensor=I.clone(t),n=s<=(e.cacheSensitivity||0)}return n}async function q1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||h("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||h("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=I.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?I.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):I.clone(n),o.diff=I.sub(o.input1,o.input2),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return I.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),s}var j2,I2,N2,S2=class{constructor(){w(this,"browser");w(this,"node");w(this,"worker");w(this,"platform","");w(this,"agent","");w(this,"backends",[]);w(this,"initial");w(this,"filter");w(this,"tfjs");w(this,"offscreen");w(this,"perfadd",!1);w(this,"tensorflow",{version:void 0,gpu:void 0});w(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});w(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});w(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});w(this,"cpu",{model:void 0,flags:[]});w(this,"kernels",[]);ue(this,j2,void 0);ue(this,I2,void 0);ue(this,N2,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:W0.version["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Y0(this,j2)}set Canvas(t){Re(this,j2,t),globalThis.Canvas=t}get Image(){return Y0(this,I2)}set Image(t){Re(this,I2,t),globalThis.Image=t}get ImageData(){return Y0(this,N2)}set ImageData(t){Re(this,N2,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(W0.engine().registryFactory);try{this.tensorflow={version:W0.backend().binding?W0.backend().binding.TF_Version:void 0,gpu:W0.backend().binding?W0.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W0.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W0.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=Ae(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=W0.getKernelsForBackend(W0.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};j2=new WeakMap,I2=new WeakMap,N2=new WeakMap;var R=new S2;var Q2=class{constructor(){w(this,"config");w(this,"element");w(this,"stream");w(this,"devices",[]);w(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});w(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let A=document.getElementById(t.element);if(A&&A instanceof HTMLVideoElement)this.element=A;else return this.config.debug&&h("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&h("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(n.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&h("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&h("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&h("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(A){return h("webcam",A),`webcam error: ${A}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(A=>{this.element?this.element.onloadeddata=()=>A(!0):A(!1)}),await this.element.play(),this.config.debug&&h("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&h("webcam error","no stream"),"webcam error no stream")});w(this,"pause",()=>{this.element&&this.element.pause()});w(this,"play",async()=>{this.element&&await this.element.play()});w(this,"stop",()=>{this.config.debug&&h("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var f2=G(H());var t5={};ze(t5,{"affectnet-mobilenet":()=>br,age:()=>gr,"anti-spoofing":()=>_r,antispoof:()=>ar,blazeface:()=>ir,"blazeface-back":()=>Tr,"blazeface-front":()=>vr,"blazepose-detector":()=>Rr,"blazepose-full":()=>Mr,"blazepose-heavy":()=>Pr,"blazepose-lite":()=>kr,centernet:()=>lr,default:()=>ds,efficientpose:()=>wr,"efficientpose-i-lite":()=>$r,"efficientpose-ii-lite":()=>es,"efficientpose-iv":()=>ts,emotion:()=>cr,faceboxes:()=>Er,facemesh:()=>dr,"facemesh-attention":()=>Sr,"facemesh-attention-pinto":()=>zr,"facemesh-detection-full":()=>jr,"facemesh-detection-short":()=>Ir,faceres:()=>xr,"faceres-deep":()=>Nr,gear:()=>Cr,"gear-e1":()=>Or,"gear-e2":()=>Lr,gender:()=>Dr,"gender-ssrnet-imdb":()=>Wr,handdetect:()=>Fr,"handlandmark-full":()=>Br,"handlandmark-lite":()=>yr,"handlandmark-sparse":()=>Hr,handskeleton:()=>Gr,handtrack:()=>fr,"insightface-efficientnet-b0":()=>ns,"insightface-ghostnet-strides1":()=>os,"insightface-ghostnet-strides2":()=>rs,"insightface-mobilenet-emore":()=>ss,"insightface-mobilenet-swish":()=>As,iris:()=>mr,liveness:()=>pr,meet:()=>Vr,mobileface:()=>Zr,mobilefacenet:()=>qr,models:()=>ur,"movenet-lightning":()=>hr,"movenet-multipose":()=>Xr,"movenet-thunder":()=>Ur,nanodet:()=>Yr,"nanodet-e":()=>as,"nanodet-g":()=>is,"nanodet-m":()=>ls,"nanodet-t":()=>cs,posenet:()=>Kr,rvm:()=>Jr,selfie:()=>Qr});var ar=853098,ir=538928,lr=4030290,cr=820516,dr=1477958,xr=6978814,yr=2023432,fr=2964837,mr=2599092,pr=592976,ur=0,hr=4650216,br=6920630,gr=161240,Tr=538928,vr=402048,Rr=5928856,Mr=6339202,Pr=27502466,kr=2726402,wr=5651240,Er=2013002,zr=2387598,Sr=2382414,jr=1026192,Ir=201268,Nr=13957620,Or=112438,Lr=112438,Cr=1498916,Wr=161236,Dr=201808,Fr=3515612,Br=5431368,Hr=5286322,Gr=5502280,Vr=372228,Zr=2183192,qr=5171976,Xr=9448838,Ur=12477112,Yr=7574558,Kr=5032780,Jr=3739355,Qr=212886,_r=853098,$r=2269064,es=5651240,ts=25643252,ns=13013224,os=8093408,rs=8049584,ss=6938536,As=12168584,as=12319156,is=7574558,ls=1887474,cs=5294216,ds={antispoof:ar,blazeface:ir,centernet:lr,emotion:cr,facemesh:dr,faceres:xr,"handlandmark-lite":yr,handtrack:fr,iris:mr,liveness:pr,models:ur,"movenet-lightning":hr,"affectnet-mobilenet":br,age:gr,"blazeface-back":Tr,"blazeface-front":vr,"blazepose-detector":Rr,"blazepose-full":Mr,"blazepose-heavy":Pr,"blazepose-lite":kr,efficientpose:wr,faceboxes:Er,"facemesh-attention-pinto":zr,"facemesh-attention":Sr,"facemesh-detection-full":jr,"facemesh-detection-short":Ir,"faceres-deep":Nr,"gear-e1":Or,"gear-e2":Lr,gear:Cr,"gender-ssrnet-imdb":Wr,gender:Dr,handdetect:Fr,"handlandmark-full":Br,"handlandmark-sparse":Hr,handskeleton:Gr,meet:Vr,mobileface:Zr,mobilefacenet:qr,"movenet-multipose":Xr,"movenet-thunder":Ur,nanodet:Yr,posenet:Kr,rvm:Jr,selfie:Qr,"anti-spoofing":_r,"efficientpose-i-lite":$r,"efficientpose-ii-lite":es,"efficientpose-iv":ts,"insightface-efficientnet-b0":ns,"insightface-ghostnet-strides1":os,"insightface-ghostnet-strides2":rs,"insightface-mobilenet-emore":ss,"insightface-mobilenet-swish":As,"nanodet-e":as,"nanodet-g":is,"nanodet-m":ls,"nanodet-t":cs};var D0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},I0={};async function xs(e,t){return D0.debug&&h("load model fetch:",e,t),fetch(e,t)}function X1(e){D0.cacheModels=e.cacheModels,D0.verbose=e.debug,D0.modelBasePath=e.modelBasePath}async function O(e){var c,x,i,f;let t=C1(D0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),r="indexeddb://"+o;I0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:t5[o],inCache:!1,url:""},D0.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=D0.cacheSupported&&D0.cacheModels?await f2.io.listModels():{}}catch(d){D0.cacheSupported=!1}I0[o].inCache=D0.cacheSupported&&D0.cacheModels&&Object.keys(s).includes(r),I0[o].url=I0[o].inCache?r:t;let A=typeof fetch=="undefined"?{}:{fetchFunc:(d,m)=>xs(d,m)},a=new f2.GraphModel(I0[o].url,A),l=!1;try{a.findIOHandler(),D0.debug&&h("model load handler:",a.handler)}catch(d){h("error finding model i/o handler:",t,d)}try{let d=await((c=a.handler)==null?void 0:c.load())||null;I0[o].sizeFromManifest=((x=d==null?void 0:d.weightData)==null?void 0:x.byteLength)||0,d?a.loadSync(d):a=await f2.loadGraphModel(I0[o].inCache?r:t,A),I0[o].sizeLoadedWeights=((f=(i=a.artifacts)==null?void 0:i.weightData)==null?void 0:f.byteLength)||0,D0.verbose&&h("load:",{model:o,url:a.modelUrl,bytes:I0[o].sizeLoadedWeights}),l=!0}catch(d){h("error loading model:",t,d)}if(l&&D0.cacheModels&&D0.cacheSupported&&!I0[o].inCache)try{let d=await a.save(r);D0.debug&&h("model saved:",r,d)}catch(d){h("error saving model:",t,d)}return a}var n5="3.1.1";var S=G(H());var u0=G(H());var o0={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ms(){let e=o0.gl;e&&(o0.extensions=e.getSupportedExtensions())}function U1(e){var t;if(e.config.backend==="humangl"&&(o0.name in u0.engine().registry&&!((t=o0==null?void 0:o0.gl)!=null&&t.getParameter(o0.gl.VERSION))&&(h("humangl error: backend invalid context"),e.models.reset()),!u0.findBackend(o0.name))){try{o0.canvas=Ae(100,100)}catch(r){h("humangl error: cannot create canvas:",r);return}try{if(o0.gl=o0.canvas.getContext("webgl2",o0.webGLattr),!o0.gl){h("humangl error: cannot get webgl context");return}if(!o0.gl.getParameter(o0.gl.VERSION).includes("2.0")){h("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}o0.canvas&&(o0.canvas.addEventListener("webglcontextlost",s=>{throw h("humangl error:",s.type),h("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),o0.canvas.addEventListener("webglcontextrestored",s=>{h("humangl error: context restored:",s)}),o0.canvas.addEventListener("webglcontextcreationerror",s=>{h("humangl error: context create:",s)}))}catch(r){h("humangl error: cannot get webgl context:",r);return}try{u0.setWebGLContext(2,o0.gl)}catch(r){h("humangl error: cannot set webgl context:",r);return}try{let r=new u0.GPGPUContext(o0.gl);u0.registerBackend(o0.name,()=>new u0.MathBackendWebGL(r),o0.priority)}catch(r){h("humangl error: cannot register webgl backend:",r);return}try{u0.getKernelsForBackend("webgl").forEach(s=>{let A={...s,backendName:o0.name};u0.registerKernel(A)})}catch(r){h("humangl error: cannot update webgl backend registration:",r);return}try{u0.env().flagRegistry.WEBGL_VERSION&&u0.env().set("WEBGL_VERSION",2)}catch(r){h("humangl error: cannot set WebGL backend flags:",r);return}ms();let n=u0.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&h("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):h("humangl error: no current gl context:",o,o0.gl)}}var Se=G(H()),C={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function Y1(){C.tf255=Se.scalar(255,"float32"),C.tf1=Se.scalar(1,"float32"),C.tf2=Se.scalar(2,"float32"),C.tf05=Se.scalar(.5,"float32"),C.tf127=Se.scalar(127.5,"float32"),C.rgb=Se.tensor1d([.2989,.587,.114],"float32")}async function hs(){var e;return await R.updateBackend(),(e=R.tensorflow)!=null&&e.version?"tensorflow":R.webgpu.supported&&R.webgpu.backend?"webgpu":R.webgl.supported&&R.webgl.backend?"webgl":R.wasm.supported&&R.wasm.backend?"wasm":"cpu"}function bs(e){let t=[];if(!R.kernels.includes("mod")){let n={kernelName:"Mod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.sub(o.inputs.a,S.mul(S.div(o.inputs.a,o.inputs.b),o.inputs.b)))};S.registerKernel(n),R.kernels.push("mod"),t.push("mod")}if(!R.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.add(S.mul(S.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),S.mod(o.inputs.a,o.inputs.b)))};S.registerKernel(n),R.kernels.push("floormod"),t.push("floormod")}if(!R.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>{let r=S.getBackend();S.setBackend("cpu");let s=S.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return S.setBackend(r),s})};S.registerKernel(n),R.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&h("registered kernels:",t)}var K1={};async function O2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await hs()),t||R.initial||e.config.backend&&e.config.backend.length>0&&S.getBackend()!==e.config.backend){let r=v();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&h("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&h("running inside electron");let s=Object.keys(S.engine().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(U1(e),s=Object.keys(S.engine().registryFactory)),e.config.debug&&h("available backends:",s),R.browser&&!R.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&h("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),R.node&&!R.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&h(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),R.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")h("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let A=await navigator.gpu.requestAdapter();if(e.config.debug&&h("enumerated webgpu adapter:",A),!A)h("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let a="requestAdapterInfo"in A?await A.requestAdapterInfo():void 0;h("webgpu adapter info:",a)}}if(s.includes(e.config.backend)||(h(`error: backend ${e.config.backend} not found in registry`),e.config.backend=R.node?"tensorflow":"webgl",e.config.debug&&h(`override: setting backend ${e.config.backend}`)),e.config.debug&&h("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(S.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&S.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&h("wasm path:",e.config.wasmPath),typeof S.setWasmPaths!="undefined")S.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let A=!1,a=!1;try{A=await S.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),a=await S.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&h(`wasm execution: ${a?"simd":"no simd"} ${A?"multithreaded":"singlethreaded"}`),e.config.debug&&!a&&h("warning: wasm simd support is not enabled")}catch(l){h("wasm detection failed")}}try{await S.setBackend(e.config.backend),await S.ready()}catch(A){return h("error: cannot set backend:",e.config.backend,A),!1}e.config.debug&&(K1=JSON.parse(JSON.stringify(S.env().flags)))}if((S.getBackend()==="humangl"||S.getBackend()==="webgl")&&(S.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&S.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),S.env().flagRegistry.WEBGL_EXP_CONV&&S.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(h("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),S.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),S.getBackend(),e.config.debug){let s=S.env().flags,A={};for(let a of Object.keys(s))K1[a]!==s[a]&&(A[a]=s[a]);e.config.debug&&Object.keys(A).length>0&&h("backend:",S.getBackend(),"flags:",A)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&h("flags:",e.config.flags);for(let[s,A]of Object.entries(e.config.flags))S.env().set(s,A)}S.enableProdMode(),Y1(),e.performance.initBackend=Math.trunc(v()-r),e.config.backend=S.getBackend(),await R.updateBackend(),bs(e.config)}return!0}function _2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&h("kernelFunc",n,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};S.registerKernel(o)}R.kernels=S.getKernelsForBackend(S.getBackend()).map(n=>n.kernelName.toLowerCase())}var rt={};ze(rt,{all:()=>Js,body:()=>et,canvas:()=>Ks,face:()=>$2,gesture:()=>ot,hand:()=>tt,init:()=>l5,object:()=>nt,options:()=>f0,person:()=>Ys});var oe=e=>{if(!e)h("draw error: invalid canvas");else if(!e.getContext)h("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)h("draw error: cannot get canvas context");else return t}return null},Je=e=>Math.round(e*180/Math.PI),Y=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Qe=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function re(e,t,n,o,r){let s=t.replace(/\[.*\]/g,"").split(` +`;var _t=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(r,s)=>(n[s]=0,r))},$t=class{constructor(t,n,o){w(this,"uniform",{});w(this,"attribute",{});w(this,"gl");w(this,"id");w(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(h(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(h("filter: could not create shader"),null)});this.gl=t;let r=this.compile(n,this.gl.VERTEX_SHADER),s=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){h("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){h(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),_t(n,"attribute",this.attribute);for(let A in this.attribute)this.attribute[A]=this.gl.getAttribLocation(this.id,A);_t(n,"uniform",this.uniform),_t(o,"uniform",this.uniform);for(let A in this.uniform)this.uniform[A]=this.gl.getUniformLocation(this.id,A)}}};function V1(){let e=0,t=null,n=!1,o=-1,r=[null,null],s=[],A=null,a=null,l=Ae(100,100),c={},x={INTERMEDIATE:1},i=l.getContext("webgl");if(!i){h("filter: cannot get webgl context");return}this.gl=i;function f(g,p){if(!(g===l.width&&p===l.height)){if(l.width=g,l.height=p,!A){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);A=i.createBuffer(),i.bindBuffer(i.ARRAY_BUFFER,A),i.bufferData(i.ARRAY_BUFFER,b,i.STATIC_DRAW),i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}i.viewport(0,0,l.width,l.height),r=[null,null]}}function d(g,p){let b=i.createFramebuffer();i.bindFramebuffer(i.FRAMEBUFFER,b);let k=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,k);let P=i.createTexture();return i.bindTexture(i.TEXTURE_2D,P),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,g,p,0,i.RGBA,i.UNSIGNED_BYTE,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.framebufferTexture2D(i.FRAMEBUFFER,i.COLOR_ATTACHMENT0,i.TEXTURE_2D,P,0),i.bindTexture(i.TEXTURE_2D,null),i.bindFramebuffer(i.FRAMEBUFFER,null),{fbo:b,texture:P}}function m(g){return r[g]=r[g]||d(l.width,l.height),r[g]}function y(g=0){if(!a)return;let p=null,b=null,k=!1;e===0?p=t:p=m(o).texture||null,e++,n&&!(g&x.INTERMEDIATE)?(b=null,k=e%2===0):(o=(o+1)%2,b=m(o).fbo||null),i.bindTexture(i.TEXTURE_2D,p),i.bindFramebuffer(i.FRAMEBUFFER,b),i.uniform1f(a.uniform.flipY,k?-1:1),i.drawArrays(i.TRIANGLES,0,6)}function u(g){if(c[g])return a=c[g],i.useProgram((a?a.id:null)||null),a;if(a=new $t(i,W1,g),!a)return h("filter: could not get webgl program"),null;let p=Float32Array.BYTES_PER_ELEMENT,b=4*p;return i.enableVertexAttribArray(a.attribute.pos),i.vertexAttribPointer(a.attribute.pos,2,i.FLOAT,!1,b,0*p),i.enableVertexAttribArray(a.attribute.uv),i.vertexAttribPointer(a.attribute.uv,2,i.FLOAT,!1,b,2*p),c[g]=a,a}let T={colorMatrix:g=>{let p=new Float32Array(g);p[4]/=255,p[9]/=255,p[14]/=255,p[19]/=255;let b=p[18]===1&&p[3]===0&&p[8]===0&&p[13]===0&&p[15]===0&&p[16]===0&&p[17]===0&&p[19]===0?F1:D1,k=u(b);k&&(i.uniform1fv(k.uniform.m,p),y())},brightness:g=>{let p=(g||0)+1;T.colorMatrix([p,0,0,0,0,0,p,0,0,0,0,0,p,0,0,0,0,0,1,0])},saturation:g=>{let p=(g||0)*2/3+1,b=(p-1)*-.5;T.colorMatrix([p,b,b,0,0,b,p,b,0,0,b,b,p,0,0,0,0,0,1,0])},desaturate:()=>{T.saturation(-1)},contrast:g=>{let p=(g||0)+1,b=-128*(p-1);T.colorMatrix([p,0,0,0,b,0,p,0,0,b,0,0,p,0,b,0,0,0,1,0])},negative:()=>{T.contrast(-2)},hue:g=>{g=(g||0)/180*Math.PI;let p=Math.cos(g),b=Math.sin(g),k=.213,P=.715,N=.072;T.colorMatrix([k+p*(1-k)+b*-k,P+p*-P+b*-P,N+p*-N+b*(1-N),0,0,k+p*-k+b*.143,P+p*(1-P)+b*.14,N+p*-N+b*-.283,0,0,k+p*-k+b*-(1-k),P+p*-P+b*P,N+p*(1-N)+b*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{T.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{T.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{T.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{T.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{T.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{T.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{T.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{T.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:g=>{let p=new Float32Array(g),b=1/l.width,k=1/l.height,P=u(G1);P&&(i.uniform1fv(P.uniform.m,p),i.uniform2f(P.uniform.px,b,k),y())},detectEdges:()=>{T.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{T.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{T.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:g=>{let p=g||1;T.convolution.call(this,[0,-1*p,0,-1*p,1+4*p,-1*p,0,-1*p,0])},emboss:g=>{let p=g||1;T.convolution.call(this,[-2*p,-1*p,0,-1*p,1,1*p,0,1*p,2*p])},blur:g=>{let p=g/7/l.width,b=g/7/l.height,k=u(H1);k&&(i.uniform2f(k.uniform.px,0,b),y(x.INTERMEDIATE),i.uniform2f(k.uniform.px,p,0),y())},pixelate:g=>{let p=g/l.width,b=g/l.height,k=u(B1);k&&(i.uniform2f(k.uniform.size,p,b),y())}};this.add=function(g){let p=Array.prototype.slice.call(arguments,1),b=T[g];s.push({func:b,args:p})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(g){f(g.width,g.height),e=0,t||(t=i.createTexture()),i.bindTexture(i.TEXTURE_2D,t),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.NEAREST),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.NEAREST),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,g);for(let p=0;px.data())),A=Math.max(s[0][0],s[1][0],s[2][0]),l=(A>1?255:1)/A,c;if(l>1){let x=[U.sub(n[0],o[0]),U.sub(n[1],o[1]),U.sub(n[2],o[2])],i=[U.sub(r[0],o[0]),U.sub(r[1],o[1]),U.sub(r[2],o[2])],f=[U.mul(x[0],l),U.mul(x[1],l),U.mul(x[2],l)],d=U.stack([f[0],f[1],f[2]],2);c=U.reshape(d,[1,t.shape[0]||0,t.shape[1]||0,3]),U.dispose([...x,...i,...f,d])}else c=U.expandDims(t,0);return U.dispose([...n,...o,...r,n,t,e]),c}var U2=3840,R0=null,M0=null,y2=null,e0,ne={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function e5(){ne.inputSum=0,ne.cacheDiff=1,ne.sumMethod=0,ne.inputTensor=void 0}function Ae(e,t){let n;if(R.browser)if(R.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof R.Canvas!="undefined")n=new R.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof R.Canvas!="undefined"?n=new R.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function Y2(e,t){let n=t||Ae(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function K2(e,t,n=!0){var f,d,m;if(!e)return t.debug&&h("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof I.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof I.Tensor){let y=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)y=I.expandDims(e,0);else if(e.shape[2]===4){let u=I.slice3d(e,[0,0,0],[-1,-1,3]);y=I.expandDims(u,0),I.dispose(u)}}else e.shape.length===4&&(e.shape[3]===3?y=I.clone(e):e.shape[3]===4&&(y=I.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(y==null||y.shape.length!==4||y.shape[0]!==1||y.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(y.dtype==="int32"){let u=I.cast(y,"float32");I.dispose(y),y=u}return{tensor:y,canvas:t.filter.return?M0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&h("input stream is not ready"),{tensor:null,canvas:R0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!r)return t.debug&&h("cannot determine input dimensions"),{tensor:null,canvas:R0};let s=o,A=r;if(s>U2&&(s=U2,A=Math.trunc(s*r/o)),A>U2&&(A=U2,s=Math.trunc(A*o/r)),(((f=t.filter)==null?void 0:f.width)||0)>0?s=t.filter.width:(((d=t.filter)==null?void 0:d.height)||0)>0&&(s=o*((t.filter.height||0)/r)),(t.filter.height||0)>0?A=t.filter.height:(t.filter.width||0)>0&&(A=r*((t.filter.width||0)/o)),!s||!A)throw new Error("input error: cannot determine dimension");(!R0||R0.width!==s||R0.height!==A)&&(R0=Ae(s,A));let a=R0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?a.putImageData(e,0,0):t.filter.flip&&typeof a.translate!="undefined"?(a.translate(o,0),a.scale(-1,1),a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),a.setTransform(1,0,0,1,0,0)):a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),(!M0||R0.width!==M0.width||R0.height!==M0.height)&&(M0=Ae(R0.width,R0.height)),t.filter.enabled&&R.webgl.supported?(e0||(e0=R.browser?new V1:null),R.filter=!!e0,e0!=null&&e0.add?(e0.reset(),t.filter.brightness!==0&&e0.add("brightness",t.filter.brightness),t.filter.contrast!==0&&e0.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&e0.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&e0.add("blur",t.filter.blur),t.filter.saturation!==0&&e0.add("saturation",t.filter.saturation),t.filter.hue!==0&&e0.add("hue",t.filter.hue),t.filter.negative&&e0.add("negative"),t.filter.sepia&&e0.add("sepia"),t.filter.vintage&&e0.add("brownie"),t.filter.sepia&&e0.add("sepia"),t.filter.kodachrome&&e0.add("kodachrome"),t.filter.technicolor&&e0.add("technicolor"),t.filter.polaroid&&e0.add("polaroid"),t.filter.pixelate!==0&&e0.add("pixelate",t.filter.pixelate),((m=e0.get())==null?void 0:m.length)>1?M0=e0.apply(R0):M0=e0.draw(R0)):(t.debug&&h("input process error: cannot initialize filters"),R.webgl.supported=!1,t.filter.enabled=!1,Y2(R0,M0))):(Y2(R0,M0),e0&&(e0=null),R.filter=!!e0),!n)return{tensor:null,canvas:M0};if(!M0)throw new Error("canvas error: cannot create output");let l,c=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(R.browser&&I.browser)l=I.browser?I.browser.fromPixels(e):null;else{c=e.data.length/e.height/e.width;let y=new Uint8Array(e.data.buffer);l=I.tensor(y,[e.height,e.width,c],"int32")}else if((!y2||M0.width!==y2.width||M0.height!==y2.height)&&(y2=Ae(M0.width,M0.height)),I.browser&&R.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=I.browser.fromPixels(M0):(y2=Y2(M0),l=I.browser.fromPixels(y2));else{let T=Y2(M0).getContext("2d").getImageData(0,0,s,A);c=T.data.length/s/A;let g=new Uint8Array(T.data.buffer);l=I.tensor(g,[s,A,c])}if(c===4){let y=I.slice3d(l,[0,0,0],[-1,-1,3]);I.dispose(l),l=y}if(!l)throw new Error("input error: cannot create tensor");let x=I.cast(l,"float32"),i=t.filter.equalization?await X2(x):I.expandDims(x,0);if(I.dispose([l,x]),t.filter.autoBrightness){let y=I.max(i),u=await y.data();t.filter.brightness=u[0]>1?1-u[0]/255:1-u[0],I.dispose(y)}return{tensor:i,canvas:t.filter.return?M0:null}}async function Z1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!ne.inputTensor)ne.inputTensor=I.clone(t);else if(ne.inputTensor.shape[1]!==t.shape[1]||ne.inputTensor.shape[2]!==t.shape[2])I.dispose(ne.inputTensor),ne.inputTensor=I.clone(t);else{let o={};o.diff=I.sub(t,ne.inputTensor),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;I.dispose([ne.inputTensor,o.diff,o.squared,o.sum]),ne.inputTensor=I.clone(t),n=s<=(e.cacheSensitivity||0)}return n}async function q1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||h("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||h("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=I.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?I.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):I.clone(n),o.diff=I.sub(o.input1,o.input2),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return I.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),s}var j2,I2,N2,S2=class{constructor(){w(this,"browser");w(this,"node");w(this,"worker");w(this,"platform","");w(this,"agent","");w(this,"backends",[]);w(this,"initial");w(this,"filter");w(this,"tfjs");w(this,"offscreen");w(this,"perfadd",!1);w(this,"tensorflow",{version:void 0,gpu:void 0});w(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});w(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});w(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});w(this,"cpu",{model:void 0,flags:[]});w(this,"kernels",[]);ue(this,j2,void 0);ue(this,I2,void 0);ue(this,N2,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:W0.version["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Y0(this,j2)}set Canvas(t){Re(this,j2,t),globalThis.Canvas=t}get Image(){return Y0(this,I2)}set Image(t){Re(this,I2,t),globalThis.Image=t}get ImageData(){return Y0(this,N2)}set ImageData(t){Re(this,N2,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(W0.engine().registryFactory);try{this.tensorflow={version:W0.backend().binding?W0.backend().binding.TF_Version:void 0,gpu:W0.backend().binding?W0.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W0.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W0.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=Ae(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=W0.getKernelsForBackend(W0.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};j2=new WeakMap,I2=new WeakMap,N2=new WeakMap;var R=new S2;var Q2=class{constructor(){w(this,"config");w(this,"element");w(this,"stream");w(this,"devices",[]);w(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});w(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let A=document.getElementById(t.element);if(A&&A instanceof HTMLVideoElement)this.element=A;else return this.config.debug&&h("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&h("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(n.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&h("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&h("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&h("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(A){return h("webcam",A),`webcam error: ${A}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(A=>{this.element?this.element.onloadeddata=()=>A(!0):A(!1)}),await this.element.play(),this.config.debug&&h("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&h("webcam error","no stream"),"webcam error no stream")});w(this,"pause",()=>{this.element&&this.element.pause()});w(this,"play",async()=>{this.element&&await this.element.play()});w(this,"stop",()=>{this.config.debug&&h("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var f2=G(H());var t5={};ze(t5,{"affectnet-mobilenet":()=>br,age:()=>gr,"anti-spoofing":()=>_r,antispoof:()=>ar,blazeface:()=>ir,"blazeface-back":()=>Tr,"blazeface-front":()=>vr,"blazepose-detector":()=>Rr,"blazepose-full":()=>Mr,"blazepose-heavy":()=>Pr,"blazepose-lite":()=>kr,centernet:()=>lr,default:()=>ds,efficientpose:()=>wr,"efficientpose-i-lite":()=>$r,"efficientpose-ii-lite":()=>es,"efficientpose-iv":()=>ts,emotion:()=>cr,faceboxes:()=>Er,facemesh:()=>dr,"facemesh-attention":()=>Sr,"facemesh-attention-pinto":()=>zr,"facemesh-detection-full":()=>jr,"facemesh-detection-short":()=>Ir,faceres:()=>xr,"faceres-deep":()=>Nr,gear:()=>Cr,"gear-e1":()=>Or,"gear-e2":()=>Lr,gender:()=>Dr,"gender-ssrnet-imdb":()=>Wr,handdetect:()=>Fr,"handlandmark-full":()=>Br,"handlandmark-lite":()=>yr,"handlandmark-sparse":()=>Hr,handskeleton:()=>Gr,handtrack:()=>fr,"insightface-efficientnet-b0":()=>ns,"insightface-ghostnet-strides1":()=>os,"insightface-ghostnet-strides2":()=>rs,"insightface-mobilenet-emore":()=>ss,"insightface-mobilenet-swish":()=>As,iris:()=>mr,liveness:()=>pr,meet:()=>Vr,mobileface:()=>Zr,mobilefacenet:()=>qr,models:()=>ur,"movenet-lightning":()=>hr,"movenet-multipose":()=>Xr,"movenet-thunder":()=>Ur,nanodet:()=>Yr,"nanodet-e":()=>as,"nanodet-g":()=>is,"nanodet-m":()=>ls,"nanodet-t":()=>cs,posenet:()=>Kr,rvm:()=>Jr,selfie:()=>Qr});var ar=853098,ir=538928,lr=4030290,cr=820516,dr=1477958,xr=6978814,yr=2023432,fr=2964837,mr=2599092,pr=592976,ur=0,hr=4650216,br=6920630,gr=161240,Tr=538928,vr=402048,Rr=5928856,Mr=6339202,Pr=27502466,kr=2726402,wr=5651240,Er=2013002,zr=2387598,Sr=2382414,jr=1026192,Ir=201268,Nr=13957620,Or=112438,Lr=112438,Cr=1498916,Wr=161236,Dr=201808,Fr=3515612,Br=5431368,Hr=5286322,Gr=5502280,Vr=372228,Zr=2183192,qr=5171976,Xr=9448838,Ur=12477112,Yr=7574558,Kr=5032780,Jr=3739355,Qr=212886,_r=853098,$r=2269064,es=5651240,ts=25643252,ns=13013224,os=8093408,rs=8049584,ss=6938536,As=12168584,as=12319156,is=7574558,ls=1887474,cs=5294216,ds={antispoof:ar,blazeface:ir,centernet:lr,emotion:cr,facemesh:dr,faceres:xr,"handlandmark-lite":yr,handtrack:fr,iris:mr,liveness:pr,models:ur,"movenet-lightning":hr,"affectnet-mobilenet":br,age:gr,"blazeface-back":Tr,"blazeface-front":vr,"blazepose-detector":Rr,"blazepose-full":Mr,"blazepose-heavy":Pr,"blazepose-lite":kr,efficientpose:wr,faceboxes:Er,"facemesh-attention-pinto":zr,"facemesh-attention":Sr,"facemesh-detection-full":jr,"facemesh-detection-short":Ir,"faceres-deep":Nr,"gear-e1":Or,"gear-e2":Lr,gear:Cr,"gender-ssrnet-imdb":Wr,gender:Dr,handdetect:Fr,"handlandmark-full":Br,"handlandmark-sparse":Hr,handskeleton:Gr,meet:Vr,mobileface:Zr,mobilefacenet:qr,"movenet-multipose":Xr,"movenet-thunder":Ur,nanodet:Yr,posenet:Kr,rvm:Jr,selfie:Qr,"anti-spoofing":_r,"efficientpose-i-lite":$r,"efficientpose-ii-lite":es,"efficientpose-iv":ts,"insightface-efficientnet-b0":ns,"insightface-ghostnet-strides1":os,"insightface-ghostnet-strides2":rs,"insightface-mobilenet-emore":ss,"insightface-mobilenet-swish":As,"nanodet-e":as,"nanodet-g":is,"nanodet-m":ls,"nanodet-t":cs};var D0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},I0={};async function xs(e,t){return D0.debug&&h("load model fetch:",e,t),fetch(e,t)}function X1(e){D0.cacheModels=e.cacheModels,D0.verbose=e.debug,D0.modelBasePath=e.modelBasePath}async function O(e){var c,x,i,f;let t=C1(D0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),r="indexeddb://"+o;I0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:t5[o],inCache:!1,url:""},D0.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=D0.cacheSupported&&D0.cacheModels?await f2.io.listModels():{}}catch(d){D0.cacheSupported=!1}I0[o].inCache=D0.cacheSupported&&D0.cacheModels&&Object.keys(s).includes(r),I0[o].url=I0[o].inCache?r:t;let A=typeof fetch=="undefined"?{}:{fetchFunc:(d,m)=>xs(d,m)},a=new f2.GraphModel(I0[o].url,A),l=!1;try{a.findIOHandler(),D0.debug&&h("model load handler:",a.handler)}catch(d){h("error finding model i/o handler:",t,d)}try{let d=await((c=a.handler)==null?void 0:c.load())||null;I0[o].sizeFromManifest=((x=d==null?void 0:d.weightData)==null?void 0:x.byteLength)||0,d?a.loadSync(d):a=await f2.loadGraphModel(I0[o].inCache?r:t,A),I0[o].sizeLoadedWeights=((f=(i=a.artifacts)==null?void 0:i.weightData)==null?void 0:f.byteLength)||0,D0.verbose&&h("load:",{model:o,url:a.modelUrl,bytes:I0[o].sizeLoadedWeights}),l=!0}catch(d){h("error loading model:",t,d)}if(l&&D0.cacheModels&&D0.cacheSupported&&!I0[o].inCache)try{let d=await a.save(r);D0.debug&&h("model saved:",r,d)}catch(d){h("error saving model:",t,d)}return a}var n5="3.1.2";var S=G(H());var u0=G(H());var o0={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ms(){let e=o0.gl;e&&(o0.extensions=e.getSupportedExtensions())}function U1(e){var t;if(e.config.backend==="humangl"&&(o0.name in u0.engine().registry&&!((t=o0==null?void 0:o0.gl)!=null&&t.getParameter(o0.gl.VERSION))&&(h("humangl error: backend invalid context"),e.models.reset()),!u0.findBackend(o0.name))){try{o0.canvas=Ae(100,100)}catch(r){h("humangl error: cannot create canvas:",r);return}try{if(o0.gl=o0.canvas.getContext("webgl2",o0.webGLattr),!o0.gl){h("humangl error: cannot get webgl context");return}if(!o0.gl.getParameter(o0.gl.VERSION).includes("2.0")){h("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}o0.canvas&&(o0.canvas.addEventListener("webglcontextlost",s=>{throw h("humangl error:",s.type),h("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),o0.canvas.addEventListener("webglcontextrestored",s=>{h("humangl error: context restored:",s)}),o0.canvas.addEventListener("webglcontextcreationerror",s=>{h("humangl error: context create:",s)}))}catch(r){h("humangl error: cannot get webgl context:",r);return}try{u0.setWebGLContext(2,o0.gl)}catch(r){h("humangl error: cannot set webgl context:",r);return}try{let r=new u0.GPGPUContext(o0.gl);u0.registerBackend(o0.name,()=>new u0.MathBackendWebGL(r),o0.priority)}catch(r){h("humangl error: cannot register webgl backend:",r);return}try{u0.getKernelsForBackend("webgl").forEach(s=>{let A={...s,backendName:o0.name};u0.registerKernel(A)})}catch(r){h("humangl error: cannot update webgl backend registration:",r);return}try{u0.env().flagRegistry.WEBGL_VERSION&&u0.env().set("WEBGL_VERSION",2)}catch(r){h("humangl error: cannot set WebGL backend flags:",r);return}ms();let n=u0.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&h("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):h("humangl error: no current gl context:",o,o0.gl)}}var Se=G(H()),C={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function Y1(){C.tf255=Se.scalar(255,"float32"),C.tf1=Se.scalar(1,"float32"),C.tf2=Se.scalar(2,"float32"),C.tf05=Se.scalar(.5,"float32"),C.tf127=Se.scalar(127.5,"float32"),C.rgb=Se.tensor1d([.2989,.587,.114],"float32")}async function hs(){var e;return await R.updateBackend(),(e=R.tensorflow)!=null&&e.version?"tensorflow":R.webgpu.supported&&R.webgpu.backend?"webgpu":R.webgl.supported&&R.webgl.backend?"webgl":R.wasm.supported&&R.wasm.backend?"wasm":"cpu"}function bs(e){let t=[];if(!R.kernels.includes("mod")){let n={kernelName:"Mod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.sub(o.inputs.a,S.mul(S.div(o.inputs.a,o.inputs.b),o.inputs.b)))};S.registerKernel(n),R.kernels.push("mod"),t.push("mod")}if(!R.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.add(S.mul(S.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),S.mod(o.inputs.a,o.inputs.b)))};S.registerKernel(n),R.kernels.push("floormod"),t.push("floormod")}if(!R.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>{let r=S.getBackend();S.setBackend("cpu");let s=S.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return S.setBackend(r),s})};S.registerKernel(n),R.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&h("registered kernels:",t)}var K1={};async function O2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await hs()),t||R.initial||e.config.backend&&e.config.backend.length>0&&S.getBackend()!==e.config.backend){let r=v();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&h("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&h("running inside electron");let s=Object.keys(S.engine().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(U1(e),s=Object.keys(S.engine().registryFactory)),e.config.debug&&h("available backends:",s),R.browser&&!R.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&h("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),R.node&&!R.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&h(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),R.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")h("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let A=await navigator.gpu.requestAdapter();if(e.config.debug&&h("enumerated webgpu adapter:",A),!A)h("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let a="requestAdapterInfo"in A?await A.requestAdapterInfo():void 0;h("webgpu adapter info:",a)}}if(s.includes(e.config.backend)||(h(`error: backend ${e.config.backend} not found in registry`),e.config.backend=R.node?"tensorflow":"webgl",e.config.debug&&h(`override: setting backend ${e.config.backend}`)),e.config.debug&&h("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(S.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&S.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&h("wasm path:",e.config.wasmPath),typeof S.setWasmPaths!="undefined")S.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let A=!1,a=!1;try{A=await S.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),a=await S.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&h(`wasm execution: ${a?"simd":"no simd"} ${A?"multithreaded":"singlethreaded"}`),e.config.debug&&!a&&h("warning: wasm simd support is not enabled")}catch(l){h("wasm detection failed")}}try{await S.setBackend(e.config.backend),await S.ready()}catch(A){return h("error: cannot set backend:",e.config.backend,A),!1}e.config.debug&&(K1=JSON.parse(JSON.stringify(S.env().flags)))}if((S.getBackend()==="humangl"||S.getBackend()==="webgl")&&(S.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&S.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),S.env().flagRegistry.WEBGL_EXP_CONV&&S.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(h("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),S.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),S.getBackend(),e.config.debug){let s=S.env().flags,A={};for(let a of Object.keys(s))K1[a]!==s[a]&&(A[a]=s[a]);e.config.debug&&Object.keys(A).length>0&&h("backend:",S.getBackend(),"flags:",A)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&h("flags:",e.config.flags);for(let[s,A]of Object.entries(e.config.flags))S.env().set(s,A)}S.enableProdMode(),Y1(),e.performance.initBackend=Math.trunc(v()-r),e.config.backend=S.getBackend(),await R.updateBackend(),bs(e.config)}return!0}function _2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&h("kernelFunc",n,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};S.registerKernel(o)}R.kernels=S.getKernelsForBackend(S.getBackend()).map(n=>n.kernelName.toLowerCase())}var rt={};ze(rt,{all:()=>Js,body:()=>et,canvas:()=>Ks,face:()=>$2,gesture:()=>ot,hand:()=>tt,init:()=>l5,object:()=>nt,options:()=>f0,person:()=>Ys});var oe=e=>{if(!e)h("draw error: invalid canvas");else if(!e.getContext)h("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)h("draw error: cannot get canvas context");else return t}return null},Je=e=>Math.round(e*180/Math.PI),Y=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Qe=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function re(e,t,n,o,r){let s=t.replace(/\[.*\]/g,"").split(` `).map(a=>a.trim()),A=Math.max(0,n);for(let a=s.length-1;a>=0;a--){let l=a*r.lineHeight+o;r.shadowColor&&r.shadowColor!==""&&(e.fillStyle=r.shadowColor,e.fillText(s[a],A+5,l+16)),e.fillStyle=r.labelColor,e.fillText(s[a],A+4,l+15)}}function he(e,t,n,o,r){e.fillStyle=Qe(o,r),e.beginPath(),e.arc(t,n,r.pointSize,0,2*Math.PI),e.fill()}function be(e,t,n,o,r,s){if(e.beginPath(),e.lineWidth=s.lineWidth,s.useCurves){let A=(t+t+o)/2,a=(n+n+r)/2;e.ellipse(A,a,o/2,r/2,0,0,2*Math.PI)}else e.moveTo(t+s.roundRect,n),e.lineTo(t+o-s.roundRect,n),e.quadraticCurveTo(t+o,n,t+o,n+s.roundRect),e.lineTo(t+o,n+r-s.roundRect),e.quadraticCurveTo(t+o,n+r,t+o-s.roundRect,n+r),e.lineTo(t+s.roundRect,n+r),e.quadraticCurveTo(t,n+r,t,n+r-s.roundRect),e.lineTo(t,n+s.roundRect),e.quadraticCurveTo(t,n,t+s.roundRect,n),e.closePath();e.stroke()}function o5(e,t,n){if(!(t.length<2)){e.beginPath(),e.moveTo(t[0][0],t[0][1]);for(let o of t)e.strokeStyle=Qe(o[2]||0,n),e.lineTo(Math.trunc(o[0]),Math.trunc(o[1]));e.stroke(),n.fillPolygons&&(e.closePath(),e.fill())}}function Q1(e,t,n){if(!(t.length<2)){if(e.lineWidth=n.lineWidth,!n.useCurves||t.length<=2){o5(e,t,n);return}e.moveTo(t[0][0],t[0][1]);for(let o=0;oL2[e]),Za=Ts.map(e=>L2[e]),qa=vs.map(e=>L2[e]);function je(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Rs=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Ms=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Ps=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],ks=[[474,475],[475,476],[476,477],[477,474]],ws=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Es=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],zs=[[469,470],[470,471],[471,472],[472,469]],Ss=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]],Xa={lips:je(Rs),leftEye:je(Ms),leftEyebrow:je(Ps),leftIris:je(ks),rightEye:je(ws),rightEyebrow:je(Es),rightIris:je(zs),faceOval:je(Ss)};var js=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Is=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Ns=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],Os=[[474,475],[475,476],[476,477],[477,474]],Ls=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Cs=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],Ws=[[469,470],[470,471],[471,472],[472,469]],Ds=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]];function Ie(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Fs={lips:Ie(js),leftEye:Ie(Is),leftEyebrow:Ie(Ns),leftIris:Ie(Os),rightEye:Ie(Ls),rightEyebrow:Ie(Cs),rightIris:Ie(Ws),faceOval:Ie(Ds)},Bs=Object.entries(Fs).map(([e,t])=>t.map(n=>[n,e])).flat(),Ua=new Map(Bs),C2=[61,146,91,181,84,17,314,405,321,375,291,185,40,39,37,0,267,269,270,409,78,95,88,178,87,14,317,402,318,324,308,191,80,81,82,13,312,311,310,415,76,77,90,180,85,16,315,404,320,307,306,184,74,73,72,11,302,303,304,408,62,96,89,179,86,15,316,403,319,325,292,183,42,41,38,12,268,271,272,407],e2=[33,7,163,144,145,153,154,155,133,246,161,160,159,158,157,173,130,25,110,24,23,22,26,112,243,247,30,29,27,28,56,190,226,31,228,229,230,231,232,233,244,113,225,224,223,222,221,189,35,124,46,53,52,65,143,111,117,118,119,120,121,128,245,156,70,63,105,66,107,55,193],t2=[263,249,390,373,374,380,381,382,362,466,388,387,386,385,384,398,359,255,339,254,253,252,256,341,463,467,260,259,257,258,286,414,446,261,448,449,450,451,452,453,464,342,445,444,443,442,441,413,265,353,276,283,282,295,372,340,346,347,348,349,350,357,465,383,300,293,334,296,336,285,417];var X;function Hs(e,t){var o,r,s,A,a,l,c,x,i;if(!X.drawLabels||((o=X.faceLabels)==null?void 0:o.length)===0)return;let n=X.faceLabels.slice();if(n=Y(n,"[id]",e.id.toFixed(0)),e.score&&(n=Y(n,"[score]",100*e.score)),e.gender&&(n=Y(n,"[gender]",e.gender)),e.genderScore&&(n=Y(n,"[genderScore]",100*e.genderScore)),e.age&&(n=Y(n,"[age]",e.age)),e.distance&&(n=Y(n,"[distance]",100*e.distance)),e.real&&(n=Y(n,"[real]",100*e.real)),e.live&&(n=Y(n,"[live]",100*e.live)),e.emotion&&e.emotion.length>0){let f=e.emotion.map(d=>`${Math.trunc(100*d.score)}% ${d.emotion}`);f.length>3&&(f.length=3),n=Y(n,"[emotions]",f.join(" "))}(s=(r=e.rotation)==null?void 0:r.angle)!=null&&s.roll&&(n=Y(n,"[roll]",Je(e.rotation.angle.roll))),(a=(A=e.rotation)==null?void 0:A.angle)!=null&&a.yaw&&(n=Y(n,"[yaw]",Je(e.rotation.angle.yaw))),(c=(l=e.rotation)==null?void 0:l.angle)!=null&&c.pitch&&(n=Y(n,"[pitch]",Je(e.rotation.angle.pitch))),(i=(x=e.rotation)==null?void 0:x.gaze)!=null&&i.bearing&&(n=Y(n,"[gaze]",Je(e.rotation.gaze.bearing))),re(t,n,e.box[0],e.box[1],X)}function Gs(e,t){var n,o,r,s;if((n=e.annotations)!=null&&n.leftEyeIris&&((o=e.annotations)!=null&&o.leftEyeIris[0])){t.strokeStyle=X.useDepth?"rgba(255, 200, 255, 0.3)":X.color,t.beginPath();let A=Math.abs(e.annotations.leftEyeIris[3][0]-e.annotations.leftEyeIris[1][0])/2,a=Math.abs(e.annotations.leftEyeIris[4][1]-e.annotations.leftEyeIris[2][1])/2;t.ellipse(e.annotations.leftEyeIris[0][0],e.annotations.leftEyeIris[0][1],A,a,0,0,2*Math.PI),t.stroke(),X.fillPolygons&&(t.fillStyle=X.useDepth?"rgba(255, 255, 200, 0.3)":X.color,t.fill())}if((r=e.annotations)!=null&&r.rightEyeIris&&((s=e.annotations)!=null&&s.rightEyeIris[0])){t.strokeStyle=X.useDepth?"rgba(255, 200, 255, 0.3)":X.color,t.beginPath();let A=Math.abs(e.annotations.rightEyeIris[3][0]-e.annotations.rightEyeIris[1][0])/2,a=Math.abs(e.annotations.rightEyeIris[4][1]-e.annotations.rightEyeIris[2][1])/2;t.ellipse(e.annotations.rightEyeIris[0][0],e.annotations.rightEyeIris[0][1],A,a,0,0,2*Math.PI),t.stroke(),X.fillPolygons&&(t.fillStyle=X.useDepth?"rgba(255, 255, 200, 0.3)":X.color,t.fill())}}function Vs(e,t){var n;if(X.drawGaze&&((n=e.rotation)!=null&&n.angle)&&typeof Path2D!="undefined"){t.strokeStyle="pink";let o=e.box[0]+e.box[2]/2-e.box[3]*Je(e.rotation.angle.yaw)/90,r=e.box[1]+e.box[3]/2+e.box[2]*Je(e.rotation.angle.pitch)/90,s=new Path2D(` M ${e.box[0]+e.box[2]/2} ${e.box[1]} C diff --git a/dist/human.node.js b/dist/human.node.js index 497febd2..d8192ca1 100644 --- a/dist/human.node.js +++ b/dist/human.node.js @@ -96,7 +96,7 @@ c31 * m[6] + c32 * m[7] + c33 * m[8]; gl_FragColor.a = c22.a; } -`;var Qt=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(r,s)=>(n[s]=0,r))},_t=class{constructor(t,n,o){w(this,"uniform",{});w(this,"attribute",{});w(this,"gl");w(this,"id");w(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(h(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(h("filter: could not create shader"),null)});this.gl=t;let r=this.compile(n,this.gl.VERTEX_SHADER),s=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){h("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){h(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),Qt(n,"attribute",this.attribute);for(let A in this.attribute)this.attribute[A]=this.gl.getAttribLocation(this.id,A);Qt(n,"uniform",this.uniform),Qt(o,"uniform",this.uniform);for(let A in this.uniform)this.uniform[A]=this.gl.getUniformLocation(this.id,A)}}};function G1(){let e=0,t=null,n=!1,o=-1,r=[null,null],s=[],A=null,a=null,l=Ae(100,100),c={},x={INTERMEDIATE:1},i=l.getContext("webgl");if(!i){h("filter: cannot get webgl context");return}this.gl=i;function f(g,p){if(!(g===l.width&&p===l.height)){if(l.width=g,l.height=p,!A){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);A=i.createBuffer(),i.bindBuffer(i.ARRAY_BUFFER,A),i.bufferData(i.ARRAY_BUFFER,b,i.STATIC_DRAW),i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}i.viewport(0,0,l.width,l.height),r=[null,null]}}function d(g,p){let b=i.createFramebuffer();i.bindFramebuffer(i.FRAMEBUFFER,b);let k=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,k);let P=i.createTexture();return i.bindTexture(i.TEXTURE_2D,P),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,g,p,0,i.RGBA,i.UNSIGNED_BYTE,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.framebufferTexture2D(i.FRAMEBUFFER,i.COLOR_ATTACHMENT0,i.TEXTURE_2D,P,0),i.bindTexture(i.TEXTURE_2D,null),i.bindFramebuffer(i.FRAMEBUFFER,null),{fbo:b,texture:P}}function m(g){return r[g]=r[g]||d(l.width,l.height),r[g]}function y(g=0){if(!a)return;let p=null,b=null,k=!1;e===0?p=t:p=m(o).texture||null,e++,n&&!(g&x.INTERMEDIATE)?(b=null,k=e%2===0):(o=(o+1)%2,b=m(o).fbo||null),i.bindTexture(i.TEXTURE_2D,p),i.bindFramebuffer(i.FRAMEBUFFER,b),i.uniform1f(a.uniform.flipY,k?-1:1),i.drawArrays(i.TRIANGLES,0,6)}function u(g){if(c[g])return a=c[g],i.useProgram((a?a.id:null)||null),a;if(a=new _t(i,C1,g),!a)return h("filter: could not get webgl program"),null;let p=Float32Array.BYTES_PER_ELEMENT,b=4*p;return i.enableVertexAttribArray(a.attribute.pos),i.vertexAttribPointer(a.attribute.pos,2,i.FLOAT,!1,b,0*p),i.enableVertexAttribArray(a.attribute.uv),i.vertexAttribPointer(a.attribute.uv,2,i.FLOAT,!1,b,2*p),c[g]=a,a}let T={colorMatrix:g=>{let p=new Float32Array(g);p[4]/=255,p[9]/=255,p[14]/=255,p[19]/=255;let b=p[18]===1&&p[3]===0&&p[8]===0&&p[13]===0&&p[15]===0&&p[16]===0&&p[17]===0&&p[19]===0?D1:W1,k=u(b);k&&(i.uniform1fv(k.uniform.m,p),y())},brightness:g=>{let p=(g||0)+1;T.colorMatrix([p,0,0,0,0,0,p,0,0,0,0,0,p,0,0,0,0,0,1,0])},saturation:g=>{let p=(g||0)*2/3+1,b=(p-1)*-.5;T.colorMatrix([p,b,b,0,0,b,p,b,0,0,b,b,p,0,0,0,0,0,1,0])},desaturate:()=>{T.saturation(-1)},contrast:g=>{let p=(g||0)+1,b=-128*(p-1);T.colorMatrix([p,0,0,0,b,0,p,0,0,b,0,0,p,0,b,0,0,0,1,0])},negative:()=>{T.contrast(-2)},hue:g=>{g=(g||0)/180*Math.PI;let p=Math.cos(g),b=Math.sin(g),k=.213,P=.715,N=.072;T.colorMatrix([k+p*(1-k)+b*-k,P+p*-P+b*-P,N+p*-N+b*(1-N),0,0,k+p*-k+b*.143,P+p*(1-P)+b*.14,N+p*-N+b*-.283,0,0,k+p*-k+b*-(1-k),P+p*-P+b*P,N+p*(1-N)+b*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{T.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{T.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{T.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{T.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{T.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{T.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{T.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{T.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:g=>{let p=new Float32Array(g),b=1/l.width,k=1/l.height,P=u(H1);P&&(i.uniform1fv(P.uniform.m,p),i.uniform2f(P.uniform.px,b,k),y())},detectEdges:()=>{T.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{T.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{T.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:g=>{let p=g||1;T.convolution.call(this,[0,-1*p,0,-1*p,1+4*p,-1*p,0,-1*p,0])},emboss:g=>{let p=g||1;T.convolution.call(this,[-2*p,-1*p,0,-1*p,1,1*p,0,1*p,2*p])},blur:g=>{let p=g/7/l.width,b=g/7/l.height,k=u(B1);k&&(i.uniform2f(k.uniform.px,0,b),y(x.INTERMEDIATE),i.uniform2f(k.uniform.px,p,0),y())},pixelate:g=>{let p=g/l.width,b=g/l.height,k=u(F1);k&&(i.uniform2f(k.uniform.size,p,b),y())}};this.add=function(g){let p=Array.prototype.slice.call(arguments,1),b=T[g];s.push({func:b,args:p})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(g){f(g.width,g.height),e=0,t||(t=i.createTexture()),i.bindTexture(i.TEXTURE_2D,t),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.NEAREST),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.NEAREST),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,g);for(let p=0;px.data())),A=Math.max(s[0][0],s[1][0],s[2][0]),l=(A>1?255:1)/A,c;if(l>1){let x=[U.sub(n[0],o[0]),U.sub(n[1],o[1]),U.sub(n[2],o[2])],i=[U.sub(r[0],o[0]),U.sub(r[1],o[1]),U.sub(r[2],o[2])],f=[U.mul(x[0],l),U.mul(x[1],l),U.mul(x[2],l)],d=U.stack([f[0],f[1],f[2]],2);c=U.reshape(d,[1,t.shape[0]||0,t.shape[1]||0,3]),U.dispose([...x,...i,...f,d])}else c=U.expandDims(t,0);return U.dispose([...n,...o,...r,n,t,e]),c}var X2=3840,R0=null,M0=null,y2=null,e0,ne={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function $t(){ne.inputSum=0,ne.cacheDiff=1,ne.sumMethod=0,ne.inputTensor=void 0}function Ae(e,t){let n;if(R.browser)if(R.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof R.Canvas!="undefined")n=new R.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof R.Canvas!="undefined"?n=new R.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function q2(e,t){let n=t||Ae(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function U2(e,t,n=!0){var f,d,m;if(!e)return t.debug&&h("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof I.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof I.Tensor){let y=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)y=I.expandDims(e,0);else if(e.shape[2]===4){let u=I.slice3d(e,[0,0,0],[-1,-1,3]);y=I.expandDims(u,0),I.dispose(u)}}else e.shape.length===4&&(e.shape[3]===3?y=I.clone(e):e.shape[3]===4&&(y=I.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(y==null||y.shape.length!==4||y.shape[0]!==1||y.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(y.dtype==="int32"){let u=I.cast(y,"float32");I.dispose(y),y=u}return{tensor:y,canvas:t.filter.return?M0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&h("input stream is not ready"),{tensor:null,canvas:R0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!r)return t.debug&&h("cannot determine input dimensions"),{tensor:null,canvas:R0};let s=o,A=r;if(s>X2&&(s=X2,A=Math.trunc(s*r/o)),A>X2&&(A=X2,s=Math.trunc(A*o/r)),(((f=t.filter)==null?void 0:f.width)||0)>0?s=t.filter.width:(((d=t.filter)==null?void 0:d.height)||0)>0&&(s=o*((t.filter.height||0)/r)),(t.filter.height||0)>0?A=t.filter.height:(t.filter.width||0)>0&&(A=r*((t.filter.width||0)/o)),!s||!A)throw new Error("input error: cannot determine dimension");(!R0||R0.width!==s||R0.height!==A)&&(R0=Ae(s,A));let a=R0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?a.putImageData(e,0,0):t.filter.flip&&typeof a.translate!="undefined"?(a.translate(o,0),a.scale(-1,1),a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),a.setTransform(1,0,0,1,0,0)):a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),(!M0||R0.width!==M0.width||R0.height!==M0.height)&&(M0=Ae(R0.width,R0.height)),t.filter.enabled&&R.webgl.supported?(e0||(e0=R.browser?new G1:null),R.filter=!!e0,e0!=null&&e0.add?(e0.reset(),t.filter.brightness!==0&&e0.add("brightness",t.filter.brightness),t.filter.contrast!==0&&e0.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&e0.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&e0.add("blur",t.filter.blur),t.filter.saturation!==0&&e0.add("saturation",t.filter.saturation),t.filter.hue!==0&&e0.add("hue",t.filter.hue),t.filter.negative&&e0.add("negative"),t.filter.sepia&&e0.add("sepia"),t.filter.vintage&&e0.add("brownie"),t.filter.sepia&&e0.add("sepia"),t.filter.kodachrome&&e0.add("kodachrome"),t.filter.technicolor&&e0.add("technicolor"),t.filter.polaroid&&e0.add("polaroid"),t.filter.pixelate!==0&&e0.add("pixelate",t.filter.pixelate),((m=e0.get())==null?void 0:m.length)>1?M0=e0.apply(R0):M0=e0.draw(R0)):(t.debug&&h("input process error: cannot initialize filters"),R.webgl.supported=!1,t.filter.enabled=!1,q2(R0,M0))):(q2(R0,M0),e0&&(e0=null),R.filter=!!e0),!n)return{tensor:null,canvas:M0};if(!M0)throw new Error("canvas error: cannot create output");let l,c=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(R.browser&&I.browser)l=I.browser?I.browser.fromPixels(e):null;else{c=e.data.length/e.height/e.width;let y=new Uint8Array(e.data.buffer);l=I.tensor(y,[e.height,e.width,c],"int32")}else if((!y2||M0.width!==y2.width||M0.height!==y2.height)&&(y2=Ae(M0.width,M0.height)),I.browser&&R.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=I.browser.fromPixels(M0):(y2=q2(M0),l=I.browser.fromPixels(y2));else{let T=q2(M0).getContext("2d").getImageData(0,0,s,A);c=T.data.length/s/A;let g=new Uint8Array(T.data.buffer);l=I.tensor(g,[s,A,c])}if(c===4){let y=I.slice3d(l,[0,0,0],[-1,-1,3]);I.dispose(l),l=y}if(!l)throw new Error("input error: cannot create tensor");let x=I.cast(l,"float32"),i=t.filter.equalization?await Z2(x):I.expandDims(x,0);if(I.dispose([l,x]),t.filter.autoBrightness){let y=I.max(i),u=await y.data();t.filter.brightness=u[0]>1?1-u[0]/255:1-u[0],I.dispose(y)}return{tensor:i,canvas:t.filter.return?M0:null}}async function V1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!ne.inputTensor)ne.inputTensor=I.clone(t);else if(ne.inputTensor.shape[1]!==t.shape[1]||ne.inputTensor.shape[2]!==t.shape[2])I.dispose(ne.inputTensor),ne.inputTensor=I.clone(t);else{let o={};o.diff=I.sub(t,ne.inputTensor),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;I.dispose([ne.inputTensor,o.diff,o.squared,o.sum]),ne.inputTensor=I.clone(t),n=s<=(e.cacheSensitivity||0)}return n}async function Z1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||h("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||h("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=I.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?I.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):I.clone(n),o.diff=I.sub(o.input1,o.input2),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return I.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),s}var z2,S2,j2,E2=class{constructor(){w(this,"browser");w(this,"node");w(this,"worker");w(this,"platform","");w(this,"agent","");w(this,"backends",[]);w(this,"initial");w(this,"filter");w(this,"tfjs");w(this,"offscreen");w(this,"perfadd",!1);w(this,"tensorflow",{version:void 0,gpu:void 0});w(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});w(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});w(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});w(this,"cpu",{model:void 0,flags:[]});w(this,"kernels",[]);ue(this,z2,void 0);ue(this,S2,void 0);ue(this,j2,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:W0.version["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Y0(this,z2)}set Canvas(t){Re(this,z2,t),globalThis.Canvas=t}get Image(){return Y0(this,S2)}set Image(t){Re(this,S2,t),globalThis.Image=t}get ImageData(){return Y0(this,j2)}set ImageData(t){Re(this,j2,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(W0.engine().registryFactory);try{this.tensorflow={version:W0.backend().binding?W0.backend().binding.TF_Version:void 0,gpu:W0.backend().binding?W0.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W0.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W0.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=Ae(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=W0.getKernelsForBackend(W0.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};z2=new WeakMap,S2=new WeakMap,j2=new WeakMap;var R=new E2;var K2=class{constructor(){w(this,"config");w(this,"element");w(this,"stream");w(this,"devices",[]);w(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});w(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let A=document.getElementById(t.element);if(A&&A instanceof HTMLVideoElement)this.element=A;else return this.config.debug&&h("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&h("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(n.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&h("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&h("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&h("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(A){return h("webcam",A),`webcam error: ${A}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(A=>{this.element?this.element.onloadeddata=()=>A(!0):A(!1)}),await this.element.play(),this.config.debug&&h("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&h("webcam error","no stream"),"webcam error no stream")});w(this,"pause",()=>{this.element&&this.element.pause()});w(this,"play",async()=>{this.element&&await this.element.play()});w(this,"stop",()=>{this.config.debug&&h("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var f2=G(H());var e5={};ze(e5,{"affectnet-mobilenet":()=>br,age:()=>gr,"anti-spoofing":()=>_r,antispoof:()=>ar,blazeface:()=>ir,"blazeface-back":()=>Tr,"blazeface-front":()=>vr,"blazepose-detector":()=>Rr,"blazepose-full":()=>Mr,"blazepose-heavy":()=>Pr,"blazepose-lite":()=>kr,centernet:()=>lr,default:()=>ds,efficientpose:()=>wr,"efficientpose-i-lite":()=>$r,"efficientpose-ii-lite":()=>es,"efficientpose-iv":()=>ts,emotion:()=>cr,faceboxes:()=>Er,facemesh:()=>dr,"facemesh-attention":()=>Sr,"facemesh-attention-pinto":()=>zr,"facemesh-detection-full":()=>jr,"facemesh-detection-short":()=>Ir,faceres:()=>xr,"faceres-deep":()=>Nr,gear:()=>Cr,"gear-e1":()=>Lr,"gear-e2":()=>Or,gender:()=>Dr,"gender-ssrnet-imdb":()=>Wr,handdetect:()=>Fr,"handlandmark-full":()=>Br,"handlandmark-lite":()=>yr,"handlandmark-sparse":()=>Hr,handskeleton:()=>Gr,handtrack:()=>fr,"insightface-efficientnet-b0":()=>ns,"insightface-ghostnet-strides1":()=>os,"insightface-ghostnet-strides2":()=>rs,"insightface-mobilenet-emore":()=>ss,"insightface-mobilenet-swish":()=>As,iris:()=>mr,liveness:()=>pr,meet:()=>Vr,mobileface:()=>Zr,mobilefacenet:()=>Xr,models:()=>ur,"movenet-lightning":()=>hr,"movenet-multipose":()=>qr,"movenet-thunder":()=>Ur,nanodet:()=>Yr,"nanodet-e":()=>as,"nanodet-g":()=>is,"nanodet-m":()=>ls,"nanodet-t":()=>cs,posenet:()=>Kr,rvm:()=>Jr,selfie:()=>Qr});var ar=853098,ir=538928,lr=4030290,cr=820516,dr=1477958,xr=6978814,yr=2023432,fr=2964837,mr=2599092,pr=592976,ur=0,hr=4650216,br=6920630,gr=161240,Tr=538928,vr=402048,Rr=5928856,Mr=6339202,Pr=27502466,kr=2726402,wr=5651240,Er=2013002,zr=2387598,Sr=2382414,jr=1026192,Ir=201268,Nr=13957620,Lr=112438,Or=112438,Cr=1498916,Wr=161236,Dr=201808,Fr=3515612,Br=5431368,Hr=5286322,Gr=5502280,Vr=372228,Zr=2183192,Xr=5171976,qr=9448838,Ur=12477112,Yr=7574558,Kr=5032780,Jr=3739355,Qr=212886,_r=853098,$r=2269064,es=5651240,ts=25643252,ns=13013224,os=8093408,rs=8049584,ss=6938536,As=12168584,as=12319156,is=7574558,ls=1887474,cs=5294216,ds={antispoof:ar,blazeface:ir,centernet:lr,emotion:cr,facemesh:dr,faceres:xr,"handlandmark-lite":yr,handtrack:fr,iris:mr,liveness:pr,models:ur,"movenet-lightning":hr,"affectnet-mobilenet":br,age:gr,"blazeface-back":Tr,"blazeface-front":vr,"blazepose-detector":Rr,"blazepose-full":Mr,"blazepose-heavy":Pr,"blazepose-lite":kr,efficientpose:wr,faceboxes:Er,"facemesh-attention-pinto":zr,"facemesh-attention":Sr,"facemesh-detection-full":jr,"facemesh-detection-short":Ir,"faceres-deep":Nr,"gear-e1":Lr,"gear-e2":Or,gear:Cr,"gender-ssrnet-imdb":Wr,gender:Dr,handdetect:Fr,"handlandmark-full":Br,"handlandmark-sparse":Hr,handskeleton:Gr,meet:Vr,mobileface:Zr,mobilefacenet:Xr,"movenet-multipose":qr,"movenet-thunder":Ur,nanodet:Yr,posenet:Kr,rvm:Jr,selfie:Qr,"anti-spoofing":_r,"efficientpose-i-lite":$r,"efficientpose-ii-lite":es,"efficientpose-iv":ts,"insightface-efficientnet-b0":ns,"insightface-ghostnet-strides1":os,"insightface-ghostnet-strides2":rs,"insightface-mobilenet-emore":ss,"insightface-mobilenet-swish":As,"nanodet-e":as,"nanodet-g":is,"nanodet-m":ls,"nanodet-t":cs};var D0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},I0={};async function xs(e,t){return D0.debug&&h("load model fetch:",e,t),fetch(e,t)}function X1(e){D0.cacheModels=e.cacheModels,D0.verbose=e.debug,D0.modelBasePath=e.modelBasePath}async function L(e){var c,x,i,f;let t=O1(D0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),r="indexeddb://"+o;I0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:e5[o],inCache:!1,url:""},D0.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=D0.cacheSupported&&D0.cacheModels?await f2.io.listModels():{}}catch(d){D0.cacheSupported=!1}I0[o].inCache=D0.cacheSupported&&D0.cacheModels&&Object.keys(s).includes(r),I0[o].url=I0[o].inCache?r:t;let A=typeof fetch=="undefined"?{}:{fetchFunc:(d,m)=>xs(d,m)},a=new f2.GraphModel(I0[o].url,A),l=!1;try{a.findIOHandler(),D0.debug&&h("model load handler:",a.handler)}catch(d){h("error finding model i/o handler:",t,d)}try{let d=await((c=a.handler)==null?void 0:c.load())||null;I0[o].sizeFromManifest=((x=d==null?void 0:d.weightData)==null?void 0:x.byteLength)||0,d?a.loadSync(d):a=await f2.loadGraphModel(I0[o].inCache?r:t,A),I0[o].sizeLoadedWeights=((f=(i=a.artifacts)==null?void 0:i.weightData)==null?void 0:f.byteLength)||0,D0.verbose&&h("load:",{model:o,url:a.modelUrl,bytes:I0[o].sizeLoadedWeights}),l=!0}catch(d){h("error loading model:",t,d)}if(l&&D0.cacheModels&&D0.cacheSupported&&!I0[o].inCache)try{let d=await a.save(r);D0.debug&&h("model saved:",r,d)}catch(d){h("error saving model:",t,d)}return a}var t5="3.1.1";var S=G(H());var u0=G(H());var o0={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ms(){let e=o0.gl;e&&(o0.extensions=e.getSupportedExtensions())}function q1(e){var t;if(e.config.backend==="humangl"&&(o0.name in u0.engine().registry&&!((t=o0==null?void 0:o0.gl)!=null&&t.getParameter(o0.gl.VERSION))&&(h("humangl error: backend invalid context"),e.models.reset()),!u0.findBackend(o0.name))){try{o0.canvas=Ae(100,100)}catch(r){h("humangl error: cannot create canvas:",r);return}try{if(o0.gl=o0.canvas.getContext("webgl2",o0.webGLattr),!o0.gl){h("humangl error: cannot get webgl context");return}if(!o0.gl.getParameter(o0.gl.VERSION).includes("2.0")){h("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}o0.canvas&&(o0.canvas.addEventListener("webglcontextlost",s=>{throw h("humangl error:",s.type),h("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),o0.canvas.addEventListener("webglcontextrestored",s=>{h("humangl error: context restored:",s)}),o0.canvas.addEventListener("webglcontextcreationerror",s=>{h("humangl error: context create:",s)}))}catch(r){h("humangl error: cannot get webgl context:",r);return}try{u0.setWebGLContext(2,o0.gl)}catch(r){h("humangl error: cannot set webgl context:",r);return}try{let r=new u0.GPGPUContext(o0.gl);u0.registerBackend(o0.name,()=>new u0.MathBackendWebGL(r),o0.priority)}catch(r){h("humangl error: cannot register webgl backend:",r);return}try{u0.getKernelsForBackend("webgl").forEach(s=>{let A={...s,backendName:o0.name};u0.registerKernel(A)})}catch(r){h("humangl error: cannot update webgl backend registration:",r);return}try{u0.env().flagRegistry.WEBGL_VERSION&&u0.env().set("WEBGL_VERSION",2)}catch(r){h("humangl error: cannot set WebGL backend flags:",r);return}ms();let n=u0.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&h("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):h("humangl error: no current gl context:",o,o0.gl)}}var Se=G(H()),C={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function U1(){C.tf255=Se.scalar(255,"float32"),C.tf1=Se.scalar(1,"float32"),C.tf2=Se.scalar(2,"float32"),C.tf05=Se.scalar(.5,"float32"),C.tf127=Se.scalar(127.5,"float32"),C.rgb=Se.tensor1d([.2989,.587,.114],"float32")}async function hs(){var e;return await R.updateBackend(),(e=R.tensorflow)!=null&&e.version?"tensorflow":R.webgpu.supported&&R.webgpu.backend?"webgpu":R.webgl.supported&&R.webgl.backend?"webgl":R.wasm.supported&&R.wasm.backend?"wasm":"cpu"}function bs(e){let t=[];if(!R.kernels.includes("mod")){let n={kernelName:"Mod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.sub(o.inputs.a,S.mul(S.div(o.inputs.a,o.inputs.b),o.inputs.b)))};S.registerKernel(n),R.kernels.push("mod"),t.push("mod")}if(!R.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.add(S.mul(S.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),S.mod(o.inputs.a,o.inputs.b)))};S.registerKernel(n),R.kernels.push("floormod"),t.push("floormod")}if(!R.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>{let r=S.getBackend();S.setBackend("cpu");let s=S.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return S.setBackend(r),s})};S.registerKernel(n),R.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&h("registered kernels:",t)}var Y1={};async function I2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await hs()),t||R.initial||e.config.backend&&e.config.backend.length>0&&S.getBackend()!==e.config.backend){let r=v();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&h("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&h("running inside electron");let s=Object.keys(S.engine().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(q1(e),s=Object.keys(S.engine().registryFactory)),e.config.debug&&h("available backends:",s),R.browser&&!R.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&h("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),R.node&&!R.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&h(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),R.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")h("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let A=await navigator.gpu.requestAdapter();if(e.config.debug&&h("enumerated webgpu adapter:",A),!A)h("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let a="requestAdapterInfo"in A?await A.requestAdapterInfo():void 0;h("webgpu adapter info:",a)}}if(s.includes(e.config.backend)||(h(`error: backend ${e.config.backend} not found in registry`),e.config.backend=R.node?"tensorflow":"webgl",e.config.debug&&h(`override: setting backend ${e.config.backend}`)),e.config.debug&&h("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(S.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&S.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&h("wasm path:",e.config.wasmPath),typeof S.setWasmPaths!="undefined")S.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let A=!1,a=!1;try{A=await S.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),a=await S.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&h(`wasm execution: ${a?"simd":"no simd"} ${A?"multithreaded":"singlethreaded"}`),e.config.debug&&!a&&h("warning: wasm simd support is not enabled")}catch(l){h("wasm detection failed")}}try{await S.setBackend(e.config.backend),await S.ready()}catch(A){return h("error: cannot set backend:",e.config.backend,A),!1}e.config.debug&&(Y1=JSON.parse(JSON.stringify(S.env().flags)))}if((S.getBackend()==="humangl"||S.getBackend()==="webgl")&&(S.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&S.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),S.env().flagRegistry.WEBGL_EXP_CONV&&S.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(h("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),S.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),S.getBackend(),e.config.debug){let s=S.env().flags,A={};for(let a of Object.keys(s))Y1[a]!==s[a]&&(A[a]=s[a]);e.config.debug&&Object.keys(A).length>0&&h("backend:",S.getBackend(),"flags:",A)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&h("flags:",e.config.flags);for(let[s,A]of Object.entries(e.config.flags))S.env().set(s,A)}S.enableProdMode(),U1(),e.performance.initBackend=Math.trunc(v()-r),e.config.backend=S.getBackend(),await R.updateBackend(),bs(e.config)}return!0}function J2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&h("kernelFunc",n,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};S.registerKernel(o)}R.kernels=S.getKernelsForBackend(S.getBackend()).map(n=>n.kernelName.toLowerCase())}var nt={};ze(nt,{all:()=>Js,body:()=>_2,canvas:()=>Ks,face:()=>Q2,gesture:()=>tt,hand:()=>$2,init:()=>i5,object:()=>et,options:()=>f0,person:()=>Ys});var oe=e=>{if(!e)h("draw error: invalid canvas");else if(!e.getContext)h("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)h("draw error: cannot get canvas context");else return t}return null},Je=e=>Math.round(e*180/Math.PI),Y=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Qe=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function re(e,t,n,o,r){let s=t.replace(/\[.*\]/g,"").split(` +`;var Qt=(e,t,n)=>{let o=new RegExp("\\b"+t+" \\w+ (\\w+)","ig");e.replace(o,(r,s)=>(n[s]=0,r))},_t=class{constructor(t,n,o){w(this,"uniform",{});w(this,"attribute",{});w(this,"gl");w(this,"id");w(this,"compile",(t,n)=>{let o=this.gl.createShader(n);return o?(this.gl.shaderSource(o,t),this.gl.compileShader(o),this.gl.getShaderParameter(o,this.gl.COMPILE_STATUS)?o:(h(`filter: gl compile failed: ${this.gl.getShaderInfoLog(o)||"unknown"}`),null)):(h("filter: could not create shader"),null)});this.gl=t;let r=this.compile(n,this.gl.VERTEX_SHADER),s=this.compile(o,this.gl.FRAGMENT_SHADER);if(this.id=this.gl.createProgram(),!(!r||!s)){if(!this.id){h("filter: could not create webgl program");return}if(this.gl.attachShader(this.id,r),this.gl.attachShader(this.id,s),this.gl.linkProgram(this.id),!this.gl.getProgramParameter(this.id,this.gl.LINK_STATUS)){h(`filter: gl link failed: ${this.gl.getProgramInfoLog(this.id)||"unknown"}`);return}this.gl.useProgram(this.id),Qt(n,"attribute",this.attribute);for(let A in this.attribute)this.attribute[A]=this.gl.getAttribLocation(this.id,A);Qt(n,"uniform",this.uniform),Qt(o,"uniform",this.uniform);for(let A in this.uniform)this.uniform[A]=this.gl.getUniformLocation(this.id,A)}}};function G1(){let e=0,t=null,n=!1,o=-1,r=[null,null],s=[],A=null,a=null,l=Ae(100,100),c={},x={INTERMEDIATE:1},i=l.getContext("webgl");if(!i){h("filter: cannot get webgl context");return}this.gl=i;function f(g,p){if(!(g===l.width&&p===l.height)){if(l.width=g,l.height=p,!A){let b=new Float32Array([-1,-1,0,1,1,-1,1,1,-1,1,0,0,-1,1,0,0,1,-1,1,1,1,1,1,0]);A=i.createBuffer(),i.bindBuffer(i.ARRAY_BUFFER,A),i.bufferData(i.ARRAY_BUFFER,b,i.STATIC_DRAW),i.pixelStorei(i.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0)}i.viewport(0,0,l.width,l.height),r=[null,null]}}function d(g,p){let b=i.createFramebuffer();i.bindFramebuffer(i.FRAMEBUFFER,b);let k=i.createRenderbuffer();i.bindRenderbuffer(i.RENDERBUFFER,k);let P=i.createTexture();return i.bindTexture(i.TEXTURE_2D,P),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,g,p,0,i.RGBA,i.UNSIGNED_BYTE,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.framebufferTexture2D(i.FRAMEBUFFER,i.COLOR_ATTACHMENT0,i.TEXTURE_2D,P,0),i.bindTexture(i.TEXTURE_2D,null),i.bindFramebuffer(i.FRAMEBUFFER,null),{fbo:b,texture:P}}function m(g){return r[g]=r[g]||d(l.width,l.height),r[g]}function y(g=0){if(!a)return;let p=null,b=null,k=!1;e===0?p=t:p=m(o).texture||null,e++,n&&!(g&x.INTERMEDIATE)?(b=null,k=e%2===0):(o=(o+1)%2,b=m(o).fbo||null),i.bindTexture(i.TEXTURE_2D,p),i.bindFramebuffer(i.FRAMEBUFFER,b),i.uniform1f(a.uniform.flipY,k?-1:1),i.drawArrays(i.TRIANGLES,0,6)}function u(g){if(c[g])return a=c[g],i.useProgram((a?a.id:null)||null),a;if(a=new _t(i,C1,g),!a)return h("filter: could not get webgl program"),null;let p=Float32Array.BYTES_PER_ELEMENT,b=4*p;return i.enableVertexAttribArray(a.attribute.pos),i.vertexAttribPointer(a.attribute.pos,2,i.FLOAT,!1,b,0*p),i.enableVertexAttribArray(a.attribute.uv),i.vertexAttribPointer(a.attribute.uv,2,i.FLOAT,!1,b,2*p),c[g]=a,a}let T={colorMatrix:g=>{let p=new Float32Array(g);p[4]/=255,p[9]/=255,p[14]/=255,p[19]/=255;let b=p[18]===1&&p[3]===0&&p[8]===0&&p[13]===0&&p[15]===0&&p[16]===0&&p[17]===0&&p[19]===0?D1:W1,k=u(b);k&&(i.uniform1fv(k.uniform.m,p),y())},brightness:g=>{let p=(g||0)+1;T.colorMatrix([p,0,0,0,0,0,p,0,0,0,0,0,p,0,0,0,0,0,1,0])},saturation:g=>{let p=(g||0)*2/3+1,b=(p-1)*-.5;T.colorMatrix([p,b,b,0,0,b,p,b,0,0,b,b,p,0,0,0,0,0,1,0])},desaturate:()=>{T.saturation(-1)},contrast:g=>{let p=(g||0)+1,b=-128*(p-1);T.colorMatrix([p,0,0,0,b,0,p,0,0,b,0,0,p,0,b,0,0,0,1,0])},negative:()=>{T.contrast(-2)},hue:g=>{g=(g||0)/180*Math.PI;let p=Math.cos(g),b=Math.sin(g),k=.213,P=.715,N=.072;T.colorMatrix([k+p*(1-k)+b*-k,P+p*-P+b*-P,N+p*-N+b*(1-N),0,0,k+p*-k+b*.143,P+p*(1-P)+b*.14,N+p*-N+b*-.283,0,0,k+p*-k+b*-(1-k),P+p*-P+b*P,N+p*(1-N)+b*N,0,0,0,0,0,1,0])},desaturateLuminance:()=>{T.colorMatrix([.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,.2764723,.929708,.0938197,0,-37.1,0,0,0,1,0])},sepia:()=>{T.colorMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0])},brownie:()=>{T.colorMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0])},vintagePinhole:()=>{T.colorMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0])},kodachrome:()=>{T.colorMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0])},technicolor:()=>{T.colorMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0])},polaroid:()=>{T.colorMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0])},shiftToBGR:()=>{T.colorMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0])},convolution:g=>{let p=new Float32Array(g),b=1/l.width,k=1/l.height,P=u(H1);P&&(i.uniform1fv(P.uniform.m,p),i.uniform2f(P.uniform.px,b,k),y())},detectEdges:()=>{T.convolution.call(this,[0,1,0,1,-4,1,0,1,0])},sobelX:()=>{T.convolution.call(this,[-1,0,1,-2,0,2,-1,0,1])},sobelY:()=>{T.convolution.call(this,[-1,-2,-1,0,0,0,1,2,1])},sharpen:g=>{let p=g||1;T.convolution.call(this,[0,-1*p,0,-1*p,1+4*p,-1*p,0,-1*p,0])},emboss:g=>{let p=g||1;T.convolution.call(this,[-2*p,-1*p,0,-1*p,1,1*p,0,1*p,2*p])},blur:g=>{let p=g/7/l.width,b=g/7/l.height,k=u(B1);k&&(i.uniform2f(k.uniform.px,0,b),y(x.INTERMEDIATE),i.uniform2f(k.uniform.px,p,0),y())},pixelate:g=>{let p=g/l.width,b=g/l.height,k=u(F1);k&&(i.uniform2f(k.uniform.size,p,b),y())}};this.add=function(g){let p=Array.prototype.slice.call(arguments,1),b=T[g];s.push({func:b,args:p})},this.reset=function(){s=[]},this.get=function(){return s},this.apply=function(g){f(g.width,g.height),e=0,t||(t=i.createTexture()),i.bindTexture(i.TEXTURE_2D,t),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.NEAREST),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.NEAREST),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,i.RGBA,i.UNSIGNED_BYTE,g);for(let p=0;px.data())),A=Math.max(s[0][0],s[1][0],s[2][0]),l=(A>1?255:1)/A,c;if(l>1){let x=[U.sub(n[0],o[0]),U.sub(n[1],o[1]),U.sub(n[2],o[2])],i=[U.sub(r[0],o[0]),U.sub(r[1],o[1]),U.sub(r[2],o[2])],f=[U.mul(x[0],l),U.mul(x[1],l),U.mul(x[2],l)],d=U.stack([f[0],f[1],f[2]],2);c=U.reshape(d,[1,t.shape[0]||0,t.shape[1]||0,3]),U.dispose([...x,...i,...f,d])}else c=U.expandDims(t,0);return U.dispose([...n,...o,...r,n,t,e]),c}var X2=3840,R0=null,M0=null,y2=null,e0,ne={inputSum:0,cacheDiff:1,sumMethod:0,inputTensor:void 0};function $t(){ne.inputSum=0,ne.cacheDiff=1,ne.sumMethod=0,ne.inputTensor=void 0}function Ae(e,t){let n;if(R.browser)if(R.worker){if(typeof OffscreenCanvas=="undefined")throw new Error("canvas error: attempted to run in web worker but OffscreenCanvas is not supported");n=new OffscreenCanvas(e,t)}else if(typeof document!="undefined")n=document.createElement("canvas"),n.width=e,n.height=t;else if(typeof navigator!="undefined"&&navigator.product==="ReactNative")if(typeof R.Canvas!="undefined")n=new R.Canvas(e,t);else if(typeof globalThis.Canvas!="undefined")n=new globalThis.Canvas(e,t);else throw new Error("canvas error: attempted to use canvas in react-native without canvas support installed");else throw new Error("canvas error: attempted to run in browser but DOM is not defined");else typeof R.Canvas!="undefined"?n=new R.Canvas(e,t):typeof globalThis.Canvas!="undefined"&&(n=new globalThis.Canvas(e,t));return n}function q2(e,t){let n=t||Ae(e.width,e.height);return n.getContext("2d").drawImage(e,0,0),n}async function U2(e,t,n=!0){var f,d,m;if(!e)return t.debug&&h("input error: input is missing"),{tensor:null,canvas:null};if(!(e instanceof I.Tensor)&&!(typeof Image!="undefined"&&e instanceof Image)&&!(typeof globalThis.Canvas!="undefined"&&e instanceof globalThis.Canvas)&&!(typeof ImageData!="undefined"&&e instanceof ImageData)&&!(typeof ImageBitmap!="undefined"&&e instanceof ImageBitmap)&&!(typeof HTMLImageElement!="undefined"&&e instanceof HTMLImageElement)&&!(typeof HTMLMediaElement!="undefined"&&e instanceof HTMLMediaElement)&&!(typeof HTMLVideoElement!="undefined"&&e instanceof HTMLVideoElement)&&!(typeof HTMLCanvasElement!="undefined"&&e instanceof HTMLCanvasElement)&&!(typeof OffscreenCanvas!="undefined"&&e instanceof OffscreenCanvas))throw new Error("input error: type not recognized");if(e instanceof I.Tensor){let y=null;if(e.isDisposedInternal)throw new Error("input error: attempted to use tensor but it is disposed");if(!e.shape)throw new Error("input error: attempted to use tensor without a shape");if(e.shape.length===3){if(e.shape[2]===3)y=I.expandDims(e,0);else if(e.shape[2]===4){let u=I.slice3d(e,[0,0,0],[-1,-1,3]);y=I.expandDims(u,0),I.dispose(u)}}else e.shape.length===4&&(e.shape[3]===3?y=I.clone(e):e.shape[3]===4&&(y=I.slice4d(e,[0,0,0,0],[-1,-1,-1,3])));if(y==null||y.shape.length!==4||y.shape[0]!==1||y.shape[3]!==3)throw new Error(`input error: attempted to use tensor with unrecognized shape: ${e.shape.toString()}`);if(y.dtype==="int32"){let u=I.cast(y,"float32");I.dispose(y),y=u}return{tensor:y,canvas:t.filter.return?M0:null}}if(typeof e.readyState!="undefined"&&e.readyState<=2)return t.debug&&h("input stream is not ready"),{tensor:null,canvas:R0};let o=e.naturalWidth||e.videoWidth||e.width||e.shape&&e.shape[1]>0,r=e.naturalHeight||e.videoHeight||e.height||e.shape&&e.shape[2]>0;if(!o||!r)return t.debug&&h("cannot determine input dimensions"),{tensor:null,canvas:R0};let s=o,A=r;if(s>X2&&(s=X2,A=Math.trunc(s*r/o)),A>X2&&(A=X2,s=Math.trunc(A*o/r)),(((f=t.filter)==null?void 0:f.width)||0)>0?s=t.filter.width:(((d=t.filter)==null?void 0:d.height)||0)>0&&(s=o*((t.filter.height||0)/r)),(t.filter.height||0)>0?A=t.filter.height:(t.filter.width||0)>0&&(A=r*((t.filter.width||0)/o)),!s||!A)throw new Error("input error: cannot determine dimension");(!R0||R0.width!==s||R0.height!==A)&&(R0=Ae(s,A));let a=R0.getContext("2d");if(typeof ImageData!="undefined"&&e instanceof ImageData?a.putImageData(e,0,0):t.filter.flip&&typeof a.translate!="undefined"?(a.translate(o,0),a.scale(-1,1),a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),a.setTransform(1,0,0,1,0,0)):a.drawImage(e,0,0,o,r,0,0,R0.width,R0.height),(!M0||R0.width!==M0.width||R0.height!==M0.height)&&(M0=Ae(R0.width,R0.height)),t.filter.enabled&&R.webgl.supported?(e0||(e0=R.browser?new G1:null),R.filter=!!e0,e0!=null&&e0.add?(e0.reset(),t.filter.brightness!==0&&e0.add("brightness",t.filter.brightness),t.filter.contrast!==0&&e0.add("contrast",t.filter.contrast),t.filter.sharpness!==0&&e0.add("sharpen",t.filter.sharpness),t.filter.blur!==0&&e0.add("blur",t.filter.blur),t.filter.saturation!==0&&e0.add("saturation",t.filter.saturation),t.filter.hue!==0&&e0.add("hue",t.filter.hue),t.filter.negative&&e0.add("negative"),t.filter.sepia&&e0.add("sepia"),t.filter.vintage&&e0.add("brownie"),t.filter.sepia&&e0.add("sepia"),t.filter.kodachrome&&e0.add("kodachrome"),t.filter.technicolor&&e0.add("technicolor"),t.filter.polaroid&&e0.add("polaroid"),t.filter.pixelate!==0&&e0.add("pixelate",t.filter.pixelate),((m=e0.get())==null?void 0:m.length)>1?M0=e0.apply(R0):M0=e0.draw(R0)):(t.debug&&h("input process error: cannot initialize filters"),R.webgl.supported=!1,t.filter.enabled=!1,q2(R0,M0))):(q2(R0,M0),e0&&(e0=null),R.filter=!!e0),!n)return{tensor:null,canvas:M0};if(!M0)throw new Error("canvas error: cannot create output");let l,c=3;if(typeof ImageData!="undefined"&&e instanceof ImageData||e.data&&e.width&&e.height)if(R.browser&&I.browser)l=I.browser?I.browser.fromPixels(e):null;else{c=e.data.length/e.height/e.width;let y=new Uint8Array(e.data.buffer);l=I.tensor(y,[e.height,e.width,c],"int32")}else if((!y2||M0.width!==y2.width||M0.height!==y2.height)&&(y2=Ae(M0.width,M0.height)),I.browser&&R.browser)t.backend==="webgl"||t.backend==="humangl"||t.backend==="webgpu"?l=I.browser.fromPixels(M0):(y2=q2(M0),l=I.browser.fromPixels(y2));else{let T=q2(M0).getContext("2d").getImageData(0,0,s,A);c=T.data.length/s/A;let g=new Uint8Array(T.data.buffer);l=I.tensor(g,[s,A,c])}if(c===4){let y=I.slice3d(l,[0,0,0],[-1,-1,3]);I.dispose(l),l=y}if(!l)throw new Error("input error: cannot create tensor");let x=I.cast(l,"float32"),i=t.filter.equalization?await Z2(x):I.expandDims(x,0);if(I.dispose([l,x]),t.filter.autoBrightness){let y=I.max(i),u=await y.data();t.filter.brightness=u[0]>1?1-u[0]/255:1-u[0],I.dispose(y)}return{tensor:i,canvas:t.filter.return?M0:null}}async function V1(e,t){let n=!1;if(e.cacheSensitivity===0||!t.shape||t.shape.length!==4||t.shape[1]>3840||t.shape[2]>2160)return n;if(!ne.inputTensor)ne.inputTensor=I.clone(t);else if(ne.inputTensor.shape[1]!==t.shape[1]||ne.inputTensor.shape[2]!==t.shape[2])I.dispose(ne.inputTensor),ne.inputTensor=I.clone(t);else{let o={};o.diff=I.sub(t,ne.inputTensor),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;I.dispose([ne.inputTensor,o.diff,o.squared,o.sum]),ne.inputTensor=I.clone(t),n=s<=(e.cacheSensitivity||0)}return n}async function Z1(e,t,n){let o={};if(!t||!n||t.shape.length!==4||t.shape.length!==n.shape.length)return e.debug||h("invalid input tensor or tensor shapes do not match:",t.shape,n.shape),0;if(t.shape[0]!==1||n.shape[0]!==1||t.shape[3]!==3||n.shape[3]!==3)return e.debug||h("input tensors must be of shape [1, height, width, 3]:",t.shape,n.shape),0;o.input1=I.clone(t),o.input2=t.shape[1]!==n.shape[1]||t.shape[2]!==n.shape[2]?I.image.resizeBilinear(n,[t.shape[1],t.shape[2]]):I.clone(n),o.diff=I.sub(o.input1,o.input2),o.squared=I.mul(o.diff,o.diff),o.sum=I.sum(o.squared);let s=(await o.sum.data())[0]/(t.shape[1]||1)/(t.shape[2]||1)/255/3;return I.dispose([o.input1,o.input2,o.diff,o.squared,o.sum]),s}var z2,S2,j2,E2=class{constructor(){w(this,"browser");w(this,"node");w(this,"worker");w(this,"platform","");w(this,"agent","");w(this,"backends",[]);w(this,"initial");w(this,"filter");w(this,"tfjs");w(this,"offscreen");w(this,"perfadd",!1);w(this,"tensorflow",{version:void 0,gpu:void 0});w(this,"wasm",{supported:void 0,backend:void 0,simd:void 0,multithread:void 0});w(this,"webgl",{supported:void 0,backend:void 0,version:void 0,renderer:void 0,shader:void 0,vendor:void 0});w(this,"webgpu",{supported:void 0,backend:void 0,adapter:void 0});w(this,"cpu",{model:void 0,flags:[]});w(this,"kernels",[]);ue(this,z2,void 0);ue(this,S2,void 0);ue(this,j2,void 0);if(this.browser=typeof navigator!="undefined",this.node=typeof process!="undefined"&&typeof process.versions!="undefined"&&typeof process.versions.node!="undefined",this.tfjs={version:W0.version["tfjs-core"]},this.offscreen=typeof OffscreenCanvas!="undefined",this.initial=!0,this.worker=this.browser&&this.offscreen?typeof WorkerGlobalScope!="undefined":void 0,typeof navigator!="undefined"&&typeof navigator.userAgent!="undefined"){let t=navigator.userAgent||"",n=t.match(/\(([^()]+)\)/g);if(n!=null&&n[0]){let o=n[0].match(/\(([^()]+)\)/g);this.platform=o!=null&&o[0]?o[0].replace(/\(|\)/g,""):"",this.agent=t.replace(n[0],""),this.platform[1]&&(this.agent=this.agent.replace(n[1],"")),this.agent=this.agent.replace(/ /g," ")}}else typeof process!="undefined"&&(this.platform=`${process.platform} ${process.arch}`,this.agent=`NodeJS ${process.version}`)}get Canvas(){return Y0(this,z2)}set Canvas(t){Re(this,z2,t),globalThis.Canvas=t}get Image(){return Y0(this,S2)}set Image(t){Re(this,S2,t),globalThis.Image=t}get ImageData(){return Y0(this,j2)}set ImageData(t){Re(this,j2,t),globalThis.ImageData=t}async updateBackend(){this.backends=Object.keys(W0.engine().registryFactory);try{this.tensorflow={version:W0.backend().binding?W0.backend().binding.TF_Version:void 0,gpu:W0.backend().binding?W0.backend().binding.isUsingGpuDevice():void 0}}catch(o){}this.wasm.supported=typeof WebAssembly!="undefined",this.wasm.backend=this.backends.includes("wasm"),this.wasm.supported&&this.wasm.backend&&(this.wasm.simd=await W0.env().getAsync("WASM_HAS_SIMD_SUPPORT"),this.wasm.multithread=await W0.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"));let t=Ae(100,100),n=t?t.getContext("webgl2"):void 0;this.webgl.supported=typeof n!="undefined",this.webgl.backend=this.backends.includes("webgl"),this.webgl.supported&&this.webgl.backend&&n&&(this.webgl.version=n.getParameter(n.VERSION),this.webgl.vendor=n.getParameter(n.VENDOR),this.webgl.renderer=n.getParameter(n.RENDERER),this.webgl.shader=n.getParameter(n.SHADING_LANGUAGE_VERSION)),this.webgpu.supported=this.browser&&typeof navigator!="undefined"&&typeof navigator.gpu!="undefined",this.webgpu.backend=this.backends.includes("webgpu");try{if(this.webgpu.supported){let o=await navigator.gpu.requestAdapter();this.webgpu.adapter=await(o==null?void 0:o.requestAdapterInfo())}}catch(o){this.webgpu.supported=!1}try{this.kernels=W0.getKernelsForBackend(W0.getBackend()).map(o=>o.kernelName.toLowerCase())}catch(o){}}updateCPU(){let t={model:"",flags:[]};this.node&&this.platform.startsWith("linux"),this.cpu?this.cpu=t:Object.defineProperty(this,"cpu",{value:t})}};z2=new WeakMap,S2=new WeakMap,j2=new WeakMap;var R=new E2;var K2=class{constructor(){w(this,"config");w(this,"element");w(this,"stream");w(this,"devices",[]);w(this,"enumerate",async()=>{try{let t=await navigator.mediaDevices.enumerateDevices();this.devices=t.filter(n=>n.kind==="videoinput")}catch(t){this.devices=[]}return this.devices});w(this,"start",async t=>{var r,s;if(t!=null&&t.debug&&(this.config.debug=t==null?void 0:t.debug),t!=null&&t.crop&&(this.config.crop=t==null?void 0:t.crop),t!=null&&t.mode&&(this.config.mode=t==null?void 0:t.mode),t!=null&&t.width&&(this.config.width=t==null?void 0:t.width),t!=null&&t.height&&(this.config.height=t==null?void 0:t.height),t!=null&&t.id&&(this.config.id=t==null?void 0:t.id),t!=null&&t.element)if(typeof t.element=="string"){let A=document.getElementById(t.element);if(A&&A instanceof HTMLVideoElement)this.element=A;else return this.config.debug&&h("webcam","cannot get dom element",t.element),`webcam error: cannot get dom element: ${t.element}`}else if(t.element instanceof HTMLVideoElement)this.element=t.element;else return this.config.debug&&h("webcam","unknown dom element",t.element),`webcam error: unknown dom element: ${t.element}`;else this.element=document.createElement("video");let n={audio:!1,video:{facingMode:this.config.mode==="front"?"user":"environment",resizeMode:this.config.crop?"crop-and-scale":"none"}};if(((r=this.config)==null?void 0:r.width)>0&&(n.video.width={ideal:this.config.width}),((s=this.config)==null?void 0:s.height)>0&&(n.video.height={ideal:this.config.height}),this.config.id&&(n.video.deviceId=this.config.id),this.element.addEventListener("play",()=>{this.config.debug&&h("webcam","play")}),this.element.addEventListener("pause",()=>{this.config.debug&&h("webcam","pause")}),this.element.addEventListener("click",async()=>{!this.element||!this.stream||(this.element.paused?await this.element.play():this.element.pause())}),!(navigator!=null&&navigator.mediaDevices))return this.config.debug&&h("webcam error","no devices"),"webcam error: no devices";try{this.stream=await navigator.mediaDevices.getUserMedia(n)}catch(A){return h("webcam",A),`webcam error: ${A}`}return this.stream?(this.element.srcObject=this.stream,await new Promise(A=>{this.element?this.element.onloadeddata=()=>A(!0):A(!1)}),await this.element.play(),this.config.debug&&h("webcam",{width:this.width,height:this.height,label:this.label,stream:this.stream,track:this.track,settings:this.settings,constraints:this.constraints,capabilities:this.capabilities}),`webcam: ${this.label}`):(this.config.debug&&h("webcam error","no stream"),"webcam error no stream")});w(this,"pause",()=>{this.element&&this.element.pause()});w(this,"play",async()=>{this.element&&await this.element.play()});w(this,"stop",()=>{this.config.debug&&h("webcam","stop"),this.track&&this.track.stop()});this.config={element:void 0,debug:!0,mode:"front",crop:!1,width:0,height:0}}get track(){if(this.stream)return this.stream.getVideoTracks()[0]}get capabilities(){if(this.track)return this.track.getCapabilities?this.track.getCapabilities():void 0}get constraints(){if(this.track)return this.track.getConstraints?this.track.getConstraints():void 0}get settings(){if(!this.stream)return;let t=this.stream.getVideoTracks()[0];return t.getSettings?t.getSettings():void 0}get label(){return this.track?this.track.label:""}get paused(){var t;return((t=this.element)==null?void 0:t.paused)||!1}get width(){var t;return((t=this.element)==null?void 0:t.videoWidth)||0}get height(){var t;return((t=this.element)==null?void 0:t.videoHeight)||0}};var f2=G(H());var e5={};ze(e5,{"affectnet-mobilenet":()=>br,age:()=>gr,"anti-spoofing":()=>_r,antispoof:()=>ar,blazeface:()=>ir,"blazeface-back":()=>Tr,"blazeface-front":()=>vr,"blazepose-detector":()=>Rr,"blazepose-full":()=>Mr,"blazepose-heavy":()=>Pr,"blazepose-lite":()=>kr,centernet:()=>lr,default:()=>ds,efficientpose:()=>wr,"efficientpose-i-lite":()=>$r,"efficientpose-ii-lite":()=>es,"efficientpose-iv":()=>ts,emotion:()=>cr,faceboxes:()=>Er,facemesh:()=>dr,"facemesh-attention":()=>Sr,"facemesh-attention-pinto":()=>zr,"facemesh-detection-full":()=>jr,"facemesh-detection-short":()=>Ir,faceres:()=>xr,"faceres-deep":()=>Nr,gear:()=>Cr,"gear-e1":()=>Lr,"gear-e2":()=>Or,gender:()=>Dr,"gender-ssrnet-imdb":()=>Wr,handdetect:()=>Fr,"handlandmark-full":()=>Br,"handlandmark-lite":()=>yr,"handlandmark-sparse":()=>Hr,handskeleton:()=>Gr,handtrack:()=>fr,"insightface-efficientnet-b0":()=>ns,"insightface-ghostnet-strides1":()=>os,"insightface-ghostnet-strides2":()=>rs,"insightface-mobilenet-emore":()=>ss,"insightface-mobilenet-swish":()=>As,iris:()=>mr,liveness:()=>pr,meet:()=>Vr,mobileface:()=>Zr,mobilefacenet:()=>Xr,models:()=>ur,"movenet-lightning":()=>hr,"movenet-multipose":()=>qr,"movenet-thunder":()=>Ur,nanodet:()=>Yr,"nanodet-e":()=>as,"nanodet-g":()=>is,"nanodet-m":()=>ls,"nanodet-t":()=>cs,posenet:()=>Kr,rvm:()=>Jr,selfie:()=>Qr});var ar=853098,ir=538928,lr=4030290,cr=820516,dr=1477958,xr=6978814,yr=2023432,fr=2964837,mr=2599092,pr=592976,ur=0,hr=4650216,br=6920630,gr=161240,Tr=538928,vr=402048,Rr=5928856,Mr=6339202,Pr=27502466,kr=2726402,wr=5651240,Er=2013002,zr=2387598,Sr=2382414,jr=1026192,Ir=201268,Nr=13957620,Lr=112438,Or=112438,Cr=1498916,Wr=161236,Dr=201808,Fr=3515612,Br=5431368,Hr=5286322,Gr=5502280,Vr=372228,Zr=2183192,Xr=5171976,qr=9448838,Ur=12477112,Yr=7574558,Kr=5032780,Jr=3739355,Qr=212886,_r=853098,$r=2269064,es=5651240,ts=25643252,ns=13013224,os=8093408,rs=8049584,ss=6938536,As=12168584,as=12319156,is=7574558,ls=1887474,cs=5294216,ds={antispoof:ar,blazeface:ir,centernet:lr,emotion:cr,facemesh:dr,faceres:xr,"handlandmark-lite":yr,handtrack:fr,iris:mr,liveness:pr,models:ur,"movenet-lightning":hr,"affectnet-mobilenet":br,age:gr,"blazeface-back":Tr,"blazeface-front":vr,"blazepose-detector":Rr,"blazepose-full":Mr,"blazepose-heavy":Pr,"blazepose-lite":kr,efficientpose:wr,faceboxes:Er,"facemesh-attention-pinto":zr,"facemesh-attention":Sr,"facemesh-detection-full":jr,"facemesh-detection-short":Ir,"faceres-deep":Nr,"gear-e1":Lr,"gear-e2":Or,gear:Cr,"gender-ssrnet-imdb":Wr,gender:Dr,handdetect:Fr,"handlandmark-full":Br,"handlandmark-sparse":Hr,handskeleton:Gr,meet:Vr,mobileface:Zr,mobilefacenet:Xr,"movenet-multipose":qr,"movenet-thunder":Ur,nanodet:Yr,posenet:Kr,rvm:Jr,selfie:Qr,"anti-spoofing":_r,"efficientpose-i-lite":$r,"efficientpose-ii-lite":es,"efficientpose-iv":ts,"insightface-efficientnet-b0":ns,"insightface-ghostnet-strides1":os,"insightface-ghostnet-strides2":rs,"insightface-mobilenet-emore":ss,"insightface-mobilenet-swish":As,"nanodet-e":as,"nanodet-g":is,"nanodet-m":ls,"nanodet-t":cs};var D0={cacheModels:!0,cacheSupported:!0,verbose:!0,debug:!1,modelBasePath:""},I0={};async function xs(e,t){return D0.debug&&h("load model fetch:",e,t),fetch(e,t)}function X1(e){D0.cacheModels=e.cacheModels,D0.verbose=e.debug,D0.modelBasePath=e.modelBasePath}async function L(e){var c,x,i,f;let t=O1(D0.modelBasePath,e||"");t.toLowerCase().endsWith(".json")||(t+=".json");let n=t.includes("/")?t.split("/"):t.split("\\"),o=n[n.length-1].replace(".json",""),r="indexeddb://"+o;I0[o]={name:o,sizeFromManifest:0,sizeLoadedWeights:0,sizeDesired:e5[o],inCache:!1,url:""},D0.cacheSupported=typeof indexedDB!="undefined";let s={};try{s=D0.cacheSupported&&D0.cacheModels?await f2.io.listModels():{}}catch(d){D0.cacheSupported=!1}I0[o].inCache=D0.cacheSupported&&D0.cacheModels&&Object.keys(s).includes(r),I0[o].url=I0[o].inCache?r:t;let A=typeof fetch=="undefined"?{}:{fetchFunc:(d,m)=>xs(d,m)},a=new f2.GraphModel(I0[o].url,A),l=!1;try{a.findIOHandler(),D0.debug&&h("model load handler:",a.handler)}catch(d){h("error finding model i/o handler:",t,d)}try{let d=await((c=a.handler)==null?void 0:c.load())||null;I0[o].sizeFromManifest=((x=d==null?void 0:d.weightData)==null?void 0:x.byteLength)||0,d?a.loadSync(d):a=await f2.loadGraphModel(I0[o].inCache?r:t,A),I0[o].sizeLoadedWeights=((f=(i=a.artifacts)==null?void 0:i.weightData)==null?void 0:f.byteLength)||0,D0.verbose&&h("load:",{model:o,url:a.modelUrl,bytes:I0[o].sizeLoadedWeights}),l=!0}catch(d){h("error loading model:",t,d)}if(l&&D0.cacheModels&&D0.cacheSupported&&!I0[o].inCache)try{let d=await a.save(r);D0.debug&&h("model saved:",r,d)}catch(d){h("error saving model:",t,d)}return a}var t5="3.1.2";var S=G(H());var u0=G(H());var o0={name:"humangl",priority:999,canvas:null,gl:null,extensions:[],webGLattr:{alpha:!1,antialias:!1,premultipliedAlpha:!1,preserveDrawingBuffer:!1,depth:!1,stencil:!1,failIfMajorPerformanceCaveat:!1,desynchronized:!0}};function ms(){let e=o0.gl;e&&(o0.extensions=e.getSupportedExtensions())}function q1(e){var t;if(e.config.backend==="humangl"&&(o0.name in u0.engine().registry&&!((t=o0==null?void 0:o0.gl)!=null&&t.getParameter(o0.gl.VERSION))&&(h("humangl error: backend invalid context"),e.models.reset()),!u0.findBackend(o0.name))){try{o0.canvas=Ae(100,100)}catch(r){h("humangl error: cannot create canvas:",r);return}try{if(o0.gl=o0.canvas.getContext("webgl2",o0.webGLattr),!o0.gl){h("humangl error: cannot get webgl context");return}if(!o0.gl.getParameter(o0.gl.VERSION).includes("2.0")){h("backend override: using fallback webgl backend as webgl 2.0 is not detected"),e.config.backend="webgl";return}o0.canvas&&(o0.canvas.addEventListener("webglcontextlost",s=>{throw h("humangl error:",s.type),h("possible browser memory leak using webgl or conflict with multiple backend registrations"),e.emit("error"),new Error("backend error: webgl context lost")}),o0.canvas.addEventListener("webglcontextrestored",s=>{h("humangl error: context restored:",s)}),o0.canvas.addEventListener("webglcontextcreationerror",s=>{h("humangl error: context create:",s)}))}catch(r){h("humangl error: cannot get webgl context:",r);return}try{u0.setWebGLContext(2,o0.gl)}catch(r){h("humangl error: cannot set webgl context:",r);return}try{let r=new u0.GPGPUContext(o0.gl);u0.registerBackend(o0.name,()=>new u0.MathBackendWebGL(r),o0.priority)}catch(r){h("humangl error: cannot register webgl backend:",r);return}try{u0.getKernelsForBackend("webgl").forEach(s=>{let A={...s,backendName:o0.name};u0.registerKernel(A)})}catch(r){h("humangl error: cannot update webgl backend registration:",r);return}try{u0.env().flagRegistry.WEBGL_VERSION&&u0.env().set("WEBGL_VERSION",2)}catch(r){h("humangl error: cannot set WebGL backend flags:",r);return}ms();let n=u0.backend(),o=typeof n.gpgpu!="undefined"?n.getGPGPUContext().gl:null;o?e.config.debug&&h("humangl backend registered:",{webgl:o.getParameter(o.VERSION),renderer:o.getParameter(o.RENDERER)}):h("humangl error: no current gl context:",o,o0.gl)}}var Se=G(H()),C={tf255:255,tf1:1,tf2:2,tf05:.5,tf127:127.5,rgb:[.2989,.587,.114]};function U1(){C.tf255=Se.scalar(255,"float32"),C.tf1=Se.scalar(1,"float32"),C.tf2=Se.scalar(2,"float32"),C.tf05=Se.scalar(.5,"float32"),C.tf127=Se.scalar(127.5,"float32"),C.rgb=Se.tensor1d([.2989,.587,.114],"float32")}async function hs(){var e;return await R.updateBackend(),(e=R.tensorflow)!=null&&e.version?"tensorflow":R.webgpu.supported&&R.webgpu.backend?"webgpu":R.webgl.supported&&R.webgl.backend?"webgl":R.wasm.supported&&R.wasm.backend?"wasm":"cpu"}function bs(e){let t=[];if(!R.kernels.includes("mod")){let n={kernelName:"Mod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.sub(o.inputs.a,S.mul(S.div(o.inputs.a,o.inputs.b),o.inputs.b)))};S.registerKernel(n),R.kernels.push("mod"),t.push("mod")}if(!R.kernels.includes("floormod")){let n={kernelName:"FloorMod",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>S.add(S.mul(S.floorDiv(o.inputs.a,o.inputs.b),o.inputs.b),S.mod(o.inputs.a,o.inputs.b)))};S.registerKernel(n),R.kernels.push("floormod"),t.push("floormod")}if(!R.kernels.includes("rotatewithoffset")&&e.softwareKernels){let n={kernelName:"RotateWithOffset",backendName:S.getBackend(),kernelFunc:o=>S.tidy(()=>{let r=S.getBackend();S.setBackend("cpu");let s=S.image.rotateWithOffset(o.inputs.image,o.attrs.radians,o.attrs.fillValue,o.attrs.center);return S.setBackend(r),s})};S.registerKernel(n),R.kernels.push("rotatewithoffset"),t.push("rotatewithoffset")}t.length>0&&e.debug&&h("registered kernels:",t)}var Y1={};async function I2(e,t=!1){var n,o;if(e.state="backend",((n=e.config.backend)==null?void 0:n.length)===0&&(e.config.backend=await hs()),t||R.initial||e.config.backend&&e.config.backend.length>0&&S.getBackend()!==e.config.backend){let r=v();if(e.config.backend&&e.config.backend.length>0){typeof window=="undefined"&&typeof WorkerGlobalScope!="undefined"&&e.config.debug&&e.config.debug&&h("running inside web worker"),typeof navigator!="undefined"&&((o=navigator==null?void 0:navigator.userAgent)!=null&&o.toLowerCase().includes("electron"))&&e.config.debug&&h("running inside electron");let s=Object.keys(S.engine().registryFactory);if(e.config.backend==="humangl"&&!s.includes("humangl")&&(q1(e),s=Object.keys(S.engine().registryFactory)),e.config.debug&&h("available backends:",s),R.browser&&!R.node&&e.config.backend==="tensorflow"&&s.includes("webgl")&&(e.config.debug&&h("override: backend set to tensorflow while running in browser"),e.config.backend="webgl"),R.node&&!R.browser&&(e.config.backend==="webgl"||e.config.backend==="humangl")&&s.includes("tensorflow")&&(e.config.debug&&h(`override: backend set to ${e.config.backend} while running in nodejs`),e.config.backend="tensorflow"),R.browser&&e.config.backend==="webgpu")if(typeof navigator=="undefined"||typeof navigator.gpu=="undefined")h("override: backend set to webgpu but browser does not support webgpu"),e.config.backend="webgl";else{let A=await navigator.gpu.requestAdapter();if(e.config.debug&&h("enumerated webgpu adapter:",A),!A)h("override: backend set to webgpu but browser reports no available gpu"),e.config.backend="webgl";else{let a="requestAdapterInfo"in A?await A.requestAdapterInfo():void 0;h("webgpu adapter info:",a)}}if(s.includes(e.config.backend)||(h(`error: backend ${e.config.backend} not found in registry`),e.config.backend=R.node?"tensorflow":"webgl",e.config.debug&&h(`override: setting backend ${e.config.backend}`)),e.config.debug&&h("setting backend:",[e.config.backend]),e.config.backend==="wasm"){if(S.env().flagRegistry.CANVAS2D_WILL_READ_FREQUENTLY&&S.env().set("CANVAS2D_WILL_READ_FREQUENTLY",!0),e.config.debug&&h("wasm path:",e.config.wasmPath),typeof S.setWasmPaths!="undefined")S.setWasmPaths(e.config.wasmPath,e.config.wasmPlatformFetch);else throw new Error("backend error: attempting to use wasm backend but wasm path is not set");let A=!1,a=!1;try{A=await S.env().getAsync("WASM_HAS_MULTITHREAD_SUPPORT"),a=await S.env().getAsync("WASM_HAS_SIMD_SUPPORT"),e.config.debug&&h(`wasm execution: ${a?"simd":"no simd"} ${A?"multithreaded":"singlethreaded"}`),e.config.debug&&!a&&h("warning: wasm simd support is not enabled")}catch(l){h("wasm detection failed")}}try{await S.setBackend(e.config.backend),await S.ready()}catch(A){return h("error: cannot set backend:",e.config.backend,A),!1}e.config.debug&&(Y1=JSON.parse(JSON.stringify(S.env().flags)))}if((S.getBackend()==="humangl"||S.getBackend()==="webgl")&&(S.env().flagRegistry.WEBGL_USE_SHAPES_UNIFORMS&&S.env().set("WEBGL_USE_SHAPES_UNIFORMS",!0),S.env().flagRegistry.WEBGL_EXP_CONV&&S.env().set("WEBGL_EXP_CONV",!0),e.config.debug&&typeof e.config.deallocate!="undefined"&&e.config.deallocate&&(h("changing webgl: WEBGL_DELETE_TEXTURE_THRESHOLD:",!0),S.env().set("WEBGL_DELETE_TEXTURE_THRESHOLD",0))),S.getBackend(),e.config.debug){let s=S.env().flags,A={};for(let a of Object.keys(s))Y1[a]!==s[a]&&(A[a]=s[a]);e.config.debug&&Object.keys(A).length>0&&h("backend:",S.getBackend(),"flags:",A)}if(e.config.flags&&Object.keys(e.config.flags).length>0){e.config.debug&&h("flags:",e.config.flags);for(let[s,A]of Object.entries(e.config.flags))S.env().set(s,A)}S.enableProdMode(),U1(),e.performance.initBackend=Math.trunc(v()-r),e.config.backend=S.getBackend(),await R.updateBackend(),bs(e.config)}return!0}function J2(e,t){for(let n of e){let o={kernelName:n,backendName:t.backend,kernelFunc:r=>{var s;return t.debug&&h("kernelFunc",n,t.backend,r),(s=r==null?void 0:r.inputs)==null?void 0:s.info}};S.registerKernel(o)}R.kernels=S.getKernelsForBackend(S.getBackend()).map(n=>n.kernelName.toLowerCase())}var nt={};ze(nt,{all:()=>Js,body:()=>_2,canvas:()=>Ks,face:()=>Q2,gesture:()=>tt,hand:()=>$2,init:()=>i5,object:()=>et,options:()=>f0,person:()=>Ys});var oe=e=>{if(!e)h("draw error: invalid canvas");else if(!e.getContext)h("draw error: canvas context not defined");else{let t=e.getContext("2d",{willReadFrequently:!0});if(!t)h("draw error: cannot get canvas context");else return t}return null},Je=e=>Math.round(e*180/Math.PI),Y=(e,t,n)=>e.replace(t,typeof n=="number"?n.toFixed(1):n),Qe=(e,t)=>{if(!t.useDepth||typeof e=="undefined")return t.color;let n=Uint8ClampedArray.from([127+2*e,127-2*e,255]);return`rgba(${n[0]}, ${n[1]}, ${n[2]}, ${t.alpha})`};function re(e,t,n,o,r){let s=t.replace(/\[.*\]/g,"").split(` `).map(a=>a.trim()),A=Math.max(0,n);for(let a=s.length-1;a>=0;a--){let l=a*r.lineHeight+o;r.shadowColor&&r.shadowColor!==""&&(e.fillStyle=r.shadowColor,e.fillText(s[a],A+5,l+16)),e.fillStyle=r.labelColor,e.fillText(s[a],A+4,l+15)}}function he(e,t,n,o,r){e.fillStyle=Qe(o,r),e.beginPath(),e.arc(t,n,r.pointSize,0,2*Math.PI),e.fill()}function be(e,t,n,o,r,s){if(e.beginPath(),e.lineWidth=s.lineWidth,s.useCurves){let A=(t+t+o)/2,a=(n+n+r)/2;e.ellipse(A,a,o/2,r/2,0,0,2*Math.PI)}else e.moveTo(t+s.roundRect,n),e.lineTo(t+o-s.roundRect,n),e.quadraticCurveTo(t+o,n,t+o,n+s.roundRect),e.lineTo(t+o,n+r-s.roundRect),e.quadraticCurveTo(t+o,n+r,t+o-s.roundRect,n+r),e.lineTo(t+s.roundRect,n+r),e.quadraticCurveTo(t,n+r,t,n+r-s.roundRect),e.lineTo(t,n+s.roundRect),e.quadraticCurveTo(t,n,t+s.roundRect,n),e.closePath();e.stroke()}function n5(e,t,n){if(!(t.length<2)){e.beginPath(),e.moveTo(t[0][0],t[0][1]);for(let o of t)e.strokeStyle=Qe(o[2]||0,n),e.lineTo(Math.trunc(o[0]),Math.trunc(o[1]));e.stroke(),n.fillPolygons&&(e.closePath(),e.fill())}}function J1(e,t,n){if(!(t.length<2)){if(e.lineWidth=n.lineWidth,!n.useCurves||t.length<=2){n5(e,t,n);return}e.moveTo(t[0][0],t[0][1]);for(let o=0;oN2[e]),Za=Ts.map(e=>N2[e]),Xa=vs.map(e=>N2[e]);function je(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Rs=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Ms=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Ps=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],ks=[[474,475],[475,476],[476,477],[477,474]],ws=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Es=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],zs=[[469,470],[470,471],[471,472],[472,469]],Ss=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]],qa={lips:je(Rs),leftEye:je(Ms),leftEyebrow:je(Ps),leftIris:je(ks),rightEye:je(ws),rightEyebrow:je(Es),rightIris:je(zs),faceOval:je(Ss)};var js=[[61,146],[146,91],[91,181],[181,84],[84,17],[17,314],[314,405],[405,321],[321,375],[375,291],[61,185],[185,40],[40,39],[39,37],[37,0],[0,267],[267,269],[269,270],[270,409],[409,291],[78,95],[95,88],[88,178],[178,87],[87,14],[14,317],[317,402],[402,318],[318,324],[324,308],[78,191],[191,80],[80,81],[81,82],[82,13],[13,312],[312,311],[311,310],[310,415],[415,308]],Is=[[263,249],[249,390],[390,373],[373,374],[374,380],[380,381],[381,382],[382,362],[263,466],[466,388],[388,387],[387,386],[386,385],[385,384],[384,398],[398,362]],Ns=[[276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]],Ls=[[474,475],[475,476],[476,477],[477,474]],Os=[[33,7],[7,163],[163,144],[144,145],[145,153],[153,154],[154,155],[155,133],[33,246],[246,161],[161,160],[160,159],[159,158],[158,157],[157,173],[173,133]],Cs=[[46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]],Ws=[[469,470],[470,471],[471,472],[472,469]],Ds=[[10,338],[338,297],[297,332],[332,284],[284,251],[251,389],[389,356],[356,454],[454,323],[323,361],[361,288],[288,397],[397,365],[365,379],[379,378],[378,400],[400,377],[377,152],[152,148],[148,176],[176,149],[149,150],[150,136],[136,172],[172,58],[58,132],[132,93],[93,234],[234,127],[127,162],[162,21],[21,54],[54,103],[103,67],[67,109],[109,10]];function Ie(e){let t=e.map(n=>n[0]);return t.push(e[e.length-1][1]),t}var Fs={lips:Ie(js),leftEye:Ie(Is),leftEyebrow:Ie(Ns),leftIris:Ie(Ls),rightEye:Ie(Os),rightEyebrow:Ie(Cs),rightIris:Ie(Ws),faceOval:Ie(Ds)},Bs=Object.entries(Fs).map(([e,t])=>t.map(n=>[n,e])).flat(),Ua=new Map(Bs),L2=[61,146,91,181,84,17,314,405,321,375,291,185,40,39,37,0,267,269,270,409,78,95,88,178,87,14,317,402,318,324,308,191,80,81,82,13,312,311,310,415,76,77,90,180,85,16,315,404,320,307,306,184,74,73,72,11,302,303,304,408,62,96,89,179,86,15,316,403,319,325,292,183,42,41,38,12,268,271,272,407],e2=[33,7,163,144,145,153,154,155,133,246,161,160,159,158,157,173,130,25,110,24,23,22,26,112,243,247,30,29,27,28,56,190,226,31,228,229,230,231,232,233,244,113,225,224,223,222,221,189,35,124,46,53,52,65,143,111,117,118,119,120,121,128,245,156,70,63,105,66,107,55,193],t2=[263,249,390,373,374,380,381,382,362,466,388,387,386,385,384,398,359,255,339,254,253,252,256,341,463,467,260,259,257,258,286,414,446,261,448,449,450,451,452,453,464,342,445,444,443,442,441,413,265,353,276,283,282,295,372,340,346,347,348,349,350,357,465,383,300,293,334,296,336,285,417];var q;function Hs(e,t){var o,r,s,A,a,l,c,x,i;if(!q.drawLabels||((o=q.faceLabels)==null?void 0:o.length)===0)return;let n=q.faceLabels.slice();if(n=Y(n,"[id]",e.id.toFixed(0)),e.score&&(n=Y(n,"[score]",100*e.score)),e.gender&&(n=Y(n,"[gender]",e.gender)),e.genderScore&&(n=Y(n,"[genderScore]",100*e.genderScore)),e.age&&(n=Y(n,"[age]",e.age)),e.distance&&(n=Y(n,"[distance]",100*e.distance)),e.real&&(n=Y(n,"[real]",100*e.real)),e.live&&(n=Y(n,"[live]",100*e.live)),e.emotion&&e.emotion.length>0){let f=e.emotion.map(d=>`${Math.trunc(100*d.score)}% ${d.emotion}`);f.length>3&&(f.length=3),n=Y(n,"[emotions]",f.join(" "))}(s=(r=e.rotation)==null?void 0:r.angle)!=null&&s.roll&&(n=Y(n,"[roll]",Je(e.rotation.angle.roll))),(a=(A=e.rotation)==null?void 0:A.angle)!=null&&a.yaw&&(n=Y(n,"[yaw]",Je(e.rotation.angle.yaw))),(c=(l=e.rotation)==null?void 0:l.angle)!=null&&c.pitch&&(n=Y(n,"[pitch]",Je(e.rotation.angle.pitch))),(i=(x=e.rotation)==null?void 0:x.gaze)!=null&&i.bearing&&(n=Y(n,"[gaze]",Je(e.rotation.gaze.bearing))),re(t,n,e.box[0],e.box[1],q)}function Gs(e,t){var n,o,r,s;if((n=e.annotations)!=null&&n.leftEyeIris&&((o=e.annotations)!=null&&o.leftEyeIris[0])){t.strokeStyle=q.useDepth?"rgba(255, 200, 255, 0.3)":q.color,t.beginPath();let A=Math.abs(e.annotations.leftEyeIris[3][0]-e.annotations.leftEyeIris[1][0])/2,a=Math.abs(e.annotations.leftEyeIris[4][1]-e.annotations.leftEyeIris[2][1])/2;t.ellipse(e.annotations.leftEyeIris[0][0],e.annotations.leftEyeIris[0][1],A,a,0,0,2*Math.PI),t.stroke(),q.fillPolygons&&(t.fillStyle=q.useDepth?"rgba(255, 255, 200, 0.3)":q.color,t.fill())}if((r=e.annotations)!=null&&r.rightEyeIris&&((s=e.annotations)!=null&&s.rightEyeIris[0])){t.strokeStyle=q.useDepth?"rgba(255, 200, 255, 0.3)":q.color,t.beginPath();let A=Math.abs(e.annotations.rightEyeIris[3][0]-e.annotations.rightEyeIris[1][0])/2,a=Math.abs(e.annotations.rightEyeIris[4][1]-e.annotations.rightEyeIris[2][1])/2;t.ellipse(e.annotations.rightEyeIris[0][0],e.annotations.rightEyeIris[0][1],A,a,0,0,2*Math.PI),t.stroke(),q.fillPolygons&&(t.fillStyle=q.useDepth?"rgba(255, 255, 200, 0.3)":q.color,t.fill())}}function Vs(e,t){var n;if(q.drawGaze&&((n=e.rotation)!=null&&n.angle)&&typeof Path2D!="undefined"){t.strokeStyle="pink";let o=e.box[0]+e.box[2]/2-e.box[3]*Je(e.rotation.angle.yaw)/90,r=e.box[1]+e.box[3]/2+e.box[2]*Je(e.rotation.angle.pitch)/90,s=new Path2D(` M ${e.box[0]+e.box[2]/2} ${e.box[1]} C diff --git a/samples/out/ai-body.jpg b/samples/out/ai-body.jpg index 0f0049e9..f115f27a 100644 Binary files a/samples/out/ai-body.jpg and b/samples/out/ai-body.jpg differ diff --git a/test/build.log b/test/build.log index b3c6424e..608765f5 100644 --- a/test/build.log +++ b/test/build.log @@ -1,51 +1,51 @@ -2023-09-18 12:39:57 DATA:  Build {"name":"@vladmandic/human","version":"3.1.1"} -2023-09-18 12:39:57 INFO:  Application: {"name":"@vladmandic/human","version":"3.1.1"} -2023-09-18 12:39:57 INFO:  Environment: {"profile":"production","config":".build.json","package":"package.json","tsconfig":true,"eslintrc":true,"git":true} -2023-09-18 12:39:57 INFO:  Toolchain: {"build":"0.9.2","esbuild":"0.17.19","typescript":"5.1.6","typedoc":"0.23.28","eslint":"8.49.0"} -2023-09-18 12:39:57 INFO:  Build: {"profile":"production","steps":["clean","compile","typings","typedoc","lint","changelog"]} -2023-09-18 12:39:57 STATE: Clean: {"locations":["dist/*","types/*","typedoc/*"]} -2023-09-18 12:39:57 STATE: Compile: {"name":"tfjs/browser/version","format":"esm","platform":"browser","input":"tfjs/tf-version.ts","output":"dist/tfjs.version.js","files":1,"inputBytes":1289,"outputBytes":358} -2023-09-18 12:39:57 STATE: Compile: {"name":"tfjs/nodejs/cpu","format":"cjs","platform":"node","input":"tfjs/tf-node.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":566,"outputBytes":957} -2023-09-18 12:39:57 STATE: Compile: {"name":"human/nodejs/cpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node.js","files":80,"inputBytes":675948,"outputBytes":320762} -2023-09-18 12:39:57 STATE: Compile: {"name":"tfjs/nodejs/gpu","format":"cjs","platform":"node","input":"tfjs/tf-node-gpu.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":574,"outputBytes":965} -2023-09-18 12:39:57 STATE: Compile: {"name":"human/nodejs/gpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-gpu.js","files":80,"inputBytes":675956,"outputBytes":320766} -2023-09-18 12:39:57 STATE: Compile: {"name":"tfjs/nodejs/wasm","format":"cjs","platform":"node","input":"tfjs/tf-node-wasm.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":662,"outputBytes":2003} -2023-09-18 12:39:57 STATE: Compile: {"name":"human/nodejs/wasm","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-wasm.js","files":80,"inputBytes":676994,"outputBytes":320877} -2023-09-18 12:39:57 STATE: Compile: {"name":"tfjs/browser/esm/nobundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":1372,"outputBytes":667} -2023-09-18 12:39:57 STATE: Compile: {"name":"human/browser/esm/nobundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm-nobundle.js","files":80,"inputBytes":675658,"outputBytes":319325} -2023-09-18 12:39:57 STATE: Compile: {"name":"tfjs/browser/esm/bundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":10,"inputBytes":1372,"outputBytes":1264969} -2023-09-18 12:39:58 STATE: Compile: {"name":"human/browser/iife/bundle","format":"iife","platform":"browser","input":"src/human.ts","output":"dist/human.js","files":80,"inputBytes":1939960,"outputBytes":1579985} -2023-09-18 12:39:58 STATE: Compile: {"name":"human/browser/esm/bundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm.js","files":80,"inputBytes":1939960,"outputBytes":2057229} -2023-09-18 12:40:01 STATE: Typings: {"input":"src/human.ts","output":"types/lib","files":15} -2023-09-18 12:40:02 STATE: TypeDoc: {"input":"src/human.ts","output":"typedoc","objects":81,"generated":true} -2023-09-18 12:40:02 STATE: Compile: {"name":"demo/typescript","format":"esm","platform":"browser","input":"demo/typescript/index.ts","output":"demo/typescript/index.js","files":1,"inputBytes":6318,"outputBytes":2970} -2023-09-18 12:40:02 STATE: Compile: {"name":"demo/faceid","format":"esm","platform":"browser","input":"demo/faceid/index.ts","output":"demo/faceid/index.js","files":2,"inputBytes":17503,"outputBytes":9403} -2023-09-18 12:40:02 STATE: Compile: {"name":"demo/tracker","format":"esm","platform":"browser","input":"demo/tracker/index.ts","output":"demo/tracker/index.js","files":2,"inputBytes":54375,"outputBytes":22791} -2023-09-18 12:40:10 STATE: Lint: {"locations":["**/*.json","src/**/*.ts","test/**/*.js","demo/**/*.js","**/*.md"],"files":172,"errors":0,"warnings":0} -2023-09-18 12:40:10 STATE: ChangeLog: {"repository":"https://github.com/vladmandic/human","branch":"main","output":"CHANGELOG.md"} -2023-09-18 12:40:10 STATE: Copy: {"input":"node_modules/@vladmandic/tfjs/types/tfjs-core.d.ts","output":"types/tfjs-core.d.ts"} -2023-09-18 12:40:10 INFO:  Done... -2023-09-18 12:40:10 STATE: Copy: {"input":"node_modules/@vladmandic/tfjs/types/tfjs.d.ts","output":"types/tfjs.esm.d.ts"} -2023-09-18 12:40:10 STATE: Copy: {"input":"src/types/tsconfig.json","output":"types/tsconfig.json"} -2023-09-18 12:40:10 STATE: Copy: {"input":"src/types/eslint.json","output":"types/.eslintrc.json"} -2023-09-18 12:40:10 STATE: Copy: {"input":"src/types/tfjs.esm.d.ts","output":"dist/tfjs.esm.d.ts"} -2023-09-18 12:40:10 STATE: Filter: {"input":"types/tfjs-core.d.ts"} -2023-09-18 12:40:11 STATE: API-Extractor: {"succeeeded":true,"errors":0,"warnings":211} -2023-09-18 12:40:11 STATE: Filter: {"input":"types/human.d.ts"} -2023-09-18 12:40:11 STATE: Write: {"output":"dist/human.esm-nobundle.d.ts"} -2023-09-18 12:40:11 STATE: Write: {"output":"dist/human.esm.d.ts"} -2023-09-18 12:40:11 STATE: Write: {"output":"dist/human.d.ts"} -2023-09-18 12:40:11 STATE: Write: {"output":"dist/human.node-gpu.d.ts"} -2023-09-18 12:40:11 STATE: Write: {"output":"dist/human.node.d.ts"} -2023-09-18 12:40:11 STATE: Write: {"output":"dist/human.node-wasm.d.ts"} -2023-09-18 12:40:11 INFO:  Analyze models: {"folders":8,"result":"models/models.json"} -2023-09-18 12:40:11 STATE: Models {"folder":"./models","models":12} -2023-09-18 12:40:11 STATE: Models {"folder":"../human-models/models","models":44} -2023-09-18 12:40:11 STATE: Models {"folder":"../blazepose/model/","models":4} -2023-09-18 12:40:11 STATE: Models {"folder":"../anti-spoofing/model","models":1} -2023-09-18 12:40:11 STATE: Models {"folder":"../efficientpose/models","models":3} -2023-09-18 12:40:11 STATE: Models {"folder":"../insightface/models","models":5} -2023-09-18 12:40:11 STATE: Models {"folder":"../movenet/models","models":3} -2023-09-18 12:40:11 STATE: Models {"folder":"../nanodet/models","models":4} -2023-09-18 12:40:12 STATE: Models: {"count":58,"totalSize":380063249} -2023-09-18 12:40:12 INFO:  Human Build complete... {"logFile":"test/build.log"} +2023-09-18 12:44:45 DATA:  Build {"name":"@vladmandic/human","version":"3.1.2"} +2023-09-18 12:44:45 INFO:  Application: {"name":"@vladmandic/human","version":"3.1.2"} +2023-09-18 12:44:45 INFO:  Environment: {"profile":"production","config":".build.json","package":"package.json","tsconfig":true,"eslintrc":true,"git":true} +2023-09-18 12:44:45 INFO:  Toolchain: {"build":"0.9.2","esbuild":"0.17.19","typescript":"5.1.6","typedoc":"0.23.28","eslint":"8.49.0"} +2023-09-18 12:44:45 INFO:  Build: {"profile":"production","steps":["clean","compile","typings","typedoc","lint","changelog"]} +2023-09-18 12:44:45 STATE: Clean: {"locations":["dist/*","types/*","typedoc/*"]} +2023-09-18 12:44:45 STATE: Compile: {"name":"tfjs/browser/version","format":"esm","platform":"browser","input":"tfjs/tf-version.ts","output":"dist/tfjs.version.js","files":1,"inputBytes":1289,"outputBytes":358} +2023-09-18 12:44:45 STATE: Compile: {"name":"tfjs/nodejs/cpu","format":"cjs","platform":"node","input":"tfjs/tf-node.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":566,"outputBytes":957} +2023-09-18 12:44:45 STATE: Compile: {"name":"human/nodejs/cpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node.js","files":80,"inputBytes":675948,"outputBytes":320762} +2023-09-18 12:44:45 STATE: Compile: {"name":"tfjs/nodejs/gpu","format":"cjs","platform":"node","input":"tfjs/tf-node-gpu.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":574,"outputBytes":965} +2023-09-18 12:44:45 STATE: Compile: {"name":"human/nodejs/gpu","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-gpu.js","files":80,"inputBytes":675956,"outputBytes":320766} +2023-09-18 12:44:45 STATE: Compile: {"name":"tfjs/nodejs/wasm","format":"cjs","platform":"node","input":"tfjs/tf-node-wasm.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":662,"outputBytes":2003} +2023-09-18 12:44:45 STATE: Compile: {"name":"human/nodejs/wasm","format":"cjs","platform":"node","input":"src/human.ts","output":"dist/human.node-wasm.js","files":80,"inputBytes":676994,"outputBytes":320877} +2023-09-18 12:44:45 STATE: Compile: {"name":"tfjs/browser/esm/nobundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":2,"inputBytes":1372,"outputBytes":667} +2023-09-18 12:44:45 STATE: Compile: {"name":"human/browser/esm/nobundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm-nobundle.js","files":80,"inputBytes":675658,"outputBytes":319325} +2023-09-18 12:44:45 STATE: Compile: {"name":"tfjs/browser/esm/bundle","format":"esm","platform":"browser","input":"tfjs/tf-browser.ts","output":"dist/tfjs.esm.js","files":10,"inputBytes":1372,"outputBytes":1264969} +2023-09-18 12:44:45 STATE: Compile: {"name":"human/browser/iife/bundle","format":"iife","platform":"browser","input":"src/human.ts","output":"dist/human.js","files":80,"inputBytes":1939960,"outputBytes":1579985} +2023-09-18 12:44:45 STATE: Compile: {"name":"human/browser/esm/bundle","format":"esm","platform":"browser","input":"src/human.ts","output":"dist/human.esm.js","files":80,"inputBytes":1939960,"outputBytes":2057229} +2023-09-18 12:44:48 STATE: Typings: {"input":"src/human.ts","output":"types/lib","files":15} +2023-09-18 12:44:50 STATE: TypeDoc: {"input":"src/human.ts","output":"typedoc","objects":81,"generated":true} +2023-09-18 12:44:50 STATE: Compile: {"name":"demo/typescript","format":"esm","platform":"browser","input":"demo/typescript/index.ts","output":"demo/typescript/index.js","files":1,"inputBytes":6318,"outputBytes":2970} +2023-09-18 12:44:50 STATE: Compile: {"name":"demo/faceid","format":"esm","platform":"browser","input":"demo/faceid/index.ts","output":"demo/faceid/index.js","files":2,"inputBytes":17503,"outputBytes":9403} +2023-09-18 12:44:50 STATE: Compile: {"name":"demo/tracker","format":"esm","platform":"browser","input":"demo/tracker/index.ts","output":"demo/tracker/index.js","files":2,"inputBytes":54375,"outputBytes":22791} +2023-09-18 12:44:57 STATE: Lint: {"locations":["**/*.json","src/**/*.ts","test/**/*.js","demo/**/*.js","**/*.md"],"files":172,"errors":0,"warnings":0} +2023-09-18 12:44:57 STATE: ChangeLog: {"repository":"https://github.com/vladmandic/human","branch":"main","output":"CHANGELOG.md"} +2023-09-18 12:44:57 STATE: Copy: {"input":"node_modules/@vladmandic/tfjs/types/tfjs-core.d.ts","output":"types/tfjs-core.d.ts"} +2023-09-18 12:44:57 INFO:  Done... +2023-09-18 12:44:57 STATE: Copy: {"input":"node_modules/@vladmandic/tfjs/types/tfjs.d.ts","output":"types/tfjs.esm.d.ts"} +2023-09-18 12:44:57 STATE: Copy: {"input":"src/types/tsconfig.json","output":"types/tsconfig.json"} +2023-09-18 12:44:57 STATE: Copy: {"input":"src/types/eslint.json","output":"types/.eslintrc.json"} +2023-09-18 12:44:57 STATE: Copy: {"input":"src/types/tfjs.esm.d.ts","output":"dist/tfjs.esm.d.ts"} +2023-09-18 12:44:57 STATE: Filter: {"input":"types/tfjs-core.d.ts"} +2023-09-18 12:44:58 STATE: API-Extractor: {"succeeeded":true,"errors":0,"warnings":211} +2023-09-18 12:44:58 STATE: Filter: {"input":"types/human.d.ts"} +2023-09-18 12:44:58 STATE: Write: {"output":"dist/human.esm-nobundle.d.ts"} +2023-09-18 12:44:58 STATE: Write: {"output":"dist/human.esm.d.ts"} +2023-09-18 12:44:58 STATE: Write: {"output":"dist/human.d.ts"} +2023-09-18 12:44:58 STATE: Write: {"output":"dist/human.node-gpu.d.ts"} +2023-09-18 12:44:58 STATE: Write: {"output":"dist/human.node.d.ts"} +2023-09-18 12:44:58 STATE: Write: {"output":"dist/human.node-wasm.d.ts"} +2023-09-18 12:44:58 INFO:  Analyze models: {"folders":8,"result":"models/models.json"} +2023-09-18 12:44:58 STATE: Models {"folder":"./models","models":12} +2023-09-18 12:44:58 STATE: Models {"folder":"../human-models/models","models":44} +2023-09-18 12:44:58 STATE: Models {"folder":"../blazepose/model/","models":4} +2023-09-18 12:44:58 STATE: Models {"folder":"../anti-spoofing/model","models":1} +2023-09-18 12:44:58 STATE: Models {"folder":"../efficientpose/models","models":3} +2023-09-18 12:44:58 STATE: Models {"folder":"../insightface/models","models":5} +2023-09-18 12:44:58 STATE: Models {"folder":"../movenet/models","models":3} +2023-09-18 12:44:58 STATE: Models {"folder":"../nanodet/models","models":4} +2023-09-18 12:44:59 STATE: Models: {"count":58,"totalSize":380063249} +2023-09-18 12:44:59 INFO:  Human Build complete... {"logFile":"test/build.log"} diff --git a/test/test.log b/test/test.log index 562217c9..29200871 100644 --- a/test/test.log +++ b/test/test.log @@ -1,888 +1,905 @@ -2023-08-05 14:52:07 INFO:  @vladmandic/human version 3.1.1 -2023-08-05 14:52:07 INFO:  User: vlado Platform: linux Arch: x64 Node: v19.4.0 -2023-08-05 14:52:07 INFO:  demos: [{"cmd":"../demo/nodejs/node.js","args":[]},{"cmd":"../demo/nodejs/node-simple.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/nodejs/process-folder.js","args":["samples"]},{"cmd":"../demo/multithread/node-multiprocess.js","args":[]},{"cmd":"../demo/facematch/node-match.js","args":[]},{"cmd":"../demo/nodejs/node-bench.js","args":[]},{"cmd":"../test/test-node-emotion.js","args":[]}] -2023-08-05 14:52:07 INFO:  {"cmd":"../demo/nodejs/node.js","args":[]} start -2023-08-05 14:52:09 INFO:  {"cmd":"../demo/nodejs/node-simple.js","args":[]} start -2023-08-05 14:52:11 INFO:  {"cmd":"../demo/nodejs/node-event.js","args":["samples/in/ai-body.jpg"]} start -2023-08-05 14:52:12 INFO:  {"cmd":"../demo/nodejs/node-similarity.js","args":["samples/in/ai-face.jpg","samples/in/ai-upper.jpg"]} start -2023-08-05 14:52:13 INFO:  {"cmd":"../demo/nodejs/node-canvas.js","args":["samples/in/ai-body.jpg","samples/out/ai-body.jpg"]} start -2023-08-05 14:52:15 INFO:  {"cmd":"../demo/nodejs/process-folder.js","args":["samples"]} start -2023-08-05 14:52:22 INFO:  {"cmd":"../demo/multithread/node-multiprocess.js","args":[]} start -2023-08-05 14:53:00 INFO:  {"cmd":"../demo/facematch/node-match.js","args":[]} start -2023-08-05 14:53:04 INFO:  {"cmd":"../demo/nodejs/node-bench.js","args":[]} start -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: /home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31582 -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: return this.executor.inputs; -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: ^ -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: TypeError: Cannot read properties of undefined (reading 'inputs') -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31582:34) -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: at G3 (/home/vlado/dev/human/dist/human.node.js:121:28447) -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: Thrown at: -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: at get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31582:34) -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: at G3 (/home/vlado/dev/human/dist/human.node.js:121:28447) -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:15 WARN:  ../demo/nodejs/node-bench.js stderr: Node.js v19.4.0 -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: /home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31582 -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: return this.executor.inputs; -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: ^ -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: TypeError: Cannot read properties of undefined (reading 'inputs') -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31582:34) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at G3 (/home/vlado/dev/human/dist/human.node-gpu.js:121:28447) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at runNextTicks (node:internal/process/task_queues:64:3) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at process.processImmediate (node:internal/timers:442:9) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: Thrown at: -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31582:34) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at G3 (/home/vlado/dev/human/dist/human.node-gpu.js:121:28447) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at runNextTicks (node:internal/process/task_queues:64:3) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: at processImmediate (node:internal/timers:442:9) -2023-08-05 14:53:28 WARN:  ../demo/nodejs/node-bench.js stderr: Node.js v19.4.0 -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: /home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-backend-wasm@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-backend-wasm/dist/tf-backend-wasm.node.js:8595 -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: throw ex; -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: ^ -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: TypeError: Cannot read properties of undefined (reading 'inputNodes') -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31568:34) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.normalizeInputs (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31894:56) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.execute (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31973:23) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at E3 (/home/vlado/dev/human/dist/human.node-wasm.js:121:20457) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at W3 (/home/vlado/dev/human/dist/human.node-wasm.js:121:25444) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at Q5 (/home/vlado/dev/human/dist/human.node-wasm.js:121:41925) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at /home/vlado/dev/human/dist/human.node-wasm.js:840:8174 -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: Thrown at: -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31568:34) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.normalizeInputs (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31894:56) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at GraphModel.execute (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31973:23) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at E3 (/home/vlado/dev/human/dist/human.node-wasm.js:121:20457) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at W3 (/home/vlado/dev/human/dist/human.node-wasm.js:121:25444) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at Q5 (/home/vlado/dev/human/dist/human.node-wasm.js:121:41925) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at /home/vlado/dev/human/dist/human.node-wasm.js:840:8174 -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:39 WARN:  ../demo/nodejs/node-bench.js stderr: Node.js v19.4.0 -2023-08-05 14:53:39 INFO:  {"cmd":"../test/test-node-emotion.js","args":[]} start -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: /home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31568 -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: return this.executor.inputNodes; -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: ^ -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: TypeError: Cannot read properties of undefined (reading 'inputNodes') -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at GraphModel.get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31568:34) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at GraphModel.normalizeInputs (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31894:56) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at GraphModel.execute (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31973:23) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at w3 (/home/vlado/dev/human/dist/human.node.js:121:20457) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at C3 (/home/vlado/dev/human/dist/human.node.js:121:25444) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at J5 (/home/vlado/dev/human/dist/human.node.js:121:41925) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at /home/vlado/dev/human/dist/human.node.js:840:8174 -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: Thrown at: -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31568:34) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at GraphModel.normalizeInputs (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31894:56) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at GraphModel.execute (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31973:23) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at w3 (/home/vlado/dev/human/dist/human.node.js:121:20457) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at C3 (/home/vlado/dev/human/dist/human.node.js:121:25444) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at J5 (/home/vlado/dev/human/dist/human.node.js:121:41925) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at /home/vlado/dev/human/dist/human.node.js:840:8174 -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:53:50 WARN:  ../test/test-node-emotion.js stderr: Node.js v19.4.0 -2023-08-05 14:53:50 INFO:  tests: ["test-node-load.js","test-node-gear.js","test-backend-node.js","test-backend-node-gpu.js","test-backend-node-wasm.js"] -2023-08-05 14:53:50 INFO:  -2023-08-05 14:53:50 INFO:  test-node-load.js start -2023-08-05 14:53:50 INFO:  test-node-load.js load start {"human":"3.1.1","tf":"4.10.0","progress":0} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":0,"progress":0} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":11,"progress":0} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":20,"progress":0} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":33,"progress":0} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":49,"progress":0.02443697553522879} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":66,"progress":0.06164218554150753} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":82,"progress":0.12865823126207815} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":99,"progress":0.2204080722078057} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":108,"progress":0.33826045252170456} -2023-08-05 14:53:50 DATA:  test-node-load.js load interval {"elapsed":202,"progress":0.68355493315821} -2023-08-05 14:53:50 STATE: test-node-load.js passed {"progress":1} -2023-08-05 14:53:50 INFO:  test-node-load.js load final {"progress":1} -2023-08-05 14:53:51 DATA:  test-node-load.js load interval {"elapsed":1033,"progress":1} -2023-08-05 14:53:51 INFO:  -2023-08-05 14:53:51 INFO:  test-node-gear.js start -2023-08-05 14:53:52 DATA:  test-node-gear.js input: ["samples/in/ai-face.jpg"] -2023-08-05 14:53:55 STATE: test-node-gear.js passed: gear faceres samples/in/ai-face.jpg -2023-08-05 14:53:55 DATA:  test-node-gear.js results {"face":0,"model":"faceres","image":"samples/in/ai-face.jpg","age":23.5,"gender":"female","genderScore":0.92,"emotion":[]} -2023-08-05 14:53:56 STATE: test-node-gear.js passed: gear gear samples/in/ai-face.jpg -2023-08-05 14:53:56 DATA:  test-node-gear.js results {"face":0,"model":"gear","image":"samples/in/ai-face.jpg","age":23.3,"gender":"female","genderScore":0.51,"race":[{"score":0.93,"race":"white"}],"emotion":[]} -2023-08-05 14:53:57 STATE: test-node-gear.js passed: gear ssrnet samples/in/ai-face.jpg -2023-08-05 14:53:57 DATA:  test-node-gear.js results {"face":0,"model":"ssrnet","image":"samples/in/ai-face.jpg","age":23.4,"gender":"female","genderScore":0.99,"emotion":[]} -2023-08-05 14:53:58 STATE: test-node-gear.js passed: gear ssrnet samples/in/ai-face.jpg -2023-08-05 14:53:58 DATA:  test-node-gear.js results {"face":0,"model":"ssrnet","image":"samples/in/ai-face.jpg","age":23.4,"gender":"male","emotion":[]} -2023-08-05 14:53:58 INFO:  -2023-08-05 14:53:58 INFO:  test-backend-node.js start -2023-08-05 14:53:58 INFO:  test-backend-node.js test: configuration validation -2023-08-05 14:53:58 STATE: test-backend-node.js passed: configuration default validation [] -2023-08-05 14:53:58 STATE: test-backend-node.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] -2023-08-05 14:53:58 INFO:  test-backend-node.js test: model load -2023-08-05 14:53:58 STATE: test-backend-node.js passed: models loaded 11 11 [{"name":"liveness","loaded":true,"size":592976,"url":"file://models/liveness.json"},{"name":"blazeface","loaded":true,"size":538928,"url":"file://models/blazeface.json"},{"name":"antispoof","loaded":true,"size":853098,"url":"file://models/antispoof.json"},{"name":"emotion","loaded":true,"size":820516,"url":"file://models/emotion.json"},{"name":"facemesh","loaded":true,"size":1477958,"url":"file://models/facemesh.json"},{"name":"handskeleton","loaded":true,"size":0,"url":"file://models/handlandmark-lite.json"},{"name":"iris","loaded":true,"size":2599092,"url":"file://models/iris.json"},{"name":"handtrack","loaded":true,"size":2964837,"url":"file://models/handtrack.json"},{"name":"centernet","loaded":true,"size":4030290,"url":"file://models/centernet.json"},{"name":"movenet","loaded":true,"size":4650216,"url":"file://models/movenet-lightning.json"},{"name":"faceres","loaded":true,"size":6978814,"url":"file://models/faceres.json"}] -2023-08-05 14:53:58 INFO:  test-backend-node.js memory: {"memory":{"unreliable":true,"numTensors":1785,"numDataBuffers":1785,"numBytes":56431460}} -2023-08-05 14:53:58 INFO:  test-backend-node.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":56431460,"numTensors":1785,"numStringTensors":0,"numDataBuffers":1785,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} -2023-08-05 14:53:58 INFO:  test-backend-node.js test: warmup -2023-08-05 14:53:58 STATE: test-backend-node.js passed: create human -2023-08-05 14:53:58 INFO:  test-backend-node.js human version: 3.1.1 -2023-08-05 14:53:58 INFO:  test-backend-node.js platform: linux x64 agent: NodeJS v19.4.0 -2023-08-05 14:53:58 INFO:  test-backend-node.js tfjs version: 4.10.0 -2023-08-05 14:53:58 INFO:  test-backend-node.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v19.4.0","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"4.10.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.9.1","gpu":false},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":172} -2023-08-05 14:53:58 STATE: test-backend-node.js passed: set backend: tensorflow -2023-08-05 14:53:58 STATE: test-backend-node.js tensors 1785 -2023-08-05 14:53:58 STATE: test-backend-node.js result: defined models: 11 loaded models: 11 -2023-08-05 14:53:58 STATE: test-backend-node.js passed: load models 11 -2023-08-05 14:53:58 STATE: test-backend-node.js passed: warmup: none default -2023-08-05 14:53:58 DATA:  test-backend-node.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} -2023-08-05 14:53:58 DATA:  test-backend-node.js result: performance: load: null total: null -2023-08-05 14:53:58 STATE: test-backend-node.js passed: warmup none result match -2023-08-05 14:53:59 STATE: test-backend-node.js event: image -2023-08-05 14:53:59 STATE: test-backend-node.js event: detect -2023-08-05 14:53:59 STATE: test-backend-node.js event: warmup -2023-08-05 14:53:59 STATE: test-backend-node.js passed: warmup: face default -2023-08-05 14:53:59 DATA:  test-backend-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.42,"keypoints":4} -2023-08-05 14:53:59 DATA:  test-backend-node.js result: performance: load: null total: 821 -2023-08-05 14:53:59 STATE: test-backend-node.js passed: warmup face result match -2023-08-05 14:53:59 STATE: test-backend-node.js event: image -2023-08-05 14:54:00 STATE: test-backend-node.js event: detect -2023-08-05 14:54:00 STATE: test-backend-node.js event: warmup -2023-08-05 14:54:00 STATE: test-backend-node.js passed: warmup: body default -2023-08-05 14:54:00 DATA:  test-backend-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} -2023-08-05 14:54:00 DATA:  test-backend-node.js result: performance: load: null total: 652 -2023-08-05 14:54:00 STATE: test-backend-node.js passed: warmup body result match -2023-08-05 14:54:00 STATE: test-backend-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":"thumb up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} -2023-08-05 14:54:00 INFO:  test-backend-node.js test: details verification -2023-08-05 14:54:00 STATE: test-backend-node.js start default -2023-08-05 14:54:00 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:00 STATE: test-backend-node.js event: image -2023-08-05 14:54:01 STATE: test-backend-node.js event: detect -2023-08-05 14:54:01 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg default -2023-08-05 14:54:01 DATA:  test-backend-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} -2023-08-05 14:54:01 DATA:  test-backend-node.js result: performance: load: null total: 631 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face length 1 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face score 1 0.93 1 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face age/gender 23.7 female 0.97 2.34 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face arrays 4 478 1024 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face anti-spoofing 0.79 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details face liveness 0.83 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details body length 1 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details body 0.92 17 6 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details hand length 1 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details hand 0.51 0.73 point -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details hand arrays 21 5 7 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details gesture length 7 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details gesture first {"face":0,"gesture":"facing right"} -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details object length 1 -2023-08-05 14:54:01 STATE: test-backend-node.js passed: details object 0.72 person -2023-08-05 14:54:02 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996800} -2023-08-05 14:54:02 STATE: test-backend-node.js event: image -2023-08-05 14:54:02 STATE: test-backend-node.js event: detect -2023-08-05 14:54:02 STATE: test-backend-node.js passed: tensor shape: [1,1200,1200,4] dtype: float32 -2023-08-05 14:54:02 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996800} -2023-08-05 14:54:02 STATE: test-backend-node.js event: image -2023-08-05 14:54:03 STATE: test-backend-node.js event: detect -2023-08-05 14:54:03 STATE: test-backend-node.js passed: tensor shape: [1200,1200,4] dtype: float32 -2023-08-05 14:54:03 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:03 STATE: test-backend-node.js event: image -2023-08-05 14:54:04 STATE: test-backend-node.js event: detect -2023-08-05 14:54:04 STATE: test-backend-node.js passed: tensor shape: [1,1200,1200,3] dtype: float32 -2023-08-05 14:54:05 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:05 STATE: test-backend-node.js event: image -2023-08-05 14:54:05 STATE: test-backend-node.js event: detect -2023-08-05 14:54:05 STATE: test-backend-node.js passed: tensor shape: [1200,1200,3] dtype: float32 -2023-08-05 14:54:06 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} -2023-08-05 14:54:06 STATE: test-backend-node.js event: image -2023-08-05 14:54:06 STATE: test-backend-node.js event: detect -2023-08-05 14:54:06 STATE: test-backend-node.js passed: tensor shape: [1,1200,1200,4] dtype: int32 -2023-08-05 14:54:06 INFO:  test-backend-node.js test default -2023-08-05 14:54:06 STATE: test-backend-node.js start async -2023-08-05 14:54:07 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:07 STATE: test-backend-node.js event: image -2023-08-05 14:54:07 STATE: test-backend-node.js event: detect -2023-08-05 14:54:07 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg async -2023-08-05 14:54:07 DATA:  test-backend-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} -2023-08-05 14:54:07 DATA:  test-backend-node.js result: performance: load: null total: 637 -2023-08-05 14:54:07 STATE: test-backend-node.js passed: default result face match 1 female 0.97 -2023-08-05 14:54:07 INFO:  test-backend-node.js test sync -2023-08-05 14:54:07 STATE: test-backend-node.js start sync -2023-08-05 14:54:08 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:08 STATE: test-backend-node.js event: image -2023-08-05 14:54:09 STATE: test-backend-node.js event: detect -2023-08-05 14:54:09 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg sync -2023-08-05 14:54:09 DATA:  test-backend-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} -2023-08-05 14:54:09 DATA:  test-backend-node.js result: performance: load: null total: 711 -2023-08-05 14:54:09 STATE: test-backend-node.js passed: default sync 1 female 0.97 -2023-08-05 14:54:09 INFO:  test-backend-node.js test: image process -2023-08-05 14:54:09 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:54:09 STATE: test-backend-node.js passed: image input null [1,256,256,3] -2023-08-05 14:54:09 INFO:  test-backend-node.js test: image null -2023-08-05 14:54:09 STATE: test-backend-node.js passed: invalid input could not convert input to tensor -2023-08-05 14:54:09 INFO:  test-backend-node.js test face similarity -2023-08-05 14:54:09 STATE: test-backend-node.js start face similarity -2023-08-05 14:54:09 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:54:09 STATE: test-backend-node.js event: image -2023-08-05 14:54:09 STATE: test-backend-node.js event: detect -2023-08-05 14:54:09 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face similarity -2023-08-05 14:54:09 DATA:  test-backend-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} -2023-08-05 14:54:09 DATA:  test-backend-node.js result: performance: load: null total: 601 -2023-08-05 14:54:09 STATE: test-backend-node.js start face similarity -2023-08-05 14:54:10 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:10 STATE: test-backend-node.js event: image -2023-08-05 14:54:11 STATE: test-backend-node.js event: detect -2023-08-05 14:54:11 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg face similarity -2023-08-05 14:54:11 DATA:  test-backend-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} -2023-08-05 14:54:11 DATA:  test-backend-node.js result: performance: load: null total: 894 -2023-08-05 14:54:11 STATE: test-backend-node.js start face similarity -2023-08-05 14:54:11 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:54:11 STATE: test-backend-node.js event: image -2023-08-05 14:54:12 STATE: test-backend-node.js event: detect -2023-08-05 14:54:12 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg face similarity -2023-08-05 14:54:12 DATA:  test-backend-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} -2023-08-05 14:54:12 DATA:  test-backend-node.js result: performance: load: null total: 582 -2023-08-05 14:54:12 STATE: test-backend-node.js passed: face descriptor -2023-08-05 14:54:12 STATE: test-backend-node.js passed: face similarity {"similarity":[1,0.44727452409222157,0.55679362387159],"descriptors":[1024,1024,1024]} -2023-08-05 14:54:12 INFO:  test-backend-node.js test object -2023-08-05 14:54:12 STATE: test-backend-node.js start object -2023-08-05 14:54:12 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:12 STATE: test-backend-node.js event: image -2023-08-05 14:54:13 STATE: test-backend-node.js event: detect -2023-08-05 14:54:13 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg object -2023-08-05 14:54:13 DATA:  test-backend-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} -2023-08-05 14:54:13 DATA:  test-backend-node.js result: performance: load: null total: 654 -2023-08-05 14:54:13 STATE: test-backend-node.js passed: centernet -2023-08-05 14:54:13 STATE: test-backend-node.js start object -2023-08-05 14:54:16 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:16 STATE: test-backend-node.js event: image -2023-08-05 14:54:17 STATE: test-backend-node.js event: detect -2023-08-05 14:54:17 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg object -2023-08-05 14:54:17 DATA:  test-backend-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} -2023-08-05 14:54:17 DATA:  test-backend-node.js result: performance: load: null total: 633 -2023-08-05 14:54:17 STATE: test-backend-node.js passed: nanodet -2023-08-05 14:54:17 INFO:  test-backend-node.js test sensitive -2023-08-05 14:54:17 STATE: test-backend-node.js start sensitive -2023-08-05 14:54:17 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:17 STATE: test-backend-node.js event: image -2023-08-05 14:54:18 STATE: test-backend-node.js event: detect -2023-08-05 14:54:18 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg sensitive -2023-08-05 14:54:18 DATA:  test-backend-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} -2023-08-05 14:54:18 DATA:  test-backend-node.js result: performance: load: null total: 484 -2023-08-05 14:54:18 STATE: test-backend-node.js passed: sensitive result match -2023-08-05 14:54:18 STATE: test-backend-node.js passed: sensitive face result match -2023-08-05 14:54:18 STATE: test-backend-node.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] -2023-08-05 14:54:18 STATE: test-backend-node.js passed: sensitive body result match -2023-08-05 14:54:18 STATE: test-backend-node.js passed: sensitive hand result match -2023-08-05 14:54:18 INFO:  test-backend-node.js test body -2023-08-05 14:54:18 STATE: test-backend-node.js start blazepose -2023-08-05 14:54:27 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:27 STATE: test-backend-node.js event: image -2023-08-05 14:54:28 STATE: test-backend-node.js event: detect -2023-08-05 14:54:28 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg blazepose -2023-08-05 14:54:28 DATA:  test-backend-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} -2023-08-05 14:54:28 DATA:  test-backend-node.js result: performance: load: null total: 656 -2023-08-05 14:54:28 STATE: test-backend-node.js passed: blazepose -2023-08-05 14:54:28 STATE: test-backend-node.js start efficientpose -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: 14:54:38.082 Human: error loading model: https://vladmandic.github.io/human-models/models/efficientpose.json TypeError: fetch failed -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:54:38 DATA:  test-backend-node.js stdout: } -2023-08-05 14:54:38 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:38 STATE: test-backend-node.js event: image -2023-08-05 14:54:38 STATE: test-backend-node.js event: detect -2023-08-05 14:54:38 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg efficientpose -2023-08-05 14:54:38 DATA:  test-backend-node.js result: face: 1 body: 0 hand: 2 gesture: 9 object: 0 person: 1 {"score":1,"age":23.7,"gender":"female"} {} {} -2023-08-05 14:54:38 DATA:  test-backend-node.js result: performance: load: null total: 387 -2023-08-05 14:54:38 ERROR: test-backend-node.js failed: efficientpose {} -2023-08-05 14:54:38 STATE: test-backend-node.js start posenet -2023-08-05 14:54:41 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:41 STATE: test-backend-node.js event: image -2023-08-05 14:54:41 STATE: test-backend-node.js event: detect -2023-08-05 14:54:41 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg posenet -2023-08-05 14:54:41 DATA:  test-backend-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} -2023-08-05 14:54:41 DATA:  test-backend-node.js result: performance: load: null total: 454 -2023-08-05 14:54:41 STATE: test-backend-node.js passed: posenet -2023-08-05 14:54:41 STATE: test-backend-node.js start movenet -2023-08-05 14:54:42 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:54:42 STATE: test-backend-node.js event: image -2023-08-05 14:54:42 STATE: test-backend-node.js event: detect -2023-08-05 14:54:42 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg movenet -2023-08-05 14:54:42 DATA:  test-backend-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} -2023-08-05 14:54:42 DATA:  test-backend-node.js result: performance: load: null total: 447 -2023-08-05 14:54:42 STATE: test-backend-node.js passed: movenet -2023-08-05 14:54:42 INFO:  test-backend-node.js test face matching -2023-08-05 14:54:42 STATE: test-backend-node.js passed: face database 40 -2023-08-05 14:54:42 STATE: test-backend-node.js passed: face match {"first":{"index":4,"similarity":0.7827852525543372}} {"second":{"index":4,"similarity":0.5002052813401956}} {"third":{"index":4,"similarity":0.5401588187593348}} -2023-08-05 14:54:42 INFO:  test-backend-node.js test face similarity alternative -2023-08-05 14:54:42 STATE: test-backend-node.js start face embeddings -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: 14:54:52.533 Human: error loading model: https://vladmandic.github.io/human-models/models/mobilefacenet.json TypeError: fetch failed -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at runNextTicks (node:internal/process/task_queues:64:3) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at process.processImmediate (node:internal/timers:442:9) { -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: } -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: 14:54:52.536 Human: error loading model: https://vladmandic.github.io/human-models/models/movenet-lightning.json TypeError: fetch failed -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:54:52 DATA:  test-backend-node.js stdout: } -2023-08-05 14:54:52 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:54:52 STATE: test-backend-node.js event: image -2023-08-05 14:54:52 STATE: test-backend-node.js event: detect -2023-08-05 14:54:52 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face embeddings -2023-08-05 14:54:52 DATA:  test-backend-node.js result: face: 1 body: 0 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {} -2023-08-05 14:54:52 DATA:  test-backend-node.js result: performance: load: null total: 400 -2023-08-05 14:54:52 ERROR: test-backend-node.js failed: mobilefacenet {"embedding":0} -2023-08-05 14:54:52 STATE: test-backend-node.js start face embeddings -2023-08-05 14:54:57 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:54:57 STATE: test-backend-node.js event: image -2023-08-05 14:54:57 STATE: test-backend-node.js event: detect -2023-08-05 14:54:57 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face embeddings -2023-08-05 14:54:57 DATA:  test-backend-node.js result: face: 1 body: 0 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {} -2023-08-05 14:54:57 DATA:  test-backend-node.js result: performance: load: null total: 413 -2023-08-05 14:54:57 STATE: test-backend-node.js passed: insightface {"embedding":512} -2023-08-05 14:54:57 INFO:  test-backend-node.js test face attention -2023-08-05 14:54:57 STATE: test-backend-node.js start face attention -2023-08-05 14:54:58 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:54:58 STATE: test-backend-node.js event: image -2023-08-05 14:54:59 STATE: test-backend-node.js event: detect -2023-08-05 14:54:59 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face attention -2023-08-05 14:54:59 DATA:  test-backend-node.js result: face: 1 body: 0 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {} -2023-08-05 14:54:59 DATA:  test-backend-node.js result: performance: load: null total: 438 -2023-08-05 14:54:59 STATE: test-backend-node.js passed: face attention -2023-08-05 14:54:59 INFO:  test-backend-node.js test detectors -2023-08-05 14:54:59 STATE: test-backend-node.js start detectors -2023-08-05 14:55:01 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:01 STATE: test-backend-node.js event: image -2023-08-05 14:55:01 STATE: test-backend-node.js event: detect -2023-08-05 14:55:01 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg detectors -2023-08-05 14:55:01 DATA:  test-backend-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} -2023-08-05 14:55:01 DATA:  test-backend-node.js result: performance: load: null total: 240 -2023-08-05 14:55:01 STATE: test-backend-node.js passed: detector result face match -2023-08-05 14:55:01 STATE: test-backend-node.js passed: detector result hand match -2023-08-05 14:55:01 INFO:  test-backend-node.js test: multi-instance -2023-08-05 14:55:01 STATE: test-backend-node.js start multi instance -2023-08-05 14:55:01 STATE: test-backend-node.js event: image -2023-08-05 14:55:01 STATE: test-backend-node.js event: detect -2023-08-05 14:55:01 STATE: test-backend-node.js passed: detect: random multi instance -2023-08-05 14:55:01 DATA:  test-backend-node.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} -2023-08-05 14:55:01 DATA:  test-backend-node.js result: performance: load: null total: 244 -2023-08-05 14:55:01 INFO:  test-backend-node.js test: first instance -2023-08-05 14:55:01 STATE: test-backend-node.js start multi instance -2023-08-05 14:55:02 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:55:02 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg multi instance -2023-08-05 14:55:02 DATA:  test-backend-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} -2023-08-05 14:55:02 DATA:  test-backend-node.js result: performance: load: null total: 250 -2023-08-05 14:55:02 INFO:  test-backend-node.js test: second instance -2023-08-05 14:55:02 STATE: test-backend-node.js start multi instance -2023-08-05 14:55:02 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:55:02 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg multi instance -2023-08-05 14:55:02 DATA:  test-backend-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} -2023-08-05 14:55:02 DATA:  test-backend-node.js result: performance: load: null total: 232 -2023-08-05 14:55:02 INFO:  test-backend-node.js test: concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js start concurrent -2023-08-05 14:55:02 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:02 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:02 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:03 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:03 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:03 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:04 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:55:04 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:55:04 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:55:04 STATE: test-backend-node.js event: image -2023-08-05 14:55:04 STATE: test-backend-node.js event: image -2023-08-05 14:55:04 STATE: test-backend-node.js event: image -2023-08-05 14:55:06 STATE: test-backend-node.js event: detect -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2023 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js event: detect -2023-08-05 14:55:06 STATE: test-backend-node.js event: detect -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg concurrent -2023-08-05 14:55:06 DATA:  test-backend-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} -2023-08-05 14:55:06 DATA:  test-backend-node.js result: performance: load: null total: 2024 -2023-08-05 14:55:06 INFO:  test-backend-node.js test: monkey-patch -2023-08-05 14:55:06 STATE: test-backend-node.js event: image -2023-08-05 14:55:06 STATE: test-backend-node.js event: detect -2023-08-05 14:55:06 STATE: test-backend-node.js passed: monkey patch -2023-08-05 14:55:09 STATE: test-backend-node.js passed: segmentation [262144] -2023-08-05 14:55:09 STATE: test-backend-node.js passeed: equal usage -2023-08-05 14:55:09 INFO:  test-backend-node.js test: input compare -2023-08-05 14:55:09 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:09 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:09 STATE: test-backend-node.js passed: image compare 0 23.275441687091504 -2023-08-05 14:55:09 INFO:  test-backend-node.js events: {"image":29,"detect":29,"warmup":2} -2023-08-05 14:55:09 INFO:  test-backend-node.js tensors 14319 -2023-08-05 14:55:09 INFO:  test-backend-node.js test complete: 70736 ms -2023-08-05 14:55:09 INFO:  -2023-08-05 14:55:09 INFO:  test-backend-node-gpu.js start -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js test: configuration validation -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: configuration default validation [] -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js test: model load -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: models loaded 11 11 [{"name":"emotion","loaded":true,"size":820516,"url":"file://models/emotion.json"},{"name":"blazeface","loaded":true,"size":538928,"url":"file://models/blazeface.json"},{"name":"antispoof","loaded":true,"size":853098,"url":"file://models/antispoof.json"},{"name":"liveness","loaded":true,"size":592976,"url":"file://models/liveness.json"},{"name":"facemesh","loaded":true,"size":1477958,"url":"file://models/facemesh.json"},{"name":"handskeleton","loaded":true,"size":0,"url":"file://models/handlandmark-lite.json"},{"name":"iris","loaded":true,"size":2599092,"url":"file://models/iris.json"},{"name":"handtrack","loaded":true,"size":2964837,"url":"file://models/handtrack.json"},{"name":"centernet","loaded":true,"size":4030290,"url":"file://models/centernet.json"},{"name":"movenet","loaded":true,"size":4650216,"url":"file://models/movenet-lightning.json"},{"name":"faceres","loaded":true,"size":6978814,"url":"file://models/faceres.json"}] -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js memory: {"memory":{"unreliable":true,"numTensors":1785,"numDataBuffers":1785,"numBytes":56431460}} -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":56431460,"numTensors":1785,"numStringTensors":0,"numDataBuffers":1785,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js test: warmup -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: create human -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js human version: 3.1.1 -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js platform: linux x64 agent: NodeJS v19.4.0 -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js tfjs version: 4.10.0 -2023-08-05 14:55:11 INFO:  test-backend-node-gpu.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v19.4.0","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"4.10.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.9.1","gpu":false},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":172} -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: set backend: tensorflow -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js tensors 1785 -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js result: defined models: 11 loaded models: 11 -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: load models 11 -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: warmup: none default -2023-08-05 14:55:11 DATA:  test-backend-node-gpu.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} -2023-08-05 14:55:11 DATA:  test-backend-node-gpu.js result: performance: load: null total: null -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js passed: warmup none result match -2023-08-05 14:55:11 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:12 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:12 STATE: test-backend-node-gpu.js event: warmup -2023-08-05 14:55:12 STATE: test-backend-node-gpu.js passed: warmup: face default -2023-08-05 14:55:12 DATA:  test-backend-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.42,"keypoints":4} -2023-08-05 14:55:12 DATA:  test-backend-node-gpu.js result: performance: load: null total: 982 -2023-08-05 14:55:12 STATE: test-backend-node-gpu.js passed: warmup face result match -2023-08-05 14:55:12 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:13 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:13 STATE: test-backend-node-gpu.js event: warmup -2023-08-05 14:55:13 STATE: test-backend-node-gpu.js passed: warmup: body default -2023-08-05 14:55:13 DATA:  test-backend-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} -2023-08-05 14:55:13 DATA:  test-backend-node-gpu.js result: performance: load: null total: 754 -2023-08-05 14:55:13 STATE: test-backend-node-gpu.js passed: warmup body result match -2023-08-05 14:55:13 STATE: test-backend-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":"thumb up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} -2023-08-05 14:55:13 INFO:  test-backend-node-gpu.js test: details verification -2023-08-05 14:55:13 STATE: test-backend-node-gpu.js start default -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg default -2023-08-05 14:55:14 DATA:  test-backend-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} -2023-08-05 14:55:14 DATA:  test-backend-node-gpu.js result: performance: load: null total: 680 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face length 1 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face score 1 0.93 1 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face age/gender 23.7 female 0.97 2.34 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face arrays 4 478 1024 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face anti-spoofing 0.79 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details face liveness 0.83 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details body length 1 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details body 0.92 17 6 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details hand length 1 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details hand 0.51 0.73 point -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details hand arrays 21 5 7 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details gesture length 7 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details gesture first {"face":0,"gesture":"facing right"} -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details object length 1 -2023-08-05 14:55:14 STATE: test-backend-node-gpu.js passed: details object 0.72 person -2023-08-05 14:55:15 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996800} -2023-08-05 14:55:15 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:15 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:15 STATE: test-backend-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: float32 -2023-08-05 14:55:16 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996800} -2023-08-05 14:55:16 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:16 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:16 STATE: test-backend-node-gpu.js passed: tensor shape: [1200,1200,4] dtype: float32 -2023-08-05 14:55:17 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:17 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:17 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:17 STATE: test-backend-node-gpu.js passed: tensor shape: [1,1200,1200,3] dtype: float32 -2023-08-05 14:55:18 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:18 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:19 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:19 STATE: test-backend-node-gpu.js passed: tensor shape: [1200,1200,3] dtype: float32 -2023-08-05 14:55:19 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} -2023-08-05 14:55:19 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:20 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:20 STATE: test-backend-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: int32 -2023-08-05 14:55:20 INFO:  test-backend-node-gpu.js test default -2023-08-05 14:55:20 STATE: test-backend-node-gpu.js start async -2023-08-05 14:55:20 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:20 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:21 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:21 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg async -2023-08-05 14:55:21 DATA:  test-backend-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} -2023-08-05 14:55:21 DATA:  test-backend-node-gpu.js result: performance: load: null total: 611 -2023-08-05 14:55:21 STATE: test-backend-node-gpu.js passed: default result face match 1 female 0.97 -2023-08-05 14:55:21 INFO:  test-backend-node-gpu.js test sync -2023-08-05 14:55:21 STATE: test-backend-node-gpu.js start sync -2023-08-05 14:55:21 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:21 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg sync -2023-08-05 14:55:22 DATA:  test-backend-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} -2023-08-05 14:55:22 DATA:  test-backend-node-gpu.js result: performance: load: null total: 608 -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js passed: default sync 1 female 0.97 -2023-08-05 14:55:22 INFO:  test-backend-node-gpu.js test: image process -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js passed: image input null [1,256,256,3] -2023-08-05 14:55:22 INFO:  test-backend-node-gpu.js test: image null -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js passed: invalid input could not convert input to tensor -2023-08-05 14:55:22 INFO:  test-backend-node-gpu.js test face similarity -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js start face similarity -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:22 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:23 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:23 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face similarity -2023-08-05 14:55:23 DATA:  test-backend-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} -2023-08-05 14:55:23 DATA:  test-backend-node-gpu.js result: performance: load: null total: 623 -2023-08-05 14:55:23 STATE: test-backend-node-gpu.js start face similarity -2023-08-05 14:55:23 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:23 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg face similarity -2023-08-05 14:55:24 DATA:  test-backend-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} -2023-08-05 14:55:24 DATA:  test-backend-node-gpu.js result: performance: load: null total: 564 -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js start face similarity -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg face similarity -2023-08-05 14:55:24 DATA:  test-backend-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} -2023-08-05 14:55:24 DATA:  test-backend-node-gpu.js result: performance: load: null total: 518 -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js passed: face descriptor -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js passed: face similarity {"similarity":[1,0.44727452409222157,0.55679362387159],"descriptors":[1024,1024,1024]} -2023-08-05 14:55:24 INFO:  test-backend-node-gpu.js test object -2023-08-05 14:55:24 STATE: test-backend-node-gpu.js start object -2023-08-05 14:55:25 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:25 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:25 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:25 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg object -2023-08-05 14:55:25 DATA:  test-backend-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} -2023-08-05 14:55:25 DATA:  test-backend-node-gpu.js result: performance: load: null total: 578 -2023-08-05 14:55:25 STATE: test-backend-node-gpu.js passed: centernet -2023-08-05 14:55:25 STATE: test-backend-node-gpu.js start object -2023-08-05 14:55:28 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:28 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:29 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:29 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg object -2023-08-05 14:55:29 DATA:  test-backend-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} -2023-08-05 14:55:29 DATA:  test-backend-node-gpu.js result: performance: load: null total: 558 -2023-08-05 14:55:29 STATE: test-backend-node-gpu.js passed: nanodet -2023-08-05 14:55:29 INFO:  test-backend-node-gpu.js test sensitive -2023-08-05 14:55:29 STATE: test-backend-node-gpu.js start sensitive -2023-08-05 14:55:29 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:29 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg sensitive -2023-08-05 14:55:30 DATA:  test-backend-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} -2023-08-05 14:55:30 DATA:  test-backend-node-gpu.js result: performance: load: null total: 493 -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js passed: sensitive result match -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js passed: sensitive face result match -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js passed: sensitive body result match -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js passed: sensitive hand result match -2023-08-05 14:55:30 INFO:  test-backend-node-gpu.js test body -2023-08-05 14:55:30 STATE: test-backend-node-gpu.js start blazepose -2023-08-05 14:55:38 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:38 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:39 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:39 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg blazepose -2023-08-05 14:55:39 DATA:  test-backend-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} -2023-08-05 14:55:39 DATA:  test-backend-node-gpu.js result: performance: load: null total: 680 -2023-08-05 14:55:39 STATE: test-backend-node-gpu.js passed: blazepose -2023-08-05 14:55:39 STATE: test-backend-node-gpu.js start efficientpose -2023-08-05 14:55:42 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:42 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:42 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:42 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg efficientpose -2023-08-05 14:55:42 DATA:  test-backend-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} -2023-08-05 14:55:42 DATA:  test-backend-node-gpu.js result: performance: load: null total: 643 -2023-08-05 14:55:42 STATE: test-backend-node-gpu.js passed: efficientpose -2023-08-05 14:55:42 STATE: test-backend-node-gpu.js start posenet -2023-08-05 14:55:44 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:44 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:45 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:45 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg posenet -2023-08-05 14:55:45 DATA:  test-backend-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} -2023-08-05 14:55:45 DATA:  test-backend-node-gpu.js result: performance: load: null total: 443 -2023-08-05 14:55:45 STATE: test-backend-node-gpu.js passed: posenet -2023-08-05 14:55:45 STATE: test-backend-node-gpu.js start movenet -2023-08-05 14:55:45 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:55:45 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:46 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:46 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg movenet -2023-08-05 14:55:46 DATA:  test-backend-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} -2023-08-05 14:55:46 DATA:  test-backend-node-gpu.js result: performance: load: null total: 448 -2023-08-05 14:55:46 STATE: test-backend-node-gpu.js passed: movenet -2023-08-05 14:55:46 INFO:  test-backend-node-gpu.js test face matching -2023-08-05 14:55:46 STATE: test-backend-node-gpu.js passed: face database 40 -2023-08-05 14:55:46 STATE: test-backend-node-gpu.js passed: face match {"first":{"index":4,"similarity":0.7827852525543372}} {"second":{"index":4,"similarity":0.5002052813401956}} {"third":{"index":4,"similarity":0.5401588187593348}} -2023-08-05 14:55:46 INFO:  test-backend-node-gpu.js test face similarity alternative -2023-08-05 14:55:46 STATE: test-backend-node-gpu.js start face embeddings -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: 14:55:56.145 Human: error loading model: https://vladmandic.github.io/human-models/models/movenet-lightning.json TypeError: fetch failed -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js stdout: } -2023-08-05 14:55:56 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:55:56 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:55:56 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:55:56 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js result: face: 1 body: 0 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {} -2023-08-05 14:55:56 DATA:  test-backend-node-gpu.js result: performance: load: null total: 468 -2023-08-05 14:55:56 STATE: test-backend-node-gpu.js passed: mobilefacenet {"embedding":192} -2023-08-05 14:55:56 STATE: test-backend-node-gpu.js start face embeddings -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: 14:56:06.695 Human: error loading model: https://vladmandic.github.io/insightface/models/insightface-mobilenet-swish.json TypeError: fetch failed -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:56:06 DATA:  test-backend-node-gpu.js stdout: } -2023-08-05 14:56:06 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:56:06 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:07 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:07 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings -2023-08-05 14:56:07 DATA:  test-backend-node-gpu.js result: face: 1 body: 0 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {} -2023-08-05 14:56:07 DATA:  test-backend-node-gpu.js result: performance: load: null total: 514 -2023-08-05 14:56:07 ERROR: test-backend-node-gpu.js failed: insightface {"embedding":0} -2023-08-05 14:56:07 INFO:  test-backend-node-gpu.js test face attention -2023-08-05 14:56:07 STATE: test-backend-node-gpu.js start face attention -2023-08-05 14:56:08 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:56:08 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:08 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:08 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face attention -2023-08-05 14:56:08 DATA:  test-backend-node-gpu.js result: face: 1 body: 0 hand: 2 gesture: 8 object: 0 person: 1 {"score":1,"age":23.5,"gender":"female"} {} {} -2023-08-05 14:56:08 DATA:  test-backend-node-gpu.js result: performance: load: null total: 518 -2023-08-05 14:56:08 STATE: test-backend-node-gpu.js passed: face attention -2023-08-05 14:56:08 INFO:  test-backend-node-gpu.js test detectors -2023-08-05 14:56:08 STATE: test-backend-node-gpu.js start detectors -2023-08-05 14:56:10 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:56:10 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg detectors -2023-08-05 14:56:11 DATA:  test-backend-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} -2023-08-05 14:56:11 DATA:  test-backend-node-gpu.js result: performance: load: null total: 317 -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js passed: detector result face match -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js passed: detector result hand match -2023-08-05 14:56:11 INFO:  test-backend-node-gpu.js test: multi-instance -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js start multi instance -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js passed: detect: random multi instance -2023-08-05 14:56:11 DATA:  test-backend-node-gpu.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} -2023-08-05 14:56:11 DATA:  test-backend-node-gpu.js result: performance: load: null total: 265 -2023-08-05 14:56:11 INFO:  test-backend-node-gpu.js test: first instance -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js start multi instance -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance -2023-08-05 14:56:11 DATA:  test-backend-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} -2023-08-05 14:56:11 DATA:  test-backend-node-gpu.js result: performance: load: null total: 256 -2023-08-05 14:56:11 INFO:  test-backend-node-gpu.js test: second instance -2023-08-05 14:56:11 STATE: test-backend-node-gpu.js start multi instance -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance -2023-08-05 14:56:12 DATA:  test-backend-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} -2023-08-05 14:56:12 DATA:  test-backend-node-gpu.js result: performance: load: null total: 312 -2023-08-05 14:56:12 INFO:  test-backend-node-gpu.js test: concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js start concurrent -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:56:12 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:56:13 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:56:13 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:56:13 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:56:14 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:56:14 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289056} -2023-08-05 14:56:14 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:14 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:14 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2003 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent -2023-08-05 14:56:16 DATA:  test-backend-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} -2023-08-05 14:56:16 DATA:  test-backend-node-gpu.js result: performance: load: null total: 2004 -2023-08-05 14:56:16 INFO:  test-backend-node-gpu.js test: monkey-patch -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js event: image -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js event: detect -2023-08-05 14:56:16 STATE: test-backend-node-gpu.js passed: monkey patch -2023-08-05 14:56:17 STATE: test-backend-node-gpu.js passed: segmentation [262144] -2023-08-05 14:56:17 STATE: test-backend-node-gpu.js passeed: equal usage -2023-08-05 14:56:17 INFO:  test-backend-node-gpu.js test: input compare -2023-08-05 14:56:17 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} -2023-08-05 14:56:18 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} -2023-08-05 14:56:18 STATE: test-backend-node-gpu.js passed: image compare 0 23.275441687091504 -2023-08-05 14:56:18 INFO:  test-backend-node-gpu.js events: {"image":29,"detect":29,"warmup":2} -2023-08-05 14:56:18 INFO:  test-backend-node-gpu.js tensors 14605 -2023-08-05 14:56:18 INFO:  test-backend-node-gpu.js test complete: 67033 ms -2023-08-05 14:56:19 INFO:  -2023-08-05 14:56:19 INFO:  test-backend-node-wasm.js start -2023-08-05 14:56:19 DATA:  test-backend-node-wasm.js stdout: 2023-08-05 14:56:19 INFO:  { supported: true, backend: true, simd: undefined, multithread: undefined } https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@4.10.0/dist/ -2023-08-05 14:56:20 STATE: test-backend-node-wasm.js passed: model server: https://vladmandic.github.io/human-models/models/ -2023-08-05 14:56:20 INFO:  test-backend-node-wasm.js test: configuration validation -2023-08-05 14:56:20 STATE: test-backend-node-wasm.js passed: configuration default validation [] -2023-08-05 14:56:20 STATE: test-backend-node-wasm.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] -2023-08-05 14:56:20 INFO:  test-backend-node-wasm.js test: model load -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: 14:56:30.234 Human: error loading model: https://vladmandic.github.io/human-models/models/blazeface.json TypeError: fetch failed -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at runNextTicks (node:internal/process/task_queues:64:3) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processImmediate (node:internal/timers:442:9) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: } -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: 14:56:30.237 Human: error loading model: https://vladmandic.github.io/human-models/models/antispoof.json TypeError: fetch failed -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at processTicksAndRejections (node:internal/process/task_queues:95:5) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at runNextTicks (node:internal/process/task_queues:64:3) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processImmediate (node:internal/timers:442:9) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: } -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: 14:56:30.238 Human: error loading model: https://vladmandic.github.io/human-models/models/liveness.json TypeError: fetch failed -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: } -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: 14:56:30.239 Human: error loading model: https://vladmandic.github.io/human-models/models/handtrack.json TypeError: fetch failed -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Object.fetch (node:internal/deps/undici/undici:14152:11) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: cause: ConnectTimeoutError: Connect Timeout Error -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at onConnectTimeout (node:internal/deps/undici/undici:7967:28) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at node:internal/deps/undici/undici:7925:50 -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at Immediate._onImmediate (node:internal/deps/undici/undici:7956:13) -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: at process.processImmediate (node:internal/timers:471:21) { -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: code: 'UND_ERR_CONNECT_TIMEOUT' -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js stdout: } -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js passed: models loaded 11 11 [{"name":"emotion","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/emotion.json"},{"name":"facemesh","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/facemesh.json"},{"name":"iris","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/iris.json"},{"name":"handskeleton","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/handlandmark-lite.json"},{"name":"faceres","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/faceres.json"},{"name":"movenet","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/movenet-lightning.json"},{"name":"centernet","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/centernet.json"},{"name":"blazeface","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/blazeface.json"},{"name":"antispoof","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/antispoof.json"},{"name":"liveness","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/liveness.json"},{"name":"handtrack","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/handtrack.json"}] -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js memory: {"memory":{"unreliable":false,"numTensors":1020,"numDataBuffers":1020,"numBytes":41747352}} -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":41747352,"numTensors":1020,"numStringTensors":0,"numDataBuffers":1020,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js test: warmup -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js passed: create human -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js human version: 3.1.1 -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js platform: linux x64 agent: NodeJS v19.4.0 -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js tfjs version: 4.10.0 -2023-08-05 14:56:30 INFO:  test-backend-node-wasm.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v19.4.0","backends":["wasm"],"initial":false,"tfjs":{"version":"4.10.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":174} -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js passed: set backend: wasm -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js tensors 1020 -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js result: defined models: 11 loaded models: 11 -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js passed: load models 11 -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js passed: warmup: none default -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} -2023-08-05 14:56:30 DATA:  test-backend-node-wasm.js result: performance: load: null total: null -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js passed: warmup none result match -2023-08-05 14:56:30 STATE: test-backend-node-wasm.js event: image -2023-08-05 14:56:30 ERROR: test-backend-node-wasm.js failed: testWarmup default -2023-08-05 14:56:30 ERROR: test-backend-node-wasm.js uncaughtException {"name":"TypeError","message":"Cannot read properties of undefined (reading 'inputNodes')","stack":["TypeError: Cannot read properties of undefined (reading 'inputNodes')"," at GraphModel.get (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31568:34)"," at GraphModel.normalizeInputs (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31894:56)"," at GraphModel.execute (/home/vlado/dev/human/node_modules/.pnpm/@tensorflow+tfjs-converter@4.10.0_@tensorflow+tfjs-core@4.10.0/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:31973:23)"," at E3 (/home/vlado/dev/human/dist/human.node-wasm.js:121:20457)"," at W3 (/home/vlado/dev/human/dist/human.node-wasm.js:121:25444)"," at Q5 (/home/vlado/dev/human/dist/human.node-wasm.js:121:41925)"," at /home/vlado/dev/human/dist/human.node-wasm.js:840:8288"," at process.processTicksAndRejections (node:internal/process/task_queues:95:5)"]} -2023-08-05 14:56:30 STATE: all tests complete -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/node.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/node-simple.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/node-event.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/node-similarity.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/node-canvas.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/process-folder.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/multithread/node-multiprocess.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/facematch/node-match.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"../demo/nodejs/node-bench.js","passed":1,"failed":"critical"} -2023-08-05 14:56:30 INFO:  status {"test":"../test/test-node-emotion.js","passed":1,"failed":"critical"} -2023-08-05 14:56:30 INFO:  status {"test":"test-node-load.js","passed":1,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"test-node-gear.js","passed":4,"failed":0} -2023-08-05 14:56:30 INFO:  status {"test":"test-backend-node.js","passed":123,"failed":2} -2023-08-05 14:56:30 INFO:  status {"test":"test-backend-node-gpu.js","passed":124,"failed":1} -2023-08-05 14:56:30 INFO:  status {"test":"test-backend-node-wasm.js","passed":9,"failed":1} -2023-08-05 14:56:30 INFO:  failures {"count":4} -2023-08-05 14:56:30 WARN:  failed {"test":"test-backend-node.js","message":["error",["failed: efficientpose",{}]]} -2023-08-05 14:56:30 WARN:  failed {"test":"test-backend-node.js","message":["error",["failed: mobilefacenet",{"embedding":0}]]} -2023-08-05 14:56:30 WARN:  failed {"test":"test-backend-node-gpu.js","message":["error",["failed: insightface",{"embedding":0}]]} -2023-08-05 14:56:30 WARN:  failed {"test":"test-backend-node-wasm.js","message":["error",["failed:","testWarmup default"]]} +2023-09-18 12:45:27 INFO:  @vladmandic/human version 3.1.2 +2023-09-18 12:45:27 INFO:  User: vlado Platform: linux Arch: x64 Node: v20.6.1 +2023-09-18 12:45:27 INFO:  demos: [{"cmd":"../demo/nodejs/node.js","args":[]},{"cmd":"../demo/nodejs/node-simple.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/nodejs/process-folder.js","args":["samples"]},{"cmd":"../demo/multithread/node-multiprocess.js","args":[]},{"cmd":"../demo/facematch/node-match.js","args":[]},{"cmd":"../demo/nodejs/node-bench.js","args":[]},{"cmd":"../test/test-node-emotion.js","args":[]}] +2023-09-18 12:45:27 INFO:  {"cmd":"../demo/nodejs/node.js","args":[]} start +2023-09-18 12:45:28 INFO:  {"cmd":"../demo/nodejs/node-simple.js","args":[]} start +2023-09-18 12:45:29 INFO:  {"cmd":"../demo/nodejs/node-event.js","args":["samples/in/ai-body.jpg"]} start +2023-09-18 12:45:30 INFO:  {"cmd":"../demo/nodejs/node-similarity.js","args":["samples/in/ai-face.jpg","samples/in/ai-upper.jpg"]} start +2023-09-18 12:45:30 INFO:  {"cmd":"../demo/nodejs/node-canvas.js","args":["samples/in/ai-body.jpg","samples/out/ai-body.jpg"]} start +2023-09-18 12:45:31 INFO:  {"cmd":"../demo/nodejs/process-folder.js","args":["samples"]} start +2023-09-18 12:45:33 INFO:  {"cmd":"../demo/multithread/node-multiprocess.js","args":[]} start +2023-09-18 12:45:45 INFO:  {"cmd":"../demo/facematch/node-match.js","args":[]} start +2023-09-18 12:45:46 INFO:  {"cmd":"../demo/nodejs/node-bench.js","args":[]} start +2023-09-18 12:46:01 INFO:  {"cmd":"../test/test-node-emotion.js","args":[]} start +2023-09-18 12:46:07 INFO:  tests: ["test-node-load.js","test-node-gear.js","test-backend-node.js","test-backend-node-gpu.js","test-backend-node-wasm.js"] +2023-09-18 12:46:07 INFO:  +2023-09-18 12:46:07 INFO:  test-node-load.js start +2023-09-18 12:46:07 INFO:  test-node-load.js load start {"human":"3.1.2","tf":"4.11.0","progress":0} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":0,"progress":0} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":12,"progress":0} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":26,"progress":0.12865823126207815} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":40,"progress":0.33826045252170456} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":64,"progress":0.4726970548784964} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":77,"progress":0.68355493315821} +2023-09-18 12:46:07 STATE: test-node-load.js passed {"progress":1} +2023-09-18 12:46:07 INFO:  test-node-load.js load final {"progress":1} +2023-09-18 12:46:07 DATA:  test-node-load.js load interval {"elapsed":435,"progress":1} +2023-09-18 12:46:07 INFO:  +2023-09-18 12:46:07 INFO:  test-node-gear.js start +2023-09-18 12:46:08 DATA:  test-node-gear.js input: ["samples/in/ai-face.jpg"] +2023-09-18 12:46:09 STATE: test-node-gear.js passed: gear faceres samples/in/ai-face.jpg +2023-09-18 12:46:09 DATA:  test-node-gear.js results {"face":0,"model":"faceres","image":"samples/in/ai-face.jpg","age":23.5,"gender":"female","genderScore":0.92,"emotion":[]} +2023-09-18 12:46:09 STATE: test-node-gear.js passed: gear gear samples/in/ai-face.jpg +2023-09-18 12:46:09 DATA:  test-node-gear.js results {"face":0,"model":"gear","image":"samples/in/ai-face.jpg","age":23.3,"gender":"female","genderScore":0.51,"race":[{"score":0.93,"race":"white"}],"emotion":[]} +2023-09-18 12:46:09 STATE: test-node-gear.js passed: gear ssrnet samples/in/ai-face.jpg +2023-09-18 12:46:09 DATA:  test-node-gear.js results {"face":0,"model":"ssrnet","image":"samples/in/ai-face.jpg","age":23.4,"gender":"female","genderScore":0.99,"emotion":[]} +2023-09-18 12:46:10 STATE: test-node-gear.js passed: gear ssrnet samples/in/ai-face.jpg +2023-09-18 12:46:10 DATA:  test-node-gear.js results {"face":0,"model":"ssrnet","image":"samples/in/ai-face.jpg","age":23.4,"gender":"male","emotion":[]} +2023-09-18 12:46:10 INFO:  +2023-09-18 12:46:10 INFO:  test-backend-node.js start +2023-09-18 12:46:10 INFO:  test-backend-node.js test: configuration validation +2023-09-18 12:46:10 STATE: test-backend-node.js passed: configuration default validation [] +2023-09-18 12:46:10 STATE: test-backend-node.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] +2023-09-18 12:46:10 INFO:  test-backend-node.js test: model load +2023-09-18 12:46:10 STATE: test-backend-node.js passed: models loaded 11 11 [{"name":"blazeface","loaded":true,"size":538928,"url":"file://models/blazeface.json"},{"name":"antispoof","loaded":true,"size":853098,"url":"file://models/antispoof.json"},{"name":"liveness","loaded":true,"size":592976,"url":"file://models/liveness.json"},{"name":"emotion","loaded":true,"size":820516,"url":"file://models/emotion.json"},{"name":"facemesh","loaded":true,"size":1477958,"url":"file://models/facemesh.json"},{"name":"handskeleton","loaded":true,"size":0,"url":"file://models/handlandmark-lite.json"},{"name":"iris","loaded":true,"size":2599092,"url":"file://models/iris.json"},{"name":"handtrack","loaded":true,"size":2964837,"url":"file://models/handtrack.json"},{"name":"centernet","loaded":true,"size":4030290,"url":"file://models/centernet.json"},{"name":"movenet","loaded":true,"size":4650216,"url":"file://models/movenet-lightning.json"},{"name":"faceres","loaded":true,"size":6978814,"url":"file://models/faceres.json"}] +2023-09-18 12:46:10 INFO:  test-backend-node.js memory: {"memory":{"unreliable":true,"numTensors":1785,"numDataBuffers":1785,"numBytes":56431460}} +2023-09-18 12:46:10 INFO:  test-backend-node.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":56431460,"numTensors":1785,"numStringTensors":0,"numDataBuffers":1785,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} +2023-09-18 12:46:10 INFO:  test-backend-node.js test: warmup +2023-09-18 12:46:10 STATE: test-backend-node.js passed: create human +2023-09-18 12:46:10 INFO:  test-backend-node.js human version: 3.1.2 +2023-09-18 12:46:10 INFO:  test-backend-node.js platform: linux x64 agent: NodeJS v20.6.1 +2023-09-18 12:46:10 INFO:  test-backend-node.js tfjs version: 4.11.0 +2023-09-18 12:46:10 INFO:  test-backend-node.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v20.6.1","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"4.11.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.9.1","gpu":false},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":172} +2023-09-18 12:46:10 STATE: test-backend-node.js passed: set backend: tensorflow +2023-09-18 12:46:10 STATE: test-backend-node.js tensors 1785 +2023-09-18 12:46:10 STATE: test-backend-node.js result: defined models: 11 loaded models: 11 +2023-09-18 12:46:10 STATE: test-backend-node.js passed: load models 11 +2023-09-18 12:46:10 STATE: test-backend-node.js passed: warmup: none default +2023-09-18 12:46:10 DATA:  test-backend-node.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} +2023-09-18 12:46:10 DATA:  test-backend-node.js result: performance: load: null total: null +2023-09-18 12:46:10 STATE: test-backend-node.js passed: warmup none result match +2023-09-18 12:46:10 STATE: test-backend-node.js event: image +2023-09-18 12:46:10 STATE: test-backend-node.js event: detect +2023-09-18 12:46:10 STATE: test-backend-node.js event: warmup +2023-09-18 12:46:10 STATE: test-backend-node.js passed: warmup: face default +2023-09-18 12:46:10 DATA:  test-backend-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.42,"keypoints":4} +2023-09-18 12:46:10 DATA:  test-backend-node.js result: performance: load: null total: 420 +2023-09-18 12:46:10 STATE: test-backend-node.js passed: warmup face result match +2023-09-18 12:46:10 STATE: test-backend-node.js event: image +2023-09-18 12:46:11 STATE: test-backend-node.js event: detect +2023-09-18 12:46:11 STATE: test-backend-node.js event: warmup +2023-09-18 12:46:11 STATE: test-backend-node.js passed: warmup: body default +2023-09-18 12:46:11 DATA:  test-backend-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} +2023-09-18 12:46:11 DATA:  test-backend-node.js result: performance: load: null total: 323 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: warmup body result match +2023-09-18 12:46:11 STATE: test-backend-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":"thumb up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} +2023-09-18 12:46:11 INFO:  test-backend-node.js test: details verification +2023-09-18 12:46:11 STATE: test-backend-node.js start default +2023-09-18 12:46:11 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:11 STATE: test-backend-node.js event: image +2023-09-18 12:46:11 STATE: test-backend-node.js event: detect +2023-09-18 12:46:11 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg default +2023-09-18 12:46:11 DATA:  test-backend-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} +2023-09-18 12:46:11 DATA:  test-backend-node.js result: performance: load: null total: 311 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face length 1 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face score 1 0.93 1 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face age/gender 23.7 female 0.97 2.34 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face arrays 4 478 1024 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face anti-spoofing 0.79 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details face liveness 0.83 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details body length 1 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details body 0.92 17 6 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details hand length 1 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details hand 0.51 0.73 point +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details hand arrays 21 5 7 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details gesture length 7 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details gesture first {"face":0,"gesture":"facing right"} +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details object length 1 +2023-09-18 12:46:11 STATE: test-backend-node.js passed: details object 0.72 person +2023-09-18 12:46:11 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996928} +2023-09-18 12:46:11 STATE: test-backend-node.js event: image +2023-09-18 12:46:12 STATE: test-backend-node.js event: detect +2023-09-18 12:46:12 STATE: test-backend-node.js passed: tensor shape: [1,1200,1200,4] dtype: float32 +2023-09-18 12:46:12 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996928} +2023-09-18 12:46:12 STATE: test-backend-node.js event: image +2023-09-18 12:46:12 STATE: test-backend-node.js event: detect +2023-09-18 12:46:12 STATE: test-backend-node.js passed: tensor shape: [1200,1200,4] dtype: float32 +2023-09-18 12:46:12 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:12 STATE: test-backend-node.js event: image +2023-09-18 12:46:13 STATE: test-backend-node.js event: detect +2023-09-18 12:46:13 STATE: test-backend-node.js passed: tensor shape: [1,1200,1200,3] dtype: float32 +2023-09-18 12:46:13 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:13 STATE: test-backend-node.js event: image +2023-09-18 12:46:13 STATE: test-backend-node.js event: detect +2023-09-18 12:46:13 STATE: test-backend-node.js passed: tensor shape: [1200,1200,3] dtype: float32 +2023-09-18 12:46:13 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} +2023-09-18 12:46:13 STATE: test-backend-node.js event: image +2023-09-18 12:46:13 STATE: test-backend-node.js event: detect +2023-09-18 12:46:13 STATE: test-backend-node.js passed: tensor shape: [1,1200,1200,4] dtype: int32 +2023-09-18 12:46:13 INFO:  test-backend-node.js test default +2023-09-18 12:46:13 STATE: test-backend-node.js start async +2023-09-18 12:46:14 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:14 STATE: test-backend-node.js event: image +2023-09-18 12:46:14 STATE: test-backend-node.js event: detect +2023-09-18 12:46:14 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg async +2023-09-18 12:46:14 DATA:  test-backend-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} +2023-09-18 12:46:14 DATA:  test-backend-node.js result: performance: load: null total: 311 +2023-09-18 12:46:14 STATE: test-backend-node.js passed: default result face match 1 female 0.97 +2023-09-18 12:46:14 INFO:  test-backend-node.js test sync +2023-09-18 12:46:14 STATE: test-backend-node.js start sync +2023-09-18 12:46:14 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:14 STATE: test-backend-node.js event: image +2023-09-18 12:46:15 STATE: test-backend-node.js event: detect +2023-09-18 12:46:15 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg sync +2023-09-18 12:46:15 DATA:  test-backend-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} +2023-09-18 12:46:15 DATA:  test-backend-node.js result: performance: load: null total: 318 +2023-09-18 12:46:15 STATE: test-backend-node.js passed: default sync 1 female 0.97 +2023-09-18 12:46:15 INFO:  test-backend-node.js test: image process +2023-09-18 12:46:15 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:15 STATE: test-backend-node.js passed: image input null [1,256,256,3] +2023-09-18 12:46:15 INFO:  test-backend-node.js test: image null +2023-09-18 12:46:15 STATE: test-backend-node.js passed: invalid input could not convert input to tensor +2023-09-18 12:46:15 INFO:  test-backend-node.js test face similarity +2023-09-18 12:46:15 STATE: test-backend-node.js start face similarity +2023-09-18 12:46:15 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:15 STATE: test-backend-node.js event: image +2023-09-18 12:46:15 STATE: test-backend-node.js event: detect +2023-09-18 12:46:15 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face similarity +2023-09-18 12:46:15 DATA:  test-backend-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} +2023-09-18 12:46:15 DATA:  test-backend-node.js result: performance: load: null total: 308 +2023-09-18 12:46:15 STATE: test-backend-node.js start face similarity +2023-09-18 12:46:15 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:15 STATE: test-backend-node.js event: image +2023-09-18 12:46:15 STATE: test-backend-node.js event: detect +2023-09-18 12:46:15 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg face similarity +2023-09-18 12:46:15 DATA:  test-backend-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} +2023-09-18 12:46:15 DATA:  test-backend-node.js result: performance: load: null total: 301 +2023-09-18 12:46:15 STATE: test-backend-node.js start face similarity +2023-09-18 12:46:15 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:15 STATE: test-backend-node.js event: image +2023-09-18 12:46:16 STATE: test-backend-node.js event: detect +2023-09-18 12:46:16 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg face similarity +2023-09-18 12:46:16 DATA:  test-backend-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} +2023-09-18 12:46:16 DATA:  test-backend-node.js result: performance: load: null total: 274 +2023-09-18 12:46:16 STATE: test-backend-node.js passed: face descriptor +2023-09-18 12:46:16 STATE: test-backend-node.js passed: face similarity {"similarity":[1,0.44727441595492046,0.556793560189727],"descriptors":[1024,1024,1024]} +2023-09-18 12:46:16 INFO:  test-backend-node.js test object +2023-09-18 12:46:16 STATE: test-backend-node.js start object +2023-09-18 12:46:16 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:16 STATE: test-backend-node.js event: image +2023-09-18 12:46:16 STATE: test-backend-node.js event: detect +2023-09-18 12:46:16 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg object +2023-09-18 12:46:16 DATA:  test-backend-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} +2023-09-18 12:46:16 DATA:  test-backend-node.js result: performance: load: null total: 299 +2023-09-18 12:46:16 STATE: test-backend-node.js passed: centernet +2023-09-18 12:46:16 STATE: test-backend-node.js start object +2023-09-18 12:46:17 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:17 STATE: test-backend-node.js event: image +2023-09-18 12:46:17 STATE: test-backend-node.js event: detect +2023-09-18 12:46:17 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg object +2023-09-18 12:46:17 DATA:  test-backend-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} +2023-09-18 12:46:17 DATA:  test-backend-node.js result: performance: load: null total: 294 +2023-09-18 12:46:17 STATE: test-backend-node.js passed: nanodet +2023-09-18 12:46:17 INFO:  test-backend-node.js test sensitive +2023-09-18 12:46:17 STATE: test-backend-node.js start sensitive +2023-09-18 12:46:18 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:18 STATE: test-backend-node.js event: image +2023-09-18 12:46:18 STATE: test-backend-node.js event: detect +2023-09-18 12:46:18 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg sensitive +2023-09-18 12:46:18 DATA:  test-backend-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} +2023-09-18 12:46:18 DATA:  test-backend-node.js result: performance: load: null total: 266 +2023-09-18 12:46:18 STATE: test-backend-node.js passed: sensitive result match +2023-09-18 12:46:18 STATE: test-backend-node.js passed: sensitive face result match +2023-09-18 12:46:18 STATE: test-backend-node.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] +2023-09-18 12:46:18 STATE: test-backend-node.js passed: sensitive body result match +2023-09-18 12:46:18 STATE: test-backend-node.js passed: sensitive hand result match +2023-09-18 12:46:18 INFO:  test-backend-node.js test body +2023-09-18 12:46:18 STATE: test-backend-node.js start blazepose +2023-09-18 12:46:20 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:20 STATE: test-backend-node.js event: image +2023-09-18 12:46:20 STATE: test-backend-node.js event: detect +2023-09-18 12:46:20 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg blazepose +2023-09-18 12:46:20 DATA:  test-backend-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} +2023-09-18 12:46:20 DATA:  test-backend-node.js result: performance: load: null total: 370 +2023-09-18 12:46:20 STATE: test-backend-node.js passed: blazepose +2023-09-18 12:46:20 STATE: test-backend-node.js start efficientpose +2023-09-18 12:46:21 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:21 STATE: test-backend-node.js event: image +2023-09-18 12:46:21 STATE: test-backend-node.js event: detect +2023-09-18 12:46:21 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg efficientpose +2023-09-18 12:46:21 DATA:  test-backend-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} +2023-09-18 12:46:21 DATA:  test-backend-node.js result: performance: load: null total: 306 +2023-09-18 12:46:21 STATE: test-backend-node.js passed: efficientpose +2023-09-18 12:46:21 STATE: test-backend-node.js start posenet +2023-09-18 12:46:22 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:22 STATE: test-backend-node.js event: image +2023-09-18 12:46:22 STATE: test-backend-node.js event: detect +2023-09-18 12:46:22 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg posenet +2023-09-18 12:46:22 DATA:  test-backend-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} +2023-09-18 12:46:22 DATA:  test-backend-node.js result: performance: load: null total: 257 +2023-09-18 12:46:22 STATE: test-backend-node.js passed: posenet +2023-09-18 12:46:22 STATE: test-backend-node.js start movenet +2023-09-18 12:46:23 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:23 STATE: test-backend-node.js event: image +2023-09-18 12:46:23 STATE: test-backend-node.js event: detect +2023-09-18 12:46:23 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg movenet +2023-09-18 12:46:23 DATA:  test-backend-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} +2023-09-18 12:46:23 DATA:  test-backend-node.js result: performance: load: null total: 251 +2023-09-18 12:46:23 STATE: test-backend-node.js passed: movenet +2023-09-18 12:46:23 INFO:  test-backend-node.js test face matching +2023-09-18 12:46:23 STATE: test-backend-node.js passed: face database 40 +2023-09-18 12:46:23 STATE: test-backend-node.js passed: face match {"first":{"index":4,"similarity":0.7827852251220577}} {"second":{"index":4,"similarity":0.5002052057057577}} {"third":{"index":4,"similarity":0.5401588464054732}} +2023-09-18 12:46:23 INFO:  test-backend-node.js test face similarity alternative +2023-09-18 12:46:23 STATE: test-backend-node.js start face embeddings +2023-09-18 12:46:24 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:24 STATE: test-backend-node.js event: image +2023-09-18 12:46:24 STATE: test-backend-node.js event: detect +2023-09-18 12:46:24 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face embeddings +2023-09-18 12:46:24 DATA:  test-backend-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} +2023-09-18 12:46:24 DATA:  test-backend-node.js result: performance: load: null total: 308 +2023-09-18 12:46:24 STATE: test-backend-node.js passed: mobilefacenet {"embedding":192} +2023-09-18 12:46:24 STATE: test-backend-node.js start face embeddings +2023-09-18 12:46:25 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:25 STATE: test-backend-node.js event: image +2023-09-18 12:46:25 STATE: test-backend-node.js event: detect +2023-09-18 12:46:25 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face embeddings +2023-09-18 12:46:25 DATA:  test-backend-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} +2023-09-18 12:46:25 DATA:  test-backend-node.js result: performance: load: null total: 305 +2023-09-18 12:46:25 STATE: test-backend-node.js passed: insightface {"embedding":512} +2023-09-18 12:46:25 INFO:  test-backend-node.js test face attention +2023-09-18 12:46:25 STATE: test-backend-node.js start face attention +2023-09-18 12:46:26 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:26 STATE: test-backend-node.js event: image +2023-09-18 12:46:26 STATE: test-backend-node.js event: detect +2023-09-18 12:46:26 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg face attention +2023-09-18 12:46:26 DATA:  test-backend-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} +2023-09-18 12:46:26 DATA:  test-backend-node.js result: performance: load: null total: 284 +2023-09-18 12:46:26 STATE: test-backend-node.js passed: face attention +2023-09-18 12:46:26 INFO:  test-backend-node.js test detectors +2023-09-18 12:46:26 STATE: test-backend-node.js start detectors +2023-09-18 12:46:27 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:27 STATE: test-backend-node.js event: image +2023-09-18 12:46:27 STATE: test-backend-node.js event: detect +2023-09-18 12:46:27 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg detectors +2023-09-18 12:46:27 DATA:  test-backend-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} +2023-09-18 12:46:27 DATA:  test-backend-node.js result: performance: load: null total: 137 +2023-09-18 12:46:27 STATE: test-backend-node.js passed: detector result face match +2023-09-18 12:46:27 STATE: test-backend-node.js passed: detector result hand match +2023-09-18 12:46:27 INFO:  test-backend-node.js test: multi-instance +2023-09-18 12:46:27 STATE: test-backend-node.js start multi instance +2023-09-18 12:46:27 STATE: test-backend-node.js event: image +2023-09-18 12:46:27 STATE: test-backend-node.js event: detect +2023-09-18 12:46:27 STATE: test-backend-node.js passed: detect: random multi instance +2023-09-18 12:46:27 DATA:  test-backend-node.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} +2023-09-18 12:46:27 DATA:  test-backend-node.js result: performance: load: null total: 123 +2023-09-18 12:46:27 INFO:  test-backend-node.js test: first instance +2023-09-18 12:46:27 STATE: test-backend-node.js start multi instance +2023-09-18 12:46:27 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:27 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg multi instance +2023-09-18 12:46:27 DATA:  test-backend-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} +2023-09-18 12:46:27 DATA:  test-backend-node.js result: performance: load: null total: 139 +2023-09-18 12:46:27 INFO:  test-backend-node.js test: second instance +2023-09-18 12:46:27 STATE: test-backend-node.js start multi instance +2023-09-18 12:46:27 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:27 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg multi instance +2023-09-18 12:46:27 DATA:  test-backend-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} +2023-09-18 12:46:27 DATA:  test-backend-node.js result: performance: load: null total: 122 +2023-09-18 12:46:27 INFO:  test-backend-node.js test: concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js start concurrent +2023-09-18 12:46:27 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:27 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:27 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:28 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:28 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:28 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:28 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:28 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:28 STATE: test-backend-node.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:28 STATE: test-backend-node.js event: image +2023-09-18 12:46:28 STATE: test-backend-node.js event: image +2023-09-18 12:46:28 STATE: test-backend-node.js event: image +2023-09-18 12:46:29 STATE: test-backend-node.js event: detect +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-upper.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js event: detect +2023-09-18 12:46:29 STATE: test-backend-node.js event: detect +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-face.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 STATE: test-backend-node.js passed: detect: samples/in/ai-body.jpg concurrent +2023-09-18 12:46:29 DATA:  test-backend-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} +2023-09-18 12:46:29 DATA:  test-backend-node.js result: performance: load: null total: 1139 +2023-09-18 12:46:29 INFO:  test-backend-node.js test: monkey-patch +2023-09-18 12:46:29 STATE: test-backend-node.js event: image +2023-09-18 12:46:29 STATE: test-backend-node.js event: detect +2023-09-18 12:46:29 STATE: test-backend-node.js passed: monkey patch +2023-09-18 12:46:30 STATE: test-backend-node.js passed: segmentation [262144] +2023-09-18 12:46:30 STATE: test-backend-node.js passeed: equal usage +2023-09-18 12:46:30 INFO:  test-backend-node.js test: input compare +2023-09-18 12:46:30 STATE: test-backend-node.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:30 STATE: test-backend-node.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:30 STATE: test-backend-node.js passed: image compare 0 23.275441687091504 +2023-09-18 12:46:30 INFO:  test-backend-node.js events: {"image":29,"detect":29,"warmup":2} +2023-09-18 12:46:30 INFO:  test-backend-node.js tensors 14855 +2023-09-18 12:46:30 INFO:  test-backend-node.js test complete: 20515 ms +2023-09-18 12:46:30 INFO:  +2023-09-18 12:46:30 INFO:  test-backend-node-gpu.js start +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js test: configuration validation +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: configuration default validation [] +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js test: model load +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: models loaded 11 11 [{"name":"blazeface","loaded":true,"size":538928,"url":"file://models/blazeface.json"},{"name":"antispoof","loaded":true,"size":853098,"url":"file://models/antispoof.json"},{"name":"liveness","loaded":true,"size":592976,"url":"file://models/liveness.json"},{"name":"emotion","loaded":true,"size":820516,"url":"file://models/emotion.json"},{"name":"facemesh","loaded":true,"size":1477958,"url":"file://models/facemesh.json"},{"name":"handskeleton","loaded":true,"size":0,"url":"file://models/handlandmark-lite.json"},{"name":"iris","loaded":true,"size":2599092,"url":"file://models/iris.json"},{"name":"handtrack","loaded":true,"size":2964837,"url":"file://models/handtrack.json"},{"name":"centernet","loaded":true,"size":4030290,"url":"file://models/centernet.json"},{"name":"movenet","loaded":true,"size":4650216,"url":"file://models/movenet-lightning.json"},{"name":"faceres","loaded":true,"size":6978814,"url":"file://models/faceres.json"}] +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js memory: {"memory":{"unreliable":true,"numTensors":1785,"numDataBuffers":1785,"numBytes":56431460}} +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":56431460,"numTensors":1785,"numStringTensors":0,"numDataBuffers":1785,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js test: warmup +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: create human +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js human version: 3.1.2 +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js platform: linux x64 agent: NodeJS v20.6.1 +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js tfjs version: 4.11.0 +2023-09-18 12:46:31 INFO:  test-backend-node-gpu.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v20.6.1","backends":["cpu","tensorflow"],"initial":false,"tfjs":{"version":"4.11.0"},"offscreen":false,"perfadd":false,"tensorflow":{"version":"2.9.1","gpu":false},"wasm":{"supported":true,"backend":false},"webgl":{"supported":false,"backend":false},"webgpu":{"supported":false,"backend":false},"cpu":{"flags":[]},"kernels":172} +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: set backend: tensorflow +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js tensors 1785 +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js result: defined models: 11 loaded models: 11 +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: load models 11 +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: warmup: none default +2023-09-18 12:46:31 DATA:  test-backend-node-gpu.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} +2023-09-18 12:46:31 DATA:  test-backend-node-gpu.js result: performance: load: null total: null +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: warmup none result match +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js event: warmup +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: warmup: face default +2023-09-18 12:46:31 DATA:  test-backend-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.42,"keypoints":4} +2023-09-18 12:46:31 DATA:  test-backend-node-gpu.js result: performance: load: null total: 429 +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js passed: warmup face result match +2023-09-18 12:46:31 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js event: warmup +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: warmup: body default +2023-09-18 12:46:32 DATA:  test-backend-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} +2023-09-18 12:46:32 DATA:  test-backend-node-gpu.js result: performance: load: null total: 341 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: warmup body result match +2023-09-18 12:46:32 STATE: test-backend-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":"thumb up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} +2023-09-18 12:46:32 INFO:  test-backend-node-gpu.js test: details verification +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js start default +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg default +2023-09-18 12:46:32 DATA:  test-backend-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} +2023-09-18 12:46:32 DATA:  test-backend-node-gpu.js result: performance: load: null total: 327 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face length 1 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face score 1 0.93 1 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face age/gender 23.7 female 0.97 2.34 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face arrays 4 478 1024 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face anti-spoofing 0.79 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details face liveness 0.83 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details body length 1 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details body 0.92 17 6 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details hand length 1 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details hand 0.51 0.73 point +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details hand arrays 21 5 7 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details gesture length 7 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details gesture first {"face":0,"gesture":"facing right"} +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details object length 1 +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: details object 0.72 person +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996928} +2023-09-18 12:46:32 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: float32 +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1371996928} +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js passed: tensor shape: [1200,1200,4] dtype: float32 +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:33 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js passed: tensor shape: [1,1200,1200,3] dtype: float32 +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js passed: tensor shape: [1200,1200,3] dtype: float32 +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js passed: tensor shape: [1,1200,1200,4] dtype: int32 +2023-09-18 12:46:34 INFO:  test-backend-node-gpu.js test default +2023-09-18 12:46:34 STATE: test-backend-node-gpu.js start async +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg async +2023-09-18 12:46:35 DATA:  test-backend-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} +2023-09-18 12:46:35 DATA:  test-backend-node-gpu.js result: performance: load: null total: 317 +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js passed: default result face match 1 female 0.97 +2023-09-18 12:46:35 INFO:  test-backend-node-gpu.js test sync +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js start sync +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:35 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg sync +2023-09-18 12:46:36 DATA:  test-backend-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} +2023-09-18 12:46:36 DATA:  test-backend-node-gpu.js result: performance: load: null total: 325 +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: default sync 1 female 0.97 +2023-09-18 12:46:36 INFO:  test-backend-node-gpu.js test: image process +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: image input null [1,256,256,3] +2023-09-18 12:46:36 INFO:  test-backend-node-gpu.js test: image null +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: invalid input could not convert input to tensor +2023-09-18 12:46:36 INFO:  test-backend-node-gpu.js test face similarity +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js start face similarity +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face similarity +2023-09-18 12:46:36 DATA:  test-backend-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} +2023-09-18 12:46:36 DATA:  test-backend-node-gpu.js result: performance: load: null total: 315 +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js start face similarity +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg face similarity +2023-09-18 12:46:36 DATA:  test-backend-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} +2023-09-18 12:46:36 DATA:  test-backend-node-gpu.js result: performance: load: null total: 312 +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js start face similarity +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:36 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg face similarity +2023-09-18 12:46:37 DATA:  test-backend-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} +2023-09-18 12:46:37 DATA:  test-backend-node-gpu.js result: performance: load: null total: 281 +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js passed: face descriptor +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js passed: face similarity {"similarity":[1,0.44727441595492046,0.556793560189727],"descriptors":[1024,1024,1024]} +2023-09-18 12:46:37 INFO:  test-backend-node-gpu.js test object +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js start object +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg object +2023-09-18 12:46:37 DATA:  test-backend-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} +2023-09-18 12:46:37 DATA:  test-backend-node-gpu.js result: performance: load: null total: 304 +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js passed: centernet +2023-09-18 12:46:37 STATE: test-backend-node-gpu.js start object +2023-09-18 12:46:38 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:38 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:38 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:38 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg object +2023-09-18 12:46:38 DATA:  test-backend-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} +2023-09-18 12:46:38 DATA:  test-backend-node-gpu.js result: performance: load: null total: 297 +2023-09-18 12:46:38 STATE: test-backend-node-gpu.js passed: nanodet +2023-09-18 12:46:38 INFO:  test-backend-node-gpu.js test sensitive +2023-09-18 12:46:38 STATE: test-backend-node-gpu.js start sensitive +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg sensitive +2023-09-18 12:46:39 DATA:  test-backend-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} +2023-09-18 12:46:39 DATA:  test-backend-node-gpu.js result: performance: load: null total: 263 +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: sensitive result match +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: sensitive face result match +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: sensitive body result match +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js passed: sensitive hand result match +2023-09-18 12:46:39 INFO:  test-backend-node-gpu.js test body +2023-09-18 12:46:39 STATE: test-backend-node-gpu.js start blazepose +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg blazepose +2023-09-18 12:46:41 DATA:  test-backend-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} +2023-09-18 12:46:41 DATA:  test-backend-node-gpu.js result: performance: load: null total: 360 +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js passed: blazepose +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js start efficientpose +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:41 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:42 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:42 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg efficientpose +2023-09-18 12:46:42 DATA:  test-backend-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} +2023-09-18 12:46:42 DATA:  test-backend-node-gpu.js result: performance: load: null total: 323 +2023-09-18 12:46:42 STATE: test-backend-node-gpu.js passed: efficientpose +2023-09-18 12:46:42 STATE: test-backend-node-gpu.js start posenet +2023-09-18 12:46:42 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:42 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg posenet +2023-09-18 12:46:43 DATA:  test-backend-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} +2023-09-18 12:46:43 DATA:  test-backend-node-gpu.js result: performance: load: null total: 278 +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: posenet +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js start movenet +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg movenet +2023-09-18 12:46:43 DATA:  test-backend-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} +2023-09-18 12:46:43 DATA:  test-backend-node-gpu.js result: performance: load: null total: 256 +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: movenet +2023-09-18 12:46:43 INFO:  test-backend-node-gpu.js test face matching +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: face database 40 +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js passed: face match {"first":{"index":4,"similarity":0.7827852251220577}} {"second":{"index":4,"similarity":0.5002052057057577}} {"third":{"index":4,"similarity":0.5401588464054732}} +2023-09-18 12:46:43 INFO:  test-backend-node-gpu.js test face similarity alternative +2023-09-18 12:46:43 STATE: test-backend-node-gpu.js start face embeddings +2023-09-18 12:46:44 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:44 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:44 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:44 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings +2023-09-18 12:46:44 DATA:  test-backend-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} +2023-09-18 12:46:44 DATA:  test-backend-node-gpu.js result: performance: load: null total: 298 +2023-09-18 12:46:44 STATE: test-backend-node-gpu.js passed: mobilefacenet {"embedding":192} +2023-09-18 12:46:44 STATE: test-backend-node-gpu.js start face embeddings +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face embeddings +2023-09-18 12:46:45 DATA:  test-backend-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} +2023-09-18 12:46:45 DATA:  test-backend-node-gpu.js result: performance: load: null total: 315 +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js passed: insightface {"embedding":512} +2023-09-18 12:46:45 INFO:  test-backend-node-gpu.js test face attention +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js start face attention +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:45 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg face attention +2023-09-18 12:46:46 DATA:  test-backend-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} +2023-09-18 12:46:46 DATA:  test-backend-node-gpu.js result: performance: load: null total: 280 +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: face attention +2023-09-18 12:46:46 INFO:  test-backend-node-gpu.js test detectors +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js start detectors +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg detectors +2023-09-18 12:46:46 DATA:  test-backend-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} +2023-09-18 12:46:46 DATA:  test-backend-node-gpu.js result: performance: load: null total: 140 +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: detector result face match +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: detector result hand match +2023-09-18 12:46:46 INFO:  test-backend-node-gpu.js test: multi-instance +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js start multi instance +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: detect: random multi instance +2023-09-18 12:46:46 DATA:  test-backend-node-gpu.js result: face: 0 body: 1 hand: 0 gesture: 0 object: 0 person: 0 {} {} {"score":0,"keypoints":0} +2023-09-18 12:46:46 DATA:  test-backend-node-gpu.js result: performance: load: null total: 128 +2023-09-18 12:46:46 INFO:  test-backend-node-gpu.js test: first instance +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js start multi instance +2023-09-18 12:46:46 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance +2023-09-18 12:46:47 DATA:  test-backend-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} +2023-09-18 12:46:47 DATA:  test-backend-node-gpu.js result: performance: load: null total: 130 +2023-09-18 12:46:47 INFO:  test-backend-node-gpu.js test: second instance +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start multi instance +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg multi instance +2023-09-18 12:46:47 DATA:  test-backend-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} +2023-09-18 12:46:47 DATA:  test-backend-node-gpu.js result: performance: load: null total: 132 +2023-09-18 12:46:47 INFO:  test-backend-node-gpu.js test: concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js start concurrent +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:47 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151289024} +2023-09-18 12:46:48 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:48 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:48 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1162 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1162 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-upper.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1162 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1164 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1164 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-face.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1164 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1164 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1164 +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: detect: samples/in/ai-body.jpg concurrent +2023-09-18 12:46:49 DATA:  test-backend-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} +2023-09-18 12:46:49 DATA:  test-backend-node-gpu.js result: performance: load: null total: 1164 +2023-09-18 12:46:49 INFO:  test-backend-node-gpu.js test: monkey-patch +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js event: image +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js event: detect +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: monkey patch +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: segmentation [262144] +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passeed: equal usage +2023-09-18 12:46:49 INFO:  test-backend-node-gpu.js test: input compare +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34696120} +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1004796864} +2023-09-18 12:46:49 STATE: test-backend-node-gpu.js passed: image compare 0 23.275441687091504 +2023-09-18 12:46:49 INFO:  test-backend-node-gpu.js events: {"image":29,"detect":29,"warmup":2} +2023-09-18 12:46:49 INFO:  test-backend-node-gpu.js tensors 14855 +2023-09-18 12:46:49 INFO:  test-backend-node-gpu.js test complete: 18651 ms +2023-09-18 12:46:49 INFO:  +2023-09-18 12:46:49 INFO:  test-backend-node-wasm.js start +2023-09-18 12:46:50 DATA:  test-backend-node-wasm.js stdout: 2023-09-18 12:46:50 INFO:  { supported: true, backend: true, simd: undefined, multithread: undefined } https://cdn.jsdelivr.net/npm/@tensorflow/tfjs-backend-wasm@4.11.0/dist/ +2023-09-18 12:46:50 STATE: test-backend-node-wasm.js passed: model server: https://vladmandic.github.io/human-models/models/ +2023-09-18 12:46:50 INFO:  test-backend-node-wasm.js test: configuration validation +2023-09-18 12:46:50 STATE: test-backend-node-wasm.js passed: configuration default validation [] +2023-09-18 12:46:50 STATE: test-backend-node-wasm.js passed: configuration invalid validation [{"reason":"unknown property","where":"config.invalid = true"}] +2023-09-18 12:46:50 INFO:  test-backend-node-wasm.js test: model load +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: models loaded 11 11 [{"name":"blazeface","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/blazeface.json"},{"name":"liveness","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/liveness.json"},{"name":"emotion","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/emotion.json"},{"name":"antispoof","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/antispoof.json"},{"name":"facemesh","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/facemesh.json"},{"name":"handskeleton","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/handlandmark-lite.json"},{"name":"handtrack","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/handtrack.json"},{"name":"iris","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/iris.json"},{"name":"centernet","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/centernet.json"},{"name":"faceres","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/faceres.json"},{"name":"movenet","loaded":true,"size":0,"url":"https://vladmandic.github.io/human-models/models/movenet-lightning.json"}] +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js memory: {"memory":{"unreliable":false,"numTensors":1785,"numDataBuffers":1785,"numBytes":56431460}} +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js state: {"state":{"registeredVariables":{},"nextTapeNodeId":0,"numBytes":56431460,"numTensors":1785,"numStringTensors":0,"numDataBuffers":1785,"gradientDepth":0,"kernelDepth":0,"scopeStack":[],"numDataMovesStack":[],"nextScopeId":0,"tensorInfo":{},"profiling":false,"activeProfile":{"newBytes":0,"newTensors":0,"peakBytes":0,"kernels":[],"result":null,"kernelNames":[]}}} +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js test: warmup +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: create human +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js human version: 3.1.2 +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js platform: linux x64 agent: NodeJS v20.6.1 +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js tfjs version: 4.11.0 +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js env: {"browser":false,"node":true,"platform":"linux x64","agent":"NodeJS v20.6.1","backends":["wasm"],"initial":false,"tfjs":{"version":"4.11.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":174} +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: set backend: wasm +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js tensors 1785 +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js result: defined models: 11 loaded models: 11 +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: load models 11 +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: warmup: none default +2023-09-18 12:46:52 DATA:  test-backend-node-wasm.js result: face: 0 body: 0 hand: 0 gesture: 0 object: 0 person: 0 {} {} {} +2023-09-18 12:46:52 DATA:  test-backend-node-wasm.js result: performance: load: null total: null +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: warmup none result match +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js event: warmup +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: warmup: face default +2023-09-18 12:46:52 DATA:  test-backend-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} +2023-09-18 12:46:52 DATA:  test-backend-node-wasm.js result: performance: load: null total: 472 +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: warmup face result match +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js event: warmup +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: warmup: body default +2023-09-18 12:46:52 DATA:  test-backend-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} +2023-09-18 12:46:52 DATA:  test-backend-node-wasm.js result: performance: load: null total: 326 +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js passed: warmup body result match +2023-09-18 12:46:52 STATE: test-backend-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":"thumb up"},{"hand":0,"gesture":"open palm"},{"iris":0,"gesture":"looking left"},{"iris":0,"gesture":"looking up"}]} +2023-09-18 12:46:52 INFO:  test-backend-node-wasm.js test: details verification +2023-09-18 12:46:52 STATE: test-backend-node-wasm.js start default +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg default +2023-09-18 12:46:53 DATA:  test-backend-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} +2023-09-18 12:46:53 DATA:  test-backend-node-wasm.js result: performance: load: null total: 315 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face length 1 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face score 1 0.93 1 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face age/gender 23.7 female 0.97 2.34 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face arrays 4 478 1024 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face emotion 2 {"score":0.59,"emotion":"angry"} +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face anti-spoofing 0.79 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details face liveness 0.83 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details body length 1 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details body 0.92 17 6 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details hand length 1 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details hand 0.51 0.73 point +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details hand arrays 21 5 7 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details gesture length 7 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details gesture first {"face":0,"gesture":"facing right"} +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details object length 1 +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: details object 0.72 person +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1413675264} +2023-09-18 12:46:53 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js passed: tensor shape: [1,1200,1200,4] dtype: float32 +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1200,1200,4] {"checksum":1413675264} +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js passed: tensor shape: [1200,1200,4] dtype: float32 +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:46:54 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js passed: tensor shape: [1,1200,1200,3] dtype: float32 +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1200,1200,3] {"checksum":1038921856} +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js passed: tensor shape: [1200,1200,3] dtype: float32 +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,4] {"checksum":1371996871} +2023-09-18 12:46:55 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:56 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:56 STATE: test-backend-node-wasm.js passed: tensor shape: [1,1200,1200,4] dtype: int32 +2023-09-18 12:46:56 INFO:  test-backend-node-wasm.js test default +2023-09-18 12:46:56 STATE: test-backend-node-wasm.js start async +2023-09-18 12:46:58 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:46:58 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:46:58 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:46:58 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg async +2023-09-18 12:46:58 DATA:  test-backend-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} +2023-09-18 12:46:58 DATA:  test-backend-node-wasm.js result: performance: load: null total: 370 +2023-09-18 12:46:58 STATE: test-backend-node-wasm.js passed: default result face match 1 female 0.97 +2023-09-18 12:46:58 INFO:  test-backend-node-wasm.js test sync +2023-09-18 12:46:58 STATE: test-backend-node-wasm.js start sync +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg sync +2023-09-18 12:47:00 DATA:  test-backend-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} +2023-09-18 12:47:00 DATA:  test-backend-node-wasm.js result: performance: load: null total: 390 +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js passed: default sync 1 female 0.97 +2023-09-18 12:47:00 INFO:  test-backend-node-wasm.js test: image process +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js passed: image input null [1,256,256,3] +2023-09-18 12:47:00 INFO:  test-backend-node-wasm.js test: image null +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js passed: invalid input could not convert input to tensor +2023-09-18 12:47:00 INFO:  test-backend-node-wasm.js test face similarity +2023-09-18 12:47:00 STATE: test-backend-node-wasm.js start face similarity +2023-09-18 12:47:02 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2023-09-18 12:47:02 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:02 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:02 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-face.jpg face similarity +2023-09-18 12:47:02 DATA:  test-backend-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} +2023-09-18 12:47:02 DATA:  test-backend-node-wasm.js result: performance: load: null total: 380 +2023-09-18 12:47:02 STATE: test-backend-node-wasm.js start face similarity +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg face similarity +2023-09-18 12:47:03 DATA:  test-backend-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} +2023-09-18 12:47:03 DATA:  test-backend-node-wasm.js result: performance: load: null total: 297 +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js start face similarity +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-upper.jpg [1,720,688,3] {"checksum":151155104} +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-upper.jpg face similarity +2023-09-18 12:47:03 DATA:  test-backend-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} +2023-09-18 12:47:03 DATA:  test-backend-node-wasm.js result: performance: load: null total: 282 +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: face descriptor +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: face similarity {"similarity":[1,0.4472741837136387,0.5567931378245533],"descriptors":[1024,1024,1024]} +2023-09-18 12:47:03 INFO:  test-backend-node-wasm.js test object +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js start object +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:03 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:04 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:04 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg object +2023-09-18 12:47:04 DATA:  test-backend-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} +2023-09-18 12:47:04 DATA:  test-backend-node-wasm.js result: performance: load: null total: 302 +2023-09-18 12:47:04 STATE: test-backend-node-wasm.js passed: centernet +2023-09-18 12:47:04 STATE: test-backend-node-wasm.js start object +2023-09-18 12:47:05 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:05 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:06 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:06 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg object +2023-09-18 12:47:06 DATA:  test-backend-node-wasm.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} +2023-09-18 12:47:06 DATA:  test-backend-node-wasm.js result: performance: load: null total: 341 +2023-09-18 12:47:06 STATE: test-backend-node-wasm.js passed: nanodet +2023-09-18 12:47:06 INFO:  test-backend-node-wasm.js test sensitive +2023-09-18 12:47:06 STATE: test-backend-node-wasm.js start sensitive +2023-09-18 12:47:07 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:07 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg sensitive +2023-09-18 12:47:08 DATA:  test-backend-node-wasm.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} +2023-09-18 12:47:08 DATA:  test-backend-node-wasm.js result: performance: load: null total: 272 +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js passed: sensitive result match +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js passed: sensitive face result match +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js passed: sensitive face emotion result [{"score":0.59,"emotion":"angry"},{"score":0.29,"emotion":"fear"}] +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js passed: sensitive body result match +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js passed: sensitive hand result match +2023-09-18 12:47:08 INFO:  test-backend-node-wasm.js test body +2023-09-18 12:47:08 STATE: test-backend-node-wasm.js start blazepose +2023-09-18 12:47:11 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:11 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:11 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:11 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg blazepose +2023-09-18 12:47:11 DATA:  test-backend-node-wasm.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} +2023-09-18 12:47:11 DATA:  test-backend-node-wasm.js result: performance: load: null total: 403 +2023-09-18 12:47:11 STATE: test-backend-node-wasm.js passed: blazepose +2023-09-18 12:47:11 STATE: test-backend-node-wasm.js start efficientpose +2023-09-18 12:47:12 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:12 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:13 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:13 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg efficientpose +2023-09-18 12:47:13 DATA:  test-backend-node-wasm.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} +2023-09-18 12:47:13 DATA:  test-backend-node-wasm.js result: performance: load: null total: 622 +2023-09-18 12:47:13 STATE: test-backend-node-wasm.js passed: efficientpose +2023-09-18 12:47:13 STATE: test-backend-node-wasm.js start posenet +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg posenet +2023-09-18 12:47:14 DATA:  test-backend-node-wasm.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} +2023-09-18 12:47:14 DATA:  test-backend-node-wasm.js result: performance: load: null total: 244 +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: posenet +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js start movenet +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-body.jpg [1,1200,1200,3] {"checksum":1038921856} +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-body.jpg movenet +2023-09-18 12:47:14 DATA:  test-backend-node-wasm.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} +2023-09-18 12:47:14 DATA:  test-backend-node-wasm.js result: performance: load: null total: 203 +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: movenet +2023-09-18 12:47:14 INFO:  test-backend-node-wasm.js test face matching +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: face database 40 +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js passed: face match {"first":{"index":4,"similarity":0.7827852754786533}} {"second":{"index":4,"similarity":0.5002051178899982}} {"third":{"index":4,"similarity":0.5401586736511599}} +2023-09-18 12:47:14 INFO:  test-backend-node-wasm.js test face similarity alternative +2023-09-18 12:47:14 STATE: test-backend-node-wasm.js start face embeddings +2023-09-18 12:47:16 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2023-09-18 12:47:16 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:16 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:16 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-face.jpg face embeddings +2023-09-18 12:47:16 DATA:  test-backend-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} +2023-09-18 12:47:16 DATA:  test-backend-node-wasm.js result: performance: load: null total: 288 +2023-09-18 12:47:16 STATE: test-backend-node-wasm.js passed: mobilefacenet {"embedding":192} +2023-09-18 12:47:16 STATE: test-backend-node-wasm.js start face embeddings +2023-09-18 12:47:18 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2023-09-18 12:47:18 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:18 STATE: test-backend-node-wasm.js event: detect +2023-09-18 12:47:18 STATE: test-backend-node-wasm.js passed: detect: samples/in/ai-face.jpg face embeddings +2023-09-18 12:47:18 DATA:  test-backend-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} +2023-09-18 12:47:18 DATA:  test-backend-node-wasm.js result: performance: load: null total: 268 +2023-09-18 12:47:18 STATE: test-backend-node-wasm.js passed: insightface {"embedding":512} +2023-09-18 12:47:18 INFO:  test-backend-node-wasm.js test face attention +2023-09-18 12:47:18 STATE: test-backend-node-wasm.js start face attention +2023-09-18 12:47:19 STATE: test-backend-node-wasm.js passed: load image: samples/in/ai-face.jpg [1,256,256,3] {"checksum":34697856} +2023-09-18 12:47:19 STATE: test-backend-node-wasm.js event: image +2023-09-18 12:47:19 ERROR: test-backend-node-wasm.js failed: testDetect face attention +2023-09-18 12:47:19 ERROR: test-backend-node-wasm.js uncaughtException {"name":"Error","message":"BatchMatMul for non non-float32 tensors not yet supported.","stack":["Error: BatchMatMul for non non-float32 tensors not yet supported."," at Object.batchMatMul [as kernelFunc] (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-backend-wasm/dist/tf-backend-wasm.node.js:1280:15)"," at kernelFunc (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-core/dist/tf-core.node.js:4707:32)"," at /home/vlado/dev/human/node_modules/@tensorflow/tfjs-core/dist/tf-core.node.js:4767:27"," at Engine.scopedRun (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-core/dist/tf-core.node.js:4572:23)"," at Engine.runKernelFunc (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-core/dist/tf-core.node.js:4763:14)"," at Engine.runKernel (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-core/dist/tf-core.node.js:4636:21)"," at matMul_ (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:13408:19)"," at Object.matMul__op [as matMul] (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:12217:29)"," at executeOp$9 (/home/vlado/dev/human/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:29592:25)"," at /home/vlado/dev/human/node_modules/@tensorflow/tfjs-converter/dist/tf-converter.node.js:30172:50"]} +2023-09-18 12:47:19 STATE: all tests complete +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/node.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/node-simple.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/node-event.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/node-similarity.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/node-canvas.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/process-folder.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/multithread/node-multiprocess.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/facematch/node-match.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../demo/nodejs/node-bench.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"../test/test-node-emotion.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"test-node-load.js","passed":1,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"test-node-gear.js","passed":4,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"test-backend-node.js","passed":125,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"test-backend-node-gpu.js","passed":125,"failed":0} +2023-09-18 12:47:19 INFO:  status {"test":"test-backend-node-wasm.js","passed":92,"failed":1} +2023-09-18 12:47:19 INFO:  failures {"count":1} +2023-09-18 12:47:19 WARN:  failed {"test":"test-backend-node-wasm.js","message":["error",["failed:","testDetect face attention"]]} diff --git a/typedoc/classes/Env.html b/typedoc/classes/Env.html index 61816660..375e40fe 100644 --- a/typedoc/classes/Env.html +++ b/typedoc/classes/Env.html @@ -1,4 +1,4 @@ -Env | @vladmandic/human - v3.1.1
+Env | @vladmandic/human - v3.1.2
  • Preparing search index...
  • -
  • The search index is not available
@vladmandic/human - v3.1.1
+
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -343,7 +343,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -449,7 +449,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -558,7 +558,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -3388,7 +3388,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -249,7 +249,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -148,7 +148,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -48,7 +48,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -41,7 +41,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -43,7 +43,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -58,7 +58,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -69,7 +69,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -62,7 +62,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -48,7 +48,7 @@

    Theme

    @@ -6,12 +6,12 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    -

    @vladmandic/human - v3.1.1

    +

    @vladmandic/human - v3.1.2

    @@ -142,7 +142,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -106,7 +106,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -90,7 +90,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -98,7 +98,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -248,7 +248,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -261,7 +261,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -90,7 +90,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -90,7 +90,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -144,7 +144,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -101,7 +101,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -148,7 +148,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -98,7 +98,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -98,7 +98,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -90,7 +90,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -90,7 +90,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -98,7 +98,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -222,7 +222,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -227,7 +227,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -99,7 +99,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -58,7 +58,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -156,7 +156,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -130,7 +130,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -83,7 +83,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -114,7 +114,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -98,7 +98,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -116,7 +116,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -147,7 +147,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -110,7 +110,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -111,7 +111,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -72,7 +72,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -93,7 +93,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -174,7 +174,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -55,7 +55,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -50,7 +50,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -52,7 +52,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    AnyCanvas: HTMLCanvasElement | OffscreenCanvas
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    AnyImage: HTMLImageElement | typeof Image
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    AnyVideo: HTMLMediaElement | HTMLVideoElement
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BackendEnum: "" | "cpu" | "wasm" | "webgl" | "humangl" | "tensorflow" | "webgpu"
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyAnnotationBlazePose: "leftLeg" | "rightLeg" | "torso" | "leftArm" | "rightArm" | "leftEye" | "rightEye" | "mouth"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyAnnotationEfficientPose: "leftLeg" | "rightLeg" | "torso" | "leftArm" | "rightArm" | "head"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyGesture: `leaning ${"left" | "right"}` | `raise ${"left" | "right"} hand` | "i give up"
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyLandmarkBlazePose: "nose" | "leftEyeInside" | "leftEye" | "leftEyeOutside" | "rightEyeInside" | "rightEye" | "rightEyeOutside" | "leftEar" | "rightEar" | "leftMouth" | "rightMouth" | "leftShoulder" | "rightShoulder" | "leftElbow" | "rightElbow" | "leftWrist" | "rightWrist" | "leftPinky" | "rightPinky" | "leftIndex" | "rightIndex" | "leftThumb" | "rightThumb" | "leftHip" | "rightHip" | "leftKnee" | "rightKnee" | "leftAnkle" | "rightAnkle" | "leftHeel" | "rightHeel" | "leftFoot" | "rightFoot" | "bodyCenter" | "bodyTop" | "leftPalm" | "leftHand" | "rightPalm" | "rightHand"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyLandmarkEfficientNet: "head" | "neck" | "rightShoulder" | "rightElbow" | "rightWrist" | "chest" | "leftShoulder" | "leftElbow" | "leftWrist" | "bodyCenter" | "rightHip" | "rightKnee" | "rightAnkle" | "leftHip" | "leftKnee" | "leftAnkle"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyLandmarkMoveNet: "nose" | "leftEye" | "rightEye" | "leftEar" | "rightEar" | "leftShoulder" | "rightShoulder" | "leftElbow" | "rightElbow" | "leftWrist" | "rightWrist" | "leftHip" | "rightHip" | "leftKnee" | "rightKnee" | "leftAnkle" | "rightAnkle"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    BodyLandmarkPoseNet: "nose" | "leftEye" | "rightEye" | "leftEar" | "rightEar" | "leftShoulder" | "rightShoulder" | "leftElbow" | "rightElbow" | "leftWrist" | "rightWrist" | "leftHip" | "rightHip" | "leftKnee" | "rightKnee" | "leftAnkle" | "rightAnkle"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Box: [number, number, number, number]
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Emotion: "angry" | "disgust" | "fear" | "happy" | "sad" | "surprise" | "neutral"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Events: "create" | "load" | "image" | "result" | "warmup" | "error"
    @@ -43,7 +43,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    ExternalCanvas: typeof Canvas
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    FaceGesture: `facing ${"left" | "center" | "right"}` | `blink ${"left" | "right"} eye` | `mouth ${number}% open` | `head ${"up" | "down"}`
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    FaceLandmark: "leftEye" | "rightEye" | "nose" | "mouth" | "leftEar" | "rightEar" | "symmetryLine" | "silhouette" | "lipsUpperOuter" | "lipsLowerOuter" | "lipsUpperInner" | "lipsLowerInner" | "rightEyeUpper0" | "rightEyeLower0" | "rightEyeUpper1" | "rightEyeLower1" | "rightEyeUpper2" | "rightEyeLower2" | "rightEyeLower3" | "rightEyebrowUpper" | "rightEyebrowLower" | "rightEyeIris" | "leftEyeUpper0" | "leftEyeLower0" | "leftEyeUpper1" | "leftEyeLower1" | "leftEyeUpper2" | "leftEyeLower2" | "leftEyeLower3" | "leftEyebrowUpper" | "leftEyebrowLower" | "leftEyeIris" | "midwayBetweenEyes" | "noseTip" | "noseBottom" | "noseRightCorner" | "noseLeftCorner" | "rightCheek" | "leftCheek"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Finger: "index" | "middle" | "pinky" | "ring" | "thumb" | "palm"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    FingerCurl: "none" | "half" | "full"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    FingerDirection: "verticalUp" | "verticalDown" | "horizontalLeft" | "horizontalRight" | "diagonalUpRight" | "diagonalUpLeft" | "diagonalDownRight" | "diagonalDownLeft"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Gender: "male" | "female" | "unknown"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    GestureResult: {
        face: number;
        gesture: FaceGesture;
    } | {
        gesture: IrisGesture;
        iris: number;
    } | {
        body: number;
        gesture: BodyGesture;
    } | {
        gesture: HandGesture;
        hand: number;
    }
    @@ -41,7 +41,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    HandGesture: `${"thumb" | "index" | "middle" | "ring" | "pinky"} forward` | `${"thumb" | "index" | "middle" | "ring" | "pinky"} up` | "victory" | "thumbs up"
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    HandType: "hand" | "fist" | "pinch" | "point" | "face" | "tip" | "pinchtip"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    ImageObjects: ImageData | ImageBitmap
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    IrisGesture: "facing center" | `looking ${"left" | "right" | "up" | "down"}` | "looking center"
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    ObjectType: "person" | "bicycle" | "car" | "motorcycle" | "airplane" | "bus" | "train" | "truck" | "boat" | "traffic light" | "fire hydrant" | "stop sign" | "parking meter" | "bench" | "bird" | "cat" | "dog" | "horse" | "sheep" | "cow" | "elephant" | "bear" | "zebra" | "giraffe" | "backpack" | "umbrella" | "handbag" | "tie" | "suitcase" | "frisbee" | "skis" | "snowboard" | "sports ball" | "kite" | "baseball bat" | "baseball glove" | "skateboard" | "surfboard" | "tennis racket" | "bottle" | "wine glass" | "cup" | "fork" | "knife" | "spoon" | "bowl" | "banana" | "apple" | "sandwich" | "orange" | "broccoli" | "carrot" | "hot dog" | "pizza" | "donut" | "cake" | "chair" | "couch" | "potted plant" | "bed" | "dining table" | "toilet" | "tv" | "laptop" | "mouse" | "remote" | "keyboard" | "cell phone" | "microwave" | "oven" | "toaster" | "sink" | "refrigerator" | "book" | "clock" | "vase" | "scissors" | "teddy bear" | "hair drier" | "toothbrush"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Point: [number, number, number?]
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Race: "white" | "black" | "asian" | "indian" | "other"
    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    SegmentationEnum: "default" | "alpha" | "foreground" | "state"
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Tensor1D: Tensor<R1>
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Tensor2D: Tensor<R2>
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Tensor3D: Tensor<R3>
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    Tensor4D: Tensor<R4>
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    TensorLike: TypedArray | number | boolean | string | RecursiveArray<number | number[] | TypedArray> | RecursiveArray<boolean> | RecursiveArray<string> | Uint8Array[]
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    WarmupEnum: "" | "none" | "face" | "full" | "body"
    @@ -36,7 +36,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -35,7 +35,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    defaults: Config = ...
    @@ -38,7 +38,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    @@ -37,7 +37,7 @@

    Theme

    @@ -6,13 +6,13 @@
    • Preparing search index...
    • -
    • The search index is not available
    @vladmandic/human - v3.1.1 +
  • The search index is not available
  • @vladmandic/human - v3.1.2
    env: Env = ...