vuer 0.0.32rc8__py3-none-any.whl → 0.0.32rc23__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of vuer might be problematic. Click here for more details.
- vuer/__pycache__/events.cpython-38.pyc +0 -0
- vuer/__pycache__/server.cpython-38.pyc +0 -0
- vuer/client_build/404.html +8 -11
- vuer/client_build/assets/chunks/chunk-B5NqXhlg.js +2 -0
- vuer/client_build/assets/chunks/chunk-B5NqXhlg.js.map +1 -0
- vuer/client_build/assets/chunks/chunk-CmlEsaFt.js +6816 -0
- vuer/client_build/assets/chunks/chunk-CmlEsaFt.js.map +1 -0
- vuer/client_build/assets/chunks/chunk-DAfdqQjW.js +16 -0
- vuer/client_build/assets/chunks/chunk-DAfdqQjW.js.map +1 -0
- vuer/client_build/assets/chunks/chunk-DM5X-Fsx.js +53 -0
- vuer/client_build/assets/chunks/chunk-DM5X-Fsx.js.map +1 -0
- vuer/client_build/assets/chunks/chunk-DT-Gzcc9.js +102 -0
- vuer/client_build/assets/chunks/chunk-DT-Gzcc9.js.map +1 -0
- vuer/client_build/assets/chunks/chunk-mF18BbkE.js +3 -0
- vuer/client_build/assets/chunks/chunk-mF18BbkE.js.map +1 -0
- vuer/client_build/assets/entries/entry-client-routing.DcliWhPk.js +5 -0
- vuer/client_build/assets/entries/entry-client-routing.DcliWhPk.js.map +1 -0
- vuer/client_build/assets/entries/pages_editor.dxxI6p1y.js +2 -0
- vuer/client_build/assets/entries/pages_editor.dxxI6p1y.js.map +1 -0
- vuer/client_build/assets/entries/pages_error.CLFwp4P1.js +2 -0
- vuer/client_build/assets/entries/pages_error.CLFwp4P1.js.map +1 -0
- vuer/client_build/assets/entries/pages_index.cBvCoMtg.js +2 -0
- vuer/client_build/assets/entries/pages_index.cBvCoMtg.js.map +1 -0
- vuer/client_build/assets/entries/pages_simple.DNtn6Zih.js +2 -0
- vuer/client_build/assets/entries/pages_simple.DNtn6Zih.js.map +1 -0
- vuer/client_build/assets/static/editor.e6iYOnjc.css +1 -0
- vuer/client_build/assets/static/index.CdgWIjKL.css +1 -0
- vuer/client_build/assets/static/logo.2_7Lo9tV.svg +36 -0
- vuer/client_build/assets/static/onRenderClient.DQ-loHhw.css +1 -0
- vuer/client_build/editor/index.html +17 -0
- vuer/client_build/editor/index.pageContext.json +1 -0
- vuer/client_build/index.html +10 -13
- vuer/client_build/index.pageContext.json +1 -1
- vuer/client_build/pages/_error/+Page.d.ts +2 -0
- vuer/client_build/pages/editor/+Page.d.ts +1 -0
- vuer/client_build/pages/index/+Page.d.ts +2 -0
- vuer/client_build/pages/simple/+Page.d.ts +1 -0
- vuer/client_build/renderer/+config.d.ts +45 -0
- vuer/client_build/renderer/+onHydrationEnd.d.ts +3 -0
- vuer/client_build/renderer/+onPageTransitionEnd.d.ts +3 -0
- vuer/client_build/renderer/+onPageTransitionStart.d.ts +3 -0
- vuer/client_build/renderer/+onRenderClient.d.ts +2 -0
- vuer/client_build/renderer/+onRenderHtml.d.ts +2 -0
- vuer/client_build/renderer/Layout.d.ts +6 -0
- vuer/client_build/renderer/Link.d.ts +7 -0
- vuer/client_build/renderer/PageContext.d.ts +19 -0
- vuer/client_build/renderer/getPageTitle.d.ts +3 -0
- vuer/client_build/renderer/useData.d.ts +2 -0
- vuer/client_build/renderer/usePageContext.d.ts +9 -0
- vuer/client_build/simple/index.html +16 -0
- vuer/client_build/simple/index.pageContext.json +1 -0
- vuer/events.py +25 -7
- vuer/schemas/__init__.py +1 -0
- vuer/schemas/__pycache__/__init__.cpython-38.pyc +0 -0
- vuer/schemas/__pycache__/physics_components.cpython-38.pyc +0 -0
- vuer/schemas/__pycache__/scene_components.cpython-38.pyc +0 -0
- vuer/schemas/physics_components.py +19 -0
- vuer/schemas/scene_components.py +3 -3
- vuer/schemas/timeline_components.py +0 -0
- {vuer-0.0.32rc8.dist-info → vuer-0.0.32rc23.dist-info}/METADATA +16 -1
- {vuer-0.0.32rc8.dist-info → vuer-0.0.32rc23.dist-info}/RECORD +65 -16
- {vuer-0.0.32rc8.dist-info → vuer-0.0.32rc23.dist-info}/LICENSE +0 -0
- {vuer-0.0.32rc8.dist-info → vuer-0.0.32rc23.dist-info}/WHEEL +0 -0
- {vuer-0.0.32rc8.dist-info → vuer-0.0.32rc23.dist-info}/entry_points.txt +0 -0
- {vuer-0.0.32rc8.dist-info → vuer-0.0.32rc23.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
var sr=typeof self<"u"?self:{};function Ir(t,e){t:{for(var r=["CLOSURE_FLAGS"],n=sr,s=0;s<r.length;s++)if((n=n[r[s]])==null){r=null;break t}r=n}return(t=r&&r[t])!=null?t:e}function Xt(){throw Error("Invalid UTF8")}function Hn(t,e){return e=String.fromCharCode.apply(null,e),t==null?e:t+e}let Re,kr;const t1=typeof TextDecoder<"u";let e1;const r1=typeof TextEncoder<"u";function Gs(t){if(r1)t=(e1||(e1=new TextEncoder)).encode(t);else{let r=0;const n=new Uint8Array(3*t.length);for(let s=0;s<t.length;s++){var e=t.charCodeAt(s);if(128>e)n[r++]=e;else{if(2048>e)n[r++]=e>>6|192;else{if(55296<=e&&57343>=e){if(56319>=e&&s<t.length){const i=t.charCodeAt(++s);if(56320<=i&&57343>=i){e=1024*(e-55296)+i-56320+65536,n[r++]=e>>18|240,n[r++]=e>>12&63|128,n[r++]=e>>6&63|128,n[r++]=63&e|128;continue}s--}e=65533}n[r++]=e>>12|224,n[r++]=e>>6&63|128}n[r++]=63&e|128}}t=r===n.length?n:n.subarray(0,r)}return t}var ye,js=Ir(610401301,!1),tn=Ir(572417392,Ir(1,!0));const Xn=sr.navigator;function Rr(t){return!!js&&!!ye&&ye.brands.some(({brand:e})=>e&&e.indexOf(t)!=-1)}function ct(t){var e;return(e=sr.navigator)&&(e=e.userAgent)||(e=""),e.indexOf(t)!=-1}function Ut(){return!!js&&!!ye&&0<ye.brands.length}function Sr(){return Ut()?Rr("Chromium"):(ct("Chrome")||ct("CriOS"))&&!(!Ut()&&ct("Edge"))||ct("Silk")}ye=Xn&&Xn.userAgentData||null;var n1=!Ut()&&(ct("Trident")||ct("MSIE"));!ct("Android")||Sr(),Sr(),ct("Safari")&&(Sr()||!Ut()&&ct("Coast")||!Ut()&&ct("Opera")||!Ut()&&ct("Edge")||(Ut()?Rr("Microsoft Edge"):ct("Edg/"))||Ut()&&Rr("Opera"));var Vs={},fe=null;function s1(t){var e=t.length,r=3*e/4;r%3?r=Math.floor(r):"=.".indexOf(t[e-1])!=-1&&(r="=.".indexOf(t[e-2])!=-1?r-2:r-1);var n=new Uint8Array(r),s=0;return function(i,o){function c(Bt){for(;a<i.length;){var G=i.charAt(a++),X=fe[G];if(X!=null)return X;if(!/^[\s\xa0]*$/.test(G))throw Error("Unknown base64 encoding at char: "+G)}return Bt}zs();for(var a=0;;){var h=c(-1),u=c(0),m=c(64),O=c(64);if(O===64&&h===-1)break;o(h<<2|u>>4),m!=64&&(o(u<<4&240|m>>2),O!=64&&o(m<<6&192|O))}}(t,function(i){n[s++]=i}),s!==r?n.subarray(0,s):n}function zs(){if(!fe){fe={};for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),e=["+/=","+/","-_=","-_.","-_"],r=0;5>r;r++){var n=t.concat(e[r].split(""));Vs[r]=n;for(var s=0;s<n.length;s++){var i=n[s];fe[i]===void 0&&(fe[i]=s)}}}}var Ws=typeof Uint8Array<"u",Hs=!n1&&typeof btoa=="function";function Kn(t){if(!Hs){var e;e===void 0&&(e=0),zs(),e=Vs[e];var r=Array(Math.floor(t.length/3)),n=e[64]||"";let a=0,h=0;for(;a<t.length-2;a+=3){var s=t[a],i=t[a+1],o=t[a+2],c=e[s>>2];s=e[(3&s)<<4|i>>4],i=e[(15&i)<<2|o>>6],o=e[63&o],r[h++]=c+s+i+o}switch(c=0,o=n,t.length-a){case 2:o=e[(15&(c=t[a+1]))<<2]||n;case 1:t=t[a],r[h]=e[t>>2]+e[(3&t)<<4|c>>4]+o+n}return r.join("")}for(e="",r=0,n=t.length-10240;r<n;)e+=String.fromCharCode.apply(null,t.subarray(r,r+=10240));return e+=String.fromCharCode.apply(null,r?t.subarray(r):t),btoa(e)}const $n=/[-_.]/g,i1={"-":"+",_:"/",".":"="};function o1(t){return i1[t]||""}function Xs(t){if(!Hs)return s1(t);$n.test(t)&&(t=t.replace($n,o1)),t=atob(t);const e=new Uint8Array(t.length);for(let r=0;r<t.length;r++)e[r]=t.charCodeAt(r);return e}function ir(t){return Ws&&t!=null&&t instanceof Uint8Array}let a1;function or(){return a1||(a1=new Uint8Array(0))}var ee={};let c1;function Ks(t){if(t!==ee)throw Error("illegal external caller")}function re(){return c1||(c1=new Nt(null,ee))}function en(t){Ks(ee);var e=t.T;return(e=e==null||ir(e)?e:typeof e=="string"?Xs(e):null)==null?e:t.T=e}var Nt=class{constructor(t,e){if(Ks(e),this.T=t,t!=null&&t.length===0)throw Error("ByteString should be constructed with non-empty values")}qa(){const t=en(this);return t?new Uint8Array(t):or()}};function $s(t,e){return Error(`Invalid wire type: ${t} (at position ${e})`)}function rn(){return Error("Failed to read varint, encoding is invalid.")}function qs(t,e){return Error(`Tried to read past the end of the data ${e} > ${t}`)}function Ys(t){return t.length==0?re():new Nt(t,ee)}function nn(t){if(typeof t=="string")return{buffer:Xs(t),H:!1};if(Array.isArray(t))return{buffer:new Uint8Array(t),H:!1};if(t.constructor===Uint8Array)return{buffer:t,H:!1};if(t.constructor===ArrayBuffer)return{buffer:new Uint8Array(t),H:!1};if(t.constructor===Nt)return{buffer:en(t)||or(),H:!0};if(t instanceof Uint8Array)return{buffer:new Uint8Array(t.buffer,t.byteOffset,t.byteLength),H:!1};throw Error("Type not convertible to a Uint8Array, expected a Uint8Array, an ArrayBuffer, a base64 encoded string, a ByteString or an Array of numbers")}function sn(){return typeof BigInt=="function"}var Cr=!tn;let qn=!tn;const h1=typeof Uint8Array.prototype.slice=="function";let Js,P=0,W=0;function ar(t){const e=0>t;let r=(t=Math.abs(t))>>>0;if(t=Math.floor((t-r)/4294967296),e){const[n,s]=an(r,t);t=s,r=n}P=r>>>0,W=t>>>0}function on(t){const e=Js||(Js=new DataView(new ArrayBuffer(8)));e.setFloat32(0,+t,!0),W=0,P=e.getUint32(0,!0)}function Zs(t,e){return 4294967296*e+(t>>>0)}function Qs(t,e){const r=2147483648&e;return r&&(e=~e>>>0,(t=1+~t>>>0)==0&&(e=e+1>>>0)),t=Zs(t,e),r?-t:t}function Br(t,e){if(t>>>=0,2097151>=(e>>>=0))var r=""+(4294967296*e+t);else sn()?r=""+(BigInt(e)<<BigInt(32)|BigInt(t)):(t=(16777215&t)+6777216*(r=16777215&(t>>>24|e<<8))+6710656*(e=e>>16&65535),r+=8147497*e,e*=2,1e7<=t&&(r+=Math.floor(t/1e7),t%=1e7),1e7<=r&&(e+=Math.floor(r/1e7),r%=1e7),r=e+Yn(r)+Yn(t));return r}function Yn(t){return t=String(t),"0000000".slice(t.length)+t}function ti(){var t=P,e=W;if(2147483648&e)if(sn())t=""+(BigInt(0|e)<<BigInt(32)|BigInt(t>>>0));else{const[r,n]=an(t,e);t="-"+Br(r,n)}else t=Br(t,e);return t}function cr(t){if(16>t.length)ar(Number(t));else if(sn())t=BigInt(t),P=Number(t&BigInt(4294967295))>>>0,W=Number(t>>BigInt(32)&BigInt(4294967295));else{const e=+(t[0]==="-");W=P=0;const r=t.length;for(let n=e,s=(r-e)%6+e;s<=r;n=s,s+=6){const i=Number(t.slice(n,s));W*=1e6,P=1e6*P+i,4294967296<=P&&(W+=Math.trunc(P/4294967296),W>>>=0,P>>>=0)}if(e){const[n,s]=an(P,W);P=n,W=s}}}function an(t,e){return e=~e,t?t=1+~t:e+=1,[t,e]}function Dr(t,e,{W:r=!1}={}){t.W=r,e&&(e=nn(e),t.h=e.buffer,t.u=e.H,t.v=0,t.l=t.h.length,t.g=t.v)}function $t(t,e){if(t.g=e,e>t.l)throw qs(t.l,e)}function cn(t,e){let r,n=0,s=0,i=0;const o=t.h;let c=t.g;do r=o[c++],n|=(127&r)<<i,i+=7;while(32>i&&128&r);for(32<i&&(s|=(127&r)>>4),i=3;32>i&&128&r;i+=7)r=o[c++],s|=(127&r)<<i;if($t(t,c),128>r)return e(n>>>0,s>>>0);throw rn()}function hn(t){let e=0,r=t.g;const n=r+10,s=t.h;for(;r<n;){const i=s[r++];if(e|=i,(128&i)==0)return $t(t,r),!!(127&e)}throw rn()}function Ur(t){var e=t.h;const r=t.g,n=e[r],s=e[r+1],i=e[r+2];return e=e[r+3],$t(t,t.g+4),(n<<0|s<<8|i<<16|e<<24)>>>0}function ei(t,e){if(0>e)throw Error(`Tried to read a negative byte length: ${e}`);const r=t.g,n=r+e;if(n>t.l)throw qs(e,t.l-r);return t.g=n,r}function ri(t,e){if(e==0)return re();var r=ei(t,e);return t.W&&t.u?r=t.h.subarray(r,r+e):(t=t.h,r=r===(e=r+e)?or():h1?t.slice(r,e):new Uint8Array(t.subarray(r,e))),Ys(r)}var ke=class{constructor(t,e){this.h=null,this.u=!1,this.g=this.l=this.v=0,Dr(this,t,e)}clear(){this.h=null,this.u=!1,this.g=this.l=this.v=0,this.W=!1}m(){const t=this.h;let e=this.g,r=t[e++],n=127&r;if(128&r&&(r=t[e++],n|=(127&r)<<7,128&r&&(r=t[e++],n|=(127&r)<<14,128&r&&(r=t[e++],n|=(127&r)<<21,128&r&&(r=t[e++],n|=r<<28,128&r&&128&t[e++]&&128&t[e++]&&128&t[e++]&&128&t[e++]&&128&t[e++])))))throw rn();return $t(this,e),n}j(){return this.m()>>>0}B(){var t=Ur(this);const e=2*(t>>31)+1,r=t>>>23&255;return t&=8388607,r==255?t?NaN:1/0*e:r==0?e*Math.pow(2,-149)*t:e*Math.pow(2,r-150)*(t+Math.pow(2,23))}C(){return this.m()}},Jn=[];function ni(t){var e=t.g;if(e.g==e.l)return!1;t.l=t.g.g;var r=t.g.j();if(e=r>>>3,!(0<=(r&=7)&&5>=r))throw $s(r,t.l);if(1>e)throw Error(`Invalid field number: ${e} (at position ${t.l})`);return t.m=e,t.h=r,!0}function Ge(t){switch(t.h){case 0:t.h!=0?Ge(t):hn(t.g);break;case 1:$t(t=t.g,t.g+8);break;case 2:if(t.h!=2)Ge(t);else{var e=t.g.j();$t(t=t.g,t.g+e)}break;case 5:$t(t=t.g,t.g+4);break;case 3:for(e=t.m;;){if(!ni(t))throw Error("Unmatched start-group tag: stream EOF");if(t.h==4){if(t.m!=e)throw Error("Unmatched end-group tag");break}Ge(t)}break;default:throw $s(t.h,t.l)}}function Se(t,e,r){const n=t.g.l,s=t.g.j(),i=t.g.g+s;let o=i-n;if(0>=o&&(t.g.l=i,r(e,t,void 0,void 0,void 0),o=i-t.g.g),o)throw Error(`Message parsing ended unexpectedly. Expected to read ${s} bytes, instead read ${s-o} bytes, either the data ended unexpectedly or the message misreported its own length`);return t.g.g=i,t.g.l=n,e}function un(t){var e=t.g.j(),r=ei(t=t.g,e);if(t=t.h,t1){var n,s=t;(n=kr)||(n=kr=new TextDecoder("utf-8",{fatal:!0})),t=r+e,s=r===0&&t===s.length?s:s.subarray(r,t);try{var i=n.decode(s)}catch(c){if(Re===void 0){try{n.decode(new Uint8Array([128]))}catch{}try{n.decode(new Uint8Array([97])),Re=!0}catch{Re=!1}}throw!Re&&(kr=void 0),c}}else{e=(i=r)+e,r=[];let c,a=null;for(;i<e;){var o=t[i++];128>o?r.push(o):224>o?i>=e?Xt():(c=t[i++],194>o||(192&c)!=128?(i--,Xt()):r.push((31&o)<<6|63&c)):240>o?i>=e-1?Xt():(c=t[i++],(192&c)!=128||o===224&&160>c||o===237&&160<=c||(192&(s=t[i++]))!=128?(i--,Xt()):r.push((15&o)<<12|(63&c)<<6|63&s)):244>=o?i>=e-2?Xt():(c=t[i++],(192&c)!=128||c-144+(o<<28)>>30||(192&(s=t[i++]))!=128||(192&(n=t[i++]))!=128?(i--,Xt()):(o=(7&o)<<18|(63&c)<<12|(63&s)<<6|63&n,o-=65536,r.push(55296+(o>>10&1023),56320+(1023&o)))):Xt(),8192<=r.length&&(a=Hn(a,r),r.length=0)}i=Hn(a,r)}return i}function si(t){const e=t.g.j();return ri(t.g,e)}function hr(t,e,r){var n=t.g.j();for(n=t.g.g+n;t.g.g<n;)r.push(e.call(t.g))}var Ce=[];function Zn(t){return t?/^\d+$/.test(t)?(cr(t),new Qn(P,W)):null:u1||(u1=new Qn(0,0))}var Qn=class{constructor(t,e){this.h=t>>>0,this.g=e>>>0}};let u1;function ts(t){return t?/^-?\d+$/.test(t)?(cr(t),new es(P,W)):null:l1||(l1=new es(0,0))}var es=class{constructor(t,e){this.h=t>>>0,this.g=e>>>0}};let l1;function qe(t,e,r){for(;0<r||127<e;)t.g.push(127&e|128),e=(e>>>7|r<<25)>>>0,r>>>=7;t.g.push(e)}function xe(t,e){for(;127<e;)t.g.push(127&e|128),e>>>=7;t.g.push(e)}function ur(t,e){if(0<=e)xe(t,e);else{for(let r=0;9>r;r++)t.g.push(127&e|128),e>>=7;t.g.push(1)}}function _e(t,e){t.g.push(e>>>0&255),t.g.push(e>>>8&255),t.g.push(e>>>16&255),t.g.push(e>>>24&255)}function ne(t,e){e.length!==0&&(t.l.push(e),t.h+=e.length)}function pt(t,e,r){xe(t.g,8*e+r)}function ln(t,e){return pt(t,e,2),e=t.g.end(),ne(t,e),e.push(t.h),e}function fn(t,e){var r=e.pop();for(r=t.h+t.g.length()-r;127<r;)e.push(127&r|128),r>>>=7,t.h++;e.push(r),t.h++}function lr(t,e,r){pt(t,e,2),xe(t.g,r.length),ne(t,t.g.end()),ne(t,r)}function Nr(t,e,r,n){r!=null&&(e=ln(t,e),n(r,t),fn(t,e))}class ae{constructor(e,r,n,s){this.g=e,this.h=r,this.l=n,this.la=s}}function Y(t){return Array.prototype.slice.call(t)}const kt=typeof Symbol=="function"&&typeof Symbol()=="symbol"?Symbol():void 0;var fr=kt?(t,e)=>{t[kt]|=e}:(t,e)=>{t.D!==void 0?t.D|=e:Object.defineProperties(t,{D:{value:e,configurable:!0,writable:!0,enumerable:!1}})};function rs(t){const e=L(t);(1&e)!=1&&(Object.isFrozen(t)&&(t=Y(t)),C(t,1|e))}var Ye=kt?(t,e)=>{t[kt]&=~e}:(t,e)=>{t.D!==void 0&&(t.D&=~e)};function z(t,e,r){return r?t|e:t&~e}var L=kt?t=>0|t[kt]:t=>0|t.D,_=kt?t=>t[kt]:t=>t.D,C=kt?(t,e)=>{t[kt]=e}:(t,e)=>{t.D!==void 0?t.D=e:Object.defineProperties(t,{D:{value:e,configurable:!0,writable:!0,enumerable:!1}})};function ns(){var t=[];return fr(t,1),t}function ce(t){return fr(t,34),t}function f1(t,e){C(e,-14591&(0|t))}function Gr(t,e){C(e,-14557&(34|t))}function Je(t){return(t=t>>14&1023)===0?536870912:t}var Fe={},ii={};function ss(t){return!(!t||typeof t!="object"||t.Ia!==ii)}function pe(t){return t!==null&&typeof t=="object"&&!Array.isArray(t)&&t.constructor===Object}let oi=!tn;function ai(t,e,r){if(t!=null){if(typeof t=="string")t=t?new Nt(t,ee):re();else if(t.constructor!==Nt)if(ir(t))t=r?Ys(t):t.length?new Nt(new Uint8Array(t),ee):re();else{if(!e)throw Error();t=void 0}}return t}function jr(t,e,r){if(!Array.isArray(t)||t.length)return!1;const n=L(t);return!!(1&n)||!(!e||!(Array.isArray(e)?e.includes(r):e.has(r)))&&(C(t,1|n),!0)}var Qt;const is=[];function Lt(t){if(2&t)throw Error()}C(is,55),Qt=Object.freeze(is);class Ze{constructor(e,r,n){this.l=0,this.g=e,this.h=r,this.m=n}next(){if(this.l<this.g.length){const e=this.g[this.l++];return{done:!1,value:this.h?this.h.call(this.m,e):e}}return{done:!0,value:void 0}}[Symbol.iterator](){return new Ze(this.g,this.h,this.m)}}var d1={};let Gt,ve;function ci(t,e){(e=Gt?e[Gt]:void 0)&&(t[Gt]=Y(e))}function hi(t,e){t.__closure__error__context__984382||(t.__closure__error__context__984382={}),t.__closure__error__context__984382.severity=e}function ui(t){return hi(t=Error(t),"warning"),t}function zt(t){return t==null?t:typeof t=="number"||t==="NaN"||t==="Infinity"||t==="-Infinity"?Number(t):void 0}function li(t){return t==null?t:typeof t=="boolean"||typeof t=="number"?!!t:void 0}const p1=/^-?([1-9][0-9]*|0)(\.[0-9]+)?$/;function dr(t){const e=typeof t;return e==="number"?Number.isFinite(t):e==="string"&&p1.test(t)}function he(t){if(t==null)return t;if(typeof t=="string"){if(!t)return;t=+t}return typeof t=="number"?t:void 0}function g1(t){if(t==null)return t;if(typeof t=="string"){if(!t)return;t=+t}return typeof t=="number"?t:void 0}function dn(t){return Math.trunc(t)}function pn(t,e){var r=Math.trunc(Number(t));return Number.isSafeInteger(r)?String(r):((r=t.indexOf("."))!==-1&&(t=t.substring(0,r)),e&&(cr(t),t=ti()),t)}function Qe(t){return t==null?t:dr(t)?typeof t=="number"?dn(t):pn(t,!1):void 0}function Le(t){if(typeof t!="string")throw Error();return t}function Oe(t){if(t!=null&&typeof t!="string")throw Error();return t}function we(t){return t==null||typeof t=="string"?t:void 0}function gn(t,e,r,n){if(t!=null&&typeof t=="object"&&t.P===Fe)return t;if(!Array.isArray(t))return r?2&n?(t=e[os])?e=t:(ce((t=new e).s),e=e[os]=t):e=new e:e=void 0,e;let s=r=L(t);return s===0&&(s|=32&n),s|=2&n,s!==r&&C(t,s),new e(t)}const os=typeof Symbol=="function"&&typeof Symbol()=="symbol"?Symbol():"di";function Be(t){return t}function m1(t,e,r){if(e){var n=!!n;if(!dr(e=t))throw ui("int64");typeof e=="string"?n=pn(e,n):n?(e=Math.trunc(e),!n||Number.isSafeInteger(e)?n=String(e):(ar(e),n=ti())):n=dn(e)}else n=Qe(t);return typeof(r=(t=n)==null?r?0:void 0:t)=="string"&&(n=+r,Number.isSafeInteger(n))?n:r}let tr,mn,y1;function er(t){switch(typeof t){case"boolean":return mn||(mn=[0,void 0,!0]);case"number":return 0<t?void 0:t===0?y1||(y1=[0,void 0]):[-t,void 0];case"string":return[0,t];case"object":return t}}function qt(t,e){return fi(t,e[0],e[1])}function fi(t,e,r){if(t==null&&(t=tr),tr=void 0,t==null){var n=96;r?(t=[r],n|=512):t=[],e&&(n=-16760833&n|(1023&e)<<14)}else{if(!Array.isArray(t))throw Error();if(64&(n=L(t)))return ve&&delete t[ve],t;if(n|=64,r&&(n|=512,r!==t[0]))throw Error();t:{if(r=n,n=t.length){const s=n-1;if(pe(t[s])){if(1024<=(e=s-(+!!(512&(r|=256))-1)))throw Error();n=-16760833&r|(1023&e)<<14;break t}}if(e){if(1024<(e=Math.max(e,n-(+!!(512&r)-1))))throw Error();n=-16760833&r|(1023&e)<<14}else n=r}}return C(t,n),t}let _1=function(){try{return new class extends Map{constructor(){super()}},!1}catch{return!0}}();class xr{constructor(){this.g=new Map}get(e){return this.g.get(e)}set(e,r){return this.g.set(e,r),this.size=this.g.size,this}delete(e){return e=this.g.delete(e),this.size=this.g.size,e}clear(){this.g.clear(),this.size=this.g.size}has(e){return this.g.has(e)}entries(){return this.g.entries()}keys(){return this.g.keys()}values(){return this.g.values()}forEach(e,r){return this.g.forEach(e,r)}[Symbol.iterator](){return this.entries()}}const v1=_1?(Object.setPrototypeOf(xr.prototype,Map.prototype),Object.defineProperties(xr.prototype,{size:{value:0,configurable:!0,enumerable:!0,writable:!0}}),xr):class extends Map{constructor(){super()}};function Fr(t){if(2&t.I)throw Error("Cannot mutate an immutable Map")}var lt=class extends v1{constructor(t,e,r=Be,n=Be){super();let s=L(t);s|=64,C(t,s),this.I=s,this.O=e,this.J=r||Be,this.S=this.O?w1:n||Be;for(let i=0;i<t.length;i++){const o=t[i],c=r(o[0],!1,!0);let a=o[1];e?a===void 0&&(a=null):a=n(o[1],!1,!0,void 0,void 0,s),super.set(c,a)}}ka(t=as){return this.R(t)}R(t=as){const e=[],r=super.entries();for(var n;!(n=r.next()).done;)(n=n.value)[0]=t(n[0]),n[1]=t(n[1]),e.push(n);return e}clear(){Fr(this),super.clear()}delete(t){return Fr(this),super.delete(this.J(t,!0,!1))}entries(){var t=this.ha();return new Ze(t,b1,this)}keys(){return this.Ha()}values(){var t=this.ha();return new Ze(t,lt.prototype.get,this)}forEach(t,e){super.forEach((r,n)=>{t.call(e,this.get(n),n,this)})}set(t,e){return Fr(this),(t=this.J(t,!0,!1))==null?this:e==null?(super.delete(t),this):super.set(t,this.S(e,!0,!0,this.O,!1,this.I))}Oa(t){const e=this.J(t[0],!1,!0);t=t[1],t=this.O?t===void 0?null:t:this.S(t,!1,!0,void 0,!1,this.I),super.set(e,t)}has(t){return super.has(this.J(t,!1,!1))}get(t){t=this.J(t,!1,!1);const e=super.get(t);if(e!==void 0){var r=this.O;return r?((r=this.S(e,!1,!0,r,this.ra,this.I))!==e&&super.set(t,r),r):e}}ha(){return Array.from(super.keys())}Ha(){return super.keys()}[Symbol.iterator](){return this.entries()}};function w1(t,e,r,n,s,i){return t=gn(t,n,r,i),s&&(t=pr(t)),t}function as(t){return t}function b1(t){return[t,this.get(t)]}function yn(t,e,r,n,s,i){if(t!=null){if(Array.isArray(t))t=i&&2&L(t)?t:_n(t,e,r,n!==void 0,s,i);else if(pe(t)){const o={};for(let c in t)o[c]=yn(t[c],e,r,n,s,i);t=o}else t=e(t,n);return t}}function _n(t,e,r,n,s,i){const o=n||r?L(t):0;n=n?!!(32&o):void 0;const c=Y(t);for(let a=0;a<c.length;a++)c[a]=yn(c[a],e,r,n,s,i);return r&&(ci(c,t),r(o,c)),c}function E1(t){return yn(t,di,void 0,void 0,!1,!1)}function di(t){return t.P===Fe?t.toJSON():t instanceof lt?t.ka(E1):function(e){switch(typeof e){case"number":return isFinite(e)?e:String(e);case"boolean":return e?1:0;case"object":if(e){if(Array.isArray(e))return oi||!jr(e,void 0,9999)?e:void 0;if(ir(e))return Kn(e);if(e instanceof Nt){const r=e.T;return r==null?"":typeof r=="string"?r:e.T=Kn(r)}if(e instanceof lt)return e=e.ka(),Cr||e.length!==0?e:void 0}}return e}(t)}function Vr(t,e,r=Gr){if(t!=null){if(Ws&&t instanceof Uint8Array)return e?t:new Uint8Array(t);if(Array.isArray(t)){var n=L(t);return 2&n?t:(e&&(e=n===0||!!(32&n)&&!(64&n||!(16&n))),e?(C(t,-12293&(34|n)),t):_n(t,Vr,4&n?Gr:r,!0,!1,!0))}return t.P===Fe?(r=t.s,t=2&(n=_(r))?t:vn(t,r,n,!0)):t instanceof lt&&(r=ce(t.R(Vr)),t=new lt(r,t.O,t.J,t.S)),t}}function vn(t,e,r,n){return t=t.constructor,tr=e=pi(e,r,n),e=new t(e),tr=void 0,e}function pi(t,e,r){const n=r||2&e?Gr:f1,s=!!(32&e);return t=function(i,o,c){const a=Y(i);var h=a.length;const u=256&o?a[h-1]:void 0;for(h+=u?-1:0,o=512&o?1:0;o<h;o++)a[o]=c(a[o]);if(u){o=a[o]={};for(const m in u)o[m]=c(u[m])}return ci(a,i),a}(t,e,i=>Vr(i,s,n)),fr(t,32|(r?2:0)),t}function pr(t){const e=t.s,r=_(e);return 2&r?vn(t,e,r,!1):t}function se(t,e){return Rt(t=t.s,_(t),e)}function Rt(t,e,r,n){if(r===-1)return null;if(r>=Je(e)){if(256&e)return t[t.length-1][r]}else{var s=t.length;if(n&&256&e&&(n=t[s-1][r])!=null)return n;if((e=r+(+!!(512&e)-1))<s)return t[e]}}function b(t,e,r,n){const s=t.s;let i=_(s);return Lt(i),E(s,i,e,r,n),t}function E(t,e,r,n,s){var i=Je(e);if(r>=i||s){if(s=e,256&e)i=t[t.length-1];else{if(n==null)return s;i=t[i+(+!!(512&e)-1)]={},s|=256}return i[r]=n,s!==e&&C(t,s),s}return t[r+(+!!(512&e)-1)]=n,256&e&&r in(t=t[t.length-1])&&delete t[r],e}function Wt(t,e,r,n,s){var i=2&e;let o=Rt(t,e,r,s);Array.isArray(o)||(o=Qt);const c=!(2&n);n=!(1&n);const a=!!(32&e);let h=L(o);return h!==0||!a||i||c?1&h||(h|=1,C(o,h)):(h|=33,C(o,h)),i?(t=!1,2&h||(ce(o),t=!!(4&h)),(n||t)&&Object.freeze(o)):(i=!!(2&h)||!!(2048&h),n&&i?(o=Y(o),n=1,a&&!c&&(n|=32),C(o,n),E(t,e,r,o,s)):c&&32&h&&!i&&Ye(o,32)),o}function je(t,e){t=t.s;let r=_(t);const n=Rt(t,r,e),s=zt(n);return s!=null&&s!==n&&E(t,r,e,s),s}function gi(t){t=t.s;let e=_(t);const r=Rt(t,e,1),n=ai(r,!0,!!(34&e));return n!=null&&n!==r&&E(t,e,1,n),n}function te(t,e,r){var n=2;t=t.s;let s=_(t);2&s&&(n=1);let i=Wt(t,s,e,1);s=_(t);var o=L(i);let c=o,a=!!(2&o);const h=a&&!!(4&o);if(!(4&o)){Object.isFrozen(i)&&(i=Y(i),c=0,a=!!(2&(o=be(o,s,!1))),s=E(t,s,e,i)),o=z(o,4,!1),o=z(o,4096,!1),o=z(o,8192,!1);let u=0,m=0;for(;u<i.length;u++){const O=r(i[u]);O!=null&&(i[m++]=O)}m<u&&(i.length=m),o=z(o,20,!0)}return h||((r=n===1)&&(o=z(o,2,!0)),o!==c&&C(i,o),(r||a)&&Object.freeze(i)),n===2&&a&&(i=Y(i),o=be(o,s,!1),C(i,o),E(t,s,e,i)),i}let A1;function cs(){return A1??(A1=new lt(ce([]),void 0,void 0,void 0,d1))}function mi(t){t=Y(t);for(let e=0;e<t.length;e++){const r=t[e]=Y(t[e]);Array.isArray(r[1])&&(r[1]=ce(r[1]))}return t}function rr(t,e,r){{const o=t.s;let c=_(o);if(Lt(c),r==null)E(o,c,e);else{var n=t=L(r),s=!!(2&t)||Object.isFrozen(r),i=!s&&!1;if(!(4&t)){t=21,s&&(r=Y(r),n=0,t=be(t,c,!0)),s=!!(4&t)&&!!(4096&t);for(let a=0;a<r.length;a++)r[a]=Le(r[a])}i&&(t=z(t,2,!0)),t!==n&&C(r,t),i&&Object.freeze(r),E(o,c,e,r)}}}function Me(t,e,r,n){const s=_(t);Lt(s),t=Wt(t,s,e,2),n=r(n,!!(4&(e=L(t)))&&!!(4096&e)),t.push(n)}function T1(t){return t}function Lr(t,e){return wn(t=t.s,_(t),to)===e?e:-1}function wn(t,e,r){let n=0;for(let s=0;s<r.length;s++){const i=r[s];Rt(t,e,i)!=null&&(n!==0&&(e=E(t,e,n)),n=i)}return n}function bn(t,e,r,n){let s=_(t);Lt(s);const i=Rt(t,s,r,n);let o;if(i!=null&&i.P===Fe)return(e=pr(i))!==i&&E(t,s,r,e,n),e.s;if(Array.isArray(i)){const c=L(i);o=2&c?pi(i,c,!1):i,o=qt(o,e)}else o=qt(void 0,e);return o!==i&&E(t,s,r,o,n),o}function yi(t,e,r,n){t=t.s;let s=_(t);const i=Rt(t,s,r,n);return(e=gn(i,e,!1,s))!==i&&e!=null&&E(t,s,r,e,n),e}function v(t,e,r,n=!1){if((e=yi(t,e,r,n))==null)return e;t=t.s;let s=_(t);if(!(2&s)){const i=pr(e);i!==e&&E(t,s,r,e=i,n)}return e}function _i(t,e,r,n,s,i,o){const c=s===1;s=s===2,i=!!i;var a=!!(2&e)&&s;let h=Wt(t,e,n,3);e=_(t);var u=L(h),m=!!(2&u);const O=!!(4&u),Bt=!!(32&u);let G=m&&O||!!(2048&u);if(!O){var X=h,Dt=e;const Er=!!(2&u);Er&&(Dt=z(Dt,2,!0));let Vn=!Er,zn=!0,Ie=0,Ar=0;for(;Ie<X.length;Ie++){const Tr=gn(X[Ie],r,!1,Dt);if(Tr instanceof r){if(!Er){const Wn=!!(2&L(Tr.s));Vn&&(Vn=!Wn),zn&&(zn=Wn)}X[Ar++]=Tr}}Ar<Ie&&(X.length=Ar),u=z(u,4,!0),u=z(u,16,zn),u=z(u,8,Vn),C(X,u),m&&!a&&(Object.freeze(h),G=!0)}if(r=u,a=!!(8&u)||c&&!h.length,o&&!a){for(G&&(h=Y(h),G=!1,r=0,u=be(u,e,i),e=E(t,e,n,h)),o=h,a=u,m=0;m<o.length;m++)(X=o[m])!==(u=pr(X))&&(o[m]=u);a=z(a,8,!0),u=a=z(a,16,!o.length)}return G||(c?u=z(u,!h.length||16&u&&(!O||Bt)?2:2048,!0):i||(u=z(u,32,!1)),u!==r&&C(h,u),c&&(Object.freeze(h),G=!0)),s&&G&&(h=Y(h),u=be(u,e,i),C(h,u),E(t,e,n,h)),h}function It(t,e,r){t=t.s;const n=_(t),s=!!(2&n);return _i(t,n,e,r,s?1:2,!1,!s)}function p(t,e,r,n,s){return n==null&&(n=void 0),b(t,r,n,s)}function ge(t,e,r,n){n==null&&(n=void 0),t=t.s;let s=_(t);Lt(s),(r=wn(t,s,r))&&r!==e&&n!=null&&(s=E(t,s,r)),E(t,s,e,n)}function be(t,e,r){return t=z(t,2,!!(2&e)),t=z(t,32,!!(32&e)&&r),z(t,2048,!1)}function zr(t,e,r){t=t.s;const n=_(t);Lt(n),t=_i(t,n,e,1,2),e=r??new e,t.push(e),2&L(e.s)?Ye(t,8):Ye(t,16)}function ht(t,e){return he(se(t,e))}function ft(t,e){return we(se(t,e))}function St(t){return t??0}function H(t,e){return St(je(t,e))}function Ee(t,e,r){if(r!=null){if(typeof r!="boolean")throw t=typeof r,Error(`Expected boolean but got ${t!="object"?t:r?Array.isArray(r)?"array":t:"null"}: ${r}`);r=!!r}b(t,e,r)}function xt(t,e,r){if(r!=null){if(typeof r!="number")throw ui("int32");if(!Number.isFinite(r)){const n=Error();hi(n,"incident"),function(s){sr.setTimeout(()=>{throw s},0)}(n)}}b(t,e,r)}function g(t,e,r){if(r!=null&&typeof r!="number")throw Error(`Value of float/double field must be a number, found ${typeof r}: ${r}`);b(t,e,r)}function yt(t,e,r){e.g?e.m(t,e.g,e.h,r,!0):e.m(t,e.h,r,!0)}lt.prototype.toJSON=void 0,lt.prototype.Ia=ii;var l=class{constructor(t,e){this.s=fi(t,e)}toJSON(){return vi(this,_n(this.s,di,void 0,void 0,!1,!1),!0)}l(){var t=L2;return t.g?t.l(this,t.g,t.h,!0,2):t.l(this,t.h,t.defaultValue,!0)}clone(){const t=this.s;return vn(this,t,_(t),!1)}H(){return!!(2&L(this.s))}};function vi(t,e,r){const n=t.constructor.A;var s=_(r?t.s:e),i=Je(s),o=!1;if(n&&oi){if(!r){var c;if((e=Y(e)).length&&pe(c=e[e.length-1])){for(o=0;o<n.length;o++)if(n[o]>=i){Object.assign(e[e.length-1]={},c);break}}o=!0}var a;i=e,r=!r,t=Je(c=_(t.s)),c=+!!(512&c)-1;for(let Dt=0;Dt<n.length;Dt++){var h=n[Dt];if(h<t){var u=i[h+=c];u==null?i[h]=r?Qt:ns():r&&u!==Qt&&rs(u)}else{if(!a){var m=void 0;i.length&&pe(m=i[i.length-1])?a=m:i.push(a={})}u=a[h],a[h]==null?a[h]=r?Qt:ns():r&&u!==Qt&&rs(u)}}}if(!(a=e.length))return e;let O,Bt;if(pe(m=e[a-1])){t:{var G=m;for(var X in i={},r=!1,G)t=G[X],Array.isArray(t)&&(c=t,(!qn&&jr(t,n,+X)||!Cr&&ss(t)&&t.size===0)&&(t=null),t!=c&&(r=!0)),t!=null?i[X]=t:r=!0;if(r){for(let Dt in i){G=i;break t}G=null}}G!=m&&(O=!0),a--}for(s=+!!(512&s)-1;0<a&&((m=e[X=a-1])==null||!qn&&jr(m,n,X-s)||!Cr&&ss(m)&&m.size===0);a--)Bt=!0;return(O||Bt)&&(e=o?e:Array.prototype.slice.call(e,0,a),o&&(e.length=a),G&&e.push(G)),e}function wi(t){return Array.isArray(t)?t[0]instanceof ae?t:[C1,t]:[t,void 0]}function ue(t,e){if(Array.isArray(e)){var r=L(e);if(4&r)return e;for(var n=0,s=0;n<e.length;n++){const i=t(e[n]);i!=null&&(e[s++]=i)}return s<n&&(e.length=s),C(e,-12289&(5|r)),2&r&&Object.freeze(e),e}}l.prototype.P=Fe,l.prototype.toString=function(){return vi(this,this.s,!1).toString()};const hs=Symbol();function En(t){let e=t[hs];if(!e){const r=Ai(t),n=Tn(t),s=n.g;e=s?(i,o)=>s(i,o,n):(i,o)=>{for(;ni(o)&&o.h!=4;){var c=o.m,a=n[c];if(!a){var h=n.fa;h&&(h=h[c])&&(a=n[c]=k1(h))}a&&a(o,i,c)||(c=(a=o).l,Ge(a),a.ea?a=void 0:(h=a.g.g-c,a.g.g=c,a=ri(a.g,h)),c=i,a&&(Gt||(Gt=Symbol()),(h=c[Gt])?h.push(a):c[Gt]=[a]))}r===bi||r===Ei||r.Ja||(i[ve||(ve=Symbol())]=r)},t[hs]=e}return e}function k1(t){const e=(t=wi(t))[0].g;if(t=t[1]){const r=En(t),n=Tn(t).K;return(s,i,o)=>e(s,i,o,n,r)}return e}let bi,Ei;const Ve=Symbol();function S1(t,e,r){const n=r[1];let s;if(n){const i=n[Ve];s=i?i.K:er(n[0]),t[e]=i??n}s&&s===mn?(t.ia||(t.ia=[])).push(e):r[0]&&(t.ja||(t.ja=[])).push(e)}function us(t,e){return[t.l,!e||0<e[0]?void 0:e]}function Ai(t){var e=t[Ve];if(e)return e;if(!(e=An(t,t[Ve]={},us,us,S1)).ja&&!e.ia){let r=!0;for(let n in e){isNaN(n)||(r=!1);break}r?(e=er(t[0])===mn,e=t[Ve]=e?Ei||(Ei={K:er(!0)}):bi||(bi={})):e.Ja=!0}return e}function x1(t,e,r){t[e]=r}function An(t,e,r,n,s=x1){e.K=er(t[0]);let i=0;var o=t[++i];o&&o.constructor===Object&&(e.fa=o,typeof(o=t[++i])=="function"&&(e.g=o,e.h=t[++i],o=t[++i]));const c={};for(;Array.isArray(o)&&typeof o[0]=="number"&&0<o[0];){for(var a=0;a<o.length;a++)c[o[a]]=o;o=t[++i]}for(a=1;o!==void 0;){let m;typeof o=="number"&&(a+=o,o=t[++i]);var h=void 0;if(o instanceof ae?m=o:(m=B1,i--),m.la){o=t[++i],h=t;var u=i;typeof o=="function"&&(o=o(),h[u]=o),h=o}for(u=a+1,typeof(o=t[++i])=="number"&&0>o&&(u-=o,o=t[++i]);a<u;a++){const O=c[a];s(e,a,h?n(m,h,O):r(m,O))}}return e}const ls=Symbol();function Ti(t){let e=t[ls];if(!e){const r=gr(t);e=(n,s)=>ki(n,s,r),t[ls]=e}return e}const ze=Symbol();function F1(t){return t.h}function L1(t,e){let r,n;const s=t.h;return(i,o,c)=>s(i,o,c,n||(n=gr(e).K),r||(r=Ti(e)))}function gr(t){let e=t[ze];return e||(e=An(t,t[ze]={},F1,L1),We in t&&ze in t&&(t.length=0),e)}const We=Symbol();function O1(t,e){const r=t.g;return e?(n,s,i)=>r(n,s,i,e):r}function M1(t,e,r){const n=t.g;let s,i;return(o,c,a)=>n(o,c,a,i||(i=Tn(e).K),s||(s=En(e)),r)}function Tn(t){let e=t[We];return e||(Ai(t),e=An(t,t[We]={},O1,M1),We in t&&ze in t&&(t.length=0),e)}function fs(t,e){var r=t[e];if(r)return r;if((r=t.fa)&&(r=r[e])){var n=(r=wi(r))[0].h;if(r=r[1]){const s=Ti(r),i=gr(r).K;r=(r=t.h)?r(i,s):(o,c,a)=>n(o,c,a,i,s)}else r=n;return t[e]=r}}function ki(t,e,r){for(var n=_(t),s=+!!(512&n)-1,i=t.length,o=512&n?1:0,c=i+(256&n?-1:0);o<c;o++){const a=t[o];if(a==null)continue;const h=o-s,u=fs(r,h);u&&u(e,a,h)}if(256&n){n=t[i-1];for(let a in n)s=+a,Number.isNaN(s)||(i=n[a])!=null&&(c=fs(r,s))&&c(e,i,s)}if(t=Gt?t[Gt]:void 0)for(ne(e,e.g.end()),r=0;r<t.length;r++)ne(e,en(t[r])||or())}function J(t,e){return new ae(t,e,!1,!1)}function le(t,e){return new ae(t,e,!0,!1)}function mr(t,e){return new ae(t,e,!1,!0)}function Z(t,e,r){E(t,_(t),e,r)}var P1=mr(function(t,e,r,n,s){return t.h===2&&(t=Se(t,qt([void 0,void 0],n),s),Lt(n=_(e)),(s=Rt(e,n,r))instanceof lt?2&s.I?((s=s.R()).push(t),E(e,n,r,s)):s.Oa(t):Array.isArray(s)?(2&L(s)&&E(e,n,r,s=mi(s)),s.push(t)):E(e,n,r,[t]),!0)},function(t,e,r,n,s){if(e instanceof lt)e.forEach((i,o)=>{Nr(t,r,qt([o,i],n),s)});else if(Array.isArray(e))for(let i=0;i<e.length;i++){const o=e[i];Array.isArray(o)&&Nr(t,r,qt(o,n),s)}});function Si(t,e,r){t:if(e!=null){if(dr(e)){if(typeof e=="string"){e=pn(e,!1);break t}if(typeof e=="number"){e=dn(e);break t}}e=void 0}e!=null&&(typeof e=="string"&&ts(e),e!=null&&(pt(t,r,0),typeof e=="number"?(t=t.g,ar(e),qe(t,P,W)):(r=ts(e),qe(t.g,r.h,r.g))))}function xi(t,e,r){(e=he(e))!=null&&e!=null&&(pt(t,r,0),ur(t.g,e))}function Fi(t,e,r){(e=li(e))!=null&&(pt(t,r,0),t.g.g.push(e?1:0))}function Li(t,e,r){(e=we(e))!=null&&lr(t,r,Gs(e))}function yr(t,e,r,n,s){Nr(t,r,e instanceof l?e.s:Array.isArray(e)?qt(e,n):void 0,s)}function Oi(t,e,r){(e=e==null||typeof e=="string"||ir(e)||e instanceof Nt?e:void 0)!=null&&lr(t,r,nn(e).buffer)}function Mi(t,e,r){return(t.h===5||t.h===2)&&(e=Wt(e,_(e),r,2,!1),t.h==2?hr(t,ke.prototype.B,e):e.push(t.g.B()),!0)}var D,Pt=J(function(t,e,r){if(t.h!==1)return!1;var n=t.g;t=Ur(n);const s=Ur(n);n=2*(s>>31)+1;const i=s>>>20&2047;return t=4294967296*(1048575&s)+t,Z(e,r,i==2047?t?NaN:1/0*n:i==0?n*Math.pow(2,-1074)*t:n*Math.pow(2,i-1075)*(t+4503599627370496)),!0},function(t,e,r){(e=zt(e))!=null&&(pt(t,r,1),t=t.g,(r=Js||(Js=new DataView(new ArrayBuffer(8)))).setFloat64(0,+e,!0),P=r.getUint32(0,!0),W=r.getUint32(4,!0),_e(t,P),_e(t,W))}),U=J(function(t,e,r){return t.h===5&&(Z(e,r,t.g.B()),!0)},function(t,e,r){(e=zt(e))!=null&&(pt(t,r,5),t=t.g,on(e),_e(t,P))}),I1=le(Mi,function(t,e,r){if((e=ue(zt,e))!=null)for(let i=0;i<e.length;i++){var n=t,s=e[i];s!=null&&(pt(n,r,5),n=n.g,on(s),_e(n,P))}}),kn=le(Mi,function(t,e,r){if((e=ue(zt,e))!=null&&e.length){pt(t,r,2),xe(t.g,4*e.length);for(let n=0;n<e.length;n++)r=t.g,on(e[n]),_e(r,P)}}),jt=J(function(t,e,r){return t.h===0&&(Z(e,r,cn(t.g,Qs)),!0)},Si),Or=J(function(t,e,r){return t.h===0&&(Z(e,r,(t=cn(t.g,Qs))===0?void 0:t),!0)},Si),R1=J(function(t,e,r){return t.h===0&&(Z(e,r,cn(t.g,Zs)),!0)},function(t,e,r){t:if(e!=null){if(dr(e)){if(typeof e=="string"){var n=Math.trunc(Number(e));Number.isSafeInteger(n)?e=String(n):((n=e.indexOf("."))!==-1&&(e=e.substring(0,n)),cr(e),e=Br(P,W));break t}if(typeof e=="number"){e=Math.trunc(e);break t}}e=void 0}e!=null&&(typeof e=="string"&&Zn(e),e!=null&&(pt(t,r,0),typeof e=="number"?(t=t.g,ar(e),qe(t,P,W)):(r=Zn(e),qe(t.g,r.h,r.g))))}),R=J(function(t,e,r){return t.h===0&&(Z(e,r,t.g.m()),!0)},xi),Sn=le(function(t,e,r){return(t.h===0||t.h===2)&&(e=Wt(e,_(e),r,2,!1),t.h==2?hr(t,ke.prototype.m,e):e.push(t.g.m()),!0)},function(t,e,r){if((e=ue(he,e))!=null&&e.length){r=ln(t,r);for(let n=0;n<e.length;n++)ur(t.g,e[n]);fn(t,r)}}),ie=J(function(t,e,r){return t.h===0&&(Z(e,r,(t=t.g.m())===0?void 0:t),!0)},xi),B=J(function(t,e,r){return t.h===0&&(Z(e,r,hn(t.g)),!0)},Fi),me=J(function(t,e,r){return t.h===0&&(Z(e,r,(t=hn(t.g))===!1?void 0:t),!0)},Fi),K=le(function(t,e,r){return t.h===2&&(Me(e,r,T1,t=un(t)),!0)},function(t,e,r){if((e=ue(we,e))!=null)for(let s=0;s<e.length;s++){var n=e[s];n!=null&&lr(t,r,Gs(n))}}),Vt=J(function(t,e,r){return t.h===2&&(Z(e,r,(t=un(t))===""?void 0:t),!0)},Li),T=J(function(t,e,r){return t.h===2&&(Z(e,r,un(t)),!0)},Li),C1=mr(function(t,e,r,n,s){return t.h===2&&(Se(t,bn(e,n,r,!0),s),!0)},yr),B1=mr(function(t,e,r,n,s){return t.h===2&&(Se(t,bn(e,n,r),s),!0)},yr);D=new ae(function(t,e,r,n,s){if(t.h!==2)return!1;n=qt(void 0,n);let i=_(e);Lt(i);let o=Wt(e,i,r,3);return i=_(e),4&L(o)&&(o=Y(o),C(o,-2079&(1|L(o))),E(e,i,r,o)),o.push(n),Se(t,n,s),!0},function(t,e,r,n,s){if(Array.isArray(e))for(let i=0;i<e.length;i++)yr(t,e[i],r,n,s)},!0,!0);var k=mr(function(t,e,r,n,s,i){if(t.h!==2)return!1;let o=_(e);return Lt(o),(i=wn(e,o,i))&&r!==i&&E(e,o,i),Se(t,e=bn(e,n,r),s),!0},yr),Pi=J(function(t,e,r){return t.h===2&&(Z(e,r,si(t)),!0)},Oi),D1=le(function(t,e,r){return(t.h===0||t.h===2)&&(e=Wt(e,_(e),r,2,!1),t.h==2?hr(t,ke.prototype.j,e):e.push(t.g.j()),!0)},function(t,e,r){if((e=ue(g1,e))!=null)for(let i=0;i<e.length;i++){var n=t,s=e[i];s!=null&&(pt(n,r,0),xe(n.g,s))}}),Ft=J(function(t,e,r){return t.h===0&&(Z(e,r,t.g.m()),!0)},function(t,e,r){(e=he(e))!=null&&(e=parseInt(e,10),pt(t,r,0),ur(t.g,e))}),U1=le(function(t,e,r){return(t.h===0||t.h===2)&&(e=Wt(e,_(e),r,2,!1),t.h==2?hr(t,ke.prototype.C,e):e.push(t.g.m()),!0)},function(t,e,r){if((e=ue(he,e))!=null&&e.length){r=ln(t,r);for(let n=0;n<e.length;n++)ur(t.g,e[n]);fn(t,r)}});class N1{constructor(e,r){this.h=e,this.g=r,this.l=v,this.m=p,this.defaultValue=void 0}}function _t(t,e){return new N1(t,e)}function Ht(t,e){return(r,n)=>{t:{if(Ce.length){const i=Ce.pop();i.o(n),Dr(i.g,r,n),r=i}else r=new class{constructor(i,o){if(Jn.length){const c=Jn.pop();Dr(c,i,o),i=c}else i=new ke(i,o);this.g=i,this.l=this.g.g,this.h=this.m=-1,this.o(o)}o({ea:i=!1}={}){this.ea=i}}(r,n);try{const i=new t,o=i.s;En(e)(o,r),ve&&delete o[ve];var s=i;break t}finally{r.g.clear(),r.m=-1,r.h=-1,100>Ce.length&&Ce.push(r)}s=void 0}return s}}function xn(t){return function(){const e=new class{constructor(){this.l=[],this.h=0,this.g=new class{constructor(){this.g=[]}length(){return this.g.length}end(){const o=this.g;return this.g=[],o}}}};ki(this.s,e,gr(t)),ne(e,e.g.end());const r=new Uint8Array(e.h),n=e.l,s=n.length;let i=0;for(let o=0;o<s;o++){const c=n[o];r.set(c,i),i+=c.length}return e.l=[r],r}}var Ii=[0,Vt,J(function(t,e,r){return t.h===2&&(Z(e,r,(t=si(t))===re()?void 0:t),!0)},function(t,e,r){if(e!=null){if(e instanceof l){const n=e.Qa;return void(n&&(e=n(e),e!=null&&lr(t,r,nn(e).buffer)))}if(Array.isArray(e))return}Oi(t,e,r)})],G1=[0,T],Ri=[0,R,Ft,B,-1,Sn,Ft,-1],j1=[0,B,-1],Ci=class extends l{constructor(){super()}};Ci.A=[6];var Bi=[0,B,T,B,Ft,-1,U1,T,-1,j1,Ft],Di=[0,T,-2],ds=class extends l{constructor(){super()}},Ui=[0],Ni=[0,R,B,-2],dt=class extends l{constructor(t){super(t,2)}},x={},V1=[-2,x,B];x[336783863]=[0,T,B,-1,R,[0,[1,2,3,4,5],k,Ui,k,Bi,k,Di,k,Ni,k,Ri],G1];var z1=[0,Vt,me],Gi=[0,Or,-1,me,-3,Or,Sn,Vt,ie,Or,-1,me,ie,me,-2,Vt],Pe=[-1,{}],ji=[0,T,1,Pe],Vi=[0,T,K,Pe];function gt(t,e){e=Oe(e),t=t.s;let r=_(t);Lt(r),E(t,r,2,e===""?void 0:e)}function A(t,e){Me(t.s,3,Le,e)}function w(t,e){Me(t.s,4,Le,e)}var $=class extends l{constructor(t){super(t,500)}o(t){return p(this,0,7,t)}};$.A=[3,4,5,6,8,13,17,1005];var W1=[-500,Vt,-1,K,-3,V1,D,Ii,ie,-1,ji,Vi,D,z1,Vt,Gi,ie,K,987,K],H1=[0,Vt,-1,Pe],X1=[-500,T,-1,[-1,{}],998,T],K1=[-500,T,K,-1,[-2,{},B],997,K,-1],$1=[-500,T,K,Pe,998,K];function mt(t,e){zr(t,$,e)}function F(t,e){Me(t.s,10,Le,e)}function S(t,e){Me(t.s,15,Le,e)}var Q=class extends l{constructor(t){super(t,500)}o(t){return p(this,0,1001,t)}};Q.A=[1,6,7,9,10,15,16,17,14,1002];var zi=[-500,D,W1,4,D,X1,D,K1,ie,D,$1,K,ie,ji,Vi,D,H1,K,-2,Gi,Vt,-1,me,979,Pe,D,Ii],q1=Ht(Q,zi);Q.prototype.g=xn(zi);var Y1=[0,D,[0,R,-2]],J1=class extends l{constructor(t){super(t)}},Z1=[0,R,U,T,-1],Fn=class extends l{constructor(t){super(t)}g(){return It(this,J1,1)}};Fn.A=[1];var Wi=[0,D,Z1],Ln=Ht(Fn,Wi),Q1=[0,R,U],t2=[0,R,-1,Y1],e2=class extends l{constructor(t){super(t)}},r2=[0,R,-3],n2=[0,U,-3],s2=class extends l{constructor(t){super(t)}},i2=[0,U,-1,T,U],He=class extends l{constructor(t){super(t)}h(){return v(this,e2,2)}g(){return It(this,s2,5)}};He.A=[5];var o2=[0,Ft,r2,n2,t2,D,i2],Hi=class extends l{constructor(t){super(t)}};Hi.A=[1,2,3,8,9];var Xi=Ht(Hi,[0,K,Sn,kn,o2,T,-1,jt,D,Q1,K,jt]),Ki=class extends l{constructor(t){super(t)}},a2=[0,U,-4],$i=class extends l{constructor(t){super(t)}};$i.A=[1];var On=Ht($i,[0,D,a2]),qi=class extends l{constructor(t){super(t)}},c2=[0,U,-4],Yi=class extends l{constructor(t){super(t)}};Yi.A=[1];var _r=Ht(Yi,[0,D,c2]),Ji=class extends l{constructor(t){super(t)}};Ji.A=[3];var h2=[0,R,-1,kn,Ft],Zi=class extends l{constructor(){super()}};Zi.prototype.g=xn([0,U,-4,jt]);var u2=class extends l{constructor(t){super(t)}},l2=[0,1,R,T,Wi],Qi=class extends l{constructor(t){super(t)}};Qi.A=[1];var f2=Ht(Qi,[0,D,l2,jt]),Wr=class extends l{constructor(t){super(t)}};Wr.A=[1];var d2=class extends l{constructor(t){super(t)}oa(){const t=gi(this);return t??re()}},p2=class extends l{constructor(t){super(t)}},to=[1,2],g2=[0,to,k,[0,kn],k,[0,Pi],R,T],eo=class extends l{constructor(t){super(t)}};eo.A=[1];var m2=Ht(eo,[0,D,g2,jt]),vr=class extends l{constructor(t){super(t)}};vr.A=[4,5];var ro=[0,T,R,U,K,-1],ps=class extends l{constructor(t){super(t)}},y2=[0,B,-1],gs=class extends l{constructor(t){super(t)}},Xe=[1,2,3,4,5],nr=class extends l{constructor(t){super(t)}g(){return gi(this)!=null}h(){return ft(this,2)!=null}},no=[0,Pi,T,[0,R,jt,-1],[0,R1,jt]],I=class extends l{constructor(t){super(t)}g(){return li(se(this,2))??!1}},N=[0,no,B,[0,Xe,k,Ni,k,Bi,k,Ri,k,Ui,k,Di],Ft],Mn=class extends l{constructor(t){super(t)}},so=[0,N,U,-1,R],_2=_t(502141897,Mn);x[502141897]=so;var io=[0,no];x[512499200]=io;var oo=[0,io];x[515723506]=oo;var v2=Ht(class extends l{constructor(t){super(t)}},[0,[0,Ft,-1,I1,D1],h2]),ao=[0,N];x[508981768]=ao;var w2=class extends l{constructor(t){super(t)}},co=[0,N,U,ao,B],ho=class extends l{constructor(t){super(t)}},uo=[0,N,so,co,U,oo];x[508968149]=co;var b2=_t(508968150,ho);x[508968150]=uo;var lo=class extends l{constructor(t){super(t)}},E2=_t(513916220,lo);x[513916220]=[0,N,uo,R];var Zt=class extends l{constructor(t){super(t)}h(){return v(this,vr,2)}g(){b(this,2)}},fo=[0,N,ro];x[478825465]=fo;var po=[0,N];x[478825422]=po;var A2=class extends l{constructor(t){super(t)}},go=[0,N,po,fo,-1],mo=class extends l{constructor(t){super(t)}},yo=[0,N,U,R],_o=class extends l{constructor(t){super(t)}},vo=[0,N,U],Pn=class extends l{constructor(t){super(t)}},wo=[0,N,yo,vo,U],bo=class extends l{constructor(t){super(t)}},T2=[0,N,wo,go];x[463370452]=go,x[464864288]=yo,x[474472470]=vo;var k2=_t(462713202,Pn);x[462713202]=wo;var S2=_t(479097054,bo);x[479097054]=T2;var Eo=class extends l{constructor(t){super(t)}},x2=_t(456383383,Eo);x[456383383]=[0,N,ro];var Ao=class extends l{constructor(t){super(t)}},F2=_t(476348187,Ao);x[476348187]=[0,N,y2];var To=class extends l{constructor(t){super(t)}},ko=[0,Ft,-1],Hr=class extends l{constructor(t){super(t)}};Hr.A=[3];var L2=_t(458105876,class extends l{constructor(t){super(t)}g(){var t=this.s;const e=_(t);var r=2&e;return t=function(n,s,i){var o=Hr;const c=2&s;let a=!1;if(i==null){if(c)return cs();i=[]}else if(i.constructor===lt){if(!(2&i.I)||c)return i;i=i.R()}else Array.isArray(i)?a=!!(2&L(i)):i=[];if(c){if(!i.length)return cs();a||(a=!0,ce(i))}else a&&(a=!1,i=mi(i));return a||(64&L(i)?Ye(i,32):32&s&&fr(i,32)),E(n,s,2,o=new lt(i,o,m1,void 0),!1),o}(t,e,Rt(t,e,2)),t==null||!r&&Hr&&(t.ra=!0),r=t}});x[458105876]=[0,ko,P1,[!0,jt,[0,T,-1,K]]];var In=class extends l{constructor(t){super(t)}},So=_t(458105758,In);x[458105758]=[0,N,T,ko];var Rn=class extends l{constructor(t){super(t)}};Rn.A=[5,6];var O2=_t(443442058,Rn);x[443442058]=[0,N,T,R,U,K,-1];var M2=class extends l{constructor(t){super(t)}},xo=[0,N,U,-1,R];x[514774813]=xo;var P2=class extends l{constructor(t){super(t)}},Fo=[0,N,U,B],Lo=class extends l{constructor(t){super(t)}},I2=[0,N,xo,Fo,U];x[518928384]=Fo;var R2=_t(516587230,Lo);function Xr(t,e){return e=e?e.clone():new vr,t.displayNamesLocale!==void 0?b(e,1,Oe(t.displayNamesLocale)):t.displayNamesLocale===void 0&&b(e,1),t.maxResults!==void 0?xt(e,2,t.maxResults):"maxResults"in t&&b(e,2),t.scoreThreshold!==void 0?g(e,3,t.scoreThreshold):"scoreThreshold"in t&&b(e,3),t.categoryAllowlist!==void 0?rr(e,4,t.categoryAllowlist):"categoryAllowlist"in t&&b(e,4),t.categoryDenylist!==void 0?rr(e,5,t.categoryDenylist):"categoryDenylist"in t&&b(e,5),e}function Oo(t,e=-1,r=""){return{categories:t.map(n=>({index:St(ht(n,1))??-1,score:H(n,2)??0,categoryName:ft(n,3)??""??"",displayName:ft(n,4)??""??""})),headIndex:e,headName:r}}function Mo(t){var o,c;var e=te(t,3,zt),r=te(t,2,he);const n=te(t,1,we),s=te(t,9,we),i={categories:[],keypoints:[]};for(let a=0;a<e.length;a++)i.categories.push({score:e[a],index:r[a]??-1,categoryName:n[a]??"",displayName:s[a]??""});if((e=(o=v(t,He,4))==null?void 0:o.h())&&(i.boundingBox={originX:ht(e,1)??0,originY:ht(e,2)??0,width:ht(e,3)??0,height:ht(e,4)??0,angle:0}),(c=v(t,He,4))==null?void 0:c.g().length)for(const a of v(t,He,4).g())i.keypoints.push({x:je(a,1)??0,y:je(a,2)??0,score:je(a,4)??0,label:ft(a,3)??""});return i}function Cn(t){const e=[];for(const r of It(t,qi,1))e.push({x:H(r,1)??0,y:H(r,2)??0,z:H(r,3)??0});return e}function Po(t){const e=[];for(const r of It(t,Ki,1))e.push({x:H(r,1)??0,y:H(r,2)??0,z:H(r,3)??0});return e}function ms(t){return Array.from(t,e=>127<e?e-256:e)}function ys(t,e){if(t.length!==e.length)throw Error(`Cannot compute cosine similarity between embeddings of different sizes (${t.length} vs. ${e.length}).`);let r=0,n=0,s=0;for(let i=0;i<t.length;i++)r+=t[i]*e[i],n+=t[i]*t[i],s+=e[i]*e[i];if(0>=n||0>=s)throw Error("Cannot compute cosine similarity on embedding with 0 norm.");return r/Math.sqrt(n*s)}let De;x[516587230]=I2;const C2=new Uint8Array([0,97,115,109,1,0,0,0,1,5,1,96,0,1,123,3,2,1,0,10,10,1,8,0,65,0,253,15,253,98,11]);async function Io(){if(De===void 0)try{await WebAssembly.instantiate(C2),De=!0}catch{De=!1}return De}async function Mr(t,e=""){const r=await Io()?"wasm_internal":"wasm_nosimd_internal";return{wasmLoaderPath:`${e}/${t}_${r}.js`,wasmBinaryPath:`${e}/${t}_${r}.wasm`}}var Ue=class{};function Ro(){const t=navigator.userAgent;return t.includes("Safari")&&!t.includes("Chrome")}async function _s(t){if(typeof importScripts!="function"){const e=document.createElement("script");return e.src=t.toString(),e.crossOrigin="anonymous",new Promise((r,n)=>{e.addEventListener("load",()=>{r()},!1),e.addEventListener("error",s=>{n(s)},!1),document.body.appendChild(e)})}importScripts(t.toString())}function f(t,e,r){t.m||console.error("No wasm multistream support detected: ensure dependency inclusion of :gl_graph_runner_internal_multi_input target"),r(e=t.i.stringToNewUTF8(e)),t.i._free(e)}function vs(t,e,r){if(!t.i.canvas)throw Error("No OpenGL canvas configured.");if(r?t.i._bindTextureToStream(r):t.i._bindTextureToCanvas(),!(r=t.i.canvas.getContext("webgl2")||t.i.canvas.getContext("webgl")))throw Error("Failed to obtain WebGL context from the provided canvas. `getContext()` should only be invoked with `webgl` or `webgl2`.");return t.i.gpuOriginForWebTexturesIsBottomLeft&&r.pixelStorei(r.UNPACK_FLIP_Y_WEBGL,!0),r.texImage2D(r.TEXTURE_2D,0,r.RGBA,r.RGBA,r.UNSIGNED_BYTE,e),t.i.gpuOriginForWebTexturesIsBottomLeft&&r.pixelStorei(r.UNPACK_FLIP_Y_WEBGL,!1),e.videoWidth?(r=e.videoWidth,e=e.videoHeight):e.naturalWidth?(r=e.naturalWidth,e=e.naturalHeight):(r=e.width,e=e.height),!t.l||r===t.i.canvas.width&&e===t.i.canvas.height||(t.i.canvas.width=r,t.i.canvas.height=e),[r,e]}function ws(t,e,r){t.m||console.error("No wasm multistream support detected: ensure dependency inclusion of :gl_graph_runner_internal_multi_input target");const n=new Uint32Array(e.length);for(let s=0;s<e.length;s++)n[s]=t.i.stringToNewUTF8(e[s]);e=t.i._malloc(4*n.length),t.i.HEAPU32.set(n,e>>2),r(e);for(const s of n)t.i._free(s);t.i._free(e)}function Ot(t,e,r){t.i.simpleListeners=t.i.simpleListeners||{},t.i.simpleListeners[e]=r}function Kt(t,e,r){let n=[];t.i.simpleListeners=t.i.simpleListeners||{},t.i.simpleListeners[e]=(s,i,o)=>{i?(r(n,o),n=[]):n.push(s)}}Ue.forVisionTasks=function(t){return Mr("vision",t)},Ue.forTextTasks=function(t){return Mr("text",t)},Ue.forAudioTasks=function(t){return Mr("audio",t)},Ue.isSimdSupported=function(){return Io()};async function B2(t,e,r,n){return t=await(async(s,i,o,c,a)=>{if(i&&await _s(i),!self.ModuleFactory||o&&(await _s(o),!self.ModuleFactory))throw Error("ModuleFactory not set.");return self.Module&&a&&((i=self.Module).locateFile=a.locateFile,a.mainScriptUrlOrBlob&&(i.mainScriptUrlOrBlob=a.mainScriptUrlOrBlob)),a=await self.ModuleFactory(self.Module||a),self.ModuleFactory=self.Module=void 0,new s(a,c)})(t,r.wasmLoaderPath,r.assetLoaderPath,e,{locateFile:s=>s.endsWith(".wasm")?r.wasmBinaryPath.toString():r.assetBinaryPath&&s.endsWith(".data")?r.assetBinaryPath.toString():s}),await t.o(n),t}function bs(t,e){const r=v(t.baseOptions,nr,1)||new nr;typeof e=="string"?(b(r,2,Oe(e)),b(r,1)):e instanceof Uint8Array&&(b(r,1,ai(e,!1,!1)),b(r,2)),p(t.baseOptions,0,1,r)}function Es(t){try{const e=t.L.length;if(e===1)throw Error(t.L[0].message);if(1<e)throw Error("Encountered multiple errors: "+t.L.map(r=>r.message).join(", "))}finally{t.L=[]}}function d(t,e){t.N=Math.max(t.N,e)}function Bn(t,e){t.B=new $,gt(t.B,"PassThroughCalculator"),A(t.B,"free_memory"),w(t.B,"free_memory_unused_out"),F(e,"free_memory"),mt(e,t.B)}function Ae(t,e){A(t.B,e),w(t.B,e+"_unused_out")}function Dn(t){t.g.addBoolToStream(!0,"free_memory",t.N)}var Kr=class{constructor(t){this.g=t,this.L=[],this.N=0,this.g.setAutoRenderToScreen(!1)}l(t,e=!0){var r,n,s,i,o,c;if(e){const a=t.baseOptions||{};if((r=t.baseOptions)!=null&&r.modelAssetBuffer&&((n=t.baseOptions)!=null&&n.modelAssetPath))throw Error("Cannot set both baseOptions.modelAssetPath and baseOptions.modelAssetBuffer");if(!((s=v(this.baseOptions,nr,1))!=null&&s.g()||(i=v(this.baseOptions,nr,1))!=null&&i.h()||(o=t.baseOptions)!=null&&o.modelAssetBuffer||(c=t.baseOptions)!=null&&c.modelAssetPath))throw Error("Either baseOptions.modelAssetPath or baseOptions.modelAssetBuffer must be set");if(function(h,u){let m=v(h.baseOptions,gs,3);if(!m){var O=m=new gs,Bt=new ds;ge(O,4,Xe,Bt)}"delegate"in u&&(u.delegate==="GPU"?(u=m,O=new Ci,ge(u,2,Xe,O)):(u=m,O=new ds,ge(u,4,Xe,O))),p(h.baseOptions,0,3,m)}(this,a),a.modelAssetPath)return fetch(a.modelAssetPath.toString()).then(h=>{if(h.ok)return h.arrayBuffer();throw Error(`Failed to fetch model: ${a.modelAssetPath} (${h.status})`)}).then(h=>{try{this.g.i.FS_unlink("/model.dat")}catch{}this.g.i.FS_createDataFile("/","model.dat",new Uint8Array(h),!0,!1,!1),bs(this,"/model.dat"),this.m(),this.V()});bs(this,a.modelAssetBuffer)}return this.m(),this.V(),Promise.resolve()}V(){}aa(){let t;if(this.g.aa(e=>{t=q1(e)}),!t)throw Error("Failed to retrieve CalculatorGraphConfig");return t}setGraph(t,e){this.g.attachErrorListener((r,n)=>{this.L.push(Error(n))}),this.g.Ma(),this.g.setGraph(t,e),this.B=void 0,Es(this)}finishProcessing(){this.g.finishProcessing(),Es(this)}close(){this.B=void 0,this.g.closeGraph()}};function ut(t,e){if(t===null)throw Error(`Unable to obtain required WebGL resource: ${e}`);return t}Kr.prototype.close=Kr.prototype.close;class D2{constructor(e,r,n,s){this.g=e,this.h=r,this.m=n,this.l=s}bind(){this.g.bindVertexArray(this.h)}close(){this.g.deleteVertexArray(this.h),this.g.deleteBuffer(this.m),this.g.deleteBuffer(this.l)}}function As(t,e,r){const n=t.h;if(r=ut(n.createShader(r),"Failed to create WebGL shader"),n.shaderSource(r,e),n.compileShader(r),!n.getShaderParameter(r,n.COMPILE_STATUS))throw Error(`Could not compile WebGL shader: ${n.getShaderInfoLog(r)}`);return n.attachShader(t.g,r),r}function Ts(t,e){const r=t.h,n=ut(r.createVertexArray(),"Failed to create vertex array");r.bindVertexArray(n);const s=ut(r.createBuffer(),"Failed to create buffer");r.bindBuffer(r.ARRAY_BUFFER,s),r.enableVertexAttribArray(t.u),r.vertexAttribPointer(t.u,2,r.FLOAT,!1,0,0),r.bufferData(r.ARRAY_BUFFER,new Float32Array([-1,-1,-1,1,1,1,1,-1]),r.STATIC_DRAW);const i=ut(r.createBuffer(),"Failed to create buffer");return r.bindBuffer(r.ARRAY_BUFFER,i),r.enableVertexAttribArray(t.B),r.vertexAttribPointer(t.B,2,r.FLOAT,!1,0,0),r.bufferData(r.ARRAY_BUFFER,new Float32Array(e?[0,1,0,0,1,0,1,1]:[0,0,0,1,1,1,1,0]),r.STATIC_DRAW),r.bindBuffer(r.ARRAY_BUFFER,null),r.bindVertexArray(null),new D2(r,n,s,i)}function Co(t,e){if(t.h){if(e!==t.h)throw Error("Cannot change GL context once initialized")}else t.h=e}function Un(t,e,r,n){if(Co(t,e),!t.g){const s=t.h;if(t.g=ut(s.createProgram(),"Failed to create WebGL program"),t.C=As(t,`
|
|
2
|
+
attribute vec2 aVertex;
|
|
3
|
+
attribute vec2 aTex;
|
|
4
|
+
varying vec2 vTex;
|
|
5
|
+
void main(void) {
|
|
6
|
+
gl_Position = vec4(aVertex, 0.0, 1.0);
|
|
7
|
+
vTex = aTex;
|
|
8
|
+
}`,s.VERTEX_SHADER),t.v=As(t,`
|
|
9
|
+
precision mediump float;
|
|
10
|
+
varying vec2 vTex;
|
|
11
|
+
uniform sampler2D inputTexture;
|
|
12
|
+
void main() {
|
|
13
|
+
gl_FragColor = texture2D(inputTexture, vTex);
|
|
14
|
+
}
|
|
15
|
+
`,s.FRAGMENT_SHADER),s.linkProgram(t.g),!s.getProgramParameter(t.g,s.LINK_STATUS))throw Error(`Error during program linking: ${s.getProgramInfoLog(t.g)}`);t.u=s.getAttribLocation(t.g,"aVertex"),t.B=s.getAttribLocation(t.g,"aTex")}return r?(t.m||(t.m=Ts(t,!0)),r=t.m):(t.j||(t.j=Ts(t,!1)),r=t.j),e.useProgram(t.g),r.bind(),t=n(),r.g.bindVertexArray(null),t}function wr(t,e,r){Co(t,e),t.l||(t.l=ut(e.createFramebuffer(),"Failed to create framebuffe.")),e.bindFramebuffer(e.FRAMEBUFFER,t.l),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,r,0)}function Nn(t){var e;(e=t.h)==null||e.bindFramebuffer(t.h.FRAMEBUFFER,null)}var Gn=class{close(){if(this.g){const t=this.h;t.deleteProgram(this.g),t.deleteShader(this.C),t.deleteShader(this.v)}this.l&&this.h.deleteFramebuffer(this.l),this.j&&this.j.close(),this.m&&this.m.close()}};function Mt(t,e){switch(e){case 0:return t.g.find(r=>r instanceof Uint8Array);case 1:return t.g.find(r=>r instanceof Float32Array);case 2:return t.g.find(r=>typeof WebGLTexture<"u"&&r instanceof WebGLTexture);default:throw Error(`Type is not supported: ${e}`)}}function $r(t){var e=Mt(t,1);if(!e){if(e=Mt(t,0))e=new Float32Array(e).map(n=>n/255);else{e=new Float32Array(t.width*t.height);const n=Yt(t);var r=Uo(t);if(wr(r,n,Bo(t)),"iPad Simulator;iPhone Simulator;iPod Simulator;iPad;iPhone;iPod".split(";").includes(navigator.platform)||navigator.userAgent.includes("Mac")&&"ontouchend"in self.document){r=new Float32Array(t.width*t.height*4),n.readPixels(0,0,t.width,t.height,n.RGBA,n.FLOAT,r);for(let s=0,i=0;s<e.length;++s,i+=4)e[s]=r[i]}else n.readPixels(0,0,t.width,t.height,n.RED,n.FLOAT,e)}t.g.push(e)}return e}function Bo(t){let e=Mt(t,2);if(!e){const r=Yt(t);e=Go(t);const n=$r(t),s=Do(t);r.texImage2D(r.TEXTURE_2D,0,s,t.width,t.height,0,r.RED,r.FLOAT,n),qr(t)}return e}function Yt(t){if(!t.canvas)throw Error("Conversion to different image formats require that a canvas is passed when initializing the image.");return t.h||(t.h=ut(t.canvas.getContext("webgl2"),"You cannot use a canvas that is already bound to a different type of rendering context.")),t.h}function Do(t){if(t=Yt(t),!Ne)if(t.getExtension("EXT_color_buffer_float")&&t.getExtension("OES_texture_float_linear")&&t.getExtension("EXT_float_blend"))Ne=t.R32F;else{if(!t.getExtension("EXT_color_buffer_half_float"))throw Error("GPU does not fully support 4-channel float32 or float16 formats");Ne=t.R16F}return Ne}function Uo(t){return t.l||(t.l=new Gn),t.l}function No(t){(t=Yt(t)).texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.NEAREST),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.NEAREST)}function Go(t){const e=Yt(t);e.viewport(0,0,t.width,t.height),e.activeTexture(e.TEXTURE0);let r=Mt(t,2);return r?e.bindTexture(e.TEXTURE_2D,r):(r=ut(e.createTexture(),"Failed to create texture"),t.g.push(r),t.m=!0,e.bindTexture(e.TEXTURE_2D,r),No(t)),r}function qr(t){t.h.bindTexture(t.h.TEXTURE_2D,null)}var Ne,j=class{constructor(t,e,r,n,s,i){this.g=t,this.m=e,this.canvas=r,this.l=n,this.width=s,this.height=i,this.m&&--ks===0&&console.error("You seem to be creating MPMask instances without invoking .close(). This leaks resources.")}Ga(){return!!Mt(this,0)}Ea(){return!!Mt(this,1)}M(){return!!Mt(this,2)}Ca(){return(e=Mt(t=this,0))||(e=$r(t),e=new Uint8Array(e.map(r=>255*r)),t.g.push(e)),e;var t,e}za(){return $r(this)}Z(){return Bo(this)}clone(){const t=[];for(const e of this.g){let r;if(e instanceof Uint8Array)r=new Uint8Array(e);else if(e instanceof Float32Array)r=new Float32Array(e);else{if(!(e instanceof WebGLTexture))throw Error(`Type is not supported: ${e}`);{const n=Yt(this),s=Uo(this);n.activeTexture(n.TEXTURE1),r=ut(n.createTexture(),"Failed to create texture"),n.bindTexture(n.TEXTURE_2D,r),No(this);const i=Do(this);n.texImage2D(n.TEXTURE_2D,0,i,this.width,this.height,0,n.RED,n.FLOAT,null),n.bindTexture(n.TEXTURE_2D,null),wr(s,n,r),Un(s,n,!1,()=>{Go(this),n.clearColor(0,0,0,0),n.clear(n.COLOR_BUFFER_BIT),n.drawArrays(n.TRIANGLE_FAN,0,4),qr(this)}),Nn(s),qr(this)}}t.push(r)}return new j(t,this.M(),this.canvas,this.l,this.width,this.height)}close(){this.m&&Yt(this).deleteTexture(Mt(this,2)),ks=-1}};j.prototype.close=j.prototype.close,j.prototype.clone=j.prototype.clone,j.prototype.getAsWebGLTexture=j.prototype.Z,j.prototype.getAsFloat32Array=j.prototype.za,j.prototype.getAsUint8Array=j.prototype.Ca,j.prototype.hasWebGLTexture=j.prototype.M,j.prototype.hasFloat32Array=j.prototype.Ea,j.prototype.hasUint8Array=j.prototype.Ga;var ks=250;function Tt(t,e){switch(e){case 0:return t.g.find(r=>r instanceof ImageData);case 1:return t.g.find(r=>typeof ImageBitmap<"u"&&r instanceof ImageBitmap);case 2:return t.g.find(r=>typeof WebGLTexture<"u"&&r instanceof WebGLTexture);default:throw Error(`Type is not supported: ${e}`)}}function jo(t){var e=Tt(t,0);if(!e){e=Jt(t);const r=jn(t),n=new Uint8Array(t.width*t.height*4);wr(r,e,Ke(t)),e.readPixels(0,0,t.width,t.height,e.RGBA,e.UNSIGNED_BYTE,n),Nn(r),e=new ImageData(new Uint8ClampedArray(n.buffer),t.width,t.height),t.g.push(e)}return e}function Ke(t){let e=Tt(t,2);if(!e){const r=Jt(t);e=$e(t);const n=Tt(t,1)||jo(t);r.texImage2D(r.TEXTURE_2D,0,r.RGBA,r.RGBA,r.UNSIGNED_BYTE,n),de(t)}return e}function Jt(t){if(!t.canvas)throw Error("Conversion to different image formats require that a canvas is passed when iniitializing the image.");return t.h||(t.h=ut(t.canvas.getContext("webgl2"),"You cannot use a canvas that is already bound to a different type of rendering context.")),t.h}function jn(t){return t.l||(t.l=new Gn),t.l}function Vo(t){(t=Jt(t)).texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.LINEAR)}function $e(t){const e=Jt(t);e.viewport(0,0,t.width,t.height),e.activeTexture(e.TEXTURE0);let r=Tt(t,2);return r?e.bindTexture(e.TEXTURE_2D,r):(r=ut(e.createTexture(),"Failed to create texture"),t.g.push(r),t.m=!0,e.bindTexture(e.TEXTURE_2D,r),Vo(t)),r}function de(t){t.h.bindTexture(t.h.TEXTURE_2D,null)}function Ss(t){const e=Jt(t);return Un(jn(t),e,!0,()=>function(r,n){const s=r.canvas;if(s.width===r.width&&s.height===r.height)return n();const i=s.width,o=s.height;return s.width=r.width,s.height=r.height,r=n(),s.width=i,s.height=o,r}(t,()=>{if(e.bindFramebuffer(e.FRAMEBUFFER,null),e.clearColor(0,0,0,0),e.clear(e.COLOR_BUFFER_BIT),e.drawArrays(e.TRIANGLE_FAN,0,4),!(t.canvas instanceof OffscreenCanvas))throw Error("Conversion to ImageBitmap requires that the MediaPipe Tasks is initialized with an OffscreenCanvas");return t.canvas.transferToImageBitmap()}))}var V=class{constructor(t,e,r,n,s,i,o){this.g=t,this.j=e,this.m=r,this.canvas=n,this.l=s,this.width=i,this.height=o,(this.j||this.m)&&--xs===0&&console.error("You seem to be creating MPImage instances without invoking .close(). This leaks resources.")}Fa(){return!!Tt(this,0)}ga(){return!!Tt(this,1)}M(){return!!Tt(this,2)}Ba(){return jo(this)}Aa(){var t=Tt(this,1);return t||(Ke(this),$e(this),t=Ss(this),de(this),this.g.push(t),this.j=!0),t}Z(){return Ke(this)}clone(){const t=[];for(const e of this.g){let r;if(e instanceof ImageData)r=new ImageData(e.data,this.width,this.height);else if(e instanceof WebGLTexture){const n=Jt(this),s=jn(this);n.activeTexture(n.TEXTURE1),r=ut(n.createTexture(),"Failed to create texture"),n.bindTexture(n.TEXTURE_2D,r),Vo(this),n.texImage2D(n.TEXTURE_2D,0,n.RGBA,this.width,this.height,0,n.RGBA,n.UNSIGNED_BYTE,null),n.bindTexture(n.TEXTURE_2D,null),wr(s,n,r),Un(s,n,!1,()=>{$e(this),n.clearColor(0,0,0,0),n.clear(n.COLOR_BUFFER_BIT),n.drawArrays(n.TRIANGLE_FAN,0,4),de(this)}),Nn(s),de(this)}else{if(!(e instanceof ImageBitmap))throw Error(`Type is not supported: ${e}`);Ke(this),$e(this),r=Ss(this),de(this)}t.push(r)}return new V(t,this.ga(),this.M(),this.canvas,this.l,this.width,this.height)}close(){this.j&&Tt(this,1).close(),this.m&&Jt(this).deleteTexture(Tt(this,2)),xs=-1}};V.prototype.close=V.prototype.close,V.prototype.clone=V.prototype.clone,V.prototype.getAsWebGLTexture=V.prototype.Z,V.prototype.getAsImageBitmap=V.prototype.Aa,V.prototype.getAsImageData=V.prototype.Ba,V.prototype.hasWebGLTexture=V.prototype.M,V.prototype.hasImageBitmap=V.prototype.ga,V.prototype.hasImageData=V.prototype.Fa;var xs=250;function vt(...t){return t.map(([e,r])=>({start:e,end:r}))}const U2=function(t){return class extends t{Ma(){this.i._registerModelResourcesGraphService()}}}((Fs=class{constructor(t,e){this.l=!0,this.i=t,this.g=null,this.h=0,this.m=typeof this.i._addIntToInputStream=="function",e!==void 0?this.i.canvas=e:typeof OffscreenCanvas>"u"||Ro()?(console.warn("OffscreenCanvas not supported and GraphRunner constructor glCanvas parameter is undefined. Creating backup canvas."),this.i.canvas=document.createElement("canvas")):this.i.canvas=new OffscreenCanvas(1,1)}async initializeGraph(t){const e=await(await fetch(t)).arrayBuffer();t=!(t.endsWith(".pbtxt")||t.endsWith(".textproto")),this.setGraph(new Uint8Array(e),t)}setGraphFromString(t){this.setGraph(new TextEncoder().encode(t),!1)}setGraph(t,e){const r=t.length,n=this.i._malloc(r);this.i.HEAPU8.set(t,n),e?this.i._changeBinaryGraph(r,n):this.i._changeTextGraph(r,n),this.i._free(n)}configureAudio(t,e,r,n,s){this.i._configureAudio||console.warn('Attempting to use configureAudio without support for input audio. Is build dep ":gl_graph_runner_audio" missing?'),f(this,n||"input_audio",i=>{f(this,s=s||"audio_header",o=>{this.i._configureAudio(i,o,t,e,r)})})}setAutoResizeCanvas(t){this.l=t}setAutoRenderToScreen(t){this.i._setAutoRenderToScreen(t)}setGpuBufferVerticalFlip(t){this.i.gpuOriginForWebTexturesIsBottomLeft=t}aa(t){Ot(this,"__graph_config__",e=>{t(e)}),f(this,"__graph_config__",e=>{this.i._getGraphConfig(e,void 0)}),delete this.i.simpleListeners.__graph_config__}attachErrorListener(t){this.i.errorListener=t}attachEmptyPacketListener(t,e){this.i.emptyPacketListeners=this.i.emptyPacketListeners||{},this.i.emptyPacketListeners[t]=e}addAudioToStream(t,e,r){this.addAudioToStreamWithShape(t,0,0,e,r)}addAudioToStreamWithShape(t,e,r,n,s){const i=4*t.length;this.h!==i&&(this.g&&this.i._free(this.g),this.g=this.i._malloc(i),this.h=i),this.i.HEAPF32.set(t,this.g/4),f(this,n,o=>{this.i._addAudioToInputStream(this.g,e,r,o,s)})}addGpuBufferToStream(t,e,r){f(this,e,n=>{const[s,i]=vs(this,t,n);this.i._addBoundTextureToStream(n,s,i,r)})}addBoolToStream(t,e,r){f(this,e,n=>{this.i._addBoolToInputStream(t,n,r)})}addDoubleToStream(t,e,r){f(this,e,n=>{this.i._addDoubleToInputStream(t,n,r)})}addFloatToStream(t,e,r){f(this,e,n=>{this.i._addFloatToInputStream(t,n,r)})}addIntToStream(t,e,r){f(this,e,n=>{this.i._addIntToInputStream(t,n,r)})}addStringToStream(t,e,r){f(this,e,n=>{f(this,t,s=>{this.i._addStringToInputStream(s,n,r)})})}addStringRecordToStream(t,e,r){f(this,e,n=>{ws(this,Object.keys(t),s=>{ws(this,Object.values(t),i=>{this.i._addFlatHashMapToInputStream(s,i,Object.keys(t).length,n,r)})})})}addProtoToStream(t,e,r,n){f(this,r,s=>{f(this,e,i=>{const o=this.i._malloc(t.length);this.i.HEAPU8.set(t,o),this.i._addProtoToInputStream(o,t.length,i,s,n),this.i._free(o)})})}addEmptyPacketToStream(t,e){f(this,t,r=>{this.i._addEmptyPacketToInputStream(r,e)})}addBoolVectorToStream(t,e,r){f(this,e,n=>{const s=this.i._allocateBoolVector(t.length);if(!s)throw Error("Unable to allocate new bool vector on heap.");for(const i of t)this.i._addBoolVectorEntry(s,i);this.i._addBoolVectorToInputStream(s,n,r)})}addDoubleVectorToStream(t,e,r){f(this,e,n=>{const s=this.i._allocateDoubleVector(t.length);if(!s)throw Error("Unable to allocate new double vector on heap.");for(const i of t)this.i._addDoubleVectorEntry(s,i);this.i._addDoubleVectorToInputStream(s,n,r)})}addFloatVectorToStream(t,e,r){f(this,e,n=>{const s=this.i._allocateFloatVector(t.length);if(!s)throw Error("Unable to allocate new float vector on heap.");for(const i of t)this.i._addFloatVectorEntry(s,i);this.i._addFloatVectorToInputStream(s,n,r)})}addIntVectorToStream(t,e,r){f(this,e,n=>{const s=this.i._allocateIntVector(t.length);if(!s)throw Error("Unable to allocate new int vector on heap.");for(const i of t)this.i._addIntVectorEntry(s,i);this.i._addIntVectorToInputStream(s,n,r)})}addStringVectorToStream(t,e,r){f(this,e,n=>{const s=this.i._allocateStringVector(t.length);if(!s)throw Error("Unable to allocate new string vector on heap.");for(const i of t)f(this,i,o=>{this.i._addStringVectorEntry(s,o)});this.i._addStringVectorToInputStream(s,n,r)})}addBoolToInputSidePacket(t,e){f(this,e,r=>{this.i._addBoolToInputSidePacket(t,r)})}addDoubleToInputSidePacket(t,e){f(this,e,r=>{this.i._addDoubleToInputSidePacket(t,r)})}addFloatToInputSidePacket(t,e){f(this,e,r=>{this.i._addFloatToInputSidePacket(t,r)})}addIntToInputSidePacket(t,e){f(this,e,r=>{this.i._addIntToInputSidePacket(t,r)})}addStringToInputSidePacket(t,e){f(this,e,r=>{f(this,t,n=>{this.i._addStringToInputSidePacket(n,r)})})}addProtoToInputSidePacket(t,e,r){f(this,r,n=>{f(this,e,s=>{const i=this.i._malloc(t.length);this.i.HEAPU8.set(t,i),this.i._addProtoToInputSidePacket(i,t.length,s,n),this.i._free(i)})})}addBoolVectorToInputSidePacket(t,e){f(this,e,r=>{const n=this.i._allocateBoolVector(t.length);if(!n)throw Error("Unable to allocate new bool vector on heap.");for(const s of t)this.i._addBoolVectorEntry(n,s);this.i._addBoolVectorToInputSidePacket(n,r)})}addDoubleVectorToInputSidePacket(t,e){f(this,e,r=>{const n=this.i._allocateDoubleVector(t.length);if(!n)throw Error("Unable to allocate new double vector on heap.");for(const s of t)this.i._addDoubleVectorEntry(n,s);this.i._addDoubleVectorToInputSidePacket(n,r)})}addFloatVectorToInputSidePacket(t,e){f(this,e,r=>{const n=this.i._allocateFloatVector(t.length);if(!n)throw Error("Unable to allocate new float vector on heap.");for(const s of t)this.i._addFloatVectorEntry(n,s);this.i._addFloatVectorToInputSidePacket(n,r)})}addIntVectorToInputSidePacket(t,e){f(this,e,r=>{const n=this.i._allocateIntVector(t.length);if(!n)throw Error("Unable to allocate new int vector on heap.");for(const s of t)this.i._addIntVectorEntry(n,s);this.i._addIntVectorToInputSidePacket(n,r)})}addStringVectorToInputSidePacket(t,e){f(this,e,r=>{const n=this.i._allocateStringVector(t.length);if(!n)throw Error("Unable to allocate new string vector on heap.");for(const s of t)f(this,s,i=>{this.i._addStringVectorEntry(n,i)});this.i._addStringVectorToInputSidePacket(n,r)})}attachBoolListener(t,e){Ot(this,t,e),f(this,t,r=>{this.i._attachBoolListener(r)})}attachBoolVectorListener(t,e){Kt(this,t,e),f(this,t,r=>{this.i._attachBoolVectorListener(r)})}attachIntListener(t,e){Ot(this,t,e),f(this,t,r=>{this.i._attachIntListener(r)})}attachIntVectorListener(t,e){Kt(this,t,e),f(this,t,r=>{this.i._attachIntVectorListener(r)})}attachDoubleListener(t,e){Ot(this,t,e),f(this,t,r=>{this.i._attachDoubleListener(r)})}attachDoubleVectorListener(t,e){Kt(this,t,e),f(this,t,r=>{this.i._attachDoubleVectorListener(r)})}attachFloatListener(t,e){Ot(this,t,e),f(this,t,r=>{this.i._attachFloatListener(r)})}attachFloatVectorListener(t,e){Kt(this,t,e),f(this,t,r=>{this.i._attachFloatVectorListener(r)})}attachStringListener(t,e){Ot(this,t,e),f(this,t,r=>{this.i._attachStringListener(r)})}attachStringVectorListener(t,e){Kt(this,t,e),f(this,t,r=>{this.i._attachStringVectorListener(r)})}attachProtoListener(t,e,r){Ot(this,t,e),f(this,t,n=>{this.i._attachProtoListener(n,r||!1)})}attachProtoVectorListener(t,e,r){Kt(this,t,e),f(this,t,n=>{this.i._attachProtoVectorListener(n,r||!1)})}attachAudioListener(t,e,r){this.i._attachAudioListener||console.warn('Attempting to use attachAudioListener without support for output audio. Is build dep ":gl_graph_runner_audio_out" missing?'),Ot(this,t,(n,s)=>{n=new Float32Array(n.buffer,n.byteOffset,n.length/4),e(n,s)}),f(this,t,n=>{this.i._attachAudioListener(n,r||!1)})}finishProcessing(){this.i._waitUntilIdle()}closeGraph(){this.i._closeGraph(),this.i.simpleListeners=void 0,this.i.emptyPacketListeners=void 0}},class extends Fs{get ca(){return this.i}pa(t,e,r){f(this,e,n=>{const[s,i]=vs(this,t,n);this.ca._addBoundTextureAsImageToStream(n,s,i,r)})}X(t,e){Ot(this,t,e),f(this,t,r=>{this.ca._attachImageListener(r)})}Y(t,e){Kt(this,t,e),f(this,t,r=>{this.ca._attachImageVectorListener(r)})}}));var Fs,wt=class extends U2{};async function y(t,e,r){return async function(n,s,i,o){return B2(n,s,i,o)}(t,r.canvas??(typeof OffscreenCanvas>"u"||Ro()?document.createElement("canvas"):void 0),e,r)}function zo(t,e,r,n){if(t.da){const i=new Zi;if(r!=null&&r.regionOfInterest){if(!t.na)throw Error("This task doesn't support region-of-interest.");var s=r.regionOfInterest;if(s.left>=s.right||s.top>=s.bottom)throw Error("Expected RectF with left < right and top < bottom.");if(0>s.left||0>s.top||1<s.right||1<s.bottom)throw Error("Expected RectF values to be in [0,1].");g(i,1,(s.left+s.right)/2),g(i,2,(s.top+s.bottom)/2),g(i,4,s.right-s.left),g(i,3,s.bottom-s.top)}else g(i,1,.5),g(i,2,.5),g(i,4,1),g(i,3,1);if(r!=null&&r.rotationDegrees){if((r==null?void 0:r.rotationDegrees)%90!=0)throw Error("Expected rotation to be a multiple of 90°.");if(g(i,5,-Math.PI*r.rotationDegrees/180),(r==null?void 0:r.rotationDegrees)%180!=0){const[o,c]=e.videoWidth!==void 0?[e.videoWidth,e.videoHeight]:e.naturalWidth!==void 0?[e.naturalWidth,e.naturalHeight]:[e.width,e.height];r=H(i,3)*c/o,s=H(i,4)*o/c,g(i,4,r),g(i,3,s)}}t.g.addProtoToStream(i.g(),"mediapipe.NormalizedRect",t.da,n)}t.g.pa(e,t.ma,n??performance.now()),t.finishProcessing()}function bt(t,e,r){var n;if((n=t.baseOptions)!=null&&n.g())throw Error("Task is not initialized with image mode. 'runningMode' must be set to 'IMAGE'.");zo(t,e,r,t.N+1)}function Ct(t,e,r,n){var s;if(!((s=t.baseOptions)!=null&&s.g()))throw Error("Task is not initialized with video mode. 'runningMode' must be set to 'VIDEO'.");zo(t,e,r,n)}function Te(t,e,r){var n=e.data;const s=e.width,i=s*(e=e.height);if((n instanceof Uint8Array||n instanceof Float32Array)&&n.length!==i)throw Error("Unsupported channel count: "+n.length/i);return t=new j([n],!1,t.g.i.canvas,t.U,s,e),r?t.clone():t}var st=class extends Kr{constructor(t,e,r,n){super(t),this.g=t,this.ma=e,this.da=r,this.na=n,this.U=new Gn}l(t,e=!0){if("runningMode"in t&&Ee(this.baseOptions,2,!!t.runningMode&&t.runningMode!=="IMAGE"),t.canvas!==void 0&&this.g.i.canvas!==t.canvas)throw Error("You must create a new task to reset the canvas.");return super.l(t,e)}close(){this.U.close(),super.close()}};st.prototype.close=st.prototype.close;var it=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect_in",!1),this.j={detections:[]},this.h=new Mn,t=new I,p(this.h,0,1,t),g(this.h,2,.5),g(this.h,3,.3)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){return"minDetectionConfidence"in t&&g(this.h,2,t.minDetectionConfidence??.5),"minSuppressionThreshold"in t&&g(this.h,3,t.minSuppressionThreshold??.3),this.l(t)}F(t,e){return this.j={detections:[]},bt(this,t,e),this.j}G(t,e,r){return this.j={detections:[]},Ct(this,t,r,e),this.j}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect_in"),S(t,"detections");const e=new dt;yt(e,_2,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.face_detector.FaceDetectorGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect_in"),w(r,"DETECTIONS:detections"),r.o(e),mt(t,r),this.g.attachProtoVectorListener("detections",(n,s)=>{for(const i of n)n=Xi(i),this.j.detections.push(Mo(n));d(this,s)}),this.g.attachEmptyPacketListener("detections",n=>{d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};it.prototype.detectForVideo=it.prototype.G,it.prototype.detect=it.prototype.F,it.prototype.setOptions=it.prototype.o,it.createFromModelPath=async function(t,e){return y(it,t,{baseOptions:{modelAssetPath:e}})},it.createFromModelBuffer=function(t,e){return y(it,t,{baseOptions:{modelAssetBuffer:e}})},it.createFromOptions=function(t,e){return y(it,t,e)};var Wo=vt([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]),Ho=vt([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]),Xo=vt([276,283],[283,282],[282,295],[295,285],[300,293],[293,334],[334,296],[296,336]),N2=vt([474,475],[475,476],[476,477],[477,474]),Ko=vt([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]),$o=vt([46,53],[53,52],[52,65],[65,55],[70,63],[63,105],[105,66],[66,107]),G2=vt([469,470],[470,471],[471,472],[472,469]),qo=vt([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]),j2=[...Wo,...Ho,...Xo,...Ko,...$o,...qo],V2=vt([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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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],[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]);function Ls(t){t.j={faceLandmarks:[],faceBlendshapes:[],facialTransformationMatrixes:[]}}var M=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!1),this.j={faceLandmarks:[],faceBlendshapes:[],facialTransformationMatrixes:[]},this.outputFacialTransformationMatrixes=this.outputFaceBlendshapes=!1,this.h=new ho,t=new I,p(this.h,0,1,t),this.v=new w2,p(this.h,0,3,this.v),this.u=new Mn,p(this.h,0,2,this.u),xt(this.u,4,1),g(this.u,2,.5),g(this.v,2,.5),g(this.h,4,.5)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){return"numFaces"in t&&xt(this.u,4,t.numFaces??1),"minFaceDetectionConfidence"in t&&g(this.u,2,t.minFaceDetectionConfidence??.5),"minTrackingConfidence"in t&&g(this.h,4,t.minTrackingConfidence??.5),"minFacePresenceConfidence"in t&&g(this.v,2,t.minFacePresenceConfidence??.5),"outputFaceBlendshapes"in t&&(this.outputFaceBlendshapes=!!t.outputFaceBlendshapes),"outputFacialTransformationMatrixes"in t&&(this.outputFacialTransformationMatrixes=!!t.outputFacialTransformationMatrixes),this.l(t)}F(t,e){return Ls(this),bt(this,t,e),this.j}G(t,e,r){return Ls(this),Ct(this,t,r,e),this.j}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect"),S(t,"face_landmarks");const e=new dt;yt(e,b2,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.face_landmarker.FaceLandmarkerGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),w(r,"NORM_LANDMARKS:face_landmarks"),r.o(e),mt(t,r),this.g.attachProtoVectorListener("face_landmarks",(n,s)=>{for(const i of n)n=_r(i),this.j.faceLandmarks.push(Cn(n));d(this,s)}),this.g.attachEmptyPacketListener("face_landmarks",n=>{d(this,n)}),this.outputFaceBlendshapes&&(S(t,"blendshapes"),w(r,"BLENDSHAPES:blendshapes"),this.g.attachProtoVectorListener("blendshapes",(n,s)=>{if(this.outputFaceBlendshapes)for(const i of n)n=Ln(i),this.j.faceBlendshapes.push(Oo(n.g()??[]));d(this,s)}),this.g.attachEmptyPacketListener("blendshapes",n=>{d(this,n)})),this.outputFacialTransformationMatrixes&&(S(t,"face_geometry"),w(r,"FACE_GEOMETRY:face_geometry"),this.g.attachProtoVectorListener("face_geometry",(n,s)=>{if(this.outputFacialTransformationMatrixes)for(const i of n)(n=v(v2(i),Ji,2))&&this.j.facialTransformationMatrixes.push({rows:St(ht(n,1))??0,columns:St(ht(n,2))??0,data:te(n,3,zt)??[]});d(this,s)}),this.g.attachEmptyPacketListener("face_geometry",n=>{d(this,n)})),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};M.prototype.detectForVideo=M.prototype.G,M.prototype.detect=M.prototype.F,M.prototype.setOptions=M.prototype.o,M.createFromModelPath=function(t,e){return y(M,t,{baseOptions:{modelAssetPath:e}})},M.createFromModelBuffer=function(t,e){return y(M,t,{baseOptions:{modelAssetBuffer:e}})},M.createFromOptions=function(t,e){return y(M,t,e)},M.FACE_LANDMARKS_LIPS=Wo,M.FACE_LANDMARKS_LEFT_EYE=Ho,M.FACE_LANDMARKS_LEFT_EYEBROW=Xo,M.FACE_LANDMARKS_LEFT_IRIS=N2,M.FACE_LANDMARKS_RIGHT_EYE=Ko,M.FACE_LANDMARKS_RIGHT_EYEBROW=$o,M.FACE_LANDMARKS_RIGHT_IRIS=G2,M.FACE_LANDMARKS_FACE_OVAL=qo,M.FACE_LANDMARKS_CONTOURS=j2,M.FACE_LANDMARKS_TESSELATION=V2;var Et=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!0),this.j=new lo,t=new I,p(this.j,0,1,t)}get baseOptions(){return v(this.j,I,1)}set baseOptions(t){p(this.j,0,1,t)}o(t){return super.l(t)}Pa(t,e,r){const n=typeof e!="function"?e:{};if(this.h=typeof e=="function"?e:r,bt(this,t,n??{}),!this.h)return this.u}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect"),S(t,"stylized_image");const e=new dt;yt(e,E2,this.j);const r=new $;gt(r,"mediapipe.tasks.vision.face_stylizer.FaceStylizerGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),w(r,"STYLIZED_IMAGE:stylized_image"),r.o(e),mt(t,r),this.g.X("stylized_image",(n,s)=>{var i=!this.h,o=n.data,c=n.width;const a=c*(n=n.height);if(o instanceof Uint8Array)if(o.length===3*a){const h=new Uint8ClampedArray(4*a);for(let u=0;u<a;++u)h[4*u]=o[3*u],h[4*u+1]=o[3*u+1],h[4*u+2]=o[3*u+2],h[4*u+3]=255;o=new ImageData(h,c,n)}else{if(o.length!==4*a)throw Error("Unsupported channel count: "+o.length/a);o=new ImageData(new Uint8ClampedArray(o.buffer,o.byteOffset,o.length),c,n)}else if(!(o instanceof WebGLTexture))throw Error(`Unsupported format: ${o.constructor.name}`);c=new V([o],!1,!1,this.g.i.canvas,this.U,c,n),this.u=i=i?c.clone():c,this.h&&this.h(i),d(this,s)}),this.g.attachEmptyPacketListener("stylized_image",n=>{this.u=null,this.h&&this.h(null),d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};Et.prototype.stylize=Et.prototype.Pa,Et.prototype.setOptions=Et.prototype.o,Et.createFromModelPath=function(t,e){return y(Et,t,{baseOptions:{modelAssetPath:e}})},Et.createFromModelBuffer=function(t,e){return y(Et,t,{baseOptions:{modelAssetBuffer:e}})},Et.createFromOptions=function(t,e){return y(Et,t,e)};var Yo=vt([0,1],[1,2],[2,3],[3,4],[0,5],[5,6],[6,7],[7,8],[5,9],[9,10],[10,11],[11,12],[9,13],[13,14],[14,15],[15,16],[13,17],[0,17],[17,18],[18,19],[19,20]);function Os(t){t.gestures=[],t.landmarks=[],t.worldLandmarks=[],t.handedness=[]}function Ms(t){return t.gestures.length===0?{gestures:[],landmarks:[],worldLandmarks:[],handedness:[],handednesses:[]}:{gestures:t.gestures,landmarks:t.landmarks,worldLandmarks:t.worldLandmarks,handedness:t.handedness,handednesses:t.handedness}}function Ps(t,e=!0){const r=[];for(const s of t){var n=Ln(s);t=[];for(const i of n.g())n=e&&ht(i,1)!=null?St(ht(i,1)):-1,t.push({score:H(i,2)??0,index:n,categoryName:ft(i,3)??""??"",displayName:ft(i,4)??""??""});r.push(t)}return r}var tt=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!1),this.gestures=[],this.landmarks=[],this.worldLandmarks=[],this.handedness=[],this.v=new bo,t=new I,p(this.v,0,1,t),this.C=new Pn,p(this.v,0,2,this.C),this.u=new _o,p(this.C,0,3,this.u),this.h=new mo,p(this.C,0,2,this.h),this.j=new A2,p(this.v,0,3,this.j),g(this.h,2,.5),g(this.C,4,.5),g(this.u,2,.5)}get baseOptions(){return v(this.v,I,1)}set baseOptions(t){p(this.v,0,1,t)}o(t){var n,s,i,o;if(xt(this.h,3,t.numHands??1),"minHandDetectionConfidence"in t&&g(this.h,2,t.minHandDetectionConfidence??.5),"minTrackingConfidence"in t&&g(this.C,4,t.minTrackingConfidence??.5),"minHandPresenceConfidence"in t&&g(this.u,2,t.minHandPresenceConfidence??.5),t.cannedGesturesClassifierOptions){var e=new Zt,r=Xr(t.cannedGesturesClassifierOptions,(n=v(this.j,Zt,3))==null?void 0:n.h());p(e,0,2,r),p(this.j,0,3,e)}else t.cannedGesturesClassifierOptions===void 0&&((s=v(this.j,Zt,3))==null||s.g());return t.customGesturesClassifierOptions?(p(e=new Zt,0,2,r=Xr(t.customGesturesClassifierOptions,(i=v(this.j,Zt,4))==null?void 0:i.h())),p(this.j,0,4,e)):t.customGesturesClassifierOptions===void 0&&((o=v(this.j,Zt,4))==null||o.g()),this.l(t)}Ka(t,e){return Os(this),bt(this,t,e),Ms(this)}La(t,e,r){return Os(this),Ct(this,t,r,e),Ms(this)}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect"),S(t,"hand_gestures"),S(t,"hand_landmarks"),S(t,"world_hand_landmarks"),S(t,"handedness");const e=new dt;yt(e,S2,this.v);const r=new $;gt(r,"mediapipe.tasks.vision.gesture_recognizer.GestureRecognizerGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),w(r,"HAND_GESTURES:hand_gestures"),w(r,"LANDMARKS:hand_landmarks"),w(r,"WORLD_LANDMARKS:world_hand_landmarks"),w(r,"HANDEDNESS:handedness"),r.o(e),mt(t,r),this.g.attachProtoVectorListener("hand_landmarks",(n,s)=>{for(const i of n){n=_r(i);const o=[];for(const c of It(n,qi,1))o.push({x:H(c,1)??0,y:H(c,2)??0,z:H(c,3)??0});this.landmarks.push(o)}d(this,s)}),this.g.attachEmptyPacketListener("hand_landmarks",n=>{d(this,n)}),this.g.attachProtoVectorListener("world_hand_landmarks",(n,s)=>{for(const i of n){n=On(i);const o=[];for(const c of It(n,Ki,1))o.push({x:H(c,1)??0,y:H(c,2)??0,z:H(c,3)??0});this.worldLandmarks.push(o)}d(this,s)}),this.g.attachEmptyPacketListener("world_hand_landmarks",n=>{d(this,n)}),this.g.attachProtoVectorListener("hand_gestures",(n,s)=>{this.gestures.push(...Ps(n,!1)),d(this,s)}),this.g.attachEmptyPacketListener("hand_gestures",n=>{d(this,n)}),this.g.attachProtoVectorListener("handedness",(n,s)=>{this.handedness.push(...Ps(n)),d(this,s)}),this.g.attachEmptyPacketListener("handedness",n=>{d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};function Is(t){return{landmarks:t.landmarks,worldLandmarks:t.worldLandmarks,handednesses:t.handedness,handedness:t.handedness}}tt.prototype.recognizeForVideo=tt.prototype.La,tt.prototype.recognize=tt.prototype.Ka,tt.prototype.setOptions=tt.prototype.o,tt.createFromModelPath=function(t,e){return y(tt,t,{baseOptions:{modelAssetPath:e}})},tt.createFromModelBuffer=function(t,e){return y(tt,t,{baseOptions:{modelAssetBuffer:e}})},tt.createFromOptions=function(t,e){return y(tt,t,e)},tt.HAND_CONNECTIONS=Yo;var et=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!1),this.landmarks=[],this.worldLandmarks=[],this.handedness=[],this.j=new Pn,t=new I,p(this.j,0,1,t),this.u=new _o,p(this.j,0,3,this.u),this.h=new mo,p(this.j,0,2,this.h),xt(this.h,3,1),g(this.h,2,.5),g(this.u,2,.5),g(this.j,4,.5)}get baseOptions(){return v(this.j,I,1)}set baseOptions(t){p(this.j,0,1,t)}o(t){return"numHands"in t&&xt(this.h,3,t.numHands??1),"minHandDetectionConfidence"in t&&g(this.h,2,t.minHandDetectionConfidence??.5),"minTrackingConfidence"in t&&g(this.j,4,t.minTrackingConfidence??.5),"minHandPresenceConfidence"in t&&g(this.u,2,t.minHandPresenceConfidence??.5),this.l(t)}F(t,e){return this.landmarks=[],this.worldLandmarks=[],this.handedness=[],bt(this,t,e),Is(this)}G(t,e,r){return this.landmarks=[],this.worldLandmarks=[],this.handedness=[],Ct(this,t,r,e),Is(this)}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect"),S(t,"hand_landmarks"),S(t,"world_hand_landmarks"),S(t,"handedness");const e=new dt;yt(e,k2,this.j);const r=new $;gt(r,"mediapipe.tasks.vision.hand_landmarker.HandLandmarkerGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),w(r,"LANDMARKS:hand_landmarks"),w(r,"WORLD_LANDMARKS:world_hand_landmarks"),w(r,"HANDEDNESS:handedness"),r.o(e),mt(t,r),this.g.attachProtoVectorListener("hand_landmarks",(n,s)=>{for(const i of n)n=_r(i),this.landmarks.push(Cn(n));d(this,s)}),this.g.attachEmptyPacketListener("hand_landmarks",n=>{d(this,n)}),this.g.attachProtoVectorListener("world_hand_landmarks",(n,s)=>{for(const i of n)n=On(i),this.worldLandmarks.push(Po(n));d(this,s)}),this.g.attachEmptyPacketListener("world_hand_landmarks",n=>{d(this,n)}),this.g.attachProtoVectorListener("handedness",(n,s)=>{var i=this.handedness,o=i.push;const c=[];for(const a of n){n=Ln(a);const h=[];for(const u of n.g())h.push({score:H(u,2)??0,index:St(ht(u,1))??-1,categoryName:ft(u,3)??""??"",displayName:ft(u,4)??""??""});c.push(h)}o.call(i,...c),d(this,s)}),this.g.attachEmptyPacketListener("handedness",n=>{d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};et.prototype.detectForVideo=et.prototype.G,et.prototype.detect=et.prototype.F,et.prototype.setOptions=et.prototype.o,et.createFromModelPath=function(t,e){return y(et,t,{baseOptions:{modelAssetPath:e}})},et.createFromModelBuffer=function(t,e){return y(et,t,{baseOptions:{modelAssetBuffer:e}})},et.createFromOptions=function(t,e){return y(et,t,e)},et.HAND_CONNECTIONS=Yo;var ot=class extends st{constructor(t,e){super(new wt(t,e),"input_image","norm_rect",!0),this.j={classifications:[]},this.h=new Eo,t=new I,p(this.h,0,1,t)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){var e=Xr(t,v(this.h,vr,2));return p(this.h,0,2,e),this.l(t)}sa(t,e){return this.j={classifications:[]},bt(this,t,e),this.j}ta(t,e,r){return this.j={classifications:[]},Ct(this,t,r,e),this.j}m(){var t=new Q;F(t,"input_image"),F(t,"norm_rect"),S(t,"classifications");const e=new dt;yt(e,x2,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.image_classifier.ImageClassifierGraph"),A(r,"IMAGE:input_image"),A(r,"NORM_RECT:norm_rect"),w(r,"CLASSIFICATIONS:classifications"),r.o(e),mt(t,r),this.g.attachProtoListener("classifications",(n,s)=>{this.j=function(i){const o={classifications:It(i,u2,1).map(c=>{var a;return Oo(((a=v(c,Fn,4))==null?void 0:a.g())??[],St(ht(c,2)),ft(c,3)??"")})};return Qe(se(i,2))!=null&&(o.timestampMs=St(Qe(se(i,2)))),o}(f2(n)),d(this,s)}),this.g.attachEmptyPacketListener("classifications",n=>{d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};ot.prototype.classifyForVideo=ot.prototype.ta,ot.prototype.classify=ot.prototype.sa,ot.prototype.setOptions=ot.prototype.o,ot.createFromModelPath=function(t,e){return y(ot,t,{baseOptions:{modelAssetPath:e}})},ot.createFromModelBuffer=function(t,e){return y(ot,t,{baseOptions:{modelAssetBuffer:e}})},ot.createFromOptions=function(t,e){return y(ot,t,e)};var rt=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!0),this.h=new Ao,this.embeddings={embeddings:[]},t=new I,p(this.h,0,1,t)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){var e=this.h,r=v(this.h,ps,2);return r=r?r.clone():new ps,t.l2Normalize!==void 0?Ee(r,1,t.l2Normalize):"l2Normalize"in t&&b(r,1),t.quantize!==void 0?Ee(r,2,t.quantize):"quantize"in t&&b(r,2),p(e,0,2,r),this.l(t)}xa(t,e){return bt(this,t,e),this.embeddings}ya(t,e,r){return Ct(this,t,r,e),this.embeddings}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect"),S(t,"embeddings_out");const e=new dt;yt(e,F2,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.image_embedder.ImageEmbedderGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),w(r,"EMBEDDINGS:embeddings_out"),r.o(e),mt(t,r),this.g.attachProtoListener("embeddings_out",(n,s)=>{n=m2(n),this.embeddings=function(i){return{embeddings:It(i,p2,1).map(o=>{var a,h;const c={headIndex:St(ht(o,3))??-1,headName:ft(o,4)??""??""};if(yi(o,Wr,Lr(o,1))!==void 0)o=te(o=v(o,Wr,Lr(o,1)),1,zt),c.floatEmbedding=o;else{const u=new Uint8Array(0);c.quantizedEmbedding=((h=(a=v(o,d2,Lr(o,2)))==null?void 0:a.oa())==null?void 0:h.qa())??u}return c}),timestampMs:St(Qe(se(i,2)))}}(n),d(this,s)}),this.g.attachEmptyPacketListener("embeddings_out",n=>{d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};rt.cosineSimilarity=function(t,e){if(t.floatEmbedding&&e.floatEmbedding)t=ys(t.floatEmbedding,e.floatEmbedding);else{if(!t.quantizedEmbedding||!e.quantizedEmbedding)throw Error("Cannot compute cosine similarity between quantized and float embeddings.");t=ys(ms(t.quantizedEmbedding),ms(e.quantizedEmbedding))}return t},rt.prototype.embedForVideo=rt.prototype.ya,rt.prototype.embed=rt.prototype.xa,rt.prototype.setOptions=rt.prototype.o,rt.createFromModelPath=function(t,e){return y(rt,t,{baseOptions:{modelAssetPath:e}})},rt.createFromModelBuffer=function(t,e){return y(rt,t,{baseOptions:{modelAssetBuffer:e}})},rt.createFromOptions=function(t,e){return y(rt,t,e)};var Yr=class{constructor(t,e,r){this.confidenceMasks=t,this.categoryMask=e,this.qualityScores=r}close(){var t,e;(t=this.confidenceMasks)==null||t.forEach(r=>{r.close()}),(e=this.categoryMask)==null||e.close()}};function Rs(t){t.categoryMask=void 0,t.confidenceMasks=void 0,t.qualityScores=void 0}function Cs(t){try{const e=new Yr(t.confidenceMasks,t.categoryMask,t.qualityScores);if(!t.j)return e;t.j(e)}finally{Dn(t)}}Yr.prototype.close=Yr.prototype.close;var q=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!1),this.u=[],this.outputCategoryMask=!1,this.outputConfidenceMasks=!0,this.h=new In,this.v=new To,p(this.h,0,3,this.v),t=new I,p(this.h,0,1,t)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){return t.displayNamesLocale!==void 0?b(this.h,2,Oe(t.displayNamesLocale)):"displayNamesLocale"in t&&b(this.h,2),"outputCategoryMask"in t&&(this.outputCategoryMask=t.outputCategoryMask??!1),"outputConfidenceMasks"in t&&(this.outputConfidenceMasks=t.outputConfidenceMasks??!0),super.l(t)}V(){(function(t){var r,n;const e=It(t.aa(),$,1).filter(s=>(ft(s,1)??"").includes("mediapipe.tasks.TensorsToSegmentationCalculator"));if(t.u=[],1<e.length)throw Error("The graph has more than one mediapipe.tasks.TensorsToSegmentationCalculator.");e.length===1&&(((n=(r=v(e[0],dt,7))==null?void 0:r.l())==null?void 0:n.g())??new Map).forEach((s,i)=>{t.u[Number(i)]=ft(s,1)??""})})(this)}ba(t,e,r){const n=typeof e!="function"?e:{};return this.j=typeof e=="function"?e:r,Rs(this),bt(this,t,n),Cs(this)}Na(t,e,r,n){const s=typeof r!="function"?r:{};return this.j=typeof r=="function"?r:n,Rs(this),Ct(this,t,s,e),Cs(this)}Da(){return this.u}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect");const e=new dt;yt(e,So,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.image_segmenter.ImageSegmenterGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),r.o(e),mt(t,r),Bn(this,t),this.outputConfidenceMasks&&(S(t,"confidence_masks"),w(r,"CONFIDENCE_MASKS:confidence_masks"),Ae(this,"confidence_masks"),this.g.Y("confidence_masks",(n,s)=>{this.confidenceMasks=n.map(i=>Te(this,i,!this.j)),d(this,s)}),this.g.attachEmptyPacketListener("confidence_masks",n=>{this.confidenceMasks=[],d(this,n)})),this.outputCategoryMask&&(S(t,"category_mask"),w(r,"CATEGORY_MASK:category_mask"),Ae(this,"category_mask"),this.g.X("category_mask",(n,s)=>{this.categoryMask=Te(this,n,!this.j),d(this,s)}),this.g.attachEmptyPacketListener("category_mask",n=>{this.categoryMask=void 0,d(this,n)})),S(t,"quality_scores"),w(r,"QUALITY_SCORES:quality_scores"),this.g.attachFloatVectorListener("quality_scores",(n,s)=>{this.qualityScores=n,d(this,s)}),this.g.attachEmptyPacketListener("quality_scores",n=>{this.categoryMask=void 0,d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};q.prototype.getLabels=q.prototype.Da,q.prototype.segmentForVideo=q.prototype.Na,q.prototype.segment=q.prototype.ba,q.prototype.setOptions=q.prototype.o,q.createFromModelPath=function(t,e){return y(q,t,{baseOptions:{modelAssetPath:e}})},q.createFromModelBuffer=function(t,e){return y(q,t,{baseOptions:{modelAssetBuffer:e}})},q.createFromOptions=function(t,e){return y(q,t,e)};var Jr=class{constructor(t,e,r){this.confidenceMasks=t,this.categoryMask=e,this.qualityScores=r}close(){var t,e;(t=this.confidenceMasks)==null||t.forEach(r=>{r.close()}),(e=this.categoryMask)==null||e.close()}};Jr.prototype.close=Jr.prototype.close;var z2=class extends l{constructor(t){super(t)}},oe=[0,R,-2],W2=[0,Pt,-3,B],br=[0,Pt,-3,B,Pt,-1],Jo=[0,br],H2=[0,Jo,oe],X2=[0,br,oe],Zo=[0,br,R,-1],K2=[0,Zo,oe],$2=[0,Pt,-3,B,oe,-1],q2=[0,Pt,-3,B,Ft],Pr=class extends l{constructor(t){super(t)}},Bs=[0,Pt,-1,B],Qo=class extends l{constructor(){super()}};Qo.A=[1];var Ds=class extends l{constructor(t){super(t)}},Zr=[1,2,3,4,5,6,7,8,9,10,14,15],Y2=[0,Zr,k,br,k,X2,k,Jo,k,H2,k,Bs,k,q2,k,W2,k,[0,T,Pt,-2,B,R,B,-1,2,Pt,oe],k,Zo,k,K2,Pt,oe,T,k,$2,k,[0,D,Bs]],J2=[0,T,R,-1,B],Qr=class extends l{constructor(){super()}};Qr.A=[1],Qr.prototype.g=xn([0,D,Y2,T,J2]);var At=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect_in",!1),this.outputCategoryMask=!1,this.outputConfidenceMasks=!0,this.h=new In,this.v=new To,p(this.h,0,3,this.v),t=new I,p(this.h,0,1,t)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){return"outputCategoryMask"in t&&(this.outputCategoryMask=t.outputCategoryMask??!1),"outputConfidenceMasks"in t&&(this.outputConfidenceMasks=t.outputConfidenceMasks??!0),super.l(t)}ba(t,e,r,n){const s=typeof r!="function"?r:{};this.j=typeof r=="function"?r:n,this.qualityScores=this.categoryMask=this.confidenceMasks=void 0,r=this.N+1,n=new Qr;const i=new Ds;var o=new z2;if(xt(o,1,255),p(i,0,12,o),e.keypoint&&e.scribble)throw Error("Cannot provide both keypoint and scribble.");if(e.keypoint){var c=new Pr;Ee(c,3,!0),g(c,1,e.keypoint.x),g(c,2,e.keypoint.y),ge(i,5,Zr,c)}else{if(!e.scribble)throw Error("Must provide either a keypoint or a scribble.");for(c of(o=new Qo,e.scribble))Ee(e=new Pr,3,!0),g(e,1,c.x),g(e,2,c.y),zr(o,Pr,e);ge(i,15,Zr,o)}zr(n,Ds,i),this.g.addProtoToStream(n.g(),"drishti.RenderData","roi_in",r),bt(this,t,s);t:{try{const h=new Jr(this.confidenceMasks,this.categoryMask,this.qualityScores);if(!this.j){var a=h;break t}this.j(h)}finally{Dn(this)}a=void 0}return a}m(){var t=new Q;F(t,"image_in"),F(t,"roi_in"),F(t,"norm_rect_in");const e=new dt;yt(e,So,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.interactive_segmenter.InteractiveSegmenterGraph"),A(r,"IMAGE:image_in"),A(r,"ROI:roi_in"),A(r,"NORM_RECT:norm_rect_in"),r.o(e),mt(t,r),Bn(this,t),this.outputConfidenceMasks&&(S(t,"confidence_masks"),w(r,"CONFIDENCE_MASKS:confidence_masks"),Ae(this,"confidence_masks"),this.g.Y("confidence_masks",(n,s)=>{this.confidenceMasks=n.map(i=>Te(this,i,!this.j)),d(this,s)}),this.g.attachEmptyPacketListener("confidence_masks",n=>{this.confidenceMasks=[],d(this,n)})),this.outputCategoryMask&&(S(t,"category_mask"),w(r,"CATEGORY_MASK:category_mask"),Ae(this,"category_mask"),this.g.X("category_mask",(n,s)=>{this.categoryMask=Te(this,n,!this.j),d(this,s)}),this.g.attachEmptyPacketListener("category_mask",n=>{this.categoryMask=void 0,d(this,n)})),S(t,"quality_scores"),w(r,"QUALITY_SCORES:quality_scores"),this.g.attachFloatVectorListener("quality_scores",(n,s)=>{this.qualityScores=n,d(this,s)}),this.g.attachEmptyPacketListener("quality_scores",n=>{this.categoryMask=void 0,d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};At.prototype.segment=At.prototype.ba,At.prototype.setOptions=At.prototype.o,At.createFromModelPath=function(t,e){return y(At,t,{baseOptions:{modelAssetPath:e}})},At.createFromModelBuffer=function(t,e){return y(At,t,{baseOptions:{modelAssetBuffer:e}})},At.createFromOptions=function(t,e){return y(At,t,e)};var at=class extends st{constructor(t,e){super(new wt(t,e),"input_frame_gpu","norm_rect",!1),this.j={detections:[]},this.h=new Rn,t=new I,p(this.h,0,1,t)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){return t.displayNamesLocale!==void 0?b(this.h,2,Oe(t.displayNamesLocale)):"displayNamesLocale"in t&&b(this.h,2),t.maxResults!==void 0?xt(this.h,3,t.maxResults):"maxResults"in t&&b(this.h,3),t.scoreThreshold!==void 0?g(this.h,4,t.scoreThreshold):"scoreThreshold"in t&&b(this.h,4),t.categoryAllowlist!==void 0?rr(this.h,5,t.categoryAllowlist):"categoryAllowlist"in t&&b(this.h,5),t.categoryDenylist!==void 0?rr(this.h,6,t.categoryDenylist):"categoryDenylist"in t&&b(this.h,6),this.l(t)}F(t,e){return this.j={detections:[]},bt(this,t,e),this.j}G(t,e,r){return this.j={detections:[]},Ct(this,t,r,e),this.j}m(){var t=new Q;F(t,"input_frame_gpu"),F(t,"norm_rect"),S(t,"detections");const e=new dt;yt(e,O2,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.ObjectDetectorGraph"),A(r,"IMAGE:input_frame_gpu"),A(r,"NORM_RECT:norm_rect"),w(r,"DETECTIONS:detections"),r.o(e),mt(t,r),this.g.attachProtoVectorListener("detections",(n,s)=>{for(const i of n)n=Xi(i),this.j.detections.push(Mo(n));d(this,s)}),this.g.attachEmptyPacketListener("detections",n=>{d(this,n)}),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};at.prototype.detectForVideo=at.prototype.G,at.prototype.detect=at.prototype.F,at.prototype.setOptions=at.prototype.o,at.createFromModelPath=async function(t,e){return y(at,t,{baseOptions:{modelAssetPath:e}})},at.createFromModelBuffer=function(t,e){return y(at,t,{baseOptions:{modelAssetBuffer:e}})},at.createFromOptions=function(t,e){return y(at,t,e)};function Us(t){t.landmarks=[],t.worldLandmarks=[],t.v=void 0}function Ns(t){try{const e=new class{constructor(r,n,s){this.landmarks=r,this.worldLandmarks=n,this.g=s}close(){var r;(r=this.g)==null||r.forEach(n=>{n.close()})}}(t.landmarks,t.worldLandmarks,t.v);if(!t.u)return e;t.u(e)}finally{Dn(t)}}var nt=class extends st{constructor(t,e){super(new wt(t,e),"image_in","norm_rect",!1),this.landmarks=[],this.worldLandmarks=[],this.outputSegmentationMasks=!1,this.h=new Lo,t=new I,p(this.h,0,1,t),this.C=new P2,p(this.h,0,3,this.C),this.j=new M2,p(this.h,0,2,this.j),xt(this.j,4,1),g(this.j,2,.5),g(this.C,2,.5),g(this.h,4,.5)}get baseOptions(){return v(this.h,I,1)}set baseOptions(t){p(this.h,0,1,t)}o(t){return"numPoses"in t&&xt(this.j,4,t.numPoses??1),"minPoseDetectionConfidence"in t&&g(this.j,2,t.minPoseDetectionConfidence??.5),"minTrackingConfidence"in t&&g(this.h,4,t.minTrackingConfidence??.5),"minPosePresenceConfidence"in t&&g(this.C,2,t.minPosePresenceConfidence??.5),"outputSegmentationMasks"in t&&(this.outputSegmentationMasks=t.outputSegmentationMasks??!1),this.l(t)}F(t,e,r){const n=typeof e!="function"?e:{};return this.u=typeof e=="function"?e:r,Us(this),bt(this,t,n),Ns(this)}G(t,e,r,n){const s=typeof r!="function"?r:{};return this.u=typeof r=="function"?r:n,Us(this),Ct(this,t,s,e),Ns(this)}m(){var t=new Q;F(t,"image_in"),F(t,"norm_rect"),S(t,"normalized_landmarks"),S(t,"world_landmarks"),S(t,"segmentation_masks");const e=new dt;yt(e,R2,this.h);const r=new $;gt(r,"mediapipe.tasks.vision.pose_landmarker.PoseLandmarkerGraph"),A(r,"IMAGE:image_in"),A(r,"NORM_RECT:norm_rect"),w(r,"NORM_LANDMARKS:normalized_landmarks"),w(r,"WORLD_LANDMARKS:world_landmarks"),r.o(e),mt(t,r),Bn(this,t),this.g.attachProtoVectorListener("normalized_landmarks",(n,s)=>{this.landmarks=[];for(const i of n)n=_r(i),this.landmarks.push(Cn(n));d(this,s)}),this.g.attachEmptyPacketListener("normalized_landmarks",n=>{this.landmarks=[],d(this,n)}),this.g.attachProtoVectorListener("world_landmarks",(n,s)=>{this.worldLandmarks=[];for(const i of n)n=On(i),this.worldLandmarks.push(Po(n));d(this,s)}),this.g.attachEmptyPacketListener("world_landmarks",n=>{this.worldLandmarks=[],d(this,n)}),this.outputSegmentationMasks&&(w(r,"SEGMENTATION_MASK:segmentation_masks"),Ae(this,"segmentation_masks"),this.g.Y("segmentation_masks",(n,s)=>{this.v=n.map(i=>Te(this,i,!this.u)),d(this,s)}),this.g.attachEmptyPacketListener("segmentation_masks",n=>{this.v=[],d(this,n)})),t=t.g(),this.setGraph(new Uint8Array(t),!0)}};nt.prototype.detectForVideo=nt.prototype.G,nt.prototype.detect=nt.prototype.F,nt.prototype.setOptions=nt.prototype.o,nt.createFromModelPath=function(t,e){return y(nt,t,{baseOptions:{modelAssetPath:e}})},nt.createFromModelBuffer=function(t,e){return y(nt,t,{baseOptions:{modelAssetBuffer:e}})},nt.createFromOptions=function(t,e){return y(nt,t,e)},nt.POSE_CONNECTIONS=vt([0,1],[1,2],[2,3],[3,7],[0,4],[4,5],[5,6],[6,8],[9,10],[11,12],[11,13],[13,15],[15,17],[15,19],[15,21],[17,19],[12,14],[14,16],[16,18],[16,20],[16,22],[18,20],[11,23],[12,24],[23,24],[23,25],[24,26],[25,27],[26,28],[27,29],[28,30],[29,31],[30,32],[27,31],[28,32]);export{it as FaceDetector,M as FaceLandmarker,Et as FaceStylizer,Ue as FilesetResolver,tt as GestureRecognizer,et as HandLandmarker,ot as ImageClassifier,rt as ImageEmbedder,q as ImageSegmenter,Yr as ImageSegmenterResult,At as InteractiveSegmenter,Jr as InteractiveSegmenterResult,V as MPImage,j as MPMask,at as ObjectDetector,nt as PoseLandmarker,Kr as TaskRunner,st as VisionTaskRunner};
|
|
16
|
+
//# sourceMappingURL=chunk-DAfdqQjW.js.map
|