/*! * ONNX Runtime Common v1.14.0 * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.ort=t():e.ort=t()}(self,(function(){return function(){"use strict";var e={d:function(t,r){for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r:function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{InferenceSession:function(){return p},Tensor:function(){return h},env:function(){return a},registerBackend:function(){return o}});var r={},n=[],o=function(e,t,o){if(!t||"function"!=typeof t.init||"function"!=typeof t.createSessionHandler)throw new TypeError("not a valid backend");var i=r[e];if(void 0===i)r[e]={backend:t,priority:o};else{if(i.priority>o)return;if(i.priority===o&&i.backend!==t)throw new Error('cannot register backend "'.concat(e,'" using priority ').concat(o))}if(o>=0){var a=n.indexOf(e);-1!==a&&n.splice(a,1);for(var f=0;f0&&o[o.length-1])||6!==f[0]&&2!==f[0])){a=0;continue}if(3===f[0]&&(!o||f[1]>o[0]&&f[1]0&&o[o.length-1])||6!==f[0]&&2!==f[0])){a=0;continue}if(3===f[0]&&(!o||f[1]>o[0]&&f[1]0&&o[o.length-1])||6!==f[0]&&2!==f[0])){a=0;continue}if(3===f[0]&&(!o||f[1]>o[0]&&f[1]=s.byteLength)throw new RangeError("'byteOffset' is out of range [0, ".concat(s.byteLength,")."));if(c=t.byteLength-u,"number"==typeof n){if(c=n,!Number.isSafeInteger(c))throw new RangeError("'byteLength' must be an integer.");if(c<=0||u+c>s.byteLength)throw new RangeError("'byteLength' is out of range (0, ".concat(s.byteLength-u,"]."));if("object"==typeof o&&null!==o)f=o;else if(void 0!==o)throw new TypeError("'options' must be an object.")}else if(void 0!==n)throw new TypeError("'byteLength' must be a number.")}else if(void 0!==r)throw new TypeError("'options' must be an object.");a=new Uint8Array(s,u,c)}return h=f.executionProviders||[],d=h.map((function(e){return"string"==typeof e?e:e.name})),[4,i(d)];case 1:return[4,l.sent().createSessionHandler(a,f)];case 2:return[2,new e(l.sent())]}}))}))},e.prototype.startProfiling=function(){this.handler.startProfiling()},e.prototype.endProfiling=function(){this.handler.endProfiling()},Object.defineProperty(e.prototype,"inputNames",{get:function(){return this.handler.inputNames},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"outputNames",{get:function(){return this.handler.outputNames},enumerable:!1,configurable:!0}),e}();return t}()})); //# sourceMappingURL=ort-common.es5.min.js.map