vardn=Object.create,Ge=Object.defineProperty,un=Object.getPrototypeOf,fn=Object.prototype.hasOwnProperty,ln=Object.getOwnPropertyNames,hn=Object.getOwnPropertyDescriptor;varlo=o=>Ge(o,"__esModule",{value:!0});varho=(o,t)=>()=>(t||(t={exports:{}},o(t.exports,t)),t.exports),Er=(o,t)=>{lo(o);for(vareint)Ge(o,e,{get:t[e],enumerable:!0})},Bt=(o,t,e)=>{if(lo(o),t&&typeoft=="object"||typeoft=="function")for(letrofln(t))!fn.call(o,r)&&r!=="default"&&Ge(o,r,{get:()=>t[r],enumerable:!(e=hn(t,r))||e.enumerable});returno},b=o=>o&&o.__esModule?o:Bt(Ge(o!=null?dn(un(o)):{},"default",{value:o,enumerable:!0}),o);import*asMafrom"@tensorflow/tfjs/dist/index.js";import*asCafrom"@tensorflow/tfjs-backend-wasm";varg=ho(xn=>{Bt(xn,Ma);Bt(xn,Ca)});varyo=ho((Pn,vo)=>{Er(Pn,{isNodejs:()=>_n});function_n(){returntypeofglobal=="object"&&!0&&typeofvo!="undefined"&&typeofprocess!="undefined"&&!!process.version}});varva=b(g());varQr={};Er(Qr,{AnchorPosition:()=>dt,DrawBox:()=>Xe,DrawBoxOptions:()=>Hr,DrawFaceLandmarks:()=>Kr,DrawFaceLandmarksOptions:()=>Zr,DrawTextField:()=>Mt,DrawTextFieldOptions:()=>Ne,drawContour:()=>lt,drawDetections:()=>En,drawFaceExpressions:()=>In,drawFaceLandmarks:()=>Ln});functionlt(o,t,e=!1){if(o.beginPath(),t.slice(1).forEach(({x:r,y:n},a)=>{lets=t[a];o.moveTo(s.x,s.y),o.lineTo(r,n)}),e){letr=t[t.length-1],n=t[0];if(!r||!n)return;o.moveTo(r.x,r.y),o.lineTo(n.x,n.y)}o.stroke()}varMr={};Er(Mr,{computeReshapedDimensions:()=>Ir,getCenterPoint:()=>Ot,isDimensions:()=>Ve,isEven:()=>ze,isFloat:()=>Nr,isTensor:()=>Rt,isTensor1D:()=>bn,isTensor2D:()=>Cr,isTensor3D:()=>ht,isTensor4D:()=>z,isValidNumber:()=>rt,isValidProbablitiy:()=>ee,range:()=>ct,round:()=>$t});varxo=b(g());varA=class{constructor(t,e){if(!rt(t)||!rt(e))thrownewError(`Dimensions.constructor - expected width and height to be valid numbers, instead have ${JSON.stringify({width:t,height:e})}`);this._width=t,this._height=e}getwidth(){returnthis._width}getheight(){returnthis._height}reverse(){returnnewA(1/this.width,1/this.height)}};functionRt(o,t){returnoinstanceofxo.Tensor&&o.shape.length===t}functionbn(o){returnRt(o,1)}functionCr(o){returnRt(o,2)}functionht(o){returnRt(o,3)}functionz(o){returnRt(o,4)}functionNr(o){returno%1!=0}functionze(o){returno%2==0}function$t(o,t=2){lete=10**t;returnMath.floor(o*e)/e}functionVe(o){returno&&o.width&&o.height}functionIr({width:o,height:t},e){letr=e/Math.max(t,o);returnnewA(Math.round(o*r),Math.round(t*r))}functionOt(o){returno.reduce((t,e)=>t.add(e),newx(0,0)).div(newx(o.length,o.length))}functionct(o,t,e){returnArray(o).fill(0).map((r,n)=>t+n*e)}functionrt(o){return!!o&&o!==Infinity&&o!==-Infinity&&!Number.isNaN(o)||o===0}functionee(o){returnrt(o)&&o>=0&&o<=1}varx=class{constructor(t,e){this._x=t,this._y=e}getx(){returnthis._x}gety(){returnthis._y}add(t){returnnewx(this.x+t.x,this.y+t.y)}sub(t){returnnewx(this.x-t.x,this.y-t.y)}mul(t){returnnewx(this.x*t.x,this.y*t.y)}div(t){returnnewx(this.x/t.x,this.y/t.y)}abs(){returnnewx(Math.abs(this.x),Math.abs(this.y))}magnitude(){returnMath.sqrt(this.x**2+this.y**2)}floor(){returnnewx(Math.floor(this.x),Math.floor(this.y))}};varD=class{staticisRect(t){return!!t&&[t.x,t.y,t.width,t.height].every(rt)}staticassertIsValidBox(t,e,r=!1){if(!D.isRect(t))thrownewError(`${e} - invalid box: ${JSON.stringify(t)}, expected object with properties x, y, width, height`);if(!r&&(t.width<0||t.height<0))thrownewError(`${e} - width (${t.width}) and height (${t.height}) must be positive numbers`)}constructor(t,e=!0){letr=t||{},n=[r.left,r.top,r.right,r.bottom].every(rt),a=[r.x,r.y,r.width,r.height].every(rt);if(!a&&!n)thrownewError(`Box.constructor - expected box to be IBoundingBox | IRect, instead have ${JSON.stringify(r)}`);let[s,i,c,m]=a?[r.x,r.y,r.width,r.height]:[r.left,r.top,r.right-r.left,r.bottom-r.top];D.assertIsValidBox({x:s,y:i,width:c,height:m},"Box.constructor",e),this._x=s,this._y=i,this._width=c,this._height=m}getx(){returnthis._x}gety(){returnthis._y}getwidth(){returnthis._width}getheigh